Provide ancillary utility functions useful for manipulating Bokeh documents.
- initialize_references_json(references_json: List[ReferenceJson], references: Mapping[ID, Model], setter: Setter | None = None) None ¶
Given a JSON representation of the models in a graph, and new model objects, set the properties on the models from the JSON
JSON) – JSON specifying attributes and values to initialize new model objects with.
A dictionary mapping model IDs to newly created (but not yet initialized) Bokeh models.
This is an “out” parameter. The values it contains will be modified in-place.
This is used to prevent “boomerang” updates to Bokeh apps. (default: None)
In the context of a Bokeh server application, incoming updates to properties will be annotated with the session that is doing the updating. This value is propagated through any subsequent change notifications that the update triggers. The session can compare the event setter to itself, and suppress any updates that originate from itself.
- instantiate_references_json(references_json: List[ReferenceJson], existing_instances: Dict[ID, Model]) Dict[ID, Model] ¶
Given a JSON representation of all the models in a graph, return a dict of new model objects.
JSON) – JSON specifying new Bokeh models to create