SOAP Complex Type Variable

[email protected] (Punit Gupta)
Newsgroups php.soap
Message-ID <6BDB420ACBE990478825E673755DF99604FD4D9559@NELSON.endeavordc.endeavortelecom.com>
I am building a webservice using PEAR SOAP and I need to define a complex type which can take input like following:

<EquipmentInfo>
            <Equipment>
                        <EquipmentTypeId></EquipmentTypeId>
                        <Quantity></Quantity>
            </Equipment>
            <Equipment>
                        <EquipmentTypeId></EquipmentTypeId>
                        <Quantity></Quantity>
            </Equipment>
</EquipmentInfo>


EquipmentInfo variable needs to be defined as a sequence of elements of type Equipment. Equipment Type should have two sub-elements. Following is the source code but it doesn't produce correct WSDL.

class EquipOrder
{
             var $__dispatch_map = array();
             var $__typedef = array();

             function EquipOrder () {
                        $this->__typedef['Equipment'] =   array("EquipmentTypeId"=>"Integer", "Quantity"=>"Integer");

                        $this->__typedef['EquipmentInfo'] =  array(array('Equipment'=> "{urn:EquipOrder}Equipment"));
            }

}


Can someone please shed some light on it?

Thanks,
-Punit.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.