class Parser

Latte parser.

Constants

internal RE_STRING

internal N_PREFIX

CONTENT_HTML

Context-aware escaping content types

CONTENT_XHTML

Context-aware escaping content types

CONTENT_XML

Context-aware escaping content types

CONTENT_TEXT

Context-aware escaping content types

internal CONTEXT_NONE

internal CONTEXT_MACRO

internal CONTEXT_HTML_TEXT

internal CONTEXT_HTML_TAG

internal CONTEXT_HTML_ATTRIBUTE

internal CONTEXT_HTML_COMMENT

internal CONTEXT_HTML_CDATA

Properties

string $defaultSyntax
deprecated $shortNoEscape
array $syntaxes

Methods

Token[]
parse($input)

Process all {macros} and .

setContentType($type)

No description

setContext($context, $quote = null)

No description

setSyntax($type)

Changes macro tag delimiters.

setDelimiters($left, $right)

Changes macro tag delimiters.

array|null
parseMacroTag($tag)

Parses macro tag to name, arguments a modifiers parts.

getLine()

No description

filter(Token $token)

Process low-level macros.

Details

at line 87
Token[] parse($input)

Process all {macros} and .

Parameters

$input

Return Value

Token[]

at line 336
Parser setContentType($type)

No description

Parameters

$type

Return Value

Parser

at line 351
Parser setContext($context, $quote = null)

No description

Parameters

$context
$quote

Return Value

Parser

at line 363
Parser setSyntax($type)

Changes macro tag delimiters.

Parameters

$type

Return Value

Parser

at line 381
Parser setDelimiters($left, $right)

Changes macro tag delimiters.

Parameters

$left
$right

Return Value

Parser

at line 394
array|null parseMacroTag($tag)

internal  
 

Parses macro tag to name, arguments a modifiers parts.

Parameters

$tag

Return Value

array|null

at line 431
getLine()

No description

at line 442
protected filter(Token $token)

Process low-level macros.

Parameters

Token $token

Traits

Better OOP experience.