|
||||||||||
| 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.AbstractMapStore
org.datanucleus.store.rdbms.scostore.RDBMSJoinMapStore
public class RDBMSJoinMapStore
RDBMS-specific implementation of an MapStore using join table.
| Field Summary | |
|---|---|
protected org.datanucleus.store.mapped.mapping.JavaTypeMapping |
adapterMapping
when the element mappings columns can't be part of the primary key by datastore limitations like BLOB types. |
protected org.datanucleus.ClassLoaderResolver |
clr
|
| Fields inherited from class org.datanucleus.store.rdbms.scostore.AbstractMapStore |
|---|
iterateUsingDiscriminator, keyMapping, keysAreEmbedded, keysAreSerialised, keyType, kmd, mapTable, valueMapping, valuesAreEmbedded, valuesAreSerialised, valueTable, valueType, vmd |
| Fields inherited from class org.datanucleus.store.rdbms.scostore.BaseContainerStore |
|---|
allowNulls, dba, LOCALISER, ownerMapping, ownerMemberMetaData, relationType, storeMgr |
| Constructor Summary | |
|---|---|
RDBMSJoinMapStore(MapTable mapTable,
org.datanucleus.ClassLoaderResolver clr)
Constructor for the backing store of a join map for RDBMS. |
|
| Method Summary | |
|---|---|
void |
clear(org.datanucleus.store.ObjectProvider ownerSM)
Method to clear the map of all values. |
protected void |
clearInternal(org.datanucleus.store.ObjectProvider ownerSM)
|
org.datanucleus.store.scostore.SetStore |
entrySetStore()
Accessor for the map entries in the Map. |
org.datanucleus.store.mapped.mapping.JavaTypeMapping |
getAdapterMapping()
|
protected SQLStatement |
getSQLStatementForGet(org.datanucleus.store.ObjectProvider ownerSM)
Method to return an SQLStatement for retrieving the value for a key. |
protected Object |
getValue(org.datanucleus.store.ObjectProvider ownerSM,
Object key)
Method to retrieve a value from the Map given the key. |
protected int[] |
internalPut(org.datanucleus.store.ObjectProvider ownerSM,
org.datanucleus.store.connection.ManagedConnection conn,
boolean batched,
Object key,
Object value,
boolean executeNow)
Method to process a "put" statement (where the key has no value in the join table). |
protected void |
internalUpdate(org.datanucleus.store.ObjectProvider ownerSM,
org.datanucleus.store.connection.ManagedConnection conn,
boolean batched,
Object key,
Object value,
boolean executeNow)
Method to process an "update" statement (where the key already has a value in the join table). |
org.datanucleus.store.scostore.SetStore |
keySetStore()
Accessor for the keys in the Map. |
protected org.datanucleus.store.scostore.SetStore |
newMapEntrySetStore()
|
protected org.datanucleus.store.scostore.SetStore |
newMapKeySetStore()
|
protected org.datanucleus.store.scostore.SetStore |
newMapValueSetStore()
|
Object |
put(org.datanucleus.store.ObjectProvider sm,
Object key,
Object value)
Method to put an item in the Map. |
void |
putAll(org.datanucleus.store.ObjectProvider sm,
Map m)
Method to put all elements from a Map into our Map. |
Object |
remove(org.datanucleus.store.ObjectProvider sm,
Object key)
Method to remove an item from the map. |
protected void |
removeInternal(org.datanucleus.store.ObjectProvider sm,
Object key)
|
org.datanucleus.store.scostore.SetStore |
valueSetStore()
Accessor for the values in the Map. |
| Methods inherited from class org.datanucleus.store.rdbms.scostore.AbstractMapStore |
|---|
containsKey, containsValue, get, getKeyMapping, getKmd, getMapTable, getUpdateEmbeddedKeyStmt, getUpdateEmbeddedValueStmt, getValueMapping, getVmd, initialise, isValuesAreEmbedded, isValuesAreSerialised, keysAreEmbedded, keysAreSerialised, updatedEmbeddedKey, updateEmbeddedKey, updateEmbeddedValue, updateEmbeddedValue, validateKeyForReading, validateKeyForWriting, validateKeyType, validateValueForReading, validateValueForWriting, validateValueType, valuesAreEmbedded, valuesAreSerialised |
| 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.Store |
|---|
getStoreManager |
| Field Detail |
|---|
protected final org.datanucleus.store.mapped.mapping.JavaTypeMapping adapterMapping
protected org.datanucleus.ClassLoaderResolver clr
| Constructor Detail |
|---|
public RDBMSJoinMapStore(MapTable mapTable,
org.datanucleus.ClassLoaderResolver clr)
mapTable - Join table for the Mapclr - The ClassLoaderResolver| Method Detail |
|---|
public void putAll(org.datanucleus.store.ObjectProvider sm,
Map m)
putAll in interface org.datanucleus.store.scostore.MapStoreputAll in class AbstractMapStoresm - State Manager for the Mapm - The Map to add
public Object put(org.datanucleus.store.ObjectProvider sm,
Object key,
Object value)
sm - State Manager for the map.key - The key to store the value againstvalue - The value to store.
public Object remove(org.datanucleus.store.ObjectProvider sm,
Object key)
sm - State Manager for the map.key - Key of the item to remove.
public void clear(org.datanucleus.store.ObjectProvider ownerSM)
ownerSM - State Manager for the map.public org.datanucleus.store.scostore.SetStore keySetStore()
public org.datanucleus.store.scostore.SetStore valueSetStore()
public org.datanucleus.store.scostore.SetStore entrySetStore()
public org.datanucleus.store.mapped.mapping.JavaTypeMapping getAdapterMapping()
protected Object getValue(org.datanucleus.store.ObjectProvider ownerSM,
Object key)
throws NoSuchElementException
getValue in class AbstractMapStoreownerSM - State Manager for the owner of the map.key - The key to retrieve the value for.
NoSuchElementException - if the value for the key was not foundprotected SQLStatement getSQLStatementForGet(org.datanucleus.store.ObjectProvider ownerSM)
ownerSM - StateManager for the owning object
protected void clearInternal(org.datanucleus.store.ObjectProvider ownerSM)
protected void removeInternal(org.datanucleus.store.ObjectProvider sm,
Object key)
protected org.datanucleus.store.scostore.SetStore newMapKeySetStore()
protected org.datanucleus.store.scostore.SetStore newMapValueSetStore()
protected org.datanucleus.store.scostore.SetStore newMapEntrySetStore()
protected void internalUpdate(org.datanucleus.store.ObjectProvider ownerSM,
org.datanucleus.store.connection.ManagedConnection conn,
boolean batched,
Object key,
Object value,
boolean executeNow)
throws org.datanucleus.store.mapped.exceptions.MappedDatastoreException
ownerSM - StateManager for the ownerconn - The Connectionbatched - Whether we are batching itkey - The keyvalue - The new valueexecuteNow - Whether to execute the statement now or wait til any batch
org.datanucleus.store.mapped.exceptions.MappedDatastoreException - Thrown if an error occurs
protected int[] internalPut(org.datanucleus.store.ObjectProvider ownerSM,
org.datanucleus.store.connection.ManagedConnection conn,
boolean batched,
Object key,
Object value,
boolean executeNow)
throws org.datanucleus.store.mapped.exceptions.MappedDatastoreException
ownerSM - StateManager for the ownerconn - The Connectionbatched - Whether we are batching itkey - The keyvalue - The valueexecuteNow - Whether to execute the statement now or wait til batching
org.datanucleus.store.mapped.exceptions.MappedDatastoreException - Thrown if an error occurs
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||