Options
All
  • Public
  • Public/Protected
  • All
Menu

The interface for a document model.

Hierarchy

Index

Properties

contentChanged

contentChanged: ISignal<this, void>

A signal emitted when the document content changes.

defaultKernelLanguage

defaultKernelLanguage: string

The default kernel language of the document.

defaultKernelName

defaultKernelName: string

The default kernel name of the document.

dirty

dirty: boolean

The dirty state of the model.

Notes

This should be cleared when the document is loaded from or saved to disk.

isDisposed

isDisposed: boolean

Test whether the object has been disposed.

Notes

This property is always safe to access.

modelDB

modelDB: IModelDB

The underlying IModelDB instance in which model data is stored.

Notes

Making direct edits to the values stored in theIModelDB is not recommended, and may produce unpredictable results.

readOnly

readOnly: boolean

The read-only state of the model.

stateChanged

stateChanged: ISignal<this, IChangedArgsGeneric<any>>

A signal emitted when the model state changes.

Methods

dispose

  • dispose(): void
  • Dispose of the resources held by the object.

    Notes

    If the object's dispose method is called more than once, all calls made after the first will be a no-op.

    Undefined Behavior

    It is undefined behavior to use any functionality of the object after it has been disposed unless otherwise explicitly noted.

    Returns void

fromJSON

  • fromJSON(value: any): void
  • Deserialize the model from JSON.

    Notes

    Should emit a [contentChanged] signal.

    Parameters

    • value: any

    Returns void

fromString

  • fromString(value: string): void
  • Deserialize the model from a string.

    Notes

    Should emit a [contentChanged] signal.

    Parameters

    • value: string

    Returns void

toJSON

  • toJSON(): JSONValue

toString

  • toString(): string

Generated using TypeDoc