java2wsdl (axis2) 用法
我正在尝试使用 java2wsdl 为 JiraSoapServiceImpl 生成文档文字 wsdl。然而,似乎无论我使用什么用法,我都会遇到 ClassNotFoundException。
java2wsdl -cp . -cn com.atlassian.jira.rpc.soap.JiraSoapServiceImpl
这些文件位于 bat 文件旁边。
Exception in thread "main" java.lang.ClassNotFoundException: com.atlassian.jira.rpc.soap.JiraSoapServiceImpl
at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:242)
at org.apache.axis2.description.java2wsdl.Java2WSDLUtils.namespaceFromClassName(Java2WSDLUtils.java:65)
at org.apache.axis2.description.java2wsdl.Java2WSDLUtils.schemaNamespaceFromClassName(Java2WSDLUtils.java:84)
at org.apache.ws.java2wsdl.Java2WSDLBuilder.getSchemaTargetNamespace(Java2WSDLBuilder.java:121)
at org.apache.ws.java2wsdl.Java2WSDLBuilder.generateWSDL(Java2WSDLBuilder.java:212)
at org.apache.ws.java2wsdl.Java2WSDLCodegenEngine.generate(Java2WSDLCodegenEngine.java:59)
at org.apache.ws.java2wsdl.Java2WSDL.main(Java2WSDL.java:32)
I'm trying to use java2wsdl
to generate a document literal wsdl for JiraSoapServiceImpl
. However it seems that no matter what usage I use, I got a ClassNotFoundException.
java2wsdl -cp . -cn com.atlassian.jira.rpc.soap.JiraSoapServiceImpl
The files are located next to the bat file.
Exception in thread "main" java.lang.ClassNotFoundException: com.atlassian.jira.rpc.soap.JiraSoapServiceImpl
at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:242)
at org.apache.axis2.description.java2wsdl.Java2WSDLUtils.namespaceFromClassName(Java2WSDLUtils.java:65)
at org.apache.axis2.description.java2wsdl.Java2WSDLUtils.schemaNamespaceFromClassName(Java2WSDLUtils.java:84)
at org.apache.ws.java2wsdl.Java2WSDLBuilder.getSchemaTargetNamespace(Java2WSDLBuilder.java:121)
at org.apache.ws.java2wsdl.Java2WSDLBuilder.generateWSDL(Java2WSDLBuilder.java:212)
at org.apache.ws.java2wsdl.Java2WSDLCodegenEngine.generate(Java2WSDLCodegenEngine.java:59)
at org.apache.ws.java2wsdl.Java2WSDL.main(Java2WSDL.java:32)
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
该类应位于 ./com/atlassian/jira/rpc/soap/JiraSoapServiceImpl.class 中。是吗,或者正如您所说,它是“bat 文件旁边”,即 ./JiraSoapServiceImpl.class?
而且——仅举一个例子——它应该是*.class,而不是*.java。
顺便说一句,JIRA 有公共 WSDL,为什么需要从 Impl 类生成一些东西?
This class should be in ./com/atlassian/jira/rpc/soap/JiraSoapServiceImpl.class. Is it, or as you said, it is "next to bat file", i.e. ./JiraSoapServiceImpl.class?
And -- just for a case -- it should be *.class, not *.java.
BTW, JIRA has public WSDL, why do you need to generate something from Impl class?