A simple plugin registration.
Definition at line 135 of file acmdlib.py.
◆ exists()
def python.acmdlib.Plugins.exists |
( |
|
cls, |
|
|
|
name |
|
) |
| |
Check if plugin exists
Definition at line 147 of file acmdlib.py.
148 """Check if plugin exists
150 return name
in cls._plugins
◆ load()
def python.acmdlib.Plugins.load |
( |
|
cls, |
|
|
|
name |
|
) |
| |
Load given plugin and return it
Definition at line 153 of file acmdlib.py.
154 """Load given plugin and return it
157 return importlib.import_module(cls._plugins[name])
158 except Exception
as err:
159 print(
"** could not load command [%s]:\n%s" % (name, err))
◆ loadAll()
def python.acmdlib.Plugins.loadAll |
( |
|
cls | ) |
|
Load all plugins
Definition at line 162 of file acmdlib.py.
165 for k
in cls._plugins.
keys():
◆ register()
def python.acmdlib.Plugins.register |
( |
|
cls, |
|
|
|
name, |
|
|
|
value |
|
) |
| |
Register plugin
Definition at line 141 of file acmdlib.py.
144 cls._plugins[name] = value
◆ _plugins
python.acmdlib.Plugins._plugins |
|
staticprivate |
The documentation for this class was generated from the following file: