processing_components/visibility/msv2supp.py
def cmp_to_total(cls):
    """
    Decorator to define the six comparison operators that are needed
    for total ordering that can be used in all versions of Python
    from the __cmp__() method.
    """

    names = ['__lt__', '__le__', '__gt__', '__ge__', '__eq__', '__ne__']
    funcs = [_cmp_to_lt, _cmp_to_le, _cmp_to_gt, _cmp_to_ge, _cmp_to_eq, _cmp_to_ne]

    for name, func in zip(names, funcs):
        # Is it defined?
        if name not in dir(cls):
            func.__name__ = name
            setattr(cls, name, func)

    return cls

    Decorator to define the six comparison operators that are needed
    for total ordering that can be used in all versions of Python
    from the __cmp__() method.
    
Decorator to define the six comparison operators that are needed
for total ordering that can be used in all versions of Python
from the __cmp__() method.
Decorator to define the six comparison operators that are needed for total ordering that can be used in all versions of Python from the __cmp__ () method .
def cmp_to_total(cls):
    names = ['__lt__', '__le__', '__gt__', '__ge__', '__eq__', '__ne__']
    funcs = [_cmp_to_lt, _cmp_to_le, _cmp_to_gt, _cmp_to_ge, _cmp_to_eq, _cmp_to_ne]
    for name, func in zip(names, funcs):
        if name not in dir(cls):
            func.__name__ = name
            setattr(cls, name, func)
    return cls
def cmp_to_total ( cls ) : names = [ '__lt__' , '__le__' , '__gt__' , '__ge__' , '__eq__' , '__ne__' ] funcs = [ _cmp_to_lt , _cmp_to_le , _cmp_to_gt , _cmp_to_ge , _cmp_to_eq , _cmp_to_ne ] for name , func in zip ( names , funcs ) : if name not in dir ( cls ) : func . __name__ = name setattr ( cls , name , func ) return cls
Decorator to define the six comparison operators that are needed
for total ordering that can be used in all versions of Python
from the __cmp__() method.
Decorator to define the six comparison operators that are needed for total ordering that can be used in all versions of Python from the __cmp__ () method .
"""
    Decorator to define the six comparison operators that are needed
    for total ordering that can be used in all versions of Python
    from the __cmp__() method.
    """ # Is it defined?
cls