1 | <?php |
||
16 | class MakeTransformer extends GeneratorCommand |
||
17 | { |
||
18 | /** |
||
19 | * The console command name. |
||
20 | * |
||
21 | * @var string |
||
22 | */ |
||
23 | protected $name = 'make:transformer'; |
||
24 | |||
25 | /** |
||
26 | * The console command description. |
||
27 | * |
||
28 | * @var string |
||
29 | */ |
||
30 | protected $description = 'Create a new transformer class'; |
||
31 | |||
32 | /** |
||
33 | * The type of class being generated. |
||
34 | * |
||
35 | * @var string |
||
36 | */ |
||
37 | protected $type = 'Transformer'; |
||
38 | |||
39 | /** |
||
40 | * Get the stub file for the generator. |
||
41 | * |
||
42 | * @return string |
||
43 | */ |
||
44 | protected function getStub() |
||
52 | |||
53 | /** |
||
54 | * Get the default namespace for the class. |
||
55 | * |
||
56 | * @param string $rootNamespace |
||
57 | * @return string |
||
58 | */ |
||
59 | protected function getDefaultNamespace($rootNamespace) |
||
63 | |||
64 | /** |
||
65 | * Build the class with the given name. |
||
66 | * |
||
67 | * @param string $name |
||
68 | * @return string |
||
69 | */ |
||
70 | protected function buildClass($name) |
||
84 | |||
85 | /** |
||
86 | * Resolve a model from the given class name. |
||
87 | * |
||
88 | * @return string |
||
89 | */ |
||
90 | protected function resolveModelFromClassName() |
||
94 | |||
95 | /** |
||
96 | * Build the model replacement values. |
||
97 | * |
||
98 | * @param array $replace |
||
99 | * @return array |
||
100 | */ |
||
101 | protected function buildModelReplacements(array $replace) |
||
115 | |||
116 | /** |
||
117 | * Get the fully-qualified model class name. |
||
118 | * |
||
119 | * @param string $model |
||
120 | * @return string |
||
121 | */ |
||
122 | protected function parseModel($model) |
||
136 | |||
137 | /** |
||
138 | * Get the console command options. |
||
139 | * |
||
140 | * @return array |
||
141 | */ |
||
142 | protected function getOptions() |
||
149 | } |
This check looks at variables that are passed out again to other methods.
If the outgoing method call has stricter type requirements than the method itself, an issue is raised.
An additional type check may prevent trouble.