Package com.peterphi.usermanager.ui
Class TemplateExceptionRenderer
java.lang.Object
com.peterphi.usermanager.ui.TemplateExceptionRenderer
- All Implemented Interfaces:
RestFailureRenderer
Renders exceptions using a template
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionjavax.ws.rs.core.Response
render
(RestFailure failure) Allows user-defined code to present the exception in a more user-friendly mannerMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.peterphi.std.guice.web.rest.jaxrs.exception.RestFailureRenderer
shouldSuppressLog
-
Field Details
-
enabled
@Inject(optional=true) protected boolean enabled
-
-
Constructor Details
-
TemplateExceptionRenderer
public TemplateExceptionRenderer()
-
-
Method Details
-
render
Description copied from interface:RestFailureRenderer
Allows user-defined code to present the exception in a more user-friendly manner- Specified by:
render
in interfaceRestFailureRenderer
- Returns:
- a non-null Response if desired - otherwise (or if this method throws) the default exeption renderer will be used
-