Package org.pgcodekeeper.core.schema.pg
Class MaterializedPgView
java.lang.Object
org.pgcodekeeper.core.schema.PgStatement
org.pgcodekeeper.core.schema.PgStatementContainer
org.pgcodekeeper.core.schema.AbstractView
org.pgcodekeeper.core.schema.pg.AbstractPgView
org.pgcodekeeper.core.schema.pg.MaterializedPgView
- All Implemented Interfaces:
IHashable,IOptionContainer,IRelation,ISearchPath,ISimpleOptionContainer,IStatement,IStatementContainer
PostgreSQL materialized view implementation.
Materialized views are database objects that contain the results of a query
and can be refreshed periodically to update the cached data.
-
Field Summary
Fields inherited from class org.pgcodekeeper.core.schema.pg.AbstractPgView
CHECK_OPTIONFields inherited from class org.pgcodekeeper.core.schema.PgStatement
GOFields inherited from interface org.pgcodekeeper.core.schema.IOptionContainer
GP_OPTION_LIST -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleancompare(PgStatement obj) This method does not account for nested child PgStatements.voidcomputeHash(Hasher hasher) Computes the hash of the implementing object using the provided hasher.Gets the type name of this statement for SQL generation.voidsetDistribution(String distribution) voidsetIsWithData(Boolean isWithData) voidvoidsetTablespace(String tablespace) Methods inherited from class org.pgcodekeeper.core.schema.pg.AbstractPgView
addColumnComment, addColumnName, addOption, appendAlterComments, appendAlterSQL, appendComments, canDropBeforeCreate, getCreationSQL, getOptions, getRelationColumns, setQueryMethods inherited from class org.pgcodekeeper.core.schema.AbstractView
addConstraint, getConstraint, getConstraints, getStatementTypeMethods inherited from class org.pgcodekeeper.core.schema.PgStatementContainer
addChild, addIndex, addPolicy, addRule, addTrigger, compareChildren, computeChildrenHash, getChild, getContainingSchema, getIndex, getIndexes, getPolicies, getPolicy, getRule, getRules, getTrigger, getTriggers, isClustered, shallowCopyMethods inherited from class org.pgcodekeeper.core.schema.PgStatement
addAllDeps, addDep, addPrivilege, appendOwnerSQL, canDrop, checkComments, clearPrivileges, deepCopy, equals, getAuthor, getBareName, getChildren, getComment, getDbType, getDeps, getDescendants, getDropSQL, getDropSQL, getLibName, getLocation, getName, getObjectState, getObjectState, getOwner, getParent, getPrivileges, getQualifiedName, getSQL, getTwin, hasChildren, hashCode, isLib, isOwned, isSubElement, setAuthor, setComment, setLibName, setLocation, setOwner, setParent, toStringMethods inherited from interface org.pgcodekeeper.core.schema.ISearchPath
getDatabase, getSchemaNameMethods inherited from interface org.pgcodekeeper.core.schema.ISimpleOptionContainer
appendOptions, compareOptionsMethods inherited from interface org.pgcodekeeper.core.schema.IStatement
getBareName, getComment, getName, getParent, getQualifiedName, getStatementType
-
Constructor Details
-
MaterializedPgView
Creates a new materialized view.- Parameters:
name- view name
-
-
Method Details
-
setMethod
-
setDistribution
-
getTypeName
Description copied from class:PgStatementGets the type name of this statement for SQL generation.- Overrides:
getTypeNamein classPgStatement- Returns:
- the type name
-
setIsWithData
-
setTablespace
-
compare
Description copied from class:PgStatementThis method does not account for nested child PgStatements. Shallow version ofPgStatement.equals(Object)- Overrides:
comparein classAbstractPgView
-
computeHash
Description copied from interface:IHashableComputes the hash of the implementing object using the provided hasher. The implementation should call appropriateputmethods on the hasher for all fields that should contribute to the hash value.- Specified by:
computeHashin interfaceIHashable- Overrides:
computeHashin classAbstractPgView- Parameters:
hasher- the hasher instance to use for hash computation
-