Source code for nanome.beta.nanome_sdk.session.nanome_plugin

from .session_client import SessionClient
from .ui_manager import UIManager


[docs]class NanomePlugin: """Used as parent class for all Nanome plugins. Provides attributes to class instances that inherit from it. self.client: SessionClient for sending/receiving messages to/from Nanome self.ui_manager: UIManager for creating and managing UI elements and callbacks """ client = None ui_manager = UIManager()
[docs] def set_client(self, plugin_id, session_id, version_table): """Used internally by the PluginServer.""" self.client = SessionClient(plugin_id, session_id, version_table)
[docs] async def on_start(self): pass
[docs] async def on_stop(self): pass
[docs] async def on_complex_added_removed(self): pass