public abstract class

PersistentClass

extends Object
implements Serializable Filterable MetaAttributable
java.lang.Object
   ↳ org.hibernate.mapping.PersistentClass
Known Direct Subclasses
Known Indirect Subclasses

Class Overview

Mapping for an entity.

Summary

Constants
String NOT_NULL_DISCRIMINATOR_MAPPING
String NULL_DISCRIMINATOR_MAPPING
Fields
protected int optimisticLockMode
protected final Set synchronizedTables
Public Constructors
PersistentClass()
Public Methods
abstract Object accept(PersistentClassVisitor mv)
void addFilter(String name, String condition)
void addJoin(Join join)
void addMappedsuperclassProperty(Property p)
void addProperty(Property p)
void addSubclass(Subclass subclass)
void addSynchronizedTable(String table)
void addTuplizer(EntityMode entityMode, String implClassName)
void createPrimaryKey()
int getBatchSize()
abstract String getCacheConcurrencyStrategy()
String getClassName()
String getCustomSQLDelete()
ExecuteUpdateResultCheckStyle getCustomSQLDeleteCheckStyle()
String getCustomSQLInsert()
ExecuteUpdateResultCheckStyle getCustomSQLInsertCheckStyle()
String getCustomSQLUpdate()
ExecuteUpdateResultCheckStyle getCustomSQLUpdateCheckStyle()
Component getDeclaredIdentifierMapper()
abstract Property getDeclaredIdentifierProperty()
Iterator getDeclaredPropertyIterator()
abstract Property getDeclaredVersion()
Iterator getDirectSubclasses()
abstract Value getDiscriminator()
String getDiscriminatorValue()
String getEntityName()
abstract Class getEntityPersisterClass()
Map getFilterMap()
abstract KeyValue getIdentifier()
Component getIdentifierMapper()
abstract Property getIdentifierProperty()
Table getIdentityTable()
Iterator getJoinClosureIterator()
int getJoinClosureSpan()
Iterator getJoinIterator()
int getJoinNumber(Property prop)
String getJpaEntityName()
abstract KeyValue getKey()
abstract Iterator getKeyClosureIterator()
String getLoaderName()
Class getMappedClass()
MetaAttribute getMetaAttribute(String name)
Map getMetaAttributes()
String getNodeName()
abstract int getOptimisticLockMode()
Property getProperty(String propertyName)
abstract Iterator getPropertyClosureIterator()
int getPropertyClosureSpan()
Iterator getPropertyIterator()
Build an iterator over the properties defined on this class.
Class getProxyInterface()
String getProxyInterfaceName()
Property getRecursiveProperty(String propertyPath)
Iterator getReferenceablePropertyIterator()
Build an iterator of properties which are "referenceable".
Property getReferencedProperty(String propertyPath)
Given a property path, locate the appropriate referenceable property reference.
abstract RootClass getRootClass()
abstract Table getRootTable()
Iterator getSubclassClosureIterator()
abstract int getSubclassId()
Iterator getSubclassIterator()
Iterate over subclasses in a special 'order', most derived subclasses first.
Iterator getSubclassJoinClosureIterator()
Iterator getSubclassPropertyClosureIterator()
int getSubclassSpan()
Iterator getSubclassTableClosureIterator()
MappedSuperclass getSuperMappedSuperclass()
abstract PersistentClass getSuperclass()
abstract Set getSynchronizedTables()
abstract Table getTable()
abstract Iterator getTableClosureIterator()
String getTemporaryIdTableDDL()
String getTemporaryIdTableName()
String getTuplizerImplClassName(EntityMode mode)
Map getTuplizerMap()
Iterator getUnjoinedPropertyIterator()
Build an iterator over the properties defined on this class which are not defined as part of a join.
abstract Property getVersion()
abstract String getWhere()
boolean hasDom4jRepresentation()
abstract boolean hasEmbeddedIdentifier()
boolean hasIdentifierMapper()
abstract boolean hasIdentifierProperty()
boolean hasNaturalId()
boolean hasPojoRepresentation()
boolean hasSelectBeforeUpdate()
boolean hasSubclasses()
boolean hasSubselectLoadableCollections()
Boolean isAbstract()
boolean isClassOrSuperclassJoin(Join join)
boolean isClassOrSuperclassTable(Table closureTable)
boolean isCustomDeleteCallable()
boolean isCustomInsertCallable()
boolean isCustomUpdateCallable()
abstract boolean isDiscriminatorInsertable()
boolean isDiscriminatorValueNotNull()
boolean isDiscriminatorValueNull()
abstract boolean isExplicitPolymorphism()
boolean isForceDiscriminator()
abstract boolean isInherited()
abstract boolean isJoinedSubclass()
boolean isLazy()
abstract boolean isLazyPropertiesCacheable()
abstract boolean isMutable()
abstract boolean isPolymorphic()
abstract boolean isVersioned()
void prepareTemporaryTables(Mapping mapping, Dialect dialect)
void setAbstract(Boolean isAbstract)
void setBatchSize(int batchSize)
void setClassName(String className)
void setCustomSQLDelete(String customSQLDelete, boolean callable, ExecuteUpdateResultCheckStyle checkStyle)
void setCustomSQLInsert(String customSQLInsert, boolean callable, ExecuteUpdateResultCheckStyle checkStyle)
void setCustomSQLUpdate(String customSQLUpdate, boolean callable, ExecuteUpdateResultCheckStyle checkStyle)
void setDeclaredIdentifierMapper(Component declaredIdentifierMapper)
void setDiscriminatorValue(String discriminatorValue)
void setDynamicInsert(boolean dynamicInsert)
void setDynamicUpdate(boolean dynamicUpdate)
void setEntityName(String entityName)
abstract void setEntityPersisterClass(Class classPersisterClass)
void setIdentifierMapper(Component handle)
void setJpaEntityName(String jpaEntityName)
void setLazy(boolean lazy)
void setLoaderName(String loaderName)
void setMetaAttributes(Map metas)
void setNodeName(String nodeName)
void setOptimisticLockMode(int optimisticLockMode)
void setProxyInterfaceName(String proxyInterfaceName)
void setSelectBeforeUpdate(boolean selectBeforeUpdate)
void setSubselectLoadableCollections(boolean hasSubselectCollections)
void setSuperMappedSuperclass(MappedSuperclass superMappedSuperclass)
String toString()
boolean useDynamicInsert()
boolean useDynamicUpdate()
void validate(Mapping mapping)
Protected Methods
void addSubclassJoin(Join join)
void addSubclassProperty(Property prop)
void addSubclassTable(Table subclassTable)
void checkColumnDuplication(Set distinctColumns, Iterator columns)
void checkColumnDuplication()
void checkPropertyColumnDuplication(Set distinctColumns, Iterator properties)
Iterator getDiscriminatorColumnIterator()
Iterator getNonDuplicatedPropertyIterator()
[Expand]
Inherited Methods
From class java.lang.Object
From interface org.hibernate.mapping.Filterable
From interface org.hibernate.mapping.MetaAttributable

