com.sap.tc.mobile.exception.standard
Class SAPIllegalArgumentException

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by java.lang.RuntimeException
              extended by java.lang.IllegalArgumentException
                  extended by com.sap.tc.mobile.exception.standard.SAPIllegalArgumentException
All Implemented Interfaces:
IBaseException, java.io.Serializable

public class SAPIllegalArgumentException
extends java.lang.IllegalArgumentException
implements IBaseException

Wrapper class for IllegalArgumentException.

See Also:
Serialized Form

Field Summary
static MsgObject NOT_SERIALIZABLE
          Not able to serialize field of type {0}.
static MsgObject PARAMETER_FORBIDDEN_CHARACTER
          The parameter {0} has the value {1}, and it contains the character {2} which is not allowed.
static MsgObject PARAMETER_LENGTH_TOO_HIGH
          The length of parameter {0} is {1} characters, but allowed maximum is {2} characters (value {3}).
static MsgObject PARAMETER_LENGTH_TOO_LOW
          The length of parameter {0} is {1} characters, but allowed minimum is {2} characters (value {3}).
static MsgObject PARAMETER_MALFORMED
          Argument {0} (Type {1}) is malformed.
static MsgObject PARAMETER_NULL
          Parameter {0} must not be null.
static MsgObject PARAMETER_OUT_OF_RANGE
          The parameter {0} has the value {1}, but this is not part of the allowed values {2}.
static MsgObject PARAMETER_TOO_HIGH
          The value of parameter {0} is {1}, but maximum is {2}.
static MsgObject PARAMETER_TOO_LOW
          The value of parameter {0} is {1}, but minimum is {2}.
static MsgObject PARAMETER_TOO_MANY
          Too many arguments.
static MsgObject PARAMETER_WRONG_TYPE
          Type {1} of argument {0} is wrong.
static MsgObject PROPERTY_FORBIDDEN_CHARACTER
          The property {0} has the value {1}, and it contains the character {2} which is not allowed.
static MsgObject PROPERTY_LENGTH_TOO_HIGH
          The length of property {0} is {1} characters, but allowed maximum is {2} characters (value {3}).
static MsgObject PROPERTY_LENGTH_TOO_LOW
          The length of property {0} is {1} characters, but allowed minimum is {2} characters (value {3}).
static MsgObject PROPERTY_NOT_EXISTENT
          The property {0} does not exist.
static MsgObject PROPERTY_OUT_OF_RANGE
          The property {0} has the value {1}, but this is not part of the allowed values {2}.
static MsgObject PROPERTY_TOO_HIGH
          The value of property {0} is {1}, but maximum is {2}.
static MsgObject PROPERTY_TOO_LOW
          The value of property {0} is {1}, but minimum is {2}.
 
Fields inherited from interface com.sap.tc.mobile.exception.IBaseException
audit
 
Constructor Summary
SAPIllegalArgumentException(Location loc, MsgObject msgObject)
          Constructs an exception with the specified root cause, which caused this exception.
SAPIllegalArgumentException(Location loc, MsgObject msgObject, java.lang.Object[] args)
          Constructs an exception with the specified root cause, which caused this exception.
SAPIllegalArgumentException(Location loc, MsgObject msgObject, java.lang.Object[] args, java.lang.Throwable rootCause)
          Constructs an exception with the specified root cause, which caused this exception.
 
Method Summary
 java.lang.Throwable getCause()
          Getter method for root cause.
 java.lang.String getLocalizedMessage()
          Gets localized message.
 Location getLogLocation()
          Getter method for logging location.
 java.lang.String getMessage()
           
 java.lang.String getNestedLocalizedMessage()
          Chains localized messages of the nested exceptions.
 java.lang.String getNestedStackTraceString()
          Chains the stack trace information of nested exceptions.
 java.lang.String getStackTraceString()
          Gets stack trace information of this exception only.
 java.lang.String getSystemStackTraceString()
          Gets the stack information of this exception in respect of the current system environment.
 java.lang.Throwable initCause(java.lang.Throwable cause)
          Initializes the cause of this exception to the specified value.
 void printStackTrace()
          Prints this exception and its backtrace to the standard error stream.
 void printStackTrace(java.io.PrintStream s)
          Prints this exception and its backtrace to the specified print stream.
 void printStackTrace(java.io.PrintWriter s)
          Prints the action object and its backtrace to the specified print writer.
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getStackTrace, setStackTrace, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

PARAMETER_NULL

public static final MsgObject PARAMETER_NULL
Parameter {0} must not be null.


PARAMETER_TOO_LOW

public static final MsgObject PARAMETER_TOO_LOW
The value of parameter {0} is {1}, but minimum is {2}.


PARAMETER_TOO_HIGH

public static final MsgObject PARAMETER_TOO_HIGH
The value of parameter {0} is {1}, but maximum is {2}.


PARAMETER_LENGTH_TOO_LOW

public static final MsgObject PARAMETER_LENGTH_TOO_LOW
The length of parameter {0} is {1} characters, but allowed minimum is {2} characters (value {3}).


PARAMETER_LENGTH_TOO_HIGH

public static final MsgObject PARAMETER_LENGTH_TOO_HIGH
The length of parameter {0} is {1} characters, but allowed maximum is {2} characters (value {3}).


PARAMETER_FORBIDDEN_CHARACTER

public static final MsgObject PARAMETER_FORBIDDEN_CHARACTER
The parameter {0} has the value {1}, and it contains the character {2} which is not allowed.


PARAMETER_OUT_OF_RANGE

public static final MsgObject PARAMETER_OUT_OF_RANGE
The parameter {0} has the value {1}, but this is not part of the allowed values {2}.


PARAMETER_TOO_MANY

public static final MsgObject PARAMETER_TOO_MANY
Too many arguments.


PARAMETER_WRONG_TYPE

public static final MsgObject PARAMETER_WRONG_TYPE
Type {1} of argument {0} is wrong. (Note: order of arguments)


PARAMETER_MALFORMED

public static final MsgObject PARAMETER_MALFORMED
Argument {0} (Type {1}) is malformed.


PROPERTY_NOT_EXISTENT

public static final MsgObject PROPERTY_NOT_EXISTENT
The property {0} does not exist.


PROPERTY_TOO_LOW

public static final MsgObject PROPERTY_TOO_LOW
The value of property {0} is {1}, but minimum is {2}.


PROPERTY_TOO_HIGH

public static final MsgObject PROPERTY_TOO_HIGH
The value of property {0} is {1}, but maximum is {2}.


PROPERTY_LENGTH_TOO_LOW

public static final MsgObject PROPERTY_LENGTH_TOO_LOW
The length of property {0} is {1} characters, but allowed minimum is {2} characters (value {3}).


PROPERTY_LENGTH_TOO_HIGH

public static final MsgObject PROPERTY_LENGTH_TOO_HIGH
The length of property {0} is {1} characters, but allowed maximum is {2} characters (value {3}).


PROPERTY_FORBIDDEN_CHARACTER

public static final MsgObject PROPERTY_FORBIDDEN_CHARACTER
The property {0} has the value {1}, and it contains the character {2} which is not allowed.


PROPERTY_OUT_OF_RANGE

public static final MsgObject PROPERTY_OUT_OF_RANGE
The property {0} has the value {1}, but this is not part of the allowed values {2}.


NOT_SERIALIZABLE

public static final MsgObject NOT_SERIALIZABLE
Not able to serialize field of type {0}.

Constructor Detail

SAPIllegalArgumentException

public SAPIllegalArgumentException(Location loc,
                                   MsgObject msgObject)
Constructs an exception with the specified root cause, which caused this exception.

Parameters:
loc - logging location which will be used in case of automatic tracing logging location.
msgObject - message object.

SAPIllegalArgumentException

public SAPIllegalArgumentException(Location loc,
                                   MsgObject msgObject,
                                   java.lang.Object[] args)
Constructs an exception with the specified root cause, which caused this exception.

Parameters:
loc - logging location which will be used in case of automatic tracing logging location.
msgObject - message object.
args - arguments for message.

SAPIllegalArgumentException

public SAPIllegalArgumentException(Location loc,
                                   MsgObject msgObject,
                                   java.lang.Object[] args,
                                   java.lang.Throwable rootCause)
Constructs an exception with the specified root cause, which caused this exception.

Parameters:
loc - logging location which will be used in case of automatic tracing logging location.
msgObject - message object.
args - arguments for message.
rootCause - throwable object which caused this exception.
Method Detail

