开发者

How to call web service from java code?

I want to call a web service "gatewaedi" from java code.

I a开发者_Python百科m not getting how to call it, could someone please provide an example?


This is how you call a webservice with JAX-RPC

String wsdlURL = "http://localhost:6080/HelloWebService/services/Hello?wsdl"[1];

String namespace = "http://Hello.com"[2];

String serviceName = "GatewaediWebService";

QName serviceQN = new QName(namespace, serviceName);

ServiceFactory serviceFactory = ServiceFactory.newInstance();

Service service = serviceFactory.createService(serviceQN);
  1. Should be replaced by the gatewaedi webservice call, which I can not find now.

  2. Should be replaced by the gatewaedi webservice corresponding namespace, that too I can't find.

If you want send me more information about this webservice and I will write you the complete code.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