Marco Rossi wrote:

I try to create a ws with axis and Tomcat 4.
I want that my ws return a simple object, something like this:

Class SimpleObject{
        private String name;

        public String getName(){
                return name;
}

public void setName(String name){
        this.name = name;
}
}

My start class looks like:

Class SimpleWS{
        public SimpleObject testWS(){
                SimpleObject so = new SimpleObject();
                so.setName("test");

                return so;
}
}

When I try to test my client, I fetch a null object (SimpleObject ==
null), but if I try to return a simple type (i.e. a String field) it
works.

Thanks in advance,
Marco



Are you using the BeanSerializer ?
If so, try to add a default constructor to your SimpleObject  :

public SimpleObject() { }

Reply via email to