Package ai.devtools.utils
Class MatchUtils
- java.lang.Object
-
- ai.devtools.utils.MatchUtils
-
public class MatchUtils extends Object
Static methods for matching bounding boxes to underlying Selenium elements.
-
-
Constructor Summary
Constructors Constructor Description MatchUtils()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static WebElementmatchBoundingBoxToSeleniumElement(com.google.gson.JsonObject boundingBox, SmartDriver driver)Matches a bounding box returned by the dev-tools.ai API to a selenium WebElement on the current page.static WebElementmatchBoundingBoxToSeleniumElementJS(com.google.gson.JsonObject boundingBox, SmartDriver driver)
-
-
-
Method Detail
-
matchBoundingBoxToSeleniumElementJS
public static WebElement matchBoundingBoxToSeleniumElementJS(com.google.gson.JsonObject boundingBox, SmartDriver driver)
-
matchBoundingBoxToSeleniumElement
public static WebElement matchBoundingBoxToSeleniumElement(com.google.gson.JsonObject boundingBox, SmartDriver driver)
Matches a bounding box returned by the dev-tools.ai API to a selenium WebElement on the current page.- Parameters:
boundingBox- The json representing the element returned by the dev-tools.ai API.driver- TheSmartDriverto use- Returns:
- The best-matching, underlying
WebElementwhich best fits the parameters specified byboudingBox
-
-