org.qi4j.spi.cache
Interface Cache<T>

Type Parameters:
T - The Value type to be stored in the cache.
All Known Implementing Classes:
EhCacheImpl, NullCache

public interface Cache<T>

Interface to interact with Cache implementations. The Cache interface has the simple put/get/remove method to make implementations very easy and straight forward. The key is always a String, since it is intended to be used for the EntityComposite's identity, and not totally generic.


Method Summary
 boolean exists(String key)
           
 T get(String key)
           
 void put(String key, T value)
           
 T remove(String key)
           
 

Method Detail

get

T get(String key)

remove

T remove(String key)

put

void put(String key,
         T value)

exists

boolean exists(String key)