Options
All
  • Public
  • Public/Protected
  • All
Menu

Class OutputModel

The default implementation of a notebook output model. The namespace for OutputModel statics.

Hierarchy

  • OutputModel

Implements

Index

Constructors

constructor

Properties

Private _changed

_changed: Signal<this, void> = new Signal<this, void>(this)

Private _data

_data: IObservableJSON

Private _metadata

_metadata: IObservableJSON

Private _raw

_raw: JSONObject

Private _rawData

_rawData: ReadonlyJSONObject

Private _rawMetadata

_rawMetadata: ReadonlyJSONObject

executionCount

executionCount: nbformat.ExecutionCount

The execution count.

trusted

trusted: boolean

Whether the model is trusted.

type

type: string

The output type.

Accessors

changed

  • get changed(): ISignal<this, void>
  • A signal emitted when the output model changes.

    Returns ISignal<this, void>

data

  • get data(): ReadonlyJSONObject
  • The data associated with the model.

    Returns ReadonlyJSONObject

metadata

  • get metadata(): ReadonlyJSONObject
  • The metadata associated with the model.

    Returns ReadonlyJSONObject

Methods

Private _updateObservable

  • _updateObservable(observable: IObservableJSON, data: ReadonlyJSONObject): void
  • Update an observable JSON object using a readonly JSON object.

    Parameters

    • observable: IObservableJSON
    • data: ReadonlyJSONObject

    Returns void

dispose

  • dispose(): void
  • Dispose of the resources used by the output model.

    Returns void

setData

  • setData(options: ISetDataOptions): void
  • Set the data associated with the model.

    Notes

    Depending on the implementation of the mime model, this call may or may not have deferred effects,

    Parameters

    • options: ISetDataOptions

    Returns void

toJSON

  • toJSON(): nbformat.IOutput

Static getData

  • getData(output: nbformat.IOutput): JSONObject
  • Get the data for an output.

    params

    output - A kernel output message payload.

    Parameters

    • output: nbformat.IOutput

    Returns JSONObject

    • The data for the payload.

Static getMetadata

  • getMetadata(output: nbformat.IOutput): JSONObject
  • Get the metadata from an output message.

    params

    output - A kernel output message payload.

    Parameters

    • output: nbformat.IOutput

    Returns JSONObject

    • The metadata for the payload.

Generated using TypeDoc