Exception: Dry::Monads::UnwrapError
- Inherits:
-
StandardError
- Object
- StandardError
- Dry::Monads::UnwrapError
- Defined in:
- lib/dry/monads/errors.rb
Overview
An unsuccessful result of extracting a value from a monad.
Instance Attribute Summary collapse
- #receiver ⇒ Object readonly
Instance Method Summary collapse
-
#initialize(receiver) ⇒ UnwrapError
constructor
A new instance of UnwrapError.
Constructor Details
#initialize(receiver) ⇒ UnwrapError
Returns a new instance of UnwrapError.
9 10 11 12 |
# File 'lib/dry/monads/errors.rb', line 9 def initialize(receiver) @receiver = receiver super("value! was called on #{receiver.inspect}") end |
Instance Attribute Details
#receiver ⇒ Object (readonly)
7 8 9 |
# File 'lib/dry/monads/errors.rb', line 7 def receiver @receiver end |