@hydranium/glsp-server 1.0.0-next.79 → 1.0.0-next.85
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/command/hydranium-glsp-recording-command.d.ts +21 -21
- package/lib/command/hydranium-glsp-recording-command.d.ts.map +1 -1
- package/lib/command/hydranium-glsp-recording-command.js +24 -25
- package/lib/command/hydranium-glsp-recording-command.js.map +1 -1
- package/lib/state/abstract-hydranium-glsp-state.d.ts +65 -42
- package/lib/state/abstract-hydranium-glsp-state.d.ts.map +1 -1
- package/lib/state/abstract-hydranium-glsp-state.js +58 -41
- package/lib/state/abstract-hydranium-glsp-state.js.map +1 -1
- package/lib/state/full-text-hydranium-glsp-state.d.ts +3 -3
- package/lib/state/full-text-hydranium-glsp-state.d.ts.map +1 -1
- package/lib/state/full-text-hydranium-glsp-state.js +4 -3
- package/lib/state/full-text-hydranium-glsp-state.js.map +1 -1
- package/lib/state/reconcile-source-model-write.d.ts +7 -6
- package/lib/state/reconcile-source-model-write.d.ts.map +1 -1
- package/lib/state/reconcile-source-model-write.js +4 -4
- package/lib/state/reconcile-source-model-write.js.map +1 -1
- package/lib/state/reconciling-multi-document-glsp-state.d.ts +15 -14
- package/lib/state/reconciling-multi-document-glsp-state.d.ts.map +1 -1
- package/lib/state/reconciling-multi-document-glsp-state.js +21 -20
- package/lib/state/reconciling-multi-document-glsp-state.js.map +1 -1
- package/lib/state/reconciling-transfer-hydranium-glsp-state.d.ts +3 -3
- package/lib/state/reconciling-transfer-hydranium-glsp-state.d.ts.map +1 -1
- package/lib/state/reconciling-transfer-hydranium-glsp-state.js +6 -6
- package/lib/state/reconciling-transfer-hydranium-glsp-state.js.map +1 -1
- package/lib/storage/hydranium-glsp-storage.d.ts +10 -10
- package/lib/storage/hydranium-glsp-storage.d.ts.map +1 -1
- package/lib/storage/hydranium-glsp-storage.js.map +1 -1
- package/lib/validation/diagnostic-markers.d.ts +2 -2
- package/lib/validation/diagnostic-markers.d.ts.map +1 -1
- package/lib/validation/diagnostic-markers.js.map +1 -1
- package/lib/validation/hydranium-glsp-model-validator.d.ts.map +1 -1
- package/lib/validation/hydranium-glsp-model-validator.js +1 -1
- package/lib/validation/hydranium-glsp-model-validator.js.map +1 -1
- package/package.json +7 -7
- package/src/command/hydranium-glsp-recording-command.ts +25 -25
- package/src/state/abstract-hydranium-glsp-state.ts +85 -51
- package/src/state/full-text-hydranium-glsp-state.ts +5 -4
- package/src/state/reconcile-source-model-write.ts +10 -9
- package/src/state/reconciling-multi-document-glsp-state.ts +22 -21
- package/src/state/reconciling-transfer-hydranium-glsp-state.ts +7 -7
- package/src/storage/hydranium-glsp-storage.ts +10 -10
- package/src/validation/diagnostic-markers.ts +2 -2
- package/src/validation/hydranium-glsp-model-validator.ts +3 -3
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
********************************************************************************/
|
|
9
9
|
import { type JsonModelState } from '@eclipse-glsp/server';
|
|
10
10
|
import { type AstNode } from '@hydranium/langium';
|
|
11
|
-
import { type MaybePromise } from '@hydranium/protocol';
|
|
11
|
+
import { type BasedOn, type MaybePromise } from '@hydranium/protocol';
|
|
12
12
|
import { AbstractHydraniumGlspState } from './abstract-hydranium-glsp-state.js';
|
|
13
13
|
/** Whole-document-text source model: the serialised text of the source root. */
|
|
14
14
|
export interface FullTextSourceModel {
|
|
@@ -29,7 +29,7 @@ export interface FullTextSourceModel {
|
|
|
29
29
|
* because serialization may be async; the sync fast path is preserved.
|
|
30
30
|
* - {@link updateSourceModel} pushes the text back through
|
|
31
31
|
* `ModelService.update` (which accepts a raw text payload) and captures the
|
|
32
|
-
* re-parsed root
|
|
32
|
+
* re-parsed root, gated on the caller's `basedOn`.
|
|
33
33
|
*
|
|
34
34
|
* No `baseline` / conflict reconcile: a whole-document model has exactly one
|
|
35
35
|
* field, so every concurrent edit is a same-field collision and undo / redo
|
|
@@ -38,6 +38,6 @@ export interface FullTextSourceModel {
|
|
|
38
38
|
*/
|
|
39
39
|
export declare class FullTextHydraniumGlspState<TRoot extends AstNode> extends AbstractHydraniumGlspState<TRoot, FullTextSourceModel> implements JsonModelState<FullTextSourceModel> {
|
|
40
40
|
get sourceModel(): MaybePromise<FullTextSourceModel>;
|
|
41
|
-
updateSourceModel(model: FullTextSourceModel): Promise<void>;
|
|
41
|
+
updateSourceModel(model: FullTextSourceModel, basedOn?: BasedOn): Promise<void>;
|
|
42
42
|
}
|
|
43
43
|
//# sourceMappingURL=full-text-hydranium-glsp-state.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"full-text-hydranium-glsp-state.d.ts","sourceRoot":"","sources":["../../src/state/full-text-hydranium-glsp-state.ts"],"names":[],"mappings":"AAAA;;;;;;;kFAOkF;AAElF,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,sBAAsB,CAAC;AAE3D,OAAO,EAAE,KAAK,OAAO,EAAE,MAAM,oBAAoB,CAAC;AAElD,OAAO,EAAiB,KAAK,YAAY,EAAE,MAAM,qBAAqB,CAAC;
|
|
1
|
+
{"version":3,"file":"full-text-hydranium-glsp-state.d.ts","sourceRoot":"","sources":["../../src/state/full-text-hydranium-glsp-state.ts"],"names":[],"mappings":"AAAA;;;;;;;kFAOkF;AAElF,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,sBAAsB,CAAC;AAE3D,OAAO,EAAE,KAAK,OAAO,EAAE,MAAM,oBAAoB,CAAC;AAElD,OAAO,EAAE,KAAK,OAAO,EAAiB,KAAK,YAAY,EAAE,MAAM,qBAAqB,CAAC;AACrF,OAAO,EAAE,0BAA0B,EAAE,MAAM,oCAAoC,CAAC;AAEhF,gFAAgF;AAChF,MAAM,WAAW,mBAAmB;IACjC,IAAI,EAAE,MAAM,CAAC;CACf;AAED;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,qBACa,0BAA0B,CAAC,KAAK,SAAS,OAAO,CAC1D,SAAQ,0BAA0B,CAAC,KAAK,EAAE,mBAAmB,CAC7D,YAAW,cAAc,CAAC,mBAAmB,CAAC;IAE9C,IAAI,WAAW,IAAI,YAAY,CAAC,mBAAmB,CAAC,CAInD;IAEK,iBAAiB,CAAC,KAAK,EAAE,mBAAmB,EAAE,OAAO,GAAE,OAAsB,GAAG,OAAO,CAAC,IAAI,CAAC;CASrG"}
|
|
@@ -31,7 +31,7 @@ import { AbstractHydraniumGlspState } from './abstract-hydranium-glsp-state.js';
|
|
|
31
31
|
* because serialization may be async; the sync fast path is preserved.
|
|
32
32
|
* - {@link updateSourceModel} pushes the text back through
|
|
33
33
|
* `ModelService.update` (which accepts a raw text payload) and captures the
|
|
34
|
-
* re-parsed root
|
|
34
|
+
* re-parsed root, gated on the caller's `basedOn`.
|
|
35
35
|
*
|
|
36
36
|
* No `baseline` / conflict reconcile: a whole-document model has exactly one
|
|
37
37
|
* field, so every concurrent edit is a same-field collision and undo / redo
|
|
@@ -44,11 +44,12 @@ let FullTextHydraniumGlspState = class FullTextHydraniumGlspState extends Abstra
|
|
|
44
44
|
const text = serializer.serializeAst(this._sourceRoot);
|
|
45
45
|
return isPromiseLike(text) ? text.then(value => ({ text: value })) : { text };
|
|
46
46
|
}
|
|
47
|
-
async updateSourceModel(model) {
|
|
47
|
+
async updateSourceModel(model, basedOn = this.basedOn) {
|
|
48
48
|
const document = await this.sharedServices.model.ModelService.update({
|
|
49
49
|
uri: this._sourceUri,
|
|
50
50
|
model: model.text,
|
|
51
|
-
clientId: this.clientId
|
|
51
|
+
clientId: this.clientId,
|
|
52
|
+
basedOn
|
|
52
53
|
});
|
|
53
54
|
this.setSourceRoot(this._sourceUri, document.root);
|
|
54
55
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"full-text-hydranium-glsp-state.js","sourceRoot":"","sources":["../../src/state/full-text-hydranium-glsp-state.ts"],"names":[],"mappings":"AAAA;;;;;;;kFAOkF;;;;;;;AAGlF,OAAO,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAEvC,OAAO,EAAE,GAAG,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QACH,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,UAAU,EAAE,QAAQ,CAAC,IAAa,CAAC,CAAC;IAC/D,CAAC;CACH,CAAA;AAnBY,0BAA0B;IADtC,UAAU,EAAE;GACA,0BAA0B,CAmBtC"}
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
*
|
|
7
7
|
* SPDX-License-Identifier: MIT
|
|
8
8
|
********************************************************************************/
|
|
9
|
-
import { type ConflictResolver, type Logger } from '@hydranium/protocol';
|
|
9
|
+
import { type BasedOn, type ConflictResolver, type Logger } from '@hydranium/protocol';
|
|
10
10
|
/**
|
|
11
11
|
* The I/O and policy a {@link reconcileSourceModelWrite} call needs. Deliberately
|
|
12
12
|
* a plain record rather than a base class: the states that use it differ in what
|
|
@@ -16,11 +16,12 @@ import { type ConflictResolver, type Logger } from '@hydranium/protocol';
|
|
|
16
16
|
*/
|
|
17
17
|
export interface SourceModelWriteHooks<TModel> {
|
|
18
18
|
/**
|
|
19
|
-
* Write `model` and
|
|
20
|
-
* on the first attempt (opting into the `ConflictError` gate) and
|
|
21
|
-
* on the merged / forced retries, where the
|
|
19
|
+
* Write `model` and record the resulting state. Called with the caller's own
|
|
20
|
+
* `basedOn` on the first attempt (opting into the `ConflictError` gate) and
|
|
21
|
+
* with `'anything'` on the merged / forced retries, where the reconcile has
|
|
22
|
+
* already decided to win and the point is to land the write.
|
|
22
23
|
*/
|
|
23
|
-
persist(model: TModel,
|
|
24
|
+
persist(model: TModel, basedOn: BasedOn): Promise<void>;
|
|
24
25
|
/** Current server-side projection, or `undefined` when unavailable. */
|
|
25
26
|
refetch(): Promise<TModel | undefined>;
|
|
26
27
|
/** Last in-sync projection the user's intent is measured against. */
|
|
@@ -39,5 +40,5 @@ export interface SourceModelWriteHooks<TModel> {
|
|
|
39
40
|
* re-thrown untouched — this function only knows how to handle the specific
|
|
40
41
|
* failure of "the based-on version was superseded".
|
|
41
42
|
*/
|
|
42
|
-
export declare function reconcileSourceModelWrite<TModel extends object>(model: TModel,
|
|
43
|
+
export declare function reconcileSourceModelWrite<TModel extends object>(model: TModel, basedOn: BasedOn, hooks: SourceModelWriteHooks<TModel>): Promise<void>;
|
|
43
44
|
//# sourceMappingURL=reconcile-source-model-write.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"reconcile-source-model-write.d.ts","sourceRoot":"","sources":["../../src/state/reconcile-source-model-write.ts"],"names":[],"mappings":"AAAA;;;;;;;kFAOkF;AAElF,OAAO,EAAE,KAAK,gBAAgB,EAAE,KAAK,MAAM,EAAmB,MAAM,qBAAqB,CAAC;
|
|
1
|
+
{"version":3,"file":"reconcile-source-model-write.d.ts","sourceRoot":"","sources":["../../src/state/reconcile-source-model-write.ts"],"names":[],"mappings":"AAAA;;;;;;;kFAOkF;AAElF,OAAO,EAAE,KAAK,OAAO,EAAE,KAAK,gBAAgB,EAAE,KAAK,MAAM,EAAmB,MAAM,qBAAqB,CAAC;AAExG;;;;;;GAMG;AACH,MAAM,WAAW,qBAAqB,CAAC,MAAM;IAC1C;;;;;OAKG;IACH,OAAO,CAAC,KAAK,EAAE,MAAM,EAAE,OAAO,EAAE,OAAO,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IACxD,uEAAuE;IACvE,OAAO,IAAI,OAAO,CAAC,MAAM,GAAG,SAAS,CAAC,CAAC;IACvC,qEAAqE;IACrE,QAAQ,CAAC,QAAQ,EAAE,MAAM,GAAG,SAAS,CAAC;IACtC,QAAQ,CAAC,gBAAgB,EAAE,gBAAgB,CAAC;IAC5C,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IACxB,gFAAgF;IAChF,iBAAiB,IAAI,IAAI,CAAC;CAC5B;AAED;;;;;;;;GAQG;AACH,wBAAsB,yBAAyB,CAAC,MAAM,SAAS,MAAM,EAClE,KAAK,EAAE,MAAM,EACb,OAAO,EAAE,OAAO,EAChB,KAAK,EAAE,qBAAqB,CAAC,MAAM,CAAC,GACpC,OAAO,CAAC,IAAI,CAAC,CA8Bf"}
|
|
@@ -16,9 +16,9 @@ import { isConflictError } from '@hydranium/protocol';
|
|
|
16
16
|
* re-thrown untouched — this function only knows how to handle the specific
|
|
17
17
|
* failure of "the based-on version was superseded".
|
|
18
18
|
*/
|
|
19
|
-
export async function reconcileSourceModelWrite(model,
|
|
19
|
+
export async function reconcileSourceModelWrite(model, basedOn, hooks) {
|
|
20
20
|
try {
|
|
21
|
-
await hooks.persist(model,
|
|
21
|
+
await hooks.persist(model, basedOn);
|
|
22
22
|
}
|
|
23
23
|
catch (err) {
|
|
24
24
|
if (!isConflictError(err)) {
|
|
@@ -27,7 +27,7 @@ export async function reconcileSourceModelWrite(model, version, hooks) {
|
|
|
27
27
|
const outcome = await hooks.conflictResolver.resolve(hooks.baseline ?? model, model, () => hooks.refetch());
|
|
28
28
|
switch (outcome.status) {
|
|
29
29
|
case 'merged':
|
|
30
|
-
await hooks.persist(outcome.merged);
|
|
30
|
+
await hooks.persist(outcome.merged, 'anything');
|
|
31
31
|
return;
|
|
32
32
|
case 'no-op':
|
|
33
33
|
hooks.logger.debug(`updateSourceModel no-op (v${err.expectedVersion} → v${err.actualVersion}); already in sync`);
|
|
@@ -39,7 +39,7 @@ export async function reconcileSourceModelWrite(model, version, hooks) {
|
|
|
39
39
|
return;
|
|
40
40
|
case 'unavailable':
|
|
41
41
|
hooks.logger.warn(`updateSourceModel refetch unavailable (v${err.expectedVersion} → v${err.actualVersion}); forcing without version`);
|
|
42
|
-
await hooks.persist(model);
|
|
42
|
+
await hooks.persist(model, 'anything');
|
|
43
43
|
return;
|
|
44
44
|
}
|
|
45
45
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"reconcile-source-model-write.js","sourceRoot":"","sources":["../../src/state/reconcile-source-model-write.ts"],"names":[],"mappings":"AAAA;;;;;;;kFAOkF;AAElF,OAAO,
|
|
1
|
+
{"version":3,"file":"reconcile-source-model-write.js","sourceRoot":"","sources":["../../src/state/reconcile-source-model-write.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CAAC,KAAK,EAAE,UAAU,CAAC,CAAC;gBACvC,OAAO;QACb,CAAC;IACJ,CAAC;AACJ,CAAC"}
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
********************************************************************************/
|
|
9
9
|
import { type JsonModelState } from '@eclipse-glsp/server';
|
|
10
10
|
import { type AstNode } from '@hydranium/langium';
|
|
11
|
-
import { type TransferElement } from '@hydranium/protocol';
|
|
11
|
+
import { type BasedOn, type TransferElement } from '@hydranium/protocol';
|
|
12
12
|
import { AbstractHydraniumGlspState } from './abstract-hydranium-glsp-state.js';
|
|
13
13
|
/**
|
|
14
14
|
* Source model spanning more than one document: the primary document's
|
|
@@ -66,8 +66,8 @@ export interface MultiDocumentSourceModel<TPrimary extends TransferElement = Tra
|
|
|
66
66
|
* than reconciled. Gating them too would need a per-document reconcile whose
|
|
67
67
|
* outcomes can disagree (merge one, conflict another) with no way to un-write the
|
|
68
68
|
* merged one — the atomicity problem again, one layer up. An adopter that wants
|
|
69
|
-
* a coarser check overrides {@link
|
|
70
|
-
* {@link AbstractHydraniumGlspState.
|
|
69
|
+
* a coarser check overrides {@link secondaryBasedOn} to return the version
|
|
70
|
+
* {@link AbstractHydraniumGlspState.snapshotVersionOf} already holds, and takes
|
|
71
71
|
* on the partial-write window named there.
|
|
72
72
|
*/
|
|
73
73
|
export declare class ReconcilingMultiDocumentGlspState<TRoot extends AstNode, TPrimary extends TransferElement = TransferElement> extends AbstractHydraniumGlspState<TRoot, MultiDocumentSourceModel<TPrimary>> implements JsonModelState<MultiDocumentSourceModel<TPrimary>> {
|
|
@@ -112,14 +112,14 @@ export declare class ReconcilingMultiDocumentGlspState<TRoot extends AstNode, TP
|
|
|
112
112
|
* `ConflictError` from the primary, reconcile via the injected policy exactly
|
|
113
113
|
* as the single-document state does — the orchestration is shared.
|
|
114
114
|
*/
|
|
115
|
-
updateSourceModel(model: MultiDocumentSourceModel<TPrimary>,
|
|
115
|
+
updateSourceModel(model: MultiDocumentSourceModel<TPrimary>, basedOn?: BasedOn): Promise<void>;
|
|
116
116
|
/**
|
|
117
117
|
* Write hook — secondaries first (ungated), primary last (gated on
|
|
118
|
-
* `
|
|
118
|
+
* `basedOn`). The order is the failure-mode choice documented on the
|
|
119
119
|
* class, not incidental: override this when the primary is the document the
|
|
120
120
|
* others REFERENCE, since then this order writes the references first.
|
|
121
121
|
*/
|
|
122
|
-
protected persist(model: MultiDocumentSourceModel<TPrimary>,
|
|
122
|
+
protected persist(model: MultiDocumentSourceModel<TPrimary>, basedOn: BasedOn): Promise<{
|
|
123
123
|
root: TRoot;
|
|
124
124
|
}>;
|
|
125
125
|
/**
|
|
@@ -139,24 +139,25 @@ export declare class ReconcilingMultiDocumentGlspState<TRoot extends AstNode, TP
|
|
|
139
139
|
* it is also cheap enough to run per document per write.
|
|
140
140
|
*/
|
|
141
141
|
protected hasChanged(baseline: object | undefined, candidate: object): boolean;
|
|
142
|
-
/** Write the primary document, opting into the conflict gate
|
|
143
|
-
protected persistPrimary(model: TPrimary,
|
|
142
|
+
/** Write the primary document, opting into the conflict gate unless `basedOn` is `'anything'`. */
|
|
143
|
+
protected persistPrimary(model: TPrimary, basedOn: BasedOn): Promise<{
|
|
144
144
|
root: TRoot;
|
|
145
145
|
}>;
|
|
146
146
|
/**
|
|
147
|
-
* Write one secondary document, gated on whatever {@link
|
|
147
|
+
* Write one secondary document, gated on whatever {@link secondaryBasedOn}
|
|
148
148
|
* returns. Override alongside {@link persistPrimary} when the round-trip
|
|
149
149
|
* differs per document role — a layout file and a semantic file need not
|
|
150
150
|
* share a serializer.
|
|
151
151
|
*/
|
|
152
152
|
protected persistSecondary(uri: string, model: TransferElement): Promise<void>;
|
|
153
153
|
/**
|
|
154
|
-
*
|
|
155
|
-
*
|
|
154
|
+
* What a secondary write declares it was based on. Default `'anything'` —
|
|
155
|
+
* ungated, because gating the whole set needs a per-document reconcile whose
|
|
156
|
+
* outcomes can disagree, with no way to un-write an already-merged sibling.
|
|
156
157
|
*
|
|
157
158
|
* **The hook exists so that opting in is an override rather than a
|
|
158
|
-
* reimplementation.** The state already
|
|
159
|
-
* ({@link AbstractHydraniumGlspState.
|
|
159
|
+
* reimplementation.** The state already holds what such a check needs
|
|
160
|
+
* ({@link AbstractHydraniumGlspState.snapshotVersionOf}), and returning that
|
|
160
161
|
* value here is the whole opt-in; without it the only place to put the
|
|
161
162
|
* comparison is a copy of {@link persistSecondary}, which then has to be kept
|
|
162
163
|
* in step with the framework's write call.
|
|
@@ -166,7 +167,7 @@ export declare class ReconcilingMultiDocumentGlspState<TRoot extends AstNode, TP
|
|
|
166
167
|
* the reconcile then drops the edit those writes stay. Weigh that against the
|
|
167
168
|
* default, which lets a foreign edit to a secondary be overwritten silently.
|
|
168
169
|
*/
|
|
169
|
-
protected
|
|
170
|
+
protected secondaryBasedOn(_uri: string): BasedOn;
|
|
170
171
|
/**
|
|
171
172
|
* Refetch hook — the current settled projection across the write set, used by
|
|
172
173
|
* the conflict resolver to replay the user's intent against fresh state.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"reconciling-multi-document-glsp-state.d.ts","sourceRoot":"","sources":["../../src/state/reconciling-multi-document-glsp-state.ts"],"names":[],"mappings":"AAAA;;;;;;;kFAOkF;AAElF,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,sBAAsB,CAAC;AAE3D,OAAO,EAAE,KAAK,OAAO,EAAE,MAAM,oBAAoB,CAAC;AAClD,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,qBAAqB,CAAC;
|
|
1
|
+
{"version":3,"file":"reconciling-multi-document-glsp-state.d.ts","sourceRoot":"","sources":["../../src/state/reconciling-multi-document-glsp-state.ts"],"names":[],"mappings":"AAAA;;;;;;;kFAOkF;AAElF,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,sBAAsB,CAAC;AAE3D,OAAO,EAAE,KAAK,OAAO,EAAE,MAAM,oBAAoB,CAAC;AAClD,OAAO,EAAE,KAAK,OAAO,EAAE,KAAK,eAAe,EAAE,M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AAQ,EAAE,MAAM,GAAG,SAAS,EAAE,SAAS,EAAE,MAAM,GAAG,OAAO;IAI9E,kGAAkG;cAClF,cAAc,CAAC,KAAK,EAAE,QAAQ,EAAE,OAAO,EAAE,OAAO,GAAG,OAAO,CAAC;QAAE,IAAI,EAAE,KAAK,CAAA;KAAE,CAAC;IAU3F;;;;;OAKG;cACa,gBAAgB,CAAC,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,eAAe,GAAG,OAAO,CAAC,IAAI,CAAC;IASpF;;;;;;;;;;;;;;;;OAgBG;IACH,SAAS,CAAC,gBAAgB,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO;IAIjD;;;;;;OAMG;cACa,OAAO,IAAI,OAAO,CAAC,wBAAwB,CAAC,QAAQ,CAAC,GAAG,SAAS,CAAC;IAelF,wFAAwF;IACxF,SAAS,CAAC,eAAe,CAAC,GAAG,EAAE,MAAM,GAAG,eAAe,GAAG,SAAS;IAKnE,oFAAoF;IACpF,SAAS,CAAC,WAAW,CAAC,CAAC,SAAS,eAAe,GAAG,eAAe,EAAE,IAAI,EAAE,OAAO,GAAG,CAAC;CAGtF"}
|
|
@@ -55,8 +55,8 @@ import { reconcileSourceModelWrite } from './reconcile-source-model-write.js';
|
|
|
55
55
|
* than reconciled. Gating them too would need a per-document reconcile whose
|
|
56
56
|
* outcomes can disagree (merge one, conflict another) with no way to un-write the
|
|
57
57
|
* merged one — the atomicity problem again, one layer up. An adopter that wants
|
|
58
|
-
* a coarser check overrides {@link
|
|
59
|
-
* {@link AbstractHydraniumGlspState.
|
|
58
|
+
* a coarser check overrides {@link secondaryBasedOn} to return the version
|
|
59
|
+
* {@link AbstractHydraniumGlspState.snapshotVersionOf} already holds, and takes
|
|
60
60
|
* on the partial-write window named there.
|
|
61
61
|
*/
|
|
62
62
|
let ReconcilingMultiDocumentGlspState = class ReconcilingMultiDocumentGlspState extends AbstractHydraniumGlspState {
|
|
@@ -116,10 +116,10 @@ let ReconcilingMultiDocumentGlspState = class ReconcilingMultiDocumentGlspState
|
|
|
116
116
|
* `ConflictError` from the primary, reconcile via the injected policy exactly
|
|
117
117
|
* as the single-document state does — the orchestration is shared.
|
|
118
118
|
*/
|
|
119
|
-
async updateSourceModel(model,
|
|
120
|
-
return reconcileSourceModelWrite(model,
|
|
121
|
-
persist: async (candidate,
|
|
122
|
-
const { root } = await this.persist(candidate,
|
|
119
|
+
async updateSourceModel(model, basedOn = this.basedOn) {
|
|
120
|
+
return reconcileSourceModelWrite(model, basedOn, {
|
|
121
|
+
persist: async (candidate, candidateBasedOn) => {
|
|
122
|
+
const { root } = await this.persist(candidate, candidateBasedOn);
|
|
123
123
|
this.setSourceRoot(this._sourceUri, root);
|
|
124
124
|
},
|
|
125
125
|
refetch: () => this.refetch(),
|
|
@@ -131,11 +131,11 @@ let ReconcilingMultiDocumentGlspState = class ReconcilingMultiDocumentGlspState
|
|
|
131
131
|
}
|
|
132
132
|
/**
|
|
133
133
|
* Write hook — secondaries first (ungated), primary last (gated on
|
|
134
|
-
* `
|
|
134
|
+
* `basedOn`). The order is the failure-mode choice documented on the
|
|
135
135
|
* class, not incidental: override this when the primary is the document the
|
|
136
136
|
* others REFERENCE, since then this order writes the references first.
|
|
137
137
|
*/
|
|
138
|
-
async persist(model,
|
|
138
|
+
async persist(model, basedOn) {
|
|
139
139
|
for (const [uri, secondary] of Object.entries(model.secondaries)) {
|
|
140
140
|
if (this.hasChanged(this.baseline?.secondaries[uri], secondary)) {
|
|
141
141
|
await this.persistSecondary(uri, secondary);
|
|
@@ -146,7 +146,7 @@ let ReconcilingMultiDocumentGlspState = class ReconcilingMultiDocumentGlspState
|
|
|
146
146
|
// captured rather than round-tripping the document for no reason.
|
|
147
147
|
return { root: this._sourceRoot };
|
|
148
148
|
}
|
|
149
|
-
return this.persistPrimary(model.primary,
|
|
149
|
+
return this.persistPrimary(model.primary, basedOn);
|
|
150
150
|
}
|
|
151
151
|
/**
|
|
152
152
|
* Whether `candidate` differs from the baseline projection of the same
|
|
@@ -167,18 +167,18 @@ let ReconcilingMultiDocumentGlspState = class ReconcilingMultiDocumentGlspState
|
|
|
167
167
|
hasChanged(baseline, candidate) {
|
|
168
168
|
return baseline === undefined || JSON.stringify(baseline) !== JSON.stringify(candidate);
|
|
169
169
|
}
|
|
170
|
-
/** Write the primary document, opting into the conflict gate
|
|
171
|
-
async persistPrimary(model,
|
|
170
|
+
/** Write the primary document, opting into the conflict gate unless `basedOn` is `'anything'`. */
|
|
171
|
+
async persistPrimary(model, basedOn) {
|
|
172
172
|
const document = await this.sharedServices.model.ModelService.update({
|
|
173
173
|
uri: this._sourceUri,
|
|
174
174
|
model,
|
|
175
175
|
clientId: this.clientId,
|
|
176
|
-
|
|
176
|
+
basedOn
|
|
177
177
|
});
|
|
178
178
|
return document;
|
|
179
179
|
}
|
|
180
180
|
/**
|
|
181
|
-
* Write one secondary document, gated on whatever {@link
|
|
181
|
+
* Write one secondary document, gated on whatever {@link secondaryBasedOn}
|
|
182
182
|
* returns. Override alongside {@link persistPrimary} when the round-trip
|
|
183
183
|
* differs per document role — a layout file and a semantic file need not
|
|
184
184
|
* share a serializer.
|
|
@@ -188,16 +188,17 @@ let ReconcilingMultiDocumentGlspState = class ReconcilingMultiDocumentGlspState
|
|
|
188
188
|
uri,
|
|
189
189
|
model,
|
|
190
190
|
clientId: this.clientId,
|
|
191
|
-
|
|
191
|
+
basedOn: this.secondaryBasedOn(uri)
|
|
192
192
|
});
|
|
193
193
|
}
|
|
194
194
|
/**
|
|
195
|
-
*
|
|
196
|
-
*
|
|
195
|
+
* What a secondary write declares it was based on. Default `'anything'` —
|
|
196
|
+
* ungated, because gating the whole set needs a per-document reconcile whose
|
|
197
|
+
* outcomes can disagree, with no way to un-write an already-merged sibling.
|
|
197
198
|
*
|
|
198
199
|
* **The hook exists so that opting in is an override rather than a
|
|
199
|
-
* reimplementation.** The state already
|
|
200
|
-
* ({@link AbstractHydraniumGlspState.
|
|
200
|
+
* reimplementation.** The state already holds what such a check needs
|
|
201
|
+
* ({@link AbstractHydraniumGlspState.snapshotVersionOf}), and returning that
|
|
201
202
|
* value here is the whole opt-in; without it the only place to put the
|
|
202
203
|
* comparison is a copy of {@link persistSecondary}, which then has to be kept
|
|
203
204
|
* in step with the framework's write call.
|
|
@@ -207,8 +208,8 @@ let ReconcilingMultiDocumentGlspState = class ReconcilingMultiDocumentGlspState
|
|
|
207
208
|
* the reconcile then drops the edit those writes stay. Weigh that against the
|
|
208
209
|
* default, which lets a foreign edit to a secondary be overwritten silently.
|
|
209
210
|
*/
|
|
210
|
-
|
|
211
|
-
return
|
|
211
|
+
secondaryBasedOn(_uri) {
|
|
212
|
+
return 'anything';
|
|
212
213
|
}
|
|
213
214
|
/**
|
|
214
215
|
* Refetch hook — the current settled projection across the write set, used by
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"reconciling-multi-document-glsp-state.js","sourceRoot":"","sources":["../../src/state/reconciling-multi-document-glsp-state.ts"],"names":[],"mappings":"AAAA;;;;;;;kFAOkF;;;;;;;AAGlF,OAAO,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAGvC,OAAO,EAAE,0BAA0B,EAAE,MAAM,oCAAoC,CAAC;AAChF,OAAO,EAAE,yBAAyB,EAAE,MAAM,mCAAmC,CAAC;AAmB9E;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2CG;AAEI,IAAM,iCAAiC,GAAvC,MAAM,iCACV,SAAQ,0BAAqE;IAG7E;;;;OAIG;IACO,QAAQ,CAAsC;IAExD;;;;;;;;;;OAUG;IACH,IAAI,WAAW;QACZ,MAAM,WAAW,GAAoC,EAAE,CAAC;QACxD,KAAK,MAAM,GAAG,IAAI,IAAI,CAAC,aAAa,EAAE,CAAC;YACpC,MAAM,UAAU,GAAG,IAAI,CAAC,eAAe,CAAC,GAAG,CAAC,CAAC;YAC7C,IAAI,UAAU,EAAE,CAAC;gBACd,WAAW,CAAC,GAAG,CAAC,GAAG,UAAU,CAAC;YACjC,CAAC;QACJ,CAAC;QACD,OAAO,EAAE,OAAO,EAAE,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC,WAAW,CAAC,EAAE,WAAW,EAAE,CAAC;IACvE,CAAC;IAEQ,aAAa,CAAC,GAAW,EAAE,IAAW;QAC5C,KAAK,CAAC,aAAa,CAAC,GAAG,EAAE,IAAI,CAAC,CAAC;QAC/B,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,CAAC;QACxB,IAAI,CAAC,QAAQ,GAAG,IAAI,CAAC,WAAW,CAAC;IACpC,CAAC;IAED;;;;;;;;;;;;;;;OAeG;IACO,aAAa,CAAC,IAAY;QACjC,wDAAwD;IAC3D,CAAC;IAED;;;;OAIG;IACH,KAAK,CAAC,iBAAiB,CAAC,KAAyC,EAAE,
|
|
1
|
+
{"version":3,"file":"reconciling-multi-document-glsp-state.js","sourceRoot":"","sources":["../../src/state/reconciling-multi-document-glsp-state.ts"],"names":[],"mappings":"AAAA;;;;;;;kFAOkF;;;;;;;AAGlF,OAAO,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAGvC,OAAO,EAAE,0BAA0B,EAAE,MAAM,oCAAoC,CAAC;AAChF,OAAO,EAAE,yBAAyB,EAAE,MAAM,mCAAmC,CAAC;AAmB9E;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2CG;AAEI,IAAM,iCAAiC,GAAvC,MAAM,iCACV,SAAQ,0BAAqE;IAG7E;;;;OAIG;IACO,QAAQ,CAAsC;IAExD;;;;;;;;;;OAUG;IACH,IAAI,WAAW;QACZ,MAAM,WAAW,GAAoC,EAAE,CAAC;QACxD,KAAK,MAAM,GAAG,IAAI,IAAI,CAAC,aAAa,EAAE,CAAC;YACpC,MAAM,UAAU,GAAG,IAAI,CAAC,eAAe,CAAC,GAAG,CAAC,CAAC;YAC7C,IAAI,UAAU,EAAE,CAAC;gBACd,WAAW,CAAC,GAAG,CAAC,GAAG,UAAU,CAAC;YACjC,CA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AAC,CAAC,SAAS,CAAC;IACpD,CAAC;IAED,oFAAoF;IAC1E,WAAW,CAA8C,IAAa;QAC7E,OAAO,IAAI,CAAC,cAAc,CAAC,KAAK,CAAC,eAAe,CAAC,UAAU,CAAC,IAAI,EAAE,SAAS,CAAiB,CAAC;IAChG,CAAC;CACH,CAAA;AArMY,iCAAiC;IAD7C,UAAU,EAAE;GACA,iCAAiC,CAqM7C"}
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
********************************************************************************/
|
|
9
9
|
import { type JsonModelState } from '@eclipse-glsp/server';
|
|
10
10
|
import { type AstNode } from '@hydranium/langium';
|
|
11
|
-
import { type TransferElement } from '@hydranium/protocol';
|
|
11
|
+
import { type BasedOn, type TransferElement } from '@hydranium/protocol';
|
|
12
12
|
import { AbstractHydraniumGlspState } from './abstract-hydranium-glsp-state.js';
|
|
13
13
|
/**
|
|
14
14
|
* Editable GLSP state for adopters whose source model is a **structured
|
|
@@ -68,7 +68,7 @@ export declare class ReconcilingTransferHydraniumGlspState<TRoot extends AstNode
|
|
|
68
68
|
* (force = last-writer-wins, reconciling = field-level merge) shared with
|
|
69
69
|
* undo / redo.
|
|
70
70
|
*/
|
|
71
|
-
updateSourceModel(model: TSourceModel,
|
|
71
|
+
updateSourceModel(model: TSourceModel, basedOn?: BasedOn): Promise<void>;
|
|
72
72
|
/**
|
|
73
73
|
* Persist hook — the only write-side I/O. Default routes the structured
|
|
74
74
|
* model through `ModelService.update` (serialize → reparse), opting into
|
|
@@ -76,7 +76,7 @@ export declare class ReconcilingTransferHydraniumGlspState<TRoot extends AstNode
|
|
|
76
76
|
* round-trip differs override this; the orchestration in
|
|
77
77
|
* {@link updateSourceModel} is unchanged.
|
|
78
78
|
*/
|
|
79
|
-
protected persist(model: TSourceModel,
|
|
79
|
+
protected persist(model: TSourceModel, basedOn: BasedOn): Promise<{
|
|
80
80
|
root: TRoot;
|
|
81
81
|
}>;
|
|
82
82
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"reconciling-transfer-hydranium-glsp-state.d.ts","sourceRoot":"","sources":["../../src/state/reconciling-transfer-hydranium-glsp-state.ts"],"names":[],"mappings":"AAAA;;;;;;;kFAOkF;AAElF,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,sBAAsB,CAAC;AAE3D,OAAO,EAAE,KAAK,OAAO,EAAE,MAAM,oBAAoB,CAAC;AAClD,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,qBAAqB,CAAC;
|
|
1
|
+
{"version":3,"file":"reconciling-transfer-hydranium-glsp-state.d.ts","sourceRoot":"","sources":["../../src/state/reconciling-transfer-hydranium-glsp-state.ts"],"names":[],"mappings":"AAAA;;;;;;;kFAOkF;AAElF,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,sBAAsB,CAAC;AAE3D,OAAO,EAAE,KAAK,OAAO,EAAE,MAAM,oBAAoB,CAAC;AAClD,OAAO,EAAE,KAAK,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,qBAAqB,CAAC;AACzE,OAAO,EAAE,0BAA0B,EAAE,MAAM,oCAAoC,CAAC;AAGhF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8BG;AACH,qBACa,qCAAqC,CAAC,KAAK,SAAS,OAAO,EAAE,YAAY,SAAS,eAAe,CAC3G,SAAQ,0BAA0B,CAAC,KAAK,EAAE,YAAY,CACtD,YAAW,cAAc,CAAC,YAAY,CAAC;IAEvC;;;;;;OAMG;IACH,SAAS,CAAC,QAAQ,CAAC,EAAE,YAAY,CAAC;IAElC;;;;;;;OAOG;IACH,IAAI,WAAW,IAAI,YAAY,CAE9B;IAEQ,aAAa,CAAC,GAAG,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,GAAG,IAAI;IAKtD;;;;;;;OAOG;IACG,iBAAiB,CAAC,KAAK,EAAE,YAAY,EAAE,OAAO,GAAE,OAAsB,GAAG,OAAO,CAAC,IAAI,CAAC;IAiB5F;;;;;;OAMG;cACa,OAAO,CAAC,KAAK,EAAE,YAAY,EAAE,OAAO,EAAE,OAAO,GAAG,OAAO,CAAC;QAAE,IAAI,EAAE,KAAK,CAAA;KAAE,CAAC;IAUxF;;;;;;OAMG;cACa,OAAO,IAAI,OAAO,CAAC,YAAY,GAAG,SAAS,CAAC;CAI9D"}
|
|
@@ -78,13 +78,13 @@ let ReconcilingTransferHydraniumGlspState = class ReconcilingTransferHydraniumGl
|
|
|
78
78
|
* (force = last-writer-wins, reconciling = field-level merge) shared with
|
|
79
79
|
* undo / redo.
|
|
80
80
|
*/
|
|
81
|
-
async updateSourceModel(model,
|
|
81
|
+
async updateSourceModel(model, basedOn = this.basedOn) {
|
|
82
82
|
// Orchestration lives in `reconcileSourceModelWrite` so the multi-document
|
|
83
83
|
// state gets the identical conflict handling; this method supplies only
|
|
84
84
|
// the single-document meaning of persist / project.
|
|
85
|
-
return reconcileSourceModelWrite(model,
|
|
86
|
-
persist: async (candidate,
|
|
87
|
-
const { root } = await this.persist(candidate,
|
|
85
|
+
return reconcileSourceModelWrite(model, basedOn, {
|
|
86
|
+
persist: async (candidate, candidateBasedOn) => {
|
|
87
|
+
const { root } = await this.persist(candidate, candidateBasedOn);
|
|
88
88
|
this.setSourceRoot(this._sourceUri, root);
|
|
89
89
|
},
|
|
90
90
|
refetch: () => this.refetch(),
|
|
@@ -101,12 +101,12 @@ let ReconcilingTransferHydraniumGlspState = class ReconcilingTransferHydraniumGl
|
|
|
101
101
|
* round-trip differs override this; the orchestration in
|
|
102
102
|
* {@link updateSourceModel} is unchanged.
|
|
103
103
|
*/
|
|
104
|
-
async persist(model,
|
|
104
|
+
async persist(model, basedOn) {
|
|
105
105
|
const document = await this.sharedServices.model.ModelService.update({
|
|
106
106
|
uri: this._sourceUri,
|
|
107
107
|
model,
|
|
108
108
|
clientId: this.clientId,
|
|
109
|
-
|
|
109
|
+
basedOn
|
|
110
110
|
});
|
|
111
111
|
return document;
|
|
112
112
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"reconciling-transfer-hydranium-glsp-state.js","sourceRoot":"","sources":["../../src/state/reconciling-transfer-hydranium-glsp-state.ts"],"names":[],"mappings":"AAAA;;;;;;;kFAOkF;;;;;;;AAGlF,OAAO,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAGvC,OAAO,EAAE,0BAA0B,EAAE,MAAM,oCAAoC,CAAC;AAChF,OAAO,EAAE,yBAAyB,EAAE,MAAM,mCAAmC,CAAC;AAE9E;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8BG;AAEI,IAAM,qCAAqC,GAA3C,MAAM,qCACV,SAAQ,0BAA+C;IAGvD;;;;;;OAMG;IACO,QAAQ,CAAgB;IAElC;;;;;;;OAOG;IACH,IAAI,WAAW;QACZ,OAAO,IAAI,CAAC,cAAc,CAAC,KAAK,CAAC,eAAe,CAAC,UAAU,CAAC,IAAI,CAAC,WAAW,EAAE,SAAS,CAA4B,CAAC;IACvH,CAAC;IAEQ,aAAa,CAAC,GAAW,EAAE,IAAW;QAC5C,KAAK,CAAC,aAAa,CAAC,GAAG,EAAE,IAAI,CAAC,CAAC;QAC/B,IAAI,CAAC,QAAQ,GAAG,IAAI,CAAC,WAAW,CAAC;IACpC,CAAC;IAED;;;;;;;OAOG;IACH,KAAK,CAAC,iBAAiB,CAAC,KAAmB,EAAE,
|
|
1
|
+
{"version":3,"file":"reconciling-transfer-hydranium-glsp-state.js","sourceRoot":"","sources":["../../src/state/reconciling-transfer-hydranium-glsp-state.ts"],"names":[],"mappings":"AAAA;;;;;;;kFAOkF;;;;;;;AAGlF,OAAO,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAGvC,OAAO,EAAE,0BAA0B,EAAE,MAAM,oCAAoC,CAAC;AAChF,OAAO,EAAE,yBAAyB,EAAE,MAAM,mCAAmC,CAAC;AAE9E;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8BG;AAEI,IAAM,qCAAqC,GAA3C,MAAM,qCACV,SAAQ,0BAA+C;I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AClE,GAAG,EAAE,IAAI,CAAC,UAAU;YACpB,KAAK;YACL,QAAQ,EAAE,IAAI,CAAC,QAAQ;YACvB,OAAO;SACT,CAAC,CAAC;QACH,OAAO,QAAsC,CAAC;IACjD,CAAC;IAED;;;;;;OAMG;IACO,KAAK,CAAC,OAAO;QACpB,MAAM,KAAK,GAAG,MAAM,IAAI,CAAC,cAAc,CAAC,KAAK,CAAC,YAAY,CAAC,SAAS,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC,KAAK,CAAC,GAAG,EAAE,CAAC,SAAS,CAAC,CAAC;QAC7G,OAAO,KAAK,CAAC,CAAC,CAAE,IAAI,CAAC,cAAc,CAAC,KAAK,CAAC,eAAe,CAAC,UAAU,CAAC,KAAK,CAAC,IAAI,EAAE,SAAS,CAA6B,CAAC,CAAC,CAAC,SAAS,CAAC;IACvI,CAAC;CACH,CAAA;AAnFY,qCAAqC;IADjD,UAAU,EAAE;GACA,qCAAqC,CAmFjD"}
|
|
@@ -146,7 +146,7 @@ export declare class HydraniumGlspStorage<TRoot extends AstNode, TSourceModel =
|
|
|
146
146
|
*/
|
|
147
147
|
protected resubmitDebouncer: Debouncer;
|
|
148
148
|
/** Latest event document awaiting the debounced resubmit; read by {@link flushResubmit} (last write wins). */
|
|
149
|
-
protected pendingResubmitDocument?: AstDocument<AstNode
|
|
149
|
+
protected pendingResubmitDocument?: AstDocument<AstNode>;
|
|
150
150
|
protected init(): void;
|
|
151
151
|
/**
|
|
152
152
|
* Default load flow — {@link doLoadSourceModel}. Adopters whose load flow
|
|
@@ -223,7 +223,7 @@ export declare class HydraniumGlspStorage<TRoot extends AstNode, TSourceModel =
|
|
|
223
223
|
* drag this client authors — the guard above gates the resubmit, not the
|
|
224
224
|
* markers.
|
|
225
225
|
*/
|
|
226
|
-
protected handleSecondaryUpdated(uri: string, event: AstDocumentUpdatedEvent<AstNode
|
|
226
|
+
protected handleSecondaryUpdated(uri: string, event: AstDocumentUpdatedEvent<AstNode>): void;
|
|
227
227
|
/**
|
|
228
228
|
* The primary document's current state, or `undefined` when it is not
|
|
229
229
|
* registered.
|
|
@@ -235,7 +235,7 @@ export declare class HydraniumGlspStorage<TRoot extends AstNode, TSourceModel =
|
|
|
235
235
|
* arrives pre-validation with an empty array — and diagnostics are the reason
|
|
236
236
|
* {@link doUpdateAndSubmit} takes a separate event document at all.
|
|
237
237
|
*/
|
|
238
|
-
protected currentPrimaryDocument(): AstDocument<AstNode
|
|
238
|
+
protected currentPrimaryDocument(): AstDocument<AstNode> | undefined;
|
|
239
239
|
/**
|
|
240
240
|
* React to an external rebuild reaching `Validated`. Self-cleans if the
|
|
241
241
|
* session has vanished but this listener leaked (neither `sessionDisposed`
|
|
@@ -244,7 +244,7 @@ export declare class HydraniumGlspStorage<TRoot extends AstNode, TSourceModel =
|
|
|
244
244
|
* diagnostic markers for every update — including own edits, which skip
|
|
245
245
|
* the resubmit but can still change diagnostics.
|
|
246
246
|
*/
|
|
247
|
-
protected handleModelUpdated(rootUri: string, event: AstDocumentUpdatedEvent<AstNode
|
|
247
|
+
protected handleModelUpdated(rootUri: string, event: AstDocumentUpdatedEvent<AstNode>): Promise<void>;
|
|
248
248
|
/**
|
|
249
249
|
* Whether this storage has outlived its session — disposing it as a side
|
|
250
250
|
* effect when so. Checked from every subscription entry point because GLSP's
|
|
@@ -259,7 +259,7 @@ export declare class HydraniumGlspStorage<TRoot extends AstNode, TSourceModel =
|
|
|
259
259
|
* {@link resubmitDebouncer}, so a burst of rebuilds runs
|
|
260
260
|
* {@link doUpdateAndSubmit} once with the most recent document.
|
|
261
261
|
*/
|
|
262
|
-
protected scheduleUpdateAndSubmit(document: AstDocument<AstNode
|
|
262
|
+
protected scheduleUpdateAndSubmit(document: AstDocument<AstNode>): void;
|
|
263
263
|
/**
|
|
264
264
|
* Debouncer callback: run the resubmit for the latest pending document
|
|
265
265
|
* against this storage's (invariant) source URI and dispatch the result.
|
|
@@ -271,7 +271,7 @@ export declare class HydraniumGlspStorage<TRoot extends AstNode, TSourceModel =
|
|
|
271
271
|
* mark our stack clean so the editor doesn't prompt to re-save identical
|
|
272
272
|
* content. Our own saves already settle the stack through the save flow.
|
|
273
273
|
*/
|
|
274
|
-
protected handleModelSaved(event: AstDocumentSavedEvent<AstNode
|
|
274
|
+
protected handleModelSaved(event: AstDocumentSavedEvent<AstNode>): void;
|
|
275
275
|
/**
|
|
276
276
|
* Re-settle to a guaranteed fully-linked + reprojected root, capture it, and
|
|
277
277
|
* (unless suppressed) resubmit a deduped external GModel. Diagnostics for the
|
|
@@ -280,13 +280,13 @@ export declare class HydraniumGlspStorage<TRoot extends AstNode, TSourceModel =
|
|
|
280
280
|
* pre-validation, and this path re-settles precisely to escape a transient
|
|
281
281
|
* mid-rebuild snapshot.
|
|
282
282
|
*/
|
|
283
|
-
protected doUpdateAndSubmit(rootUri: string, eventDocument: AstDocument<AstNode
|
|
283
|
+
protected doUpdateAndSubmit(rootUri: string, eventDocument: AstDocument<AstNode>): Promise<Action[]>;
|
|
284
284
|
/**
|
|
285
285
|
* Recompute the desired edit mode from the document's structural-error state,
|
|
286
286
|
* flip {@link AbstractHydraniumGlspState.editMode}, and — only on a transition —
|
|
287
287
|
* return the {@link onParseErrorChanged} actions. No transition → no actions.
|
|
288
288
|
*/
|
|
289
|
-
protected refreshEditMode(document: AstDocument<AstNode
|
|
289
|
+
protected refreshEditMode(document: AstDocument<AstNode>): Action[];
|
|
290
290
|
/**
|
|
291
291
|
* Seam: is the AST structurally broken (lexing/parsing errors)? Drives both
|
|
292
292
|
* READONLY mode and the GModel resubmit skip — keeping the last valid canvas
|
|
@@ -294,7 +294,7 @@ export declare class HydraniumGlspStorage<TRoot extends AstNode, TSourceModel =
|
|
|
294
294
|
* carrying a Langium `lexing-error` / `parsing-error` code. Adopters override
|
|
295
295
|
* to compose additional break reasons.
|
|
296
296
|
*/
|
|
297
|
-
protected isStructurallyBroken(document: AstDocument<AstNode
|
|
297
|
+
protected isStructurallyBroken(document: AstDocument<AstNode>): boolean;
|
|
298
298
|
/**
|
|
299
299
|
* Seam: actions to emit when the structural-broken state transitions.
|
|
300
300
|
* Default: a {@link SetEditModeAction} toggling READONLY ↔ EDITABLE — editing
|
|
@@ -325,7 +325,7 @@ export declare class HydraniumGlspStorage<TRoot extends AstNode, TSourceModel =
|
|
|
325
325
|
* the validation clear a moment later. Measured on a browser host, polling the
|
|
326
326
|
* overlay: no element, empty, the sentence, empty again.
|
|
327
327
|
*/
|
|
328
|
-
protected onParseErrorChanged(_document: AstDocument<AstNode
|
|
328
|
+
protected onParseErrorChanged(_document: AstDocument<AstNode>, broken: boolean): Action[];
|
|
329
329
|
/**
|
|
330
330
|
* Seam: extra actions to dispatch right after the initial settled root is
|
|
331
331
|
* captured (e.g. an adopter-specific status or palette refresh). Default: none.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"hydranium-glsp-storage.d.ts","sourceRoot":"","sources":["../../src/storage/hydranium-glsp-storage.ts"],"names":[],"mappings":"AAAA;;;;;;;kFAOkF;AAGlF,OAAO,EACJ,KAAK,MAAM,EACX,gBAAgB,EAChB,KAAK,aAAa,EAClB,KAAK,qBAAqB,EAC1B,oBAAoB,EAEpB,KAAK,mBAAmB,EACxB,KAAK,UAAU,EAGf,MAAM,IAAI,UAAU,EACpB,KAAK,YAAY,EAGjB,cAAc,EACd,KAAK,kBAAkB,EAEvB,KAAK,eAAe,EAEpB,KAAK,kBAAkB,EAEzB,MAAM,sBAAsB,CAAC;AAC9B,OAAO,EAAE,SAAS,EAAiB,oBAAoB,EAAE,MAAM,qBAAqB,CAAC;AAErF,OAAO,EAAE,KAAK,OAAO,EAAE,MAAM,oBAAoB,CAAC;AAElD,OAAO,EAAE,WAAW,EAAE,KAAK,qBAAqB,EAAE,KAAK,uBAAuB,EAAE,KAAK,oBAAoB,EAAE,MAAM,iBAAiB,CAAC;AAEnI,OAAO,EAAE,KAAK,0BAA0B,EAAE,MAAM,2CAA2C,CAAC;AAC5F,OAAO,EAAE,KAAK,8BAA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