Package org.apache.xmlrpc.webserver
Class ServletWebServer.Exception
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.io.IOException
-
- org.apache.xmlrpc.webserver.ServletWebServer.Exception
-
- All Implemented Interfaces:
java.io.Serializable
- Enclosing class:
- ServletWebServer
public static class ServletWebServer.Exception extends java.io.IOException
This exception is thrown by the request handling classes, advising the server, that it should return an error response.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description private java.lang.String
description
private static long
serialVersionUID
private int
statusCode
-
Constructor Summary
Constructors Constructor Description Exception(int pStatusCode, java.lang.String pMessage, java.lang.String pDescription)
Creates a new instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
getDescription()
Returns the error description.java.lang.String
getMessage()
int
getStatusCode()
Returns the HTTP status code.
-
-
-
Field Detail
-
serialVersionUID
private static final long serialVersionUID
- See Also:
- Constant Field Values
-
statusCode
private final int statusCode
-
description
private final java.lang.String description
-
-
Constructor Detail
-
Exception
public Exception(int pStatusCode, java.lang.String pMessage, java.lang.String pDescription)
Creates a new instance.- Parameters:
pStatusCode
- The HTTP status code being sent to the client.pMessage
- The HTTP status message being sent to the client.pDescription
- The error description being sent to the client in the response body.
-
-
Method Detail
-
getMessage
public java.lang.String getMessage()
- Overrides:
getMessage
in classjava.lang.Throwable
-
getDescription
public java.lang.String getDescription()
Returns the error description. The server will send the description as plain text in the response body.- Returns:
- The error description.
-
getStatusCode
public int getStatusCode()
Returns the HTTP status code.- Returns:
- The status code.
-
-