class_docstr: A mixin class to provide an interface for registering and
  triggering callbacks.
class_docstr_tok: ["A","mixin","class","to","provide","an","interface","for","registering","and","triggering","callbacks","."]
docstr: Trigger callbacks for ``attr`` on this object.
  
  Args:
      attr (str) :
      old (object) :
      new (object) :
  
  Returns:
      None
docstr_tok: ["Trigger","callbacks","for","``","attr","``","on","this","object",".","Args",":","attr","(","str",")",":","old","(","object",")",":","new","(","object",")",":","Returns",":","None"]
code: def trigger(
      self,
      attr: str,
      old: Any,
      new: Any,
      hint: DocumentPatchedEvent | None = None,
      setter: Setter | None = None,
  ) -> None:
      """Trigger callbacks for ``attr`` on this object.
  
      Args:
          attr (str) :
          old (object) :
          new (object) :
  
      Returns:
          None
  
      """
  
      def invoke() -> None:
          callbacks = self._callbacks.get(attr)
          if callbacks:
              for callback in callbacks:
                  callback(attr, old, new)
  
      if self.document is not None:
          from ..model import Model
  
          self.document.callbacks.notify_change(
              cast(Model, self), attr, old, new, hint, setter, invoke
          )
      else:
          invoke()
  
file_path: bokeh/src/bokeh/util/callback_manager.py
imports: from __future__ import annotations
  import logging
  from collections import defaultdict
  from inspect import signature
  from typing import TYPE_CHECKING, Any, Callable, Sequence, Union, cast
  from ..events import Event, ModelEvent
  from ..util.functions import get_param_info
label_desc: Use image node_id 4 for calling the PropertyCallbackManager obj's underlying member method code with example usage: obj.trigger(attr, old, new, hint, setter) without return types