org.riotfamily.website.freemarker
Class RiotTemplateExceptionHandler

java.lang.Object
  extended by org.riotfamily.website.freemarker.RiotTemplateExceptionHandler
All Implemented Interfaces:
freemarker.template.TemplateExceptionHandler

public class RiotTemplateExceptionHandler
extends Object
implements freemarker.template.TemplateExceptionHandler

FreeMarker TemplateExceptionHandler that only outputs an error message if the template is requested by an authenticated Riot user: Otherwise the message is silently swallowed. Additionally the handler instructs Cachius not to cache the output.

Since:
7.0
Author:
Felix Gnass [fgnass at neteye dot de]

Field Summary
 
Fields inherited from interface freemarker.template.TemplateExceptionHandler
DEBUG_HANDLER, HTML_DEBUG_HANDLER, IGNORE_HANDLER, RETHROW_HANDLER
 
Constructor Summary
RiotTemplateExceptionHandler()
           
 
Method Summary
 void handleTemplateException(freemarker.template.TemplateException te, freemarker.core.Environment env, Writer out)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RiotTemplateExceptionHandler

public RiotTemplateExceptionHandler()
Method Detail

handleTemplateException

public void handleTemplateException(freemarker.template.TemplateException te,
                                    freemarker.core.Environment env,
                                    Writer out)
                             throws freemarker.template.TemplateException
Specified by:
handleTemplateException in interface freemarker.template.TemplateExceptionHandler
Throws:
freemarker.template.TemplateException