public interface CacheImplementor extends Service, Cache, Serializable
Define internal contact of <tt>Cache API</tt>
Modifier and Type | Method and Description |
---|---|
void |
close()
Close all cache regions.
|
CollectionRegionAccessStrategy |
determineCollectionRegionAccessStrategy(Collection model) |
EntityRegionAccessStrategy |
determineEntityRegionAccessStrategy(PersistentClass model) |
NaturalIdRegionAccessStrategy |
determineNaturalIdRegionAccessStrategy(PersistentClass model) |
void |
evictQueries()
Clean up the default
QueryCache . |
CollectionRegionAccessStrategy |
getCollectionRegionAccess(String regionName)
Find the "access strategy" for the named collection cache region.
|
QueryCache |
getDefaultQueryCache()
Get the default
QueryCache . |
EntityRegionAccessStrategy |
getEntityRegionAccess(String regionName)
Find the "access strategy" for the named entity cache region.
|
NaturalIdRegionAccessStrategy |
getNaturalIdCacheRegionAccessStrategy(String regionName)
Find the "access strategy" for the named natrual-id cache region.
|
default QueryCache |
getQueryCache()
Deprecated.
Use
getDefaultQueryCache() instead. |
QueryCache |
getQueryCache(String regionName)
Get query cache by <tt>region name</tt> or create a new one if none exist.
|
RegionFactory |
getRegionFactory()
The underlying RegionFactory in use.
|
String[] |
getSecondLevelCacheRegionNames()
Get the names of <tt>all</tt> cache regions, including entity, collection, natural-id and query caches.
|
UpdateTimestampsCache |
getUpdateTimestampsCache()
Get
UpdateTimestampsCache instance managed by the SessionFactory . |
String |
qualifyRegionName(String regionName)
Applies any defined prefix, handling all
null checks. |
containsCollection, containsEntity, containsEntity, containsQuery, evictAllRegions, evictCollection, evictCollectionRegion, evictCollectionRegions, evictDefaultQueryRegion, evictEntity, evictEntity, evictEntityRegion, evictEntityRegion, evictEntityRegions, evictNaturalIdRegion, evictNaturalIdRegion, evictNaturalIdRegions, evictQueryRegion, evictQueryRegions, getSessionFactory
void close()
Close all cache regions.
QueryCache getQueryCache(String regionName) throws HibernateException
Get query cache by <tt>region name</tt> or create a new one if none exist. <p/> If the region name is null, then default query cache region will be returned.
regionName
- Query cache region name.QueryCache
associated with the region name, or default query cache if the region name is <tt>null</tt>.HibernateException
- HibernateException
maybe thrown when the creation of new QueryCache instance.@Deprecated default QueryCache getQueryCache()
getDefaultQueryCache()
instead.Get the default QueryCache
.
QueryCache getDefaultQueryCache()
Get the default QueryCache
.
UpdateTimestampsCache getUpdateTimestampsCache()
Get UpdateTimestampsCache
instance managed by the SessionFactory
.
void evictQueries() throws HibernateException
Clean up the default QueryCache
.
HibernateException
RegionFactory getRegionFactory()
The underlying RegionFactory in use.
RegionFactory
String qualifyRegionName(String regionName)
Applies any defined prefix, handling all null
checks.
regionName
- The region name to qualifyString[] getSecondLevelCacheRegionNames()
Get the names of <tt>all</tt> cache regions, including entity, collection, natural-id and query caches.
EntityRegionAccessStrategy getEntityRegionAccess(String regionName)
Find the "access strategy" for the named entity cache region.
regionName
- The name of the regionCollectionRegionAccessStrategy getCollectionRegionAccess(String regionName)
Find the "access strategy" for the named collection cache region.
regionName
- The name of the regionNaturalIdRegionAccessStrategy getNaturalIdCacheRegionAccessStrategy(String regionName)
Find the "access strategy" for the named natrual-id cache region.
regionName
- The name of the regionEntityRegionAccessStrategy determineEntityRegionAccessStrategy(PersistentClass model)
NaturalIdRegionAccessStrategy determineNaturalIdRegionAccessStrategy(PersistentClass model)
CollectionRegionAccessStrategy determineCollectionRegionAccessStrategy(Collection model)
Copyright © 2001-2018 Red Hat, Inc. All Rights Reserved.