Package liquibase

Class CatalogAndSchema


  • public class CatalogAndSchema
    extends Object
    Object representing a database catalog and schema. This differs from Schema in that it has not come from an actual database Schema.

    A null value for catalogName or schemaName signifies the default catalog/schema.

    • Constructor Detail

      • CatalogAndSchema

        public CatalogAndSchema​(String catalogName,
                                String schemaName)
    • Method Detail

      • getCatalogName

        public String getCatalogName()
      • getSchemaName

        public String getSchemaName()
      • standardize

        public CatalogAndSchema standardize​(Database accordingTo)
        This method returns a new CatalogAndSchema adjusted based on the configuration of the passed database. If the database does not support schemas, the returned object will have a null schema. If the database does not support catalogs, the returned object will have a null catalog. If either the schema or catalog matches the database default catalog or schema, they will be nulled out. Catalog and/or schema names will be upper case unless the database violates the SQL standard by being case-sensitive about some or all unquoted identifiers.
        See Also:
        customize(liquibase.database.Database)
      • customize

        public CatalogAndSchema customize​(Database accordingTo)
        Returns a new CatalogAndSchema object with null/default catalog and schema names set to the correct default catalog and schema. If the database does not support catalogs or schemas they will retain a null value. Catalog and schema capitalization will match what the database expects.
        See Also:
        standardize(liquibase.database.Database)
      • toString

        public String toString()
        String version includes both catalog and schema. If either is null it returns the string "DEFAULT" in its place.
        Overrides:
        toString in class Object