Class LastModifiedCache
- java.lang.Object
-
- org.pentaho.platform.plugin.services.cache.LastModifiedCache
-
- All Implemented Interfaces:
javax.persistence.Cache
,org.hibernate.Cache
,org.pentaho.platform.api.cache.ILastModifiedCacheItem
,HvCache
public class LastModifiedCache extends Object implements org.pentaho.platform.api.cache.ILastModifiedCacheItem, HvCache
User: rfellows Date: 10/25/11 Time: 3:53 PM
-
-
Field Summary
Fields Modifier and Type Field Description protected static org.apache.commons.logging.Log
LOGGER
-
Constructor Summary
Constructors Constructor Description LastModifiedCache(org.hibernate.cache.spi.DirectAccessRegion directAccessRegion, org.hibernate.SessionFactory sessionFactory)
LastModifiedCache(org.hibernate.cache.spi.DirectAccessRegion directAccessRegion, org.hibernate.SessionFactory sessionFactory, long lastModified)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
contains(Class cls, Object primaryKey)
boolean
containsCollection(String role, Serializable ownerIdentifier)
boolean
containsEntity(Class entityClass, Serializable identifier)
boolean
containsEntity(String entityName, Serializable identifier)
boolean
containsQuery(String regionName)
void
evict(Class aClass)
void
evict(Class cls, Object primaryKey)
void
evictCollectionData()
void
evictCollectionData(String role)
void
evictCollectionData(String role, Serializable ownerIdentifier)
void
evictDefaultQueryRegion()
void
evictEntityData()
void
evictEntityData(Class entityClass)
void
evictEntityData(Class entityClass, Serializable identifier)
void
evictEntityData(String entityName)
void
evictEntityData(String entityName, Serializable identifier)
void
evictNaturalIdData()
void
evictNaturalIdData(Class entityClass)
void
evictNaturalIdData(String entityName)
void
evictQueryRegion(String regionName)
void
evictQueryRegions()
void
evictRegion(String regionName)
Set
getAllKeys()
Return all keys for the regionnet.sf.ehcache.Ehcache
getCache()
Exposes the underlaying EhCache associated with this HvCacheString
getCacheKey()
org.hibernate.cache.spi.DirectAccessRegion
getDirectAccessRegion()
Return built in cache accesslong
getLastModified()
org.hibernate.engine.spi.SessionFactoryImplementor
getSessionFactory()
org.hibernate.cache.ehcache.internal.StorageAccessImpl
getStorageAccess()
Return the object that allows direct storage accessprotected void
setLastModified()
void
setLastModified(long lastModified)
<T> T
unwrap(Class<T> cls)
-
-
-
Constructor Detail
-
LastModifiedCache
public LastModifiedCache(org.hibernate.cache.spi.DirectAccessRegion directAccessRegion, org.hibernate.SessionFactory sessionFactory)
-
LastModifiedCache
public LastModifiedCache(org.hibernate.cache.spi.DirectAccessRegion directAccessRegion, org.hibernate.SessionFactory sessionFactory, long lastModified)
-
-
Method Detail
-
getLastModified
public long getLastModified()
- Specified by:
getLastModified
in interfaceorg.pentaho.platform.api.cache.ILastModifiedCacheItem
-
getCacheKey
public String getCacheKey()
- Specified by:
getCacheKey
in interfaceorg.pentaho.platform.api.cache.ILastModifiedCacheItem
-
setLastModified
public void setLastModified(long lastModified)
-
setLastModified
protected void setLastModified()
-
getSessionFactory
public org.hibernate.engine.spi.SessionFactoryImplementor getSessionFactory()
- Specified by:
getSessionFactory
in interfaceorg.hibernate.Cache
-
containsEntity
public boolean containsEntity(Class entityClass, Serializable identifier)
- Specified by:
containsEntity
in interfaceorg.hibernate.Cache
-
containsEntity
public boolean containsEntity(String entityName, Serializable identifier)
- Specified by:
containsEntity
in interfaceorg.hibernate.Cache
-
evictEntityData
public void evictEntityData(Class entityClass, Serializable identifier)
- Specified by:
evictEntityData
in interfaceorg.hibernate.Cache
-
evictEntityData
public void evictEntityData(String entityName, Serializable identifier)
- Specified by:
evictEntityData
in interfaceorg.hibernate.Cache
-
evictEntityData
public void evictEntityData(Class entityClass)
- Specified by:
evictEntityData
in interfaceorg.hibernate.Cache
-
evictEntityData
public void evictEntityData(String entityName)
- Specified by:
evictEntityData
in interfaceorg.hibernate.Cache
-
evictEntityData
public void evictEntityData()
- Specified by:
evictEntityData
in interfaceorg.hibernate.Cache
-
evictNaturalIdData
public void evictNaturalIdData(Class entityClass)
- Specified by:
evictNaturalIdData
in interfaceorg.hibernate.Cache
-
evictNaturalIdData
public void evictNaturalIdData(String entityName)
- Specified by:
evictNaturalIdData
in interfaceorg.hibernate.Cache
-
evictNaturalIdData
public void evictNaturalIdData()
- Specified by:
evictNaturalIdData
in interfaceorg.hibernate.Cache
-
containsCollection
public boolean containsCollection(String role, Serializable ownerIdentifier)
- Specified by:
containsCollection
in interfaceorg.hibernate.Cache
-
evictCollectionData
public void evictCollectionData(String role, Serializable ownerIdentifier)
- Specified by:
evictCollectionData
in interfaceorg.hibernate.Cache
-
evictCollectionData
public void evictCollectionData(String role)
- Specified by:
evictCollectionData
in interfaceorg.hibernate.Cache
-
evictCollectionData
public void evictCollectionData()
- Specified by:
evictCollectionData
in interfaceorg.hibernate.Cache
-
containsQuery
public boolean containsQuery(String regionName)
- Specified by:
containsQuery
in interfaceorg.hibernate.Cache
-
evictDefaultQueryRegion
public void evictDefaultQueryRegion()
- Specified by:
evictDefaultQueryRegion
in interfaceorg.hibernate.Cache
-
evictQueryRegion
public void evictQueryRegion(String regionName)
- Specified by:
evictQueryRegion
in interfaceorg.hibernate.Cache
-
evictQueryRegions
public void evictQueryRegions()
- Specified by:
evictQueryRegions
in interfaceorg.hibernate.Cache
-
evictRegion
public void evictRegion(String regionName)
- Specified by:
evictRegion
in interfaceorg.hibernate.Cache
-
contains
public boolean contains(Class cls, Object primaryKey)
- Specified by:
contains
in interfacejavax.persistence.Cache
-
evict
public void evict(Class cls, Object primaryKey)
- Specified by:
evict
in interfacejavax.persistence.Cache
-
evict
public void evict(Class aClass)
- Specified by:
evict
in interfacejavax.persistence.Cache
-
unwrap
public <T> T unwrap(Class<T> cls)
- Specified by:
unwrap
in interfacejavax.persistence.Cache
-
getAllKeys
public Set getAllKeys()
Description copied from interface:HvCache
Return all keys for the region- Specified by:
getAllKeys
in interfaceHvCache
- Returns:
-
getDirectAccessRegion
public org.hibernate.cache.spi.DirectAccessRegion getDirectAccessRegion()
Description copied from interface:HvCache
Return built in cache access- Specified by:
getDirectAccessRegion
in interfaceHvCache
- Returns:
-
getStorageAccess
public org.hibernate.cache.ehcache.internal.StorageAccessImpl getStorageAccess()
Description copied from interface:HvCache
Return the object that allows direct storage access- Specified by:
getStorageAccess
in interfaceHvCache
- Returns:
-
-