Exception: Rjq::HaltError
Overview
Halting terminates the whole jq program. It is deliberately not a RuntimeError: try/catch and the optional operator only catch ordinary filter failures.
Instance Attribute Summary collapse
-
#status ⇒ Object
readonly
Returns the value of attribute status.
-
#value ⇒ Object
readonly
Returns the value of attribute value.
Instance Method Summary collapse
-
#initialize(value = nil, status = 0) ⇒ HaltError
constructor
A new instance of HaltError.
Constructor Details
#initialize(value = nil, status = 0) ⇒ HaltError
Returns a new instance of HaltError.
57 58 59 60 61 |
# File 'lib/rjq/errors.rb', line 57 def initialize(value = nil, status = 0) @value = value @status = status super(value.nil? ? 'halt_error' : value.to_s) end |
Instance Attribute Details
#status ⇒ Object (readonly)
Returns the value of attribute status.
55 56 57 |
# File 'lib/rjq/errors.rb', line 55 def status @status end |
#value ⇒ Object (readonly)
Returns the value of attribute value.
55 56 57 |
# File 'lib/rjq/errors.rb', line 55 def value @value end |