io.selendroid.server.model
Class DefaultSelendroidDriver
java.lang.Object
io.selendroid.server.model.DefaultSelendroidDriver
- All Implemented Interfaces:
- SelendroidDriver
public class DefaultSelendroidDriver
- extends Object
- implements SelendroidDriver
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
BROWSER_NAME
public static final String BROWSER_NAME
- See Also:
- Constant Field Values
PLATFORM
public static final String PLATFORM
- See Also:
- Constant Field Values
SUPPORTS_JAVASCRIPT
public static final String SUPPORTS_JAVASCRIPT
- See Also:
- Constant Field Values
TAKES_SCREENSHOT
public static final String TAKES_SCREENSHOT
- See Also:
- Constant Field Values
VERSION
public static final String VERSION
- See Also:
- Constant Field Values
SUPPORTS_ALERTS
public static final String SUPPORTS_ALERTS
- See Also:
- Constant Field Values
ROTATABLE
public static final String ROTATABLE
- See Also:
- Constant Field Values
ACCEPT_SSL_CERTS
public static final String ACCEPT_SSL_CERTS
- See Also:
- Constant Field Values
SUPPORTS_NETWORK_CONNECTION
public static final String SUPPORTS_NETWORK_CONNECTION
- See Also:
- Constant Field Values
DefaultSelendroidDriver
public DefaultSelendroidDriver(ServerInstrumentation instrumentation)
findElement
public AndroidElement findElement(By by)
- Specified by:
findElement in interface SelendroidDriver
findElements
public List<AndroidElement> findElements(By by)
- Specified by:
findElements in interface SelendroidDriver
getSession
public Session getSession()
- Specified by:
getSession in interface SelendroidDriver
getSessionCapabilities
public org.json.JSONObject getSessionCapabilities(String sessionId)
- Specified by:
getSessionCapabilities in interface SelendroidDriver
sleepQuietly
public static void sleepQuietly(long ms)
stopSession
public void stopSession()
- Specified by:
stopSession in interface SelendroidDriver
takeScreenshot
public byte[] takeScreenshot()
- Specified by:
takeScreenshot in interface SelendroidDriver
switchContext
public void switchContext(String type)
- Specified by:
switchContext in interface SelendroidDriver
initializeSession
public String initializeSession(org.json.JSONObject desiredCapabilities)
- Specified by:
initializeSession in interface SelendroidDriver
getKeyboard
public Keyboard getKeyboard()
- Specified by:
getKeyboard in interface SelendroidDriver
getTouch
public TouchScreen getTouch()
- Specified by:
getTouch in interface SelendroidDriver
getCurrentUrl
public String getCurrentUrl()
- Specified by:
getCurrentUrl in interface SelendroidDriver
getWindowSource
public String getWindowSource()
- Specified by:
getWindowSource in interface SelendroidDriver
getFullWindowTree
public org.json.JSONObject getFullWindowTree()
- Specified by:
getFullWindowTree in interface SelendroidDriver
getTitle
public String getTitle()
- Specified by:
getTitle in interface SelendroidDriver
get
public void get(String url)
- Specified by:
get in interface SelendroidDriver
getOrientation
public ScreenOrientation getOrientation()
- Specified by:
getOrientation in interface SelendroidDriver
rotate
public void rotate(ScreenOrientation orientation)
- Specified by:
rotate in interface SelendroidDriver
isNativeWindowMode
public boolean isNativeWindowMode()
executeScript
public Object executeScript(String script,
org.json.JSONArray args)
- Specified by:
executeScript in interface SelendroidDriver
executeScript
public Object executeScript(String script,
Object... args)
- Specified by:
executeScript in interface SelendroidDriver
executeAsyncScript
public Object executeAsyncScript(String script,
org.json.JSONArray args)
- Specified by:
executeAsyncScript in interface SelendroidDriver
getContext
public String getContext()
- Specified by:
getContext in interface SelendroidDriver
getWindowSize
public Dimension getWindowSize()
- Specified by:
getWindowSize in interface SelendroidDriver
getContexts
public Set<String> getContexts()
- Specified by:
getContexts in interface SelendroidDriver
addCookie
public void addCookie(String url,
Cookie cookie)
- Specified by:
addCookie in interface SelendroidDriver
getCookies
public Set<Cookie> getCookies(String url)
- Specified by:
getCookies in interface SelendroidDriver
deleteCookie
public void deleteCookie(String url)
- Specified by:
deleteCookie in interface SelendroidDriver
deleteNamedCookie
public void deleteNamedCookie(String url,
String name)
- Specified by:
deleteNamedCookie in interface SelendroidDriver
setFrameContext
public void setFrameContext(Object obj)
throws org.json.JSONException
- Specified by:
setFrameContext in interface SelendroidDriver
- Throws:
org.json.JSONException
back
public void back()
- Specified by:
back in interface SelendroidDriver
forward
public void forward()
- Specified by:
forward in interface SelendroidDriver
refresh
public void refresh()
- Specified by:
refresh in interface SelendroidDriver
isAlertPresent
public boolean isAlertPresent()
- Specified by:
isAlertPresent in interface SelendroidDriver
getAlertText
public String getAlertText()
- Specified by:
getAlertText in interface SelendroidDriver
acceptAlert
public void acceptAlert()
- Specified by:
acceptAlert in interface SelendroidDriver
dismissAlert
public void dismissAlert()
- Specified by:
dismissAlert in interface SelendroidDriver
setAlertText
public void setAlertText(CharSequence... keysToSend)
- Specified by:
setAlertText in interface SelendroidDriver
setAsyncTimeout
public void setAsyncTimeout(long timeout)
- Specified by:
setAsyncTimeout in interface SelendroidDriver
isAirplaneMode
public boolean isAirplaneMode()
- Specified by:
isAirplaneMode in interface SelendroidDriver
Copyright © 2014. All rights reserved.