<?xml version="1.0" encoding="UTF-8"?>
<!--
/**
 * Copyright (c) Codice Foundation
 *
 * This is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation, either
 * version 3 of the License, or any later version.
 *
 * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
 * See the GNU Lesser General Public License for more details. A copy of the GNU Lesser General Public License is distributed along with this program and can be found at
 * <http://www.gnu.org/licenses/lgpl.html>.
 *
 **/
-->
<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 http://maven.apache.org/xsd/maven-4.0.0.xsd">
    <modelVersion>4.0.0</modelVersion>

    <groupId>ddf.jaxb</groupId>
    <artifactId>ddf-jaxb-reactor</artifactId>
    <version>1.0.2</version>
    <name>DDF :: JAXB</name>

    <packaging>pom</packaging>

    <scm>
        <url>https://github.com/codice/ddf-jaxb</url>
        <connection>scm:git:https://github.com/codice/ddf-jaxb.git</connection>
        <developerConnection>scm:git:https://github.com/codice/ddf-jaxb.git</developerConnection>
        <tag>HEAD</tag>
    </scm>

    <properties>
        <ddf.support.version>2.3.16</ddf.support.version>
        <maven-checkstyle-plugin.version>3.0.0</maven-checkstyle-plugin.version>
        <maven-jaxb2-plugin.version>0.14.0</maven-jaxb2-plugin.version>
        <maven-compiler-plugin.version>3.8.0</maven-compiler-plugin.version>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <gml-v_3_1_1-schema.version>1.1.0</gml-v_3_1_1-schema.version>
        <ows-v_1_0_0-schema.version>1.1.0</ows-v_1_0_0-schema.version>
        <ogc-filter-v_1_1_0-schema.thirdparty.version>1.1.0_5</ogc-filter-v_1_1_0-schema.thirdparty.version>
        <maven-source-plugin.version>3.0.1</maven-source-plugin.version>

        <!-- Neither of the below modules use semantic versioning correctly -->
        <!-- Even though it's only a minor version bump <jaxb>2.3.0</jaxb> is a breaking change -->
        <!-- and cannot be updated until our schemas use a newer version of JAXB2 -->
        <!-- <jvnet.jaxb2>0.11.0</jvnet.jaxb2> also uses 2.3.0 -->
        <jaxb.version>2.2.11</jaxb.version>
        <jvnet.jaxb2.version>0.10.0</jvnet.jaxb2.version>

        <jaxb.visitor.version>1.13</jaxb.visitor.version>
        <jaxb2.annotate.version>1.1.0</jaxb2.annotate.version>

        <!-- gitflow-incremental-builder -->
        <!-- See https://github.com/vackosar/gitflow-incremental-builder for a list of all the options -->
        <gib.referenceBranch>refs/remotes/origin/master</gib.referenceBranch>
        <gib.baseBranch>HEAD</gib.baseBranch>
        <gib.enabled>false</gib.enabled>
        <gib.failOnError>false</gib.failOnError>
        <gitflow.version>3.4</gitflow.version>
    </properties>

    <distributionManagement>
        <repository>
            <id>releases</id>
            <url>https://repo.codice.org/repository/maven-releases/</url>
        </repository>
        <snapshotRepository>
            <id>snapshots</id>
            <url>https://repo.codice.org/repository/maven-snapshots/</url>
        </snapshotRepository>
    </distributionManagement>

    <licenses>
        <license>
            <name>GNU Lesser General Public v3</name>
            <url>http://www.gnu.org/licenses/lgpl.html</url>
            <distribution>repo</distribution>
        </license>
    </licenses>

    <organization>
        <name>Codice Foundation</name>
        <url>https://codice.org</url>
    </organization>

    <build>
        <extensions>
            <extension>
                <groupId>com.vackosar.gitflowincrementalbuilder</groupId>
                <artifactId>gitflow-incremental-builder</artifactId>
                <version>${gitflow.version}</version>
            </extension>
        </extensions>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
                <version>${maven-compiler-plugin.version}</version>
                <configuration>
                    <forceJavacCompilerUse>true</forceJavacCompilerUse>
                    <source>8</source>
                    <target>8</target>
                    <maxmem>512M</maxmem>
                    <fork>${compiler.fork}</fork>
                    <encoding>${project.build.sourceEncoding}</encoding>
                </configuration>
            </plugin>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-checkstyle-plugin</artifactId>
                <version>${maven-checkstyle-plugin.version}</version>
                <dependencies>
                    <dependency>
                        <groupId>ddf.support</groupId>
                        <artifactId>support-checkstyle</artifactId>
                        <version>${ddf.support.version}</version>
                        <optional>true</optional>
                    </dependency>
                </dependencies>
                <executions>
                    <execution>
                        <id>checkstyle-check-xml</id>
                        <phase>validate</phase>
                        <goals>
                            <goal>check</goal>
                        </goals>
                        <configuration>
                            <!-- This configures the plugin for mvn install -->
                            <configLocation>checkstyle-enforced-xml.xml</configLocation>
                            <headerLocation>lpgl-header-check-xml.txt</headerLocation>
                            <sourceDirectories>${basedir}</sourceDirectories>
                            <includes>src/**/*.xml, pom.xml</includes>
                            <consoleOutput>true</consoleOutput>
                            <failsOnError>true</failsOnError>
                            <linkXRef>false</linkXRef>
                            <aggregate>true</aggregate>
                        </configuration>
                    </execution>
                </executions>
                <configuration>
                    <!-- This configures the plugin for mvn checkstyle:checkstyle  -->
                    <configLocation>checkstyle-enforced.xml</configLocation>
                    <headerLocation>lpgl-header-check.txt</headerLocation>
                    <consoleOutput>true</consoleOutput>
                    <failsOnError>true</failsOnError>
                    <linkXRef>false</linkXRef>
                    <aggregate>true</aggregate>
                    <includeTestSourceDirectory>true</includeTestSourceDirectory>
                </configuration>
            </plugin>
        </plugins>
        <pluginManagement>
            <plugins>
                <plugin>
                    <groupId>org.jvnet.jaxb2.maven2</groupId>
                    <artifactId>maven-jaxb2-plugin</artifactId>
                    <version>${maven-jaxb2-plugin.version}</version>
                    <configuration>
                        <plugins combine.children="append">
                            <plugin>
                                <groupId>org.jvnet.jaxb2_commons</groupId>
                                <artifactId>jaxb2-basics</artifactId>
                                <version>${jvnet.jaxb2.version}</version>
                            </plugin>
                        </plugins>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-source-plugin</artifactId>
                    <version>${maven-source-plugin.version}</version>
                </plugin>
            </plugins>
        </pluginManagement>
    </build>

    <repositories>
        <repository>
            <id>central</id>
            <name>Central Repository</name>
            <url>https://repo.maven.apache.org/maven2</url>
            <layout>default</layout>
            <snapshots>
                <enabled>false</enabled>
            </snapshots>
        </repository>
        <repository>
            <id>codice</id>
            <name>Codice Repository</name>
            <url>https://repo.codice.org/repository/maven-public/</url>
        </repository>
    </repositories>
    <pluginRepositories>
        <pluginRepository>
            <id>central</id>
            <name>Central Repository</name>
            <url>https://repo.maven.apache.org/maven2</url>
            <layout>default</layout>
            <snapshots>
                <enabled>false</enabled>
            </snapshots>
        </pluginRepository>
        <pluginRepository>
            <id>codice</id>
            <name>Codice Repository</name>
            <url>https://repo.codice.org/repository/maven-public/</url>
        </pluginRepository>
    </pluginRepositories>

    <modules>
        <module>platform-parser-test-domain</module>
        <module>security-cas-tokenvalidator</module>
        <module>catalog-transformer-xml-binding</module>
        <module>spatial-csw-schema-bindings</module>
        <module>registry-schema-bindings</module>
        <module>spatial-wfs-v1_0_0-schema-bindings</module>
        <module>spatial-wfs-v2_0_0-schema-bindings</module>
        <module>security-pdp-authzrealm</module>
    </modules>
</project>