org.apache.maven.announcement
Class AnnouncementMojo

java.lang.Object
  extended byorg.apache.maven.plugin.AbstractMojo
      extended byorg.apache.maven.announcement.AnnouncementMojo
All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled, org.apache.maven.plugin.Mojo

public class AnnouncementMojo
extends org.apache.maven.plugin.AbstractMojo

Version:
$Id: AnnouncementMojo.java 422 2005-08-26 aqr $
Author:
aramirez@exist.com

Field Summary
 
Fields inherited from interface org.apache.maven.plugin.Mojo
ROLE
 
Constructor Summary
AnnouncementMojo()
           
 
Method Summary
 void doGenerate(ChangesXML xml)
          Add the parameters to velocity context
 void execute()
          Generate the template
 java.lang.String getArtifactId()
           
 java.lang.String getDevelopmentTeam()
           
 java.lang.String getFinalName()
           
 java.lang.String getGroupId()
           
 java.lang.String getIntroduction()
           
 Release getLatestRelease(java.util.List releases)
          Get the latest release by matching the release in changes.xml and in the version of the pom
 java.lang.String getOutputDirectory()
           
 java.lang.String getPackaging()
           
 java.lang.String getUrl()
           
 java.lang.String getUrlDownload()
           
 org.codehaus.plexus.velocity.VelocityComponent getVelocity()
           
 java.lang.String getVersion()
           
 ChangesXML getXml()
           
 java.lang.String getXmlPath()
           
 void processTemplate(org.apache.velocity.context.Context context, java.lang.String outputDirectory, java.lang.String template)
          Create the velocity template
 void setArtifactId(java.lang.String artifactId)
           
 void setDevelopmentTeam(java.lang.String developmentTeam)
           
 void setFinalName(java.lang.String finalName)
           
 void setGroupId(java.lang.String groupId)
           
 void setIntroduction(java.lang.String introduction)
           
 void setOutputDirectory(java.lang.String outputDirectory)
           
 void setPackaging(java.lang.String packaging)
           
 void setUrl(java.lang.String url)
           
 void setUrlDownload(java.lang.String urlDownload)
           
 void setVelocity(org.codehaus.plexus.velocity.VelocityComponent velocity)
           
 void setVersion(java.lang.String version)
           
 void setXml(ChangesXML xml)
           
 void setXmlPath(java.lang.String xmlPath)
           
 
Methods inherited from class org.apache.maven.plugin.AbstractMojo
getLog, getPluginContext, setLog, setPluginContext
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AnnouncementMojo

public AnnouncementMojo()
Method Detail

execute

public void execute()
             throws org.apache.maven.plugin.MojoExecutionException
Generate the template

Throws:
org.apache.maven.plugin.MojoExecutionException

doGenerate

public void doGenerate(ChangesXML xml)
                throws org.apache.maven.plugin.MojoExecutionException
Add the parameters to velocity context

Parameters:
xml - parsed changes.xml
Throws:
org.apache.maven.plugin.MojoExecutionException

getLatestRelease

public Release getLatestRelease(java.util.List releases)
                         throws org.apache.maven.plugin.MojoExecutionException
Get the latest release by matching the release in changes.xml and in the version of the pom

Parameters:
releases - list of releases in changes.xml
Throws:
org.apache.maven.plugin.MojoExecutionException

processTemplate

public void processTemplate(org.apache.velocity.context.Context context,
                            java.lang.String outputDirectory,
                            java.lang.String template)
                     throws org.apache.velocity.exception.ResourceNotFoundException,
                            org.apache.velocity.exception.VelocityException,
                            java.io.IOException,
                            org.apache.maven.plugin.MojoExecutionException
Create the velocity template

Parameters:
context - velocity context that has the parameter values
outputDirectory - directory where the file will be generated
template - velocity template which will the context be merged
Throws:
ResourceNotFoundException, - VelocityException, IOException
org.apache.velocity.exception.ResourceNotFoundException
org.apache.velocity.exception.VelocityException
java.io.IOException
org.apache.maven.plugin.MojoExecutionException

getXmlPath

public java.lang.String getXmlPath()

setXmlPath

public void setXmlPath(java.lang.String xmlPath)

getOutputDirectory

public java.lang.String getOutputDirectory()

setOutputDirectory

public void setOutputDirectory(java.lang.String outputDirectory)

getGroupId

public java.lang.String getGroupId()

setGroupId

public void setGroupId(java.lang.String groupId)

getArtifactId

public java.lang.String getArtifactId()

setArtifactId

public void setArtifactId(java.lang.String artifactId)

getVersion

public java.lang.String getVersion()

setVersion

public void setVersion(java.lang.String version)

getUrl

public java.lang.String getUrl()

setUrl

public void setUrl(java.lang.String url)

getXml

public ChangesXML getXml()

setXml

public void setXml(ChangesXML xml)

getPackaging

public java.lang.String getPackaging()

setPackaging

public void setPackaging(java.lang.String packaging)

getDevelopmentTeam

public java.lang.String getDevelopmentTeam()

setDevelopmentTeam

public void setDevelopmentTeam(java.lang.String developmentTeam)

getIntroduction

public java.lang.String getIntroduction()

setIntroduction

public void setIntroduction(java.lang.String introduction)

getVelocity

public org.codehaus.plexus.velocity.VelocityComponent getVelocity()

setVelocity

public void setVelocity(org.codehaus.plexus.velocity.VelocityComponent velocity)

getFinalName

public java.lang.String getFinalName()

setFinalName

public void setFinalName(java.lang.String finalName)

getUrlDownload

public java.lang.String getUrlDownload()

setUrlDownload

public void setUrlDownload(java.lang.String urlDownload)


Copyright © {inceptionYear}-2007 null. All Rights Reserved.