类 DriverActions
- java.lang.Object
-
- tech.testnx.cah.common.browser.actions.DriverActions
-
- 所有已实现的接口:
OperateBrowser
@Experimental public class DriverActions extends Object implements OperateBrowser
- 作者:
- Yun
-
-
构造器概要
构造器 构造器 说明 DriverActions(org.openqa.selenium.WebDriver driver)
-
方法概要
所有方法 实例方法 具体方法 修饰符和类型 方法 说明 org.openqa.selenium.RectanglegetBrowserOuterRect()Location and size of entire browser(outer window)org.openqa.selenium.PointgetBrowserViewPortLocationOnScreenInBrowserMaxMode()Location and size of browser inner view port on screenorg.openqa.selenium.PointgetElementLocationOnPage(org.openqa.selenium.WebElement e)get element location absolute to the top and left corner of entire page by driverorg.openqa.selenium.RectanglegetElementRectOnScreenInBrowserFullScreenMode(org.openqa.selenium.WebElement e)Element location and dimension on screen and scrolling into view automatically in browser Full Screen modeorg.openqa.selenium.RectanglegetElementRectOnScreenInBrowserMaxMode(org.openqa.selenium.WebElement e)Element location and dimension on screen and scrolling into view automatically in browser normal max modebooleanrequestBrowserFullScreenMode()Request browser full screen mode by WebDriverorg.openqa.selenium.PointscrollIntoView(org.openqa.selenium.WebElement e)Scroll element into view port and return the relative location to the top-left corner of view port<X> XtakeFullDomPageScreenshot(org.openqa.selenium.OutputType<X> outputType)Take full DOM page screenshot for all browsers<X,Y>
Pair<X,Y>takeFullDomPageScreenshot(org.openqa.selenium.OutputType<X> outputTypeX, org.openqa.selenium.OutputType<Y> outputTypeY)Take full DOM page screenshot for all browsers<X> XtakeScreenshot(org.openqa.selenium.OutputType<X> outputType)Take default screenshot by WebDriver<X,Y>
Pair<X,Y>takeScreenshot(org.openqa.selenium.OutputType<X> outputTypeX, org.openqa.selenium.OutputType<Y> outputTypeY)Take default screenshot by WebDriver
-
-
-
方法详细资料
-
getBrowserOuterRect
public org.openqa.selenium.Rectangle getBrowserOuterRect()
Location and size of entire browser(outer window)
-
getBrowserViewPortLocationOnScreenInBrowserMaxMode
public org.openqa.selenium.Point getBrowserViewPortLocationOnScreenInBrowserMaxMode()
Location and size of browser inner view port on screen
-
scrollIntoView
public org.openqa.selenium.Point scrollIntoView(org.openqa.selenium.WebElement e)
Scroll element into view port and return the relative location to the top-left corner of view port
-
getElementLocationOnPage
public org.openqa.selenium.Point getElementLocationOnPage(org.openqa.selenium.WebElement e)
get element location absolute to the top and left corner of entire page by driver
-
getElementRectOnScreenInBrowserMaxMode
public org.openqa.selenium.Rectangle getElementRectOnScreenInBrowserMaxMode(org.openqa.selenium.WebElement e)
Element location and dimension on screen and scrolling into view automatically in browser normal max mode
-
getElementRectOnScreenInBrowserFullScreenMode
public org.openqa.selenium.Rectangle getElementRectOnScreenInBrowserFullScreenMode(org.openqa.selenium.WebElement e)
Element location and dimension on screen and scrolling into view automatically in browser Full Screen mode
-
requestBrowserFullScreenMode
public boolean requestBrowserFullScreenMode()
Request browser full screen mode by WebDriver
-
takeScreenshot
public <X> X takeScreenshot(org.openqa.selenium.OutputType<X> outputType)
Take default screenshot by WebDriver
-
takeScreenshot
public <X,Y> Pair<X,Y> takeScreenshot(org.openqa.selenium.OutputType<X> outputTypeX, org.openqa.selenium.OutputType<Y> outputTypeY)
Take default screenshot by WebDriver
-
takeFullDomPageScreenshot
public <X> X takeFullDomPageScreenshot(org.openqa.selenium.OutputType<X> outputType) throws IOExceptionTake full DOM page screenshot for all browsers- 抛出:
IOException
-
takeFullDomPageScreenshot
public <X,Y> Pair<X,Y> takeFullDomPageScreenshot(org.openqa.selenium.OutputType<X> outputTypeX, org.openqa.selenium.OutputType<Y> outputTypeY) throws IOException
Take full DOM page screenshot for all browsers- 抛出:
IOException
-
-