public class ApplicationError
extends java.lang.Object
implements java.io.Serializable
Modifier and Type | Field and Description |
---|---|
static short | TYPE_GENERIC_ERROR
The client error type to indicate a generic error.
|
static short | TYPE_INVALID_PARAMETER_VALUE
The client error type to indicate an invalid parameter value.
|
static short | TYPE_MALFORMED_REQUEST
The client error type to indicate the request was improperly formed.
|
static short | TYPE_MISSING_PARAMETER
The client error type to indicate a missing parameter.
|
static short | TYPE_PARAMETER_VALUE_NOT_NUMERIC
The client error type to indicate the parameter is not a numeric.
|
Constructor and Description |
---|
ApplicationError()
Creates an instance of the client error object.
|
ApplicationError(short type, java.lang.String errorKey, java.lang.Object[] errorParameters, java.lang.String resourceBundleName)
Creates an instance of the client error object.
|
ApplicationError(short type, java.lang.String errorKey, java.lang.String localizedMessage, java.lang.Object[] errorParameters, java.lang.String resourceBundleName, java.lang.String errorCode)
Creates an instance of the client error object.
|
Modifier and Type | Method and Description |
---|---|
java.lang.String | getErrorCode()
This method returns the error code
|
java.lang.String | getErrorKey()
This method returns the error key associated with the client error.
|
java.lang.Object[] | getErrorParameters()
This method returns the error parameter to be used to help quantify the client error.
|
java.util.Locale | getLocale()
This method returns the locale used by the getLocalizedMessage method.
|
java.lang.String | getLocalizedMessage()
This method returns the localized message of the client error.
|
java.lang.String | getLocalizedMessage(java.util.Locale locale)
This method returns the localized message of the client error.
|
short | getType()
This method returns the type of the parameter error.
|
void | setErrorCode(java.lang.String astrErrorCode)
This method sets error code.
|
void | setErrorKey(java.lang.String errorKey)
This method sets the error key of the client error.
|
void | setErrorParameters(java.lang.Object[] errorParameters)
This method sets the parameter errors.
|
void | setLocale(java.util.Locale locale)
This method sets the locale used by the getLocalizedMessage method.
|
void | setLocalizedMessage(java.lang.String aLocalizedMessage)
This method set the localized message of the client error.
|
void | setType(short type)
This method sets the type of the client error.
|
java.lang.String | toString()
This method returns a short description of this error.
|
public static final short TYPE_GENERIC_ERROR
public static final short TYPE_MISSING_PARAMETER
public static final short TYPE_INVALID_PARAMETER_VALUE
public static final short TYPE_PARAMETER_VALUE_NOT_NUMERIC
public static final short TYPE_MALFORMED_REQUEST
public ApplicationError()
public ApplicationError(short type, java.lang.String errorKey, java.lang.Object[] errorParameters, java.lang.String resourceBundleName)
public ApplicationError(short type, java.lang.String errorKey, java.lang.String localizedMessage, java.lang.Object[] errorParameters, java.lang.String resourceBundleName, java.lang.String errorCode)
public short getType()
public void setType(short type)
public java.lang.String getErrorKey()
public void setErrorKey(java.lang.String errorKey)
public java.lang.Object[] getErrorParameters()
public void setErrorParameters(java.lang.Object[] errorParameters)
public java.util.Locale getLocale()
public void setLocale(java.util.Locale locale)
public void setLocalizedMessage(java.lang.String aLocalizedMessage)
public java.lang.String getLocalizedMessage()
public java.lang.String getLocalizedMessage(java.util.Locale locale)
public java.lang.String getErrorCode()
public void setErrorCode(java.lang.String astrErrorCode)
public java.lang.String toString()