FrontendException::__construct()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 0
Metric Value
eloc 1
dl 0
loc 3
ccs 2
cts 2
cp 1
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 1
crap 1
1
<?php
2
/**
3
 * Created by PhpStorm.
4
 * User: famoser
5
 * Date: 13/11/2016
6
 * Time: 12:27
7
 */
8
9
namespace Famoser\XKCDCache\Exceptions;
10
11
12
use Exception;
13
use Famoser\XKCDCache\Types\FrontendError;
14
15
/**
16
 * if an exception while displaying a page in the frontend occurs, this exception typ eis thrown
17
 * @package Famoser\XKCDCache\Exceptions
18
 */
19
class FrontendException extends Exception
20
{
21
    /**
22
     * FrontendException constructor.
23
     * @param int $frontendError
24
     */
25 1
    public function __construct(int $frontendError)
26
    {
27 1
        parent::__construct(FrontendError::toString($frontendError), $frontendError, null);
28
    }
29
}