<?php
declare(strict_types=1);
namespace Slivki\BusinessFeature\Yclients\Message\Query;
use DateTimeImmutable;
use Slivki\BusinessFeature\Yclients\SortType;
use Slivki\Messenger\Query\QueryInterface;
use Slivki\ValueObject\Coordinate;
final class SearchAvailableAppointmentWithOfferInfoQuery implements QueryInterface
{
private int $categoryId;
private DateTimeImmutable $date;
private string $rangeTime;
private ?Coordinate $coordinate;
private string $sortBy;
public function __construct(
int $categoryId,
DateTimeImmutable $date,
string $rangeTime,
?Coordinate $coordinate = null,
string $sortBy = SortType::VARIETY
) {
$this->categoryId = $categoryId;
$this->date = $date;
$this->rangeTime = $rangeTime;
$this->coordinate = $coordinate;
$this->sortBy = $sortBy;
}
public function getCategoryId(): int
{
return $this->categoryId;
}
public function getDate(): DateTimeImmutable
{
return $this->date;
}
public function getRangeTime(): string
{
return $this->rangeTime;
}
public function getCoordinate(): ?Coordinate
{
return $this->coordinate;
}
public function getSortBy(): string
{
return $this->sortBy;
}
}