Add Types

Signed-off-by: davidarendsen <davidarendsen@hey.com>
This commit is contained in:
davidarendsen 2022-08-15 21:22:01 +00:00
commit a50e33ba04
5 changed files with 93 additions and 1 deletions

18
src/Type/Time.php Normal file
View file

@ -0,0 +1,18 @@
<?php
namespace Arendsen\FluxQueryBuilder\Type;
use DateTime;
class Time implements TypeInterface
{
public function __construct(DateTime $dateTime)
{
$this->dateTime = $dateTime;
}
public function __toString(): string
{
return 'time(v: ' . $this->dateTime->format('Y-m-d\TH:i:s\Z') . ')';
}
}