@fluidframework/map 2.0.0-internal.7.3.0 → 2.0.0-internal.7.4.0
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 +4 -0
- package/api-extractor-lint.json +13 -0
- package/api-extractor.json +8 -3
- package/api-report/map.api.md +42 -44
- package/dist/directory.cjs +221 -35
- package/dist/directory.cjs.map +1 -1
- package/dist/directory.d.ts +499 -38
- package/dist/directory.d.ts.map +1 -1
- package/dist/interfaces.cjs.map +1 -1
- package/dist/interfaces.d.ts +10 -20
- package/dist/interfaces.d.ts.map +1 -1
- package/dist/localValues.cjs +1 -2
- package/dist/localValues.cjs.map +1 -1
- package/dist/localValues.d.ts +2 -4
- package/dist/localValues.d.ts.map +1 -1
- package/dist/map-alpha.d.ts +97 -68
- package/dist/map-beta.d.ts +59 -890
- package/dist/map-public.d.ts +59 -890
- package/dist/map-untrimmed.d.ts +28 -70
- package/dist/map.cjs +2 -10
- package/dist/map.cjs.map +1 -1
- package/dist/map.d.ts +2 -10
- package/dist/map.d.ts.map +1 -1
- package/dist/packageVersion.cjs +1 -1
- package/dist/packageVersion.cjs.map +1 -1
- package/dist/packageVersion.d.ts +1 -1
- package/lib/directory.d.ts +499 -38
- package/lib/directory.d.ts.map +1 -1
- package/lib/directory.mjs +221 -35
- package/lib/directory.mjs.map +1 -1
- package/lib/index.d.ts +4 -15
- package/lib/index.d.ts.map +1 -1
- package/lib/interfaces.d.ts +10 -20
- package/lib/interfaces.d.ts.map +1 -1
- package/lib/interfaces.mjs.map +1 -1
- package/lib/internalInterfaces.d.ts +2 -2
- package/lib/internalInterfaces.d.ts.map +1 -1
- package/lib/localValues.d.ts +3 -5
- package/lib/localValues.d.ts.map +1 -1
- package/lib/localValues.mjs +1 -2
- package/lib/localValues.mjs.map +1 -1
- package/lib/map-alpha.d.ts +97 -68
- package/lib/map-beta.d.ts +59 -890
- package/lib/map-public.d.ts +59 -890
- package/lib/map-untrimmed.d.ts +28 -70
- package/lib/map.d.ts +3 -11
- package/lib/map.d.ts.map +1 -1
- package/lib/map.mjs +2 -10
- package/lib/map.mjs.map +1 -1
- package/lib/mapKernel.d.ts +2 -2
- package/lib/mapKernel.d.ts.map +1 -1
- package/lib/packageVersion.d.ts +1 -1
- package/lib/packageVersion.mjs +1 -1
- package/lib/packageVersion.mjs.map +1 -1
- package/map.test-files.tar +0 -0
- package/package.json +22 -18
- package/src/directory.ts +275 -58
- package/src/interfaces.ts +10 -20
- package/src/localValues.ts +2 -4
- package/src/map.ts +2 -10
- package/src/packageVersion.ts +1 -1
package/src/interfaces.ts
CHANGED
|
@@ -13,8 +13,7 @@ import {
|
|
|
13
13
|
|
|
14
14
|
/**
|
|
15
15
|
* Type of "valueChanged" event parameter.
|
|
16
|
-
*
|
|
17
|
-
* @public
|
|
16
|
+
* @alpha
|
|
18
17
|
*/
|
|
19
18
|
export interface IValueChanged {
|
|
20
19
|
/**
|
|
@@ -34,8 +33,7 @@ export interface IValueChanged {
|
|
|
34
33
|
* Interface describing actions on a directory.
|
|
35
34
|
*
|
|
36
35
|
* @remarks When used as a Map, operates on its keys.
|
|
37
|
-
*
|
|
38
|
-
* @public
|
|
36
|
+
* @alpha
|
|
39
37
|
*/
|
|
40
38
|
// TODO: Use `unknown` instead (breaking change).
|
|
41
39
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
@@ -119,8 +117,7 @@ export interface IDirectory
|
|
|
119
117
|
*
|
|
120
118
|
* @remarks
|
|
121
119
|
* These events only emit on the {@link ISharedDirectory} itself, and not on subdirectories.
|
|
122
|
-
*
|
|
123
|
-
* @public
|
|
120
|
+
* @alpha
|
|
124
121
|
*/
|
|
125
122
|
export interface ISharedDirectoryEvents extends ISharedObjectEvents {
|
|
126
123
|
/**
|
|
@@ -193,8 +190,7 @@ export interface ISharedDirectoryEvents extends ISharedObjectEvents {
|
|
|
193
190
|
|
|
194
191
|
/**
|
|
195
192
|
* Events emitted in response to changes to the directory data.
|
|
196
|
-
*
|
|
197
|
-
* @public
|
|
193
|
+
* @alpha
|
|
198
194
|
*/
|
|
199
195
|
export interface IDirectoryEvents extends IEvent {
|
|
200
196
|
/**
|
|
@@ -275,8 +271,7 @@ export interface IDirectoryEvents extends IEvent {
|
|
|
275
271
|
* Provides a hierarchical organization of map-like data structures as SubDirectories.
|
|
276
272
|
* The values stored within can be accessed like a map, and the hierarchy can be navigated using path syntax.
|
|
277
273
|
* SubDirectories can be retrieved for use as working directories.
|
|
278
|
-
*
|
|
279
|
-
* @public
|
|
274
|
+
* @alpha
|
|
280
275
|
*/
|
|
281
276
|
export interface ISharedDirectory
|
|
282
277
|
extends ISharedObject<ISharedDirectoryEvents & IDirectoryEvents>,
|
|
@@ -291,8 +286,7 @@ export interface ISharedDirectory
|
|
|
291
286
|
|
|
292
287
|
/**
|
|
293
288
|
* Type of "valueChanged" event parameter for {@link ISharedDirectory}.
|
|
294
|
-
*
|
|
295
|
-
* @public
|
|
289
|
+
* @alpha
|
|
296
290
|
*/
|
|
297
291
|
export interface IDirectoryValueChanged extends IValueChanged {
|
|
298
292
|
/**
|
|
@@ -303,8 +297,7 @@ export interface IDirectoryValueChanged extends IValueChanged {
|
|
|
303
297
|
|
|
304
298
|
/**
|
|
305
299
|
* Events emitted in response to changes to the {@link ISharedMap | map} data.
|
|
306
|
-
*
|
|
307
|
-
* @public
|
|
300
|
+
* @alpha
|
|
308
301
|
*/
|
|
309
302
|
export interface ISharedMapEvents extends ISharedObjectEvents {
|
|
310
303
|
/**
|
|
@@ -343,8 +336,7 @@ export interface ISharedMapEvents extends ISharedObjectEvents {
|
|
|
343
336
|
* {@link @fluidframework/datastore#FluidObjectHandle}.
|
|
344
337
|
*
|
|
345
338
|
* For more information, including example usages, see {@link https://fluidframework.com/docs/data-structures/map/}.
|
|
346
|
-
*
|
|
347
|
-
* @public
|
|
339
|
+
* @alpha
|
|
348
340
|
*/
|
|
349
341
|
// TODO: Use `unknown` instead (breaking change).
|
|
350
342
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
@@ -389,8 +381,7 @@ export interface ISharedMap extends ISharedObject<ISharedMapEvents>, Map<string,
|
|
|
389
381
|
* channel ID.
|
|
390
382
|
*
|
|
391
383
|
* @deprecated This type is legacy and deprecated.
|
|
392
|
-
*
|
|
393
|
-
* @public
|
|
384
|
+
* @alpha
|
|
394
385
|
*/
|
|
395
386
|
export interface ISerializableValue {
|
|
396
387
|
/**
|
|
@@ -407,8 +398,7 @@ export interface ISerializableValue {
|
|
|
407
398
|
|
|
408
399
|
/**
|
|
409
400
|
* Serialized {@link ISerializableValue} counterpart.
|
|
410
|
-
*
|
|
411
|
-
* @public
|
|
401
|
+
* @alpha
|
|
412
402
|
*/
|
|
413
403
|
export interface ISerializedValue {
|
|
414
404
|
/**
|
package/src/localValues.ts
CHANGED
|
@@ -16,8 +16,7 @@ import { ISerializableValue, ISerializedValue } from "./interfaces";
|
|
|
16
16
|
|
|
17
17
|
/**
|
|
18
18
|
* A local value to be stored in a container type Distributed Data Store (DDS).
|
|
19
|
-
*
|
|
20
|
-
* @public
|
|
19
|
+
* @alpha
|
|
21
20
|
*/
|
|
22
21
|
export interface ILocalValue {
|
|
23
22
|
/**
|
|
@@ -99,8 +98,7 @@ export class PlainLocalValue implements ILocalValue {
|
|
|
99
98
|
/**
|
|
100
99
|
* Enables a container type {@link https://fluidframework.com/docs/build/dds/ | DDS} to produce and store local
|
|
101
100
|
* values with minimal awareness of how those objects are stored, serialized, and deserialized.
|
|
102
|
-
*
|
|
103
|
-
* @public
|
|
101
|
+
* @alpha
|
|
104
102
|
*/
|
|
105
103
|
export class LocalValueMaker {
|
|
106
104
|
/**
|
package/src/map.ts
CHANGED
|
@@ -30,7 +30,7 @@ const snapshotFileName = "header";
|
|
|
30
30
|
* {@link @fluidframework/datastore-definitions#IChannelFactory} for {@link SharedMap}.
|
|
31
31
|
*
|
|
32
32
|
* @sealed
|
|
33
|
-
* @
|
|
33
|
+
* @alpha
|
|
34
34
|
*/
|
|
35
35
|
export class MapFactory implements IChannelFactory {
|
|
36
36
|
/**
|
|
@@ -89,8 +89,7 @@ export class MapFactory implements IChannelFactory {
|
|
|
89
89
|
|
|
90
90
|
/**
|
|
91
91
|
* {@inheritDoc ISharedMap}
|
|
92
|
-
*
|
|
93
|
-
* @public
|
|
92
|
+
* @alpha
|
|
94
93
|
*/
|
|
95
94
|
export class SharedMap extends SharedObject<ISharedMapEvents> implements ISharedMap {
|
|
96
95
|
/**
|
|
@@ -250,7 +249,6 @@ export class SharedMap extends SharedObject<ISharedMapEvents> implements IShared
|
|
|
250
249
|
|
|
251
250
|
/**
|
|
252
251
|
* {@inheritDoc @fluidframework/shared-object-base#SharedObject.summarizeCore}
|
|
253
|
-
* @internal
|
|
254
252
|
*/
|
|
255
253
|
protected summarizeCore(
|
|
256
254
|
serializer: IFluidSerializer,
|
|
@@ -330,7 +328,6 @@ export class SharedMap extends SharedObject<ISharedMapEvents> implements IShared
|
|
|
330
328
|
|
|
331
329
|
/**
|
|
332
330
|
* {@inheritDoc @fluidframework/shared-object-base#SharedObject.loadCore}
|
|
333
|
-
* @internal
|
|
334
331
|
*/
|
|
335
332
|
protected async loadCore(storage: IChannelStorageService): Promise<void> {
|
|
336
333
|
const json = await readAndParse<object>(storage, snapshotFileName);
|
|
@@ -350,13 +347,11 @@ export class SharedMap extends SharedObject<ISharedMapEvents> implements IShared
|
|
|
350
347
|
|
|
351
348
|
/**
|
|
352
349
|
* {@inheritDoc @fluidframework/shared-object-base#SharedObject.onDisconnect}
|
|
353
|
-
* @internal
|
|
354
350
|
*/
|
|
355
351
|
protected onDisconnect(): void {}
|
|
356
352
|
|
|
357
353
|
/**
|
|
358
354
|
* {@inheritDoc @fluidframework/shared-object-base#SharedObject.reSubmitCore}
|
|
359
|
-
* @internal
|
|
360
355
|
*/
|
|
361
356
|
protected reSubmitCore(content: unknown, localOpMetadata: unknown): void {
|
|
362
357
|
this.kernel.trySubmitMessage(content as IMapOperation, localOpMetadata);
|
|
@@ -364,7 +359,6 @@ export class SharedMap extends SharedObject<ISharedMapEvents> implements IShared
|
|
|
364
359
|
|
|
365
360
|
/**
|
|
366
361
|
* {@inheritDoc @fluidframework/shared-object-base#SharedObjectCore.applyStashedOp}
|
|
367
|
-
* @internal
|
|
368
362
|
*/
|
|
369
363
|
protected applyStashedOp(content: unknown): unknown {
|
|
370
364
|
return this.kernel.tryApplyStashedOp(content as IMapOperation);
|
|
@@ -372,7 +366,6 @@ export class SharedMap extends SharedObject<ISharedMapEvents> implements IShared
|
|
|
372
366
|
|
|
373
367
|
/**
|
|
374
368
|
* {@inheritDoc @fluidframework/shared-object-base#SharedObject.processCore}
|
|
375
|
-
* @internal
|
|
376
369
|
*/
|
|
377
370
|
protected processCore(
|
|
378
371
|
message: ISequencedDocumentMessage,
|
|
@@ -390,7 +383,6 @@ export class SharedMap extends SharedObject<ISharedMapEvents> implements IShared
|
|
|
390
383
|
|
|
391
384
|
/**
|
|
392
385
|
* {@inheritDoc @fluidframework/shared-object-base#SharedObject.rollback}
|
|
393
|
-
* @internal
|
|
394
386
|
*/
|
|
395
387
|
protected rollback(content: unknown, localOpMetadata: unknown): void {
|
|
396
388
|
this.kernel.rollback(content, localOpMetadata);
|
package/src/packageVersion.ts
CHANGED