Thanks for the message. Even when I change "SOAP-ENC:Array[3]" to have "http://soapinterop.org/xsd:LocationVo[3]" it still gives the same error. I've created TypeMappings for Both the LocationObject and LocationVo. LocationObject contains a name (string) and a LocationVo[].
I've been able to successfully have one LocationVo (not in an array) inside of a LocationObject, but not a LocationVo[]). Thanks - Dave. --- Tom Jordahl <[EMAIL PROTECTED]> wrote: > > There is no type on the <item>'s, and nothing that > tells Axis what the array type is. > > Have you told Axis what "objLocation" contains? > Take a look at your type mappings and the XML your > are getting and see if it has all the info it needs > to realize the each array item is a complex type > (not a simple type, which is what its trying to > deserialize). > > Hope that helps. > > -- > Tom Jordahl > Macromedia Server Development > > > > -----Original Message----- > From: David Mullens [mailto:[EMAIL PROTECTED]] > Sent: Friday, December 06, 2002 3:46 PM > To: [EMAIL PROTECTED] > Subject: Problem with array (ArrayList) within an > object. > > > I'm using axis to connect to a PHP webservice (using > nusoap). I've included the XML response. Whenever > Axis trys to deserialize this, it generates the > following error: > org.xml.sax.SAXException: SimpleDeserializer > encountered a child element, which is NOT expected, > in > something it was trying to deserialize. > > I'm not sure what I need to do to 'fix' this. I've > tried using different deserializers, but it doesn't > seem to matter (the same error is generated). > Basically, I'm trying to get back an object, that > has > an arraylist (or an array) of a different object > contained within it. Any suggestion, info, etc is > greatly appreciated. > > Thanks - Dave. > > =========================================== > > <?xml version="1.0" encoding="UTF-8"?> > > <SOAP-ENV:Envelope > SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" > xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" > xmlns:xsd="http://www.w3.org/2001/XMLSchema" > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" > xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" > xmlns:si="si"> > <SOAP-ENV:Body> > <getLocationsObjectResponse> > <output xsi:type="si:LocationsObject"> > <objName > xsi:type="xsd:string">object1</objName> > <objLocations xsd:type="SOAP-ENC:Array" > SOAP-ENC:arrayType="SOAP-ENC:Array[3]"> > <item> > <locationCode > xsi:type="xsd:string">place</locationCode> > <location xsi:type="xsd:string">test > House</location> > <city xsi:type="xsd:string">here</city> > <state xsi:type="xsd:string">ky</state> > <zip xsi:type="xsd:string">34332</zip> > <phone xsi:type="xsd:string">na</phone> > <website > xsi:type="xsd:string">http://www.nowhere.com</website> > </item> > <item> > <locationCode > xsi:type="xsd:string">place2</locationCode> > <location > xsi:type="xsd:string">someone's > House</location> > <city xsi:type="xsd:string">there</city> > <state xsi:type="xsd:string">CA</state> > <zip xsi:type="xsd:string">98923</zip> > <phone xsi:type="xsd:string">na</phone> > <website > xsi:type="xsd:string">http://www.nowhere.com</website> > </item> > <item> > <locationCode > xsi:type="xsd:string">Numb2</locationCode> > <location > xsi:type="xsd:string">number2</location> > <city xsi:type="xsd:string">where</city> > <state xsi:type="xsd:string">dc</state> > <zip xsi:type="xsd:string">23212</zip> > <phone xsi:type="xsd:string">na</phone> > <website > xsi:type="xsd:string">Https://www.somehwere</website> > </item> > </objLocations> > </output> > </getLocationsObjectResponse> > </SOAP-ENV:Body> > </SOAP-ENV:Envelope> > > ===== > David Mullens > Java Programmer > Marion, IN > > __________________________________________________ > Do you Yahoo!? > Yahoo! Mail Plus - Powerful. Affordable. Sign up > now. > http://mailplus.yahoo.com ===== David Mullens Java Programmer Marion, IN __________________________________________________ Do you Yahoo!? Yahoo! Mail Plus - Powerful. Affordable. Sign up now. http://mailplus.yahoo.com
