All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.infinispan.jcache.JCacheEntry Maven / Gradle / Ivy

There is a newer version: 9.1.7.Final
Show newest version
package org.infinispan.jcache;

import javax.cache.Cache.Entry;

import org.infinispan.commons.util.ReflectionUtil;

/**
 * Infinispan implementation of {@link javax.cache.Cache.Entry}.
 *
 * @param  the type of key maintained by this cache entry
 * @param  the type of value maintained by this cache entry
 * @author Vladimir Blagojevic
 * @author Galder Zamarreño
 * @since 5.3
 */
public final class JCacheEntry implements Entry {

   protected final K key;

   protected final V value;

   public JCacheEntry(K key, V value) {
      this.key = key;
      this.value = value;
   }

   @Override
   public K getKey() {
      return key;
   }

   @Override
   public V getValue() {
      return value;
   }

   @Override
   public  T unwrap(Class clazz) {
      return ReflectionUtil.unwrap(this, clazz);
   }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy