* @package tao */ class tao_models_classes_AccessDeniedException extends tao_models_classes_UserException implements common_exception_UserReadableException, common_log_SeverityLevel { // --- ASSOCIATIONS --- // --- ATTRIBUTES --- /** * @access private * @var Request */ private $request; // --- OPERATIONS --- /** * An exception if a user is not authorised to execute a controller action * * @param string $userUri * @param string $action * @param string $module * @param string $ext */ public function __construct($userUri, $action, $module, $ext) { $this->request = new Request(); parent::__construct('Access to ' . $ext . '::' . $module . '::' . $action . ' denied for user \'' . $userUri . '\''); } /** * @return Request */ public function getDeniedRequest() { return $this->request; } public function getSeverity() { return common_Logger::INFO_LEVEL; } public function getUserMessage() { return __('Access denied. Please renew your authentication!'); } }