Twig_NodeVisitor_Sandbox implements sandboxing.
More...
◆ doEnterNode()
Definition at line 26 of file Sandbox.php.
References Twig_Node\getAttribute(), Twig_Node\getNode(), Twig_Node\getNodeTag(), and Twig_Node\getTemplateLine().
29 $this->inAModule =
true;
30 $this->tags = array();
31 $this->filters = array();
32 $this->functions = array();
35 } elseif ($this->inAModule) {
43 $this->filters[$node->
getNode(
'filter')->getAttribute(
'value')] = $node;
53 $this->functions[
'range'] = $node;
Twig_Node_SandboxedPrint adds a check for the __toString() method when the variable is an object and ...
Represents a node that outputs an expression.
Represents a module node.
◆ doLeaveNode()
◆ getPriority()
Twig_NodeVisitor_Sandbox::getPriority |
( |
| ) |
|
Returns the priority for this visitor.
Priority should be between -10 and 10 (0 is the default).
- Returns
- int The priority level
Implements Twig_NodeVisitorInterface.
Definition at line 76 of file Sandbox.php.
◆ $filters
Twig_NodeVisitor_Sandbox::$filters |
|
protected |
◆ $functions
Twig_NodeVisitor_Sandbox::$functions |
|
protected |
◆ $inAModule
Twig_NodeVisitor_Sandbox::$inAModule = false |
|
protected |
◆ $tags
Twig_NodeVisitor_Sandbox::$tags |
|
protected |
The documentation for this class was generated from the following file:
- libs/composer/vendor/twig/twig/lib/Twig/NodeVisitor/Sandbox.php