Class CoreExtension
java.lang.Object
io.pebbletemplates.pebble.extension.AbstractExtension
io.pebbletemplates.pebble.extension.core.CoreExtension
- All Implemented Interfaces:
Extension
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionUse this method to provide custom binary operators.Use this method to provide custom filters.Use this method to provide custom functions.Use this method to provide variables available to all templatesNode visitors will travel the AST tree during the compilation phase.getTests()
Use this method to provide custom tests.Use this method to provide custom tags.Use this method to provide custom unary operators.Methods inherited from class io.pebbletemplates.pebble.extension.AbstractExtension
getAttributeResolver
-
Constructor Details
-
CoreExtension
public CoreExtension()
-
-
Method Details
-
getTokenParsers
Description copied from interface:Extension
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.- Specified by:
getTokenParsers
in interfaceExtension
- Overrides:
getTokenParsers
in classAbstractExtension
- Returns:
- A list of TokenParsers. It is okay to return null.
-
getUnaryOperators
Description copied from interface:Extension
Use this method to provide custom unary operators.- Specified by:
getUnaryOperators
in interfaceExtension
- Overrides:
getUnaryOperators
in classAbstractExtension
- Returns:
- A list of Operators. It is okay to return null;
-
getBinaryOperators
Description copied from interface:Extension
Use this method to provide custom binary operators.- Specified by:
getBinaryOperators
in interfaceExtension
- Overrides:
getBinaryOperators
in classAbstractExtension
- Returns:
- A list of Operators. It is okay to return null;
-
getFilters
Description copied from interface:Extension
Use this method to provide custom filters.- Specified by:
getFilters
in interfaceExtension
- Overrides:
getFilters
in classAbstractExtension
- Returns:
- A list of filters. It is okay to return null.
-
getTests
Description copied from interface:Extension
Use this method to provide custom tests.- Specified by:
getTests
in interfaceExtension
- Overrides:
getTests
in classAbstractExtension
- Returns:
- A list of tests. It is okay to return null.
-
getFunctions
Description copied from interface:Extension
Use this method to provide custom functions.- Specified by:
getFunctions
in interfaceExtension
- Overrides:
getFunctions
in classAbstractExtension
- Returns:
- A list of functions. It is okay to return null.
-
getGlobalVariables
Description copied from interface:Extension
Use this method to provide variables available to all templates- Specified by:
getGlobalVariables
in interfaceExtension
- Overrides:
getGlobalVariables
in classAbstractExtension
- Returns:
- Map of global variables available to all templates
-
getNodeVisitors
Description copied from interface:Extension
Node visitors will travel the AST tree during the compilation phase.- Specified by:
getNodeVisitors
in interfaceExtension
- Overrides:
getNodeVisitors
in classAbstractExtension
- Returns:
- a list of node visitors
-