Class: JSONAPI::Error
- Inherits:
-
Object
- Object
- JSONAPI::Error
- Defined in:
- lib/jsonapi/error.rb
Instance Attribute Summary collapse
-
#code ⇒ Object
Returns the value of attribute code.
-
#detail ⇒ Object
Returns the value of attribute detail.
-
#href ⇒ Object
Returns the value of attribute href.
-
#id ⇒ Object
Returns the value of attribute id.
-
#links ⇒ Object
Returns the value of attribute links.
-
#path ⇒ Object
Returns the value of attribute path.
-
#status ⇒ Object
Returns the value of attribute status.
-
#title ⇒ Object
Returns the value of attribute title.
Instance Method Summary collapse
-
#initialize(options = {}) ⇒ Error
constructor
A new instance of Error.
Constructor Details
#initialize(options = {}) ⇒ Error
Returns a new instance of Error.
6 7 8 9 10 11 12 13 14 15 |
# File 'lib/jsonapi/error.rb', line 6 def initialize(={}) @title = [:title] @detail = [:detail] @id = [:id] @href = [:href] @code = [:code] @path = [:path] @links = [:links] @status = [:status] end |
Instance Attribute Details
#code ⇒ Object
Returns the value of attribute code.
4 5 6 |
# File 'lib/jsonapi/error.rb', line 4 def code @code end |
#detail ⇒ Object
Returns the value of attribute detail.
4 5 6 |
# File 'lib/jsonapi/error.rb', line 4 def detail @detail end |
#href ⇒ Object
Returns the value of attribute href.
4 5 6 |
# File 'lib/jsonapi/error.rb', line 4 def href @href end |
#id ⇒ Object
Returns the value of attribute id.
4 5 6 |
# File 'lib/jsonapi/error.rb', line 4 def id @id end |
#links ⇒ Object
Returns the value of attribute links.
4 5 6 |
# File 'lib/jsonapi/error.rb', line 4 def links @links end |
#path ⇒ Object
Returns the value of attribute path.
4 5 6 |
# File 'lib/jsonapi/error.rb', line 4 def path @path end |
#status ⇒ Object
Returns the value of attribute status.
4 5 6 |
# File 'lib/jsonapi/error.rb', line 4 def status @status end |
#title ⇒ Object
Returns the value of attribute title.
4 5 6 |
# File 'lib/jsonapi/error.rb', line 4 def title @title end |