Interface DBModelErrorHandler

All Known Implementing Classes:
DBModelErrorLogger

public interface DBModelErrorHandler
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    columnNullableMismatch(DBColumn col, boolean nullable)
    This method is called when a NOT NULL constraints of a column in the Empire-db definition does not match the database.
    void
    columnSizeMismatch(DBColumn col, int size, int scale)
    This method is called when the size of a column in the Empire-db definition does not match the database.
    void
    This method is called when the type of a column in the Empire-db definition does not match the database.
    void
    This method is called when an object (e. g. table or column) is missing in the database.
    void
    objectTypeMismatch(DBObject object, String name, Class<?> expectedType)
    This method is called when an object (e. g. table or column) is missing in the database.
    void
    This method is called when a column in a primary key of the Empire-db definition is missing in the database
    void
    primaryKeyMismatch(DBIndex primaryKey, DBColumn[] tableKey)
    This method is called when the primary key of the Empire-db definition does not match the primary key of the existing table
  • Method Details

    • itemNotFound

      void itemNotFound(DBObject dbo)
      This method is called when an object (e. g. table or column) is missing in the database.
      Parameters:
      dbo - The missing object
    • objectTypeMismatch

      void objectTypeMismatch(DBObject object, String name, Class<?> expectedType)
      This method is called when an object (e. g. table or column) is missing in the database.
      Parameters:
      object - the missing object
      name - the name of the object
      expectedType - the expected type
    • primaryKeyColumnMissing

      void primaryKeyColumnMissing(DBIndex primaryKey, DBColumn column)
      This method is called when a column in a primary key of the Empire-db definition is missing in the database
      Parameters:
      primaryKey - The primary key that misses the column
      column - The missing column
    • primaryKeyMismatch

      void primaryKeyMismatch(DBIndex primaryKey, DBColumn[] tableKey)
      This method is called when the primary key of the Empire-db definition does not match the primary key of the existing table
      Parameters:
      primaryKey - The index key
      tableKey - The referenced table key
    • columnTypeMismatch

      void columnTypeMismatch(DBColumn col, DataType type)
      This method is called when the type of a column in the Empire-db definition does not match the database.
      Parameters:
      col - The affected column
      type -
    • columnSizeMismatch

      void columnSizeMismatch(DBColumn col, int size, int scale)
      This method is called when the size of a column in the Empire-db definition does not match the database.
      Parameters:
      col - The affected column
      size - Size in the database
      scale - Decimal scale in the database (only for decimal types, 0 otherwise)
    • columnNullableMismatch

      void columnNullableMismatch(DBColumn col, boolean nullable)
      This method is called when a NOT NULL constraints of a column in the Empire-db definition does not match the database.
      Parameters:
      col - The affected column
      nullable - true if the column is required in the database