com.sun.n1.sps.model.util
Class ClientException

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by com.sun.n1.sps.model.util.ClientException
All Implemented Interfaces:
java.io.Serializable
Direct Known Subclasses:
AuthenticationException, CommandException, ConfigurationException, ConversionException, IllegalArgumentsException, NetworkException

public class ClientException
extends java.lang.Exception

This is the base class for several public-api client exceptions. As a design goal, this class localizes all messages in the causal chain at the point of construction, and does not store SPS classes. This is to allow the serialization of this class to environments where the supporting SPS localization software may not be present.

See Also:
Serialized Form

Constructor Summary
ClientException(java.lang.String inMessage)
          Constructs a new exception with the specified detail message.
ClientException(java.lang.String inMessage, java.lang.Throwable inCause)
          Constructs a new exception with the specified detail message and cause.
ClientException(java.lang.Throwable inCause)
          Constructs a new exception with the specified cause.
 
Method Summary
 void printStackTrace(java.io.PrintStream s)
          Prints this throwable and its backtrace to the specified print stream.
 void printStackTrace(java.io.PrintWriter s)
          Prints this throwable and its backtrace to the specified print writer.
static ClientException wrap(java.lang.Throwable inThrowable)
          Returns a ClientException, wrapping any other throwable exception, if inThrowable is not an instance of inThrowable, and inThrowable otherwise.
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, setStackTrace, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ClientException

public ClientException(java.lang.Throwable inCause)
Constructs a new exception with the specified cause.

Parameters:
inCause - - the specified cause.

ClientException

public ClientException(java.lang.String inMessage,
                       java.lang.Throwable inCause)
Constructs a new exception with the specified detail message and cause.

Parameters:
inMessage - - thr etail messag
inCause - - the cause

ClientException

public ClientException(java.lang.String inMessage)
Constructs a new exception with the specified detail message.

Parameters:
inMessage - - te detail message
Method Detail

printStackTrace

public void printStackTrace(java.io.PrintWriter s)
Prints this throwable and its backtrace to the specified print writer.

Overrides:
printStackTrace in class java.lang.Throwable
Parameters:
s - PrintWriter to use for output

printStackTrace

public void printStackTrace(java.io.PrintStream s)
Prints this throwable and its backtrace to the specified print stream.

Overrides:
printStackTrace in class java.lang.Throwable
Parameters:
s - PrintStream to use for output

wrap

public static ClientException wrap(java.lang.Throwable inThrowable)
Returns a ClientException, wrapping any other throwable exception, if inThrowable is not an instance of inThrowable, and inThrowable otherwise.

Parameters:
inThrowable - - Throwable
Returns:
ClientException, wrapping any other throwable exception.