public interface Template extends TemplateContextOperator, Updatable
Modifier and Type | Method and Description |
---|---|
void |
addImport(Object importPath) |
List<String> |
getImportPathList()
返回宏文件中引入模板的顺序
|
Map<String,Macro> |
getMacroMap()
返回宏的内容
|
String |
getPath()
返回模板对应的路径
|
TemplateEngine |
getTemplateEngine()
返回模板引擎
|
void |
render() |
void |
render(TemplateContext context) |
void |
render(TemplateContext context,
OutputStream outputStream)
进行渲染
|
void |
setTemplateEngine(TemplateEngine templateEngine)
设置对应的模板引擎
|
getTemplateContext, put
getAbsolutePath, getLastModifiedTime, setAbsolutePath, setLastModifiedTime
void addImport(Object importPath)
void render(TemplateContext context, OutputStream outputStream) throws TemplateException
outputStream
- TemplateException
void render(TemplateContext context) throws TemplateException
TemplateException
void render() throws TemplateException
TemplateException
String getPath()
TemplateEngine getTemplateEngine()
void setTemplateEngine(TemplateEngine templateEngine)
templateEngine
- Copyright © 2006–2018 TinyGroup. All rights reserved.