| Total Complexity | 4 |
| Total Lines | 20 |
| Duplicated Lines | 0 % |
| Coverage | 100% |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 10 | class SystemClock implements Clock |
||
| 11 | { |
||
| 12 | /** |
||
| 13 | * @var DateTimeZone |
||
| 14 | */ |
||
| 15 | private $timeZone; |
||
| 16 | |||
| 17 | public function __construct(DateTimeZone $timeZone = null) |
||
| 20 | 24 | } |
|
| 21 | 24 | ||
| 22 | public function now(): DateTimeImmutable |
||
| 23 | 14 | { |
|
| 24 | return new DateTimeImmutable('now', $this->timeZone); |
||
| 25 | 14 | } |
|
| 26 | |||
| 27 | public function timeZone(): DateTimeZone |
||
| 30 | 13 | } |
|
| 31 | } |
||
| 32 |