Class: Kreuzcrawl::PageActionTypeText

Inherits:
Data
  • Object
show all
Extended by:
T::Sig
Includes:
PageAction
Defined in:
lib/kreuzcrawl/native.rb

Overview

Type text into an element matching the given CSS selector.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#selectorObject (readonly)

rubocop:disable Lint/UselessMethodDefinition



263
264
265
# File 'lib/kreuzcrawl/native.rb', line 263

def selector
  @selector
end

#textObject (readonly)

rubocop:disable Lint/UselessMethodDefinition



263
264
265
# File 'lib/kreuzcrawl/native.rb', line 263

def text
  @text
end

Class Method Details

.from_hash(hash) ⇒ Object



292
293
294
# File 'lib/kreuzcrawl/native.rb', line 292

def self.from_hash(hash)
  new(selector: hash[:selector] || hash["selector"], text: hash[:text] || hash["text"])
end

Instance Method Details

#click?Boolean

Returns:

  • (Boolean)


274
# File 'lib/kreuzcrawl/native.rb', line 274

def click? = false

#execute_js?Boolean

Returns:

  • (Boolean)


286
# File 'lib/kreuzcrawl/native.rb', line 286

def execute_js? = false

#press?Boolean

Returns:

  • (Boolean)


278
# File 'lib/kreuzcrawl/native.rb', line 278

def press? = false

#scrape?Boolean

Returns:

  • (Boolean)


288
289
290
# File 'lib/kreuzcrawl/native.rb', line 288

def scrape? = false
# @param hash [Hash] deserialized from the native extension
# @return [self]

#screenshot?Boolean

Returns:

  • (Boolean)


284
# File 'lib/kreuzcrawl/native.rb', line 284

def screenshot? = false

#scroll?Boolean

Returns:

  • (Boolean)


280
# File 'lib/kreuzcrawl/native.rb', line 280

def scroll? = false

#type_text?Boolean

Returns:

  • (Boolean)


276
# File 'lib/kreuzcrawl/native.rb', line 276

def type_text? = true

#wait?Boolean

Returns:

  • (Boolean)


282
# File 'lib/kreuzcrawl/native.rb', line 282

def wait? = false