net.sourceforge.pmd.renderers

## Class AbstractRenderer

- java.lang.Object
- - net.sourceforge.pmd.AbstractPropertySource
  - - net.sourceforge.pmd.renderers.AbstractRenderer

- All Implemented Interfaces:
    PropertySource, Renderer
  Direct Known Subclasses:
    AbstractAccumulatingRenderer, AbstractIncrementingRenderer

      public abstract class AbstractRenderer
      extends AbstractPropertySource
      implements Renderer

  Abstract base class for `Renderer` implementations.

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected String` | `description`
    `protected String` | `name`
    `protected Map<String,String>` | `propertyDefinitions` Deprecated.
    `protected boolean` | `showSuppressedViolations`
    `protected Writer` | `writer`

    - ### Fields inherited from class net.sourceforge.pmd.AbstractPropertySource

      `propertyDescriptors, propertyValuesByDescriptor`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `AbstractRenderer(String name, String description)`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected void` | `defineProperty(String name, String description)` Deprecated.
    `void` | `flush()`
    `String` | `getDescription()` Get the description of the Renderer.
    `String` | `getName()` Get the name of the Renderer.
    `Map<String,String>` | `getPropertyDefinitions()` Deprecated.
    `Writer` | `getWriter()` Get the Writer for the Renderer.
    `boolean` | `isShowSuppressedViolations()` Get the indicator for whether to show suppressed violations.
    `void` | `setDescription(String description)` Set the description of the Renderer.
    `void` | `setName(String name)` Set the name of the Renderer.
    `void` | `setShowSuppressedViolations(boolean showSuppressedViolations)` Set the indicator for whether to show suppressed violations.
    `void` | `setWriter(Writer writer)` Set the Writer for the Renderer.

    - ### Methods inherited from class net.sourceforge.pmd.AbstractPropertySource

      `copyPropertyDescriptors, copyPropertyValues, definePropertyDescriptor, dysfunctionReason, getPropertiesByPropertyDescriptor, getProperty, getPropertyDescriptor, getPropertyDescriptors, hasDescriptor, ignoredProperties, setProperty, useDefaultValueFor, usesDefaultValues`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

    - ### Methods inherited from interface net.sourceforge.pmd.renderers.Renderer

      `defaultFileExtension, end, renderFileReport, start, startFileAnalysis`

    - ### Methods inherited from interface net.sourceforge.pmd.PropertySource

      `definePropertyDescriptor, dysfunctionReason, getPropertiesByPropertyDescriptor, getProperty, getPropertyDescriptor, getPropertyDescriptors, hasDescriptor, ignoredProperties, setProperty, useDefaultValueFor, usesDefaultValues`

- - ### Field Detail

    - #### name

          protected String name

    - #### description

          protected String description

    - #### propertyDefinitions

          @Deprecated
          protected Map<String,String> propertyDefinitions

      Deprecated.

    - #### showSuppressedViolations

          protected boolean showSuppressedViolations

    - #### writer

          protected Writer writer

  - ### Constructor Detail

    - #### AbstractRenderer

          public AbstractRenderer(String name,
                          String description)

  - ### Method Detail

    - #### getName

          public String getName()

      Get the name of the Renderer.
      Specified by:
        `getName` in interface `Renderer`
      Specified by:
        `getName` in class `AbstractPropertySource`
      Returns:
        The name of the Renderer.

    - #### setName

          public void setName(String name)

      Set the name of the Renderer.
      Specified by:
        `setName` in interface `Renderer`
      Parameters:
        `name` - The name of the Renderer.

    - #### getDescription

          public String getDescription()

      Get the description of the Renderer.
      Specified by:
        `getDescription` in interface `Renderer`
      Returns:
        The description of the Renderer.

    - #### setDescription

          public void setDescription(String description)

      Set the description of the Renderer.
      Specified by:
        `setDescription` in interface `Renderer`
      Parameters:
        `description` - The description of the Renderer.

    - #### getPropertyDefinitions

          @Deprecated
          public Map<String,String> getPropertyDefinitions()

      Deprecated.
      Get the configuration property definitions for Renderer. The keys in the map are the configuration property names, with the corresponding value being a description.
      Specified by:
        `getPropertyDefinitions` in interface `Renderer`
      Returns:
        The configuration property definition map.

    - #### defineProperty

          @Deprecated
          protected void defineProperty(String name,
                                       String description)

      Deprecated.
      Define a property.
      Parameters:
        `name` - The property name.
        `description` - The description of the property.

    - #### isShowSuppressedViolations

          public boolean isShowSuppressedViolations()

      Get the indicator for whether to show suppressed violations.
      Specified by:
        `isShowSuppressedViolations` in interface `Renderer`
      Returns:
        `true` if suppressed violations should show, `false` otherwise.

    - #### setShowSuppressedViolations

          public void setShowSuppressedViolations(boolean showSuppressedViolations)

      Set the indicator for whether to show suppressed violations.
      Specified by:
        `setShowSuppressedViolations` in interface `Renderer`
      Parameters:
        `showSuppressedViolations` - Whether to show suppressed violations.

    - #### setWriter

          public void setWriter(Writer writer)

      Set the Writer for the Renderer.
      Specified by:
        `setWriter` in interface `Renderer`
      Parameters:
        `writer` - The Writer.

    - #### getWriter

          public Writer getWriter()

      Get the Writer for the Renderer.
      Specified by:
        `getWriter` in interface `Renderer`
      Returns:
        The Writer.

    - #### flush

          public void flush()

      Specified by:
        `flush` in interface `Renderer`

Copyright © 2002-2013 InfoEther. All Rights Reserved.