Skip to content

Commit 876d254

Browse files
authored
chore: teak types in yardoc (#307)
1 parent 7548ea9 commit 876d254

File tree

3 files changed

+12
-6
lines changed

3 files changed

+12
-6
lines changed

lib/appium_lib_core/common/base/driver.rb

+7-3
Original file line numberDiff line numberDiff line change
@@ -247,6 +247,8 @@ def deactivate
247247

248248
# Returns an instance of DeviceIME
249249
#
250+
# @return [Appium::Core::Base::Driver::DeviceIME]
251+
#
250252
# @example
251253
#
252254
# @driver.ime.activate engine: 'com.android.inputmethod.latin/.LatinIME'
@@ -297,6 +299,8 @@ def ime_active_engine
297299
# @!method ime_activated
298300
# Android only. Indicates whether IME input is active at the moment (not if it is available).
299301
#
302+
# @return [Boolean]
303+
#
300304
# @example
301305
#
302306
# @driver.ime_activated #=> True if IME is activated
@@ -861,7 +865,7 @@ def back
861865
end
862866

863867
# Get the device window's logs.
864-
# @return [String]
868+
# @return [Appium::Core::Logs]
865869
#
866870
# @example
867871
#
@@ -887,7 +891,7 @@ def get_timeouts
887891
# Retrieve the capabilities of the specified session.
888892
# It's almost same as +@driver.capabilities+ but you can get more details.
889893
#
890-
# @return [Selenium::WebDriver::Remote::Capabilities]
894+
# @return [Selenium::WebDriver::Remote::Capabilities, Selenium::WebDriver::Remote::W3C::Capabilities]
891895
#
892896
# @example
893897
# @driver.session_capabilities
@@ -1046,7 +1050,7 @@ def find_element_by_image(img_path)
10461050
#
10471051
# @param [String] img_path A path to a partial image you'd like to find
10481052
#
1049-
# @return [::Selenium::WebDriver::Element]
1053+
# @return [Array<Selenium::WebDriver::Element>]
10501054
#
10511055
# @example
10521056
#

lib/appium_lib_core/common/base/search_context.rb

+2
Original file line numberDiff line numberDiff line change
@@ -141,6 +141,8 @@ def find_element(*args)
141141
#
142142
# Find all elements matching the given arguments
143143
#
144+
# @return [Array<Selenium::WebDriver::Element>]
145+
#
144146
# @see SearchContext#find_elements
145147
#
146148
def find_elements(*args)

lib/appium_lib_core/common/device/image_comparison.rb

+3-3
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ module ImageComparison
4747
# not available in the default OpenCV installation and have to be enabled manually
4848
# before library compilation. The default detector name is 'ORB'.
4949
# @param [String] match_func The name of the matching function. The default one is 'BruteForce'.
50-
# @param [String] good_matches_factor The maximum count of "good" matches (e. g. with minimal distances).
50+
# @param [String, nil] good_matches_factor The maximum count of "good" matches (e. g. with minimal distances).
5151
# The default one is nil.
5252
# @param [Bool] visualize Makes the endpoint to return an image, which contains the visualized result of
5353
# the corresponding picture matching operation. This option is disabled by default.
@@ -94,7 +94,7 @@ def match_images_features(first_image:,
9494
# are supported.
9595
# @param [Bool] visualize Makes the endpoint to return an image, which contains the visualized result of
9696
# the corresponding picture matching operation. This option is disabled by default.
97-
# @param [Float] threshold [0.5] At what normalized threshold to reject
97+
# @param [Float, nil] threshold [0.5] At what normalized threshold to reject
9898
#
9999
# @example
100100
# @driver.find_image_occurrence full_image: "image data 1", partial_image: "image data 2"
@@ -144,7 +144,7 @@ def get_images_similarity(first_image:, second_image:, visualize: false)
144144
# +:matchFeatures is by default.
145145
# @param [String] first_image An image data. All image formats, that OpenCV library itself accepts, are supported.
146146
# @param [String] second_image An image data. All image formats, that OpenCV library itself accepts, are supported.
147-
# @param [Hash] options The content of this dictionary depends on the actual +mode+ value.
147+
# @param [Hash, nil] options The content of this dictionary depends on the actual +mode+ value.
148148
# See the documentation on +appium-support+ module for more details.
149149
# @return [Hash] The content of the resulting dictionary depends on the actual +mode+ and +options+ values.
150150
# See the documentation on +appium-support+ module for more details.

0 commit comments

Comments
 (0)