"I'm not back." - Bill Harding, Twister
Originally posted by Jim Yingst:
Or we could say that yes there is, and that way is by using an ObjectInputStream. From the question, it's not clear if you're familiar with the basics of how to use this.
Once you know the class of the object(s) in the file, you can cast the objects to the correct class and call other methods.
It also might be useful to use XStream to write an XML representation of each object after you read it. This tool does all the work of using reflection to identify all the fields in an object, and writes the object in an easy-to-read format.
"I'm not back." - Bill Harding, Twister
Originally posted by Jim Yingst:
Well, you probably need to include the far file(s) in your class path. Have you tried running the code I showed? What happens?
[ March 03, 2008: Message edited by: Jim Yingst ]
"I'm not back." - Bill Harding, Twister
"I'm not back." - Bill Harding, Twister
"I'm not back." - Bill Harding, Twister
"I'm not back." - Bill Harding, Twister
"I'm not back." - Bill Harding, Twister
Java Certifiication Courses: <a rel="nofollow">Santis</a>
SCJP 1.4 - SCJP 6 - SCWCD 5 - OCEEJBD 6 - OCEJPAD 6
How To Ask Questions How To Answer Questions
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime. |