Add a new Artisan command event to the schedule.

@param  string $command
@param  array  $parameters
@return \Zilf\Console\Scheduling\Event
184355
public function command($command, array $parameters = [])
    {
        if (class_exists($command)) {
            $command = (new $command)->getName();
        }

        return $this->exec(
            Application::formatCommandString($command), $parameters
        );
    }
537119
public function handle(UpdateScheduleCommand $command)
    {
        $schedule = $command->schedule;

        $schedule->update($this->filter($command));

        event(new ScheduleWasUpdatedEvent($this->auth->user(), $schedule));

        return $schedule;
    }
1120516
protected function executeCommand(Command $command, array $arguments, OutputInterface $output)
    {
        $output = clone $output;
        if ($output->getVerbosity() >= OutputInterface::VERBOSITY_VERBOSE) {
            $output->setVerbosity($output->getVerbosity());
        } else {
            $output->setVerbosity(OutputInterface::VERBOSITY_QUIET);
        }

        return $command->run(new ArrayInput($arguments), $output);
    }
20736
public function call( $command, array $parameters = [] )
	{
		$parameters = collect( $parameters )->prepend( $command );

		$this->lastOutput = new BufferedOutput;

		$this->setCatchExceptions( false );

		$result = $this->run( new ArrayInput( $parameters->toArray() ), $this->lastOutput );

		$this->setCatchExceptions( true );

		return $result;
	}
517125
public function addCommand($command)
    {
        $command = $this->resolveCommandObject($command);

        /*
         * At this stage we definitely have a proper command to use.
         *
         * @var Command $command
         */
        $this->commands[$command->getName()] = $command;

        $aliases = $command->getAliases();

        if (empty($aliases)) {
            return $this;
        }

        foreach ($command->getAliases() as $alias) {
            if (isset($this->commands[$alias])) {
                throw new TelegramSDKException(sprintf(
                    '[Error] Alias [%s] conflicts with command name of "%s" try with another name or remove this alias from the list.',
                    $alias,
                    get_class($command)
                ));
            }

            if (isset($this->commandAliases[$alias])) {
                throw new TelegramSDKException(sprintf(
                    '[Error] Alias [%s] conflicts with another command\'s alias list: "%s", try with another name or remove this alias from the list.',
                    $alias,
                    get_class($command)
                ));
            }

            $this->commandAliases[$alias] = $command;
        }

        return $this;


    }
628982
protected function runCommand(\Parable\Console\Command $command, array $parameters = [])
    {
        $parameter = new \Parable\Console\Parameter();
        $parameter->setParameters($parameters);

        $command->prepare($this->app, $this->output, $this->input, $parameter);

        return $command->run();
    }
632321
protected function addCommand($name, array $parameters = array())
    {
        $this->commands[] = $command = $this->createCommand($name, $parameters);

        return $command;
    }
642898
public function addCommand(Command $command) {
        $this->commands[$command->getName()] = $command;
        $command->freeze();
        return $this;
    }
655125
final protected function callArtisanCommand($command, array $params = [])
    {
        // Default input arguments
        $inputArguments = ['NodesInstall', $command];

        // Add artisan parameters to input arguments
        if (!empty($params) && is_array($params)) {
            $inputArguments[] = implode(' ', $params);
        }

        // Execute Artisan command
        return $this->getInstaller()->getArtisan()->handle(
            new SymfonyConsoleInput($inputArguments),
            new SymfonyConsoleOutput()
        );
    }
1025220
protected function queueRequest(UserEventInterface $event, $command, array $params)
    {
        $event->setPrefix($this->prefix);
        $event->setCommand($command);
        $event->setParams(array_filter($params, 'strlen'));
        $this->queue->insert($event, $this->getPriority($command, $params));
    }
1291407
public function addCommand($command, $config = array())
    {
        if (!($command instanceof KControllerToolbarCommand)) {
            $command = $this->getCommand($command, $config);
        }

        return $this->getDelegate()->addCommand($command, $config);
    }
753422
public function runCommand($command, $argv) {
		if (!empty($this->args[0]) && $this->hasMethod($this->args[0])) {
			$this->action = $this->args[0];
		} else {
			$this->action = null;
		}
		$this->statisticsStart('AdvancedShell');
		Configure::write('debug', (int)Hash::get($this->params, 'debug'));
		if ($this->isScheduled()) {
			if ($this->params['scheduled-no-split']) {
				$this->setScheduleSplitter(new ScheduleNoSplit());
			}
			$this->schedule();
			$out = null;
		} elseif ($this->action) {
			$out = $this->{$this->action}();
		} else {
			$out = parent::runCommand($command, $argv);
		}
		$this->statisticsEnd('AdvancedShell');
		$this->sqlDump(false, false);
		$this->hr();
		return $out;
	}
895098
public function post($command, array $params)
	{
		$options = array();
		$options[CURLOPT_POST] = TRUE;

		if ($params) {
			$options[CURLOPT_POSTFIELDS] = json_encode($params);
		}

		return $this->call($command, $options);
	}
590093
public function call($command, array $parameters = array())
	{
		$this->bootstrap();

		// If we are calling a arbitary command from within the application, we will load
		// all of the available deferred providers which will make all of the commands
		// available to an application. Otherwise the command will not be available.
		$this->app->loadDeferredProviders();

		return $this->getArtisan()->call($command, $parameters);
	}
623676
protected function coreCommand($command, $core, $params = array())
    {
        $command = strtoupper($command);
        $params = array_merge($params, array('action' => $command, 'wt' => 'json'));
        $params[$command == 'CREATE' ? 'name' : 'core'] = $core;

        return $this->_sendRawGet($this->_constructUrl('admin/cores', $params));
    }
349509
public function handle(CreateScheduleCommand $command)
    {
        try {
            $schedule = Schedule::create($this->filter($command));

            event(new ScheduleWasCreatedEvent($this->auth->user(), $schedule));
        } catch (InvalidArgumentException $e) {
            throw new ValidationException(new MessageBag([$e->getMessage()]));
        }

        return $schedule;
    }
180548
public function addCustomCommand($command)
    {
        $name = lcfirst(class_basename($command));

        $this->customCommands[$name] = $command;
    }