<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>


	<!--
		=======================================================================
		PROJECT INFORMATION
		=======================================================================
	-->

	<parent>
		<groupId>com.googlecode.japis</groupId>
		<artifactId>japis</artifactId>
		<version>1.0</version>
	</parent>

	<groupId>com.googlecode.japis</groupId>
	<artifactId>japis-java</artifactId>
	<packaging>pom</packaging>
	<version>1.0</version>

	<name>JAPIS Java</name>
	<description>
		Root for JAPIS development projects using Java. Configurations for
		development plugins and reports.
	</description>
	<url>${japis.url}</url>


	<!--
		=======================================================================
		PROPERTIES
		=======================================================================
	-->

	<properties>
		<japis.google.scm>java.japis</japis.google.scm>
		<japis.compiler.source>1.6</japis.compiler.source>
		<japis.compiler.target>1.6</japis.compiler.target>
		<japis.javadoc.version>2.7</japis.javadoc.version>
		<japis.jxr.version>2.2</japis.jxr.version>
	</properties>


	<!--
		=======================================================================
		ENVIRONMENT
		=======================================================================
	-->

	<distributionManagement>
		<site>
			<id>google-site</id>
			<name>Google Code SCM</name>
			<url>${japis.site.deploy}</url>
		</site>
	</distributionManagement>

	<scm>
		<connection>${japis.scm.connection}</connection>
		<developerConnection>${japis.scm.connection}</developerConnection>
		<url>${japis.scm.url}</url>
	</scm>


	<!--
		=======================================================================
		BUILD
		=======================================================================
	-->

	<build>
		<extensions>
			<!-- Shared configuration files -->
			<extension>
				<groupId>com.googlecode.japis</groupId>
				<artifactId>japis-java-config</artifactId>
				<version>1.0</version>
			</extension>
		</extensions>
		<plugins>
			<!-- Global Javadoc configuration and JAR publishing -->
			<plugin>
				<artifactId>maven-javadoc-plugin</artifactId>
				<version>${japis.javadoc.version}</version>
				<configuration>
					<breakiterator>true</breakiterator>
					<footer>${project.version}</footer>
					<header>${project.version}</header>
					<locale>en</locale>
					<quiet>true</quiet>
					<serialwarn>true</serialwarn>
				</configuration>
				<executions>
					<execution>
						<id>attach-javadocs</id>
						<goals>
							<goal>jar</goal>
						</goals>
					</execution>
				</executions>
			</plugin>
			<!-- Cross reference source code -->
			<!--
				This is a report, but since it must run before other reports we
				generate it explicitly here.
			-->
			<plugin>
				<artifactId>maven-jxr-plugin</artifactId>
				<version>${japis.jxr.version}</version>
				<executions>
					<execution>
						<id>jxr-pre-site</id>
						<goals>
							<goal>jxr</goal>
							<goal>test-jxr</goal>
						</goals>
						<phase>pre-site</phase>
					</execution>
				</executions>
			</plugin>
			<!-- Source publishing -->
			<plugin>
				<artifactId>maven-source-plugin</artifactId>
				<version>2.1.2</version>
				<executions>
					<execution>
						<id>attach-sources</id>
						<goals>
							<goal>jar-no-fork</goal>
						</goals>
					</execution>
				</executions>
			</plugin>
		</plugins>
		<pluginManagement>
			<plugins>
				<!-- Distributable packages assembly -->
				<plugin>
					<artifactId>maven-assembly-plugin</artifactId>
					<version>2.2-beta-5</version>
					<configuration>
						<descriptorSourceDirectory>assembly</descriptorSourceDirectory>
					</configuration>
					<executions>
						<execution>
							<id>config-assembly</id>
							<phase>package</phase>
							<goals>
								<goal>single</goal>
							</goals>
						</execution>
					</executions>
				</plugin>
				<!-- Java compiling -->
				<plugin>
					<artifactId>maven-compiler-plugin</artifactId>
					<version>2.2</version>
					<configuration>
						<source>${japis.compiler.source}</source>
						<target>${japis.compiler.target}</target>
					</configuration>
				</plugin>
				<!-- EAR assembly -->
				<plugin>
					<artifactId>maven-ear-plugin</artifactId>
					<version>2.4.2</version>
					<configuration>
						<archive>
							<index>true</index>
							<manifest>
								<addDefaultImplementationEntries>
									true
								</addDefaultImplementationEntries>
								<addDefaultSpecificationEntries>
									true
								</addDefaultSpecificationEntries>
							</manifest>
						</archive>
						<version>6</version>
					</configuration>
				</plugin>
				<!-- EJB asssembly -->
				<plugin>
					<artifactId>maven-ejb-plugin</artifactId>
					<version>2.2.1</version>
					<configuration>
						<archive>
							<index>true</index>
							<manifest>
								<addClasspath>true</addClasspath>
								<addDefaultImplementationEntries>
									true
								</addDefaultImplementationEntries>
								<addDefaultSpecificationEntries>
									true
								</addDefaultSpecificationEntries>
							</manifest>
						</archive>
						<ejbVersion>3.0</ejbVersion>
					</configuration>
				</plugin>
				<!-- JAR assembly -->
				<plugin>
					<artifactId>maven-jar-plugin</artifactId>
					<version>2.3.1</version>
					<configuration>
						<archive>
							<index>true</index>
							<manifest>
								<addClasspath>true</addClasspath>
								<addDefaultImplementationEntries>
									true
								</addDefaultImplementationEntries>
								<addDefaultSpecificationEntries>
									true
								</addDefaultSpecificationEntries>
							</manifest>
						</archive>
					</configuration>
				</plugin>
				<!-- Testing -->
				<plugin>
					<artifactId>maven-surefire-plugin</artifactId>
					<version>2.5</version>
					<configuration>
						<includes>
							<include>**/*Test.java</include>
						</includes>
					</configuration>
				</plugin>
				<!-- WAR assembly -->
				<plugin>
					<artifactId>maven-war-plugin</artifactId>
					<version>2.1-beta-1</version>
					<configuration>
						<archive>
							<index>true</index>
							<manifest>
								<addClasspath>true</addClasspath>
								<addDefaultImplementationEntries>
									true
								</addDefaultImplementationEntries>
								<addDefaultSpecificationEntries>
									true
								</addDefaultSpecificationEntries>
							</manifest>
						</archive>
					</configuration>
				</plugin>
			</plugins>
		</pluginManagement>
	</build>


	<!--
		=======================================================================
		REPORTING
		=======================================================================
	-->

	<reporting>
		<plugins>
			<!-- Coding style problems -->
			<plugin>
				<artifactId>maven-checkstyle-plugin</artifactId>
				<version>2.5</version>
				<configuration>
					<configLocation>japis/java/config/checkstyle.xml</configLocation>
					<failOnViolation>false</failOnViolation>
					<headerLocation>japis/java/config/java-header.txt</headerLocation>
					<includeTestSourceDirectory>true</includeTestSourceDirectory>
				</configuration>
			</plugin>
			<!-- On-line Javadoc -->
			<plugin>
				<artifactId>maven-javadoc-plugin</artifactId>
				<version>${japis.javadoc.version}</version>
				<configuration>
					<breakiterator>true</breakiterator>
					<footer>${project.version}</footer>
					<header>${project.version}</header>
					<locale>en</locale>
					<quiet>true</quiet>
					<serialwarn>true</serialwarn>
				</configuration>
				<reportSets>
					<reportSet>
						<id>javadoc</id>
						<reports>
							<report>javadoc</report>
						</reports>
					</reportSet>
					<reportSet>
						<id>test-javadoc</id>
						<reports>
							<report>test-javadoc</report>
						</reports>
					</reportSet>
				</reportSets>
			</plugin>
			<!-- Cross-references, generated in pre-site by plugin above -->
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-jxr-plugin</artifactId>
				<version>${japis.jxr.version}</version>
			</plugin>
			<!-- Codification problems -->
			<plugin>
				<artifactId>maven-pmd-plugin</artifactId>
				<version>2.5</version>
				<configuration>
					<ignoreIdentifiers>true</ignoreIdentifiers>
					<ignoreLiterals>true</ignoreLiterals>
					<includeTests>true</includeTests>
				</configuration>
				<reportSets>
					<reportSet>
						<id>cpd</id>
						<reports>
							<report>cpd</report>
						</reports>
					</reportSet>
				</reportSets>
			</plugin>
			<!-- Unit tests reports -->
			<plugin>
				<artifactId>maven-surefire-report-plugin</artifactId>
				<version>2.5</version>
				<reportSets>
					<reportSet>
						<id>surefire</id>
						<reports>
							<report>report-only</report>
						</reports>
					</reportSet>
				</reportSets>
			</plugin>
			<!-- Binary compatibility -->
			<plugin>
				<groupId>org.codehaus.mojo</groupId>
				<artifactId>clirr-maven-plugin</artifactId>
				<version>2.2.2</version>
			</plugin>
			<!-- Test coverage -->
			<plugin>
				<groupId>org.codehaus.mojo</groupId>
				<artifactId>cobertura-maven-plugin</artifactId>
				<version>2.4</version>
				<configuration>
					<encoding>${project.build.sourceEncoding}</encoding>
					<formats>
						<format>xml</format>
						<format>html</format>
					</formats>
					<quiet>true</quiet>
				</configuration>
			</plugin>
			<!-- Codification problems -->
			<plugin>
				<groupId>org.codehaus.mojo</groupId>
				<artifactId>findbugs-maven-plugin</artifactId>
				<version>2.3.1</version>
				<configuration>
					<effort>Max</effort>
					<includeTests>true</includeTests>
					<threshold>Low</threshold>
				</configuration>
			</plugin>
			<!-- Line counting metrics -->
			<plugin>
				<groupId>org.codehaus.mojo</groupId>
				<artifactId>javancss-maven-plugin</artifactId>
				<version>2.0</version>
			</plugin>
			<!-- Design quality metrics -->
			<plugin>
				<groupId>org.codehaus.mojo</groupId>
				<artifactId>jdepend-maven-plugin</artifactId>
				<version>2.0-beta-2</version>
			</plugin>
			<!-- Source code tags -->
			<plugin>
				<groupId>org.codehaus.mojo</groupId>
				<artifactId>taglist-maven-plugin</artifactId>
				<version>2.4</version>
				<configuration>
					<tagListOptions>
						<tagClasses>
							<tagClass>
								<displayName>Implementation Note</displayName>
								<tags>
									<tag>
										<matchString>WORKAROUND</matchString>
										<matchType>ignoreCase</matchType>
									</tag>
								</tags>
							</tagClass>
							<tagClass>
								<displayName>Work Needed</displayName>
								<tags>
									<tag>
										<matchString>FIXME</matchString>
										<matchType>ignoreCase</matchType>
									</tag>
									<tag>
										<matchString>TODO</matchString>
										<matchType>exact</matchType>
									</tag>
								</tags>
							</tagClass>
						</tagClasses>
					</tagListOptions>
				</configuration>
			</plugin>
		</plugins>
	</reporting>

</project>
