5class Entity implements \JsonSerializable
20 $this->
id = strtolower(
$options[
'id']);
25 $this->options =
$options[
'options'];
43 if (isset(
$options[
'substituteEntityId']) && is_string(
$options[
'substituteEntityId']))
45 $this->substituteEntityId =
$options[
'substituteEntityId'];
51 $entity =
new Entity($entityOptions);
58 if (isset($entityOptions[
'filters']) && is_array($entityOptions[
'filters']))
72 $entity->addFilter($filter);
82 public function getId(): ?string
116 $this->filters[] = $filter;
128 $this->searchable = $flag;
140 $this->dynamicSearch = $flag;
152 $this->dynamicLoad = $flag;
160 'id' => $this->
getId(),
static getFilters(string $entityId, array $filterOptions=[])
static getProvider(Entity $entity)
__construct(array $options)
addFilter(BaseFilter $filter)
setSearchable(bool $flag=true)
setDynamicLoad(bool $flag=true)
setProvider(BaseProvider $provider)
setDynamicSearch(bool $flag=true)
static create(array $entityOptions)