Re: complexTypes for dynamic invocations?

From: Jan Tietjens <jantietjens_at_YAHOO.COM>
Date: Wed, 22 Jan 2003 02:03:33 -0700

Hello Kenneth,
please read my comments below.

On Wed, 22 Jan 2003 10:36:35 +0800, Kenneth Andersson <kandersson_at_SIMTECH.A-STAR.EDU.SG> wrote:

>1. For a generic XML construct other than simple datatypes, what parameter am I supposed to pass to the call.invoke(Object[] params) method?
>(Simple datatypes such as xsd:string, xsd:int, xsd:boolean are quite straightforward, just pass in java String[], Integer[], Boolean[], etc. What should I pass for a complex datatype? element?)
In that case, you are supposed to pass a custom Java object to the Call object. The object could contain a HashMap with all the member of a complex type. If you try to pass the object to the call object, you will receive a exception. The reason for this is, that you have to register a custom (de)serializer for your object. This is not a trivial task. You can get informations about the serializer and deserializer framerwork in the JAX-RPC specification.

I've allready developed a framework which is capable to handle XML complex data types, in with the DII. Thus I would recommend to study the source code from the UNO Web service proxy. It is open source, so feel free to use and modify the code. If you have some enhancements please send them to me.
You could find the code at the following web page:

Generall informations are here:

The component is tested with the google Web service, but there exists still bugs.

>2. To parse the WSDL is not that difficult, except the <wsdl:types> element since it (almost always) contains XML Schema. How to parse the XML Schema and then construct a corresponding XML? Any good XML Schema parsers out there?
>(I actually wrote my own WSDL Parser using JDOM, but I haven't dealt with the <wsdl:types> entry yet. Now I saw that JWSDL [JSR110] is released, but JWSDL also doesn't support the contents of <wsdl:types> [they treat it as extensibility elements since potentially not just XSD could be used])

I don't know about XML Schema parsers, I've implemented my own SAXParser.

I hope this helps,