Package de.javakaffee.kryoserializers
Class CopyForIterateCollectionSerializer
- java.lang.Object
-
- com.esotericsoftware.kryo.Serializer<T>
-
- com.esotericsoftware.kryo.serializers.CollectionSerializer
-
- de.javakaffee.kryoserializers.CopyForIterateCollectionSerializer
-
public class CopyForIterateCollectionSerializer extends com.esotericsoftware.kryo.serializers.CollectionSerializerA kryoSerializerthat creates a copy of the source collection for writing object data.This is useful for applications where objects/collections that are serialized might be accessed by different threads. However, it only reduces the probability of concurrent modification exceptions, as even during taking the copy the collection might be modified by another thread.
- Author:
- Martin Grotzke
-
-
Constructor Summary
Constructors Constructor Description CopyForIterateCollectionSerializer()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidwrite(com.esotericsoftware.kryo.Kryo kryo, com.esotericsoftware.kryo.io.Output output, Collection object)-
Methods inherited from class com.esotericsoftware.kryo.serializers.CollectionSerializer
copy, create, createCopy, getElementClass, getElementSerializer, read, setElementClass, setElementClass, setElementsCanBeNull, setElementSerializer, writeHeader
-
-
-
-
Method Detail
-
write
public void write(com.esotericsoftware.kryo.Kryo kryo, com.esotericsoftware.kryo.io.Output output, Collection object)- Overrides:
writein classcom.esotericsoftware.kryo.serializers.CollectionSerializer
-
-