Here you can find the source of deserialize(byte[] data)
public static <T> T deserialize(byte[] data)
//package com.java2s; //License from project: Apache License import java.io.*; public class Main { public static <T> T deserialize(byte[] data) { try {/*w w w .ja va 2 s. c o m*/ ByteArrayInputStream in = new ByteArrayInputStream(data); ObjectInputStream ois = new ObjectInputStream(in); return (T) ois.readObject(); } catch (Exception e) { e.printStackTrace(); } return null; } }