Exception: Mona::Result::NoMatchError

Inherits:
Error
  • Object
show all
Defined in:
lib/mona/result/error.rb

Overview

raised when Result::Match does not match the result

Since:

  • 0.1.0

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(result) ⇒ NoMatchError

Returns a new instance of NoMatchError.

Since:

  • 0.1.0



12
13
14
15
# File 'lib/mona/result/error.rb', line 12

def initialize(result)
  @result = result
  super("No match found for #{result}")
end

Instance Attribute Details

#resultObject (readonly)

Since:

  • 0.1.0



10
11
12
# File 'lib/mona/result/error.rb', line 10

def result
  @result
end