FirstDataGuzzleRequestException   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 30
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 2
eloc 5
c 1
b 0
f 0
dl 0
loc 30
rs 10

2 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 9 1
A getResponse() 0 3 1
1
<?php
2
3
/**
4
 * MIT License
5
 * For full license information, please view the LICENSE file that was distributed with this source code.
6
 */
7
8
namespace SprykerEco\Zed\FirstData\Dependency\External\Guzzle\Exception;
9
10
use Exception;
11
use SprykerEco\Zed\FirstData\Dependency\External\Guzzle\Response\FirstDataGuzzleResponseInterface;
12
use Throwable;
13
14
class FirstDataGuzzleRequestException extends Exception
15
{
16
    /**
17
     * @var \SprykerEco\Zed\FirstData\Dependency\External\Guzzle\Response\FirstDataGuzzleResponseInterface
18
     */
19
    protected $response;
20
21
    /**
22
     * @param \SprykerEco\Zed\FirstData\Dependency\External\Guzzle\Response\FirstDataGuzzleResponseInterface $response
23
     * @param string $message
24
     * @param int $code
25
     * @param \Throwable|null $previous
26
     */
27
    public function __construct(
28
        FirstDataGuzzleResponseInterface $response,
29
        string $message = '',
30
        int $code = 0,
31
        ?Throwable $previous = null
32
    ) {
33
        parent::__construct($message, $code, $previous);
34
35
        $this->response = $response;
36
    }
37
38
    /**
39
     * @return \SprykerEco\Zed\FirstData\Dependency\External\Guzzle\Response\FirstDataGuzzleResponseInterface
40
     */
41
    public function getResponse(): FirstDataGuzzleResponseInterface
42
    {
43
        return $this->response;
44
    }
45
}
46