NotebookController class

A notebook controller represents an entity that can execute notebook cells. This is often referred to as a kernel.

There can be multiple controllers and the editor will let users choose which controller to use for a certain notebook. The {@linkcode NotebookController.notebookTypenotebookType}-property defines for what kind of notebooks a controller is for and the {@linkcode NotebookController.updateNotebookAffinityupdateNotebookAffinity}-function allows controllers to set a preference for specific notebook documents. When a controller has been selected its {@link NotebookController.onDidChangeSelectedNotebooksonDidChangeSelectedNotebooks}-event fires.

When a cell is being run the editor will invoke the {@linkcode NotebookController.executeHandlerexecuteHandler} and a controller is expected to create and finalize a {@link NotebookCellExecutionnotebook cell execution}. However, controllers are also free to create executions by themselves.

Available extensions
Annotations
  • @JS()
  • @staticInterop
  • @anonymous

Constructors

NotebookController({String? id, String? notebookType, List<String>? supportedLanguages, String? label, String? description, String? detail, bool? supportsExecutionOrder, FutureOr<void> executeHandler(List<NotebookCell>, NotebookDocument, NotebookController)?, FutureOr<void> interruptHandler(NotebookDocument)?, Event<IInline81>? onDidChangeSelectedNotebooks, NotebookCellExecution createNotebookCellExecution(NotebookCell)?, void updateNotebookAffinity(NotebookDocument, NotebookControllerAffinity)?, void dispose()?})
factory

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited