class Shell extends Shell (View source)

Methods

null|string
getCommand(string $input)

Get a command (if one exists) for the current input string.

bool
hasCommand(string $input)

Check whether a command is set for the current input string.

string|NULL
getCommandFromInput(string $input)

Get the command from the current input, takes aliases into account.

Details

protected null|string getCommand(string $input)

Get a command (if one exists) for the current input string.

Parameters

string $input

Return Value

null|string

protected bool hasCommand(string $input)

Check whether a command is set for the current input string.

Parameters

string $input

Return Value

bool True if the shell has a command for the given input.

protected string|NULL getCommandFromInput(string $input)

Get the command from the current input, takes aliases into account.

Parameters

string $input The raw input

Return Value

string|NULL The current command.