1 | <?php |
||
30 | class PommAwareCommand extends Command |
||
31 | { |
||
32 | private $pomm; |
||
33 | |||
34 | protected $config_file; |
||
35 | |||
36 | /** |
||
37 | * execute |
||
38 | * |
||
39 | * Set pomm dependent variables. |
||
40 | * |
||
41 | * @see Command |
||
42 | */ |
||
43 | protected function execute(InputInterface $input, OutputInterface $output) |
||
47 | |||
48 | /** |
||
49 | * configureRequiredArguments |
||
50 | * |
||
51 | * In order to keep the same argument order for all commands, it is |
||
52 | * necessary to be able to declare base required fields before subcommands. |
||
53 | * |
||
54 | * @access protected |
||
55 | * @return PommAwareCommand $this |
||
56 | */ |
||
57 | protected function configureRequiredArguments() |
||
61 | |||
62 | /** |
||
63 | * configureOptionals |
||
64 | * |
||
65 | * In order to keep the same argument order for all commands, it is |
||
66 | * necessary to be able to declare base required fields before subcommands. |
||
67 | * |
||
68 | * @access protected |
||
69 | * @return PommAwareCommand $this |
||
70 | */ |
||
71 | protected function configureOptionals() |
||
85 | |||
86 | /** |
||
87 | * configure |
||
88 | * |
||
89 | * @see Command |
||
90 | */ |
||
91 | protected function configure() |
||
98 | |||
99 | /** |
||
100 | * getPomm |
||
101 | * |
||
102 | * Return the Pomm instance. |
||
103 | * |
||
104 | * @access protected |
||
105 | * @return Pomm |
||
106 | * @throws CliException |
||
107 | */ |
||
108 | protected function getPomm() |
||
124 | |||
125 | /** |
||
126 | * setPomm |
||
127 | * |
||
128 | * When used with a framework, it is useful to get the Pomm instance from |
||
129 | * the framework configuration mechanism. |
||
130 | * |
||
131 | * @access public |
||
132 | * @param Pomm $pomm |
||
133 | * @return PommAwareCommand |
||
134 | */ |
||
135 | public function setPomm(Pomm $pomm) |
||
141 | } |
||
142 |