Exception: Slop::InvalidOptionValue

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

Overview

Raised when a given option is provided by the user and does not match the expected format for that type. This is only raised if validate_types is set to true.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(msg, flag) ⇒ InvalidOptionValue

Returns a new instance of InvalidOptionValue.



48
49
50
51
# File 'lib/slop/error.rb', line 48

def initialize(msg, flag)
  super(msg)
  @flag = flag
end

Instance Attribute Details

#flagObject (readonly)

Returns the value of attribute flag.



46
47
48
# File 'lib/slop/error.rb', line 46

def flag
  @flag
end