<?xml version="1.0" encoding="UTF-8"?>
<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 https://maven.apache.org/xsd/maven-4.0.0.xsd">
    <modelVersion>4.0.0</modelVersion>
    <parent>
        <groupId>net.hasor</groupId>
        <artifactId>hasor-parent</artifactId>
        <version>4.2.2</version>
        <relativePath>../../pom.xml</relativePath>
    </parent>

    <!-- Maven Info -->
    <artifactId>hasor-dataql-fx</artifactId>
    <packaging>jar</packaging>

    <!-- Project Info -->
    <name>Hasor-DataQL/FunctionX</name>
    <description>the hasor DataQL project.</description>

    <developers>
        <developer>
            <name>赵永春(Mr.Zhao)</name>
            <email>zyc@hasor.net</email>
        </developer>
    </developers>


    <properties>
        <antlr4.visitor>true</antlr4.visitor>
    </properties>

    <build>
        <plugins>
            <!-- 把 javassist、ognl 的源码和 class 集成到 hasor-dataql-fx 项目 中 -->
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-shade-plugin</artifactId>
                <version>3.2.1</version>
                <executions>
                    <execution>
                        <phase>package</phase>
                        <goals>
                            <goal>shade</goal>
                        </goals>
                        <configuration>
                            <createSourcesJar>true</createSourcesJar>
                            <createDependencyReducedPom>false</createDependencyReducedPom>
                            <minimizeJar>true</minimizeJar>
                            <artifactSet>
                                <includes>
                                    <include>ognl:ognl</include>
                                    <include>org.javassist:javassist</include>
                                    <include>com.github.jsqlparser:jsqlparser</include>
                                    <include>net.hasor:hasor-dataql-fx</include>
                                </includes>
                            </artifactSet>
                            <relocations>
                                <relocation>
                                    <pattern>ognl</pattern>
                                    <shadedPattern>net.hasor.dataql.fx.db.ognl</shadedPattern>
                                </relocation>
                                <relocation>
                                    <pattern>javassist</pattern>
                                    <shadedPattern>net.hasor.dataql.fx.db.javassist</shadedPattern>
                                </relocation>
                                <relocation>
                                    <pattern>net.sf.jsqlparser</pattern>
                                    <shadedPattern>net.hasor.dataql.fx.db.jsqlparser</shadedPattern>
                                </relocation>
                            </relocations>
                            <filters>
                                <filter>
                                    <artifact>*:*</artifact>
                                    <excludes>
                                        <exclude>META-INF/MANIFEST.MF</exclude>
                                    </excludes>
                                </filter>
                            </filters>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>

    <!-- 引用依赖 -->
    <dependencies>
        <!-- basic -->
        <dependency>
            <groupId>net.hasor</groupId>
            <artifactId>hasor-dataql</artifactId>
        </dependency>
        <dependency>
            <groupId>com.alibaba</groupId>
            <artifactId>fastjson</artifactId>
        </dependency>

        <!-- database -->
        <dependency>
            <groupId>net.hasor</groupId>
            <artifactId>hasor-db</artifactId>
        </dependency>
        <dependency>
            <groupId>ognl</groupId>
            <artifactId>ognl</artifactId>
            <version>3.2.14</version>
            <scope>compile</scope>
            <optional>true</optional>
        </dependency>
        <dependency>
            <groupId>com.github.jsqlparser</groupId>
            <artifactId>jsqlparser</artifactId>
            <version>3.1</version>
            <scope>compile</scope>
            <optional>true</optional>
        </dependency>

        <!-- web -->
        <dependency>
            <groupId>net.hasor</groupId>
            <artifactId>hasor-web</artifactId>
        </dependency>
        <dependency>
            <groupId>javax.servlet</groupId>
            <artifactId>javax.servlet-api</artifactId>
            <scope>provided</scope>
        </dependency>

        <!-- python -->
        <!-- <dependency>-->
        <!--   <groupId>org.python</groupId>-->
        <!--   <artifactId>jython</artifactId>-->
        <!--   <version>2.7.2</version>-->
        <!--   <scope>provided</scope>-->
        <!-- </dependency>-->
    </dependencies>
</project>