类 FreeMarkerUtils
java.lang.Object
com.publiccms.common.tools.FreeMarkerUtils
FreeMarker工具类
FreeMarkerUtils
-
字段概要
字段 -
构造器概要
构造器 -
方法概要
修饰符和类型方法说明static void
generateFileByFile
(String templateFilePath, String destFilePath, freemarker.template.Configuration configuration, Map<String, Object> model) static void
generateFileByFile
(String templateFilePath, String destFilePath, freemarker.template.Configuration configuration, Map<String, Object> model, boolean override) static void
generateFileByFile
(String templateFilePath, String destFilePath, freemarker.template.Configuration configuration, Map<String, Object> model, boolean override, boolean append) static void
generateStringByFile
(Writer writer, String template, freemarker.template.Configuration configuration, Map<String, Object> model) static String
generateStringByFile
(String template, freemarker.template.Configuration configuration) static String
generateStringByFile
(String template, freemarker.template.Configuration configuration, Map<String, Object> model) static String
generateStringByString
(String templateContent, freemarker.template.Configuration configuration, Map<String, Object> model)
-
字段详细资料
-
log
private static final org.apache.commons.logging.Log log
-
-
构造器详细资料
-
FreeMarkerUtils
private FreeMarkerUtils()
-
-
方法详细资料
-
generateFileByFile
public static void generateFileByFile(String templateFilePath, String destFilePath, freemarker.template.Configuration configuration, Map<String, Object> model) throws IOException, freemarker.template.TemplateException- 参数:
templateFilePath
-destFilePath
-configuration
-model
-- 抛出:
IOException
freemarker.template.TemplateException
-
generateFileByFile
public static void generateFileByFile(String templateFilePath, String destFilePath, freemarker.template.Configuration configuration, Map<String, Object> model, boolean override) throws IOException, freemarker.template.TemplateException- 参数:
templateFilePath
-destFilePath
-configuration
-model
-override
-- 抛出:
IOException
freemarker.template.TemplateException
-
generateFileByFile
public static void generateFileByFile(String templateFilePath, String destFilePath, freemarker.template.Configuration configuration, Map<String, Object> model, boolean override, boolean append) throws IOException, freemarker.template.TemplateException- 参数:
templateFilePath
-destFilePath
-configuration
-model
-override
-append
-- 抛出:
IOException
freemarker.template.TemplateException
-
generateStringByFile
public static String generateStringByFile(String template, freemarker.template.Configuration configuration) throws IOException, freemarker.template.TemplateException - 参数:
template
-configuration
-- 返回:
- render result
- 抛出:
freemarker.template.TemplateException
IOException
-
generateStringByFile
public static String generateStringByFile(String template, freemarker.template.Configuration configuration, Map<String, Object> model) throws IOException, freemarker.template.TemplateException- 参数:
template
-configuration
-model
-- 返回:
- render result
- 抛出:
IOException
freemarker.template.TemplateException
-
generateStringByFile
public static void generateStringByFile(Writer writer, String template, freemarker.template.Configuration configuration, Map<String, Object> model) throws IOException, freemarker.template.TemplateException- 参数:
writer
-template
-configuration
-model
-- 抛出:
IOException
freemarker.template.TemplateException
-
generateStringByString
public static String generateStringByString(String templateContent, freemarker.template.Configuration configuration, Map<String, Object> model) throws IOException, freemarker.template.TemplateException- 参数:
templateContent
-configuration
-model
-- 返回:
- render result
- 抛出:
IOException
freemarker.template.TemplateException
-