[ERROR] “不支持使用 SOAP 编码。SOAP 扩展元素包含 use=“encoded“ “ 无法解析 WSDL。
程序员文章站
2022-03-07 12:12:30
下载axis-1_4,地址https://archive.apache.org/dist/ws/axis/1_4/java -cp mail.jar;saaj.jar;jaxrpc.jar;commons-discovery-0.2.jar;commons-logging-1.0.4.jar;axis.jar;activation.jar;wsdl4j-1.5.1.jar org.apache.axis.wsdl.WSDL2Java D:\TmriOutNewAccess.xml -p com...
下载axis-1_4,地址https://archive.apache.org/dist/ws/axis/1_4/
解压,进入D:\axis-1_4\lib
执行命令
java -cp mail.jar;saaj.jar;jaxrpc.jar;commons-discovery-0.2.jar;commons-logging-1.0.4.jar;axis.jar;activation.jar;wsdl4j-1.5.1.jar org.apache.axis.wsdl.WSDL2Java D:\TmriOutNewAccess.xml -p com.lxw.webservice
生成的文件
调用
public class test {
public static void main(String[] args) throws RemoteException {
TmriJaxRpcOutNewAccessService locator = new TmriJaxRpcOutNewAccessServiceLocator();
TmriOutNewAccessSoapBindingStub stub = (TmriOutNewAccessSoapBindingStub) locator.getTmriOutNewAccess();
String result = stub.queryObjectOut("", "", "", "", "", "", "", "", "");
System.out.println("result:" + result);
}
}
Intellij Idea 下 生成WebServiceClient (WS客户端)参考:https://www.cnblogs.com/felordcn/p/12142597.html
本文地址:https://blog.csdn.net/lw112190/article/details/110920699
上一篇: java算法--冒泡排序操作
下一篇: 自动化测试框架[Cypress框架拆解]