PEEL Shopping
Open source ecommerce : PEEL Shopping
Public Member Functions | Protected Member Functions | Protected Attributes
Twig_Parser Class Reference

Default parser implementation. More...

Inheritance diagram for Twig_Parser:
Twig_ParserInterface

Public Member Functions

 __construct (Twig_Environment $env)
 Constructor. More...
 
 getEnvironment ()
 
 getVarName ()
 
 getFilename ()
 
 parse (Twig_TokenStream $stream, $test=null, $dropNeedle=false)
 Converts a token stream to a node tree. More...
 
 subparse ($test, $dropNeedle=false)
 
 addHandler ($name, $class)
 
 addNodeVisitor (Twig_NodeVisitorInterface $visitor)
 
 getBlockStack ()
 
 peekBlockStack ()
 
 popBlockStack ()
 
 pushBlockStack ($name)
 
 hasBlock ($name)
 
 getBlock ($name)
 
 setBlock ($name, $value)
 
 hasMacro ($name)
 
 setMacro ($name, Twig_Node_Macro $node)
 
 addTrait ($trait)
 
 hasTraits ()
 
 embedTemplate (Twig_Node_Module $template)
 
 addImportedSymbol ($type, $alias, $name=null, Twig_Node_Expression $node=null)
 
 getImportedSymbol ($type, $alias)
 
 isMainScope ()
 
 pushLocalScope ()
 
 popLocalScope ()
 
 getExpressionParser ()
 Gets the expression parser. More...
 
 getParent ()
 
 setParent ($parent)
 
 getStream ()
 Gets the token stream. More...
 
 getCurrentToken ()
 Gets the current token. More...
 
- Public Member Functions inherited from Twig_ParserInterface
 parse (Twig_TokenStream $stream)
 Converts a token stream to a node tree. More...
 

Protected Member Functions

 filterBodyNodes (Twig_NodeInterface $node)
 

Protected Attributes

 $stack = array()
 
 $stream
 
 $parent
 
 $handlers
 
 $visitors
 
 $expressionParser
 
 $blocks
 
 $blockStack
 
 $macros
 
 $env
 
 $reservedMacroNames
 
 $importedSymbols
 
 $traits
 
 $embeddedTemplates = array()
 

Detailed Description

Default parser implementation.

Author
Fabien Potencier fabie.nosp@m.n@sy.nosp@m.mfony.nosp@m..com

Definition at line 18 of file Parser.php.

Constructor & Destructor Documentation

__construct ( Twig_Environment  $env)

Constructor.

Parameters
Twig_Environment$envA Twig_Environment instance

Definition at line 40 of file Parser.php.

Member Function Documentation

addHandler (   $name,
  $class 
)

Definition at line 209 of file Parser.php.

addImportedSymbol (   $type,
  $alias,
  $name = null,
Twig_Node_Expression  $node = null 
)

Definition at line 293 of file Parser.php.

addNodeVisitor ( Twig_NodeVisitorInterface  $visitor)

Definition at line 214 of file Parser.php.

addTrait (   $trait)

Definition at line 276 of file Parser.php.

embedTemplate ( Twig_Node_Module  $template)

Definition at line 286 of file Parser.php.

filterBodyNodes ( Twig_NodeInterface  $node)
protected

Definition at line 362 of file Parser.php.

getBlock (   $name)

Definition at line 244 of file Parser.php.

getBlockStack ( )

Definition at line 219 of file Parser.php.

getCurrentToken ( )

Gets the current token.

Returns
Twig_Token The current token

Definition at line 357 of file Parser.php.

getEnvironment ( )

Definition at line 45 of file Parser.php.

getExpressionParser ( )

Gets the expression parser.

Returns
Twig_ExpressionParser The expression parser

Definition at line 327 of file Parser.php.

getFilename ( )

Definition at line 55 of file Parser.php.

getImportedSymbol (   $type,
  $alias 
)

Definition at line 298 of file Parser.php.

getParent ( )

Definition at line 332 of file Parser.php.

getStream ( )

Gets the token stream.

Returns
Twig_TokenStream The token stream

Definition at line 347 of file Parser.php.

getVarName ( )

Definition at line 50 of file Parser.php.

hasBlock (   $name)

Definition at line 239 of file Parser.php.

hasMacro (   $name)

Definition at line 254 of file Parser.php.

hasTraits ( )

Definition at line 281 of file Parser.php.

isMainScope ( )

Definition at line 307 of file Parser.php.

parse ( Twig_TokenStream  $stream,
  $test = null,
  $dropNeedle = false 
)

Converts a token stream to a node tree.

Parameters
Twig_TokenStream$streamA token stream instance
Returns
Twig_Node_Module A node tree

Definition at line 67 of file Parser.php.

peekBlockStack ( )

Definition at line 224 of file Parser.php.

popBlockStack ( )

Definition at line 229 of file Parser.php.

popLocalScope ( )

Definition at line 317 of file Parser.php.

pushBlockStack (   $name)

Definition at line 234 of file Parser.php.

pushLocalScope ( )

Definition at line 312 of file Parser.php.

setBlock (   $name,
  $value 
)

Definition at line 249 of file Parser.php.

setMacro (   $name,
Twig_Node_Macro  $node 
)

Definition at line 259 of file Parser.php.

setParent (   $parent)

Definition at line 337 of file Parser.php.

subparse (   $test,
  $dropNeedle = false 
)

Definition at line 132 of file Parser.php.

Field Documentation

$blocks
protected

Definition at line 26 of file Parser.php.

$blockStack
protected

Definition at line 27 of file Parser.php.

$embeddedTemplates = array()
protected

Definition at line 33 of file Parser.php.

$env
protected

Definition at line 29 of file Parser.php.

$expressionParser
protected

Definition at line 25 of file Parser.php.

$handlers
protected

Definition at line 23 of file Parser.php.

$importedSymbols
protected

Definition at line 31 of file Parser.php.

$macros
protected

Definition at line 28 of file Parser.php.

$parent
protected

Definition at line 22 of file Parser.php.

$reservedMacroNames
protected

Definition at line 30 of file Parser.php.

$stack = array()
protected

Definition at line 20 of file Parser.php.

$stream
protected

Definition at line 21 of file Parser.php.

$traits
protected

Definition at line 32 of file Parser.php.

$visitors
protected

Definition at line 24 of file Parser.php.


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

This documentation for Open ecommerce PEEL Shopping and PEEL.fr has been generated by Doxygen on Thu Oct 15 2015 14:41:45 - Peel ecommerce is a product of Agence web Advisto SAS. All rights reserved.