public abstract class DirectAccessRegionTemplate extends AbstractRegion implements DirectAccessRegion
Bridge between DirectAccessRegion and StorageAccess
| Constructor and Description |
|---|
DirectAccessRegionTemplate(String name,
RegionFactory regionFactory,
StorageAccess storageAccess)
Constructs a
DirectAccessRegionTemplate. |
| Modifier and Type | Method and Description |
|---|---|
void |
clear()
Clear all data cached in the region
|
void |
destroy()
The "end state" contract of the region’s lifecycle.
|
Object |
getFromCache(Object key,
SharedSessionContractImplementor session)
Get value by key
|
StorageAccess |
getStorageAccess() |
void |
putIntoCache(Object key,
Object value,
SharedSessionContractImplementor session)
Put a value by key
|
getName, getRegionFactoryclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetName, getRegionFactorypublic DirectAccessRegionTemplate(String name, RegionFactory regionFactory, StorageAccess storageAccess)
Constructs a DirectAccessRegionTemplate.
name - - the unqualified region nameregionFactory - - the region factorystorageAccess - - the cache storage access strategypublic StorageAccess getStorageAccess()
public Object getFromCache(Object key, SharedSessionContractImplementor session)
DirectAccessRegionGet value by key
getFromCache in interface DirectAccessRegionpublic void putIntoCache(Object key, Object value, SharedSessionContractImplementor session)
DirectAccessRegionPut a value by key
putIntoCache in interface DirectAccessRegionpublic void clear()
RegionClear all data cached in the region
public void destroy()
RegionThe "end state" contract of the region’s lifecycle. Called
during SessionFactory.close() to give
the region a chance to cleanup.
Copyright © 2001-2018 Red Hat, Inc. All Rights Reserved.