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>dev.metaschema.java</groupId>
<artifactId>metaschema-maven-plugin</artifactId>
<version>2.0.1</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>