Exception: Shift::Api::Core::Errors::NotFound

Inherits:
ServerError show all
Defined in:
lib/shift/api/core/errors.rb

Instance Attribute Summary collapse

Attributes inherited from ApiError

#env, #original_exception

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from ServerError

#backtrace

Constructor Details

#initialize(uri) ⇒ NotFound

Returns a new instance of NotFound.



74
75
76
# File 'lib/shift/api/core/errors.rb', line 74

def initialize(uri)
  @uri = uri
end

Instance Attribute Details

#uriObject (readonly)

Returns the value of attribute uri.



73
74
75
# File 'lib/shift/api/core/errors.rb', line 73

def uri
  @uri
end

Class Method Details

.from_jsonapi_client(ex) ⇒ Object



82
83
84
# File 'lib/shift/api/core/errors.rb', line 82

def self.from_jsonapi_client(ex)
  new(ex.uri)
end

Instance Method Details

#messageObject



78
79
80
# File 'lib/shift/api/core/errors.rb', line 78

def message
  "Couldn't find resource at: #{ uri }"
end