Пример #1
0
 /**
  * Handle the specified command.
  * @param CommandInterface $command
  */
 public function handle(CommandInterface $command)
 {
     $handlerName = $command->getCommandName() . 'Handler';
     $handlers = $this->loadHandlers($handlerName);
     foreach ($handlers as $handler) {
         $handler->handle($command);
     }
 }
Пример #2
0
 /**
  * @param SimpleCommand $command
  * @return mixed
  */
 public function handle(\TomWright\Commander\Command\CommandInterface $command)
 {
     $command->setExecuted(true);
     $command->setSuccessful(true);
 }