1 | <?php |
||
12 | class VhostDefineCommand extends ContainerAwareCommand |
||
13 | { |
||
14 | /** |
||
15 | * {@inheritDoc} |
||
16 | */ |
||
17 | 6 | protected function configure() |
|
26 | |||
27 | /** |
||
28 | * {@inheritDoc} |
||
29 | */ |
||
30 | 6 | protected function execute(InputInterface $input, OutputInterface $output) |
|
55 | |||
56 | /** |
||
57 | * Retrieve vhost's name to process |
||
58 | * |
||
59 | * @param InputInterface $input |
||
60 | * |
||
61 | * @return string |
||
62 | */ |
||
63 | 6 | private function getVhost(InputInterface $input) |
|
72 | |||
73 | /** |
||
74 | * @param InputInterface $input |
||
75 | * @param OutputInterface $output |
||
|
|||
76 | * |
||
77 | * @return VhostConfiguration |
||
78 | * |
||
79 | * @throws \InvalidArgumentException |
||
80 | */ |
||
81 | 6 | private function getVhostConfiguration(InputInterface $input) |
|
99 | |||
100 | /** |
||
101 | * @param InputInterface $input |
||
102 | * @param OutputInterface $output |
||
103 | * @param string $message |
||
104 | */ |
||
105 | 6 | private function comment(InputInterface $input, OutputInterface $output, $message) |
|
106 | { |
||
107 | 6 | $io = $this->getIO($input, $output); |
|
108 | |||
109 | 6 | if (null !== $io && method_exists($io, 'comment')) { |
|
110 | 6 | $io->comment($message); |
|
111 | 6 | } else { |
|
112 | $output->writeln(sprintf('<comment>%s</comment>', $message)); |
||
113 | } |
||
114 | 6 | } |
|
115 | |||
116 | /** |
||
117 | * @param InputInterface $input |
||
118 | * @param OutputInterface $output |
||
119 | * @param string $message |
||
120 | */ |
||
121 | 4 | private function success(InputInterface $input, OutputInterface $output, $message) |
|
122 | { |
||
123 | 4 | $io = $this->getIO($input, $output); |
|
124 | |||
125 | 4 | if (null !== $io) { |
|
126 | 4 | $io->success($message); |
|
127 | 4 | } else { |
|
128 | $output->writeln(sprintf('<info>%s</info>', $message)); |
||
129 | } |
||
130 | 4 | } |
|
131 | |||
132 | /** |
||
133 | * @param InputInterface $input |
||
134 | * @param OutputInterface $output |
||
135 | * @return null|\Symfony\Component\Console\Style\SymfonyStyle |
||
136 | */ |
||
137 | 6 | private function getIO(InputInterface $input, OutputInterface $output) |
|
145 | } |
||
146 |
This check looks for PHPDoc comments describing methods or function parameters that do not exist on the corresponding method or function.
Consider the following example. The parameter
$italy
is not defined by the methodfinale(...)
.The most likely cause is that the parameter was removed, but the annotation was not.