PropertySourceAbstractAccumulatingRenderer, AbstractIncrementingRenderer, AbstractRenderer, CodeClimateRenderer, CSVRenderer, EmacsRenderer, EmptyRenderer, HTMLRenderer, IDEAJRenderer, SummaryHTMLRenderer, TextColorRenderer, TextPadRenderer, TextRenderer, VBHTMLRenderer, XMLRenderer, XSLTRenderer, YAHTMLRendererpublic interface Renderer extends PropertySource
setShowSuppressedViolations(boolean)setWriter(Writer)start()startFileAnalysis(DataSource) for each source file
processedrenderFileReport(Report) for each Report instanceend()
An implementation of the Renderer interface is expected to have a default
constructor. Properties should be defined using the
PropertySource.definePropertyDescriptor(PropertyDescriptor)
method. After the instance is created, the property values are set. This
means, you won't have access to property values in your constructor.
| Modifier and Type | Method | Description |
|---|---|---|
java.lang.String |
defaultFileExtension() |
Return the default filename extension to use.
|
void |
end() |
This method is at the very end of the Rendering process, after
renderFileReport(Report). |
void |
flush() |
|
java.lang.String |
getDescription() |
Get the description of the Renderer.
|
java.lang.String |
getName() |
Get the name of the Renderer.
|
java.io.Writer |
getWriter() |
Get the Writer for the Renderer.
|
boolean |
isShowSuppressedViolations() |
Get the indicator for whether to show suppressed violations.
|
void |
renderFileReport(Report report) |
Render the given file Report.
|
void |
setDescription(java.lang.String description) |
Set the description of the Renderer.
|
void |
setName(java.lang.String name) |
Set the name of the Renderer.
|
void |
setShowSuppressedViolations(boolean showSuppressedViolations) |
Set the indicator for whether to show suppressed violations.
|
void |
setWriter(java.io.Writer writer) |
Set the Writer for the Renderer.
|
void |
start() |
This method is called before any source files are processed.
|
void |
startFileAnalysis(DataSource dataSource) |
This method is called each time a source file is processed.
|
definePropertyDescriptor, dysfunctionReason, getPropertiesByPropertyDescriptor, getProperty, getPropertyDescriptor, getPropertyDescriptors, hasDescriptor, ignoredProperties, setProperty, setProperty, useDefaultValueFor, usesDefaultValuesjava.lang.String getName()
void setName(java.lang.String name)
name - The name of the Renderer.java.lang.String getDescription()
java.lang.String defaultFileExtension()
void setDescription(java.lang.String description)
description - The description of the Renderer.boolean isShowSuppressedViolations()
true if suppressed violations should show,
false otherwise.void setShowSuppressedViolations(boolean showSuppressedViolations)
showSuppressedViolations - Whether to show suppressed violations.java.io.Writer getWriter()
void setWriter(java.io.Writer writer)
writer - The Writer.void start()
throws java.io.IOException
java.io.IOExceptionvoid startFileAnalysis(DataSource dataSource)
start(), but before
renderFileReport(Report) and end().
This method may be invoked by different threads which are processing
files independently. Therefore, any non-trivial implementation of this
method needs to be thread-safe.dataSource - The source file.void renderFileReport(Report report) throws java.io.IOException
start() and
startFileAnalysis(DataSource), but before
end().report - A file Report.java.io.IOExceptionReportvoid end() throws java.io.IOException
renderFileReport(Report).java.io.IOExceptionvoid flush()
throws java.io.IOException
java.io.IOExceptionCopyright © 2002–2018 PMD. All rights reserved.