public class CachePartitionSegment extends Object implements ConstructorFunction<String,ICacheRecordStore>
Responsible for all cache data of a partition. Creates and
looks up CacheRecordStore
s by name.
CacheService
manages all CachePartitionSegment
s.Modifier and Type | Field and Description |
---|---|
protected AbstractCacheService |
cacheService |
protected Object |
mutex |
protected int |
partitionId |
protected ConcurrentMap<String,ICacheRecordStore> |
recordStores |
Constructor and Description |
---|
CachePartitionSegment(AbstractCacheService cacheService,
int partitionId) |
Modifier and Type | Method and Description |
---|---|
void |
clear() |
ICacheRecordStore |
createNew(String name) |
void |
deleteRecordStore(String name,
boolean destroy) |
Collection<CacheConfig> |
getCacheConfigs() |
ICacheRecordStore |
getOrCreateRecordStore(String name) |
int |
getPartitionId() |
ICacheRecordStore |
getRecordStore(String name) |
boolean |
hasAnyRecordStore() |
boolean |
hasRecordStore(String name) |
void |
init() |
Iterator<ICacheRecordStore> |
recordStoreIterator() |
void |
shutdown() |
protected final AbstractCacheService cacheService
protected final int partitionId
protected final ConcurrentMap<String,ICacheRecordStore> recordStores
protected final Object mutex
public CachePartitionSegment(AbstractCacheService cacheService, int partitionId)
public ICacheRecordStore createNew(String name)
createNew
in interface ConstructorFunction<String,ICacheRecordStore>
public Iterator<ICacheRecordStore> recordStoreIterator()
public Collection<CacheConfig> getCacheConfigs()
public int getPartitionId()
public ICacheRecordStore getOrCreateRecordStore(String name)
public ICacheRecordStore getRecordStore(String name)
public void deleteRecordStore(String name, boolean destroy)
public boolean hasAnyRecordStore()
public boolean hasRecordStore(String name)
public void init()
public void clear()
public void shutdown()
Copyright © 2016 Hazelcast, Inc.. All Rights Reserved.