3 namespace Drupal\Core\Http\Exception;
5 use Drupal\Core\Cache\CacheableDependencyInterface;
6 use Drupal\Core\Cache\CacheableDependencyTrait;
7 use Symfony\Component\HttpKernel\Exception\UnauthorizedHttpException;
10 * A cacheable UnauthorizedHttpException.
12 class CacheableUnauthorizedHttpException extends UnauthorizedHttpException implements CacheableDependencyInterface {
14 use CacheableDependencyTrait;
19 public function __construct(CacheableDependencyInterface $cacheability, $challenge, $message = NULL, \Exception $previous = NULL, $code = 0) {
20 $this->setCacheability($cacheability);
21 parent::__construct($challenge, $message, $previous, $code);