It is a good idea to use serialize to save preferences (or new projects) in a swing-based app?
1 posts in topic
Flat View  Flat View

Posted By:   Juan_Perez
Posted On:   Monday, July 2, 2001 09:46 AM

What is better for saving app-project status: XML or serializing the whole project?

it serializing designed for saving the state of swing-apps?

Swing serialization format is not stable

Posted By:   Kevin_Riff  
Posted On:   Friday, September 7, 2001 09:18 AM

You could use serialization to store preferences but I would not serialize any Swing classes directly. Most of them still carry the warning that serialized instances may not be compatible with future versions. This means that if your users install a newer VM (even just a maitenance release), you run the risk that your saved data will not load anymore. Check the JavaDocs for any classes you plan to serialize and watch out for the warning.

About | Sitemap | Contact