| @@ 7-24 (lines=18) @@ | ||
| 4 | ||
| 5 | use Stefanius\SpecialDates\SDK\AbstractSpecialDate; |
|
| 6 | ||
| 7 | class DutchNeighboursDay extends AbstractSpecialDate |
|
| 8 | { |
|
| 9 | protected function generate() |
|
| 10 | { |
|
| 11 | $this->description = 'Burendag'; |
|
| 12 | ||
| 13 | if ($this->year >= 2006) { |
|
| 14 | $timestamp = strtotime('fourth saturday', mktime(0, 0, 0, 9, 0, $this->year)); |
|
| 15 | $this->startDate = new \DateTime(); |
|
| 16 | $this->startDate->setTimestamp($timestamp); |
|
| 17 | $this->endDate = new \DateTime(); |
|
| 18 | $this->endDate->setTimestamp($timestamp); |
|
| 19 | $this->totalLength = 1; |
|
| 20 | } else { |
|
| 21 | $this->valid = false; |
|
| 22 | } |
|
| 23 | } |
|
| 24 | } |
|
| 25 | ||
| @@ 7-24 (lines=18) @@ | ||
| 4 | ||
| 5 | use Stefanius\SpecialDates\SDK\AbstractSpecialDate; |
|
| 6 | ||
| 7 | class DutchSecretaryDay extends AbstractSpecialDate |
|
| 8 | { |
|
| 9 | protected function generate() |
|
| 10 | { |
|
| 11 | $this->description = 'Secretaressedag'; |
|
| 12 | ||
| 13 | if ($this->year >= 1989) { |
|
| 14 | $timestamp = strtotime('third thursday', mktime(0, 0, 0, 4, 0, $this->year)); |
|
| 15 | $this->startDate = new \DateTime(); |
|
| 16 | $this->startDate->setTimestamp($timestamp); |
|
| 17 | $this->endDate = new \DateTime(); |
|
| 18 | $this->endDate->setTimestamp($timestamp); |
|
| 19 | $this->totalLength = 1; |
|
| 20 | } else { |
|
| 21 | $this->valid = false; |
|
| 22 | } |
|
| 23 | } |
|
| 24 | } |
|
| 25 | ||