Constants

public static final String NOT_NULL_DISCRIMINATOR_MAPPING

Constant Value: "not null"

public static final String NULL_DISCRIMINATOR_MAPPING

Constant Value: "null"

Fields

protected int optimisticLockMode

protected final Set synchronizedTables

Public Constructors

public PersistentClass ()

Public Methods

public abstract Object accept (PersistentClassVisitor mv)

public void addFilter (String name, String condition)

public void addJoin (Join join)

public void addMappedsuperclassProperty (Property p)

public void addProperty (Property p)

public void addSubclass (Subclass subclass)

public void addSynchronizedTable (String table)

public void addTuplizer (EntityMode entityMode, String implClassName)

public void createPrimaryKey ()

public int getBatchSize ()

public abstract String getCacheConcurrencyStrategy ()

public String getClassName ()

public String getCustomSQLDelete ()

public ExecuteUpdateResultCheckStyle getCustomSQLDeleteCheckStyle ()

public String getCustomSQLInsert ()

public ExecuteUpdateResultCheckStyle getCustomSQLInsertCheckStyle ()

public String getCustomSQLUpdate ()

public ExecuteUpdateResultCheckStyle getCustomSQLUpdateCheckStyle ()

public Component getDeclaredIdentifierMapper ()

public abstract Property getDeclaredIdentifierProperty ()

public Iterator getDeclaredPropertyIterator ()

public abstract Property getDeclaredVersion ()

public Iterator getDirectSubclasses ()

public abstract Value getDiscriminator ()

public String getDiscriminatorValue ()

public String getEntityName ()

public abstract Class getEntityPersisterClass ()

public Map getFilterMap ()

public abstract KeyValue getIdentifier ()

public Component getIdentifierMapper ()

public abstract Property getIdentifierProperty ()

public Table getIdentityTable ()

public Iterator getJoinClosureIterator ()

public int getJoinClosureSpan ()

public Iterator getJoinIterator ()

public int getJoinNumber (Property prop)

public String getJpaEntityName ()

public abstract KeyValue getKey ()

public abstract Iterator getKeyClosureIterator ()

public String getLoaderName ()

public Class getMappedClass ()

public MetaAttribute getMetaAttribute (String name)

public Map getMetaAttributes ()

public String getNodeName ()

public abstract int getOptimisticLockMode ()

public Property getProperty (String propertyName)

public abstract Iterator getPropertyClosureIterator ()

public int getPropertyClosureSpan ()

public Iterator getPropertyIterator ()

Build an iterator over the properties defined on this class. The returned iterator only accounts for "normal" properties (i.e. non-identifier properties).

Differs from getUnjoinedPropertyIterator() in that the iterator we return here will include properties defined as part of a join.

Returns
  • An iterator over the "normal" properties.

public Class getProxyInterface ()

public String getProxyInterfaceName ()

public Property getRecursiveProperty (String propertyPath)

public Iterator getReferenceablePropertyIterator ()

