import org.apache.axis.client.Call;
import org.apache.axis.client.Service;
public class Test {
/**
*
* @param args
* void
*/
public static void main(String[] args) {
try {
Integer reqFlag = new Integer(1);
String provinceCode = "1";
String cardSN = "1";
String data = "1";
String endpoint = "http://localhost:8099/SecrKeyMS/services/Consume";
String operation = "service";
Service service = new Service();
Call call = (Call) service.createCall();
call.setTargetEndpointAddress(new java.net.URL(endpoint));
call.setOperationName(operation);
String xml = (String) call.invoke(new Object[] {reqFlag,provinceCode,cardSN,data});
System.out.println(xml);
} catch (Exception e) {
e.printStackTrace();
}
}
}
简单的Axis客户端
最新推荐文章于 2022-09-13 14:13:50 发布