<?xml version="1.0" encoding="UTF-8"?>
<!--
  ~ Copyright (c) 2024 Robert Bosch Manufacturing Solutions GmbH
  ~
  ~ See the AUTHORS file(s) distributed with this work for additional
  ~ information regarding authorship.
  ~
  ~ This Source Code Form is subject to the terms of the Mozilla Public
  ~ License, v. 2.0. If a copy of the MPL was not distributed with this
  ~ file, You can obtain one at https://mozilla.org/MPL/2.0/.
  ~
  ~ SPDX-License-Identifier: MPL-2.0
  -->

<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>
      <groupId>com.boschsemanticstack</groupId>
      <artifactId>semanticstack-rql-parent</artifactId>
      <version>1.3.2</version>
      <relativePath>../pom.xml</relativePath>
   </parent>
   <artifactId>semanticstack-rql-parser</artifactId>
   <name>Bosch Semantic Stack RQL Parser</name>

   <dependencies>
      <dependency>
         <groupId>com.boschsemanticstack</groupId>
         <artifactId>semanticstack-rql-core</artifactId>
      </dependency>
      <dependency>
         <groupId>com.boschsemanticstack</groupId>
         <artifactId>semanticstack-rql-model</artifactId>
      </dependency>
      <dependency>
         <groupId>org.antlr</groupId>
         <artifactId>antlr4-runtime</artifactId>
      </dependency>

      <dependency>
         <groupId>org.antlr</groupId>
         <artifactId>antlr4</artifactId>
         <scope>test</scope>
      </dependency>
      <dependency>
         <groupId>org.junit.jupiter</groupId>
         <artifactId>junit-jupiter</artifactId>
         <scope>test</scope>
      </dependency>
      <dependency>
         <groupId>org.assertj</groupId>
         <artifactId>assertj-core</artifactId>
         <scope>test</scope>
      </dependency>
      <dependency>
         <groupId>io.reactivex.rxjava2</groupId>
         <artifactId>rxjava</artifactId>
         <scope>test</scope>
      </dependency>
   </dependencies>

   <build>
      <plugins>
         <plugin>
            <groupId>org.antlr</groupId>
            <artifactId>antlr4-maven-plugin</artifactId>
            <configuration>
               <sourceDirectory>src/main/antlr</sourceDirectory>
               <outputDirectory>src-gen/main/java/com/boschsemanticstack/rql/parser/v1/internal</outputDirectory>
               <visitor>true</visitor>
            </configuration>
            <executions>
               <execution>
                  <id>antlr</id>
                  <goals>
                     <goal>antlr4</goal>
                  </goals>
               </execution>
            </executions>
         </plugin>
         <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-clean-plugin</artifactId>
            <configuration>
               <filesets>
                  <fileset>
                     <directory>src-gen/main/java</directory>
                  </fileset>
               </filesets>
            </configuration>
         </plugin>
         <plugin>
            <groupId>org.codehaus.mojo</groupId>
            <artifactId>build-helper-maven-plugin</artifactId>
            <executions>
               <execution>
                  <goals>
                     <goal>add-source</goal>
                  </goals>
                  <phase>generate-sources</phase>
                  <configuration>
                     <sources>
                        <source>src-gen/main/java</source>
                     </sources>
                  </configuration>
               </execution>
            </executions>
         </plugin>
      </plugins>
   </build>
</project>
