Package org.hibernate.cfg.annotations
Class TableBinder
- java.lang.Object
-
- org.hibernate.cfg.annotations.TableBinder
-
public class TableBinder extends java.lang.Object
Table related operations
-
-
Constructor Summary
Constructors Constructor Description TableBinder()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static void
addIndexes(Table hibTable, Index[] indexes, MetadataBuildingContext buildingContext)
static void
addIndexes(Table hibTable, Index[] indexes, MetadataBuildingContext buildingContext)
Table
bind()
static void
bindFk(PersistentClass referencedEntity, PersistentClass destinationEntity, Ejb3JoinColumn[] columns, SimpleValue value, boolean unique, MetadataBuildingContext buildingContext)
static Table
buildAndFillTable(java.lang.String schema, java.lang.String catalog, Identifier logicalName, boolean isAbstract, java.util.List<UniqueConstraintHolder> uniqueConstraints, java.util.List<JPAIndexHolder> jpaIndexHolders, java.lang.String constraints, MetadataBuildingContext buildingContext, java.lang.String subselect, InFlightMetadataCollector.EntityTableXref denormalizedSuperTableXref)
static Table
buildAndFillTable(java.lang.String schema, java.lang.String catalog, ObjectNameSource nameSource, NamingStrategyHelper namingStrategyHelper, boolean isAbstract, java.util.List<UniqueConstraintHolder> uniqueConstraints, java.util.List<JPAIndexHolder> jpaIndexHolders, java.lang.String constraints, MetadataBuildingContext buildingContext, java.lang.String subselect, InFlightMetadataCollector.EntityTableXref denormalizedSuperTableXref)
static java.util.List<JPAIndexHolder>
buildJpaIndexHolder(Index[] indexes)
static java.util.List<UniqueConstraintHolder>
buildUniqueConstraintHolders(UniqueConstraint[] annotations)
Build a list ofUniqueConstraintHolder
instances given a list ofUniqueConstraint
annotations.static java.util.List<java.lang.String[]>
buildUniqueConstraints(UniqueConstraint[] constraintsArray)
Deprecated.static void
createUniqueConstraint(Value value)
java.lang.String
getName()
static void
linkJoinColumnWithValueOverridingNameIfImplicit(PersistentClass referencedEntity, java.util.Iterator columnIterator, Ejb3JoinColumn[] columns, SimpleValue value)
void
setAbstract(boolean anAbstract)
void
setBuildingContext(MetadataBuildingContext buildingContext)
void
setCatalog(java.lang.String catalog)
void
setConstraints(java.lang.String constraints)
void
setDefaultName(java.lang.String ownerClassName, java.lang.String ownerEntity, java.lang.String ownerJpaEntity, java.lang.String ownerEntityTable, java.lang.String associatedClassName, java.lang.String associatedEntity, java.lang.String associatedJpaEntity, java.lang.String associatedEntityTable, java.lang.String propertyName)
void
setJPA2ElementCollection(boolean isJPA2ElementCollection)
void
setJpaIndex(Index[] jpaIndex)
void
setName(java.lang.String name)
void
setSchema(java.lang.String schema)
void
setUniqueConstraints(UniqueConstraint[] uniqueConstraints)
-
-
-
Method Detail
-
setBuildingContext
public void setBuildingContext(MetadataBuildingContext buildingContext)
-
setSchema
public void setSchema(java.lang.String schema)
-
setCatalog
public void setCatalog(java.lang.String catalog)
-
getName
public java.lang.String getName()
-
setName
public void setName(java.lang.String name)
-
setAbstract
public void setAbstract(boolean anAbstract)
-
setUniqueConstraints
public void setUniqueConstraints(UniqueConstraint[] uniqueConstraints)
-
setJpaIndex
public void setJpaIndex(Index[] jpaIndex)
-
setConstraints
public void setConstraints(java.lang.String constraints)
-
setJPA2ElementCollection
public void setJPA2ElementCollection(boolean isJPA2ElementCollection)
-
bind
public Table bind()
-
buildAndFillTable
public static Table buildAndFillTable(java.lang.String schema, java.lang.String catalog, ObjectNameSource nameSource, NamingStrategyHelper namingStrategyHelper, boolean isAbstract, java.util.List<UniqueConstraintHolder> uniqueConstraints, java.util.List<JPAIndexHolder> jpaIndexHolders, java.lang.String constraints, MetadataBuildingContext buildingContext, java.lang.String subselect, InFlightMetadataCollector.EntityTableXref denormalizedSuperTableXref)
-
buildAndFillTable
public static Table buildAndFillTable(java.lang.String schema, java.lang.String catalog, Identifier logicalName, boolean isAbstract, java.util.List<UniqueConstraintHolder> uniqueConstraints, java.util.List<JPAIndexHolder> jpaIndexHolders, java.lang.String constraints, MetadataBuildingContext buildingContext, java.lang.String subselect, InFlightMetadataCollector.EntityTableXref denormalizedSuperTableXref)
-
bindFk
public static void bindFk(PersistentClass referencedEntity, PersistentClass destinationEntity, Ejb3JoinColumn[] columns, SimpleValue value, boolean unique, MetadataBuildingContext buildingContext)
-
linkJoinColumnWithValueOverridingNameIfImplicit
public static void linkJoinColumnWithValueOverridingNameIfImplicit(PersistentClass referencedEntity, java.util.Iterator columnIterator, Ejb3JoinColumn[] columns, SimpleValue value)
-
createUniqueConstraint
public static void createUniqueConstraint(Value value)
-
addIndexes
public static void addIndexes(Table hibTable, Index[] indexes, MetadataBuildingContext buildingContext)
-
addIndexes
public static void addIndexes(Table hibTable, Index[] indexes, MetadataBuildingContext buildingContext)
-
buildJpaIndexHolder
public static java.util.List<JPAIndexHolder> buildJpaIndexHolder(Index[] indexes)
-
buildUniqueConstraints
@Deprecated public static java.util.List<java.lang.String[]> buildUniqueConstraints(UniqueConstraint[] constraintsArray)
Deprecated.
-
buildUniqueConstraintHolders
public static java.util.List<UniqueConstraintHolder> buildUniqueConstraintHolders(UniqueConstraint[] annotations)
Build a list ofUniqueConstraintHolder
instances given a list ofUniqueConstraint
annotations.- Parameters:
annotations
- TheUniqueConstraint
annotations.- Returns:
- The built
UniqueConstraintHolder
instances.
-
setDefaultName
public void setDefaultName(java.lang.String ownerClassName, java.lang.String ownerEntity, java.lang.String ownerJpaEntity, java.lang.String ownerEntityTable, java.lang.String associatedClassName, java.lang.String associatedEntity, java.lang.String associatedJpaEntity, java.lang.String associatedEntityTable, java.lang.String propertyName)
-
-