1 | <?php |
||
20 | class SwaggerGenerateCommand extends Command |
||
21 | { |
||
22 | |||
23 | /** |
||
24 | * container |
||
25 | * |
||
26 | * @var \Symfony\Component\DependencyInjection\ContainerInterface |
||
27 | */ |
||
28 | private $container; |
||
29 | |||
30 | /** |
||
31 | * root dir |
||
32 | * |
||
33 | * @var string |
||
34 | */ |
||
35 | private $rootDir; |
||
36 | |||
37 | /** |
||
38 | * filesystem |
||
39 | * |
||
40 | * @var \Symfony\Component\Filesystem\Filesystem |
||
41 | */ |
||
42 | private $filesystem; |
||
43 | |||
44 | /** |
||
45 | * apidoc service |
||
46 | * |
||
47 | * @var \Graviton\SwaggerBundle\Service\Swagger |
||
48 | */ |
||
49 | private $apidoc; |
||
50 | |||
51 | /** |
||
52 | * {@inheritDoc} |
||
53 | * |
||
54 | * @return void |
||
55 | */ |
||
56 | 4 | protected function configure() |
|
57 | { |
||
58 | 4 | parent::configure(); |
|
59 | |||
60 | 4 | $this->setName('graviton:swagger:generate') |
|
61 | 4 | ->setDescription( |
|
62 | 4 | 'Generates swagger.json in web dir' |
|
63 | ); |
||
64 | 4 | } |
|
65 | |||
66 | /** |
||
67 | * set container |
||
68 | * |
||
69 | * @param \Symfony\Component\DependencyInjection\ContainerInterface $container service_container |
||
70 | * |
||
71 | * @return void |
||
72 | */ |
||
73 | 4 | public function setContainer($container) |
|
77 | |||
78 | /** |
||
79 | * sets the root dir |
||
80 | * |
||
81 | * @param string $rootDir root dir |
||
82 | * |
||
83 | * @return void |
||
84 | */ |
||
85 | 4 | public function setRootDir($rootDir) |
|
89 | |||
90 | /** |
||
91 | * set filesystem |
||
92 | * |
||
93 | * @param mixed $filesystem filesystem |
||
94 | * |
||
95 | * @return void |
||
96 | */ |
||
97 | 4 | public function setFilesystem($filesystem) |
|
101 | |||
102 | /** |
||
103 | * sets apidoc |
||
104 | * |
||
105 | * @param mixed $apidoc apidoc |
||
106 | * |
||
107 | * @return void |
||
108 | */ |
||
109 | 4 | public function setApidoc($apidoc) |
|
113 | |||
114 | /** |
||
115 | * {@inheritDoc} |
||
116 | * |
||
117 | * @param InputInterface $input input |
||
118 | * @param OutputInterface $output output |
||
119 | * |
||
120 | * @return void |
||
121 | */ |
||
122 | protected function execute(InputInterface $input, OutputInterface $output) |
||
129 | } |
||
130 |