Welcome to the "trac"-ing site of soap4r!
[soap4r] [httpclient] [openpgp4u] [pkcs1] [logger] [csv] [vtr]

Ticket #168 (closed enhancement: fixed)

Opened 3 years ago

Last modified 3 years ago

<choice> support

Reported by: nahi Assigned to: nahi
Priority: high Milestone: 1.5.6
Component: wsdl4r Version: 1.5
Keywords: Cc:

Description

Hi all,

I am testing a SOAP server using SOAP4R and have generated drivers from
the WSDL with wsdl2ruby.

One of the WSDL files contains the following definition:

<xsd:element name="terminalID" minOccurs="1" maxOccurs="1">
  <xsd:complexType>
     <xsd:choice>
        <xsd:element name="imei" type="xsd:string"/>
        <xsd:element name="devId" type="xsd:string"/>
     </xsd:choice>
  </xsd:complexType>
</xsd:element>

If I understand this correctly the server expects something like:

<terminalID><imei>1000000000</imei></terminalID>

or

<terminalID><devId>1000000000</devId></terminalID>

However the default.rb file that was generated contains a
@@schema_element with:

["terminalID", nil]

when I am building the object to send it in the SOAP message I cannot
find a way to include one of the two choices in the terminalID element.
How would I be able to do that?

Thanks,
Mark

Change History

10/30/05 22:10:25 changed by nahi

  • status changed from new to closed.
  • resolution set to fixed.

(In [1655]) added <choice/> support. closes #168.