Class: RaaP::Result::Failure
- Inherits:
-
Object
- Object
- RaaP::Result::Failure
- Includes:
- ReturnValueWithType
- Defined in:
- lib/raap/result.rb
Instance Method Summary collapse
- #called_str ⇒ Object
-
#initialize(exception: nil) ⇒ Failure
constructor
A new instance of Failure.
Methods included from ReturnValueWithType
Constructor Details
#initialize(exception: nil) ⇒ Failure
Returns a new instance of Failure.
77 78 79 |
# File 'lib/raap/result.rb', line 77 def initialize(exception: nil, **) super end |
Instance Method Details
#called_str ⇒ Object
81 82 83 84 85 86 87 88 89 90 |
# File 'lib/raap/result.rb', line 81 def called_str scr = SymbolicCaller.new(symbolic_call) return_type = if exception "raised #{exception.class}" else return_value_with_type end "#{scr.call_str} -> #{return_type}" end |