Defines a criterion based on an XPath for HTML screen classes.

The XPath criterion allows defining an XPath expression leading to one or several elements of a web page that uniquely identify a given screen class (logo, image, link, field, etc.).
Matching condition: The XPath criterion matches when the evaluation of the Xpath expression, defined in XPath property, on the HTML page’s DOM gives a non-empty result.
Note: The XPath criterion, together with the URL criterion, are the two only possible criteria for detecting a screen class in CWC and CWI projects.

Property Type Category Description
Comment String standard Describes the object comment to include in the documentation report.
This property generally contains an explanation about the object.
XPath String standard Defines the XPath expression of searched nodes.
The execution of this XPath on the web page DOM can result in a single Node or a NodeList. In these cases, the criterion matches.
The execution of the XPath on the web page DOM can result in an empty result. In this case, the criterion doesn’t match.
Reverse result boolean expert Defines if the criteria’s result should be reversed.
When a criteria is evaluated, it can sometimes be useful to get the opposite of the standard result (i.e. when the criteria matches, its result is false, and when it doesn’t match, its result is true). Use this property to reverse the standard result.
For example, you may define a screen class that does not contain the text “Hello” in white on black background. For that, you define a criterion matching on the text “Hello” in white on black background, and you reverse it thanks to this property.