N98\Magento\Command\Developer\Ide\PhpStorm\MetaCommand::writeToOutput PHP Метод

writeToOutput() защищенный Метод

protected writeToOutput ( Symfony\Component\Console\Input\InputInterface $input, Symfony\Component\Console\Output\OutputInterface $output, $classMaps )
$input Symfony\Component\Console\Input\InputInterface
$output Symfony\Component\Console\Output\OutputInterface
$classMaps
    protected function writeToOutput(InputInterface $input, OutputInterface $output, $classMaps)
    {
        $map = <<<PHP
<?php
namespace PHPSTORM_META {
    /** @noinspection PhpUnusedLocalVariableInspection */
    /** @noinspection PhpIllegalArrayKeyTypeInspection */
    /** @noinspection PhpLanguageLevelInspection */
    \$STATIC_METHOD_TYPES = [
PHP;
        $map .= "\n";
        foreach ($this->groupFactories as $group => $methods) {
            foreach ($methods as $method) {
                $map .= "        " . $method . "('') => [\n";
                foreach ($classMaps[$group] as $classPrefix => $class) {
                    $map .= "            '{$classPrefix}' instanceof \\{$class},\n";
                }
                $map .= "        ], \n";
            }
        }
        $map .= <<<PHP
    ];
}
PHP;
        if ($input->getOption('stdout')) {
            $output->writeln($map);
        } else {
            if (\file_put_contents($this->_magentoRootFolder . '/.phpstorm.meta.php', $map)) {
                $output->writeln('<info>File <comment>.phpstorm.meta.php</comment> generated</info>');
            }
        }
    }