class RDoc::Options

def setup_generator generator_name = @generator_name

def setup_generator generator_name = @generator_name
  @generator = @generators[generator_name]
  unless @generator then
    raise OptionParser::InvalidArgument,
          "Invalid output formatter #{generator_name}"
  end
  return if @generator_options.include? @generator
  @generator_name = generator_name
  @generator_options << @generator
  if @generator.respond_to? :setup_options then
    @option_parser ||= OptionParser.new
    @generator.setup_options self
  end
end