Exception: ComicWalker::Client::Error

Inherits:
StandardError
  • Object
show all
Defined in:
lib/comic_walker/client.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(code, reason) ⇒ Error

Returns a new instance of Error.



16
17
18
19
20
# File 'lib/comic_walker/client.rb', line 16

def initialize(code, reason)
  super("#{code}: #{reason}")
  @code = code
  @reason = reason
end

Instance Attribute Details

#codeObject (readonly)

Returns the value of attribute code.



15
16
17
# File 'lib/comic_walker/client.rb', line 15

def code
  @code
end

#reasonObject (readonly)

Returns the value of attribute reason.



15
16
17
# File 'lib/comic_walker/client.rb', line 15

def reason
  @reason
end