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)
| 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 | |
| 149 | class HandlerTool(Tool): |
no test coverage detected