Class PgView

All Implemented Interfaces:
IHashable, IOptionContainer, IRelation, ISearchPath, ISimpleOptionContainer, IStatement, IStatementContainer

public final class PgView extends AbstractPgView
PostgreSQL view implementation. Views are virtual tables defined by queries that provide a way to present data from one or more tables in a customized format without storing the data physically.
  • Constructor Details

    • PgView

      public PgView(String name)
      Creates a new PostgreSQL view.
      Parameters:
      name - view name
  • Method Details

    • addColumnDefaultValue

      public void addColumnDefaultValue(String columnName, String defaultValue)
      Adds/replaces column default value specification.
      Parameters:
      columnName - column name
      defaultValue - default value expression
    • removeColumnDefaultValue

      public void removeColumnDefaultValue(String columnName)
      Removes column default value specification.
      Parameters:
      columnName - column name to remove default from
    • compare

      public boolean compare(PgStatement obj)
      Description copied from class: PgStatement
      This method does not account for nested child PgStatements. Shallow version of PgStatement.equals(Object)
      Overrides:
      compare in class AbstractPgView
    • computeHash

      public void computeHash(Hasher hasher)
      Description copied from interface: IHashable
      Computes the hash of the implementing object using the provided hasher. The implementation should call appropriate put methods on the hasher for all fields that should contribute to the hash value.
      Specified by:
      computeHash in interface IHashable
      Overrides:
      computeHash in class AbstractPgView
      Parameters:
      hasher - the hasher instance to use for hash computation