| 1 | <?php |
||
| 17 | class ConsoleApplication |
||
| 18 | { |
||
| 19 | /** |
||
| 20 | * @var array |
||
| 21 | */ |
||
| 22 | private $commands = []; |
||
| 23 | |||
| 24 | /** |
||
| 25 | * Getter for association commands. |
||
| 26 | * |
||
| 27 | * @return ArrayCollection |
||
| 28 | */ |
||
| 29 | public function getCommands() |
||
| 33 | |||
| 34 | /** |
||
| 35 | * Setter for association commands. |
||
| 36 | * |
||
| 37 | * @param array $commands |
||
| 38 | * |
||
| 39 | * @return self |
||
| 40 | */ |
||
| 41 | public function setCommands($commands = []) |
||
| 47 | |||
| 48 | /** |
||
| 49 | * Adds an command if it doesn't exist to the association with commands. |
||
| 50 | * |
||
| 51 | * @param Command $command |
||
| 52 | * |
||
| 53 | * @return self |
||
| 54 | */ |
||
| 55 | public function addCommand(Command $command) |
||
| 61 | } |
||
| 62 |