@java.lang.SuppressWarnings("rawtypes") public abstract class Association<T extends Property> extends AbstractPersistentProperty
Models an association between one class and another
Constructor and description |
---|
Association
(PersistentEntity owner, MappingContext context, java.beans.PropertyDescriptor descriptor) |
Association
(PersistentEntity owner, MappingContext context, java.lang.String name, java.lang.Class type) |
Type Params | Return Type | Name and description |
---|---|---|
|
public boolean |
doesCascade(javax.persistence.CascadeType cascadeOperation) Returns true if the this association cascade for the given cascade operation |
|
public boolean |
doesCascade(javax.persistence.CascadeType cascadeOperations) Returns true if this association cascades for the given cascade operation |
|
public boolean |
doesCascadeValidate(java.lang.Object associatedObject) Returns true if this association should cascade validation to the given entity. |
|
public PersistentEntity |
getAssociatedEntity()
|
|
protected java.util.Set<javax.persistence.CascadeType> |
getCascadeOperations() |
|
protected CascadeValidateType |
getCascadeValidateOperation() |
|
public javax.persistence.FetchType |
getFetchStrategy()
|
|
public Association |
getInverseSide()
|
|
public java.lang.String |
getReferencedPropertyName()
|
|
public boolean |
isBasic()
|
|
public boolean |
isBidirectional()
|
|
public boolean |
isCircular()
|
|
public boolean |
isEmbedded()
|
|
public boolean |
isList()
|
|
public boolean |
isOrphanRemoval()
|
|
public boolean |
isOwningSide() Returns whether this side owns the relationship. |
|
public void |
setAssociatedEntity(PersistentEntity associatedEntity) Sets the associated entity |
|
public void |
setOwningSide(boolean owningSide) Sets whether this association is the owning side |
|
public void |
setReferencedPropertyName(java.lang.String referencedPropertyName) Sets the name of the inverse property |
|
public java.lang.String |
toString() |
Methods inherited from class | Name |
---|---|
class AbstractPersistentProperty |
getCapitilizedName, getName, getOwner, getReader, getType, getWriter, isInherited, isNullable, toString |
Returns true if the this association cascade for the given cascade operation
cascadeOperation
- The cascadeOperationReturns true if this association cascades for the given cascade operation
cascadeOperations
- The cascadeOperationsReturns true if this association should cascade validation to the given entity. Note that if the object state is persisted, it may still be validated as part of the object graph.
associatedObject
- The associated object that may or may not be validated further
Returns whether this side owns the relationship. This controls the default cascading behavior if none is specified
Sets the associated entity
associatedEntity
- The associated entitySets whether this association is the owning side
owningSide
- True if it isSets the name of the inverse property
referencedPropertyName
- The referenced property name