How can I easily enable the persistence of JavaBeans components as XML files?

Govind Seshadri

The persistence scheme added in JDK 1.4 uses instances of the XMLEncoder class to write out files representing JavaBeans components. Every file written by XMLEncoder uses the same XML schema, regardless of the beans the file contains. The corresponding reader, XMLDecoder, can be used to read the encoded XML files. For more details read the paper: Long Term Persistence of JavaBeansTM Components: XML Schema