org.hibernate.type
Interface AssociationType

All Superinterfaces:
Serializable, Type
All Known Implementing Classes:
AnyType, CollectionType, EntityType

public interface AssociationType
extends Type

A type that represents some kind of association between entities.

Author:
Gavin King
See Also:
Cascade

Method Summary
 String getAssociatedEntityName(SessionFactoryImplementor factory)
          Get the entity name of the associated entity
 Joinable getAssociatedJoinable(SessionFactoryImplementor factory)
          Get the "persister" for this association - a class or collection persister
 ForeignKeyDirection getForeignKeyDirection()
          Get the foreign key directionality of this association
 String getLHSPropertyName()
          Get the name of a property in the owning entity that provides the join key (null if the identifier)
 String getOnCondition(String alias, SessionFactoryImplementor factory, Map enabledFilters)
          Get the "filtering" SQL fragment that is applied in the SQL on clause, in addition to the usual join condition
 String getRHSUniqueKeyPropertyName()
          The name of a unique property of the associated entity that provides the join key (null if the identifier of an entity, or key of a collection)
 boolean isAlwaysDirtyChecked()
          Do we dirty check this association, even when there are no columns to be updated?
 boolean isEmbeddedInXML()
           
 boolean useLHSPrimaryKey()
          Is the primary key of the owning entity table to be used in the join?
 
Methods inherited from interface org.hibernate.type.Type
assemble, beforeAssemble, compare, deepCopy, disassemble, fromXMLNode, getColumnSpan, getHashCode, getHashCode, getName, getReturnedClass, getSemiResolvedType, hydrate, isAnyType, isAssociationType, isCollectionType, isComponentType, isDirty, isDirty, isEntityType, isEqual, isEqual, isModified, isMutable, isSame, isXMLElement, nullSafeGet, nullSafeGet, nullSafeSet, nullSafeSet, replace, replace, resolve, semiResolve, setToXMLNode, sqlTypes, toColumnNullness, toLoggableString
 

Method Detail

getForeignKeyDirection

public ForeignKeyDirection getForeignKeyDirection()
Get the foreign key directionality of this association


useLHSPrimaryKey

public boolean useLHSPrimaryKey()
Is the primary key of the owning entity table to be used in the join?


getLHSPropertyName

public String getLHSPropertyName()
Get the name of a property in the owning entity that provides the join key (null if the identifier)


getRHSUniqueKeyPropertyName

public String getRHSUniqueKeyPropertyName()
The name of a unique property of the associated entity that provides the join key (null if the identifier of an entity, or key of a collection)


getAssociatedJoinable

public Joinable getAssociatedJoinable(SessionFactoryImplementor factory)
                               throws MappingException
Get the "persister" for this association - a class or collection persister

Throws:
MappingException

getAssociatedEntityName

public String getAssociatedEntityName(SessionFactoryImplementor factory)
                               throws MappingException
Get the entity name of the associated entity

Throws:
MappingException

getOnCondition

public String getOnCondition(String alias,
                             SessionFactoryImplementor factory,
                             Map enabledFilters)
                      throws MappingException
Get the "filtering" SQL fragment that is applied in the SQL on clause, in addition to the usual join condition

Throws:
MappingException

isAlwaysDirtyChecked

public boolean isAlwaysDirtyChecked()
Do we dirty check this association, even when there are no columns to be updated?


isEmbeddedInXML

public boolean isEmbeddedInXML()