Interface CacheEntry<K,V>
- Type Parameters:
K- the key typeV- the value type
- All Superinterfaces:
javax.cache.Cache.Entry<K,V>, javax.cache.processor.MutableEntry<K, V>
public interface CacheEntry<K,V>
extends javax.cache.processor.MutableEntry<K,V>
Represents a single cache entry accessed within an entry processor.
Extends MutableEntry to provide JSR-107 compliance
out of the box. Users can register either the native EntryProcessor or the
standard EntryProcessor — both receive instances
assignable to Cache.Entry, MutableEntry, and this interface.
Allows atomic read and write of cache entries.
-
Method Details
-
getKey
-
getValue
-
setValue
-
exists
-
remove
-
unwrap
Unwrap to the specified type, per JSR-107 contract.- Specified by:
unwrapin interfacejavax.cache.Cache.Entry<K,V> - Parameters:
clazz- target type- Returns:
- this entry if clazz is assignable; otherwise throws
- Throws:
IllegalArgumentException- if clazz is not assignable from this entry
-