Total Complexity | 2 |
Total Lines | 26 |
Duplicated Lines | 0 % |
Coverage | 100% |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
9 | trait HasFormatTrait |
||
10 | { |
||
11 | |||
12 | /** |
||
13 | * @var string |
||
14 | */ |
||
15 | protected $defaultFormat = null; |
||
16 | |||
17 | /** |
||
18 | * @var string |
||
19 | */ |
||
20 | protected $format = null; |
||
21 | |||
22 | 2 | public function withDefaultFormat(string $format): self |
|
23 | { |
||
24 | 2 | $this->defaultFormat = $format; |
|
25 | |||
26 | 2 | return $this; |
|
27 | } |
||
28 | |||
29 | /** |
||
30 | * @return string |
||
31 | */ |
||
32 | 4 | public function getFormat() |
|
35 | } |
||
36 | } |