class Shell extends Shell (View source)

Methods

Command|null
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 Command|null getCommand(string $input)

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

Parameters

string $input

Return Value

Command|null

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.