WSDL2Java classes to XML

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • J.Eddy

    WSDL2Java classes to XML

    Does anyone know how to go from a WSDL2Java generated class to an XML
    string of XML document. I know that there is some serialization here
    but I don't know what classes to call to do the serialization. Can
    anyone help?

    Thanks

    _someGenClass someClass = new _someGenClass() ;

    // do I use this function or is there some XML serialize class that
    // I can cast to?
    someClass.getSe rializer(/* some stuff here */);


    // I want to get to this point or to a string
    SOAPBodyElement
    // or to a
    org.w3c.dom.Doc ument
  • Christopher Blunck

    #2
    Re: WSDL2Java classes to XML

    On Wed, 05 Nov 2003 00:04:10 -0800, J.Eddy wrote:
    [color=blue]
    > Does anyone know how to go from a WSDL2Java generated class to an XML
    > string of XML document. I know that there is some serialization here
    > but I don't know what classes to call to do the serialization. Can
    > anyone help?
    >
    > Thanks
    >
    > _someGenClass someClass = new _someGenClass() ;
    >
    > // do I use this function or is there some XML serialize class that
    > // I can cast to?
    > someClass.getSe rializer(/* some stuff here */);
    >
    >
    > // I want to get to this point or to a string
    > SOAPBodyElement
    > // or to a
    > org.w3c.dom.Doc ument[/color]


    Hi J.Eddy-

    Why would you want to go from an object representation to XML format? If
    serialization is the response, perhaps you could do something less
    platform independent. If the answer is interoperabilit y, the SOAP layer
    you're using (I assume it's Axis) should provide the capability
    automatically.

    -c

    Comment

    Working...