public interface Cache
contains
, which returns false.Modifier and Type | Method and Description |
---|---|
boolean |
contains(java.lang.Class cls,
java.lang.Object primaryKey)
Whether the cache contains data for the given entity.
|
void |
evict(java.lang.Class cls)
Remove the data for entities of the specified class (and its
subclasses) from the cache.
|
void |
evict(java.lang.Class cls,
java.lang.Object primaryKey)
Remove the data for the given entity from the cache.
|
void |
evictAll()
Clear the cache.
|
<T> T |
unwrap(java.lang.Class<T> cls)
Return an object of the specified type to allow access to the provider-specific API.
|
boolean contains(java.lang.Class cls, java.lang.Object primaryKey)
cls
- entity classprimaryKey
- primary keyvoid evict(java.lang.Class cls, java.lang.Object primaryKey)
cls
- entity classprimaryKey
- primary keyvoid evict(java.lang.Class cls)
cls
- entity classvoid evictAll()
<T> T unwrap(java.lang.Class<T> cls)
cls
- the class of the object to be returned. This is normally either the
underlying Cache implementation class or an interface that it implements.PersistenceException
- if the provider does not support the call