final class TemplateLexer

Constants

StatePlain

StateLatteTag

StateLatteComment

StateHtmlText

StateHtmlTag

StateHtmlQuotedValue

StateHtmlQuotedNAttrValue

StateHtmlRawText

StateHtmlComment

StateHtmlBogus

ReTagName

HTML tag name for Latte needs (actually is [a-zA-Z][^\s/>]*)

NPrefix

special HTML attribute prefix

private ReAttrName

HTML attribute name/value (\p{C} means \x00-\x1F except space)

Methods

__construct()

No description

tokenize(string $template)

No description

void
setState(string $state, ...$args)

No description

void
pushState(string $state, ...$args)

No description

void
popState()

No description

string
getState()

No description

setSyntax(string|null $type, string|null $endTag = null)

Changes tag delimiters.

void
popSyntax()

No description

Details

at line 49
__construct()

No description

at line 59
Generator tokenize(string $template)

No description

Parameters

string $template

Return Value

Generator

at line 249
void setState(string $state, ...$args)

No description

Parameters

string $state
...$args

Return Value

void

at line 255
void pushState(string $state, ...$args)

No description

Parameters

string $state
...$args

Return Value

void

at line 262
void popState()

No description

Return Value

void

at line 268
string getState()

No description

Return Value

string

at line 277
TemplateLexer setSyntax(string|null $type, string|null $endTag = null)

Changes tag delimiters.

Parameters

string|null $type
string|null $endTag

Return Value

TemplateLexer

at line 295
void popSyntax()

No description

Return Value

void