Error msg: org.xml.sax.SAXException: Bad types (class [Ljava.lang.Object; -> class GlazeService.User)
What is wrong what do i have to do.. ?


public class Client {
        public static void main(String[] args) {
                try{
                        String endpointURL = 
"http://localhost:8080/axis/services/GlazeService";;
                        Service service = new Service();
                        Call call = (Call) service.createCall();
                        QName qn = new QName( "urn:GlazeService.Service", 
"User" );
                        call.setOperationName("ldap_GetAllUsernames");
                        call.setTargetEndpointAddress( new 
java.net.URL(endpointURL) );
                        call.registerTypeMapping( User.class,
                                        qn,
                                        
org.apache.axis.encoding.ser.BeanSerializerFactory.class,
                                        
org.apache.axis.encoding.ser.BeanDeserializerFactory.class );
                        call.setReturnType(qn);
                    User[] tomte = (User[])call.invoke(new Object [] {});
                    System.out.println("Size: " + tomte.length);
                    for(int i = 0; i < tomte.length; i++){
                        System.out.println(tomte[i].GetGecos());
                    }
                }catch(Exception e){
                        System.out.println("Something is really fucked up: " + 
e.toString());
                }
        }
}


-----

WSDD FILE:

<deployment xmlns="http://xml.apache.org/axis/wsdd/";
xmlns:java="http://xml.apache.org/axis/wsdd/providers/java";
xmlns:glaze="http://www.soapinterop.org/dealService";>
<service name="GlazeService" provider="java:RPC">
<parameter name="className" value="GlazeService.Service"/>
<parameter name="allowedMethods" value="*"/>
<operation name="ldap_GetAllUsernames" qname="glaze:ldap_GetAllUsernames"
returnQName="ldap_GetAllUsernamesReturn"
returnType="glaze:ArrayOfUser">
</operation>
</service>
<beanMapping qname="glaze:User" languageSpecificType="java:GlazeService.User"/>
<typeMapping qname="glaze:ArrayOfUser" type="java:GlazeService.User[]"
serializer="org.apache.axis.encoding.ser.ArraySerializerFactory"
deserializer="org.apache.axis.encoding.ser.ArrayDeserializerFactory"
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
</deployment>


_________________________________________________________________
Chat: Ha en fest p� Habbo Hotel http://habbohotel.msn.se/habbo/sv/channelizer Checka in h�r!




Reply via email to