AbstractSampleSource (Apache JMeter dist API)
Description: declaration: package: org.apache.jmeter.report.processor, class: AbstractSampleSource

Package org.apache.jmeter.report.processor

# Class AbstractSampleSource

java.lang.Object
org.apache.jmeter.report.processor.AbstractSampleSource

All Implemented Interfaces:
  `Runnable`, `SampleSource`

Direct Known Subclasses:
  `CsvFileSampleSource`

public abstract class AbstractSampleSource extends Object implements SampleSource

- ## Constructor Summary

  Constructors
  Modifier
  Constructor
  Description
  `protected`
  `AbstractSampleSource()`
  Instantiates a new abstract sample source.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `abstract void`
  `addSampleConsumer(SampleConsumer consumer)`
  Add a sample consumer to this sample source.
  `SampleContext`
  `getSampleContext()`
  Gets the sample context.
  `abstract void`
  `removeSampleConsumer(SampleConsumer consumer)`
  Remove a sample consumer from this sample source.
  `abstract void`
  `run()`
  `abstract void`
  `setSampleConsumers(List<SampleConsumer> consumers)`
  Sets the specified sample consumers that will consume samples produced by this sample source.
  `void`
  `setSampleContext(SampleContext sampleContext)`
  Sets the sample context.

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

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

- ## Constructor Details

  - ### AbstractSampleSource

    protected AbstractSampleSource()
    Instantiates a new abstract sample source.

- ## Method Details

  - ### run

    public abstract void run()
    Specified by:
      `run` in interface `Runnable`

  - ### getSampleContext

    public SampleContext getSampleContext()
    Description copied from interface: `SampleSource`
    Gets the sample context.
    Specified by:
      `getSampleContext` in interface `SampleSource`
    Returns:
      the sampleContext

  - ### setSampleContext

    public void setSampleContext(SampleContext sampleContext)
    Description copied from interface: `SampleSource`
    Sets the sample context.
    Specified by:
      `setSampleContext` in interface `SampleSource`
    Parameters:
      `sampleContext` - the sampleContext to set

  - ### setSampleConsumers

    public abstract void setSampleConsumers(List<SampleConsumer> consumers)
    Description copied from interface: `SampleSource`
    Sets the specified sample consumers that will consume samples produced by this sample source.
    Specified by:
      `setSampleConsumers` in interface `SampleSource`
    Parameters:
      `consumers` - consumers to be set

  - ### addSampleConsumer

    public abstract void addSampleConsumer(SampleConsumer consumer)
    Description copied from interface: `SampleSource`
    Add a sample consumer to this sample source.
    Specified by:
      `addSampleConsumer` in interface `SampleSource`
    Parameters:
      `consumer` - consumer to be added

  - ### removeSampleConsumer

    public abstract void removeSampleConsumer(SampleConsumer consumer)
    Description copied from interface: `SampleSource`
    Remove a sample consumer from this sample source.
    Specified by:
      `removeSampleConsumer` in interface `SampleSource`
    Parameters:
      `consumer` - consumer to be removed