HolidayAbstract   A
last analyzed

Complexity

Total Complexity 3

Size/Duplication

Total Lines 22
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
dl 0
loc 22
ccs 8
cts 8
cp 1
rs 10
c 0
b 0
f 0
wmc 3
lcom 0
cbo 0

3 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 5 1
A beginsAt() 0 4 1
A endsAt() 0 4 1
1
<?php
2
3
namespace HansOtt\Holiday;
4
5
use DateTimeImmutable;
6
7
abstract class HolidayAbstract implements Holiday
8
{
9
    private $beginsAt;
10
11
    private $endsAt;
12
13 4
    public function __construct(DateTimeImmutable $beginsAt, DateTimeImmutable $endsAt)
14
    {
15 4
        $this->beginsAt = $beginsAt;
16 4
        $this->endsAt = $endsAt;
17 4
    }
18
19 2
    final public function beginsAt()
20
    {
21 2
        return $this->beginsAt;
22
    }
23
24 2
    final public function endsAt()
25
    {
26 2
        return $this->endsAt;
27
    }
28
}
29