<?xml version="1.0" encoding="UTF-8"?>
<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements.  See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You 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/maven-v4_0_0.xsd">
  <modelVersion>4.0.0</modelVersion>

 <parent>
   <groupId>org.apache.commons</groupId>
   <artifactId>commons-parent</artifactId>
   <version>28</version>
 </parent>

  <groupId>org.apache.commons</groupId>
  <artifactId>commons-ognl</artifactId>
  <version>4.0-SNAPSHOT</version>
  <packaging>jar</packaging>

  <name>Apache Commons OGNL - Object Graph Navigation Library</name>
  <description>The Apache Commons OGNL library is a Java development framework for Object-Graph Navigation Language,
  plus other extras such as list projection and selection and lambda expressions.</description>
  <url>http://commons.apache.org/proper/commons-ognl/</url>
  <inceptionYear>1997</inceptionYear>
  <organization>
    <name>The Apache Software Foundation</name>
    <url>http://www.apache.org/</url>
  </organization>
  <licenses>
    <license>
      <name>The Apache License, Version 2.0</name>
      <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
      <distribution>repo</distribution>
    </license>
  </licenses>

  <developers>
    <developer>
      <name>Antonio Petrelli</name>
      <id>apetrelli</id>
      <email>apetrelli@apache.org</email>
      <roles>
        <role>Committer</role>
        <role>Emeritus</role>
      </roles>
    </developer>
    <developer>
      <name>Christian Grobmeier</name>
      <id>grobmeier</id>
      <email>grobmeier@apache.org</email>
      <roles>
        <role>PMC Member</role>
        <role>Committer</role>
      </roles>
    </developer>
    <developer>
      <name>Jesse Kuhnert</name>
      <id>jkuhnert</id>
      <email>jkuhnert@apache.org</email>
      <roles>
        <role>Committer</role>
      </roles>
    </developer>
    <developer>
      <name>Jochen Wiedmann</name>
      <id>jochen</id>
      <email>jochen@apache.org</email>
      <roles>
        <role>PMC Member</role>
        <role>Committer</role>
      </roles>
    </developer>
    <developer>
      <name>Lukasz Lenart</name>
      <id>lukaszlenart</id>
      <email>lukaszlenart@apache.org</email>
      <roles>
        <role>Committer</role>
      </roles>
    </developer>
    <developer>
      <name>Olivier Lamy</name>
      <id>olamy</id>
      <email>olamy@apache.org</email>
      <roles>
        <role>Committer</role>
      </roles>
    </developer>
    <developer>
      <name>Luke Blanshard</name>
      <id>leadpipe</id>
      <email>leadpipe@apache.org</email>
      <roles>
        <role>Committer</role>
      </roles>
    </developer>
    <developer>
      <name>Marc Andrew Davidson</name>
      <id>javadrewd</id>
      <email>javadrewd@apache.org</email>
      <roles>
        <role>Committer</role>
      </roles>
    </developer>
    <developer>
      <name>Maurizio Cucchiara</name>
      <id>mcucchiara</id>
      <email>mcucchiara@apache.org</email>
      <roles>
        <role>Committer</role>
      </roles>
    </developer>
    <developer>
      <name>Simone Tripodi</name>
      <id>simonetripodi</id>
      <email>simonetripodi@apache.org</email>
      <roles>
        <role>PMC Member</role>
        <role>Committer</role>
      </roles>
    </developer>
    <developer>
      <name>Upayavira</name>
      <id>upayavira</id>
      <email>upayavira@apache.org</email>
      <roles>
        <role>Committer</role>
      </roles>
    </developer>
  </developers>

  <contributors>
    <contributor>
      <name>Daniel Pitts</name>
    </contributor>
    <contributor>
      <name>Adrian Cumiskey</name>
      <email>acumiskey@apache.org</email>
    </contributor>
  </contributors>

  <scm>
    <connection>scm:svn:http://svn.apache.org/repos/asf/commons/proper/ognl/trunk/</connection>
    <developerConnection>scm:svn:https://svn.apache.org/repos/asf/commons/proper/ognl/trunk/</developerConnection>
    <url>http://svn.apache.org/viewvc/commons/proper/ognl/trunk/</url>
  </scm>
  <issueManagement>
    <system>jira</system>
    <url>https://issues.apache.org/jira/browse/OGNL</url>
  </issueManagement>
  <ciManagement>
    <system>Jenkins</system>
    <url>https://builds.apache.org/job/ognl/</url>
  </ciManagement>
  <distributionManagement>
    <site>
      <id>website</id>
      <url>scp://people.apache.org/www/commons.apache.org/ognl/</url>
    </site>
  </distributionManagement>

  <properties>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    <commons.javadoc.version>2.9</commons.javadoc.version>
    <maven.compile.source>1.5</maven.compile.source>
    <maven.compile.target>1.5</maven.compile.target>
    <commons.componentid>ognl</commons.componentid>
    <commons.module.name>org.apache.commons.ognl</commons.module.name>

    <commons.scmPubCheckoutDirectory>site-content</commons.scmPubCheckoutDirectory>
  </properties>

  <dependencies>
    <dependency>
      <groupId>junit</groupId>
      <artifactId>junit</artifactId>
      <version>4.10</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.easymock</groupId>
      <artifactId>easymock</artifactId>
      <version>2.3</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.javassist</groupId>
      <artifactId>javassist</artifactId>
      <version>3.16.1-GA</version>
    </dependency>
    <dependency>
      <groupId>com.carrotsearch</groupId>
      <artifactId>junit-benchmarks</artifactId>
      <classifier>jdk15</classifier>
      <version>0.3.0</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>ognl</groupId>
      <artifactId>ognl</artifactId>
      <version>3.0.2</version>
      <scope>test</scope>
    </dependency>
  </dependencies>

  <build>
    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-compiler-plugin</artifactId>
        <version>2.3.2</version>
        <configuration>
          <source>${maven.compile.source}</source>
          <target>${maven.compile.target}</target>
        </configuration>
        <executions>
          <execution>
            <id>compile-tests</id>
            <phase>process-test-sources</phase>
            <goals>
              <goal>testCompile</goal>
            </goals>
            <configuration>
              <source>${maven.compile.source}</source>
              <target>${maven.compile.target}</target>
            </configuration>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <artifactId>maven-surefire-plugin</artifactId>
        <configuration>
          <excludes>
            <exclude>**/*$*</exclude>
          </excludes>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-jar-plugin</artifactId>
        <version>2.3.1</version>
        <configuration>
          <archive>
            <compress>true</compress>
            <index>true</index>
          </archive>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-clean-plugin</artifactId>
        <version>2.4.1</version>
      </plugin>
      <plugin>
        <artifactId>maven-assembly-plugin</artifactId>
        <configuration>
          <descriptors>
            <descriptor>${basedir}/src/main/assembly/bin.xml</descriptor>
            <descriptor>${basedir}/src/main/assembly/src.xml</descriptor>
          </descriptors>
          <tarLongFileMode>gnu</tarLongFileMode>
          <attach>false</attach>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>javacc-maven-plugin</artifactId>
        <version>2.6</version>
        <executions>
        <execution>
          <id>ognl-jjtree</id>
          <configuration>
            <outputDirectory>${project.build.directory}/generated-sources/java</outputDirectory>
            <timestampDirectory>${project.build.directory}/generated-sources/javacc-timestamp</timestampDirectory>
            <package>org.apache.commons.ognl</package>
            <!-- Uncomment if AST files needs to be generated
            <nodePackage>*.jtree</nodePackage>
            -->
            <!-- Uncomment if visitor default implementation needs to be generated <visitor>true</visitor> -->
          </configuration>
          <goals>
            <!-- change goal to jtree-javacc to generate AST too -->
            <goal>javacc</goal>
          </goals>
        </execution>
        </executions>
      </plugin>
    </plugins>
    <pluginManagement>
      <plugins>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-idea-plugin</artifactId>
          <version>2.2</version>
        </plugin>

        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-surefire-plugin</artifactId>
          <version>2.13</version>
        </plugin>
      </plugins>
    </pluginManagement>
  </build>

  <profiles>
    <profile>
      <id>reporting</id>
      <activation>
        <property>
          <name>skipReports</name>
          <value>!true</value>
        </property>
      </activation>

      <reporting>
        <plugins>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-changes-plugin</artifactId>
            <version>2.8</version>
            <configuration>
              <xmlPath>${basedir}/src/changes/changes.xml</xmlPath>
              <issueLinkTemplate>%URL%/%ISSUE%</issueLinkTemplate>
            </configuration>
            <reportSets>
              <reportSet>
                <reports>
                   <report>changes-report</report>
                </reports>
              </reportSet>
            </reportSets>
          </plugin>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-checkstyle-plugin</artifactId>
            <version>2.7</version>
            <configuration>
              <configLocation>config/maven_checks.xml</configLocation>
              <headerLocation>config/maven-header.txt</headerLocation>
            </configuration>
          </plugin>
          <!-- Requires setting 'export MAVEN_OPTS="-Xmx512m" ' -->
          <plugin>
            <groupId>org.codehaus.mojo</groupId>
            <artifactId>findbugs-maven-plugin</artifactId>
            <version>2.3.1</version>
            <configuration>
              <threshold>Normal</threshold>
              <effort>Default</effort>
              <excludeFilterFile>findbugs-exclude-filter.xml</excludeFilterFile>
           </configuration>
          </plugin>
          <plugin>
            <groupId>org.codehaus.mojo</groupId>
            <artifactId>cobertura-maven-plugin</artifactId>
            <version>2.4</version>
          </plugin>
          <plugin>
            <artifactId>maven-pmd-plugin</artifactId>
            <version>2.3</version>
            <configuration>
              <targetJdk>${maven.compile.target}</targetJdk>
            </configuration>
            <reportSets>
              <reportSet>
                <reports>
                  <report>pmd</report>
                  <report>cpd</report>
                </reports>
              </reportSet>
            </reportSets>
          </plugin>
          <plugin>
            <groupId>org.codehaus.mojo</groupId>
            <artifactId>taglist-maven-plugin</artifactId>
            <version>2.4</version>
            <configuration>
              <tags>
                <tag>TODO</tag>
                <tag>NOPMD</tag>
                <tag>NOTE</tag>
                <tag>FIXME</tag>
              </tags>
            </configuration>
          </plugin>
          <plugin>
            <groupId>org.codehaus.mojo</groupId>
            <artifactId>javancss-maven-plugin</artifactId>
            <version>2.0</version>
          </plugin>
          <plugin>
            <groupId>org.codehaus.sonar-plugins</groupId>
            <artifactId>maven-report</artifactId>
            <version>0.1</version>
            <configuration>
              <sonarHostURL>https://analysis.apache.org/</sonarHostURL>
            </configuration>
          </plugin>
          <plugin>
            <groupId>org.apache.rat</groupId>
            <artifactId>apache-rat-plugin</artifactId>
            <configuration>
              <useDefaultExcludes>true</useDefaultExcludes>
              <includes>
                <include>src/**/*</include>
              </includes>
            </configuration>
          </plugin>
          <plugin>
            <groupId>org.codehaus.mojo</groupId>
            <artifactId>clirr-maven-plugin</artifactId>
          </plugin>
        </plugins>
      </reporting>
    </profile>

    <profile>
      <id>benchmarks</id>
      <activation>
        <property>
          <name>runBenchmarks</name>
          <value>true</value>
        </property>
      </activation>

      <dependencies>
        <dependency>
          <groupId>org.slf4j</groupId>
          <artifactId>slf4j-api</artifactId>
          <version>1.6.1</version>
          <scope>test</scope>
        </dependency>
        <dependency>
          <groupId>com.h2database</groupId>
          <artifactId>h2</artifactId>
          <version>1.3.158</version>
          <scope>test</scope>
        </dependency>
        <dependency>
          <groupId>com.carrotsearch</groupId>
          <artifactId>junit-benchmarks</artifactId>
          <classifier>jdk15</classifier>
          <version>0.3.0</version>
          <scope>test</scope>
        </dependency>
      </dependencies>

      <build>
        <testResources>
          <testResource>
            <directory>${basedir}/src/benchmarks/resources</directory>
          </testResource>
        </testResources>

        <plugins>
          <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>${basedir}/src/benchmarks/java</source>
                  </sources>
                </configuration>
              </execution>
            </executions>
          </plugin>

          <plugin>
            <artifactId>maven-surefire-plugin</artifactId>
            <configuration>
              <systemPropertyVariables>
                <jub.consumers>CONSOLE,XML,H2</jub.consumers>
                <jub.db.file>${project.build.directory}/benchmarks/database</jub.db.file>
                <jub.xml.file>${project.build.directory}/benchmarks.xml</jub.xml.file>
                <jub.charts.dir>${project.build.directory}/site</jub.charts.dir>
              </systemPropertyVariables>
              <argLine>-Xmx512m -Xms512m</argLine>
            </configuration>
          </plugin>
        </plugins>
      </build>
    </profile>
    <profile>
      <id>setup-checkout</id>
      <activation>
        <file>
          <missing>site-content</missing>
        </file>
      </activation>
      <build>
        <plugins>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-antrun-plugin</artifactId>
            <version>1.7</version>
            <executions>
              <execution>
                <id>prepare-checkout</id>
                <phase>pre-site</phase>
                <goals>
                  <goal>run</goal>
                </goals>
                <configuration>
                  <tasks>
                    <exec executable="svn">
                      <arg line="checkout ${commons.scmPubUrl} ${commons.scmPubCheckoutDirectory}" />
                    </exec>
                    <!-- in case of paths to ignore (added manually) -->
                    <!--
                    <exec executable="svn">
                      <arg line="update - -set-depth exclude ${commons.scmPubCheckoutDirectory}/javadocs" />
                    </exec>

                    <pathconvert pathsep=" " property="dirs">
                      <dirset dir="${commons.scmPubCheckoutDirectory}" includes="*" />
                    </pathconvert>
                    <exec executable="svn">
                      <arg line="update - -set-depth infinity ${dirs}" />
                    </exec>
                    -->
                    <exec executable="svn">
                      <arg line="update" />
                    </exec>
                  </tasks>
                </configuration>
              </execution>
            </executions>
          </plugin>
        </plugins>
      </build>
    </profile>
  </profiles>
</project>
