class LegacyParamArgvInput extends ArgvInput (View source)

deprecated 6.0.0 Use Symfony\Component\Console\Input\ArgvInput instead.

Represents an input coming from the CLI arguments - but converts legacy arg-style parameters to flags.

e.g. ddev dev:build flush=1 is converted to ddev dev:build --flush. Doesn't convert anything that isn't explicitly an InputOption in the relevant InputDefinition. Removes the parameters from the input args (e.g. doesn't become ddev dev:build flush=1 --flush).

Methods

public
__construct(array|null $argv = null, InputDefinition|null $definition = null)

No description

public
bool
hasParameterOption(string|array $values, bool $onlyParams = false)

No description

public
mixed
getParameterOption(string|array $values, string|bool|int|float|array|null $default = false, bool $onlyParams = false)

No description

public
void
bind(InputDefinition $definition)

Binds the current Input instance with the given arguments and options.

protected
void
setTokens(array $tokens)

No description

public
mixed
getLegacyParameterOption(string|array $values, string|bool|int|float|array|null $default = false)

No description

Details

__construct(array|null $argv = null, InputDefinition|null $definition = null)

No description

Parameters

array|null $argv
InputDefinition|null $definition

bool hasParameterOption(string|array $values, bool $onlyParams = false)

No description

Parameters

string|array $values
bool $onlyParams

Return Value

bool

mixed getParameterOption(string|array $values, string|bool|int|float|array|null $default = false, bool $onlyParams = false)

No description

Parameters

string|array $values
string|bool|int|float|array|null $default
bool $onlyParams

Return Value

mixed

void bind(InputDefinition $definition)

Binds the current Input instance with the given arguments and options.

Also converts any arg-style params into true flags, based on the options defined.

Parameters

InputDefinition $definition

Return Value

void

protected void setTokens(array $tokens)

No description

Parameters

array $tokens

Return Value

void

mixed getLegacyParameterOption(string|array $values, string|bool|int|float|array|null $default = false)

No description

Parameters

string|array $values
string|bool|int|float|array|null $default

Return Value

mixed