Exception: Speculation::Error
- Inherits:
-
StandardError
- Object
- StandardError
- Speculation::Error
- Defined in:
- lib/speculation/error.rb
Instance Attribute Summary collapse
-
#data ⇒ Object
readonly
Returns the value of attribute data.
Instance Method Summary collapse
-
#initialize(message, data) ⇒ Error
constructor
A new instance of Error.
- #to_s ⇒ Object
Constructor Details
#initialize(message, data) ⇒ Error
Returns a new instance of Error.
8 9 10 11 |
# File 'lib/speculation/error.rb', line 8 def initialize(, data) super() @data = data.merge(:cause => ) end |
Instance Attribute Details
#data ⇒ Object (readonly)
Returns the value of attribute data.
6 7 8 |
# File 'lib/speculation/error.rb', line 6 def data @data end |
Instance Method Details
#to_s ⇒ Object
13 14 15 |
# File 'lib/speculation/error.rb', line 13 def to_s PP.pp(@data, String.new) end |