Passed
Push — master ( 1695c0...a5e913 )
by Smoren
02:18
created

InappropriateTokenPairException   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 24
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 2
eloc 5
c 1
b 0
f 0
dl 0
loc 24
ccs 5
cts 5
cp 1
rs 10

2 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 4 1
A getPrevToken() 0 3 1
1
<?php
2
3
namespace Smoren\FormulaTools\Exceptions;
4
5
class InappropriateTokenPairException extends TokenException
6
{
7
    /**
8
     * @var string
9
     */
10
    protected string $prevToken;
11
12
    /**
13
     * @param string $message
14
     * @param string $token
15
     * @param string $prevToken
16
     */
17 51
    public function __construct(string $message, string $token, string $prevToken)
18
    {
19 51
        parent::__construct($message, $token);
20 51
        $this->prevToken = $prevToken;
21
    }
22
23
    /**
24
     * @return string
25
     */
26 1
    public function getPrevToken(): string
27
    {
28 1
        return $this->prevToken;
29
    }
30
}
31