Completed
Push — master ( 282f78...6dce89 )
by Sam
05:20
created

ServerExceptionEvent   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 23
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
eloc 4
dl 0
loc 23
rs 10
c 0
b 0
f 0
wmc 2

2 Methods

Rating   Name   Duplication   Size   Complexity  
A getException() 0 3 1
A __construct() 0 3 1
1
<?php
2
/*
3
 * This file is part of PHP DNS Server.
4
 *
5
 * (c) Yif Swery <[email protected]>
6
 *
7
 * For the full copyright and license information, please view the LICENSE
8
 * file that was distributed with this source code.
9
 */
10
11
namespace yswery\DNS\Event;
12
13
use Symfony\Component\EventDispatcher\Event;
14
15
class ServerExceptionEvent extends Event
16
{
17
    /**
18
     * @var \Exception
19
     */
20
    private $exception;
21
22
    /**
23
     * ExceptionEvent constructor.
24
     *
25
     * @param \Exception $exception
26
     */
27
    public function __construct(\Exception $exception)
28
    {
29
        $this->exception = $exception;
30
    }
31
32
    /**
33
     * @return \Exception
34
     */
35
    public function getException(): \Exception
36
    {
37
        return $this->exception;
38
    }
39
}
40