@Deprecated public class AndroidDriver extends RemoteWebDriver implements TakesScreenshot, Rotatable, BrowserConnection, HasTouchScreen, WebStorage, LocationContext, ApplicationCache
RemoteWebDriver.RemoteTargetLocator, RemoteWebDriver.RemoteWebDriverOptions, RemoteWebDriver.When
WebDriver.ImeHandler, WebDriver.Navigation, WebDriver.Options, WebDriver.TargetLocator, WebDriver.Timeouts, WebDriver.Window
Constructor and Description |
---|
AndroidDriver()
Deprecated.
The default constructor assumes the remote server is listening at http://localhost:8080/wd/hub
|
AndroidDriver(Capabilities ignored)
Deprecated.
|
AndroidDriver(DesiredCapabilities caps)
Deprecated.
|
AndroidDriver(java.lang.String remoteAddress)
Deprecated.
|
AndroidDriver(java.net.URL remoteAddress)
Deprecated.
|
AndroidDriver(java.net.URL url,
DesiredCapabilities caps)
Deprecated.
|
Modifier and Type | Method and Description |
---|---|
LocalStorage |
getLocalStorage()
Deprecated.
|
ScreenOrientation |
getOrientation()
Deprecated.
|
<X> X |
getScreenshotAs(OutputType<X> target)
Deprecated.
Capture the screenshot and store it in the specified location.
|
SessionStorage |
getSessionStorage()
Deprecated.
|
AppCacheStatus |
getStatus()
Deprecated.
The current state of the application cache.
|
TouchScreen |
getTouch()
Deprecated.
|
boolean |
isOnline()
Deprecated.
|
Location |
location()
Deprecated.
Gets the physical location of the browser.
|
void |
rotate(ScreenOrientation orientation)
Deprecated.
Changes the orientation of the browser window.
|
void |
setFileDetector(FileDetector detector)
Deprecated.
Set the file detector to be used when sending keyboard input.
|
void |
setLocation(Location loc)
Deprecated.
Sets the physical location.
|
void |
setOnline(boolean online)
Deprecated.
Changes the application online state.
|
close, execute, execute, executeAsyncScript, executeScript, findElement, findElement, findElementByClassName, findElementByCssSelector, findElementById, findElementByLinkText, findElementByName, findElementByPartialLinkText, findElementByTagName, findElementByXPath, findElements, findElements, findElementsByClassName, findElementsByCssSelector, findElementsById, findElementsByLinkText, findElementsByName, findElementsByPartialLinkText, findElementsByTagName, findElementsByXPath, get, getCapabilities, getCommandExecutor, getCurrentUrl, getElementConverter, getErrorHandler, getExecuteMethod, getFileDetector, getKeyboard, getMouse, getPageSource, getRemoteStatus, getSessionId, getTitle, getWindowHandle, getWindowHandles, log, manage, navigate, quit, setCommandExecutor, setElementConverter, setFoundBy, setLogLevel, setSessionId, startClient, startSession, startSession, stopClient, switchTo, toString
public AndroidDriver()
public AndroidDriver(Capabilities ignored)
public AndroidDriver(java.lang.String remoteAddress) throws java.net.MalformedURLException
java.net.MalformedURLException
public AndroidDriver(DesiredCapabilities caps)
public AndroidDriver(java.net.URL remoteAddress)
public AndroidDriver(java.net.URL url, DesiredCapabilities caps)
public void setFileDetector(FileDetector detector)
RemoteWebDriver
setFileDetector
in class RemoteWebDriver
detector
- The detector to use. Must not be null.FileDetector
,
LocalFileDetector
,
UselessFileDetector
public <X> X getScreenshotAs(OutputType<X> target) throws WebDriverException
TakesScreenshot
For WebDriver extending TakesScreenshot, this makes a best effort depending on the browser to return the following in order of preference:
For WebElement extending TakesScreenshot, this makes a best effort depending on the browser to return the following in order of preference: - The entire content of the HTML element - The visisble portion of the HTML element
getScreenshotAs
in interface TakesScreenshot
X
- Return type for getScreenshotAs.target
- target type, @see OutputTypeWebDriverException
- on failure.public boolean isOnline()
isOnline
in interface BrowserConnection
public void setOnline(boolean online) throws WebDriverException
BrowserConnection
setOnline
in interface BrowserConnection
online
- A boolean representing the stateWebDriverException
public void rotate(ScreenOrientation orientation)
Rotatable
public ScreenOrientation getOrientation()
getOrientation
in interface Rotatable
public TouchScreen getTouch()
getTouch
in interface HasTouchScreen
public LocalStorage getLocalStorage()
getLocalStorage
in interface WebStorage
public SessionStorage getSessionStorage()
getSessionStorage
in interface WebStorage
public Location location()
LocationContext
location
in interface LocationContext
Location
containing the location information. Returns null if the location is
not availablepublic void setLocation(Location loc)
LocationContext
setLocation
in interface LocationContext
loc
- A Location
containing the new location informationpublic AppCacheStatus getStatus()
ApplicationCache
getStatus
in interface ApplicationCache
AppCacheStatus