This type represents all possible types of nodes created by External language
plugin. The plugin gets only nodes of this type and can pattern match on them using
the kind
tag.
This type represents all possible types of nodes created by JavaScript language
plugin. The plugin gets only nodes of this type and can pattern match on them using
the kind
tag.
Generated using TypeDoc
Wrattler maintains a dependency graph that is used for evaluating code. The dependency graph is constructed by calling the
bind
operation ofLanguagePlugin
for individual languages supported in Wrattler. The graph is created once Wrattler loads a notebook and it is then updated each time a cell is modified. The dependency graph is static, meaning that it is created by analysing source code, rather than by tracking dependencies at runtime.A node in the graph is represented by the
Node
type. It is identified by thehash
property. ANode
also keeps thevalue
of the part of code that the node represents. See theValues
module for the types representing values. When code in a cell is modified, a new node with a new hash is created. Itsvalue
is initially set tonull
until the user forces evaluation of the node or any node that depends on it.Node
is the main type exported by this module. It represents a graph node, tracksantecedents
(nodes that this one depends on) and, importantly, storesvalue
and alsoerrors
associated with the node.ExportNode
is a special type of node that should be used for nodes that represent exported variables from a cell. If code in your cell produces a data frame, you should create this node for each of the exported data frames. This type has an extra attributevariableName
which Wrattler uses to pass variables to cells below in the notebook.Error
represents error messages andNodeCache
is used when constructing dependency graph to cache nodes so that, when you undo a change, Wrattler reuses the same graph node as before which remembers the previously evaluated results.The remaining types are internal to Wrattler. JavaScript language plugin uses
JsNode
, which can be eitherJsExportNode
orJsCodeNode
. External language plugins usesExternalNode
, which can be eitherExternalExportNode
orExternalCodeNode
.