<?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 http://maven.apache.org/maven-v4_0_0.xsd">
    <modelVersion>4.0.0</modelVersion>
    <parent>
        <relativePath>../topology-map/poms/compiled/</relativePath>
        <groupId>org.opennms.features.topology.build</groupId>
        <artifactId>compiled-bundle-settings</artifactId>
        <version>19.0.0-SNAPSHOT</version>
    </parent>
    <groupId>org.opennms.features</groupId>
    <artifactId>vaadin-surveillance-views</artifactId>
    <packaging>bundle</packaging>
    <name>OpenNMS :: Features :: Surveillance Views</name>
    <description>
        OpenNMS Vaadin Surveillance Views
    </description>
    <properties>
        <bundle.symbolicName>org.opennms.features.vaadin.surveillanceviews</bundle.symbolicName>
        <bundle.namespace>org.opennms.features.vaadin.surveillanceviews</bundle.namespace>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <guava.version>${guavaVersion}</guava.version>
    </properties>

    <build>
        <resources>
            <resource>
                <directory>src/main/resources</directory>
            </resource>
            <resource>
                <directory>src/main/java</directory>
                <includes>
                    <include>org/opennms/features/vaadin/surveillanceviews/internal/gwt/public/**</include>
                </includes>
            </resource>
        </resources>
        <plugins>

            <plugin>
                <!--
                 | the following instructions build a simple set of public/private classes into an OSGi bundle
                -->
                <groupId>org.apache.felix</groupId>
                <artifactId>maven-bundle-plugin</artifactId>
                <configuration>
                    <instructions>
                        <Bundle-SymbolicName>${bundle.symbolicName}</Bundle-SymbolicName>
                        <Bundle-Version>${project.version}</Bundle-Version>
                        <Export-Package>${bundle.namespace}.*;version="${project.version}"</Export-Package>
                    </instructions>
                </configuration>
            </plugin>

            <plugin>
                <groupId>com.vaadin</groupId>
                <artifactId>vaadin-maven-plugin</artifactId>
                <version>${vaadin.plugin.version}</version>
                <configuration>
                    <extraJvmArgs>-XX:MaxMetaspaceSize=256m -Xmx1g -Xss1024k</extraJvmArgs>
                    <webappDirectory>${basedir}/target/gwt/VAADIN/widgetsets</webappDirectory>
                    <hostedWebapp>${basedir}/target/gwt/VAADIN/widgetsets</hostedWebapp>
                    <noServer>true</noServer>
                    <draftCompile>false</draftCompile>
                    <compileReport>false</compileReport>
                    <style>OBF</style>
                    <strict>true</strict>
                    <runTarget>http://localhost:8980/opennms/vaadin-surveillance-views</runTarget>
                    <gwtSdkFirstInClasspath>true</gwtSdkFirstInClasspath>
                </configuration>
                <executions>
                    <execution>
                        <configuration>
                            <!-- if you don't specify any modules, the plugin will find them -->
                            <!-- <modules> <module>com.vaadin.demo.mobilemail.gwt.ColorPickerWidgetSet</module>
                                </modules> -->
                        </configuration>
                        <goals>
                            <goal>resources</goal>
                            <goal>update-widgetset</goal>
                            <goal>compile</goal>
                        </goals>
                    </execution>
                </executions>
                <dependencies>
                    <dependency>
                        <groupId>com.google.gwt</groupId>
                        <artifactId>gwt-dev</artifactId>
                        <version>${gwtVersion}</version>
                    </dependency>
                    <dependency>
                        <groupId>com.google.gwt</groupId>
                        <artifactId>gwt-user</artifactId>
                        <version>${gwtVersion}</version>
                    </dependency>
                </dependencies>
            </plugin>

            <plugin>
                <groupId>org.opennms.maven.plugins</groupId>
                <artifactId>features-maven-plugin</artifactId>
                <configuration>
                    <bundles>
                        <bundle>mvn:org.opennms.features/vaadin-surveillance-views/${project.version}</bundle>
                    </bundles>
                    <features>
                        <feature>opennms-core</feature>
                        <feature>vaadin</feature>
                    </features>
                </configuration>
            </plugin>
        </plugins>

    </build>
    <dependencies>
        <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>slf4j-api</artifactId>
            <scope>provided</scope>
        </dependency>

        <!-- OSGi Dependencies -->

        <dependency>
            <groupId>org.osgi</groupId>
            <artifactId>org.osgi.core</artifactId>
            <scope>provided</scope>
        </dependency>

        <dependency>
            <groupId>org.osgi</groupId>
            <artifactId>org.osgi.compendium</artifactId>
            <scope>provided</scope>
        </dependency>

        <dependency>
            <groupId>org.opennms.features.vaadin-components</groupId>
            <artifactId>graph</artifactId>
            <version>${project.version}</version>
        </dependency>

        <!-- Vaadin Dependencies -->

        <dependency>
            <groupId>org.opennms.features</groupId>
            <artifactId>vaadin</artifactId>
            <type>pom</type>
        </dependency>
        <dependency>
            <groupId>org.opennms.features.vaadin-components</groupId>
            <artifactId>core</artifactId>
            <version>${project.version}</version>
        </dependency>

        <dependency>
            <groupId>org.opennms</groupId>
            <artifactId>opennms-web-api</artifactId>
            <scope>provided</scope>
        </dependency>

        <dependency>
            <groupId>org.opennms.core</groupId>
            <artifactId>org.opennms.core.criteria</artifactId>
            <scope>provided</scope>
        </dependency>

        <dependency>
            <groupId>org.opennms</groupId>
            <artifactId>opennms-dao</artifactId>
            <scope>provided</scope>
        </dependency>

        <dependency>
            <groupId>org.opennms</groupId>
            <artifactId>opennms-config</artifactId>
            <scope>provided</scope>
        </dependency>

        <dependency>
            <groupId>org.opennms.features.topology</groupId>
            <artifactId>org.opennms.features.topology.api</artifactId>
            <version>${project.version}</version>
            <scope>provided</scope>
        </dependency>

    </dependencies>

</project>
