[ Index ] |
PHP Cross Reference of phpBB-3.1.12-deutsch |
[Source view] [Print] [Project Stats]
(no description)
File Size: | 588 lines (17 kb) |
Included or required: | 0 times |
Referenced: | 0 times |
Includes or requires: | 0 files |
Command:: (33 methods):
__construct()
ignoreValidationErrors()
setApplication()
setHelperSet()
getHelperSet()
getApplication()
isEnabled()
configure()
execute()
interact()
initialize()
run()
setCode()
mergeApplicationDefinition()
setDefinition()
getDefinition()
getNativeDefinition()
addArgument()
addOption()
setName()
getName()
setDescription()
getDescription()
setHelp()
getHelp()
getProcessedHelp()
setAliases()
getAliases()
getSynopsis()
getHelper()
asText()
asXml()
validateName()
__construct($name = null) X-Ref |
Constructor. param: string $name The name of the command |
ignoreValidationErrors() X-Ref |
Ignores validation errors. This is mainly useful for the help command. |
setApplication(Application $application = null) X-Ref |
Sets the application instance for this command. param: Application $application An Application instance |
setHelperSet(HelperSet $helperSet) X-Ref |
Sets the helper set. param: HelperSet $helperSet A HelperSet instance |
getHelperSet() X-Ref |
Gets the helper set. return: HelperSet A HelperSet instance |
getApplication() X-Ref |
Gets the application instance for this command. return: Application An Application instance |
isEnabled() X-Ref |
Checks whether the command is enabled or not in the current environment. Override this to check for x or y and return false if the command can not run properly under the current conditions. return: bool |
configure() X-Ref |
Configures the current command. |
execute(InputInterface $input, OutputInterface $output) X-Ref |
Executes the current command. This method is not abstract because you can use this class as a concrete class. In this case, instead of defining the execute() method, you set the code to execute by passing a Closure to the setCode() method. param: InputInterface $input An InputInterface instance param: OutputInterface $output An OutputInterface instance return: null|int null or 0 if everything went fine, or an error code |
interact(InputInterface $input, OutputInterface $output) X-Ref |
Interacts with the user. This method is executed before the InputDefinition is validated. This means that this is the only place where the command can interactively ask for values of missing required arguments. param: InputInterface $input An InputInterface instance param: OutputInterface $output An OutputInterface instance |
initialize(InputInterface $input, OutputInterface $output) X-Ref |
Initializes the command just after the input has been validated. This is mainly useful when a lot of commands extends one main command where some things need to be initialized based on the input arguments and options. param: InputInterface $input An InputInterface instance param: OutputInterface $output An OutputInterface instance |
run(InputInterface $input, OutputInterface $output) X-Ref |
Runs the command. The code to execute is either defined directly with the setCode() method or by overriding the execute() method in a sub-class. param: InputInterface $input An InputInterface instance param: OutputInterface $output An OutputInterface instance return: int The command exit code |
setCode($code) X-Ref |
Sets the code to execute when running this command. If this method is used, it overrides the code defined in the execute() method. param: callable $code A callable(InputInterface $input, OutputInterface $output) return: Command The current instance |
mergeApplicationDefinition($mergeArgs = true) X-Ref |
Merges the application definition with the command definition. This method is not part of public API and should not be used directly. param: bool $mergeArgs Whether to merge or not the Application definition arguments to Command definition arguments |
setDefinition($definition) X-Ref |
Sets an array of argument and option instances. param: array|InputDefinition $definition An array of argument and option instances or a definition instance return: Command The current instance |
getDefinition() X-Ref |
Gets the InputDefinition attached to this Command. return: InputDefinition An InputDefinition instance |
getNativeDefinition() X-Ref |
Gets the InputDefinition to be used to create XML and Text representations of this Command. Can be overridden to provide the original command representation when it would otherwise be changed by merging with the application InputDefinition. This method is not part of public API and should not be used directly. return: InputDefinition An InputDefinition instance |
addArgument($name, $mode = null, $description = '', $default = null) X-Ref |
Adds an argument. param: string $name The argument name param: int $mode The argument mode: InputArgument::REQUIRED or InputArgument::OPTIONAL param: string $description A description text param: mixed $default The default value (for InputArgument::OPTIONAL mode only) return: Command The current instance |
addOption($name, $shortcut = null, $mode = null, $description = '', $default = null) X-Ref |
Adds an option. param: string $name The option name param: string $shortcut The shortcut (can be null) param: int $mode The option mode: One of the InputOption::VALUE_* constants param: string $description A description text param: mixed $default The default value (must be null for InputOption::VALUE_NONE) return: Command The current instance |
setName($name) X-Ref |
Sets the name of the command. This method can set both the namespace and the name if you separate them by a colon (:) $command->setName('foo:bar'); param: string $name The command name return: Command The current instance |
getName() X-Ref |
Returns the command name. return: string The command name |
setDescription($description) X-Ref |
Sets the description for the command. param: string $description The description for the command return: Command The current instance |
getDescription() X-Ref |
Returns the description for the command. return: string The description for the command |
setHelp($help) X-Ref |
Sets the help for the command. param: string $help The help for the command return: Command The current instance |
getHelp() X-Ref |
Returns the help for the command. return: string The help for the command |
getProcessedHelp() X-Ref |
Returns the processed help for the command replacing the %command.name% and %command.full_name% patterns with the real values dynamically. return: string The processed help for the command |
setAliases($aliases) X-Ref |
Sets the aliases for the command. param: string[] $aliases An array of aliases for the command return: Command The current instance |
getAliases() X-Ref |
Returns the aliases for the command. return: array An array of aliases for the command |
getSynopsis() X-Ref |
Returns the synopsis for the command. return: string The synopsis |
getHelper($name) X-Ref |
Gets a helper instance by name. param: string $name The helper name return: mixed The helper value |
asText() X-Ref |
Returns a text representation of the command. return: string A string representing the command |
asXml($asDom = false) X-Ref |
Returns an XML representation of the command. param: bool $asDom Whether to return a DOM or an XML string return: string|\DOMDocument An XML string representing the command |
validateName($name) X-Ref |
No description |
Generated: Thu Jan 11 00:25:41 2018 | Cross-referenced by PHPXref 0.7.1 |