¡@

Home 

OpenStack Study: __init__.py

OpenStack Index

**** CubicPower OpenStack Study ****

def example_decorator(name, function):

    """decorator for notify which is used from utils.monkey_patch().

        :param name: name of the function

        :param function: - object of the function

        :returns: function -- decorated function

    """

    def wrapped_func(*args, **kwarg):

        CALLED_FUNCTION.append(name)

        return function(*args, **kwarg)

    return wrapped_func