Class: Crawlberg::CrawlEventComplete

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

Overview

The crawl has completed.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#pages_crawledObject (readonly)

rubocop:disable Lint/UselessMethodDefinition



193
194
195
# File 'lib/crawlberg/native.rb', line 193

def pages_crawled
  @pages_crawled
end

Class Method Details

.from_hash(hash) ⇒ Object



210
211
212
# File 'lib/crawlberg/native.rb', line 210

def self.from_hash(hash)
  new(pages_crawled: hash[:pages_crawled] || hash["pages_crawled"])
end

Instance Method Details

#complete?Boolean

Returns:

  • (Boolean)


206
207
208
# File 'lib/crawlberg/native.rb', line 206

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

#error?Boolean

Returns:

  • (Boolean)


204
# File 'lib/crawlberg/native.rb', line 204

def error? = false

#page?Boolean

Returns:

  • (Boolean)


202
# File 'lib/crawlberg/native.rb', line 202

def page? = false