freemarker 默认值

This commit is contained in:
ran.shang
2025-06-26 18:30:09 +08:00
parent b622782415
commit 161076e755
2 changed files with 4 additions and 0 deletions

View File

@@ -29,6 +29,7 @@ public class FreeMarkerTemplateUtils {
CONFIGURATION.setDefaultEncoding("UTF-8");
CONFIGURATION.setTemplateExceptionHandler(TemplateExceptionHandler.RETHROW_HANDLER);
CONFIGURATION.setCacheStorage(NullCacheStorage.INSTANCE);
CONFIGURATION.setClassicCompatible(true);
}
public static Template getTemplate(String templateName) throws IOException {