Class AnalysisTask

java.lang.Object
org.owasp.dependencycheck.AnalysisTask
All Implemented Interfaces:
Callable<Void>

@ThreadSafe public class AnalysisTask extends Object implements Callable<Void>
Task to support parallelism of dependency-check analysis. Analysis a single Dependency by a specific Analyzer.
Author:
Stefan Neuhaus
  • Constructor Details

    • AnalysisTask

      public AnalysisTask(Analyzer analyzer, Dependency dependency, Engine engine, List<Throwable> exceptions)
      Creates a new analysis task.
      Parameters:
      analyzer - a reference of the analyzer to execute
      dependency - the dependency to analyze
      engine - the dependency-check engine
      exceptions - exceptions that occur during analysis will be added to this collection of exceptions
  • Method Details

    • call

      public Void call()
      Executes the analysis task.
      Specified by:
      call in interface Callable<Void>
      Returns:
      null
    • shouldAnalyze

      protected boolean shouldAnalyze()
      Determines if the analyzer can analyze the given dependency.
      Returns:
      whether or not the analyzer can analyze the dependency