PropertySource, RendererSummaryHTMLRenderer, TextColorRenderer, YAHTMLRendererpublic abstract class AbstractAccumulatingRenderer extends AbstractRenderer
Renderer implementations which only produce
output once all source files are processed. Such Renderers use
working memory proportional to the number of violations found, which can be
quite large in some scenarios. Consider using
AbstractIncrementingRenderer which can use significantly less memory.
Subclasses should implement the end() method to output the
report.AbstractIncrementingRenderer| Modifier and Type | Field | Description |
|---|---|---|
protected Report |
report |
The accumulated Report.
|
propertyDescriptors, propertyValuesByDescriptordescription, name, showSuppressedViolations, writer| Constructor | Description |
|---|---|
AbstractAccumulatingRenderer(java.lang.String name,
java.lang.String description) |
| Modifier and Type | Method | Description |
|---|---|---|
abstract void |
end() |
Subclasses should output the
report. |
void |
renderFileReport(Report report) |
Render the given file Report.
|
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.
|
copyPropertyDescriptors, copyPropertyValues, definePropertyDescriptor, dysfunctionReason, getPropertiesByPropertyDescriptor, getProperty, getPropertyDescriptor, getPropertyDescriptors, hasDescriptor, ignoredProperties, setProperty, setProperty, useDefaultValueFor, usesDefaultValuesflush, getDescription, getName, getWriter, isShowSuppressedViolations, setDescription, setName, setShowSuppressedViolations, setWriterclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitdefinePropertyDescriptor, dysfunctionReason, getPropertiesByPropertyDescriptor, getProperty, getPropertyDescriptor, getPropertyDescriptors, hasDescriptor, ignoredProperties, setProperty, setProperty, useDefaultValueFor, usesDefaultValuesdefaultFileExtensionprotected Report report
public AbstractAccumulatingRenderer(java.lang.String name,
java.lang.String description)
public void start()
throws java.io.IOException
Rendererjava.io.IOExceptionpublic void startFileAnalysis(DataSource dataSource)
RendererRenderer.start(), but before
Renderer.renderFileReport(Report) and Renderer.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.public void renderFileReport(Report report) throws java.io.IOException
RendererRenderer.start() and
Renderer.startFileAnalysis(DataSource), but before
Renderer.end().report - A file Report.java.io.IOExceptionReportpublic abstract void end()
throws java.io.IOException
report.
This method is at the very end of the Rendering process, after
Renderer.renderFileReport(Report).java.io.IOExceptionCopyright © 2002–2018 PMD. All rights reserved.