| 构造器和说明 |
|---|
Freemarker(freemarker.template.Configuration conf,
String key)
Instantiates a new Freemarker.
|
| 限定符和类型 | 方法和说明 |
|---|---|
static Freemarker |
FreemarkerFile(File dir,
String key)
Freemarker file freemarker.
|
static Freemarker |
FreemarkerJar(Class resourceLoaderClass,
String basePackagePath,
String key)
Freemarker jar freemarker.
|
static Freemarker |
FreemarkerText(String name,
String templateContent)
Freemarker text freemarker.
|
freemarker.template.Configuration |
getConf()
Gets conf.
|
String |
getDir()
Gets dir.
|
String |
getKey()
Gets key.
|
Map |
getRoot()
Gets root.
|
freemarker.template.Template |
getTemplate()
Gets template.
|
void |
putData(String name,
Object o)
Put data.
|
String |
render()
Render string.
|
public Freemarker(freemarker.template.Configuration conf,
String key)
conf - the confkey - the keypublic static Freemarker FreemarkerFile(File dir, String key)
dir - the dirkey - the keypublic static Freemarker FreemarkerJar(Class resourceLoaderClass, String basePackagePath, String key)
resourceLoaderClass - the resource loader classbasePackagePath - the base package pathkey - the keypublic static Freemarker FreemarkerText(String name, String templateContent)
name - the nametemplateContent - the template contentpublic String render()
public String getKey()
public freemarker.template.Configuration getConf()
public String getDir()
public freemarker.template.Template getTemplate()
public Map getRoot()
Copyright © 2020. All rights reserved.