org.jminor.common.db.exception
Class DatabaseException
java.lang.Object
java.lang.Throwable
java.lang.Exception
org.jminor.common.db.exception.DatabaseException
- All Implemented Interfaces:
- Serializable
- Direct Known Subclasses:
- RecordModifiedException, RecordNotFoundException
public class DatabaseException
- extends Exception
An exception coming from a database-layer.
- See Also:
- Serialized Form
Methods inherited from class java.lang.Throwable |
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString |
DatabaseException
public DatabaseException(String message)
- Constructs a new DatabaseException instance
- Parameters:
message
- the exception message
DatabaseException
public DatabaseException(String message,
String statement)
- Constructs a new DatabaseException instance
- Parameters:
message
- the exception messagestatement
- the sql statement which caused the exception
DatabaseException
public DatabaseException(SQLException cause,
String statement,
String message)
- Constructs a new DatabaseException instance
- Parameters:
cause
- the cause of the exceptionstatement
- the sql statement which caused the exceptionmessage
- the exception message
getStatement
public final String getStatement()
- Returns:
- the sql query which caused the exception