Package net.sf.ehcache.hibernate.nonstop
Class NonstopAwareEntityRegionAccessStrategy
- java.lang.Object
-
- net.sf.ehcache.hibernate.nonstop.NonstopAwareEntityRegionAccessStrategy
-
- All Implemented Interfaces:
org.hibernate.cache.access.EntityRegionAccessStrategy
public class NonstopAwareEntityRegionAccessStrategy extends java.lang.Object implements org.hibernate.cache.access.EntityRegionAccessStrategyImplementation ofEntityRegionAccessStrategythat handlesNonStopCacheExceptionusingHibernateNonstopCacheExceptionHandler- Author:
- Abhishek Sanoujam
-
-
Constructor Summary
Constructors Constructor Description NonstopAwareEntityRegionAccessStrategy(org.hibernate.cache.access.EntityRegionAccessStrategy actualStrategy, HibernateNonstopCacheExceptionHandler hibernateNonstopExceptionHandler)Constructor accepting the actualEntityRegionAccessStrategyand theHibernateNonstopCacheExceptionHandler
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanafterInsert(java.lang.Object key, java.lang.Object value, java.lang.Object version)booleanafterUpdate(java.lang.Object key, java.lang.Object value, java.lang.Object currentVersion, java.lang.Object previousVersion, org.hibernate.cache.access.SoftLock lock)voidevict(java.lang.Object key)voidevictAll()java.lang.Objectget(java.lang.Object key, long txTimestamp)org.hibernate.cache.EntityRegiongetRegion()booleaninsert(java.lang.Object key, java.lang.Object value, java.lang.Object version)org.hibernate.cache.access.SoftLocklockItem(java.lang.Object key, java.lang.Object version)org.hibernate.cache.access.SoftLocklockRegion()booleanputFromLoad(java.lang.Object key, java.lang.Object value, long txTimestamp, java.lang.Object version)booleanputFromLoad(java.lang.Object key, java.lang.Object value, long txTimestamp, java.lang.Object version, boolean minimalPutOverride)voidremove(java.lang.Object key)voidremoveAll()voidunlockItem(java.lang.Object key, org.hibernate.cache.access.SoftLock lock)voidunlockRegion(org.hibernate.cache.access.SoftLock lock)booleanupdate(java.lang.Object key, java.lang.Object value, java.lang.Object currentVersion, java.lang.Object previousVersion)
-
-
-
Constructor Detail
-
NonstopAwareEntityRegionAccessStrategy
public NonstopAwareEntityRegionAccessStrategy(org.hibernate.cache.access.EntityRegionAccessStrategy actualStrategy, HibernateNonstopCacheExceptionHandler hibernateNonstopExceptionHandler)Constructor accepting the actualEntityRegionAccessStrategyand theHibernateNonstopCacheExceptionHandler- Parameters:
actualStrategy-hibernateNonstopExceptionHandler-
-
-
Method Detail
-
getRegion
public org.hibernate.cache.EntityRegion getRegion()
- Specified by:
getRegionin interfaceorg.hibernate.cache.access.EntityRegionAccessStrategy- See Also:
EntityRegionAccessStrategy.getRegion()
-
afterInsert
public boolean afterInsert(java.lang.Object key, java.lang.Object value, java.lang.Object version) throws org.hibernate.cache.CacheException- Specified by:
afterInsertin interfaceorg.hibernate.cache.access.EntityRegionAccessStrategy- Throws:
org.hibernate.cache.CacheException- See Also:
EntityRegionAccessStrategy.afterInsert(java.lang.Object, java.lang.Object, java.lang.Object)
-
afterUpdate
public boolean afterUpdate(java.lang.Object key, java.lang.Object value, java.lang.Object currentVersion, java.lang.Object previousVersion, org.hibernate.cache.access.SoftLock lock) throws org.hibernate.cache.CacheException- Specified by:
afterUpdatein interfaceorg.hibernate.cache.access.EntityRegionAccessStrategy- Throws:
org.hibernate.cache.CacheException- See Also:
EntityRegionAccessStrategy.afterUpdate(java.lang.Object, java.lang.Object, java.lang.Object, java.lang.Object, org.hibernate.cache.access.SoftLock)
-
evict
public void evict(java.lang.Object key) throws org.hibernate.cache.CacheException- Specified by:
evictin interfaceorg.hibernate.cache.access.EntityRegionAccessStrategy- Throws:
org.hibernate.cache.CacheException- See Also:
EntityRegionAccessStrategy.evict(java.lang.Object)
-
evictAll
public void evictAll() throws org.hibernate.cache.CacheException- Specified by:
evictAllin interfaceorg.hibernate.cache.access.EntityRegionAccessStrategy- Throws:
org.hibernate.cache.CacheException- See Also:
EntityRegionAccessStrategy.evictAll()
-
get
public java.lang.Object get(java.lang.Object key, long txTimestamp) throws org.hibernate.cache.CacheException- Specified by:
getin interfaceorg.hibernate.cache.access.EntityRegionAccessStrategy- Throws:
org.hibernate.cache.CacheException- See Also:
EntityRegionAccessStrategy.get(java.lang.Object, long)
-
insert
public boolean insert(java.lang.Object key, java.lang.Object value, java.lang.Object version) throws org.hibernate.cache.CacheException- Specified by:
insertin interfaceorg.hibernate.cache.access.EntityRegionAccessStrategy- Throws:
org.hibernate.cache.CacheException- See Also:
EntityRegionAccessStrategy.insert(java.lang.Object, java.lang.Object, java.lang.Object)
-
lockItem
public org.hibernate.cache.access.SoftLock lockItem(java.lang.Object key, java.lang.Object version) throws org.hibernate.cache.CacheException- Specified by:
lockItemin interfaceorg.hibernate.cache.access.EntityRegionAccessStrategy- Throws:
org.hibernate.cache.CacheException- See Also:
EntityRegionAccessStrategy.lockItem(java.lang.Object, java.lang.Object)
-
lockRegion
public org.hibernate.cache.access.SoftLock lockRegion() throws org.hibernate.cache.CacheException- Specified by:
lockRegionin interfaceorg.hibernate.cache.access.EntityRegionAccessStrategy- Throws:
org.hibernate.cache.CacheException- See Also:
EntityRegionAccessStrategy.lockRegion()
-
putFromLoad
public boolean putFromLoad(java.lang.Object key, java.lang.Object value, long txTimestamp, java.lang.Object version, boolean minimalPutOverride) throws org.hibernate.cache.CacheException- Specified by:
putFromLoadin interfaceorg.hibernate.cache.access.EntityRegionAccessStrategy- Throws:
org.hibernate.cache.CacheException- See Also:
EntityRegionAccessStrategy.putFromLoad(java.lang.Object, java.lang.Object, long, java.lang.Object, boolean)
-
putFromLoad
public boolean putFromLoad(java.lang.Object key, java.lang.Object value, long txTimestamp, java.lang.Object version) throws org.hibernate.cache.CacheException- Specified by:
putFromLoadin interfaceorg.hibernate.cache.access.EntityRegionAccessStrategy- Throws:
org.hibernate.cache.CacheException- See Also:
EntityRegionAccessStrategy.putFromLoad(java.lang.Object, java.lang.Object, long, java.lang.Object)
-
remove
public void remove(java.lang.Object key) throws org.hibernate.cache.CacheException- Specified by:
removein interfaceorg.hibernate.cache.access.EntityRegionAccessStrategy- Throws:
org.hibernate.cache.CacheException- See Also:
EntityRegionAccessStrategy.remove(java.lang.Object)
-
removeAll
public void removeAll() throws org.hibernate.cache.CacheException- Specified by:
removeAllin interfaceorg.hibernate.cache.access.EntityRegionAccessStrategy- Throws:
org.hibernate.cache.CacheException- See Also:
EntityRegionAccessStrategy.removeAll()
-
unlockItem
public void unlockItem(java.lang.Object key, org.hibernate.cache.access.SoftLock lock) throws org.hibernate.cache.CacheException- Specified by:
unlockItemin interfaceorg.hibernate.cache.access.EntityRegionAccessStrategy- Throws:
org.hibernate.cache.CacheException- See Also:
EntityRegionAccessStrategy.unlockItem(java.lang.Object, org.hibernate.cache.access.SoftLock)
-
unlockRegion
public void unlockRegion(org.hibernate.cache.access.SoftLock lock) throws org.hibernate.cache.CacheException- Specified by:
unlockRegionin interfaceorg.hibernate.cache.access.EntityRegionAccessStrategy- Throws:
org.hibernate.cache.CacheException- See Also:
EntityRegionAccessStrategy.unlockRegion(org.hibernate.cache.access.SoftLock)
-
update
public boolean update(java.lang.Object key, java.lang.Object value, java.lang.Object currentVersion, java.lang.Object previousVersion) throws org.hibernate.cache.CacheException- Specified by:
updatein interfaceorg.hibernate.cache.access.EntityRegionAccessStrategy- Throws:
org.hibernate.cache.CacheException- See Also:
EntityRegionAccessStrategy.update(java.lang.Object, java.lang.Object, java.lang.Object, java.lang.Object)
-
-