Package net.spy.memcached.transcoders
Class WhalinTranscoder
java.lang.Object
net.spy.memcached.compat.SpyObject
net.spy.memcached.transcoders.BaseSerializingTranscoder
net.spy.memcached.transcoders.WhalinTranscoder
- All Implemented Interfaces:
Transcoder<Object>
Transcoder that provides compatibility with Greg Whalin's memcached client.
-
Field Summary
FieldsModifier and TypeFieldDescription(package private) static final int
(package private) static final int
(package private) static final int
(package private) static final int
(package private) static final int
(package private) static final int
(package private) static final int
(package private) static final int
(package private) static final int
(package private) static final int
(package private) static final int
(package private) static final int
(package private) static final int
(package private) static final int
(package private) static final int
private final TranscoderUtils
Fields inherited from class net.spy.memcached.transcoders.BaseSerializingTranscoder
charset, compressionThreshold, DEFAULT_COMPRESSION_THRESHOLD
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondecode
(CachedData d) Decode the cached object into the object it represents.boolean
decodeBoolean
(byte[] in) protected Character
decodeCharacter
(byte[] b) 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 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
-
Field Details
-
SPECIAL_BYTE
static final int SPECIAL_BYTE- See Also:
-
SPECIAL_BOOLEAN
static final int SPECIAL_BOOLEAN- See Also:
-
SPECIAL_INT
static final int SPECIAL_INT- See Also:
-
SPECIAL_LONG
static final int SPECIAL_LONG- See Also:
-
SPECIAL_CHARACTER
static final int SPECIAL_CHARACTER- See Also:
-
SPECIAL_STRING
static final int SPECIAL_STRING- See Also:
-
SPECIAL_STRINGBUFFER
static final int SPECIAL_STRINGBUFFER- See Also:
-
SPECIAL_FLOAT
static final int SPECIAL_FLOAT- See Also:
-
SPECIAL_SHORT
static final int SPECIAL_SHORT- See Also:
-
SPECIAL_DOUBLE
static final int SPECIAL_DOUBLE- See Also:
-
SPECIAL_DATE
static final int SPECIAL_DATE- See Also:
-
SPECIAL_STRINGBUILDER
static final int SPECIAL_STRINGBUILDER- See Also:
-
SPECIAL_BYTEARRAY
static final int SPECIAL_BYTEARRAY- See Also:
-
COMPRESSED
static final int COMPRESSED- See Also:
-
SERIALIZED
static final int SERIALIZED- See Also:
-
tu
-
-
Constructor Details
-
WhalinTranscoder
public WhalinTranscoder()
-
-
Method Details
-
decode
Description copied from interface:Transcoder
Decode the cached object into the object it represents.- Specified by:
decode
in interfaceTranscoder<Object>
- Parameters:
d
- the data- Returns:
- the return value
-
encode
Description copied from interface:Transcoder
Encode the given object for storage.- Specified by:
encode
in interfaceTranscoder<Object>
- Parameters:
o
- the object- Returns:
- the CachedData representing what should be sent
-
decodeCharacter
-
encodeBoolean
public byte[] encodeBoolean(boolean b) -
decodeBoolean
public boolean decodeBoolean(byte[] in)
-