net.spy.memcached.transcoders
Class WhalinTranscoder

java.lang.Object
  extended by net.spy.memcached.compat.SpyObject
      extended by net.spy.memcached.transcoders.BaseSerializingTranscoder
          extended by net.spy.memcached.transcoders.WhalinTranscoder
All Implemented Interfaces:
Transcoder<Object>

public class WhalinTranscoder
extends BaseSerializingTranscoder
implements Transcoder<Object>

Transcoder that provides compatibility with Greg Whalin's memcached client.


Field Summary
 
Fields inherited from class net.spy.memcached.transcoders.BaseSerializingTranscoder
charset, compressionThreshold, DEFAULT_COMPRESSION_THRESHOLD
 
Constructor Summary
WhalinTranscoder()
           
 
Method Summary
 Object decode(CachedData d)
          Decode the cached object into the object it represents.
 boolean decodeBoolean(byte[] in)
           
protected  Character decodeCharacter(byte[] b)
           
 CachedData encode(Object o)
          Encode the given object for storage.
 byte[] encodeBoolean(boolean b)
           
 
Methods inherited from class net.spy.memcached.transcoders.BaseSerializingTranscoder
asyncDecode, compress, decodeString, decompress, deserialize, encodeString, getMaxSize, serialize, setCharset, setCompressionThreshold
 
Methods inherited from class net.spy.memcached.compat.SpyObject
getLogger
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface net.spy.memcached.transcoders.Transcoder
asyncDecode, getMaxSize
 

Constructor Detail

WhalinTranscoder

public WhalinTranscoder()
Method Detail

decode

public Object decode(CachedData d)
Description copied from interface: Transcoder
Decode the cached object into the object it represents.

Specified by:
decode in interface Transcoder<Object>
Parameters:
d - the data
Returns:
the return value

encode

public CachedData encode(Object o)
Description copied from interface: Transcoder
Encode the given object for storage.

Specified by:
encode in interface Transcoder<Object>
Parameters:
o - the object
Returns:
the CachedData representing what should be sent

decodeCharacter

protected Character decodeCharacter(byte[] b)

encodeBoolean

public byte[] encodeBoolean(boolean b)

decodeBoolean

public boolean decodeBoolean(byte[] in)