Exception: UrlExpander::Error

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(msg, code) ⇒ Error

Returns a new instance of Error.



58
59
60
61
# File 'lib/url_expander.rb', line 58

def initialize(msg, code)
  @code = code
  super("#{msg} - '#{code}'")
end

Instance Attribute Details

#codeObject (readonly)

Returns the value of attribute code.



56
57
58
# File 'lib/url_expander.rb', line 56

def code
  @code
end