Ubiquity 2.5.2
php rapid development framework
Loading...
Searching...
No Matches
AbstractCustomCommand Class Reference
+ Inheritance diagram for AbstractCustomCommand:

Public Member Functions

 __construct ()
 
 getCommand ()
 Return the command informations.
 
 run ($config, $options, $what,... $otherArgs)
 Run this command.
 

Protected Member Functions

 getName ()
 Return the command name.
 
 getValue ()
 Return the command parameter name.
 
 getDescription ()
 Return the command description.
 
 getAliases ()
 
 getParameters ()
 Return the list of parameters.
 
 getExamples ()
 Return a list of examples.
 
 getCategory ()
 Return the command category.
 

Protected Attributes

 $command
 

Additional Inherited Members

- Static Protected Member Functions inherited from CmdTrait
static parseArguments ()
 
static getOption ($options, $option, $longOption, $default=NULL)
 
static getOptionArray ($options, $option, $longOption, $default=NULL)
 
static getBooleanOption ($options, $option, $longOption, $default=NULL)
 
static hasOption ($options, $option, $longOption)
 
static requiredParam ($what, $paramName)
 
static answerModel ($options, $option, $longOption, $part, $config)
 
static getCompleteClassname ($config, $classname, $type='models')
 
static getSelectedModels ($models, $config)
 
static updateDomain ($options)
 

Detailed Description

Definition at line 16 of file AbstractCustomCommand.php.

Constructor & Destructor Documentation

◆ __construct()

__construct ( )

Definition at line 24 of file AbstractCustomCommand.php.

Member Function Documentation

◆ getAliases()

getAliases ( )
abstractprotected
Returns
array

◆ getCategory()

getCategory ( )
protected

Return the command category.

Returns
string

Definition at line 76 of file AbstractCustomCommand.php.

◆ getCommand()

getCommand ( )

Return the command informations.

Returns
\Ubiquity\devtools\cmd\Command

Definition at line 85 of file AbstractCustomCommand.php.

◆ getDescription()

getDescription ( )
abstractprotected

Return the command description.

Returns
string

◆ getExamples()

getExamples ( )
abstractprotected

Return a list of examples.

Sample: ['Clear all caches'=>'Ubiquity clear-cache -t=all','Clear models cache'=>'Ubiquity clear-cache -t=models']

Returns
array

◆ getName()

getName ( )
abstractprotected

Return the command name.

Returns
string

◆ getParameters()

getParameters ( )
abstractprotected

Return the list of parameters.

Sample: ['d'=>Parameter::create('database', 'The database connection to use', [],'default')].

Returns
array

◆ getValue()

getValue ( )
abstractprotected

Return the command parameter name.

Returns
string

◆ run()

run (   $config,
  $options,
  $what,
  $otherArgs 
)
abstract

Run this command.

Parameters
array$configThe Ubiquity application config array.
array$options
string$what
mixed...$otherArgs

Field Documentation

◆ $command

$command
protected

Definition at line 22 of file AbstractCustomCommand.php.


The documentation for this class was generated from the following file: