public class JMeterVariables extends Object
Constructor and Description |
---|
JMeterVariables()
Constructor, that preloads the variables from the JMeter properties
|
Modifier and Type | Method and Description |
---|---|
Set<Map.Entry<String,Object>> |
entrySet() |
String |
get(String key)
Gets the value of a variable, converted to a String.
|
int |
getIteration() |
Iterator<Map.Entry<String,Object>> |
getIterator()
Gets a read-only Iterator over the variables.
|
Object |
getObject(String key)
Gets the value of a variable (not converted to String).
|
String |
getThreadName() |
void |
incIteration()
Increase the current number of iterations
|
boolean |
isSameUserOnNextIteration() |
void |
put(String key,
String value)
Creates or updates a variable with a String value.
|
void |
putAll(JMeterVariables vars)
Updates the variables with all entries found in the variables in
vars |
void |
putAll(Map<String,?> vars)
Updates the variables with all entries found in the
Map vars |
void |
putObject(String key,
Object value)
Creates or updates a variable with a value that does not have to be a String.
|
Object |
remove(String key)
Remove a variable.
|
public JMeterVariables()
public String getThreadName()
public int getIteration()
public void incIteration()
public Object remove(String key)
key
- the variable name to removenull
if there was no such variablepublic void put(String key, String value)
key
- the variable namevalue
- the variable valuepublic void putObject(String key, Object value)
key
- the variable namevalue
- the variable valuepublic void putAll(Map<String,?> vars)
Map
vars
vars
- map with the entries to be updatedpublic void putAll(JMeterVariables vars)
vars
vars
- JMeterVariables
with the entries to be updatedpublic String get(String key)
key
- the name of the variablenull
if it does not existpublic Object getObject(String key)
key
- the name of the variablenull
if it does not existpublic Iterator<Map.Entry<String,Object>> getIterator()
public Set<Map.Entry<String,Object>> entrySet()
JMeterVariables
public boolean isSameUserOnNextIteration()
Copyright © 1998-2019 Apache Software Foundation. All Rights Reserved.