如何在pom.xml中为wsdl2java指定前端? [英] How to specify frontend for wsdl2java in a pom.xml?
本文介绍了如何在pom.xml中为wsdl2java指定前端?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我发现了关于向wsdl2java命令添加-fe jaxws21
以使其生成与jaxws 2.1兼容的代码的-fe jaxws21
的一个很好的提示 2.2,但是Maven的pom.xml
像这样放置时似乎不喜欢这种添加:
I found this great tip about adding -fe jaxws21
to the wsdl2java command to have it generate jaxws 2.1 compliant code instead of 2.2, but Maven's pom.xml
doesn't seem to like this addition when placed like this:
<goals>
<goal>wsdl2java -fe jaxws21</goal>
</goals>
为pom.xml中使用的wsdl2java指定前端的正确方法是什么?
What is the correct way of specifying a frontend for wsdl2java that's used in a pom.xml?
推荐答案
如果使用的是cxf-codegen-plugin,则可以在extraargs元素中添加参数:
If you are using cxf-codegen-plugin, you can add the arguments in extraargs element:
<executions>
<execution>
<configuration>
<wsdlOptions>
<wsdlOption>
<wsdl>...</wsdl>
<extraargs>
<extraarg>-fe</extraarg>
<extraarg>jaxws21</extraarg>
</extraargs>
</wsdlOption>
</wsdlOptions>
</configuration>
<goals>
<goal>wsdl2java</goal>
</goals>
</execution>
</executions>
来源: http://cxf.apache.org/docs /maven-cxf-codegen-plugin-wsdl-to-java.html
这篇关于如何在pom.xml中为wsdl2java指定前端?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文