@@ -124,7 +124,7 @@ |
||
124 | 124 | /** |
125 | 125 | * Transforms source code by passing it through all transformers |
126 | 126 | * |
127 | - * @param StreamMetaData|null $metadata Metadata from stream |
|
127 | + * @param StreamMetaData $metadata Metadata from stream |
|
128 | 128 | * @return void|bool Return false if transformation should be stopped |
129 | 129 | */ |
130 | 130 | public static function transformCode(StreamMetaData $metadata) |
@@ -1,12 +1,12 @@ |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * Go! AOP framework |
|
4 | - * |
|
5 | - * @copyright Copyright 2011, Lisachenko Alexander <[email protected]> |
|
6 | - * |
|
7 | - * This source file is subject to the license that is bundled |
|
8 | - * with this source code in the file LICENSE. |
|
9 | - */ |
|
3 | + * Go! AOP framework |
|
4 | + * |
|
5 | + * @copyright Copyright 2011, Lisachenko Alexander <[email protected]> |
|
6 | + * |
|
7 | + * This source file is subject to the license that is bundled |
|
8 | + * with this source code in the file LICENSE. |
|
9 | + */ |
|
10 | 10 | |
11 | 11 | namespace Go\Instrument\Transformer; |
12 | 12 |
@@ -53,7 +53,7 @@ discard block |
||
53 | 53 | /** |
54 | 54 | * Returns an enumerator for files |
55 | 55 | * |
56 | - * @return \CallbackFilterIterator|\RecursiveIteratorIterator|\SplFileInfo[] |
|
56 | + * @return \CallbackFilterIterator |
|
57 | 57 | */ |
58 | 58 | public function enumerate() |
59 | 59 | { |
@@ -73,7 +73,7 @@ discard block |
||
73 | 73 | /** |
74 | 74 | * Returns a filter callback for enumerating files |
75 | 75 | * |
76 | - * @return callable |
|
76 | + * @return \Closure |
|
77 | 77 | */ |
78 | 78 | public function getFilter() |
79 | 79 | { |
@@ -1,12 +1,12 @@ |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * Go! AOP framework |
|
4 | - * |
|
5 | - * @copyright Copyright 2015, Lisachenko Alexander <[email protected]> |
|
6 | - * |
|
7 | - * This source file is subject to the license that is bundled |
|
8 | - * with this source code in the file LICENSE. |
|
9 | - */ |
|
3 | + * Go! AOP framework |
|
4 | + * |
|
5 | + * @copyright Copyright 2015, Lisachenko Alexander <[email protected]> |
|
6 | + * |
|
7 | + * This source file is subject to the license that is bundled |
|
8 | + * with this source code in the file LICENSE. |
|
9 | + */ |
|
10 | 10 | |
11 | 11 | namespace Go\Instrument\FileSystem; |
12 | 12 |
@@ -81,7 +81,7 @@ |
||
81 | 81 | $includePaths = $this->includePaths; |
82 | 82 | $excludePaths = $this->excludePaths; |
83 | 83 | |
84 | - return function (\SplFileInfo $file) use ($rootDirectory, $includePaths, $excludePaths) { |
|
84 | + return function(\SplFileInfo $file) use ($rootDirectory, $includePaths, $excludePaths) { |
|
85 | 85 | if ($file->getExtension() !== 'php') { |
86 | 86 | return false; |
87 | 87 | }; |
@@ -55,7 +55,7 @@ |
||
55 | 55 | * This method may transform the supplied source and return a new replacement for it |
56 | 56 | * |
57 | 57 | * @param StreamMetaData $metadata Metadata for source |
58 | - * @return void|bool Return false if transformation should be stopped |
|
58 | + * @return boolean Return false if transformation should be stopped |
|
59 | 59 | */ |
60 | 60 | public function transform(StreamMetaData $metadata) |
61 | 61 | { |
@@ -1,12 +1,12 @@ |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * Go! AOP framework |
|
4 | - * |
|
5 | - * @copyright Copyright 2012, Lisachenko Alexander <[email protected]> |
|
6 | - * |
|
7 | - * This source file is subject to the license that is bundled |
|
8 | - * with this source code in the file LICENSE. |
|
9 | - */ |
|
3 | + * Go! AOP framework |
|
4 | + * |
|
5 | + * @copyright Copyright 2012, Lisachenko Alexander <[email protected]> |
|
6 | + * |
|
7 | + * This source file is subject to the license that is bundled |
|
8 | + * with this source code in the file LICENSE. |
|
9 | + */ |
|
10 | 10 | |
11 | 11 | namespace Go\Proxy; |
12 | 12 |
@@ -85,7 +85,7 @@ discard block |
||
85 | 85 | * This method may transform the supplied source and return a new replacement for it |
86 | 86 | * |
87 | 87 | * @param StreamMetaData $metadata Metadata for source |
88 | - * @return void|bool Return false if transformation should be stopped |
|
88 | + * @return boolean Return false if transformation should be stopped |
|
89 | 89 | */ |
90 | 90 | public function transform(StreamMetaData $metadata) |
91 | 91 | { |
@@ -277,7 +277,7 @@ discard block |
||
277 | 277 | * Save AOP proxy to the separate file anr returns the php source code for inclusion |
278 | 278 | * |
279 | 279 | * @param ParsedClass $class Original class reflection |
280 | - * @param string|ClassProxy $child |
|
280 | + * @param ClassProxy $child |
|
281 | 281 | * |
282 | 282 | * @return string |
283 | 283 | */ |
@@ -1,12 +1,12 @@ |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * Go! AOP framework |
|
4 | - * |
|
5 | - * @copyright Copyright 2011, Lisachenko Alexander <[email protected]> |
|
6 | - * |
|
7 | - * This source file is subject to the license that is bundled |
|
8 | - * with this source code in the file LICENSE. |
|
9 | - */ |
|
3 | + * Go! AOP framework |
|
4 | + * |
|
5 | + * @copyright Copyright 2011, Lisachenko Alexander <[email protected]> |
|
6 | + * |
|
7 | + * This source file is subject to the license that is bundled |
|
8 | + * with this source code in the file LICENSE. |
|
9 | + */ |
|
10 | 10 | |
11 | 11 | namespace Go\Instrument\Transformer; |
12 | 12 |
@@ -133,11 +133,11 @@ |
||
133 | 133 | if ($class->isInterface() || in_array('Go\Aop\Aspect', $class->getInterfaceNames())) { |
134 | 134 | continue; |
135 | 135 | } |
136 | - $wasClassProcessed = $this->processSingleClass($advisors, $metadata, $class, $lineOffset); |
|
136 | + $wasClassProcessed = $this->processSingleClass($advisors, $metadata, $class, $lineOffset); |
|
137 | 137 | $totalTransformations += (integer) $wasClassProcessed; |
138 | 138 | } |
139 | 139 | $wasFunctionsProcessed = $this->processFunctions($advisors, $metadata, $namespace); |
140 | - $totalTransformations += (integer) $wasFunctionsProcessed; |
|
140 | + $totalTransformations += (integer) $wasFunctionsProcessed; |
|
141 | 141 | } |
142 | 142 | |
143 | 143 | CleanableMemory::leaveProcessing(); |
@@ -18,7 +18,6 @@ |
||
18 | 18 | use Go\Core\AspectKernel; |
19 | 19 | use Go\Core\AspectLoader; |
20 | 20 | use Go\Instrument\ClassLoading\CachePathManager; |
21 | -use Go\Instrument\CleanableMemory; |
|
22 | 21 | use Go\ParserReflection\ReflectionFile; |
23 | 22 | use Go\ParserReflection\ReflectionFileNamespace; |
24 | 23 | use Go\Proxy\ClassProxy; |
@@ -37,6 +37,6 @@ |
||
37 | 37 | { |
38 | 38 | $result = $invocation->proceed(); |
39 | 39 | |
40 | - return $result!==null ? $result : $invocation->getThis(); |
|
40 | + return $result !== null ? $result : $invocation->getThis(); |
|
41 | 41 | } |
42 | 42 | } |
@@ -1,12 +1,12 @@ |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * Go! AOP framework |
|
4 | - * |
|
5 | - * @copyright Copyright 2014, Lisachenko Alexander <[email protected]> |
|
6 | - * |
|
7 | - * This source file is subject to the license that is bundled |
|
8 | - * with this source code in the file LICENSE. |
|
9 | - */ |
|
3 | + * Go! AOP framework |
|
4 | + * |
|
5 | + * @copyright Copyright 2014, Lisachenko Alexander <[email protected]> |
|
6 | + * |
|
7 | + * This source file is subject to the license that is bundled |
|
8 | + * with this source code in the file LICENSE. |
|
9 | + */ |
|
10 | 10 | |
11 | 11 | namespace Go\Instrument\Transformer; |
12 | 12 |
@@ -34,7 +34,7 @@ |
||
34 | 34 | public function unserialize($serialized) |
35 | 35 | { |
36 | 36 | $data = unserialize($serialized); |
37 | - foreach($data as $key=>$value) { |
|
37 | + foreach ($data as $key=>$value) { |
|
38 | 38 | $this->$key = $value; |
39 | 39 | } |
40 | 40 | } |
@@ -1,12 +1,12 @@ |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * Go! AOP framework |
|
4 | - * |
|
5 | - * @copyright Copyright 2012, Lisachenko Alexander <[email protected]> |
|
6 | - * |
|
7 | - * This source file is subject to the license that is bundled |
|
8 | - * with this source code in the file LICENSE. |
|
9 | - */ |
|
3 | + * Go! AOP framework |
|
4 | + * |
|
5 | + * @copyright Copyright 2012, Lisachenko Alexander <[email protected]> |
|
6 | + * |
|
7 | + * This source file is subject to the license that is bundled |
|
8 | + * with this source code in the file LICENSE. |
|
9 | + */ |
|
10 | 10 | |
11 | 11 | namespace Go\Proxy; |
12 | 12 |
@@ -1,12 +1,12 @@ discard block |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * Go! AOP framework |
|
4 | - * |
|
5 | - * @copyright Copyright 2014, Lisachenko Alexander <[email protected]> |
|
6 | - * |
|
7 | - * This source file is subject to the license that is bundled |
|
8 | - * with this source code in the file LICENSE. |
|
9 | - */ |
|
3 | + * Go! AOP framework |
|
4 | + * |
|
5 | + * @copyright Copyright 2014, Lisachenko Alexander <[email protected]> |
|
6 | + * |
|
7 | + * This source file is subject to the license that is bundled |
|
8 | + * with this source code in the file LICENSE. |
|
9 | + */ |
|
10 | 10 | |
11 | 11 | namespace Demo\Aspect; |
12 | 12 | |
@@ -39,9 +39,9 @@ discard block |
||
39 | 39 | public function beforeMethodExecution(MethodInvocation $invocation) |
40 | 40 | { |
41 | 41 | echo 'Calling Before Interceptor for ', |
42 | - $invocation, |
|
43 | - ' with arguments: ', |
|
44 | - json_encode($invocation->getArguments()), |
|
45 | - PHP_EOL; |
|
42 | + $invocation, |
|
43 | + ' with arguments: ', |
|
44 | + json_encode($invocation->getArguments()), |
|
45 | + PHP_EOL; |
|
46 | 46 | } |
47 | 47 | } |
@@ -31,7 +31,7 @@ |
||
31 | 31 | public function getReport($from) |
32 | 32 | { |
33 | 33 | // long calculation for 100ms |
34 | - usleep(0.1*1e6); |
|
34 | + usleep(0.1 * 1e6); |
|
35 | 35 | |
36 | 36 | return $from; |
37 | 37 | } |
@@ -1,12 +1,12 @@ |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * Go! AOP framework |
|
4 | - * |
|
5 | - * @copyright Copyright 2014, Lisachenko Alexander <[email protected]> |
|
6 | - * |
|
7 | - * This source file is subject to the license that is bundled |
|
8 | - * with this source code in the file LICENSE. |
|
9 | - */ |
|
3 | + * Go! AOP framework |
|
4 | + * |
|
5 | + * @copyright Copyright 2014, Lisachenko Alexander <[email protected]> |
|
6 | + * |
|
7 | + * This source file is subject to the license that is bundled |
|
8 | + * with this source code in the file LICENSE. |
|
9 | + */ |
|
10 | 10 | |
11 | 11 | namespace Go\Instrument\Transformer; |
12 | 12 |
@@ -12,7 +12,7 @@ |
||
12 | 12 | use Demo\Aspect\AwesomeAspectKernel; |
13 | 13 | use Go\Aop\Features; |
14 | 14 | |
15 | -include __DIR__ .'/autoload.php'; |
|
15 | +include __DIR__ . '/autoload.php'; |
|
16 | 16 | |
17 | 17 | // Initialize demo aspect container |
18 | 18 | $defaultFeatures = AwesomeAspectKernel::getDefaultFeatures(); |
@@ -1,12 +1,12 @@ |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * Go! AOP framework |
|
4 | - * |
|
5 | - * @copyright Copyright 2012, Lisachenko Alexander <[email protected]> |
|
6 | - * |
|
7 | - * This source file is subject to the license that is bundled |
|
8 | - * with this source code in the file LICENSE. |
|
9 | - */ |
|
3 | + * Go! AOP framework |
|
4 | + * |
|
5 | + * @copyright Copyright 2012, Lisachenko Alexander <[email protected]> |
|
6 | + * |
|
7 | + * This source file is subject to the license that is bundled |
|
8 | + * with this source code in the file LICENSE. |
|
9 | + */ |
|
10 | 10 | |
11 | 11 | namespace Go\Proxy; |
12 | 12 |