file ProviderException.php

Namespace

Drupal\bootstrap\Plugin\Provider
  1. <?php
  2. namespace Drupal\bootstrap\Plugin\Provider;
  3. /**
  4. * Class ProviderException.
  5. */
  6. class ProviderException extends \RuntimeException {
  7. /**
  8. * The CDN Provider that threw the exception.
  9. *
  10. * @var \Drupal\bootstrap\Plugin\Provider\ProviderInterface
  11. */
  12. protected $provider;
  13. /**
  14. * ProviderException constructor.
  15. *
  16. * @param \Drupal\bootstrap\Plugin\Provider\ProviderInterface $provider
  17. * The CDN Provider that threw the exception.
  18. * @param string $message
  19. * The exception message.
  20. * @param int $code
  21. * The exception code.
  22. * @param \Throwable $previous
  23. * A previous exception.
  24. */
  25. public function __construct(ProviderInterface $provider, $message = "", $code = 0, \Throwable $previous = NULL) {
  26. parent::__construct($message, $code, $previous);
  27. $this->provider = $provider;
  28. }
  29. /**
  30. * Retrieves the CDN Provider instance.
  31. *
  32. * @return \Drupal\bootstrap\Plugin\Provider\ProviderInterface
  33. * The CDN Provider instance.
  34. */
  35. public function getProvider() {
  36. return $this->provider;
  37. }
  38. }

Classes

Name Description
ProviderException Class ProviderException.