public interface MustacheFactory
Modifier and Type | Method and Description |
---|---|
Mustache |
compile(Reader reader,
String name)
Create a mustache given a reader and a name.
|
Mustache |
compile(String name)
Create a mustache given a resource name.
|
MustacheVisitor |
createMustacheVisitor()
Creates the visitor for compilation.
|
void |
encode(String value,
Writer writer)
This defines how "encoded" values are encoded.
|
ObjectHandler |
getObjectHandler()
The object handler knows how to transform names into fields and methods.
|
Reader |
getReader(String resourceName)
Given a resource name, construct a reader.
|
String |
translate(String from)
Converts your arbitrary name to another name.
|
MustacheVisitor createMustacheVisitor()
Reader getReader(String resourceName)
resourceName
- used to find the resourcevoid encode(String value, Writer writer)
value
- the unencoded valuewriter
- where to encode the valueObjectHandler getObjectHandler()
Mustache compile(String name)
name
- the name of the resourceMustache compile(Reader reader, String name)
reader
- the readername
- the name of the resourceCopyright © 2018. All rights reserved.