@@ -85,7 +85,7 @@ export interface ISharedBase extends IObservableDisposable {
8585 * Implement an API for Context information on the shared information.
8686 * This is used by, for example, docregistry to share the file-path of the edited content.
8787 */
88- export interface ISharedDocument extends ISharedBase {
88+ interface ISharedDocumentNoSource extends ISharedBase {
8989 /**
9090 * Document version
9191 */
@@ -117,6 +117,26 @@ export interface ISharedDocument extends ISharedBase {
117117 readonly changed : ISignal < this, DocumentChange > ;
118118}
119119
120+ /**
121+ * Implement an API for Context information on the shared information.
122+ * This is used by, for example, docregistry to share the file-path of the edited content.
123+ */
124+ export interface ISharedDocument extends ISharedDocumentNoSource {
125+ /**
126+ * Get the document source.
127+ *
128+ * @returns Source.
129+ */
130+ getSource ( ) : string | JSONValue ;
131+
132+ /**
133+ * Set the document source.
134+ *
135+ * @param value New source.
136+ */
137+ setSource ( value : string | JSONValue ) : void ;
138+ }
139+
120140/**
121141 * The ISharedText interface defines models that can be bound to a text editor like CodeMirror.
122142 */
@@ -158,7 +178,7 @@ export interface ISharedText extends ISharedBase {
158178/**
159179 * Text/Markdown/Code files are represented as ISharedFile
160180 */
161- export interface ISharedFile extends ISharedDocument , ISharedText {
181+ export interface ISharedFile extends ISharedDocumentNoSource , ISharedText {
162182 /**
163183 * The changed signal.
164184 */
0 commit comments