Java 1, ObjectInputStream, '.dat' files and compatability.
807589Aug 4 2008 — edited Aug 8 2008I have taken over software development of a product from my client's previous programmer. I have been quite shocked to discover that the program is written in Java 1 even though it has been developed over the last year. Naturally I am trying to update the program to update the program, sort out the tangled code, fix bugs and continue development.
The program relies on a large number of ".dat" data files, and I have been unable to load the objects saved in these files although there is no problem with simple data types. However I am not entirely certain that the error is due to changes in format. But I have spend weeks trying to confirm this within the program, and I have found no mention of the problem using Google.
I have a number of questions about this ....
1) Has there been a change in representation of objects saved to file between Java 1 and the current edition?
2) Is there a difference between the representation on different operating systems, ie Windows, Mac, Linux etc
3) Would text files be a better way of storing data? It would be essential for the data files to be secured so that they could not be altered outside of the application. Does Java provide a facility to do this
What solutions do you suggest to the problem?
Thanks for your help.