2727use Symfony \Component \Console \Style \SymfonyStyle ;
2828
2929/**
30- * Update a existing response class or API client method.
30+ * Update an existing response class or API client method.
3131 *
3232 * @author Tobias Nyholm <tobias.nyholm@gmail.com>
3333 */
@@ -38,14 +38,29 @@ class GenerateCommand extends Command
3838
3939 private $ manifest ;
4040
41+ /**
42+ * @var string
43+ */
4144 private $ manifestFile ;
4245
46+ /**
47+ * @var Cache
48+ */
4349 private $ cache ;
4450
51+ /**
52+ * @var ApiGenerator
53+ */
4554 private $ generator ;
4655
56+ /**
57+ * @var ClassWriter
58+ */
4759 private $ classWriter ;
4860
61+ /**
62+ * @var ComposerWriter
63+ */
4964 private $ composerWriter ;
5065
5166 public function __construct (string $ manifestFile , Cache $ cache , ClassWriter $ classWriter , ComposerWriter $ composerWriter , ApiGenerator $ generator )
@@ -59,7 +74,7 @@ public function __construct(string $manifestFile, Cache $cache, ClassWriter $cla
5974 parent ::__construct ();
6075 }
6176
62- protected function configure ()
77+ protected function configure (): void
6378 {
6479 $ this ->setAliases (['update ' ]);
6580 $ this ->setDescription ('Create or update API client methods. ' );
@@ -140,6 +155,11 @@ private function generateServicesParallel(SymfonyStyle $io, InputInterface $inpu
140155 return $ manifest ;
141156 }
142157
158+ /**
159+ * @param string[] $serviceNames
160+ *
161+ * @return array|int
162+ */
143163 private function generateServicesSequential (SymfonyStyle $ io , InputInterface $ input , ConsoleOutputInterface $ output , array $ manifest , array $ endpoints , array $ serviceNames )
144164 {
145165 if (\count ($ serviceNames ) > 1 ) {
@@ -302,7 +322,9 @@ private function generateService(SymfonyStyle $io, InputInterface $input, array
302322 }
303323
304324 /**
305- * @return array|int
325+ * @param array<string, mixed> $manifest
326+ *
327+ * @return list<string>|int
306328 */
307329 private function getServiceNames (?string $ inputServiceName , bool $ returnAll , SymfonyStyle $ io , array $ manifest )
308330 {
@@ -331,7 +353,11 @@ private function getServiceNames(?string $inputServiceName, bool $returnAll, Sym
331353 }
332354
333355 /**
334- * @return array|int
356+ * @param array{operations: array<string, mixed>,...} $definition
357+ * @param array{waiters: array<string, mixed>} $waiter
358+ * @param array{methods: list<string>,...} $manifest
359+ *
360+ * @return string[]|int
335361 */
336362 private function getOperationNames (?string $ inputOperationName , bool $ returnAll , SymfonyStyle $ io , array $ definition , array $ waiter , array $ manifest )
337363 {
0 commit comments