Exception: ShEx::Error
- Inherits:
-
StandardError
- Object
- StandardError
- ShEx::Error
- Defined in:
- lib/shex.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#code ⇒ Object
readonly
The status code associated with this error.
Instance Method Summary collapse
-
#initialize(message, options = {}) ⇒ Error
constructor
Initializes a new patch error instance.
Constructor Details
#initialize(message, options = {}) ⇒ Error
Initializes a new patch error instance.
119 120 121 122 |
# File 'lib/shex.rb', line 119 def initialize(, = {}) @code = .fetch(:status_code, 422) super(.to_s) end |
Instance Attribute Details
#code ⇒ Object (readonly)
The status code associated with this error
111 112 113 |
# File 'lib/shex.rb', line 111 def code @code end |