Reset all routes (force plugins to be re-applied) and clear all caches. If an ID or route object is given, only that specific route is affected.
(self, route=None)
| 739 | return removed |
| 740 | |
| 741 | def reset(self, route=None): |
| 742 | ''' Reset all routes (force plugins to be re-applied) and clear all |
| 743 | caches. If an ID or route object is given, only that specific route |
| 744 | is affected. ''' |
| 745 | if route is None: routes = self.routes |
| 746 | elif isinstance(route, Route): routes = [route] |
| 747 | else: routes = [self.routes[route]] |
| 748 | for route in routes: route.reset() |
| 749 | if DEBUG: |
| 750 | for route in routes: route.prepare() |
| 751 | self.trigger_hook('app_reset') |
| 752 | |
| 753 | def close(self): |
| 754 | ''' Close the application and all installed plugins. ''' |
no test coverage detected