@staticmethod
def register(signame):
    'Registers the signame if it is not already registered.\n        Returns the signal number for the signame.\n        '
    assert (type(signame) is str)
    if (signame in Signal._registry):
        return Signal._registry[signame]
    else:
        sigid = len(Signal._lookup)
        Signal._registry[signame] = sigid
        Signal._lookup.append(signame)
        Spy.on_signal_register(signame, sigid)
        return sigid
Registers the signame if it is not already registered.
Returns the signal number for the signame.
@staticmethod
def register(signame):
    'Registers the signame if it is not already registered.\n        Returns the signal number for the signame.\n        '
    assert (type(signame) is str)
    if (signame in Signal._registry):
        return Signal._registry[signame]
    else:
        sigid = len(Signal._lookup)
        Signal._registry[signame] = sigid
        Signal._lookup.append(signame)
        Spy.on_signal_register(signame, sigid)
        return sigid