Runner
Runs the generator
Constructors / Destructors
| Returns | Signature and Description |
|---|---|
void | Creates a new Runner. |
Instance Methods
| Returns | Signature and Description |
|---|---|
void | run()Runs the program. |
| Returns | Signature and Description |
|---|---|
Command | getCommand()Gets the command. |
Set<string> | getExcludes()Gets the list of excluded paths |
LoggerInterface | getLogger()Creates a new Logger based on passed options. |
void | help()Prints the help information |
noreturn | unknownOption()Handles an unknown option exception. |
void | version()Prints the version information |
Method Details
__construct
public function
__construct()Creates a new Runner.
getCommand
protected function
getCommand(Traversable<string> $args)Gets the command.
| Name | Type | Description |
|---|---|---|
$args | Traversable<string> | The command line arguments |
| Type | Description |
|---|---|
Command | The parsed command to execute |
getExcludes
protected function
getExcludes(ImmMap<string,mixed> $options)Gets the list of excluded paths
| Name | Type | Description |
|---|---|---|
$options | ImmMap<string,mixed> | The options |
| Type | Description |
|---|---|
Set<string> | The excluded paths |
getLogger
protected function
getLogger(ImmMap<string,mixed> $options)Creates a new Logger based on passed options.
| Name | Type | Description |
|---|---|---|
$options | ImmMap<string,mixed> | The options |
| Type | Description |
|---|---|
LoggerInterface | The created logger |
help
protected function
help()Prints the help information
run
public function
run(Traversable<string> $args)Runs the program.
| Name | Type | Description |
|---|---|---|
$args | Traversable<string> | The command line arguments |
unknownOption
protected function
unknownOption(UnexpectedValueException $e)Handles an unknown option exception.
| Name | Type | Description |
|---|---|---|
$e | UnexpectedValueException | The exception |
| Type | Description |
|---|---|
noreturn |
version
protected function
version()Prints the version information