@fluid-experimental/sequence-deprecated 2.0.0-internal.2.0.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/.editorconfig +7 -0
- package/.eslintrc.js +17 -0
- package/.vscode/launch.json +14 -0
- package/LICENSE +21 -0
- package/README.md +3 -0
- package/api-extractor.json +12 -0
- package/dist/index.d.ts +8 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +20 -0
- package/dist/index.js.map +1 -0
- package/dist/packageVersion.d.ts +9 -0
- package/dist/packageVersion.d.ts.map +1 -0
- package/dist/packageVersion.js +12 -0
- package/dist/packageVersion.js.map +1 -0
- package/dist/sequenceFactory.d.ts +95 -0
- package/dist/sequenceFactory.d.ts.map +1 -0
- package/dist/sequenceFactory.js +152 -0
- package/dist/sequenceFactory.js.map +1 -0
- package/dist/sharedNumberSequence.d.ts +50 -0
- package/dist/sharedNumberSequence.d.ts.map +1 -0
- package/dist/sharedNumberSequence.js +67 -0
- package/dist/sharedNumberSequence.js.map +1 -0
- package/dist/sharedObjectSequence.d.ts +50 -0
- package/dist/sharedObjectSequence.d.ts.map +1 -0
- package/dist/sharedObjectSequence.js +61 -0
- package/dist/sharedObjectSequence.js.map +1 -0
- package/dist/sparsematrix.d.ts +152 -0
- package/dist/sparsematrix.d.ts.map +1 -0
- package/dist/sparsematrix.js +349 -0
- package/dist/sparsematrix.js.map +1 -0
- package/lib/index.d.ts +8 -0
- package/lib/index.d.ts.map +1 -0
- package/lib/index.js +8 -0
- package/lib/index.js.map +1 -0
- package/lib/packageVersion.d.ts +9 -0
- package/lib/packageVersion.d.ts.map +1 -0
- package/lib/packageVersion.js +9 -0
- package/lib/packageVersion.js.map +1 -0
- package/lib/sequenceFactory.d.ts +95 -0
- package/lib/sequenceFactory.d.ts.map +1 -0
- package/lib/sequenceFactory.js +147 -0
- package/lib/sequenceFactory.js.map +1 -0
- package/lib/sharedNumberSequence.d.ts +50 -0
- package/lib/sharedNumberSequence.d.ts.map +1 -0
- package/lib/sharedNumberSequence.js +63 -0
- package/lib/sharedNumberSequence.js.map +1 -0
- package/lib/sharedObjectSequence.d.ts +50 -0
- package/lib/sharedObjectSequence.d.ts.map +1 -0
- package/lib/sharedObjectSequence.js +57 -0
- package/lib/sharedObjectSequence.js.map +1 -0
- package/lib/sparsematrix.d.ts +152 -0
- package/lib/sparsematrix.d.ts.map +1 -0
- package/lib/sparsematrix.js +340 -0
- package/lib/sparsematrix.js.map +1 -0
- package/package.json +92 -0
- package/src/index.ts +8 -0
- package/src/packageVersion.ts +9 -0
- package/src/sequenceFactory.ts +181 -0
- package/src/sharedNumberSequence.ts +68 -0
- package/src/sharedObjectSequence.ts +62 -0
- package/src/sparsematrix.ts +441 -0
- package/tsconfig.esnext.json +7 -0
- package/tsconfig.json +14 -0
package/.editorconfig
ADDED
package/.eslintrc.js
ADDED
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* Copyright (c) Microsoft Corporation and contributors. All rights reserved.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
module.exports = {
|
|
7
|
+
"extends": [
|
|
8
|
+
require.resolve("@fluidframework/eslint-config-fluid")
|
|
9
|
+
],
|
|
10
|
+
"parserOptions": {
|
|
11
|
+
"project": ["./tsconfig.json", "./src/test/tsconfig.json"]
|
|
12
|
+
},
|
|
13
|
+
"rules": {
|
|
14
|
+
"@typescript-eslint/no-use-before-define": "off",
|
|
15
|
+
"@typescript-eslint/strict-boolean-expressions": "off"
|
|
16
|
+
}
|
|
17
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
{
|
|
2
|
+
// Use IntelliSense to learn about possible attributes.
|
|
3
|
+
// Hover to view descriptions of existing attributes.
|
|
4
|
+
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
|
|
5
|
+
"version": "0.2.0",
|
|
6
|
+
"configurations": [{
|
|
7
|
+
"name": "Sequence Test",
|
|
8
|
+
"type": "node",
|
|
9
|
+
"request": "launch",
|
|
10
|
+
"program": "${workspaceRoot}/../../../node_modules/mocha/bin/_mocha",
|
|
11
|
+
"args": ["dist/test", "--no-timeouts", "--exit"],
|
|
12
|
+
"cwd": "${workspaceRoot}",
|
|
13
|
+
}]
|
|
14
|
+
}
|
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
Copyright (c) Microsoft Corporation and contributors. All rights reserved.
|
|
2
|
+
|
|
3
|
+
MIT License
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED *AS IS*, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://developer.microsoft.com/json-schemas/api-extractor/v7/api-extractor.schema.json",
|
|
3
|
+
"extends": "@fluidframework/build-common/api-extractor-common-report.json",
|
|
4
|
+
"messages": {
|
|
5
|
+
"extractorMessageReporting": {
|
|
6
|
+
"ae-internal-missing-underscore": {
|
|
7
|
+
"logLevel": "none",
|
|
8
|
+
"addToApiReportFile": false
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
}
|
|
12
|
+
}
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* Copyright (c) Microsoft Corporation and contributors. All rights reserved.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*/
|
|
5
|
+
export * from "./sharedNumberSequence";
|
|
6
|
+
export * from "./sharedObjectSequence";
|
|
7
|
+
export * from "./sparsematrix";
|
|
8
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,cAAc,wBAAwB,CAAC;AACvC,cAAc,wBAAwB,CAAC;AACvC,cAAc,gBAAgB,CAAC"}
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/*!
|
|
3
|
+
* Copyright (c) Microsoft Corporation and contributors. All rights reserved.
|
|
4
|
+
* Licensed under the MIT License.
|
|
5
|
+
*/
|
|
6
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
7
|
+
if (k2 === undefined) k2 = k;
|
|
8
|
+
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./sharedNumberSequence"), exports);
|
|
18
|
+
__exportStar(require("./sharedObjectSequence"), exports);
|
|
19
|
+
__exportStar(require("./sparsematrix"), exports);
|
|
20
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;;;;;;;;;;AAEH,yDAAuC;AACvC,yDAAuC;AACvC,iDAA+B","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nexport * from \"./sharedNumberSequence\";\nexport * from \"./sharedObjectSequence\";\nexport * from \"./sparsematrix\";\n"]}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* Copyright (c) Microsoft Corporation and contributors. All rights reserved.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*
|
|
5
|
+
* THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY
|
|
6
|
+
*/
|
|
7
|
+
export declare const pkgName = "@fluid-experimental/sequence-deprecated";
|
|
8
|
+
export declare const pkgVersion = "2.0.0-internal.2.0.0";
|
|
9
|
+
//# sourceMappingURL=packageVersion.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"packageVersion.d.ts","sourceRoot":"","sources":["../src/packageVersion.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,eAAO,MAAM,OAAO,4CAA4C,CAAC;AACjE,eAAO,MAAM,UAAU,yBAAyB,CAAC"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/*!
|
|
3
|
+
* Copyright (c) Microsoft Corporation and contributors. All rights reserved.
|
|
4
|
+
* Licensed under the MIT License.
|
|
5
|
+
*
|
|
6
|
+
* THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY
|
|
7
|
+
*/
|
|
8
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9
|
+
exports.pkgVersion = exports.pkgName = void 0;
|
|
10
|
+
exports.pkgName = "@fluid-experimental/sequence-deprecated";
|
|
11
|
+
exports.pkgVersion = "2.0.0-internal.2.0.0";
|
|
12
|
+
//# sourceMappingURL=packageVersion.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"packageVersion.js","sourceRoot":"","sources":["../src/packageVersion.ts"],"names":[],"mappings":";AAAA;;;;;GAKG;;;AAEU,QAAA,OAAO,GAAG,yCAAyC,CAAC;AACpD,QAAA,UAAU,GAAG,sBAAsB,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n *\n * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY\n */\n\nexport const pkgName = \"@fluid-experimental/sequence-deprecated\";\nexport const pkgVersion = \"2.0.0-internal.2.0.0\";\n"]}
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* Copyright (c) Microsoft Corporation and contributors. All rights reserved.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*/
|
|
5
|
+
import { IChannelAttributes, IFluidDataStoreRuntime, IChannelServices, IChannelFactory } from "@fluidframework/datastore-definitions";
|
|
6
|
+
import { IJSONSegment } from "@fluidframework/merge-tree";
|
|
7
|
+
import { ISharedObject } from "@fluidframework/shared-object-base";
|
|
8
|
+
import { SubSequence } from "@fluidframework/sequence";
|
|
9
|
+
/**
|
|
10
|
+
* @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.
|
|
11
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
12
|
+
*/
|
|
13
|
+
export declare class SharedObjectSequenceFactory implements IChannelFactory {
|
|
14
|
+
/**
|
|
15
|
+
* @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.
|
|
16
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
17
|
+
*/
|
|
18
|
+
static Type: string;
|
|
19
|
+
/**
|
|
20
|
+
* @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.
|
|
21
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
22
|
+
*/
|
|
23
|
+
static readonly Attributes: IChannelAttributes;
|
|
24
|
+
/**
|
|
25
|
+
* @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.
|
|
26
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
27
|
+
*/
|
|
28
|
+
static segmentFromSpec(segSpec: IJSONSegment): SubSequence<object>;
|
|
29
|
+
/**
|
|
30
|
+
* @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.
|
|
31
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
32
|
+
*/
|
|
33
|
+
get type(): string;
|
|
34
|
+
/**
|
|
35
|
+
* @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.
|
|
36
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
37
|
+
*/
|
|
38
|
+
get attributes(): IChannelAttributes;
|
|
39
|
+
/**
|
|
40
|
+
* {@inheritDoc @fluidframework/datastore-definitions#IChannelFactory.load}
|
|
41
|
+
*
|
|
42
|
+
* @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.
|
|
43
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
44
|
+
*/
|
|
45
|
+
load(runtime: IFluidDataStoreRuntime, id: string, services: IChannelServices, attributes: IChannelAttributes): Promise<ISharedObject>;
|
|
46
|
+
/**
|
|
47
|
+
* @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.
|
|
48
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
49
|
+
*/
|
|
50
|
+
create(document: IFluidDataStoreRuntime, id: string): ISharedObject;
|
|
51
|
+
}
|
|
52
|
+
/**
|
|
53
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
54
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
55
|
+
*/
|
|
56
|
+
export declare class SharedNumberSequenceFactory implements IChannelFactory {
|
|
57
|
+
/**
|
|
58
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
59
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
60
|
+
*/
|
|
61
|
+
static Type: string;
|
|
62
|
+
/**
|
|
63
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
64
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
65
|
+
*/
|
|
66
|
+
static readonly Attributes: IChannelAttributes;
|
|
67
|
+
/**
|
|
68
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
69
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
70
|
+
*/
|
|
71
|
+
static segmentFromSpec(segSpec: IJSONSegment): SubSequence<number>;
|
|
72
|
+
/**
|
|
73
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
74
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
75
|
+
*/
|
|
76
|
+
get type(): string;
|
|
77
|
+
/**
|
|
78
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
79
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
80
|
+
*/
|
|
81
|
+
get attributes(): IChannelAttributes;
|
|
82
|
+
/**
|
|
83
|
+
* {@inheritDoc @fluidframework/datastore-definitions#IChannelFactory.load}
|
|
84
|
+
*
|
|
85
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
86
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
87
|
+
*/
|
|
88
|
+
load(runtime: IFluidDataStoreRuntime, id: string, services: IChannelServices, attributes: IChannelAttributes): Promise<ISharedObject>;
|
|
89
|
+
/**
|
|
90
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
91
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
92
|
+
*/
|
|
93
|
+
create(document: IFluidDataStoreRuntime, id: string): ISharedObject;
|
|
94
|
+
}
|
|
95
|
+
//# sourceMappingURL=sequenceFactory.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sequenceFactory.d.ts","sourceRoot":"","sources":["../src/sequenceFactory.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EACH,kBAAkB,EAClB,sBAAsB,EACtB,gBAAgB,EAChB,eAAe,EAClB,MAAM,uCAAuC,CAAC;AAC/C,OAAO,EACH,YAAY,EACf,MAAM,4BAA4B,CAAC;AACpC,OAAO,EAAE,aAAa,EAAE,MAAM,oCAAoC,CAAC;AACnE,OAAO,EAAmB,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAKxE;;;GAGG;AACH,qBAAa,2BAA4B,YAAW,eAAe;IAC/D;;;OAGG;IACH,OAAc,IAAI,SAAiE;IAEnF;;;OAGG;IACH,gBAAuB,UAAU,EAAE,kBAAkB,CAInD;IAEF;;;OAGG;WACW,eAAe,CAAC,OAAO,EAAE,YAAY,GAAG,WAAW,CAAC,MAAM,CAAC;IAazE;;;OAGG;IACH,IAAW,IAAI,WAEd;IAED;;;OAGG;IACH,IAAW,UAAU,uBAEpB;IAED;;;;;OAKG;IACU,IAAI,CACb,OAAO,EAAE,sBAAsB,EAC/B,EAAE,EAAE,MAAM,EACV,QAAQ,EAAE,gBAAgB,EAC1B,UAAU,EAAE,kBAAkB,GAAG,OAAO,CAAC,aAAa,CAAC;IAM3D;;;OAGG;IACI,MAAM,CAAC,QAAQ,EAAE,sBAAsB,EAAE,EAAE,EAAE,MAAM,GAAG,aAAa;CAK7E;AAED;;;GAGG;AACH,qBAAa,2BAA4B,YAAW,eAAe;IAC/D;;;OAGG;IACH,OAAc,IAAI,SAAiE;IAEnF;;;OAGG;IACH,gBAAuB,UAAU,EAAE,kBAAkB,CAInD;IAEF;;;OAGG;WACW,eAAe,CAAC,OAAO,EAAE,YAAY,GAAG,WAAW,CAAC,MAAM,CAAC;IAazE;;;OAGG;IACH,IAAW,IAAI,WAEd;IAED;;;OAGG;IACH,IAAW,UAAU,uBAEpB;IAED;;;;;OAKG;IACU,IAAI,CACb,OAAO,EAAE,sBAAsB,EAC/B,EAAE,EAAE,MAAM,EACV,QAAQ,EAAE,gBAAgB,EAC1B,UAAU,EAAE,kBAAkB,GAAG,OAAO,CAAC,aAAa,CAAC;IAM3D;;;OAGG;IACI,MAAM,CAAC,QAAQ,EAAE,sBAAsB,EAAE,EAAE,EAAE,MAAM,GAAG,aAAa;CAK7E"}
|
|
@@ -0,0 +1,152 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/*!
|
|
3
|
+
* Copyright (c) Microsoft Corporation and contributors. All rights reserved.
|
|
4
|
+
* Licensed under the MIT License.
|
|
5
|
+
*/
|
|
6
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
+
exports.SharedNumberSequenceFactory = exports.SharedObjectSequenceFactory = void 0;
|
|
8
|
+
const sequence_1 = require("@fluidframework/sequence");
|
|
9
|
+
const packageVersion_1 = require("./packageVersion");
|
|
10
|
+
const sharedNumberSequence_1 = require("./sharedNumberSequence");
|
|
11
|
+
const sharedObjectSequence_1 = require("./sharedObjectSequence");
|
|
12
|
+
/**
|
|
13
|
+
* @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.
|
|
14
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
15
|
+
*/
|
|
16
|
+
class SharedObjectSequenceFactory {
|
|
17
|
+
/**
|
|
18
|
+
* @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.
|
|
19
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
20
|
+
*/
|
|
21
|
+
static segmentFromSpec(segSpec) {
|
|
22
|
+
const runSegment = segSpec;
|
|
23
|
+
if (runSegment.items) {
|
|
24
|
+
const seg = new sequence_1.SubSequence(runSegment.items);
|
|
25
|
+
if (runSegment.props) {
|
|
26
|
+
seg.addProperties(runSegment.props);
|
|
27
|
+
}
|
|
28
|
+
return seg;
|
|
29
|
+
}
|
|
30
|
+
throw new Error(`Unrecognized IJSONObject`);
|
|
31
|
+
}
|
|
32
|
+
/**
|
|
33
|
+
* @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.
|
|
34
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
35
|
+
*/
|
|
36
|
+
get type() {
|
|
37
|
+
return SharedObjectSequenceFactory.Type;
|
|
38
|
+
}
|
|
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)
|
|
42
|
+
*/
|
|
43
|
+
get attributes() {
|
|
44
|
+
return SharedObjectSequenceFactory.Attributes;
|
|
45
|
+
}
|
|
46
|
+
/**
|
|
47
|
+
* {@inheritDoc @fluidframework/datastore-definitions#IChannelFactory.load}
|
|
48
|
+
*
|
|
49
|
+
* @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.
|
|
50
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
51
|
+
*/
|
|
52
|
+
async load(runtime, id, services, attributes) {
|
|
53
|
+
const sharedSeq = new sharedObjectSequence_1.SharedObjectSequence(runtime, id, attributes);
|
|
54
|
+
await sharedSeq.load(services);
|
|
55
|
+
return sharedSeq;
|
|
56
|
+
}
|
|
57
|
+
/**
|
|
58
|
+
* @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.
|
|
59
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
60
|
+
*/
|
|
61
|
+
create(document, id) {
|
|
62
|
+
const sharedString = new sharedObjectSequence_1.SharedObjectSequence(document, id, this.attributes);
|
|
63
|
+
sharedString.initializeLocal();
|
|
64
|
+
return sharedString;
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
exports.SharedObjectSequenceFactory = SharedObjectSequenceFactory;
|
|
68
|
+
/**
|
|
69
|
+
* @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.
|
|
70
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
71
|
+
*/
|
|
72
|
+
SharedObjectSequenceFactory.Type = "https://graph.microsoft.com/types/mergeTree/object-sequence";
|
|
73
|
+
/**
|
|
74
|
+
* @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.
|
|
75
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
76
|
+
*/
|
|
77
|
+
SharedObjectSequenceFactory.Attributes = {
|
|
78
|
+
type: SharedObjectSequenceFactory.Type,
|
|
79
|
+
snapshotFormatVersion: "0.1",
|
|
80
|
+
packageVersion: packageVersion_1.pkgVersion,
|
|
81
|
+
};
|
|
82
|
+
/**
|
|
83
|
+
* @deprecated SharedNumberSequence 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
|
+
*/
|
|
86
|
+
class SharedNumberSequenceFactory {
|
|
87
|
+
/**
|
|
88
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
89
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
90
|
+
*/
|
|
91
|
+
static segmentFromSpec(segSpec) {
|
|
92
|
+
const runSegment = segSpec;
|
|
93
|
+
if (runSegment.items) {
|
|
94
|
+
const seg = new sequence_1.SubSequence(runSegment.items);
|
|
95
|
+
if (runSegment.props) {
|
|
96
|
+
seg.addProperties(runSegment.props);
|
|
97
|
+
}
|
|
98
|
+
return seg;
|
|
99
|
+
}
|
|
100
|
+
throw new Error(`Unrecognized IJSONObject`);
|
|
101
|
+
}
|
|
102
|
+
/**
|
|
103
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
104
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
105
|
+
*/
|
|
106
|
+
get type() {
|
|
107
|
+
return SharedNumberSequenceFactory.Type;
|
|
108
|
+
}
|
|
109
|
+
/**
|
|
110
|
+
* @deprecated SharedNumberSequence 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
|
+
*/
|
|
113
|
+
get attributes() {
|
|
114
|
+
return SharedNumberSequenceFactory.Attributes;
|
|
115
|
+
}
|
|
116
|
+
/**
|
|
117
|
+
* {@inheritDoc @fluidframework/datastore-definitions#IChannelFactory.load}
|
|
118
|
+
*
|
|
119
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
120
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
121
|
+
*/
|
|
122
|
+
async load(runtime, id, services, attributes) {
|
|
123
|
+
const sharedSeq = new sharedNumberSequence_1.SharedNumberSequence(runtime, id, attributes);
|
|
124
|
+
await sharedSeq.load(services);
|
|
125
|
+
return sharedSeq;
|
|
126
|
+
}
|
|
127
|
+
/**
|
|
128
|
+
* @deprecated SharedNumberSequence 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)
|
|
130
|
+
*/
|
|
131
|
+
create(document, id) {
|
|
132
|
+
const sharedString = new sharedNumberSequence_1.SharedNumberSequence(document, id, this.attributes);
|
|
133
|
+
sharedString.initializeLocal();
|
|
134
|
+
return sharedString;
|
|
135
|
+
}
|
|
136
|
+
}
|
|
137
|
+
exports.SharedNumberSequenceFactory = SharedNumberSequenceFactory;
|
|
138
|
+
/**
|
|
139
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
140
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
141
|
+
*/
|
|
142
|
+
SharedNumberSequenceFactory.Type = "https://graph.microsoft.com/types/mergeTree/number-sequence";
|
|
143
|
+
/**
|
|
144
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
145
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
146
|
+
*/
|
|
147
|
+
SharedNumberSequenceFactory.Attributes = {
|
|
148
|
+
type: SharedNumberSequenceFactory.Type,
|
|
149
|
+
snapshotFormatVersion: "0.1",
|
|
150
|
+
packageVersion: packageVersion_1.pkgVersion,
|
|
151
|
+
};
|
|
152
|
+
//# sourceMappingURL=sequenceFactory.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sequenceFactory.js","sourceRoot":"","sources":["../src/sequenceFactory.ts"],"names":[],"mappings":"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","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport {\n IChannelAttributes,\n IFluidDataStoreRuntime,\n IChannelServices,\n IChannelFactory,\n} from \"@fluidframework/datastore-definitions\";\nimport {\n IJSONSegment,\n} from \"@fluidframework/merge-tree\";\nimport { ISharedObject } from \"@fluidframework/shared-object-base\";\nimport { IJSONRunSegment, SubSequence } from \"@fluidframework/sequence\";\nimport { pkgVersion } from \"./packageVersion\";\nimport { SharedNumberSequence } from \"./sharedNumberSequence\";\nimport { SharedObjectSequence } from \"./sharedObjectSequence\";\n\n/**\n * @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.\n * For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)\n */\nexport class SharedObjectSequenceFactory implements IChannelFactory {\n /**\n * @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.\n * For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)\n */\n public static Type = \"https://graph.microsoft.com/types/mergeTree/object-sequence\";\n\n /**\n * @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.\n * For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)\n */\n public static readonly Attributes: IChannelAttributes = {\n type: SharedObjectSequenceFactory.Type,\n snapshotFormatVersion: \"0.1\",\n packageVersion: pkgVersion,\n };\n\n /**\n * @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.\n * For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)\n */\n public static segmentFromSpec(segSpec: IJSONSegment): SubSequence<object> {\n const runSegment = segSpec as IJSONRunSegment<object>;\n if (runSegment.items) {\n const seg = new SubSequence<object>(runSegment.items);\n if (runSegment.props) {\n seg.addProperties(runSegment.props);\n }\n return seg;\n }\n\n throw new Error(`Unrecognized IJSONObject`);\n }\n\n /**\n * @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.\n * For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)\n */\n public get type() {\n return SharedObjectSequenceFactory.Type;\n }\n\n /**\n * @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.\n * For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)\n */\n public get attributes() {\n return SharedObjectSequenceFactory.Attributes;\n }\n\n /**\n * {@inheritDoc @fluidframework/datastore-definitions#IChannelFactory.load}\n *\n * @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.\n * For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)\n */\n public async load(\n runtime: IFluidDataStoreRuntime,\n id: string,\n services: IChannelServices,\n attributes: IChannelAttributes): Promise<ISharedObject> {\n const sharedSeq = new SharedObjectSequence<object>(runtime, id, attributes);\n await sharedSeq.load(services);\n return sharedSeq;\n }\n\n /**\n * @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.\n * For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)\n */\n public create(document: IFluidDataStoreRuntime, id: string): ISharedObject {\n const sharedString = new SharedObjectSequence(document, id, this.attributes);\n sharedString.initializeLocal();\n return sharedString;\n }\n}\n\n/**\n * @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.\n * For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)\n */\nexport class SharedNumberSequenceFactory implements IChannelFactory {\n /**\n * @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.\n * For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)\n */\n public static Type = \"https://graph.microsoft.com/types/mergeTree/number-sequence\";\n\n /**\n * @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.\n * For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)\n */\n public static readonly Attributes: IChannelAttributes = {\n type: SharedNumberSequenceFactory.Type,\n snapshotFormatVersion: \"0.1\",\n packageVersion: pkgVersion,\n };\n\n /**\n * @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.\n * For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)\n */\n public static segmentFromSpec(segSpec: IJSONSegment): SubSequence<number> {\n const runSegment = segSpec as IJSONRunSegment<number>;\n if (runSegment.items) {\n const seg = new SubSequence<number>(runSegment.items);\n if (runSegment.props) {\n seg.addProperties(runSegment.props);\n }\n return seg;\n }\n\n throw new Error(`Unrecognized IJSONObject`);\n }\n\n /**\n * @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.\n * For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)\n */\n public get type() {\n return SharedNumberSequenceFactory.Type;\n }\n\n /**\n * @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.\n * For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)\n */\n public get attributes() {\n return SharedNumberSequenceFactory.Attributes;\n }\n\n /**\n * {@inheritDoc @fluidframework/datastore-definitions#IChannelFactory.load}\n *\n * @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.\n * For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)\n */\n public async load(\n runtime: IFluidDataStoreRuntime,\n id: string,\n services: IChannelServices,\n attributes: IChannelAttributes): Promise<ISharedObject> {\n const sharedSeq = new SharedNumberSequence(runtime, id, attributes);\n await sharedSeq.load(services);\n return sharedSeq;\n }\n\n /**\n * @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.\n * For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)\n */\n public create(document: IFluidDataStoreRuntime, id: string): ISharedObject {\n const sharedString = new SharedNumberSequence(document, id, this.attributes);\n sharedString.initializeLocal();\n return sharedString;\n }\n}\n"]}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* Copyright (c) Microsoft Corporation and contributors. All rights reserved.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*/
|
|
5
|
+
import { IFluidDataStoreRuntime, IChannelAttributes } from "@fluidframework/datastore-definitions";
|
|
6
|
+
import { SharedSequence } from "@fluidframework/sequence";
|
|
7
|
+
import { SharedNumberSequenceFactory } from "./sequenceFactory";
|
|
8
|
+
/**
|
|
9
|
+
* The SharedNumberSequence holds a sequence of numbers. Each number will be stored
|
|
10
|
+
* at a position within the sequence. See the
|
|
11
|
+
* {@link https://fluidframework.com/docs/data-structures/sequences/ | sequence documentation}
|
|
12
|
+
* for details on working with sequences.
|
|
13
|
+
*
|
|
14
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
15
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
16
|
+
*/
|
|
17
|
+
export declare class SharedNumberSequence extends SharedSequence<number> {
|
|
18
|
+
id: string;
|
|
19
|
+
/**
|
|
20
|
+
* Create a new shared number sequence
|
|
21
|
+
*
|
|
22
|
+
* @param runtime - data store runtime the new shared number sequence belongs to
|
|
23
|
+
* @param id - optional name of the shared number sequence
|
|
24
|
+
* @returns newly create shared number sequence (but not attached yet)
|
|
25
|
+
*
|
|
26
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
27
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
28
|
+
*/
|
|
29
|
+
static create(runtime: IFluidDataStoreRuntime, id?: string): SharedNumberSequence;
|
|
30
|
+
/**
|
|
31
|
+
* Get a factory for SharedNumberSequence to register with the data store.
|
|
32
|
+
*
|
|
33
|
+
* @returns a factory that creates and load SharedNumberSequence
|
|
34
|
+
*
|
|
35
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
36
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
37
|
+
*/
|
|
38
|
+
static getFactory(): SharedNumberSequenceFactory;
|
|
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)
|
|
42
|
+
*/
|
|
43
|
+
constructor(document: IFluidDataStoreRuntime, id: string, attributes: IChannelAttributes);
|
|
44
|
+
/**
|
|
45
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
46
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
47
|
+
*/
|
|
48
|
+
getRange(start: number, end?: number): number[];
|
|
49
|
+
}
|
|
50
|
+
//# sourceMappingURL=sharedNumberSequence.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sharedNumberSequence.d.ts","sourceRoot":"","sources":["../src/sharedNumberSequence.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,sBAAsB,EAAE,kBAAkB,EAAE,MAAM,uCAAuC,CAAC;AACnG,OAAO,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAC1D,OAAO,EAAE,2BAA2B,EAAE,MAAM,mBAAmB,CAAC;AAEhE;;;;;;;;GAQG;AACH,qBAAa,oBAAqB,SAAQ,cAAc,CAAC,MAAM,CAAC;IAgCP,EAAE,EAAE,MAAM;IA/B/D;;;;;;;;;OASG;WACW,MAAM,CAAC,OAAO,EAAE,sBAAsB,EAAE,EAAE,CAAC,EAAE,MAAM;IAKjE;;;;;;;OAOG;WACW,UAAU;IAIxB;;;OAGG;gBACS,QAAQ,EAAE,sBAAsB,EAAS,EAAE,EAAE,MAAM,EAAE,UAAU,EAAE,kBAAkB;IAU/F;;;OAGG;IACI,QAAQ,CAAC,KAAK,EAAE,MAAM,EAAE,GAAG,CAAC,EAAE,MAAM;CAG9C"}
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/*!
|
|
3
|
+
* Copyright (c) Microsoft Corporation and contributors. All rights reserved.
|
|
4
|
+
* Licensed under the MIT License.
|
|
5
|
+
*/
|
|
6
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
+
exports.SharedNumberSequence = void 0;
|
|
8
|
+
const sequence_1 = require("@fluidframework/sequence");
|
|
9
|
+
const sequenceFactory_1 = require("./sequenceFactory");
|
|
10
|
+
/**
|
|
11
|
+
* The SharedNumberSequence holds a sequence of numbers. Each number will be stored
|
|
12
|
+
* at a position within the sequence. See the
|
|
13
|
+
* {@link https://fluidframework.com/docs/data-structures/sequences/ | sequence documentation}
|
|
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)
|
|
18
|
+
*/
|
|
19
|
+
class SharedNumberSequence extends sequence_1.SharedSequence {
|
|
20
|
+
/**
|
|
21
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
22
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
23
|
+
*/
|
|
24
|
+
constructor(document, id, attributes) {
|
|
25
|
+
super(document, id, attributes, (spec) => {
|
|
26
|
+
const segment = sequenceFactory_1.SharedNumberSequenceFactory.segmentFromSpec(spec);
|
|
27
|
+
if (!segment) {
|
|
28
|
+
throw new Error("expected `spec` to be valid `ISegment`");
|
|
29
|
+
}
|
|
30
|
+
return segment;
|
|
31
|
+
});
|
|
32
|
+
this.id = id;
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
* Create a new shared number sequence
|
|
36
|
+
*
|
|
37
|
+
* @param runtime - data store runtime the new shared number sequence belongs to
|
|
38
|
+
* @param id - optional name of the shared number sequence
|
|
39
|
+
* @returns newly create shared number sequence (but not attached yet)
|
|
40
|
+
*
|
|
41
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
42
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
43
|
+
*/
|
|
44
|
+
static create(runtime, id) {
|
|
45
|
+
return runtime.createChannel(id, sequenceFactory_1.SharedNumberSequenceFactory.Type);
|
|
46
|
+
}
|
|
47
|
+
/**
|
|
48
|
+
* Get a factory for SharedNumberSequence to register with the data store.
|
|
49
|
+
*
|
|
50
|
+
* @returns a factory that creates and load SharedNumberSequence
|
|
51
|
+
*
|
|
52
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
53
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
54
|
+
*/
|
|
55
|
+
static getFactory() {
|
|
56
|
+
return new sequenceFactory_1.SharedNumberSequenceFactory();
|
|
57
|
+
}
|
|
58
|
+
/**
|
|
59
|
+
* @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.
|
|
60
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
61
|
+
*/
|
|
62
|
+
getRange(start, end) {
|
|
63
|
+
return this.getItems(start, end);
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
exports.SharedNumberSequence = SharedNumberSequence;
|
|
67
|
+
//# sourceMappingURL=sharedNumberSequence.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sharedNumberSequence.js","sourceRoot":"","sources":["../src/sharedNumberSequence.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAGH,uDAA0D;AAC1D,uDAAgE;AAEhE;;;;;;;;GAQG;AACH,MAAa,oBAAqB,SAAQ,yBAAsB;IA4B5D;;;OAGG;IACH,YAAY,QAAgC,EAAS,EAAU,EAAE,UAA8B;QAC3F,KAAK,CAAC,QAAQ,EAAE,EAAE,EAAE,UAAU,EAAE,CAAC,IAAI,EAAE,EAAE;YACrC,MAAM,OAAO,GAAG,6CAA2B,CAAC,eAAe,CAAC,IAAI,CAAC,CAAC;YAClE,IAAI,CAAC,OAAO,EAAE;gBACV,MAAM,IAAI,KAAK,CAAC,wCAAwC,CAAC,CAAC;aAC7D;YACD,OAAO,OAAO,CAAC;QACnB,CAAC,CAAC,CAAC;QAP8C,OAAE,GAAF,EAAE,CAAQ;IAQ/D,CAAC;IAvCD;;;;;;;;;OASG;IACI,MAAM,CAAC,MAAM,CAAC,OAA+B,EAAE,EAAW;QAC7D,OAAO,OAAO,CAAC,aAAa,CAAC,EAAE,EAC3B,6CAA2B,CAAC,IAAI,CAAyB,CAAC;IAClE,CAAC;IAED;;;;;;;OAOG;IACI,MAAM,CAAC,UAAU;QACpB,OAAO,IAAI,6CAA2B,EAAE,CAAC;IAC7C,CAAC;IAgBD;;;OAGG;IACI,QAAQ,CAAC,KAAa,EAAE,GAAY;QACvC,OAAO,IAAI,CAAC,QAAQ,CAAC,KAAK,EAAE,GAAG,CAAC,CAAC;IACrC,CAAC;CACJ;AAjDD,oDAiDC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { IFluidDataStoreRuntime, IChannelAttributes } from \"@fluidframework/datastore-definitions\";\nimport { SharedSequence } from \"@fluidframework/sequence\";\nimport { SharedNumberSequenceFactory } from \"./sequenceFactory\";\n\n/**\n * The SharedNumberSequence holds a sequence of numbers. Each number will be stored\n * at a position within the sequence. See the\n * {@link https://fluidframework.com/docs/data-structures/sequences/ | sequence documentation}\n * for details on working with sequences.\n *\n * @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.\n * For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)\n */\nexport class SharedNumberSequence extends SharedSequence<number> {\n /**\n * Create a new shared number sequence\n *\n * @param runtime - data store runtime the new shared number sequence belongs to\n * @param id - optional name of the shared number sequence\n * @returns newly create shared number sequence (but not attached yet)\n *\n * @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.\n * For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)\n */\n public static create(runtime: IFluidDataStoreRuntime, id?: string) {\n return runtime.createChannel(id,\n SharedNumberSequenceFactory.Type) as SharedNumberSequence;\n }\n\n /**\n * Get a factory for SharedNumberSequence to register with the data store.\n *\n * @returns a factory that creates and load SharedNumberSequence\n *\n * @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.\n * For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)\n */\n public static getFactory() {\n return new SharedNumberSequenceFactory();\n }\n\n /**\n * @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.\n * For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)\n */\n constructor(document: IFluidDataStoreRuntime, public id: string, attributes: IChannelAttributes) {\n super(document, id, attributes, (spec) => {\n const segment = SharedNumberSequenceFactory.segmentFromSpec(spec);\n if (!segment) {\n throw new Error(\"expected `spec` to be valid `ISegment`\");\n }\n return segment;\n });\n }\n\n /**\n * @deprecated SharedNumberSequence is not recommended for use and will be removed in an upcoming release.\n * For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)\n */\n public getRange(start: number, end?: number) {\n return this.getItems(start, end);\n }\n}\n"]}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* Copyright (c) Microsoft Corporation and contributors. All rights reserved.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*/
|
|
5
|
+
import { IFluidDataStoreRuntime, IChannelAttributes, Serializable } from "@fluidframework/datastore-definitions";
|
|
6
|
+
import { SharedSequence } from "@fluidframework/sequence";
|
|
7
|
+
import { SharedObjectSequenceFactory } from "./sequenceFactory";
|
|
8
|
+
/**
|
|
9
|
+
* The SharedObjectSequence holds a sequence of serializable objects. Each object will be stored
|
|
10
|
+
* at a position within the sequence. See the
|
|
11
|
+
* {@link https://fluidframework.com/docs/data-structures/sequences/ | sequence documentation}
|
|
12
|
+
* for details on working with sequences.
|
|
13
|
+
*
|
|
14
|
+
* @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.
|
|
15
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
16
|
+
*/
|
|
17
|
+
export declare class SharedObjectSequence<T> extends SharedSequence<T> {
|
|
18
|
+
id: string;
|
|
19
|
+
/**
|
|
20
|
+
* Create a new shared object sequence
|
|
21
|
+
*
|
|
22
|
+
* @param runtime - data store runtime the new shared object sequence belongs to
|
|
23
|
+
* @param id - optional name of the shared object sequence
|
|
24
|
+
* @returns newly create shared object sequence (but not attached yet)
|
|
25
|
+
*
|
|
26
|
+
* @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.
|
|
27
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
28
|
+
*/
|
|
29
|
+
static create<T>(runtime: IFluidDataStoreRuntime, id?: string): SharedObjectSequence<T>;
|
|
30
|
+
/**
|
|
31
|
+
* Get a factory for SharedObjectSequence to register with the data store.
|
|
32
|
+
*
|
|
33
|
+
* @returns a factory that creates and load SharedObjectSequence
|
|
34
|
+
*
|
|
35
|
+
* @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.
|
|
36
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
37
|
+
*/
|
|
38
|
+
static getFactory(): SharedObjectSequenceFactory;
|
|
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)
|
|
42
|
+
*/
|
|
43
|
+
constructor(document: IFluidDataStoreRuntime, id: string, attributes: IChannelAttributes);
|
|
44
|
+
/**
|
|
45
|
+
* @deprecated SharedObjectSequence is not recommended for use and will be removed in an upcoming release.
|
|
46
|
+
* For more info, please see [Github issue 8526](https://github.com/microsoft/FluidFramework/issues/8526)
|
|
47
|
+
*/
|
|
48
|
+
getRange(start: number, end?: number): Serializable<T>[];
|
|
49
|
+
}
|
|
50
|
+
//# sourceMappingURL=sharedObjectSequence.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sharedObjectSequence.d.ts","sourceRoot":"","sources":["../src/sharedObjectSequence.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,sBAAsB,EAAE,kBAAkB,EAAE,YAAY,EAAE,MAAM,uCAAuC,CAAC;AACjH,OAAO,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAC1D,OAAO,EAAE,2BAA2B,EAAE,MAAM,mBAAmB,CAAC;AAEhE;;;;;;;;GAQG;AACH,qBAAa,oBAAoB,CAAC,CAAC,CAAE,SAAQ,cAAc,CAAC,CAAC,CAAC;IAgCL,EAAE,EAAE,MAAM;IA/B/D;;;;;;;;;OASG;WAEW,MAAM,CAAC,CAAC,EAAE,OAAO,EAAE,sBAAsB,EAAE,EAAE,CAAC,EAAE,MAAM;IAIpE;;;;;;;OAOG;WACW,UAAU;IAIxB;;;OAGG;gBACS,QAAQ,EAAE,sBAAsB,EAAS,EAAE,EAAE,MAAM,EAAE,UAAU,EAAE,kBAAkB;IAI/F;;;OAGG;IACI,QAAQ,CAAC,KAAK,EAAE,MAAM,EAAE,GAAG,CAAC,EAAE,MAAM,GAAG,YAAY,CAAC,CAAC,CAAC,EAAE;CAGlE"}
|