Class Relation

All Implemented Interfaces:
Comparable, LiquibaseSerializable, DatabaseObject
Direct Known Subclasses:
Table, View

public abstract class Relation extends AbstractDatabaseObject
A container of columns. Usually a table or view.
  • Constructor Details

    • Relation

      protected Relation()
  • Method Details

    • getName

      public String getName()
    • setName

      public Relation setName(String name)
      Description copied from interface: DatabaseObject
      Sets the name for the database object.
      name - the new name for the database object
      a reference to the same object (implementing classes are expected to return a reference to the same object).
    • getIndexes

      public List<Index> getIndexes()
    • getUniqueConstraints

      public List<UniqueConstraint> getUniqueConstraints()
    • getContainingObjects

      public DatabaseObject[] getContainingObjects()
    • getRemarks

      public String getRemarks()
    • setRemarks

      public Relation setRemarks(String remarks)
    • getColumns

      public List<Column> getColumns()
    • addColumn

      public Relation addColumn(Column column)
    • getColumn

      public Column getColumn(String columnName)
      Returns the column object for the given columnName. If the column does not exist in this table, return null.
    • getSchema

      public Schema getSchema()
      Returns the schema.
    • setSchema

      public Relation setSchema(Schema schema)
      schema - The schema to set.
    • setSchema

      public Relation setSchema(String catalog, String schema)
    • compareTo

      public int compareTo(Object o)
      Specified by:
      compareTo in interface Comparable
      compareTo in class AbstractDatabaseObject