Package org.hibernate.mapping
Class Subclass
- java.lang.Object
-
- org.hibernate.mapping.PersistentClass
-
- org.hibernate.mapping.Subclass
-
- All Implemented Interfaces:
Serializable
,AttributeContainer
,Contributable
,Filterable
,IdentifiableTypeClass
,MetaAttributable
,TableContainer
- Direct Known Subclasses:
JoinedSubclass
,SingleTableSubclass
,UnionSubclass
public class Subclass extends PersistentClass
A mapping model object that represents a subclass in an entity class inheritance hierarchy.- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class org.hibernate.mapping.PersistentClass
NOT_NULL_DISCRIMINATOR_MAPPING, NULL_DISCRIMINATOR_MAPPING, synchronizedTables
-
-
Constructor Summary
Constructors Constructor Description Subclass(PersistentClass superclass, MetadataBuildingContext buildingContext)
-
Method Summary
-
Methods inherited from class org.hibernate.mapping.PersistentClass
addCallbackDefinitions, addCheckConstraint, addFilter, addSubclass, addSynchronizedTable, applyProperty, assignCheckConstraintsToTable, checkColumnDuplication, contains, createPrimaryKey, findSecondaryTable, findTable, getBatchSize, getCallbackDefinitions, getCheckConstraints, getClassName, getContributor, getCustomSQLDelete, getCustomSQLDeleteCheckStyle, getCustomSQLInsert, getCustomSQLInsertCheckStyle, getCustomSQLUpdate, getCustomSQLUpdateCheckStyle, getDeclaredIdentifierMapper, getDeclaredProperties, getDeleteExpectation, getDirectSubclasses, getDiscriminatorValue, getEntityName, getIdentityTable, getImplicitTable, getInsertExpectation, getJoinNumber, getJoins, getJpaEntityName, getLoaderName, getMappedClass, getMetaAttribute, getMetaAttributes, getNonDuplicatedProperties, getOptimisticLockMode, getProperties, getProperty, getProxyInterface, getProxyInterfaceName, getQueryCacheLayout, getRecursiveProperty, getReferenceableProperties, getReferencedProperty, getSecondaryTable, getServiceRegistry, getSubclassClosure, getSubclasses, getSubclassJoinClosure, getSubclassProperty, getSubclassPropertyClosure, getSubclassSpan, getSubclassTableClosure, getSubTypes, getSuperMappedSuperclass, getSuperPersistentClass, getSuperType, getTable, getUnjoinedProperties, getUpdateExpectation, hasCollectionNotReferencingPK, hasIdentifierMapper, hasNaturalId, hasPartitionedSelectionMapping, hasPojoRepresentation, hasProperty, hasSelectBeforeUpdate, hasSubclasses, isAbstract, isCached, isCachingExplicitlyRequested, isCustomDeleteCallable, isCustomInsertCallable, isCustomUpdateCallable, isDefinedOnMultipleSubclasses, isDiscriminatorValueNotNull, isDiscriminatorValueNull, isLazy, isPropertyDefinedInHierarchy, isPropertyDefinedInSuperHierarchy, prepareForMappingModel, setAbstract, setBatchSize, setCached, setCachingExplicitlyRequested, setClassName, setCustomSQLDelete, setCustomSQLInsert, setCustomSQLUpdate, setDeclaredIdentifierMapper, setDeleteExpectation, setDiscriminatorValue, setDynamicInsert, setDynamicUpdate, setEntityName, setIdentifierMapper, setInsertExpectation, setJpaEntityName, setLazy, setLoaderName, setMetaAttributes, setOptimisticLockMode, setOptimisticLockStyle, setProxyInterfaceName, setQueryCacheLayout, setSelectBeforeUpdate, setSubselectLoadableCollections, setSuperMappedSuperclass, setUpdateExpectation, toString, useDynamicInsert, useDynamicUpdate, validate
-
-
-
-
Constructor Detail
-
Subclass
public Subclass(PersistentClass superclass, MetadataBuildingContext buildingContext)
-
-
Method Detail
-
getSubclassId
public int getSubclassId()
- Specified by:
getSubclassId
in classPersistentClass
-
getNaturalIdCacheRegionName
public String getNaturalIdCacheRegionName()
- Specified by:
getNaturalIdCacheRegionName
in classPersistentClass
-
getCacheConcurrencyStrategy
public String getCacheConcurrencyStrategy()
- Specified by:
getCacheConcurrencyStrategy
in classPersistentClass
-
getRootClass
public RootClass getRootClass()
- Specified by:
getRootClass
in classPersistentClass
-
getSuperclass
public PersistentClass getSuperclass()
- Specified by:
getSuperclass
in classPersistentClass
-
getIdentifierProperty
public Property getIdentifierProperty()
- Specified by:
getIdentifierProperty
in classPersistentClass
-
getDeclaredIdentifierProperty
public Property getDeclaredIdentifierProperty()
- Specified by:
getDeclaredIdentifierProperty
in classPersistentClass
-
getIdentifier
public KeyValue getIdentifier()
- Specified by:
getIdentifier
in classPersistentClass
-
hasIdentifierProperty
public boolean hasIdentifierProperty()
- Specified by:
hasIdentifierProperty
in classPersistentClass
-
getDiscriminator
public Value getDiscriminator()
- Specified by:
getDiscriminator
in classPersistentClass
-
isMutable
public boolean isMutable()
- Specified by:
isMutable
in classPersistentClass
-
isInherited
public boolean isInherited()
- Specified by:
isInherited
in classPersistentClass
-
isPolymorphic
public boolean isPolymorphic()
- Specified by:
isPolymorphic
in classPersistentClass
-
addProperty
public void addProperty(Property property)
Description copied from interface:AttributeContainer
Add a property to thisPersistentClass
orJoin
.- Specified by:
addProperty
in interfaceAttributeContainer
- Overrides:
addProperty
in classPersistentClass
-
addMappedSuperclassProperty
public void addMappedSuperclassProperty(Property property)
- Overrides:
addMappedSuperclassProperty
in classPersistentClass
-
addJoin
public void addJoin(Join j)
- Overrides:
addJoin
in classPersistentClass
-
getPropertyClosure
public List<Property> getPropertyClosure()
- Specified by:
getPropertyClosure
in classPersistentClass
-
getTableClosure
public List<Table> getTableClosure()
- Specified by:
getTableClosure
in classPersistentClass
-
getKeyClosure
public List<KeyValue> getKeyClosure()
- Specified by:
getKeyClosure
in classPersistentClass
-
addSubclassProperty
protected void addSubclassProperty(Property p)
- Overrides:
addSubclassProperty
in classPersistentClass
-
addSubclassJoin
protected void addSubclassJoin(Join j)
- Overrides:
addSubclassJoin
in classPersistentClass
-
addSubclassTable
protected void addSubclassTable(Table table)
- Overrides:
addSubclassTable
in classPersistentClass
-
isVersioned
public boolean isVersioned()
- Specified by:
isVersioned
in classPersistentClass
-
getVersion
public Property getVersion()
- Specified by:
getVersion
in classPersistentClass
-
getDeclaredVersion
public Property getDeclaredVersion()
- Specified by:
getDeclaredVersion
in classPersistentClass
-
hasEmbeddedIdentifier
public boolean hasEmbeddedIdentifier()
- Specified by:
hasEmbeddedIdentifier
in classPersistentClass
-
getEntityPersisterClass
public Class<? extends EntityPersister> getEntityPersisterClass()
- Specified by:
getEntityPersisterClass
in classPersistentClass
-
getRootTable
public Table getRootTable()
- Specified by:
getRootTable
in classPersistentClass
-
getKey
public KeyValue getKey()
- Specified by:
getKey
in classPersistentClass
-
isExplicitPolymorphism
public boolean isExplicitPolymorphism()
- Specified by:
isExplicitPolymorphism
in classPersistentClass
-
isConcreteProxy
public boolean isConcreteProxy()
- Specified by:
isConcreteProxy
in classPersistentClass
-
setSuperclass
public void setSuperclass(PersistentClass superclass)
-
getWhere
public String getWhere()
- Specified by:
getWhere
in classPersistentClass
-
isJoinedSubclass
public boolean isJoinedSubclass()
- Specified by:
isJoinedSubclass
in classPersistentClass
-
createForeignKey
public void createForeignKey()
-
setEntityPersisterClass
public void setEntityPersisterClass(Class<? extends EntityPersister> classPersisterClass)
- Specified by:
setEntityPersisterClass
in classPersistentClass
-
getJoinClosureSpan
public int getJoinClosureSpan()
- Overrides:
getJoinClosureSpan
in classPersistentClass
-
getPropertyClosureSpan
public int getPropertyClosureSpan()
- Overrides:
getPropertyClosureSpan
in classPersistentClass
-
getJoinClosure
public List<Join> getJoinClosure()
- Overrides:
getJoinClosure
in classPersistentClass
-
isClassOrSuperclassJoin
public boolean isClassOrSuperclassJoin(Join join)
- Overrides:
isClassOrSuperclassJoin
in classPersistentClass
-
isClassOrSuperclassTable
public boolean isClassOrSuperclassTable(Table table)
- Overrides:
isClassOrSuperclassTable
in classPersistentClass
-
getTable
public Table getTable()
- Specified by:
getTable
in interfaceAttributeContainer
- Specified by:
getTable
in classPersistentClass
-
isForceDiscriminator
public boolean isForceDiscriminator()
- Overrides:
isForceDiscriminator
in classPersistentClass
-
isDiscriminatorInsertable
public boolean isDiscriminatorInsertable()
- Specified by:
isDiscriminatorInsertable
in classPersistentClass
-
getSynchronizedTables
public Set<String> getSynchronizedTables()
- Specified by:
getSynchronizedTables
in classPersistentClass
-
accept
public Object accept(PersistentClassVisitor mv)
- Specified by:
accept
in classPersistentClass
-
getFilters
public List<FilterConfiguration> getFilters()
- Specified by:
getFilters
in interfaceFilterable
- Overrides:
getFilters
in classPersistentClass
-
hasSubselectLoadableCollections
public boolean hasSubselectLoadableCollections()
- Overrides:
hasSubselectLoadableCollections
in classPersistentClass
-
getIdentifierMapper
public Component getIdentifierMapper()
- Overrides:
getIdentifierMapper
in classPersistentClass
-
getOptimisticLockStyle
public OptimisticLockStyle getOptimisticLockStyle()
- Overrides:
getOptimisticLockStyle
in classPersistentClass
-
-