Class: Playwright::SelectOptionValues
- Inherits:
-
Object
- Object
- Playwright::SelectOptionValues
- Defined in:
- lib/playwright/select_option_values.rb
Instance Method Summary collapse
- #as_params ⇒ Hash
-
#initialize(element: nil, index: nil, value: nil, label: nil) ⇒ SelectOptionValues
constructor
A new instance of SelectOptionValues.
Constructor Details
#initialize(element: nil, index: nil, value: nil, label: nil) ⇒ SelectOptionValues
Returns a new instance of SelectOptionValues.
3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 |
# File 'lib/playwright/select_option_values.rb', line 3 def initialize(element: nil, index: nil, value: nil, label: nil) params = {} = [] if value .concat(convert(:value, value)) end if index .concat(convert(:index, index)) end if label .concat(convert(:label, label)) end unless .empty? params[:options] = end if element params[:elements] = convert(:element, element) end @params = params end |
Instance Method Details
#as_params ⇒ Hash
31 32 33 |
# File 'lib/playwright/select_option_values.rb', line 31 def as_params @params end |