public interface Template
Modifier and Type | Method and Description |
---|---|
String |
render(Map<?,?> bindingMap)
将模板与绑定参数融合后返回为字符串
|
void |
render(Map<?,?> bindingMap,
File file)
写出到文件
|
void |
render(Map<?,?> bindingMap,
OutputStream out)
将模板与绑定参数融合后输出到流
|
void |
render(Map<?,?> bindingMap,
Writer writer)
将模板与绑定参数融合后输出到Writer
|
void render(Map<?,?> bindingMap, Writer writer)
bindingMap
- 绑定的参数,此Map中的参数会替换模板中的变量writer
- 输出void render(Map<?,?> bindingMap, OutputStream out)
bindingMap
- 绑定的参数,此Map中的参数会替换模板中的变量out
- 输出void render(Map<?,?> bindingMap, File file)
bindingMap
- 绑定的参数,此Map中的参数会替换模板中的变量file
- 输出到的文件Copyright © 2024. All rights reserved.