[ Index ] |
PHP Cross Reference of phpBB-3.2.11-deutsch |
[Summary view] [Print] [Text view]
1 <?php 2 3 /* 4 * This file is part of the Symfony package. 5 * 6 * (c) Fabien Potencier <fabien@symfony.com> 7 * 8 * For the full copyright and license information, please view the LICENSE 9 * file that was distributed with this source code. 10 */ 11 12 namespace Symfony\Bridge\Twig\TokenParser; 13 14 use Symfony\Bridge\Twig\Node\TransDefaultDomainNode; 15 use Twig\Node\Node; 16 use Twig\Token; 17 use Twig\TokenParser\AbstractTokenParser; 18 19 /** 20 * Token Parser for the 'trans_default_domain' tag. 21 * 22 * @author Fabien Potencier <fabien@symfony.com> 23 */ 24 class TransDefaultDomainTokenParser extends AbstractTokenParser 25 { 26 /** 27 * Parses a token and returns a node. 28 * 29 * @return Node 30 */ 31 public function parse(Token $token) 32 { 33 $expr = $this->parser->getExpressionParser()->parseExpression(); 34 35 $this->parser->getStream()->expect(Token::BLOCK_END_TYPE); 36 37 return new TransDefaultDomainNode($expr, $token->getLine(), $this->getTag()); 38 } 39 40 /** 41 * Gets the tag name associated with this token parser. 42 * 43 * @return string The tag name 44 */ 45 public function getTag() 46 { 47 return 'trans_default_domain'; 48 } 49 }
title
Description
Body
title
Description
Body
title
Description
Body
title
Body
Generated: Wed Nov 11 20:33:01 2020 | Cross-referenced by PHPXref 0.7.1 |