Returns

Link

Dispatch a command to another Shell. Similar to Object::requestAction()
but intended for running shells from other shells.

Usage:

With a string command:

return$this->dispatchShell('schema create DbAcl');

Avoid using this form if you have string arguments, with spaces in them.
The dispatched will be invoked incorrectly. Only use this form for simple
command dispatching.

With an array command:

return$this->dispatchShell('schema', 'create', 'i18n', '--dry');

With an array having two key / value pairs:
- command can accept either a string or an array. Represents the command to dispatch
- extra can accept an array of extra parameters to pass on to the dispatcher. This
parameters will be available in the param property of the called Shell

Returns

Link

Outputs a single or multiple messages to stdout. If no parameters
are passed outputs just a newline.

Output levels

There are 3 built-in output level. Shell::QUIET, Shell::NORMAL, Shell::VERBOSE.
The verbose and quiet output levels, map to the verbose and quiet output switches
present in most shells. Using Shell::QUIET for a message means it will always display.
While using Shell::VERBOSE means it will only display when verbose output is toggled.

Returns

Delegates calls to Tasks and resolves methods inside the class. Commands are looked
up with the following order:

Method on the shell.

Matching task name.

main() method.

If a shell implements a main() method, all missing method calls will be sent to
main() with the original method name in the argv.

For tasks to be invoked they must be exposed as subcommands. If you define any subcommands,
you must define all the subcommands your shell needs, whether they be methods on this class
or methods on tasks.

Parameters

array
$argv

Array of arguments to run the shell with. This array should be missing the shell name.

boolean
$autoMethodoptionalfalse

Set to true to allow any public method to be called even if it
was not defined as a subcommand. This is used by ShellDispatcher to make building simple shells easy.

array
$extraoptional
[]

Extra parameters that you can manually pass to the Shell
to be dispatched.
Built-in extra parameter is :
- requested : if used, will prevent the Shell welcome message to be displayed