Skip to content

Commit 126b37d

Browse files
committed
fixed @return when returning this or static
1 parent 6de0cd1 commit 126b37d

File tree

9 files changed

+49
-49
lines changed

9 files changed

+49
-49
lines changed

Definition/Builder/ArrayNodeDefinition.php

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ public function prototype($type)
8585
* If this function has been called and the node is not set during the finalization
8686
* phase, it's default value will be derived from its children default values.
8787
*
88-
* @return ArrayNodeDefinition
88+
* @return $this
8989
*/
9090
public function addDefaultsIfNotSet()
9191
{
@@ -101,7 +101,7 @@ public function addDefaultsIfNotSet()
101101
*
102102
* This method is applicable to prototype nodes only.
103103
*
104-
* @return ArrayNodeDefinition
104+
* @return $this
105105
*/
106106
public function addDefaultChildrenIfNoneSet($children = null)
107107
{
@@ -115,7 +115,7 @@ public function addDefaultChildrenIfNoneSet($children = null)
115115
*
116116
* This method is applicable to prototype nodes only.
117117
*
118-
* @return ArrayNodeDefinition
118+
* @return $this
119119
*/
120120
public function requiresAtLeastOneElement()
121121
{
@@ -129,7 +129,7 @@ public function requiresAtLeastOneElement()
129129
*
130130
* If used all keys have to be defined in the same configuration file.
131131
*
132-
* @return ArrayNodeDefinition
132+
* @return $this
133133
*/
134134
public function disallowNewKeysInSubsequentConfigs()
135135
{
@@ -144,7 +144,7 @@ public function disallowNewKeysInSubsequentConfigs()
144144
* @param string $singular The key to remap
145145
* @param string $plural The plural of the key for irregular plurals
146146
*
147-
* @return ArrayNodeDefinition
147+
* @return $this
148148
*/
149149
public function fixXmlConfig($singular, $plural = null)
150150
{
@@ -179,7 +179,7 @@ public function fixXmlConfig($singular, $plural = null)
179179
* @param string $name The name of the key
180180
* @param bool $removeKeyItem Whether or not the key item should be removed
181181
*
182-
* @return ArrayNodeDefinition
182+
* @return $this
183183
*/
184184
public function useAttributeAsKey($name, $removeKeyItem = true)
185185
{
@@ -194,7 +194,7 @@ public function useAttributeAsKey($name, $removeKeyItem = true)
194194
*
195195
* @param bool $allow
196196
*
197-
* @return ArrayNodeDefinition
197+
* @return $this
198198
*/
199199
public function canBeUnset($allow = true)
200200
{
@@ -216,7 +216,7 @@ public function canBeUnset($allow = true)
216216
* enableableArrayNode: {enabled: false, ...} # The config is disabled
217217
* enableableArrayNode: false # The config is disabled
218218
*
219-
* @return ArrayNodeDefinition
219+
* @return $this
220220
*/
221221
public function canBeEnabled()
222222
{
@@ -246,7 +246,7 @@ public function canBeEnabled()
246246
*
247247
* By default, the section is enabled.
248248
*
249-
* @return ArrayNodeDefinition
249+
* @return $this
250250
*/
251251
public function canBeDisabled()
252252
{
@@ -266,7 +266,7 @@ public function canBeDisabled()
266266
/**
267267
* Disables the deep merging of the node.
268268
*
269-
* @return ArrayNodeDefinition
269+
* @return $this
270270
*/
271271
public function performNoDeepMerging()
272272
{
@@ -284,7 +284,7 @@ public function performNoDeepMerging()
284284
* you want to send an entire configuration array through a special
285285
* tree that processes only part of the array.
286286
*
287-
* @return ArrayNodeDefinition
287+
* @return $this
288288
*/
289289
public function ignoreExtraKeys()
290290
{
@@ -298,7 +298,7 @@ public function ignoreExtraKeys()
298298
*
299299
* @param bool $bool Whether to enable key normalization
300300
*
301-
* @return ArrayNodeDefinition
301+
* @return $this
302302
*/
303303
public function normalizeKeys($bool)
304304
{
@@ -320,7 +320,7 @@ public function normalizeKeys($bool)
320320
*
321321
* @param NodeDefinition $node A NodeDefinition instance
322322
*
323-
* @return ArrayNodeDefinition This node
323+
* @return $this
324324
*/
325325
public function append(NodeDefinition $node)
326326
{

Definition/Builder/EnumNodeDefinition.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ class EnumNodeDefinition extends ScalarNodeDefinition
2525
/**
2626
* @param array $values
2727
*
28-
* @return EnumNodeDefinition|$this
28+
* @return $this
2929
*/
3030
public function values(array $values)
3131
{

Definition/Builder/ExprBuilder.php

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ public function __construct(NodeDefinition $node)
4040
*
4141
* @param \Closure $then
4242
*
43-
* @return ExprBuilder
43+
* @return $this
4444
*/
4545
public function always(\Closure $then = null)
4646
{
@@ -60,7 +60,7 @@ public function always(\Closure $then = null)
6060
*
6161
* @param \Closure $closure
6262
*
63-
* @return ExprBuilder
63+
* @return $this
6464
*/
6565
public function ifTrue(\Closure $closure = null)
6666
{
@@ -76,7 +76,7 @@ public function ifTrue(\Closure $closure = null)
7676
/**
7777
* Tests if the value is a string.
7878
*
79-
* @return ExprBuilder
79+
* @return $this
8080
*/
8181
public function ifString()
8282
{
@@ -88,7 +88,7 @@ public function ifString()
8888
/**
8989
* Tests if the value is null.
9090
*
91-
* @return ExprBuilder
91+
* @return $this
9292
*/
9393
public function ifNull()
9494
{
@@ -100,7 +100,7 @@ public function ifNull()
100100
/**
101101
* Tests if the value is an array.
102102
*
103-
* @return ExprBuilder
103+
* @return $this
104104
*/
105105
public function ifArray()
106106
{
@@ -114,7 +114,7 @@ public function ifArray()
114114
*
115115
* @param array $array
116116
*
117-
* @return ExprBuilder
117+
* @return $this
118118
*/
119119
public function ifInArray(array $array)
120120
{
@@ -128,7 +128,7 @@ public function ifInArray(array $array)
128128
*
129129
* @param array $array
130130
*
131-
* @return ExprBuilder
131+
* @return $this
132132
*/
133133
public function ifNotInArray(array $array)
134134
{
@@ -142,7 +142,7 @@ public function ifNotInArray(array $array)
142142
*
143143
* @param \Closure $closure
144144
*
145-
* @return ExprBuilder
145+
* @return $this
146146
*/
147147
public function then(\Closure $closure)
148148
{
@@ -154,7 +154,7 @@ public function then(\Closure $closure)
154154
/**
155155
* Sets a closure returning an empty array.
156156
*
157-
* @return ExprBuilder
157+
* @return $this
158158
*/
159159
public function thenEmptyArray()
160160
{
@@ -170,7 +170,7 @@ public function thenEmptyArray()
170170
*
171171
* @param string $message
172172
*
173-
* @return ExprBuilder
173+
* @return $this
174174
*
175175
* @throws \InvalidArgumentException
176176
*/
@@ -184,7 +184,7 @@ public function thenInvalid($message)
184184
/**
185185
* Sets a closure unsetting this key of the array at validation time.
186186
*
187-
* @return ExprBuilder
187+
* @return $this
188188
*
189189
* @throws UnsetKeyException
190190
*/

Definition/Builder/MergeBuilder.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ public function __construct(NodeDefinition $node)
3737
*
3838
* @param bool $allow
3939
*
40-
* @return MergeBuilder
40+
* @return $this
4141
*/
4242
public function allowUnset($allow = true)
4343
{
@@ -51,7 +51,7 @@ public function allowUnset($allow = true)
5151
*
5252
* @param bool $deny Whether the overwriting is forbidden or not
5353
*
54-
* @return MergeBuilder
54+
* @return $this
5555
*/
5656
public function denyOverwrite($deny = true)
5757
{

Definition/Builder/NodeBuilder.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ public function __construct()
4242
*
4343
* @param ParentNodeDefinitionInterface $parent The parent node
4444
*
45-
* @return NodeBuilder This node builder
45+
* @return $this
4646
*/
4747
public function setParent(ParentNodeDefinitionInterface $parent = null)
4848
{
@@ -182,7 +182,7 @@ public function node($name, $type)
182182
*
183183
* @param NodeDefinition $node
184184
*
185-
* @return NodeBuilder This node builder
185+
* @return $this
186186
*/
187187
public function append(NodeDefinition $node)
188188
{
@@ -207,7 +207,7 @@ public function append(NodeDefinition $node)
207207
* @param string $type The name of the type
208208
* @param string $class The fully qualified name the node definition class
209209
*
210-
* @return NodeBuilder This node builder
210+
* @return $this
211211
*/
212212
public function setNodeClass($type, $class)
213213
{

Definition/Builder/NodeDefinition.php

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ public function __construct($name, NodeParentInterface $parent = null)
5656
*
5757
* @param NodeParentInterface $parent The parent
5858
*
59-
* @return NodeDefinition|$this
59+
* @return $this
6060
*/
6161
public function setParent(NodeParentInterface $parent)
6262
{
@@ -70,7 +70,7 @@ public function setParent(NodeParentInterface $parent)
7070
*
7171
* @param string $info The info text
7272
*
73-
* @return NodeDefinition|$this
73+
* @return $this
7474
*/
7575
public function info($info)
7676
{
@@ -82,7 +82,7 @@ public function info($info)
8282
*
8383
* @param string|array $example
8484
*
85-
* @return NodeDefinition|$this
85+
* @return $this
8686
*/
8787
public function example($example)
8888
{
@@ -95,7 +95,7 @@ public function example($example)
9595
* @param string $key
9696
* @param mixed $value
9797
*
98-
* @return NodeDefinition|$this
98+
* @return $this
9999
*/
100100
public function attribute($key, $value)
101101
{
@@ -146,7 +146,7 @@ public function getNode($forceRootNode = false)
146146
*
147147
* @param mixed $value The default value
148148
*
149-
* @return NodeDefinition|$this
149+
* @return $this
150150
*/
151151
public function defaultValue($value)
152152
{
@@ -159,7 +159,7 @@ public function defaultValue($value)
159159
/**
160160
* Sets the node as required.
161161
*
162-
* @return NodeDefinition|$this
162+
* @return $this
163163
*/
164164
public function isRequired()
165165
{
@@ -173,7 +173,7 @@ public function isRequired()
173173
*
174174
* @param mixed $value
175175
*
176-
* @return NodeDefinition|$this
176+
* @return $this
177177
*/
178178
public function treatNullLike($value)
179179
{
@@ -187,7 +187,7 @@ public function treatNullLike($value)
187187
*
188188
* @param mixed $value
189189
*
190-
* @return NodeDefinition|$this
190+
* @return $this
191191
*/
192192
public function treatTrueLike($value)
193193
{
@@ -201,7 +201,7 @@ public function treatTrueLike($value)
201201
*
202202
* @param mixed $value
203203
*
204-
* @return NodeDefinition|$this
204+
* @return $this
205205
*/
206206
public function treatFalseLike($value)
207207
{
@@ -213,7 +213,7 @@ public function treatFalseLike($value)
213213
/**
214214
* Sets null as the default value.
215215
*
216-
* @return NodeDefinition|$this
216+
* @return $this
217217
*/
218218
public function defaultNull()
219219
{
@@ -223,7 +223,7 @@ public function defaultNull()
223223
/**
224224
* Sets true as the default value.
225225
*
226-
* @return NodeDefinition|$this
226+
* @return $this
227227
*/
228228
public function defaultTrue()
229229
{
@@ -233,7 +233,7 @@ public function defaultTrue()
233233
/**
234234
* Sets false as the default value.
235235
*
236-
* @return NodeDefinition|$this
236+
* @return $this
237237
*/
238238
public function defaultFalse()
239239
{
@@ -253,7 +253,7 @@ public function beforeNormalization()
253253
/**
254254
* Denies the node value being empty.
255255
*
256-
* @return NodeDefinition|$this
256+
* @return $this
257257
*/
258258
public function cannotBeEmpty()
259259
{
@@ -281,7 +281,7 @@ public function validate()
281281
*
282282
* @param bool $deny Whether the overwriting is forbidden or not
283283
*
284-
* @return NodeDefinition|$this
284+
* @return $this
285285
*/
286286
public function cannotBeOverwritten($deny = true)
287287
{

0 commit comments

Comments
 (0)