Package org.openqa.selenium.mobile
Interface NetworkConnection
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
Nested ClassesModifier and TypeInterfaceDescriptionstatic classDeprecated.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.ConnectionTypeindicating 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.ConnectionTypeof what the device's network connection is
-