class CoreMacros extends MacroSet

Basic macros for Latte.

Methods

static void
install(Compiler $compiler)

No description

void
initialize()

Initializes before template parsing.

array|null
finalize()

Finishes template parsing.

macroIf(MacroNode $node, PhpWriter $writer)

{if ...}

macroEndIf(MacroNode $node, PhpWriter $writer)

{/if ...}

macroElse(MacroNode $node, PhpWriter $writer)

{else}

macroIfContent(MacroNode $node, PhpWriter $writer)

n:ifcontent

macroEndIfContent(MacroNode $node, PhpWriter $writer)

n:ifcontent

macroTranslate(MacroNode $node, PhpWriter $writer)

{_$var |modifiers}

macroInclude(MacroNode $node, PhpWriter $writer)

{include "file" [,] [params]}

macroCapture(MacroNode $node, PhpWriter $writer)

{capture $variable}

macroCaptureEnd(MacroNode $node, PhpWriter $writer)

{/capture}

macroSpaceless(MacroNode $node)

{spaceless} ... {/spaceless}

macroWhile(MacroNode $node, PhpWriter $writer)

{while ...}

macroEndWhile(MacroNode $node, PhpWriter $writer)

{/while ...}

macroEndForeach(MacroNode $node, PhpWriter $writer)

{foreach ...}

macroBreakContinueIf(MacroNode $node, PhpWriter $writer)

{breakIf ...} {continueIf ...}

macroClass(MacroNode $node, PhpWriter $writer)

n:class="..."

macroAttr(MacroNode $node, PhpWriter $writer)

n:attr="..."

macroDump(MacroNode $node, PhpWriter $writer)

{dump ...}

macroDebugbreak(MacroNode $node, PhpWriter $writer)

{debugbreak ...}

macroVar(MacroNode $node, PhpWriter $writer)

{var ...} {default ...}

macroExpr(MacroNode $node, PhpWriter $writer)

{= ...} {php ...}

macroContentType(MacroNode $node, PhpWriter $writer)

{contentType ...}

macroVarType(MacroNode $node)

{varType type $var}

macroVarPrint(MacroNode $node)

{varPrint [all]}

macroTemplateType(MacroNode $node)

{templateType ClassName}

macroTemplatePrint(MacroNode $node)

{templatePrint [ClassName]}

Details

at line 32
static void install(Compiler $compiler)

No description

Parameters

Compiler $compiler

Return Value

void

at line 85
void initialize()

Initializes before template parsing.

Return Value

void

at line 95
array|null finalize()

Finishes template parsing.

Return Value

array|null

[prolog, epilog]

at line 120
macroIf(MacroNode $node, PhpWriter $writer)

{if ...}

Parameters

MacroNode $node
PhpWriter $writer

at line 138
macroEndIf(MacroNode $node, PhpWriter $writer)

{/if ...}

Parameters

MacroNode $node
PhpWriter $writer

at line 158
macroElse(MacroNode $node, PhpWriter $writer)

{else}

Parameters

MacroNode $node
PhpWriter $writer

at line 183
macroIfContent(MacroNode $node, PhpWriter $writer)

n:ifcontent

Parameters

MacroNode $node
PhpWriter $writer

at line 194
macroEndIfContent(MacroNode $node, PhpWriter $writer)

n:ifcontent

Parameters

MacroNode $node
PhpWriter $writer

at line 205
macroTranslate(MacroNode $node, PhpWriter $writer)

{_$var |modifiers}

Parameters

MacroNode $node
PhpWriter $writer

at line 227
macroInclude(MacroNode $node, PhpWriter $writer)

{include "file" [,] [params]}

Parameters

MacroNode $node
PhpWriter $writer

at line 250
macroCapture(MacroNode $node, PhpWriter $writer)

{capture $variable}

Parameters

MacroNode $node
PhpWriter $writer

at line 267
macroCaptureEnd(MacroNode $node, PhpWriter $writer)

{/capture}

Parameters

MacroNode $node
PhpWriter $writer

at line 279
macroSpaceless(MacroNode $node)

{spaceless} ... {/spaceless}

Parameters

MacroNode $node

at line 294
macroWhile(MacroNode $node, PhpWriter $writer)

{while ...}

Parameters

MacroNode $node
PhpWriter $writer

at line 309
macroEndWhile(MacroNode $node, PhpWriter $writer)

{/while ...}

Parameters

MacroNode $node
PhpWriter $writer

at line 324
macroEndForeach(MacroNode $node, PhpWriter $writer)

{foreach ...}

Parameters

MacroNode $node
PhpWriter $writer

at line 357
macroBreakContinueIf(MacroNode $node, PhpWriter $writer)

{breakIf ...} {continueIf ...}

Parameters

MacroNode $node
PhpWriter $writer

at line 373
macroClass(MacroNode $node, PhpWriter $writer)

n:class="..."

Parameters

MacroNode $node
PhpWriter $writer

at line 385
macroAttr(MacroNode $node, PhpWriter $writer)

n:attr="..."

Parameters

MacroNode $node
PhpWriter $writer

at line 394
macroDump(MacroNode $node, PhpWriter $writer)

{dump ...}

Parameters

MacroNode $node
PhpWriter $writer

at line 410
macroDebugbreak(MacroNode $node, PhpWriter $writer)

{debugbreak ...}

Parameters

MacroNode $node
PhpWriter $writer

at line 425
macroVar(MacroNode $node, PhpWriter $writer)

{var ...} {default ...}

Parameters

MacroNode $node
PhpWriter $writer

at line 501
macroExpr(MacroNode $node, PhpWriter $writer)

{= ...} {php ...}

Parameters

MacroNode $node
PhpWriter $writer

at line 514
macroContentType(MacroNode $node, PhpWriter $writer)

{contentType ...}

Parameters

MacroNode $node
PhpWriter $writer

at line 551
macroVarType(MacroNode $node)

{varType type $var}

Parameters

MacroNode $node

at line 568
macroVarPrint(MacroNode $node)

{varPrint [all]}

Parameters

MacroNode $node

at line 580
macroTemplateType(MacroNode $node)

{templateType ClassName}

Parameters

MacroNode $node

at line 595
macroTemplatePrint(MacroNode $node)

{templatePrint [ClassName]}

Parameters

MacroNode $node