Exception: Mothership::TypeMismatch

Inherits:
Error
  • Object
show all
Defined in:
lib/mothership/errors.rb

Instance Method Summary collapse

Constructor Details

#initialize(cmd, input, type) ⇒ TypeMismatch

Returns a new instance of TypeMismatch.



27
28
29
30
31
# File 'lib/mothership/errors.rb', line 27

def initialize(cmd, input, type)
  @command = cmd
  @input = input
  @type = type
end

Instance Method Details

#to_sObject



33
34
35
# File 'lib/mothership/errors.rb', line 33

def to_s
  "#{@command}: expected #{@type} value for #{@input}"
end