docstr: Update datasource with data for a new frame.
code: def _update_datasource(self, source, data):
      """
      Update datasource with data for a new frame.
      """
      if isinstance(source, ColumnDataSource):
          if self.handles["static_source"]:
              source.trigger("data", source.data, data)
          else:
              source.data.update(data)
      else:
          source.graph_layout = data
  
imports: from collections import defaultdict
  import numpy
  import param
  from bokeh.models import Bezier, ColumnDataSource, EdgesAndLinkedNodes, NodesAndLinkedEdges, NodesOnly, Patches, StaticLayoutProvider
  from ...core.data import Dataset
  from ...core.options import Cycle, abbreviated_exception
  from ...core.util import dimension_sanitizer, unique_array
  from ...util.transform import dim
  from ..mixins import ChordMixin, GraphMixin
  from ..util import get_directed_graph_paths, process_cmap
  from .chart import ColorbarPlot, PointPlot
  from .element import CompositeElementPlot, LegendPlot
  from .styles import base_properties, fill_properties, line_properties, rgba_tuple, text_properties
label_desc: Use image node_id 6 for calling the GraphPlot obj's underlying member method code with example usage: obj._update_datasource(source, data) without return types