Object serialization allows you to implement lightweight persistence.
Object serialization was added to the language to support two major features: Remote mothod invocation(RMI) and Java Beans.
To serialize an object, you create some sort of OutputStream object and then wrap it insied an ObjectOutputStream object. Then you can writeObject() to the stream. To reverse the process, you wrap an InputStream inside an ObjectInputStream and call readObject().
Case Study: Worm.java