Exception: Budurl::Error
- Inherits:
-
StandardError
- Object
- StandardError
- Budurl::Error
- Defined in:
- lib/budurl/client.rb
Overview
This class encapsulates BudURL API errors into a usable form.
Instance Attribute Summary collapse
-
#code ⇒ Object
readonly
Returns the value of attribute code.
Instance Method Summary collapse
-
#initialize(message, code) ⇒ Error
constructor
A new instance of Error.
Constructor Details
#initialize(message, code) ⇒ Error
Returns a new instance of Error.
61 62 63 64 |
# File 'lib/budurl/client.rb', line 61 def initialize(, code) @code = code super("#{code} - #{}") end |
Instance Attribute Details
#code ⇒ Object (readonly)
Returns the value of attribute code.
59 60 61 |
# File 'lib/budurl/client.rb', line 59 def code @code end |