axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Pridemore, Russell (MAN-Corporate)" <Russell.Pridem...@cox.com>
Subject RE: Object lists in axis
Date Wed, 13 Oct 2004 16:06:57 GMT
I return lists of objects like this:
 
<types>
  <xsd:schema targetNamespace="http://...">
    <xsd:complexType name="person">
      <xsd:sequence>
        <xsd:element name="name" type="xsd:string"/>
        <xsd:element name="address" type="xsd:string" maxOccurs="2"/>
        <xsd:element name="city" type="xsd:string"/>
        <xsd:element name="state" type="xsd:string"/>
        <xsd:element name="zip" type="xsd:string"/>
      </xsd:sequence>
    </xsd:complexType>
 
    <xsd:complexType name="personList">
      <xsd:sequence>
        <xsd:element name="people" type="my:person" minOccurs="0"
maxOccurs="unbounded"/>
      </xsd:sequence>
    </xsd:complexType>
</types>
 
<message name="GetPersonRequest">
  <part name="key" type="..."/>
</message>
<message name="GetPersonResponse">
  <part name="persons" type="my:personList"/>
</message>
 
Hope this helps,
Russ
-----Original Message-----
From: Suzy Fynes [mailto:suzanne.fynes@sentenial.ie]
Sent: Wednesday, October 13, 2004 11:54 AM
To: axis-user@ws.apache.org
Subject: Object lists in axis


Hey,
 
Have a question, I have an object containing loads of information on a
person e.g name, phone number, address etc I want to send someone a list of
these people using axis. I store the list in an ArrayList containing objects
of each person. Seen as ArrayLists are just for java its not good for a web
service, so I created an array of objects. Now considering it has to be
generic the objects can only be Strings, Integers etc 
 
So my question is how can I return more than one piece of information using
only Data type objects? Currently all web services ive deployed only use
access one method, could I have say 5 methods all returning different
information of the person. Ie. one method returns all the names, second one
returns all phone numbers etc
 
Any help would be great!
Thanks,
Sue
 

Mime
View raw message