public class ErrorServlet extends HttpServlet
| Constructor and Description |
|---|
ErrorServlet() |
| Modifier and Type | Method and Description |
|---|---|
protected String |
_t(String s)
translate a string, console bundle
|
protected String |
_t(String s,
Object o)
translate a string, console bundle
|
protected String |
_t(String s,
Object o,
Object o2)
translate a string, console bundle
|
protected String |
_w(String s)
translate a string, with webapp bundle
|
protected void |
doGet(HttpServletRequest req,
HttpServletResponse resp) |
protected void |
doPost(HttpServletRequest req,
HttpServletResponse resp)
Needed if the errored page was a POST
|
void |
init() |
protected void |
outputMessage(PrintWriter out,
int errorCode,
String errorMsg,
String errorURI,
Throwable errorCause)
Override for specific cases.
|
doDelete, doHead, doOptions, doPut, doTrace, getLastModified, service, servicedestroy, getInitParameter, getInitParameterNames, getServletConfig, getServletContext, getServletInfo, getServletName, init, log, logpublic void init()
throws ServletException
init in class GenericServletServletExceptionprotected void doGet(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException
doGet in class HttpServletServletExceptionIOExceptionprotected void doPost(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException
doPost in class HttpServletServletExceptionIOExceptionprotected void outputMessage(PrintWriter out, int errorCode, String errorMsg, String errorURI, Throwable errorCause)
errorCode - e.g. 404errorMsg - non-null, may be empty, already HTML-escapederrorURI - non-null, may be empty, already HTML-escapederrorCause - may be null