public class HDStorageImpl extends Object implements com.hazelcast.map.impl.recordstore.Storage<com.hazelcast.nio.serialization.Data,HDRecord>, ForcedEvictable<HDRecord>
Storage implementation for IMap.
This implementation can be used under multi-thread access.| Constructor and Description |
|---|
HDStorageImpl(HiDensityRecordProcessor<HDRecord> recordProcessor,
com.hazelcast.spi.serialization.SerializationService serializationService) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
addDeferredDispose(Object memoryBlock) |
void |
clear(boolean isDuringShutdown) |
boolean |
containsKey(com.hazelcast.nio.serialization.Data key) |
void |
destroy(boolean isDuringShutdown) |
void |
disposeDeferredBlocks() |
com.hazelcast.map.impl.record.Record |
extractRecordFromLazy(com.hazelcast.core.EntryView entryView) |
com.hazelcast.map.impl.iterator.MapEntriesWithCursor |
fetchEntries(int tableIndex,
int size,
com.hazelcast.spi.serialization.SerializationService serializationService) |
com.hazelcast.map.impl.iterator.MapKeysWithCursor |
fetchKeys(int tableIndex,
int size) |
HDRecord |
get(com.hazelcast.nio.serialization.Data key) |
com.hazelcast.map.impl.EntryCostEstimator |
getEntryCostEstimator() |
HDRecord |
getIfSameKey(com.hazelcast.nio.serialization.Data key) |
long |
getNativeKeyAddress(com.hazelcast.nio.serialization.Data key) |
Iterable |
getRandomSamples(int sampleCount) |
HiDensityRecordProcessor |
getRecordProcessor() |
boolean |
isEmpty() |
Iterator<HDRecord> |
mutationTolerantIterator() |
Iterator<HDRecord> |
newForcedEvictionValuesIterator()
Return iterator to be used for forced evictions.
|
void |
put(com.hazelcast.nio.serialization.Data key,
HDRecord record) |
void |
removeRecord(HDRecord record) |
void |
setEntryCostEstimator(com.hazelcast.map.impl.EntryCostEstimator entryCostEstimator) |
int |
size() |
protected NativeMemoryData |
toNative(com.hazelcast.nio.serialization.Data key) |
void |
updateRecordValue(com.hazelcast.nio.serialization.Data ignored,
HDRecord record,
Object value) |
Collection<HDRecord> |
values() |
public HDStorageImpl(HiDensityRecordProcessor<HDRecord> recordProcessor, com.hazelcast.spi.serialization.SerializationService serializationService)
public HiDensityRecordProcessor getRecordProcessor()
public void removeRecord(HDRecord record)
removeRecord in interface com.hazelcast.map.impl.recordstore.Storage<com.hazelcast.nio.serialization.Data,HDRecord>public boolean containsKey(com.hazelcast.nio.serialization.Data key)
containsKey in interface com.hazelcast.map.impl.recordstore.Storage<com.hazelcast.nio.serialization.Data,HDRecord>public void put(com.hazelcast.nio.serialization.Data key,
HDRecord record)
put in interface com.hazelcast.map.impl.recordstore.Storage<com.hazelcast.nio.serialization.Data,HDRecord>public void updateRecordValue(com.hazelcast.nio.serialization.Data ignored,
HDRecord record,
Object value)
updateRecordValue in interface com.hazelcast.map.impl.recordstore.Storage<com.hazelcast.nio.serialization.Data,HDRecord>public HDRecord get(com.hazelcast.nio.serialization.Data key)
get in interface com.hazelcast.map.impl.recordstore.Storage<com.hazelcast.nio.serialization.Data,HDRecord>public HDRecord getIfSameKey(com.hazelcast.nio.serialization.Data key)
getIfSameKey in interface com.hazelcast.map.impl.recordstore.Storage<com.hazelcast.nio.serialization.Data,HDRecord>public void clear(boolean isDuringShutdown)
clear in interface com.hazelcast.map.impl.recordstore.Storage<com.hazelcast.nio.serialization.Data,HDRecord>public Collection<HDRecord> values()
values in interface com.hazelcast.map.impl.recordstore.Storage<com.hazelcast.nio.serialization.Data,HDRecord>public Iterator<HDRecord> mutationTolerantIterator()
mutationTolerantIterator in interface com.hazelcast.map.impl.recordstore.Storage<com.hazelcast.nio.serialization.Data,HDRecord>public Iterator<HDRecord> newForcedEvictionValuesIterator()
ForcedEvictableIterator.remove()
method to remove a current record or a Storage.removeRecord(Object) - but it's only allowed to remove
a record the iterator is currently pointing to. No other modification of the underlying storage is
allowed while using this iterator.newForcedEvictionValuesIterator in interface ForcedEvictable<HDRecord>public int size()
size in interface com.hazelcast.map.impl.recordstore.Storage<com.hazelcast.nio.serialization.Data,HDRecord>public boolean isEmpty()
isEmpty in interface com.hazelcast.map.impl.recordstore.Storage<com.hazelcast.nio.serialization.Data,HDRecord>public void destroy(boolean isDuringShutdown)
destroy in interface com.hazelcast.map.impl.recordstore.Storage<com.hazelcast.nio.serialization.Data,HDRecord>public com.hazelcast.map.impl.EntryCostEstimator getEntryCostEstimator()
getEntryCostEstimator in interface com.hazelcast.map.impl.recordstore.Storage<com.hazelcast.nio.serialization.Data,HDRecord>public void setEntryCostEstimator(com.hazelcast.map.impl.EntryCostEstimator entryCostEstimator)
setEntryCostEstimator in interface com.hazelcast.map.impl.recordstore.Storage<com.hazelcast.nio.serialization.Data,HDRecord>public void disposeDeferredBlocks()
disposeDeferredBlocks in interface com.hazelcast.map.impl.recordstore.Storage<com.hazelcast.nio.serialization.Data,HDRecord>protected void addDeferredDispose(Object memoryBlock)
protected NativeMemoryData toNative(com.hazelcast.nio.serialization.Data key)
public Iterable getRandomSamples(int sampleCount)
getRandomSamples in interface com.hazelcast.map.impl.recordstore.Storage<com.hazelcast.nio.serialization.Data,HDRecord>public com.hazelcast.map.impl.iterator.MapKeysWithCursor fetchKeys(int tableIndex,
int size)
fetchKeys in interface com.hazelcast.map.impl.recordstore.Storage<com.hazelcast.nio.serialization.Data,HDRecord>public com.hazelcast.map.impl.iterator.MapEntriesWithCursor fetchEntries(int tableIndex,
int size,
com.hazelcast.spi.serialization.SerializationService serializationService)
fetchEntries in interface com.hazelcast.map.impl.recordstore.Storage<com.hazelcast.nio.serialization.Data,HDRecord>public com.hazelcast.map.impl.record.Record extractRecordFromLazy(com.hazelcast.core.EntryView entryView)
extractRecordFromLazy in interface com.hazelcast.map.impl.recordstore.Storage<com.hazelcast.nio.serialization.Data,HDRecord>public long getNativeKeyAddress(com.hazelcast.nio.serialization.Data key)
Copyright © 2021 Hazelcast, Inc.. All Rights Reserved.