Class DdlVersionBean

java.lang.Object
edu.internet2.middleware.grouper.ddl.DdlVersionBean

public class DdlVersionBean extends Object
bean to pass to versions to update stuff
  • Constructor Details

    • DdlVersionBean

      public DdlVersionBean(String objectName, Platform platform, Connection connection, String schema, SqlBuilder sqlBuilder, Database oldDatabase, Database database, StringBuilder additionalScripts, boolean isDestinationVersion, int buildingToVersion, StringBuilder fullScript, int theBuildingFromVersion)
      construct
      Parameters:
      objectName -
      platform -
      connection -
      schema -
      sqlBuilder -
      oldDatabase -
      database -
      additionalScripts -
      isDestinationVersion -
      buildingToVersion -
      fullScript -
  • Method Details

    • getGrouperDdlCompareResult

      public GrouperDdlCompareResult getGrouperDdlCompareResult()
      Returns:
    • setGrouperDdlCompareResult

      public void setGrouperDdlCompareResult(GrouperDdlCompareResult grouperDdlCompareResult)
      Parameters:
      grouperDdlCompareResult -
    • resetAlreadyDone

      public void resetAlreadyDone()
      if starting over, reset this
    • didWeDoThis

      public boolean didWeDoThis(String label, boolean addAsDoing)
      see if we already did this
      Parameters:
      label -
      addAsDoing - true if we should add that we are doing this now
      Returns:
      true if already done
    • isPostgres

      public boolean isPostgres()
      Returns:
      true if postgres
    • isMysql

      public boolean isMysql()
      Returns:
      true if mysql
    • isSmallIndexes

      public boolean isSmallIndexes()
      if small indexes
      Returns:
      true if small indexes
    • isOracle

      public boolean isOracle()
      Returns:
      true if postgres
    • appendAdditionalScriptUnique

      public void appendAdditionalScriptUnique(String script)
      append an additionalScript, but only if it is not already in the body of the script (or additionalScript)
      Parameters:
      script - should contain script (or scripts), and should end in a semicolon (each line should), and should end in newline
    • getOldDatabase

      public Database getOldDatabase()
      current state of the database (after modifications :) ). Note, this is null if this is working on old db
      Returns:
      the oldDatabase
    • setOldDatabase

      public void setOldDatabase(Database oldDatabase)
      current state of the database (after modifications :) ). Note, this is null if this is working on old db
      Parameters:
      oldDatabase - the oldDatabase to set
    • getDatabase

      public Database getDatabase()
      database we are operating on
      Returns:
      the database
    • setDatabase

      public void setDatabase(Database database)
      database we are operating on
      Parameters:
      database - the database to set
    • getAdditionalScripts

      public StringBuilder getAdditionalScripts()
      additional scripts to add after ddlutils scripts
      Returns:
      the additionalScripts
    • setAdditionalScripts

      public void setAdditionalScripts(StringBuilder additionalScripts)
      additional scripts to add after ddlutils scripts
      Parameters:
      additionalScripts - the additionalScripts to set
    • isDestinationVersion

      public boolean isDestinationVersion()
      Returns:
      the isDestinationVersion
    • setDestinationVersion

      public void setDestinationVersion(boolean isDestinationVersion)
      Parameters:
      isDestinationVersion - the isDestinationVersion to set
    • getBuildingToVersion

      public int getBuildingToVersion()
      the eventual version we are build to
      Returns:
      the buildingToVersion
    • setBuildingToVersion

      public void setBuildingToVersion(int buildingToVersion)
      the eventual version we are build to
      Parameters:
      buildingToVersion - the buildingToVersion to set
    • getFullScript

      public StringBuilder getFullScript()
      full script so far (to make sure we dont have duplicate scripts, shouldnt add directly to it from here though
      Returns:
      the fullScript
    • setFullScript

      public void setFullScript(StringBuilder fullScript)
      full script so far (to make sure we dont have duplicate scripts, shouldnt add directly to it from here though
      Parameters:
      fullScript - the fullScript to set
    • getPlatform

      public Platform getPlatform()
      ddlutils platform
      Returns:
      the platform
    • setPlatform

      public void setPlatform(Platform platform)
      ddlutils platform
      Parameters:
      platform - the platform to set
    • getConnection

      public Connection getConnection()
      jdbc connection
      Returns:
      the connection
    • setConnection

      public void setConnection(Connection connection)
      jdbc connection
      Parameters:
      connection - the connection to set
    • getSchema

      public String getSchema()
      schema
      Returns:
      the schema
    • setSchema

      public void setSchema(String schema)
      schema
      Parameters:
      schema - the schema to set
    • getSqlBuilder

      public SqlBuilder getSqlBuilder()
      ddlutils schemabuilder
      Returns:
      the sqlBuilder
    • getBuildingFromVersion

      public int getBuildingFromVersion()
      version building from
    • setBuildingFromVersion

      public void setBuildingFromVersion(int buildingFromVersion1)
      version building from
    • setSqlBuilder

      public void setSqlBuilder(SqlBuilder sqlBuilder)
      ddlutils schemabuilder
      Parameters:
      sqlBuilder - the sqlBuilder to set
    • getObjectName

      public String getObjectName()
      ddl object name (e.g. Grouper or Subject)
      Returns:
      the objectName
    • setObjectName

      public void setObjectName(String objectName)
      ddl object name (e.g. Grouper or Subject)
      Parameters:
      objectName - the objectName to set