class Bundler::Thor::Options

def initialize(hash_options = {}, defaults = {}, stop_on_unknown = false, disable_required_check = false)

an unknown option or a regular argument.
If +stop_on_unknown+ is true, #parse will stop as soon as it encounters

Takes a hash of Bundler::Thor::Option and a hash with defaults.
def initialize(hash_options = {}, defaults = {}, stop_on_unknown = false, disable_required_check = false)
  @stop_on_unknown = stop_on_unknown
  @disable_required_check = disable_required_check
  options = hash_options.values
  super(options)
  # Add defaults
  defaults.each do |key, value|
    @assigns[key.to_s] = value
    @non_assigned_required.delete(hash_options[key])
  end
  @shorts = {}
  @switches = {}
  @extra = []
  @stopped_parsing_after_extra_index = nil
  @is_treated_as_value = false
  options.each do |option|
    @switches[option.switch_name] = option
    option.aliases.each do |short|
      name = short.to_s.sub(/^(?!\-)/, "-")
      @shorts[name] ||= option.switch_name
    end
  end
end