axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Pratiksha Powar <pratiksha.po...@onmobile.com>
Subject Re: Regarding Axis serialization of "user-defined object containing array of objects"
Date Thu, 31 Jan 2008 10:45:06 GMT
Hi Everybody,

I was able to solve my problem of serialization.
The solution is as follows:
I had to mark every member variable of my user-defined object "public".
Also I had to make a few modifications in my deployment descriptor. 
I got this info from
http://www.javaranch.com/journal/200603/WSComplexTypes.html


Now I'm facing a problem with deserializing the object on client side. 
My Object contains a 2D Array of objects of type java.lang.Object, 2 int
values and 1 String object.
While deserializing I'm getting the following error:

Caused by: org.xml.sax.SAXException: No object was found for class type
int
   at
org.apache.axis.encoding.ConstructorTarget.set(ConstructorTarget.java:97)
   at
org.apache.axis.encoding.DeserializerImpl.valueComplete(DeserializerImpl.java:249)
   at
org.apache.axis.encoding.ser.ArrayDeserializer.valueComplete(ArrayDeserializer.java:583)
   at
org.apache.axis.encoding.DeserializerImpl.endElement(DeserializerImpl.java:509)
   at
org.apache.axis.encoding.DeserializationContext.endElement(DeserializationContext.java:1087)
   at
org.apache.axis.message.SAX2EventRecorder.replay(SAX2EventRecorder.java:171)
   at
org.apache.axis.message.MessageElement.publishToHandler(MessageElement.java:1141)
   at
org.apache.axis.encoding.DeserializerImpl.startElement(DeserializerImpl.java:369)
   at
org.apache.axis.encoding.ser.BeanDeserializer.startElement(BeanDeserializer.java:154)
   at
org.apache.axis.encoding.DeserializationContext.startElement(DeserializationContext.java:1048)
   at
org.apache.axis.message.SAX2EventRecorder.replay(SAX2EventRecorder.java:165)
   at
org.apache.axis.message.MessageElement.publishToHandler(MessageElement.java:1141)
   at
org.apache.axis.message.RPCElement.deserialize(RPCElement.java:345)
   at org.apache.axis.message.RPCElement.getParams(RPCElement.java:384)
   at org.apache.axis.client.Call.invoke(Call.java:2467)

I'm attaching my server-config.wsdd and my client-side program.
Can anyone help me here?

Thanks,
Pratiksha

On Tue, 2008-01-29 at 12:25 +0530, Pratiksha Powar wrote:
> Hi Everybody,
> 
> I'm trying to return a user-defined object which contains two primitives
> namely : int and Java String and a 2D array of objects of
> type :java.lang.Object
> Can you tell how should I map these objects in the server-config.wsdd
> file so that axis produces the correct wsdl ?
> I'm attaching my copy of server-config.wsdd.
> Also is it possible to write your own wsdl and make axis point to it?
> 
> Thanks,
> Pratiksha
> 
> 
> ==============================
> DISCLAIMER: The information in this message is confidential and may be legally privileged.
It is intended solely for the addressee. Access to this message by anyone else is unauthorized.
If you are not the intended recipient, any disclosure, copying, or distribution of the message,
or any action or omission taken by you in reliance on it, is prohibited and may be unlawful.
Please immediately contact the sender if you have received this message in error. Further,
this e-mail may contain viruses and all reasonable precaution to minimize the risk arising
there from is taken by OnMobile. OnMobile is not liable for any damage sustained by you as
a result of any virus in this e-mail. All applicable virus checks should be carried out by
you before opening this e-mail or any attachment thereto. 
> Thank you - OnMobile Global Limited.
> ==============================
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-user-help@ws.apache.org

Mime
View raw message