wiki:GamePluginPom.xml

The pom.xml file in the Blank Plugin Structure download is:

<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">
    <parent>
        <groupId>edu.caltech.ssel</groupId>
        <artifactId>multistage-plugins</artifactId>
        <version>1.0</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <groupId></groupId>
    <artifactId></artifactId>
    <name></name>
    <packaging>jar</packaging>

    <properties>
        <serverControllerClassname></serverControllerClassname>
        <clientGUIClassname></clientGUIClassname>
    </properties>
   
    <developers>
        <developer>
            <id></id>
            <name></name>
            <email></email>
            <url></url>
            <organization></organization>
            <organizationUrl></organizationUrl>
            <roles>
                <role></role>
            </roles>
            <timezone></timezone>
        </developer>
    </developers>
    
   <build>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-surefire-plugin</artifactId>
                <configuration>
                    <skip>true</skip>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
                <version>2.0.2</version>
                <configuration>
                    <source>1.5</source>
                    <target>1.5</target>
                </configuration>
            </plugin>
            <plugin>
                <artifactId>maven-assembly-plugin</artifactId>
                <version>2.2-beta-2</version>
                <configuration>
                    <descriptor>src/main/assembly/plugin-assembly.xml</descriptor>
                </configuration>
                <executions>
                    <execution>
                        <id>make-assembly</id>
                        <phase>package</phase> <!-- append to the packaging phase -->
                        <goals>
                            <goal>single</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>
    <dependencies>
        <dependency>
            <groupId>log4j</groupId>
            <artifactId>log4j</artifactId>
            <version>1.2.15</version>
            <exclusions>
                <exclusion>
                    <artifactId>mail</artifactId>
                    <groupId>javax.mail</groupId>
                </exclusion>
                <exclusion>
                    <artifactId>jms</artifactId>
                    <groupId>javax.jms</groupId>
                </exclusion>
                <exclusion>
                    <artifactId>jmxri</artifactId>
                    <groupId>com.sun.jmx</groupId>
                </exclusion>
                <exclusion>
                    <artifactId>jmxtools</artifactId>
                    <groupId>com.sun.jdmk</groupId>
                </exclusion>
            </exclusions>
        </dependency>
    </dependencies>
</project>

There are five elements which must be filled in for the game plugin to be able to be built:

  1. The project groupId element is the id of the organization responsible for writing the game plugin. Here at SSEL we use the value edu.caltech.ssel
  2. The project artifactId element is a unique id used by maven to identify the game plugin. It should be different from any other existing project.
  3. The project name element is the string used in the Multistage parameters file to tell the Multistage platform which type of game plugin to execute for a given match in an experimental session. It can be any string of characters.
  4. The properties serverControllerClassname element is the classpath of the class in your game plugin implementation which extends the multistage ServerControl class
  5. The properties clientGUIClassname element is the classpath of the class in your game plugin implementation which extends the multistage ClientGUI class

It is not strictly required to fill in the developers element.

More information about maven POM files is available at the Official Apache Maven site.

Last modified 4 years ago Last modified on Oct 21, 2013 3:05:01 PM