@fluidframework/sequence 2.0.0-internal.7.3.0 → 2.0.0-internal.7.4.1
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/CHANGELOG.md +57 -0
- package/api-extractor-lint.json +13 -0
- package/api-extractor.json +8 -3
- package/api-report/sequence.api.md +87 -84
- package/dist/{defaultMap.js → defaultMap.cjs} +9 -4
- package/dist/defaultMap.cjs.map +1 -0
- package/dist/defaultMap.d.ts +3 -3
- package/dist/defaultMap.d.ts.map +1 -1
- package/dist/{defaultMapInterfaces.js → defaultMapInterfaces.cjs} +1 -1
- package/dist/defaultMapInterfaces.cjs.map +1 -0
- package/dist/defaultMapInterfaces.d.ts +11 -10
- package/dist/defaultMapInterfaces.d.ts.map +1 -1
- package/dist/{index.js → index.cjs} +11 -11
- package/dist/index.cjs.map +1 -0
- package/dist/{intervalCollection.js → intervalCollection.cjs} +53 -48
- package/dist/intervalCollection.cjs.map +1 -0
- package/dist/intervalCollection.d.ts +66 -12
- package/dist/intervalCollection.d.ts.map +1 -1
- package/dist/intervalIndex/{endpointInRangeIndex.js → endpointInRangeIndex.cjs} +4 -4
- package/dist/intervalIndex/endpointInRangeIndex.cjs.map +1 -0
- package/dist/intervalIndex/endpointInRangeIndex.d.ts +2 -2
- package/dist/intervalIndex/{endpointIndex.js → endpointIndex.cjs} +3 -3
- package/dist/intervalIndex/endpointIndex.cjs.map +1 -0
- package/dist/intervalIndex/endpointIndex.d.ts +2 -2
- package/dist/intervalIndex/{idIntervalIndex.js → idIntervalIndex.cjs} +2 -2
- package/dist/intervalIndex/idIntervalIndex.cjs.map +1 -0
- package/dist/intervalIndex/idIntervalIndex.d.ts +2 -2
- package/dist/intervalIndex/{index.js → index.cjs} +7 -7
- package/dist/intervalIndex/index.cjs.map +1 -0
- package/dist/intervalIndex/{intervalIndex.js → intervalIndex.cjs} +1 -1
- package/dist/intervalIndex/intervalIndex.cjs.map +1 -0
- package/dist/intervalIndex/intervalIndex.d.ts +1 -1
- package/dist/intervalIndex/{intervalIndexUtils.js → intervalIndexUtils.cjs} +1 -1
- package/dist/intervalIndex/intervalIndexUtils.cjs.map +1 -0
- package/dist/intervalIndex/{overlappingIntervalsIndex.js → overlappingIntervalsIndex.cjs} +5 -5
- package/dist/intervalIndex/overlappingIntervalsIndex.cjs.map +1 -0
- package/dist/intervalIndex/overlappingIntervalsIndex.d.ts +2 -2
- package/dist/intervalIndex/{overlappingSequenceIntervalsIndex.js → overlappingSequenceIntervalsIndex.cjs} +4 -4
- package/dist/intervalIndex/overlappingSequenceIntervalsIndex.cjs.map +1 -0
- package/dist/intervalIndex/overlappingSequenceIntervalsIndex.d.ts +1 -1
- package/dist/intervalIndex/{sequenceIntervalIndexes.js → sequenceIntervalIndexes.cjs} +1 -1
- package/dist/intervalIndex/sequenceIntervalIndexes.cjs.map +1 -0
- package/dist/intervalIndex/sequenceIntervalIndexes.d.ts +2 -1
- package/dist/intervalIndex/sequenceIntervalIndexes.d.ts.map +1 -1
- package/dist/intervalIndex/{startpointInRangeIndex.js → startpointInRangeIndex.cjs} +4 -4
- package/dist/intervalIndex/startpointInRangeIndex.cjs.map +1 -0
- package/dist/intervalIndex/startpointInRangeIndex.d.ts +2 -2
- package/dist/{intervalTree.js → intervalTree.cjs} +1 -1
- package/dist/intervalTree.cjs.map +1 -0
- package/dist/intervals/{index.js → index.cjs} +4 -4
- package/dist/intervals/index.cjs.map +1 -0
- package/dist/intervals/{interval.js → interval.cjs} +2 -6
- package/dist/intervals/interval.cjs.map +1 -0
- package/dist/intervals/interval.d.ts +2 -7
- package/dist/intervals/interval.d.ts.map +1 -1
- package/dist/intervals/{intervalUtils.js → intervalUtils.cjs} +4 -4
- package/dist/intervals/intervalUtils.cjs.map +1 -0
- package/dist/intervals/intervalUtils.d.ts +15 -14
- package/dist/intervals/intervalUtils.d.ts.map +1 -1
- package/dist/intervals/{sequenceInterval.js → sequenceInterval.cjs} +6 -14
- package/dist/intervals/sequenceInterval.cjs.map +1 -0
- package/dist/intervals/sequenceInterval.d.ts +3 -12
- package/dist/intervals/sequenceInterval.d.ts.map +1 -1
- package/dist/{localValues.js → localValues.cjs} +1 -1
- package/dist/localValues.cjs.map +1 -0
- package/dist/localValues.d.ts +2 -1
- package/dist/localValues.d.ts.map +1 -1
- package/dist/{packageVersion.js → packageVersion.cjs} +2 -2
- package/dist/packageVersion.cjs.map +1 -0
- package/dist/packageVersion.d.ts +1 -1
- package/dist/{revertibles.js → revertibles.cjs} +10 -12
- package/dist/revertibles.cjs.map +1 -0
- package/dist/revertibles.d.ts +9 -15
- package/dist/revertibles.d.ts.map +1 -1
- package/dist/sequence-alpha.d.ts +226 -507
- package/dist/sequence-beta.d.ts +131 -1368
- package/dist/sequence-public.d.ts +131 -1368
- package/dist/sequence-untrimmed.d.ts +121 -90
- package/dist/{sequence.js → sequence.cjs} +5 -5
- package/dist/sequence.cjs.map +1 -0
- package/dist/sequence.d.ts +2 -3
- package/dist/sequence.d.ts.map +1 -1
- package/dist/{sequenceDeltaEvent.js → sequenceDeltaEvent.cjs} +4 -4
- package/dist/sequenceDeltaEvent.cjs.map +1 -0
- package/dist/sequenceDeltaEvent.d.ts +4 -4
- package/dist/{sequenceFactory.js → sequenceFactory.cjs} +4 -4
- package/dist/sequenceFactory.cjs.map +1 -0
- package/dist/sequenceFactory.d.ts +1 -1
- package/dist/{sharedIntervalCollection.js → sharedIntervalCollection.cjs} +6 -6
- package/dist/sharedIntervalCollection.cjs.map +1 -0
- package/dist/sharedIntervalCollection.d.ts +3 -3
- package/dist/{sharedSequence.js → sharedSequence.cjs} +4 -4
- package/dist/sharedSequence.cjs.map +1 -0
- package/dist/sharedSequence.d.ts +3 -3
- package/dist/{sharedString.js → sharedString.cjs} +9 -6
- package/dist/sharedString.cjs.map +1 -0
- package/dist/sharedString.d.ts +8 -5
- package/dist/sharedString.d.ts.map +1 -1
- package/lib/{defaultMap.d.ts → defaultMap.d.mts} +4 -4
- package/lib/defaultMap.d.mts.map +1 -0
- package/lib/{defaultMap.js → defaultMap.mjs} +9 -4
- package/lib/defaultMap.mjs.map +1 -0
- package/lib/{defaultMapInterfaces.d.ts → defaultMapInterfaces.d.mts} +11 -10
- package/lib/defaultMapInterfaces.d.mts.map +1 -0
- package/lib/{defaultMapInterfaces.js → defaultMapInterfaces.mjs} +1 -1
- package/lib/defaultMapInterfaces.mjs.map +1 -0
- package/lib/{index.d.ts → index.d.mts} +11 -23
- package/lib/index.d.mts.map +1 -0
- package/lib/{index.js → index.mjs} +11 -11
- package/lib/index.mjs.map +1 -0
- package/lib/{intervalCollection.d.ts → intervalCollection.d.mts} +68 -14
- package/lib/intervalCollection.d.mts.map +1 -0
- package/lib/{intervalCollection.js → intervalCollection.mjs} +53 -50
- package/lib/intervalCollection.mjs.map +1 -0
- package/lib/intervalIndex/{endpointInRangeIndex.d.ts → endpointInRangeIndex.d.mts} +5 -5
- package/lib/intervalIndex/endpointInRangeIndex.d.mts.map +1 -0
- package/lib/intervalIndex/{endpointInRangeIndex.js → endpointInRangeIndex.mjs} +4 -4
- package/lib/intervalIndex/endpointInRangeIndex.mjs.map +1 -0
- package/lib/intervalIndex/{endpointIndex.d.ts → endpointIndex.d.mts} +5 -5
- package/lib/intervalIndex/endpointIndex.d.mts.map +1 -0
- package/lib/intervalIndex/{endpointIndex.js → endpointIndex.mjs} +3 -3
- package/lib/intervalIndex/endpointIndex.mjs.map +1 -0
- package/lib/intervalIndex/{idIntervalIndex.d.ts → idIntervalIndex.d.mts} +4 -4
- package/lib/intervalIndex/idIntervalIndex.d.mts.map +1 -0
- package/lib/intervalIndex/{idIntervalIndex.js → idIntervalIndex.mjs} +2 -2
- package/lib/intervalIndex/idIntervalIndex.mjs.map +1 -0
- package/lib/intervalIndex/{index.d.ts → index.d.mts} +8 -8
- package/lib/intervalIndex/index.d.mts.map +1 -0
- package/lib/intervalIndex/{index.js → index.mjs} +7 -7
- package/{dist/intervalIndex/index.js.map → lib/intervalIndex/index.mjs.map} +1 -1
- package/lib/intervalIndex/{intervalIndex.d.ts → intervalIndex.d.mts} +2 -2
- package/lib/intervalIndex/intervalIndex.d.mts.map +1 -0
- package/lib/intervalIndex/{intervalIndex.js → intervalIndex.mjs} +1 -1
- package/lib/intervalIndex/intervalIndex.mjs.map +1 -0
- package/lib/intervalIndex/{intervalIndexUtils.js → intervalIndexUtils.mjs} +1 -1
- package/lib/intervalIndex/intervalIndexUtils.mjs.map +1 -0
- package/lib/intervalIndex/{overlappingIntervalsIndex.d.ts → overlappingIntervalsIndex.d.mts} +7 -7
- package/lib/intervalIndex/overlappingIntervalsIndex.d.mts.map +1 -0
- package/lib/intervalIndex/{overlappingIntervalsIndex.js → overlappingIntervalsIndex.mjs} +5 -5
- package/lib/intervalIndex/overlappingIntervalsIndex.mjs.map +1 -0
- package/lib/intervalIndex/{overlappingSequenceIntervalsIndex.d.ts → overlappingSequenceIntervalsIndex.d.mts} +3 -3
- package/lib/intervalIndex/overlappingSequenceIntervalsIndex.d.mts.map +1 -0
- package/lib/intervalIndex/{overlappingSequenceIntervalsIndex.js → overlappingSequenceIntervalsIndex.mjs} +4 -4
- package/lib/intervalIndex/overlappingSequenceIntervalsIndex.mjs.map +1 -0
- package/lib/intervalIndex/{sequenceIntervalIndexes.d.ts → sequenceIntervalIndexes.d.mts} +4 -3
- package/lib/intervalIndex/sequenceIntervalIndexes.d.mts.map +1 -0
- package/lib/intervalIndex/{sequenceIntervalIndexes.js → sequenceIntervalIndexes.mjs} +1 -1
- package/lib/intervalIndex/sequenceIntervalIndexes.mjs.map +1 -0
- package/lib/intervalIndex/{startpointInRangeIndex.d.ts → startpointInRangeIndex.d.mts} +5 -5
- package/lib/intervalIndex/startpointInRangeIndex.d.mts.map +1 -0
- package/lib/intervalIndex/{startpointInRangeIndex.js → startpointInRangeIndex.mjs} +4 -4
- package/lib/intervalIndex/startpointInRangeIndex.mjs.map +1 -0
- package/lib/{intervalTree.d.ts → intervalTree.d.mts} +1 -1
- package/lib/intervalTree.d.mts.map +1 -0
- package/lib/{intervalTree.js → intervalTree.mjs} +1 -1
- package/lib/intervalTree.mjs.map +1 -0
- package/lib/intervals/{index.d.ts → index.d.mts} +3 -3
- package/lib/intervals/index.d.mts.map +1 -0
- package/lib/intervals/{index.js → index.mjs} +4 -4
- package/lib/intervals/{index.js.map → index.mjs.map} +1 -1
- package/lib/intervals/{interval.d.ts → interval.d.mts} +4 -9
- package/lib/intervals/interval.d.mts.map +1 -0
- package/lib/intervals/{interval.js → interval.mjs} +2 -6
- package/lib/intervals/interval.mjs.map +1 -0
- package/lib/intervals/{intervalUtils.d.ts → intervalUtils.d.mts} +16 -15
- package/lib/intervals/intervalUtils.d.mts.map +1 -0
- package/lib/intervals/{intervalUtils.js → intervalUtils.mjs} +4 -6
- package/lib/intervals/intervalUtils.mjs.map +1 -0
- package/lib/intervals/{sequenceInterval.d.ts → sequenceInterval.d.mts} +5 -14
- package/lib/intervals/sequenceInterval.d.mts.map +1 -0
- package/lib/intervals/{sequenceInterval.js → sequenceInterval.mjs} +6 -16
- package/lib/intervals/sequenceInterval.mjs.map +1 -0
- package/lib/{localValues.d.ts → localValues.d.mts} +3 -2
- package/lib/localValues.d.mts.map +1 -0
- package/lib/{localValues.js → localValues.mjs} +1 -1
- package/lib/localValues.mjs.map +1 -0
- package/lib/{packageVersion.d.ts → packageVersion.d.mts} +1 -1
- package/lib/{packageVersion.js → packageVersion.mjs} +2 -2
- package/lib/packageVersion.mjs.map +1 -0
- package/lib/{revertibles.d.ts → revertibles.d.mts} +12 -18
- package/lib/revertibles.d.mts.map +1 -0
- package/lib/{revertibles.js → revertibles.mjs} +10 -14
- package/lib/revertibles.mjs.map +1 -0
- package/lib/{sequence-public.d.ts → sequence-alpha.d.mts} +221 -422
- package/lib/sequence-beta.d.mts +270 -0
- package/lib/sequence-public.d.mts +270 -0
- package/lib/{sequence-untrimmed.d.ts → sequence-untrimmed.d.mts} +121 -90
- package/lib/{sequence.d.ts → sequence.d.mts} +6 -7
- package/lib/sequence.d.mts.map +1 -0
- package/lib/{sequence.js → sequence.mjs} +5 -6
- package/lib/sequence.mjs.map +1 -0
- package/lib/{sequenceDeltaEvent.d.ts → sequenceDeltaEvent.d.mts} +4 -4
- package/lib/sequenceDeltaEvent.d.mts.map +1 -0
- package/lib/{sequenceDeltaEvent.js → sequenceDeltaEvent.mjs} +4 -5
- package/lib/sequenceDeltaEvent.mjs.map +1 -0
- package/lib/{sequenceFactory.d.ts → sequenceFactory.d.mts} +2 -2
- package/lib/sequenceFactory.d.mts.map +1 -0
- package/lib/{sequenceFactory.js → sequenceFactory.mjs} +4 -4
- package/lib/sequenceFactory.mjs.map +1 -0
- package/lib/{sharedIntervalCollection.d.ts → sharedIntervalCollection.d.mts} +5 -5
- package/lib/sharedIntervalCollection.d.mts.map +1 -0
- package/lib/{sharedIntervalCollection.js → sharedIntervalCollection.mjs} +6 -6
- package/lib/sharedIntervalCollection.mjs.map +1 -0
- package/lib/{sharedSequence.d.ts → sharedSequence.d.mts} +4 -4
- package/lib/sharedSequence.d.mts.map +1 -0
- package/lib/{sharedSequence.js → sharedSequence.mjs} +4 -4
- package/lib/sharedSequence.mjs.map +1 -0
- package/lib/{sharedString.d.ts → sharedString.d.mts} +10 -7
- package/lib/sharedString.d.mts.map +1 -0
- package/lib/{sharedString.js → sharedString.mjs} +9 -6
- package/lib/sharedString.mjs.map +1 -0
- package/package.json +46 -29
- package/sequence.test-files.tar +0 -0
- package/src/defaultMap.ts +22 -16
- package/src/defaultMapInterfaces.ts +15 -12
- package/src/intervalCollection.ts +131 -67
- package/src/intervalIndex/endpointInRangeIndex.ts +2 -2
- package/src/intervalIndex/endpointIndex.ts +2 -2
- package/src/intervalIndex/idIntervalIndex.ts +2 -2
- package/src/intervalIndex/intervalIndex.ts +1 -1
- package/src/intervalIndex/overlappingIntervalsIndex.ts +2 -2
- package/src/intervalIndex/overlappingSequenceIntervalsIndex.ts +1 -1
- package/src/intervalIndex/sequenceIntervalIndexes.ts +2 -1
- package/src/intervalIndex/startpointInRangeIndex.ts +2 -2
- package/src/intervals/interval.ts +2 -7
- package/src/intervals/intervalUtils.ts +15 -15
- package/src/intervals/sequenceInterval.ts +3 -12
- package/src/localValues.ts +2 -1
- package/src/packageVersion.ts +1 -1
- package/src/revertibles.ts +9 -15
- package/src/sequence.ts +2 -3
- package/src/sequenceDeltaEvent.ts +4 -4
- package/src/sequenceFactory.ts +1 -1
- package/src/sharedIntervalCollection.ts +3 -3
- package/src/sharedSequence.ts +3 -3
- package/src/sharedString.ts +8 -5
- package/tsc-multi.test.json +10 -0
- package/dist/defaultMap.js.map +0 -1
- package/dist/defaultMapInterfaces.js.map +0 -1
- package/dist/index.js.map +0 -1
- package/dist/intervalCollection.js.map +0 -1
- package/dist/intervalIndex/endpointInRangeIndex.js.map +0 -1
- package/dist/intervalIndex/endpointIndex.js.map +0 -1
- package/dist/intervalIndex/idIntervalIndex.js.map +0 -1
- package/dist/intervalIndex/intervalIndex.js.map +0 -1
- package/dist/intervalIndex/intervalIndexUtils.js.map +0 -1
- package/dist/intervalIndex/overlappingIntervalsIndex.js.map +0 -1
- package/dist/intervalIndex/overlappingSequenceIntervalsIndex.js.map +0 -1
- package/dist/intervalIndex/sequenceIntervalIndexes.js.map +0 -1
- package/dist/intervalIndex/startpointInRangeIndex.js.map +0 -1
- package/dist/intervalTree.js.map +0 -1
- package/dist/intervals/index.js.map +0 -1
- package/dist/intervals/interval.js.map +0 -1
- package/dist/intervals/intervalUtils.js.map +0 -1
- package/dist/intervals/sequenceInterval.js.map +0 -1
- package/dist/localValues.js.map +0 -1
- package/dist/packageVersion.js.map +0 -1
- package/dist/revertibles.js.map +0 -1
- package/dist/sequence.js.map +0 -1
- package/dist/sequenceDeltaEvent.js.map +0 -1
- package/dist/sequenceFactory.js.map +0 -1
- package/dist/sharedIntervalCollection.js.map +0 -1
- package/dist/sharedSequence.js.map +0 -1
- package/dist/sharedString.js.map +0 -1
- package/lib/defaultMap.d.ts.map +0 -1
- package/lib/defaultMap.js.map +0 -1
- package/lib/defaultMapInterfaces.d.ts.map +0 -1
- package/lib/defaultMapInterfaces.js.map +0 -1
- package/lib/index.d.ts.map +0 -1
- package/lib/index.js.map +0 -1
- package/lib/intervalCollection.d.ts.map +0 -1
- package/lib/intervalCollection.js.map +0 -1
- package/lib/intervalIndex/endpointInRangeIndex.d.ts.map +0 -1
- package/lib/intervalIndex/endpointInRangeIndex.js.map +0 -1
- package/lib/intervalIndex/endpointIndex.d.ts.map +0 -1
- package/lib/intervalIndex/endpointIndex.js.map +0 -1
- package/lib/intervalIndex/idIntervalIndex.d.ts.map +0 -1
- package/lib/intervalIndex/idIntervalIndex.js.map +0 -1
- package/lib/intervalIndex/index.d.ts.map +0 -1
- package/lib/intervalIndex/index.js.map +0 -1
- package/lib/intervalIndex/intervalIndex.d.ts.map +0 -1
- package/lib/intervalIndex/intervalIndex.js.map +0 -1
- package/lib/intervalIndex/intervalIndexUtils.js.map +0 -1
- package/lib/intervalIndex/overlappingIntervalsIndex.d.ts.map +0 -1
- package/lib/intervalIndex/overlappingIntervalsIndex.js.map +0 -1
- package/lib/intervalIndex/overlappingSequenceIntervalsIndex.d.ts.map +0 -1
- package/lib/intervalIndex/overlappingSequenceIntervalsIndex.js.map +0 -1
- package/lib/intervalIndex/sequenceIntervalIndexes.d.ts.map +0 -1
- package/lib/intervalIndex/sequenceIntervalIndexes.js.map +0 -1
- package/lib/intervalIndex/startpointInRangeIndex.d.ts.map +0 -1
- package/lib/intervalIndex/startpointInRangeIndex.js.map +0 -1
- package/lib/intervalTree.d.ts.map +0 -1
- package/lib/intervalTree.js.map +0 -1
- package/lib/intervals/index.d.ts.map +0 -1
- package/lib/intervals/interval.d.ts.map +0 -1
- package/lib/intervals/interval.js.map +0 -1
- package/lib/intervals/intervalUtils.d.ts.map +0 -1
- package/lib/intervals/intervalUtils.js.map +0 -1
- package/lib/intervals/sequenceInterval.d.ts.map +0 -1
- package/lib/intervals/sequenceInterval.js.map +0 -1
- package/lib/localValues.d.ts.map +0 -1
- package/lib/localValues.js.map +0 -1
- package/lib/packageVersion.js.map +0 -1
- package/lib/revertibles.d.ts.map +0 -1
- package/lib/revertibles.js.map +0 -1
- package/lib/sequence-alpha.d.ts +0 -1587
- package/lib/sequence-beta.d.ts +0 -1507
- package/lib/sequence.d.ts.map +0 -1
- package/lib/sequence.js.map +0 -1
- package/lib/sequenceDeltaEvent.d.ts.map +0 -1
- package/lib/sequenceDeltaEvent.js.map +0 -1
- package/lib/sequenceFactory.d.ts.map +0 -1
- package/lib/sequenceFactory.js.map +0 -1
- package/lib/sharedIntervalCollection.d.ts.map +0 -1
- package/lib/sharedIntervalCollection.js.map +0 -1
- package/lib/sharedSequence.d.ts.map +0 -1
- package/lib/sharedSequence.js.map +0 -1
- package/lib/sharedString.d.ts.map +0 -1
- package/lib/sharedString.js.map +0 -1
- package/tsconfig.esnext.json +0 -6
- /package/lib/intervalIndex/{intervalIndexUtils.d.ts → intervalIndexUtils.d.mts} +0 -0
- /package/lib/intervalIndex/{intervalIndexUtils.d.ts.map → intervalIndexUtils.d.mts.map} +0 -0
- /package/lib/{packageVersion.d.ts.map → packageVersion.d.mts.map} +0 -0
|
@@ -42,7 +42,9 @@ import { LocalReferencePosition } from '@fluidframework/merge-tree';
|
|
|
42
42
|
import { Marker } from '@fluidframework/merge-tree';
|
|
43
43
|
import { MergeTreeDeltaOperationType } from '@fluidframework/merge-tree';
|
|
44
44
|
import { MergeTreeDeltaOperationTypes } from '@fluidframework/merge-tree';
|
|
45
|
+
import { MergeTreeDeltaRevertible } from '@fluidframework/merge-tree';
|
|
45
46
|
import { MergeTreeMaintenanceType } from '@fluidframework/merge-tree';
|
|
47
|
+
import { MergeTreeRevertibleDriver } from '@fluidframework/merge-tree';
|
|
46
48
|
import { PropertiesManager } from '@fluidframework/merge-tree';
|
|
47
49
|
import { PropertySet } from '@fluidframework/merge-tree';
|
|
48
50
|
import { RangeStackMap } from '@fluidframework/merge-tree';
|
|
@@ -53,6 +55,7 @@ import { SharedObject } from '@fluidframework/shared-object-base';
|
|
|
53
55
|
import { SlidingPreference } from '@fluidframework/merge-tree';
|
|
54
56
|
import { SummarySerializer } from '@fluidframework/shared-object-base';
|
|
55
57
|
import { TextSegment } from '@fluidframework/merge-tree';
|
|
58
|
+
import { TypedEventEmitter } from '@fluid-internal/client-utils';
|
|
56
59
|
|
|
57
60
|
/* Excluded from this release type: appendAddIntervalToRevertibles */
|
|
58
61
|
|
|
@@ -64,103 +67,36 @@ import { TextSegment } from '@fluidframework/merge-tree';
|
|
|
64
67
|
|
|
65
68
|
/* Excluded from this release type: appendSharedStringDeltaToRevertibles */
|
|
66
69
|
|
|
67
|
-
|
|
68
|
-
* @public
|
|
69
|
-
*/
|
|
70
|
-
export declare function createEndpointIndex(sharedString: SharedString): IEndpointIndex<SequenceInterval>;
|
|
70
|
+
/* Excluded from this release type: createEndpointIndex */
|
|
71
71
|
|
|
72
|
-
|
|
73
|
-
* @public
|
|
74
|
-
*/
|
|
75
|
-
export declare function createEndpointInRangeIndex(sharedString: SharedString): IEndpointInRangeIndex<SequenceInterval>;
|
|
72
|
+
/* Excluded from this release type: createEndpointInRangeIndex */
|
|
76
73
|
|
|
77
|
-
|
|
78
|
-
* @public
|
|
79
|
-
*/
|
|
80
|
-
export declare function createIdIntervalIndex<TInterval extends ISerializableInterval>(): IIdIntervalIndex<TInterval>;
|
|
74
|
+
/* Excluded from this release type: createIdIntervalIndex */
|
|
81
75
|
|
|
82
|
-
|
|
83
|
-
* @public
|
|
84
|
-
*/
|
|
85
|
-
export declare function createOverlappingIntervalsIndex(sharedString: SharedString): IOverlappingIntervalsIndex<SequenceInterval>;
|
|
76
|
+
/* Excluded from this release type: createOverlappingIntervalsIndex */
|
|
86
77
|
|
|
87
|
-
|
|
88
|
-
* @public
|
|
89
|
-
*/
|
|
90
|
-
export declare function createOverlappingSequenceIntervalsIndex(sharedString: SharedString): SequenceIntervalIndexes.Overlapping;
|
|
78
|
+
/* Excluded from this release type: createOverlappingSequenceIntervalsIndex */
|
|
91
79
|
|
|
92
|
-
|
|
93
|
-
* @public
|
|
94
|
-
*/
|
|
95
|
-
export declare function createStartpointInRangeIndex(sharedString: SharedString): IStartpointInRangeIndex<SequenceInterval>;
|
|
80
|
+
/* Excluded from this release type: createStartpointInRangeIndex */
|
|
96
81
|
|
|
97
82
|
/**
|
|
98
|
-
* @
|
|
83
|
+
* @alpha
|
|
99
84
|
*/
|
|
100
85
|
export declare type DeserializeCallback = (properties: PropertySet) => void;
|
|
101
86
|
|
|
102
87
|
/* Excluded from this release type: discardSharedStringRevertibles */
|
|
103
88
|
|
|
104
|
-
|
|
105
|
-
* Splits the text into regions ending with markers with the given `label`.
|
|
106
|
-
* @param sharedString - String to retrieve text and markers from
|
|
107
|
-
* @param label - label to split on
|
|
108
|
-
* @returns Two parallel lists of text and markers, split by markers with the provided `label`.
|
|
109
|
-
* For example:
|
|
110
|
-
* ```typescript
|
|
111
|
-
* // Say sharedstring has contents "hello<paragraph marker 1>world<paragraph marker 2>missing".
|
|
112
|
-
* const { parallelText, parallelMarkers } = getTextAndMarkers(sharedString, "paragraph");
|
|
113
|
-
* // parallelText === ["hello", "world"]
|
|
114
|
-
* // parallelMarkers === [<paragraph marker 1 object>, <paragraph marker 2 object>]
|
|
115
|
-
* // Note parallelText does not include "missing".
|
|
116
|
-
* ```
|
|
117
|
-
* @public
|
|
118
|
-
*/
|
|
119
|
-
export declare function getTextAndMarkers(sharedString: SharedString, label: string, start?: number, end?: number): {
|
|
120
|
-
parallelText: string[];
|
|
121
|
-
parallelMarkers: Marker[];
|
|
122
|
-
};
|
|
89
|
+
/* Excluded from this release type: getTextAndMarkers */
|
|
123
90
|
|
|
124
|
-
|
|
125
|
-
* @public
|
|
126
|
-
*/
|
|
127
|
-
export declare interface IEndpointIndex<TInterval extends ISerializableInterval> extends IntervalIndex<TInterval> {
|
|
128
|
-
/**
|
|
129
|
-
* @returns the previous interval based on the given position number.
|
|
130
|
-
* If no such interval exists in this index, returns `undefined`
|
|
131
|
-
*/
|
|
132
|
-
previousInterval(pos: number): TInterval | undefined;
|
|
133
|
-
/**
|
|
134
|
-
* @returns the next interval based on the given position number.
|
|
135
|
-
* If no such interval exists in this index, returns `undefined`
|
|
136
|
-
*/
|
|
137
|
-
nextInterval(pos: number): TInterval | undefined;
|
|
138
|
-
}
|
|
91
|
+
/* Excluded from this release type: IEndpointIndex */
|
|
139
92
|
|
|
140
|
-
|
|
141
|
-
* Collection of intervals.
|
|
142
|
-
*
|
|
143
|
-
* Provide additional APIs to support efficiently querying a collection of intervals whose endpoints fall within a specified range.
|
|
144
|
-
* @public
|
|
145
|
-
*/
|
|
146
|
-
export declare interface IEndpointInRangeIndex<TInterval extends ISerializableInterval> extends IntervalIndex<TInterval> {
|
|
147
|
-
/**
|
|
148
|
-
* @returns an array of all intervals contained in this collection whose endpoints locate in the range [start, end] (includes both ends)
|
|
149
|
-
*/
|
|
150
|
-
findIntervalsWithEndpointInRange(start: number, end: number): TInterval[];
|
|
151
|
-
}
|
|
93
|
+
/* Excluded from this release type: IEndpointInRangeIndex */
|
|
152
94
|
|
|
153
|
-
|
|
154
|
-
* @public
|
|
155
|
-
*/
|
|
156
|
-
export declare interface IIdIntervalIndex<TInterval extends ISerializableInterval> extends IntervalIndex<TInterval>, Iterable<TInterval> {
|
|
157
|
-
getIntervalById(id: string): TInterval | undefined;
|
|
158
|
-
[Symbol.iterator](): Iterator<TInterval>;
|
|
159
|
-
}
|
|
95
|
+
/* Excluded from this release type: IIdIntervalIndex */
|
|
160
96
|
|
|
161
97
|
/**
|
|
162
98
|
* Basic interval abstraction
|
|
163
|
-
* @
|
|
99
|
+
* @alpha
|
|
164
100
|
*/
|
|
165
101
|
export declare interface IInterval {
|
|
166
102
|
/**
|
|
@@ -187,19 +123,27 @@ export declare interface IInterval {
|
|
|
187
123
|
* @param b - Interval to compare against
|
|
188
124
|
*/
|
|
189
125
|
compareEnd(b: IInterval): number;
|
|
190
|
-
|
|
126
|
+
/**
|
|
127
|
+
* Modifies one or more of the endpoints of this interval, returning a new interval representing the result.
|
|
128
|
+
*/
|
|
129
|
+
modify(label: string, start: SequencePlace | undefined, end: SequencePlace | undefined, op?: ISequencedDocumentMessage, localSeq?: number, useNewSlidingBehavior?: boolean): IInterval | undefined;
|
|
191
130
|
/**
|
|
192
131
|
* @returns whether this interval overlaps with `b`.
|
|
193
132
|
* Intervals are considered to overlap if their intersection is non-empty.
|
|
194
133
|
*/
|
|
195
134
|
overlaps(b: IInterval): boolean;
|
|
196
|
-
|
|
135
|
+
/**
|
|
136
|
+
* Unions this interval with `b`, returning a new interval.
|
|
137
|
+
* The union operates as a convex hull, i.e. if the two intervals are disjoint, the return value includes
|
|
138
|
+
* intermediate values between the two intervals.
|
|
139
|
+
*/
|
|
140
|
+
union(b: IInterval): IInterval;
|
|
197
141
|
}
|
|
198
142
|
|
|
199
143
|
/**
|
|
200
144
|
* Collection of intervals that supports addition, modification, removal, and efficient spatial querying.
|
|
201
145
|
* Changes to this collection will be incur updates on collaborating clients (i.e. they are not local-only).
|
|
202
|
-
* @
|
|
146
|
+
* @alpha
|
|
203
147
|
*/
|
|
204
148
|
export declare interface IIntervalCollection<TInterval extends ISerializableInterval> extends TypedEventEmitter<IIntervalCollectionEvent<TInterval>> {
|
|
205
149
|
readonly attached: boolean;
|
|
@@ -321,6 +265,7 @@ export declare interface IIntervalCollection<TInterval extends ISerializableInte
|
|
|
321
265
|
removeIntervalById(id: string): TInterval | undefined;
|
|
322
266
|
/**
|
|
323
267
|
* Changes the properties on an existing interval.
|
|
268
|
+
* @deprecated - call change with the id and and object containing the new properties
|
|
324
269
|
* @param id - Id of the interval whose properties should be changed
|
|
325
270
|
* @param props - Property set to apply to the interval. Shallow merging is used between any existing properties
|
|
326
271
|
* and `prop`, i.e. the interval will end up with a property object equivalent to `{ ...oldProps, ...props }`.
|
|
@@ -328,12 +273,26 @@ export declare interface IIntervalCollection<TInterval extends ISerializableInte
|
|
|
328
273
|
changeProperties(id: string, props: PropertySet): any;
|
|
329
274
|
/**
|
|
330
275
|
* Changes the endpoints of an existing interval.
|
|
276
|
+
* @deprecated - call change with the start and end parameters encapsulated in an object
|
|
331
277
|
* @param id - Id of the interval to change
|
|
332
278
|
* @param start - New start value. To leave the endpoint unchanged, pass the current value.
|
|
333
279
|
* @param end - New end value. To leave the endpoint unchanged, pass the current value.
|
|
334
280
|
* @returns the interval that was changed, if it existed in the collection.
|
|
335
281
|
*/
|
|
336
282
|
change(id: string, start: SequencePlace, end: SequencePlace): TInterval | undefined;
|
|
283
|
+
/**
|
|
284
|
+
* Changes the endpoints, properties, or both of an existing interval.
|
|
285
|
+
* @param id - Id of the Interval to change
|
|
286
|
+
* @returns the interval that was changed, if it existed in the collection.
|
|
287
|
+
* Pass the desired new start position, end position, and/or properties in an object. Start and end positions must be changed
|
|
288
|
+
* simultaneously - they must either both be specified or both undefined. To only change the properties, leave both endpoints
|
|
289
|
+
* undefined. To only change the endpoints, leave the properties undefined.
|
|
290
|
+
*/
|
|
291
|
+
change(id: string, { start, end, props }: {
|
|
292
|
+
start?: SequencePlace;
|
|
293
|
+
end?: SequencePlace;
|
|
294
|
+
props?: PropertySet;
|
|
295
|
+
}): TInterval | undefined;
|
|
337
296
|
attachDeserializer(onDeserialize: DeserializeCallback): void;
|
|
338
297
|
/**
|
|
339
298
|
* @returns an iterator over all intervals in this collection.
|
|
@@ -365,6 +324,14 @@ export declare interface IIntervalCollection<TInterval extends ISerializableInte
|
|
|
365
324
|
*/
|
|
366
325
|
gatherIterationResults(results: TInterval[], iteratesForward: boolean, start?: number, end?: number): void;
|
|
367
326
|
/**
|
|
327
|
+
* @deprecated - Users must manually attach the corresponding interval index to utilize this functionality, for instance:
|
|
328
|
+
*
|
|
329
|
+
* ```typescript
|
|
330
|
+
* const overlappingIntervalsIndex = createOverlappingIntervalsIndex(sharedString);
|
|
331
|
+
* collection.attachIndex(overlappingIntervalsIndex)
|
|
332
|
+
* const result = overlappingIntervalsIndex.findOverlappingIntervals(start, end);
|
|
333
|
+
* ```
|
|
334
|
+
*
|
|
368
335
|
* @returns an array of all intervals in this collection that overlap with the interval
|
|
369
336
|
* `[startPosition, endPosition]`.
|
|
370
337
|
*/
|
|
@@ -373,13 +340,34 @@ export declare interface IIntervalCollection<TInterval extends ISerializableInte
|
|
|
373
340
|
* Applies a function to each interval in this collection.
|
|
374
341
|
*/
|
|
375
342
|
map(fn: (interval: TInterval) => void): void;
|
|
343
|
+
/**
|
|
344
|
+
* @deprecated - due to the forthcoming change where the endpointIndex will no longer be
|
|
345
|
+
* automatically added to the collection. Users are advised to independently attach the
|
|
346
|
+
* index to the collection and utilize the API accordingly, for instance:
|
|
347
|
+
* ```typescript
|
|
348
|
+
* const endpointIndex = createEndpointIndex(sharedString);
|
|
349
|
+
* collection.attachIndex(endpointIndex);
|
|
350
|
+
* const result1 = endpointIndex.previousInterval(pos);
|
|
351
|
+
* ```
|
|
352
|
+
* If an index is used repeatedly, applications should generally attach it once and store it in memory.
|
|
353
|
+
*/
|
|
376
354
|
previousInterval(pos: number): TInterval | undefined;
|
|
355
|
+
/**
|
|
356
|
+
* @deprecated - due to the forthcoming change where the endpointIndex will no longer be
|
|
357
|
+
* automatically added to the collection. Users are advised to independently attach the
|
|
358
|
+
* index to the collection and utilize the API accordingly, for instance:
|
|
359
|
+
* ```typescript
|
|
360
|
+
* const endpointIndex = createEndpointIndex(sharedString);
|
|
361
|
+
* collection.attachIndex(endpointIndex);
|
|
362
|
+
* const result2 = endpointIndex.nextInterval(pos);
|
|
363
|
+
* ```
|
|
364
|
+
*/
|
|
377
365
|
nextInterval(pos: number): TInterval | undefined;
|
|
378
366
|
}
|
|
379
367
|
|
|
380
368
|
/**
|
|
381
369
|
* Change events emitted by `IntervalCollection`s
|
|
382
|
-
* @
|
|
370
|
+
* @alpha
|
|
383
371
|
*/
|
|
384
372
|
export declare interface IIntervalCollectionEvent<TInterval extends ISerializableInterval> extends IEvent {
|
|
385
373
|
/**
|
|
@@ -414,37 +402,9 @@ export declare interface IIntervalCollectionEvent<TInterval extends ISerializabl
|
|
|
414
402
|
(event: "propertyChanged", listener: (interval: TInterval, propertyDeltas: PropertySet, local: boolean, op: ISequencedDocumentMessage | undefined) => void): any;
|
|
415
403
|
}
|
|
416
404
|
|
|
417
|
-
|
|
418
|
-
* @sealed
|
|
419
|
-
* @deprecated The methods within have substitutions
|
|
420
|
-
* @public
|
|
421
|
-
*/
|
|
422
|
-
export declare interface IIntervalHelpers<TInterval extends ISerializableInterval> {
|
|
423
|
-
/**
|
|
424
|
-
*
|
|
425
|
-
* @param label - label of the interval collection this interval is being added to. This parameter is
|
|
426
|
-
* irrelevant for transient intervals.
|
|
427
|
-
* @param start - numerical start position of the interval
|
|
428
|
-
* @param end - numerical end position of the interval
|
|
429
|
-
* @param client - client creating the interval
|
|
430
|
-
* @param intervalType - Type of interval to create. Default is SlideOnRemove
|
|
431
|
-
* @param op - If this create came from a remote client, op that created it. Default is undefined (i.e. local)
|
|
432
|
-
* @param fromSnapshot - If this create came from loading a snapshot. Default is false.
|
|
433
|
-
* @param startSide - The side on which the start position lays. See
|
|
434
|
-
* {@link SequencePlace} for additional context
|
|
435
|
-
* @param endSide - The side on which the end position lays. See
|
|
436
|
-
* {@link SequencePlace} for additional context
|
|
437
|
-
*/
|
|
438
|
-
create(label: string, start: SequencePlace | undefined, end: SequencePlace | undefined, client: Client | undefined, intervalType: IntervalType, op?: ISequencedDocumentMessage, fromSnapshot?: boolean, useNewSlidingBehavior?: boolean): TInterval;
|
|
439
|
-
}
|
|
405
|
+
/* Excluded from this release type: IIntervalHelpers */
|
|
440
406
|
|
|
441
|
-
|
|
442
|
-
* @deprecated IJSONRunSegment will be removed in a upcoming release. It has been moved to the fluid-experimental/sequence-deprecated package
|
|
443
|
-
* @public
|
|
444
|
-
*/
|
|
445
|
-
export declare interface IJSONRunSegment<T> extends IJSONSegment {
|
|
446
|
-
items: Serializable<T>[];
|
|
447
|
-
}
|
|
407
|
+
/* Excluded from this release type: IJSONRunSegment */
|
|
448
408
|
|
|
449
409
|
/* Excluded from this release type: IMapMessageLocalMetadata */
|
|
450
410
|
|
|
@@ -452,71 +412,14 @@ export declare interface IJSONRunSegment<T> extends IJSONSegment {
|
|
|
452
412
|
* A sequence place that does not refer to the special endpoint segments.
|
|
453
413
|
*
|
|
454
414
|
* See {@link SequencePlace} for additional context.
|
|
455
|
-
* @
|
|
415
|
+
* @alpha
|
|
456
416
|
*/
|
|
457
417
|
export declare interface InteriorSequencePlace {
|
|
458
418
|
pos: number;
|
|
459
419
|
side: Side;
|
|
460
420
|
}
|
|
461
421
|
|
|
462
|
-
|
|
463
|
-
* Serializable interval whose endpoints are plain-old numbers.
|
|
464
|
-
* @public
|
|
465
|
-
*/
|
|
466
|
-
export declare class Interval implements ISerializableInterval {
|
|
467
|
-
start: number;
|
|
468
|
-
end: number;
|
|
469
|
-
/**
|
|
470
|
-
* {@inheritDoc ISerializableInterval.properties}
|
|
471
|
-
*/
|
|
472
|
-
properties: PropertySet;
|
|
473
|
-
/* Excluded from this release type: auxProps */
|
|
474
|
-
/* Excluded from this release type: propertyManager */
|
|
475
|
-
constructor(start: number, end: number, props?: PropertySet);
|
|
476
|
-
/**
|
|
477
|
-
* {@inheritDoc ISerializableInterval.getIntervalId}
|
|
478
|
-
*/
|
|
479
|
-
getIntervalId(): string;
|
|
480
|
-
/**
|
|
481
|
-
* @returns an array containing any auxiliary property sets added with `addPropertySet`.
|
|
482
|
-
*/
|
|
483
|
-
getAdditionalPropertySets(): PropertySet[];
|
|
484
|
-
/**
|
|
485
|
-
* Adds an auxiliary set of properties to this interval.
|
|
486
|
-
* These properties can be recovered using `getAdditionalPropertySets`
|
|
487
|
-
* @param props - set of properties to add
|
|
488
|
-
* @remarks This gets called as part of the default conflict resolver for `IIntervalCollection<Interval>`
|
|
489
|
-
* (i.e. non-sequence-based interval collections). However, the additional properties don't get serialized.
|
|
490
|
-
* This functionality seems half-baked.
|
|
491
|
-
*/
|
|
492
|
-
addPropertySet(props: PropertySet): void;
|
|
493
|
-
/* Excluded from this release type: serialize */
|
|
494
|
-
/**
|
|
495
|
-
* {@inheritDoc IInterval.clone}
|
|
496
|
-
*/
|
|
497
|
-
clone(): Interval;
|
|
498
|
-
/**
|
|
499
|
-
* {@inheritDoc IInterval.compare}
|
|
500
|
-
*/
|
|
501
|
-
compare(b: Interval): number;
|
|
502
|
-
/**
|
|
503
|
-
* {@inheritDoc IInterval.compareStart}
|
|
504
|
-
*/
|
|
505
|
-
compareStart(b: Interval): number;
|
|
506
|
-
/**
|
|
507
|
-
* {@inheritDoc IInterval.compareEnd}
|
|
508
|
-
*/
|
|
509
|
-
compareEnd(b: Interval): number;
|
|
510
|
-
/**
|
|
511
|
-
* {@inheritDoc IInterval.overlaps}
|
|
512
|
-
*/
|
|
513
|
-
overlaps(b: Interval): boolean;
|
|
514
|
-
/* Excluded from this release type: union */
|
|
515
|
-
getProperties(): PropertySet;
|
|
516
|
-
/* Excluded from this release type: addProperties */
|
|
517
|
-
/* Excluded from this release type: modify */
|
|
518
|
-
private initializeProperties;
|
|
519
|
-
}
|
|
422
|
+
/* Excluded from this release type: Interval */
|
|
520
423
|
|
|
521
424
|
/**
|
|
522
425
|
* Collection of intervals.
|
|
@@ -526,7 +429,7 @@ export declare class Interval implements ISerializableInterval {
|
|
|
526
429
|
* - "find all intervals with start endpoint between these two points"
|
|
527
430
|
* - "find all intervals which overlap this range"
|
|
528
431
|
* etc.
|
|
529
|
-
* @
|
|
432
|
+
* @alpha
|
|
530
433
|
*/
|
|
531
434
|
export declare interface IntervalIndex<TInterval extends ISerializableInterval> {
|
|
532
435
|
/**
|
|
@@ -543,38 +446,56 @@ export declare interface IntervalIndex<TInterval extends ISerializableInterval>
|
|
|
543
446
|
remove(interval: TInterval): void;
|
|
544
447
|
}
|
|
545
448
|
|
|
449
|
+
/* Excluded from this release type: IntervalLocator */
|
|
450
|
+
|
|
451
|
+
/* Excluded from this release type: intervalLocatorFromEndpoint */
|
|
452
|
+
|
|
453
|
+
/* Excluded from this release type: IntervalOpType */
|
|
454
|
+
|
|
455
|
+
/* Excluded from this release type: IntervalRevertible */
|
|
456
|
+
|
|
546
457
|
/**
|
|
547
|
-
*
|
|
548
|
-
*
|
|
458
|
+
* Determines how an interval should expand when segments are inserted adjacent
|
|
459
|
+
* to the range it spans
|
|
460
|
+
*
|
|
461
|
+
* Note that interval stickiness is currently an experimental feature and must
|
|
462
|
+
* be explicitly enabled with the `intervalStickinessEnabled` flag
|
|
463
|
+
*
|
|
464
|
+
* @alpha
|
|
549
465
|
*/
|
|
550
|
-
export declare
|
|
466
|
+
export declare const IntervalStickiness: {
|
|
551
467
|
/**
|
|
552
|
-
*
|
|
468
|
+
* Interval does not expand to include adjacent segments
|
|
553
469
|
*/
|
|
554
|
-
|
|
470
|
+
readonly NONE: 0;
|
|
555
471
|
/**
|
|
556
|
-
* Interval
|
|
472
|
+
* Interval expands to include segments inserted adjacent to the start
|
|
557
473
|
*/
|
|
558
|
-
|
|
559
|
-
|
|
474
|
+
readonly START: 1;
|
|
475
|
+
/**
|
|
476
|
+
* Interval expands to include segments inserted adjacent to the end
|
|
477
|
+
*
|
|
478
|
+
* This is the default stickiness
|
|
479
|
+
*/
|
|
480
|
+
readonly END: 2;
|
|
481
|
+
/**
|
|
482
|
+
* Interval expands to include all segments inserted adjacent to it
|
|
483
|
+
*/
|
|
484
|
+
readonly FULL: 3;
|
|
485
|
+
};
|
|
560
486
|
|
|
561
487
|
/**
|
|
562
|
-
*
|
|
563
|
-
*
|
|
564
|
-
*
|
|
565
|
-
*
|
|
566
|
-
*
|
|
488
|
+
* Determines how an interval should expand when segments are inserted adjacent
|
|
489
|
+
* to the range it spans
|
|
490
|
+
*
|
|
491
|
+
* Note that interval stickiness is currently an experimental feature and must
|
|
492
|
+
* be explicitly enabled with the `intervalStickinessEnabled` flag
|
|
493
|
+
* @alpha
|
|
567
494
|
*/
|
|
568
|
-
export declare
|
|
569
|
-
|
|
570
|
-
/* Excluded from this release type: IntervalOpType */
|
|
571
|
-
|
|
572
|
-
/* Excluded from this release type: IntervalRevertible */
|
|
573
|
-
|
|
574
|
-
/* Excluded from this release type: IntervalStickiness */
|
|
495
|
+
export declare type IntervalStickiness = (typeof IntervalStickiness)[keyof typeof IntervalStickiness];
|
|
575
496
|
|
|
576
497
|
/**
|
|
577
|
-
* @
|
|
498
|
+
* @alpha
|
|
578
499
|
*/
|
|
579
500
|
export declare enum IntervalType {
|
|
580
501
|
Simple = 0,
|
|
@@ -592,24 +513,11 @@ export declare enum IntervalType {
|
|
|
592
513
|
/* Excluded from this release type: Transient */
|
|
593
514
|
}
|
|
594
515
|
|
|
595
|
-
|
|
596
|
-
* @public
|
|
597
|
-
*/
|
|
598
|
-
export declare interface IOverlappingIntervalsIndex<TInterval extends ISerializableInterval> extends IntervalIndex<TInterval> {
|
|
599
|
-
/**
|
|
600
|
-
* @returns an array of all intervals contained in this collection that overlap the range
|
|
601
|
-
* `[start end]`.
|
|
602
|
-
*/
|
|
603
|
-
findOverlappingIntervals(start: SequencePlace, end: SequencePlace): TInterval[];
|
|
604
|
-
/**
|
|
605
|
-
* Gathers the interval results based on specified parameters.
|
|
606
|
-
*/
|
|
607
|
-
gatherIterationResults(results: TInterval[], iteratesForward: boolean, start?: SequencePlace, end?: SequencePlace): void;
|
|
608
|
-
}
|
|
516
|
+
/* Excluded from this release type: IOverlappingIntervalsIndex */
|
|
609
517
|
|
|
610
518
|
/**
|
|
611
519
|
* A range that has changed corresponding to a segment modification.
|
|
612
|
-
* @
|
|
520
|
+
* @alpha
|
|
613
521
|
*/
|
|
614
522
|
export declare interface ISequenceDeltaRange<TOperation extends MergeTreeDeltaOperationTypes = MergeTreeDeltaOperationTypes> {
|
|
615
523
|
/**
|
|
@@ -644,14 +552,17 @@ export declare interface ISequenceDeltaRange<TOperation extends MergeTreeDeltaOp
|
|
|
644
552
|
}
|
|
645
553
|
|
|
646
554
|
/**
|
|
647
|
-
* @
|
|
555
|
+
* @alpha
|
|
648
556
|
*/
|
|
649
557
|
export declare interface ISerializableInterval extends IInterval {
|
|
650
558
|
/** Serializable bag of properties associated with the interval. */
|
|
651
559
|
properties: PropertySet;
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
|
|
560
|
+
/***/
|
|
561
|
+
propertyManager: PropertiesManager;
|
|
562
|
+
/***/
|
|
563
|
+
serialize(): ISerializedInterval;
|
|
564
|
+
/***/
|
|
565
|
+
addProperties(props: PropertySet, collaborating?: boolean, seq?: number): PropertySet | undefined;
|
|
655
566
|
/**
|
|
656
567
|
* Gets the id associated with this interval.
|
|
657
568
|
* When the interval is used as part of an interval collection, this id can be used to modify or remove the
|
|
@@ -662,10 +573,38 @@ export declare interface ISerializableInterval extends IInterval {
|
|
|
662
573
|
getIntervalId(): string | undefined;
|
|
663
574
|
}
|
|
664
575
|
|
|
665
|
-
|
|
576
|
+
/**
|
|
577
|
+
* Serialized object representation of an interval.
|
|
578
|
+
* This representation is used for ops that create or change intervals.
|
|
579
|
+
* @alpha
|
|
580
|
+
*/
|
|
581
|
+
export declare interface ISerializedInterval {
|
|
582
|
+
/**
|
|
583
|
+
* Sequence number at which `start` and `end` should be interpreted
|
|
584
|
+
*
|
|
585
|
+
* @remarks It's unclear that this is necessary to store here.
|
|
586
|
+
* This should just be the refSeq on the op that modified the interval, which should be available via other means.
|
|
587
|
+
* At the time of writing, it's not plumbed through to the reconnect/rebase code, however, which does need it.
|
|
588
|
+
*/
|
|
589
|
+
sequenceNumber: number;
|
|
590
|
+
/** Start position of the interval */
|
|
591
|
+
start: number | "start" | "end";
|
|
592
|
+
/** End position of the interval */
|
|
593
|
+
end: number | "start" | "end";
|
|
594
|
+
/** Interval type to create */
|
|
595
|
+
intervalType: IntervalType;
|
|
596
|
+
/**
|
|
597
|
+
* The stickiness of this interval
|
|
598
|
+
*/
|
|
599
|
+
stickiness?: IntervalStickiness;
|
|
600
|
+
startSide?: Side;
|
|
601
|
+
endSide?: Side;
|
|
602
|
+
/** Any properties the interval has */
|
|
603
|
+
properties?: PropertySet;
|
|
604
|
+
}
|
|
666
605
|
|
|
667
606
|
/**
|
|
668
|
-
* @
|
|
607
|
+
* @alpha
|
|
669
608
|
*/
|
|
670
609
|
export declare interface ISharedIntervalCollection<TInterval extends ISerializableInterval> {
|
|
671
610
|
getIntervalCollection(label: string): IIntervalCollection<TInterval>;
|
|
@@ -703,7 +642,7 @@ export declare interface ISharedIntervalCollection<TInterval extends ISerializab
|
|
|
703
642
|
* - `event` - Various information on the segments that were modified.
|
|
704
643
|
*
|
|
705
644
|
* - `target` - The sequence itself.
|
|
706
|
-
* @
|
|
645
|
+
* @alpha
|
|
707
646
|
*/
|
|
708
647
|
export declare interface ISharedSegmentSequenceEvents extends ISharedObjectEvents {
|
|
709
648
|
(event: "createIntervalCollection", listener: (label: string, local: boolean, target: IEventThisPlaceHolder) => void): any;
|
|
@@ -713,7 +652,7 @@ export declare interface ISharedSegmentSequenceEvents extends ISharedObjectEvent
|
|
|
713
652
|
|
|
714
653
|
/**
|
|
715
654
|
* Fluid object interface describing access methods on a SharedString
|
|
716
|
-
* @
|
|
655
|
+
* @alpha
|
|
717
656
|
*/
|
|
718
657
|
export declare interface ISharedString extends SharedSegmentSequence<SharedStringSegment> {
|
|
719
658
|
/**
|
|
@@ -736,25 +675,12 @@ export declare interface ISharedString extends SharedSegmentSequence<SharedStrin
|
|
|
736
675
|
posFromRelativePos(relativePos: IRelativePosition): number;
|
|
737
676
|
}
|
|
738
677
|
|
|
739
|
-
|
|
740
|
-
* Collection of intervals.
|
|
741
|
-
*
|
|
742
|
-
* Provide additional APIs to support efficiently querying a collection of intervals whose startpoints fall within a specified range.
|
|
743
|
-
* @public
|
|
744
|
-
*/
|
|
745
|
-
export declare interface IStartpointInRangeIndex<TInterval extends ISerializableInterval> extends IntervalIndex<TInterval> {
|
|
746
|
-
/**
|
|
747
|
-
* @returns an array of all intervals contained in this collection whose startpoints locate in the range [start, end] (includes both ends)
|
|
748
|
-
*/
|
|
749
|
-
findIntervalsWithStartpointInRange(start: number, end: number): TInterval[];
|
|
750
|
-
}
|
|
678
|
+
/* Excluded from this release type: IStartpointInRangeIndex */
|
|
751
679
|
|
|
752
680
|
/* Excluded from this release type: IValueOpEmitter */
|
|
753
681
|
|
|
754
682
|
/* Excluded from this release type: MergeTreeDeltaRevertible */
|
|
755
683
|
|
|
756
|
-
/* Excluded from this release type: MergeTreeRevertibleDriver */
|
|
757
|
-
|
|
758
684
|
/* Excluded from this release type: revertSharedStringRevertibles */
|
|
759
685
|
|
|
760
686
|
/**
|
|
@@ -767,7 +693,7 @@ export declare interface IStartpointInRangeIndex<TInterval extends ISerializable
|
|
|
767
693
|
* For group ops, each op will get its own event, and the group op property will be set on the op args.
|
|
768
694
|
*
|
|
769
695
|
* Ops may get multiple events. For instance, an insert-replace will get a remove then an insert event.
|
|
770
|
-
* @
|
|
696
|
+
* @alpha
|
|
771
697
|
*/
|
|
772
698
|
export declare class SequenceDeltaEvent extends SequenceEvent<MergeTreeDeltaOperationType> {
|
|
773
699
|
readonly opArgs: IMergeTreeDeltaOpArgs;
|
|
@@ -784,7 +710,7 @@ export declare class SequenceDeltaEvent extends SequenceEvent<MergeTreeDeltaOper
|
|
|
784
710
|
* The properties of this object and its sub-objects represent the state of the sequence at the
|
|
785
711
|
* point in time at which the operation was applied.
|
|
786
712
|
* They will not take into any future modifications performed to the underlying sequence and merge tree.
|
|
787
|
-
* @
|
|
713
|
+
* @alpha
|
|
788
714
|
*/
|
|
789
715
|
export declare abstract class SequenceEvent<TOperation extends MergeTreeDeltaOperationTypes = MergeTreeDeltaOperationTypes> {
|
|
790
716
|
readonly deltaArgs: IMergeTreeDeltaCallbackArgs<TOperation>;
|
|
@@ -839,7 +765,7 @@ export declare abstract class SequenceEvent<TOperation extends MergeTreeDeltaOpe
|
|
|
839
765
|
* `mergeTreeReferencesCanSlideToEndpoint` feature flag set to true, the endpoints
|
|
840
766
|
* of the interval that are exclusive will have the ability to slide to these
|
|
841
767
|
* special endpoint segments.
|
|
842
|
-
* @
|
|
768
|
+
* @alpha
|
|
843
769
|
*/
|
|
844
770
|
export declare class SequenceInterval implements ISerializableInterval {
|
|
845
771
|
private readonly client;
|
|
@@ -860,8 +786,12 @@ export declare class SequenceInterval implements ISerializableInterval {
|
|
|
860
786
|
* {@inheritDoc ISerializableInterval.properties}
|
|
861
787
|
*/
|
|
862
788
|
properties: PropertySet;
|
|
863
|
-
|
|
864
|
-
|
|
789
|
+
/**
|
|
790
|
+
* {@inheritDoc ISerializableInterval.propertyManager}
|
|
791
|
+
*/
|
|
792
|
+
propertyManager: PropertiesManager;
|
|
793
|
+
/***/
|
|
794
|
+
get stickiness(): IntervalStickiness;
|
|
865
795
|
constructor(client: Client,
|
|
866
796
|
/**
|
|
867
797
|
* Start endpoint of this interval.
|
|
@@ -874,9 +804,18 @@ export declare class SequenceInterval implements ISerializableInterval {
|
|
|
874
804
|
*/
|
|
875
805
|
end: LocalReferencePosition, intervalType: IntervalType, props?: PropertySet, startSide?: Side, endSide?: Side);
|
|
876
806
|
private callbacks?;
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
|
|
807
|
+
/**
|
|
808
|
+
* Subscribes to position change events on this interval if there are no current listeners.
|
|
809
|
+
*/
|
|
810
|
+
addPositionChangeListeners(beforePositionChange: () => void, afterPositionChange: () => void): void;
|
|
811
|
+
/**
|
|
812
|
+
* Removes the currently subscribed position change listeners.
|
|
813
|
+
*/
|
|
814
|
+
removePositionChangeListeners(): void;
|
|
815
|
+
/**
|
|
816
|
+
* {@inheritDoc ISerializableInterval.serialize}
|
|
817
|
+
*/
|
|
818
|
+
serialize(): ISerializedInterval;
|
|
880
819
|
/**
|
|
881
820
|
* {@inheritDoc IInterval.clone}
|
|
882
821
|
*/
|
|
@@ -901,48 +840,28 @@ export declare class SequenceInterval implements ISerializableInterval {
|
|
|
901
840
|
* {@inheritDoc ISerializableInterval.getIntervalId}
|
|
902
841
|
*/
|
|
903
842
|
getIntervalId(): string;
|
|
904
|
-
|
|
905
|
-
|
|
843
|
+
/**
|
|
844
|
+
* {@inheritDoc IInterval.union}
|
|
845
|
+
*/
|
|
846
|
+
union(b: SequenceInterval): SequenceInterval;
|
|
847
|
+
/**
|
|
848
|
+
* {@inheritDoc ISerializableInterval.addProperties}
|
|
849
|
+
*/
|
|
850
|
+
addProperties(newProps: PropertySet, collab?: boolean, seq?: number, op?: ICombiningOp): PropertySet | undefined;
|
|
906
851
|
/**
|
|
907
852
|
* @returns whether this interval overlaps two numerical positions.
|
|
908
853
|
*/
|
|
909
854
|
overlapsPos(bstart: number, bend: number): boolean;
|
|
910
|
-
|
|
855
|
+
/**
|
|
856
|
+
* {@inheritDoc IInterval.modify}
|
|
857
|
+
*/
|
|
858
|
+
modify(label: string, start: SequencePlace | undefined, end: SequencePlace | undefined, op?: ISequencedDocumentMessage, localSeq?: number, useNewSlidingBehavior?: boolean): SequenceInterval;
|
|
911
859
|
private initializeProperties;
|
|
912
860
|
}
|
|
913
861
|
|
|
914
|
-
|
|
915
|
-
* @deprecated The methods within have substitutions
|
|
916
|
-
* @public
|
|
917
|
-
*/
|
|
918
|
-
export declare const sequenceIntervalHelpers: IIntervalHelpers<SequenceInterval>;
|
|
862
|
+
/* Excluded from this release type: sequenceIntervalHelpers */
|
|
919
863
|
|
|
920
|
-
|
|
921
|
-
* This namespace contains specialiazations of indexes which support spatial queries
|
|
922
|
-
* specifically for `SequenceInterval`s.
|
|
923
|
-
* @public
|
|
924
|
-
*/
|
|
925
|
-
export declare namespace SequenceIntervalIndexes {
|
|
926
|
-
/**
|
|
927
|
-
* Collection of intervals.
|
|
928
|
-
*
|
|
929
|
-
* Provides additional APIs to support efficiently querying a collection of intervals based on segments and offset.
|
|
930
|
-
*/
|
|
931
|
-
export interface Overlapping extends IOverlappingIntervalsIndex<SequenceInterval> {
|
|
932
|
-
/**
|
|
933
|
-
* Finds overlapping intervals within the specified range.
|
|
934
|
-
*
|
|
935
|
-
* @returns an array of all intervals that overlap with the specified SegOff range (includes both ends)
|
|
936
|
-
*/
|
|
937
|
-
findOverlappingIntervalsBySegoff(startSegoff: {
|
|
938
|
-
segment: ISegment | undefined;
|
|
939
|
-
offset: number | undefined;
|
|
940
|
-
}, endSegoff: {
|
|
941
|
-
segment: ISegment | undefined;
|
|
942
|
-
offset: number | undefined;
|
|
943
|
-
}): Iterable<SequenceInterval>;
|
|
944
|
-
}
|
|
945
|
-
}
|
|
864
|
+
/* Excluded from this release type: SequenceIntervalIndexes */
|
|
946
865
|
|
|
947
866
|
/**
|
|
948
867
|
* The event object returned on maintenance events.
|
|
@@ -950,44 +869,14 @@ export declare namespace SequenceIntervalIndexes {
|
|
|
950
869
|
* The properties of this object and its sub-objects represent the state of the sequence at the
|
|
951
870
|
* point in time at which the operation was applied.
|
|
952
871
|
* They will not take into consideration any future modifications performed to the underlying sequence and merge tree.
|
|
953
|
-
* @
|
|
872
|
+
* @alpha
|
|
954
873
|
*/
|
|
955
874
|
export declare class SequenceMaintenanceEvent extends SequenceEvent<MergeTreeMaintenanceType> {
|
|
956
875
|
readonly opArgs: IMergeTreeDeltaOpArgs | undefined;
|
|
957
876
|
constructor(opArgs: IMergeTreeDeltaOpArgs | undefined, deltaArgs: IMergeTreeMaintenanceCallbackArgs, mergeTreeClient: Client);
|
|
958
877
|
}
|
|
959
878
|
|
|
960
|
-
|
|
961
|
-
* Optional flags that configure options for sequence DDSs
|
|
962
|
-
* @public
|
|
963
|
-
*/
|
|
964
|
-
export declare interface SequenceOptions {
|
|
965
|
-
/**
|
|
966
|
-
* Enable the ability to use interval APIs that rely on positions before and
|
|
967
|
-
* after individual characters, referred to as "sides". See {@link SequencePlace}
|
|
968
|
-
* for additional context.
|
|
969
|
-
*
|
|
970
|
-
* This flag must be enabled to pass instances of {@link SequencePlace} to
|
|
971
|
-
* any IIntervalCollection API.
|
|
972
|
-
*
|
|
973
|
-
* Also see the feature flag `mergeTreeReferencesCanSlideToEndpoint` to allow
|
|
974
|
-
* endpoints to slide to the special endpoint segments.
|
|
975
|
-
*
|
|
976
|
-
* The default value is false.
|
|
977
|
-
*/
|
|
978
|
-
intervalStickinessEnabled: boolean;
|
|
979
|
-
/**
|
|
980
|
-
* Enable the ability for interval endpoints to slide to the special endpoint
|
|
981
|
-
* segments that exist before and after the bounds of the string. This is
|
|
982
|
-
* primarily useful for workflows involving interval stickiness, and it is
|
|
983
|
-
* suggested to enable both this flag and `intervalStickinessEnabled` at the
|
|
984
|
-
* same time.
|
|
985
|
-
*
|
|
986
|
-
* The default value is false.
|
|
987
|
-
*/
|
|
988
|
-
mergeTreeReferencesCanSlideToEndpoint: boolean;
|
|
989
|
-
[key: string]: boolean;
|
|
990
|
-
}
|
|
879
|
+
/* Excluded from this release type: SequenceOptions */
|
|
991
880
|
|
|
992
881
|
/**
|
|
993
882
|
* Defines a position and side relative to a character in a sequence.
|
|
@@ -1012,81 +901,37 @@ export declare interface SequenceOptions {
|
|
|
1012
901
|
* If a SequencePlace is the endpoint of a range (e.g. start/end of an interval or search range),
|
|
1013
902
|
* the Side value means it is exclusive if it is nearer to the other position and inclusive if it is farther.
|
|
1014
903
|
* E.g. the start of a range with Side.After is exclusive of the character at the position.
|
|
1015
|
-
* @
|
|
904
|
+
* @alpha
|
|
1016
905
|
*/
|
|
1017
906
|
export declare type SequencePlace = number | "start" | "end" | InteriorSequencePlace;
|
|
1018
907
|
|
|
1019
908
|
/* Excluded from this release type: SerializedIntervalDelta */
|
|
1020
909
|
|
|
1021
|
-
|
|
1022
|
-
* @deprecated `SharedIntervalCollection` is not maintained and is planned to be removed.
|
|
1023
|
-
* @public
|
|
1024
|
-
*/
|
|
1025
|
-
export declare class SharedIntervalCollection extends SharedObject implements ISharedIntervalCollection<Interval> {
|
|
1026
|
-
/**
|
|
1027
|
-
* Create a SharedIntervalCollection
|
|
1028
|
-
*
|
|
1029
|
-
* @param runtime - data store runtime the new shared map belongs to
|
|
1030
|
-
* @param id - optional name of the shared map
|
|
1031
|
-
* @returns newly create shared map (but not attached yet)
|
|
1032
|
-
*/
|
|
1033
|
-
static create(runtime: IFluidDataStoreRuntime, id?: string): SharedIntervalCollection;
|
|
1034
|
-
/**
|
|
1035
|
-
* Get a factory for SharedIntervalCollection to register with the data store.
|
|
1036
|
-
*
|
|
1037
|
-
* @returns a factory that creates and load SharedIntervalCollection
|
|
1038
|
-
*/
|
|
1039
|
-
static getFactory(): IChannelFactory;
|
|
1040
|
-
readonly [Symbol.toStringTag]: string;
|
|
1041
|
-
private readonly intervalCollections;
|
|
1042
|
-
/**
|
|
1043
|
-
* Constructs a new shared SharedIntervalCollection. If the object is non-local an id and service interfaces will
|
|
1044
|
-
* be provided
|
|
1045
|
-
*/
|
|
1046
|
-
constructor(id: string, runtime: IFluidDataStoreRuntime, attributes: IChannelAttributes);
|
|
1047
|
-
getIntervalCollection(label: string): IIntervalCollection<Interval>;
|
|
1048
|
-
protected summarizeCore(serializer: IFluidSerializer): ISummaryTreeWithStats;
|
|
1049
|
-
protected reSubmitCore(content: any, localOpMetadata: unknown): void;
|
|
1050
|
-
protected onDisconnect(): void;
|
|
1051
|
-
/**
|
|
1052
|
-
* {@inheritDoc @fluidframework/shared-object-base#SharedObject.loadCore}
|
|
1053
|
-
*/
|
|
1054
|
-
protected loadCore(storage: IChannelStorageService): Promise<void>;
|
|
1055
|
-
protected processCore(message: ISequencedDocumentMessage, local: boolean, localOpMetadata: unknown): void;
|
|
1056
|
-
/**
|
|
1057
|
-
* Creates the full path of the intervalCollection label
|
|
1058
|
-
* @param label - the incoming label
|
|
1059
|
-
*/
|
|
1060
|
-
protected getIntervalCollectionPath(label: string): string;
|
|
1061
|
-
protected applyStashedOp(): void;
|
|
1062
|
-
}
|
|
910
|
+
/* Excluded from this release type: SharedIntervalCollection */
|
|
1063
911
|
|
|
1064
|
-
|
|
1065
|
-
* The factory that defines the SharedIntervalCollection.
|
|
1066
|
-
* @deprecated `SharedIntervalCollection` is not maintained and is planned to be removed.
|
|
1067
|
-
* @public
|
|
1068
|
-
*/
|
|
1069
|
-
export declare class SharedIntervalCollectionFactory implements IChannelFactory {
|
|
1070
|
-
static readonly Type = "https://graph.microsoft.com/types/sharedIntervalCollection";
|
|
1071
|
-
static readonly Attributes: IChannelAttributes;
|
|
1072
|
-
get type(): string;
|
|
1073
|
-
get attributes(): IChannelAttributes;
|
|
1074
|
-
/**
|
|
1075
|
-
* {@inheritDoc @fluidframework/datastore-definitions#IChannelFactory.load}
|
|
1076
|
-
*/
|
|
1077
|
-
load(runtime: IFluidDataStoreRuntime, id: string, services: IChannelServices, attributes: IChannelAttributes): Promise<SharedIntervalCollection>;
|
|
1078
|
-
create(runtime: IFluidDataStoreRuntime, id: string): SharedIntervalCollection;
|
|
1079
|
-
}
|
|
912
|
+
/* Excluded from this release type: SharedIntervalCollectionFactory */
|
|
1080
913
|
|
|
1081
914
|
/**
|
|
1082
|
-
* @
|
|
915
|
+
* @alpha
|
|
1083
916
|
*/
|
|
1084
917
|
export declare abstract class SharedSegmentSequence<T extends ISegment> extends SharedObject<ISharedSegmentSequenceEvents> implements ISharedIntervalCollection<SequenceInterval>, MergeTreeRevertibleDriver {
|
|
1085
918
|
private readonly dataStoreRuntime;
|
|
1086
919
|
id: string;
|
|
1087
920
|
readonly segmentFromSpec: (spec: IJSONSegment) => ISegment;
|
|
1088
921
|
get loaded(): Promise<void>;
|
|
1089
|
-
|
|
922
|
+
/**
|
|
923
|
+
* This is a safeguard to avoid problematic reentrancy of local ops. This type of scenario occurs if the user of SharedString subscribes
|
|
924
|
+
* to the `sequenceDelta` event and uses the callback for a local op to submit further local ops.
|
|
925
|
+
* Historically (before 2.0.0-internal.6.1.0), doing so would result in eventual consistency issues or a corrupted document.
|
|
926
|
+
* These issues were fixed in #16815 which makes such reentrancy no different from applying the ops in order but not from within the change events,
|
|
927
|
+
* but there is still little test coverage for reentrant scenarios.
|
|
928
|
+
* Additionally, applications submitting ops from inside change events need to take extreme care that their data models also support reentrancy.
|
|
929
|
+
* Since this is likely not the case, by default SharedString throws when encountering reentrant ops.
|
|
930
|
+
*
|
|
931
|
+
* An application using SharedString which explicitly wants to opt in to allowing reentrancy anyway can set `sharedStringPreventReentrancy`
|
|
932
|
+
* on the data store options to `false`.
|
|
933
|
+
*/
|
|
934
|
+
protected guardReentrancy: <TRet>(callback: () => TRet) => TRet;
|
|
1090
935
|
private static createOpsFromDelta;
|
|
1091
936
|
protected client: Client;
|
|
1092
937
|
/** `Deferred` that triggers once the object is loaded */
|
|
@@ -1293,36 +1138,7 @@ export declare abstract class SharedSegmentSequence<T extends ISegment> extends
|
|
|
1293
1138
|
private initializeIntervalCollections;
|
|
1294
1139
|
}
|
|
1295
1140
|
|
|
1296
|
-
|
|
1297
|
-
* @deprecated SharedSequence will be removed in a upcoming release. It has been moved to the fluid-experimental/sequence-deprecated package
|
|
1298
|
-
* @public
|
|
1299
|
-
*/
|
|
1300
|
-
export declare class SharedSequence<T> extends SharedSegmentSequence<SubSequence<T>> {
|
|
1301
|
-
id: string;
|
|
1302
|
-
constructor(document: IFluidDataStoreRuntime, id: string, attributes: IChannelAttributes, specToSegment: (spec: IJSONSegment) => ISegment);
|
|
1303
|
-
/**
|
|
1304
|
-
* @param pos - The position to insert the items at.
|
|
1305
|
-
* @param items - The items to insert.
|
|
1306
|
-
* @param props - Optional. Properties to set on the inserted items.
|
|
1307
|
-
*/
|
|
1308
|
-
insert(pos: number, items: Serializable<T>[], props?: PropertySet): void;
|
|
1309
|
-
/**
|
|
1310
|
-
* @param start - The inclusive start of the range to remove
|
|
1311
|
-
* @param end - The exclusive end of the range to remove
|
|
1312
|
-
*/
|
|
1313
|
-
remove(start: number, end: number): void;
|
|
1314
|
-
/**
|
|
1315
|
-
* Returns the total count of items in the sequence
|
|
1316
|
-
*/
|
|
1317
|
-
getItemCount(): number;
|
|
1318
|
-
/**
|
|
1319
|
-
* Gets the items in the specified range
|
|
1320
|
-
*
|
|
1321
|
-
* @param start - The inclusive start of the range
|
|
1322
|
-
* @param end - The exclusive end of the range
|
|
1323
|
-
*/
|
|
1324
|
-
getItems(start: number, end?: number): Serializable<T>[];
|
|
1325
|
-
}
|
|
1141
|
+
/* Excluded from this release type: SharedSequence */
|
|
1326
1142
|
|
|
1327
1143
|
/**
|
|
1328
1144
|
* The Shared String is a specialized data structure for handling collaborative
|
|
@@ -1332,8 +1148,7 @@ export declare class SharedSequence<T> extends SharedSegmentSequence<SubSequence
|
|
|
1332
1148
|
* In addition to text, a Shared String can also contain markers. Markers can be
|
|
1333
1149
|
* used to store metadata at positions within the text, like the details of an
|
|
1334
1150
|
* image or Fluid object that should be rendered with the text.
|
|
1335
|
-
*
|
|
1336
|
-
* @public
|
|
1151
|
+
* @alpha
|
|
1337
1152
|
*/
|
|
1338
1153
|
export declare class SharedString extends SharedSegmentSequence<SharedStringSegment> implements ISharedString {
|
|
1339
1154
|
id: string;
|
|
@@ -1394,6 +1209,10 @@ export declare class SharedString extends SharedSegmentSequence<SharedStringSegm
|
|
|
1394
1209
|
* @param marker - The marker to annotate
|
|
1395
1210
|
* @param props - The properties to annotate the marker with
|
|
1396
1211
|
* @param consensusCallback - The callback called when consensus is reached
|
|
1212
|
+
*
|
|
1213
|
+
* @deprecated We no longer intend to support this functionality and it will
|
|
1214
|
+
* be removed in a future release. There is no replacement for this
|
|
1215
|
+
* functionality.
|
|
1397
1216
|
*/
|
|
1398
1217
|
annotateMarkerNotifyConsensus(marker: Marker, props: PropertySet, callback: (m: Marker) => void): void;
|
|
1399
1218
|
/**
|
|
@@ -1449,7 +1268,7 @@ export declare class SharedString extends SharedSegmentSequence<SharedStringSegm
|
|
|
1449
1268
|
}
|
|
1450
1269
|
|
|
1451
1270
|
/**
|
|
1452
|
-
* @
|
|
1271
|
+
* @alpha
|
|
1453
1272
|
*/
|
|
1454
1273
|
export declare class SharedStringFactory implements IChannelFactory {
|
|
1455
1274
|
static Type: string;
|
|
@@ -1467,7 +1286,7 @@ export declare class SharedStringFactory implements IChannelFactory {
|
|
|
1467
1286
|
/* Excluded from this release type: SharedStringRevertible */
|
|
1468
1287
|
|
|
1469
1288
|
/**
|
|
1470
|
-
* @
|
|
1289
|
+
* @alpha
|
|
1471
1290
|
*/
|
|
1472
1291
|
export declare type SharedStringSegment = TextSegment | Marker;
|
|
1473
1292
|
|
|
@@ -1475,33 +1294,13 @@ export declare type SharedStringSegment = TextSegment | Marker;
|
|
|
1475
1294
|
* Defines a side relative to a character in a sequence.
|
|
1476
1295
|
*
|
|
1477
1296
|
* @remarks See {@link SequencePlace} for additional context on usage.
|
|
1478
|
-
* @
|
|
1297
|
+
* @alpha
|
|
1479
1298
|
*/
|
|
1480
1299
|
export declare enum Side {
|
|
1481
1300
|
Before = 0,
|
|
1482
1301
|
After = 1
|
|
1483
1302
|
}
|
|
1484
1303
|
|
|
1485
|
-
|
|
1486
|
-
* @deprecated SubSequence will be removed in a upcoming release. It has been moved to the fluid-experimental/sequence-deprecated package
|
|
1487
|
-
* @public
|
|
1488
|
-
*/
|
|
1489
|
-
export declare class SubSequence<T> extends BaseSegment {
|
|
1490
|
-
items: Serializable<T>[];
|
|
1491
|
-
static readonly typeString: string;
|
|
1492
|
-
static is(segment: ISegment): segment is SubSequence<any>;
|
|
1493
|
-
static fromJSONObject<U>(spec: Serializable): SubSequence<U> | undefined;
|
|
1494
|
-
readonly type: string;
|
|
1495
|
-
constructor(items: Serializable<T>[]);
|
|
1496
|
-
toJSONObject(): IJSONRunSegment<T>;
|
|
1497
|
-
clone(start?: number, end?: number): SubSequence<T>;
|
|
1498
|
-
canAppend(segment: ISegment): boolean;
|
|
1499
|
-
toString(): string;
|
|
1500
|
-
append(segment: ISegment): void;
|
|
1501
|
-
removeRange(start: number, end: number): boolean;
|
|
1502
|
-
protected createSplitSegmentAt(pos: number): SubSequence<T> | undefined;
|
|
1503
|
-
}
|
|
1504
|
-
|
|
1505
|
-
/* Excluded from this release type: TypedEventEmitter */
|
|
1304
|
+
/* Excluded from this release type: SubSequence */
|
|
1506
1305
|
|
|
1507
1306
|
export { }
|