Interface Extension
-
- All Known Implementing Classes:
AbstractExtension
,AttributeResolverExtension
,CoreExtension
,DebugExtension
,EscaperExtension
,ExtensionCustomizer
,I18nExtension
public interface Extension
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.util.List<AttributeResolver>
getAttributeResolver()
AttributeResolver will resolve instance attributesjava.util.List<BinaryOperator>
getBinaryOperators()
Use this method to provide custom binary operators.java.util.Map<java.lang.String,Filter>
getFilters()
Use this method to provide custom filters.java.util.Map<java.lang.String,Function>
getFunctions()
Use this method to provide custom functions.java.util.Map<java.lang.String,java.lang.Object>
getGlobalVariables()
Use this method to provide variables available to all templatesjava.util.List<NodeVisitorFactory>
getNodeVisitors()
Node visitors will travel the AST tree during the compilation phase.java.util.Map<java.lang.String,Test>
getTests()
Use this method to provide custom tests.java.util.List<TokenParser>
getTokenParsers()
Use this method to provide custom tags.java.util.List<UnaryOperator>
getUnaryOperators()
Use this method to provide custom unary operators.
-
-
-
Method Detail
-
getFilters
java.util.Map<java.lang.String,Filter> getFilters()
Use this method to provide custom filters.- Returns:
- A list of filters. It is okay to return null.
-
getTests
java.util.Map<java.lang.String,Test> getTests()
Use this method to provide custom tests.- Returns:
- A list of tests. It is okay to return null.
-
getFunctions
java.util.Map<java.lang.String,Function> getFunctions()
Use this method to provide custom functions.- Returns:
- A list of functions. It is okay to return null.
-
getTokenParsers
java.util.List<TokenParser> getTokenParsers()
Use this method to provide custom tags. A TokenParser is used to parse a stream of tokens into Nodes which are then responsible for compiling themselves into Java.- Returns:
- A list of TokenParsers. It is okay to return null.
-
getBinaryOperators
java.util.List<BinaryOperator> getBinaryOperators()
Use this method to provide custom binary operators.- Returns:
- A list of Operators. It is okay to return null;
-
getUnaryOperators
java.util.List<UnaryOperator> getUnaryOperators()
Use this method to provide custom unary operators.- Returns:
- A list of Operators. It is okay to return null;
-
getGlobalVariables
java.util.Map<java.lang.String,java.lang.Object> getGlobalVariables()
Use this method to provide variables available to all templates- Returns:
- Map of global variables available to all templates
-
getNodeVisitors
java.util.List<NodeVisitorFactory> getNodeVisitors()
Node visitors will travel the AST tree during the compilation phase.- Returns:
- a list of node visitors
-
getAttributeResolver
java.util.List<AttributeResolver> getAttributeResolver()
AttributeResolver will resolve instance attributes- Returns:
- a list of attribute resolver
-
-