Package com.pyranid

Class DatabaseException

All Implemented Interfaces:
Serializable

@NotThreadSafe public class DatabaseException extends RuntimeException
Thrown when an error occurs when interacting with a Database.

If the cause of this exception is a SQLException, the getErrorCode() and getSqlState() accessors are shorthand for retrieving the corresponding SQLException values.

Since:
1.0.0
Author:
Mark Allen
See Also:
  • Constructor Details

    • DatabaseException

      public DatabaseException(@Nullable String message)
      Creates a DatabaseException with the given message.
      Parameters:
      message - a message describing this exception
    • DatabaseException

      public DatabaseException(@Nullable Throwable cause)
      Creates a DatabaseException which wraps the given cause.
      Parameters:
      cause - the cause of this exception
    • DatabaseException

      public DatabaseException(@Nullable String message, @Nullable Throwable cause)
      Creates a DatabaseException which wraps the given cause.
      Parameters:
      message - a message describing this exception
      cause - the cause of this exception
  • Method Details