class_docstr: Base class for all class types that have Bokeh properties.
  
      
class_docstr_tok: ["Base","class","for","all","class","types","that","have","Bokeh","properties","."]
docstr: Set a property value on this object from JSON.
  
  Args:
      name: (str) : name of the attribute to set
  
      json: (JSON-value) : value to set to the attribute to
  
      models (dict or None, optional) :
          Mapping of model ids to models (default: None)
  
          This is needed in cases where the attributes to update also
          have values that have references.
  
      setter(ClientSession or ServerSession or None, optional) :
          This is used to prevent "boomerang" updates to Bokeh apps.
  
          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.
  
  Returns:
      None
docstr_tok: ["Set","a","property","value","on","this","object","from","JSON",".","Args",":","name",":","(","str",")",":","name","of","the","attribute","to","set","json",":","(","JSON-value",")",":","value","to","set","to","the","attribute","to","models","(","dict","or","None",",","optional",")",":","Mapping","of","model","ids","to","models","(","default",":","None",")","This","is","needed","in","cases","where","the","attributes","to","update","also","have","values","that","have","references",".","setter","(","ClientSession","or","ServerSession","or","None",",","optional",")",":","This","is","used","to","prevent","``","boomerang","''","updates","to","Bokeh","apps",".","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",".","Returns",":","None"]
code: def set_from_json(
      self, name: str, value: Any, *, setter: Setter | None = None
  ) -> None:
      """Set a property value on this object from JSON.
  
      Args:
          name: (str) : name of the attribute to set
  
          json: (JSON-value) : value to set to the attribute to
  
          models (dict or None, optional) :
              Mapping of model ids to models (default: None)
  
              This is needed in cases where the attributes to update also
              have values that have references.
  
          setter(ClientSession or ServerSession or None, optional) :
              This is used to prevent "boomerang" updates to Bokeh apps.
  
              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.
  
      Returns:
          None
  
      """
      if name in self.properties(_with_props=True):
          log.trace(f"Patching attribute {name!r} of {self!r} with {value!r}")  # type: ignore # TODO: log.trace()
          descriptor = self.lookup(name)
          descriptor.set_from_json(self, value, setter=setter)
      else:
          log.warning(
              "JSON had attr %r on obj %r, which is a client-only or invalid attribute that shouldn't have been sent",
              name,
              self,
          )
  
imports: from __future__ import annotations
  import logging
  import difflib
  from typing import TYPE_CHECKING, Any, Callable, ClassVar, Iterable, Literal, NoReturn, TypedDict, TypeVar, Union, overload
  from weakref import WeakSet
  from ..util.strings import append_docstring, nice_join
  from ..util.warnings import warn
  from .property.descriptor_factory import PropertyDescriptorFactory
  from .property.descriptors import PropertyDescriptor, UnsetValueError
  from .property.override import Override
  from .property.singletons import Intrinsic, Undefined
  from .property.wrappers import PropertyValueContainer
  from .serialization import ObjectRep, Ref, Serializable, Serializer
  from .types import ID
label_desc: Use image node_id 9 for calling the HasProps obj's underlying member method code with example usage: obj.set_from_json(name, value) without return types