Package org.openqa.selenium.support.ui
Class Quotes
java.lang.Object
org.openqa.selenium.support.ui.Quotes
-
Constructor Summary
-
Method Summary
-
Constructor Details
-
Quotes
public Quotes()
-
-
Method Details
-
escape
Convert strings with both quotes and ticks into a valid xpath componentFor example,
foo
will be converted to"foo"
,f"oo
will be converted to'f"oo'
,foo'"bar
will be converted toconcat("foo'", '"', "bar")
- Parameters:
toEscape
- a text to escape quotes in, e.g."f'oo"
- Returns:
- the same text with escaped quoted, e.g.
"\"f'oo\""
-