try {
in = new CustomClassDescriptorObjectInputStream(
new CompressByteArrayInputStream(data), classSerial);
return in.readObject();
} catch (ClassNotFoundException e) {
throw new ObjectIOException(
"Class not found while deserializing object: " +
e.getMessage(),
e, false);
} catch (IOException e) {
throw new ObjectIOException(
"Problem deserializing object: " + e.getMessage(), e, false);
} finally {
if (in != null) {
try {
in.close();