Srianth,
        Thanks, this got me going in the right direction. I have been messing
around with it and here is what i think needs to be done.

before parsing the xml, the lexical=handler needs to be set to the parser
like this
parser.setProperty("http://xml.org/sax/properties/lexical-handler";,
handler);

and the handler needs to implement org.xml.sax.ext.LexicalHandler, the
DeserializationContextImpl is a perfect example of this.

but unfortunately the DeserializationContextImpl tries to build an envelope,
so what I am doing right now is building my own class that implements
deserializationcontext and builds an object instead of the soapenvelope
etc...

This should allow me to deserialize the xml into the necessary objects. I
think this is the correct way to do this, but if anyone has any input I
would love to hear it.


--George


-----Original Message-----
From: Srinath Perera [mailto:[EMAIL PROTECTED]
Sent: Friday, July 04, 2003 4:38 AM
To: [EMAIL PROTECTED]
Subject: RE: how to deserialize into bean


Hi George,
I got it to somewhere. I haven't test it yet. give it a try if u have
time. please note this is only a GUESS

I belive when you use getvalue() what u get is a object with no value's
set....ok.

we know the bean DeSerializer extends from the DefaultHandler (SAX).
create a SAX parser(something euqivelent eg:-XMLReader ). set your xml
source to the parser.
set the Deseiralizer as the ContentHandlerof the parser.

(i belive u know that staff - if not refer simple example for SAX)

then call parse() method.
then the values of the return object from getValue() should be set.
(if that works pls answer via mailing list).

regards.

Srianth

 time

Reply via email to