hey Martin, What do you mean by 1.0? I am using Axis2 1.0, is there v1.3 out for Axis2 ? I am actually experimenting using stub (generated by WSDL2Java) to write the client, echoString is just a simple example I started with.... Do you have any idea where I might find some resources about using stub to writing client ? thanks, Jenny
2006-05-29 ======= 2006-05-29 08:54:23 you wrote:======= >Is there a reason why you are using Axis 1.0 instead of 1.3? >The new 1.3 uses class org.soapinterop.EchoString >and the specific method call is org.soapinterop.EchoString(java.lang.String) > >M- > >This email message and any files transmitted with it contain confidential >information intended only for the person(s) to whom this email message is >addressed. If you have received this email message in error, please notify >the sender immediately by telephone or email and destroy the original >message without making a copy. Thank you. > >----- Original Message ----- >From: "Jenny ZHANG" <[EMAIL PROTECTED]> >To: "axis-user" <[email protected]> >Sent: Sunday, May 28, 2006 1:41 PM >Subject: [Axis2] Pls help ----> about using stub to writing >echoStringclient. > > >> Hey, >> >> I used WSDL2Java to generate a stub for Axis2SampleDocLitService.aar as >> instructed in user's manual. >> and then tried to use the stub to write a simple client .java for its >> echoString operation (the codes are >> attached) , however, when I compiled it, it said >> >> " [javac] >> C:\Apache\Axis2-std-1.0\samples\src\src\echoStringClient.java:24: cannot >> apply org.apache.axis2.userguide.Axis2SampleDocLitServiceStub's >> echoString(org >> .apache.axis2.userguide.Axis2SampleDocLitServiceStub.EchoStringParam) to >> (or >> g.apache.axis2.userguide.xsd.EchoStringParamDocument) " >> >> Could anyone please tell me what's wrong with the codes? Thanks ! >> >> Jenny >> [EMAIL PROTECTED] >> 2006-05-29 >> >> ---------------------------------- >> import org.apache.axis2.userguide.xsd.EchoStringParamDocument; >> import org.apache.axis2.userguide.xsd.EchoStringParamDocument.*; >> import org.apache.axis2.userguide.xsd.EchoStringReturnDocument; >> import org.apache.axis2.userguide.xsd.EchoStringReturnDocument.*; >> import org.apache.axis2.userguide.Axis2SampleDocLitServiceStub; >> import org.apache.axis2.addressing.EndpointReference; >> >> public class echoStringClient { >> private static EndpointReference targetEPR = new >> EndpointReference("http://127.0.0.1:8080/axis2/services/Axis2SampleDocLitService"); >> >> public static void main(String[] args) { >> try { >> //Create the stub by passing the AXIS_HOME and target EPR. >> //We pass null to the AXIS_HOME and hence the stub will use the >> current directory as the AXIS_HOME >> Axis2SampleDocLitServiceStub stub= new >> Axis2SampleDocLitServiceStub(null, >> >> "http://localhost:8080/axis2/services/Axis2SampleDocLitService"); >> >> //Create the request document to be sent. >> EchoStringParamDocument reqDoc= >> EchoStringParamDocument.Factory.newInstance(); >> reqDoc.setEchoStringParam("Axis2 Echo"); >> >> //invokes the Web service. >> EchoStringReturnDocument resDoc=stub.echoString(reqDoc); >> System.out.println(resDoc.getEchoStringReturn()); >> >> } catch (Exception e) { >> e.printStackTrace(); >> } >> >> } >> } >> >> >> >> >> --------------------------------------------------------------------- >> To unsubscribe, e-mail: [EMAIL PROTECTED] >> For additional commands, e-mail: [EMAIL PROTECTED] >> >> = = = = = = = = = = = = = = = = = = = =
