is dom serializable

hii've found in so many articles that DOM is not serializable. but once i made a DOM document and passed that document object to client thru rmi. is document object of DOM really serializable?thanx
[219 byte] By [sabbyna] at [2007-11-27 8:23:10]
# 1
No idea. org.omg.dom.Document isn't specificed to implement Serialize, but the (parser-dependent) implementation might.Why wouldn't you pass around the XML directly as text?
ejpa at 2007-7-12 20:11:59 > top of Java-index,Core,Core APIs...
# 2
do u mean sending the string to client and in client recreate the xml document and parse it?
sabbyna at 2007-7-12 20:11:59 > top of Java-index,Core,Core APIs...
# 3

> do u mean sending the string to client and in client

> recreate the xml document and parse it?

Yep. XML can be used as a serialization mechanism, it's one of it's uses: a definition of serialization is the representation of an in-memory object in a format that can then be used to re-create that object at another place or time, and XML can be used to achieve this. There's little point serializing something that's already serialized

georgemca at 2007-7-12 20:11:59 > top of Java-index,Core,Core APIs...
# 4

In this case you do not even need to send xml document because

you wiil first convert your object to Xml document then

send it to network and at other end you have to again parse it convert into a object ..

instead of doing that you can simply send the object as it is. u can save the overhead to marshal and unmarshal of your data object and xml.

sachin.agrawala at 2007-7-12 20:11:59 > top of Java-index,Core,Core APIs...
# 5

> In this case you do not even need to send xml

> document because

> you wiil first convert your object to Xml document

> then

> send it to network and at other end you have to again

> parse it convert into a object ..

>

> instead of doing that you can simply send the object

> as it is. u can save the overhead to marshal and

> unmarshal of your data object and xml.

Although serializing in a binary format has it's downsides. For one, if the class changes, this can break the deserialization. For another, it restricts the use to Java programs, whereas XML serialization can integrate disparate systems in different technologies (see: SOAP et al)

georgemca at 2007-7-12 20:11:59 > top of Java-index,Core,Core APIs...
# 6
point taken sir,
sachin.agrawala at 2007-7-12 20:11:59 > top of Java-index,Core,Core APIs...