Class: Crawlberg::PageActionWait
- Inherits:
-
Data
- Object
- Data
- Crawlberg::PageActionWait
- Extended by:
- T::Sig
- Includes:
- PageAction
- Defined in:
- lib/crawlberg/native.rb
Overview
Wait for a duration or for an element to appear.
Instance Attribute Summary collapse
-
#milliseconds ⇒ 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
#milliseconds ⇒ Object (readonly)
rubocop:disable Lint/UselessMethodDefinition
400 401 402 |
# File 'lib/crawlberg/native.rb', line 400 def milliseconds @milliseconds end |
#selector ⇒ Object (readonly)
rubocop:disable Lint/UselessMethodDefinition
400 401 402 |
# File 'lib/crawlberg/native.rb', line 400 def selector @selector end |
Class Method Details
.from_hash(hash) ⇒ Object
431 432 433 |
# File 'lib/crawlberg/native.rb', line 431 def self.from_hash(hash) new(milliseconds: hash[:milliseconds] || hash["milliseconds"], selector: hash[:selector] || hash["selector"]) end |
Instance Method Details
#click? ⇒ Boolean
413 |
# File 'lib/crawlberg/native.rb', line 413 def click? = false |
#execute_js? ⇒ Boolean
425 |
# File 'lib/crawlberg/native.rb', line 425 def execute_js? = false |
#press? ⇒ Boolean
417 |
# File 'lib/crawlberg/native.rb', line 417 def press? = false |
#scrape? ⇒ Boolean
427 428 429 |
# File 'lib/crawlberg/native.rb', line 427 def scrape? = false # @param hash [Hash] deserialized from the native extension # @return [self] |
#screenshot? ⇒ Boolean
423 |
# File 'lib/crawlberg/native.rb', line 423 def screenshot? = false |
#scroll? ⇒ Boolean
419 |
# File 'lib/crawlberg/native.rb', line 419 def scroll? = false |
#type_text? ⇒ Boolean
415 |
# File 'lib/crawlberg/native.rb', line 415 def type_text? = false |
#wait? ⇒ Boolean
421 |
# File 'lib/crawlberg/native.rb', line 421 def wait? = true |