Class: RIPE::ObjectError
- Inherits:
-
Object
- Object
- RIPE::ObjectError
- Defined in:
- lib/ripe/object_error.rb
Instance Method Summary collapse
- #args ⇒ Object
- #attribute ⇒ Object
-
#initialize(hash) ⇒ ObjectError
constructor
A new instance of ObjectError.
- #severity ⇒ Object
- #text ⇒ Object
Constructor Details
#initialize(hash) ⇒ ObjectError
Returns a new instance of ObjectError.
4 5 6 |
# File 'lib/ripe/object_error.rb', line 4 def initialize(hash) @hash = hash end |
Instance Method Details
#args ⇒ Object
20 21 22 |
# File 'lib/ripe/object_error.rb', line 20 def args @hash['args'].map { |a| a['value'] } end |
#attribute ⇒ Object
16 17 18 |
# File 'lib/ripe/object_error.rb', line 16 def attribute @hash['attribute'] end |
#severity ⇒ Object
12 13 14 |
# File 'lib/ripe/object_error.rb', line 12 def severity @hash['severity'] end |
#text ⇒ Object
8 9 10 |
# File 'lib/ripe/object_error.rb', line 8 def text @hash['text'] % args end |