src/Entity/Common/TimeInterval.php line 9
<?php
namespace App\Entity\Common;
use DateTime;
use Doctrine\ORM\Mapping as ORM;
#[ORM\Embeddable]
class TimeInterval implements DateTimeIntervalInterface
{
/**
* @var DateTime|null
*/
#[ORM\Column(type: 'time', nullable: true)]
private $from;
/**
* @var DateTime|null
*/
#[ORM\Column(type: 'time', nullable: true)]
private $to;
/**
* @return DateTime|null
*/
public function getFrom(): ?DateTime
{
return $this->from;
}
/**
* @param DateTime|null $from
*/
public function setFrom(?DateTime $from): void
{
$this->from = $from;
}
/**
* @return DateTime|null
*/
public function getTo(): ?DateTime
{
return $this->to;
}
/**
* @param DateTime|null $to
*/
public function setTo(?DateTime $to): void
{
$this->to = $to;
}
}