我正在尝试将包名称映射到名称空间
根据文档:https://github.com/highsource/maven-jaxb2-plugin/wiki/Configure-Target-Packages-in-Binding-Files
<jaxb:bindings xmlns:tns="http://www.myexample.com/my-service/request" scd="x-schema::tns">
<jaxb:schemaBindings >
<jaxb:package name="com.request" />
</jaxb:schemaBindings>
</jaxb:bindings>
它似乎被忽略了。
查看完整示例:https://github.com/deslauriersp/jaxb-bindings-not-working
答案 0 :(得分:0)
问题出在XJC itsetf
使用-wsdl选项时,绑定不起作用(这是实验性的,正式不支持)
我的解决方案是包括所有XSD,但不包括WSDL本身