|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.datanucleus.store.rdbms.scostore.BaseContainerStore
org.datanucleus.store.rdbms.scostore.ElementContainerStore
org.datanucleus.store.rdbms.scostore.AbstractCollectionStore
org.datanucleus.store.rdbms.scostore.AbstractSetStore
org.datanucleus.store.rdbms.scostore.RDBMSFKSetStore
public class RDBMSFKSetStore
RDBMS-specific implementation of an SetStore using foreign keys.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class org.datanucleus.store.rdbms.scostore.ElementContainerStore |
|---|
ElementContainerStore.ElementInfo |
| Field Summary |
|---|
| Fields inherited from class org.datanucleus.store.rdbms.scostore.AbstractCollectionStore |
|---|
containsStmt |
| Fields inherited from class org.datanucleus.store.rdbms.scostore.ElementContainerStore |
|---|
addStmt, clearStmt, clr, containerTable, elementInfo, elementIsPersistentInterface, elementMapping, elementsAreEmbedded, elementsAreSerialised, elementType, emd, iterateUsingDiscriminator, orderMapping, relationDiscriminatorMapping, relationDiscriminatorValue, removeStmt, sizeStmt, usingDiscriminatorInSizeStmt |
| Fields inherited from class org.datanucleus.store.rdbms.scostore.BaseContainerStore |
|---|
allowNulls, dba, LOCALISER, ownerMapping, ownerMemberMetaData, relationType, storeMgr |
| Constructor Summary | |
|---|---|
RDBMSFKSetStore(org.datanucleus.metadata.AbstractMemberMetaData mmd,
RDBMSStoreManager storeMgr,
org.datanucleus.ClassLoaderResolver clr)
Constructor for the backing store of a FK set for RDBMS. |
|
| Method Summary | |
|---|---|
boolean |
add(org.datanucleus.store.ObjectProvider op,
Object element,
int size)
Method to add an object to the relationship at the collection end. |
boolean |
addAll(org.datanucleus.store.ObjectProvider op,
Collection elements,
int size)
Method to add a collection of object to the relationship at the collection end. |
protected boolean |
checkRemovalOfElementShouldDelete(org.datanucleus.store.ObjectProvider op)
Convenience method to return if the removal of an element should delete the element. |
void |
clear(org.datanucleus.store.ObjectProvider op)
Method to allow the Set relationship to be cleared out. |
protected String |
getClearNullifyStmt()
Generates the statement for clearing items by nulling the owner link out. |
protected int |
getFieldNumberInElementForBidirectional(org.datanucleus.store.ObjectProvider op)
This seems to return the field number in the element of the relation when it is a bidirectional relation. |
protected SQLStatement |
getSQLStatementForIterator(org.datanucleus.store.ObjectProvider op)
Method to generate an SQLStatement for iterating through elements of the set. |
Iterator |
iterator(org.datanucleus.store.ObjectProvider op)
Accessor for an iterator for the set. |
protected void |
manageRemovalOfElement(org.datanucleus.store.ObjectProvider op,
Object element)
Convenience method to manage the removal of an element from the collection, performing any necessary "managed relationship" updates when the field is bidirectional. |
boolean |
remove(org.datanucleus.store.ObjectProvider op,
Object element,
int size,
boolean allowDependentField)
Method to remove the link to the collection object specified. |
boolean |
removeAll(org.datanucleus.store.ObjectProvider op,
Collection elements,
int size)
Method to remove the links to a collection of elements specified. |
void |
update(org.datanucleus.store.ObjectProvider op,
Collection coll)
Method to update the collection to be the supplied collection of elements. |
| Methods inherited from class org.datanucleus.store.rdbms.scostore.AbstractSetStore |
|---|
internalAdd, internalRemove, remove |
| Methods inherited from class org.datanucleus.store.rdbms.scostore.AbstractCollectionStore |
|---|
contains, containsInternal, getRemoveStmt, getUpdateEmbeddedElementStmt, updateEmbeddedElement, updateEmbeddedElement |
| Methods inherited from class org.datanucleus.store.rdbms.scostore.ElementContainerStore |
|---|
executeClear, getAddStmt, getClearStmt, getContainerTable, getElementInfo, getElementInformationForClass, getElementMapping, getEmd, getOrderMapping, getRelationDiscriminatorMapping, getRelationDiscriminatorValue, getSize, getSizeStmt, hasOrderMapping, invalidateAddStmt, isElementsAreEmbedded, isElementsAreSerialised, size, validateElementForReading, validateElementForWriting, validateElementType |
| Methods inherited from class org.datanucleus.store.rdbms.scostore.BaseContainerStore |
|---|
allowsBatching, getDatastoreAdapter, getOwnerMapping, getOwnerMemberMetaData, getRelationType, getStateManagerForEmbeddedPCObject, getStoreManager, isEmbeddedMapping, setOwner |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.datanucleus.store.scostore.CollectionStore |
|---|
contains, hasOrderMapping, size, updateEmbeddedElement |
| Methods inherited from interface org.datanucleus.store.scostore.Store |
|---|
getStoreManager |
| Constructor Detail |
|---|
public RDBMSFKSetStore(org.datanucleus.metadata.AbstractMemberMetaData mmd,
RDBMSStoreManager storeMgr,
org.datanucleus.ClassLoaderResolver clr)
mmd - The MetaData for the field that this representsstoreMgr - The MappedStoreManager managing the associated datastore.clr - The ClassLoaderResolver| Method Detail |
|---|
protected int getFieldNumberInElementForBidirectional(org.datanucleus.store.ObjectProvider op)
op - ObjectProvider for the owner.
public void update(org.datanucleus.store.ObjectProvider op,
Collection coll)
update in interface org.datanucleus.store.scostore.CollectionStoreupdate in class AbstractCollectionStoreop - ObjectProvider for the owner.coll - The collection to use
public boolean add(org.datanucleus.store.ObjectProvider op,
Object element,
int size)
add in interface org.datanucleus.store.scostore.CollectionStoreadd in class AbstractSetStoreop - ObjectProvider for the owner.element - Element to be added
public boolean addAll(org.datanucleus.store.ObjectProvider op,
Collection elements,
int size)
addAll in interface org.datanucleus.store.scostore.CollectionStoreaddAll in class AbstractSetStoreop - ObjectProvider for the owner.elements - Elements to be addedsize - Current size of set (if known). Not used by sets
public boolean remove(org.datanucleus.store.ObjectProvider op,
Object element,
int size,
boolean allowDependentField)
remove in interface org.datanucleus.store.scostore.CollectionStoreremove in class AbstractSetStoreop - ObjectProvider for the owner.element - The element of the collection to be deleted.allowDependentField - Whether to allow any cascade deletes caused by this removalsize - Current size
public boolean removeAll(org.datanucleus.store.ObjectProvider op,
Collection elements,
int size)
removeAll in interface org.datanucleus.store.scostore.CollectionStoreremoveAll in class AbstractSetStoreop - ObjectProvider for the owner.elements - The elements of the collection to be deleted.
protected boolean checkRemovalOfElementShouldDelete(org.datanucleus.store.ObjectProvider op)
op - ObjectProvider for the owner.
protected void manageRemovalOfElement(org.datanucleus.store.ObjectProvider op,
Object element)
op - ObjectProvider for the owner.element - The elementpublic void clear(org.datanucleus.store.ObjectProvider op)
clear in interface org.datanucleus.store.scostore.CollectionStoreclear in class ElementContainerStoreop - ObjectProvider for the owner.protected String getClearNullifyStmt()
UPDATE LISTTABLE SET OWNERCOL=NULL [,DISTINGUISHER=NULL] WHERE OWNERCOL=?when there is only one element table, and will be
UPDATE
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||