@@ -102,7 +102,7 @@ |
||
102 | 102 | $originalLoader = $loader[0]; |
103 | 103 | |
104 | 104 | // Configure library loader for doctrine annotation loader |
105 | - AnnotationRegistry::registerLoader(function ($class) use ($originalLoader) { |
|
105 | + AnnotationRegistry::registerLoader(function($class) use ($originalLoader) { |
|
106 | 106 | $originalLoader->loadClass($class); |
107 | 107 | |
108 | 108 | return class_exists($class, false); |
@@ -1,12 +1,12 @@ |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * Go! AOP framework |
|
4 | - * |
|
5 | - * @copyright Copyright 2013, 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 2013, 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 |
@@ -39,7 +39,7 @@ |
||
39 | 39 | */ |
40 | 40 | public static function leaveProcessing() |
41 | 41 | { |
42 | - self::$level = self::$level > 0 ? self::$level-1 : 0; |
|
42 | + self::$level = self::$level > 0 ? self::$level - 1 : 0; |
|
43 | 43 | } |
44 | 44 | |
45 | 45 | /** |
@@ -1,12 +1,12 @@ |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * Go! AOP framework |
|
4 | - * |
|
5 | - * @copyright Copyright 2013, 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 2013, 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 |
@@ -52,7 +52,7 @@ |
||
52 | 52 | } |
53 | 53 | |
54 | 54 | // resolve path parts (single dot, double dot and double delimiters) |
55 | - $path = str_replace(array('/', '\\'), DIRECTORY_SEPARATOR, $path); |
|
55 | + $path = str_replace(array('/', '\\'), DIRECTORY_SEPARATOR, $path); |
|
56 | 56 | if (strpos($path, '.') !== false) { |
57 | 57 | $parts = explode(DIRECTORY_SEPARATOR, $path); |
58 | 58 | $absolutes = array(); |
@@ -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 |
@@ -1,12 +1,12 @@ discard block |
||
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; |
12 | 12 | |
@@ -82,13 +82,13 @@ discard block |
||
82 | 82 | return $this->parser->parse($class->getDocComment(), 'class '.$class->getName()); |
83 | 83 | } |
84 | 84 | |
85 | - /** |
|
86 | - * Gets the annotations applied to a method. |
|
87 | - * |
|
88 | - * @param ParsedReflectionMethod $method The ReflectionMethod of the method from which |
|
89 | - * the annotations should be read. |
|
90 | - * @return array An array of Annotations. |
|
91 | - */ |
|
85 | + /** |
|
86 | + * Gets the annotations applied to a method. |
|
87 | + * |
|
88 | + * @param ParsedReflectionMethod $method The ReflectionMethod of the method from which |
|
89 | + * the annotations should be read. |
|
90 | + * @return array An array of Annotations. |
|
91 | + */ |
|
92 | 92 | public function getMethodAnnotations(ParsedReflectionMethod $method) |
93 | 93 | { |
94 | 94 | $this->parser->setTarget(Target::TARGET_METHOD); |
@@ -79,7 +79,7 @@ discard block |
||
79 | 79 | { |
80 | 80 | $this->parser->setTarget(Target::TARGET_CLASS); |
81 | 81 | |
82 | - return $this->parser->parse($class->getDocComment(), 'class '.$class->getName()); |
|
82 | + return $this->parser->parse($class->getDocComment(), 'class ' . $class->getName()); |
|
83 | 83 | } |
84 | 84 | |
85 | 85 | /** |
@@ -93,7 +93,7 @@ discard block |
||
93 | 93 | { |
94 | 94 | $this->parser->setTarget(Target::TARGET_METHOD); |
95 | 95 | |
96 | - return $this->parser->parse($method->getDocComment(), 'method '.$method->getDeclaringClass()->name.'::'.$method->getName().'()'); |
|
96 | + return $this->parser->parse($method->getDocComment(), 'method ' . $method->getDeclaringClass()->name . '::' . $method->getName() . '()'); |
|
97 | 97 | } |
98 | 98 | |
99 | 99 | /** |
@@ -107,7 +107,7 @@ discard block |
||
107 | 107 | { |
108 | 108 | $this->parser->setTarget(Target::TARGET_PROPERTY); |
109 | 109 | |
110 | - return $this->parser->parse($property->getDocComment(), 'property '.$property->getDeclaringClass()->name.'::$'.$property->getName()); |
|
110 | + return $this->parser->parse($property->getDocComment(), 'property ' . $property->getDeclaringClass()->name . '::$' . $property->getName()); |
|
111 | 111 | } |
112 | 112 | |
113 | 113 | /** |
@@ -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 |
@@ -77,7 +77,7 @@ discard block |
||
77 | 77 | */ |
78 | 78 | public function transform(StreamMetaData $metadata = null) |
79 | 79 | { |
80 | - if (strpos($metadata->source, 'new ')===false) { |
|
80 | + if (strpos($metadata->source, 'new ') === false) { |
|
81 | 81 | return; |
82 | 82 | } |
83 | 83 | |
@@ -95,7 +95,7 @@ discard block |
||
95 | 95 | $isWaitingEnd = true; |
96 | 96 | $isWaitingClass = false; |
97 | 97 | } |
98 | - if (in_array($tokenStream[$index+1], array('(', ';', ')', '.'))) { |
|
98 | + if (in_array($tokenStream[$index + 1], array('(', ';', ')', '.'))) { |
|
99 | 99 | $isWaitingEnd = true; |
100 | 100 | $isWaitingClass = false; |
101 | 101 | } |
@@ -122,7 +122,7 @@ discard block |
||
122 | 122 | */ |
123 | 123 | public function transform(StreamMetaData $metadata) |
124 | 124 | { |
125 | - if ((strpos($metadata->source, 'include')===false) && (strpos($metadata->source, 'require')===false)) { |
|
125 | + if ((strpos($metadata->source, 'include') === false) && (strpos($metadata->source, 'require') === false)) { |
|
126 | 126 | return; |
127 | 127 | } |
128 | 128 | static $lookFor = array( |
@@ -173,7 +173,7 @@ discard block |
||
173 | 173 | if (!$isWaitingEnd && isset($lookFor[$token])) { |
174 | 174 | $isWaitingEnd = true; |
175 | 175 | $isBracesFinished = $isTernaryOperator = false; |
176 | - $transformedSource .= ' \\' . __CLASS__ . '::rewrite('; |
|
176 | + $transformedSource .= ' \\' . __CLASS__ . '::rewrite('; |
|
177 | 177 | } |
178 | 178 | } |
179 | 179 | $metadata->source = $transformedSource; |
@@ -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 @@ |
||
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 |
@@ -471,11 +471,11 @@ |
||
471 | 471 | ($prefix ? "$prefix " : '') . // List of class modifiers |
472 | 472 | 'class ' . // 'class' keyword with one space |
473 | 473 | $this->name . // Name of the class |
474 | - ' extends '. // 'extends' keyword with |
|
474 | + ' extends ' . // 'extends' keyword with |
|
475 | 475 | $this->parentClassName . // Name of the parent class |
476 | 476 | ($this->interfaces ? ' implements ' . join(', ', $this->interfaces) : '') . "\n" . // Interfaces list |
477 | 477 | "{\n" . // Start of class definition |
478 | - ($this->traits ? $this->indent('use ' . join(', ', $this->traits) .';'."\n") : '') . "\n" . // Traits list |
|
478 | + ($this->traits ? $this->indent('use ' . join(', ', $this->traits) . ';' . "\n") : '') . "\n" . // Traits list |
|
479 | 479 | $this->indent(join("\n", $this->propertiesCode)) . "\n" . // Property definitions |
480 | 480 | $this->indent(join("\n", $this->methodsCode)) . "\n" . // Method definitions |
481 | 481 | "}" // End of class definition |
@@ -1,12 +1,12 @@ |
||
1 | 1 | <?php |
2 | 2 | /** |
3 | - * Go! AOP framework |
|
4 | - * |
|
5 | - * @copyright Copyright 2013, 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 2013, 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 |
@@ -84,7 +84,7 @@ discard block |
||
84 | 84 | static $accessor = null; |
85 | 85 | |
86 | 86 | if (!$accessor) { |
87 | - $accessor = AspectKernel::getInstance()->getContainer()->get('aspect.advisor.accessor'); |
|
87 | + $accessor = AspectKernel::getInstance()->getContainer()->get('aspect.advisor.accessor'); |
|
88 | 88 | } |
89 | 89 | |
90 | 90 | $advices = self::$functionAdvices[$namespace][AspectContainer::FUNCTION_PREFIX][$joinPointName]; |
@@ -167,7 +167,7 @@ discard block |
||
167 | 167 | } |
168 | 168 | |
169 | 169 | $code = ( |
170 | - preg_replace('/ {4}|\t/', '', $function->getDocComment()) ."\n" . // Original doc-comment |
|
170 | + preg_replace('/ {4}|\t/', '', $function->getDocComment()) . "\n" . // Original doc-comment |
|
171 | 171 | 'function ' . // 'function' keyword |
172 | 172 | ($function->returnsReference() ? '&' : '') . // By reference symbol |
173 | 173 | $functionName . // Function name |
@@ -193,13 +193,13 @@ discard block |
||
193 | 193 | */ |
194 | 194 | protected function getJoinpointInvocationBody(ReflectionFunction $function) |
195 | 195 | { |
196 | - $class = '\\' . __CLASS__; |
|
196 | + $class = '\\' . __CLASS__; |
|
197 | 197 | |
198 | 198 | $dynamicArgs = false; |
199 | 199 | $hasOptionals = false; |
200 | 200 | $hasReferences = false; |
201 | 201 | |
202 | - $argValues = array_map(function (ReflectionParameter $param) use (&$dynamicArgs, &$hasOptionals, &$hasReferences) { |
|
202 | + $argValues = array_map(function(ReflectionParameter $param) use (&$dynamicArgs, &$hasOptionals, &$hasReferences) { |
|
203 | 203 | $byReference = $param->isPassedByReference(); |
204 | 204 | $dynamicArg = $param->name == '...'; |
205 | 205 | $dynamicArgs = $dynamicArgs || $dynamicArg; |
@@ -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 |