C:/Users/zhangya>wsimport -d E:/temp -keep -verbose -p test http://localhost:8888/ns?wsdl -keep -verbose -p test http://localhost:8888/ws01?wsdl-d <directory> specify where to place generated output files(指定生成文件的路徑)-verbose output messages about what the compiler is doing(輸出詳細信息)-keep keep generated files(生成java文件,不帶此參數將只生成class文件)-p <pkg> specifies the target package 生成代碼的目標包執行上面命令生成如下代碼
編寫測試類
package test;public class Test { public static void main(String[] args) { MyServiceipmlService msis = new MyServiceIpmlService(); IMyService ms = msis.getMyServiceIpmlPort(); ms.minus(10,1); } }
新聞熱點
疑難解答