use of freemarker.template.Template in project paascloud-master by paascloud.
the class OptFreeMarkerServiceImpl method getTemplate.
@Override
public String getTemplate(Map<String, Object> map, String templateLocation) throws IOException, TemplateException {
Preconditions.checkArgument(PublicUtil.isNotEmpty(templateLocation), "模板不能为空");
Template t = configuration.getTemplate(templateLocation, "UTF-8");
return FreeMarkerTemplateUtils.processTemplateIntoString(t, map);
}
Aggregations