com.esotericsoftware.kryo.serializers
Class DefaultSerializers.TreeMapSerializer

java.lang.Object
  extended by com.esotericsoftware.kryo.Serializer<java.util.Map>
      extended by com.esotericsoftware.kryo.serializers.MapSerializer
          extended by com.esotericsoftware.kryo.serializers.DefaultSerializers.TreeMapSerializer
Enclosing class:
DefaultSerializers

public static class DefaultSerializers.TreeMapSerializer
extends MapSerializer


Constructor Summary
DefaultSerializers.TreeMapSerializer()
           
 
Method Summary
protected  java.util.Map create(Kryo kryo, Input input, java.lang.Class<java.util.Map> type)
          Used by MapSerializer.read(Kryo, Input, Class) to create the new object.
protected  java.util.Map createCopy(Kryo kryo, java.util.Map original)
           
 void write(Kryo kryo, Output output, java.util.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
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultSerializers.TreeMapSerializer

public DefaultSerializers.TreeMapSerializer()
Method Detail

write

public void write(Kryo kryo,
                  Output output,
                  java.util.Map map)
Description copied from class: Serializer
Writes the bytes for the object to the output.

This method should not be called directly, instead this serializer can be passed to Kryo write methods that accept a serialier.

Overrides:
write in class MapSerializer
map - May be null if Serializer.getAcceptsNull() is true.

create

protected java.util.Map create(Kryo kryo,
                               Input input,
                               java.lang.Class<java.util.Map> type)
Description copied from class: MapSerializer
Used by MapSerializer.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 uses Kryo.newInstance(Class).

Overrides:
create in class MapSerializer

createCopy

protected java.util.Map createCopy(Kryo kryo,
                                   java.util.Map original)
Overrides:
createCopy in class MapSerializer