|
Apache JMeter | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.jmeter.testelement.AbstractTestElement org.apache.jmeter.util.ScriptingTestElement org.apache.jmeter.util.JSR223TestElement
public abstract class JSR223TestElement
Field Summary |
---|
Fields inherited from class org.apache.jmeter.util.ScriptingTestElement |
---|
scriptLanguage |
Fields inherited from interface org.apache.jmeter.testelement.TestElement |
---|
COMMENTS, ENABLED, GUI_CLASS, NAME, TEST_CLASS |
Constructor Summary | |
---|---|
JSR223TestElement()
|
Method Summary | |
---|---|
String |
getCacheKey()
|
static ScriptEngineManager |
getInstance()
|
protected ScriptEngine |
getScriptEngine()
|
String |
getScriptLanguage()
|
protected void |
populateBindings(Bindings bindings)
Populate variables to be passed to scripts |
protected Object |
processFileOrScript(ScriptEngine scriptEngine,
Bindings bindings)
This method will run inline script or file script with special behaviour for file script: - If ScriptEngine implements Compilable script will be compiled and cached - If not if will be run |
void |
setCacheKey(String cacheKey)
|
void |
setScriptLanguage(String s)
|
void |
testEnded()
Called once for all threads after the end of a test. |
void |
testEnded(String host)
Called once for all threads after the end of a test. |
void |
testStarted()
Called just before the start of the test from the main engine thread. |
void |
testStarted(String host)
Called just before the start of the test from the main engine thread. |
Methods inherited from class org.apache.jmeter.util.ScriptingTestElement |
---|
getFilename, getParameters, getScript, setFilename, setParameters, setScript |
Methods inherited from class java.lang.Object |
---|
finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public JSR223TestElement()
Method Detail |
---|
public static ScriptEngineManager getInstance()
protected ScriptEngine getScriptEngine() throws ScriptException
ScriptException
protected void populateBindings(Bindings bindings)
bindings
- Bindingsprotected Object processFileOrScript(ScriptEngine scriptEngine, Bindings bindings) throws IOException, ScriptException
scriptEngine
- ScriptEnginebindings
- Bindings
might be null
IOException
ScriptException
public String getCacheKey()
public void setCacheKey(String cacheKey)
cacheKey
- the cacheKey to setpublic void testStarted()
TestStateListener
Called just before the start of the test from the main engine thread. This is before the test elements are cloned. Note that not all the test variables will have been set up at this point.
N.B. testStarted() and testEnded() are called from different threads.
testStarted
in interface TestStateListener
TestStateListener.testStarted()
public void testStarted(String host)
TestStateListener
Called just before the start of the test from the main engine thread. This is before the test elements are cloned. Note that not all the test variables will have been set up at this point.
N.B. testStarted() and testEnded() are called from different threads.
testStarted
in interface TestStateListener
host
- name of hostTestStateListener.testStarted(java.lang.String)
public void testEnded()
TestStateListener
Called once for all threads after the end of a test. This will use the same element instances as at the start of the test.
N.B. testStarted() and testEnded() are called from different threads.
testEnded
in interface TestStateListener
TestStateListener.testEnded()
public void testEnded(String host)
TestStateListener
Called once for all threads after the end of a test. This will use the same element instances as at the start of the test.
N.B. testStarted() and testEnded() are called from different threads.
testEnded
in interface TestStateListener
host
- name of hostTestStateListener.testEnded(java.lang.String)
public String getScriptLanguage()
public void setScriptLanguage(String s)
|
Apache JMeter | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |