(self, name)
return decorator
Return a decorator that attaches a callback to a hook. See
            :meth:`add_hook` for details.
Return a decorator that attaches a callback to a hook. See
            :meth:`add_hook` for details.
Return a decorator that attaches a callback to a hook . See : meth : add_hook for details .
def hook(self, name):
        """ Return a decorator that attaches a callback to a hook. See
            :meth:`add_hook` for details."""
        def decorator(func):
            self.add_hook(name, func)
            return func
        return decorator
def hook ( self , name ) : def decorator ( func ) : self . add_hook ( name , func ) return func return decorator