KryoSerializerInstance¶
KryoSerializerInstance
is a SerializerInstance.
Creating Instance¶
KryoSerializerInstance
takes the following to be created:
- KryoSerializer
-
useUnsafe
flag -
usePool
flag
KryoSerializerInstance
is created when:
KryoSerializer
is requested for a new SerializerInstance
Output¶
KryoSerializerInstance
creates Kryo's Output
lazily (on demand and once only).
KryoSerializerInstance
requests the KryoSerializer for a newKryoOutput.
output
is used for serialization.
serialize¶
serialize[T: ClassTag](
t: T): ByteBuffer
serialize
is part of the SerializerInstance abstraction.
serialize
...FIXME
deserialize¶
deserialize[T: ClassTag](
bytes: ByteBuffer): T
deserialize
is part of the SerializerInstance abstraction.
deserialize
...FIXME
Releasing Kryo Instance¶
releaseKryo(
kryo: Kryo): Unit
releaseKryo
...FIXME
releaseKryo
is used when:
KryoSerializationStream
is requested toclose
KryoDeserializationStream
is requested toclose
KryoSerializerInstance
is requested to serialize and deserialize (and getAutoReset)
getAutoReset¶
getAutoReset(): Boolean
getAutoReset
uses Java Reflection to access the value of the autoReset
field of the Kryo
class.
getAutoReset
is used when:
KryoSerializer
is requested for the supportsRelocationOfSerializedObjects flag