| Total Complexity | 4 |
| Total Lines | 36 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 13 | class DateRange extends CanonicalRange |
||
| 14 | { |
||
| 15 | use StringifiesBoundariesFromDateTimeInterface; |
||
| 16 | |||
| 17 | /** |
||
| 18 | * @param string $boundary |
||
| 19 | * @return string |
||
| 20 | */ |
||
| 21 | protected function addToDiscreteBoundary(string $boundary): string |
||
| 22 | { |
||
| 23 | return $this->transformBoundary($boundary)->addDay()->toDateString(); |
||
| 24 | } |
||
| 25 | |||
| 26 | /** |
||
| 27 | * @param string $boundary |
||
| 28 | * @return CarbonImmutable |
||
| 29 | */ |
||
| 30 | protected function transformBoundary(string $boundary): CarbonImmutable |
||
| 31 | { |
||
| 32 | return CarbonImmutable::parse($boundary); |
||
| 33 | } |
||
| 34 | |||
| 35 | /** |
||
| 36 | * {@inheritdoc} |
||
| 37 | */ |
||
| 38 | protected function getBoundaryFormat(): string |
||
| 41 | } |
||
| 42 | |||
| 43 | /** |
||
| 44 | * @return string |
||
| 45 | */ |
||
| 46 | public function forSql(): string |
||
| 51 |