RE: optionality of operation nodes in the interface et. al

Menon,

input, output, and fault are optional because there is no useful way to express co-occurrence constraints in W3C XML Schema.  An operation ought to conform to its associated Message Exchange Pattern, but that may mean that the cardinality of any two of the cited elements (input, output, fault) may be zero.  This is also why they have unbounded upper cardinality.

As to "empty" interfaces, while I do not recall the discussion of this in detail, there are two outstanding reasons for them, both related to interface inheritance.

1) an empty interface might be used as a marker (this is not a terribly convincing argument, in my opinion, but I'm speaking solely for myself throughout this response)

2) an "empty" interface might inherit from one or more existing interfaces.  In particular, it might "unite" two disparate interfaces, allowing a single service to provide the unified interface (since services may only implement one interface).  In this case, the interface element is "empty," but extends existing interfaces.  Again, there is no way to express this co-occurrence constraint in W3C XML Schema.

Oh, and finally:

3) no harm, no foul.  :-)  A truly empty interface isn't of any particular use, but it doesn't harm anything (that I can think of; you're welcome to suggest reasons that might cause the WG to consider this a defect).

Amy!

-----Original Message-----
From: www-ws-desc-request@w3.org on behalf of Ramkumar Menon
Sent: Thu 3/2/2006 5:55 AM
To: www-ws-desc@w3.org
Subject: optionality of operation nodes in the interface et. al
 
Hi All,

Had a question on the WSDL 2.0 schema.
What is the reason for the optionality of "operation" nodes in an interface
? Similarly, the optionality of the input, output and faults for operations
etc ?
If I have an interface with no operation nodes within it, it wd be still
considered syntactically valid. [the behaviour is the same in WSDL
1.1schema as well].

rgds,
Menon
--
Shift to the left, shift to the right!
Pop up, push down, byte, byte, byte!

-Ramkumar Menon
A typical Macroprocessor

Received on Friday, 3 March 2006 03:43:46 UTC