Hi,

I have my own JavaBeans, that serialized and deserialized correctly and also
can be sent as arrays. It was very easy to do this, so I think i
misunderstand you...
But for me it looks like this:
If the serialization/deserialization (I hate to write these words, they not
common with my german orthography :-) ) works correctly just define at your
Service as return-type an object-array. If the object you wanna send is an
ArrayList, e.g. call the toArray()-method and it should be sent.
On client side cast you returnvalue from invoke into object[] and after that
all the objects to your beans:

Object response = call.invoke(new Object[]{});
Object[] resArray = (Object[])response;
for(int i=0;i<resArray.length;i++)
{
  MyBean curBean = (MyBean)resArray[i];
...
}

for me that works without any problems. Maybe it helps you.

Greetings from Hamburg/Germany
Seppo

-----Ursprüngliche Nachricht-----
Von: McCaslin Orion [mailto:[EMAIL PROTECTED]] 
Gesendet: Donnerstag, 9. Januar 2003 01:51
An: [EMAIL PROTECTED]
Betreff: No deserializer defined for array type ?


Hi,

I am not having success getting an array of complex objects deserialized in
a simple test client.

Has anybody figured out how to solve this error?

org.xml.sax.SAXException: No deserializer defined for array type
{http://object.myObject}MyObject at
org.apache.axis.encoding.ser.ArrayDeserializer.onStartElement(ArrayDeseriali
zer.java:257)


The Service function:
public MyObject[] getMyObjects() {
      MyObject[] myObjArray = new MyObject[3];
        myObjArray[0]= new MyObject();
        myObjArray[1]= new MyObject();
        myObjArray[2]= new MyObject();
        return(myObjArray);
}

I've seen a few of these error postings w/o answers.

In another posting, a workaround was mentioned...
----------------------------------------------------
Define a class which holds your array, and make the
new class a bean. Something like this

class Folders {
        Folder[] folders;
      getter/setter functions
-----------------------------------------------------
Is this really the only way?

Many thanks,
Orion

Reply via email to