Metaschema Maven Plugin

This Maven build plugin automates the generation of Java classes for a set of Metaschema definitions as part of a Maven build.

The following is an example of a Maven configuration for this plugin.

<project xmlns="http://maven.apache.org/POM/4.0.0"
	xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
	xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
	<modelVersion>4.0.0</modelVersion>

	<groupId>my.group</groupId>
	<artifactId>my-library</artifactId>
	<version>0.0.1-SNAPSHOT</version>
	<packaging>jar</packaging>

	<name>An example project</name>

	<build>
		<plugins>
			<plugin>
				<groupId>gov.nist.secauto.metaschema</groupId>
				<artifactId>metaschema-maven-plugin</artifactId>
				<version>1.0.0-M1</version>
				<executions>
					<execution>
						<id>generate-model-sources</id>
						<goals>
							<goal>generate-sources</goal>
						</goals>
						<configuration>
							<!-- defines where to find the Metaschemas to generate Java classes from -->
							<metaschemaDir>${project.build.directory}/src/main/metaschema</metaschemaDir>
							<!-- defines which metaschema in the above directory to use -->
							<includes>
								<include>*_metaschema.xml</include>
							</includes>
						</configuration>
					</execution>
				</executions>
			</plugin>
		</plugins>
	</build>
</project>