@@ -12,7 +12,6 @@ |
||
| 12 | 12 | use Railt\Reflection\Contracts\Definition\Behaviour\ProvidesInterfaces; |
| 13 | 13 | use Railt\Reflection\Contracts\Definition\InterfaceDefinition; |
| 14 | 14 | use Railt\Reflection\Contracts\Definition\TypeDefinition; |
| 15 | -use Railt\Reflection\Exception\TypeNotFoundException; |
|
| 16 | 15 | |
| 17 | 16 | /** |
| 18 | 17 | * Trait HasInterfaces |
@@ -110,7 +110,7 @@ |
||
| 110 | 110 | * @version SDL June 2018 |
| 111 | 111 | * @var string |
| 112 | 112 | */ |
| 113 | - public const INTERFACE = 'INTERFACE'; |
|
| 113 | + public const INTERFACE = 'INTERFACE'; |
|
| 114 | 114 | |
| 115 | 115 | /** |
| 116 | 116 | * @version SDL June 2018 |
@@ -70,7 +70,7 @@ |
||
| 70 | 70 | */ |
| 71 | 71 | private function bootInheritance(\SplStack $stack, array $children = []): void |
| 72 | 72 | { |
| 73 | - $push = function (string $type) use ($stack): void { |
|
| 73 | + $push = function(string $type) use ($stack): void { |
|
| 74 | 74 | self::$inheritance[$type] = \array_values(\iterator_to_array($stack)); |
| 75 | 75 | self::$inheritance[$type][] = static::ROOT_TYPE; |
| 76 | 76 | |
@@ -74,7 +74,7 @@ |
||
| 74 | 74 | */ |
| 75 | 75 | private function verifyExtensionType(TypeDefinition $def): void |
| 76 | 76 | { |
| 77 | - if (! $this::typeOf($def::getType())) { |
|
| 77 | + if (!$this::typeOf($def::getType())) { |
|
| 78 | 78 | $error = \sprintf('Type %s can extends only %s types, but %s given.', $this, static::getType(), $def); |
| 79 | 79 | throw new TypeConflictException($error); |
| 80 | 80 | } |
@@ -32,7 +32,7 @@ |
||
| 32 | 32 | /** |
| 33 | 33 | * @var string |
| 34 | 34 | */ |
| 35 | - public const STDLIB_SCHEMA_PATH = __DIR__ . '/../../resources/stdlib.graphqls'; |
|
| 35 | + public const STDLIB_SCHEMA_PATH = __DIR__.'/../../resources/stdlib.graphqls'; |
|
| 36 | 36 | |
| 37 | 37 | /** |
| 38 | 38 | * GraphQLDocument constructor. |
@@ -52,7 +52,7 @@ |
||
| 52 | 52 | $this->withDescription(self::TYPE_DESCRIPTION) |
| 53 | 53 | ->withArgument((new ArgumentDefinition($this, $document, 'if', 'Boolean')) |
| 54 | 54 | ->withModifiers(ArgumentDefinition::IS_NOT_NULL)) |
| 55 | - ->withLocation(...\array_map(function (string $location) use ($document): DirectiveLocation { |
|
| 55 | + ->withLocation(...\array_map(function(string $location) use ($document): DirectiveLocation { |
|
| 56 | 56 | return new DirectiveLocation($this, $document, $location); |
| 57 | 57 | }, self::LOCATIONS)); |
| 58 | 58 | } |
@@ -58,9 +58,9 @@ |
||
| 58 | 58 | parent::__construct($document, self::TYPE_NAME); |
| 59 | 59 | |
| 60 | 60 | $this->withDescription(self::TYPE_DESCRIPTION) |
| 61 | - ->withArgument((new ArgumentDefinition($this, $document, 'reason','String')) |
|
| 61 | + ->withArgument((new ArgumentDefinition($this, $document, 'reason', 'String')) |
|
| 62 | 62 | ->withDefaultValue('No longer supported')) |
| 63 | - ->withLocation(...\array_map(function (string $location) use ($document): DirectiveLocation { |
|
| 63 | + ->withLocation(...\array_map(function(string $location) use ($document): DirectiveLocation { |
|
| 64 | 64 | return new DirectiveLocation($this, $document, $location); |
| 65 | 65 | }, self::LOCATIONS)); |
| 66 | 66 | } |
@@ -53,7 +53,7 @@ |
||
| 53 | 53 | $this->withDescription(self::TYPE_DESCRIPTION) |
| 54 | 54 | ->withArgument((new ArgumentDefinition($this, $document, 'if', 'Boolean')) |
| 55 | 55 | ->withModifiers(ArgumentDefinition::IS_NOT_NULL)) |
| 56 | - ->withLocation(...\array_map(function (string $location) use ($document): DirectiveLocation { |
|
| 56 | + ->withLocation(...\array_map(function(string $location) use ($document): DirectiveLocation { |
|
| 57 | 57 | return new DirectiveLocation($this, $document, $location); |
| 58 | 58 | }, self::LOCATIONS)); |
| 59 | 59 | } |