EventDispatchingNodeCommandControllerPluginInterface
interface EventDispatchingNodeCommandControllerPluginInterface implements NodeCommandControllerPluginInterface (View source)
An interface for plugins for the NodeCommandController that dispatches events
Constants
EVENT_TASK |
Entering a task. Event arguments are $taskDescription, $taskClosure (only executed if not in dry-run) and (optionally) a $requiresConfirmation flag |
EVENT_NOTICE |
A notice is printed to the console |
EVENT_WARNING |
A warning is printed to the console but does not quit the execution |
EVENT_ERROR |
An error is printed to the console and stops the execution with an error exit code |
Methods
Returns a short description for the specific task the plugin solves for the specified command
Returns a piece of description for the specific task the plugin solves for the specified command
A method which runs the task implemented by the plugin for the given command
Details
static string
getSubCommandShortDescription(string $controllerCommandName)
Returns a short description for the specific task the plugin solves for the specified command
static string
getSubCommandDescription(string $controllerCommandName)
Returns a piece of description for the specific task the plugin solves for the specified command
void
invokeSubCommand(string $controllerCommandName, ConsoleOutput $output, NodeType $nodeType = null, string $workspaceName = 'live', bool $dryRun = false, bool $cleanup = true)
A method which runs the task implemented by the plugin for the given command
void
on(string $eventIdentifier, Closure $callback)
Attaches a new event handler