I would like to be able to serialize objects to a human-readable and editable format.
For example the following class
-----------------------------
package com.blah.testing;
public class
Test implements java.io.Serializable
{
private
String name;
private int countOfSomething;
...
}
-------------------------------
might look like the following when serialized to a file
------------------------------
begin
type=com.blah.testing.Test
begin
type=java.lang.String;
fieldName=name;
fieldValue="John Doe";
end
begin
type=int;
fieldName=countOfSomething;
fieldValue=17;
end
end
------------------------------
Is anyone aware of something like a ObjectInputTextStream or an ObjectOutputTextStream that could read and write objects from and to a nice readable format like the above format?
If not, do you have suggestions on how to write classes to implement the above streams?
Thanks,
Chip