Class HttpErrorResponse
java.lang.Object
net.targetr.wtm3.net.http.HttpResponse
net.targetr.wtm3.net.http.response.HttpByteArrayResponse
net.targetr.wtm3.net.http.response.HttpStringResponse
net.targetr.wtm3.net.http.response.HttpErrorResponse
Response sent to client after an error.
- Author:
- Dr Michael Gardiner
-
Field Summary
Fields inherited from class net.targetr.wtm3.net.http.HttpResponse
bytesWritten, code, headerLength, headers, info, version, writeErrorHandler -
Constructor Summary
ConstructorsConstructorDescriptionHttpErrorResponse(int code, String info) Returns an error code and simple error page to the client.HttpErrorResponse(int code, String info, Throwable t) Returns an error code and simple error page including stack trace to the client.HttpErrorResponse(HttpRequest httpReq, int code, String info) Returns an error code and simple error page including stack trace to the client.HttpErrorResponse(HttpRequest httpReq, int code, String info, String details) Returns an error code and simple error page including stack trace to the client.HttpErrorResponse(HttpRequest httpReq, int code, String info, String details, Throwable t) Returns an error code and simple error page including stack trace to the client.HttpErrorResponse(HttpRequest httpReq, int code, String info, Throwable t) Returns an error code and simple error page including stack trace to the client.HttpErrorResponse(HttpRequest httpReq, HttpResponse httpRes, int code, String info, String details, Throwable t) Returns an error code and simple error page including stack trace to the client. -
Method Summary
Methods inherited from class net.targetr.wtm3.net.http.response.HttpByteArrayResponse
setAllowGzip, writeMethods inherited from class net.targetr.wtm3.net.http.HttpResponse
getBodyInputStream, getContentLength, parseResponse, toString
-
Constructor Details
-
HttpErrorResponse
Returns an error code and simple error page to the client.- Parameters:
code- HTTP error codeinfo- Information about the error
-
HttpErrorResponse
Returns an error code and simple error page including stack trace to the client.- Parameters:
code- HTTP error codeinfo- Information about the errort- Exception to use to build stack trace.
-
HttpErrorResponse
Returns an error code and simple error page including stack trace to the client.- Parameters:
httpReq- The HTTP request that caused the error.code- HTTP error codeinfo- Information about the error
-
HttpErrorResponse
Returns an error code and simple error page including stack trace to the client.- Parameters:
httpReq- The HTTP request that caused the error.code- HTTP error codeinfo- Information about the errordetails- Additional details about the error.
-
HttpErrorResponse
Returns an error code and simple error page including stack trace to the client.- Parameters:
httpReq- The HTTP request that caused the error.code- HTTP error codeinfo- Information about the errort- Exception to use to display stack trace.
-
HttpErrorResponse
Returns an error code and simple error page including stack trace to the client.- Parameters:
httpReq- The HTTP request that caused the error.code- HTTP error codeinfo- Information about the errordetails- Additional details about the error.t- Exception to use to display stack trace.
-
HttpErrorResponse
public HttpErrorResponse(HttpRequest httpReq, HttpResponse httpRes, int code, String info, String details, Throwable t) Returns an error code and simple error page including stack trace to the client.- Parameters:
httpReq- The HTTP request that caused the error.httpRes- The HTTP response that caused the error.code- HTTP error codeinfo- Information about the errordetails- Additional details about the error.t- Exception to use to display stack trace.
-