我使用nusoap生成wsdl并且我在试图描述选择元素(xsd:choice)时陷入困境。
所需的xsd部分如下所示:
<xsd:complexType name="sensitivityConditionType">
<xsd:sequence>
<xsd:choice minOccurs="1" maxOccurs="unbounded">
<xsd:element name="sensitivityCondition" type="tns:sensitivityConditionType" minOccurs="1" maxOccurs="1" />
<xsd:element name="operandCondition" type="tns:condition" minOccurs="1" maxOccurs="1" />
</xsd:choice>
</xsd:sequence>
<xsd:attribute name="operator" type="xsd:string" use="required" />
<xsd:attribute name="sensitivityType" type="xsd:string" use="optional" default="VIOLATELIMIT" />
</xsd:complexType>
目标是需要“sensitivityCondition”或“operandCondition”之一,但我没有找到以编程方式生成此结构的任何解决方案。
Thanx的帮助。