Usa ObjectOutputStream per serializzare e ObjectInputStream per deserializzare. Se poi hai problemi specifici chiedi pure