com.croftsoft.core.lang
Class ExternalAccessException
java.lang.Object
java.lang.Throwable
java.lang.Exception
com.croftsoft.core.lang.ExternalAccessException
- All Implemented Interfaces:
- Serializable
public final class ExternalAccessException
- extends Exception
Indicates an Exception while accessing an external resource.
Useful for propagating an SQLException or RemoteException through
a Data Access Object (DAO) interface. Define the data accessor
interface methods so that they throw ExternalAccessException instead
of SQLException, RemoteException, IOException, or any other
Exception indicating external access failure. Since the calling
application no longer needs to be hard-coded to handle an Exception
subclass specific to the data access mechanism, the mechanism can be
easily replaced, at run-time if desired, simply by instantiating a
different concrete implementation of the data accessor interface.
The original Exception is passed into the ExternalAccessException as
a constructor argument. The Exception stack trace is stored as a
String within the ExternalAccessException in order to facilitate
serialization and persistence without the need to transport class
files.
- Since:
- 2001-02-28
- Version:
- 2001-06-21
- See Also:
-
Sun Java Center J2EE Patterns: Data Access Object,
"A Note on Distributed Computing",
Serialized Form
- Author:
- David W. Croft
Methods inherited from class java.lang.Throwable |
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString |
ExternalAccessException
public ExternalAccessException(String message,
Exception rootException)
ExternalAccessException
public ExternalAccessException(Exception rootException)
ExternalAccessException
public ExternalAccessException(String message)
ExternalAccessException
public ExternalAccessException()
getRootExceptionStackTrace
public String getRootExceptionStackTrace()
CroftSoft Core Javadoc (2008-09-28 20:58:02)