public class RegexExtractor extends AbstractScopedTestElement implements PostProcessor, Serializable
Modifier and Type | Field and Description |
---|---|
static String |
USE_BODY |
static String |
USE_BODY_UNESCAPED |
static String |
USE_CODE |
static String |
USE_HDRS |
static String |
USE_MESSAGE |
static String |
USE_URL |
COMMENTS, ENABLED, GUI_CLASS, NAME, TEST_CLASS
Constructor and Description |
---|
RegexExtractor() |
Modifier and Type | Method and Description |
---|---|
String |
getDefaultValue() |
int |
getMatchNumber() |
String |
getMatchNumberAsString() |
String |
getRefName() |
String |
getRegex() |
String |
getTemplate() |
void |
process()
Parses the response data using regular expressions and saving the results
into variables for use later in the test.
|
void |
setDefaultValue(String defaultValue)
Sets the value of the variable if no matches are found
|
void |
setMatchNumber(int matchNumber)
Set which Match to use.
|
void |
setMatchNumber(String matchNumber) |
void |
setRefName(String refName) |
void |
setRegex(String regex) |
void |
setTemplate(String template) |
void |
setUseField(String actionCommand) |
boolean |
useBody() |
boolean |
useCode() |
boolean |
useHeaders() |
boolean |
useMessage() |
boolean |
useUnescapedBody() |
boolean |
useUrl() |
fetchScope, getSampleList, getScopeName, getVariableName, isScopeAll, isScopeChildren, isScopeParent, isScopeVariable, isScopeVariable, setScopeAll, setScopeChildren, setScopeParent, setScopeVariable
addProperty, addTestElement, canRemove, clear, clearTemporary, clearTestElementChildren, clone, emptyTemporary, equals, getComment, getName, getProperty, getPropertyAsBoolean, getPropertyAsBoolean, getPropertyAsDouble, getPropertyAsFloat, getPropertyAsInt, getPropertyAsInt, getPropertyAsLong, getPropertyAsLong, getPropertyAsString, getPropertyAsString, getThreadContext, getThreadName, hashCode, isEnabled, isRunningVersion, isTemporary, logProperties, mergeIn, propertyIterator, recoverRunningVersion, removeProperty, setComment, setName, setProperty, setProperty, setProperty, setProperty, setProperty, setProperty, setProperty, setRunningVersion, setTemporary, setThreadContext, setThreadName, traverse, traverseCollection, traverseMap, traverseProperty
public static final String USE_HDRS
public static final String USE_BODY
public static final String USE_BODY_UNESCAPED
public static final String USE_URL
public static final String USE_CODE
public static final String USE_MESSAGE
public void process()
process
in interface PostProcessor
PostProcessor.process()
public void setRegex(String regex)
public String getRegex()
public void setRefName(String refName)
public String getRefName()
public void setMatchNumber(int matchNumber)
matchNumber
- public void setMatchNumber(String matchNumber)
public int getMatchNumber()
public String getMatchNumberAsString()
public void setDefaultValue(String defaultValue)
defaultValue
- public String getDefaultValue()
public void setTemplate(String template)
public String getTemplate()
public boolean useHeaders()
public boolean useBody()
public boolean useUnescapedBody()
public boolean useUrl()
public boolean useCode()
public boolean useMessage()
public void setUseField(String actionCommand)
Copyright © 1998-2012 Apache Software Foundation. All Rights Reserved.