|
Apache JMeter 1.9 |
|||||||||
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.config.ConfigTestElement | +--org.apache.jmeter.protocol.http.control.CookieManager
This class provides an interface to the netscape cookies file to pass cookies along with a request.
Nested Class Summary | |
static class |
CookieManager.Test
|
Field Summary | |
static String |
CLEAR
|
static String |
COOKIES
|
Fields inherited from class org.apache.jmeter.config.ConfigTestElement |
PASSWORD, USERNAME |
Fields inherited from class org.apache.jmeter.testelement.AbstractTestElement |
log |
Fields inherited from interface org.apache.jmeter.testelement.TestElement |
ENABLED, GUI_CLASS, NAME, TEST_CLASS |
Constructor Summary | |
CookieManager()
|
Method Summary | |
void |
add()
add an empty cookie |
void |
add(Cookie c)
add a cookie |
void |
addCookieFromHeader(String cookieHeader,
URL url)
|
void |
addFile(String cookieFile)
add cookie data from a file |
void |
clear()
Remove all the cookie |
long |
convertDateFormatStrToLong(String dateStr)
|
String |
convertLongToDateFormatStr(long dateLong)
|
Cookie |
get(int i)
return the cookie at index i |
String |
getClassLabel()
|
boolean |
getClearEachIteration()
|
Cookie |
getCookie(int row)
|
int |
getCookieCount()
|
String |
getCookieHeaderForURL(URL url)
|
CollectionProperty |
getCookies()
|
void |
recoverRunningVersion()
Tells the test element to return to the state it was in when makeRunningVersion() was called. |
void |
remove(int index)
remove a cookie |
void |
removeCookieNamed(String name)
|
void |
save(String authFile)
save the cookie data to a file |
void |
setClearEachIteration(boolean clear)
|
void |
setRunningVersion(boolean running)
Sets the runningVersion. |
int |
size()
return the number cookies |
String[] |
split(String splittee,
String splitChar,
String def)
Takes a String and a tokenizer character, and returns a new array of strings of the string split by the tokenizer character. |
void |
testEnded()
|
void |
testEnded(String host)
|
void |
testIterationStart(LoopIterationEvent event)
Each time through a Thread Group's test script, an iteration event is fired. |
void |
testStarted()
|
void |
testStarted(String host)
|
Methods inherited from class org.apache.jmeter.config.ConfigTestElement |
addTestElement |
Methods inherited from class org.apache.jmeter.testelement.AbstractTestElement |
addProperty, clone, equals, getName, getProperty, getPropertyAsBoolean, getPropertyAsDouble, getPropertyAsFloat, getPropertyAsInt, getPropertyAsLong, getPropertyAsString, isRunningVersion, logProperties, mergeIn, nextIsNull, propertyIterator, removeProperty, setName, setProperty, setProperty, traverse, traverseCollection, traverseMap, traverseProperty |
Methods inherited from class java.lang.Object |
finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final String CLEAR
public static final String COOKIES
Constructor Detail |
public CookieManager()
Method Detail |
public CollectionProperty getCookies()
public int getCookieCount()
public boolean getClearEachIteration()
public void setClearEachIteration(boolean clear)
public Cookie getCookie(int row)
public void save(String authFile) throws IOException
IOException
public void addFile(String cookieFile) throws IOException
IOException
public void recoverRunningVersion()
TestElement
recoverRunningVersion
in interface TestElement
recoverRunningVersion
in class AbstractTestElement
public void setRunningVersion(boolean running)
AbstractTestElement
setRunningVersion
in interface TestElement
setRunningVersion
in class AbstractTestElement
running
- the runningVersion to setpublic void add(Cookie c)
public void add()
public void clear()
clear
in interface TestElement
clear
in class AbstractTestElement
public void remove(int index)
public int size()
public Cookie get(int i)
public String convertLongToDateFormatStr(long dateLong)
public long convertDateFormatStrToLong(String dateStr)
public String getCookieHeaderForURL(URL url)
public void addCookieFromHeader(String cookieHeader, URL url)
public void removeCookieNamed(String name)
public String[] split(String splittee, String splitChar, String def)
splittee
- String to be splitsplitChar
- Character to split the string ondef
- Default value to place between two split chars that have
nothing between them
public String getClassLabel()
public void testStarted()
testStarted
in interface TestListener
public void testEnded()
testEnded
in interface TestListener
public void testStarted(String host)
testStarted
in interface TestListener
public void testEnded(String host)
testEnded
in interface TestListener
public void testIterationStart(LoopIterationEvent event)
TestListener
testIterationStart
in interface TestListener
event
-
|
Apache JMeter 1.9 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |