Description
The MustacheParser class allows you to implement a Mustache parser.
Properties
initialTokens
List of original Mustache tokens.
public
List<MustacheToken> _initialTokens = new ArrayList<>()
originalTokens
List of original Mustache tokens.
public
List<Token> _originalTokens = new ArrayList<>()
resultTokens
List of parsed Mustache tokens.
public
List<MustacheToken> _resultTokens = new ArrayList<>()
template
Mustache template.
private
String _template = ""
variableNames
List of found variable names.
public
List_variableNames = new ArrayList<>()
Instance methods
clear
Clears parsing results.
public
void clear()
parseString
Sets a new Mustache string and parses it into internal byte code.
public
void parseString(String mustache) throws Exception
- mustache: String - new Mustache string.
parseTokens
Sets a new mustache Token and parses it into internal byte code.
public
void parseTokens(List<Token> tokens) throws MustacheException
- mustache: List<Token> - new Mustache string.