Exception: Myrrha::Error

Inherits:
StandardError
  • Object
show all
Defined in:
lib/myrrha/errors.rb

Overview

Raised when a coercion fails

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(msg, cause = $!) ⇒ Error

Returns a new instance of Error.



6
7
8
9
# File 'lib/myrrha/errors.rb', line 6

def initialize(msg, cause = $!)
  super(msg)
  @cause = cause
end

Instance Attribute Details

#causeObject

Returns the value of attribute cause.



5
6
7
# File 'lib/myrrha/errors.rb', line 5

def cause
  @cause
end