Magestead\Command\Index\SetModeCommand::execute PHP Метод

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

protected execute ( Symfony\Component\Console\Input\InputInterface $input, Symfony\Component\Console\Output\OutputInterface $output ) : ProcessCommand | null
$input Symfony\Component\Console\Input\InputInterface
$output Symfony\Component\Console\Output\OutputInterface
Результат Magestead\Command\ProcessCommand | null
    protected function execute(InputInterface $input, OutputInterface $output)
    {
        $indexMode = $input->getArgument('mode');
        $command = $this->getCommand(new Config($output), $indexMode);
        if ($command) {
            $output->writeln('<info>Setting index mode</info>');
            $pCommand = "vagrant ssh -c '" . $command . "'";
            return new ProcessCommand($pCommand, $this->_projectPath, $output);
        }
        $output->writeln('<error>Command not available for this application</error>');
    }