PHP 클래스 Kohana_Twig_Trans_TokenParser, kohana-twig

Both block styles are allowed: {% trans "String to translate" %} {% trans %} String to translate {% endtrans %} The body of the tag will be trim()ed before being passed to __().
상속: extends Twig_TokenParser
파일 보기 프로젝트 열기: jonathangeiger/kohana-twig

공개 메소드들

메소드 설명
decideForEnd ( $token ) : boolean Tests for the endtrans block
getTag ( ) Gets the tag name associated with this token parser.
parse ( Twig_Token $token ) : Twig_NodeInterface Parses a token and returns a node.

보호된 메소드들

메소드 설명
check_trans_string ( Twig_NodeInterface $body, string $lineno ) : void Ensures only "simple" vars are in the body to be translated.

메소드 상세

check_trans_string() 보호된 메소드

Ensures only "simple" vars are in the body to be translated.
저자: Tiger Advertising
protected check_trans_string ( Twig_NodeInterface $body, string $lineno ) : void
$body Twig_NodeInterface
$lineno string
리턴 void

decideForEnd() 공개 메소드

Tests for the endtrans block
public decideForEnd ( $token ) : boolean
리턴 boolean

getTag() 공개 메소드

Gets the tag name associated with this token parser.
public getTag ( )

parse() 공개 메소드

Parses a token and returns a node.
public parse ( Twig_Token $token ) : Twig_NodeInterface
$token Twig_Token A Twig_Token instance
리턴 Twig_NodeInterface A Twig_NodeInterface instance