public class EyesAppiumUtils extends Object
| Modifier and Type | Field and Description |
|---|---|
static String |
NAVIGATION_BAR |
static String |
STATUS_BAR |
| Constructor and Description |
|---|
EyesAppiumUtils() |
| Modifier and Type | Method and Description |
|---|---|
static ContentSize |
getContentSize(io.appium.java_client.AppiumDriver driver,
org.openqa.selenium.WebElement element) |
static org.openqa.selenium.WebElement |
getFirstScrollableView(org.openqa.selenium.WebDriver driver) |
static org.openqa.selenium.WebElement |
getFirstVisibleChild(org.openqa.selenium.WebElement element) |
static String |
getHelperLibraryVersion(EyesAppiumDriver driver,
com.applitools.eyes.Logger logger) |
static LastScrollData |
getLastScrollData(io.appium.java_client.AppiumDriver driver) |
static Map<String,Integer> |
getSystemBarsHeights(EyesAppiumDriver driver) |
static boolean |
isLandscapeOrientation(com.applitools.eyes.Logger logger,
org.openqa.selenium.WebDriver driver) |
static BufferedImage |
normalizeRotation(com.applitools.eyes.Logger logger,
org.openqa.selenium.WebDriver driver,
BufferedImage image,
ImageRotation rotation)
Rotates the image as necessary.
|
static void |
scrollBackToElement(io.appium.java_client.android.AndroidDriver driver,
org.openqa.selenium.remote.RemoteWebElement scroller,
org.openqa.selenium.remote.RemoteWebElement scrollToEl) |
static void |
scrollByDirection(io.appium.java_client.AppiumDriver driver,
String direction) |
static void |
scrollByDirection(io.appium.java_client.AppiumDriver driver,
String direction,
double distanceRatio) |
static int |
tryAutomaticRotation(com.applitools.eyes.Logger logger,
org.openqa.selenium.WebDriver driver,
BufferedImage image) |
public static final String STATUS_BAR
public static final String NAVIGATION_BAR
public static org.openqa.selenium.WebElement getFirstScrollableView(org.openqa.selenium.WebDriver driver)
public static org.openqa.selenium.WebElement getFirstVisibleChild(org.openqa.selenium.WebElement element)
public static void scrollByDirection(io.appium.java_client.AppiumDriver driver,
String direction)
public static void scrollByDirection(io.appium.java_client.AppiumDriver driver,
String direction,
double distanceRatio)
public static void scrollBackToElement(io.appium.java_client.android.AndroidDriver driver,
org.openqa.selenium.remote.RemoteWebElement scroller,
org.openqa.selenium.remote.RemoteWebElement scrollToEl)
public static ContentSize getContentSize(io.appium.java_client.AppiumDriver driver, org.openqa.selenium.WebElement element)
@Nullable public static LastScrollData getLastScrollData(io.appium.java_client.AppiumDriver driver)
public static boolean isLandscapeOrientation(com.applitools.eyes.Logger logger,
org.openqa.selenium.WebDriver driver)
public static int tryAutomaticRotation(com.applitools.eyes.Logger logger,
org.openqa.selenium.WebDriver driver,
BufferedImage image)
public static BufferedImage normalizeRotation(com.applitools.eyes.Logger logger, org.openqa.selenium.WebDriver driver, BufferedImage image, ImageRotation rotation)
driver - The underlying driver which produced the screenshot.image - The image to normalize.rotation - The degrees by which to rotate the image:
positive values = clockwise rotation,
negative values = counter-clockwise,
0 = force no rotation,
null = rotate automatically as needed.public static Map<String,Integer> getSystemBarsHeights(EyesAppiumDriver driver)
public static String getHelperLibraryVersion(EyesAppiumDriver driver, com.applitools.eyes.Logger logger)
Copyright © 2022. All rights reserved.