public class ObjectSerializationUtils extends Object
Constructor and Description |
---|
ObjectSerializationUtils() |
Modifier and Type | Method and Description |
---|---|
static <T> T |
deserialize(byte[] aData,
Class<T> aType)
Desrializes an object from a byte array.
|
static byte[] |
serialize(Object aObject)
Serialize an object to a byte array.
|
public static byte[] serialize(Object aObject) throws IOException
aObject
- Object ot serialize.IOException
public static <T> T deserialize(byte[] aData, Class<T> aType) throws IOException, ClassNotFoundException
T
- Type of the object.aData
- Serialized data.aType
- Type of the object.IOException
ClassNotFoundException
Copyright © 2024. All rights reserved.