]>
git.proxmox.com Git - ceph.git/blob - ceph/src/pybind/mgr/dashboard/plugins/interfaces.py
f9169a0d89a6ea4f6fe17d17e0a1c58e58dc1582
1 # -*- coding: utf-8 -*-
2 from __future__
import absolute_import
4 from . import PLUGIN_MANAGER
as PM
, Interface
, Mixin
# pylint: disable=cyclic-import
9 mgr
= mgr
# type: ignore
12 class CanCherrypy(Mixin
):
14 request
= cherrypy
.request
15 response
= cherrypy
.response
19 class Initializable(Interface
):
23 Placeholder for module scope initialization
28 class Setupable(Interface
):
32 Placeholder for plugin setup, right after server start.
33 CanMgr.mgr is initialized by then.
38 class HasOptions(Interface
):
40 def get_options(self
):
45 class HasCommands(Interface
):
47 def register_commands(self
):
52 class HasControllers(Interface
):
54 def get_controllers(self
):
59 class ConfiguresCherryPy(Interface
):
61 def configure_cherrypy(self
, config
):
65 class FilterRequest(object):
67 class BeforeHandler(Interface
):
69 def filter_request_before_handler(self
, request
):