<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/maven-v4_0_0.xsd">
	<modelVersion>4.0.0</modelVersion>
	<parent>
		<groupId>net.sf.jasperreports</groupId>
		<artifactId>jasperreports-common</artifactId>
		<version>${revision}</version>
		<relativePath>./pom-common.xml</relativePath>
	</parent>
	<artifactId>jasperreports-javaflow</artifactId>
	<packaging>jar</packaging>
	<name>JasperReports Library Javaflow</name>
	<description>Free Java Reporting Library</description>
	<url>http://jasperreports.sourceforge.net</url>
	<scm>
		<connection>${scmConnection}</connection>
		<tag>${revision}</tag>
		<url>${scmUrl}</url>
	</scm>
	<dependencies>
		<dependency>
			<groupId>net.tascalate.javaflow</groupId>
			<artifactId>net.tascalate.javaflow.api</artifactId>
			<version>2.7.5</version>
			<scope>compile</scope>
			<optional>false</optional>
		</dependency>
	</dependencies>
	<build>
		<directory>target/javaflow</directory>
		<plugins>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-resources-plugin</artifactId>
				<version>${maven-resources-plugin.version}</version>
				<executions>
					<execution>
						<id>copy-classes-to-javaflow</id>
						<phase>process-classes</phase>
						<goals>
							<goal>copy-resources</goal>
						</goals>
						<configuration>
							<outputDirectory>${project.build.directory}/classes-javaflow</outputDirectory>
							<resources>
								<resource>
									<directory>${project.build.directory}/classes</directory>
									<includes>
										<include>net/sf/jasperreports/engine/fill/BaseReportFiller.class</include>
										<include>net/sf/jasperreports/engine/fill/JRBaseFiller.class</include>
										<include>net/sf/jasperreports/engine/fill/JRVerticalFiller.class</include>
										<include>net/sf/jasperreports/engine/fill/JRHorizontalFiller.class</include>
										<include>net/sf/jasperreports/engine/fill/JRFillSubreport.class</include>
										<include>net/sf/jasperreports/engine/fill/JRSubreportRunnable.class</include>
										<include>net/sf/jasperreports/engine/fill/JRContinuationSubreportRunner.class</include>
										<include>net/sf/jasperreports/engine/fill/FillerSubreportParent.class</include>
										<include>default.jasperreports.properties</include>
									</includes>
								</resource>
							</resources>
						</configuration>
					</execution>
					<execution>
						<id>copy-classes-from-javaflow</id>
						<phase>prepare-package</phase>
						<goals>
							<goal>copy-resources</goal>
						</goals>
						<configuration>
							<outputDirectory>${project.build.directory}/classes</outputDirectory>
							<resources>
								<resource>
									<directory>${project.build.directory}/classes-javaflow</directory>
								</resource>
							</resources>
						</configuration>
					</execution>
				</executions>
			</plugin>
			<plugin>
				<groupId>net.tascalate.javaflow</groupId>
				<artifactId>net.tascalate.javaflow.tools.maven</artifactId>
				<version>${net.tascalate.javaflow.tools.maven.version}</version>
				<executions>
					<execution>
						<id>javaflow-enhance-main-classes</id> 
						<phase>process-classes</phase>
						<goals>
							<goal>javaflow-enhance</goal>
						</goals>
						<configuration>
							<buildDir>${project.build.directory}/classes-javaflow</buildDir>
						</configuration>
					</execution>
				</executions>
			</plugin>
			<plugin>
				<groupId>com.google.code.maven-replacer-plugin</groupId>
				<artifactId>replacer</artifactId>
				<version>${maven-replacer-plugin.version}</version>
				<executions>
					<execution>
						<phase>process-classes</phase>
						<goals>
							<goal>replace</goal>
						</goals>
					</execution>
				</executions>
				<configuration>
					<file>${project.build.directory}/classes-javaflow/default.jasperreports.properties</file>
					<token>net.sf.jasperreports.subreport.runner.factory\=[\w\.]*</token>
					<value>net.sf.jasperreports.subreport.runner.factory=net.sf.jasperreports.engine.fill.JRContinuationSubreportRunnerFactory</value>
				</configuration>
			</plugin>
		</plugins>
	</build>
</project>
