Skip to content

Commit 7bf0f6d

Browse files
committed
docs: move docs about location
1 parent 5fb2aca commit 7bf0f6d

File tree

1 file changed

+36
-0
lines changed

1 file changed

+36
-0
lines changed

lib/appium_lib_core/android/device.rb

+36
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,42 @@ module Device
106106
# @driver.toggle_data
107107
#
108108

109+
# @!method location
110+
# Get the location of the device.
111+
#
112+
# @return [::Appium::Location]
113+
#
114+
# @example
115+
#
116+
# driver.location #=> ::Appium::Location.new(10, 10, 10)
117+
#
118+
119+
# @!method location=
120+
# Set the location of the device.
121+
#
122+
# @param [::Appium::Location] location Set the location.
123+
#
124+
# @example
125+
#
126+
# driver.location = ::Appium::Location.new(10, 10, 10)
127+
#
128+
129+
# Set the location of the device.
130+
#
131+
# @param [String, Number] latitude Set the latitude.
132+
# @param [String, Number] longitude Set the longitude.
133+
# @param [String, Number] altitude Set the altitude.
134+
# @param [String, Number] speed Set the speed to apply the location on Android real devices
135+
# in meters/second @since Appium 1.21.0 and in knots for emulators @since Appium 1.22.0.
136+
# @param [String, Number] satellites Sets the count of geo satellites being tracked in range 1..12 @since Appium 1.22.0.
137+
# This number is respected on Emulators.
138+
# @param [::Appium::Location]
139+
#
140+
# @example
141+
#
142+
# driver.set_location 10, 10, 0
143+
#
144+
109145
# @!method toggle_location_services
110146
# Switch the state of the location service
111147
#

0 commit comments

Comments
 (0)