lib/appium_lib/ios/element/generic.rb in appium_lib-0.3.16 vs lib/appium_lib/ios/element/generic.rb in appium_lib-0.4.0

- old
+ new

@@ -17,18 +17,12 @@ 3. value Android name = iOS name & label Android text = iOS value =end - def ios_js_loaded? method_name - @ios_js.include? method_name - end - def ios_js_load method_name - @ios_js.push method_name - end - + # @private # returnElems requires a wrapped $(element). # set to empty array when length is zero to prevent hang. # # UIAElementNil when not matched # @@ -42,10 +36,12 @@ # window 0 is the main window. # window 1 is the 1st webview (if it exists) # must break instead of return because it's not a function. # # single element length is undefined when found and 0 when not found. + # @param predicate [String] the predicate + # @return [String] the completed JavaScript program def first_ele_js predicate <<-JS function isNil( a ) { return a.type() === 'UIAElementNil'; } @@ -92,9 +88,12 @@ run(); JS end + # @private + # @param predicate [String] the predicate + # @return [String] the completed JavaScript program def all_ele_js predicate <<-JS var w = au.mainWindow; var search = "#{predicate}"; var a = w.elements().withPredicate(search).toArray(); \ No newline at end of file