com.google.code.ssm.providers.xmemcached
Class MemcacheClientWrapper

java.lang.Object
  extended by com.google.code.ssm.providers.AbstractMemcacheClientWrapper
      extended by com.google.code.ssm.providers.xmemcached.MemcacheClientWrapper
All Implemented Interfaces:
CacheClient

 class MemcacheClientWrapper
extends AbstractMemcacheClientWrapper

Since:
2.0.0
Author:
Jakub BiaƂek

Constructor Summary
MemcacheClientWrapper(MemcachedClient memcachedClient)
           
 
Method Summary
 boolean add(String key, int exp, Object value)
           
<T> boolean
add(String key, int exp, T value, CacheTranscoder transcoder)
           
 long decr(String key, int by)
           
 long decr(String key, int by, long def)
           
 boolean delete(String key)
           
 void flush()
           
 Object get(String key)
           
<T> T
get(String key, CacheTranscoder transcoder)
           
<T> T
get(String key, CacheTranscoder transcoder, long timeout)
           
 Collection<SocketAddress> getAvailableServers()
           
 Map<String,Object> getBulk(Collection<String> keys)
           
<T> Map<String,T>
getBulk(Collection<String> keys, CacheTranscoder transcoder)
           
 Object getNativeClient()
           
 CacheTranscoder getTranscoder()
           
 long incr(String key, int by)
           
 long incr(String key, int by, long def)
           
 long incr(String key, int by, long def, int expiration)
           
 boolean set(String key, int exp, Object value)
           
<T> boolean
set(String key, int exp, T value, CacheTranscoder transcoder)
           
 void shutdown()
           
 
Methods inherited from class com.google.code.ssm.providers.AbstractMemcacheClientWrapper
delete
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MemcacheClientWrapper

MemcacheClientWrapper(MemcachedClient memcachedClient)
Method Detail

add

public boolean add(String key,
                   int exp,
                   Object value)
            throws TimeoutException,
                   CacheException
Throws:
TimeoutException
CacheException

add

public <T> boolean add(String key,
                       int exp,
                       T value,
                       CacheTranscoder transcoder)
            throws TimeoutException,
                   CacheException
Throws:
TimeoutException
CacheException

decr

public long decr(String key,
                 int by)
          throws TimeoutException,
                 CacheException
Throws:
TimeoutException
CacheException

decr

public long decr(String key,
                 int by,
                 long def)
          throws TimeoutException,
                 CacheException
Throws:
TimeoutException
CacheException

delete

public boolean delete(String key)
               throws TimeoutException,
                      CacheException
Throws:
TimeoutException
CacheException

flush

public void flush()
           throws TimeoutException,
                  CacheException
Throws:
TimeoutException
CacheException

get

public Object get(String key)
           throws TimeoutException,
                  CacheException
Throws:
TimeoutException
CacheException

get

public <T> T get(String key,
                 CacheTranscoder transcoder)
      throws TimeoutException,
             CacheException
Throws:
TimeoutException
CacheException

get

public <T> T get(String key,
                 CacheTranscoder transcoder,
                 long timeout)
      throws TimeoutException,
             CacheException
Throws:
TimeoutException
CacheException

getAvailableServers

public Collection<SocketAddress> getAvailableServers()

getBulk

public Map<String,Object> getBulk(Collection<String> keys)
                           throws TimeoutException,
                                  CacheException
Throws:
TimeoutException
CacheException

getBulk

public <T> Map<String,T> getBulk(Collection<String> keys,
                                 CacheTranscoder transcoder)
                      throws TimeoutException,
                             CacheException
Throws:
TimeoutException
CacheException

incr

public long incr(String key,
                 int by)
          throws TimeoutException,
                 CacheException
Throws:
TimeoutException
CacheException

incr

public long incr(String key,
                 int by,
                 long def)
          throws TimeoutException,
                 CacheException
Throws:
TimeoutException
CacheException

incr

public long incr(String key,
                 int by,
                 long def,
                 int expiration)
          throws TimeoutException,
                 CacheException
Throws:
TimeoutException
CacheException

set

public boolean set(String key,
                   int exp,
                   Object value)
            throws TimeoutException,
                   CacheException
Throws:
TimeoutException
CacheException

set

public <T> boolean set(String key,
                       int exp,
                       T value,
                       CacheTranscoder transcoder)
            throws TimeoutException,
                   CacheException
Throws:
TimeoutException
CacheException

shutdown

public void shutdown()

getTranscoder

public CacheTranscoder getTranscoder()

getNativeClient

public Object getNativeClient()


Copyright © 2015. All rights reserved.