@@ -31,7 +31,7 @@ discard block |
||
31 | 31 | } |
32 | 32 | |
33 | 33 | /** |
34 | - * @param $study |
|
34 | + * @param Study $study |
|
35 | 35 | * @param mixed $control |
36 | 36 | * @param Experiment[] $experiments |
37 | 37 | * @param string[] $interfaces |
@@ -111,6 +111,9 @@ discard block |
||
111 | 111 | return $experiment; |
112 | 112 | } |
113 | 113 | |
114 | + /** |
|
115 | + * @param string $name |
|
116 | + */ |
|
114 | 117 | private function createPropertyExperiment($name, Study $study, $control, array $trials) |
115 | 118 | { |
116 | 119 | $experiment_name = sprintf('%s::$%s', $study->getName(), $name); |
@@ -137,7 +140,7 @@ discard block |
||
137 | 140 | /** |
138 | 141 | * @param mixed $instance |
139 | 142 | * @param string $name |
140 | - * @return callable |
|
143 | + * @return \Closure |
|
141 | 144 | */ |
142 | 145 | private function createPropertyCallable($instance, $name) |
143 | 146 | { |
@@ -161,6 +164,9 @@ discard block |
||
161 | 164 | }; |
162 | 165 | } |
163 | 166 | |
167 | + /** |
|
168 | + * @param string $name |
|
169 | + */ |
|
164 | 170 | private function createMissingMethodCallable($instance, $name) |
165 | 171 | { |
166 | 172 | return function() use ($instance, $name) { |
@@ -44,13 +44,13 @@ discard block |
||
44 | 44 | |
45 | 45 | foreach ($interfaces as &$interface) { |
46 | 46 | if (strpos($interface, '\\') !== 0) { |
47 | - $interface = '\\'.$interface; |
|
47 | + $interface = '\\' . $interface; |
|
48 | 48 | } |
49 | 49 | } |
50 | 50 | |
51 | 51 | $generator = new ClassGenerator($blind_name, 'Scientist\Blind'); |
52 | 52 | $generator->setImplementedInterfaces($interfaces); |
53 | - $generator->addTrait('\\'.DecoratorTrait::class); |
|
53 | + $generator->addTrait('\\' . DecoratorTrait::class); |
|
54 | 54 | |
55 | 55 | $this->addInterfaceMethods($generator, $interfaces); |
56 | 56 | |
@@ -140,7 +140,7 @@ discard block |
||
140 | 140 | */ |
141 | 141 | private function createPropertyCallable($instance, $name) |
142 | 142 | { |
143 | - return function () use ($instance, $name) { |
|
143 | + return function() use ($instance, $name) { |
|
144 | 144 | $args = func_get_args(); |
145 | 145 | // __set |
146 | 146 | if (count($args) > 1) { |
@@ -155,14 +155,14 @@ discard block |
||
155 | 155 | |
156 | 156 | private function createMissingPropertyCallable($instance, $name) |
157 | 157 | { |
158 | - return function () use ($instance, $name) { |
|
158 | + return function() use ($instance, $name) { |
|
159 | 159 | throw new MissingProperty($instance, $name); |
160 | 160 | }; |
161 | 161 | } |
162 | 162 | |
163 | 163 | private function createMissingMethodCallable($instance, $name) |
164 | 164 | { |
165 | - return function () use ($instance, $name) { |
|
165 | + return function() use ($instance, $name) { |
|
166 | 166 | throw new MissingMethod($instance, $name); |
167 | 167 | }; |
168 | 168 | } |
@@ -205,7 +205,7 @@ |
||
205 | 205 | |
206 | 206 | /** |
207 | 207 | * @param string ...$interface blind will implement the interfaces specified |
208 | - * @return mixed |
|
208 | + * @return Blind |
|
209 | 209 | */ |
210 | 210 | public function blind($interface = null) |
211 | 211 | { |