| java.util.TreeMap org.jpox.sco.TreeMap
Method Summary | |
protected void | addQueuedOperation(QueuedOperation op) Convenience method to add a queued operation to the operations we perform at commit. | public void | attachCopy(Object value) Method to return an attached copy of the passed (detached) value. | public void | clear() Method to clear the TreeMap. | public Object | clone() Creates and returns a copy of this object.
Mutable second-class Objects are required to provide a public
clone method in order to allow for copying PersistenceCapable
objects. | public Comparator | comparator() Accessor for the comparator. | public boolean | containsKey(Object key) | public boolean | containsValue(Object value) Method to return if the map contains this value. | public Object | detachCopy(FetchPlanState state) Method to return a detached copy of the container. | public java.util.Set | entrySet() Accessor for the set of entries in the Map. | public synchronized boolean | equals(Object o) Method to check the equality of this map, and another.
Parameters: o - The map to compare against. | public Object | firstKey() Accessor for the first key in the sorted map. | public void | flush() Method to flush the changes to the datastore when operating in queued mode. | public Object | get(Object key) Accessor for the value stored against a key. | public String | getFieldName() Accessor for the field name that this TreeMap relates to. | public Object | getOwner() Accessor for the owner that this TreeMap relates to. | public Object | getValue() Accessor for the unwrapped value that we are wrapping. | public synchronized int | hashCode() Method to generate a hashcode for this Map. | public SortedMap | headMap(Object toKey) Method to retrieve the head of the map up to the specified key.
Parameters: toKey - the key to return up to. | public void | initialise(Object o, boolean forInsert, boolean forUpdate) Method to initialise the SCO from an existing value. | public void | initialise() Method to initialise the SCO for use. | public boolean | isEmpty() Method to return if the Map is empty. | public java.util.Set | keySet() Accessor for the set of keys in the Map. | public Object | lastKey() Accessor for the last key in the sorted map. | public void | load() Method to effect the load of the data in the SCO. | protected void | loadFromStore() Method to load all elements from the "backing store" where appropriate. | public void | makeDirty() | public synchronized QueryExpression | newQueryStatement() Method to generate a QueryStatement for the SCO. | public synchronized QueryExpression | newQueryStatement(Class candidateClass, DatastoreIdentifier candidateAlias) Method to return a QueryStatement, using the specified candidate class. | public synchronized ResultObjectFactory | newResultObjectFactory(QueryExpression stmt, boolean ignoreCache, Class resultClass, boolean useFetchPlan) Method to return a new result object factory for processing of Query
statements. | public Object | put(Object key, Object value) Method to add a value against a key to the TreeMap. | public void | putAll(java.util.Map m) Method to add the specified Map's values under their keys here. | public Object | remove(Object key) Method to remove the value for a key from the TreeMap. | public int | size() Method to return the size of the Map. | public SortedMap | subMap(Object fromKey, Object toKey) Method to retrieve the subset of the map between the specified keys. | public SortedMap | tailMap(Object fromKey) Method to retrieve the part of the map after the specified key. | public synchronized void | unsetOwner() Method to unset the owner and field details. | public void | updateEmbeddedKey(Object key, int fieldNumber, Object newValue) Method to update an embedded key in this map. | public void | updateEmbeddedValue(Object value, int fieldNumber, Object newValue) Method to update an embedded value in this map. | public Collection | values() Accessor for the set of values in the Map. | protected Object | writeReplace() The writeReplace method is called when ObjectOutputStream is preparing
to write the object to the stream. |
isCacheLoaded | protected boolean isCacheLoaded(Code) | | Status flag whether the map is loaded into the cache.
|
queued | boolean queued(Code) | | Whether the SCO is in "direct" or "queued" mode.
|
useCache | protected boolean useCache(Code) | | Whether to use "delegate" caching.
|
TreeMap | public TreeMap(StateManager ownerSM, String fieldName)(Code) | | Constructor
Parameters: ownerSM - the owner StateManager Parameters: fieldName - the field name |
addQueuedOperation | protected void addQueuedOperation(QueuedOperation op)(Code) | | Convenience method to add a queued operation to the operations we perform at commit.
Parameters: op - The operation |
attachCopy | public void attachCopy(Object value)(Code) | | Method to return an attached copy of the passed (detached) value. The returned attached copy
is a SCO wrapper. Goes through the existing keys/values in the store for this owner field and
removes ones no longer present, and adds new keys/values. All keys/values in the (detached)
value are attached.
Parameters: value - The new (map) value |
clear | public void clear()(Code) | | Method to clear the TreeMap.
|
clone | public Object clone()(Code) | | Creates and returns a copy of this object.
Mutable second-class Objects are required to provide a public
clone method in order to allow for copying PersistenceCapable
objects. In contrast to Object.clone(), this method must not throw a
CloneNotSupportedException.
The cloned object |
comparator | public Comparator comparator()(Code) | | Accessor for the comparator.
The comparator |
containsKey | public boolean containsKey(Object key)(Code) | | Method to return if the map contains this key
Parameters: key - The key Whether it is contained |
containsValue | public boolean containsValue(Object value)(Code) | | Method to return if the map contains this value.
Parameters: value - The value Whether it is contained |
detachCopy | public Object detachCopy(FetchPlanState state)(Code) | | Method to return a detached copy of the container.
Recurse sthrough the keys/values so that they are likewise detached.
Parameters: state - State for detachment process The detached container |
entrySet | public java.util.Set entrySet()(Code) | | Accessor for the set of entries in the Map.
Set of entries |
equals | public synchronized boolean equals(Object o)(Code) | | Method to check the equality of this map, and another.
Parameters: o - The map to compare against. Whether they are equal. |
firstKey | public Object firstKey()(Code) | | Accessor for the first key in the sorted map.
The first key |
flush | public void flush()(Code) | | Method to flush the changes to the datastore when operating in queued mode.
Does nothing in "direct" mode.
|
get | public Object get(Object key)(Code) | | Accessor for the value stored against a key.
Parameters: key - The key The value. |
getFieldName | public String getFieldName()(Code) | | Accessor for the field name that this TreeMap relates to.
The field name |
getOwner | public Object getOwner()(Code) | | Accessor for the owner that this TreeMap relates to.
The owner |
getValue | public Object getValue()(Code) | | Accessor for the unwrapped value that we are wrapping.
The unwrapped value |
hashCode | public synchronized int hashCode()(Code) | | Method to generate a hashcode for this Map.
The hashcode. |
headMap | public SortedMap headMap(Object toKey)(Code) | | Method to retrieve the head of the map up to the specified key.
Parameters: toKey - the key to return up to. The map meeting the input |
initialise | public void initialise(Object o, boolean forInsert, boolean forUpdate)(Code) | | Method to initialise the SCO from an existing value.
Parameters: o - Object to set value using. Parameters: forInsert - Whether the object needs inserting in the datastore with this value Parameters: forUpdate - Whether to update the datastore with this value |
initialise | public void initialise()(Code) | | Method to initialise the SCO for use.
|
isEmpty | public boolean isEmpty()(Code) | | Method to return if the Map is empty.
Whether it is empty. |
keySet | public java.util.Set keySet()(Code) | | Accessor for the set of keys in the Map.
Set of keys. |
lastKey | public Object lastKey()(Code) | | Accessor for the last key in the sorted map.
The last key |
load | public void load()(Code) | | Method to effect the load of the data in the SCO.
Used when the SCO supports lazy-loading to tell it to load all now.
|
loadFromStore | protected void loadFromStore()(Code) | | Method to load all elements from the "backing store" where appropriate.
|
makeDirty | public void makeDirty()(Code) | | Utility to mark the object as dirty
|
newQueryStatement | public synchronized QueryExpression newQueryStatement()(Code) | | Method to generate a QueryStatement for the SCO.
The QueryStatement |
newQueryStatement | public synchronized QueryExpression newQueryStatement(Class candidateClass, DatastoreIdentifier candidateAlias)(Code) | | Method to return a QueryStatement, using the specified candidate class.
Parameters: candidateClass - the candidate class Parameters: candidateAlias - Alias for the candidate The QueryStatement |
newResultObjectFactory | public synchronized ResultObjectFactory newResultObjectFactory(QueryExpression stmt, boolean ignoreCache, Class resultClass, boolean useFetchPlan)(Code) | | Method to return a new result object factory for processing of Query
statements.
Parameters: stmt - The Query Statement. Parameters: ignoreCache - Whether to ignore the cache. Parameters: resultClass - Whether to create objects of a particular class Parameters: useFetchPlan - whether to use the fetch plan to retrieve fields in the same query The result object factory. |
put | public Object put(Object key, Object value)(Code) | | Method to add a value against a key to the TreeMap.
Parameters: key - The key Parameters: value - The value The previous value for the specified key. |
putAll | public void putAll(java.util.Map m)(Code) | | Method to add the specified Map's values under their keys here.
Parameters: m - The map |
remove | public Object remove(Object key)(Code) | | Method to remove the value for a key from the TreeMap.
Parameters: key - The key to remove The value that was removed from this key. |
size | public int size()(Code) | | Method to return the size of the Map.
The size |
subMap | public SortedMap subMap(Object fromKey, Object toKey)(Code) | | Method to retrieve the subset of the map between the specified keys.
Parameters: fromKey - The start key Parameters: toKey - The end key The map meeting the input |
tailMap | public SortedMap tailMap(Object fromKey)(Code) | | Method to retrieve the part of the map after the specified key.
Parameters: fromKey - The start key The map meeting the input |
unsetOwner | public synchronized void unsetOwner()(Code) | | Method to unset the owner and field details.
|
updateEmbeddedKey | public void updateEmbeddedKey(Object key, int fieldNumber, Object newValue)(Code) | | Method to update an embedded key in this map.
Parameters: key - The key Parameters: fieldNumber - Number of field in the key Parameters: newValue - New value for this field |
updateEmbeddedValue | public void updateEmbeddedValue(Object value, int fieldNumber, Object newValue)(Code) | | Method to update an embedded value in this map.
Parameters: value - The value Parameters: fieldNumber - Number of field in the value Parameters: newValue - New value for this field |
values | public Collection values()(Code) | | Accessor for the set of values in the Map.
Set of values. |
writeReplace | protected Object writeReplace() throws ObjectStreamException(Code) | | The writeReplace method is called when ObjectOutputStream is preparing
to write the object to the stream. The ObjectOutputStream checks whether
the class defines the writeReplace method. If the method is defined, the
writeReplace method is called to allow the object to designate its
replacement in the stream. The object returned should be either of the
same type as the object passed in or an object that when read and
resolved will result in an object of a type that is compatible with all
references to the object.
the replaced object throws: ObjectStreamException - |
Methods inherited from java.util.TreeMap | public Map.Entry<K, V> ceilingEntry(K key)(Code)(Java Doc) public K ceilingKey(K key)(Code)(Java Doc) public void clear()(Code)(Java Doc) public Object clone()(Code)(Java Doc) public Comparator<? super K> comparator()(Code)(Java Doc) public boolean containsKey(Object key)(Code)(Java Doc) public boolean containsValue(Object value)(Code)(Java Doc) public NavigableSet<K> descendingKeySet()(Code)(Java Doc) public NavigableMap<K, V> descendingMap()(Code)(Java Doc) public Set<Map.Entry<K, V>> entrySet()(Code)(Java Doc) public Map.Entry<K, V> firstEntry()(Code)(Java Doc) public K firstKey()(Code)(Java Doc) public Map.Entry<K, V> floorEntry(K key)(Code)(Java Doc) public K floorKey(K key)(Code)(Java Doc) public V get(Object key)(Code)(Java Doc) public NavigableMap<K, V> headMap(K toKey, boolean inclusive)(Code)(Java Doc) public SortedMap<K, V> headMap(K toKey)(Code)(Java Doc) public Map.Entry<K, V> higherEntry(K key)(Code)(Java Doc) public K higherKey(K key)(Code)(Java Doc) public Set<K> keySet()(Code)(Java Doc) public Map.Entry<K, V> lastEntry()(Code)(Java Doc) public K lastKey()(Code)(Java Doc) public Map.Entry<K, V> lowerEntry(K key)(Code)(Java Doc) public K lowerKey(K key)(Code)(Java Doc) public NavigableSet<K> navigableKeySet()(Code)(Java Doc) public Map.Entry<K, V> pollFirstEntry()(Code)(Java Doc) public Map.Entry<K, V> pollLastEntry()(Code)(Java Doc) public V put(K key, V value)(Code)(Java Doc) public void putAll(Map<? extends K, ? extends V> map)(Code)(Java Doc) public V remove(Object key)(Code)(Java Doc) public int size()(Code)(Java Doc) public NavigableMap<K, V> subMap(K fromKey, boolean fromInclusive, K toKey, boolean toInclusive)(Code)(Java Doc) public SortedMap<K, V> subMap(K fromKey, K toKey)(Code)(Java Doc) public NavigableMap<K, V> tailMap(K fromKey, boolean inclusive)(Code)(Java Doc) public SortedMap<K, V> tailMap(K fromKey)(Code)(Java Doc) public Collection<V> values()(Code)(Java Doc)
|
|
|