Java tutorial
//package com.java2s; import java.io.File; import java.io.FileInputStream; import java.io.IOException; import java.io.ObjectInputStream; public class Main { public static Object DeserializeObject(String path) throws ClassNotFoundException, IOException { Object o; ObjectInputStream ois = new ObjectInputStream(new FileInputStream(new File(path))); o = ois.readObject(); return o; } }