1

3 つの異なる XML スキーマがあります。これら 3 つの XSD に対応するクラスと ORM テーブルを生成したいと考えています。ビルドにはMavenを使用しています。

私が使用しているMaven Pom構成は次のとおりです。

<plugin>
    <groupId>org.jvnet.hyperjaxb3</groupId>
    <artifactId>maven-hyperjaxb3-plugin</artifactId>
    <version>0.5.6</version>
    <executions>
        <execution>
            <goals>
                <goal>generate</goal>
            </goals>
        </execution>
    </executions>
    <configuration>
        <args>
            <arg>-Xannotate</arg>
            <arg>-enableIntrospection</arg>
        </args>
        <schemaDirectory>src/main/resources</schemaDirectory>
        <bindingDirectory>src/main/resources</bindingDirectory>
        <persistenceXml>src/main/resources/event.xml</persistenceXml>
        <generateDirectory>${project.build.directory}/generated-sources/xjc</generateDirectory>
        <schemaIncludes>
            <include>EventML.xsd</include>
        </schemaIncludes>
        <specVersion>2.2</specVersion>
        <extension>true</extension>
        <variant>jpa2</variant>
        <persistenceUnitName>event</persistenceUnitName>
    </configuration>
</plugin>

さらに 2 つの XSD を含めたいと考えています。どうやってやるの?

4

1 に答える 1

2

You can just change these lines:

<schemaIncludes>
    <include>EventML.xsd</include>
</schemaIncludes>

To this:

<schemaIncludes>
    <include>EventML.xsd</include>
    <include>Other1.xsd</include>
    <include>Other2.xsd</include>
</schemaIncludes>
于 2015-10-14T21:10:14.140 に答える