Method: Optimist::Option#initialize
- Defined in:
- lib/optimist.rb
#initialize ⇒ Option
Returns a new instance of Option.
770 771 772 773 774 775 776 777 778 779 780 |
# File 'lib/optimist.rb', line 770 def initialize @long = LongNames.new @short = ShortNames.new # can be an Array of one-char strings, a one-char String, nil or :none @name = nil @multi_given = false @hidden = false @default = nil @permitted = nil @permitted_response = "option '%{arg}' only accepts %{valid_string}" @optshash = Hash.new() end |