1 | <?php |
||
22 | class ExecutionContext implements ExecutionContextInterface |
||
23 | { |
||
24 | |||
25 | use ErrorContainerTrait; |
||
26 | |||
27 | /** @var AbstractSchema */ |
||
28 | private $schema; |
||
29 | |||
30 | /** @var Request */ |
||
31 | private $request; |
||
32 | |||
33 | /** @var ContainerInterface */ |
||
34 | private $container; |
||
35 | |||
36 | /** @var array */ |
||
37 | private $typeFieldLookupTable; |
||
38 | |||
39 | /** |
||
40 | * ExecutionContext constructor. |
||
41 | * |
||
42 | * @param AbstractSchema $schema |
||
43 | */ |
||
44 | 74 | public function __construct(AbstractSchema $schema) |
|
53 | |||
54 | /** |
||
55 | * @param AbstractObjectType $type |
||
56 | * @param string $fieldName |
||
57 | * |
||
58 | * @return Field |
||
59 | */ |
||
60 | 68 | public function getField(AbstractObjectType $type, $fieldName) |
|
74 | |||
75 | 74 | protected function validateSchema() |
|
83 | |||
84 | 74 | protected function introduceIntrospectionFields() |
|
90 | |||
91 | /** |
||
92 | * @return AbstractSchema |
||
93 | */ |
||
94 | 68 | public function getSchema() |
|
98 | |||
99 | /** |
||
100 | * @param AbstractSchema $schema |
||
101 | * |
||
102 | * @return $this |
||
103 | */ |
||
104 | public function setSchema(AbstractSchema $schema) |
||
110 | |||
111 | /** |
||
112 | * @return Request |
||
113 | */ |
||
114 | 68 | public function getRequest() |
|
118 | |||
119 | /** |
||
120 | * @param Request $request |
||
121 | * |
||
122 | * @return $this |
||
123 | */ |
||
124 | 68 | public function setRequest(Request $request) |
|
130 | |||
131 | public function get($id) |
||
135 | |||
136 | /** |
||
137 | * @return ContainerInterface |
||
138 | */ |
||
139 | 1 | public function getContainer() |
|
143 | |||
144 | /** |
||
145 | * @param ContainerInterface $container |
||
146 | * |
||
147 | * @return $this |
||
148 | */ |
||
149 | 71 | public function setContainer(ContainerInterface $container) |
|
155 | } |
||
156 |