org.apache.maven.plugin.announcement
Class AnnouncementMojo

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

public class AnnouncementMojo
extends AbstractAnnouncementMojo

Goal which generate the template for an announcement.

Since:
2.0-beta-2
Version:
$Id: AnnouncementMojo.html 816603 2012-05-08 12:53:30Z hboutemy $
Author:
aramirez@exist.com
Is defined by the goal name:
announcement-generate
Requires the dependencies in this specified scope:
test

Field Summary
 
Fields inherited from class org.apache.maven.plugin.announcement.AbstractAnnouncementMojo
basedir, mavenSession, runOnlyAtExecutionRoot
 
Fields inherited from interface org.apache.maven.plugin.Mojo
ROLE
 
Constructor Summary
AnnouncementMojo()
           
 
Method Summary
 void doGenerate(List<Release> releases)
          Add the parameters to velocity context
protected  void doGenerate(List<Release> releases, Release release)
           
 void execute()
          Generate the template
 String getArtifactId()
           
 String getDevelopmentTeam()
           
 String getFinalName()
           
 String getGroupId()
           
 String getIntroduction()
           
 Map<String,String> getIssueTypes()
           
protected  List<Release> getJiraReleases()
           
 File getOutputDirectory()
           
 String getPackaging()
           
protected  List<Release> getTracReleases()
           
 String getUrl()
           
 String getUrlDownload()
           
 org.codehaus.plexus.velocity.VelocityComponent getVelocity()
           
 String getVersion()
           
 ChangesXML getXml()
           
 File getXmlPath()
           
 void processTemplate(Context context, File outputDirectory, String template, String announcementFile)
          Create the velocity template
 void setArtifactId(String artifactId)
           
 void setDevelopmentTeam(String developmentTeam)
           
 void setFinalName(String finalName)
           
 void setGroupId(String groupId)
           
 void setIntroduction(String introduction)
           
 void setIssueTypes(Map<String,String> issueTypes)
           
 void setOutputDirectory(File outputDirectory)
           
 void setPackaging(String packaging)
           
 void setUrl(String url)
           
 void setUrlDownload(String urlDownload)
           
 void setVelocity(org.codehaus.plexus.velocity.VelocityComponent velocity)
           
 void setVersion(String version)
           
 void setXml(ChangesXML xml)
           
 void setXmlPath(File xmlPath)
           
 
Methods inherited from class org.apache.maven.plugin.announcement.AbstractAnnouncementMojo
isThisTheExecutionRoot
 
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(List<Release> releases)
                throws org.apache.maven.plugin.MojoExecutionException
Add the parameters to velocity context

Parameters:
releases - A List of Releases
Throws:
org.apache.maven.plugin.MojoExecutionException

doGenerate

protected void doGenerate(List<Release> releases,
                          Release release)
                   throws org.apache.maven.plugin.MojoExecutionException
Throws:
org.apache.maven.plugin.MojoExecutionException

processTemplate

public void processTemplate(Context context,
                            File outputDirectory,
                            String template,
                            String announcementFile)
                     throws ResourceNotFoundException,
                            VelocityException,
                            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
announcementFile - The file name of the generated announcement
Throws:
ResourceNotFoundException, - VelocityException, IOException
ResourceNotFoundException
VelocityException
org.apache.maven.plugin.MojoExecutionException

getJiraReleases

protected List<Release> getJiraReleases()
                                 throws org.apache.maven.plugin.MojoExecutionException
Throws:
org.apache.maven.plugin.MojoExecutionException

getTracReleases

protected List<Release> getTracReleases()
                                 throws org.apache.maven.plugin.MojoExecutionException
Throws:
org.apache.maven.plugin.MojoExecutionException

getArtifactId

public String getArtifactId()

setArtifactId

public void setArtifactId(String artifactId)

getDevelopmentTeam

public String getDevelopmentTeam()

setDevelopmentTeam

public void setDevelopmentTeam(String developmentTeam)

getFinalName

public String getFinalName()

setFinalName

public void setFinalName(String finalName)

getGroupId

public String getGroupId()

setGroupId

public void setGroupId(String groupId)

getIntroduction

public String getIntroduction()

setIntroduction

public void setIntroduction(String introduction)

setIssueTypes

public void setIssueTypes(Map<String,String> issueTypes)

getIssueTypes

public Map<String,String> getIssueTypes()

getOutputDirectory

public File getOutputDirectory()

setOutputDirectory

public void setOutputDirectory(File outputDirectory)

getPackaging

public String getPackaging()

setPackaging

public void setPackaging(String packaging)

getUrl

public String getUrl()

setUrl

public void setUrl(String url)

getUrlDownload

public String getUrlDownload()

setUrlDownload

public void setUrlDownload(String urlDownload)

getVelocity

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

setVelocity

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

getVersion

public String getVersion()

setVersion

public void setVersion(String version)

getXml

public ChangesXML getXml()

setXml

public void setXml(ChangesXML xml)

getXmlPath

public File getXmlPath()

setXmlPath

public void setXmlPath(File xmlPath)


Copyright © 2002-2011 The Apache Software Foundation. All Rights Reserved.