initCause

public java.lang.Throwable initCause(java.lang.Throwable cause)
Description copied from interface: IBaseException
Initializes the cause of this exception to the specified value. (The cause is the throwable that caused this exception to get thrown.)

This method can be called at most once. That means the cause can be specified only once.

Specified by:
initCause in interface IBaseException
Overrides:
initCause in class java.lang.Throwable
Parameters:
cause - the cause (which is saved for later retrieval by the IBaseException.getCause() method). (A null value is permitted, and indicates that the cause is nonexistent or unknown.)
Returns:
a reference to this exception instance.
See Also:
IBaseException.initCause(Throwable)

getCause

public java.lang.Throwable getCause()
Description copied from interface: IBaseException
Getter method for root cause.

Specified by:
getCause in interface IBaseException
Overrides:
getCause in class java.lang.Throwable
Returns:
throwable object which caused this exception or null
See Also:
IBaseException.getCause()

getLocalizedMessage

public java.lang.String getLocalizedMessage()
Description copied from interface: IBaseException
Gets localized message.

The default locale and default time zone are used for localization.

These values have no effect if the finallyLocalize method has already been called.

Specified by:
getLocalizedMessage in interface IBaseException
Overrides:
getLocalizedMessage in class java.lang.Throwable
Returns:
message string or null
See Also:
IBaseException.getLocalizedMessage()

getNestedLocalizedMessage

public java.lang.String getNestedLocalizedMessage()
Description copied from interface: IBaseException
Chains localized messages of the nested exceptions.

The default locale and the default time zone are used for localization.

These values have no effect if the finallyLocalize method has already been called.

Specified by:
getNestedLocalizedMessage in interface IBaseException
Returns:
message string or null
See Also:
IBaseException.getNestedLocalizedMessage()

getSystemStackTraceString

public java.lang.String getSystemStackTraceString()
Gets the stack information of this exception in respect of the current system environment.

Specified by:
getSystemStackTraceString in interface IBaseException
Returns:
the stack trace as a string in respect of the current system
See Also:
IBaseException.getSystemStackTraceString()

getStackTraceString

public java.lang.String getStackTraceString()
Description copied from interface: IBaseException
Gets stack trace information of this exception only.

The stack traces of nested exceptions are not chained.

Specified by:
getStackTraceString in interface IBaseException
Returns:
the stack trace as a string without information of chained exceptions.
See Also:
IBaseException.getStackTraceString()

getNestedStackTraceString

public java.lang.String getNestedStackTraceString()
Description copied from interface: IBaseException
Chains the stack trace information of nested exceptions.

The caused stack trace is displayed first.

Specified by:
getNestedStackTraceString in interface IBaseException
Returns:
the stack trace as a string
See Also:
IBaseException.getNestedStackTraceString()

printStackTrace

public void printStackTrace()
Description copied from interface: IBaseException
Prints this exception and its backtrace to the standard error stream. This method prints a stack trace for this exception object on the error output stream that is the value of the field System.err.

Specified by:
printStackTrace in interface IBaseException
Overrides:
printStackTrace in class java.lang.Throwable
See Also:
IBaseException.printStackTrace()

printStackTrace

public void printStackTrace(java.io.PrintStream s)
Description copied from interface: IBaseException
Prints this exception and its backtrace to the specified print stream.

Specified by:
printStackTrace in interface IBaseException
Overrides:
printStackTrace in class java.lang.Throwable
Parameters:
s - PrintStream to use for output
See Also:
IBaseException.printStackTrace(PrintStream)

printStackTrace

public void printStackTrace(java.io.PrintWriter s)
Description copied from interface: IBaseException
Prints the action object and its backtrace to the specified print writer.

Specified by:
printStackTrace in interface IBaseException
Overrides:
printStackTrace in class java.lang.Throwable
Parameters:
s - PrintWriter to use for output
See Also:
IBaseException.printStackTrace(PrintWriter)

getMessage

public java.lang.String getMessage()
Overrides:
getMessage in class java.lang.Throwable
See Also:
getLocalizedMessage()

getLogLocation

public Location getLogLocation()
Getter method for logging location.

If no location is specified, null is returned.

Returns:
logging location