MCPcopy
hub / github.com/fluentpython/example-code-2e / decorator

Method decorator

21-async/mojifinder/bottle.py:651–653  ·  view source on GitHub ↗
(func)

Source from the content-addressed store, hash-verified

649 """ Return a decorator that attaches a callback to a hook. See
650 :meth:`add_hook` for details."""
651 def decorator(func):
652 self.add_hook(name, func)
653 return func
654 return decorator
655
656 def mount(self, prefix, app, **options):

Callers

nothing calls this directly

Calls 6

add_hookMethod · 0.95
add_routeMethod · 0.95
makelistFunction · 0.85
yieldroutesFunction · 0.85
RouteClass · 0.85
loadFunction · 0.70

Tested by

no test coverage detected