Method from org.apache.jmeter.testelement.TestPlan Detail: |
public void addConfigElement(ConfigElement c) {
configs.add(c);
}
Adds a feature to the ConfigElement attribute of the TestPlan object. |
public void addJMeterComponent(TestElement child) {
if (child instanceof ThreadGroup) {
addThreadGroup((ThreadGroup) child);
}
}
|
public void addParameter(String name,
String value) {
getVariables().addArgument(name, value);
}
|
public void addTestElement(TestElement tg) {
super.addTestElement(tg);
if (tg instanceof ThreadGroup && !isRunningVersion()) {
addThreadGroup((ThreadGroup) tg);
}
}
|
public void addThreadGroup(ThreadGroup group) {
threadGroups.add(group);
}
Adds a feature to the ThreadGroup attribute of the TestPlan object. |
public static TestPlan createTestPlan(String name) {
if (plan == null) {
if (name == null) {
plan = new TestPlan();
} else {
plan = new TestPlan(name);
}
plan.setProperty(new StringProperty(TestElement.GUI_CLASS, "org.apache.jmeter.control.gui.TestPlanGui"));
}
return plan;
}
|
public String getBasedir() {
return getPropertyAsString(BASEDIR);
}
|
public static boolean getFunctionalMode() {
return functionalMode;
}
Gets the static copy of the functional mode |
public String getTestPlanClasspath() {
return getPropertyAsString(CLASSPATHS);
}
Returns a string in CSV format |
public String[] getTestPlanClasspathArray() {
return JOrphanUtils.split(this.getTestPlanClasspath(),CLASSPATH_SEPARATOR);
}
|
public Collection getThreadGroups() {
return threadGroups;
}
Gets the ThreadGroups attribute of the TestPlan object. |
public Map getUserDefinedVariables() {
Arguments args = getVariables();
return args.getArgumentsAsMap();
}
|
public boolean isFunctionalMode() {
return getPropertyAsBoolean(FUNCTIONAL_MODE);
}
Fetches the functional mode property |
public boolean isSerialized() {
return getPropertyAsBoolean(SERIALIZE_THREADGROUPS);
}
Fetch the serialize threadgroups property |
public void prepareForPreCompile() {
getVariables().setRunningVersion(true);
}
|
public void setBasedir(String b) {
setProperty(BASEDIR, b);
}
|
public void setFunctionalMode(boolean funcMode) {
setProperty(new BooleanProperty(FUNCTIONAL_MODE, funcMode));
functionalMode = funcMode;
}
|
public void setSerialized(boolean serializeTGs) {
setProperty(new BooleanProperty(SERIALIZE_THREADGROUPS, serializeTGs));
}
|
public void setTestPlanClasspath(String text) {
setProperty(CLASSPATHS,text);
}
Set the classpath for the test plan |
public void setTestPlanClasspathArray(String[] text) {
StringBuffer cat = new StringBuffer();
for (int idx=0; idx < text.length; idx++) {
if (idx > 0) {
cat.append(CLASSPATH_SEPARATOR);
}
cat.append(text[idx]);
}
this.setTestPlanClasspath(cat.toString());
}
|
public void setUserDefinedVariables(Arguments vars) {
setProperty(new TestElementProperty(USER_DEFINED_VARIABLES, vars));
}
|
public void testEnded() {
try {
FileServer.getFileServer().closeFiles();
} catch (IOException e) {
log.error("Problem closing files at end of test", e);
}
}
|
public void testEnded(String host) {
testEnded();
}
|
public void testIterationStart(LoopIterationEvent event) {
}
|
public void testStarted() {
if (getBasedir() != null && getBasedir().length() > 0) {
try {
FileServer.getFileServer().setBasedir(FileServer.getFileServer().getBaseDir() + getBasedir());
} catch (IOException e) {
log.error("Failed to set file server base dir with " + getBasedir(), e);
}
}
// we set the classpath
String[] paths = this.getTestPlanClasspathArray();
for (int idx=0; idx < paths.length; idx++) {
NewDriver.addURL(paths[idx]);
log.info("add " + paths[idx] + " to classpath");
}
}
|
public void testStarted(String host) {
testStarted();
}
|