Version française
Home     About     Download     Resources     Contact us    

This site is updated infrequently. For up-to-date information, please visit the new OCaml website at

Browse thread
OCSoap Schema Restrictions
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Richard Jones <rich@a...>
Subject: Re: [Caml-list] OCSoap Schema Restrictions
On Wed, May 16, 2007 at 11:07:02AM +0200, Florian Hars wrote:
> I found this in the ocsoap  source:
> type Types = <wsdl:types> [
>      Documentation?
>      Schema (* Only allow a single schema here, even though the standard
> 	     * would allow multiple.
> 	     *)
>   ]
> Is there a deeper reason for this restriction? The silly web service I'd
> need to connect to contains 8 schema elements here...

Well, there's not really a deep reason, beyond the facts that (a) WSDL
is a ridiculously complicated standard, and (b) OCSoap understands
just about enough to be able to parse the Google AdWords schemas.

The shallow reason is in

let main () =
  let wsdl = wsdl_load filename in
  let schema = wsdl_schema wsdl in

You'll probably want to make wsdl_schema return a list of schemas,
then have this code iterate over them.  Doing the right thing with the
functions and types defined in each schema so that their names don't
clash with each other might be a bit harder: you might consider
putting them into separate submodules or just mangling the names.


Richard Jones
Red Hat