ryvencore.Base module¶
- complete_data(data: dict) dict¶
Default implementation for completing data with frontend properties. When running with a frontend that needs to store additional information about components (e.g. current position and color of a node), this frontend then overrode this exact function to add whatever is necessary for adding this data.
- class Base¶
Bases:
objectBase class for all abstract components. Provides functionality for ID counting. Assigns a global ID to every object and provides an optional custom ID counter for additional custom counting.
- class IDCtr¶
Bases:
object- count()¶
increases the counter and returns the new count. first time is 0
- set_count(cnt)¶
- global_id_ctr = <ryvencore.Base.Base.IDCtr object>¶
- id_ctr = None¶
- events = {}¶
- complete_data_function()¶
- data() dict¶
converts the object to a JSON compatible dict for serialization
- complete_data(data: dict) ryvencore.Base.Base.data¶
- on(ev: ryvencore.Base.Event, callback)¶
- off(ev: ryvencore.Base.Event, callback)¶