TemplateParser
final class TemplateParser
Properties
Block[][] | $blocks | ||
$blockLayer | |||
$inHead | |||
$strict | |||
$lastIndentation |
Methods
__construct()
No description
parse(string $template)
Parses tokens to nodes.
parseFragment(callable $resolver, callable|null $after = null)
No description
Node|null
inTextResolve()
No description
parseLatteComment()
No description
Node|null
parseLatteStatement(callable|null $resolver = null)
No description
addTags(array $parsers)
No description
void
void
setPolicy(Policy|null $policy)
No description
setContentType(string $type)
No description
string
getContentType()
No description
getStream()
No description
getLexer()
No description
Tag|null
peekTag()
No description
void
popTag()
No description
int
generateId()
No description
bool
isTagAllowed(string $name)
No description
Details
at line 48
__construct()
No description
at line 59
TemplateNode
parse(string $template)
Parses tokens to nodes.
at line 85
FragmentNode
parseFragment(callable $resolver, callable|null $after = null)
No description
at line 107
Node|null
inTextResolve()
No description
at line 121
TextNode
parseText()
No description
at line 150
NopNode
parseLatteComment()
No description
at line 164
Node|null
parseLatteStatement(callable|null $resolver = null)
No description
at line 294
TemplateParser
addTags(array $parsers)
No description
at line 363
void
ensureIsConsumed(Tag $tag)
No description
at line 372
void
checkBlockIsUnique(Block $block)
No description
at line 389
TemplateParser
setPolicy(Policy|null $policy)
No description
at line 396
TemplateParser
setContentType(string $type)
No description
at line 406
string
getContentType()
No description
at line 413
TokenStream
getStream()
internal |
No description
at line 419
TemplateLexer
getLexer()
No description
at line 425
Tag|null
peekTag()
No description
at line 439
void
popTag()
No description
at line 445
int
generateId()
No description
at line 451
bool
isTagAllowed(string $name)
No description