FaultEvent::getException()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 4

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 0
Metric Value
dl 0
loc 4
ccs 2
cts 2
cp 1
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 0
crap 1
1
<?php
2
3
namespace Freshcells\SoapClientBundle\Event;
4
5
class FaultEvent extends Event
6
{
7
    /**
8
     * @var string
9
     */
10
    protected $id;
11
    /**
12
     * @var \Exception
13
     */
14
    protected $exception;
15
16
    /**
17
     * @var RequestEvent
18
     */
19
    protected $requestEvent;
20
21
    /**
22
     * FaultEvent constructor.
23
     * @param string $id
24
     * @param \Exception $exception
25
     * @param RequestEvent $requestEvent
26
     */
27 6
    public function __construct(string $id, \Exception $exception, RequestEvent $requestEvent)
28
    {
29 6
        $this->id           = $id;
30 6
        $this->exception    = $exception;
31 6
        $this->requestEvent = $requestEvent;
32 6
    }
33
34
    /**
35
     * @return string
36
     */
37 6
    public function getId(): string
38
    {
39 6
        return $this->id;
40
    }
41
42
    /**
43
     * @return \Exception
44
     */
45 6
    public function getException(): \Exception
46
    {
47 6
        return $this->exception;
48
    }
49
50
    /**
51
     * @return RequestEvent
52
     */
53 6
    public function getRequestEvent(): RequestEvent
54
    {
55 6
        return $this->requestEvent;
56
    }
57
}
58