<?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>
        <groupId>com.rackspace.papi.components</groupId>
        <artifactId>filters-support</artifactId>
        <version>5.0.5</version>
    </parent>

    <groupId>com.rackspace.papi.components</groupId>
    <artifactId>client-auth</artifactId>

    <name>Repose Components - Client Authentication</name>
    <description>TODO</description>

    <packaging>jar</packaging>

    <properties>
        <sonar.jacoco.itReportPath>${project.basedir}/../../../target/jacoco-it.exec</sonar.jacoco.itReportPath>
    </properties>

    <dependencies>
        <!-- This dependency will pull in an implementation of necessary javaee-api
             classes used during testing -->
        <dependency>
            <groupId>javax.mail</groupId>
            <artifactId>mail</artifactId>
            <scope>test</scope>
        </dependency>

        <dependency>
            <groupId>com.rackspace.cloud.services.clients</groupId>
            <artifactId>auth</artifactId>
        </dependency>

        <dependency>
            <groupId>net.sf.ehcache</groupId>
            <artifactId>ehcache-core</artifactId>
            <scope>test</scope>
        </dependency>

        <dependency>
            <groupId>com.rackspace.papi.core</groupId>
            <artifactId>core-lib</artifactId>
        </dependency>

        <dependency>
            <groupId>com.rackspace.papi.commons</groupId>
            <artifactId>configuration</artifactId>
        </dependency>

        <dependency>
            <groupId>com.rackspace.papi.commons</groupId>
            <artifactId>utilities</artifactId>
        </dependency>

        <dependency>
            <groupId>org.jvnet.jaxb2_commons</groupId>
            <artifactId>jaxb2-basics-runtime</artifactId>
            <version>0.6.3</version>
        </dependency>


    </dependencies>

    <build>
        <plugins>

            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>xml-maven-plugin</artifactId>

                <configuration>
                    <transformationSets>
                        <transformationSet>
                            <dir>src/main/resources/META-INF/schema/config</dir>
                            <stylesheet>../xsl/remove-1.1-elements.xsl</stylesheet>
                            <outputDir>
                                ${project.build.directory}/generated-resources/xml/xslt/config
                            </outputDir>
                        </transformationSet>
                        <transformationSet>
                            <dir>src/main/resources/META-INF/schema/http-basic</dir>
                            <stylesheet>../xsl/remove-1.1-elements.xsl</stylesheet>
                            <outputDir>
                                ${project.build.directory}/generated-resources/xml/xslt/http-basic
                            </outputDir>
                        </transformationSet>
                        <transformationSet>
                            <dir>src/main/resources/META-INF/schema/openstack-ids-auth</dir>
                            <stylesheet>../xsl/remove-1.1-elements.xsl</stylesheet>
                            <outputDir>
                                ${project.build.directory}/generated-resources/xml/xslt/openstack-ids-auth
                            </outputDir>
                        </transformationSet>
                        <transformationSet>
                            <dir>src/main/resources/META-INF/schema/rackspace-auth-v1.1</dir>
                            <stylesheet>../xsl/remove-1.1-elements.xsl</stylesheet>
                            <outputDir>
                                ${project.build.directory}/generated-resources/xml/xslt/rackspace-auth-v1.1
                            </outputDir>
                        </transformationSet>
                    </transformationSets>
                </configuration>
            </plugin>

            <plugin>
                <groupId>org.jvnet.jaxb2.maven2</groupId>
                <artifactId>maven-jaxb2-plugin</artifactId>

                <configuration>

                    <specVersion>2.2</specVersion>
                    <schemaDirectory>${project.build.directory}/generated-resources/xml/xslt</schemaDirectory>

                    <schemaIncludes>
                        <include>**/*.xsd</include>
                    </schemaIncludes>
                    <bindingIncludes>
                        <include>**/*.xjb</include>
                    </bindingIncludes>
                    <strict>true</strict>
                    <verbose>false</verbose>

                    <args>
                        <arg>-XtoString</arg>
                        <arg>
                            -XtoString-toStringStrategyClass=com.rackspace.papi.commons.util.string.PasswordSensitiveToStringStrategy
                        </arg>
                    </args>
                </configuration>
            </plugin>
        </plugins>
    </build>
</project>
