com.caucho.ejb
Class EJBExceptionWrapper

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by java.lang.RuntimeException
              extended by javax.ejb.EJBException
                  extended by com.caucho.ejb.EJBExceptionWrapper
All Implemented Interfaces:
java.io.Serializable

public class EJBExceptionWrapper
extends EJBException

Wraps the actual exception with an EJB exception

See Also:
Serialized Form

Constructor Summary
EJBExceptionWrapper()
          Null constructor for beans
EJBExceptionWrapper(java.lang.String msg)
          Create a basic EJBExceptionWrapper with a message.
EJBExceptionWrapper(java.lang.String msg, java.lang.Throwable rootCause)
          Create a EJBExceptionWrapper wrapping a root exception.
EJBExceptionWrapper(java.lang.Throwable rootCause)
          Create a EJBExceptionWrapper wrapping a root exception.
 
Method Summary
static EJBException create(java.lang.Throwable exn)
          Creates an EJBException from a throwable.
static java.lang.RuntimeException createRuntime(java.lang.Throwable rootCause)
          Creates a runtime from a throwable.
 java.lang.Throwable getCause()
           
 
Methods inherited from class javax.ejb.EJBException
getCausedByException
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

EJBExceptionWrapper

public EJBExceptionWrapper()
Null constructor for beans


EJBExceptionWrapper

public EJBExceptionWrapper(java.lang.String msg)
Create a basic EJBExceptionWrapper with a message.

Parameters:
msg - the exception message.

EJBExceptionWrapper

public EJBExceptionWrapper(java.lang.Throwable rootCause)
Create a EJBExceptionWrapper wrapping a root exception.

Parameters:
rootCause - the underlying wrapped exception.

EJBExceptionWrapper

public EJBExceptionWrapper(java.lang.String msg,
                           java.lang.Throwable rootCause)
Create a EJBExceptionWrapper wrapping a root exception.

Parameters:
rootCause - the underlying wrapped exception.
Method Detail

getCause

public java.lang.Throwable getCause()
Overrides:
getCause in class java.lang.Throwable

create

public static EJBException create(java.lang.Throwable exn)
Creates an EJBException from a throwable.


createRuntime

public static java.lang.RuntimeException createRuntime(java.lang.Throwable rootCause)
Creates a runtime from a throwable.