Class DefaultSerializers.TreeMapSerializer
- java.lang.Object
-
- com.esotericsoftware.kryo.Serializer<Map>
-
- com.esotericsoftware.kryo.serializers.MapSerializer
-
- com.esotericsoftware.kryo.serializers.DefaultSerializers.TreeMapSerializer
-
- Enclosing class:
- DefaultSerializers
public static class DefaultSerializers.TreeMapSerializer extends MapSerializer
Serializer forTreeMapand any subclass.- Author:
- Tumi
(enhacements)
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.esotericsoftware.kryo.serializers.MapSerializer
MapSerializer.BindMap
-
-
Constructor Summary
Constructors Constructor Description TreeMapSerializer()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected Mapcreate(Kryo kryo, Input input, Class<Map> type)Used byMapSerializer.read(Kryo, Input, Class)to create the new object.protected MapcreateCopy(Kryo kryo, Map original)voidwrite(Kryo kryo, Output output, Map map)Writes the bytes for the object to the output.-
Methods inherited from class com.esotericsoftware.kryo.serializers.MapSerializer
copy, read, setGenerics, setKeyClass, setKeysCanBeNull, setValueClass, setValuesCanBeNull
-
Methods inherited from class com.esotericsoftware.kryo.Serializer
getAcceptsNull, isImmutable, setAcceptsNull, setImmutable
-
-
-
-
Method Detail
-
write
public void write(Kryo kryo, Output output, Map map)
Description copied from class:SerializerWrites the bytes for the object to the output.This method should not be called directly, instead this serializer can be passed to
Kryowrite methods that accept a serialier.- Overrides:
writein classMapSerializermap- May be null ifSerializer.getAcceptsNull()is true.
-
create
protected Map create(Kryo kryo, Input input, Class<Map> type)
Description copied from class:MapSerializerUsed byMapSerializer.read(Kryo, Input, Class)to create the new object. This can be overridden to customize object creation, eg to call a constructor with arguments. The default implementation usesKryo.newInstance(Class).- Overrides:
createin classMapSerializer
-
createCopy
protected Map createCopy(Kryo kryo, Map original)
- Overrides:
createCopyin classMapSerializer
-
-