Package org.hibernate.mapping
Class Table
java.lang.Object
org.hibernate.mapping.Table
- All Implemented Interfaces:
Serializable,RelationalModel
- Direct Known Subclasses:
DenormalizedTable
A relational table
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddCheckConstraint(String constraint) voidaddUniqueKey(UniqueKey uniqueKey) booleancontainsColumn(Column column) createForeignKey(String keyName, List keyColumns, String referencedEntityName) createForeignKey(String keyName, List keyColumns, String referencedEntityName, List referencedColumns) voidcreateUniqueKey(List keyColumns) getColumn(int n) Return the column which is identified by column provided as argument.intgetName()getOrCreateIndex(String indexName) getOrCreateUniqueKey(String keyName) getQualifiedName(Dialect dialect, String defaultCatalog, String defaultSchema) returns quoted name as it would be in the mapping file.getQuotedName(Dialect dialect) returns quoted name as it is in the mapping file.getQuotedSchema(Dialect dialect) getRowId()intgetUniqueKey(String keyName) booleanbooleanbooleanbooleanbooleanbooleanisQuoted()booleanbooleanstatic StringvoidsetAbstract(boolean isAbstract) voidsetCatalog(String catalog) voidsetComment(String comment) voidsetIdentifierValue(KeyValue idValue) voidvoidsetPrimaryKey(PrimaryKey primaryKey) voidsetQuoted(boolean quoted) voidvoidvoidsetSubselect(String subselect) sqlAlterStrings(Dialect dialect, Mapping p, TableMetadata tableInfo, String defaultCatalog, String defaultSchema) sqlCommentStrings(Dialect dialect, String defaultCatalog, String defaultSchema) sqlCreateString(Dialect dialect, Mapping p, String defaultCatalog, String defaultSchema) sqlDropString(Dialect dialect, String defaultCatalog, String defaultSchema) sqlTemporaryTableCreateString(Dialect dialect, Mapping mapping) toString()uniqueColumnString(Iterator iterator) uniqueColumnString(Iterator iterator, String referencedEntityName) voidvalidateColumns(Dialect dialect, Mapping mapping, TableMetadata tableInfo)
-
Constructor Details
-
Table
public Table() -
Table
-
-
Method Details
-
getQualifiedName
-
qualify
-
getName
-
getQuotedName
returns quoted name as it would be in the mapping file. -
getQuotedName
-
getQuotedSchema
returns quoted name as it is in the mapping file. -
getQuotedSchema
-
setName
-
getColumn
Return the column which is identified by column provided as argument.- Parameters:
column- column with atleast a name.- Returns:
- the underlying column or null if not inside this table. Note: the instance *can* be different than the input parameter, but the name will be the same.
-
getColumn
-
addColumn
-
getColumnSpan
public int getColumnSpan() -
getColumnIterator
-
getIndexIterator
-
getForeignKeyIterator
-
getUniqueKeyIterator
-
validateColumns
-
sqlAlterStrings
public Iterator sqlAlterStrings(Dialect dialect, Mapping p, TableMetadata tableInfo, String defaultCatalog, String defaultSchema) throws HibernateException - Throws:
HibernateException
-
hasPrimaryKey
public boolean hasPrimaryKey() -
sqlTemporaryTableCreateString
public String sqlTemporaryTableCreateString(Dialect dialect, Mapping mapping) throws HibernateException - Throws:
HibernateException
-
sqlCreateString
public String sqlCreateString(Dialect dialect, Mapping p, String defaultCatalog, String defaultSchema) - Specified by:
sqlCreateStringin interfaceRelationalModel
-
sqlDropString
- Specified by:
sqlDropStringin interfaceRelationalModel
-
getPrimaryKey
-
setPrimaryKey
-
getOrCreateIndex
-
getIndex
-
addIndex
-
addUniqueKey
-
createUniqueKey
-
getUniqueKey
-
getOrCreateUniqueKey
-
createForeignKeys
public void createForeignKeys() -
createForeignKey
-
createForeignKey
public ForeignKey createForeignKey(String keyName, List keyColumns, String referencedEntityName, List referencedColumns) -
uniqueColumnString
-
uniqueColumnString
-
getSchema
-
setSchema
-
getCatalog
-
setCatalog
-
getUniqueInteger
public int getUniqueInteger() -
setIdentifierValue
-
getIdentifierValue
-
isSchemaQuoted
public boolean isSchemaQuoted() -
isQuoted
public boolean isQuoted() -
setQuoted
public void setQuoted(boolean quoted) -
addCheckConstraint
-
containsColumn
-
getRowId
-
setRowId
-
toString
-
getSubselect
-
setSubselect
-
isSubselect
public boolean isSubselect() -
isAbstractUnionTable
public boolean isAbstractUnionTable() -
hasDenormalizedTables
public boolean hasDenormalizedTables() -
setAbstract
public void setAbstract(boolean isAbstract) -
isAbstract
public boolean isAbstract() -
isPhysicalTable
public boolean isPhysicalTable() -
getComment
-
setComment
-
getCheckConstraintsIterator
-
sqlCommentStrings
-