开发者

CFX wadl2java problem generating java

开发者 https://www.devze.com 2023-04-05 13:55 出处:网络
Hi I\'m trying to generate the Java classes that are defined in the following WADL http://www.epo.org/searching/free/ops.html

Hi I'm trying to generate the Java classes that are defined in the following WADL

http://www.epo.org/searching/free/ops.html

I'm trying to do it by command line. I've download the WADL and the XSD and also the apache-cfx-2.4.2.

I've tried to run the following command:

wadl2java" -verbose ops.wadl

I'm getting this error:

org.apache.cxf.tools.common.ToolException: java.lang.NullPointerException
    at org.apache.cxf.tools.wadlto.jaxrs.JAXRSContainer.execute(JAXRSContainer.java:75)
    at org.apache.cxf.tools.common.toolspec.ToolRunner.runTool(ToolRunner.java:103)
    at org.apache.cxf.tools.wadlto.WADLToJava.run(WADLToJava.java:65)
    at org.apache.cxf.tools.wadlto.WADLToJava.run(WADLToJava.java:57)
    at org.apache.cxf.tools.wadlto.WADLToJava.main(WADLToJava.java:99)
Caused by: java.lang.NullPointerException
    at org.apache.cxf.jaxrs.ext.codegen.SourceGenerator.createC开发者_开发技巧odeModel(SourceGenerator.java:914)
    at org.apache.cxf.jaxrs.ext.codegen.SourceGenerator.generateSchemaCodeAndInfo(SourceGenerator.java:182)

Does anyone know how to generate Java Classes from WADL without using Maven (I haven't got the permission to use it)?


I ended up using the XSD's and generating the code from there. I used the JAXB xcj command.

0

精彩评论

暂无评论...
验证码 换一张
取 消