Class PersistentSortedMap<K,E>
java.lang.Object
org.hibernate.collection.spi.AbstractPersistentCollection<E>
org.hibernate.collection.spi.PersistentMap<K,E>
org.hibernate.collection.spi.PersistentSortedMap<K,E>
- All Implemented Interfaces:
Serializable, Map<K,E>, SequencedMap<K, E>, SortedMap<K, E>, LazyInitializable, PersistentCollection<E>, InstanceIdentity
@Incubating
public class PersistentSortedMap<K,E>
extends PersistentMap<K,E>
implements SortedMap<K,E>
A persistent wrapper for a
SortedMap. Underlying
collection is a TreeMap.- See Also:
- API Note:
- Incubating in terms of making this non-internal. These contracts will be getting cleaned up in following releases.
-
Nested Class Summary
Nested classes/interfaces inherited from class AbstractPersistentCollection
AbstractPersistentCollection.AbstractValueDelayedOperation, AbstractPersistentCollection.DelayedOperation<E>, AbstractPersistentCollection.IteratorProxy<E>, AbstractPersistentCollection.LazyInitializationWork<T>, AbstractPersistentCollection.ListIteratorProxy, AbstractPersistentCollection.ListProxy, AbstractPersistentCollection.SetProxy<E>, AbstractPersistentCollection.ValueDelayedOperation<E> -
Field Summary
FieldsFields inherited from class PersistentMap
mapFields inherited from class AbstractPersistentCollection
elementRemoved, UNKNOWN -
Constructor Summary
ConstructorsConstructorDescriptionConstructs a PersistentSortedMap.PersistentSortedMap(SharedSessionContractImplementor session, Comparator<K> comparator) Constructs a PersistentSortedMap.PersistentSortedMap(SharedSessionContractImplementor session, SortedMap<K, E> map) Constructs a PersistentSortedMap. -
Method Summary
Modifier and TypeMethodDescriptionComparator<? super K> firstKey()lastKey()voidsetComparator(Comparator<? super K> comparator) protected Serializablesnapshot(BasicCollectionPersister persister) Methods inherited from class PersistentMap
clear, containsKey, containsValue, disassemble, empty, entries, entryExists, entrySet, equals, equalsSnapshot, get, getDeletes, getElement, getIndex, getOrphans, getSnapshot, getSnapshotElement, hasDeletes, hashCode, initializeEmptyCollection, initializeFromCache, injectLoadedState, isEmpty, isSnapshotEmpty, isWrapper, keySet, needsInserting, needsUpdating, put, putAll, remove, size, toString, valuesMethods inherited from class AbstractPersistentCollection
$$_hibernate_getInstanceId, $$_hibernate_setInstanceId, afterInitialize, afterRowInsert, beforeInitialize, beginRead, checkPersister, clearDirty, clearOperationQueue, dirty, elementByIndex, elementExists, endRead, forceInitialization, getCachedSize, getIdentifier, getKey, getOrphans, getOwner, getQueuedOrphans, getRole, getSession, getSize, getSnapshot, getStoredSnapshot, getValue, hasQueuedOperations, identityRemove, initialize, isClearQueueEnabled, isConnectedToSession, isDirectlyAccessible, isDirty, isElementRemoved, isInitialized, isInitializing, isInverseCollection, isInverseCollectionNoOrphanDelete, isInverseOneToManyOrNoOrphanDelete, isOperationQueueEnabled, isPutQueueEnabled, isRowUpdatePossible, isUnreferenced, needsRecreate, performQueuedOperations, postAction, preInsert, prepareForPossibleLoadingOutsideTransaction, queuedAdditionIterator, queueOperation, read, readElementByIndex, readElementExistence, readIndexExistence, readSize, replaceQueuedOperationValues, setCurrentSession, setDirectlyAccessible, setInitialized, setOwner, setSnapshot, unsetSession, wasInitialized, writeMethods inherited from interface Map
clear, compute, computeIfAbsent, computeIfPresent, containsKey, containsValue, equals, forEach, get, getOrDefault, hashCode, isEmpty, merge, put, putAll, putIfAbsent, remove, remove, replace, replace, replaceAll, sizeMethods inherited from interface PersistentCollection
includeInInsert, includeInRecreate, isDirectlyProvidedCollection, isNewlyInstantiated, needsUpdating, renderMethods inherited from interface SequencedMap
firstEntry, lastEntry, pollFirstEntry, pollLastEntry, sequencedEntrySet, sequencedKeySet, sequencedValues
-
Field Details
-
comparator
-
-
Constructor Details
-
PersistentSortedMap
public PersistentSortedMap()Constructs a PersistentSortedMap. This form needed for SOAP libraries, etc
-
-
Method Details
-
snapshot
- Throws:
HibernateException
-
setComparator
-
comparator
- Specified by:
comparatorin interfaceSortedMap<K,E>
-
subMap
-
headMap
-
tailMap
-
firstKey
-
lastKey
-