Exception: Rested::ObjectNotFound
- Inherits:
-
Error
- Object
- Exception
- Error
- Rested::ObjectNotFound
- Defined in:
- lib/rested/error.rb
Instance Attribute Summary (collapse)
-
- (Object) id
Returns the value of attribute id.
Attributes inherited from Error
#http_response, #message, #reason, #status, #validations
Instance Method Summary (collapse)
-
- (ObjectNotFound) initialize(res)
constructor
A new instance of ObjectNotFound.
- - (Object) to_s
Constructor Details
- (ObjectNotFound) initialize(res)
A new instance of ObjectNotFound
47 48 49 50 |
# File 'lib/rested/error.rb', line 47 def initialize(res) super(res) self.id = $1 if res.content =~ /Invalid Object.*?(\d+)/ end |
Instance Attribute Details
- (Object) id
Returns the value of attribute id
45 46 47 |
# File 'lib/rested/error.rb', line 45 def id @id end |
Instance Method Details
- (Object) to_s
52 53 54 |
# File 'lib/rested/error.rb', line 52 def to_s "Invalid Object ID '#{self.id}'" end |