Exception: Beget::RequestError
- Inherits:
-
StandardError
- Object
- StandardError
- Beget::RequestError
- Defined in:
- lib/beget_api.rb
Overview
General method error
Instance Attribute Summary collapse
-
#code ⇒ Object
readonly
Returns the value of attribute code.
-
#text ⇒ Object
readonly
Returns the value of attribute text.
Instance Method Summary collapse
-
#initialize(code, text) ⇒ RequestError
constructor
A new instance of RequestError.
- #to_s ⇒ Object
Constructor Details
#initialize(code, text) ⇒ RequestError
Returns a new instance of RequestError.
86 87 88 89 90 |
# File 'lib/beget_api.rb', line 86 def initialize(code, text) super() @code = code @text = text end |
Instance Attribute Details
#code ⇒ Object (readonly)
Returns the value of attribute code.
84 85 86 |
# File 'lib/beget_api.rb', line 84 def code @code end |
#text ⇒ Object (readonly)
Returns the value of attribute text.
84 85 86 |
# File 'lib/beget_api.rb', line 84 def text @text end |
Instance Method Details
#to_s ⇒ Object
92 93 94 |
# File 'lib/beget_api.rb', line 92 def to_s %(#{@code}: #{@text}) end |