@fluidframework/sequence 0.53.0 → 0.54.2
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/README.md +8 -25
- package/dist/packageVersion.d.ts +1 -1
- package/dist/packageVersion.js +1 -1
- package/dist/packageVersion.js.map +1 -1
- package/dist/sequence.d.ts.map +1 -1
- package/dist/sequence.js +1 -1
- package/dist/sequence.js.map +1 -1
- package/dist/sequenceFactory.d.ts +62 -0
- package/dist/sequenceFactory.d.ts.map +1 -1
- package/dist/sequenceFactory.js +62 -0
- package/dist/sequenceFactory.js.map +1 -1
- package/dist/sharedNumberSequence.d.ts +17 -0
- package/dist/sharedNumberSequence.d.ts.map +1 -1
- package/dist/sharedNumberSequence.js +17 -0
- package/dist/sharedNumberSequence.js.map +1 -1
- package/dist/sharedObjectSequence.d.ts +17 -0
- package/dist/sharedObjectSequence.d.ts.map +1 -1
- package/dist/sharedObjectSequence.js +17 -0
- package/dist/sharedObjectSequence.js.map +1 -1
- package/lib/packageVersion.d.ts +1 -1
- package/lib/packageVersion.js +1 -1
- package/lib/packageVersion.js.map +1 -1
- package/lib/sequence.d.ts.map +1 -1
- package/lib/sequence.js +1 -1
- package/lib/sequence.js.map +1 -1
- package/lib/sequenceFactory.d.ts +62 -0
- package/lib/sequenceFactory.d.ts.map +1 -1
- package/lib/sequenceFactory.js +62 -0
- package/lib/sequenceFactory.js.map +1 -1
- package/lib/sharedNumberSequence.d.ts +17 -0
- package/lib/sharedNumberSequence.d.ts.map +1 -1
- package/lib/sharedNumberSequence.js +17 -0
- package/lib/sharedNumberSequence.js.map +1 -1
- package/lib/sharedObjectSequence.d.ts +17 -0
- package/lib/sharedObjectSequence.d.ts.map +1 -1
- package/lib/sharedObjectSequence.js +17 -0
- package/lib/sharedObjectSequence.js.map +1 -1
- package/package.json +11 -11
- package/src/packageVersion.ts +1 -1
- package/src/sequence.ts +5 -2
- package/src/sequenceFactory.ts +62 -0
- package/src/sharedNumberSequence.ts +17 -0
- package/src/sharedObjectSequence.ts +17 -0
package/src/sequenceFactory.ts
CHANGED
|
@@ -68,15 +68,31 @@ export class SharedStringFactory implements IChannelFactory {
|
|
|
68
68
|
}
|
|
69
69
|
}
|
|
70
70
|
|
|
71
|
+
/**
|
|
72
|
+
* @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.
|
|
73
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
74
|
+
*/
|
|
71
75
|
export class SharedObjectSequenceFactory implements IChannelFactory {
|
|
76
|
+
/**
|
|
77
|
+
* @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.
|
|
78
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
79
|
+
*/
|
|
72
80
|
public static Type = "https://graph.microsoft.com/types/mergeTree/object-sequence";
|
|
73
81
|
|
|
82
|
+
/**
|
|
83
|
+
* @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.
|
|
84
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
85
|
+
*/
|
|
74
86
|
public static readonly Attributes: IChannelAttributes = {
|
|
75
87
|
type: SharedObjectSequenceFactory.Type,
|
|
76
88
|
snapshotFormatVersion: "0.1",
|
|
77
89
|
packageVersion: pkgVersion,
|
|
78
90
|
};
|
|
79
91
|
|
|
92
|
+
/**
|
|
93
|
+
* @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.
|
|
94
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
95
|
+
*/
|
|
80
96
|
public static segmentFromSpec(segSpec: IJSONSegment) {
|
|
81
97
|
// eslint-disable-next-line @typescript-eslint/ban-types
|
|
82
98
|
const runSegment = segSpec as IJSONRunSegment<object>;
|
|
@@ -90,16 +106,27 @@ export class SharedObjectSequenceFactory implements IChannelFactory {
|
|
|
90
106
|
}
|
|
91
107
|
}
|
|
92
108
|
|
|
109
|
+
/**
|
|
110
|
+
* @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.
|
|
111
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
112
|
+
*/
|
|
93
113
|
public get type() {
|
|
94
114
|
return SharedObjectSequenceFactory.Type;
|
|
95
115
|
}
|
|
96
116
|
|
|
117
|
+
/**
|
|
118
|
+
* @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.
|
|
119
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
120
|
+
*/
|
|
97
121
|
public get attributes() {
|
|
98
122
|
return SharedObjectSequenceFactory.Attributes;
|
|
99
123
|
}
|
|
100
124
|
|
|
101
125
|
/**
|
|
102
126
|
* {@inheritDoc @fluidframework/datastore-definitions#IChannelFactory.load}
|
|
127
|
+
*
|
|
128
|
+
* @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.
|
|
129
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
103
130
|
*/
|
|
104
131
|
public async load(
|
|
105
132
|
runtime: IFluidDataStoreRuntime,
|
|
@@ -112,6 +139,10 @@ export class SharedObjectSequenceFactory implements IChannelFactory {
|
|
|
112
139
|
return sharedSeq;
|
|
113
140
|
}
|
|
114
141
|
|
|
142
|
+
/**
|
|
143
|
+
* @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.
|
|
144
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
145
|
+
*/
|
|
115
146
|
public create(document: IFluidDataStoreRuntime, id: string): ISharedObject {
|
|
116
147
|
const sharedString = new SharedObjectSequence(document, id, this.attributes);
|
|
117
148
|
sharedString.initializeLocal();
|
|
@@ -119,15 +150,31 @@ export class SharedObjectSequenceFactory implements IChannelFactory {
|
|
|
119
150
|
}
|
|
120
151
|
}
|
|
121
152
|
|
|
153
|
+
/**
|
|
154
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
155
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
156
|
+
*/
|
|
122
157
|
export class SharedNumberSequenceFactory implements IChannelFactory {
|
|
158
|
+
/**
|
|
159
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
160
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
161
|
+
*/
|
|
123
162
|
public static Type = "https://graph.microsoft.com/types/mergeTree/number-sequence";
|
|
124
163
|
|
|
164
|
+
/**
|
|
165
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
166
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
167
|
+
*/
|
|
125
168
|
public static readonly Attributes: IChannelAttributes = {
|
|
126
169
|
type: SharedNumberSequenceFactory.Type,
|
|
127
170
|
snapshotFormatVersion: "0.1",
|
|
128
171
|
packageVersion: pkgVersion,
|
|
129
172
|
};
|
|
130
173
|
|
|
174
|
+
/**
|
|
175
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
176
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
177
|
+
*/
|
|
131
178
|
public static segmentFromSpec(segSpec: IJSONSegment) {
|
|
132
179
|
const runSegment = segSpec as IJSONRunSegment<number>;
|
|
133
180
|
if (runSegment.items) {
|
|
@@ -139,16 +186,27 @@ export class SharedNumberSequenceFactory implements IChannelFactory {
|
|
|
139
186
|
}
|
|
140
187
|
}
|
|
141
188
|
|
|
189
|
+
/**
|
|
190
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
191
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
192
|
+
*/
|
|
142
193
|
public get type() {
|
|
143
194
|
return SharedNumberSequenceFactory.Type;
|
|
144
195
|
}
|
|
145
196
|
|
|
197
|
+
/**
|
|
198
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
199
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
200
|
+
*/
|
|
146
201
|
public get attributes() {
|
|
147
202
|
return SharedNumberSequenceFactory.Attributes;
|
|
148
203
|
}
|
|
149
204
|
|
|
150
205
|
/**
|
|
151
206
|
* {@inheritDoc @fluidframework/datastore-definitions#IChannelFactory.load}
|
|
207
|
+
*
|
|
208
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
209
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
152
210
|
*/
|
|
153
211
|
public async load(
|
|
154
212
|
runtime: IFluidDataStoreRuntime,
|
|
@@ -160,6 +218,10 @@ export class SharedNumberSequenceFactory implements IChannelFactory {
|
|
|
160
218
|
return sharedSeq;
|
|
161
219
|
}
|
|
162
220
|
|
|
221
|
+
/**
|
|
222
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
223
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
224
|
+
*/
|
|
163
225
|
public create(document: IFluidDataStoreRuntime, id: string): ISharedObject {
|
|
164
226
|
const sharedString = new SharedNumberSequence(document, id, this.attributes);
|
|
165
227
|
sharedString.initializeLocal();
|
|
@@ -12,6 +12,9 @@ import { SharedSequence } from "./sharedSequence";
|
|
|
12
12
|
* at a position within the sequence. See the
|
|
13
13
|
* {@link https://fluidframework.com/docs/data-structures/sequences/ | sequence documentation}
|
|
14
14
|
* for details on working with sequences.
|
|
15
|
+
*
|
|
16
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
17
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
15
18
|
*/
|
|
16
19
|
export class SharedNumberSequence extends SharedSequence<number> {
|
|
17
20
|
/**
|
|
@@ -20,6 +23,9 @@ export class SharedNumberSequence extends SharedSequence<number> {
|
|
|
20
23
|
* @param runtime - data store runtime the new shared number sequence belongs to
|
|
21
24
|
* @param id - optional name of the shared number sequence
|
|
22
25
|
* @returns newly create shared number sequence (but not attached yet)
|
|
26
|
+
*
|
|
27
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
28
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
23
29
|
*/
|
|
24
30
|
public static create(runtime: IFluidDataStoreRuntime, id?: string) {
|
|
25
31
|
return runtime.createChannel(id,
|
|
@@ -30,15 +36,26 @@ export class SharedNumberSequence extends SharedSequence<number> {
|
|
|
30
36
|
* Get a factory for SharedNumberSequence to register with the data store.
|
|
31
37
|
*
|
|
32
38
|
* @returns a factory that creates and load SharedNumberSequence
|
|
39
|
+
*
|
|
40
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
41
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
33
42
|
*/
|
|
34
43
|
public static getFactory() {
|
|
35
44
|
return new SharedNumberSequenceFactory();
|
|
36
45
|
}
|
|
37
46
|
|
|
47
|
+
/**
|
|
48
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
49
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
50
|
+
*/
|
|
38
51
|
constructor(document: IFluidDataStoreRuntime, public id: string, attributes: IChannelAttributes) {
|
|
39
52
|
super(document, id, attributes, SharedNumberSequenceFactory.segmentFromSpec);
|
|
40
53
|
}
|
|
41
54
|
|
|
55
|
+
/**
|
|
56
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
57
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
58
|
+
*/
|
|
42
59
|
public getRange(start: number, end?: number) {
|
|
43
60
|
return this.getItems(start, end);
|
|
44
61
|
}
|
|
@@ -12,6 +12,9 @@ import { SharedSequence } from "./sharedSequence";
|
|
|
12
12
|
* at a position within the sequence. See the
|
|
13
13
|
* {@link https://fluidframework.com/docs/data-structures/sequences/ | sequence documentation}
|
|
14
14
|
* for details on working with sequences.
|
|
15
|
+
*
|
|
16
|
+
* @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.
|
|
17
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
15
18
|
*/
|
|
16
19
|
export class SharedObjectSequence<T> extends SharedSequence<T> {
|
|
17
20
|
/**
|
|
@@ -20,6 +23,9 @@ export class SharedObjectSequence<T> extends SharedSequence<T> {
|
|
|
20
23
|
* @param runtime - data store runtime the new shared object sequence belongs to
|
|
21
24
|
* @param id - optional name of the shared object sequence
|
|
22
25
|
* @returns newly create shared object sequence (but not attached yet)
|
|
26
|
+
*
|
|
27
|
+
* @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.
|
|
28
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
23
29
|
*/
|
|
24
30
|
// eslint-disable-next-line @typescript-eslint/no-shadow
|
|
25
31
|
public static create<T>(runtime: IFluidDataStoreRuntime, id?: string) {
|
|
@@ -30,15 +36,26 @@ export class SharedObjectSequence<T> extends SharedSequence<T> {
|
|
|
30
36
|
* Get a factory for SharedObjectSequence to register with the data store.
|
|
31
37
|
*
|
|
32
38
|
* @returns a factory that creates and load SharedObjectSequence
|
|
39
|
+
*
|
|
40
|
+
* @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.
|
|
41
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
33
42
|
*/
|
|
34
43
|
public static getFactory() {
|
|
35
44
|
return new SharedObjectSequenceFactory();
|
|
36
45
|
}
|
|
37
46
|
|
|
47
|
+
/**
|
|
48
|
+
* @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.
|
|
49
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
50
|
+
*/
|
|
38
51
|
constructor(document: IFluidDataStoreRuntime, public id: string, attributes: IChannelAttributes) {
|
|
39
52
|
super(document, id, attributes, SharedObjectSequenceFactory.segmentFromSpec);
|
|
40
53
|
}
|
|
41
54
|
|
|
55
|
+
/**
|
|
56
|
+
* @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.
|
|
57
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
58
|
+
*/
|
|
42
59
|
public getRange(start: number, end?: number): Serializable<T>[] {
|
|
43
60
|
return this.getItems(start, end);
|
|
44
61
|
}
|