org.apache.commons.httpclient
public class URIException extends HttpException
| Modifier and Type | Field and Description |
|---|---|
static int |
ESCAPING
The URI escape encoding and decoding error.
|
static int |
PARSING
The URI parsing error.
|
static int |
PUNYCODE
The DNS punycode encoding or decoding error.
|
protected java.lang.String |
reason
The reason message.
|
protected int |
reasonCode
The reason code.
|
static int |
UNKNOWN
No specified reason code.
|
static int |
UNSUPPORTED_ENCODING
The unsupported character encoding.
|
| Constructor and Description |
|---|
URIException()
Default constructor.
|
URIException(int reasonCode)
The constructor with a reason code argument.
|
URIException(int reasonCode,
java.lang.String reason)
The constructor with a reason string and its code arguments.
|
URIException(java.lang.String reason)
The constructor with a reason string argument.
|
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
getReason()
Deprecated.
You should instead call
Throwable.getMessage(). |
int |
getReasonCode()
Get the reason code.
|
void |
setReason(java.lang.String reason)
Deprecated.
Callers should instead set this via a parameter to the constructor.
|
void |
setReasonCode(int reasonCode)
Deprecated.
Callers should set the reason code as a parameter to the
constructor.
|
getCause, printStackTrace, printStackTrace, printStackTracepublic static final int UNKNOWN
public static final int PARSING
public static final int UNSUPPORTED_ENCODING
public static final int ESCAPING
public static final int PUNYCODE
protected int reasonCode
protected java.lang.String reason
public URIException()
public URIException(int reasonCode)
reasonCode - the reason codepublic URIException(int reasonCode,
java.lang.String reason)
reasonCode - the reason codereason - the reasonpublic URIException(java.lang.String reason)
reason - the reasonpublic int getReasonCode()
getReasonCode in class HttpExceptionpublic void setReasonCode(int reasonCode)
setReasonCode in class HttpExceptionreasonCode - the reason codepublic java.lang.String getReason()
Throwable.getMessage().getReason in class HttpExceptionpublic void setReason(java.lang.String reason)
setReason in class HttpExceptionreason - the reason message