Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Java > how to move from java object serialization to xml serialization?

Reply
Thread Tools

how to move from java object serialization to xml serialization?

 
 
Dimitri Ognibene
Guest
Posts: n/a
 
      09-01-2006
I've some classes that contains matematical models, I was used to save
and load them thorogh java serialization, now I wish to switch to xml..
can anyone help?

 
Reply With Quote
 
 
 
 
Andrew Thompson
Guest
Posts: n/a
 
      09-01-2006
Dimitri Ognibene wrote:
> I've some classes that contains matematical models, I was used to save
> and load them thorogh java serialization, now I wish to switch to xml..
> can anyone help?


Probably not until you identify a problem.
Did you have a specific question?

Andrew T.

 
Reply With Quote
 
 
 
 
Jean-Francois Briere
Guest
Posts: n/a
 
      09-01-2006
You could use the XMLEncoder XMLDecoder classes but it probably won't
fit your needs.
A simple Google with keywords "java xml serialization" gives XSteam at
the first result.
It's good. I've tried it in the past. There are others available
though.

Regards

 
Reply With Quote
 
=?ISO-8859-1?Q?Arne_Vajh=F8j?=
Guest
Posts: n/a
 
      09-01-2006
Dimitri Ognibene wrote:
> I've some classes that contains matematical models, I was used to save
> and load them thorogh java serialization, now I wish to switch to xml..


JAXB maybe ?

Arne
 
Reply With Quote
 
Dimitri Ognibene
Guest
Posts: n/a
 
      09-02-2006
there is not a standard way to do this work?

Another think, I want to do this change because I could need to
change my java code, but still need the data I've obtained in an older
version...
so.. sometime the data are exactly the same, some time there are some
new fields,
which i would set by hand to default values in the serialized version..
but I can't even read
the file in the first scenarion with standard serialization, the second
scenarion is quite sci-fi
So I think xml could feet my needs...
but I've seen many way and many libraries to do this in java..
I'd like to do the change with less effort possible.
Thank you

ps.
I've seen http://java.sun.com/products/jfc/tsc.../persistence4/,
http://java.sun.com/j2se/1.4.2/docs/...MLEncoder.html and
some other sun reference.. just in this moment.. what are the pros and
cons of this class?

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Re: How include a large array? Edward A. Falk C Programming 1 04-04-2013 08:07 PM
Re: [ANN] pyxser-1.2r --- Python-Object to XML serialization module Stefan Behnel Python 3 08-25-2009 05:23 AM
Object serialization XML vs java serialization plasticfloor@gmail.com Java 3 06-14-2006 03:45 AM
Serialization Problems and books on serialization? sinleeh@hotmail.com Java 8 01-02-2005 02:40 PM
avoiding XML serialization, different WSDL generation, soap serialization Ramunas Urbonas ASP .Net Web Services 1 07-27-2004 09:57 PM



Advertisments