<?xml version="1.0" encoding="UTF-8"?>
<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>

    <parent>
        <artifactId>urnadministration</artifactId>
        <groupId>de.dnb.resolvingdienste</groupId>
        <version>4.1.7-SNAPSHOT</version>
    </parent>

    <artifactId>urnadministration-api</artifactId>

    <name>URN-Administration API</name>

    <dependencies>

        <!-- Container APIs

             The API only requires JAX-RS and Bean Validation. To simplify using the
             API in applications which do not run on a Java EE container, we depend
             specifically on the JAX-RS and Bean Validation APIs instead of the full
             Java EE API.
        -->

        <dependency>
            <groupId>javax.ws.rs</groupId>
            <artifactId>javax.ws.rs-api</artifactId>
            <scope>provided</scope>
        </dependency>

        <dependency>
            <groupId>javax.json.bind</groupId>
            <artifactId>javax.json.bind-api</artifactId>
            <scope>provided</scope>
        </dependency>

        <dependency>
            <groupId>javax.validation</groupId>
            <artifactId>validation-api</artifactId>
            <scope>provided</scope>
        </dependency>
        
        <!-- Annotations for REST-API documentation -->

        <dependency>
            <!-- While the Enunciate annotations are declared with retention runtime
                 they are not used during runtime. As described in JLS 13.5.7, the
                 JVM should ignore unknown annotations at runtime unless they are
                 explicitly referenced. Therefore, Enunciate annotations need to be
                 available only at compile time.

                 See https://github.com/stoicflame/enunciate/issues/680 and
                 https://stackoverflow.com/a/3568041/8362098 for details.
            -->
            <groupId>com.webcohesion.enunciate</groupId>
            <artifactId>enunciate-core-annotations</artifactId>
            <scope>provided</scope>
        </dependency>

        <!-- Test dependencies -->

        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <scope>test</scope>
        </dependency>

        <dependency>
            <groupId>org.assertj</groupId>
            <artifactId>assertj-core</artifactId>
            <scope>test</scope>
        </dependency>

        <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>slf4j-simple</artifactId>
            <scope>test</scope>
        </dependency>
    </dependencies>

    <build>
        <plugins>
            <plugin>
                <groupId>com.webcohesion.enunciate</groupId>
                <artifactId>enunciate-maven-plugin</artifactId>
                <executions>
                    <execution>
                        <id>create-api-docs</id>
                        <goals>
                            <goal>docs</goal>
                        </goals>
                        <configuration>
                            <docsDir>${project.build.outputDirectory}/META-INF/resources</docsDir>
                            <docsSubdir>/</docsSubdir>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>

</project>
