<?php
 namespace Eluceo\iCal\Domain\ValueObject; use DateTimeInterface as PhpDateTime; use DateTimeZone as PhpDateTimeZone; final class DateTime extends Timestamp { private bool $applyTimeZone; public function __construct(PhpDateTime $phpDateTime, bool $applyTimeZone) { parent::__construct($phpDateTime); $this->applyTimeZone = $applyTimeZone; } public function getDateTimeZone(): PhpDateTimeZone { return $this->getDateTime()->getTimezone(); } public function hasDateTimeZone(): bool { return $this->applyTimeZone; } } 