@@ -23,7 +23,7 @@ discard block |
||
23 | 23 | */ |
24 | 24 | public function toString(): string |
25 | 25 | { |
26 | - return (string)$this->toPrimitive(); |
|
26 | + return (string) $this->toPrimitive(); |
|
27 | 27 | } |
28 | 28 | |
29 | 29 | /** |
@@ -59,7 +59,7 @@ discard block |
||
59 | 59 | return $this->parseInt($value->getValue()); |
60 | 60 | } |
61 | 61 | |
62 | - return (float)$value->getValue(); |
|
62 | + return (float) $value->getValue(); |
|
63 | 63 | } |
64 | 64 | |
65 | 65 | /** |
@@ -113,7 +113,7 @@ discard block |
||
113 | 113 | */ |
114 | 114 | private function parseExponential(string $value): float |
115 | 115 | { |
116 | - return (float)$value; |
|
116 | + return (float) $value; |
|
117 | 117 | } |
118 | 118 | |
119 | 119 | /** |
@@ -131,7 +131,7 @@ discard block |
||
131 | 131 | */ |
132 | 132 | private function parseFloat(string $value): float |
133 | 133 | { |
134 | - return (float)$value; |
|
134 | + return (float) $value; |
|
135 | 135 | } |
136 | 136 | |
137 | 137 | /** |
@@ -21,7 +21,7 @@ |
||
21 | 21 | */ |
22 | 22 | public function toPrimitive(): string |
23 | 23 | { |
24 | - return (string)$this->getChild(0)->getValue(); |
|
24 | + return (string) $this->getChild(0)->getValue(); |
|
25 | 25 | } |
26 | 26 | |
27 | 27 | /** |
@@ -21,7 +21,7 @@ discard block |
||
21 | 21 | */ |
22 | 22 | public function toString(): string |
23 | 23 | { |
24 | - $values = \array_map(function (ValueInterface $value) { |
|
24 | + $values = \array_map(function(ValueInterface $value) { |
|
25 | 25 | return $value->toString(); |
26 | 26 | }, \iterator_to_array($this->getValues())); |
27 | 27 | |
@@ -33,7 +33,7 @@ discard block |
||
33 | 33 | */ |
34 | 34 | public function toPrimitive(): iterable |
35 | 35 | { |
36 | - return \array_map(function (ValueInterface $value) { |
|
36 | + return \array_map(function(ValueInterface $value) { |
|
37 | 37 | return $value->toPrimitive(); |
38 | 38 | }, \iterator_to_array($this->getValues())); |
39 | 39 | } |
@@ -43,7 +43,7 @@ |
||
43 | 43 | } |
44 | 44 | |
45 | 45 | /** |
46 | - * @return null|ValueInterface|NodeInterface |
|
46 | + * @return null|NodeInterface |
|
47 | 47 | */ |
48 | 48 | public function getDefaultValue(): ?ValueInterface |
49 | 49 | { |
@@ -37,13 +37,13 @@ |
||
37 | 37 | $object->withField($this->dependent($ast, $object)); |
38 | 38 | } |
39 | 39 | |
40 | - $this->when->resolving(function () use ($rule, $object): void { |
|
40 | + $this->when->resolving(function() use ($rule, $object): void { |
|
41 | 41 | foreach ($rule->getImplementations() as $interface) { |
42 | 42 | $object->withInterface($interface->getTypeName()); |
43 | 43 | } |
44 | 44 | }); |
45 | 45 | |
46 | - $this->when->runtime(function () use ($rule, $object): void { |
|
46 | + $this->when->runtime(function() use ($rule, $object): void { |
|
47 | 47 | foreach ($rule->getDirectives() as $ast) { |
48 | 48 | $object->withDirective($this->dependent($ast, $object)); |
49 | 49 | } |
@@ -36,7 +36,7 @@ |
||
36 | 36 | $enum->withValue($this->dependent($enumValue, $enum)); |
37 | 37 | } |
38 | 38 | |
39 | - $this->when->runtime(function () use ($rule, $enum): void { |
|
39 | + $this->when->runtime(function() use ($rule, $enum): void { |
|
40 | 40 | foreach ($rule->getDirectives() as $ast) { |
41 | 41 | $enum->withDirective($this->dependent($ast, $enum)); |
42 | 42 | } |
@@ -33,13 +33,13 @@ |
||
33 | 33 | $union->withOffset($rule->getOffset()); |
34 | 34 | $union->withDescription($rule->getDescription()); |
35 | 35 | |
36 | - $this->when->resolving(function () use ($rule, $union): void { |
|
36 | + $this->when->resolving(function() use ($rule, $union): void { |
|
37 | 37 | foreach ($rule->getUnitedTypes() as $ast) { |
38 | 38 | $union->withDefinition($ast->getTypeName()); |
39 | 39 | } |
40 | 40 | }); |
41 | 41 | |
42 | - $this->when->runtime(function () use ($rule, $union): void { |
|
42 | + $this->when->runtime(function() use ($rule, $union): void { |
|
43 | 43 | foreach ($rule->getDirectives() as $ast) { |
44 | 44 | $union->withDirective($this->dependent($ast, $union)); |
45 | 45 | } |
@@ -32,7 +32,7 @@ |
||
32 | 32 | $input->withOffset($rule->getOffset()); |
33 | 33 | $input->withDescription($rule->getDescription()); |
34 | 34 | |
35 | - $this->when->runtime(function () use ($rule, $input): void { |
|
35 | + $this->when->runtime(function() use ($rule, $input): void { |
|
36 | 36 | foreach ($rule->getDirectives() as $ast) { |
37 | 37 | $input->withDirective($this->dependent($ast, $input)); |
38 | 38 | } |
@@ -32,11 +32,11 @@ discard block |
||
32 | 32 | $scalar->withOffset($rule->getOffset()); |
33 | 33 | $scalar->withDescription($rule->getDescription()); |
34 | 34 | |
35 | - $this->when->resolving(function () use ($rule, $scalar): void { |
|
35 | + $this->when->resolving(function() use ($rule, $scalar): void { |
|
36 | 36 | if ($ast = $rule->getExtends()) { |
37 | 37 | $parent = $this->load($ast->getTypeName(), $scalar); |
38 | 38 | |
39 | - if (! ($parent instanceof Definition\ScalarDefinition)) { |
|
39 | + if (!($parent instanceof Definition\ScalarDefinition)) { |
|
40 | 40 | $error = '%s can extends only Scalar type, but %s given'; |
41 | 41 | throw (new TypeConflictException(\sprintf($error, $scalar, $parent))) |
42 | 42 | ->throwsIn($scalar->getFile(), $rule->getOffset()); |
@@ -46,7 +46,7 @@ discard block |
||
46 | 46 | } |
47 | 47 | }); |
48 | 48 | |
49 | - $this->when->runtime(function () use ($rule, $scalar): void { |
|
49 | + $this->when->runtime(function() use ($rule, $scalar): void { |
|
50 | 50 | foreach ($rule->getDirectives() as $ast) { |
51 | 51 | $scalar->withDirective($this->dependent($ast, $scalar)); |
52 | 52 | } |