Exception: ShEx::Error
- Inherits:
-
StandardError
- Object
- StandardError
- ShEx::Error
- Defined in:
- lib/shex.rb
Direct Known Subclasses
Algebra::NotMatched, NotSatisfied, ParseError, StructureError
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.
92 93 94 95 |
# File 'lib/shex.rb', line 92 def initialize(, = {}) @code = .fetch(:status_code, 422) super(.to_s) end |
Instance Attribute Details
#code ⇒ Object (readonly)
The status code associated with this error
84 85 86 |
# File 'lib/shex.rb', line 84 def code @code end |