org.datanucleus.store.mapped.scostore
Class FKArrayStore
java.lang.Object
org.datanucleus.store.mapped.scostore.BaseContainerStore
org.datanucleus.store.mapped.scostore.ElementContainerStore
org.datanucleus.store.mapped.scostore.AbstractArrayStore
org.datanucleus.store.mapped.scostore.FKArrayStore
- All Implemented Interfaces:
- ArrayStoreQueryable, ArrayStore, Store
public abstract class FKArrayStore
- extends AbstractArrayStore
Backing store for an array that is formed by a foreign key in the table of the
element type. Only supported when the element is a PersistenceCapable type (since
that has its own element table, capable of having a FK!)
| Fields inherited from class org.datanucleus.store.mapped.scostore.ElementContainerStore |
clr, containerTable, elementInfo, elementIsPersistentInterface, elementMapping, elementsAreEmbedded, elementsAreSerialised, elementType, emd, iterateUsingDiscriminator, orderMapping, relationDiscriminatorMapping, relationDiscriminatorValue, specialization |
| Methods inherited from class org.datanucleus.store.mapped.scostore.ElementContainerStore |
getContainerTable, getElementInfo, getElementInformationForClass, getElementMapping, getElementType, getEmd, getOrderMapping, getRelationDiscriminatorMapping, getRelationDiscriminatorValue, hasOrderMapping, isElementsAreEmbedded, isElementsAreSerialised, size, validateElementForReading, validateElementForWriting, validateElementType |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
FKArrayStore
public FKArrayStore(AbstractMemberMetaData fmd,
MappedStoreManager storeMgr,
ClassLoaderResolver clr,
FKArrayStoreSpecialization specialization)
- Constructor.
- Parameters:
fmd - Field MetaData for the field that this representsstoreMgr - The Store Manager in useclr - The ClassLoaderResolver
clear
public void clear(StateManager ownerSM)
- Method to clear the Array.
This is called when the container object is being deleted and the elements are to be removed (maybe for dependent field).
- Specified by:
clear in interface ArrayStore- Overrides:
clear in class AbstractArrayStore
- Parameters:
ownerSM - The state manager
set
public boolean set(StateManager ownerSM,
java.lang.Object array)
- Method to set the array for the specified owner to the passed value.
- Specified by:
set in interface ArrayStore- Overrides:
set in class AbstractArrayStore
- Parameters:
ownerSM - State Manager for the ownerarray - the array
- Returns:
- Whether the array was updated successfully
joinElementsTo
public ScalarExpression joinElementsTo(QueryExpression stmt,
QueryExpression parentStmt,
JavaTypeMapping ownerMapping,
LogicSetExpression ownerTe,
DatastoreIdentifier listTableAlias,
java.lang.Class filteredElementType,
ScalarExpression elmExpr,
DatastoreIdentifier elementTableAlias)
- Method used in queries when contains() has been invoked.
- Parameters:
stmt - The Query StatementparentStmt - the parent Query Statement. If there is no parent, parentStmt must be equals to stmtownerMapping - the mapping for the owner.ownerTe - Table Expression for the ownerlistTableAlias - alias for the "List" table.filteredElementType - The Class Type for the filtered elementelmExpr - The Expression for the elementelementTableAlias - The SQL alias to assign to the expression for the element table.
- Returns:
- expression to the join
Copyright © 2010. All Rights Reserved.