codesimian
Class CSCastException

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by java.lang.RuntimeException
              extended by codesimian.CSCastException
All Implemented Interfaces:
java.io.Serializable

public class CSCastException
extends java.lang.RuntimeException

CSCastException is thrown by CS objects when CS.L(Class) or CS.LForProxy(Class) can not cast the CS to the specified Class type.

See Also:
Serialized Form

Field Summary
 CS couldNotCastMe
           
 java.lang.Class couldNotCastToThisType
          The thrower of this CSCastException could not cast a CS to some Class type.
 java.lang.String message
           
 
Constructor Summary
CSCastException()
          couldNotCastToThisType is set to null.
CSCastException(java.lang.Class couldNotCastToThisType)
          Constructs a CSCastException with no detail message.
CSCastException(java.lang.Class couldNotCastToThisType, java.lang.String s)
          Constructs a CSCastException with the specified detail message.
CSCastException(CS couldNotCastMe, java.lang.Class couldNotCastToThisType)
          also remembers the CS that could not be cast to the Class type
CSCastException(CS couldNotCastMe, java.lang.Class couldNotCastToThisType, java.lang.String s)
          also remembers the CS that could not be cast to the Class type
CSCastException(java.lang.String s)
          couldNotCastToThisType is set to null.
 
Method Summary
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

couldNotCastMe

public final CS couldNotCastMe

couldNotCastToThisType

public final java.lang.Class couldNotCastToThisType
The thrower of this CSCastException could not cast a CS to some Class type. This is that Class type.


message

public final java.lang.String message
Constructor Detail

CSCastException

public CSCastException()
couldNotCastToThisType is set to null. "By convention, class Throwable and its subclasses have two constructors, one that takes no arguments and one that takes a String argument that can be used to produce an error message."


CSCastException

public CSCastException(java.lang.String s)
couldNotCastToThisType is set to null. "By convention, class Throwable and its subclasses have two constructors, one that takes no arguments and one that takes a String argument that can be used to produce an error message."


CSCastException

public CSCastException(java.lang.Class couldNotCastToThisType)
Constructs a CSCastException with no detail message.


CSCastException

public CSCastException(java.lang.Class couldNotCastToThisType,
                       java.lang.String s)
Constructs a CSCastException with the specified detail message.


CSCastException

public CSCastException(CS couldNotCastMe,
                       java.lang.Class couldNotCastToThisType)
also remembers the CS that could not be cast to the Class type


CSCastException

public CSCastException(CS couldNotCastMe,
                       java.lang.Class couldNotCastToThisType,
                       java.lang.String s)
also remembers the CS that could not be cast to the Class type

Method Detail

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Throwable