Write the object to an ObjectOutputStream. Make sure the classes you wish to write implement Serializable, and any info you don't need to be written marked as transient.