net.spy.jwebkit.cache
Class MemcachedCacheProvider

java.lang.Object
  extended by net.spy.SpyObject
      extended by net.spy.jwebkit.cache.MemcachedCacheProvider
All Implemented Interfaces:
CacheProvider

public class MemcachedCacheProvider
extends net.spy.SpyObject
implements CacheProvider

Cache provider that stores stuff in memcached.


Constructor Summary
MemcachedCacheProvider()
           
 
Method Summary
 void destroy()
          Tear down.
 CacheEntry getEntry(java.lang.String key)
          Get the cache entry for the given key.
 void init(javax.servlet.FilterConfig conf)
          Initialize with the given filter config.
 void setEntry(java.lang.String key, CacheEntry ce, long cacheTime)
          Store a cache entry for the given key.
 
Methods inherited from class net.spy.SpyObject
getLogger
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MemcachedCacheProvider

public MemcachedCacheProvider()
Method Detail

init

public void init(javax.servlet.FilterConfig conf)
          throws javax.servlet.ServletException
Description copied from interface: CacheProvider
Initialize with the given filter config.

Specified by:
init in interface CacheProvider
Throws:
javax.servlet.ServletException

destroy

public void destroy()
Description copied from interface: CacheProvider
Tear down.

Specified by:
destroy in interface CacheProvider

getEntry

public CacheEntry getEntry(java.lang.String key)
Description copied from interface: CacheProvider
Get the cache entry for the given key.

Specified by:
getEntry in interface CacheProvider
Parameters:
key - the cache key
Returns:
the object at that location, or null if there's no object for that key.

setEntry

public void setEntry(java.lang.String key,
                     CacheEntry ce,
                     long cacheTime)
Description copied from interface: CacheProvider
Store a cache entry for the given key.

Specified by:
setEntry in interface CacheProvider
Parameters:
key - the key under which to store the entry
ce - the entry to store
cacheTime - how long the item should be considered valid


Copyright © 1995-2007 SPY Internetworking. All Rights Reserved.