@@ -49,6 +49,9 @@ |
||
49 | 49 | return new static($name); |
50 | 50 | } |
51 | 51 | |
52 | + /** |
|
53 | + * @param string $name |
|
54 | + */ |
|
52 | 55 | public function __construct($name) { |
53 | 56 | parent::__construct($name); |
54 | 57 | $this->initParameters(); |
@@ -17,6 +17,9 @@ |
||
17 | 17 | private $visitors; |
18 | 18 | private $filename; |
19 | 19 | |
20 | + /** |
|
21 | + * @param string $filename |
|
22 | + */ |
|
20 | 23 | public function __construct($filename) { |
21 | 24 | $this->filename = $filename; |
22 | 25 | $this->visitors = new Set(); |
@@ -74,7 +74,7 @@ discard block |
||
74 | 74 | * Returns whether this node is a boolean value |
75 | 75 | * |
76 | 76 | * @param Node $node |
77 | - * @return bool |
|
77 | + * @return boolean|null |
|
78 | 78 | */ |
79 | 79 | private function isBool(Node $node) { |
80 | 80 | if ($node instanceof ConstFetch) { |
@@ -91,7 +91,7 @@ discard block |
||
91 | 91 | * Returns whether this node is a null value |
92 | 92 | * |
93 | 93 | * @param Node $node |
94 | - * @return bool |
|
94 | + * @return boolean|null |
|
95 | 95 | */ |
96 | 96 | private function isNull(Node $node) { |
97 | 97 | if ($node instanceof ConstFetch) { |
@@ -104,7 +104,7 @@ discard block |
||
104 | 104 | * Returns the value from a node |
105 | 105 | * |
106 | 106 | * @param Node $node |
107 | - * @return mixed |
|
107 | + * @return string |
|
108 | 108 | */ |
109 | 109 | private function getExpression(Node $node) { |
110 | 110 | if ($node instanceof ConstFetch) { |
@@ -28,7 +28,7 @@ |
||
28 | 28 | |
29 | 29 | /** |
30 | 30 | * |
31 | - * @param AbstractModel|TypePart $model |
|
31 | + * @param AbstractModel $model |
|
32 | 32 | * @param bool $allowed |
33 | 33 | * |
34 | 34 | * @return string|null |
@@ -79,7 +79,6 @@ |
||
79 | 79 | /** |
80 | 80 | * Sets the parent class name |
81 | 81 | * |
82 | - * @param PhpClass|string|null $name the new parent |
|
83 | 82 | * @return $this |
84 | 83 | */ |
85 | 84 | public function setParentClassName($parent) { |
@@ -35,7 +35,7 @@ discard block |
||
35 | 35 | * A quick way to add a parameter which is created from the given parameters |
36 | 36 | * |
37 | 37 | * @param string $name |
38 | - * @param string[]|PhpTypeInterface[] $types |
|
38 | + * @param string[]|PhpTypeInterface[] $type |
|
39 | 39 | * @param mixed $defaultValue omit the argument to define no default value |
40 | 40 | * |
41 | 41 | * @return $this |
@@ -46,7 +46,7 @@ discard block |
||
46 | 46 | * A quick way to add a parameter with description which is created from the given parameters |
47 | 47 | * |
48 | 48 | * @param string $name |
49 | - * @param string[]|PhpTypeInterface[] $types |
|
49 | + * @param string[]|PhpTypeInterface[] $type |
|
50 | 50 | * @param null|string $typeDescription |
51 | 51 | * @param mixed $defaultValue omit the argument to define no default value |
52 | 52 | * |
@@ -84,7 +84,7 @@ discard block |
||
84 | 84 | /** |
85 | 85 | * Returns a collection of parameters |
86 | 86 | * |
87 | - * @return array |
|
87 | + * @return PhpParameter[] |
|
88 | 88 | */ |
89 | 89 | public function getParameters(); |
90 | 90 |
@@ -34,7 +34,6 @@ discard block |
||
34 | 34 | * Sets the type |
35 | 35 | * |
36 | 36 | * @param null|Map|string[]|PhpTypeInterface[] $types |
37 | - * @param string $description |
|
38 | 37 | * |
39 | 38 | * @return $this |
40 | 39 | */ |
@@ -54,7 +53,6 @@ discard block |
||
54 | 53 | * adds a type |
55 | 54 | * |
56 | 55 | * @param string|PhpTypeInterface $type |
57 | - * @param string $description |
|
58 | 56 | * @return $this |
59 | 57 | */ |
60 | 58 | public function addType($type) { |
@@ -4,12 +4,24 @@ |
||
4 | 4 | |
5 | 5 | interface PhpTypeInterface extends NamespaceInterface |
6 | 6 | { |
7 | + /** |
|
8 | + * @return string |
|
9 | + */ |
|
7 | 10 | public function getName(): ?string; |
8 | 11 | |
12 | + /** |
|
13 | + * @return string |
|
14 | + */ |
|
9 | 15 | public function getQualifiedName(): ?string; |
10 | 16 | |
17 | + /** |
|
18 | + * @return parts\NamePart |
|
19 | + */ |
|
11 | 20 | public function setName(?string $name); |
12 | 21 | |
22 | + /** |
|
23 | + * @return parts\QualifiedNamePart |
|
24 | + */ |
|
13 | 25 | public function setQualifiedName(?string $qualifiedName); |
14 | 26 | |
15 | 27 | public function __toString(): string; |