public function addTokenParser(Twig_TokenParserInterface $parser)
    {
        if ($this->extensionInitialized) {
            throw new LogicException('Unable to add a token parser as extensions have already been initialized.');
        }

        $this->staging->addTokenParser($parser);
    }
public function addTokenParser(Twig_TokenParserInterface $parser)
    {
        if ($this->extensionInitialized) {
            throw new LogicException('Unable to add a token parser as extensions have already been initialized.');
        }

        $this->staging->addTokenParser($parser);
    }
public function addTokenParser ( Twig_TokenParserInterface $ parser ) { if ( $ this -> extensionInitialized ) { throw new LogicException ( 'Unable to add a token parser as extensions have already been initialized.' ) ; } $ this -> staging -> addTokenParser ( $ parser ) ; }
Registers a Token Parser.

@param Twig_TokenParserInterface $parser A Twig_TokenParserInterface instance
Registers a Token Parser .