You are here

class ExceptionHalJsonSubscriber in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 core/modules/hal/src/EventSubscriber/ExceptionHalJsonSubscriber.php \Drupal\hal\EventSubscriber\ExceptionHalJsonSubscriber

Handle HAL JSON exceptions the same as JSON exceptions.

Hierarchy

Expanded class hierarchy of ExceptionHalJsonSubscriber

1 string reference to 'ExceptionHalJsonSubscriber'
hal.services.yml in core/modules/hal/hal.services.yml
core/modules/hal/hal.services.yml
1 service uses ExceptionHalJsonSubscriber
exception.default_json in core/modules/hal/hal.services.yml
Drupal\hal\EventSubscriber\ExceptionHalJsonSubscriber

File

core/modules/hal/src/EventSubscriber/ExceptionHalJsonSubscriber.php, line 15
Contains \Drupal\hal\EventSubscriber\ExceptionHalJsonSubscriber.

Namespace

Drupal\hal\EventSubscriber
View source
class ExceptionHalJsonSubscriber extends ExceptionJsonSubscriber {

  /**
   * {@inheritdoc}
   */
  protected function getHandledFormats() {
    return [
      'hal_json',
    ];
  }

}

Members

Namesort descending Modifiers Type Description Overrides
ExceptionHalJsonSubscriber::getHandledFormats protected function Specifies the request formats this subscriber will respond to. Overrides ExceptionJsonSubscriber::getHandledFormats
ExceptionJsonSubscriber::getPriority protected static function Specifies the priority of all listeners in this class. Overrides HttpExceptionSubscriberBase::getPriority
ExceptionJsonSubscriber::on403 public function Handles a 403 error for JSON.
ExceptionJsonSubscriber::on404 public function Handles a 404 error for JSON.
ExceptionJsonSubscriber::on405 public function Handles a 405 error for JSON.
ExceptionJsonSubscriber::on406 public function Handles a 406 error for JSON.
HttpExceptionSubscriberBase::getSubscribedEvents public static function Registers the methods in this class that should be listeners. Overrides EventSubscriberInterface::getSubscribedEvents
HttpExceptionSubscriberBase::onException public function Handles errors for this subscriber.