Package org.openqa.selenium.mobile
Interface NetworkConnection
- All Known Implementing Classes:
ChromeDriver
,ChromiumDriver
,EdgeDriver
,RemoteNetworkConnection
Deprecated.
Control a device's network connection
Example usage:
NetworkConnection mobileDriver = (NetworkConnection) driver; if (mobileDriver.getNetworkConnection() != ConnectionType.AIRPLANE_MODE) { // enabling Airplane mode mobileDriver.setNetworkConnection(ConnectionType.AIRPLANE_MODE); }
-
Nested Class Summary
Modifier and TypeInterfaceDescriptionstatic class
Deprecated.ConnectionType is a bitmask to represent a device's network connection -
Method Summary
Modifier and TypeMethodDescriptionDeprecated.Query the driver for the Airplane Mode setting stateDeprecated.Set the Connection type Not all connection type combinations are valid for an individual type of device and the remote endpoint will make a best effort to set the type as requested
-
Method Details
-
getNetworkConnection
NetworkConnection.ConnectionType getNetworkConnection()Deprecated.Query the driver for the Airplane Mode setting state- Returns:
NetworkConnection.ConnectionType
indicating if the device is in Airplane Mode
-
setNetworkConnection
Deprecated.Set the Connection type Not all connection type combinations are valid for an individual type of device and the remote endpoint will make a best effort to set the type as requested- Parameters:
type
- ConnectionType of what the network connection should be- Returns:
NetworkConnection.ConnectionType
of what the device's network connection is
-