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 |
---|---|---|
|
boolean |
doesCascade(javax.persistence.CascadeType cascadeOperation) Returns true if the this association cascade for the given cascade operation |
|
boolean |
doesCascade(javax.persistence.CascadeType... cascadeOperations) Returns true if the this association cascade for the given cascade operation |
|
PersistentEntity |
getAssociatedEntity() @return The entity associated with the this association |
|
protected java.util.Set<javax.persistence.CascadeType> |
getCascadeOperations() |
|
javax.persistence.FetchType |
getFetchStrategy() @return The fetch strategy for the association |
|
Association |
getInverseSide() @return The inverse side or null if the association is not bidirectional |
|
java.lang.String |
getReferencedPropertyName() @return Returns the name of the inverse property or null if this association is unidirectional |
|
boolean |
isBasic() @return Whether this association is embedded |
|
boolean |
isBidirectional() @return True if the association is bidirectional |
|
boolean |
isCircular() @return Whether the association is circular |
|
boolean |
isEmbedded() @return Whether this association is embedded |
|
boolean |
isList() @return Whether the association is a List |
|
boolean |
isOrphanRemoval() @return Whether orphaned entities should be removed when cascading deletes to this association |
|
boolean |
isOwningSide() Returns whether this side owns the relationship. |
|
void |
setAssociatedEntity(PersistentEntity associatedEntity) Sets the associated entity |
|
void |
setOwningSide(boolean owningSide) Sets whether this association is the owning side |
|
void |
setReferencedPropertyName(java.lang.String referencedPropertyName) Sets the name of the inverse property |
|
java.lang.String |
toString() |
Methods inherited from class | Name |
---|---|
class AbstractPersistentProperty |
getOwner, getWriter, isNullable, getReader, getCapitilizedName, toString, getName, isInherited, getType, wait, wait, wait, equals, hashCode, getClass, notify, notifyAll, getMapping |
class java.lang.Object |
java.lang.Object#wait(long, int), java.lang.Object#wait(long), java.lang.Object#wait(), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll() |
Returns true if the this association cascade for the given cascade operation
cascadeOperation
- The cascadeOperationReturns true if the this association cascade for the given cascade operation
cascadeOperations
- The cascadeOperations
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