axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jan Alexander" <a...@systinet.com>
Subject RE: Philosophical question about WSDL and web service frameworks
Date Mon, 14 Jan 2002 21:58:43 GMT
Hi James,

the problem may be in the OrderResponseHeader type, where the xsd:choice is used:

<choice occurs="?">
   <element type="OrderHeader" name="OriginalOrderHeader"/>
   <element type="ChangeOrderHeader"/>
</choice>

Unfortunately, there is no native support for such features in the Java Programming language
(for example in C++ one would use union construct).

We at Systinet plan to support the choice element in XML Schema in the next version of the
WASP Server product. The mapping to Java language we are proposing for example for this choice
element would look like this:

public class OrderResponseHeader
{
   ...
   public class Choice1
   {
       public static int DISC_ORDERHEADER = 1;
       public static int DISC_CHANGEORDERHEADER = 2;

         public int discriminator;

         public OrderHeader originalOrderHeader;
       public ChangeOrderHeader changeOrderHeader;
   }

    ...
}

Any comments ?

Jan Alexander
WASP Server Project Leader, Systinet (formerly Idoox)
http://www.systinet.com


> -----Original Message-----
> From: James Yegerlehner [mailto:james@kamiak.com]
> Sent: Saturday, January 12, 2002 5:12 PM
> To: axis-dev@xml.apache.org
> Cc: jsr-101-comments@jcp.org; mark@kamiak.com
> Subject: Philosophical question about WSDL and web service frameworks
>
>
> Hello all:
>
> Specialized markup languages are proliferating. Each such language defines
> types particular to some problem domain. For example, the xCBL schemas
> (www.xcbl.org) define schemas for types related to business transactions:
> invoice, product catalog, order, etc are all defined by xCBL.
>
> The complementary nature of these schemas to WSDL is obvious:
> WSDL specifies
> the type of each message part using a type or element in an XML
> schema. One
> must expect that developers of web services will wish to use the types
> defined by schema relevant to their problem domain. The natural way to
> proceed is to 1. create a WSDL document defining the web service interface
> and incorporating these domain-specific schema, and 2. generate the web
> service skeleton automatically from the WSDL.
>
> I think the authors of most of the web service frameworks realize
> that this
> is desirable, because they have utilities that allow creation of classes
> from WSDL.  But we haven't found a single one that can
> successfully create a
> skeleton if the web service includes an instance of the xCBL:Order and
> xCBL:OrderResponse types. There's nothing special about Order and
> OrderResponse except that these just happen to be the two we chose for the
> our test case.
>
> So my questions are: is it desirable that a service skeleton generator
> (WSDL2Java in the case of Axis) should be able to map WSDL that
> may contain
> _any_ valid schema? It seems so to me but I don't hear anyone else talking
> about this. Is it feasible? Do the current contributors to WSDL2Java have
> any plans in this direction?
>
> BTW I'm not complaining about Axis. I understand that it's open source and
> if I want certain functionality I should be willing to contribute it.
>
> Regards,
> ------------
> James Yegerlehner
> Omniopera: XML Schema and WSDL Authoring Software
> http://www.omniopera.com
>


Mime
View raw message