* the return value is not null.
*/
private ManagedObject deserialize(byte[] data) {
Object obj = SerialUtil.deserialize(data, context.classSerial);
if (obj == null) {
throw new ObjectIOException(
"Managed object must not deserialize to null", false);
} else if (!(obj instanceof ManagedObject)) {
throw new ObjectIOException(
"Deserialized object must implement ManagedObject", false);
}
return (ManagedObject) obj;
}