Hi all,

I've got some Java classes that look like this:

public class Person
{
        public String name;
}

public class People extends CommonResponse
{
        public Person[] persons;
}

I ran it through Axis 1.4 on Tomcat, using a deploy that has this in it:

<service name="MyService" provider="java:RPC" style="wrapped" use="literal">


...and this is part of the WSDL it generates for the service:

<complexType name="People">
  <complexContent>
    <extension base="impl:CommonResponse>
      <sequence>
<element name="persons" nillable="true" type="impl:ArrayOfPerson"/>
      </sequence>
    </extension>
  </complexContent>
</complexType>

<complexType name="ArrayOfPerson">
  <sequence>
<element maxOccurs="unbounded" minOccurs="0" name="item" type="impl:Person"/>
  </sequence>
</complexType>

<complexType name="Person">
  <sequence>
    <element name="name" nillable="true" type="xsd:string"/>
  </sequence>
</complexType>

As far as I can tell, this is a correct description of the array.

In the service, when I return an array of two Persons, Axis generates this in the response:

<people>
  <persons>
    <name>George</name>
  </persons>
  <persons>
    <name>Fred</name>
  </persons>
</people>

This doesn't seem right to me. Shouldn't there be just one <persons> with a bunch of <item> elements? Is Axis messing up?

Thanks,

--Rob

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to