org.springframework.roo.project
Class Plugin

java.lang.Object
  extended by org.springframework.roo.project.Plugin
All Implemented Interfaces:
Comparable<Plugin>

public class Plugin
extends Object
implements Comparable<Plugin>

Simplified immutable representation of a maven build plugin.

Structured after the model used by Maven.

Since:
1.1
Author:
Alan Stewart

Constructor Summary
Plugin(Element plugin)
          Convenience constructor when an XML element is available that represents a Maven .
Plugin(org.springframework.roo.model.JavaPackage groupId, org.springframework.roo.model.JavaSymbolName artifactId, String version)
          Creates an immutable Plugin.
Plugin(String groupId, String artifactId, String version)
          Convenience constructor.
Plugin(String groupId, String artifactId, String version, Configuration configuration, List<Dependency> dependencies, List<Execution> executions)
          Convenience constructor.
 
Method Summary
 int compareTo(Plugin o)
           
 boolean equals(Object obj)
           
 org.springframework.roo.model.JavaSymbolName getArtifactId()
           
 Configuration getConfiguration()
           
 List<Dependency> getDependencies()
           
 List<Execution> getExecutions()
           
 org.springframework.roo.model.JavaPackage getGroupId()
           
 String getVersion()
           
 int hashCode()
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Plugin

public Plugin(org.springframework.roo.model.JavaPackage groupId,
              org.springframework.roo.model.JavaSymbolName artifactId,
              String version)
Creates an immutable Plugin.

Parameters:
groupId - the group ID (required)
artifactId - the artifact ID (required)
version - the version (required)

Plugin

public Plugin(String groupId,
              String artifactId,
              String version)
Convenience constructor.

Parameters:
groupId - the group ID (required)
artifactId - the artifact ID (required)
version - the version (required)

Plugin

public Plugin(String groupId,
              String artifactId,
              String version,
              Configuration configuration,
              List<Dependency> dependencies,
              List<Execution> executions)
Convenience constructor.

Parameters:
groupId - the group ID (required)
artifactId - the artifact ID (required)
version - the version (required)
configuration - the configuration for this plugin (optional)
dependencies - the dependencies for this plugin (optional)
executions - the executions for this plugin (optional)

Plugin

public Plugin(Element plugin)
Convenience constructor when an XML element is available that represents a Maven .

Parameters:
plugin - to parse (required)
Method Detail

getGroupId

public org.springframework.roo.model.JavaPackage getGroupId()

getArtifactId

public org.springframework.roo.model.JavaSymbolName getArtifactId()

getVersion

public String getVersion()

getConfiguration

public Configuration getConfiguration()

getDependencies

public List<Dependency> getDependencies()
Returns:
list of dependencies (never null)

getExecutions

public List<Execution> getExecutions()

hashCode

public int hashCode()
Overrides:
hashCode in class Object

equals

public boolean equals(Object obj)
Overrides:
equals in class Object

compareTo

public int compareTo(Plugin o)
Specified by:
compareTo in interface Comparable<Plugin>

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2009-2010 VMware, Inc. All Rights Reserved.