<?xml version="1.0"?>
<!--
  ~ Copyright (c) 2010-2018 Evolveum
  ~
  ~ Licensed under the Apache License, Version 2.0 (the "License");
  ~ you may not use this file except in compliance with the License.
  ~ You may obtain a copy of the License at
  ~
  ~     http://www.apache.org/licenses/LICENSE-2.0
  ~
  ~ Unless required by applicable law or agreed to in writing, software
  ~ distributed under the License is distributed on an "AS IS" BASIS,
  ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  ~ See the License for the specific language governing permissions and
  ~ limitations under the License.
  -->

<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>com.evolveum.midpoint.infra</groupId>
    <artifactId>prism-api</artifactId>
    <name>midPoint Infrastructure - prism-api</name>
    <parent>
        <artifactId>infra</artifactId>
        <groupId>com.evolveum.midpoint</groupId>
        <version>4.0-M2</version>
    </parent>
    <scm>
        <connection>https://github.com/Evolveum/midpoint.git</connection>
        <developerConnection>git@github.com:Evolveum/midpoint.git</developerConnection>
        <url>https://fisheye.evolveum.com/browse/midPoint</url>
    </scm>
    <dependencies>
        <dependency>
            <groupId>com.evolveum.midpoint.infra</groupId>
            <artifactId>util</artifactId>
            <version>4.0-M2</version>
        </dependency>
        <!--<dependency>-->
            <!--<groupId>com.sun.xml.bind</groupId>-->
            <!--<artifactId>jaxb-xjc</artifactId>-->
        <!--</dependency>-->
        <!--<dependency>-->
            <!--<groupId>org.apache.cxf</groupId>-->
            <!--<artifactId>cxf-rt-wsdl</artifactId>-->
        <!--</dependency>-->
        <dependency>
            <groupId>commons-lang</groupId>
            <artifactId>commons-lang</artifactId>
        </dependency>
		<!--<dependency>-->
			<!--<groupId>org.apache.commons</groupId>-->
			<!--<artifactId>commons-lang3</artifactId>-->
		<!--</dependency>-->
		<dependency>
			<groupId>org.apache.commons</groupId>
			<artifactId>commons-collections4</artifactId>
		</dependency>
		<dependency>
			<groupId>org.apache.santuario</groupId>
			<artifactId>xmlsec</artifactId>
		</dependency>
        <dependency>
            <groupId>org.jetbrains</groupId>
            <artifactId>annotations-java5</artifactId>
        </dependency>
		<!--<dependency>-->
		  <!--<groupId>com.fasterxml.jackson.core</groupId>-->
		  <!--<artifactId>jackson-core</artifactId>-->
		<!--</dependency>-->
		<!--<dependency>-->
		  <!--<groupId>com.fasterxml.jackson.core</groupId>-->
		  <!--<artifactId>jackson-annotations</artifactId>-->
		<!--</dependency>-->
		<!--<dependency>-->
			<!--<groupId>org.yaml</groupId>-->
			<!--<artifactId>snakeyaml</artifactId>-->
		<!--</dependency>-->
		<dependency>
		  <groupId>org.springframework</groupId>
		  <artifactId>spring-core</artifactId>
		</dependency>
		<!--<dependency>-->
		  <!--<groupId>org.springframework</groupId>-->
		  <!--<artifactId>spring-beans</artifactId>-->
		<!--</dependency>-->
		<!--<dependency>-->
		  <!--<groupId>xml-resolver</groupId>-->
		  <!--<artifactId>xml-resolver</artifactId>-->
		<!--</dependency>-->
		<dependency>
		  <groupId>commons-codec</groupId>
		  <artifactId>commons-codec</artifactId>
		</dependency>
		<dependency>
		  <groupId>commons-io</groupId>
		  <artifactId>commons-io</artifactId>
		</dependency>
		<!--<dependency>-->
		  <!--<groupId>com.sun.xml.bind</groupId>-->
		  <!--<artifactId>jaxb-impl</artifactId>-->
		<!--</dependency>-->
		<dependency>
		  <groupId>org.jvnet.jaxb2_commons</groupId>
		  <artifactId>jaxb2-basics-runtime</artifactId>
		</dependency>
		<!--<dependency>-->
			<!--&lt;!&ndash; make this dependency explicit to detect conflicts with older versions &ndash;&gt;-->
		  <!--<groupId>org.codehaus.woodstox</groupId>-->
		  <!--<artifactId>stax2-api</artifactId>-->
		<!--</dependency>-->
		<!--<dependency>-->
			<!--<groupId>org.codehaus.staxmate</groupId>-->
			<!--<artifactId>staxmate</artifactId>-->
		<!--</dependency>-->

		<!--<dependency>-->
		  <!--<groupId>com.fasterxml.jackson.core</groupId>-->
		  <!--<artifactId>jackson-databind</artifactId>-->
		<!--</dependency>-->

        <!-- TEST -->
        <dependency>
            <groupId>org.testng</groupId>
            <artifactId>testng</artifactId>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>com.evolveum.midpoint.tools</groupId>
            <artifactId>test-ng</artifactId>
            <version>4.0-M2</version>
            <scope>test</scope>
        </dependency>
    </dependencies>
    <build>
        <plugins>
        	<!-- Code generator may be used in Prism in the "pure" form without any prism-specific plugins.
        	 This creates the classes for basic (almost-primitive) data types such as PolyStringType. 
        	 But ... the JAXB-generated classes are not that useful. They may reflect the schema well, but
        	 there are glitches. E.g. the JAXB classes generated for query namespace are completely useless.
        	 The default JAXB-generated class for PolyStringType is also useless. Therefore the classes that
        	 were generated from the schema are copied to the "main" source tree in the form that suits us
        	 better than just blindly following the schema. Therefore the following plugin is commented out.
        	 It may be used in case that the schemas change and we need to re-generate and re-tweak them.
        	 But the plugin should be disabled during normal build. -->
            <!-- <plugin>
                <groupId>org.jvnet.jaxb2.maven2</groupId>
                <artifactId>maven-jaxb2-plugin</artifactId>
                <version>0.8.0</version>
                <executions>
                    <execution>
                        <goals>
                            <goal>generate</goal>
                        </goals>
                        <configuration>
                            <verbose>true</verbose>
                            <catalog>src/main/resources/META-INF/catalog.xml</catalog>
                            <extension>true</extension>
                            <schemaDirectory>src/main/resources/xml/ns/public</schemaDirectory>
                            <generateDirectory>${project.build.directory}/generated-sources/xjc</generateDirectory>
                        </configuration>
                    </execution>
                </executions>
            </plugin>  -->
        	<!-- 
        	 Following plugin generates the JAXB classes for prism tests.
        	 We can't really test full JAXB capabilities here as we get the proper JAXB plugin code
        	 only after Prism is compiled.
        	 This plugin is not really needed during normal build.
             The classes that we need are hard-copied into the prism test source tree.
             Disabling this plugin speeds up the compilation. -->
             <!-- 
            <plugin>
                <groupId>org.jvnet.jaxb2.maven2</groupId>
                <artifactId>maven-jaxb2-plugin</artifactId>
                <version>0.8.0</version>
                <executions>
                    <execution>
                        <goals>
                            <goal>generate</goal>
                        </goals>
                        <configuration>
                            <verbose>true</verbose>
                            <catalog>src/main/resources/META-INF/catalog.xml</catalog>
                            <extension>true</extension>
                            <schemaDirectory>src/main/resources/xml/ns/test</schemaDirectory>
                            <generateDirectory>${project.build.directory}/generated-sources/xjc</generateDirectory>
                        </configuration>
                    </execution>
                </executions>
            </plugin>  -->
        </plugins>
    </build>
</project>
