/var/www/vhosts/ihelp.ro/httpdocs/vendor/cakephp/cakephp/src/Console
NameSizeModeActions
Command/-0755rm
Exception/-0755rm
TestSuite/-0755rm
Arguments.php39260644editdlrm
BaseCommand.php85150644editdlrm
Command.php1420644editdlrm
CommandCollection.php74910644editdlrm
CommandCollectionAwareInterface.php10270644editdlrm
CommandFactory.php19790644editdlrm
CommandFactoryInterface.php10010644editdlrm
CommandInterface.php16980644editdlrm
CommandRunner.php126430644editdlrm
CommandScanner.php48430644editdlrm
composer.json11730644editdlrm
ConsoleErrorHandler.php1890644editdlrm
ConsoleInput.php28530644editdlrm
ConsoleInputArgument.php55680644editdlrm
ConsoleInputOption.php89290644editdlrm
ConsoleInputSubcommand.php39340644editdlrm
ConsoleIo.php215160644editdlrm
ConsoleOptionParser.php315660644editdlrm
ConsoleOutput.php100000644editdlrm
Helper.php17050644editdlrm
HelperRegistry.php32650644editdlrm
HelpFormatter.php73140644editdlrm
LICENSE.txt12040644editdlrm
README.md34650644editdlrm
Shell.php293710644editdlrm
ShellDispatcher.php121610644editdlrm
TaskRegistry.php29310644editdlrm
Edit: /var/www/vhosts/ihelp.ro/httpdocs/vendor/cakephp/cakephp/src/Console/Arguments.php (3926B)
*/ protected $argNames; /** * Positional arguments. * * @var array */ protected $args; /** * Named options * * @var array */ protected $options; /** * Constructor * * @param array $args Positional arguments * @param array $options Named arguments * @param array $argNames List of argument names. Order is expected to be * the same as $args. */ public function __construct(array $args, array $options, array $argNames) { $this->args = $args; $this->options = $options; $this->argNames = $argNames; } /** * Get all positional arguments. * * @return array */ public function getArguments(): array { return $this->args; } /** * Get positional arguments by index. * * @param int $index The argument index to access. * @return string|null The argument value or null */ public function getArgumentAt(int $index): ?string { if ($this->hasArgumentAt($index)) { return $this->args[$index]; } return null; } /** * Check if a positional argument exists * * @param int $index The argument index to check. * @return bool */ public function hasArgumentAt(int $index): bool { return isset($this->args[$index]); } /** * Check if a positional argument exists by name * * @param string $name The argument name to check. * @return bool */ public function hasArgument(string $name): bool { $offset = array_search($name, $this->argNames, true); if ($offset === false) { return false; } return isset($this->args[$offset]); } /** * Check if a positional argument exists by name * * @param string $name The argument name to check. * @return string|null */ public function getArgument(string $name): ?string { $offset = array_search($name, $this->argNames, true); if ($offset === false || !isset($this->args[$offset])) { return null; } return $this->args[$offset]; } /** * Get an array of all the options * * @return array */ public function getOptions(): array { return $this->options; } /** * Get an option's value or null * * @param string $name The name of the option to check. * @return string|int|bool|null The option value or null. */ public function getOption(string $name) { return $this->options[$name] ?? null; } /** * Check if an option is defined and not null. * * @param string $name The name of the option to check. * @return bool */ public function hasOption(string $name): bool { return isset($this->options[$name]); } }