Class AbstractSampleProcessor
java.lang.Object
org.apache.jmeter.report.processor.AbstractSampleProcessor
- All Implemented Interfaces:
SampleProcessor
- Direct Known Subclasses:
AbstractSampleConsumer
Base for sample processor implementations
Implements basic logic for setting sample context and handling channel attributes.
Implements basic logic for setting sample context and handling channel attributes.
- Since:
- 3.0
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptiongetChannelAttribute
(int channel, String key) Return an attribute value associated on a channel on this sample processorGets the sample context.void
setChannelAttribute
(int channel, String key, Object value) Associate an attribute to the specified channel for this sample processor
If the attribute already exist, it is replaced.void
setSampleContext
(SampleContext sampleContext) Set sample context that this consumer should rely on.
-
Constructor Details
-
AbstractSampleProcessor
public AbstractSampleProcessor()
-
-
Method Details
-
getSampleContext
Description copied from interface:SampleProcessor
Gets the sample context.- Specified by:
getSampleContext
in interfaceSampleProcessor
- Returns:
- the sample context
-
setSampleContext
Description copied from interface:SampleProcessor
Set sample context that this consumer should rely on.- Specified by:
setSampleContext
in interfaceSampleProcessor
- Parameters:
sampleContext
- the new sample context
-
setChannelAttribute
Description copied from interface:SampleProcessor
Associate an attribute to the specified channel for this sample processor
If the attribute already exist, it is replaced.- Specified by:
setChannelAttribute
in interfaceSampleProcessor
- Parameters:
channel
- The channel number to associate the attribute onkey
- The attribute keyvalue
- The attribute value to be set
-
getChannelAttribute
Description copied from interface:SampleProcessor
Return an attribute value associated on a channel on this sample processor- Specified by:
getChannelAttribute
in interfaceSampleProcessor
- Parameters:
channel
- The channel on which the attribute is associatedkey
- The attribute key to be retrieved- Returns:
- The attribute value or null if none is found for the specified key
-