ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
Twig_LexerInterface Interface Reference

Interface implemented by lexer classes. More...

+ Inheritance diagram for Twig_LexerInterface:
+ Collaboration diagram for Twig_LexerInterface:

Public Member Functions

 tokenize ($code, $name=null)
 Tokenizes a source code. More...
 

Detailed Description

Interface implemented by lexer classes.

Author
Fabien Potencier fabie.nosp@m.n@sy.nosp@m.mfony.nosp@m..com
Deprecated:
since 1.12 (to be removed in 3.0)

Definition at line 19 of file LexerInterface.php.

Member Function Documentation

◆ tokenize()

Twig_LexerInterface::tokenize (   $code,
  $name = null 
)

Tokenizes a source code.

Parameters
string | Twig_Source$codeThe source code
string$nameA unique identifier for the source code
Returns
Twig_TokenStream
Exceptions
Twig_Error_SyntaxWhen the code is syntactically wrong

Implemented in Twig_Lexer.


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