35         $body = $this->parser->subparse(array($this, 
'decideBlockEnd'), 
true);
 
   40             foreach ($body as $node) {
 
   41                 if ($node instanceof 
Twig_Node_Text && ctype_space($node->getAttribute(
'data'))) {
 
   45                 if (!$node instanceof Twig_Node_Include) {
 
   46                     throw new Twig_Error_Syntax(
'Only "include" tags are allowed within a "sandbox" section', $node->getLine(), $this->parser->getFilename());
 
   56         return $token->
test(
'endsandbox');
 
decideBlockEnd(Twig_Token $token)
 
Base class for all token parsers. 
 
Marks a section of a template as untrusted code that must be evaluated in the sandbox mode...
 
getTag()
Gets the tag name associated with this token parser. 
 
parse(Twig_Token $token)
Parses a token and returns a node. 
 
Represents an include node. 
 
Exception thrown when a syntax error occurs during lexing or parsing of a template. 
 
Represents a sandbox node. 
 
test($type, $values=null)
Tests the current token for a type and/or a value.