class StringFilter extends Filter (View source)

String Filter Class

Constants

TYPE

Type of Filter.

Methods

__construct( array $columnLabelOrIndex, array $config = array())

Creates the new Filter object to filter the given column label or index.

mixed
__get( string $option)

Get the value of a set option via magic method.

from  JsonConfig
getOptions()

Gets the Options object for the JsonConfig

from  JsonConfig
setOption( string $option, mixed $value)

Shortcut method to set the value of an option and return $this.

from  JsonConfig
setOptions( array $config)

Parses the config array by passing the values through each method to check validity against if the option exists.

from  JsonConfig
array
jsonSerialize()

Custom serialization of the JsonConfig object.

from  JsonConfig
string
getType()

Returns the Filter type.

from  Filter
filterColumnIndex( integer $columnIndex)

The column of the datatable the filter should operate upon.

from  Filter
filterColumnLabel( string $columnLabel)

The label of the column the filter should operate upon.

from  Filter
ui( array $uiConfig)

Assigns custom attributes to the controls that the filter is attached to.

from  Filter
matchType( string $matchType)

What type of string the control should match.

caseSensitive( boolean $caseSensitive)

Whether matching should be case sensitive or not.

useFormattedValue( boolean $useFormattedValue)

Whether the control should match against cell formatted values or against actual values.

Details

at line 49
__construct( array $columnLabelOrIndex, array $config = array())

Creates the new Filter object to filter the given column label or index.

Parameters

array $columnLabelOrIndex
array $config

Exceptions

InvalidConfigProperty
InvalidConfigValue

in JsonConfig at line 64
mixed __get( string $option)

Get the value of a set option via magic method.

Parameters

string $option Name of option.

Return Value

mixed

Exceptions

InvalidConfigProperty

in JsonConfig at line 75
Options getOptions()

Gets the Options object for the JsonConfig

Return Value

Options

in JsonConfig at line 90
JsonConfig setOption( string $option, mixed $value)

Shortcut method to set the value of an option and return $this.

In order to maintain backwards compatibility, ConfigObjects will be unwrapped.

Parameters

string $option Option to set.
mixed $value Value of the option.

Return Value

JsonConfig

in JsonConfig at line 106
setOptions( array $config)

Parses the config array by passing the values through each method to check validity against if the option exists.

Parameters

array $config

Exceptions

InvalidConfigValue
InvalidConfigProperty

in JsonConfig at line 275
array jsonSerialize()

Custom serialization of the JsonConfig object.

Return Value

array

in Filter at line 82
string getType()

Returns the Filter type.

Return Value

string

in Filter at line 97
Filter filterColumnIndex( integer $columnIndex)

The column of the datatable the filter should operate upon.

It is mandatory to provide either this option or filterColumnLabel. If both present, this option takes precedence.

Parameters

integer $columnIndex Column index

Return Value

Filter

Exceptions

InvalidConfigValue

in Filter at line 111
Filter filterColumnLabel( string $columnLabel)

The label of the column the filter should operate upon.

It is mandatory to provide either this option or filterColumnIndex. If both present, filterColumnIndex takes precedence.

Parameters

string $columnLabel Column label

Return Value

Filter

Exceptions

InvalidConfigValue

in Filter at line 122
Filter ui( array $uiConfig)

Assigns custom attributes to the controls that the filter is attached to.

Parameters

array $uiConfig Array of options for configuring the UI

Return Value

Filter

at line 69
StringFilter matchType( string $matchType)

What type of string the control should match.

Allowed types: - exact : Match exact values only - prefix : Prefixes starting from the beginning of the value ('prefix') - any : Any substring

Parameters

string $matchType

Return Value

StringFilter

Exceptions

InvalidConfigValue

at line 87
StringFilter caseSensitive( boolean $caseSensitive)

Whether matching should be case sensitive or not.

Parameters

boolean $caseSensitive

Return Value

StringFilter

Exceptions

InvalidConfigValue

at line 99
StringFilter useFormattedValue( boolean $useFormattedValue)

Whether the control should match against cell formatted values or against actual values.

Parameters

boolean $useFormattedValue

Return Value

StringFilter

Exceptions

InvalidConfigValue