问题描述
- CXF工程 RuntimeModelBuilder报错
-
1、我的JDK版本是1.7
2、我的CXF是在官网下载的,我把全部的jar包都加进去了
3、代码package demo.hw.server; import javax.jws.WebParam; import javax.jws.WebService; @WebService public interface HelloWorld { String sayHi(@WebParam(name="text") String text); }
package demo.hw.server; import javax.jws.WebParam; import javax.jws.WebService; @WebService(serviceName="HelloWorld") public class HelloWorldImpl implements HelloWorld { public String sayHi(@WebParam(name="text") String text) { System.out.println("sayHi called"); return "Hello " + text; } }
package demo.hw.server; import javax.xml.ws.Endpoint; public class Server { public Server() throws Exception { System.out.println("server start"); HelloWorld helloWorld = new HelloWorldImpl(); String address = "http://localhost:9000/HelloWorld"; Endpoint.publish(address, helloWorld); } public static void main(String args[]) throws Exception { new Server(); System.out.println("Server ready..."); Thread.sleep(5 * 60 * 1000); System.out.println("Server exiting"); System.exit(0); } }
就这三个文件,然后报错。。我都崩溃了,网上说的那些方法不管用啊
报错截图
解决方案
。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。
时间: 2024-12-22 14:35:55