@@ -947,7 +947,7 @@ discard block |
||
947 | 947 | * method. |
948 | 948 | * |
949 | 949 | * @param integer $modifiers |
950 | - * @return \PDepend\Source\AST\ASTMethod|\PDepend\Source\AST\ASTFieldDeclaration |
|
950 | + * @return ASTNode |
|
951 | 951 | * @since 0.9.6 |
952 | 952 | */ |
953 | 953 | protected function parseMethodOrFieldDeclaration($modifiers = 0) |
@@ -2684,7 +2684,7 @@ discard block |
||
2684 | 2684 | * This method optionally parses an expression node and returns it. When no |
2685 | 2685 | * expression was found this method will return <b>null</b>. |
2686 | 2686 | * |
2687 | - * @return \PDepend\Source\AST\ASTNode|null |
|
2687 | + * @return null|ASTExpression |
|
2688 | 2688 | * @throws \PDepend\Source\Parser\ParserException |
2689 | 2689 | * @since 0.9.6 |
2690 | 2690 | */ |
@@ -3509,7 +3509,7 @@ discard block |
||
3509 | 3509 | * ------------------------ |
3510 | 3510 | * </code> |
3511 | 3511 | * |
3512 | - * @return \PDepend\Source\AST\ASTForInit|null |
|
3512 | + * @return null|ASTNode |
|
3513 | 3513 | * @since 0.9.8 |
3514 | 3514 | */ |
3515 | 3515 | private function parseForInit() |
@@ -3548,7 +3548,7 @@ discard block |
||
3548 | 3548 | * ------------------------------- |
3549 | 3549 | * </code> |
3550 | 3550 | * |
3551 | - * @return \PDepend\Source\AST\ASTForUpdate|null |
|
3551 | + * @return null|ASTNode |
|
3552 | 3552 | * @since 0.9.12 |
3553 | 3553 | */ |
3554 | 3554 | private function parseForUpdate() |
@@ -4301,7 +4301,7 @@ discard block |
||
4301 | 4301 | /** |
4302 | 4302 | * Parses a full qualified class name postfix. |
4303 | 4303 | * |
4304 | - * @return \PDepend\Source\AST\ASTClassFqnPostfix |
|
4304 | + * @return ASTNode |
|
4305 | 4305 | * @since 2.0.0 |
4306 | 4306 | */ |
4307 | 4307 | protected function parseFullQualifiedClassNamePostfix() |
@@ -5725,7 +5725,7 @@ discard block |
||
5725 | 5725 | /** |
5726 | 5726 | * Parses a type hint that is valid in the supported PHP version. |
5727 | 5727 | * |
5728 | - * @return \PDepend\Source\AST\ASTNode|null |
|
5728 | + * @return \PDepend\Source\AST\ASTClassOrInterfaceReference|null |
|
5729 | 5729 | * @since 1.0.0 |
5730 | 5730 | */ |
5731 | 5731 | protected function parseTypeHint() |
@@ -5793,7 +5793,7 @@ discard block |
||
5793 | 5793 | /** |
5794 | 5794 | * Parses an optional statement or returns <b>null</b>. |
5795 | 5795 | * |
5796 | - * @return \PDepend\Source\AST\ASTNode|null |
|
5796 | + * @return ASTNode |
|
5797 | 5797 | * @since 0.9.8 |
5798 | 5798 | */ |
5799 | 5799 | private function parseOptionalStatement() |
@@ -6744,7 +6744,7 @@ discard block |
||
6744 | 6744 | /** |
6745 | 6745 | * Parses fn operator of lambda function for syntax fn() => available since PHP 7.4. |
6746 | 6746 | * |
6747 | - * @return \PDepend\Source\AST\ASTValue |
|
6747 | + * @return ASTNode |
|
6748 | 6748 | * @throws \PDepend\Source\Parser\UnexpectedTokenException |
6749 | 6749 | */ |
6750 | 6750 | protected function parseLambdaFunctionDeclaration() |
@@ -6946,7 +6946,7 @@ discard block |
||
6946 | 6946 | * doc comment information. The returned value will be <b>null</b> when no |
6947 | 6947 | * type information exists. |
6948 | 6948 | * |
6949 | - * @return \PDepend\Source\AST\ASTType|null |
|
6949 | + * @return ASTNode |
|
6950 | 6950 | * @since 0.9.6 |
6951 | 6951 | */ |
6952 | 6952 | private function parseFieldDeclarationType() |
@@ -209,7 +209,7 @@ discard block |
||
209 | 209 | /** |
210 | 210 | * Create a TextUi Runner |
211 | 211 | * |
212 | - * @return Runner |
|
212 | + * @return TextUI\Runner |
|
213 | 213 | */ |
214 | 214 | protected function createTextUiRunner() |
215 | 215 | { |
@@ -572,6 +572,9 @@ discard block |
||
572 | 572 | return new Engine($configuration, $cacheFactory, $analyzerFactory); |
573 | 573 | } |
574 | 574 | |
575 | + /** |
|
576 | + * @param TextUI\Runner $runner |
|
577 | + */ |
|
575 | 578 | protected function silentRun($runner) |
576 | 579 | { |
577 | 580 | ob_start(); |
@@ -821,7 +824,7 @@ discard block |
||
821 | 824 | * Parses the test code associated with the calling test method. |
822 | 825 | * |
823 | 826 | * @param boolean $ignoreAnnotations The parser should ignore annotations. |
824 | - * @return \PDepend\Source\AST\ASTNamespace[] |
|
827 | + * @return Source\AST\ASTArtifactList |
|
825 | 828 | */ |
826 | 829 | protected function parseCodeResourceForTest($ignoreAnnotations = false) |
827 | 830 | { |
@@ -837,7 +840,7 @@ discard block |
||
837 | 840 | * |
838 | 841 | * @param string $testCase |
839 | 842 | * @param boolean $ignoreAnnotations |
840 | - * @return \PDepend\Source\AST\ASTNamespace[] |
|
843 | + * @return Source\AST\ASTArtifactList |
|
841 | 844 | */ |
842 | 845 | public function parseTestCaseSource($testCase, $ignoreAnnotations = false) |
843 | 846 | { |
@@ -861,7 +864,7 @@ discard block |
||
861 | 864 | * |
862 | 865 | * @param string $fileOrDirectory |
863 | 866 | * @param boolean $ignoreAnnotations |
864 | - * @return \PDepend\Source\AST\ASTNamespace[] |
|
867 | + * @return Source\AST\ASTArtifactList |
|
865 | 868 | */ |
866 | 869 | public function parseSource($fileOrDirectory, $ignoreAnnotations = false) |
867 | 870 | { |
@@ -922,6 +925,9 @@ discard block |
||
922 | 925 | ); |
923 | 926 | } |
924 | 927 | |
928 | + /** |
|
929 | + * @param string $className |
|
930 | + */ |
|
925 | 931 | public function getMockBuilder($className) |
926 | 932 | { |
927 | 933 | include_once __DIR__ . '/MockBuilder.php'; |
@@ -929,6 +935,9 @@ discard block |
||
929 | 935 | return new MockBuilder($this, $className); |
930 | 936 | } |
931 | 937 | |
938 | + /** |
|
939 | + * @param string $originalClassName |
|
940 | + */ |
|
932 | 941 | protected function getAbstractClassMock($originalClassName, array $arguments = array(), $mockClassName = '', $callOriginalConstructor = true, $callOriginalClone = true, $callAutoload = true, $mockedMethods = array(), $cloneArguments = false) |
933 | 942 | { |
934 | 943 | if (version_compare(phpversion(), '7.4.0-dev', '<')) { |
@@ -328,7 +328,7 @@ discard block |
||
328 | 328 | * Analyzes the registered directories and returns the collection of |
329 | 329 | * analyzed namespace. |
330 | 330 | * |
331 | - * @return \PDepend\Source\AST\ASTNamespace[] |
|
331 | + * @return Source\AST\ASTArtifactList |
|
332 | 332 | */ |
333 | 333 | public function analyze() |
334 | 334 | { |
@@ -721,6 +721,9 @@ discard block |
||
721 | 721 | return $analyzers; |
722 | 722 | } |
723 | 723 | |
724 | + /** |
|
725 | + * @param string $path |
|
726 | + */ |
|
724 | 727 | private function isPhpStream($path) |
725 | 728 | { |
726 | 729 | return substr($path, 0, strlen($this->phpStreamPrefix)) === $this->phpStreamPrefix; |
@@ -273,7 +273,7 @@ discard block |
||
273 | 273 | /** |
274 | 274 | * Returns all {@link \PDepend\Source\AST\ASTMethod} objects in this type. |
275 | 275 | * |
276 | - * @return ASTMethod[] |
|
276 | + * @return ASTArtifactList |
|
277 | 277 | */ |
278 | 278 | public function getMethods() |
279 | 279 | { |
@@ -479,7 +479,7 @@ discard block |
||
479 | 479 | * names of all those properties that should be cached for this class or |
480 | 480 | * interface instance. |
481 | 481 | * |
482 | - * @return array |
|
482 | + * @return string[] |
|
483 | 483 | */ |
484 | 484 | public function __sleep() |
485 | 485 | { |
@@ -221,6 +221,12 @@ |
||
221 | 221 | } |
222 | 222 | } |
223 | 223 | |
224 | + /** |
|
225 | + * @param integer $tokenType |
|
226 | + * @param integer $modifiers |
|
227 | + * |
|
228 | + * @return integer |
|
229 | + */ |
|
224 | 230 | private function getModifiersForConstantDefinition($tokenType, $modifiers) |
225 | 231 | { |
226 | 232 | $allowed = State::IS_PUBLIC | State::IS_PROTECTED | State::IS_PRIVATE; |