@tsed/mongoose 8.0.0-alpha.5 → 8.0.0-alpha.7

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.
Files changed (174) hide show
  1. package/lib/esm/MongooseModule.js.map +1 -1
  2. package/lib/esm/decorators/dynamicRef.js +1 -1
  3. package/lib/esm/decorators/dynamicRef.js.map +1 -1
  4. package/lib/esm/decorators/indexed.js.map +1 -1
  5. package/lib/esm/decorators/model.js.map +1 -1
  6. package/lib/esm/decorators/mongoosePlugin.js.map +1 -1
  7. package/lib/esm/decorators/numberDecimal.js +1 -1
  8. package/lib/esm/decorators/numberDecimal.js.map +1 -1
  9. package/lib/esm/decorators/objectID.js.map +1 -1
  10. package/lib/esm/decorators/postHook.js.map +1 -1
  11. package/lib/esm/decorators/preHook.js.map +1 -1
  12. package/lib/esm/decorators/ref.js.map +1 -1
  13. package/lib/esm/decorators/schema.js.map +1 -1
  14. package/lib/esm/decorators/versionKey.js.map +1 -1
  15. package/lib/esm/decorators/virtualRef.js.map +1 -1
  16. package/lib/esm/services/MongooseConnections.js +1 -1
  17. package/lib/esm/services/MongooseConnections.js.map +1 -1
  18. package/lib/esm/services/MongooseService.js.map +1 -1
  19. package/lib/esm/utils/createModel.js.map +1 -1
  20. package/lib/esm/utils/createSchema.js.map +1 -1
  21. package/lib/esm/utils/resolveRefType.js.map +1 -1
  22. package/lib/esm/utils/schemaOptions.js.map +1 -1
  23. package/lib/types/decorators/indexed.d.ts +24 -0
  24. package/lib/types/decorators/mongoosePlugin.d.ts +24 -0
  25. package/lib/types/decorators/numberDecimal.d.ts +24 -0
  26. package/lib/types/decorators/objectID.d.ts +24 -0
  27. package/lib/types/decorators/schema.d.ts +24 -0
  28. package/lib/types/interfaces/MongooseConnectionOptions.d.ts +24 -0
  29. package/lib/types/interfaces/MongooseDocument.d.ts +24 -0
  30. package/lib/types/interfaces/MongooseModel.d.ts +24 -0
  31. package/lib/types/interfaces/MongooseSchemaOptions.d.ts +24 -0
  32. package/lib/types/services/MongooseService.d.ts +24 -0
  33. package/lib/types/utils/createModel.d.ts +24 -0
  34. package/lib/types/utils/createSchema.d.ts +24 -0
  35. package/lib/types/utils/schemaOptions.d.ts +24 -0
  36. package/package.json +19 -20
  37. package/vitest.config.mts +4 -4
  38. package/lib/cjs/MongooseModule.js +0 -36
  39. package/lib/cjs/MongooseModule.js.map +0 -1
  40. package/lib/cjs/constants/constants.js +0 -24
  41. package/lib/cjs/constants/constants.js.map +0 -1
  42. package/lib/cjs/decorators/auto.js +0 -28
  43. package/lib/cjs/decorators/auto.js.map +0 -1
  44. package/lib/cjs/decorators/discriminatorKey.js +0 -6
  45. package/lib/cjs/decorators/discriminatorKey.js.map +0 -1
  46. package/lib/cjs/decorators/dynamicRef.js +0 -65
  47. package/lib/cjs/decorators/dynamicRef.js.map +0 -1
  48. package/lib/cjs/decorators/excludeIndexes.js +0 -28
  49. package/lib/cjs/decorators/excludeIndexes.js.map +0 -1
  50. package/lib/cjs/decorators/expires.js +0 -28
  51. package/lib/cjs/decorators/expires.js.map +0 -1
  52. package/lib/cjs/decorators/immutable.js +0 -30
  53. package/lib/cjs/decorators/immutable.js.map +0 -1
  54. package/lib/cjs/decorators/indexed.js +0 -26
  55. package/lib/cjs/decorators/indexed.js.map +0 -1
  56. package/lib/cjs/decorators/lowercase.js +0 -28
  57. package/lib/cjs/decorators/lowercase.js.map +0 -1
  58. package/lib/cjs/decorators/model.js +0 -69
  59. package/lib/cjs/decorators/model.js.map +0 -1
  60. package/lib/cjs/decorators/mongooseIndex.js +0 -39
  61. package/lib/cjs/decorators/mongooseIndex.js.map +0 -1
  62. package/lib/cjs/decorators/mongooseIndexes.js +0 -39
  63. package/lib/cjs/decorators/mongooseIndexes.js.map +0 -1
  64. package/lib/cjs/decorators/mongoosePlugin.js +0 -22
  65. package/lib/cjs/decorators/mongoosePlugin.js.map +0 -1
  66. package/lib/cjs/decorators/numberDecimal.js +0 -78
  67. package/lib/cjs/decorators/numberDecimal.js.map +0 -1
  68. package/lib/cjs/decorators/objectID.js +0 -32
  69. package/lib/cjs/decorators/objectID.js.map +0 -1
  70. package/lib/cjs/decorators/postHook.js +0 -26
  71. package/lib/cjs/decorators/postHook.js.map +0 -1
  72. package/lib/cjs/decorators/preHook.js +0 -71
  73. package/lib/cjs/decorators/preHook.js.map +0 -1
  74. package/lib/cjs/decorators/ref.js +0 -84
  75. package/lib/cjs/decorators/ref.js.map +0 -1
  76. package/lib/cjs/decorators/schema.js +0 -32
  77. package/lib/cjs/decorators/schema.js.map +0 -1
  78. package/lib/cjs/decorators/schemaIgnore.js +0 -27
  79. package/lib/cjs/decorators/schemaIgnore.js.map +0 -1
  80. package/lib/cjs/decorators/select.js +0 -28
  81. package/lib/cjs/decorators/select.js.map +0 -1
  82. package/lib/cjs/decorators/sparse.js +0 -30
  83. package/lib/cjs/decorators/sparse.js.map +0 -1
  84. package/lib/cjs/decorators/text.js +0 -29
  85. package/lib/cjs/decorators/text.js.map +0 -1
  86. package/lib/cjs/decorators/trim.js +0 -27
  87. package/lib/cjs/decorators/trim.js.map +0 -1
  88. package/lib/cjs/decorators/unique.js +0 -27
  89. package/lib/cjs/decorators/unique.js.map +0 -1
  90. package/lib/cjs/decorators/uppercase.js +0 -28
  91. package/lib/cjs/decorators/uppercase.js.map +0 -1
  92. package/lib/cjs/decorators/versionKey.js +0 -12
  93. package/lib/cjs/decorators/versionKey.js.map +0 -1
  94. package/lib/cjs/decorators/virtualRef.js +0 -38
  95. package/lib/cjs/decorators/virtualRef.js.map +0 -1
  96. package/lib/cjs/index.js +0 -51
  97. package/lib/cjs/index.js.map +0 -1
  98. package/lib/cjs/interfaces/MongooseConnectionOptions.js +0 -3
  99. package/lib/cjs/interfaces/MongooseConnectionOptions.js.map +0 -1
  100. package/lib/cjs/interfaces/MongooseDocument.js +0 -3
  101. package/lib/cjs/interfaces/MongooseDocument.js.map +0 -1
  102. package/lib/cjs/interfaces/MongooseModel.js +0 -3
  103. package/lib/cjs/interfaces/MongooseModel.js.map +0 -1
  104. package/lib/cjs/interfaces/MongooseModelOptions.js +0 -3
  105. package/lib/cjs/interfaces/MongooseModelOptions.js.map +0 -1
  106. package/lib/cjs/interfaces/MongooseSchemaOptions.js +0 -3
  107. package/lib/cjs/interfaces/MongooseSchemaOptions.js.map +0 -1
  108. package/lib/cjs/interfaces/MongooseSchemaTypes.js +0 -10
  109. package/lib/cjs/interfaces/MongooseSchemaTypes.js.map +0 -1
  110. package/lib/cjs/interfaces/MongooseVirtualRefOptions.js +0 -3
  111. package/lib/cjs/interfaces/MongooseVirtualRefOptions.js.map +0 -1
  112. package/lib/cjs/interfaces/interfaces.js +0 -3
  113. package/lib/cjs/interfaces/interfaces.js.map +0 -1
  114. package/lib/cjs/package.json +0 -3
  115. package/lib/cjs/registries/MongooseModels.js +0 -5
  116. package/lib/cjs/registries/MongooseModels.js.map +0 -1
  117. package/lib/cjs/services/MongooseConnections.js +0 -47
  118. package/lib/cjs/services/MongooseConnections.js.map +0 -1
  119. package/lib/cjs/services/MongooseService.js +0 -78
  120. package/lib/cjs/services/MongooseService.js.map +0 -1
  121. package/lib/cjs/utils/createModel.js +0 -44
  122. package/lib/cjs/utils/createModel.js.map +0 -1
  123. package/lib/cjs/utils/createSchema.js +0 -161
  124. package/lib/cjs/utils/createSchema.js.map +0 -1
  125. package/lib/cjs/utils/resolveRefType.js +0 -19
  126. package/lib/cjs/utils/resolveRefType.js.map +0 -1
  127. package/lib/cjs/utils/schemaOptions.js +0 -60
  128. package/lib/cjs/utils/schemaOptions.js.map +0 -1
  129. package/lib/esm/package.json +0 -3
  130. package/lib/types-esm/MongooseModule.d.ts +0 -13
  131. package/lib/types-esm/constants/constants.d.ts +0 -20
  132. package/lib/types-esm/decorators/auto.d.ts +0 -20
  133. package/lib/types-esm/decorators/discriminatorKey.d.ts +0 -1
  134. package/lib/types-esm/decorators/dynamicRef.d.ts +0 -35
  135. package/lib/types-esm/decorators/excludeIndexes.d.ts +0 -20
  136. package/lib/types-esm/decorators/expires.d.ts +0 -20
  137. package/lib/types-esm/decorators/immutable.d.ts +0 -22
  138. package/lib/types-esm/decorators/indexed.d.ts +0 -19
  139. package/lib/types-esm/decorators/lowercase.d.ts +0 -20
  140. package/lib/types-esm/decorators/model.d.ts +0 -39
  141. package/lib/types-esm/decorators/mongooseIndex.d.ts +0 -27
  142. package/lib/types-esm/decorators/mongooseIndexes.d.ts +0 -32
  143. package/lib/types-esm/decorators/mongoosePlugin.d.ts +0 -11
  144. package/lib/types-esm/decorators/numberDecimal.d.ts +0 -32
  145. package/lib/types-esm/decorators/objectID.d.ts +0 -19
  146. package/lib/types-esm/decorators/postHook.d.ts +0 -48
  147. package/lib/types-esm/decorators/preHook.d.ts +0 -49
  148. package/lib/types-esm/decorators/ref.d.ts +0 -38
  149. package/lib/types-esm/decorators/schema.d.ts +0 -54
  150. package/lib/types-esm/decorators/schemaIgnore.d.ts +0 -19
  151. package/lib/types-esm/decorators/select.d.ts +0 -20
  152. package/lib/types-esm/decorators/sparse.d.ts +0 -22
  153. package/lib/types-esm/decorators/text.d.ts +0 -21
  154. package/lib/types-esm/decorators/trim.d.ts +0 -19
  155. package/lib/types-esm/decorators/unique.d.ts +0 -19
  156. package/lib/types-esm/decorators/uppercase.d.ts +0 -20
  157. package/lib/types-esm/decorators/versionKey.d.ts +0 -1
  158. package/lib/types-esm/decorators/virtualRef.d.ts +0 -26
  159. package/lib/types-esm/index.d.ts +0 -47
  160. package/lib/types-esm/interfaces/MongooseConnectionOptions.d.ts +0 -9
  161. package/lib/types-esm/interfaces/MongooseDocument.d.ts +0 -2
  162. package/lib/types-esm/interfaces/MongooseModel.d.ts +0 -8
  163. package/lib/types-esm/interfaces/MongooseModelOptions.d.ts +0 -7
  164. package/lib/types-esm/interfaces/MongooseSchemaOptions.d.ts +0 -36
  165. package/lib/types-esm/interfaces/MongooseSchemaTypes.d.ts +0 -5
  166. package/lib/types-esm/interfaces/MongooseVirtualRefOptions.d.ts +0 -9
  167. package/lib/types-esm/interfaces/interfaces.d.ts +0 -8
  168. package/lib/types-esm/registries/MongooseModels.d.ts +0 -2
  169. package/lib/types-esm/services/MongooseConnections.d.ts +0 -9
  170. package/lib/types-esm/services/MongooseService.d.ts +0 -25
  171. package/lib/types-esm/utils/createModel.d.ts +0 -18
  172. package/lib/types-esm/utils/createSchema.d.ts +0 -28
  173. package/lib/types-esm/utils/resolveRefType.d.ts +0 -5
  174. package/lib/types-esm/utils/schemaOptions.d.ts +0 -14
@@ -1,3 +1,27 @@
1
+ /// <reference types="mongoose/types/aggregate.js" />
2
+ /// <reference types="mongoose/types/callback.js" />
3
+ /// <reference types="mongoose/types/collection.js" />
4
+ /// <reference types="mongoose/types/connection.js" />
5
+ /// <reference types="mongoose/types/cursor.js" />
6
+ /// <reference types="mongoose/types/document.js" />
7
+ /// <reference types="mongoose/types/error.js" />
8
+ /// <reference types="mongoose/types/expressions.js" />
9
+ /// <reference types="mongoose/types/helpers.js" />
10
+ /// <reference types="mongoose/types/middlewares.js" />
11
+ /// <reference types="mongoose/types/indexes.js" />
12
+ /// <reference types="mongoose/types/models.js" />
13
+ /// <reference types="mongoose/types/mongooseoptions.js" />
14
+ /// <reference types="mongoose/types/pipelinestage.js" />
15
+ /// <reference types="mongoose/types/populate.js" />
16
+ /// <reference types="mongoose/types/query.js" />
17
+ /// <reference types="mongoose/types/schemaoptions.js" />
18
+ /// <reference types="mongoose/types/schematypes.js" />
19
+ /// <reference types="mongoose/types/session.js" />
20
+ /// <reference types="mongoose/types/types.js" />
21
+ /// <reference types="mongoose/types/utility.js" />
22
+ /// <reference types="mongoose/types/validation.js" />
23
+ /// <reference types="mongoose/types/virtuals.js" />
24
+ /// <reference types="mongoose/types/inferschematype.js" />
1
25
  import { Schema } from "mongoose";
2
26
  import { MongooseNextCB, MongoosePreHookCB, MongooseSchemaOptions } from "../interfaces/MongooseSchemaOptions.js";
3
27
  /**
package/package.json CHANGED
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "name": "@tsed/mongoose",
3
3
  "description": "Mongoose package for Ts.ED framework",
4
- "type": "commonjs",
5
- "version": "8.0.0-alpha.5",
4
+ "type": "module",
5
+ "version": "8.0.0-alpha.7",
6
6
  "keywords": [
7
7
  "tsed",
8
8
  "mongoose",
@@ -11,14 +11,13 @@
11
11
  "orm"
12
12
  ],
13
13
  "source": "./src/index.ts",
14
- "main": "./lib/cjs/index.js",
14
+ "main": "./lib/esm/index.js",
15
15
  "module": "./lib/esm/index.js",
16
16
  "typings": "./lib/types/index.d.ts",
17
17
  "exports": {
18
18
  ".": {
19
19
  "types": "./lib/types/index.d.ts",
20
20
  "import": "./lib/esm/index.js",
21
- "require": "./lib/cjs/index.js",
22
21
  "default": "./lib/cjs/index.js"
23
22
  }
24
23
  },
@@ -31,30 +30,30 @@
31
30
  },
32
31
  "dependencies": {
33
32
  "change-case": "4.1.2",
34
- "tslib": "2.6.1"
33
+ "tslib": "2.7.0"
35
34
  },
36
35
  "devDependencies": {
37
- "@tsed/ajv": "8.0.0-alpha.5",
38
- "@tsed/barrels": "8.0.0-alpha.5",
39
- "@tsed/core": "8.0.0-alpha.5",
40
- "@tsed/di": "8.0.0-alpha.5",
41
- "@tsed/json-mapper": "8.0.0-alpha.5",
36
+ "@tsed/ajv": "8.0.0-alpha.7",
37
+ "@tsed/barrels": "8.0.0-alpha.7",
38
+ "@tsed/core": "8.0.0-alpha.7",
39
+ "@tsed/di": "8.0.0-alpha.7",
40
+ "@tsed/json-mapper": "8.0.0-alpha.7",
42
41
  "@tsed/logger": ">=6.7.5",
43
- "@tsed/schema": "8.0.0-alpha.5",
44
- "@tsed/testcontainers-mongo": "8.0.0-alpha.5",
45
- "@tsed/typescript": "8.0.0-alpha.5",
46
- "eslint": "^8.57.0",
42
+ "@tsed/schema": "8.0.0-alpha.7",
43
+ "@tsed/testcontainers-mongo": "8.0.0-alpha.7",
44
+ "@tsed/typescript": "8.0.0-alpha.7",
45
+ "eslint": "9.11.1",
47
46
  "mongoose": "6.12.7",
48
- "typescript": "4.9.5",
47
+ "typescript": "5.4.5",
49
48
  "vitest": "2.0.4"
50
49
  },
51
50
  "peerDependencies": {
52
- "@tsed/ajv": "8.0.0-alpha.5",
53
- "@tsed/core": "8.0.0-alpha.5",
54
- "@tsed/di": "8.0.0-alpha.5",
55
- "@tsed/json-mapper": "8.0.0-alpha.5",
51
+ "@tsed/ajv": "8.0.0-alpha.7",
52
+ "@tsed/core": "8.0.0-alpha.7",
53
+ "@tsed/di": "8.0.0-alpha.7",
54
+ "@tsed/json-mapper": "8.0.0-alpha.7",
56
55
  "@tsed/logger": ">=6.7.5",
57
- "@tsed/schema": "8.0.0-alpha.5",
56
+ "@tsed/schema": "8.0.0-alpha.7",
58
57
  "mongoose": ">=6.0.0"
59
58
  },
60
59
  "repository": "https://github.com/tsedio/tsed",
package/vitest.config.mts CHANGED
@@ -12,10 +12,10 @@ export default defineConfig(
12
12
  coverage: {
13
13
  ...presets.test.coverage,
14
14
  thresholds: {
15
- statements: 98.03,
16
- branches: 95,
17
- functions: 100,
18
- lines: 98.03
15
+ statements: 0,
16
+ branches: 0,
17
+ functions: 0,
18
+ lines: 0
19
19
  }
20
20
  }
21
21
  }
@@ -1,36 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.MongooseModule = void 0;
4
- const tslib_1 = require("tslib");
5
- const di_1 = require("@tsed/di");
6
- const di_2 = require("@tsed/di");
7
- const MongooseConnections_js_1 = require("./services/MongooseConnections.js");
8
- const MongooseService_js_1 = require("./services/MongooseService.js");
9
- /**
10
- * @ignore
11
- */
12
- let MongooseModule = class MongooseModule {
13
- constructor(mongooseService, settings) {
14
- this.mongooseService = mongooseService;
15
- this.settings = settings;
16
- // auto configure the cache manager when mongoose is used with @tsed/mongoose
17
- const cache = this.settings.get("cache");
18
- // istanbul ignore next
19
- if (cache?.mongoose) {
20
- cache.connection = this.mongooseService.get();
21
- }
22
- }
23
- $onInit() { }
24
- $onDestroy() {
25
- return this.mongooseService.closeConnections();
26
- }
27
- };
28
- MongooseModule = tslib_1.__decorate([
29
- (0, di_2.Module)({
30
- imports: [MongooseConnections_js_1.MONGOOSE_CONNECTIONS]
31
- }),
32
- tslib_1.__param(1, (0, di_1.Configuration)()),
33
- tslib_1.__metadata("design:paramtypes", [MongooseService_js_1.MongooseService, Object])
34
- ], MongooseModule);
35
- exports.MongooseModule = MongooseModule;
36
- //# sourceMappingURL=MongooseModule.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"MongooseModule.js","sourceRoot":"","sources":["../../src/MongooseModule.ts"],"names":[],"mappings":";;;;AAAA,iCAA+C;AAC/C,iCAA2C;AAC3C,8EAAuE;AACvE,sEAA8D;AAE9D;;GAEG;AAII,IAAM,cAAc,GAApB,MAAM,cAAc;IACzB,YACU,eAAgC,EACf,QAAuB;QADxC,oBAAe,GAAf,eAAe,CAAiB;QACf,aAAQ,GAAR,QAAQ,CAAe;QAEhD,6EAA6E;QAC7E,MAAM,KAAK,GAAG,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAM,OAAO,CAAC,CAAC;QAE9C,uBAAuB;QACvB,IAAI,KAAK,EAAE,QAAQ,EAAE;YACnB,KAAK,CAAC,UAAU,GAAG,IAAI,CAAC,eAAe,CAAC,GAAG,EAAE,CAAC;SAC/C;IACH,CAAC;IAED,OAAO,KAAyB,CAAC;IAEjC,UAAU;QACR,OAAO,IAAI,CAAC,eAAe,CAAC,gBAAgB,EAAE,CAAC;IACjD,CAAC;CACF,CAAA;AAnBY,cAAc;IAH1B,IAAA,WAAM,EAAC;QACN,OAAO,EAAE,CAAC,6CAAoB,CAAC;KAChC,CAAC;IAIG,mBAAA,IAAA,kBAAa,GAAE,CAAA;6CADS,oCAAe;GAF/B,cAAc,CAmB1B;AAnBY,wCAAc"}
@@ -1,24 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.MONGOOSE_MODEL_NAME = exports.MONGOOSE_MODEL = exports.MONGOOSE_SCHEMA_OPTIONS = exports.MONGOOSE_SCHEMA = void 0;
4
- /**
5
- *
6
- * @type {string}
7
- */
8
- exports.MONGOOSE_SCHEMA = "tsed:mongoose:schema";
9
- /**
10
- *
11
- * @type {string}
12
- */
13
- exports.MONGOOSE_SCHEMA_OPTIONS = "tsed:mongoose:schema:options";
14
- /**
15
- *
16
- * @type {string}
17
- */
18
- exports.MONGOOSE_MODEL = "tsed:mongoose:model";
19
- /**
20
- *
21
- * @type {string}
22
- */
23
- exports.MONGOOSE_MODEL_NAME = "tsed:mongoose:model:name";
24
- //# sourceMappingURL=constants.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"constants.js","sourceRoot":"","sources":["../../../src/constants/constants.ts"],"names":[],"mappings":";;;AAAA;;;GAGG;AACU,QAAA,eAAe,GAAG,sBAAsB,CAAC;AACtD;;;GAGG;AACU,QAAA,uBAAuB,GAAG,8BAA8B,CAAC;AACtE;;;GAGG;AACU,QAAA,cAAc,GAAG,qBAAqB,CAAC;AACpD;;;GAGG;AACU,QAAA,mBAAmB,GAAG,0BAA0B,CAAC"}
@@ -1,28 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.Auto = void 0;
4
- const schema_js_1 = require("./schema.js");
5
- /**
6
- * If true, uses Mongoose's default _id settings. Only allowed for ObjectIds
7
- *
8
- * ### Example
9
- *
10
- * ```typescript
11
- * @Model()
12
- * export class EventModel {
13
- * @ExcludeIndexes()
14
- * field: string;
15
- * }
16
- * ```
17
- *
18
- * @param {boolean} auto
19
- * @returns {Function}
20
- * @decorator
21
- * @mongoose
22
- * @property
23
- */
24
- function Auto(auto = true) {
25
- return (0, schema_js_1.MongooseSchema)({ auto });
26
- }
27
- exports.Auto = Auto;
28
- //# sourceMappingURL=auto.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"auto.js","sourceRoot":"","sources":["../../../src/decorators/auto.ts"],"names":[],"mappings":";;;AAAA,2CAA2C;AAE3C;;;;;;;;;;;;;;;;;;GAkBG;AACH,SAAgB,IAAI,CAAC,OAAgB,IAAI;IACvC,OAAO,IAAA,0BAAc,EAAC,EAAC,IAAI,EAAQ,CAAC,CAAC;AACvC,CAAC;AAFD,oBAEC"}
@@ -1,6 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.DiscriminatorKey = void 0;
4
- var schema_1 = require("@tsed/schema");
5
- Object.defineProperty(exports, "DiscriminatorKey", { enumerable: true, get: function () { return schema_1.DiscriminatorKey; } });
6
- //# sourceMappingURL=discriminatorKey.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"discriminatorKey.js","sourceRoot":"","sources":["../../../src/decorators/discriminatorKey.ts"],"names":[],"mappings":";;;AAAA,uCAA8C;AAAtC,0GAAA,gBAAgB,OAAA"}
@@ -1,65 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.DynamicRef = void 0;
4
- const core_1 = require("@tsed/core");
5
- const schema_1 = require("@tsed/schema");
6
- const mongoose_1 = require("mongoose");
7
- const constants_js_1 = require("../constants/constants.js");
8
- const json_mapper_1 = require("@tsed/json-mapper");
9
- const MongooseModels_js_1 = require("../registries/MongooseModels.js");
10
- function isRef(value) {
11
- return (value && value._bsontype) || (0, core_1.isString)(value);
12
- }
13
- function getType(refPath, ctx) {
14
- return (ctx?.self[refPath] && MongooseModels_js_1.MongooseModels.get(ctx.self[refPath])) || Object;
15
- }
16
- /**
17
- * Define a property as mongoose reference to other Model (decorated with @Model).
18
- *
19
- * ### Example
20
- *
21
- * ```typescript
22
- * @Model()
23
- * class FooModel {
24
- *
25
- * @DynamicRef('type')
26
- * field: DynamicRef<OtherFooModel | OtherModel>
27
- *
28
- * @Enum(['OtherFooModel', 'OtherModel'])
29
- * type: string
30
- * }
31
- *
32
- * @Model()
33
- * class OtherFooModel {
34
- * }
35
- *
36
- * @Model()
37
- * class OtherModel {
38
- * }
39
- * ```
40
- *
41
- * @param refPath {String} the path to apply the correct model
42
- * @param types {Type} the classes to generate the correct json schema
43
- * @returns {Function}
44
- * @decorator
45
- * @mongoose
46
- * @property
47
- */
48
- function DynamicRef(refPath, ...types) {
49
- return (0, core_1.useDecorators)((0, schema_1.Property)(Object), (0, schema_1.Example)("5ce7ad3028890bd71749d477"), (0, schema_1.Description)("A reference ObjectID"), (0, core_1.StoreMerge)(constants_js_1.MONGOOSE_SCHEMA, {
50
- type: mongoose_1.Schema.Types.ObjectId,
51
- refPath
52
- }), (0, json_mapper_1.OnDeserialize)((value, ctx) => {
53
- if (isRef(value)) {
54
- return value.toString();
55
- }
56
- return (0, json_mapper_1.deserialize)(value, { ...ctx, type: getType(refPath, ctx) });
57
- }), (0, json_mapper_1.OnSerialize)((value, ctx) => {
58
- if (isRef(value)) {
59
- return value.toString();
60
- }
61
- return (0, json_mapper_1.serialize)(value, { ...ctx, type: getType(refPath, ctx) });
62
- }), (0, schema_1.OneOf)((0, schema_1.string)().example("5ce7ad3028890bd71749d477").description("A reference ObjectID"), ...types));
63
- }
64
- exports.DynamicRef = DynamicRef;
65
- //# sourceMappingURL=dynamicRef.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"dynamicRef.js","sourceRoot":"","sources":["../../../src/decorators/dynamicRef.ts"],"names":[],"mappings":";;;AAAA,qCAAyF;AACzF,yCAA4F;AAC5F,uCAAkD;AAClD,4DAA0D;AAC1D,mDAAqF;AACrF,uEAA+D;AAE/D,SAAS,KAAK,CAAC,KAA+B;IAC5C,OAAO,CAAC,KAAK,IAAI,KAAK,CAAC,SAAS,CAAC,IAAI,IAAA,eAAQ,EAAC,KAAK,CAAC,CAAC;AACvD,CAAC;AAED,SAAS,OAAO,CAAC,OAAe,EAAE,GAAoB;IACpD,OAAO,CAAC,GAAG,EAAE,IAAI,CAAC,OAAO,CAAC,IAAI,kCAAc,CAAC,GAAG,CAAC,GAAG,CAAC,IAAI,CAAC,OAAO,CAAW,CAAC,CAAC,IAAI,MAAM,CAAC;AAC3F,CAAC;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AACH,SAAgB,UAAU,CAAC,OAAe,EAAE,GAAG,KAAkB;IAC/D,OAAO,IAAA,oBAAa,EAClB,IAAA,iBAAQ,EAAC,MAAM,CAAC,EAChB,IAAA,gBAAO,EAAC,0BAA0B,CAAC,EACnC,IAAA,oBAAW,EAAC,sBAAsB,CAAC,EACnC,IAAA,iBAAU,EAAC,8BAAe,EAAE;QAC1B,IAAI,EAAE,iBAAc,CAAC,KAAK,CAAC,QAAQ;QACnC,OAAO;KACR,CAAC,EACF,IAAA,2BAAa,EAAC,CAAC,KAAK,EAAE,GAAG,EAAE,EAAE;QAC3B,IAAI,KAAK,CAAC,KAAK,CAAC,EAAE;YAChB,OAAO,KAAK,CAAC,QAAQ,EAAE,CAAC;SACzB;QAED,OAAO,IAAA,yBAAW,EAAC,KAAK,EAAE,EAAC,GAAG,GAAG,EAAE,IAAI,EAAE,OAAO,CAAC,OAAO,EAAE,GAAG,CAAC,EAAC,CAAC,CAAC;IACnE,CAAC,CAAC,EACF,IAAA,yBAAW,EAAC,CAAC,KAAU,EAAE,GAAG,EAAE,EAAE;QAC9B,IAAI,KAAK,CAAC,KAAK,CAAC,EAAE;YAChB,OAAO,KAAK,CAAC,QAAQ,EAAE,CAAC;SACzB;QAED,OAAO,IAAA,uBAAS,EAAC,KAAK,EAAE,EAAC,GAAG,GAAG,EAAE,IAAI,EAAE,OAAO,CAAC,OAAO,EAAE,GAAG,CAAC,EAAC,CAAC,CAAC;IACjE,CAAC,CAAC,EACF,IAAA,cAAK,EAAC,IAAA,eAAM,GAAE,CAAC,OAAO,CAAC,0BAA0B,CAAC,CAAC,WAAW,CAAC,sBAAsB,CAAC,EAAE,GAAG,KAAK,CAAC,CAC7E,CAAC;AACzB,CAAC;AAzBD,gCAyBC"}
@@ -1,28 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.ExcludeIndexes = void 0;
4
- const schema_js_1 = require("./schema.js");
5
- /**
6
- * If true, Mongoose will skip gathering indexes on subpaths. Only allowed for subdocuments and subdocument arrays.
7
- *
8
- * ### Example
9
- *
10
- * ```typescript
11
- * @Model()
12
- * export class EventModel {
13
- * @ExcludeIndexes()
14
- * field: string;
15
- * }
16
- * ```
17
- *
18
- * @param {boolean} excludeIndexes
19
- * @returns {Function}
20
- * @decorator
21
- * @mongoose
22
- * @property
23
- */
24
- function ExcludeIndexes(excludeIndexes = true) {
25
- return (0, schema_js_1.MongooseSchema)({ excludeIndexes });
26
- }
27
- exports.ExcludeIndexes = ExcludeIndexes;
28
- //# sourceMappingURL=excludeIndexes.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"excludeIndexes.js","sourceRoot":"","sources":["../../../src/decorators/excludeIndexes.ts"],"names":[],"mappings":";;;AAAA,2CAA2C;AAE3C;;;;;;;;;;;;;;;;;;GAkBG;AACH,SAAgB,cAAc,CAAC,iBAA0B,IAAI;IAC3D,OAAO,IAAA,0BAAc,EAAC,EAAC,cAAc,EAAQ,CAAC,CAAC;AACjD,CAAC;AAFD,wCAEC"}
@@ -1,28 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.Expires = void 0;
4
- const schema_js_1 = require("./schema.js");
5
- /**
6
- * Defines a TTL index on this path. Only allowed for dates.
7
- *
8
- * ### Example
9
- *
10
- * ```typescript
11
- * @Model()
12
- * export class EventModel {
13
- * @Expires('5d')
14
- * field: string;
15
- * }
16
- * ```
17
- *
18
- * @param {boolean | any} expires
19
- * @returns {Function}
20
- * @decorator
21
- * @mongoose
22
- * @property
23
- */
24
- function Expires(expires) {
25
- return (0, schema_js_1.MongooseSchema)({ expires });
26
- }
27
- exports.Expires = Expires;
28
- //# sourceMappingURL=expires.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"expires.js","sourceRoot":"","sources":["../../../src/decorators/expires.ts"],"names":[],"mappings":";;;AAAA,2CAA2C;AAE3C;;;;;;;;;;;;;;;;;;GAkBG;AACH,SAAgB,OAAO,CAAC,OAA+B;IACrD,OAAO,IAAA,0BAAc,EAAC,EAAC,OAAO,EAAQ,CAAC,CAAC;AAC1C,CAAC;AAFD,0BAEC"}
@@ -1,30 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.Immutable = void 0;
4
- const schema_js_1 = require("./schema.js");
5
- /**
6
- * If [truthy](https://masteringjs.io/tutorials/fundamentals/truthy), Mongoose will
7
- * disallow changes to this path once the document is saved to the database for the first time. Read more
8
- * about [immutability in Mongoose here](http://thecodebarbarian.com/whats-new-in-mongoose-5-6-immutable-properties.html).
9
- *
10
- * ### Example
11
- *
12
- * ```typescript
13
- * @Model()
14
- * export class EventModel {
15
- * @Immutable()
16
- * field: string;
17
- * }
18
- * ```
19
- *
20
- * @param {boolean | any} immutable
21
- * @returns {Function}
22
- * @decorator
23
- * @mongoose
24
- * @property
25
- */
26
- function Immutable(immutable = true) {
27
- return (0, schema_js_1.MongooseSchema)({ immutable });
28
- }
29
- exports.Immutable = Immutable;
30
- //# sourceMappingURL=immutable.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"immutable.js","sourceRoot":"","sources":["../../../src/decorators/immutable.ts"],"names":[],"mappings":";;;AAAA,2CAA2C;AAE3C;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,SAAgB,SAAS,CAAC,YAA0D,IAAI;IACtF,OAAO,IAAA,0BAAc,EAAC,EAAC,SAAS,EAAQ,CAAC,CAAC;AAC5C,CAAC;AAFD,8BAEC"}
@@ -1,26 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.Indexed = void 0;
4
- const schema_js_1 = require("./schema.js");
5
- /**
6
- * Tell Mongoose whether to define an index for the property.
7
- * ### Example
8
- *
9
- * ```typescript
10
- * @Model()
11
- * export class EventModel {
12
- * @Indexed()
13
- * field: string;
14
- * }
15
- * ```
16
- *
17
- * @returns {Function}
18
- * @decorator
19
- * @mongoose
20
- * @property
21
- */
22
- function Indexed(index = true) {
23
- return (0, schema_js_1.MongooseSchema)({ index });
24
- }
25
- exports.Indexed = Indexed;
26
- //# sourceMappingURL=indexed.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"indexed.js","sourceRoot":"","sources":["../../../src/decorators/indexed.ts"],"names":[],"mappings":";;;AACA,2CAA2C;AAE3C;;;;;;;;;;;;;;;;GAgBG;AACH,SAAgB,OAAO,CAAC,QAAyC,IAAI;IACnE,OAAO,IAAA,0BAAc,EAAC,EAAC,KAAK,EAAQ,CAAC,CAAC;AACxC,CAAC;AAFD,0BAEC"}
@@ -1,28 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.Lowercase = void 0;
4
- const schema_js_1 = require("./schema.js");
5
- /**
6
- * If truthy, Mongoose will add a custom setter that lowercases this string using JavaScript's built-in String#toLowerCase().
7
- *
8
- * ### Example
9
- *
10
- * ```typescript
11
- * @Model()
12
- * export class EventModel {
13
- * @Lowercase()
14
- * field: string;
15
- * }
16
- * ```
17
- *
18
- * @param {boolean} lowercase
19
- * @returns {Function}
20
- * @decorator
21
- * @mongoose
22
- * @property
23
- */
24
- function Lowercase(lowercase = true) {
25
- return (0, schema_js_1.MongooseSchema)({ lowercase });
26
- }
27
- exports.Lowercase = Lowercase;
28
- //# sourceMappingURL=lowercase.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"lowercase.js","sourceRoot":"","sources":["../../../src/decorators/lowercase.ts"],"names":[],"mappings":";;;AAAA,2CAA2C;AAE3C;;;;;;;;;;;;;;;;;;GAkBG;AACH,SAAgB,SAAS,CAAC,YAAqB,IAAI;IACjD,OAAO,IAAA,0BAAc,EAAC,EAAC,SAAS,EAAQ,CAAC,CAAC;AAC5C,CAAC;AAFD,8BAEC"}
@@ -1,69 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.Model = void 0;
4
- const core_1 = require("@tsed/core");
5
- const di_1 = require("@tsed/di");
6
- const MongooseConnections_js_1 = require("../services/MongooseConnections.js");
7
- const createModel_js_1 = require("../utils/createModel.js");
8
- const createSchema_js_1 = require("../utils/createSchema.js");
9
- const schemaOptions_js_1 = require("../utils/schemaOptions.js");
10
- /**
11
- * Define a class as a Mongoose Model. The model can be injected to the Service, Controller, Middleware, Converters or Filter with
12
- * `@Inject` annotation.
13
- *
14
- * ### Example
15
- *
16
- * ```typescript
17
- * @Model()
18
- * export class EventModel {
19
- * @Property()
20
- * field: string;
21
- * }
22
- * ```
23
- *
24
- * Then inject the model into a service:
25
- *
26
- * ```typescript
27
- * class MyService {
28
- * constructor(@Inject(EventModel) eventModel: MongooseModel<EventModel>) {
29
- * eventModel.findById().exec();
30
- * }
31
- * }
32
- * ```
33
- *
34
- * ### Options
35
- *
36
- * - `schemaOptions` (mongoose.SchemaOptions): Option to configure the schema behavior.
37
- * - `name` (String): model name.
38
- * - `collection` (String): collection (optional, induced from model name).
39
- * - `skipInit` (Boolean): skipInit whether to skip initialization (defaults to false).
40
- *
41
- * @param {MongooseModelOptions} options
42
- * @returns {(target: any) => void}
43
- * @decorator
44
- * @mongoose
45
- * @class
46
- */
47
- function Model(options = {}) {
48
- return (0, core_1.useDecorators)((target) => {
49
- const { token, collectionName } = (0, createModel_js_1.getModelToken)(target, options);
50
- (0, di_1.registerProvider)({
51
- provide: token,
52
- deps: [],
53
- useFactory() {
54
- return (0, createSchema_js_1.getSchema)(target, options);
55
- }
56
- });
57
- (0, di_1.registerProvider)({
58
- provide: target,
59
- type: "mongoose:model",
60
- deps: [MongooseConnections_js_1.MONGOOSE_CONNECTIONS, token],
61
- useFactory(connections, schema) {
62
- (0, schemaOptions_js_1.applySchemaOptions)(schema, (0, schemaOptions_js_1.schemaOptions)(target));
63
- return (0, createModel_js_1.createModel)(target, schema, collectionName, options.collection, options.overwriteModels, connections.get(options.connection));
64
- }
65
- });
66
- });
67
- }
68
- exports.Model = Model;
69
- //# sourceMappingURL=model.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"model.js","sourceRoot":"","sources":["../../../src/decorators/model.ts"],"names":[],"mappings":";;;AAAA,qCAAiD;AACjD,iCAA0C;AAI1C,+EAAwE;AACxE,4DAAmE;AACnE,8DAAmD;AACnD,gEAA4E;AAE5E;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoCG;AACH,SAAgB,KAAK,CAAC,UAAgC,EAAE;IACtD,OAAO,IAAA,oBAAa,EAAC,CAAC,MAAW,EAAE,EAAE;QACnC,MAAM,EAAC,KAAK,EAAE,cAAc,EAAC,GAAG,IAAA,8BAAa,EAAC,MAAM,EAAE,OAAO,CAAC,CAAC;QAE/D,IAAA,qBAAgB,EAAC;YACf,OAAO,EAAE,KAAK;YACd,IAAI,EAAE,EAAE;YACR,UAAU;gBACR,OAAO,IAAA,2BAAS,EAAC,MAAM,EAAE,OAAc,CAAC,CAAC;YAC3C,CAAC;SACF,CAAC,CAAC;QAEH,IAAA,qBAAgB,EAAC;YACf,OAAO,EAAE,MAAM;YACf,IAAI,EAAE,gBAAgB;YACtB,IAAI,EAAE,CAAC,6CAAoB,EAAE,KAAK,CAAC;YACnC,UAAU,CAAC,WAAiC,EAAE,MAAc;gBAC1D,IAAA,qCAAkB,EAAC,MAAM,EAAE,IAAA,gCAAa,EAAC,MAAM,CAAC,CAAC,CAAC;gBAClD,OAAO,IAAA,4BAAW,EAChB,MAAM,EACN,MAAM,EACN,cAAc,EACd,OAAO,CAAC,UAAU,EAClB,OAAO,CAAC,eAAe,EACvB,WAAW,CAAC,GAAG,CAAC,OAAO,CAAC,UAAU,CAAC,CACpC,CAAC;YACJ,CAAC;SACF,CAAC,CAAC;IACL,CAAC,CAAC,CAAC;AACL,CAAC;AA7BD,sBA6BC"}
@@ -1,39 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.MongooseIndex = void 0;
4
- const schemaOptions_js_1 = require("../utils/schemaOptions.js");
5
- /**
6
- * Calls schema.index() to define an index (most likely compound) for the schema.
7
- *
8
- * ### Example
9
- *
10
- * ```typescript
11
- * @Model()
12
- * @MongooseIndex({first: 1, second: 1}, {unique: 1})
13
- * export class EventModel {
14
- *
15
- * @Property()
16
- * first: string;
17
- *
18
- * @Property()
19
- * second: string;
20
- *
21
- * }
22
- * ```
23
- *
24
- * @param fields
25
- * @param options
26
- * @returns {Function}
27
- * @decorator
28
- * @mongoose
29
- * @class
30
- */
31
- function MongooseIndex(fields, options) {
32
- return (target) => {
33
- (0, schemaOptions_js_1.schemaOptions)(target, {
34
- indexes: [{ fields, options }]
35
- });
36
- };
37
- }
38
- exports.MongooseIndex = MongooseIndex;
39
- //# sourceMappingURL=mongooseIndex.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"mongooseIndex.js","sourceRoot":"","sources":["../../../src/decorators/mongooseIndex.ts"],"names":[],"mappings":";;;AAAA,gEAAwD;AAExD;;;;;;;;;;;;;;;;;;;;;;;;;GAyBG;AACH,SAAgB,aAAa,CAAC,MAAc,EAAE,OAAa;IACzD,OAAO,CAAC,MAAW,EAAE,EAAE;QACrB,IAAA,gCAAa,EAAC,MAAM,EAAE;YACpB,OAAO,EAAE,CAAC,EAAC,MAAM,EAAE,OAAO,EAAC,CAAC;SAC7B,CAAC,CAAC;IACL,CAAC,CAAC;AACJ,CAAC;AAND,sCAMC"}
@@ -1,39 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.MongooseIndexes = void 0;
4
- const schemaOptions_js_1 = require("../utils/schemaOptions.js");
5
- /**
6
- * Calls schema.index() to define multiple indexes (most likely compound) for the schema.
7
- *
8
- * ### Example
9
- *
10
- * ```typescript
11
- * @Model()
12
- * @MongooseIndexes([{fields: {first: 1, second: 1}, options:{unique: 1}}, {fields: {first: 1, third: 1}, options:{unique: 1}}])
13
- * export class EventModel {
14
- *
15
- * @Property()
16
- * first: string;
17
- *
18
- * @Property()
19
- * second: string;
20
- *
21
- * @Property()
22
- * third: string;
23
- *
24
- * }
25
- * ```
26
- *
27
- * @param indexes - define multiple mongoose indexes
28
- * @returns {Function}
29
- * @decorator
30
- * @mongoose
31
- * @class
32
- */
33
- function MongooseIndexes(indexes) {
34
- return (target) => {
35
- (0, schemaOptions_js_1.schemaOptions)(target, { indexes });
36
- };
37
- }
38
- exports.MongooseIndexes = MongooseIndexes;
39
- //# sourceMappingURL=mongooseIndexes.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"mongooseIndexes.js","sourceRoot":"","sources":["../../../src/decorators/mongooseIndexes.ts"],"names":[],"mappings":";;;AAAA,gEAAwD;AAExD;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AACH,SAAgB,eAAe,CAAC,OAA+C;IAC7E,OAAO,CAAC,MAAW,EAAE,EAAE;QACrB,IAAA,gCAAa,EAAC,MAAM,EAAE,EAAC,OAAO,EAAC,CAAC,CAAC;IACnC,CAAC,CAAC;AACJ,CAAC;AAJD,0CAIC"}
@@ -1,22 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.MongoosePlugin = void 0;
4
- const schemaOptions_js_1 = require("../utils/schemaOptions.js");
5
- /**
6
- *
7
- * @param {(schema: "mongoose".Schema, options?: any) => void} plugin
8
- * @param options
9
- * @returns {Function}
10
- * @decorator
11
- * @mongoose
12
- * @class
13
- */
14
- function MongoosePlugin(plugin, options) {
15
- return (target) => {
16
- (0, schemaOptions_js_1.schemaOptions)(target, {
17
- plugins: [{ plugin, options }]
18
- });
19
- };
20
- }
21
- exports.MongoosePlugin = MongoosePlugin;
22
- //# sourceMappingURL=mongoosePlugin.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"mongoosePlugin.js","sourceRoot":"","sources":["../../../src/decorators/mongoosePlugin.ts"],"names":[],"mappings":";;;AACA,gEAAwD;AAExD;;;;;;;;GAQG;AACH,SAAgB,cAAc,CAAC,MAAwD,EAAE,OAAa;IACpG,OAAO,CAAC,MAAW,EAAE,EAAE;QACrB,IAAA,gCAAa,EAAC,MAAM,EAAE;YACpB,OAAO,EAAE,CAAC,EAAC,MAAM,EAAE,OAAO,EAAC,CAAC;SAC7B,CAAC,CAAC;IACL,CAAC,CAAC;AACJ,CAAC;AAND,wCAMC"}