public class DeserializingConverter extends java.lang.Object implements Converter<byte[],java.lang.Object>
Converter
that delegates to a
Deserializer
to convert data in a byte array to an object.Constructor and Description |
---|
DeserializingConverter()
Create a
DeserializingConverter with default ObjectInputStream
configuration, using the "latest user-defined ClassLoader". |
DeserializingConverter(java.lang.ClassLoader classLoader)
Create a
DeserializingConverter for using an ObjectInputStream
with the given ClassLoader . |
DeserializingConverter(Deserializer<java.lang.Object> deserializer)
Create a
DeserializingConverter that delegates to the provided Deserializer . |
Modifier and Type | Method and Description |
---|---|
java.lang.Object |
convert(byte[] source)
Convert the source object of type
S to target type T . |
public DeserializingConverter()
DeserializingConverter
with default ObjectInputStream
configuration, using the "latest user-defined ClassLoader".public DeserializingConverter(java.lang.ClassLoader classLoader)
DeserializingConverter
for using an ObjectInputStream
with the given ClassLoader
.DefaultDeserializer.DefaultDeserializer(ClassLoader)
public DeserializingConverter(Deserializer<java.lang.Object> deserializer)
DeserializingConverter
that delegates to the provided Deserializer
.public java.lang.Object convert(byte[] source)
Converter
S
to target type T
.