我試圖讓這個運行結合」。也許你的意思是「http://jaxb.dev.java.net/plugin/code-injector」?JAXB定製與接口
是否有一些新的方法讓生成的bean實現接口?
編輯:我也得在我的POM警告unrecognized parameter -Xinheritance
與CXF版本2.4.0
<plugin>
<groupId>org.apache.cxf</groupId>
<artifactId>cxf-xjc-plugin</artifactId>
<version>2.4.0</version>
<configuration>
<extensions>
<extension>org.apache.cxf.xjcplugins:cxf-xjc-boolean:2.4.0</extension>
<extension>org.apache.cxf.xjcplugins:cxf-xjc-bug671:2.4.0</extension>
<extension>org.apache.cxf.xjcplugins:cxf-xjc-dv:2.4.0</extension>
<extension>org.apache.cxf.xjcplugins:cxf-xjc-ts:2.4.0</extension>
<extension>org.apache.cxf.xjcplugins:cxf-xjc-pl:2.4.0</extension>
<extension>org.apache.cxf.xjcplugins:cxf-xjc-ts:2.4.0</extension>
<extension>org.apache.cxf.xjcplugins:cxf-xjc-wsdlextension:2.4.0</extension>
</extensions>
</configuration>
<executions>
<execution>
<id>generate-sources</id>
<phase>generate-sources</phase>
<goals>
<goal>xsdtojava</goal>
</goals>
<configuration>
<xsdOptions>
<xsdOption>
<extension>true</extension>
<xsd>some.xsd</xsd>
<packagename>somepackage</packagename>
<bindingFile>src\main\resources\bindings\bindings.xml</bindingFile>
<extensionArgs>
<arg>-Xdv</arg>
<arg>-Xinheritance</arg>
</extensionArgs>
</xsdOption>
</xsdOptions>
</configuration>
</execution>
<execution>
<configuration>
</configuration>
</execution>
</executions>
<dependencies>
<dependency>
<groupId>org.jvnet.jaxb2_commons</groupId>
<artifactId>jaxb2-basics-runtime</artifactId>
<version>0.6.3</version>
</dependency>
你要存檔什麼末尾添加呢?你想在你的jaxb類中實現哪些接口? – jddsantaella 2012-03-28 18:08:26
我有一些轉換爲java文件的xsd文件,其中一些Java文件應該實現一些現有bean的自定義定義接口。 – 2012-03-28 18:10:17
向我們展示您的pom部分,調用xjc – artbristol 2012-03-28 19:02:22