Completed
Push — master ( e112b2...aa67e9 )
by De Cramer
02:06
created

ChainOperationException   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 26
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
dl 0
loc 26
ccs 6
cts 6
cp 1
rs 10
c 0
b 0
f 0
wmc 2

2 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 5 1
A getChainOperationName() 0 3 1
1
<?php
2
3
namespace Oliverde8\Component\PhpEtl\Exception;
4
use Throwable;
5
6
/**
7
 * Class ChainException
8
 *
9
 * @author    de Cramer Oliver<[email protected]>
10
 * @copyright 2018 Oliverde8
11
 * @package Oliverde8\Component\PhpEtl
12
 */
13
class ChainOperationException extends \Exception
14
{
15
    /** @var string */
16
    protected $chainOperationName;
17
18
    /**
19
     * ChainOperationException constructor.
20
     *
21
     * @param string $message
22
     * @param int $code
23
     * @param Throwable|null $previous
24
     * @param string $chainOperationName
25
     */
26 1
    public function __construct($message = "", $code = 0, \Exception $previous = null, $chainOperationName = '')
27
    {
28 1
        $this->chainOperationName = $chainOperationName;
29
30 1
        parent::__construct($message, $code, $previous);
31 1
    }
32
33
    /**
34
     * @return string
35
     */
36 1
    public function getChainOperationName()
37
    {
38 1
        return $this->chainOperationName;
39
    }
40
}