Exception: Scraper::Reader::HTTPError

Inherits:
StandardError
  • Object
show all
Defined in:
lib/scraper/reader.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(cause = nil) ⇒ HTTPError

Returns a new instance of HTTPError.



26
27
28
# File 'lib/scraper/reader.rb', line 26

def initialize(cause = nil)
  @cause = cause
end

Instance Attribute Details

#causeObject (readonly)

Returns the value of attribute cause.



24
25
26
# File 'lib/scraper/reader.rb', line 24

def cause
  @cause
end

Instance Method Details

#to_sObject



31
32
33
# File 'lib/scraper/reader.rb', line 31

def to_s
  @cause ? "#{super}: #{@cause}" : super
end