class_docstr: Manage a collection of events and a sequence of callbacks for each.
  
  This is attached to :class:`~IPython.core.interactiveshell.InteractiveShell`
  instances as an ``events`` attribute.
  
  .. note::
  
     This API is experimental in IPython 2.0, and may be revised in future versions.
class_docstr_tok: ["Manage","a","collection","of","events","and","a","sequence","of","callbacks","for","each",".","This","is","attached","to",":","class",":","`","~IPython.core.interactiveshell.InteractiveShell","`","instances","as","an","``","events","``","attribute",".","..","note",":",":","This","API","is","experimental","in","IPython","2.0",",","and","may","be","revised","in","future","versions","."]
docstr: Initialise the :class:`CallbackManager`.
  
  Parameters
  ----------
  shell
      The :class:`~IPython.core.interactiveshell.InteractiveShell` instance
  available_events
      An iterable of names for callback events.
  print_on_error:
      A boolean flag to set whether the EventManager will print a warning which a event errors.
docstr_tok: ["Initialise","the",":","class",":","`","CallbackManager","`",".","Parameters","--","--","--","--","--","shell","The",":","class",":","`","~IPython.core.interactiveshell.InteractiveShell","`","instance","available_events","An","iterable","of","names","for","callback","events",".","print_on_error",":","A","boolean","flag","to","set","whether","the","EventManager","will","print","a","warning","which","a","event","errors","."]
code: def __init__(self, shell, available_events, print_on_error=True):
      """Initialise the :class:`CallbackManager`.
  
      Parameters
      ----------
      shell
          The :class:`~IPython.core.interactiveshell.InteractiveShell` instance
      available_events
          An iterable of names for callback events.
      print_on_error:
          A boolean flag to set whether the EventManager will print a warning which a event errors.
      """
      self.shell = shell
      self.callbacks = {n: [] for n in available_events}
      self.print_on_error = print_on_error
  
file_path: catboost/contrib/python/ipython/py3/IPython/core/events.py
label_desc: Use image node_id 1 to create a new EventManager object from inherited base classes: object with example: obj = EventManager(shell, available_events, print_on_error)