1 回答

aluckdog
TA貢獻1847條經(jīng)驗 獲得超7個贊
1.了解url : http://localhost:8080/test/services/user?wsdl;
2.新建web service 項目 Test,啟動接口;
3.在項目Test上新建一個 web service client ,選擇JAX_WS;
4.Test項目會自動生成關(guān)聯(lián)代碼,新建一個Java類,main方法
1 2 3 4 5 6 7 8 9 | public static void main(String[] args) { System.out.println("123"); ServiceCommandService sc = new ServiceCommandService(); IServiceCommand is = sc.getServiceCommandPort(); String s = is.queryInstanceById(); System.out.println(s); String s2 = is.queryInstanceList(); System.out.println(s2); } |
添加回答
舉報
0/150
提交
取消