public class StringSerializer extends Serializer
log
Constructor and Description |
---|
StringSerializer() |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
readObject(java.nio.ByteBuffer data,
java.lang.Class c)
Read an object from the buffer, effectively deserializing it.
|
static java.lang.String |
readString(java.nio.ByteBuffer data) |
void |
writeObject(java.nio.ByteBuffer buffer,
java.lang.Object object)
Write an object to the buffer, effectively serializing it.
|
static void |
writeString(java.lang.String s,
java.nio.ByteBuffer buffer) |
getExactSerializer, getExactSerializerRegistration, getSerializer, getSerializer, getSerializerRegistration, getSerializerRegistration, getSerializerRegistrations, initialize, initialize, isReadOnly, readClass, readClassAndObject, registerClass, registerClass, registerClass, registerClasses, registerClassForId, registerPackage, setReadOnly, setStrictRegistration, writeClass, writeClassAndObject
public static void writeString(java.lang.String s, java.nio.ByteBuffer buffer) throws java.io.IOException
java.io.IOException
public static java.lang.String readString(java.nio.ByteBuffer data) throws java.io.IOException
java.io.IOException
public java.lang.String readObject(java.nio.ByteBuffer data, java.lang.Class c) throws java.io.IOException
Serializer
readObject
in class Serializer
data
- The buffer to read from.c
- The class of the object.java.io.IOException
- If deserializing fails.public void writeObject(java.nio.ByteBuffer buffer, java.lang.Object object) throws java.io.IOException
Serializer
writeObject
in class Serializer
buffer
- The buffer to write to.object
- The object to serialize.java.io.IOException
- If serializing fails.