Package org.apache.jmeter.threads
Class SamplePackage
java.lang.Object
org.apache.jmeter.threads.SamplePackage
Packages methods related to sample handling.
A SamplePackage contains all elements associated to a Sampler:
A SamplePackage contains all elements associated to a Sampler:
- SampleListener(s)
- Timer(s)
- Assertion(s)
- PreProcessor(s)
- PostProcessor(s)
- ConfigTestElement(s)
- Controller(s)
- 
Constructor SummaryConstructorsConstructorDescriptionSamplePackage(List<ConfigTestElement> configs, List<SampleListener> listeners, List<Timer> timers, List<Assertion> assertions, List<PostProcessor> postProcessors, List<PreProcessor> preProcessors, List<Controller> controllers) 
- 
Method SummaryModifier and TypeMethodDescriptionvoidaddAssertion(Assertion asser) Add AssertionvoidAdd Post processorvoidAdd Pre processorvoidaddSampleListener(SampleListener listener) Add Sample ListenervoidAdd TimerReturns the configs.Returns the preProcessors.voidRecover each member of SamplePackage to the state before the call of setRunningVersion(true)voidsetRunningVersion(boolean running) Make the SamplePackage the running version, or make it no longer the running version.void
- 
Constructor Details- 
SamplePackagepublic SamplePackage(List<ConfigTestElement> configs, List<SampleListener> listeners, List<Timer> timers, List<Assertion> assertions, List<PostProcessor> postProcessors, List<PreProcessor> preProcessors, List<Controller> controllers) 
 
- 
- 
Method Details- 
setRunningVersionpublic void setRunningVersion(boolean running) Make the SamplePackage the running version, or make it no longer the running version. This tells to each element of the SamplePackage that it's current state must be retrievable by a call to recoverRunningVersion().- Parameters:
- running- boolean
- See Also:
- 
- TestElement.setRunningVersion(boolean)
 
 
- 
recoverRunningVersionpublic void recoverRunningVersion()Recover each member of SamplePackage to the state before the call of setRunningVersion(true)- See Also:
- 
- TestElement.recoverRunningVersion()
 
 
- 
getSampleListeners- Returns:
- List of SampleListeners
 
- 
addSampleListenerAdd Sample Listener- Parameters:
- listener-- SampleListener
 
- 
getTimers- Returns:
- List of Timers
 
- 
addPostProcessorAdd Post processor- Parameters:
- ex-- PostProcessor
 
- 
addPreProcessorAdd Pre processor- Parameters:
- pre-- PreProcessor
 
- 
addTimerAdd Timer- Parameters:
- timer-- Timer
 
- 
addAssertionAdd Assertion- Parameters:
- asser-- Assertion
 
- 
getAssertions- Returns:
- List of Assertion
 
- 
getPostProcessors- Returns:
- List of PostProcessors
 
- 
getSampler- Returns:
- Sampler
 
- 
setSampler- Parameters:
- s-- Sampler
 
- 
getPreProcessorsReturns the preProcessors.- Returns:
- List of PreProcessor
 
- 
getConfigsReturns the configs.- Returns:
- List of ConfigTestElement
 
 
-