Package org.hibernate.cache.spi.support
Class DirectAccessRegionTemplate
java.lang.Object
org.hibernate.cache.spi.support.AbstractRegion
org.hibernate.cache.spi.support.DirectAccessRegionTemplate
- All Implemented Interfaces:
DirectAccessRegion
,Region
- Direct Known Subclasses:
QueryResultsRegionTemplate
,TimestampsRegionTemplate
public abstract class DirectAccessRegionTemplate
extends AbstractRegion
implements DirectAccessRegion
Bridge between DirectAccessRegion and StorageAccess
-
Constructor Summary
ConstructorsConstructorDescriptionDirectAccessRegionTemplate
(String name, RegionFactory regionFactory, StorageAccess storageAccess) Constructs aDirectAccessRegionTemplate
. -
Method Summary
Modifier and TypeMethodDescriptionvoid
clear()
Clear all data cached in the regionvoid
destroy()
The "end state" contract of the region's lifecycle.getFromCache
(Object key, SharedSessionContractImplementor session) Get value by keyvoid
putIntoCache
(Object key, Object value, SharedSessionContractImplementor session) Put a value by keyMethods inherited from class org.hibernate.cache.spi.support.AbstractRegion
getName, getRegionFactory
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.hibernate.cache.spi.Region
getName, getRegionFactory
-
Constructor Details
-
DirectAccessRegionTemplate
public DirectAccessRegionTemplate(String name, RegionFactory regionFactory, StorageAccess storageAccess) Constructs aDirectAccessRegionTemplate
.- Parameters:
name
- - the unqualified region nameregionFactory
- - the region factorystorageAccess
- - the cache storage access strategy
-
-
Method Details
-
getStorageAccess
-
clear
public void clear()Description copied from interface:Region
Clear all data cached in the region -
destroy
public void destroy()Description copied from interface:Region
The "end state" contract of the region's lifecycle. Called duringSessionFactory.close()
to give the region a chance to cleanup.
-