<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>devtools</artifactId>
        <groupId>info.mikaelsvensson.devtools</groupId>
        <version>1.2.1</version>
    </parent>
    <artifactId>doclet</artifactId>
    <version>1.2.1</version>
    <packaging>jar</packaging>
    <name>doclet</name>
    <url>http://devtools.mikaelsvensson.info/doclet</url>

    <properties>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <projectVersion>${project.version}</projectVersion>
    </properties>

    <build>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-antrun-plugin</artifactId>
                <version>1.7</version>
                <executions>
                    <execution>
                        <id>generate-xmldoclet-samples</id>
                        <goals>
                            <goal>run</goal>
                        </goals>
                        <phase>pre-site</phase>
                        <configuration>
                            <target>
                                <ant antfile="${project.basedir}/xmldoclet-samples-antproject.xml" target="create" />
                            </target>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-javadoc-plugin</artifactId>
                <version>2.9.1</version>
                <executions>
                    <execution>
                        <id>generate-site-content-from-javadoc</id>
                        <goals>
                            <goal>javadoc</goal>
                        </goals>
                        <phase>pre-site</phase>
                        <configuration>
                            <sourcepath>${project.build.sourceDirectory}</sourcepath>
                            <docfilessubdirs>true</docfilessubdirs>
                            <doclet>info.mikaelsvensson.devtools.doclet.xml.XmlDoclet</doclet>
                            <docletArtifacts>
                                <docletArtifact>
                                    <groupId>info.mikaelsvensson.devtools</groupId>
                                    <artifactId>doclet</artifactId>
                                    <version>1.0-SNAPSHOT</version>
                                </docletArtifact>
                                <docletArtifact>
                                    <groupId>net.sf.saxon</groupId>
                                    <artifactId>Saxon-HE</artifactId>
                                    <version>9.4</version>
                                </docletArtifact>
                            </docletArtifacts>
                            <show>private</show>
                            <destDir>../</destDir>
                            <additionalparam>
                                -format.name extensive
                                -format.property.wrapListElements true
                                -format.property.showAnnotations true
                                -output ${project.build.sourceDirectory}/../../site/xdoc/index.xml
                                -transformer ${project.build.sourceDirectory}/../../site/index.xslt
                                -untransformedoutput ./source-code-documentation.xml
                            </additionalparam>
                            <useStandardDocletOptions>false</useStandardDocletOptions>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
                <version>2.5.1</version>
                <configuration>
                    <source>1.6</source>
                    <target>1.6</target>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>build-helper-maven-plugin</artifactId>
                <version>1.7</version>
                <executions>
                    <execution>
                        <id>add-test-source</id>
                        <phase>generate-test-sources</phase>
                        <goals>
                            <goal>add-test-source</goal>
                        </goals>
                        <configuration>
                            <sources>
                                <source>${project.build.testSourceDirectory}/../resources</source>
                            </sources>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>

    <reporting>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-project-info-reports-plugin</artifactId>
                <version>2.7</version>
                <configuration>
                    <dependencyDetailsEnabled>false</dependencyDetailsEnabled>
                    <dependencyLocationsEnabled>false</dependencyLocationsEnabled>
                </configuration>
                <reportSets>
                    <reportSet>
                        <reports>
                            <report>index</report>
                            <!--<report>plugins</report>-->
                        </reports>
                    </reportSet>
                </reportSets>
            </plugin>
        </plugins>
    </reporting>

    <dependencies>
        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>4.9</version>
        </dependency>
        <dependency>
            <groupId>com.sun</groupId>
            <artifactId>tools</artifactId>
            <version>1.5.0</version>
            <scope>system</scope>
            <systemPath>${java.home}/../lib/tools.jar</systemPath>
        </dependency>
        <dependency>
            <!-- TODO: MISV 20120612 Used to find JPA annotations in entity classes (and this information is used when generating UML diagrams). -->
            <groupId>org.apache.openejb</groupId>
            <artifactId>javaee-api</artifactId>
            <version>5.0-2</version>
        </dependency>
        <dependency>
            <groupId>xmlunit</groupId>
            <artifactId>xmlunit</artifactId>
            <version>1.3</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>com.google.code.javaparser</groupId>
            <artifactId>javaparser</artifactId>
            <version>1.0.8</version>
        </dependency>
    </dependencies>
</project>
