1 | <?php |
||
31 | abstract class CloudCommand extends Command |
||
32 | { |
||
33 | 85 | private $cloudManager; |
|
34 | |||
35 | 85 | public function __construct(CloudManagerInterface $cloudManager) |
|
41 | |||
42 | 85 | /** |
|
43 | * {@inheritDoc} |
||
44 | */ |
||
45 | protected function configure() |
||
55 | |||
56 | /** |
||
57 | * @return \Xabbuh\PandaClient\Api\CloudManager |
||
58 | */ |
||
59 | 67 | protected function getCloudManager() |
|
63 | |||
64 | /** |
||
65 | * Get the cloud to work on. |
||
66 | * |
||
67 | * @param \Symfony\Component\Console\Input\InputInterface $input |
||
68 | * |
||
69 | * @return \Xabbuh\PandaClient\Api\CloudInterface |
||
70 | */ |
||
71 | protected function getCloud(InputInterface $input) |
||
79 | 69 | ||
80 | /** |
||
81 | * Executes the actual command (to be implemented by subclasses, will be called automatically). |
||
82 | 69 | * |
|
83 | 29 | * @param InputInterface $input |
|
84 | 29 | * @param OutputInterface $output |
|
85 | */ |
||
86 | 69 | abstract protected function doExecuteCommand(InputInterface $input, OutputInterface $output); |
|
87 | |||
88 | /** |
||
89 | * {@inheritDoc} |
||
90 | */ |
||
91 | protected function execute(InputInterface $input, OutputInterface $output) |
||
99 | } |
||
100 |