freemarker-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Daniel Dekany <>
Subject Re: TemplateExceptionHandlerType
Date Thu, 07 Apr 2016 06:41:22 GMT
But there's already support for that. If you are using a "properties"
file, try:


or even:


See all the settings that can be set via string-string pairs here:

Thursday, April 7, 2016, 7:57:30 AM, Lalish-Menagh, Trevor wrote:

> Hello FreeMarker Devs,
> Which I was working with FreeMarker, I ran into the issue of
> wanting to configure my TemplateExceptionHandler type from a
> standard properties file. Unfortunately, there is no mapping to the
> static TemplateExceptionHandler types to a String equivalent that I could use in properties.
> I solved this by creating a TemplateExceptionHandlerType enum with
> a getHandler() method that allows you to get a standard
> TemplateExceptionHandler by String name as follows:
> TemplateExceptionHandlerType.valueOf("RETHROW_HANDLER").getHandler());
> I have attached my code change, including unit test, as a patch
> file in this email for peer review.
> Yours,
> Trevor

 Daniel Dekany

View raw message