为cxf生成的类添加前缀
我使用 CXF 从 wsdl 生成 Java 类。是否可以为所有生成的类名称分配前缀?
I use CXF to generate Java classes form wsdl. Is it possible to assign a prefix to all generated classes names?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
wsdl2java
工具有一个-b 选项:
您提供的绑定文件需要具有以下内容:
这会将
Foo
前缀添加到为类型、匿名类型和元素生成的类中。请注意,schemaLocation
属性必须指向实际架构。The
wsdl2java
tool has an-b
option:The binding file you provide needs to have the following contents:
This adds
Foo
prefix to classes generated for types, anonymous types and elements. Note that theschemaLocation
attribute must point to the actual schema.