|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.maven.plugin.AbstractMojo
org.apache.maven.reporting.AbstractMavenReport
org.apache.maven.plugin.changelog.ChangeLogReport
public class ChangeLogReport
Generate a changelog report.
Field Summary | |
---|---|
protected java.util.List |
developers
List of developers to be shown on the report. |
protected java.lang.String |
displayChangeSetDetailUrl
A template string that is used to create the changeset URL. |
protected java.lang.String |
displayFileDetailUrl
A template string that is used to create the URL to the file details. |
protected java.lang.String |
displayFileRevDetailUrl
A template string that is used to create the revision aware URL to the file details in a similar fashion to the displayFileDetailUrl . |
protected java.lang.String |
scmUrl
The URL to view the scm. |
Fields inherited from interface org.apache.maven.reporting.MavenReport |
---|
CATEGORY_PROJECT_INFORMATION, CATEGORY_PROJECT_REPORTS, ROLE |
Fields inherited from interface org.apache.maven.plugin.Mojo |
---|
ROLE |
Constructor Summary | |
---|---|
ChangeLogReport()
|
Method Summary | |
---|---|
boolean |
canGenerateReport()
|
void |
checkResult(org.apache.maven.scm.ScmResult result)
|
protected long |
countFilesChanged(java.util.Collection entries)
counts the number of files that were changed in the specified SCM |
protected void |
doChangeSetTitle(org.apache.maven.scm.command.changelog.ChangeLogSet set,
java.util.ResourceBundle bundle,
org.apache.maven.doxia.sink.Sink sink)
Generate the title for the report. |
protected void |
doGenerateEmptyReport(java.util.ResourceBundle bundle,
org.apache.maven.doxia.sink.Sink sink)
generates an empty report in case there are no sources to generate a report with |
protected void |
doGenerateReport(java.util.List changeLogSets,
java.util.ResourceBundle bundle,
org.apache.maven.doxia.sink.Sink sink)
method that generates the report for this mojo. |
protected void |
doSummary(org.apache.maven.scm.command.changelog.ChangeLogSet set,
java.util.ResourceBundle bundle,
org.apache.maven.doxia.sink.Sink sink)
Generate the summary section of the report. |
void |
executeReport(java.util.Locale locale)
|
protected java.util.List |
generateChangeSetsFromSCM()
creates a ChangeLog object and then connects to the SCM to generate the changed sets |
protected void |
generateLinks(java.lang.String connection,
java.lang.String name,
org.apache.maven.doxia.sink.Sink sink)
attaches the http links from the changed files |
protected void |
generateLinks(java.lang.String connection,
java.lang.String name,
java.lang.String revision,
org.apache.maven.doxia.sink.Sink sink)
attaches the http links from the changed files |
protected java.util.ResourceBundle |
getBundle(java.util.Locale locale)
|
protected java.util.List |
getChangedSets()
populates the changedSets field by either connecting to the SCM or using an existing XML generated in a previous run of the report |
protected java.lang.String |
getConnection()
used to retrieve the SCM connection string |
java.lang.String |
getDescription(java.util.Locale locale)
|
java.lang.String |
getName(java.util.Locale locale)
|
protected java.lang.String |
getOutputDirectory()
|
java.lang.String |
getOutputName()
|
protected org.apache.maven.project.MavenProject |
getProject()
|
org.apache.maven.scm.repository.ScmRepository |
getScmRepository()
|
protected org.apache.maven.doxia.siterenderer.Renderer |
getSiteRenderer()
|
protected void |
initReportUrls()
populates the report url used to create links from certain elements of the report |
protected void |
sinkAuthorDetails(org.apache.maven.doxia.sink.Sink sink,
java.lang.String author)
If the supplied author is a known developer this method outputs a link to the team members report, or alternatively, if the supplied author is unknown, outputs the author's name as plain text. |
Methods inherited from class org.apache.maven.reporting.AbstractMavenReport |
---|
closeReport, execute, generate, generate, generate, getCategoryName, getReportOutputDirectory, getSink, getSinkFactory, isExternalReport, setReportOutputDirectory |
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 |
Field Detail |
---|
protected java.lang.String scmUrl
protected java.lang.String displayFileDetailUrl
%FILE%
- this is the path to a file
Example:
http://checkstyle.cvs.sourceforge.net/checkstyle%FILE%?view=markup
Note: If you don't supply the token in your template, the path of the file will simply be appended to your template URL.
protected java.lang.String displayChangeSetDetailUrl
%REV%
- this is the changeset revision
Example:
http://fisheye.sourceforge.net/changelog/a-project/?cs=%REV%
Note: If you don't supply the %REV% token in your template, the revision will simply be appended to your template URL.
protected java.lang.String displayFileRevDetailUrl
displayFileDetailUrl
.
When a report contains both file and file revision information, as in the
Change Log report, this template string can be used to create a revision
aware URL to the file details.
If not defined this template string defaults to the same value as the
displayFileDetailUrl
and thus revision number aware links will
not be used.
There are two special tokens that you can use in your template:
%FILE%
- this is the path to a file%REV%
- this is the revision of the file
Example:
http://fisheye.sourceforge.net/browse/a-project/%FILE%?r=%REV%
Note: If you don't supply the %FILE% token in your template, the path of the file will simply be appended to your template URL.
protected java.util.List developers
Constructor Detail |
---|
public ChangeLogReport()
Method Detail |
---|
public void executeReport(java.util.Locale locale) throws org.apache.maven.reporting.MavenReportException
executeReport
in class org.apache.maven.reporting.AbstractMavenReport
org.apache.maven.reporting.MavenReportException
protected java.util.List getChangedSets() throws org.apache.maven.reporting.MavenReportException
org.apache.maven.reporting.MavenReportException
protected java.util.List generateChangeSetsFromSCM() throws org.apache.maven.reporting.MavenReportException
org.apache.maven.reporting.MavenReportException
public org.apache.maven.scm.repository.ScmRepository getScmRepository() throws org.apache.maven.scm.ScmException
org.apache.maven.scm.ScmException
public void checkResult(org.apache.maven.scm.ScmResult result) throws org.apache.maven.plugin.MojoExecutionException
org.apache.maven.plugin.MojoExecutionException
protected java.lang.String getConnection() throws org.apache.maven.reporting.MavenReportException
org.apache.maven.reporting.MavenReportException
- when there is insufficient information to retrieve the SCM connection stringprotected void doGenerateEmptyReport(java.util.ResourceBundle bundle, org.apache.maven.doxia.sink.Sink sink)
bundle
- the resource bundle to retrieve report phrases fromsink
- the report formatting toolprotected void doGenerateReport(java.util.List changeLogSets, java.util.ResourceBundle bundle, org.apache.maven.doxia.sink.Sink sink)
changeLogSets
- changed sets to generate the report frombundle
- the resource bundle to retrieve report phrases fromsink
- the report formatting toolprotected void doChangeSetTitle(org.apache.maven.scm.command.changelog.ChangeLogSet set, java.util.ResourceBundle bundle, org.apache.maven.doxia.sink.Sink sink)
set
- change set to generate the report frombundle
- the resource bundle to retrieve report phrases fromsink
- the report formatting toolprotected void doSummary(org.apache.maven.scm.command.changelog.ChangeLogSet set, java.util.ResourceBundle bundle, org.apache.maven.doxia.sink.Sink sink)
set
- change set to generate the report frombundle
- the resource bundle to retrieve report phrases fromsink
- the report formatting toolprotected long countFilesChanged(java.util.Collection entries)
entries
- a collection of SCM changes
protected void sinkAuthorDetails(org.apache.maven.doxia.sink.Sink sink, java.lang.String author)
sink
- Sink to use for outputtingauthor
- The author's name.protected void initReportUrls()
protected void generateLinks(java.lang.String connection, java.lang.String name, org.apache.maven.doxia.sink.Sink sink)
connection
- the string used to connect to the SCMname
- filename of the file that was changedsink
- the report formatting toolprotected void generateLinks(java.lang.String connection, java.lang.String name, java.lang.String revision, org.apache.maven.doxia.sink.Sink sink)
connection
- the string used to connect to the SCMname
- filename of the file that was changedrevision
- the revision codesink
- the report formatting toolprotected org.apache.maven.project.MavenProject getProject()
getProject
in class org.apache.maven.reporting.AbstractMavenReport
protected java.lang.String getOutputDirectory()
getOutputDirectory
in class org.apache.maven.reporting.AbstractMavenReport
protected org.apache.maven.doxia.siterenderer.Renderer getSiteRenderer()
getSiteRenderer
in class org.apache.maven.reporting.AbstractMavenReport
public java.lang.String getDescription(java.util.Locale locale)
public java.lang.String getName(java.util.Locale locale)
public java.lang.String getOutputName()
protected java.util.ResourceBundle getBundle(java.util.Locale locale)
locale
-
public boolean canGenerateReport()
canGenerateReport
in interface org.apache.maven.reporting.MavenReport
canGenerateReport
in class org.apache.maven.reporting.AbstractMavenReport
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |