axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jinesh Varia <jineshresea...@yahoo.com>
Subject RE: was this bug fixed?? deserializing beans within an array in a bean
Date Fri, 14 Mar 2003 05:41:00 GMT
Sir,

Thank you for your reply. I understand it is a bug and I will also track its activity. But
I am
highly dependent on AXIS now. Can you please suggest me a workaround? or a pointer on where
would
I need a change? I am using AXIS1.1RC2 one tomcat apache linux

My SOAP response is working fine when I simple send a SOAPRequest. ( I used XMLSPY to send
a SOAP
request and recieve it)

The SOAP response is in this format

<publications>
<item>
<pubid>34234</pubid>
<title>afdadfs</title>
<persons>
<item>
<perid>33<perid>
<personname>asfasdfasdfasdf</personname>
</item>
<item>
<perid>33<perid>
<personname>asfasdfasdfasdf</personname>
</item>
</persons>
</item>
<item>
<pubid>342334244</pubid>
<title>afdadfasdfasdffs</title>
</item>
<publications>


My data structures are:

public class Person 
{
	private int perID;
	private String personName;
}

public class Publication 
{
	private int pubID;
	private String title;
	Person [] person;
	int year;
}

-----------------
My WSDL is attached 
Web service is functioning perfectly at http://dblpseer.ist.psu.edu/ws/services/DBLPSeerPort?WSDL
---------------

I am getting SOAP responses when I send the requests but when I am using a client, It gives
me
this error.

for eg.  My searthTitle takes in a searchString (SearchTitleRequestType )and returns a Publication
Array. Hence when it executes the function (does the RPC) and when it returns it gives me
this
error 


//MyClient.jsp

 DBLPSeerWebService service = new DBLPSeerWebServiceLocator();

 DBLPSeerPortType port = service.getDBLPSeerPort();
 
 SearchTitleRequestType body = new SearchTitleRequestType();
 body.setSearchString(searchString);

 Publication temp[];
 SearchTitleResponseType strp = port.searchTitle(body);
 temp = strp.getPublications();<<<<<<<<<<<<<####1 :
I think it gives an error here.

 //And then I print this array
###@2: Or over here
while(temp[i]!=null){
		<%= temp[i].getPubID() %>"><b><%= temp[i].getTitle() %></b>
	        <%= temp[i].getYear() %><br />
		<span class="f">Authors/Editors: </span>
		<% int j=0;
			while(temp[i].getPersons()[j]!=null){
				
	<%= temp[i].getPersons()[j].getPerID() %>::<%= temp[i].getPersons([j].getPersonName()
%>, 
	<%
			j++;
			} 
i++
}


I think since the Publications element is an SOAP array and it contains a Persons element
which
contains a SOAPArray, the problem is coming...

Can you please give me a pointer or a workaround???? It will be HIGHLY WORSHIPPED at this
point of
time.


THANKS
Jinesh


ps. I tried changing my WSDL which would put the PERSON and PUBLICATION elements inside the
ARRAYS
so that it does not give <item> but gives <publication> (under <publications>)
and <person> (under
<persons>) BUT then it did not create the getters and setters functions at all. and
I could
proceed!!

AnyBODY ANY HELP!! will be appreciated.....





--- David Gilbert <dgilbert@cragmonttech.com> wrote:
> There are a few bugs still outstanding regarding deserializing java bean
> arrays.  Please see http://nagoya.apache.org/bugzilla/index.html for a
> listing and the latest status.
> 
> -----Original Message-----
> From: Jinesh Varia [mailto:jineshresearch@yahoo.com]
> Sent: Thursday, March 13, 2003 4:59 PM
> To: dgilbert@cragmonttech.com
> Cc: axis-user@ws.apache.org
> Subject: was this bug fixed?? deserializing beans within an array in a
> bean
> 
> 
> I am using AXISRC2. PLEASE somebody inform me whether this but is fixed or
> not??
> thanks
> 
> org.xml.sax.SAXException: No deserializer defined for array type Publication
> 	at org.apache.axis.AxisFault.makeFault(AxisFault.java:129)
> 	at org.apache.axis.client.Call.invoke(Call.java:2237)
> 	at org.apache.axis.client.Call.invoke(Call.java:2133)
> 	at org.apache.axis.client.Call.invoke(Call.java:1656)
> 	at DBLPSeerClient.DBLPSeerBindingStub.searchTitle(DBLPSeerBindingStub
> 
> =====
> -----------------------------------------------------------------
> Jinesh Varia
> Graduate Student, Information Systems
> Pennsylvania State University
> Email: jinesh@psu.edu
> -----------------------------------------------------------------
> 'Self is the author of its actions.'
> 
> __________________________________________________
> Do you Yahoo!?
> Yahoo! Web Hosting - establish your business online
> http://webhosting.yahoo.com
> 


=====
-----------------------------------------------------------------
Jinesh Varia
Graduate Student, Information Systems
Pennsylvania State University
Email: jinesh@psu.edu
-----------------------------------------------------------------
'Self is the author of its actions.'

__________________________________________________
Do you Yahoo!?
Yahoo! Web Hosting - establish your business online
http://webhosting.yahoo.com
Mime
View raw message