xref: /dokuwiki/inc/Action/Exception/FatalException.php (revision d868eb89f182718a31113373a6272670bd7f8012)
164ab5140SAndreas Gohr<?php
264ab5140SAndreas Gohr
364ab5140SAndreas Gohrnamespace dokuwiki\Action\Exception;
464ab5140SAndreas Gohr
564ab5140SAndreas Gohr/**
664ab5140SAndreas Gohr * Class FatalException
764ab5140SAndreas Gohr *
864ab5140SAndreas Gohr * A fatal exception during handling the action
964ab5140SAndreas Gohr *
10e8aa6739SAndreas Gohr * Will abort all handling and display some info to the user. The HTTP status code
11e8aa6739SAndreas Gohr * can be defined.
1264ab5140SAndreas Gohr *
1364ab5140SAndreas Gohr * @package dokuwiki\Action\Exception
1464ab5140SAndreas Gohr */
158c7c53b0SAndreas Gohrclass FatalException extends \Exception
168c7c53b0SAndreas Gohr{
1764ab5140SAndreas Gohr    /**
1864ab5140SAndreas Gohr     * FatalException constructor.
1964ab5140SAndreas Gohr     *
2064ab5140SAndreas Gohr     * @param string $message the message to send
2164ab5140SAndreas Gohr     * @param int $status the HTTP status to send
2264ab5140SAndreas Gohr     * @param null|\Exception $previous previous exception
2364ab5140SAndreas Gohr     */
24*d868eb89SAndreas Gohr    public function __construct($message = 'A fatal error occured', $status = 500, $previous = null)
25*d868eb89SAndreas Gohr    {
2664ab5140SAndreas Gohr        parent::__construct($message, $status, $previous);
2764ab5140SAndreas Gohr    }
2864ab5140SAndreas Gohr}
29