Package xal.tools.database
Class DatabaseException
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
xal.tools.database.DatabaseException
- All Implemented Interfaces:
Serializable
DatabaseException wraps SQLException exceptions thrown while interacting with
the database Eventually this class will provide a common interpretation of
SQLException codes regardless of the database source.
- Author:
- tap
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionDatabaseException
(String message, DatabaseAdaptor adaptor, SQLException cause) Constructor to wrap an SQLException -
Method Summary
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Constructor Details
-
DatabaseException
Constructor to wrap an SQLException- Parameters:
message
- The exception messageadaptor
- The database adaptor to use to interpret the SQLExceptioncause
- The cause of the exception
-
-
Method Details
-
getRawErrorCode
public int getRawErrorCode()Get the database specific error code.- Returns:
- the error code of the SQLException which is the cause of this database exception
-