Exception: UsageMod::InvalidIntegerError

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

Overview

The user specified a non integer when an integer argument was expected when the program was run

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(integer_str) ⇒ InvalidIntegerError

Returns a new instance of InvalidIntegerError.



78
79
80
81
# File 'lib/Usage.rb', line 78

def initialize(integer_str)
  @integer_str = integer_str
  super("invalid integer value: '#{integer_str}'")
end

Instance Attribute Details

#integer_strObject (readonly)

Returns the value of attribute integer_str.



77
78
79
# File 'lib/Usage.rb', line 77

def integer_str
  @integer_str
end