You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by sentenza <se...@gmail.com> on 2006/12/02 10:01:10 UTC

java.util.List serialization

Hi,

I want make web services with pojo class using axis2.
I have 2 class :

public class Content
{

}


-- 
char sentenza[] =
"\xeb\x0d\x5f\x31\xc0\x50\x89\xe2"
"\x52\x57\x54\xb0\x3b\xcd\x80\xe8"
"\xee\xff\xff\xff/bin/sh";

Re: java.util.List serialization

Posted by sentenza <se...@gmail.com>.
Sorry I send mail by error :P

so I have 2 class:

public class Content {

    List<String>    users = new ArrayList<String>(0);

    public List<String> getUsers() {
        return users;
    }

    public void setUsers(List<String> users) {
        this.users = users;
    }
}

public class WSContent {

    public Content getContent() {
        Content content = new Content();

        List<String> users = new ArrayList<String>(0);
        users.add("test");
        users.add("test2");
        content.setUsers(users);
        return content;
    }

}

When I invoke the service by calling getContent() method I have the
following error on tomcat:

GRAVE: Exception occurred while trying to invoke service method getContent
org.apache.axiom.om.OMException: java.lang.IllegalArgumentException: null
rcl

Apparently this due to the List type in Content class :/

My question is how can I serialize the java.util.List ?

On 12/2/06, sentenza < sentenza9@gmail.com> wrote:
>
> Hi,
>
> I want make web services with pojo class using axis2.
> I have 2 class :
>
> public class Content
> {
>
> }
>
>
> --
> char sentenza[] =
> "\xeb\x0d\x5f\x31\xc0\x50\x89\xe2"
> "\x52\x57\x54\xb0\x3b\xcd\x80\xe8"
> "\xee\xff\xff\xff/bin/sh";




-- 
char sentenza[] =
"\xeb\x0d\x5f\x31\xc0\x50\x89\xe2"
"\x52\x57\x54\xb0\x3b\xcd\x80\xe8"
"\xee\xff\xff\xff/bin/sh";