Class CADatabaseExceptions

java.lang.Object
com.io7m.cardant.database.postgres.internal.CADatabaseExceptions

public final class CADatabaseExceptions extends Object
Functions to handle database exceptions.
  • Method Details

    • handleDatabaseException

      @SafeVarargs public static CADatabaseException handleDatabaseException(com.io7m.cardant.database.postgres.internal.CADatabaseTransaction transaction, org.jooq.exception.DataAccessException e, Map.Entry<String,String>... attributes)
      Handle a data access exception.
      Parameters:
      transaction - The transaction
      e - The exception
      attributes - The attributes
      Returns:
      The resulting exception
    • handleDatabaseException

      public static CADatabaseException handleDatabaseException(com.io7m.cardant.database.postgres.internal.CADatabaseTransaction transaction, org.jooq.exception.DataAccessException e, SortedMap<String,String> attributes)
      Handle a data access exception.
      Parameters:
      transaction - The transaction
      e - The exception
      attributes - The attributes
      Returns:
      The resulting exception