3 namespace Drupal\update_script_test\PathProcessor;
5 use Drupal\Core\PathProcessor\InboundPathProcessorInterface;
6 use Drupal\Core\State\StateInterface;
7 use Symfony\Component\HttpFoundation\Request;
10 * Example path processor which breaks on inbound.
12 class BrokenInboundPathProcessor implements InboundPathProcessorInterface {
17 * @var \Drupal\Core\State\StateInterface
22 * Constructs a new BrokenInboundPathProcessor instance.
24 * @param \Drupal\Core\State\StateInterface $state
27 public function __construct(StateInterface $state) {
28 $this->state = $state;
34 public function processInbound($path, Request $request) {
35 if ($this->state->get('update_script_test_broken_inbound', FALSE)) {
36 throw new \RuntimeException();