MCPcopy
hub / github.com/cherrypy/cherrypy / _setup

Method _setup

cherrypy/_cptools.py:135–146  ·  view source on GitHub ↗

Hook this tool into cherrypy.request. The standard CherryPy request object will automatically call this method when the tool is "turned on" in config.

(self)

Source from the content-addressed store, hash-verified

133 return tool_decorator
134
135 def _setup(self):
136 """Hook this tool into cherrypy.request.
137
138 The standard CherryPy request object will automatically call
139 this method when the tool is "turned on" in config.
140 """
141 conf = self._merged_args()
142 p = conf.pop('priority', None)
143 if p is None:
144 p = getattr(self.callable, 'priority', self._priority)
145 cherrypy.serving.request.hooks.attach(self._point, self.callable,
146 priority=p, **conf)
147
148
149class HandlerTool(Tool):

Callers 1

__exit__Method · 0.45

Calls 3

_merged_argsMethod · 0.95
popMethod · 0.80
attachMethod · 0.80

Tested by

no test coverage detected