Test Failed
Push — master ( 22b809...326de4 )
by Brent
05:15 queued 39s
created

StitcherException   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 23
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Test Coverage

Coverage 55.56%

Importance

Changes 0
Metric Value
dl 0
loc 23
ccs 5
cts 9
cp 0.5556
rs 10
c 0
b 0
f 0
wmc 3
lcom 0
cbo 0

3 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 7 1
A title() 0 4 1
A body() 0 4 1
1
<?php
2
3
namespace Stitcher\Exception;
4
5
use Exception;
6
7
class StitcherException extends Exception
8
{
9
    protected $title;
10
    protected $body;
11
12 2
    public function __construct(string $title, ?string $body = null)
13
    {
14 2
        parent::__construct($title);
15
16 2
        $this->title = $title;
17 2
        $this->body = $body;
18 2
    }
19
20
    public function title(): string
21
    {
22
        return $this->title;
23
    }
24
25
    public function body(): ?string
26
    {
27
        return $this->body;
28
    }
29
}
30