Interface DdlVersionable

All Known Implementing Classes:
GrouperDdl, GrouperMidpointDdl, GrouperMockDdl, GrouperOrgDdl, GrouperTestDdl, SubjectDdl

public interface DdlVersionable
enums which are ddl version need to implement this interface
  • Method Details

    • requiresEmptyChangelog

      boolean requiresEmptyChangelog()
      if this version requires an empty changelog
      Returns:
      true if so
    • getGrouperVersion

      String getGrouperVersion()
      get grouper version e.g. x.y.z
      Returns:
      grouper version
    • addAllForeignKeysViewsEtc

      void addAllForeignKeysViewsEtc(DdlVersionBean ddlVersionBean)
      add all foreign keys, views, table / col comments, etc
      Parameters:
      ddlVersionBean -
    • dropAllViews

      void dropAllViews(DdlVersionBean ddlVersionBean)
      drop all views at the beginning of the script...
      Parameters:
      ddlVersionBean -
    • getVersion

      int getVersion()
      get the version of this enum
      Returns:
      the version
    • getObjectName

      String getObjectName()
      get the object name of this enum, e.g. if GrouperEnum, the object name is Grouper
      Returns:
      the object name
    • getDefaultTablePattern

      String getDefaultTablePattern()
       get the table pattern for this dbname (would be nice if there were no overlap,
       so ext's should not start with grouper, e.g. grouploader_
       note that underscore is a wildcard which is unfortunate
      Returns:
      the table patter, e.g. "GROUPER%"
    • getSampleTablenames

      String[] getSampleTablenames()
      an example table name so we can hone in on the exact metadata
      Returns:
      the table name
    • updateVersionFromPrevious

      void updateVersionFromPrevious(Database database, DdlVersionBean ddlVersionBean)
      check to see if the changes are already made, and then add the changes to the database object that should be used to update from the previous version
      Parameters:
      database - ddlutils database object
      ddlVersionBean - has references to stuff you need
    • recreateViewsAndForeignKeys

      boolean recreateViewsAndForeignKeys()
      Returns:
      true if the update requires views/keys to be recreated