V
V
Viktor Yanyshev2019-06-27 11:24:15
SOAP
Viktor Yanyshev, 2019-06-27 11:24:15

How to specify in WSDL that arguments are required to be passed?

There is a type description like this:

<xsd:complexType name="Order">
                <xsd:sequence/>
                <xsd:attribute name="ClientSystemID" type="xsd:int"/>
                <xsd:attribute name="BuildingID" type="xsd:int" use="required"/>
                <xsd:attribute name="Phone" type="xsd:string" use="required"/>
            </xsd:complexType>
            <xsd:complexType name="OrderProps">
                <xsd:complexContent>
                    <xsd:restriction base="soapenc:Array">
                        <xsd:sequence/>
                        <xsd:attribute ref="soapenc:arrayType" wsdl:arrayType="tns:Order[]"/>
                    </xsd:restriction>
                </xsd:complexContent>
            </xsd:complexType>

On the client, I send an empty array, an empty object is returned in response, should it return an error if use="required" is specified, or how to indicate that the attributes are required?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alex Murfy, 2019-06-27
@qxcoder

Full article HERE.
5d149ba5a8a28802560479.png

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question