@@ 182-193 (lines=12) @@ | ||
179 | * |
|
180 | * @throws \Exception|InvalidServiceException |
|
181 | */ |
|
182 | public function addCustomResolver($id, $resolver) |
|
183 | { |
|
184 | if (!$resolver instanceof EventResolverInterface) { |
|
185 | $this->handleException(new InvalidServiceException( |
|
186 | 'Resolver Service must implement' . EventResolverInterface::class |
|
187 | )); |
|
188 | ||
189 | return; |
|
190 | } |
|
191 | ||
192 | $this->customResolvers[$id] = $resolver; |
|
193 | } |
|
194 | ||
195 | /** |
|
196 | * @param mixed $resolver |
|
@@ 200-211 (lines=12) @@ | ||
197 | * |
|
198 | * @throws \Exception |
|
199 | */ |
|
200 | public function setCommonResolver($resolver) |
|
201 | { |
|
202 | if (!$resolver instanceof EventResolverInterface) { |
|
203 | $this->commonResolver = $this->handleException(new InvalidServiceException( |
|
204 | 'Resolver Service must implement' . EventResolverInterface::class |
|
205 | )); |
|
206 | ||
207 | return; |
|
208 | } |
|
209 | ||
210 | $this->commonResolver = $resolver; |
|
211 | } |
|
212 | ||
213 | ||
214 | /** |