import org.apache.axis.client.Call;
import org.apache.axis.client.Service;
import javax.xml.namespace.QName;
import java.lang.Integer;
public class Test {
/**
* @param args
*/
public static void main(String[] args) throws Exception{
String varname="haha";
String endpoint="http://localhost:1314/web/Service.asmx";
Service service=new Service();
Call call=(Call)service.createCall();
call.setTargetEndpointAddress(new java.net.URL(endpoint));
call.setOperationName(new QName("http://tempuri.org/","HelloWorld"));//notice
call.addParameter(new QName("http://tempuri.org/", "str"),org.apache.axis.encoding.XMLType.XSD_STRING,javax.xml.rpc.ParameterMode.IN);
call.addParameter(new QName("http://tempuri.org/", "second"),org.apache.axis.encoding.XMLType.XSD_STRING,javax.xml.rpc.ParameterMode.IN);
call.setReturnType(org.apache.axis.encoding.XMLType.XSD_STRING);
call.setUseSOAPAction(true);
call.setSOAPActionURI("http://tempuri.org/HelloWorld");
String output=(String)call.invoke(new Object[]{varname," Two"});
System.out.println(output);
}
}