parameters: (self, name)
return_statement: return wrapper
docstring: Return a decorator that attaches a callback to a hook. Three hooks
              are currently implemented:
  
              - before_request: Executed once before each request
              - after_request: Executed once after each request
              - app_reset: Called whenever :meth:`reset` is called.
docstring_summary: Return a decorator that attaches a callback to a hook. Three hooks
              are currently implemented:
docstring_tokens: Return a decorator that attaches a callback to a hook . Three hooks are currently implemented :
function: def hook(self, name):
          """ Return a decorator that attaches a callback to a hook. Three hooks
              are currently implemented:
  
              - before_request: Executed once before each request
              - after_request: Executed once after each request
              - app_reset: Called whenever :meth:`reset` is called.
          """
          def wrapper(func):
              self.hooks.add(name, func)
              return func
          return wrapper
function_tokens: def hook ( self , name ) : def wrapper ( func ) : self . hooks . add ( name , func ) return func return wrapper