Class Processor<T>

java.lang.Object
org.owasp.dependencycheck.utils.processing.Processor<T>
Type Parameters:
T - the type of processor
All Implemented Interfaces:
AutoCloseable, Runnable

public abstract class Processor<T> extends Object implements Runnable, AutoCloseable
Abstract class to create, in general, an input stream processor used to evaluate the output of an external process.
Author:
Jeremy Long
  • Constructor Details

    • Processor

      public Processor()
      Creates a new processor.
    • Processor

      public Processor(T input)
      Creates a new processor.
      Parameters:
      input - the input to process
  • Method Details

    • setInput

      public void setInput(T input)
      Sets the input to process.
      Parameters:
      input - the input to process
    • getInput

      protected T getInput()
      Retrieves a reference to the input.
      Returns:
      a reference to the input
    • addSuppressedExceptions

      protected void addSuppressedExceptions(Throwable ex, Throwable... suppress)
      Adds any non-null exceptions in the `suppress` list to the suppressed exceptions on the main exception `ex`.
      Parameters:
      ex - the main exception that suppressed exceptions will be added
      suppress - one or more exceptions that will be added as suppressed