Base class for tasks that depends on a sfCommandApplication object.
Method Summary
Methods inherited from sfTask
addArgument , addArguments , addOption , addOptions , ask , askAndValidate , askConfirmation , asXml , configure , doRun , execute , getAliases , getArguments , getBriefDescription , getDetailedDescription , getFormatter , getFullName , getName , getNamespace , getOptions , getSynopsis , initialize , log , logBlock , logSection , process , run , runFromCLI , setFormatter , strlen , __construct
Method Details
-
(sfTask) createTask ($name)
Browse code
| $name |
The name of the task |
Creates a new task object.
throws LogicException If the current task has no command application
-
(sfMailer) getMailer ()
Browse code
Returns a mailer instance.
Notice that your task should accept an application option.
The mailer configuration is read from the current configuration
instance, which is automatically created according to the current
--application option.
returns A sfMailer instance
-
(sfRouting) getRouting ()
Browse code
Returns a routing instance.
Notice that your task should accept an application option.
The routing configuration is read from the current configuration
instance, which is automatically created according to the current
--application option.
returns A sfRouting instance
-
-
-
@see sfTask
-
@see sfTask
-
(Boolean) runTask ($name, $arguments, $options)
Browse code
| $name |
The name of the task to execute |
| $arguments |
An array of arguments to pass to the task |
| $options |
An array of options to pass to the task |
Executes another task in the context of the current one.
returns The returned value of the task run() method
-
setCommandApplication ($commandApplication)
Browse code
| $commandApplication |
A sfCommandApplication instance |
Sets the command application instance for this task.
|