Build an iterator of properties which are "referenceable".

Returns
  • The property iterator.

public Property getReferencedProperty (String propertyPath)

Given a property path, locate the appropriate referenceable property reference.

A referenceable property is a property which can be a target of a foreign-key mapping (an identifier or explcitly named in a property-ref).

Parameters
propertyPath The property path to resolve into a property reference.
Returns
  • The property reference (never null).
Throws
MappingException If the property could not be found.

public abstract RootClass getRootClass ()

public abstract Table getRootTable ()

public Iterator getSubclassClosureIterator ()

public abstract int getSubclassId ()

public Iterator getSubclassIterator ()

Iterate over subclasses in a special 'order', most derived subclasses first.

public Iterator getSubclassJoinClosureIterator ()

public Iterator getSubclassPropertyClosureIterator ()

public int getSubclassSpan ()

public Iterator getSubclassTableClosureIterator ()

public MappedSuperclass getSuperMappedSuperclass ()

public abstract PersistentClass getSuperclass ()

public abstract Set getSynchronizedTables ()

public abstract Table getTable ()

public abstract Iterator getTableClosureIterator ()

public String getTemporaryIdTableDDL ()

public String getTemporaryIdTableName ()

public String getTuplizerImplClassName (EntityMode mode)

public Map getTuplizerMap ()

public Iterator getUnjoinedPropertyIterator ()

Build an iterator over the properties defined on this class which are not defined as part of a join. As with getPropertyIterator(), the returned iterator only accounts for non-identifier properties.

Returns
  • An iterator over the non-joined "normal" properties.

public abstract Property getVersion ()

public abstract String getWhere ()

public boolean hasDom4jRepresentation ()

public abstract boolean hasEmbeddedIdentifier ()

public boolean hasIdentifierMapper ()

public abstract boolean hasIdentifierProperty ()

public boolean hasNaturalId ()

public boolean hasPojoRepresentation ()

public boolean hasSelectBeforeUpdate ()

public boolean hasSubclasses ()

public boolean hasSubselectLoadableCollections ()

public Boolean isAbstract ()

public boolean isClassOrSuperclassJoin (Join join)

public boolean isClassOrSuperclassTable (Table closureTable)

public boolean isCustomDeleteCallable ()

public boolean isCustomInsertCallable ()

public boolean isCustomUpdateCallable ()

public abstract boolean isDiscriminatorInsertable ()

public boolean isDiscriminatorValueNotNull ()

public boolean isDiscriminatorValueNull ()

public abstract boolean isExplicitPolymorphism ()

public boolean isForceDiscriminator ()

public abstract boolean isInherited ()

public abstract boolean isJoinedSubclass ()

public boolean isLazy ()

public abstract boolean isLazyPropertiesCacheable ()

public abstract boolean isMutable ()

public abstract boolean isPolymorphic ()

public abstract boolean isVersioned ()

public void prepareTemporaryTables (Mapping mapping, Dialect dialect)

public void setAbstract (Boolean isAbstract)

public void setBatchSize (int batchSize)

public void setClassName (String className)

public void setCustomSQLDelete (String customSQLDelete, boolean callable, ExecuteUpdateResultCheckStyle checkStyle)

public void setCustomSQLInsert (String customSQLInsert, boolean callable, ExecuteUpdateResultCheckStyle checkStyle)

public void setCustomSQLUpdate (String customSQLUpdate, boolean callable, ExecuteUpdateResultCheckStyle checkStyle)

public void setDeclaredIdentifierMapper (Component declaredIdentifierMapper)

public void setDiscriminatorValue (String discriminatorValue)

public void setDynamicInsert (boolean dynamicInsert)

public void setDynamicUpdate (boolean dynamicUpdate)

public void setEntityName (String entityName)

public abstract void setEntityPersisterClass (Class classPersisterClass)

public void setIdentifierMapper (Component handle)

public void setJpaEntityName (String jpaEntityName)

public void setLazy (boolean lazy)

public void setLoaderName (String loaderName)

public void setMetaAttributes (Map metas)

public void setNodeName (String nodeName)

public void setOptimisticLockMode (int optimisticLockMode)

public void setProxyInterfaceName (String proxyInterfaceName)

public void setSelectBeforeUpdate (boolean selectBeforeUpdate)

public void setSubselectLoadableCollections (boolean hasSubselectCollections)

public void setSuperMappedSuperclass (MappedSuperclass superMappedSuperclass)

public String toString ()

public boolean useDynamicInsert ()

public boolean useDynamicUpdate ()

public void validate (Mapping mapping)

Protected Methods

protected void addSubclassJoin (Join join)

protected void addSubclassProperty (Property prop)

protected void addSubclassTable (Table subclassTable)

protected void checkColumnDuplication (Set distinctColumns, Iterator columns)

protected void checkColumnDuplication ()

protected void checkPropertyColumnDuplication (Set distinctColumns, Iterator properties)

protected Iterator getDiscriminatorColumnIterator ()

protected Iterator getNonDuplicatedPropertyIterator ()