'Add an option to this section.
:param name:       The name of this option. Must be a valid Python identifier.
Must also be unique in this OptionSet and all its subsets.
:param switches:   List of command line switches for this option
(as supplied to :module:`optparse`). If empty, this
option will not be added to the command line parser.
:param help:       Help text.
:param type:       Type checking of option values. Supported types are:
`None, \'choice\', \'complex\', \'float\', \'int\', \'string\'`.
:param choices:    List of strings or `None`.
:param group:      Group this option belongs to. You must previously
have created this group with a call to :method:`add_group`.
:param default:    The default value for this option.
:param action:     The action to pass to optparse. Supported values are:
`None, \'count\'`. For choices and boolean options,
action is automatically set correctly.'

def add_opt(self, name, switches=[], help=None, type=None, choices=None, group=None, default=None, action=None, metavar=None):

    pref = Option(name, switches=switches, help=help, type=type, choices=choices, group=group, default=default, action=action, metavar=None)
    if ((group is not None) and (group not in self.groups.keys())):
        raise ValueError(('Group    %s    has    not    been    added    to    this    section' % group))
    if (pref in self.preferences):
        raise ValueError(('An    option    with    the    name    %s    already    exists    in    this    set.' % name))
    self.preferences.append(pref)
    self.defaults[name] = default
