Class: Kreuzcrawl::PageActionScroll
- Inherits:
-
Data
- Object
- Data
- Kreuzcrawl::PageActionScroll
- Extended by:
- T::Sig
- Includes:
- PageAction
- Defined in:
- lib/kreuzcrawl/native.rb
Overview
Scroll the page or a specific element.
Instance Attribute Summary collapse
-
#amount ⇒ Object
readonly
rubocop:disable Lint/UselessMethodDefinition.
-
#direction ⇒ Object
readonly
rubocop:disable Lint/UselessMethodDefinition.
-
#selector ⇒ Object
readonly
rubocop:disable Lint/UselessMethodDefinition.
Class Method Summary collapse
Instance Method Summary collapse
- #click? ⇒ Boolean
- #execute_js? ⇒ Boolean
- #press? ⇒ Boolean
- #scrape? ⇒ Boolean
- #screenshot? ⇒ Boolean
- #scroll? ⇒ Boolean
- #type_text? ⇒ Boolean
- #wait? ⇒ Boolean
Instance Attribute Details
#amount ⇒ Object (readonly)
rubocop:disable Lint/UselessMethodDefinition
328 329 330 |
# File 'lib/kreuzcrawl/native.rb', line 328 def amount @amount end |
#direction ⇒ Object (readonly)
rubocop:disable Lint/UselessMethodDefinition
328 329 330 |
# File 'lib/kreuzcrawl/native.rb', line 328 def direction @direction end |
#selector ⇒ Object (readonly)
rubocop:disable Lint/UselessMethodDefinition
328 329 330 |
# File 'lib/kreuzcrawl/native.rb', line 328 def selector @selector end |
Class Method Details
.from_hash(hash) ⇒ Object
360 361 362 |
# File 'lib/kreuzcrawl/native.rb', line 360 def self.from_hash(hash) new(direction: hash[:direction] || hash["direction"], selector: hash[:selector] || hash["selector"], amount: hash[:amount] || hash["amount"]) end |
Instance Method Details
#click? ⇒ Boolean
342 |
# File 'lib/kreuzcrawl/native.rb', line 342 def click? = false |
#execute_js? ⇒ Boolean
354 |
# File 'lib/kreuzcrawl/native.rb', line 354 def execute_js? = false |
#press? ⇒ Boolean
346 |
# File 'lib/kreuzcrawl/native.rb', line 346 def press? = false |
#scrape? ⇒ Boolean
356 357 358 |
# File 'lib/kreuzcrawl/native.rb', line 356 def scrape? = false # @param hash [Hash] deserialized from the native extension # @return [self] |
#screenshot? ⇒ Boolean
352 |
# File 'lib/kreuzcrawl/native.rb', line 352 def screenshot? = false |
#scroll? ⇒ Boolean
348 |
# File 'lib/kreuzcrawl/native.rb', line 348 def scroll? = true |
#type_text? ⇒ Boolean
344 |
# File 'lib/kreuzcrawl/native.rb', line 344 def type_text? = false |
#wait? ⇒ Boolean
350 |
# File 'lib/kreuzcrawl/native.rb', line 350 def wait? = false |