Module: Selenium::WebDriver::DriverExtensions::HasNetworkConnection Private

Defined in:
lib/selenium/webdriver/common/driver_extensions/has_network_connection.rb

This module is part of a private API. You should avoid using this module if possible, as it may be removed or be changed in the future.

Instance Method Summary collapse

Instance Method Details

#network_connection_typeObject

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



24
25
26
27
28
29
30
31
32
# File 'lib/selenium/webdriver/common/driver_extensions/has_network_connection.rb', line 24

def network_connection_type
  connection_value = @bridge.getNetworkConnection

  connection_type = values_to_type[connection_value]

  # In case the connection type is not recognized return the
  # connection value.
  connection_type || connection_value
end

#network_connection_type=(connection_type) ⇒ Object

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Raises:

  • (ArgumentError)


34
35
36
37
38
39
40
# File 'lib/selenium/webdriver/common/driver_extensions/has_network_connection.rb', line 34

def network_connection_type=(connection_type)
  raise ArgumentError, "Invalid connection type" unless valid_type? connection_type

  connection_value = type_to_values[connection_type]

  @bridge.setNetworkConnection connection_value
end