Completed
Push — master ( 0c057f...83f3fd )
by Christopher
13:35
created

EvangelizeException::__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 3
CRAP Score 1

Importance

Changes 1
Bugs 1 Features 0
Metric Value
c 1
b 1
f 0
dl 0
loc 4
ccs 3
cts 3
cp 1
rs 10
cc 1
eloc 2
nc 1
nop 3
crap 1
1
<?php
2
3
namespace Vundi\Checkpoint1;
4
5
use Exception;
6
7
/**
8
 * Custom Exception Class for PHP Evangelize
9
 */
10
class EvangelizeException extends \Exception
11
{
12
    // Message
13 3
    public function __construct($message, $code = 1, Exception $previous = null)
14
    {
15 3
        parent::__construct($message, $code, $previous);
16 3
    }
17
18
    // custom string representation of object
19
    public function __toString()
20
    {
21
        return __CLASS__ . ": [{$this->code}]: {$this->message}\n";
22
    }
23
}