org.apache.commons.httpclient

Class URIException

public class URIException extends HttpException

The URI parsing and escape encoding exception.

Version: $Revision: 480424 $ $Date: 2002/03/14 15:14:01

Author: Sung-Gu Oleg Kalnichevski

Field Summary
static intESCAPING
The URI escape encoding and decoding error.
static intPARSING
The URI parsing error.
static intPUNYCODE
The DNS punycode encoding or decoding error.
protected Stringreason
The reason message.
protected intreasonCode
The reason code.
static intUNKNOWN
No specified reason code.
static intUNSUPPORTED_ENCODING
The unsupported character encoding.
Constructor Summary
URIException()
Default constructor.
URIException(int reasonCode)
The constructor with a reason code argument.
URIException(int reasonCode, String reason)
The constructor with a reason string and its code arguments.
URIException(String reason)
The constructor with a reason string argument.
Method Summary
StringgetReason()
Get the reason message.
intgetReasonCode()
Get the reason code.
voidsetReason(String reason)
Set the reason message.
voidsetReasonCode(int reasonCode)
Set the reason code.

Field Detail

ESCAPING

public static final int ESCAPING
The URI escape encoding and decoding error.

PARSING

public static final int PARSING
The URI parsing error.

PUNYCODE

public static final int PUNYCODE
The DNS punycode encoding or decoding error.

reason

protected String reason
The reason message.

reasonCode

protected int reasonCode
The reason code.

UNKNOWN

public static final int UNKNOWN
No specified reason code.

UNSUPPORTED_ENCODING

public static final int UNSUPPORTED_ENCODING
The unsupported character encoding.

Constructor Detail

URIException

public URIException()
Default constructor.

URIException

public URIException(int reasonCode)
The constructor with a reason code argument.

Parameters: reasonCode the reason code

URIException

public URIException(int reasonCode, String reason)
The constructor with a reason string and its code arguments.

Parameters: reasonCode the reason code reason the reason

URIException

public URIException(String reason)
The constructor with a reason string argument.

Parameters: reason the reason

Method Detail

getReason

public String getReason()

Deprecated: You should instead call URIException.

Get the reason message.

Returns: the reason message

getReasonCode

public int getReasonCode()
Get the reason code.

Returns: the reason code

setReason

public void setReason(String reason)

Deprecated: Callers should instead set this via a parameter to the constructor.

Set the reason message.

Parameters: reason the reason message

setReasonCode

public void setReasonCode(int reasonCode)

Deprecated: Callers should set the reason code as a parameter to the constructor.

Set the reason code.

Parameters: reasonCode the reason code

Copyright (c) 1999-2005 - Apache Software Foundation