wsdl ,not able to pass a complex type to a method

R

Rahul Sharma

I'm trying to use a web service .
I am using 'soap/rpc/driver' after creating an object of the driver
class , i am able to authenticate by calling a method on it .

- <element name="authenticate">
- <complexType>
- <sequence>
<element name="username" type="xsd:string" />
<element name="password" type="xsd:string" />
</sequence>
</complexType>
</element>

i am able to authenticate using the code below
driver = SOAP::RPC::Driver.new(URL, NAMESPACE)
driver.add_method('authenticate','username','password')
driver.add_method('authenticateResponse','authenticateReturn')
sid= driver.authenticate('uname','pwd')

I want to use the hostCreate method , it takes the instance of
HostTransport as argument, I cannot figure out ,how can I pass this as
argument. Pls help .
I have pasted the related wsdl below


- <complexType name="TransportObject">
<sequence />
</complexType>
- <complexType name="ConfigurationTransport">
- <complexContent>
- <extension base="impl:TransportObject">
- <sequence>
<element name="ID" nillable="true" type="xsd:int" />
<element name="description" nillable="true" type="xsd:string" />
<element name="name" nillable="true" type="xsd:string" />
</sequence>
</extension>
</complexContent>
</complexType>
- <complexType name="HostTransport">
- <complexContent>
- <extension base="impl:ConfigurationTransport">
- <sequence>
<element name="agentVersion" nillable="true" type="xsd:string" />
<element name="displayName" nillable="true" type="xsd:string" />
<element name="external" type="xsd:boolean" />
<element name="externalID" nillable="true" type="xsd:string" />
<element name="hostGroupID" nillable="true" type="xsd:int" />
<element name="platform" nillable="true" type="xsd:string" />
<element name="securityProfileID" nillable="true" type="xsd:int" />
</sequence>
</extension>
</complexContent>
</complexType>




- <element name="hostCreate">
- <complexType>
- <sequence>
<element name="host" type="impl:HostTransport" />
<element name="sID" type="xsd:string" />
</sequence>
</complexType>
</element>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,764
Messages
2,569,566
Members
45,041
Latest member
RomeoFarnh

Latest Threads

Top