Joomla CMS
4.2.2
Documentation des API du CMS Joomla en version 4.2.2
|
Fonctions membres publiques | |
__construct (array $parameters, InputDefinition $definition=null) | |
getFirstArgument () | |
hasParameterOption ($values, bool $onlyParams=false) | |
getParameterOption ($values, $default=false, bool $onlyParams=false) | |
__toString () | |
Fonctions membres publiques hérités de Input | |
__construct (InputDefinition $definition=null) | |
bind (InputDefinition $definition) | |
validate () | |
isInteractive () | |
setInteractive (bool $interactive) | |
getArguments () | |
getArgument (string $name) | |
setArgument (string $name, $value) | |
hasArgument (string $name) | |
getOptions () | |
getOption (string $name) | |
setOption (string $name, $value) | |
hasOption (string $name) | |
escapeToken (string $token) | |
setStream ($stream) | |
getStream () | |
Fonctions membres protégées | |
parse () | |
Fonctions membres protégées hérités de Input | |
parse () | |
Fonctions membres privées | |
addShortOption (string $shortcut, $value) | |
addLongOption (string $name, $value) | |
addArgument ($name, $value) | |
Attributs privés | |
$parameters | |
Membres hérités additionnels | |
Attributs protégés hérités de Input | |
$definition | |
$stream | |
$options = [] | |
$arguments = [] | |
$interactive = true | |
ArrayInput represents an input provided as an array.
Usage:
$input = new ArrayInput(['command' => 'foo:bar', 'foo' => 'bar', '--bar' => 'foobar']);
__construct | ( | array | $parameters, |
InputDefinition | $definition = null |
||
) |
__toString | ( | ) |
Returns a stringified representation of the args passed to the command.
Références $params, $this, $val, et Input\escapeToken().
|
private |
Adds an argument value.
string | int | $name | The argument name |
mixed | $value | The value for the argument |
InvalidArgumentException | When argument given doesn't exist |
Référencé par ArrayInput\parse().
|
private |
Adds a long option value.
InvalidOptionException | When option given doesn't exist |
InvalidOptionException | When a required value is missing |
Références $name, $option, $value, et null.
Référencé par ArrayInput\addShortOption(), et ArrayInput\parse().
|
private |
Adds a short option value.
InvalidOptionException | When option given doesn't exist |
Références $value, et ArrayInput\addLongOption().
Référencé par ArrayInput\parse().
getFirstArgument | ( | ) |
{Returns the first argument from the raw parameters (not parsed).
Implémente InputInterface.
{Returns the value of a raw option (not parsed).This method is to be used to introspect the input parameters before they have been validated. It must be used carefully. Does not necessarily return the correct result for short options when multiple flags are combined in the same option.
string | array | $values | The value(s) to look for in the raw parameters (can be an array) |
string | bool | int | float | array | null | $default | The default value to return if no result is found |
bool | $onlyParams | Only check real parameters, skip those following an end of options (–) signal |
Implémente InputInterface.
hasParameterOption | ( | $values, | |
bool | $onlyParams = false |
||
) |
{Returns true if the raw parameters (not parsed) contain a value.This method is to be used to introspect the input parameters before they have been validated. It must be used carefully. Does not necessarily return the correct result for short options when multiple flags are combined in the same option.
string | array | $values | The values to look for in the raw parameters (can be an array) |
bool | $onlyParams | Only check real parameters, skip those following an end of options (–) signal |
Implémente InputInterface.
|
protected |
{}
Références $key, $value, ArrayInput\addArgument(), ArrayInput\addLongOption(), ArrayInput\addShortOption(), et elseif.
|
private |
Référencé par ArrayInput\__construct().