Package org.redisson.codec
Class KryoCodec
java.lang.Object
org.redisson.client.codec.BaseCodec
org.redisson.codec.KryoCodec
- All Implemented Interfaces:
Codec
Kryo 4 codec
Fully thread-safe.
- Author:
- Nikita Koksharov
-
Nested Class Summary
-
Field Summary
Fields inherited from class org.redisson.client.codec.BaseCodec
SKIPPED_CODECS
-
Constructor Summary
ConstructorDescriptionKryoCodec
(ClassLoader classLoader) KryoCodec
(ClassLoader classLoader, KryoCodec codec) KryoCodec
(List<Class<?>> classes, ClassLoader classLoader) -
Method Summary
Modifier and TypeMethodDescriptionprotected com.esotericsoftware.kryo.Kryo
createInstance
(List<Class<?>> classes, ClassLoader classLoader) Sub classes can customize the Kryo instance by overriding this methodcom.esotericsoftware.kryo.Kryo
get()
Returns class loader object used to load classes used in decoding processReturns object decoder used for any objects stored Redis structure except HMAPReturns object encoder used for any objects stored Redis structure except HMAPvoid
offer
(com.esotericsoftware.kryo.Kryo kryo) Methods inherited from class org.redisson.client.codec.BaseCodec
copy, getMapKeyDecoder, getMapKeyEncoder, getMapValueDecoder, getMapValueEncoder, toString
-
Constructor Details
-
KryoCodec
public KryoCodec() -
KryoCodec
-
KryoCodec
-
KryoCodec
-
KryoCodec
-
-
Method Details
-
get
public com.esotericsoftware.kryo.Kryo get() -
offer
public void offer(com.esotericsoftware.kryo.Kryo kryo) -
createInstance
protected com.esotericsoftware.kryo.Kryo createInstance(List<Class<?>> classes, ClassLoader classLoader) Sub classes can customize the Kryo instance by overriding this method- Returns:
- create Kryo instance
-
getValueDecoder
Description copied from interface:Codec
Returns object decoder used for any objects stored Redis structure except HMAP- Returns:
- decoder
-
getValueEncoder
Description copied from interface:Codec
Returns object encoder used for any objects stored Redis structure except HMAP- Returns:
- encoder
-
getClassLoader
Description copied from interface:Codec
Returns class loader object used to load classes used in decoding process- Specified by:
getClassLoader
in interfaceCodec
- Overrides:
getClassLoader
in classBaseCodec
- Returns:
- class loader
-