class TypeFilter implements FilterInterface

Traits

Methods

array
asStringArray(string|array $filterValue, bool $multidimensional = false)

No description

string
asString(string|array $filterValue)

No description

int
asInt(string|array $filterValue)

No description

array
asIntArray(string|array $filterValue)

No description

bool
asBool(string|array $filterValue)

No description

string
getFilterKey()

<p>This filter will only be run when a query contains a filter param with this key.</p>

void
filter(SearchState $state, string|array $value, bool $negate)

<p>Filters a query.</p>

Details

protected array asStringArray(string|array $filterValue, bool $multidimensional = false)

Parameters

string|array $filterValue
bool $multidimensional

Return Value

array

Exceptions

ValidationException

protected string asString(string|array $filterValue)

Parameters

string|array $filterValue

Return Value

string

Exceptions

ValidationException

protected int asInt(string|array $filterValue)

Parameters

string|array $filterValue

Return Value

int

Exceptions

ValidationException

protected array asIntArray(string|array $filterValue)

Parameters

string|array $filterValue

Return Value

array

Exceptions

ValidationException

protected bool asBool(string|array $filterValue)

Parameters

string|array $filterValue

Return Value

bool

Exceptions

ValidationException

string getFilterKey()

<p>This filter will only be run when a query contains a filter param with this key.</p>

Return Value

string

void filter(SearchState $state, string|array $value, bool $negate)

<p>Filters a query.</p>

Parameters

SearchState $state
string|array $value
bool $negate

Return Value

void