ILIAS  release_5-3 Revision v5.3.23-19-g915713cf615
CExtDisablingNodeVisitor Class Reference
+ Inheritance diagram for CExtDisablingNodeVisitor:
+ Collaboration diagram for CExtDisablingNodeVisitor:

Public Member Functions

 enterNode (Twig_NodeInterface $node, Twig_Environment $env)
 Called before child nodes are visited. More...
 
 leaveNode (Twig_NodeInterface $node, Twig_Environment $env)
 Called after child nodes are visited. More...
 
 getPriority ()
 Returns the priority for this visitor. More...
 

Detailed Description

Definition at line 737 of file TemplateTest.php.

Member Function Documentation

◆ enterNode()

CExtDisablingNodeVisitor::enterNode ( Twig_NodeInterface  $node,
Twig_Environment  $env 
)

Called before child nodes are visited.

Returns
Twig_NodeInterface The modified node

Implements Twig_NodeVisitorInterface.

Definition at line 739 of file TemplateTest.php.

740  {
741  if ($node instanceof Twig_Node_Expression_GetAttr) {
742  $node->setAttribute('disable_c_ext', true);
743  }
744 
745  return $node;
746  }

◆ getPriority()

CExtDisablingNodeVisitor::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 753 of file TemplateTest.php.

754  {
755  return 0;
756  }

◆ leaveNode()

CExtDisablingNodeVisitor::leaveNode ( Twig_NodeInterface  $node,
Twig_Environment  $env 
)

Called after child nodes are visited.

Returns
Twig_NodeInterface|false The modified node or false if the node must be removed

Implements Twig_NodeVisitorInterface.

Definition at line 748 of file TemplateTest.php.

749  {
750  return $node;
751  }

The documentation for this class was generated from the following file: