@fluidframework/synthesize 2.0.0-internal.8.0.0 → 2.0.0-rc.1.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/README.md +0 -6
- package/dist/{IFluidDependencySynthesizer.cjs → IFluidDependencySynthesizer.js} +1 -1
- package/dist/IFluidDependencySynthesizer.js.map +1 -0
- package/dist/dependencyContainer.d.ts +1 -1
- package/dist/{dependencyContainer.cjs → dependencyContainer.js} +3 -3
- package/dist/dependencyContainer.js.map +1 -0
- package/dist/{index.cjs → index.js} +3 -3
- package/dist/index.js.map +1 -0
- package/dist/synthesize-alpha.d.ts +44 -2
- package/dist/synthesize-untrimmed.d.ts +2 -2
- package/dist/test/{dependencyContainer.spec.cjs → dependencyContainer.spec.js} +2 -2
- package/dist/test/dependencyContainer.spec.js.map +1 -0
- package/dist/test/tsconfig.tsbuildinfo +1 -0
- package/dist/test/types/{validateSynthesizePrevious.generated.cjs → validateSynthesizePrevious.generated.js} +1 -1
- package/dist/test/types/validateSynthesizePrevious.generated.js.map +1 -0
- package/dist/types.d.ts +2 -2
- package/dist/types.d.ts.map +1 -1
- package/dist/{types.cjs → types.js} +1 -1
- package/dist/types.js.map +1 -0
- package/lib/{IFluidDependencySynthesizer.d.ts → IFluidDependencySynthesizer.d.mts} +1 -1
- package/lib/IFluidDependencySynthesizer.d.mts.map +1 -0
- package/lib/{dependencyContainer.d.ts → dependencyContainer.d.mts} +2 -2
- package/lib/dependencyContainer.d.mts.map +1 -0
- package/lib/dependencyContainer.mjs +1 -1
- package/lib/dependencyContainer.mjs.map +1 -1
- package/lib/{index.d.ts → index.d.mts} +1 -1
- package/lib/index.d.mts.map +1 -0
- package/lib/{synthesize-untrimmed.d.ts → synthesize-alpha.d.mts} +2 -2
- package/lib/{synthesize-alpha.d.ts → synthesize-untrimmed.d.mts} +44 -2
- package/lib/{types.d.ts → types.d.mts} +3 -3
- package/lib/types.d.mts.map +1 -0
- package/lib/types.mjs.map +1 -1
- package/package.json +71 -19
- package/dist/IFluidDependencySynthesizer.cjs.map +0 -1
- package/dist/dependencyContainer.cjs.map +0 -1
- package/dist/index.cjs.map +0 -1
- package/dist/test/dependencyContainer.spec.cjs.map +0 -1
- package/dist/test/types/validateSynthesizePrevious.generated.cjs.map +0 -1
- package/dist/types.cjs.map +0 -1
- package/lib/IFluidDependencySynthesizer.d.ts.map +0 -1
- package/lib/dependencyContainer.d.ts.map +0 -1
- package/lib/index.d.ts.map +0 -1
- package/lib/types.d.ts.map +0 -1
- /package/lib/{synthesize-beta.d.ts → synthesize-beta.d.mts} +0 -0
- /package/lib/{synthesize-public.d.ts → synthesize-public.d.mts} +0 -0
package/README.md
CHANGED
|
@@ -13,12 +13,6 @@ When taking a dependency on a Fluid Framework library, we recommend using a `^`
|
|
|
13
13
|
While Fluid Framework libraries may use different ranges with interdependencies between other Fluid Framework libraries,
|
|
14
14
|
library consumers should always prefer `^`.
|
|
15
15
|
|
|
16
|
-
Note that when depending on a library version of the form `2.0.0-internal.x.y.z`, called the Fluid internal version scheme,
|
|
17
|
-
you must use a `>= <` dependency range (such as `>=2.0.0-internal.x.y.z <2.0.0-internal.w.0.0` where `w` is `x+1`).
|
|
18
|
-
Standard `^` and `~` ranges will not work as expected.
|
|
19
|
-
See the [@fluid-tools/version-tools](https://github.com/microsoft/FluidFramework/blob/main/build-tools/packages/version-tools/README.md)
|
|
20
|
-
package for more information including tools to convert between version schemes.
|
|
21
|
-
|
|
22
16
|
<!-- prettier-ignore-end -->
|
|
23
17
|
|
|
24
18
|
<!-- AUTO-GENERATED-CONTENT:END -->
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"IFluidDependencySynthesizer.js","sourceRoot":"","sources":["../src/IFluidDependencySynthesizer.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAIH;;GAEG;AACU,QAAA,2BAA2B,GACvC,6BAA6B,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { AsyncFluidObjectProvider, FluidObjectSymbolProvider } from \"./types\";\n\n/**\n * @alpha\n */\nexport const IFluidDependencySynthesizer: keyof IProvideFluidDependencySynthesizer =\n\t\"IFluidDependencySynthesizer\";\n\n/**\n * @alpha\n */\nexport interface IProvideFluidDependencySynthesizer {\n\tIFluidDependencySynthesizer: IFluidDependencySynthesizer;\n}\n\n/**\n * IFluidDependencySynthesizer can generate FluidObjects based on the IProvideFluidObject pattern.\n * It allow for registering providers and uses synthesize to generate a new object with the optional\n * and required types.\n * @alpha\n */\nexport interface IFluidDependencySynthesizer extends IProvideFluidDependencySynthesizer {\n\t/**\n\t * synthesize takes optional and required types and returns an object that will fulfill the\n\t * defined types based off objects that has been previously registered.\n\t *\n\t * @param optionalTypes - optional types to be in the Scope object\n\t * @param requiredTypes - required types that need to be in the Scope object\n\t */\n\tsynthesize<O, R = undefined | Record<string, never>>(\n\t\toptionalTypes: FluidObjectSymbolProvider<O>,\n\t\trequiredTypes: Required<FluidObjectSymbolProvider<R>>,\n\t): AsyncFluidObjectProvider<O, R>;\n\n\t/**\n\t * Check if a given type is registered\n\t * @param type - Type to check\n\t */\n\thas(type: string): boolean;\n}\n"]}
|
|
@@ -7,7 +7,7 @@ import { IFluidDependencySynthesizer } from "./IFluidDependencySynthesizer";
|
|
|
7
7
|
/**
|
|
8
8
|
* DependencyContainer is similar to a IoC Container. It takes providers and will
|
|
9
9
|
* synthesize an object based on them when requested.
|
|
10
|
-
* @
|
|
10
|
+
* @alpha
|
|
11
11
|
*/
|
|
12
12
|
export declare class DependencyContainer<TMap> implements IFluidDependencySynthesizer {
|
|
13
13
|
private readonly providers;
|
|
@@ -6,11 +6,11 @@
|
|
|
6
6
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
7
|
exports.DependencyContainer = void 0;
|
|
8
8
|
const core_utils_1 = require("@fluidframework/core-utils");
|
|
9
|
-
const IFluidDependencySynthesizer_1 = require("./IFluidDependencySynthesizer
|
|
9
|
+
const IFluidDependencySynthesizer_1 = require("./IFluidDependencySynthesizer");
|
|
10
10
|
/**
|
|
11
11
|
* DependencyContainer is similar to a IoC Container. It takes providers and will
|
|
12
12
|
* synthesize an object based on them when requested.
|
|
13
|
-
* @
|
|
13
|
+
* @alpha
|
|
14
14
|
*/
|
|
15
15
|
class DependencyContainer {
|
|
16
16
|
get IFluidDependencySynthesizer() {
|
|
@@ -157,4 +157,4 @@ class DependencyContainer {
|
|
|
157
157
|
}
|
|
158
158
|
}
|
|
159
159
|
exports.DependencyContainer = DependencyContainer;
|
|
160
|
-
//# sourceMappingURL=dependencyContainer.
|
|
160
|
+
//# sourceMappingURL=dependencyContainer.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dependencyContainer.js","sourceRoot":"","sources":["../src/dependencyContainer.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAEH,2DAAyD;AAQzD,+EAA4E;AAE5E;;;;GAIG;AACH,MAAa,mBAAmB;IAG/B,IAAW,2BAA2B;QACrC,OAAO,IAAI,CAAC;IACb,CAAC;IAED,YAAmB,GAAG,OAAoD;QANzD,cAAS,GAAG,IAAI,GAAG,EAAwC,CAAC;QAO5E,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC,CAAC,EAAoC,EAAE,CAAC,CAAC,KAAK,SAAS,CAAC,CAAC;IACzF,CAAC;IAED;;;;;OAKG;IACI,QAAQ,CACd,IAAO,EACP,QAA4C;QAE5C,IAAI,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,IAAI,CAAC,EAAE;YAC7B,MAAM,IAAI,KAAK,CACd,6CAA6C,MAAM,CAAC,IAAI,CAAC,sBAAsB,CAC/E,CAAC;SACF;QAED,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,IAAI,EAAE,QAAQ,CAAC,CAAC;IACpC,CAAC;IAED;;;OAGG;IACI,UAAU,CAAC,IAAgB;QACjC,IAAI,IAA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C;iBACH;YACF,CAAC;SACD,CAAC;IACH,CAAC;CACD;AA5KD,kDA4KC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { LazyPromise } from \"@fluidframework/core-utils\";\nimport {\n\tAsyncFluidObjectProvider,\n\tFluidObjectSymbolProvider,\n\tFluidObjectProvider,\n\tAsyncOptionalFluidObjectProvider,\n\tAsyncRequiredFluidObjectProvider,\n} from \"./types\";\nimport { IFluidDependencySynthesizer } from \"./IFluidDependencySynthesizer\";\n\n/**\n * DependencyContainer is similar to a IoC Container. It takes providers and will\n * synthesize an object based on them when requested.\n * @alpha\n */\nexport class DependencyContainer<TMap> implements IFluidDependencySynthesizer {\n\tprivate readonly providers = new Map<keyof TMap, FluidObjectProvider<any>>();\n\tprivate readonly parents: IFluidDependencySynthesizer[];\n\tpublic get IFluidDependencySynthesizer() {\n\t\treturn this;\n\t}\n\n\tpublic constructor(...parents: (IFluidDependencySynthesizer | undefined)[]) {\n\t\tthis.parents = parents.filter((v): v is IFluidDependencySynthesizer => v !== undefined);\n\t}\n\n\t/**\n\t * Add a new provider\n\t * @param type - Name of the Type T being provided\n\t * @param provider - A provider that will resolve the T correctly when asked\n\t * @throws - If passing a type that's already registered\n\t */\n\tpublic register<T extends keyof TMap = keyof TMap>(\n\t\ttype: T,\n\t\tprovider: FluidObjectProvider<Pick<TMap, T>>,\n\t): void {\n\t\tif (this.providers.has(type)) {\n\t\t\tthrow new Error(\n\t\t\t\t`Attempting to register a provider of type ${String(type)} that already exists`,\n\t\t\t);\n\t\t}\n\n\t\tthis.providers.set(type, provider);\n\t}\n\n\t/**\n\t * Remove a provider\n\t * @param type - Name of the provider to remove\n\t */\n\tpublic unregister(type: keyof TMap): void {\n\t\tif (this.providers.has(type)) {\n\t\t\tthis.providers.delete(type);\n\t\t}\n\t}\n\n\t/**\n\t * {@inheritDoc (IFluidDependencySynthesizer:interface).synthesize}\n\t */\n\tpublic synthesize<O, R = undefined | Record<string, never>>(\n\t\toptionalTypes: FluidObjectSymbolProvider<O>,\n\t\trequiredTypes: Required<FluidObjectSymbolProvider<R>>,\n\t): AsyncFluidObjectProvider<O, R> {\n\t\tconst base: AsyncFluidObjectProvider<O, R> = {} as any;\n\t\tthis.generateRequired<R>(base, requiredTypes);\n\t\tthis.generateOptional<O>(base, optionalTypes);\n\t\tObject.defineProperty(base, IFluidDependencySynthesizer, { get: () => this });\n\t\treturn base;\n\t}\n\n\t/**\n\t * {@inheritDoc (IFluidDependencySynthesizer:interface).has}\n\t * @param excludeParents - If true, exclude checking parent registries\n\t */\n\tpublic has(type: string, excludeParents?: boolean): boolean {\n\t\tif (this.providers.has(type as keyof TMap)) {\n\t\t\treturn true;\n\t\t}\n\t\tif (excludeParents !== true) {\n\t\t\treturn this.parents.some((p: IFluidDependencySynthesizer) => p.has(type));\n\t\t}\n\t\treturn false;\n\t}\n\t/**\n\t * @deprecated Needed for backwards compatability.\n\t */\n\tprivate getProvider(provider: string & keyof TMap) {\n\t\t// this was removed, but some partners have trouble with back compat where they\n\t\t// use invalid patterns with FluidObject and IFluidDependencySynthesizer\n\t\t// this is just for back compat until those are removed\n\t\tif (this.has(provider)) {\n\t\t\tif (this.providers.has(provider)) {\n\t\t\t\treturn this.providers.get(provider);\n\t\t\t}\n\t\t\tfor (const parent of this.parents) {\n\t\t\t\tif (parent instanceof DependencyContainer) {\n\t\t\t\t\treturn parent.getProvider(provider);\n\t\t\t\t} else {\n\t\t\t\t\t// older implementations of the IFluidDependencySynthesizer exposed getProvider\n\t\t\t\t\tconst maybeGetProvider: { getProvider?(provider: string & keyof TMap) } =\n\t\t\t\t\t\tparent as any;\n\t\t\t\t\tif (maybeGetProvider?.getProvider !== undefined) {\n\t\t\t\t\t\treturn maybeGetProvider.getProvider(provider);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\tprivate generateRequired<T>(\n\t\tbase: AsyncRequiredFluidObjectProvider<T>,\n\t\ttypes: Required<FluidObjectSymbolProvider<T>>,\n\t) {\n\t\tif (types === undefined) {\n\t\t\treturn;\n\t\t}\n\t\tfor (const key of Object.keys(types) as unknown as (keyof TMap)[]) {\n\t\t\tconst provider = this.resolveProvider(key);\n\t\t\tif (provider === undefined) {\n\t\t\t\tthrow new Error(\n\t\t\t\t\t`Object attempted to be created without registered required provider ${String(\n\t\t\t\t\t\tkey,\n\t\t\t\t\t)}`,\n\t\t\t\t);\n\t\t\t}\n\t\t\tObject.defineProperty(base, key, provider);\n\t\t}\n\t}\n\n\tprivate generateOptional<T>(\n\t\tbase: AsyncOptionalFluidObjectProvider<T>,\n\t\ttypes: FluidObjectSymbolProvider<T>,\n\t) {\n\t\tif (types === undefined) {\n\t\t\treturn;\n\t\t}\n\t\tfor (const key of Object.keys(types) as unknown as (keyof TMap)[]) {\n\t\t\t// back-compat: in 0.56 we allow undefined in the types, but we didn't before\n\t\t\t// this will keep runtime back compat, eventually we should support undefined properties\n\t\t\t// rather than properties that return promises that resolve to undefined\n\t\t\tconst provider = this.resolveProvider(key) ?? { get: async () => undefined };\n\t\t\tObject.defineProperty(base, key, provider);\n\t\t}\n\t}\n\n\tprivate resolveProvider<T extends keyof TMap>(t: T): PropertyDescriptor | undefined {\n\t\t// If we have the provider return it\n\t\tconst provider = this.providers.get(t);\n\t\tif (provider === undefined) {\n\t\t\tfor (const parent of this.parents) {\n\t\t\t\t// eslint-disable-next-line @typescript-eslint/consistent-type-assertions\n\t\t\t\tconst sp = { [t]: t } as FluidObjectSymbolProvider<Pick<TMap, T>>;\n\t\t\t\tconst syn = parent.synthesize<Pick<TMap, T>, Record<string, unknown>>(sp, {});\n\t\t\t\tconst descriptor = Object.getOwnPropertyDescriptor(syn, t);\n\t\t\t\tif (descriptor !== undefined) {\n\t\t\t\t\treturn descriptor;\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn undefined;\n\t\t}\n\n\t\t// The double nested gets are required for lazy loading the provider resolution\n\t\tif (typeof provider === \"function\") {\n\t\t\treturn {\n\t\t\t\t// eslint-disable-next-line @typescript-eslint/promise-function-async\n\t\t\t\tget() {\n\t\t\t\t\tif (provider && typeof provider === \"function\") {\n\t\t\t\t\t\treturn Promise.resolve(this[IFluidDependencySynthesizer])\n\t\t\t\t\t\t\t.then(async (fds): Promise<any> => provider(fds))\n\t\t\t\t\t\t\t.then((p) => p?.[t]);\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t};\n\t\t}\n\t\treturn {\n\t\t\tget() {\n\t\t\t\tif (provider) {\n\t\t\t\t\treturn new LazyPromise(async () => {\n\t\t\t\t\t\treturn Promise.resolve(provider).then((p) => {\n\t\t\t\t\t\t\tif (p) {\n\t\t\t\t\t\t\t\treturn p[t];\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t});\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t},\n\t\t};\n\t}\n}\n"]}
|
|
@@ -5,8 +5,8 @@
|
|
|
5
5
|
*/
|
|
6
6
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
7
|
exports.IFluidDependencySynthesizer = exports.DependencyContainer = void 0;
|
|
8
|
-
var dependencyContainer_1 = require("./dependencyContainer
|
|
8
|
+
var dependencyContainer_1 = require("./dependencyContainer");
|
|
9
9
|
Object.defineProperty(exports, "DependencyContainer", { enumerable: true, get: function () { return dependencyContainer_1.DependencyContainer; } });
|
|
10
|
-
var IFluidDependencySynthesizer_1 = require("./IFluidDependencySynthesizer
|
|
10
|
+
var IFluidDependencySynthesizer_1 = require("./IFluidDependencySynthesizer");
|
|
11
11
|
Object.defineProperty(exports, "IFluidDependencySynthesizer", { enumerable: true, get: function () { return IFluidDependencySynthesizer_1.IFluidDependencySynthesizer; } });
|
|
12
|
-
//# sourceMappingURL=index.
|
|
12
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAEH,6DAA4D;AAAnD,0HAAA,mBAAmB,OAAA;AAC5B,6EAGuC;AAFtC,0IAAA,2BAA2B,OAAA","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nexport { DependencyContainer } from \"./dependencyContainer\";\nexport {\n\tIFluidDependencySynthesizer,\n\tIProvideFluidDependencySynthesizer,\n} from \"./IFluidDependencySynthesizer\";\nexport {\n\tAsyncFluidObjectProvider,\n\tAsyncOptionalFluidObjectProvider,\n\tAsyncRequiredFluidObjectProvider,\n\tFluidObjectProvider,\n\tFluidObjectSymbolProvider,\n} from \"./types\";\n"]}
|
|
@@ -24,9 +24,51 @@ export declare type AsyncRequiredFluidObjectProvider<T> = T extends undefined ?
|
|
|
24
24
|
[P in keyof T]: Promise<NonNullable<Exclude<T[P], undefined | null>>>;
|
|
25
25
|
};
|
|
26
26
|
|
|
27
|
-
|
|
27
|
+
/**
|
|
28
|
+
* DependencyContainer is similar to a IoC Container. It takes providers and will
|
|
29
|
+
* synthesize an object based on them when requested.
|
|
30
|
+
* @alpha
|
|
31
|
+
*/
|
|
32
|
+
export declare class DependencyContainer<TMap> implements IFluidDependencySynthesizer {
|
|
33
|
+
private readonly providers;
|
|
34
|
+
private readonly parents;
|
|
35
|
+
get IFluidDependencySynthesizer(): this;
|
|
36
|
+
constructor(...parents: (IFluidDependencySynthesizer | undefined)[]);
|
|
37
|
+
/**
|
|
38
|
+
* Add a new provider
|
|
39
|
+
* @param type - Name of the Type T being provided
|
|
40
|
+
* @param provider - A provider that will resolve the T correctly when asked
|
|
41
|
+
* @throws - If passing a type that's already registered
|
|
42
|
+
*/
|
|
43
|
+
register<T extends keyof TMap = keyof TMap>(type: T, provider: FluidObjectProvider<Pick<TMap, T>>): void;
|
|
44
|
+
/**
|
|
45
|
+
* Remove a provider
|
|
46
|
+
* @param type - Name of the provider to remove
|
|
47
|
+
*/
|
|
48
|
+
unregister(type: keyof TMap): void;
|
|
49
|
+
/**
|
|
50
|
+
* {@inheritDoc (IFluidDependencySynthesizer:interface).synthesize}
|
|
51
|
+
*/
|
|
52
|
+
synthesize<O, R = undefined | Record<string, never>>(optionalTypes: FluidObjectSymbolProvider<O>, requiredTypes: Required<FluidObjectSymbolProvider<R>>): AsyncFluidObjectProvider<O, R>;
|
|
53
|
+
/**
|
|
54
|
+
* {@inheritDoc (IFluidDependencySynthesizer:interface).has}
|
|
55
|
+
* @param excludeParents - If true, exclude checking parent registries
|
|
56
|
+
*/
|
|
57
|
+
has(type: string, excludeParents?: boolean): boolean;
|
|
58
|
+
/**
|
|
59
|
+
* @deprecated Needed for backwards compatability.
|
|
60
|
+
*/
|
|
61
|
+
private getProvider;
|
|
62
|
+
private generateRequired;
|
|
63
|
+
private generateOptional;
|
|
64
|
+
private resolveProvider;
|
|
65
|
+
}
|
|
28
66
|
|
|
29
|
-
|
|
67
|
+
/**
|
|
68
|
+
* Multiple ways to provide a Fluid object.
|
|
69
|
+
* @alpha
|
|
70
|
+
*/
|
|
71
|
+
export declare type FluidObjectProvider<T> = NonNullable<T> | Promise<NonNullable<T>> | ((dependencyContainer: IFluidDependencySynthesizer) => NonNullable<T>) | ((dependencyContainer: IFluidDependencySynthesizer) => Promise<NonNullable<T>>);
|
|
30
72
|
|
|
31
73
|
/**
|
|
32
74
|
* This is a condensed version of Record that requires the object has all
|
|
@@ -27,7 +27,7 @@ export declare type AsyncRequiredFluidObjectProvider<T> = T extends undefined ?
|
|
|
27
27
|
/**
|
|
28
28
|
* DependencyContainer is similar to a IoC Container. It takes providers and will
|
|
29
29
|
* synthesize an object based on them when requested.
|
|
30
|
-
* @
|
|
30
|
+
* @alpha
|
|
31
31
|
*/
|
|
32
32
|
export declare class DependencyContainer<TMap> implements IFluidDependencySynthesizer {
|
|
33
33
|
private readonly providers;
|
|
@@ -66,7 +66,7 @@ export declare class DependencyContainer<TMap> implements IFluidDependencySynthe
|
|
|
66
66
|
|
|
67
67
|
/**
|
|
68
68
|
* Multiple ways to provide a Fluid object.
|
|
69
|
-
* @
|
|
69
|
+
* @alpha
|
|
70
70
|
*/
|
|
71
71
|
export declare type FluidObjectProvider<T> = NonNullable<T> | Promise<NonNullable<T>> | ((dependencyContainer: IFluidDependencySynthesizer) => NonNullable<T>) | ((dependencyContainer: IFluidDependencySynthesizer) => Promise<NonNullable<T>>);
|
|
72
72
|
|
|
@@ -8,7 +8,7 @@ const assert_1 = require("assert");
|
|
|
8
8
|
const core_interfaces_1 = require("@fluidframework/core-interfaces");
|
|
9
9
|
const datastore_1 = require("@fluidframework/datastore");
|
|
10
10
|
const core_utils_1 = require("@fluidframework/core-utils");
|
|
11
|
-
const index_1 = require("../index
|
|
11
|
+
const index_1 = require("../index");
|
|
12
12
|
const mockHandleContext = {
|
|
13
13
|
absolutePath: "",
|
|
14
14
|
isAttached: false,
|
|
@@ -404,4 +404,4 @@ class PassThru {
|
|
|
404
404
|
}
|
|
405
405
|
}
|
|
406
406
|
}
|
|
407
|
-
//# sourceMappingURL=dependencyContainer.spec.
|
|
407
|
+
//# sourceMappingURL=dependencyContainer.spec.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dependencyContainer.spec.js","sourceRoot":"","sources":["../../src/test/dependencyContainer.spec.ts"],"names":[],"mappings":";AAAA;;;GAGG;;AAEH,mCAA0C;AAE1C,qEAOyC;AACzC,yDAA8D;AAE9D,2DAAyD;AACzD,oCAA+C;AAI/C,MAAM,iBAAiB,GAAwB;IAC9C,YAAY,EAAE,EAAE;IAChB,UAAU,EAAE,KAAK;IACjB,mBAAmB,EAAE,SAAgB;IAErC,WAAW,EAAE,GAAG,EAAE;QACjB,MAAM,IAAI,KAAK,CAAC,yBAAyB,CAAC,CAAC;IAC5C,CAAC;IACD,aAAa,EAAE,GAAG,EAAE;QACnB,MAAM,IAAI,KAAK,CAAC,yBAAyB,CAAC,CAAC;IAC5C,CAAC;CACD,CAAC;AAEF,MAAM,YAAY;IACjB,IAAW,cAAc;Q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AAC,MAAM,CAAC,UAAU,CAAC,aAAa,EAAE,aAAa,CAAC,CAAC;IAC7D,CAAC;IACD,GAAG,CAAC,IAAY;QACf,OAAO,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC;IAC9B,CAAC;IAGD,WAAW,CAAuB,GAAM;QACvC,MAAM,KAAK,GAAG,IAAI,CAAC,MAA8B,CAAC;QAClD,IAAI,KAAK,CAAC,WAAW,EAAE;YACtB,OAAO,KAAK,CAAC,WAAW,CAAC,GAAG,CAAC,CAAC;SAC9B;IACF,CAAC;CACD","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { strict as assert } from \"assert\";\n\nimport {\n\tIFluidLoadable,\n\tIFluidHandleContext,\n\tIFluidHandle,\n\tIProvideFluidLoadable,\n\tIProvideFluidHandle,\n\tFluidObject,\n} from \"@fluidframework/core-interfaces\";\nimport { FluidObjectHandle } from \"@fluidframework/datastore\";\n\nimport { LazyPromise } from \"@fluidframework/core-utils\";\nimport { DependencyContainer } from \"../index\";\nimport { IFluidDependencySynthesizer } from \"../IFluidDependencySynthesizer\";\nimport { AsyncFluidObjectProvider, FluidObjectProvider, FluidObjectSymbolProvider } from \"../types\";\n\nconst mockHandleContext: IFluidHandleContext = {\n\tabsolutePath: \"\",\n\tisAttached: false,\n\tIFluidHandleContext: undefined as any,\n\n\tattachGraph: () => {\n\t\tthrow new Error(\"Method not implemented.\");\n\t},\n\tresolveHandle: () => {\n\t\tthrow new Error(\"Method not implemented.\");\n\t},\n};\n\nclass MockLoadable implements IFluidLoadable {\n\tpublic get IFluidLoadable() {\n\t\treturn this;\n\t}\n\tpublic get handle() {\n\t\treturn new FluidObjectHandle(this, \"\", mockHandleContext);\n\t}\n}\n\nconst ISomeObject: keyof IProvideSomeObject = \"ISomeObject\";\ninterface IProvideSomeObject {\n\treadonly ISomeObject: ISomeObject;\n}\ninterface ISomeObject extends IProvideSomeObject {\n\tvalue: number;\n}\nclass MockSomeObject implements ISomeObject {\n\tpublic get ISomeObject() {\n\t\treturn this;\n\t}\n\tpublic readonly value = 0;\n}\n\ndescribe(\"someObjectlicious\", () => {\n\tdescribe(\"Aqueduct\", () => {\n\t\tdescribe(\"DependencyContainer\", () => {\n\t\t\tit(`One Optional Provider registered via value`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tconst mock = new MockLoadable();\n\t\t\t\tdc.register(IFluidLoadable, mock);\n\n\t\t\t\tconst s = dc.synthesize<IFluidLoadable>({ IFluidLoadable }, undefined);\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Optional IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === mock, \"IFluidLoadable is expected\");\n\t\t\t\tassert(\n\t\t\t\t\tloadable?.handle.absolutePath === mock.handle.absolutePath,\n\t\t\t\t\t\"IFluidLoadable is valid\",\n\t\t\t\t);\n\t\t\t});\n\n\t\t\tit(`One Optional Provider registered via Promise value`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tconst mock = new MockLoadable();\n\t\t\t\tdc.register(IFluidLoadable, Promise.resolve(mock));\n\n\t\t\t\tconst s = dc.synthesize<IFluidLoadable>({ IFluidLoadable }, undefined);\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Optional IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === mock, \"IFluidLoadable is expected\");\n\t\t\t\tassert(\n\t\t\t\t\tloadable?.handle.absolutePath === mock.handle.absolutePath,\n\t\t\t\t\t\"IFluidLoadable is valid\",\n\t\t\t\t);\n\t\t\t});\n\n\t\t\tit(`One Optional Provider registered via factory`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tconst mock = new MockLoadable();\n\t\t\t\tconst factory = () => mock;\n\t\t\t\tdc.register(IFluidLoadable, factory);\n\n\t\t\t\tconst s = dc.synthesize<IFluidLoadable>({ IFluidLoadable }, undefined);\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Optional IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === mock, \"IFluidLoadable is expected\");\n\t\t\t\tassert(\n\t\t\t\t\tloadable?.handle.absolutePath === mock.handle.absolutePath,\n\t\t\t\t\t\"IFluidLoadable is valid\",\n\t\t\t\t);\n\t\t\t});\n\n\t\t\tit(`One Optional Provider registered via Promise factory`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tconst mock = new MockLoadable();\n\t\t\t\tconst factory = async () => mock;\n\t\t\t\tdc.register(IFluidLoadable, factory);\n\n\t\t\t\tconst s = dc.synthesize<IFluidLoadable>({ IFluidLoadable }, undefined);\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Optional IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === mock, \"IFluidLoadable is expected\");\n\t\t\t\tassert(\n\t\t\t\t\tloadable?.handle.absolutePath === mock.handle.absolutePath,\n\t\t\t\t\t\"IFluidLoadable is valid\",\n\t\t\t\t);\n\t\t\t});\n\n\t\t\tit(`One Optional Provider registered via LazyPromise factory`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tconst mock = new MockLoadable();\n\t\t\t\tlet lazyPromiseFlag = false;\n\t\t\t\tconst lazyFactory = new LazyPromise(async () => {\n\t\t\t\t\tlazyPromiseFlag = true;\n\t\t\t\t\treturn mock;\n\t\t\t\t});\n\t\t\t\tdc.register(IFluidLoadable, lazyFactory);\n\n\t\t\t\tconst s = dc.synthesize<IFluidLoadable>({ IFluidLoadable }, undefined);\n\t\t\t\tconst loadable_promise = s.IFluidLoadable;\n\t\t\t\t// This stacking of promises is done in order to make sure that the loadable_promise would have been executed by the time the assertion is done\n\t\t\t\tawait Promise.resolve().then(async () => {\n\t\t\t\t\tassert(!lazyPromiseFlag, \"Optional IFluidLoadable was correctly lazy loaded\");\n\t\t\t\t\tconst loadable = await loadable_promise;\n\t\t\t\t\tassert(loadable, \"Optional IFluidLoadable was registered\");\n\t\t\t\t\tassert(loadable === mock, \"IFluidLoadable is expected\");\n\t\t\t\t\tassert(\n\t\t\t\t\t\tloadable?.handle.absolutePath === mock.handle.absolutePath,\n\t\t\t\t\t\t\"IFluidLoadable is valid\",\n\t\t\t\t\t);\n\t\t\t\t});\n\t\t\t});\n\n\t\t\tit(`One Required Provider registered via value`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tconst mock = new MockLoadable();\n\t\t\t\tdc.register(IFluidLoadable, mock);\n\n\t\t\t\tconst s = dc.synthesize<undefined, IProvideFluidLoadable>(undefined, {\n\t\t\t\t\tIFluidLoadable,\n\t\t\t\t});\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Required IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === mock, \"IFluidLoadable is expected\");\n\t\t\t\tassert(\n\t\t\t\t\tloadable?.handle.absolutePath === mock.handle.absolutePath,\n\t\t\t\t\t\"IFluidLoadable is valid\",\n\t\t\t\t);\n\t\t\t});\n\n\t\t\tit(`One Required Provider registered via Promise value`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tconst mock = new MockLoadable();\n\t\t\t\tdc.register(IFluidLoadable, Promise.resolve(mock));\n\n\t\t\t\tconst s = dc.synthesize<undefined, IProvideFluidLoadable>(undefined, {\n\t\t\t\t\tIFluidLoadable,\n\t\t\t\t});\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Required IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === mock, \"IFluidLoadable is expected\");\n\t\t\t\tassert(\n\t\t\t\t\tloadable?.handle.absolutePath === mock.handle.absolutePath,\n\t\t\t\t\t\"IFluidLoadable is valid\",\n\t\t\t\t);\n\t\t\t});\n\n\t\t\tit(`One Required Provider registered via factory`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tconst mock = new MockLoadable();\n\t\t\t\tconst factory = () => mock;\n\t\t\t\tdc.register(IFluidLoadable, factory);\n\n\t\t\t\tconst s = dc.synthesize<undefined, IProvideFluidLoadable>(undefined, {\n\t\t\t\t\tIFluidLoadable,\n\t\t\t\t});\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Required IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === mock, \"IFluidLoadable is expected\");\n\t\t\t\tassert(\n\t\t\t\t\tloadable?.handle.absolutePath === mock.handle.absolutePath,\n\t\t\t\t\t\"IFluidLoadable is valid\",\n\t\t\t\t);\n\t\t\t});\n\n\t\t\tit(`One Required Provider registered via Promise factory`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tconst mock = new MockLoadable();\n\t\t\t\tconst factory = async () => mock;\n\t\t\t\tdc.register(IFluidLoadable, factory);\n\n\t\t\t\tconst s = dc.synthesize<undefined, IProvideFluidLoadable>(undefined, {\n\t\t\t\t\tIFluidLoadable,\n\t\t\t\t});\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Required IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === mock, \"IFluidLoadable is expected\");\n\t\t\t\tassert(\n\t\t\t\t\tloadable?.handle.absolutePath === mock.handle.absolutePath,\n\t\t\t\t\t\"IFluidLoadable is valid\",\n\t\t\t\t);\n\t\t\t});\n\n\t\t\tit(`One Required Provider registered via LazyPromise factory`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tconst mock = new MockLoadable();\n\t\t\t\tlet lazyPromiseFlag = false;\n\t\t\t\tconst lazyFactory = new LazyPromise(async () => {\n\t\t\t\t\tlazyPromiseFlag = true;\n\t\t\t\t\treturn mock;\n\t\t\t\t});\n\t\t\t\tdc.register(IFluidLoadable, lazyFactory);\n\n\t\t\t\tconst s = dc.synthesize<undefined, IProvideFluidLoadable>(undefined, {\n\t\t\t\t\tIFluidLoadable,\n\t\t\t\t});\n\t\t\t\tconst loadable_promise = s.IFluidLoadable;\n\t\t\t\t// This stacking of promises is done in order to make sure that the loadable_promise would have been executed by the time the assertion is done\n\t\t\t\tawait Promise.resolve().then(async () => {\n\t\t\t\t\tassert(!lazyPromiseFlag, \"Required IFluidLoadable was correctly lazy loaded\");\n\t\t\t\t\tconst loadable = await loadable_promise;\n\t\t\t\t\tassert(loadable, \"Required IFluidLoadable was registered\");\n\t\t\t\t\tassert(loadable === mock, \"IFluidLoadable is expected\");\n\t\t\t\t\tassert(\n\t\t\t\t\t\tloadable?.handle.absolutePath === mock.handle.absolutePath,\n\t\t\t\t\t\t\"IFluidLoadable is valid\",\n\t\t\t\t\t);\n\t\t\t\t});\n\t\t\t});\n\n\t\t\tit(`Two Optional Modules all registered`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable & ISomeObject>>();\n\t\t\t\tconst loadableMock = new MockLoadable();\n\t\t\t\tdc.register(IFluidLoadable, loadableMock);\n\t\t\t\tconst someObjectMock = new MockSomeObject();\n\t\t\t\tdc.register(ISomeObject, someObjectMock);\n\n\t\t\t\tconst s = dc.synthesize<IFluidLoadable & ISomeObject>(\n\t\t\t\t\t{ IFluidLoadable, ISomeObject },\n\t\t\t\t\tundefined,\n\t\t\t\t);\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Optional IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === loadableMock, \"IFluidLoadable is expected\");\n\n\t\t\t\tconst someObject = await s.ISomeObject;\n\t\t\t\tassert(someObject, \"Optional ISomeObject was registered\");\n\t\t\t\tassert(someObject === someObjectMock, \"ISomeObject is expected\");\n\t\t\t});\n\n\t\t\tit(`Two Optional Modules one registered`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable & ISomeObject>>();\n\t\t\t\tconst loadableMock = new MockLoadable();\n\t\t\t\tdc.register(IFluidLoadable, loadableMock);\n\n\t\t\t\tconst s = dc.synthesize<IFluidLoadable & ISomeObject>(\n\t\t\t\t\t{ IFluidLoadable, ISomeObject },\n\t\t\t\t\tundefined,\n\t\t\t\t);\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Optional IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === loadableMock, \"IFluidLoadable is expected\");\n\n\t\t\t\tconst someObject = await s.ISomeObject;\n\t\t\t\tassert(!someObject, \"Optional ISomeObject was not registered\");\n\t\t\t});\n\n\t\t\tit(`Two Optional Modules none registered`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable & ISomeObject>>();\n\n\t\t\t\tconst s = dc.synthesize<IFluidLoadable & ISomeObject>(\n\t\t\t\t\t{ IFluidLoadable, ISomeObject },\n\t\t\t\t\tundefined,\n\t\t\t\t);\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(!loadable, \"Optional IFluidLoadable was not registered\");\n\t\t\t\tconst someObject = await s.ISomeObject;\n\t\t\t\tassert(!someObject, \"Optional ISomeObject was not registered\");\n\t\t\t});\n\n\t\t\tit(`Two Required Modules all registered`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable & ISomeObject>>();\n\t\t\t\tconst loadableMock = new MockLoadable();\n\t\t\t\tdc.register(IFluidLoadable, loadableMock);\n\t\t\t\tconst someObjectMock = new MockSomeObject();\n\t\t\t\tdc.register(ISomeObject, someObjectMock);\n\n\t\t\t\tconst s = dc.synthesize<undefined, IProvideFluidLoadable & IProvideSomeObject>(\n\t\t\t\t\tundefined,\n\t\t\t\t\t{ IFluidLoadable, ISomeObject },\n\t\t\t\t);\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Required IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === loadableMock, \"IFluidLoadable is expected\");\n\n\t\t\t\tconst someObject = await s.ISomeObject;\n\t\t\t\tassert(someObject, \"Required ISomeObject was registered\");\n\t\t\t\tassert(someObject === someObjectMock, \"ISomeObject is expected\");\n\t\t\t});\n\n\t\t\tit(`Required Provider not registered should throw`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\n\t\t\t\tassert.throws(\n\t\t\t\t\t() =>\n\t\t\t\t\t\tdc.synthesize<undefined, IProvideFluidLoadable>(undefined, {\n\t\t\t\t\t\t\tIFluidLoadable,\n\t\t\t\t\t\t}),\n\t\t\t\t\tError,\n\t\t\t\t);\n\t\t\t});\n\n\t\t\tit(`Optional Provider found in Parent`, async () => {\n\t\t\t\tconst parentDc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tconst mock = new MockLoadable();\n\t\t\t\tparentDc.register(IFluidLoadable, mock);\n\t\t\t\tconst dc = new DependencyContainer(parentDc);\n\n\t\t\t\tconst s = dc.synthesize<IFluidLoadable>({ IFluidLoadable }, undefined);\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Optional IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === mock, \"IFluidLoadable is expected\");\n\t\t\t\tassert(\n\t\t\t\t\tloadable?.handle.absolutePath === mock.handle.absolutePath,\n\t\t\t\t\t\"IFluidLoadable is valid\",\n\t\t\t\t);\n\t\t\t});\n\n\t\t\tit(`Optional Modules found in Parent and Child`, async () => {\n\t\t\t\tconst parentDc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tconst loadableMock = new MockLoadable();\n\t\t\t\tparentDc.register(IFluidLoadable, loadableMock);\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<ISomeObject>>(parentDc);\n\t\t\t\tconst someObjectMock = new MockSomeObject();\n\t\t\t\tdc.register(ISomeObject, someObjectMock);\n\n\t\t\t\tconst s = dc.synthesize<IFluidLoadable & ISomeObject>(\n\t\t\t\t\t{ IFluidLoadable, ISomeObject },\n\t\t\t\t\tundefined,\n\t\t\t\t);\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Optional IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === loadableMock, \"IFluidLoadable is expected\");\n\n\t\t\t\tconst someObject = await s.ISomeObject;\n\t\t\t\tassert(someObject, \"Optional ISomeObject was registered\");\n\t\t\t\tassert(someObject === someObjectMock, \"ISomeObject is expected\");\n\t\t\t});\n\n\t\t\tit(`Optional Provider found in Parent and Child resolves Child`, async () => {\n\t\t\t\tconst parentDc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tparentDc.register(IFluidLoadable, new MockLoadable());\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>(parentDc);\n\t\t\t\tconst loadableMock = new MockLoadable();\n\t\t\t\tdc.register(IFluidLoadable, loadableMock);\n\n\t\t\t\tconst s = dc.synthesize<IFluidLoadable>({ IFluidLoadable }, undefined);\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Optional IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === loadableMock, \"IFluidLoadable is expected\");\n\t\t\t});\n\n\t\t\tit(`Required Provider found in Parent`, async () => {\n\t\t\t\tconst parentDc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tconst mock = new MockLoadable();\n\t\t\t\tparentDc.register(IFluidLoadable, mock);\n\t\t\t\tconst dc = new DependencyContainer(parentDc);\n\n\t\t\t\tconst s = dc.synthesize<undefined, IProvideFluidLoadable>(undefined, {\n\t\t\t\t\tIFluidLoadable,\n\t\t\t\t});\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Required IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === mock, \"IFluidLoadable is expected\");\n\t\t\t\tassert(\n\t\t\t\t\tloadable?.handle.absolutePath === mock.handle.absolutePath,\n\t\t\t\t\t\"IFluidLoadable is valid\",\n\t\t\t\t);\n\t\t\t});\n\n\t\t\tit(`Required Modules found in Parent and Child`, async () => {\n\t\t\t\tconst parentDc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tconst loadableMock = new MockLoadable();\n\t\t\t\tparentDc.register(IFluidLoadable, loadableMock);\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<ISomeObject>>(parentDc);\n\t\t\t\tconst someObjectMock = new MockSomeObject();\n\t\t\t\tdc.register(ISomeObject, someObjectMock);\n\n\t\t\t\tconst s = dc.synthesize<undefined, IProvideFluidLoadable & IProvideSomeObject>(\n\t\t\t\t\tundefined,\n\t\t\t\t\t{ IFluidLoadable, ISomeObject },\n\t\t\t\t);\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Required IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === loadableMock, \"IFluidLoadable is expected\");\n\n\t\t\t\tconst someObject = await s.ISomeObject;\n\t\t\t\tassert(someObject, \"Required ISomeObject was registered\");\n\t\t\t\tassert(someObject === someObjectMock, \"ISomeObject is expected\");\n\t\t\t});\n\n\t\t\tit(`Required Provider found in Parent and Child resolves Child`, async () => {\n\t\t\t\tconst parentDc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tparentDc.register(IFluidLoadable, new MockLoadable());\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>(parentDc);\n\t\t\t\tconst loadableMock = new MockLoadable();\n\t\t\t\tdc.register(IFluidLoadable, loadableMock);\n\n\t\t\t\tconst s = dc.synthesize<undefined, IProvideFluidLoadable>(undefined, {\n\t\t\t\t\tIFluidLoadable,\n\t\t\t\t});\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Required IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === loadableMock, \"IFluidLoadable is expected\");\n\t\t\t});\n\n\t\t\tit(`Registering`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tdc.register(IFluidLoadable, new MockLoadable());\n\t\t\t\tassert(dc.has(IFluidLoadable), \"DependencyContainer has IFluidLoadable\");\n\t\t\t});\n\n\t\t\tit(`Registering the same type twice throws`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tdc.register(IFluidLoadable, new MockLoadable());\n\t\t\t\tassert.throws(() => dc.register(IFluidLoadable, new MockLoadable()), Error);\n\t\t\t});\n\n\t\t\tit(`Registering then Unregistering`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tdc.register(IFluidLoadable, new MockLoadable());\n\t\t\t\tdc.unregister(IFluidLoadable);\n\t\t\t\tassert(!dc.has(IFluidLoadable), \"DependencyContainer doesn't have IFluidLoadable\");\n\t\t\t});\n\n\t\t\tit(`Registering then Unregistering then Registering`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tdc.register(IFluidLoadable, new MockLoadable());\n\t\t\t\tdc.unregister(IFluidLoadable);\n\t\t\t\tdc.register(IFluidLoadable, new MockLoadable());\n\t\t\t\tassert(dc.has(IFluidLoadable), \"DependencyContainer has IFluidLoadable\");\n\t\t\t});\n\n\t\t\tit(`has() resolves correctly in all variations`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable & ISomeObject>>();\n\t\t\t\tdc.register(IFluidLoadable, new MockLoadable());\n\t\t\t\tdc.register(ISomeObject, new MockSomeObject());\n\t\t\t\tassert(dc.has(IFluidLoadable), \"Manager has IFluidLoadable\");\n\t\t\t\tassert(dc.has(ISomeObject), \"Manager has ISomeObject\");\n\t\t\t\tassert(\n\t\t\t\t\tdc.has(IFluidLoadable) && dc.has(ISomeObject),\n\t\t\t\t\t\"Manager has IFluidLoadable & ISomeObject\",\n\t\t\t\t);\n\t\t\t});\n\n\t\t\tit(`Child has Parent modules`, async () => {\n\t\t\t\tconst parentDc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tconst loadableMock = new MockLoadable();\n\t\t\t\tparentDc.register(IFluidLoadable, loadableMock);\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<ISomeObject>>(parentDc);\n\t\t\t\tconst someObjectMock = new MockSomeObject();\n\t\t\t\tdc.register(ISomeObject, someObjectMock);\n\n\t\t\t\tassert(dc.has(IFluidLoadable), \"has includes parent registered\");\n\t\t\t\tassert(\n\t\t\t\t\t!dc.has(IFluidLoadable, true),\n\t\t\t\t\t\"has does not include excluded parent registered\",\n\t\t\t\t);\n\t\t\t\tassert(dc.has(ISomeObject), \"has includes registered\");\n\t\t\t\tassert(!dc.has(IFluidHandle), \"does not include not registered\");\n\t\t\t});\n\n\t\t\tit(`Parent Resolved from Child`, async () => {\n\t\t\t\tconst parentDc = new DependencyContainer<FluidObject<IFluidHandle>>();\n\t\t\t\tconst loadableToHandle: FluidObjectProvider<IProvideFluidHandle> = async (\n\t\t\t\t\tfds: IFluidDependencySynthesizer,\n\t\t\t\t) => {\n\t\t\t\t\tconst loadable = fds.synthesize<undefined, IProvideFluidLoadable>(undefined, {\n\t\t\t\t\t\tIFluidLoadable,\n\t\t\t\t\t});\n\t\t\t\t\treturn (await loadable.IFluidLoadable).handle;\n\t\t\t\t};\n\t\t\t\tparentDc.register(IFluidHandle, loadableToHandle);\n\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>(parentDc);\n\t\t\t\tconst loadableMock = new MockLoadable();\n\t\t\t\tdc.register(IFluidLoadable, loadableMock);\n\n\t\t\t\tconst deps = dc.synthesize<IFluidHandle>({ IFluidHandle }, undefined);\n\t\t\t\tassert((await deps.IFluidHandle) !== undefined, \"handle undefined\");\n\t\t\t});\n\n\t\t\tit(`Undefined Provider is not Undefined`, async () => {\n\t\t\t\tconst dc = new DependencyContainer();\n\t\t\t\tconst deps = dc.synthesize<IFluidLoadable>({ IFluidLoadable }, {});\n\t\t\t\tassert(deps.IFluidLoadable !== undefined, \"handle undefined\");\n\t\t\t\tassert((await deps.IFluidLoadable) === undefined, \"handle undefined\");\n\t\t\t});\n\n\t\t\tit(`test getProvider backcompat`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tconst loadableMock = new MockLoadable();\n\t\t\t\tdc.register(IFluidLoadable, loadableMock);\n\t\t\t\tconst testGetProvider = (deps: IFluidDependencySynthesizer, scenario: string) => {\n\t\t\t\t\tconst old = deps as any as {\n\t\t\t\t\t\tgetProvider(\n\t\t\t\t\t\t\tkey: \"IFluidLoadable\",\n\t\t\t\t\t\t): FluidObjectProvider<FluidObject<IFluidLoadable>>;\n\t\t\t\t\t};\n\t\t\t\t\tconst provider = old.getProvider(\"IFluidLoadable\");\n\t\t\t\t\tassert.equal(provider, loadableMock, scenario);\n\t\t\t\t};\n\t\t\t\ttestGetProvider(dc, \"direct\");\n\t\t\t\ttestGetProvider(new DependencyContainer(dc), \"parent\");\n\t\t\t\ttestGetProvider(new PassThru<FluidObject<IFluidLoadable>>(dc), \"pass thru\");\n\t\t\t\ttestGetProvider(\n\t\t\t\t\tnew DependencyContainer(new PassThru<FluidObject<IFluidLoadable>>(dc)),\n\t\t\t\t\t\"pass thru as child\",\n\t\t\t\t);\n\t\t\t});\n\t\t});\n\t});\n});\n\nclass PassThru<TMap> implements IFluidDependencySynthesizer {\n\tconstructor(private readonly parent: IFluidDependencySynthesizer) {}\n\tsynthesize<O, R = Record<string, never> | undefined>(\n\t\toptionalTypes: FluidObjectSymbolProvider<O>,\n\t\trequiredTypes: Required<FluidObjectSymbolProvider<R>>,\n\t): AsyncFluidObjectProvider<O, R> {\n\t\treturn this.parent.synthesize(optionalTypes, requiredTypes);\n\t}\n\thas(type: string): boolean {\n\t\treturn this.parent.has(type);\n\t}\n\treadonly IFluidDependencySynthesizer = this;\n\n\tgetProvider<K extends keyof TMap>(key: K): FluidObjectProvider<TMap[K]> | undefined {\n\t\tconst maybe = this.parent as any as Partial<this>;\n\t\tif (maybe.getProvider) {\n\t\t\treturn maybe.getProvider(key);\n\t\t}\n\t}\n}\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"program":{"fileNames":["../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es5.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2015.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2016.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2017.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2018.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2019.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2020.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.dom.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.dom.iterable.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2015.core.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2015.collection.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2015.generator.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2015.iterable.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2015.promise.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2015.proxy.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2015.reflect.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2015.symbol.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2016.array.include.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2017.object.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2017.string.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2017.intl.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2017.typedarrays.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2018.asynciterable.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2018.intl.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2018.promise.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2018.regexp.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2019.array.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2019.object.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2019.string.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2019.symbol.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2019.intl.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2020.bigint.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2020.date.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2020.promise.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2020.sharedmemory.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2020.string.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2020.symbol.wellknown.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2020.intl.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.es2020.number.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.esnext.intl.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.decorators.d.ts","../../../../../node_modules/.pnpm/typescript@5.1.6/node_modules/typescript/lib/lib.decorators.legacy.d.ts","../../../../common/core-interfaces/dist/disposable.d.ts","../../../../common/core-interfaces/dist/error.d.ts","../../../../common/core-interfaces/dist/events.d.ts","../../../../common/core-interfaces/dist/fluidRouter.d.ts","../../../../common/core-interfaces/dist/provider.d.ts","../../../../common/core-interfaces/dist/handles.d.ts","../../../../common/core-interfaces/dist/fluidLoadable.d.ts","../../../../common/core-interfaces/dist/fluidPackage.d.ts","../../../../common/core-interfaces/dist/logger.d.ts","../../../../common/core-interfaces/dist/config.d.ts","../../../../common/core-interfaces/dist/index.d.ts","../../../../runtime/datastore/dist/fluidHandle.d.ts","../../../../common/client-utils/dist/bufferNode.d.ts","../../../../common/client-utils/dist/hashFileNode.d.ts","../../../../common/client-utils/dist/performanceIsomorphic.d.ts","../../../../common/client-utils/dist/base64Encoding.d.ts","../../../../common/client-utils/dist/bufferShared.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/assert.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/assert/strict.d.ts","../../../../../node_modules/.pnpm/@types+events@3.0.3/node_modules/@types/events/index.d.ts","../../../../../node_modules/.pnpm/buffer@6.0.3/node_modules/buffer/index.d.ts","../../../../../node_modules/.pnpm/undici-types@5.26.5/node_modules/undici-types/header.d.ts","../../../../../node_modules/.pnpm/undici-types@5.26.5/node_modules/undici-types/readable.d.ts","../../../../../node_modules/.pnpm/undici-types@5.26.5/node_modules/undici-types/file.d.ts","../../../../../node_modules/.pnpm/undici-types@5.26.5/node_modules/undici-types/fetch.d.ts","../../../../../node_modules/.pnpm/undici-types@5.26.5/node_modules/undici-types/formdata.d.ts","../../../../../node_modules/.pnpm/undici-types@5.26.5/node_modules/undici-types/connector.d.ts","../../../../../node_modules/.pnpm/undici-types@5.26.5/node_modules/undici-types/client.d.ts","../../../../../node_modules/.pnpm/undici-types@5.26.5/node_modules/undici-types/errors.d.ts","../../../../../node_modules/.pnpm/undici-types@5.26.5/node_modules/undici-types/dispatcher.d.ts","../../../../../node_modules/.pnpm/undici-types@5.26.5/node_modules/undici-types/global-dispatcher.d.ts","../../../../../node_modules/.pnpm/undici-types@5.26.5/node_modules/undici-types/global-origin.d.ts","../../../../../node_modules/.pnpm/undici-types@5.26.5/node_modules/undici-types/pool-stats.d.ts","../../../../../node_modules/.pnpm/undici-types@5.26.5/node_modules/undici-types/pool.d.ts","../../../../../node_modules/.pnpm/undici-types@5.26.5/node_modules/undici-types/handlers.d.ts","../../../../../node_modules/.pnpm/undici-types@5.26.5/node_modules/undici-types/balanced-pool.d.ts","../../../../../node_modules/.pnpm/undici-types@5.26.5/node_modules/undici-types/agent.d.ts","../../../../../node_modules/.pnpm/undici-types@5.26.5/node_modules/undici-types/mock-interceptor.d.ts","../../../../../node_modules/.pnpm/undici-types@5.26.5/node_modules/undici-types/mock-agent.d.ts","../../../../../node_modules/.pnpm/undici-types@5.26.5/node_modules/undici-types/mock-client.d.ts","../../../../../node_modules/.pnpm/undici-types@5.26.5/node_modules/undici-types/mock-pool.d.ts","../../../../../node_modules/.pnpm/undici-types@5.26.5/node_modules/undici-types/mock-errors.d.ts","../../../../../node_modules/.pnpm/undici-types@5.26.5/node_modules/undici-types/proxy-agent.d.ts","../../../../../node_modules/.pnpm/undici-types@5.26.5/node_modules/undici-types/api.d.ts","../../../../../node_modules/.pnpm/undici-types@5.26.5/node_modules/undici-types/cookies.d.ts","../../../../../node_modules/.pnpm/undici-types@5.26.5/node_modules/undici-types/patch.d.ts","../../../../../node_modules/.pnpm/undici-types@5.26.5/node_modules/undici-types/filereader.d.ts","../../../../../node_modules/.pnpm/undici-types@5.26.5/node_modules/undici-types/diagnostics-channel.d.ts","../../../../../node_modules/.pnpm/undici-types@5.26.5/node_modules/undici-types/websocket.d.ts","../../../../../node_modules/.pnpm/undici-types@5.26.5/node_modules/undici-types/content-type.d.ts","../../../../../node_modules/.pnpm/undici-types@5.26.5/node_modules/undici-types/cache.d.ts","../../../../../node_modules/.pnpm/undici-types@5.26.5/node_modules/undici-types/interceptors.d.ts","../../../../../node_modules/.pnpm/undici-types@5.26.5/node_modules/undici-types/index.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/globals.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/async_hooks.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/buffer.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/child_process.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/cluster.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/console.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/constants.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/crypto.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/dgram.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/diagnostics_channel.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/dns.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/dns/promises.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/domain.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/dom-events.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/events.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/fs.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/fs/promises.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/http.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/http2.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/https.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/inspector.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/module.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/net.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/os.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/path.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/perf_hooks.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/process.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/punycode.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/querystring.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/readline.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/readline/promises.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/repl.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/stream.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/stream/promises.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/stream/consumers.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/stream/web.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/string_decoder.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/test.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/timers.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/timers/promises.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/tls.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/trace_events.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/tty.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/url.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/util.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/v8.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/vm.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/wasi.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/worker_threads.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/zlib.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/globals.global.d.ts","../../../../../node_modules/.pnpm/@types+node@18.19.1/node_modules/@types/node/index.d.ts","../../../../common/client-utils/dist/typedEventEmitter.d.ts","../../../../common/client-utils/dist/eventForwarder.d.ts","../../../../common/client-utils/dist/trace.d.ts","../../../../common/client-utils/dist/indexNode.d.ts","../../../../common/core-utils/dist/assert.d.ts","../../../../common/core-utils/dist/compare.d.ts","../../../../common/core-utils/dist/delay.d.ts","../../../../common/core-utils/dist/heap.d.ts","../../../../common/core-utils/dist/lazy.d.ts","../../../../common/core-utils/dist/promiseCache.d.ts","../../../../common/core-utils/dist/promises.d.ts","../../../../common/core-utils/dist/timer.d.ts","../../../../common/core-utils/dist/unreachable.d.ts","../../../../common/core-utils/dist/index.d.ts","../../../../utils/telemetry-utils/dist/telemetryTypes.d.ts","../../../../utils/telemetry-utils/dist/logger.d.ts","../../../../utils/telemetry-utils/dist/config.d.ts","../../../../../node_modules/.pnpm/@fluidframework+protocol-definitions@3.1.0/node_modules/@fluidframework/protocol-definitions/dist/users.d.ts","../../../../../node_modules/.pnpm/@fluidframework+protocol-definitions@3.1.0/node_modules/@fluidframework/protocol-definitions/dist/clients.d.ts","../../../../../node_modules/.pnpm/@fluidframework+protocol-definitions@3.1.0/node_modules/@fluidframework/protocol-definitions/dist/config.d.ts","../../../../../node_modules/.pnpm/@fluidframework+protocol-definitions@3.1.0/node_modules/@fluidframework/protocol-definitions/dist/consensus.d.ts","../../../../../node_modules/.pnpm/@fluidframework+protocol-definitions@3.1.0/node_modules/@fluidframework/protocol-definitions/dist/date.d.ts","../../../../../node_modules/.pnpm/@fluidframework+protocol-definitions@3.1.0/node_modules/@fluidframework/protocol-definitions/dist/protocol.d.ts","../../../../../node_modules/.pnpm/@fluidframework+protocol-definitions@3.1.0/node_modules/@fluidframework/protocol-definitions/dist/scopes.d.ts","../../../../../node_modules/.pnpm/@fluidframework+protocol-definitions@3.1.0/node_modules/@fluidframework/protocol-definitions/dist/tokens.d.ts","../../../../../node_modules/.pnpm/@fluidframework+protocol-definitions@3.1.0/node_modules/@fluidframework/protocol-definitions/dist/sockets.d.ts","../../../../../node_modules/.pnpm/@fluidframework+protocol-definitions@3.1.0/node_modules/@fluidframework/protocol-definitions/dist/storage.d.ts","../../../../../node_modules/.pnpm/@fluidframework+protocol-definitions@3.1.0/node_modules/@fluidframework/protocol-definitions/dist/summary.d.ts","../../../../../node_modules/.pnpm/@fluidframework+protocol-definitions@3.1.0/node_modules/@fluidframework/protocol-definitions/dist/index.d.ts","../../../../utils/telemetry-utils/dist/fluidErrorBase.d.ts","../../../../utils/telemetry-utils/dist/errorLogging.d.ts","../../../../utils/telemetry-utils/dist/error.d.ts","../../../../utils/telemetry-utils/dist/eventEmitterWithErrorHandling.d.ts","../../../../utils/telemetry-utils/dist/events.d.ts","../../../../utils/telemetry-utils/dist/mockLogger.d.ts","../../../../utils/telemetry-utils/dist/thresholdCounter.d.ts","../../../../utils/telemetry-utils/dist/sampledTelemetryHelper.d.ts","../../../../utils/telemetry-utils/dist/utils.d.ts","../../../../utils/telemetry-utils/dist/index.d.ts","../../../../common/container-definitions/dist/audience.d.ts","../../../../common/container-definitions/dist/fluidPackage.d.ts","../../../../common/container-definitions/dist/browserPackage.d.ts","../../../../common/driver-definitions/dist/urlResolver.d.ts","../../../../common/driver-definitions/dist/driverError.d.ts","../../../../common/driver-definitions/dist/storage.d.ts","../../../../common/driver-definitions/dist/index.d.ts","../../../../common/container-definitions/dist/deltas.d.ts","../../../../common/container-definitions/dist/error.d.ts","../../../../common/container-definitions/dist/runtime.d.ts","../../../../common/container-definitions/dist/fluidModule.d.ts","../../../../common/container-definitions/dist/loader.d.ts","../../../../common/container-definitions/dist/index.d.ts","../../../../runtime/runtime-definitions/dist/attribution.d.ts","../../../../runtime/id-compressor/dist/types/identifiers.d.ts","../../../../runtime/id-compressor/dist/types/persisted-types/0.0.1.d.ts","../../../../runtime/id-compressor/dist/types/persisted-types/index.d.ts","../../../../runtime/id-compressor/dist/types/idCompressor.d.ts","../../../../runtime/id-compressor/dist/types/index.d.ts","../../../../runtime/id-compressor/dist/idCompressor.d.ts","../../../../runtime/id-compressor/dist/identifiers.d.ts","../../../../runtime/id-compressor/dist/utilities.d.ts","../../../../runtime/id-compressor/dist/index.d.ts","../../../../runtime/runtime-definitions/dist/dataStoreFactory.d.ts","../../../../runtime/runtime-definitions/dist/dataStoreRegistry.d.ts","../../../../runtime/runtime-definitions/dist/garbageCollection.d.ts","../../../../runtime/runtime-definitions/dist/protocol.d.ts","../../../../runtime/runtime-definitions/dist/summary.d.ts","../../../../runtime/runtime-definitions/dist/dataStoreContext.d.ts","../../../../runtime/runtime-definitions/dist/index.d.ts","../../../../runtime/datastore-definitions/dist/storage.d.ts","../../../../runtime/datastore-definitions/dist/dataStoreRuntime.d.ts","../../../../runtime/datastore-definitions/dist/channel.d.ts","../../../../runtime/datastore-definitions/dist/jsonable.d.ts","../../../../runtime/datastore-definitions/dist/serializable.d.ts","../../../../runtime/datastore-definitions/dist/index.d.ts","../../../../runtime/datastore/dist/dataStoreRuntime.d.ts","../../../../runtime/datastore/dist/index.d.ts","../IFluidDependencySynthesizer.d.ts","../types.d.ts","../dependencyContainer.d.ts","../index.d.ts","../../src/test/dependencyContainer.spec.ts","../../../../../node_modules/.pnpm/@fluidframework+synthesize@2.0.0-internal.8.0.0/node_modules/@fluidframework/synthesize/dist/types.d.ts","../../../../../node_modules/.pnpm/@fluidframework+synthesize@2.0.0-internal.8.0.0/node_modules/@fluidframework/synthesize/dist/IFluidDependencySynthesizer.d.ts","../../../../../node_modules/.pnpm/@fluidframework+synthesize@2.0.0-internal.8.0.0/node_modules/@fluidframework/synthesize/dist/dependencyContainer.d.ts","../../../../../node_modules/.pnpm/@fluidframework+synthesize@2.0.0-internal.8.0.0/node_modules/@fluidframework/synthesize/dist/index.d.ts","../../src/test/types/validateSynthesizePrevious.generated.ts","../../../../../node_modules/.pnpm/@types+mocha@9.1.1/node_modules/@types/mocha/index.d.ts"],"fileInfos":[{"version":"f59215c5f1d886b05395ee7aca73e0ac69ddfad2843aa88530e797879d511bad","affectsGlobalScope":true,"impliedFormat":1},{"version":"45b7ab580deca34ae9729e97c13cfd999df04416a79116c3bfb483804f85ded4","impliedFormat":1},{"version":"dc48272d7c333ccf58034c0026162576b7d50ea0e69c3b9292f803fc20720fd5","impliedFormat":1},{"version":"27147504487dc1159369da4f4da8a26406364624fa9bc3db632f7d94a5bae2c3","impliedFormat":1},{"version":"5e1c4c362065a6b95ff952c0eab010f04dcd2c3494e813b493ecfd4fcb9fc0d8","impliedFormat":1},{"version":"68d73b4a11549f9c0b7d352d10e91e5dca8faa3322bfb77b661839c42b1ddec7","impliedFormat":1},{"version":"5efce4fc3c29ea84e8928f97adec086e3dc876365e0982cc8479a07954a3efd4","impliedFormat":1},{"version":"3dda5344576193a4ae48b8d03f105c86f20b2f2aff0a1d1fd7935f5d68649654","affectsGlobalScope":true,"impliedFormat":1},{"version":"35299ae4a62086698444a5aaee27fc7aa377c68cbb90b441c9ace246ffd05c97","affectsGlobalScope":true,"impliedFormat":1},{"version":"9d9885c728913c1d16e0d2831b40341d6ad9a0ceecaabc55209b306ad9c736a5","affectsGlobalScope":true,"impliedFormat":1},{"version":"17bea081b9c0541f39dd1ae9bc8c78bdd561879a682e60e2f25f688c0ecab248","affectsGlobalScope":true,"impliedFormat":1},{"version":"4443e68b35f3332f753eacc66a04ac1d2053b8b035a0e0ac1d455392b5e243b3","affectsGlobalScope":true,"impliedFormat":1},{"version":"ab22100fdd0d24cfc2cc59d0a00fc8cf449830d9c4030dc54390a46bd562e929","affectsGlobalScope":true,"impliedFormat":1},{"version":"f7bd636ae3a4623c503359ada74510c4005df5b36de7f23e1db8a5c543fd176b","affectsGlobalScope":true,"impliedFormat":1},{"version":"ce691fb9e5c64efb9547083e4a34091bcbe5bdb41027e310ebba8f7d96a98671","affectsGlobalScope":true,"impliedFormat":1},{"version":"8d697a2a929a5fcb38b7a65594020fcef05ec1630804a33748829c5ff53640d0","affectsGlobalScope":true,"impliedFormat":1},{"version":"0c20f4d2358eb679e4ae8a4432bdd96c857a2960fd6800b21ec4008ec59d60ea","affectsGlobalScope":true,"impliedFormat":1},{"version":"36ae84ccc0633f7c0787bc6108386c8b773e95d3b052d9464a99cd9b8795fbec","affectsGlobalScope":true,"impliedFormat":1},{"version":"82d0d8e269b9eeac02c3bd1c9e884e85d483fcb2cd168bccd6bc54df663da031","affectsGlobalScope":true,"impliedFormat":1},{"version":"b8deab98702588840be73d67f02412a2d45a417a3c097b2e96f7f3a42ac483d1","affectsGlobalScope":true,"impliedFormat":1},{"version":"4738f2420687fd85629c9efb470793bb753709c2379e5f85bc1815d875ceadcd","affectsGlobalScope":true,"impliedFormat":1},{"version":"2f11ff796926e0832f9ae148008138ad583bd181899ab7dd768a2666700b1893","affectsGlobalScope":true,"impliedFormat":1},{"version":"376d554d042fb409cb55b5cbaf0b2b4b7e669619493c5d18d5fa8bd67273f82a","affectsGlobalScope":true,"impliedFormat":1},{"version":"9fc46429fbe091ac5ad2608c657201eb68b6f1b8341bd6d670047d32ed0a88fa","affectsGlobalScope":true,"impliedFormat":1},{"version":"61c37c1de663cf4171e1192466e52c7a382afa58da01b1dc75058f032ddf0839","affectsGlobalScope":true,"impliedFormat":1},{"version":"c4138a3dd7cd6cf1f363ca0f905554e8d81b45844feea17786cdf1626cb8ea06","affectsGlobalScope":true,"impliedFormat":1},{"version":"6ff3e2452b055d8f0ec026511c6582b55d935675af67cdb67dd1dc671e8065df","affectsGlobalScope":true,"impliedFormat":1},{"version":"03de17b810f426a2f47396b0b99b53a82c1b60e9cba7a7edda47f9bb077882f4","affectsGlobalScope":true,"impliedFormat":1},{"version":"8184c6ddf48f0c98429326b428478ecc6143c27f79b79e85740f17e6feb090f1","affectsGlobalScope":true,"impliedFormat":1},{"version":"261c4d2cf86ac5a89ad3fb3fafed74cbb6f2f7c1d139b0540933df567d64a6ca","affectsGlobalScope":true,"impliedFormat":1},{"version":"6af1425e9973f4924fca986636ac19a0cf9909a7e0d9d3009c349e6244e957b6","affectsGlobalScope":true,"impliedFormat":1},{"version":"576711e016cf4f1804676043e6a0a5414252560eb57de9faceee34d79798c850","affectsGlobalScope":true,"impliedFormat":1},{"version":"89c1b1281ba7b8a96efc676b11b264de7a8374c5ea1e6617f11880a13fc56dc6","affectsGlobalScope":true,"impliedFormat":1},{"version":"15a630d6817718a2ddd7088c4f83e4673fde19fa992d2eae2cf51132a302a5d3","affectsGlobalScope":true,"impliedFormat":1},{"version":"f06948deb2a51aae25184561c9640fb66afeddb34531a9212d011792b1d19e0a","affectsGlobalScope":true,"impliedFormat":1},{"version":"01e0ee7e1f661acedb08b51f8a9b7d7f959e9cdb6441360f06522cc3aea1bf2e","affectsGlobalScope":true,"impliedFormat":1},{"version":"ac17a97f816d53d9dd79b0d235e1c0ed54a8cc6a0677e9a3d61efb480b2a3e4e","affectsGlobalScope":true,"impliedFormat":1},{"version":"bf14a426dbbf1022d11bd08d6b8e709a2e9d246f0c6c1032f3b2edb9a902adbe","affectsGlobalScope":true,"impliedFormat":1},{"version":"ec0104fee478075cb5171e5f4e3f23add8e02d845ae0165bfa3f1099241fa2aa","affectsGlobalScope":true,"impliedFormat":1},{"version":"2b72d528b2e2fe3c57889ca7baef5e13a56c957b946906d03767c642f386bbc3","affectsGlobalScope":true,"impliedFormat":1},{"version":"9cc66b0513ad41cb5f5372cca86ef83a0d37d1c1017580b7dace3ea5661836df","affectsGlobalScope":true,"impliedFormat":1},{"version":"368af93f74c9c932edd84c58883e736c9e3d53cec1fe24c0b0ff451f529ceab1","affectsGlobalScope":true,"impliedFormat":1},{"version":"307c8b7ebbd7f23a92b73a4c6c0a697beca05b06b036c23a34553e5fe65e4fdc","affectsGlobalScope":true,"impliedFormat":1},{"version":"189c0703923150aa30673fa3de411346d727cc44a11c75d05d7cf9ef095daa22","affectsGlobalScope":true,"impliedFormat":1},{"version":"782dec38049b92d4e85c1585fbea5474a219c6984a35b004963b00beb1aab538","affectsGlobalScope":true,"impliedFormat":1},{"version":"2ea167b8505527403109dcdf0ce258986ddd684961f7eb5cd36e25f7ba339730","impliedFormat":1},{"version":"323e38eb371a86821896fb50ed926b0d59761d5a2e407a1b9ed62bba11a9872d","impliedFormat":1},{"version":"252ca73a7c260e4abb14585480df2308df333f0774c7203b364af4e10a4876f8","impliedFormat":1},{"version":"d1d878a1661002034e2dc6a7d40baa2e3d1aec74643c341f7469d604cc245192","impliedFormat":1},{"version":"a64edb16eacf69e9473e5b829d850ac4b526daf673e92a84628c8c492fe06d68","impliedFormat":1},{"version":"3c7959a597ebc1d6aecceae9f9625715fd1cb3eff0032cae7b49d6625c7dde1b","impliedFormat":1},{"version":"b83ea41a48ae78ade8ced9fa3fcbd5ffccf10ec7d417f3de1c73904403c43ade","impliedFormat":1},{"version":"c8c5ba100c8578755579f8fd6bc9c8f7753376a43d23f656a77d3c34cb6af92a","impliedFormat":1},{"version":"3c87e4cf3612aa6e87dc0b3dc7603827c216a212a7af332813dc6eee19024bff","impliedFormat":1},{"version":"06c8622d8f31b530058177e1ba6e97e3896c369be4b5f0d19e870512787e9e78","impliedFormat":1},{"version":"b68100223bfef208123ea4569c6c20eb6e11c07e3f88799f03f559fa5f4f4922","impliedFormat":1},{"version":"fe814156c1e14982e763f83c261b430d7fbfb480f01841f4c48c6bd9499a0094","impliedFormat":1},{"version":"4812ad98953705fa59c7c5b7c4ad46672531497e5c236f1bd625c479114dda00","impliedFormat":1},{"version":"9dcebbc6c3ba0e08658aa8ac54a9d605e252185b7c227a1cec09a52cdb736e1d","impliedFormat":1},{"version":"858f82bb3501bc4e3ec08c4d9f8035768a62549d4de42804600e9eb63a475e36","impliedFormat":1},{"version":"b6e4b2df38794096aba6944a0941accf45da9b97d2da719dd8a95d883b0fc7b1","impliedFormat":1},{"version":"023683fdc80a7f5c8dc1426427f328373aa309bf28be20bb7ff9b5fe1a3010c3","impliedFormat":1},{"version":"3846d0dcf468a1d1a07e6d00eaa37ec542956fb5fe0357590a6407af20d2ff90","impliedFormat":1},{"version":"7394959e5a741b185456e1ef5d64599c36c60a323207450991e7a42e08911419","impliedFormat":1},{"version":"93d28b4eb12c68fccc1f2fc04a4ef83ea3b2a03b18055d3bf29cab267aa7042e","impliedFormat":1},{"version":"4967529644e391115ca5592184d4b63980569adf60ee685f968fd59ab1557188","impliedFormat":1},{"version":"5929864ce17fba74232584d90cb721a89b7ad277220627cc97054ba15a98ea8f","impliedFormat":1},{"version":"7180c03fd3cb6e22f911ce9ba0f8a7008b1a6ddbe88ccf16a9c8140ef9ac1686","impliedFormat":1},{"version":"25c8056edf4314820382a5fdb4bb7816999acdcb929c8f75e3f39473b87e85bc","impliedFormat":1},{"version":"54cb85a47d760da1c13c00add10d26b5118280d44d58e6908d8e89abbd9d7725","impliedFormat":1},{"version":"3e4825171442666d31c845aeb47fcd34b62e14041bb353ae2b874285d78482aa","impliedFormat":1},{"version":"c6fd2c5a395f2432786c9cb8deb870b9b0e8ff7e22c029954fabdd692bff6195","impliedFormat":1},{"version":"a967bfe3ad4e62243eb604bf956101e4c740f5921277c60debaf325c1320bf88","impliedFormat":1},{"version":"e9775e97ac4877aebf963a0289c81abe76d1ec9a2a7778dbe637e5151f25c5f3","impliedFormat":1},{"version":"471e1da5a78350bc55ef8cef24eb3aca6174143c281b8b214ca2beda51f5e04a","impliedFormat":1},{"version":"cadc8aced301244057c4e7e73fbcae534b0f5b12a37b150d80e5a45aa4bebcbd","impliedFormat":1},{"version":"385aab901643aa54e1c36f5ef3107913b10d1b5bb8cbcd933d4263b80a0d7f20","impliedFormat":1},{"version":"9670d44354bab9d9982eca21945686b5c24a3f893db73c0dae0fd74217a4c219","impliedFormat":1},{"version":"db3435f3525cd785bf21ec6769bf8da7e8a776be1a99e2e7efb5f244a2ef5fee","impliedFormat":1},{"version":"c3b170c45fc031db31f782e612adf7314b167e60439d304b49e704010e7bafe5","impliedFormat":1},{"version":"40383ebef22b943d503c6ce2cb2e060282936b952a01bea5f9f493d5fb487cc7","impliedFormat":1},{"version":"4893a895ea92c85345017a04ed427cbd6a1710453338df26881a6019432febdd","impliedFormat":1},{"version":"3a84b7cb891141824bd00ef8a50b6a44596aded4075da937f180c90e362fe5f6","impliedFormat":1},{"version":"13f6f39e12b1518c6650bbb220c8985999020fe0f21d818e28f512b7771d00f9","impliedFormat":1},{"version":"9b5369969f6e7175740bf51223112ff209f94ba43ecd3bb09eefff9fd675624a","impliedFormat":1},{"version":"4fe9e626e7164748e8769bbf74b538e09607f07ed17c2f20af8d680ee49fc1da","impliedFormat":1},{"version":"24515859bc0b836719105bb6cc3d68255042a9f02a6022b3187948b204946bd2","impliedFormat":1},{"version":"33203609eba548914dc83ddf6cadbc0bcb6e8ef89f6d648ca0908ae887f9fcc5","impliedFormat":1},{"version":"0db18c6e78ea846316c012478888f33c11ffadab9efd1cc8bcc12daded7a60b6","impliedFormat":1},{"version":"89167d696a849fce5ca508032aabfe901c0868f833a8625d5a9c6e861ef935d2","impliedFormat":1},{"version":"e53a3c2a9f624d90f24bf4588aacd223e7bec1b9d0d479b68d2f4a9e6011147f","impliedFormat":1},{"version":"339dc5265ee5ed92e536a93a04c4ebbc2128f45eeec6ed29f379e0085283542c","impliedFormat":1},{"version":"9f0a92164925aa37d4a5d9dd3e0134cff8177208dba55fd2310cd74beea40ee2","impliedFormat":1},{"version":"8bfdb79bf1a9d435ec48d9372dc93291161f152c0865b81fc0b2694aedb4578d","impliedFormat":1},{"version":"2e85db9e6fd73cfa3d7f28e0ab6b55417ea18931423bd47b409a96e4a169e8e6","impliedFormat":1},{"version":"c46e079fe54c76f95c67fb89081b3e399da2c7d109e7dca8e4b58d83e332e605","impliedFormat":1},{"version":"d32275be3546f252e3ad33976caf8c5e842c09cb87d468cb40d5f4cf092d1acc","impliedFormat":1},{"version":"4a0c3504813a3289f7fb1115db13967c8e004aa8e4f8a9021b95285502221bd1","impliedFormat":1},{"version":"49026435d21e3d7559d723af3ae48f73ec28f9cba651b41bd2ac991012836122","affectsGlobalScope":true,"impliedFormat":1},{"version":"39b1a50d543770780b0409a4caacb87f3ff1d510aedfeb7dc06ed44188256f89","impliedFormat":1},{"version":"b6a4a51bc749ad882c33d98563ff5a94716ca884bfde949a8c97bad530e4ee2c","affectsGlobalScope":true,"impliedFormat":1},{"version":"16b872cf5432818bdbf405428b4a1d77bb2a7ab908e8bd6609f9a541cea92f81","impliedFormat":1},{"version":"fe39ceafa361b6d339b518936275eff89a77e7dfe92f2efa5fb97abf9a95ca49","impliedFormat":1},{"version":"4009dd21843fe4a62d1d97b584a2937ca9f045df6fbd65c8b264d8dd04b656fd","affectsGlobalScope":true,"impliedFormat":1},{"version":"a40826e8476694e90da94aa008283a7de50d1dafd37beada623863f1901cb7fb","impliedFormat":1},{"version":"c9e6ea53a25729dbb5b5bb6960db4387df2f8e88add9cbf36b6ff590481134f9","impliedFormat":1},{"version":"3e95e6310d49db6d575ac6c2896c02761426aa5aab0b18169f971151c709b770","impliedFormat":1},{"version":"7eb0662b995994db248290a0f0a1d8ed685991a162ff9eb4dee36f099cccd0d9","impliedFormat":1},{"version":"bea5c9fc0843a6961411ab4a04df856a8372448bc0d180da0c3a054ff31044b8","impliedFormat":1},{"version":"715873cecbfcebb49f293f0521bd0955d6298486e2eeb9c7bbf5e9f20a6ed152","impliedFormat":1},{"version":"c6cf9428f45f3d78b07df7d7aab1569994c177d36549e3a962f952d89f026bc4","impliedFormat":1},{"version":"2c71199d1fc83bf17636ad5bf63a945633406b7b94887612bba4ef027c662b3e","affectsGlobalScope":true,"impliedFormat":1},{"version":"6c7b9d2139abd8f2e83ed8fa018c3799ab3187755a6665621feb6e93d3429ac3","affectsGlobalScope":true,"impliedFormat":1},{"version":"a019c9782ea4e21c83881c780cebce8ad86e3f78122619336eacbd87e47fe674","impliedFormat":1},{"version":"021ca24be8eb8c46f99b4e03ebf872931f590c9b07b88d715c68bd30495b6c44","impliedFormat":1},{"version":"5899ab1898582115c432cccef063298f75477bf2cebe5473360043fddd67bcc6","impliedFormat":1},{"version":"6b97f4106d72ae6b4ebf4e46d2fe90f4d04dd04b3dbff6e294572440a428209d","impliedFormat":1},{"version":"e3baa0c5780c2c805ec33a999722a2f740b572eb3746fd0a5f93a0a5c3dbf7f6","impliedFormat":1},{"version":"48fedd2f8549a2ae7e62f30fdb015779c2a7b536760730c5269406cd3d17cab2","impliedFormat":1},{"version":"089867511b37a534ae71f3d9bc97acc0b925b7f5dbec113f98c4b49224c694eb","affectsGlobalScope":true,"impliedFormat":1},{"version":"c874bfffe38a94b129077eaba4e26575972d545d5d04cd64e90c02d2c029ead6","impliedFormat":1},{"version":"f5ce35485541e817c2d4105d3eb78e3e538bbb009515ed014694363fa3e94ceb","impliedFormat":1},{"version":"323506ce173f7f865f42f493885ee3dacd18db6359ea1141d57676d3781ce10c","impliedFormat":1},{"version":"bd88055918cf8bf30ad7c9269177f7ebeafd4c5f0d28919edccd1c1d24f7e73c","affectsGlobalScope":true,"impliedFormat":1},{"version":"4ee9304173804c2c6dff4fcb8ad900619a4078b30d37f7e455236836e8e87a45","affectsGlobalScope":true,"impliedFormat":1},{"version":"ea3ab3727cd6c222d94003ecafa30e8550c61eadcdabbf59514aee76e86211a5","impliedFormat":1},{"version":"d3cdd41693c5ed6bec4f1a1c399d9501372b14bd341bc46eedacf2854c5df5a7","impliedFormat":1},{"version":"2de7a21c92226fb8abbeed7a0a9bd8aa6d37e4c68a8c7ff7938c644267e9fcc1","impliedFormat":1},{"version":"6d6070c5c81ba0bfe58988c69e3ba3149fc86421fd383f253aeb071cbf29cd41","impliedFormat":1},{"version":"48dab0d6e633b8052e7eaa0efb0bb3d58a733777b248765eafcb0b0349439834","impliedFormat":1},{"version":"6e4b2642721462bf62d19593770659f268a6ca1e9fd15543747efb3ac471cee3","impliedFormat":1},{"version":"269929a24b2816343a178008ac9ae9248304d92a8ba8e233055e0ed6dbe6ef71","impliedFormat":1},{"version":"93452d394fdd1dc551ec62f5042366f011a00d342d36d50793b3529bfc9bd633","impliedFormat":1},{"version":"cdaaf046791d7d588f28f32197c5d6acc43343e62540a67eed194c9c20535fdc","impliedFormat":1},{"version":"4b1ff655bd8edd879dd4f04f15338ce0109f58ccb424165d44fa07e7ea39c4bf","impliedFormat":1},{"version":"6fa61015444e843013443f2e5ca6bee5f033cbf361f953fd932abb0c029b73b2","affectsGlobalScope":true,"impliedFormat":1},{"version":"300f8e9de0b0c3482be3e749462b6ebc3dab8a316801f1da0def94aed0cd2018","affectsGlobalScope":true,"impliedFormat":1},{"version":"4e228e78c1e9b0a75c70588d59288f63a6258e8b1fe4a67b0c53fe03461421d9","impliedFormat":1},{"version":"24b8c93eb91a64a6fbb877a295cfac4c10aa4660599970c954a99d33697534a3","impliedFormat":1},{"version":"76a89af04f2ba1807309320dab5169c0d1243b80738b4a2005989e40a136733e","impliedFormat":1},{"version":"c045b664abf3fc2a4750fa96117ab2735e4ed45ddd571b2a6a91b9917e231a02","impliedFormat":1},{"version":"ca619678b887ae262316673b55bb358c517593d3b6b96c1271972716c699da32","affectsGlobalScope":true,"impliedFormat":1},{"version":"40ed27386f21a739bd0d2e2cfed563760588f2aeaa7ad149c1bf1454a7ec743a","affectsGlobalScope":true,"impliedFormat":1},{"version":"d1ef1d8516286380fd0a6f498f1650d374a8cb5f03d91633b6124e4fb8fb131d","impliedFormat":1},{"version":"fecdf44bec4ee9c5188e5f2f58c292c9689c02520900dceaaa6e76594de6da90","impliedFormat":1},{"version":"2641e5e19268b6f5038ad48a6e2598965301df8a77c48c99d8df760a6a154204","impliedFormat":1},{"version":"6a4a80787c57c10b3ea8314c80d9cc6e1deb99d20adca16106a337825f582420","affectsGlobalScope":true,"impliedFormat":1},{"version":"f2b9440f98d6f94c8105883a2b65aee2fce0248f71f41beafd0a80636f3a565d","impliedFormat":1},{"version":"ab9b9a36e5284fd8d3bf2f7d5fcbc60052f25f27e4d20954782099282c60d23e","affectsGlobalScope":true,"impliedFormat":1},{"version":"b510d0a18e3db42ac9765d26711083ec1e8b4e21caaca6dc4d25ae6e8623f447","impliedFormat":1},{"version":"89770f74968d22e5195c92e6a15a2315b35c44a795bc488bc2c2c9cf94e3b34f","impliedFormat":1},{"version":"81b828cedde10b708124cf4acabddc57e5c17e54a42e07506ea5f4fbde663d87","impliedFormat":1},{"version":"5fa5ca164fea16db2c611d502b3f5c82c1f02417507de0c4debeaf924f771a7a","impliedFormat":1},{"version":"6e33f96796b3f6ad6f737d1d28d82b66427966907b8703b98b58c2ae8a5b2333","impliedFormat":1},{"version":"3738606f7a546c0fdd74cfe1280a1efc502c80d5778a5527bcb8918fbc465ee5","impliedFormat":1},{"version":"df504094b5f46b960d326e01cdc2683b83cde9b1f3af52c22196360fd8191aef","impliedFormat":1},{"version":"7a2e7c19fbfd3ca11cd3fb90edf4fc3adf379bd31da785bef41f34a5c97d18c0","impliedFormat":1},{"version":"f4f9db86be98abda0930205133aa386c24ca11f277cfc0d0f1b0fa2de23c6bae","impliedFormat":1},{"version":"c718be4288049148aff73acb33942759a6a7b194c0fbf8c023c0186f403e64da","impliedFormat":1},{"version":"48e716f42a6444b2023acaaad75c390d6143dea43d52b37bfc5420fdfaa4f888","impliedFormat":1},{"version":"779978910a7760c3b0797084f6f7e6d9bceb5c2e30d63e9cb161716db1e32ed3","impliedFormat":1},{"version":"d3cf09decd9187dcbb925f0a0a7f4b2c3da80c3c1a9b636d2332a3aecd2b5992","impliedFormat":1},{"version":"568ea0e68446d5ba3c9f511a3a89d2c2c3eb2ec9d71f9c38a692fbb3915339ee","impliedFormat":1},{"version":"b3e9a7d4905609e07b8ae61b9f7d262240ef28797185b073d218f04486067e6b","impliedFormat":1},{"version":"7256febd272a24bd76fc5ad02e1adddc9e52a412139783837f9930b9e3ea2435","impliedFormat":1},{"version":"d86f9872317cb0a8247a958182d56078fcc6d57669d79962d3501e9f79ec076c","impliedFormat":1},{"version":"c8fe20e2db9f255ae9165a69f63a30803798f132d44ccb06489eb573c012197c","impliedFormat":1},{"version":"f338a331fc98b7a1f203f27b72934b22157bab6e23102f005b09786dcf383668","impliedFormat":1},{"version":"7336bc25cc72933b720c3bef0cb3087991aa27844c83376fc3fe36a824d7a8ed","impliedFormat":1},{"version":"5e661c9454b04066cceed04d87fbde484332b44405ad5d3d5e631e1bcb283b1a","impliedFormat":1},{"version":"1070df8aa24c5dd2823080a2882e5d09fb86fcbfc0104ccba13326121233de3f","impliedFormat":1},{"version":"2f1b2648a9ddeb7af4f497573aa751c99adf6ab11f40b554527f0f65fa5e39a8","impliedFormat":1},{"version":"20c4a80fbb0a5663564211f2148b3d8505fbb8ac0528dc7dd03c0357e6e18e48","impliedFormat":1},{"version":"5aa6397b22f8a04f8e5d97b2c08bb7038ca611363da1fe8e1174aa7114022248","impliedFormat":1},{"version":"c12cfe54ae9534e67fcef5c56efa1af3433b3dab19277866219e150a53db7aa6","impliedFormat":1},{"version":"63c4a0b4eb97c1f17198ffac8e868c2ade94bed702a93f364fb0de5459244a37","impliedFormat":1},{"version":"287492771a2f5f70e0618f932efa9895d5040901134d072c88fe79a3b46f1ca1","impliedFormat":1},{"version":"7f447c501d8bb805692f04ca839bd1cc4ba42589f28f6909db24490ecea872b8","impliedFormat":1},{"version":"e197b79669e5e7a62be85bb55a2c4b0a3935c9c21031f16b4801f9c1424fc7de","impliedFormat":1},{"version":"fe7c0cebf68625c1820b1fc93319648d9409021d2bad14a002645ca938a4ed6a","impliedFormat":1},{"version":"2933d72e14929db9787067dcf54092df7fa805b5cd899e5887d857962c34dbde","impliedFormat":1},{"version":"bdff031b82377b6a28afb4192490abbe16f065130ccf2e2294aebbe50a0146c4","impliedFormat":1},{"version":"2b69bdd0d8c3cf8a1996b403ad7759677175442562e89bb0f4b2d091ff707c97","impliedFormat":1},{"version":"10bd790f2555d8adc0a03f461660eba554273e3246c0ceb3f6a5f417d6629748","impliedFormat":1},{"version":"55aa8f99f91f68660dfb603d17d32801962c338a90a7d9661936e4c582a66608","impliedFormat":1},{"version":"8de633078fc317e8d998cf1f6b4b9d57c89eada17505da12b496e1d9686d3b2e","impliedFormat":1},{"version":"c878e4bdfd75a03485af04beb1651ff5010359446d41572222536d00a5ee2502","impliedFormat":1},{"version":"d3d2e941165ff1b1e63bf19c863b92b89e50a1f6f2fa8339a1dbfecabd46f756","impliedFormat":1},{"version":"9a38e042a84ca8d44af23a2d2584830d267cf192b547d84f50363170d0170ad1","impliedFormat":1},{"version":"bfe930af35cb57b0561009b48a54fd84d6ea68224d5adb235a577c4f4ef68ec5","impliedFormat":1},{"version":"e0f031b4e6818a76fa3fd6bf38aa29264bc598dee1601f0087ec9537b0ffc8fa","impliedFormat":1},{"version":"aac4e6377f752a85c57ee66bcd7b36f6d757c692dab7e43d1bf64a17b8608f5d","impliedFormat":1},{"version":"dbe4bad5c55676931c808dcbbfafcf614a89e55d7d5068aebc928e7ed17eafeb","impliedFormat":1},{"version":"cfd5b795605ba420d60d09cedbe5d233b9bb50901759ea843e73acbf0014b666","impliedFormat":1},{"version":"0f1e952e252c91440b1eb38287822d622dffd586addf0854becca9edef03ae73","impliedFormat":1},{"version":"a74b8f008dee8c60869db2a25bde16e8e75d38778eaa5edd5a879b88f1b0b2e2","impliedFormat":1},{"version":"62e51bdb51dbd23440d4c2b3976178ec7ca00adb1690c5fc56848085dbb3ef9a","impliedFormat":1},{"version":"9a76bec121a708a33b6b43fcfd1442898cf978a2ac2a9f15ca8cb5966d8c4b06","impliedFormat":1},{"version":"78cb0f496f365d27d213be6da0777ddba8ff8ef3a09e2a7d638ad5b1a8086540","impliedFormat":1},{"version":"bb4ce47a759e6c6a80e4ed1115e72f5830fbac8e940e8d9661ba1f95eea1d58f","impliedFormat":1},{"version":"a301f0459e7a00c0c5acf7cf82eb1cdf3f58194c51dd2cb00d7c86089af14df1","impliedFormat":1},{"version":"e92fda58674904c0704ab9d368dffc40bb0ead8b3325c9a10323386cd885b0f5","impliedFormat":1},{"version":"dcab3465b724aed54a583a74831cf8197a701cba8f1598495324eb323621dfe6","impliedFormat":1},{"version":"da2b5982235725afe9a0aed6ed60c6c0ccec4d9a9795b86aafdb1443fb913e54","impliedFormat":1},{"version":"7f93f4c204e36e7c4db3eab8eb1b536ade99629591449780ab063d14ac579292","impliedFormat":1},{"version":"bb5798e6512df7e32d326445d8e4d96d4adcc0de4120c3b3cd5eb267d8d89c2e","impliedFormat":1},{"version":"cf94ad90795e7d46d8eac710770036cb38f90cdac9e5581bc5e6b4f31d5ffdfd","impliedFormat":1},{"version":"d0694b66ec2d6f02ee196495d6a75790c08d2c16bafe5bd8e74ec96bb2d8431a","impliedFormat":1},{"version":"a4fc63e89fdf3b910bc942f3735c490edb1e9184cbc2d80387dd0dc52d49f0a7","impliedFormat":1},{"version":"8d523e6a4bb252bdb3441284623fd45c1607326ae037561365d08858055391d8","impliedFormat":1},{"version":"2728ef0658cb9efc597dd29d00156f1d298b3dc3478f99205c37155928922dd8","impliedFormat":1},{"version":"d0d88f7468427dcd2f2356aa08322cbfa16a8dd800611d850bd699b97f5b7ca3","impliedFormat":1},{"version":"a2b426dc2db567da3111136e5dd3ac1ce666fb8066a1535931fc9b40f49bbe6c","impliedFormat":1},{"version":"9f881daa662d54fda5c67ead52b1c024410d273672a8cb2e241a07fc2461a56f","impliedFormat":1},{"version":"7189e88a8093ae3ee36a1ce2ab8978c18fd0d8c5ecf6d2525cfab1fc425016ac","impliedFormat":1},{"version":"eda60e730f313d5d280e01f60b23db6f1158f7fcacad2892a37bee53ebbfd827","impliedFormat":1},{"version":"1d26859aa495b18bb96c30b081290ce275a50bbbd95e238ebbdd2ff631089be5","impliedFormat":1},{"version":"b6de1015df9b52c4fb34488f59b3d5dc20704f92aa8fcbe50d568b3ee667c3c1","impliedFormat":1},{"version":"5999a2ff4a66451434052e5eda20e2ef0e2758f88a18d7f1245d86c44572b959","impliedFormat":1},{"version":"4d949922c12ae2d15d4a010ce13d61eede41c6850b04c9fc970eb4bcb433bdc1","impliedFormat":1},{"version":"7c914bab31ace660ddb5e2b0ae2aa924d2b5faaeeca0261e0ada1ebba9722305","impliedFormat":1},{"version":"a6c6e0d17dd706d93c88377cc29f4cd1d6fd70e0162cb7610300c2d81f83a3d3","impliedFormat":1},{"version":"ea06b244f942be5467b237178774fc052573152ef69d1d9e1bf1c061af15df10","impliedFormat":1},{"version":"8a8cd239a260d899d1dd92b8bae39c412ee4175ad9ead9832514f66b500ee676","impliedFormat":1},{"version":"4e622d02fb2d2bff3cea84857d46f58841fd1e9c776ed531af29235f6999b33b","impliedFormat":1},{"version":"c7b93ce919fef735b01c1feb6eceb667f2d9b8f005513a7837cb845017299be1","impliedFormat":1},{"version":"2035c5afc65e2225b0b3162c546d042ece92f4bde48d7a11a98d4faff9b0638e","impliedFormat":1},{"version":"b7e0e35b429f40a47187cd08cc986a16c72e59bbb7f2034532b695cb87c5e3b6","impliedFormat":1},{"version":"cea4333c48d8211dc044595b4013f5dec8f6909dc182a5241de5872e430fa1ab","impliedFormat":1},{"version":"0452c979d0a94eb12a9d941f2ec6ba072890fa6ebda05667aae8d585dfa88ee4","impliedFormat":1},{"version":"b3d328c10e306a4c037274ec16489c6fdeae9fc4d2487d76b309d8d2289b2de1","impliedFormat":1},{"version":"c56da47559d21ce6f1b69565ac2b308afe6c51b7c40e2776472158cd4ffd0c47","impliedFormat":1},{"version":"b18605c186b6df26918aaa93df65509eb04c43314a147a8f6e69c23647fe2787","impliedFormat":1},{"version":"b7e0e35b429f40a47187cd08cc986a16c72e59bbb7f2034532b695cb87c5e3b6","impliedFormat":1},{"version":"541ffc7b0b14633884d3b43ef741c6eff26a96dcbafa28aaa266ec43028f2594","impliedFormat":1},{"version":"b3d328c10e306a4c037274ec16489c6fdeae9fc4d2487d76b309d8d2289b2de1","impliedFormat":1},{"version":"9f248a57ea662ea7683e37bcec0f1695e3d6c946add42ee7a772145288c2ca34","impliedFormat":1},{"version":"3f6d6465811321abc30a1e5f667feed63e5b3917b3d6c8d6645daf96c75f97ba","affectsGlobalScope":true,"impliedFormat":1}],"root":[232,237],"options":{"composite":false,"declaration":false,"declarationMap":false,"esModuleInterop":true,"inlineSources":true,"jsx":2,"module":1,"noImplicitAny":false,"noUnusedLocals":true,"outDir":"./","rootDir":"../../src/test","skipLibCheck":true,"sourceMap":true,"strict":true,"target":7},"fileIdsList":[[143,168],[143],[143,169],[143,168,169,170,171,172,173,174,175,176,177,178],[143,169,170,173,175],[143,172],[143,233],[143,233,234],[143,233,234,235],[143,236],[63,143],[100,143],[101,106,134,143],[102,113,114,121,131,142,143],[102,103,113,121,143],[104,143],[105,106,114,122,143],[106,131,139,143],[107,109,113,121,143],[108,143],[109,110,143],[113,143],[111,113,143],[100,113,143],[113,114,115,131,142,143],[113,114,115,128,131,134,143],[98,143,147],[109,113,116,121,131,142,143],[113,114,116,117,121,131,139,142,143],[116,118,131,139,142,143],[63,64,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149],[113,119,143],[120,142,143,147],[109,113,121,131,143],[122,143],[123,143],[100,124,143],[125,141,143,147],[126,143],[127,143],[113,128,129,143],[128,130,143,145],[101,113,131,132,133,134,143],[101,131,133,143],[131,132,143],[134,143],[135,143],[100,131,143],[113,137,138,143],[137,138,143],[106,121,131,139,143],[140,143],[121,141,143],[101,116,127,142,143],[106,143],[131,143,144],[120,143,145],[143,146],[101,106,113,115,124,131,142,143,145,147],[131,143,148],[75,79,142,143],[75,131,142,143],[70,143],[72,75,139,142,143],[121,139,143],[143,150],[70,143,150],[72,75,121,142,143],[67,68,71,74,101,113,131,142,143],[67,73,143],[71,75,101,134,142,143,150],[101,143,150],[91,101,143,150],[69,70,143,150],[75,143],[69,70,71,72,73,74,75,76,77,79,80,81,82,83,84,85,86,87,88,89,90,92,93,94,95,96,97,143],[75,82,83,143],[73,75,83,84,143],[74,143],[67,70,75,143],[75,79,83,84,143],[79,143],[73,75,78,142,143],[67,72,73,75,79,82,143],[101,131,143],[70,75,91,101,143,147,150],[56,113,143,150,151,193],[58,143],[58,59,60,61,62,143,151,152,153],[56,113,143,150,193],[113,143,179],[143,191],[56,143,179,193,196],[56,143,193],[56,143,191,193,199],[56,143,190,191,192,193,197,198,199,200,201],[56,143,179,190,191,193,196,197,198,199,200],[56,143,179,190,191,193,196,197,198,201],[51,143],[49,50,52,143],[46,47,48,49,50,51,52,53,54,55,143],[143,155,156,157,158,159,160,161,162,163],[143,193],[143,193,194,195],[56,143,179,193,194],[143,229],[143,228,229],[143,228,229,230],[143,228],[56,63,143,164,193,227,228,229,231],[143,231,236],[56,143,179,193,219,220,221],[56,143,179,193,202,212,219,222],[143,220,221,222,223,224],[56,143,193,223],[56,143,154,179,189,193,202,219,225],[57,143,226],[56,143,193,208],[143,208],[143,208,209,211],[143,204,206],[143,204,206,207],[143,204],[143,205],[143,208,210],[143,179],[56,143,179,193,196,202,212,213,214,215,216,217],[143,218],[143,213],[143,203,212,213,214,215,216,217,218],[56,143,179,193,215],[56,143,164,165,166,193],[56,143,179,180,181,193],[56,143,165,180,193],[56,143,154,193],[113,143,150,165],[143,165,166,167,180,181,182,183,184,185,186,187,188],[56,143,154,165,193],[56,143,165,193],[143,165]],"referencedMap":[[169,1],[170,2],[171,3],[172,2],[179,4],[173,2],[174,2],[176,5],[177,6],[178,2],[175,1],[168,2],[234,7],[235,8],[236,9],[233,10],[65,2],[238,2],[63,11],[64,11],[100,12],[101,13],[102,14],[103,15],[104,16],[105,17],[106,18],[107,19],[108,20],[109,21],[110,21],[112,22],[111,23],[113,24],[114,25],[115,26],[99,27],[149,2],[116,28],[117,29],[118,30],[150,31],[119,32],[120,33],[121,34],[122,35],[123,36],[124,37],[125,38],[126,39],[127,40],[128,41],[129,41],[130,42],[131,43],[133,44],[132,45],[134,46],[135,47],[136,48],[137,49],[138,50],[139,51],[140,52],[141,53],[142,54],[143,55],[144,56],[145,57],[146,58],[147,59],[148,60],[66,2],[44,2],[45,2],[8,2],[9,2],[11,2],[10,2],[2,2],[12,2],[13,2],[14,2],[15,2],[16,2],[17,2],[18,2],[19,2],[3,2],[4,2],[23,2],[20,2],[21,2],[22,2],[24,2],[25,2],[26,2],[5,2],[27,2],[28,2],[29,2],[30,2],[6,2],[34,2],[31,2],[32,2],[33,2],[35,2],[7,2],[36,2],[41,2],[42,2],[37,2],[38,2],[39,2],[40,2],[1,2],[43,2],[82,61],[89,62],[81,61],[96,63],[73,64],[72,65],[95,66],[90,67],[93,68],[75,69],[74,70],[70,71],[69,72],[92,73],[71,74],[76,75],[77,2],[80,75],[67,2],[98,76],[97,75],[84,77],[85,78],[87,79],[83,80],[86,81],[91,66],[78,82],[79,83],[88,84],[68,85],[94,86],[61,2],[58,2],[62,2],[152,87],[59,88],[154,89],[60,2],[153,2],[151,90],[190,91],[192,92],[197,93],[198,94],[200,95],[191,2],[202,96],[201,97],[199,98],[55,2],[46,2],[47,94],[48,2],[52,99],[53,2],[49,2],[51,100],[56,101],[54,2],[50,2],[155,2],[156,2],[157,2],[158,2],[164,102],[159,2],[160,2],[161,2],[162,2],[163,2],[194,103],[196,104],[195,105],[193,94],[228,106],[230,107],[231,108],[229,109],[232,110],[237,111],[222,112],[221,113],[225,114],[223,2],[224,115],[220,2],[226,116],[57,94],[227,117],[209,118],[210,119],[212,120],[207,121],[204,2],[208,122],[205,123],[206,124],[211,125],[203,126],[218,127],[213,128],[214,129],[215,2],[219,130],[216,126],[217,131],[167,132],[182,133],[181,134],[183,135],[184,136],[180,94],[189,137],[166,138],[185,139],[187,139],[165,94],[186,140],[188,139]],"exportedModulesMap":[[169,1],[170,2],[171,3],[172,2],[179,4],[173,2],[174,2],[176,5],[177,6],[178,2],[175,1],[168,2],[234,7],[235,8],[236,9],[233,10],[65,2],[238,2],[63,11],[64,11],[100,12],[101,13],[102,14],[103,15],[104,16],[105,17],[106,18],[107,19],[108,20],[109,21],[110,21],[112,22],[111,23],[113,24],[114,25],[115,26],[99,27],[149,2],[116,28],[117,29],[118,30],[150,31],[119,32],[120,33],[121,34],[122,35],[123,36],[124,37],[125,38],[126,39],[127,40],[128,41],[129,41],[130,42],[131,43],[133,44],[132,45],[134,46],[135,47],[136,48],[137,49],[138,50],[139,51],[140,52],[141,53],[142,54],[143,55],[144,56],[145,57],[146,58],[147,59],[148,60],[66,2],[44,2],[45,2],[8,2],[9,2],[11,2],[10,2],[2,2],[12,2],[13,2],[14,2],[15,2],[16,2],[17,2],[18,2],[19,2],[3,2],[4,2],[23,2],[20,2],[21,2],[22,2],[24,2],[25,2],[26,2],[5,2],[27,2],[28,2],[29,2],[30,2],[6,2],[34,2],[31,2],[32,2],[33,2],[35,2],[7,2],[36,2],[41,2],[42,2],[37,2],[38,2],[39,2],[40,2],[1,2],[43,2],[82,61],[89,62],[81,61],[96,63],[73,64],[72,65],[95,66],[90,67],[93,68],[75,69],[74,70],[70,71],[69,72],[92,73],[71,74],[76,75],[77,2],[80,75],[67,2],[98,76],[97,75],[84,77],[85,78],[87,79],[83,80],[86,81],[91,66],[78,82],[79,83],[88,84],[68,85],[94,86],[61,2],[58,2],[62,2],[152,87],[59,88],[154,89],[60,2],[153,2],[151,90],[190,91],[192,92],[197,93],[198,94],[200,95],[191,2],[202,96],[201,97],[199,98],[55,2],[46,2],[47,94],[48,2],[52,99],[53,2],[49,2],[51,100],[56,101],[54,2],[50,2],[155,2],[156,2],[157,2],[158,2],[164,102],[159,2],[160,2],[161,2],[162,2],[163,2],[194,103],[196,104],[195,105],[193,94],[228,106],[230,107],[231,108],[229,109],[232,110],[237,111],[222,112],[221,113],[225,114],[223,2],[224,115],[220,2],[226,116],[57,94],[227,117],[209,118],[210,119],[212,120],[207,121],[204,2],[208,122],[205,123],[206,124],[211,125],[203,126],[218,127],[213,128],[214,129],[215,2],[219,130],[216,126],[217,131],[167,132],[182,133],[181,134],[183,135],[184,136],[180,94],[189,137],[166,138],[185,139],[187,139],[165,94],[186,140],[188,139]],"semanticDiagnosticsPerFile":[169,170,171,172,179,173,174,176,177,178,175,168,234,235,236,233,65,238,63,64,100,101,102,103,104,105,106,107,108,109,110,112,111,113,114,115,99,149,116,117,118,150,119,120,121,122,123,124,125,126,127,128,129,130,131,133,132,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,66,44,45,8,9,11,10,2,12,13,14,15,16,17,18,19,3,4,23,20,21,22,24,25,26,5,27,28,29,30,6,34,31,32,33,35,7,36,41,42,37,38,39,40,1,43,82,89,81,96,73,72,95,90,93,75,74,70,69,92,71,76,77,80,67,98,97,84,85,87,83,86,91,78,79,88,68,94,61,58,62,152,59,154,60,153,151,190,192,197,198,200,191,202,201,199,55,46,47,48,52,53,49,51,56,54,50,155,156,157,158,164,159,160,161,162,163,194,196,195,193,228,230,231,229,232,237,222,221,225,223,224,220,226,57,227,209,210,212,207,204,208,205,206,211,203,218,213,214,215,219,216,217,167,182,181,183,184,180,189,166,185,187,165,186,188]},"version":"5.1.6"}
|
|
@@ -18,4 +18,4 @@ use_current_InterfaceDeclaration_IFluidDependencySynthesizer(get_old_InterfaceDe
|
|
|
18
18
|
use_old_InterfaceDeclaration_IFluidDependencySynthesizer(get_current_InterfaceDeclaration_IFluidDependencySynthesizer());
|
|
19
19
|
use_current_InterfaceDeclaration_IProvideFluidDependencySynthesizer(get_old_InterfaceDeclaration_IProvideFluidDependencySynthesizer());
|
|
20
20
|
use_old_InterfaceDeclaration_IProvideFluidDependencySynthesizer(get_current_InterfaceDeclaration_IProvideFluidDependencySynthesizer());
|
|
21
|
-
//# sourceMappingURL=validateSynthesizePrevious.generated.
|
|
21
|
+
//# sourceMappingURL=validateSynthesizePrevious.generated.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"validateSynthesizePrevious.generated.js","sourceRoot":"","sources":["../../../src/test/types/validateSynthesizePrevious.generated.ts"],"names":[],"mappings":";;AAgCA,yDAAyD,CACrD,qDAAqD,EAAE,CAAC,CAAC;AAW7D,qDAAqD,CACjD,yDAAyD,EAAE,CAAC,CAAC;AAWjE,iEAAiE,CAC7D,6DAA6D,EAAE,CAAC,CAAC;AAWrE,6DAA6D,CACzD,iEAAiE,EAAE,CAAC,CAAC;AAWzE,iEAAiE,CAC7D,6DAA6D,EAAE,CAAC,CAAC;AAWrE,6DAA6D,CACzD,iEAAiE,EAAE,CAAC,CAAC;AAWzE,gDAAgD,CAC5C,4CAA4C,EAAE,CAAC,CAAC;AAWpD,4CAA4C,CACxC,gDAAgD,EAAE,CAAC,CAAC;AAWxD,oDAAoD,CAChD,gDAAgD,EAAE,CAAC,CAAC;AAWxD,gDAAgD,CAC5C,oDAAoD,EAAE,CAAC,CAAC;AAW5D,0DAA0D,CACtD,sDAAsD,EAAE,CAAC,CAAC;AAW9D,sDAAsD,CAClD,0DAA0D,EAAE,CAAC,CAAC;AAWlE,2DAA2D,CACvD,uDAAuD,EAAE,CAAC,CAAC;AAW/D,uDAAuD,CACnD,2DAA2D,EAAE,CAAC,CAAC;AAWnE,4DAA4D,CACxD,wDAAwD,EAAE,CAAC,CAAC;AAWhE,wDAAwD,CACpD,4DAA4D,EAAE,CAAC,CAAC;AAWpE,mEAAmE,CAC/D,+DAA+D,EAAE,CAAC,CAAC;AAWvE,+DAA+D,CAC3D,mEAAmE,EAAE,CAAC,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n/*\n * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.\n * Generated by fluid-type-test-generator in @fluidframework/build-tools.\n */\nimport type * as old from \"@fluidframework/synthesize-previous\";\nimport type * as current from \"../../index\";\n\n\n// See 'build-tools/src/type-test-generator/compatibility.ts' for more information.\ntype TypeOnly<T> = T extends number\n\t? number\n\t: T extends string\n\t? string\n\t: T extends boolean | bigint | symbol\n\t? T\n\t: {\n\t\t\t[P in keyof T]: TypeOnly<T[P]>;\n\t };\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_AsyncFluidObjectProvider\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_TypeAliasDeclaration_AsyncFluidObjectProvider():\n TypeOnly<old.AsyncFluidObjectProvider<any>>;\ndeclare function use_current_TypeAliasDeclaration_AsyncFluidObjectProvider(\n use: TypeOnly<current.AsyncFluidObjectProvider<any>>): void;\nuse_current_TypeAliasDeclaration_AsyncFluidObjectProvider(\n get_old_TypeAliasDeclaration_AsyncFluidObjectProvider());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_AsyncFluidObjectProvider\": {\"backCompat\": false}\n*/\ndeclare function get_current_TypeAliasDeclaration_AsyncFluidObjectProvider():\n TypeOnly<current.AsyncFluidObjectProvider<any>>;\ndeclare function use_old_TypeAliasDeclaration_AsyncFluidObjectProvider(\n use: TypeOnly<old.AsyncFluidObjectProvider<any>>): void;\nuse_old_TypeAliasDeclaration_AsyncFluidObjectProvider(\n get_current_TypeAliasDeclaration_AsyncFluidObjectProvider());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_AsyncOptionalFluidObjectProvider\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_TypeAliasDeclaration_AsyncOptionalFluidObjectProvider():\n TypeOnly<old.AsyncOptionalFluidObjectProvider<any>>;\ndeclare function use_current_TypeAliasDeclaration_AsyncOptionalFluidObjectProvider(\n use: TypeOnly<current.AsyncOptionalFluidObjectProvider<any>>): void;\nuse_current_TypeAliasDeclaration_AsyncOptionalFluidObjectProvider(\n get_old_TypeAliasDeclaration_AsyncOptionalFluidObjectProvider());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_AsyncOptionalFluidObjectProvider\": {\"backCompat\": false}\n*/\ndeclare function get_current_TypeAliasDeclaration_AsyncOptionalFluidObjectProvider():\n TypeOnly<current.AsyncOptionalFluidObjectProvider<any>>;\ndeclare function use_old_TypeAliasDeclaration_AsyncOptionalFluidObjectProvider(\n use: TypeOnly<old.AsyncOptionalFluidObjectProvider<any>>): void;\nuse_old_TypeAliasDeclaration_AsyncOptionalFluidObjectProvider(\n get_current_TypeAliasDeclaration_AsyncOptionalFluidObjectProvider());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_AsyncRequiredFluidObjectProvider\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_TypeAliasDeclaration_AsyncRequiredFluidObjectProvider():\n TypeOnly<old.AsyncRequiredFluidObjectProvider<any>>;\ndeclare function use_current_TypeAliasDeclaration_AsyncRequiredFluidObjectProvider(\n use: TypeOnly<current.AsyncRequiredFluidObjectProvider<any>>): void;\nuse_current_TypeAliasDeclaration_AsyncRequiredFluidObjectProvider(\n get_old_TypeAliasDeclaration_AsyncRequiredFluidObjectProvider());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_AsyncRequiredFluidObjectProvider\": {\"backCompat\": false}\n*/\ndeclare function get_current_TypeAliasDeclaration_AsyncRequiredFluidObjectProvider():\n TypeOnly<current.AsyncRequiredFluidObjectProvider<any>>;\ndeclare function use_old_TypeAliasDeclaration_AsyncRequiredFluidObjectProvider(\n use: TypeOnly<old.AsyncRequiredFluidObjectProvider<any>>): void;\nuse_old_TypeAliasDeclaration_AsyncRequiredFluidObjectProvider(\n get_current_TypeAliasDeclaration_AsyncRequiredFluidObjectProvider());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"ClassDeclaration_DependencyContainer\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_ClassDeclaration_DependencyContainer():\n TypeOnly<old.DependencyContainer<any>>;\ndeclare function use_current_ClassDeclaration_DependencyContainer(\n use: TypeOnly<current.DependencyContainer<any>>): void;\nuse_current_ClassDeclaration_DependencyContainer(\n get_old_ClassDeclaration_DependencyContainer());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"ClassDeclaration_DependencyContainer\": {\"backCompat\": false}\n*/\ndeclare function get_current_ClassDeclaration_DependencyContainer():\n TypeOnly<current.DependencyContainer<any>>;\ndeclare function use_old_ClassDeclaration_DependencyContainer(\n use: TypeOnly<old.DependencyContainer<any>>): void;\nuse_old_ClassDeclaration_DependencyContainer(\n get_current_ClassDeclaration_DependencyContainer());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_FluidObjectProvider\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_TypeAliasDeclaration_FluidObjectProvider():\n TypeOnly<old.FluidObjectProvider<any>>;\ndeclare function use_current_TypeAliasDeclaration_FluidObjectProvider(\n use: TypeOnly<current.FluidObjectProvider<any>>): void;\nuse_current_TypeAliasDeclaration_FluidObjectProvider(\n get_old_TypeAliasDeclaration_FluidObjectProvider());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_FluidObjectProvider\": {\"backCompat\": false}\n*/\ndeclare function get_current_TypeAliasDeclaration_FluidObjectProvider():\n TypeOnly<current.FluidObjectProvider<any>>;\ndeclare function use_old_TypeAliasDeclaration_FluidObjectProvider(\n use: TypeOnly<old.FluidObjectProvider<any>>): void;\nuse_old_TypeAliasDeclaration_FluidObjectProvider(\n get_current_TypeAliasDeclaration_FluidObjectProvider());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_FluidObjectSymbolProvider\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_TypeAliasDeclaration_FluidObjectSymbolProvider():\n TypeOnly<old.FluidObjectSymbolProvider<any>>;\ndeclare function use_current_TypeAliasDeclaration_FluidObjectSymbolProvider(\n use: TypeOnly<current.FluidObjectSymbolProvider<any>>): void;\nuse_current_TypeAliasDeclaration_FluidObjectSymbolProvider(\n get_old_TypeAliasDeclaration_FluidObjectSymbolProvider());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_FluidObjectSymbolProvider\": {\"backCompat\": false}\n*/\ndeclare function get_current_TypeAliasDeclaration_FluidObjectSymbolProvider():\n TypeOnly<current.FluidObjectSymbolProvider<any>>;\ndeclare function use_old_TypeAliasDeclaration_FluidObjectSymbolProvider(\n use: TypeOnly<old.FluidObjectSymbolProvider<any>>): void;\nuse_old_TypeAliasDeclaration_FluidObjectSymbolProvider(\n get_current_TypeAliasDeclaration_FluidObjectSymbolProvider());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"VariableDeclaration_IFluidDependencySynthesizer\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_VariableDeclaration_IFluidDependencySynthesizer():\n TypeOnly<typeof old.IFluidDependencySynthesizer>;\ndeclare function use_current_VariableDeclaration_IFluidDependencySynthesizer(\n use: TypeOnly<typeof current.IFluidDependencySynthesizer>): void;\nuse_current_VariableDeclaration_IFluidDependencySynthesizer(\n get_old_VariableDeclaration_IFluidDependencySynthesizer());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"VariableDeclaration_IFluidDependencySynthesizer\": {\"backCompat\": false}\n*/\ndeclare function get_current_VariableDeclaration_IFluidDependencySynthesizer():\n TypeOnly<typeof current.IFluidDependencySynthesizer>;\ndeclare function use_old_VariableDeclaration_IFluidDependencySynthesizer(\n use: TypeOnly<typeof old.IFluidDependencySynthesizer>): void;\nuse_old_VariableDeclaration_IFluidDependencySynthesizer(\n get_current_VariableDeclaration_IFluidDependencySynthesizer());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"InterfaceDeclaration_IFluidDependencySynthesizer\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_InterfaceDeclaration_IFluidDependencySynthesizer():\n TypeOnly<old.IFluidDependencySynthesizer>;\ndeclare function use_current_InterfaceDeclaration_IFluidDependencySynthesizer(\n use: TypeOnly<current.IFluidDependencySynthesizer>): void;\nuse_current_InterfaceDeclaration_IFluidDependencySynthesizer(\n get_old_InterfaceDeclaration_IFluidDependencySynthesizer());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"InterfaceDeclaration_IFluidDependencySynthesizer\": {\"backCompat\": false}\n*/\ndeclare function get_current_InterfaceDeclaration_IFluidDependencySynthesizer():\n TypeOnly<current.IFluidDependencySynthesizer>;\ndeclare function use_old_InterfaceDeclaration_IFluidDependencySynthesizer(\n use: TypeOnly<old.IFluidDependencySynthesizer>): void;\nuse_old_InterfaceDeclaration_IFluidDependencySynthesizer(\n get_current_InterfaceDeclaration_IFluidDependencySynthesizer());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"InterfaceDeclaration_IProvideFluidDependencySynthesizer\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_InterfaceDeclaration_IProvideFluidDependencySynthesizer():\n TypeOnly<old.IProvideFluidDependencySynthesizer>;\ndeclare function use_current_InterfaceDeclaration_IProvideFluidDependencySynthesizer(\n use: TypeOnly<current.IProvideFluidDependencySynthesizer>): void;\nuse_current_InterfaceDeclaration_IProvideFluidDependencySynthesizer(\n get_old_InterfaceDeclaration_IProvideFluidDependencySynthesizer());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"InterfaceDeclaration_IProvideFluidDependencySynthesizer\": {\"backCompat\": false}\n*/\ndeclare function get_current_InterfaceDeclaration_IProvideFluidDependencySynthesizer():\n TypeOnly<current.IProvideFluidDependencySynthesizer>;\ndeclare function use_old_InterfaceDeclaration_IProvideFluidDependencySynthesizer(\n use: TypeOnly<old.IProvideFluidDependencySynthesizer>): void;\nuse_old_InterfaceDeclaration_IProvideFluidDependencySynthesizer(\n get_current_InterfaceDeclaration_IProvideFluidDependencySynthesizer());\n"]}
|
package/dist/types.d.ts
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Copyright (c) Microsoft Corporation and contributors. All rights reserved.
|
|
3
3
|
* Licensed under the MIT License.
|
|
4
4
|
*/
|
|
5
|
-
import { IFluidDependencySynthesizer } from "
|
|
5
|
+
import { IFluidDependencySynthesizer } from "./IFluidDependencySynthesizer";
|
|
6
6
|
/**
|
|
7
7
|
* This is a condensed version of Record that requires the object has all
|
|
8
8
|
* the FluidObject properties as its type mapped to a string representation
|
|
@@ -43,7 +43,7 @@ export type AsyncOptionalFluidObjectProvider<T> = T extends undefined ? Record<s
|
|
|
43
43
|
export type AsyncFluidObjectProvider<O, R = undefined> = AsyncOptionalFluidObjectProvider<O> & AsyncRequiredFluidObjectProvider<R>;
|
|
44
44
|
/**
|
|
45
45
|
* Multiple ways to provide a Fluid object.
|
|
46
|
-
* @
|
|
46
|
+
* @alpha
|
|
47
47
|
*/
|
|
48
48
|
export type FluidObjectProvider<T> = NonNullable<T> | Promise<NonNullable<T>> | ((dependencyContainer: IFluidDependencySynthesizer) => NonNullable<T>) | ((dependencyContainer: IFluidDependencySynthesizer) => Promise<NonNullable<T>>);
|
|
49
49
|
//# sourceMappingURL=types.d.ts.map
|
package/dist/types.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,OAAO,EAAE,2BAA2B,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,OAAO,EAAE,2BAA2B,EAAE,MAAM,+BAA+B,CAAC;AAE5E;;;;;;;;;;;GAWG;AACH,MAAM,MAAM,yBAAyB,CAAC,CAAC,IAAI;KACzC,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC;CAClB,CAAC;AAEF;;;;;GAKG;AACH,MAAM,MAAM,gCAAgC,CAAC,CAAC,IAAI,CAAC,SAAS,SAAS,GAClE,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,GACrB;KACC,CAAC,IAAI,MAAM,CAAC,GAAG,OAAO,CAAC,WAAW,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,SAAS,GAAG,IAAI,CAAC,CAAC,CAAC;CACpE,CAAC;AAEL;;;;;GAKG;AACH,MAAM,MAAM,gCAAgC,CAAC,CAAC,IAAI,CAAC,SAAS,SAAS,GAClE,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,GACrB;KACC,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,EAAE,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,SAAS,CAAC;CACzC,CAAC;AAEL;;;GAGG;AACH,MAAM,MAAM,wBAAwB,CAAC,CAAC,EAAE,CAAC,GAAG,SAAS,IAAI,gCAAgC,CAAC,CAAC,CAAC,GAC3F,gCAAgC,CAAC,CAAC,CAAC,CAAC;AAErC;;;GAGG;AACH,MAAM,MAAM,mBAAmB,CAAC,CAAC,IAC9B,WAAW,CAAC,CAAC,CAAC,GACd,OAAO,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,GACvB,CAAC,CAAC,mBAAmB,EAAE,2BAA2B,KAAK,WAAW,CAAC,CAAC,CAAC,CAAC,GACtE,CAAC,CAAC,mBAAmB,EAAE,2BAA2B,KAAK,OAAO,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\nimport { IFluidDependencySynthesizer } from \"./IFluidDependencySynthesizer\";\n\n/**\n * This is a condensed version of Record that requires the object has all\n * the FluidObject properties as its type mapped to a string representation\n * of that property.\n *\n * @example\n *\n * ```typescript\n * { IFoo: \"IFoo\" }\n * ```\n * @alpha\n */\nexport type FluidObjectSymbolProvider<T> = {\n\t[P in keyof T]?: P;\n};\n\n/**\n * This is a condensed version of Record that requires the object has all\n * the FluidObject properties as its type mapped to an object that implements\n * the property.\n * @alpha\n */\nexport type AsyncRequiredFluidObjectProvider<T> = T extends undefined\n\t? Record<string, never>\n\t: {\n\t\t\t[P in keyof T]: Promise<NonNullable<Exclude<T[P], undefined | null>>>;\n\t };\n\n/**\n * This is a condensed version of Record that requires the object has all\n * the FluidObject properties as its type, mapped to an object that implements\n * the property or undefined.\n * @alpha\n */\nexport type AsyncOptionalFluidObjectProvider<T> = T extends undefined\n\t? Record<string, never>\n\t: {\n\t\t\t[P in keyof T]?: Promise<T[P] | undefined>;\n\t };\n\n/**\n * Combined type for Optional and Required Async Fluid object Providers\n * @alpha\n */\nexport type AsyncFluidObjectProvider<O, R = undefined> = AsyncOptionalFluidObjectProvider<O> &\n\tAsyncRequiredFluidObjectProvider<R>;\n\n/**\n * Multiple ways to provide a Fluid object.\n * @alpha\n */\nexport type FluidObjectProvider<T> =\n\t| NonNullable<T>\n\t| Promise<NonNullable<T>>\n\t| ((dependencyContainer: IFluidDependencySynthesizer) => NonNullable<T>)\n\t| ((dependencyContainer: IFluidDependencySynthesizer) => Promise<NonNullable<T>>);\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"IFluidDependencySynthesizer.d.mts","sourceRoot":"","sources":["../src/IFluidDependencySynthesizer.ts"],"names":[],"mappings":"AAAA;;;GAGG;OAEI,EAAE,wBAAwB,EAAE,yBAAyB,EAAE;AAE9D;;GAEG;AACH,eAAO,MAAM,2BAA2B,EAAE,MAAM,kCAClB,CAAC;AAE/B;;GAEG;AACH,MAAM,WAAW,kCAAkC;IAClD,2BAA2B,EAAE,2BAA2B,CAAC;CACzD;AAED;;;;;GAKG;AACH,MAAM,WAAW,2BAA4B,SAAQ,kCAAkC;IACtF;;;;;;OAMG;IACH,UAAU,CAAC,CAAC,EAAE,CAAC,GAAG,SAAS,GAAG,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,EAClD,aAAa,EAAE,yBAAyB,CAAC,CAAC,CAAC,EAC3C,aAAa,EAAE,QAAQ,CAAC,yBAAyB,CAAC,CAAC,CAAC,CAAC,GACnD,wBAAwB,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;IAElC;;;OAGG;IACH,GAAG,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC;CAC3B"}
|
|
@@ -7,7 +7,7 @@ import { IFluidDependencySynthesizer } from "./IFluidDependencySynthesizer.mjs";
|
|
|
7
7
|
/**
|
|
8
8
|
* DependencyContainer is similar to a IoC Container. It takes providers and will
|
|
9
9
|
* synthesize an object based on them when requested.
|
|
10
|
-
* @
|
|
10
|
+
* @alpha
|
|
11
11
|
*/
|
|
12
12
|
export declare class DependencyContainer<TMap> implements IFluidDependencySynthesizer {
|
|
13
13
|
private readonly providers;
|
|
@@ -43,4 +43,4 @@ export declare class DependencyContainer<TMap> implements IFluidDependencySynthe
|
|
|
43
43
|
private generateOptional;
|
|
44
44
|
private resolveProvider;
|
|
45
45
|
}
|
|
46
|
-
//# sourceMappingURL=dependencyContainer.d.
|
|
46
|
+
//# sourceMappingURL=dependencyContainer.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dependencyContainer.d.mts","sourceRoot":"","sources":["../src/dependencyContainer.ts"],"names":[],"mappings":"AAAA;;;GAGG;OAGI,EACN,wBAAwB,EACxB,yBAAyB,EACzB,mBAAmB,EAGnB;OACM,EAAE,2BAA2B,EAAE;AAEtC;;;;GAIG;AACH,qBAAa,mBAAmB,CAAC,IAAI,CAAE,YAAW,2BAA2B;IAC5E,OAAO,CAAC,QAAQ,CAAC,SAAS,CAAmD;IAC7E,OAAO,CAAC,QAAQ,CAAC,OAAO,CAAgC;IACxD,IAAW,2BAA2B,SAErC;gBAEkB,GAAG,OAAO,EAAE,CAAC,2BAA2B,GAAG,SAAS,CAAC,EAAE;IAI1E;;;;;OAKG;IACI,QAAQ,CAAC,CAAC,SAAS,MAAM,IAAI,GAAG,MAAM,IAAI,EAChD,IAAI,EAAE,CAAC,EACP,QAAQ,EAAE,mBAAmB,CAAC,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC,CAAC,GAC1C,IAAI;IAUP;;;OAGG;IACI,UAAU,CAAC,IAAI,EAAE,MAAM,IAAI,GAAG,IAAI;IAMzC;;OAEG;IACI,UAAU,CAAC,CAAC,EAAE,CAAC,GAAG,SAAS,GAAG,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,EACzD,aAAa,EAAE,yBAAyB,CAAC,CAAC,CAAC,EAC3C,aAAa,EAAE,QAAQ,CAAC,yBAAyB,CAAC,CAAC,CAAC,CAAC,GACnD,wBAAwB,CAAC,CAAC,EAAE,CAAC,CAAC;IAQjC;;;OAGG;IACI,GAAG,CAAC,IAAI,EAAE,MAAM,EAAE,cAAc,CAAC,EAAE,OAAO,GAAG,OAAO;IAS3D;;OAEG;IACH,OAAO,CAAC,WAAW;IAuBnB,OAAO,CAAC,gBAAgB;IAoBxB,OAAO,CAAC,gBAAgB;IAgBxB,OAAO,CAAC,eAAe;CA2CvB"}
|
|
@@ -7,7 +7,7 @@ import { IFluidDependencySynthesizer } from "./IFluidDependencySynthesizer.mjs";
|
|
|
7
7
|
/**
|
|
8
8
|
* DependencyContainer is similar to a IoC Container. It takes providers and will
|
|
9
9
|
* synthesize an object based on them when requested.
|
|
10
|
-
* @
|
|
10
|
+
* @alpha
|
|
11
11
|
*/
|
|
12
12
|
export class DependencyContainer {
|
|
13
13
|
get IFluidDependencySynthesizer() {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"dependencyContainer.mjs","sourceRoot":"","sources":["../src/dependencyContainer.ts"],"names":[],"mappings":"AAAA;;;GAGG;OAEI,EAAE,WAAW,EAAE,MAAM,4BAA4B;OAQjD,EAAE,2BAA2B,EAAE;AAEtC;;;;GAIG;AACH,MAAM,OAAO,mBAAmB;IAG/B,IAAW,2BAA2B;QACrC,OAAO,IAAI,CAAC;IACb,CAAC;IAED,YAAmB,GAA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6BACvD,IAAI,CAAC,KAAK,EAAE,GAAG,EAAgB,EAAE,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC;6BAChD,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC;qBACtB;gBACF,CAAC;aACD,CAAC;SACF;QACD,OAAO;YACN,GAAG;gBACF,IAAI,QAAQ,EAAE;oBACb,OAAO,IAAI,WAAW,CAAC,KAAK,IAAI,EAAE;wBACjC,OAAO,OAAO,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE;4BAC3C,IAAI,CAAC,EAAE;gCACN,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC;6BACZ;wBACF,CAAC,CAAC,CAAC;oBACJ,CAAC,CAAC,CAAC;iBACH;YACF,CAAC;SACD,CAAC;IACH,CAAC;CACD","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { LazyPromise } from \"@fluidframework/core-utils\";\nimport {\n\tAsyncFluidObjectProvider,\n\tFluidObjectSymbolProvider,\n\tFluidObjectProvider,\n\tAsyncOptionalFluidObjectProvider,\n\tAsyncRequiredFluidObjectProvider,\n} from \"./types\";\nimport { IFluidDependencySynthesizer } from \"./IFluidDependencySynthesizer\";\n\n/**\n * DependencyContainer is similar to a IoC Container. It takes providers and will\n * synthesize an object based on them when requested.\n * @internal\n */\nexport class DependencyContainer<TMap> implements IFluidDependencySynthesizer {\n\tprivate readonly providers = new Map<keyof TMap, FluidObjectProvider<any>>();\n\tprivate readonly parents: IFluidDependencySynthesizer[];\n\tpublic get IFluidDependencySynthesizer() {\n\t\treturn this;\n\t}\n\n\tpublic constructor(...parents: (IFluidDependencySynthesizer | undefined)[]) {\n\t\tthis.parents = parents.filter((v): v is IFluidDependencySynthesizer => v !== undefined);\n\t}\n\n\t/**\n\t * Add a new provider\n\t * @param type - Name of the Type T being provided\n\t * @param provider - A provider that will resolve the T correctly when asked\n\t * @throws - If passing a type that's already registered\n\t */\n\tpublic register<T extends keyof TMap = keyof TMap>(\n\t\ttype: T,\n\t\tprovider: FluidObjectProvider<Pick<TMap, T>>,\n\t): void {\n\t\tif (this.providers.has(type)) {\n\t\t\tthrow new Error(\n\t\t\t\t`Attempting to register a provider of type ${String(type)} that already exists`,\n\t\t\t);\n\t\t}\n\n\t\tthis.providers.set(type, provider);\n\t}\n\n\t/**\n\t * Remove a provider\n\t * @param type - Name of the provider to remove\n\t */\n\tpublic unregister(type: keyof TMap): void {\n\t\tif (this.providers.has(type)) {\n\t\t\tthis.providers.delete(type);\n\t\t}\n\t}\n\n\t/**\n\t * {@inheritDoc (IFluidDependencySynthesizer:interface).synthesize}\n\t */\n\tpublic synthesize<O, R = undefined | Record<string, never>>(\n\t\toptionalTypes: FluidObjectSymbolProvider<O>,\n\t\trequiredTypes: Required<FluidObjectSymbolProvider<R>>,\n\t): AsyncFluidObjectProvider<O, R> {\n\t\tconst base: AsyncFluidObjectProvider<O, R> = {} as any;\n\t\tthis.generateRequired<R>(base, requiredTypes);\n\t\tthis.generateOptional<O>(base, optionalTypes);\n\t\tObject.defineProperty(base, IFluidDependencySynthesizer, { get: () => this });\n\t\treturn base;\n\t}\n\n\t/**\n\t * {@inheritDoc (IFluidDependencySynthesizer:interface).has}\n\t * @param excludeParents - If true, exclude checking parent registries\n\t */\n\tpublic has(type: string, excludeParents?: boolean): boolean {\n\t\tif (this.providers.has(type as keyof TMap)) {\n\t\t\treturn true;\n\t\t}\n\t\tif (excludeParents !== true) {\n\t\t\treturn this.parents.some((p: IFluidDependencySynthesizer) => p.has(type));\n\t\t}\n\t\treturn false;\n\t}\n\t/**\n\t * @deprecated Needed for backwards compatability.\n\t */\n\tprivate getProvider(provider: string & keyof TMap) {\n\t\t// this was removed, but some partners have trouble with back compat where they\n\t\t// use invalid patterns with FluidObject and IFluidDependencySynthesizer\n\t\t// this is just for back compat until those are removed\n\t\tif (this.has(provider)) {\n\t\t\tif (this.providers.has(provider)) {\n\t\t\t\treturn this.providers.get(provider);\n\t\t\t}\n\t\t\tfor (const parent of this.parents) {\n\t\t\t\tif (parent instanceof DependencyContainer) {\n\t\t\t\t\treturn parent.getProvider(provider);\n\t\t\t\t} else {\n\t\t\t\t\t// older implementations of the IFluidDependencySynthesizer exposed getProvider\n\t\t\t\t\tconst maybeGetProvider: { getProvider?(provider: string & keyof TMap) } =\n\t\t\t\t\t\tparent as any;\n\t\t\t\t\tif (maybeGetProvider?.getProvider !== undefined) {\n\t\t\t\t\t\treturn maybeGetProvider.getProvider(provider);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\tprivate generateRequired<T>(\n\t\tbase: AsyncRequiredFluidObjectProvider<T>,\n\t\ttypes: Required<FluidObjectSymbolProvider<T>>,\n\t) {\n\t\tif (types === undefined) {\n\t\t\treturn;\n\t\t}\n\t\tfor (const key of Object.keys(types) as unknown as (keyof TMap)[]) {\n\t\t\tconst provider = this.resolveProvider(key);\n\t\t\tif (provider === undefined) {\n\t\t\t\tthrow new Error(\n\t\t\t\t\t`Object attempted to be created without registered required provider ${String(\n\t\t\t\t\t\tkey,\n\t\t\t\t\t)}`,\n\t\t\t\t);\n\t\t\t}\n\t\t\tObject.defineProperty(base, key, provider);\n\t\t}\n\t}\n\n\tprivate generateOptional<T>(\n\t\tbase: AsyncOptionalFluidObjectProvider<T>,\n\t\ttypes: FluidObjectSymbolProvider<T>,\n\t) {\n\t\tif (types === undefined) {\n\t\t\treturn;\n\t\t}\n\t\tfor (const key of Object.keys(types) as unknown as (keyof TMap)[]) {\n\t\t\t// back-compat: in 0.56 we allow undefined in the types, but we didn't before\n\t\t\t// this will keep runtime back compat, eventually we should support undefined properties\n\t\t\t// rather than properties that return promises that resolve to undefined\n\t\t\tconst provider = this.resolveProvider(key) ?? { get: async () => undefined };\n\t\t\tObject.defineProperty(base, key, provider);\n\t\t}\n\t}\n\n\tprivate resolveProvider<T extends keyof TMap>(t: T): PropertyDescriptor | undefined {\n\t\t// If we have the provider return it\n\t\tconst provider = this.providers.get(t);\n\t\tif (provider === undefined) {\n\t\t\tfor (const parent of this.parents) {\n\t\t\t\t// eslint-disable-next-line @typescript-eslint/consistent-type-assertions\n\t\t\t\tconst sp = { [t]: t } as FluidObjectSymbolProvider<Pick<TMap, T>>;\n\t\t\t\tconst syn = parent.synthesize<Pick<TMap, T>, Record<string, unknown>>(sp, {});\n\t\t\t\tconst descriptor = Object.getOwnPropertyDescriptor(syn, t);\n\t\t\t\tif (descriptor !== undefined) {\n\t\t\t\t\treturn descriptor;\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn undefined;\n\t\t}\n\n\t\t// The double nested gets are required for lazy loading the provider resolution\n\t\tif (typeof provider === \"function\") {\n\t\t\treturn {\n\t\t\t\t// eslint-disable-next-line @typescript-eslint/promise-function-async\n\t\t\t\tget() {\n\t\t\t\t\tif (provider && typeof provider === \"function\") {\n\t\t\t\t\t\treturn Promise.resolve(this[IFluidDependencySynthesizer])\n\t\t\t\t\t\t\t.then(async (fds): Promise<any> => provider(fds))\n\t\t\t\t\t\t\t.then((p) => p?.[t]);\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t};\n\t\t}\n\t\treturn {\n\t\t\tget() {\n\t\t\t\tif (provider) {\n\t\t\t\t\treturn new LazyPromise(async () => {\n\t\t\t\t\t\treturn Promise.resolve(provider).then((p) => {\n\t\t\t\t\t\t\tif (p) {\n\t\t\t\t\t\t\t\treturn p[t];\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t});\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t},\n\t\t};\n\t}\n}\n"]}
|
|
1
|
+
{"version":3,"file":"dependencyContainer.mjs","sourceRoot":"","sources":["../src/dependencyContainer.ts"],"names":[],"mappings":"AAAA;;;GAGG;OAEI,EAAE,WAAW,EAAE,MAAM,4BAA4B;OAQjD,EAAE,2BAA2B,EAA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,QAAQ,IAAI,OAAO,QAAQ,KAAK,UAAU,EAAE;wBAC/C,OAAO,OAAO,CAAC,OAAO,CAAC,IAAI,CAAC,2BAA2B,CAAC,CAAC;6BACvD,IAAI,CAAC,KAAK,EAAE,GAAG,EAAgB,EAAE,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC;6BAChD,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC;qBACtB;gBACF,CAAC;aACD,CAAC;SACF;QACD,OAAO;YACN,GAAG;gBACF,IAAI,QAAQ,EAAE;oBACb,OAAO,IAAI,WAAW,CAAC,KAAK,IAAI,EAAE;wBACjC,OAAO,OAAO,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE;4BAC3C,IAAI,CAAC,EAAE;gCACN,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC;6BACZ;wBACF,CAAC,CAAC,CAAC;oBACJ,CAAC,CAAC,CAAC;iBACH;YACF,CAAC;SACD,CAAC;IACH,CAAC;CACD","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { LazyPromise } from \"@fluidframework/core-utils\";\nimport {\n\tAsyncFluidObjectProvider,\n\tFluidObjectSymbolProvider,\n\tFluidObjectProvider,\n\tAsyncOptionalFluidObjectProvider,\n\tAsyncRequiredFluidObjectProvider,\n} from \"./types\";\nimport { IFluidDependencySynthesizer } from \"./IFluidDependencySynthesizer\";\n\n/**\n * DependencyContainer is similar to a IoC Container. It takes providers and will\n * synthesize an object based on them when requested.\n * @alpha\n */\nexport class DependencyContainer<TMap> implements IFluidDependencySynthesizer {\n\tprivate readonly providers = new Map<keyof TMap, FluidObjectProvider<any>>();\n\tprivate readonly parents: IFluidDependencySynthesizer[];\n\tpublic get IFluidDependencySynthesizer() {\n\t\treturn this;\n\t}\n\n\tpublic constructor(...parents: (IFluidDependencySynthesizer | undefined)[]) {\n\t\tthis.parents = parents.filter((v): v is IFluidDependencySynthesizer => v !== undefined);\n\t}\n\n\t/**\n\t * Add a new provider\n\t * @param type - Name of the Type T being provided\n\t * @param provider - A provider that will resolve the T correctly when asked\n\t * @throws - If passing a type that's already registered\n\t */\n\tpublic register<T extends keyof TMap = keyof TMap>(\n\t\ttype: T,\n\t\tprovider: FluidObjectProvider<Pick<TMap, T>>,\n\t): void {\n\t\tif (this.providers.has(type)) {\n\t\t\tthrow new Error(\n\t\t\t\t`Attempting to register a provider of type ${String(type)} that already exists`,\n\t\t\t);\n\t\t}\n\n\t\tthis.providers.set(type, provider);\n\t}\n\n\t/**\n\t * Remove a provider\n\t * @param type - Name of the provider to remove\n\t */\n\tpublic unregister(type: keyof TMap): void {\n\t\tif (this.providers.has(type)) {\n\t\t\tthis.providers.delete(type);\n\t\t}\n\t}\n\n\t/**\n\t * {@inheritDoc (IFluidDependencySynthesizer:interface).synthesize}\n\t */\n\tpublic synthesize<O, R = undefined | Record<string, never>>(\n\t\toptionalTypes: FluidObjectSymbolProvider<O>,\n\t\trequiredTypes: Required<FluidObjectSymbolProvider<R>>,\n\t): AsyncFluidObjectProvider<O, R> {\n\t\tconst base: AsyncFluidObjectProvider<O, R> = {} as any;\n\t\tthis.generateRequired<R>(base, requiredTypes);\n\t\tthis.generateOptional<O>(base, optionalTypes);\n\t\tObject.defineProperty(base, IFluidDependencySynthesizer, { get: () => this });\n\t\treturn base;\n\t}\n\n\t/**\n\t * {@inheritDoc (IFluidDependencySynthesizer:interface).has}\n\t * @param excludeParents - If true, exclude checking parent registries\n\t */\n\tpublic has(type: string, excludeParents?: boolean): boolean {\n\t\tif (this.providers.has(type as keyof TMap)) {\n\t\t\treturn true;\n\t\t}\n\t\tif (excludeParents !== true) {\n\t\t\treturn this.parents.some((p: IFluidDependencySynthesizer) => p.has(type));\n\t\t}\n\t\treturn false;\n\t}\n\t/**\n\t * @deprecated Needed for backwards compatability.\n\t */\n\tprivate getProvider(provider: string & keyof TMap) {\n\t\t// this was removed, but some partners have trouble with back compat where they\n\t\t// use invalid patterns with FluidObject and IFluidDependencySynthesizer\n\t\t// this is just for back compat until those are removed\n\t\tif (this.has(provider)) {\n\t\t\tif (this.providers.has(provider)) {\n\t\t\t\treturn this.providers.get(provider);\n\t\t\t}\n\t\t\tfor (const parent of this.parents) {\n\t\t\t\tif (parent instanceof DependencyContainer) {\n\t\t\t\t\treturn parent.getProvider(provider);\n\t\t\t\t} else {\n\t\t\t\t\t// older implementations of the IFluidDependencySynthesizer exposed getProvider\n\t\t\t\t\tconst maybeGetProvider: { getProvider?(provider: string & keyof TMap) } =\n\t\t\t\t\t\tparent as any;\n\t\t\t\t\tif (maybeGetProvider?.getProvider !== undefined) {\n\t\t\t\t\t\treturn maybeGetProvider.getProvider(provider);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\tprivate generateRequired<T>(\n\t\tbase: AsyncRequiredFluidObjectProvider<T>,\n\t\ttypes: Required<FluidObjectSymbolProvider<T>>,\n\t) {\n\t\tif (types === undefined) {\n\t\t\treturn;\n\t\t}\n\t\tfor (const key of Object.keys(types) as unknown as (keyof TMap)[]) {\n\t\t\tconst provider = this.resolveProvider(key);\n\t\t\tif (provider === undefined) {\n\t\t\t\tthrow new Error(\n\t\t\t\t\t`Object attempted to be created without registered required provider ${String(\n\t\t\t\t\t\tkey,\n\t\t\t\t\t)}`,\n\t\t\t\t);\n\t\t\t}\n\t\t\tObject.defineProperty(base, key, provider);\n\t\t}\n\t}\n\n\tprivate generateOptional<T>(\n\t\tbase: AsyncOptionalFluidObjectProvider<T>,\n\t\ttypes: FluidObjectSymbolProvider<T>,\n\t) {\n\t\tif (types === undefined) {\n\t\t\treturn;\n\t\t}\n\t\tfor (const key of Object.keys(types) as unknown as (keyof TMap)[]) {\n\t\t\t// back-compat: in 0.56 we allow undefined in the types, but we didn't before\n\t\t\t// this will keep runtime back compat, eventually we should support undefined properties\n\t\t\t// rather than properties that return promises that resolve to undefined\n\t\t\tconst provider = this.resolveProvider(key) ?? { get: async () => undefined };\n\t\t\tObject.defineProperty(base, key, provider);\n\t\t}\n\t}\n\n\tprivate resolveProvider<T extends keyof TMap>(t: T): PropertyDescriptor | undefined {\n\t\t// If we have the provider return it\n\t\tconst provider = this.providers.get(t);\n\t\tif (provider === undefined) {\n\t\t\tfor (const parent of this.parents) {\n\t\t\t\t// eslint-disable-next-line @typescript-eslint/consistent-type-assertions\n\t\t\t\tconst sp = { [t]: t } as FluidObjectSymbolProvider<Pick<TMap, T>>;\n\t\t\t\tconst syn = parent.synthesize<Pick<TMap, T>, Record<string, unknown>>(sp, {});\n\t\t\t\tconst descriptor = Object.getOwnPropertyDescriptor(syn, t);\n\t\t\t\tif (descriptor !== undefined) {\n\t\t\t\t\treturn descriptor;\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn undefined;\n\t\t}\n\n\t\t// The double nested gets are required for lazy loading the provider resolution\n\t\tif (typeof provider === \"function\") {\n\t\t\treturn {\n\t\t\t\t// eslint-disable-next-line @typescript-eslint/promise-function-async\n\t\t\t\tget() {\n\t\t\t\t\tif (provider && typeof provider === \"function\") {\n\t\t\t\t\t\treturn Promise.resolve(this[IFluidDependencySynthesizer])\n\t\t\t\t\t\t\t.then(async (fds): Promise<any> => provider(fds))\n\t\t\t\t\t\t\t.then((p) => p?.[t]);\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t};\n\t\t}\n\t\treturn {\n\t\t\tget() {\n\t\t\t\tif (provider) {\n\t\t\t\t\treturn new LazyPromise(async () => {\n\t\t\t\t\t\treturn Promise.resolve(provider).then((p) => {\n\t\t\t\t\t\t\tif (p) {\n\t\t\t\t\t\t\t\treturn p[t];\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t});\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t},\n\t\t};\n\t}\n}\n"]}
|
|
@@ -5,4 +5,4 @@
|
|
|
5
5
|
export { DependencyContainer } from "./dependencyContainer.mjs";
|
|
6
6
|
export { IFluidDependencySynthesizer, IProvideFluidDependencySynthesizer, } from "./IFluidDependencySynthesizer.mjs";
|
|
7
7
|
export { AsyncFluidObjectProvider, AsyncOptionalFluidObjectProvider, AsyncRequiredFluidObjectProvider, FluidObjectProvider, FluidObjectSymbolProvider, } from "./types.mjs";
|
|
8
|
-
//# sourceMappingURL=index.d.
|
|
8
|
+
//# sourceMappingURL=index.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.mts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;OAEI,EAAE,mBAAmB,EAAE;OACvB,EACN,2BAA2B,EAC3B,kCAAkC,GAClC;OACM,EACN,wBAAwB,EACxB,gCAAgC,EAChC,gCAAgC,EAChC,mBAAmB,EACnB,yBAAyB,GACzB"}
|
|
@@ -27,7 +27,7 @@ export declare type AsyncRequiredFluidObjectProvider<T> = T extends undefined ?
|
|
|
27
27
|
/**
|
|
28
28
|
* DependencyContainer is similar to a IoC Container. It takes providers and will
|
|
29
29
|
* synthesize an object based on them when requested.
|
|
30
|
-
* @
|
|
30
|
+
* @alpha
|
|
31
31
|
*/
|
|
32
32
|
export declare class DependencyContainer<TMap> implements IFluidDependencySynthesizer {
|
|
33
33
|
private readonly providers;
|
|
@@ -66,7 +66,7 @@ export declare class DependencyContainer<TMap> implements IFluidDependencySynthe
|
|
|
66
66
|
|
|
67
67
|
/**
|
|
68
68
|
* Multiple ways to provide a Fluid object.
|
|
69
|
-
* @
|
|
69
|
+
* @alpha
|
|
70
70
|
*/
|
|
71
71
|
export declare type FluidObjectProvider<T> = NonNullable<T> | Promise<NonNullable<T>> | ((dependencyContainer: IFluidDependencySynthesizer) => NonNullable<T>) | ((dependencyContainer: IFluidDependencySynthesizer) => Promise<NonNullable<T>>);
|
|
72
72
|
|
|
@@ -24,9 +24,51 @@ export declare type AsyncRequiredFluidObjectProvider<T> = T extends undefined ?
|
|
|
24
24
|
[P in keyof T]: Promise<NonNullable<Exclude<T[P], undefined | null>>>;
|
|
25
25
|
};
|
|
26
26
|
|
|
27
|
-
|
|
27
|
+
/**
|
|
28
|
+
* DependencyContainer is similar to a IoC Container. It takes providers and will
|
|
29
|
+
* synthesize an object based on them when requested.
|
|
30
|
+
* @alpha
|
|
31
|
+
*/
|
|
32
|
+
export declare class DependencyContainer<TMap> implements IFluidDependencySynthesizer {
|
|
33
|
+
private readonly providers;
|
|
34
|
+
private readonly parents;
|
|
35
|
+
get IFluidDependencySynthesizer(): this;
|
|
36
|
+
constructor(...parents: (IFluidDependencySynthesizer | undefined)[]);
|
|
37
|
+
/**
|
|
38
|
+
* Add a new provider
|
|
39
|
+
* @param type - Name of the Type T being provided
|
|
40
|
+
* @param provider - A provider that will resolve the T correctly when asked
|
|
41
|
+
* @throws - If passing a type that's already registered
|
|
42
|
+
*/
|
|
43
|
+
register<T extends keyof TMap = keyof TMap>(type: T, provider: FluidObjectProvider<Pick<TMap, T>>): void;
|
|
44
|
+
/**
|
|
45
|
+
* Remove a provider
|
|
46
|
+
* @param type - Name of the provider to remove
|
|
47
|
+
*/
|
|
48
|
+
unregister(type: keyof TMap): void;
|
|
49
|
+
/**
|
|
50
|
+
* {@inheritDoc (IFluidDependencySynthesizer:interface).synthesize}
|
|
51
|
+
*/
|
|
52
|
+
synthesize<O, R = undefined | Record<string, never>>(optionalTypes: FluidObjectSymbolProvider<O>, requiredTypes: Required<FluidObjectSymbolProvider<R>>): AsyncFluidObjectProvider<O, R>;
|
|
53
|
+
/**
|
|
54
|
+
* {@inheritDoc (IFluidDependencySynthesizer:interface).has}
|
|
55
|
+
* @param excludeParents - If true, exclude checking parent registries
|
|
56
|
+
*/
|
|
57
|
+
has(type: string, excludeParents?: boolean): boolean;
|
|
58
|
+
/**
|
|
59
|
+
* @deprecated Needed for backwards compatability.
|
|
60
|
+
*/
|
|
61
|
+
private getProvider;
|
|
62
|
+
private generateRequired;
|
|
63
|
+
private generateOptional;
|
|
64
|
+
private resolveProvider;
|
|
65
|
+
}
|
|
28
66
|
|
|
29
|
-
|
|
67
|
+
/**
|
|
68
|
+
* Multiple ways to provide a Fluid object.
|
|
69
|
+
* @alpha
|
|
70
|
+
*/
|
|
71
|
+
export declare type FluidObjectProvider<T> = NonNullable<T> | Promise<NonNullable<T>> | ((dependencyContainer: IFluidDependencySynthesizer) => NonNullable<T>) | ((dependencyContainer: IFluidDependencySynthesizer) => Promise<NonNullable<T>>);
|
|
30
72
|
|
|
31
73
|
/**
|
|
32
74
|
* This is a condensed version of Record that requires the object has all
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { IFluidDependencySynthesizer } from ".";
|
|
1
|
+
import { IFluidDependencySynthesizer } from "./IFluidDependencySynthesizer.mjs";
|
|
2
2
|
/**
|
|
3
3
|
* This is a condensed version of Record that requires the object has all
|
|
4
4
|
* the FluidObject properties as its type mapped to a string representation
|
|
@@ -39,7 +39,7 @@ export type AsyncOptionalFluidObjectProvider<T> = T extends undefined ? Record<s
|
|
|
39
39
|
export type AsyncFluidObjectProvider<O, R = undefined> = AsyncOptionalFluidObjectProvider<O> & AsyncRequiredFluidObjectProvider<R>;
|
|
40
40
|
/**
|
|
41
41
|
* Multiple ways to provide a Fluid object.
|
|
42
|
-
* @
|
|
42
|
+
* @alpha
|
|
43
43
|
*/
|
|
44
44
|
export type FluidObjectProvider<T> = NonNullable<T> | Promise<NonNullable<T>> | ((dependencyContainer: IFluidDependencySynthesizer) => NonNullable<T>) | ((dependencyContainer: IFluidDependencySynthesizer) => Promise<NonNullable<T>>);
|
|
45
|
-
//# sourceMappingURL=types.d.
|
|
45
|
+
//# sourceMappingURL=types.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.mts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"OAIO,EAAE,2BAA2B,EAAE;AAEtC;;;;;;;;;;;GAWG;AACH,MAAM,MAAM,yBAAyB,CAAC,CAAC,IAAI;KACzC,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC;CAClB,CAAC;AAEF;;;;;GAKG;AACH,MAAM,MAAM,gCAAgC,CAAC,CAAC,IAAI,CAAC,SAAS,SAAS,GAClE,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,GACrB;KACC,CAAC,IAAI,MAAM,CAAC,GAAG,OAAO,CAAC,WAAW,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,SAAS,GAAG,IAAI,CAAC,CAAC,CAAC;CACpE,CAAC;AAEL;;;;;GAKG;AACH,MAAM,MAAM,gCAAgC,CAAC,CAAC,IAAI,CAAC,SAAS,SAAS,GAClE,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,GACrB;KACC,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,EAAE,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,SAAS,CAAC;CACzC,CAAC;AAEL;;;GAGG;AACH,MAAM,MAAM,wBAAwB,CAAC,CAAC,EAAE,CAAC,GAAG,SAAS,IAAI,gCAAgC,CAAC,CAAC,CAAC,GAC3F,gCAAgC,CAAC,CAAC,CAAC,CAAC;AAErC;;;GAGG;AACH,MAAM,MAAM,mBAAmB,CAAC,CAAC,IAC9B,WAAW,CAAC,CAAC,CAAC,GACd,OAAO,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,GACvB,CAAC,CAAC,mBAAmB,EAAE,2BAA2B,KAAK,WAAW,CAAC,CAAC,CAAC,CAAC,GACtE,CAAC,CAAC,mBAAmB,EAAE,2BAA2B,KAAK,OAAO,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC"}
|
package/lib/types.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.mjs","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\nimport { IFluidDependencySynthesizer } from \"
|
|
1
|
+
{"version":3,"file":"types.mjs","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\nimport { IFluidDependencySynthesizer } from \"./IFluidDependencySynthesizer\";\n\n/**\n * This is a condensed version of Record that requires the object has all\n * the FluidObject properties as its type mapped to a string representation\n * of that property.\n *\n * @example\n *\n * ```typescript\n * { IFoo: \"IFoo\" }\n * ```\n * @alpha\n */\nexport type FluidObjectSymbolProvider<T> = {\n\t[P in keyof T]?: P;\n};\n\n/**\n * This is a condensed version of Record that requires the object has all\n * the FluidObject properties as its type mapped to an object that implements\n * the property.\n * @alpha\n */\nexport type AsyncRequiredFluidObjectProvider<T> = T extends undefined\n\t? Record<string, never>\n\t: {\n\t\t\t[P in keyof T]: Promise<NonNullable<Exclude<T[P], undefined | null>>>;\n\t };\n\n/**\n * This is a condensed version of Record that requires the object has all\n * the FluidObject properties as its type, mapped to an object that implements\n * the property or undefined.\n * @alpha\n */\nexport type AsyncOptionalFluidObjectProvider<T> = T extends undefined\n\t? Record<string, never>\n\t: {\n\t\t\t[P in keyof T]?: Promise<T[P] | undefined>;\n\t };\n\n/**\n * Combined type for Optional and Required Async Fluid object Providers\n * @alpha\n */\nexport type AsyncFluidObjectProvider<O, R = undefined> = AsyncOptionalFluidObjectProvider<O> &\n\tAsyncRequiredFluidObjectProvider<R>;\n\n/**\n * Multiple ways to provide a Fluid object.\n * @alpha\n */\nexport type FluidObjectProvider<T> =\n\t| NonNullable<T>\n\t| Promise<NonNullable<T>>\n\t| ((dependencyContainer: IFluidDependencySynthesizer) => NonNullable<T>)\n\t| ((dependencyContainer: IFluidDependencySynthesizer) => Promise<NonNullable<T>>);\n"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fluidframework/synthesize",
|
|
3
|
-
"version": "2.0.0-
|
|
3
|
+
"version": "2.0.0-rc.1.0.0",
|
|
4
4
|
"description": "A library for synthesizing scope objects.",
|
|
5
5
|
"homepage": "https://fluidframework.com",
|
|
6
6
|
"repository": {
|
|
@@ -11,7 +11,59 @@
|
|
|
11
11
|
"license": "MIT",
|
|
12
12
|
"author": "Microsoft and contributors",
|
|
13
13
|
"sideEffects": false,
|
|
14
|
-
"
|
|
14
|
+
"exports": {
|
|
15
|
+
".": {
|
|
16
|
+
"import": {
|
|
17
|
+
"types": "./lib/index.d.mts",
|
|
18
|
+
"default": "./lib/index.mjs"
|
|
19
|
+
},
|
|
20
|
+
"require": {
|
|
21
|
+
"types": "./dist/index.d.ts",
|
|
22
|
+
"default": "./dist/index.js"
|
|
23
|
+
}
|
|
24
|
+
},
|
|
25
|
+
"./alpha": {
|
|
26
|
+
"import": {
|
|
27
|
+
"types": "./lib/synthesize-alpha.d.mts",
|
|
28
|
+
"default": "./lib/index.mjs"
|
|
29
|
+
},
|
|
30
|
+
"require": {
|
|
31
|
+
"types": "./dist/synthesize-alpha.d.ts",
|
|
32
|
+
"default": "./dist/index.js"
|
|
33
|
+
}
|
|
34
|
+
},
|
|
35
|
+
"./beta": {
|
|
36
|
+
"import": {
|
|
37
|
+
"types": "./lib/synthesize-beta.d.mts",
|
|
38
|
+
"default": "./lib/index.mjs"
|
|
39
|
+
},
|
|
40
|
+
"require": {
|
|
41
|
+
"types": "./dist/synthesize-beta.d.ts",
|
|
42
|
+
"default": "./dist/index.js"
|
|
43
|
+
}
|
|
44
|
+
},
|
|
45
|
+
"./internal": {
|
|
46
|
+
"import": {
|
|
47
|
+
"types": "./lib/index.d.mts",
|
|
48
|
+
"default": "./lib/index.mjs"
|
|
49
|
+
},
|
|
50
|
+
"require": {
|
|
51
|
+
"types": "./dist/index.d.ts",
|
|
52
|
+
"default": "./dist/index.js"
|
|
53
|
+
}
|
|
54
|
+
},
|
|
55
|
+
"./public": {
|
|
56
|
+
"import": {
|
|
57
|
+
"types": "./lib/synthesize-public.d.mts",
|
|
58
|
+
"default": "./lib/index.mjs"
|
|
59
|
+
},
|
|
60
|
+
"require": {
|
|
61
|
+
"types": "./dist/synthesize-public.d.ts",
|
|
62
|
+
"default": "./dist/index.js"
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
},
|
|
66
|
+
"main": "dist/index.js",
|
|
15
67
|
"module": "lib/index.mjs",
|
|
16
68
|
"types": "dist/index.d.ts",
|
|
17
69
|
"files": [
|
|
@@ -22,13 +74,13 @@
|
|
|
22
74
|
"all": true,
|
|
23
75
|
"cache-dir": "nyc/.cache",
|
|
24
76
|
"exclude": [
|
|
25
|
-
"src/test
|
|
26
|
-
"dist/test
|
|
77
|
+
"src/test/**/*.*ts",
|
|
78
|
+
"dist/test/**/*.*js"
|
|
27
79
|
],
|
|
28
80
|
"exclude-after-remap": false,
|
|
29
81
|
"include": [
|
|
30
|
-
"src
|
|
31
|
-
"dist
|
|
82
|
+
"src/**/*.*ts",
|
|
83
|
+
"dist/**/*.*js"
|
|
32
84
|
],
|
|
33
85
|
"report-dir": "nyc/report",
|
|
34
86
|
"reporter": [
|
|
@@ -39,22 +91,22 @@
|
|
|
39
91
|
"temp-directory": "nyc/.nyc_output"
|
|
40
92
|
},
|
|
41
93
|
"dependencies": {
|
|
42
|
-
"@fluidframework/core-utils": ">=2.0.0-
|
|
94
|
+
"@fluidframework/core-utils": ">=2.0.0-rc.1.0.0 <2.0.0-rc.1.1.0"
|
|
43
95
|
},
|
|
44
96
|
"devDependencies": {
|
|
45
97
|
"@arethetypeswrong/cli": "^0.13.3",
|
|
46
|
-
"@fluid-tools/build-cli": "^0.
|
|
98
|
+
"@fluid-tools/build-cli": "^0.29.0",
|
|
47
99
|
"@fluidframework/build-common": "^2.0.3",
|
|
48
|
-
"@fluidframework/build-tools": "^0.
|
|
49
|
-
"@fluidframework/core-interfaces": ">=2.0.0-
|
|
50
|
-
"@fluidframework/datastore": ">=2.0.0-
|
|
51
|
-
"@fluidframework/eslint-config-fluid": "^3.
|
|
52
|
-
"@fluidframework/mocha-test-setup": ">=2.0.0-
|
|
53
|
-
"@fluidframework/synthesize-previous": "npm:@fluidframework/synthesize@2.0.0-internal.
|
|
100
|
+
"@fluidframework/build-tools": "^0.29.0",
|
|
101
|
+
"@fluidframework/core-interfaces": ">=2.0.0-rc.1.0.0 <2.0.0-rc.1.1.0",
|
|
102
|
+
"@fluidframework/datastore": ">=2.0.0-rc.1.0.0 <2.0.0-rc.1.1.0",
|
|
103
|
+
"@fluidframework/eslint-config-fluid": "^3.2.0",
|
|
104
|
+
"@fluidframework/mocha-test-setup": ">=2.0.0-rc.1.0.0 <2.0.0-rc.1.1.0",
|
|
105
|
+
"@fluidframework/synthesize-previous": "npm:@fluidframework/synthesize@2.0.0-internal.8.0.0",
|
|
54
106
|
"@microsoft/api-extractor": "^7.38.3",
|
|
55
107
|
"@types/mocha": "^9.1.1",
|
|
56
108
|
"@types/node": "^18.19.0",
|
|
57
|
-
"c8": "^
|
|
109
|
+
"c8": "^8.0.1",
|
|
58
110
|
"copyfiles": "^2.4.1",
|
|
59
111
|
"cross-env": "^7.0.3",
|
|
60
112
|
"eslint": "~8.50.0",
|
|
@@ -85,14 +137,14 @@
|
|
|
85
137
|
"scripts": {
|
|
86
138
|
"api": "fluid-build . --task api",
|
|
87
139
|
"api-extractor:commonjs": "api-extractor run --local",
|
|
88
|
-
"api-extractor:esnext": "
|
|
140
|
+
"api-extractor:esnext": "api-extractor run --config ./api-extractor-esm.json",
|
|
89
141
|
"build": "fluid-build . --task build",
|
|
90
142
|
"build:commonjs": "fluid-build . --task commonjs",
|
|
91
143
|
"build:compile": "fluid-build . --task compile",
|
|
92
144
|
"build:docs": "fluid-build . --task api",
|
|
93
145
|
"build:esnext": "tsc-multi --config ../../../common/build/build-common/tsc-multi.esm.json",
|
|
94
|
-
"build:test": "tsc
|
|
95
|
-
"check:are-the-types-wrong": "attw --pack",
|
|
146
|
+
"build:test": "tsc --project ./src/test/tsconfig.json",
|
|
147
|
+
"check:are-the-types-wrong": "attw --pack . --entrypoints .",
|
|
96
148
|
"check:release-tags": "api-extractor run --local --config ./api-extractor-lint.json",
|
|
97
149
|
"ci:build:docs": "api-extractor run",
|
|
98
150
|
"clean": "rimraf --glob dist lib \"**/*.tsbuildinfo\" \"**/*.build.log\" _api-extractor-temp nyc",
|
|
@@ -107,7 +159,7 @@
|
|
|
107
159
|
"test:coverage": "c8 npm test",
|
|
108
160
|
"test:mocha": "mocha --ignore \"dist/test/types/*\" --recursive dist/test -r node_modules/@fluidframework/mocha-test-setup",
|
|
109
161
|
"test:mocha:verbose": "cross-env FLUID_TEST_VERBOSE=1 npm run test:mocha",
|
|
110
|
-
"tsc": "tsc
|
|
162
|
+
"tsc": "tsc",
|
|
111
163
|
"typetests:gen": "fluid-type-test-generator",
|
|
112
164
|
"typetests:prepare": "flub typetests --dir . --reset --previous --normalize"
|
|
113
165
|
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"IFluidDependencySynthesizer.cjs","sourceRoot":"","sources":["../src/IFluidDependencySynthesizer.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAIH;;GAEG;AACU,QAAA,2BAA2B,GACvC,6BAA6B,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { AsyncFluidObjectProvider, FluidObjectSymbolProvider } from \"./types\";\n\n/**\n * @alpha\n */\nexport const IFluidDependencySynthesizer: keyof IProvideFluidDependencySynthesizer =\n\t\"IFluidDependencySynthesizer\";\n\n/**\n * @alpha\n */\nexport interface IProvideFluidDependencySynthesizer {\n\tIFluidDependencySynthesizer: IFluidDependencySynthesizer;\n}\n\n/**\n * IFluidDependencySynthesizer can generate FluidObjects based on the IProvideFluidObject pattern.\n * It allow for registering providers and uses synthesize to generate a new object with the optional\n * and required types.\n * @alpha\n */\nexport interface IFluidDependencySynthesizer extends IProvideFluidDependencySynthesizer {\n\t/**\n\t * synthesize takes optional and required types and returns an object that will fulfill the\n\t * defined types based off objects that has been previously registered.\n\t *\n\t * @param optionalTypes - optional types to be in the Scope object\n\t * @param requiredTypes - required types that need to be in the Scope object\n\t */\n\tsynthesize<O, R = undefined | Record<string, never>>(\n\t\toptionalTypes: FluidObjectSymbolProvider<O>,\n\t\trequiredTypes: Required<FluidObjectSymbolProvider<R>>,\n\t): AsyncFluidObjectProvider<O, R>;\n\n\t/**\n\t * Check if a given type is registered\n\t * @param type - Type to check\n\t */\n\thas(type: string): boolean;\n}\n"]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"dependencyContainer.cjs","sourceRoot":"","sources":["../src/dependencyContainer.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAEH,2DAAyD;AAQzD,mFAA4E;AAE5E;;;;GAIG;AACH,MAAa,mBAAmB;IAG/B,IAAW,2BAA2B;QACrC,OAAO,IAAI,CAAC;IACb,CAAC;IAED,YAAmB,GAAG,OAAoD;QANzD,cAAS,GAAG,IAAI,GAAG,EAAwC,CAAC;QAO5E,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC,CAAC,EAAoC,EAAE,CAAC,CAAC,KAAK,SAAS,CAAC,CAAC;IACzF,CAAC;IAED;;;;;OAKG;IACI,QAAQ,CACd,IAAO,EACP,QAA4C;QAE5C,IAAI,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,IAAI,CAAC,EAAE;YAC7B,MAAM,IAAI,KAAK,CACd,6CAA6C,MAAM,CAAC,IAAI,CAAC,sBAAsB,CAC/E,CAAC;SACF;QAED,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,IAAI,EAAE,QAAQ,CAAC,CAAC;IACpC,CAAC;IAED;;;OAGG;IACI,UAAU,CAAC,IAAgB;QACjC,IAAI,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,IAAI,CAAC,EAAE;YAC7B,IAAI,CAAC,SAAS,CAAC,MAAM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Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { LazyPromise } from \"@fluidframework/core-utils\";\nimport {\n\tAsyncFluidObjectProvider,\n\tFluidObjectSymbolProvider,\n\tFluidObjectProvider,\n\tAsyncOptionalFluidObjectProvider,\n\tAsyncRequiredFluidObjectProvider,\n} from \"./types\";\nimport { IFluidDependencySynthesizer } from \"./IFluidDependencySynthesizer\";\n\n/**\n * DependencyContainer is similar to a IoC Container. It takes providers and will\n * synthesize an object based on them when requested.\n * @internal\n */\nexport class DependencyContainer<TMap> implements IFluidDependencySynthesizer {\n\tprivate readonly providers = new Map<keyof TMap, FluidObjectProvider<any>>();\n\tprivate readonly parents: IFluidDependencySynthesizer[];\n\tpublic get IFluidDependencySynthesizer() {\n\t\treturn this;\n\t}\n\n\tpublic constructor(...parents: (IFluidDependencySynthesizer | undefined)[]) {\n\t\tthis.parents = parents.filter((v): v is IFluidDependencySynthesizer => v !== undefined);\n\t}\n\n\t/**\n\t * Add a new provider\n\t * @param type - Name of the Type T being provided\n\t * @param provider - A provider that will resolve the T correctly when asked\n\t * @throws - If passing a type that's already registered\n\t */\n\tpublic register<T extends keyof TMap = keyof TMap>(\n\t\ttype: T,\n\t\tprovider: FluidObjectProvider<Pick<TMap, T>>,\n\t): void {\n\t\tif (this.providers.has(type)) {\n\t\t\tthrow new Error(\n\t\t\t\t`Attempting to register a provider of type ${String(type)} that already exists`,\n\t\t\t);\n\t\t}\n\n\t\tthis.providers.set(type, provider);\n\t}\n\n\t/**\n\t * Remove a provider\n\t * @param type - Name of the provider to remove\n\t */\n\tpublic unregister(type: keyof TMap): void {\n\t\tif (this.providers.has(type)) {\n\t\t\tthis.providers.delete(type);\n\t\t}\n\t}\n\n\t/**\n\t * {@inheritDoc (IFluidDependencySynthesizer:interface).synthesize}\n\t */\n\tpublic synthesize<O, R = undefined | Record<string, never>>(\n\t\toptionalTypes: FluidObjectSymbolProvider<O>,\n\t\trequiredTypes: Required<FluidObjectSymbolProvider<R>>,\n\t): AsyncFluidObjectProvider<O, R> {\n\t\tconst base: AsyncFluidObjectProvider<O, R> = {} as any;\n\t\tthis.generateRequired<R>(base, requiredTypes);\n\t\tthis.generateOptional<O>(base, optionalTypes);\n\t\tObject.defineProperty(base, IFluidDependencySynthesizer, { get: () => this });\n\t\treturn base;\n\t}\n\n\t/**\n\t * {@inheritDoc (IFluidDependencySynthesizer:interface).has}\n\t * @param excludeParents - If true, exclude checking parent registries\n\t */\n\tpublic has(type: string, excludeParents?: boolean): boolean {\n\t\tif (this.providers.has(type as keyof TMap)) {\n\t\t\treturn true;\n\t\t}\n\t\tif (excludeParents !== true) {\n\t\t\treturn this.parents.some((p: IFluidDependencySynthesizer) => p.has(type));\n\t\t}\n\t\treturn false;\n\t}\n\t/**\n\t * @deprecated Needed for backwards compatability.\n\t */\n\tprivate getProvider(provider: string & keyof TMap) {\n\t\t// this was removed, but some partners have trouble with back compat where they\n\t\t// use invalid patterns with FluidObject and IFluidDependencySynthesizer\n\t\t// this is just for back compat until those are removed\n\t\tif (this.has(provider)) {\n\t\t\tif (this.providers.has(provider)) {\n\t\t\t\treturn this.providers.get(provider);\n\t\t\t}\n\t\t\tfor (const parent of this.parents) {\n\t\t\t\tif (parent instanceof DependencyContainer) {\n\t\t\t\t\treturn parent.getProvider(provider);\n\t\t\t\t} else {\n\t\t\t\t\t// older implementations of the IFluidDependencySynthesizer exposed getProvider\n\t\t\t\t\tconst maybeGetProvider: { getProvider?(provider: string & keyof TMap) } =\n\t\t\t\t\t\tparent as any;\n\t\t\t\t\tif (maybeGetProvider?.getProvider !== undefined) {\n\t\t\t\t\t\treturn maybeGetProvider.getProvider(provider);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\tprivate generateRequired<T>(\n\t\tbase: AsyncRequiredFluidObjectProvider<T>,\n\t\ttypes: Required<FluidObjectSymbolProvider<T>>,\n\t) {\n\t\tif (types === undefined) {\n\t\t\treturn;\n\t\t}\n\t\tfor (const key of Object.keys(types) as unknown as (keyof TMap)[]) {\n\t\t\tconst provider = this.resolveProvider(key);\n\t\t\tif (provider === undefined) {\n\t\t\t\tthrow new Error(\n\t\t\t\t\t`Object attempted to be created without registered required provider ${String(\n\t\t\t\t\t\tkey,\n\t\t\t\t\t)}`,\n\t\t\t\t);\n\t\t\t}\n\t\t\tObject.defineProperty(base, key, provider);\n\t\t}\n\t}\n\n\tprivate generateOptional<T>(\n\t\tbase: AsyncOptionalFluidObjectProvider<T>,\n\t\ttypes: FluidObjectSymbolProvider<T>,\n\t) {\n\t\tif (types === undefined) {\n\t\t\treturn;\n\t\t}\n\t\tfor (const key of Object.keys(types) as unknown as (keyof TMap)[]) {\n\t\t\t// back-compat: in 0.56 we allow undefined in the types, but we didn't before\n\t\t\t// this will keep runtime back compat, eventually we should support undefined properties\n\t\t\t// rather than properties that return promises that resolve to undefined\n\t\t\tconst provider = this.resolveProvider(key) ?? { get: async () => undefined };\n\t\t\tObject.defineProperty(base, key, provider);\n\t\t}\n\t}\n\n\tprivate resolveProvider<T extends keyof TMap>(t: T): PropertyDescriptor | undefined {\n\t\t// If we have the provider return it\n\t\tconst provider = this.providers.get(t);\n\t\tif (provider === undefined) {\n\t\t\tfor (const parent of this.parents) {\n\t\t\t\t// eslint-disable-next-line @typescript-eslint/consistent-type-assertions\n\t\t\t\tconst sp = { [t]: t } as FluidObjectSymbolProvider<Pick<TMap, T>>;\n\t\t\t\tconst syn = parent.synthesize<Pick<TMap, T>, Record<string, unknown>>(sp, {});\n\t\t\t\tconst descriptor = Object.getOwnPropertyDescriptor(syn, t);\n\t\t\t\tif (descriptor !== undefined) {\n\t\t\t\t\treturn descriptor;\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn undefined;\n\t\t}\n\n\t\t// The double nested gets are required for lazy loading the provider resolution\n\t\tif (typeof provider === \"function\") {\n\t\t\treturn {\n\t\t\t\t// eslint-disable-next-line @typescript-eslint/promise-function-async\n\t\t\t\tget() {\n\t\t\t\t\tif (provider && typeof provider === \"function\") {\n\t\t\t\t\t\treturn Promise.resolve(this[IFluidDependencySynthesizer])\n\t\t\t\t\t\t\t.then(async (fds): Promise<any> => provider(fds))\n\t\t\t\t\t\t\t.then((p) => p?.[t]);\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t};\n\t\t}\n\t\treturn {\n\t\t\tget() {\n\t\t\t\tif (provider) {\n\t\t\t\t\treturn new LazyPromise(async () => {\n\t\t\t\t\t\treturn Promise.resolve(provider).then((p) => {\n\t\t\t\t\t\t\tif (p) {\n\t\t\t\t\t\t\t\treturn p[t];\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t});\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t},\n\t\t};\n\t}\n}\n"]}
|
package/dist/index.cjs.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAEH,iEAA4D;AAAnD,0HAAA,mBAAmB,OAAA;AAC5B,iFAGuC;AAFtC,0IAAA,2BAA2B,OAAA","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nexport { DependencyContainer } from \"./dependencyContainer\";\nexport {\n\tIFluidDependencySynthesizer,\n\tIProvideFluidDependencySynthesizer,\n} from \"./IFluidDependencySynthesizer\";\nexport {\n\tAsyncFluidObjectProvider,\n\tAsyncOptionalFluidObjectProvider,\n\tAsyncRequiredFluidObjectProvider,\n\tFluidObjectProvider,\n\tFluidObjectSymbolProvider,\n} from \"./types\";\n"]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"dependencyContainer.spec.cjs","sourceRoot":"","sources":["../../src/test/dependencyContainer.spec.ts"],"names":[],"mappings":";AAAA;;;GAGG;;AAEH,mCAA0C;AAE1C,qEAOyC;AACzC,yDAA8D;AAE9D,2DAAyD;AACzD,wCAA+C;AAI/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IAAI,QAAQ,CAA8B,EAAE,CAAC,CAAC,EACtE,oBAAoB,CACpB,CAAC;YACH,CAAC,CAAC,CAAC;QACJ,CAAC,CAAC,CAAC;IACJ,CAAC,CAAC,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,MAAM,QAAQ;IACb,YAA6B,MAAmC;QAAnC,WAAM,GAAN,MAAM,CAA6B;QAUvD,gCAA2B,GAAG,IAAI,CAAC;IAVuB,CAAC;IACpE,UAAU,CACT,aAA2C,EAC3C,aAAqD;QAErD,OAAO,IAAI,CAAC,MAAM,CAAC,UAAU,CAAC,aAAa,EAAE,aAAa,CAAC,CAAC;IAC7D,CAAC;IACD,GAAG,CAAC,IAAY;QACf,OAAO,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC;IAC9B,CAAC;IAGD,WAAW,CAAuB,GAAM;QACvC,MAAM,KAAK,GAAG,IAAI,CAAC,MAA8B,CAAC;QAClD,IAAI,KAAK,CAAC,WAAW,EAAE;YACtB,OAAO,KAAK,CAAC,WAAW,CAAC,GAAG,CAAC,CAAC;SAC9B;IACF,CAAC;CACD","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { strict as assert } from \"assert\";\n\nimport {\n\tIFluidLoadable,\n\tIFluidHandleContext,\n\tIFluidHandle,\n\tIProvideFluidLoadable,\n\tIProvideFluidHandle,\n\tFluidObject,\n} from \"@fluidframework/core-interfaces\";\nimport { FluidObjectHandle } from \"@fluidframework/datastore\";\n\nimport { LazyPromise } from \"@fluidframework/core-utils\";\nimport { DependencyContainer } from \"../index\";\nimport { IFluidDependencySynthesizer } from \"../IFluidDependencySynthesizer\";\nimport { AsyncFluidObjectProvider, FluidObjectProvider, FluidObjectSymbolProvider } from \"../types\";\n\nconst mockHandleContext: IFluidHandleContext = {\n\tabsolutePath: \"\",\n\tisAttached: false,\n\tIFluidHandleContext: undefined as any,\n\n\tattachGraph: () => {\n\t\tthrow new Error(\"Method not implemented.\");\n\t},\n\tresolveHandle: () => {\n\t\tthrow new Error(\"Method not implemented.\");\n\t},\n};\n\nclass MockLoadable implements IFluidLoadable {\n\tpublic get IFluidLoadable() {\n\t\treturn this;\n\t}\n\tpublic get handle() {\n\t\treturn new FluidObjectHandle(this, \"\", mockHandleContext);\n\t}\n}\n\nconst ISomeObject: keyof IProvideSomeObject = \"ISomeObject\";\ninterface IProvideSomeObject {\n\treadonly ISomeObject: ISomeObject;\n}\ninterface ISomeObject extends IProvideSomeObject {\n\tvalue: number;\n}\nclass MockSomeObject implements ISomeObject {\n\tpublic get ISomeObject() {\n\t\treturn this;\n\t}\n\tpublic readonly value = 0;\n}\n\ndescribe(\"someObjectlicious\", () => {\n\tdescribe(\"Aqueduct\", () => {\n\t\tdescribe(\"DependencyContainer\", () => {\n\t\t\tit(`One Optional Provider registered via value`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tconst mock = new MockLoadable();\n\t\t\t\tdc.register(IFluidLoadable, mock);\n\n\t\t\t\tconst s = dc.synthesize<IFluidLoadable>({ IFluidLoadable }, undefined);\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Optional IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === mock, \"IFluidLoadable is expected\");\n\t\t\t\tassert(\n\t\t\t\t\tloadable?.handle.absolutePath === mock.handle.absolutePath,\n\t\t\t\t\t\"IFluidLoadable is valid\",\n\t\t\t\t);\n\t\t\t});\n\n\t\t\tit(`One Optional Provider registered via Promise value`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tconst mock = new MockLoadable();\n\t\t\t\tdc.register(IFluidLoadable, Promise.resolve(mock));\n\n\t\t\t\tconst s = dc.synthesize<IFluidLoadable>({ IFluidLoadable }, undefined);\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Optional IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === mock, \"IFluidLoadable is expected\");\n\t\t\t\tassert(\n\t\t\t\t\tloadable?.handle.absolutePath === mock.handle.absolutePath,\n\t\t\t\t\t\"IFluidLoadable is valid\",\n\t\t\t\t);\n\t\t\t});\n\n\t\t\tit(`One Optional Provider registered via factory`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tconst mock = new MockLoadable();\n\t\t\t\tconst factory = () => mock;\n\t\t\t\tdc.register(IFluidLoadable, factory);\n\n\t\t\t\tconst s = dc.synthesize<IFluidLoadable>({ IFluidLoadable }, undefined);\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Optional IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === mock, \"IFluidLoadable is expected\");\n\t\t\t\tassert(\n\t\t\t\t\tloadable?.handle.absolutePath === mock.handle.absolutePath,\n\t\t\t\t\t\"IFluidLoadable is valid\",\n\t\t\t\t);\n\t\t\t});\n\n\t\t\tit(`One Optional Provider registered via Promise factory`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tconst mock = new MockLoadable();\n\t\t\t\tconst factory = async () => mock;\n\t\t\t\tdc.register(IFluidLoadable, factory);\n\n\t\t\t\tconst s = dc.synthesize<IFluidLoadable>({ IFluidLoadable }, undefined);\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Optional IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === mock, \"IFluidLoadable is expected\");\n\t\t\t\tassert(\n\t\t\t\t\tloadable?.handle.absolutePath === mock.handle.absolutePath,\n\t\t\t\t\t\"IFluidLoadable is valid\",\n\t\t\t\t);\n\t\t\t});\n\n\t\t\tit(`One Optional Provider registered via LazyPromise factory`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tconst mock = new MockLoadable();\n\t\t\t\tlet lazyPromiseFlag = false;\n\t\t\t\tconst lazyFactory = new LazyPromise(async () => {\n\t\t\t\t\tlazyPromiseFlag = true;\n\t\t\t\t\treturn mock;\n\t\t\t\t});\n\t\t\t\tdc.register(IFluidLoadable, lazyFactory);\n\n\t\t\t\tconst s = dc.synthesize<IFluidLoadable>({ IFluidLoadable }, undefined);\n\t\t\t\tconst loadable_promise = s.IFluidLoadable;\n\t\t\t\t// This stacking of promises is done in order to make sure that the loadable_promise would have been executed by the time the assertion is done\n\t\t\t\tawait Promise.resolve().then(async () => {\n\t\t\t\t\tassert(!lazyPromiseFlag, \"Optional IFluidLoadable was correctly lazy loaded\");\n\t\t\t\t\tconst loadable = await loadable_promise;\n\t\t\t\t\tassert(loadable, \"Optional IFluidLoadable was registered\");\n\t\t\t\t\tassert(loadable === mock, \"IFluidLoadable is expected\");\n\t\t\t\t\tassert(\n\t\t\t\t\t\tloadable?.handle.absolutePath === mock.handle.absolutePath,\n\t\t\t\t\t\t\"IFluidLoadable is valid\",\n\t\t\t\t\t);\n\t\t\t\t});\n\t\t\t});\n\n\t\t\tit(`One Required Provider registered via value`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tconst mock = new MockLoadable();\n\t\t\t\tdc.register(IFluidLoadable, mock);\n\n\t\t\t\tconst s = dc.synthesize<undefined, IProvideFluidLoadable>(undefined, {\n\t\t\t\t\tIFluidLoadable,\n\t\t\t\t});\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Required IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === mock, \"IFluidLoadable is expected\");\n\t\t\t\tassert(\n\t\t\t\t\tloadable?.handle.absolutePath === mock.handle.absolutePath,\n\t\t\t\t\t\"IFluidLoadable is valid\",\n\t\t\t\t);\n\t\t\t});\n\n\t\t\tit(`One Required Provider registered via Promise value`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tconst mock = new MockLoadable();\n\t\t\t\tdc.register(IFluidLoadable, Promise.resolve(mock));\n\n\t\t\t\tconst s = dc.synthesize<undefined, IProvideFluidLoadable>(undefined, {\n\t\t\t\t\tIFluidLoadable,\n\t\t\t\t});\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Required IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === mock, \"IFluidLoadable is expected\");\n\t\t\t\tassert(\n\t\t\t\t\tloadable?.handle.absolutePath === mock.handle.absolutePath,\n\t\t\t\t\t\"IFluidLoadable is valid\",\n\t\t\t\t);\n\t\t\t});\n\n\t\t\tit(`One Required Provider registered via factory`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tconst mock = new MockLoadable();\n\t\t\t\tconst factory = () => mock;\n\t\t\t\tdc.register(IFluidLoadable, factory);\n\n\t\t\t\tconst s = dc.synthesize<undefined, IProvideFluidLoadable>(undefined, {\n\t\t\t\t\tIFluidLoadable,\n\t\t\t\t});\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Required IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === mock, \"IFluidLoadable is expected\");\n\t\t\t\tassert(\n\t\t\t\t\tloadable?.handle.absolutePath === mock.handle.absolutePath,\n\t\t\t\t\t\"IFluidLoadable is valid\",\n\t\t\t\t);\n\t\t\t});\n\n\t\t\tit(`One Required Provider registered via Promise factory`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tconst mock = new MockLoadable();\n\t\t\t\tconst factory = async () => mock;\n\t\t\t\tdc.register(IFluidLoadable, factory);\n\n\t\t\t\tconst s = dc.synthesize<undefined, IProvideFluidLoadable>(undefined, {\n\t\t\t\t\tIFluidLoadable,\n\t\t\t\t});\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Required IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === mock, \"IFluidLoadable is expected\");\n\t\t\t\tassert(\n\t\t\t\t\tloadable?.handle.absolutePath === mock.handle.absolutePath,\n\t\t\t\t\t\"IFluidLoadable is valid\",\n\t\t\t\t);\n\t\t\t});\n\n\t\t\tit(`One Required Provider registered via LazyPromise factory`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tconst mock = new MockLoadable();\n\t\t\t\tlet lazyPromiseFlag = false;\n\t\t\t\tconst lazyFactory = new LazyPromise(async () => {\n\t\t\t\t\tlazyPromiseFlag = true;\n\t\t\t\t\treturn mock;\n\t\t\t\t});\n\t\t\t\tdc.register(IFluidLoadable, lazyFactory);\n\n\t\t\t\tconst s = dc.synthesize<undefined, IProvideFluidLoadable>(undefined, {\n\t\t\t\t\tIFluidLoadable,\n\t\t\t\t});\n\t\t\t\tconst loadable_promise = s.IFluidLoadable;\n\t\t\t\t// This stacking of promises is done in order to make sure that the loadable_promise would have been executed by the time the assertion is done\n\t\t\t\tawait Promise.resolve().then(async () => {\n\t\t\t\t\tassert(!lazyPromiseFlag, \"Required IFluidLoadable was correctly lazy loaded\");\n\t\t\t\t\tconst loadable = await loadable_promise;\n\t\t\t\t\tassert(loadable, \"Required IFluidLoadable was registered\");\n\t\t\t\t\tassert(loadable === mock, \"IFluidLoadable is expected\");\n\t\t\t\t\tassert(\n\t\t\t\t\t\tloadable?.handle.absolutePath === mock.handle.absolutePath,\n\t\t\t\t\t\t\"IFluidLoadable is valid\",\n\t\t\t\t\t);\n\t\t\t\t});\n\t\t\t});\n\n\t\t\tit(`Two Optional Modules all registered`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable & ISomeObject>>();\n\t\t\t\tconst loadableMock = new MockLoadable();\n\t\t\t\tdc.register(IFluidLoadable, loadableMock);\n\t\t\t\tconst someObjectMock = new MockSomeObject();\n\t\t\t\tdc.register(ISomeObject, someObjectMock);\n\n\t\t\t\tconst s = dc.synthesize<IFluidLoadable & ISomeObject>(\n\t\t\t\t\t{ IFluidLoadable, ISomeObject },\n\t\t\t\t\tundefined,\n\t\t\t\t);\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Optional IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === loadableMock, \"IFluidLoadable is expected\");\n\n\t\t\t\tconst someObject = await s.ISomeObject;\n\t\t\t\tassert(someObject, \"Optional ISomeObject was registered\");\n\t\t\t\tassert(someObject === someObjectMock, \"ISomeObject is expected\");\n\t\t\t});\n\n\t\t\tit(`Two Optional Modules one registered`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable & ISomeObject>>();\n\t\t\t\tconst loadableMock = new MockLoadable();\n\t\t\t\tdc.register(IFluidLoadable, loadableMock);\n\n\t\t\t\tconst s = dc.synthesize<IFluidLoadable & ISomeObject>(\n\t\t\t\t\t{ IFluidLoadable, ISomeObject },\n\t\t\t\t\tundefined,\n\t\t\t\t);\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Optional IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === loadableMock, \"IFluidLoadable is expected\");\n\n\t\t\t\tconst someObject = await s.ISomeObject;\n\t\t\t\tassert(!someObject, \"Optional ISomeObject was not registered\");\n\t\t\t});\n\n\t\t\tit(`Two Optional Modules none registered`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable & ISomeObject>>();\n\n\t\t\t\tconst s = dc.synthesize<IFluidLoadable & ISomeObject>(\n\t\t\t\t\t{ IFluidLoadable, ISomeObject },\n\t\t\t\t\tundefined,\n\t\t\t\t);\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(!loadable, \"Optional IFluidLoadable was not registered\");\n\t\t\t\tconst someObject = await s.ISomeObject;\n\t\t\t\tassert(!someObject, \"Optional ISomeObject was not registered\");\n\t\t\t});\n\n\t\t\tit(`Two Required Modules all registered`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable & ISomeObject>>();\n\t\t\t\tconst loadableMock = new MockLoadable();\n\t\t\t\tdc.register(IFluidLoadable, loadableMock);\n\t\t\t\tconst someObjectMock = new MockSomeObject();\n\t\t\t\tdc.register(ISomeObject, someObjectMock);\n\n\t\t\t\tconst s = dc.synthesize<undefined, IProvideFluidLoadable & IProvideSomeObject>(\n\t\t\t\t\tundefined,\n\t\t\t\t\t{ IFluidLoadable, ISomeObject },\n\t\t\t\t);\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Required IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === loadableMock, \"IFluidLoadable is expected\");\n\n\t\t\t\tconst someObject = await s.ISomeObject;\n\t\t\t\tassert(someObject, \"Required ISomeObject was registered\");\n\t\t\t\tassert(someObject === someObjectMock, \"ISomeObject is expected\");\n\t\t\t});\n\n\t\t\tit(`Required Provider not registered should throw`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\n\t\t\t\tassert.throws(\n\t\t\t\t\t() =>\n\t\t\t\t\t\tdc.synthesize<undefined, IProvideFluidLoadable>(undefined, {\n\t\t\t\t\t\t\tIFluidLoadable,\n\t\t\t\t\t\t}),\n\t\t\t\t\tError,\n\t\t\t\t);\n\t\t\t});\n\n\t\t\tit(`Optional Provider found in Parent`, async () => {\n\t\t\t\tconst parentDc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tconst mock = new MockLoadable();\n\t\t\t\tparentDc.register(IFluidLoadable, mock);\n\t\t\t\tconst dc = new DependencyContainer(parentDc);\n\n\t\t\t\tconst s = dc.synthesize<IFluidLoadable>({ IFluidLoadable }, undefined);\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Optional IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === mock, \"IFluidLoadable is expected\");\n\t\t\t\tassert(\n\t\t\t\t\tloadable?.handle.absolutePath === mock.handle.absolutePath,\n\t\t\t\t\t\"IFluidLoadable is valid\",\n\t\t\t\t);\n\t\t\t});\n\n\t\t\tit(`Optional Modules found in Parent and Child`, async () => {\n\t\t\t\tconst parentDc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tconst loadableMock = new MockLoadable();\n\t\t\t\tparentDc.register(IFluidLoadable, loadableMock);\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<ISomeObject>>(parentDc);\n\t\t\t\tconst someObjectMock = new MockSomeObject();\n\t\t\t\tdc.register(ISomeObject, someObjectMock);\n\n\t\t\t\tconst s = dc.synthesize<IFluidLoadable & ISomeObject>(\n\t\t\t\t\t{ IFluidLoadable, ISomeObject },\n\t\t\t\t\tundefined,\n\t\t\t\t);\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Optional IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === loadableMock, \"IFluidLoadable is expected\");\n\n\t\t\t\tconst someObject = await s.ISomeObject;\n\t\t\t\tassert(someObject, \"Optional ISomeObject was registered\");\n\t\t\t\tassert(someObject === someObjectMock, \"ISomeObject is expected\");\n\t\t\t});\n\n\t\t\tit(`Optional Provider found in Parent and Child resolves Child`, async () => {\n\t\t\t\tconst parentDc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tparentDc.register(IFluidLoadable, new MockLoadable());\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>(parentDc);\n\t\t\t\tconst loadableMock = new MockLoadable();\n\t\t\t\tdc.register(IFluidLoadable, loadableMock);\n\n\t\t\t\tconst s = dc.synthesize<IFluidLoadable>({ IFluidLoadable }, undefined);\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Optional IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === loadableMock, \"IFluidLoadable is expected\");\n\t\t\t});\n\n\t\t\tit(`Required Provider found in Parent`, async () => {\n\t\t\t\tconst parentDc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tconst mock = new MockLoadable();\n\t\t\t\tparentDc.register(IFluidLoadable, mock);\n\t\t\t\tconst dc = new DependencyContainer(parentDc);\n\n\t\t\t\tconst s = dc.synthesize<undefined, IProvideFluidLoadable>(undefined, {\n\t\t\t\t\tIFluidLoadable,\n\t\t\t\t});\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Required IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === mock, \"IFluidLoadable is expected\");\n\t\t\t\tassert(\n\t\t\t\t\tloadable?.handle.absolutePath === mock.handle.absolutePath,\n\t\t\t\t\t\"IFluidLoadable is valid\",\n\t\t\t\t);\n\t\t\t});\n\n\t\t\tit(`Required Modules found in Parent and Child`, async () => {\n\t\t\t\tconst parentDc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tconst loadableMock = new MockLoadable();\n\t\t\t\tparentDc.register(IFluidLoadable, loadableMock);\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<ISomeObject>>(parentDc);\n\t\t\t\tconst someObjectMock = new MockSomeObject();\n\t\t\t\tdc.register(ISomeObject, someObjectMock);\n\n\t\t\t\tconst s = dc.synthesize<undefined, IProvideFluidLoadable & IProvideSomeObject>(\n\t\t\t\t\tundefined,\n\t\t\t\t\t{ IFluidLoadable, ISomeObject },\n\t\t\t\t);\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Required IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === loadableMock, \"IFluidLoadable is expected\");\n\n\t\t\t\tconst someObject = await s.ISomeObject;\n\t\t\t\tassert(someObject, \"Required ISomeObject was registered\");\n\t\t\t\tassert(someObject === someObjectMock, \"ISomeObject is expected\");\n\t\t\t});\n\n\t\t\tit(`Required Provider found in Parent and Child resolves Child`, async () => {\n\t\t\t\tconst parentDc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tparentDc.register(IFluidLoadable, new MockLoadable());\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>(parentDc);\n\t\t\t\tconst loadableMock = new MockLoadable();\n\t\t\t\tdc.register(IFluidLoadable, loadableMock);\n\n\t\t\t\tconst s = dc.synthesize<undefined, IProvideFluidLoadable>(undefined, {\n\t\t\t\t\tIFluidLoadable,\n\t\t\t\t});\n\t\t\t\tconst loadable = await s.IFluidLoadable;\n\t\t\t\tassert(loadable, \"Required IFluidLoadable was registered\");\n\t\t\t\tassert(loadable === loadableMock, \"IFluidLoadable is expected\");\n\t\t\t});\n\n\t\t\tit(`Registering`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tdc.register(IFluidLoadable, new MockLoadable());\n\t\t\t\tassert(dc.has(IFluidLoadable), \"DependencyContainer has IFluidLoadable\");\n\t\t\t});\n\n\t\t\tit(`Registering the same type twice throws`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tdc.register(IFluidLoadable, new MockLoadable());\n\t\t\t\tassert.throws(() => dc.register(IFluidLoadable, new MockLoadable()), Error);\n\t\t\t});\n\n\t\t\tit(`Registering then Unregistering`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tdc.register(IFluidLoadable, new MockLoadable());\n\t\t\t\tdc.unregister(IFluidLoadable);\n\t\t\t\tassert(!dc.has(IFluidLoadable), \"DependencyContainer doesn't have IFluidLoadable\");\n\t\t\t});\n\n\t\t\tit(`Registering then Unregistering then Registering`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tdc.register(IFluidLoadable, new MockLoadable());\n\t\t\t\tdc.unregister(IFluidLoadable);\n\t\t\t\tdc.register(IFluidLoadable, new MockLoadable());\n\t\t\t\tassert(dc.has(IFluidLoadable), \"DependencyContainer has IFluidLoadable\");\n\t\t\t});\n\n\t\t\tit(`has() resolves correctly in all variations`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable & ISomeObject>>();\n\t\t\t\tdc.register(IFluidLoadable, new MockLoadable());\n\t\t\t\tdc.register(ISomeObject, new MockSomeObject());\n\t\t\t\tassert(dc.has(IFluidLoadable), \"Manager has IFluidLoadable\");\n\t\t\t\tassert(dc.has(ISomeObject), \"Manager has ISomeObject\");\n\t\t\t\tassert(\n\t\t\t\t\tdc.has(IFluidLoadable) && dc.has(ISomeObject),\n\t\t\t\t\t\"Manager has IFluidLoadable & ISomeObject\",\n\t\t\t\t);\n\t\t\t});\n\n\t\t\tit(`Child has Parent modules`, async () => {\n\t\t\t\tconst parentDc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tconst loadableMock = new MockLoadable();\n\t\t\t\tparentDc.register(IFluidLoadable, loadableMock);\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<ISomeObject>>(parentDc);\n\t\t\t\tconst someObjectMock = new MockSomeObject();\n\t\t\t\tdc.register(ISomeObject, someObjectMock);\n\n\t\t\t\tassert(dc.has(IFluidLoadable), \"has includes parent registered\");\n\t\t\t\tassert(\n\t\t\t\t\t!dc.has(IFluidLoadable, true),\n\t\t\t\t\t\"has does not include excluded parent registered\",\n\t\t\t\t);\n\t\t\t\tassert(dc.has(ISomeObject), \"has includes registered\");\n\t\t\t\tassert(!dc.has(IFluidHandle), \"does not include not registered\");\n\t\t\t});\n\n\t\t\tit(`Parent Resolved from Child`, async () => {\n\t\t\t\tconst parentDc = new DependencyContainer<FluidObject<IFluidHandle>>();\n\t\t\t\tconst loadableToHandle: FluidObjectProvider<IProvideFluidHandle> = async (\n\t\t\t\t\tfds: IFluidDependencySynthesizer,\n\t\t\t\t) => {\n\t\t\t\t\tconst loadable = fds.synthesize<undefined, IProvideFluidLoadable>(undefined, {\n\t\t\t\t\t\tIFluidLoadable,\n\t\t\t\t\t});\n\t\t\t\t\treturn (await loadable.IFluidLoadable).handle;\n\t\t\t\t};\n\t\t\t\tparentDc.register(IFluidHandle, loadableToHandle);\n\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>(parentDc);\n\t\t\t\tconst loadableMock = new MockLoadable();\n\t\t\t\tdc.register(IFluidLoadable, loadableMock);\n\n\t\t\t\tconst deps = dc.synthesize<IFluidHandle>({ IFluidHandle }, undefined);\n\t\t\t\tassert((await deps.IFluidHandle) !== undefined, \"handle undefined\");\n\t\t\t});\n\n\t\t\tit(`Undefined Provider is not Undefined`, async () => {\n\t\t\t\tconst dc = new DependencyContainer();\n\t\t\t\tconst deps = dc.synthesize<IFluidLoadable>({ IFluidLoadable }, {});\n\t\t\t\tassert(deps.IFluidLoadable !== undefined, \"handle undefined\");\n\t\t\t\tassert((await deps.IFluidLoadable) === undefined, \"handle undefined\");\n\t\t\t});\n\n\t\t\tit(`test getProvider backcompat`, async () => {\n\t\t\t\tconst dc = new DependencyContainer<FluidObject<IFluidLoadable>>();\n\t\t\t\tconst loadableMock = new MockLoadable();\n\t\t\t\tdc.register(IFluidLoadable, loadableMock);\n\t\t\t\tconst testGetProvider = (deps: IFluidDependencySynthesizer, scenario: string) => {\n\t\t\t\t\tconst old = deps as any as {\n\t\t\t\t\t\tgetProvider(\n\t\t\t\t\t\t\tkey: \"IFluidLoadable\",\n\t\t\t\t\t\t): FluidObjectProvider<FluidObject<IFluidLoadable>>;\n\t\t\t\t\t};\n\t\t\t\t\tconst provider = old.getProvider(\"IFluidLoadable\");\n\t\t\t\t\tassert.equal(provider, loadableMock, scenario);\n\t\t\t\t};\n\t\t\t\ttestGetProvider(dc, \"direct\");\n\t\t\t\ttestGetProvider(new DependencyContainer(dc), \"parent\");\n\t\t\t\ttestGetProvider(new PassThru<FluidObject<IFluidLoadable>>(dc), \"pass thru\");\n\t\t\t\ttestGetProvider(\n\t\t\t\t\tnew DependencyContainer(new PassThru<FluidObject<IFluidLoadable>>(dc)),\n\t\t\t\t\t\"pass thru as child\",\n\t\t\t\t);\n\t\t\t});\n\t\t});\n\t});\n});\n\nclass PassThru<TMap> implements IFluidDependencySynthesizer {\n\tconstructor(private readonly parent: IFluidDependencySynthesizer) {}\n\tsynthesize<O, R = Record<string, never> | undefined>(\n\t\toptionalTypes: FluidObjectSymbolProvider<O>,\n\t\trequiredTypes: Required<FluidObjectSymbolProvider<R>>,\n\t): AsyncFluidObjectProvider<O, R> {\n\t\treturn this.parent.synthesize(optionalTypes, requiredTypes);\n\t}\n\thas(type: string): boolean {\n\t\treturn this.parent.has(type);\n\t}\n\treadonly IFluidDependencySynthesizer = this;\n\n\tgetProvider<K extends keyof TMap>(key: K): FluidObjectProvider<TMap[K]> | undefined {\n\t\tconst maybe = this.parent as any as Partial<this>;\n\t\tif (maybe.getProvider) {\n\t\t\treturn maybe.getProvider(key);\n\t\t}\n\t}\n}\n"]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"validateSynthesizePrevious.generated.cjs","sourceRoot":"","sources":["../../../src/test/types/validateSynthesizePrevious.generated.ts"],"names":[],"mappings":";;AAgCA,yDAAyD,CACrD,qDAAqD,EAAE,CAAC,CAAC;AAW7D,qDAAqD,CACjD,yDAAyD,EAAE,CAAC,CAAC;AAWjE,iEAAiE,CAC7D,6DAA6D,EAAE,CAAC,CAAC;AAWrE,6DAA6D,CACzD,iEAAiE,EAAE,CAAC,CAAC;AAWzE,iEAAiE,CAC7D,6DAA6D,EAAE,CAAC,CAAC;AAWrE,6DAA6D,CACzD,iEAAiE,EAAE,CAAC,CAAC;AAWzE,gDAAgD,CAC5C,4CAA4C,EAAE,CAAC,CAAC;AAWpD,4CAA4C,CACxC,gDAAgD,EAAE,CAAC,CAAC;AAWxD,oDAAoD,CAChD,gDAAgD,EAAE,CAAC,CAAC;AAWxD,gDAAgD,CAC5C,oDAAoD,EAAE,CAAC,CAAC;AAW5D,0DAA0D,CACtD,sDAAsD,EAAE,CAAC,CAAC;AAW9D,sDAAsD,CAClD,0DAA0D,EAAE,CAAC,CAAC;AAWlE,2DAA2D,CACvD,uDAAuD,EAAE,CAAC,CAAC;AAW/D,uDAAuD,CACnD,2DAA2D,EAAE,CAAC,CAAC;AAWnE,4DAA4D,CACxD,wDAAwD,EAAE,CAAC,CAAC;AAWhE,wDAAwD,CACpD,4DAA4D,EAAE,CAAC,CAAC;AAWpE,mEAAmE,CAC/D,+DAA+D,EAAE,CAAC,CAAC;AAWvE,+DAA+D,CAC3D,mEAAmE,EAAE,CAAC,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n/*\n * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.\n * Generated by fluid-type-test-generator in @fluidframework/build-tools.\n */\nimport type * as old from \"@fluidframework/synthesize-previous\";\nimport type * as current from \"../../index\";\n\n\n// See 'build-tools/src/type-test-generator/compatibility.ts' for more information.\ntype TypeOnly<T> = T extends number\n\t? number\n\t: T extends string\n\t? string\n\t: T extends boolean | bigint | symbol\n\t? T\n\t: {\n\t\t\t[P in keyof T]: TypeOnly<T[P]>;\n\t };\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_AsyncFluidObjectProvider\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_TypeAliasDeclaration_AsyncFluidObjectProvider():\n TypeOnly<old.AsyncFluidObjectProvider<any,any>>;\ndeclare function use_current_TypeAliasDeclaration_AsyncFluidObjectProvider(\n use: TypeOnly<current.AsyncFluidObjectProvider<any,any>>): void;\nuse_current_TypeAliasDeclaration_AsyncFluidObjectProvider(\n get_old_TypeAliasDeclaration_AsyncFluidObjectProvider());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_AsyncFluidObjectProvider\": {\"backCompat\": false}\n*/\ndeclare function get_current_TypeAliasDeclaration_AsyncFluidObjectProvider():\n TypeOnly<current.AsyncFluidObjectProvider<any,any>>;\ndeclare function use_old_TypeAliasDeclaration_AsyncFluidObjectProvider(\n use: TypeOnly<old.AsyncFluidObjectProvider<any,any>>): void;\nuse_old_TypeAliasDeclaration_AsyncFluidObjectProvider(\n get_current_TypeAliasDeclaration_AsyncFluidObjectProvider());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_AsyncOptionalFluidObjectProvider\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_TypeAliasDeclaration_AsyncOptionalFluidObjectProvider():\n TypeOnly<old.AsyncOptionalFluidObjectProvider<any>>;\ndeclare function use_current_TypeAliasDeclaration_AsyncOptionalFluidObjectProvider(\n use: TypeOnly<current.AsyncOptionalFluidObjectProvider<any>>): void;\nuse_current_TypeAliasDeclaration_AsyncOptionalFluidObjectProvider(\n get_old_TypeAliasDeclaration_AsyncOptionalFluidObjectProvider());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_AsyncOptionalFluidObjectProvider\": {\"backCompat\": false}\n*/\ndeclare function get_current_TypeAliasDeclaration_AsyncOptionalFluidObjectProvider():\n TypeOnly<current.AsyncOptionalFluidObjectProvider<any>>;\ndeclare function use_old_TypeAliasDeclaration_AsyncOptionalFluidObjectProvider(\n use: TypeOnly<old.AsyncOptionalFluidObjectProvider<any>>): void;\nuse_old_TypeAliasDeclaration_AsyncOptionalFluidObjectProvider(\n get_current_TypeAliasDeclaration_AsyncOptionalFluidObjectProvider());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_AsyncRequiredFluidObjectProvider\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_TypeAliasDeclaration_AsyncRequiredFluidObjectProvider():\n TypeOnly<old.AsyncRequiredFluidObjectProvider<any>>;\ndeclare function use_current_TypeAliasDeclaration_AsyncRequiredFluidObjectProvider(\n use: TypeOnly<current.AsyncRequiredFluidObjectProvider<any>>): void;\nuse_current_TypeAliasDeclaration_AsyncRequiredFluidObjectProvider(\n get_old_TypeAliasDeclaration_AsyncRequiredFluidObjectProvider());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_AsyncRequiredFluidObjectProvider\": {\"backCompat\": false}\n*/\ndeclare function get_current_TypeAliasDeclaration_AsyncRequiredFluidObjectProvider():\n TypeOnly<current.AsyncRequiredFluidObjectProvider<any>>;\ndeclare function use_old_TypeAliasDeclaration_AsyncRequiredFluidObjectProvider(\n use: TypeOnly<old.AsyncRequiredFluidObjectProvider<any>>): void;\nuse_old_TypeAliasDeclaration_AsyncRequiredFluidObjectProvider(\n get_current_TypeAliasDeclaration_AsyncRequiredFluidObjectProvider());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"ClassDeclaration_DependencyContainer\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_ClassDeclaration_DependencyContainer():\n TypeOnly<old.DependencyContainer<any>>;\ndeclare function use_current_ClassDeclaration_DependencyContainer(\n use: TypeOnly<current.DependencyContainer<any>>): void;\nuse_current_ClassDeclaration_DependencyContainer(\n get_old_ClassDeclaration_DependencyContainer());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"ClassDeclaration_DependencyContainer\": {\"backCompat\": false}\n*/\ndeclare function get_current_ClassDeclaration_DependencyContainer():\n TypeOnly<current.DependencyContainer<any>>;\ndeclare function use_old_ClassDeclaration_DependencyContainer(\n use: TypeOnly<old.DependencyContainer<any>>): void;\nuse_old_ClassDeclaration_DependencyContainer(\n get_current_ClassDeclaration_DependencyContainer());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_FluidObjectProvider\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_TypeAliasDeclaration_FluidObjectProvider():\n TypeOnly<old.FluidObjectProvider<any>>;\ndeclare function use_current_TypeAliasDeclaration_FluidObjectProvider(\n use: TypeOnly<current.FluidObjectProvider<any>>): void;\nuse_current_TypeAliasDeclaration_FluidObjectProvider(\n get_old_TypeAliasDeclaration_FluidObjectProvider());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_FluidObjectProvider\": {\"backCompat\": false}\n*/\ndeclare function get_current_TypeAliasDeclaration_FluidObjectProvider():\n TypeOnly<current.FluidObjectProvider<any>>;\ndeclare function use_old_TypeAliasDeclaration_FluidObjectProvider(\n use: TypeOnly<old.FluidObjectProvider<any>>): void;\nuse_old_TypeAliasDeclaration_FluidObjectProvider(\n get_current_TypeAliasDeclaration_FluidObjectProvider());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_FluidObjectSymbolProvider\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_TypeAliasDeclaration_FluidObjectSymbolProvider():\n TypeOnly<old.FluidObjectSymbolProvider<any>>;\ndeclare function use_current_TypeAliasDeclaration_FluidObjectSymbolProvider(\n use: TypeOnly<current.FluidObjectSymbolProvider<any>>): void;\nuse_current_TypeAliasDeclaration_FluidObjectSymbolProvider(\n get_old_TypeAliasDeclaration_FluidObjectSymbolProvider());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_FluidObjectSymbolProvider\": {\"backCompat\": false}\n*/\ndeclare function get_current_TypeAliasDeclaration_FluidObjectSymbolProvider():\n TypeOnly<current.FluidObjectSymbolProvider<any>>;\ndeclare function use_old_TypeAliasDeclaration_FluidObjectSymbolProvider(\n use: TypeOnly<old.FluidObjectSymbolProvider<any>>): void;\nuse_old_TypeAliasDeclaration_FluidObjectSymbolProvider(\n get_current_TypeAliasDeclaration_FluidObjectSymbolProvider());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"VariableDeclaration_IFluidDependencySynthesizer\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_VariableDeclaration_IFluidDependencySynthesizer():\n TypeOnly<typeof old.IFluidDependencySynthesizer>;\ndeclare function use_current_VariableDeclaration_IFluidDependencySynthesizer(\n use: TypeOnly<typeof current.IFluidDependencySynthesizer>): void;\nuse_current_VariableDeclaration_IFluidDependencySynthesizer(\n get_old_VariableDeclaration_IFluidDependencySynthesizer());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"VariableDeclaration_IFluidDependencySynthesizer\": {\"backCompat\": false}\n*/\ndeclare function get_current_VariableDeclaration_IFluidDependencySynthesizer():\n TypeOnly<typeof current.IFluidDependencySynthesizer>;\ndeclare function use_old_VariableDeclaration_IFluidDependencySynthesizer(\n use: TypeOnly<typeof old.IFluidDependencySynthesizer>): void;\nuse_old_VariableDeclaration_IFluidDependencySynthesizer(\n get_current_VariableDeclaration_IFluidDependencySynthesizer());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"InterfaceDeclaration_IFluidDependencySynthesizer\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_InterfaceDeclaration_IFluidDependencySynthesizer():\n TypeOnly<old.IFluidDependencySynthesizer>;\ndeclare function use_current_InterfaceDeclaration_IFluidDependencySynthesizer(\n use: TypeOnly<current.IFluidDependencySynthesizer>): void;\nuse_current_InterfaceDeclaration_IFluidDependencySynthesizer(\n get_old_InterfaceDeclaration_IFluidDependencySynthesizer());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"InterfaceDeclaration_IFluidDependencySynthesizer\": {\"backCompat\": false}\n*/\ndeclare function get_current_InterfaceDeclaration_IFluidDependencySynthesizer():\n TypeOnly<current.IFluidDependencySynthesizer>;\ndeclare function use_old_InterfaceDeclaration_IFluidDependencySynthesizer(\n use: TypeOnly<old.IFluidDependencySynthesizer>): void;\nuse_old_InterfaceDeclaration_IFluidDependencySynthesizer(\n get_current_InterfaceDeclaration_IFluidDependencySynthesizer());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"InterfaceDeclaration_IProvideFluidDependencySynthesizer\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_InterfaceDeclaration_IProvideFluidDependencySynthesizer():\n TypeOnly<old.IProvideFluidDependencySynthesizer>;\ndeclare function use_current_InterfaceDeclaration_IProvideFluidDependencySynthesizer(\n use: TypeOnly<current.IProvideFluidDependencySynthesizer>): void;\nuse_current_InterfaceDeclaration_IProvideFluidDependencySynthesizer(\n get_old_InterfaceDeclaration_IProvideFluidDependencySynthesizer());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"InterfaceDeclaration_IProvideFluidDependencySynthesizer\": {\"backCompat\": false}\n*/\ndeclare function get_current_InterfaceDeclaration_IProvideFluidDependencySynthesizer():\n TypeOnly<current.IProvideFluidDependencySynthesizer>;\ndeclare function use_old_InterfaceDeclaration_IProvideFluidDependencySynthesizer(\n use: TypeOnly<old.IProvideFluidDependencySynthesizer>): void;\nuse_old_InterfaceDeclaration_IProvideFluidDependencySynthesizer(\n get_current_InterfaceDeclaration_IProvideFluidDependencySynthesizer());\n"]}
|
package/dist/types.cjs.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"types.cjs","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\nimport { IFluidDependencySynthesizer } from \".\";\n\n/**\n * This is a condensed version of Record that requires the object has all\n * the FluidObject properties as its type mapped to a string representation\n * of that property.\n *\n * @example\n *\n * ```typescript\n * { IFoo: \"IFoo\" }\n * ```\n * @alpha\n */\nexport type FluidObjectSymbolProvider<T> = {\n\t[P in keyof T]?: P;\n};\n\n/**\n * This is a condensed version of Record that requires the object has all\n * the FluidObject properties as its type mapped to an object that implements\n * the property.\n * @alpha\n */\nexport type AsyncRequiredFluidObjectProvider<T> = T extends undefined\n\t? Record<string, never>\n\t: {\n\t\t\t[P in keyof T]: Promise<NonNullable<Exclude<T[P], undefined | null>>>;\n\t };\n\n/**\n * This is a condensed version of Record that requires the object has all\n * the FluidObject properties as its type, mapped to an object that implements\n * the property or undefined.\n * @alpha\n */\nexport type AsyncOptionalFluidObjectProvider<T> = T extends undefined\n\t? Record<string, never>\n\t: {\n\t\t\t[P in keyof T]?: Promise<T[P] | undefined>;\n\t };\n\n/**\n * Combined type for Optional and Required Async Fluid object Providers\n * @alpha\n */\nexport type AsyncFluidObjectProvider<O, R = undefined> = AsyncOptionalFluidObjectProvider<O> &\n\tAsyncRequiredFluidObjectProvider<R>;\n\n/**\n * Multiple ways to provide a Fluid object.\n * @internal\n */\nexport type FluidObjectProvider<T> =\n\t| NonNullable<T>\n\t| Promise<NonNullable<T>>\n\t| ((dependencyContainer: IFluidDependencySynthesizer) => NonNullable<T>)\n\t| ((dependencyContainer: IFluidDependencySynthesizer) => Promise<NonNullable<T>>);\n"]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"IFluidDependencySynthesizer.d.ts","sourceRoot":"","sources":["../src/IFluidDependencySynthesizer.ts"],"names":[],"mappings":"AAAA;;;GAGG;OAEI,EAAE,wBAAwB,EAAE,yBAAyB,EAAE;AAE9D;;GAEG;AACH,eAAO,MAAM,2BAA2B,EAAE,MAAM,kCAClB,CAAC;AAE/B;;GAEG;AACH,MAAM,WAAW,kCAAkC;IAClD,2BAA2B,EAAE,2BAA2B,CAAC;CACzD;AAED;;;;;GAKG;AACH,MAAM,WAAW,2BAA4B,SAAQ,kC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,QAAQ,CAAC,yBAAyB,CAAC,CAAC,CAAC,CAAC,GACnD,wBAAwB,CAAC,CAAC,EAAE,CAAC,CAAC;IAQjC;;;OAGG;IACI,GAAG,CAAC,IAAI,EAAE,MAAM,EAAE,cAAc,CAAC,EAAE,OAAO,GAAG,OAAO;IAS3D;;OAEG;IACH,OAAO,CAAC,WAAW;IAuBnB,OAAO,CAAC,gBAAgB;IAoBxB,OAAO,CAAC,gBAAgB;IAgBxB,OAAO,CAAC,eAAe;CA2CvB"}
|
package/lib/index.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;OAEI,EAAE,mBAAmB,EAAE;OACvB,EACN,2BAA2B,EAC3B,kCAAkC,GAClC;OACM,EACN,wBAAwB,EACxB,gCAAgC,EAChC,gCAAgC,EAChC,mBAAmB,EACnB,yBAAyB,GACzB"}
|
package/lib/types.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"OAIO,EAAE,2BAA2B,EAAE,MAAM,GAAG;AAE/C;;;;;;;;;;;GAWG;AACH,MAAM,MAAM,yBAAyB,CAAC,CAAC,IAAI;KACzC,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC;CAClB,CAAC;AAEF;;;;;GAKG;AACH,MAAM,MAAM,gCAAgC,CAAC,CAAC,IAAI,CAAC,SAAS,SAAS,GAClE,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,GACrB;KACC,CAAC,IAAI,MAAM,CAAC,GAAG,OAAO,CAAC,WAAW,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,SAAS,GAAG,IAAI,CAAC,CAAC,CAAC;CACpE,CAAC;AAEL;;;;;GAKG;AACH,MAAM,MAAM,gCAAgC,CAAC,CAAC,IAAI,CAAC,SAAS,SAAS,GAClE,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,GACrB;KACC,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,EAAE,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,SAAS,CAAC;CACzC,CAAC;AAEL;;;GAGG;AACH,MAAM,MAAM,wBAAwB,CAAC,CAAC,EAAE,CAAC,GAAG,SAAS,IAAI,gCAAgC,CAAC,CAAC,CAAC,GAC3F,gCAAgC,CAAC,CAAC,CAAC,CAAC;AAErC;;;GAGG;AACH,MAAM,MAAM,mBAAmB,CAAC,CAAC,IAC9B,WAAW,CAAC,CAAC,CAAC,GACd,OAAO,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,GACvB,CAAC,CAAC,mBAAmB,EAAE,2BAA2B,KAAK,WAAW,CAAC,CAAC,CAAC,CAAC,GACtE,CAAC,CAAC,mBAAmB,EAAE,2BAA2B,KAAK,OAAO,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC"}
|
|
File without changes
|
|
File without changes
|