VersionMismatchException::expected()   A
last analyzed

Complexity

Conditions 2
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 2

Importance

Changes 0
Metric Value
dl 0
loc 4
c 0
b 0
f 0
ccs 2
cts 2
cp 1
rs 10
cc 2
eloc 2
nc 1
nop 3
crap 2
1
<?php
2
3
namespace Buttress\ConcreteClient\Exception;
4
5
class VersionMismatchException extends Exception
6
{
7
    protected $expected = null;
8
    protected $given = null;
9
10 6
    public static function expected($expected, $given = null, $previous = null)
11
    {
12 6
        return new static("Invalid Version, expected \"{$expected}\"" . ($given ? " got \"{$given}\"" : ''), $previous);
13
    }
14
}
15