Here is a simmalar example WSDL
Notice the TEmployer and TDateType inside the TPerson complex type. By calling Addperson I would be able to able to save a person via soap. this works but how do I pass values like this in perl to my soap server using Soap lite?

<?xml version="1.0"?><definitions name="Intf_person" targetNamespace=" +urn:Intf_person" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns: +soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:tns="urn:Intf_pers +on" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:SOAP-ENC="http +://schemas.xmlsoap.org/soap/encoding/" xmlns="http://schemas.xmlsoap. +org/wsdl/"> <types xmlns="http://schemas.xmlsoap.org/wsdl/"> <schema +xmlns="http://www.w3.org/2001/XMLSchema" targetNamespace="urn:Intf_pe +rson"> <complexType name="TPerson"> <all> <element name="Surname" typ +e="xsd:string" /> <element name="Fullname" type="xsd:string" /> <elem +ent name="DOB" type="tns:TDateType" /> <element name="Employer" type= +"tns:TEmployer" /> <element name="PostalAddress" type="tns:TPersonPos +talAddress" /> </all> </complexType> <complexType name="TPersonPostal +Address"> <all> <element name="ID" type="xsd:integer" /> <element nam +e="Line1" type="xsd:string" /> <element name="Line2" type="xsd:string +" /> <element name="Line3" type="xsd:string" /> <element name="Line4" + type="xsd:string" /> </all> </complexType> <complexType name="TEmplo +yer"> <all> <element name="Name" type="xsd:string" /> <element name=" +Tel" type="xsd:string" /> </all> </complexType> <complexType name="TD +ateType"> <all> <element name="Year" type="xsd:integer" /> <element n +ame="Month" type="xsd:integer" /> <element name="Day" type="xsd:integ +er" /> <element name="Hour" type="xsd:integer" /> <element name="Min" + type="xsd:integer" /> <element name="Sec" type="xsd:integer" /> </al +l> </complexType> </schema> </types> <portType name="Intf_personPort" +> <operation name="Addperson"> <input message="tns:AddpersonRequest" +/> <output message="tns:AddpersonResponse" /> </operation> </portType +> <binding name="Intf_personBinding" type="tns:Intf_personPort"> <soa +p:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http +" /> <operation name="Addperson"> <soap:operation soapAction="Intf_pe +rson#intf_person#Addperson" /> <input> <soap:body use="encoded" names +pace="Intf_person" encodingStyle="http://schemas.xmlsoap.org/soap/enc +oding/" /> </input> <output> <soap:body use="encoded" namespace="Intf +_person" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" /> + </output> </operation> </binding> <service name="Intf_personService" +> <documentation /> <port name="Intf_personPort" binding="tns:Intf_pe +rsonBinding"> <soap:address location="http://138.215.248.216:8080/Soa +p/ntf_person.php" /> </port> </service> <message name="AddpersonReque +st"> <part name="Item" type="tns:Tperson" /> <part name="Systems" typ +e="tns:TSystemsList" /> </message> <message name="AddpersonResponse"> + <part name="ErrorReturned" type="xsd:string" /> </message> </definit +ions>

20050114 Janitored by Corion: Added code tags around XML


In reply to Re^2: How to define a complex type with SOAP::Lite by za_switch
in thread How to define a complex type with SOAP::Lite by za_switch

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.