Class XPathExtractorWrapper
- java.lang.Object
-
- org.anasoid.jmc.core.wrapper.jmeter.testelement.basic.AbstractBasicTestElementWrapper<T>
-
- org.anasoid.jmc.core.wrapper.jmeter.testelement.basic.AbstractBasicChildTestElementWrapper<T>
-
- org.anasoid.jmc.core.wrapper.jmeter.testelement.AbstractScopedTestElementWrapper<org.apache.jmeter.extractor.XPathExtractor,org.apache.jmeter.extractor.gui.XPathExtractorGui>
-
- org.anasoid.jmc.core.wrapper.jmeter.extractor.XPathExtractorWrapper
-
- All Implemented Interfaces:
java.io.Serializable,Validator,JMeterGUIWrapper<org.apache.jmeter.extractor.gui.XPathExtractorGui>,PostProcessorWrapper<org.apache.jmeter.extractor.XPathExtractor>,TestElementTreeNodeWrapper<org.apache.jmeter.extractor.XPathExtractor>,TestElementWrapper<org.apache.jmeter.extractor.XPathExtractor>
@JmcDefaultName("XPath Extractor") public class XPathExtractorWrapper extends AbstractScopedTestElementWrapper<org.apache.jmeter.extractor.XPathExtractor,org.apache.jmeter.extractor.gui.XPathExtractorGui> implements PostProcessorWrapper<org.apache.jmeter.extractor.XPathExtractor>, Validator
Wrapper for XPathExtractor.- See Also:
XPathExtractor, Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classXPathExtractorWrapper.XPathExtractorWrapperBuilder<C extends XPathExtractorWrapper,B extends XPathExtractorWrapper.XPathExtractorWrapperBuilder<C,B>>-
Nested classes/interfaces inherited from class org.anasoid.jmc.core.wrapper.jmeter.testelement.AbstractScopedTestElementWrapper
AbstractScopedTestElementWrapper.AbstractScopedTestElementWrapperBuilder<T extends org.apache.jmeter.testelement.AbstractScopedTestElement,G extends org.apache.jmeter.gui.AbstractScopedJMeterGuiComponent,C extends AbstractScopedTestElementWrapper<T,G>,B extends AbstractScopedTestElementWrapper.AbstractScopedTestElementWrapperBuilder<T,G,C,B>>
-
Nested classes/interfaces inherited from class org.anasoid.jmc.core.wrapper.jmeter.testelement.basic.AbstractBasicChildTestElementWrapper
AbstractBasicChildTestElementWrapper.AbstractBasicChildTestElementWrapperBuilder<T extends org.apache.jmeter.testelement.AbstractTestElement,C extends AbstractBasicChildTestElementWrapper<T>,B extends AbstractBasicChildTestElementWrapper.AbstractBasicChildTestElementWrapperBuilder<T,C,B>>
-
Nested classes/interfaces inherited from class org.anasoid.jmc.core.wrapper.jmeter.testelement.basic.AbstractBasicTestElementWrapper
AbstractBasicTestElementWrapper.AbstractBasicTestElementWrapperBuilder<T extends org.apache.jmeter.testelement.AbstractTestElement,C extends AbstractBasicTestElementWrapper<T>,B extends AbstractBasicTestElementWrapper.AbstractBasicTestElementWrapperBuilder<T,C,B>>
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedXPathExtractorWrapper(XPathExtractorWrapper.XPathExtractorWrapperBuilder<?,?> b)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static XPathExtractorWrapper.XPathExtractorWrapperBuilder<?,?>builder()java.lang.StringgetDefaultValue()Default value returned when no match found.java.lang.Class<?>getGuiClass()Gui Test Class used by Jmeter TestElement.GUI_CLASS @See TestElementjava.lang.StringgetMatchNumber()If the XPath Path query leads to many results, you can choose which one(s) to extract as Variables:java.lang.StringgetRefName()The name of the JMeter variable in which to store the result.java.lang.Class<?>getTestClass()Test Class used by Jmeter TestElement.TEST_CLASS.java.lang.StringgetXpathQuery()Element query in XPath language.booleanisDownloadDtds()If selected, external DTDs are fetched.booleanisFragment()If selected, the fragment will be returned rather than the text content.booleanisNamespace()If checked, then the XML parser will use namespace resolution.(see note below on NAMESPACES) Note that currently only namespaces declared on the root element will be recognised.booleanisTidyQuiet()Sets the Tidy Quiet flag.booleanisTidyReportErrors()If a Tidy error occurs, then set the Assertion accordingly.booleanisTidyShowWarnings()Sets the Tidy showWarnings option.booleanisUseTidy()If checked use Tidy to parse HTML response into XHTML.booleanisValidate()Check the document against its schema.booleanisWhitespace()Ignore Element Whitespace.voidsetDefaultValue(java.lang.String defaultValue)Default value returned when no match found.voidsetDownloadDtds(boolean downloadDtds)If selected, external DTDs are fetched.voidsetFragment(boolean fragment)If selected, the fragment will be returned rather than the text content.voidsetMatchNumber(java.lang.String matchNumber)If the XPath Path query leads to many results, you can choose which one(s) to extract as Variables:voidsetNamespace(boolean namespace)If checked, then the XML parser will use namespace resolution.(see note below on NAMESPACES) Note that currently only namespaces declared on the root element will be recognised.voidsetRefName(java.lang.String refName)The name of the JMeter variable in which to store the result.voidsetTidyQuiet(boolean tidyQuiet)Sets the Tidy Quiet flag.voidsetTidyReportErrors(boolean tidyReportErrors)If a Tidy error occurs, then set the Assertion accordingly.voidsetTidyShowWarnings(boolean tidyShowWarnings)Sets the Tidy showWarnings option.voidsetUseTidy(boolean useTidy)If checked use Tidy to parse HTML response into XHTML.voidsetValidate(boolean validate)Check the document against its schema.voidsetWhitespace(boolean whitespace)Ignore Element Whitespace.voidsetXpathQuery(java.lang.String xpathQuery)Element query in XPath language.XPathExtractorWrapper.XPathExtractorWrapperBuilder<?,?>toBuilder()voidvalidate()Validate Test element.-
Methods inherited from class org.anasoid.jmc.core.wrapper.jmeter.testelement.AbstractScopedTestElementWrapper
getScope, getScopeVariable, setScope
-
Methods inherited from class org.anasoid.jmc.core.wrapper.jmeter.testelement.basic.AbstractBasicChildTestElementWrapper
getComment, getName, isEnabled, setComment, setEnabled, setName
-
Methods inherited from class org.anasoid.jmc.core.wrapper.jmeter.testelement.basic.AbstractBasicTestElementWrapper
getChilds, getGuiClassAsString, getTags, getTestClassAsString, init, internalInit, isFullClassName
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.anasoid.jmc.core.wrapper.jmeter.testelement.TestElementWrapper
getChilds, getTags, getTestClassAsString, init
-
-
-
-
Constructor Detail
-
XPathExtractorWrapper
protected XPathExtractorWrapper(XPathExtractorWrapper.XPathExtractorWrapperBuilder<?,?> b)
-
-
Method Detail
-
getGuiClass
public java.lang.Class<?> getGuiClass()
Description copied from interface:JMeterGUIWrapperGui Test Class used by Jmeter TestElement.GUI_CLASS @See TestElement- Specified by:
getGuiClassin interfaceJMeterGUIWrapper<org.apache.jmeter.extractor.gui.XPathExtractorGui>
-
getTestClass
public java.lang.Class<?> getTestClass()
Description copied from interface:TestElementWrapperTest Class used by Jmeter TestElement.TEST_CLASS. @See TestElement.- Specified by:
getTestClassin interfaceTestElementWrapper<org.apache.jmeter.extractor.XPathExtractor>
-
validate
public void validate() throws ConversionIllegalStateExceptionDescription copied from interface:ValidatorValidate Test element.- Specified by:
validatein interfaceValidator- Throws:
ConversionIllegalStateException
-
builder
public static XPathExtractorWrapper.XPathExtractorWrapperBuilder<?,?> builder()
-
toBuilder
public XPathExtractorWrapper.XPathExtractorWrapperBuilder<?,?> toBuilder()
-
getRefName
public java.lang.String getRefName()
The name of the JMeter variable in which to store the result.
-
setRefName
public void setRefName(java.lang.String refName)
The name of the JMeter variable in which to store the result.
-
getXpathQuery
public java.lang.String getXpathQuery()
Element query in XPath language. Can return more than one match.
-
setXpathQuery
public void setXpathQuery(java.lang.String xpathQuery)
Element query in XPath language. Can return more than one match.
-
getMatchNumber
public java.lang.String getMatchNumber()
If the XPath Path query leads to many results, you can choose which one(s) to extract as Variables:0: means random -1 means extract all results (default value), they will be named as <variable name>_N (where N goes from 1 to Number of results) X: means extract the Xth result. If this Xth is greater than number of matches, then nothing is returned. Default value will be used
-
setMatchNumber
public void setMatchNumber(java.lang.String matchNumber)
If the XPath Path query leads to many results, you can choose which one(s) to extract as Variables:0: means random -1 means extract all results (default value), they will be named as <variable name>_N (where N goes from 1 to Number of results) X: means extract the Xth result. If this Xth is greater than number of matches, then nothing is returned. Default value will be used
-
getDefaultValue
public java.lang.String getDefaultValue()
Default value returned when no match found. It is also returned if the node has no value and the fragment option is not selected.
-
setDefaultValue
public void setDefaultValue(java.lang.String defaultValue)
Default value returned when no match found. It is also returned if the node has no value and the fragment option is not selected.
-
isFragment
public boolean isFragment()
If selected, the fragment will be returned rather than the text content. For example //title would return "<title>Apache JMeter</title>" rather than "Apache JMeter". In this case, //title/text() would return "Apache JMeter".
-
setFragment
public void setFragment(boolean fragment)
If selected, the fragment will be returned rather than the text content. For example //title would return "<title>Apache JMeter</title>" rather than "Apache JMeter". In this case, //title/text() would return "Apache JMeter".
-
isValidate
public boolean isValidate()
Check the document against its schema. (If Tidy is not selected).
-
setValidate
public void setValidate(boolean validate)
Check the document against its schema. (If Tidy is not selected).
-
isNamespace
public boolean isNamespace()
If checked, then the XML parser will use namespace resolution.(see note below on NAMESPACES) Note that currently only namespaces declared on the root element will be recognised. See below for user-definition of additional workspace names. (If Tidy is not selected).
-
setNamespace
public void setNamespace(boolean namespace)
If checked, then the XML parser will use namespace resolution.(see note below on NAMESPACES) Note that currently only namespaces declared on the root element will be recognised. See below for user-definition of additional workspace names. (If Tidy is not selected).
-
isWhitespace
public boolean isWhitespace()
Ignore Element Whitespace. (If Tidy is not selected).
-
setWhitespace
public void setWhitespace(boolean whitespace)
Ignore Element Whitespace. (If Tidy is not selected).
-
isDownloadDtds
public boolean isDownloadDtds()
If selected, external DTDs are fetched. (If Tidy is not selected).
-
setDownloadDtds
public void setDownloadDtds(boolean downloadDtds)
If selected, external DTDs are fetched. (If Tidy is not selected).
-
isUseTidy
public boolean isUseTidy()
If checked use Tidy to parse HTML response into XHTML."Use Tidy" should be checked on for HTML response. Such response is converted to valid XHTML (XML compatible HTML) using Tidy "Use Tidy" should be unchecked for both XHTML or XML response (for example RSS)
-
setUseTidy
public void setUseTidy(boolean useTidy)
If checked use Tidy to parse HTML response into XHTML."Use Tidy" should be checked on for HTML response. Such response is converted to valid XHTML (XML compatible HTML) using Tidy "Use Tidy" should be unchecked for both XHTML or XML response (for example RSS)
-
isTidyQuiet
public boolean isTidyQuiet()
Sets the Tidy Quiet flag.
-
setTidyQuiet
public void setTidyQuiet(boolean tidyQuiet)
Sets the Tidy Quiet flag.
-
isTidyReportErrors
public boolean isTidyReportErrors()
If a Tidy error occurs, then set the Assertion accordingly.
-
setTidyReportErrors
public void setTidyReportErrors(boolean tidyReportErrors)
If a Tidy error occurs, then set the Assertion accordingly.
-
isTidyShowWarnings
public boolean isTidyShowWarnings()
Sets the Tidy showWarnings option.
-
setTidyShowWarnings
public void setTidyShowWarnings(boolean tidyShowWarnings)
Sets the Tidy showWarnings option.
-
-