public class ObjectSerDe extends java.lang.Object implements Serializer<java.lang.Object>, Deserializer<java.lang.Object>
Constructor and Description |
---|
ObjectSerDe() |
Modifier and Type | Method and Description |
---|---|
java.lang.Object |
deserialize(byte[] input)
Deserializes the given byte array input an Object and returns that value.
|
void |
serialize(java.lang.Object value,
java.io.OutputStream output)
Serializes the given value to the
OutputStream |
public java.lang.Object deserialize(byte[] input) throws DeserializationException, java.io.IOException
Deserializer
deserialize
in interface Deserializer<java.lang.Object>
input
- inputDeserializationException
- if a valid object cannot be deserialized
from the given byte arrayjava.io.IOException
- expublic void serialize(java.lang.Object value, java.io.OutputStream output) throws SerializationException, java.io.IOException
Serializer
OutputStream
serialize
in interface Serializer<java.lang.Object>
value
- valueoutput
- streamSerializationException
- If unable to serialize the given valuejava.io.IOException
- ex