final class Expressions implements Parseable (View source)

Parses a reference to an expression (column, table or database name, function call, mathematical expression, etc.).

Constants

private ALLOWED_KEYWORDS

List of allowed reserved keywords in expressions.

Methods

static Component|array|null
parse(Parser $parser, TokensList $list, array $options = [])

Possible options:.

static string
buildAll(array $component)

No description

Details

static Component|array|null parse(Parser $parser, TokensList $list, array $options = [])

Possible options:.

field

First field to be filled.
If this is not specified, it takes the value of `parseField`.

parseField

Specifies the type of the field parsed. It may be `database`,
`table` or `column`. These expressions may not include
parentheses.

breakOnAlias

If not empty, breaks when the alias occurs (it is not included).

breakOnParentheses

If not empty, breaks when the first parentheses occurs.

parenthesesDelimited

If not empty, breaks after last parentheses occurred.

Parameters

Parser $parser

the parser that serves as context

TokensList $list

the list of tokens that are being parsed

array $options

parameters for parsing

Return Value

Component|array|null

Exceptions

ParserException

static string buildAll(array $component)

No description

Parameters

array $component

the component to be built

Return Value

string