org.apache.maven.plugin.announcement
Class AnnouncementMojo
java.lang.Object
org.apache.maven.plugin.AbstractMojo
org.apache.maven.plugin.announcement.AnnouncementMojo
- All Implemented Interfaces:
- org.apache.maven.plugin.ContextEnabled, org.apache.maven.plugin.Mojo
public class AnnouncementMojo
- extends org.apache.maven.plugin.AbstractMojo
Goal which generate the template for an announcement.
- Version:
- $Id$
- Author:
- aramirez@exist.com
- Is defined by the goal name:
- announcement-generate
- Requires the dependencies in this specified scope:
- test
Fields inherited from interface org.apache.maven.plugin.Mojo |
ROLE |
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 |
AnnouncementMojo
public AnnouncementMojo()
execute
public void execute()
throws org.apache.maven.plugin.MojoExecutionException
- Generate the template
- Throws:
org.apache.maven.plugin.MojoExecutionException
doGenerate
public void doGenerate(List releases)
throws org.apache.maven.plugin.MojoExecutionException
- Add the parameters to velocity context
- Parameters:
releases
- A List
of Release
s
- Throws:
org.apache.maven.plugin.MojoExecutionException
doGenerate
protected void doGenerate(List releases,
Release release)
throws org.apache.maven.plugin.MojoExecutionException
- Throws:
org.apache.maven.plugin.MojoExecutionException
getLatestRelease
public Release getLatestRelease(List releases)
throws org.apache.maven.plugin.MojoExecutionException
- Get the latest release by matching the supplied releases
with the version from the pom.
- Parameters:
releases
- list of releases
- Returns:
- A
Release
that matches the next release of the current project
- Throws:
org.apache.maven.plugin.MojoExecutionException
getRelease
protected Release getRelease(List releases,
String version)
processTemplate
public void processTemplate(Context context,
File outputDirectory,
String template)
throws ResourceNotFoundException,
VelocityException,
org.apache.maven.plugin.MojoExecutionException
- Create the velocity template
- Parameters:
context
- velocity context that has the parameter valuesoutputDirectory
- directory where the file will be generatedtemplate
- velocity template which will the context be merged
- Throws:
ResourceNotFoundException,
- VelocityException, IOException
ResourceNotFoundException
VelocityException
org.apache.maven.plugin.MojoExecutionException
doJiraGenerate
public void doJiraGenerate()
throws org.apache.maven.plugin.MojoExecutionException
- Throws:
org.apache.maven.plugin.MojoExecutionException
getJiraReleases
protected List getJiraReleases()
throws org.apache.maven.plugin.MojoExecutionException
- Throws:
org.apache.maven.plugin.MojoExecutionException
mergeReleases
protected List mergeReleases(List changesReleases,
List jiraReleases)
getXmlPath
public File getXmlPath()
setXmlPath
public void setXmlPath(File xmlPath)
getOutputDirectory
public File getOutputDirectory()
setOutputDirectory
public void setOutputDirectory(File outputDirectory)
getGroupId
public String getGroupId()
setGroupId
public void setGroupId(String groupId)
getArtifactId
public String getArtifactId()
setArtifactId
public void setArtifactId(String artifactId)
getVersion
public String getVersion()
setVersion
public void setVersion(String version)
getUrl
public String getUrl()
setUrl
public void setUrl(String url)
getXml
public ChangesXML getXml()
setXml
public void setXml(ChangesXML xml)
getPackaging
public String getPackaging()
setPackaging
public void setPackaging(String packaging)
getDevelopmentTeam
public String getDevelopmentTeam()
setDevelopmentTeam
public void setDevelopmentTeam(String developmentTeam)
getIntroduction
public String getIntroduction()
setIntroduction
public void setIntroduction(String introduction)
getVelocity
public org.codehaus.plexus.velocity.VelocityComponent getVelocity()
setVelocity
public void setVelocity(org.codehaus.plexus.velocity.VelocityComponent velocity)
getFinalName
public String getFinalName()
setFinalName
public void setFinalName(String finalName)
getUrlDownload
public String getUrlDownload()
setUrlDownload
public void setUrlDownload(String urlDownload)
Copyright © 2002-2009 The Apache Software Foundation. All Rights Reserved.