de.javakaffee.kryoserializers
Class SubListSerializer

java.lang.Object
  extended by com.esotericsoftware.kryo.Serializer
      extended by de.javakaffee.kryoserializers.SubListSerializer

public class SubListSerializer
extends com.esotericsoftware.kryo.Serializer

A kryo Serializer for lists created via List.subList(int, int).

Author:
Martin Grotzke

Constructor Summary
SubListSerializer(com.esotericsoftware.kryo.Kryo kryo)
           
 
Method Summary
static boolean canSerialize(Class<?> type)
          Can be used to determine, if the given type can be handled by this serializer.
<T> T
readObjectData(ByteBuffer buffer, Class<T> clazz)
          
 void writeObjectData(ByteBuffer buffer, Object obj)
          
 
Methods inherited from class com.esotericsoftware.kryo.Serializer
isFinal, newInstance, readObject, setCanBeNull, writeObject
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SubListSerializer

public SubListSerializer(com.esotericsoftware.kryo.Kryo kryo)
Method Detail

canSerialize

public static boolean canSerialize(Class<?> type)
Can be used to determine, if the given type can be handled by this serializer.

Parameters:
type - the class to check.
Returns:
true if the given class can be serialized/deserialized by this serializer.

readObjectData

public <T> T readObjectData(ByteBuffer buffer,
                            Class<T> clazz)

Specified by:
readObjectData in class com.esotericsoftware.kryo.Serializer

writeObjectData

public void writeObjectData(ByteBuffer buffer,
                            Object obj)

Specified by:
writeObjectData in class com.esotericsoftware.kryo.Serializer


Copyright © 2010-2011. All Rights Reserved.