Interface NodeVisitorFactory
- All Known Implementing Classes:
EscaperNodeVisitorFactory
,MacroAndBlockRegistrantNodeVisitorFactory
,PrettyPrintNodeVisitorFactory
public interface NodeVisitorFactory
The node visitor factory creates
NodeVisitor
s.
Extension
can provide own implementation to provide their own NodeVisitor
s.
-
Method Summary
Modifier and TypeMethodDescriptioncreateVisitor
(PebbleTemplate template) This method creates a new instance of aNodeVisitor
.
-
Method Details
-
createVisitor
This method creates a new instance of aNodeVisitor
.The method is called whenever a visitor is applied to a
PebbleTemplate
.The method needs to be thread-safe. However the
NodeVisitor
itself does not need to be thread-safe.- Parameters:
template
- the template for which a visitor should be created for.- Returns:
- the visitor.
-