This class does extend all internal compile plugins

package Smarty
subpackage Compiler

 Methods

Pop closing tag

closeTag(object $compiler, array | string $expectedTag) : mixed

Raise an error if this stack-top doesn't match with expected opening tags

Parameters

$compiler

object

compiler object

$expectedTag

arraystring

the expected opening tag names

Returns

mixedany type the opening tag's name or saved data

This function checks if the attributes passed are valid

getAttributes(object $compiler, array $attributes) : array

The attributes passed for the tag to compile are checked against the list of required and optional attributes. Required attributes must be present. Optional attributes are check against the corresponding list. The keyword '_any' specifies that any attribute will be accepted as valid

Parameters

$compiler

object

compiler object

$attributes

array

attributes applied to the tag

Returns

arrayof mapped attributes for further processing

Push opening tag name on stack

openTag(object $compiler, string $openTag, mixed $data) 

Optionally additional data can be saved on stack

Parameters

$compiler

object

compiler object

$openTag

string

the opening tag's name

$data

mixed

optional data saved

 Properties

 

$option_flags : array
 

$optional_attributes : array
 

$required_attributes : array
 

$shorttag_order : array