class FilterSyntaxMatcher extends AbstractRecursiveMatcher

Properties

protected RecursiveParser $parser from  AbstractRecursiveMatcher

Methods

void
__construct(RecursiveParser $parser)

No description

mixed
recurse(string $str, string $restrict = '')

Parse given string and return its value

array
getMatchers()

Return the matchers configuration

array
parseArray(string $elements = '')

No description

array
parseArrayElement(string $key, string $value)

No description

array
parseArrayElements(string $firstElement, string|null $otherElements = null)

No description

string
parseDoubleQuotedString(string $str)

No description

bool
parseFalse()

No description

array
parseFilterCallback(string $callback, string|null $args = null)

No description

array
parseFilterArg(string $argName, string $argValue)

No description

array
parseFilterArgs(string $firstArg, string|null $otherArgs = null)

No description

null
parseNull()

No description

float
parseFloat(string $str)

No description

int
parseInteger(string $str)

No description

string
parseParam(string $str)

No description

parseRegexp(string $regexp, string $flags)

No description

string
parseSingleQuotedString(string $str)

No description

bool
parseTrue()

No description

Details

void __construct(RecursiveParser $parser)

No description

Parameters

RecursiveParser $parser

Return Value

void

protected mixed recurse(string $str, string $restrict = '')

Parse given string and return its value

Parameters

string $str
string $restrict

Pipe-separated list of allowed matches (ignored if empty)

Return Value

mixed

at line 18
array getMatchers()

Return the matchers configuration

Match name as key. Can be prefixed with a colon-separated list of groups, e.g. "Group:Name". Value must be a string or an array with the following elements:

  • regexp: the regular expression used to match input.
  • order: used to sort matchers. Defaults to 0.
  • groups: list of groups this match belongs to. Defaults to an empty array.
  • callback: called with the matched strings. Defaults to [$this, "parseX"] where X is the match name.

If the config is a string, the string is used for the "regexp" element.

Return Value

array

at line 83
array parseArray(string $elements = '')

No description

Parameters

string $elements

Return Value

array

at line 109
array parseArrayElement(string $key, string $value)

No description

Parameters

string $key
string $value

Return Value

array

at line 125
array parseArrayElements(string $firstElement, string|null $otherElements = null)

No description

Parameters

string $firstElement
string|null $otherElements

Return Value

array

at line 140
string parseDoubleQuotedString(string $str)

No description

Parameters

string $str

Return Value

string

at line 167
bool parseFalse()

No description

Return Value

bool

at line 177
array parseFilterCallback(string $callback, string|null $args = null)

No description

Parameters

string $callback
string|null $args

Return Value

array

at line 188
array parseFilterArg(string $argName, string $argValue)

No description

Parameters

string $argName
string $argValue

Return Value

array

at line 206
array parseFilterArgs(string $firstArg, string|null $otherArgs = null)

No description

Parameters

string $firstArg
string|null $otherArgs

Return Value

array

at line 220
null parseNull()

No description

Return Value

null

at line 229
float parseFloat(string $str)

No description

Parameters

string $str

Return Value

float

at line 238
int parseInteger(string $str)

No description

Parameters

string $str

Return Value

int

at line 253
string parseParam(string $str)

No description

Parameters

string $str

Return Value

string

at line 263
Regexp parseRegexp(string $regexp, string $flags)

No description

Parameters

string $regexp
string $flags

Return Value

Regexp

at line 274
string parseSingleQuotedString(string $str)

No description

Parameters

string $str

Return Value

string

at line 282
bool parseTrue()

No description

Return Value

bool