Module: Selenium::WebDriver::DriverExtensions::HasLocation Private
- Defined in:
- lib/selenium/webdriver/common/driver_extensions/has_location.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
- #location ⇒ Object private
- #location=(loc) ⇒ Object private
- #set_location(lat, lon, alt) ⇒ Object private
Instance Method Details
#location ⇒ 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.
25 26 27 |
# File 'lib/selenium/webdriver/common/driver_extensions/has_location.rb', line 25 def location @bridge.getLocation end |
#location=(loc) ⇒ 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.
29 30 31 32 33 34 35 |
# File 'lib/selenium/webdriver/common/driver_extensions/has_location.rb', line 29 def location=(loc) unless loc.kind_of?(Location) raise TypeError, "expected #{Location}, got #{loc.inspect}:#{loc.class}" end @bridge.setLocation loc.latitude, loc.longitude, loc.altitude end |
#set_location(lat, lon, alt) ⇒ 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.
37 38 39 |
# File 'lib/selenium/webdriver/common/driver_extensions/has_location.rb', line 37 def set_location(lat, lon, alt) self.location = Location.new(Float(lat), Float(lon), Float(alt)) end |