您的位置:首页 > 其它

xfire调用webService接口方法

2009-12-16 15:04 441 查看
xfire调用webService接口方法
/**
* 获取连接对象
*/
private static Client getClient() {
synchronized (XXXService.class) {
if (client == null) {
try {
client = new Client(new URL("http:XXXX?wsdl"));
} catch (Exception e1) {
e1.printStackTrace();
}
}
}
return client;
}

// Client client = getClient();
// Object[] results = null;
// try {
// //调用特定的Web Service方法
// results = client.invoke("verifyRegister", new Object[] { idNo,
// idType,name});
// } catch (Exception e) {
// e.printStackTrace();
// }
// if (results == null)
// System.out.println("zero");
// else{
// for (int i = 0; i < results.length; i++) {
// System.out.println(results[i].toString());
// }
// }
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: