Leon4gr45 commited on
Commit
cfbbc1a
·
verified ·
1 Parent(s): cd6720a

Include updated package-lock.json (part 10)

Browse files
This view is limited to 50 files because it contains too many changes.   See raw diff
Files changed (50) hide show
  1. node_modules/@nestjs/common/interfaces/modules/module-metadata.interface.js +2 -0
  2. node_modules/@nestjs/common/interfaces/modules/nest-module.interface.d.ts +7 -0
  3. node_modules/@nestjs/common/interfaces/modules/nest-module.interface.js +2 -0
  4. node_modules/@nestjs/common/interfaces/modules/optional-factory-dependency.interface.d.ts +8 -0
  5. node_modules/@nestjs/common/interfaces/modules/optional-factory-dependency.interface.js +2 -0
  6. node_modules/@nestjs/common/interfaces/modules/provider.interface.d.ts +156 -0
  7. node_modules/@nestjs/common/interfaces/modules/provider.interface.js +2 -0
  8. node_modules/@nestjs/common/interfaces/nest-application-context-options.interface.d.ts +68 -0
  9. node_modules/@nestjs/common/interfaces/nest-application-context-options.interface.js +9 -0
  10. node_modules/@nestjs/common/interfaces/nest-application-context.interface.d.ts +139 -0
  11. node_modules/@nestjs/common/interfaces/nest-application-context.interface.js +2 -0
  12. node_modules/@nestjs/common/interfaces/nest-application-options.interface.d.ts +29 -0
  13. node_modules/@nestjs/common/interfaces/nest-application-options.interface.js +2 -0
  14. node_modules/@nestjs/common/interfaces/nest-application.interface.d.ts +135 -0
  15. node_modules/@nestjs/common/interfaces/nest-application.interface.js +2 -0
  16. node_modules/@nestjs/common/interfaces/nest-microservice.interface.d.ts +75 -0
  17. node_modules/@nestjs/common/interfaces/nest-microservice.interface.js +2 -0
  18. node_modules/@nestjs/common/interfaces/router-options.interface.d.ts +28 -0
  19. node_modules/@nestjs/common/interfaces/router-options.interface.js +1 -0
  20. node_modules/@nestjs/common/interfaces/scope-options.interface.d.ts +37 -0
  21. node_modules/@nestjs/common/interfaces/scope-options.interface.js +23 -0
  22. node_modules/@nestjs/common/interfaces/shutdown-hooks-options.interface.d.ts +21 -0
  23. node_modules/@nestjs/common/interfaces/shutdown-hooks-options.interface.js +2 -0
  24. node_modules/@nestjs/common/interfaces/type.interface.d.ts +3 -0
  25. node_modules/@nestjs/common/interfaces/type.interface.js +2 -0
  26. node_modules/@nestjs/common/interfaces/version-options.interface.d.ts +92 -0
  27. node_modules/@nestjs/common/interfaces/version-options.interface.js +9 -0
  28. node_modules/@nestjs/common/interfaces/websockets/web-socket-adapter.interface.d.ts +19 -0
  29. node_modules/@nestjs/common/interfaces/websockets/web-socket-adapter.interface.js +2 -0
  30. node_modules/@nestjs/common/internal.d.ts +30 -0
  31. node_modules/@nestjs/common/internal.js +19 -0
  32. node_modules/@nestjs/common/module-utils/configurable-module.builder.d.ts +93 -0
  33. node_modules/@nestjs/common/module-utils/configurable-module.builder.js +219 -0
  34. node_modules/@nestjs/common/module-utils/constants.d.ts +9 -0
  35. node_modules/@nestjs/common/module-utils/constants.js +19 -0
  36. node_modules/@nestjs/common/module-utils/index.d.ts +2 -0
  37. node_modules/@nestjs/common/module-utils/index.js +5 -0
  38. node_modules/@nestjs/common/module-utils/interfaces/configurable-module-async-options.interface.d.ts +42 -0
  39. node_modules/@nestjs/common/module-utils/interfaces/configurable-module-async-options.interface.js +2 -0
  40. node_modules/@nestjs/common/module-utils/interfaces/configurable-module-cls.interface.d.ts +13 -0
  41. node_modules/@nestjs/common/module-utils/interfaces/configurable-module-cls.interface.js +2 -0
  42. node_modules/@nestjs/common/module-utils/interfaces/configurable-module-host.interface.d.ts +62 -0
  43. node_modules/@nestjs/common/module-utils/interfaces/configurable-module-host.interface.js +2 -0
  44. node_modules/@nestjs/common/module-utils/interfaces/index.d.ts +3 -0
  45. node_modules/@nestjs/common/module-utils/interfaces/index.js +6 -0
  46. node_modules/@nestjs/common/module-utils/utils/generate-options-injection-token.util.d.ts +1 -0
  47. node_modules/@nestjs/common/module-utils/utils/generate-options-injection-token.util.js +8 -0
  48. node_modules/@nestjs/common/module-utils/utils/get-injection-providers.util.d.ts +8 -0
  49. node_modules/@nestjs/common/module-utils/utils/get-injection-providers.util.js +35 -0
  50. node_modules/@nestjs/common/module-utils/utils/index.d.ts +2 -0
node_modules/@nestjs/common/interfaces/modules/module-metadata.interface.js ADDED
@@ -0,0 +1,2 @@
 
 
 
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
node_modules/@nestjs/common/interfaces/modules/nest-module.interface.d.ts ADDED
@@ -0,0 +1,7 @@
 
 
 
 
 
 
 
 
1
+ import { MiddlewareConsumer } from '../middleware/middleware-consumer.interface';
2
+ /**
3
+ * @publicApi
4
+ */
5
+ export interface NestModule {
6
+ configure(consumer: MiddlewareConsumer): any;
7
+ }
node_modules/@nestjs/common/interfaces/modules/nest-module.interface.js ADDED
@@ -0,0 +1,2 @@
 
 
 
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
node_modules/@nestjs/common/interfaces/modules/optional-factory-dependency.interface.d.ts ADDED
@@ -0,0 +1,8 @@
 
 
 
 
 
 
 
 
 
1
+ import { InjectionToken } from './injection-token.interface';
2
+ /**
3
+ * @publicApi
4
+ */
5
+ export type OptionalFactoryDependency = {
6
+ token: InjectionToken;
7
+ optional: boolean;
8
+ };
node_modules/@nestjs/common/interfaces/modules/optional-factory-dependency.interface.js ADDED
@@ -0,0 +1,2 @@
 
 
 
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
node_modules/@nestjs/common/interfaces/modules/provider.interface.d.ts ADDED
@@ -0,0 +1,156 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import { Scope } from '../scope-options.interface';
2
+ import { Type } from '../type.interface';
3
+ import { InjectionToken } from './injection-token.interface';
4
+ import { OptionalFactoryDependency } from './optional-factory-dependency.interface';
5
+ /**
6
+ *
7
+ * @publicApi
8
+ */
9
+ export type Provider<T = any> = Type<any> | ClassProvider<T> | ValueProvider<T> | FactoryProvider<T> | ExistingProvider<T>;
10
+ /**
11
+ * Interface defining a *Class* type provider.
12
+ *
13
+ * For example:
14
+ * ```typescript
15
+ * const configServiceProvider = {
16
+ * provide: ConfigService,
17
+ * useClass:
18
+ * process.env.NODE_ENV === 'development'
19
+ * ? DevelopmentConfigService
20
+ * : ProductionConfigService,
21
+ * };
22
+ * ```
23
+ *
24
+ * @see [Class providers](https://docs.nestjs.com/fundamentals/custom-providers#class-providers-useclass)
25
+ * @see [Injection scopes](https://docs.nestjs.com/fundamentals/injection-scopes)
26
+ *
27
+ * @publicApi
28
+ */
29
+ export interface ClassProvider<T = any> {
30
+ /**
31
+ * Injection token
32
+ */
33
+ provide: InjectionToken;
34
+ /**
35
+ * Type (class name) of provider (instance to be injected).
36
+ */
37
+ useClass: Type<T>;
38
+ /**
39
+ * Optional enum defining lifetime of the provider that is injected.
40
+ */
41
+ scope?: Scope;
42
+ /**
43
+ * This option is only available on factory providers!
44
+ *
45
+ * @see [Use factory](https://docs.nestjs.com/fundamentals/custom-providers#factory-providers-usefactory)
46
+ */
47
+ inject?: never;
48
+ /**
49
+ * Flags provider as durable. This flag can be used in combination with custom context id
50
+ * factory strategy to construct lazy DI subtrees.
51
+ *
52
+ * This flag can be used only in conjunction with scope = Scope.REQUEST.
53
+ */
54
+ durable?: boolean;
55
+ }
56
+ /**
57
+ * Interface defining a *Value* type provider.
58
+ *
59
+ * For example:
60
+ * ```typescript
61
+ * const connectionProvider = {
62
+ * provide: 'CONNECTION',
63
+ * useValue: connection,
64
+ * };
65
+ * ```
66
+ *
67
+ * @see [Value providers](https://docs.nestjs.com/fundamentals/custom-providers#value-providers-usevalue)
68
+ *
69
+ * @publicApi
70
+ */
71
+ export interface ValueProvider<T = any> {
72
+ /**
73
+ * Injection token
74
+ */
75
+ provide: InjectionToken;
76
+ /**
77
+ * Instance of a provider to be injected.
78
+ */
79
+ useValue: T;
80
+ /**
81
+ * This option is only available on factory providers!
82
+ *
83
+ * @see [Use factory](https://docs.nestjs.com/fundamentals/custom-providers#factory-providers-usefactory)
84
+ */
85
+ inject?: never;
86
+ }
87
+ /**
88
+ * Interface defining a *Factory* type provider.
89
+ *
90
+ * For example:
91
+ * ```typescript
92
+ * const connectionFactory = {
93
+ * provide: 'CONNECTION',
94
+ * useFactory: (optionsProvider: OptionsProvider) => {
95
+ * const options = optionsProvider.get();
96
+ * return new DatabaseConnection(options);
97
+ * },
98
+ * inject: [OptionsProvider],
99
+ * };
100
+ * ```
101
+ *
102
+ * @see [Factory providers](https://docs.nestjs.com/fundamentals/custom-providers#factory-providers-usefactory)
103
+ * @see [Injection scopes](https://docs.nestjs.com/fundamentals/injection-scopes)
104
+ *
105
+ * @publicApi
106
+ */
107
+ export interface FactoryProvider<T = any> {
108
+ /**
109
+ * Injection token
110
+ */
111
+ provide: InjectionToken;
112
+ /**
113
+ * Factory function that returns an instance of the provider to be injected.
114
+ */
115
+ useFactory: (...args: any[]) => T | Promise<T>;
116
+ /**
117
+ * Optional list of providers to be injected into the context of the Factory function.
118
+ */
119
+ inject?: Array<InjectionToken | OptionalFactoryDependency>;
120
+ /**
121
+ * Optional enum defining lifetime of the provider that is returned by the Factory function.
122
+ */
123
+ scope?: Scope;
124
+ /**
125
+ * Flags provider as durable. This flag can be used in combination with custom context id
126
+ * factory strategy to construct lazy DI subtrees.
127
+ *
128
+ * This flag can be used only in conjunction with scope = Scope.REQUEST.
129
+ */
130
+ durable?: boolean;
131
+ }
132
+ /**
133
+ * Interface defining an *Existing* (aliased) type provider.
134
+ *
135
+ * For example:
136
+ * ```typescript
137
+ * const loggerAliasProvider = {
138
+ * provide: 'AliasedLoggerService',
139
+ * useExisting: LoggerService
140
+ * };
141
+ * ```
142
+ *
143
+ * @see [Alias providers](https://docs.nestjs.com/fundamentals/custom-providers#alias-providers-useexisting)
144
+ *
145
+ * @publicApi
146
+ */
147
+ export interface ExistingProvider<T = any> {
148
+ /**
149
+ * Injection token
150
+ */
151
+ provide: InjectionToken;
152
+ /**
153
+ * Provider to be aliased by the Injection token.
154
+ */
155
+ useExisting: any;
156
+ }
node_modules/@nestjs/common/interfaces/modules/provider.interface.js ADDED
@@ -0,0 +1,2 @@
 
 
 
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
node_modules/@nestjs/common/interfaces/nest-application-context-options.interface.d.ts ADDED
@@ -0,0 +1,68 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import { LoggerService, LogLevel } from '../services/logger.service';
2
+ /**
3
+ * @publicApi
4
+ */
5
+ export declare class NestApplicationContextOptions {
6
+ /**
7
+ * Specifies the logger to use. Pass `false` to turn off logging.
8
+ */
9
+ logger?: LoggerService | LogLevel[] | false;
10
+ /**
11
+ * Whether to abort the process on Error. By default, the process is exited.
12
+ * Pass `false` to override the default behavior. If `false` is passed, Nest will not exit
13
+ * the application and instead will rethrow the exception.
14
+ * @default true
15
+ */
16
+ abortOnError?: boolean | undefined;
17
+ /**
18
+ * If enabled, logs will be buffered until the "Logger#flush" method is called.
19
+ * @default false
20
+ */
21
+ bufferLogs?: boolean;
22
+ /**
23
+ * If enabled, logs will be automatically flushed and buffer detached when
24
+ * application initialization process either completes or fails.
25
+ * @default true
26
+ */
27
+ autoFlushLogs?: boolean;
28
+ /**
29
+ * Whether to run application in the preview mode.
30
+ * In the preview mode, providers/controllers are not instantiated & resolved.
31
+ *
32
+ * @default false
33
+ */
34
+ preview?: boolean;
35
+ /**
36
+ * Whether to generate a serialized graph snapshot.
37
+ *
38
+ * @default false
39
+ */
40
+ snapshot?: boolean;
41
+ /**
42
+ * Determines what algorithm use to generate module ids.
43
+ * When set to `deep-hash`, the module id is generated based on the serialized module definition.
44
+ * When set to `reference`, each module obtains a unique id based on its reference.
45
+ *
46
+ * @default 'reference'
47
+ */
48
+ moduleIdGeneratorAlgorithm?: 'deep-hash' | 'reference';
49
+ /**
50
+ * Instrument the application context.
51
+ * This option allows you to add custom instrumentation to the application context.
52
+ */
53
+ instrument?: {
54
+ /**
55
+ * Function that decorates each instance created by the application context.
56
+ * This function can be used to add custom properties or methods to the instance.
57
+ * @param instance The instance to decorate.
58
+ * @returns The decorated instance.
59
+ */
60
+ instanceDecorator: (instance: unknown) => unknown;
61
+ };
62
+ /**
63
+ * If enabled, will force the use of console.log/console.error instead of process.stdout/stderr.write
64
+ * in the default ConsoleLogger. This is useful for test environments like Jest that can buffer console calls.
65
+ * @default false
66
+ */
67
+ forceConsole?: boolean;
68
+ }
node_modules/@nestjs/common/interfaces/nest-application-context-options.interface.js ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
 
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.NestApplicationContextOptions = void 0;
4
+ /**
5
+ * @publicApi
6
+ */
7
+ class NestApplicationContextOptions {
8
+ }
9
+ exports.NestApplicationContextOptions = NestApplicationContextOptions;
node_modules/@nestjs/common/interfaces/nest-application-context.interface.d.ts ADDED
@@ -0,0 +1,139 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import { ShutdownSignal } from '../enums/shutdown-signal.enum';
2
+ import { LoggerService, LogLevel } from '../services/logger.service';
3
+ import { DynamicModule } from './modules';
4
+ import { NestApplicationContextOptions } from './nest-application-context-options.interface';
5
+ import { ShutdownHooksOptions } from './shutdown-hooks-options.interface';
6
+ import { Type } from './type.interface';
7
+ export type SelectOptions = Pick<NestApplicationContextOptions, 'abortOnError'>;
8
+ export interface GetOrResolveOptions {
9
+ /**
10
+ * If enabled, lookup will only be performed in the host module.
11
+ * @default false
12
+ */
13
+ strict?: boolean;
14
+ /**
15
+ * If enabled, instead of returning a first instance registered under a given token,
16
+ * a list of instances will be returned.
17
+ * @default false
18
+ */
19
+ each?: boolean;
20
+ }
21
+ /**
22
+ * Interface defining NestApplicationContext.
23
+ *
24
+ * @publicApi
25
+ */
26
+ export interface INestApplicationContext {
27
+ /**
28
+ * Allows navigating through the modules tree, for example, to pull out a specific instance from the selected module.
29
+ * @returns {INestApplicationContext}
30
+ */
31
+ select<T>(module: Type<T> | DynamicModule, options?: SelectOptions): INestApplicationContext;
32
+ /**
33
+ * Retrieves an instance of either injectable or controller, otherwise, throws exception.
34
+ * @returns {TResult}
35
+ */
36
+ get<TInput = any, TResult = TInput>(typeOrToken: Type<TInput> | Function | string | symbol): TResult;
37
+ /**
38
+ * Retrieves an instance of either injectable or controller, otherwise, throws exception.
39
+ * @returns {TResult}
40
+ */
41
+ get<TInput = any, TResult = TInput>(typeOrToken: Type<TInput> | Function | string | symbol, options: {
42
+ strict?: boolean;
43
+ each?: undefined | false;
44
+ }): TResult;
45
+ /**
46
+ * Retrieves a list of instances of either injectables or controllers, otherwise, throws exception.
47
+ * @returns {Array<TResult>}
48
+ */
49
+ get<TInput = any, TResult = TInput>(typeOrToken: Type<TInput> | Function | string | symbol, options: {
50
+ strict?: boolean;
51
+ each: true;
52
+ }): Array<TResult>;
53
+ /**
54
+ * Retrieves an instance (or a list of instances) of either injectable or controller, otherwise, throws exception.
55
+ * @returns {TResult | Array<TResult>}
56
+ */
57
+ get<TInput = any, TResult = TInput>(typeOrToken: Type<TInput> | Function | string | symbol, options?: GetOrResolveOptions): TResult | Array<TResult>;
58
+ /**
59
+ * Resolves transient or request-scoped instance of either injectable or controller, otherwise, throws exception.
60
+ * @returns {Array<TResult>}
61
+ */
62
+ resolve<TInput = any, TResult = TInput>(typeOrToken: Type<TInput> | Function | string | symbol): Promise<TResult>;
63
+ /**
64
+ * Resolves transient or request-scoped instance of either injectable or controller, otherwise, throws exception.
65
+ * @returns {Array<TResult>}
66
+ */
67
+ resolve<TInput = any, TResult = TInput>(typeOrToken: Type<TInput> | Function | string | symbol, contextId?: {
68
+ id: number;
69
+ }): Promise<TResult>;
70
+ /**
71
+ * Resolves transient or request-scoped instance of either injectable or controller, otherwise, throws exception.
72
+ * @returns {Array<TResult>}
73
+ */
74
+ resolve<TInput = any, TResult = TInput>(typeOrToken: Type<TInput> | Function | string | symbol, contextId?: {
75
+ id: number;
76
+ }, options?: {
77
+ strict?: boolean;
78
+ each?: undefined | false;
79
+ }): Promise<TResult>;
80
+ /**
81
+ * Resolves transient or request-scoped instances of either injectables or controllers, otherwise, throws exception.
82
+ * @returns {Array<TResult>}
83
+ */
84
+ resolve<TInput = any, TResult = TInput>(typeOrToken: Type<TInput> | Function | string | symbol, contextId?: {
85
+ id: number;
86
+ }, options?: {
87
+ strict?: boolean;
88
+ each: true;
89
+ }): Promise<Array<TResult>>;
90
+ /**
91
+ * Resolves transient or request-scoped instance (or a list of instances) of either injectable or controller, otherwise, throws exception.
92
+ * @returns {Promise<TResult | Array<TResult>>}
93
+ */
94
+ resolve<TInput = any, TResult = TInput>(typeOrToken: Type<TInput> | Function | string | symbol, contextId?: {
95
+ id: number;
96
+ }, options?: GetOrResolveOptions): Promise<TResult | Array<TResult>>;
97
+ /**
98
+ * Registers the request/context object for a given context ID (DI container sub-tree).
99
+ * @returns {void}
100
+ */
101
+ registerRequestByContextId<T = any>(request: T, contextId: {
102
+ id: number;
103
+ }): void;
104
+ /**
105
+ * Terminates the application
106
+ * @returns {Promise<void>}
107
+ */
108
+ close(): Promise<void>;
109
+ /**
110
+ * Sets custom logger service.
111
+ * Flushes buffered logs if auto flush is on.
112
+ * @returns {void}
113
+ */
114
+ useLogger(logger: LoggerService | LogLevel[] | false): void;
115
+ /**
116
+ * Prints buffered logs and detaches buffer.
117
+ * @returns {void}
118
+ */
119
+ flushLogs(): void;
120
+ /**
121
+ * Enables the usage of shutdown hooks. Will call the
122
+ * `onApplicationShutdown` function of a provider if the
123
+ * process receives a shutdown signal.
124
+ *
125
+ * @param {ShutdownSignal[] | string[]} [signals] The system signals to listen to
126
+ * @param {ShutdownHooksOptions} [options] Options for configuring shutdown hooks behavior
127
+ *
128
+ * @returns {this} The Nest application context instance
129
+ */
130
+ enableShutdownHooks(signals?: ShutdownSignal[] | string[], options?: ShutdownHooksOptions): this;
131
+ /**
132
+ * Initializes the Nest application.
133
+ * Calls the Nest lifecycle events.
134
+ * It isn't mandatory to call this method directly.
135
+ *
136
+ * @returns {Promise<this>} The NestApplicationContext instance as Promise
137
+ */
138
+ init(): Promise<this>;
139
+ }
node_modules/@nestjs/common/interfaces/nest-application-context.interface.js ADDED
@@ -0,0 +1,2 @@
 
 
 
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
node_modules/@nestjs/common/interfaces/nest-application-options.interface.d.ts ADDED
@@ -0,0 +1,29 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import { CorsOptions, CorsOptionsDelegate } from './external/cors-options.interface';
2
+ import { HttpsOptions } from './external/https-options.interface';
3
+ import { NestApplicationContextOptions } from './nest-application-context-options.interface';
4
+ /**
5
+ * @publicApi
6
+ */
7
+ export interface NestApplicationOptions extends NestApplicationContextOptions {
8
+ /**
9
+ * CORS options from [CORS package](https://github.com/expressjs/cors#configuration-options)
10
+ */
11
+ cors?: boolean | CorsOptions | CorsOptionsDelegate<any>;
12
+ /**
13
+ * Whether to use underlying platform body parser.
14
+ */
15
+ bodyParser?: boolean;
16
+ /**
17
+ * Set of configurable HTTPS options
18
+ */
19
+ httpsOptions?: HttpsOptions;
20
+ /**
21
+ * Whether to register the raw request body on the request. Use `req.rawBody`.
22
+ */
23
+ rawBody?: boolean;
24
+ /**
25
+ * Force close open HTTP connections. Useful if restarting your application hangs due to
26
+ * keep-alive connections in the HTTP adapter.
27
+ */
28
+ forceCloseConnections?: boolean;
29
+ }
node_modules/@nestjs/common/interfaces/nest-application-options.interface.js ADDED
@@ -0,0 +1,2 @@
 
 
 
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
node_modules/@nestjs/common/interfaces/nest-application.interface.d.ts ADDED
@@ -0,0 +1,135 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import { CanActivate } from './features/can-activate.interface';
2
+ import { NestInterceptor } from './features/nest-interceptor.interface';
3
+ import { GlobalPrefixOptions } from './global-prefix-options.interface';
4
+ import { HttpServer } from './http/http-server.interface';
5
+ import { ExceptionFilter, INestMicroservice, NestHybridApplicationOptions, PipeTransform } from './index';
6
+ import { INestApplicationContext } from './nest-application-context.interface';
7
+ import { VersioningOptions } from './version-options.interface';
8
+ import { WebSocketAdapter } from './websockets/web-socket-adapter.interface';
9
+ /**
10
+ * Interface defining the core NestApplication object.
11
+ *
12
+ * @publicApi
13
+ */
14
+ export interface INestApplication<TServer = any> extends INestApplicationContext {
15
+ /**
16
+ * A wrapper function around HTTP adapter method: `adapter.use()`.
17
+ * Example `app.use(cors())`
18
+ *
19
+ * @returns {this}
20
+ */
21
+ use(...args: any[]): this;
22
+ /**
23
+ * Enables CORS (Cross-Origin Resource Sharing)
24
+ *
25
+ * @returns {void}
26
+ */
27
+ enableCors(options?: any): void;
28
+ /**
29
+ * Enables Versioning for the application.
30
+ * By default, URI-based versioning is used.
31
+ *
32
+ * @param {VersioningOptions} options
33
+ * @returns {this}
34
+ */
35
+ enableVersioning(options?: VersioningOptions): this;
36
+ /**
37
+ * Starts the application.
38
+ *
39
+ * @param {number|string} port
40
+ * @param {string} [hostname]
41
+ * @param {Function} [callback] Optional callback
42
+ * @returns {Promise} A Promise that, when resolved, is a reference to the underlying HttpServer.
43
+ */
44
+ listen(port: number | string, callback?: () => void): Promise<any>;
45
+ listen(port: number | string, hostname: string, callback?: () => void): Promise<any>;
46
+ /**
47
+ * Returns the url the application is listening at, based on OS and IP version. Returns as an IP value either in IPv6 or IPv4
48
+ *
49
+ * @returns {Promise<string>} The IP where the server is listening
50
+ */
51
+ getUrl(): Promise<string>;
52
+ /**
53
+ * Registers a prefix for every HTTP route path.
54
+ *
55
+ * @param {string} prefix The prefix for every HTTP route path (for example `/v1/api`)
56
+ * @param {GlobalPrefixOptions} options Global prefix options object
57
+ * @returns {this}
58
+ */
59
+ setGlobalPrefix(prefix: string, options?: GlobalPrefixOptions): this;
60
+ /**
61
+ * Register Ws Adapter which will be used inside Gateways.
62
+ * Use when you want to override default `socket.io` library.
63
+ *
64
+ * @param {WebSocketAdapter} adapter
65
+ * @returns {this}
66
+ */
67
+ useWebSocketAdapter(adapter: WebSocketAdapter): this;
68
+ /**
69
+ * Connects microservice to the NestApplication instance. Transforms application
70
+ * to a hybrid instance.
71
+ *
72
+ * @template {object} T
73
+ * @param {T} options Microservice options object
74
+ * @param {NestHybridApplicationOptions} hybridOptions Hybrid options object
75
+ * @returns {INestMicroservice}
76
+ */
77
+ connectMicroservice<T extends object = any>(options: T, hybridOptions?: NestHybridApplicationOptions): INestMicroservice;
78
+ /**
79
+ * Returns array of the microservices connected to the NestApplication.
80
+ *
81
+ * @returns {INestMicroservice[]}
82
+ */
83
+ getMicroservices(): INestMicroservice[];
84
+ /**
85
+ * Returns the underlying native HTTP server.
86
+ *
87
+ * @returns {TServer}
88
+ */
89
+ getHttpServer(): TServer;
90
+ /**
91
+ * Returns the underlying HTTP adapter.
92
+ *
93
+ * @returns {HttpServer}
94
+ */
95
+ getHttpAdapter(): HttpServer;
96
+ /**
97
+ * Starts all connected microservices asynchronously.
98
+ *
99
+ * @returns {Promise}
100
+ */
101
+ startAllMicroservices(): Promise<this>;
102
+ /**
103
+ * Registers exception filters as global filters (will be used within
104
+ * every HTTP route handler)
105
+ *
106
+ * @param {...ExceptionFilter} filters
107
+ */
108
+ useGlobalFilters(...filters: ExceptionFilter[]): this;
109
+ /**
110
+ * Registers pipes as global pipes (will be used within every HTTP route handler)
111
+ *
112
+ * @param {...PipeTransform} pipes
113
+ */
114
+ useGlobalPipes(...pipes: PipeTransform<any>[]): this;
115
+ /**
116
+ * Registers interceptors as global interceptors (will be used within
117
+ * every HTTP route handler)
118
+ *
119
+ * @param {...NestInterceptor} interceptors
120
+ */
121
+ useGlobalInterceptors(...interceptors: NestInterceptor[]): this;
122
+ /**
123
+ * Registers guards as global guards (will be used within every HTTP route handler)
124
+ *
125
+ * @param {...CanActivate} guards
126
+ */
127
+ useGlobalGuards(...guards: CanActivate[]): this;
128
+ /**
129
+ * Terminates the application (including NestApplication, Gateways, and each connected
130
+ * microservice)
131
+ *
132
+ * @returns {Promise<void>}
133
+ */
134
+ close(): Promise<void>;
135
+ }
node_modules/@nestjs/common/interfaces/nest-application.interface.js ADDED
@@ -0,0 +1,2 @@
 
 
 
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
node_modules/@nestjs/common/interfaces/nest-microservice.interface.d.ts ADDED
@@ -0,0 +1,75 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import { Observable } from 'rxjs';
2
+ import { ExceptionFilter } from './exceptions/exception-filter.interface';
3
+ import { CanActivate } from './features/can-activate.interface';
4
+ import { NestInterceptor } from './features/nest-interceptor.interface';
5
+ import { PipeTransform } from './features/pipe-transform.interface';
6
+ import { INestApplicationContext } from './nest-application-context.interface';
7
+ import { WebSocketAdapter } from './websockets/web-socket-adapter.interface';
8
+ /**
9
+ * Interface describing Microservice Context.
10
+ *
11
+ * @publicApi
12
+ */
13
+ export interface INestMicroservice extends INestApplicationContext {
14
+ /**
15
+ * Starts the microservice.
16
+ *
17
+ * @returns {void}
18
+ */
19
+ listen(): Promise<any>;
20
+ /**
21
+ * Registers a web socket adapter that will be used for Gateways.
22
+ * Use to override the default `socket.io` library.
23
+ *
24
+ * @param {WebSocketAdapter} adapter
25
+ * @returns {this}
26
+ */
27
+ useWebSocketAdapter(adapter: WebSocketAdapter): this;
28
+ /**
29
+ * Registers global exception filters (will be used for every pattern handler).
30
+ *
31
+ * @param {...ExceptionFilter} filters
32
+ */
33
+ useGlobalFilters(...filters: ExceptionFilter[]): this;
34
+ /**
35
+ * Registers global pipes (will be used for every pattern handler).
36
+ *
37
+ * @param {...PipeTransform} pipes
38
+ */
39
+ useGlobalPipes(...pipes: PipeTransform<any>[]): this;
40
+ /**
41
+ * Registers global interceptors (will be used for every pattern handler).
42
+ *
43
+ * @param {...NestInterceptor} interceptors
44
+ */
45
+ useGlobalInterceptors(...interceptors: NestInterceptor[]): this;
46
+ /**
47
+ * Registers global guards (will be used for every pattern handler).
48
+ *
49
+ * @param {...CanActivate} guards
50
+ */
51
+ useGlobalGuards(...guards: CanActivate[]): this;
52
+ /**
53
+ * Terminates the application.
54
+ *
55
+ * @returns {Promise<void>}
56
+ */
57
+ close(): Promise<void>;
58
+ /**
59
+ * Returns an observable that emits status changes.
60
+ *
61
+ * @returns {Observable<string>}
62
+ */
63
+ status: Observable<string>;
64
+ /**
65
+ * Registers an event listener for the given event.
66
+ * @param event Event name
67
+ * @param callback Callback to be executed when the event is emitted
68
+ */
69
+ on<EventsMap extends Record<string, Function> = Record<string, Function>, EventKey extends keyof EventsMap = keyof EventsMap, EventCallback extends EventsMap[EventKey] = EventsMap[EventKey]>(event: EventKey, callback: EventCallback): void;
70
+ /**
71
+ * Returns an instance of the underlying server/broker instance,
72
+ * or a group of servers if there are more than one.
73
+ */
74
+ unwrap<T>(): T;
75
+ }
node_modules/@nestjs/common/interfaces/nest-microservice.interface.js ADDED
@@ -0,0 +1,2 @@
 
 
 
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
node_modules/@nestjs/common/interfaces/router-options.interface.d.ts ADDED
@@ -0,0 +1,28 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /**
2
+ * Severity level applied to a single kind of route conflict detected at
3
+ * bootstrap.
4
+ *
5
+ * @publicApi
6
+ */
7
+ export type RouteConflictPolicyLevel = 'off' | 'warn' | 'error';
8
+ /**
9
+ * Per-kind policy for overlapping routes detected at bootstrap.
10
+ * `duplicate` covers identical (method, path, host, version) registrations.
11
+ * `shadow` covers patterns that can match the same request (for example
12
+ * `/users/me` vs `/users/:id`). Each kind defaults to `'off'`.
13
+ *
14
+ * @publicApi
15
+ */
16
+ export interface RouteConflictPolicy {
17
+ duplicate?: RouteConflictPolicyLevel;
18
+ shadow?: RouteConflictPolicyLevel;
19
+ }
20
+ /**
21
+ * Order in which routes are registered on the underlying HTTP adapter.
22
+ * `'specificity'` registers literal segments before parametric and
23
+ * wildcard ones on order-sensitive adapters (such as Express). Defaults
24
+ * to `'declaration'`.
25
+ *
26
+ * @publicApi
27
+ */
28
+ export type RouteResolutionStrategy = 'declaration' | 'specificity';
node_modules/@nestjs/common/interfaces/router-options.interface.js ADDED
@@ -0,0 +1 @@
 
 
1
+ export {};
node_modules/@nestjs/common/interfaces/scope-options.interface.d.ts ADDED
@@ -0,0 +1,37 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /**
2
+ * @publicApi
3
+ */
4
+ export declare enum Scope {
5
+ /**
6
+ * The provider can be shared across multiple classes. The provider lifetime
7
+ * is strictly tied to the application lifecycle. Once the application has
8
+ * bootstrapped, all providers have been instantiated.
9
+ */
10
+ DEFAULT = 0,
11
+ /**
12
+ * A new private instance of the provider is instantiated for every use
13
+ */
14
+ TRANSIENT = 1,
15
+ /**
16
+ * A new instance is instantiated for each request processing pipeline
17
+ */
18
+ REQUEST = 2
19
+ }
20
+ /**
21
+ * @publicApi
22
+ *
23
+ * @see [Injection Scopes](https://docs.nestjs.com/fundamentals/injection-scopes)
24
+ */
25
+ export interface ScopeOptions {
26
+ /**
27
+ * Specifies the lifetime of an injected Provider or Controller.
28
+ */
29
+ scope?: Scope;
30
+ /**
31
+ * Flags provider as durable. This flag can be used in combination with custom context id
32
+ * factory strategy to construct lazy DI subtrees.
33
+ *
34
+ * This flag can be used only in conjunction with scope = Scope.REQUEST.
35
+ */
36
+ durable?: boolean;
37
+ }
node_modules/@nestjs/common/interfaces/scope-options.interface.js ADDED
@@ -0,0 +1,23 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.Scope = void 0;
4
+ /**
5
+ * @publicApi
6
+ */
7
+ var Scope;
8
+ (function (Scope) {
9
+ /**
10
+ * The provider can be shared across multiple classes. The provider lifetime
11
+ * is strictly tied to the application lifecycle. Once the application has
12
+ * bootstrapped, all providers have been instantiated.
13
+ */
14
+ Scope[Scope["DEFAULT"] = 0] = "DEFAULT";
15
+ /**
16
+ * A new private instance of the provider is instantiated for every use
17
+ */
18
+ Scope[Scope["TRANSIENT"] = 1] = "TRANSIENT";
19
+ /**
20
+ * A new instance is instantiated for each request processing pipeline
21
+ */
22
+ Scope[Scope["REQUEST"] = 2] = "REQUEST";
23
+ })(Scope || (exports.Scope = Scope = {}));
node_modules/@nestjs/common/interfaces/shutdown-hooks-options.interface.d.ts ADDED
@@ -0,0 +1,21 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /**
2
+ * Options for configuring shutdown hooks behavior.
3
+ *
4
+ * @publicApi
5
+ */
6
+ export interface ShutdownHooksOptions {
7
+ /**
8
+ * If true, uses `process.exit()` instead of `process.kill(process.pid, signal)`
9
+ * after shutdown hooks complete. This ensures the 'exit' event is properly
10
+ * triggered, which is required for async loggers (like Pino with transports)
11
+ * to flush their buffers before the process terminates.
12
+ *
13
+ * Note: Using `process.exit()` will:
14
+ * - Change the exit code (e.g., SIGTERM: 143 → 0)
15
+ * - May not trigger other signal handlers from third-party libraries
16
+ * - May affect orchestrator (Kubernetes, Docker) behavior
17
+ *
18
+ * @default false
19
+ */
20
+ useProcessExit?: boolean;
21
+ }
node_modules/@nestjs/common/interfaces/shutdown-hooks-options.interface.js ADDED
@@ -0,0 +1,2 @@
 
 
 
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
node_modules/@nestjs/common/interfaces/type.interface.d.ts ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ export interface Type<T = any> extends Function {
2
+ new (...args: any[]): T;
3
+ }
node_modules/@nestjs/common/interfaces/type.interface.js ADDED
@@ -0,0 +1,2 @@
 
 
 
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
node_modules/@nestjs/common/interfaces/version-options.interface.d.ts ADDED
@@ -0,0 +1,92 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import { VersioningType } from '../enums/version-type.enum';
2
+ /**
3
+ * Indicates that this will work for any version passed in the request, or no version.
4
+ *
5
+ * @publicApi
6
+ */
7
+ export declare const VERSION_NEUTRAL: unique symbol;
8
+ /**
9
+ * @publicApi
10
+ */
11
+ export type VersionValue = string | typeof VERSION_NEUTRAL | Array<string | typeof VERSION_NEUTRAL>;
12
+ /**
13
+ * @publicApi
14
+ */
15
+ export interface VersionOptions {
16
+ /**
17
+ * Specifies an optional API Version. When configured, methods
18
+ * within the controller will only be routed if the request version
19
+ * matches the specified value.
20
+ *
21
+ * Supported only by HTTP-based applications (does not apply to non-HTTP microservices).
22
+ *
23
+ * @see [Versioning](https://docs.nestjs.com/techniques/versioning)
24
+ */
25
+ version?: VersionValue;
26
+ }
27
+ /**
28
+ * @publicApi
29
+ */
30
+ export interface HeaderVersioningOptions {
31
+ type: VersioningType.HEADER;
32
+ /**
33
+ * The name of the Request Header that contains the version.
34
+ */
35
+ header: string;
36
+ }
37
+ /**
38
+ * @publicApi
39
+ */
40
+ export interface UriVersioningOptions {
41
+ type: VersioningType.URI;
42
+ /**
43
+ * Optional prefix that will prepend the version within the URI.
44
+ *
45
+ * Defaults to `v`.
46
+ *
47
+ * Ex. Assuming a version of `1`, for `/api/v1/route`, `v` is the prefix.
48
+ */
49
+ prefix?: string | false;
50
+ }
51
+ /**
52
+ * @publicApi
53
+ */
54
+ export interface MediaTypeVersioningOptions {
55
+ type: VersioningType.MEDIA_TYPE;
56
+ /**
57
+ * The key within the Media Type Header to determine the version from.
58
+ *
59
+ * Ex. For `application/json;v=1`, the key is `v=`.
60
+ */
61
+ key: string;
62
+ }
63
+ /**
64
+ * @publicApi
65
+ */
66
+ export interface CustomVersioningOptions {
67
+ type: VersioningType.CUSTOM;
68
+ /**
69
+ * A function that accepts a request object (specific to the underlying platform, ie Express or Fastify)
70
+ * and returns a single version value or an ordered array of versions, in order from HIGHEST to LOWEST.
71
+ *
72
+ * Ex. Returned version array = ['3.1', '3.0', '2.5', '2', '1.9']
73
+ *
74
+ * Use type assertion or narrowing to identify the specific request type.
75
+ */
76
+ extractor: (request: unknown) => string | string[];
77
+ }
78
+ /**
79
+ * @publicApi
80
+ */
81
+ interface VersioningCommonOptions {
82
+ /**
83
+ * The default version to be used as a fallback when you did not provide some
84
+ * version to `@Controller()` nor `@Version()`.
85
+ */
86
+ defaultVersion?: VersionOptions['version'];
87
+ }
88
+ /**
89
+ * @publicApi
90
+ */
91
+ export type VersioningOptions = VersioningCommonOptions & (HeaderVersioningOptions | UriVersioningOptions | MediaTypeVersioningOptions | CustomVersioningOptions);
92
+ export {};
node_modules/@nestjs/common/interfaces/version-options.interface.js ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
 
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.VERSION_NEUTRAL = void 0;
4
+ /**
5
+ * Indicates that this will work for any version passed in the request, or no version.
6
+ *
7
+ * @publicApi
8
+ */
9
+ exports.VERSION_NEUTRAL = Symbol('VERSION_NEUTRAL');
node_modules/@nestjs/common/interfaces/websockets/web-socket-adapter.interface.d.ts ADDED
@@ -0,0 +1,19 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import { Observable } from 'rxjs';
2
+ /**
3
+ * @publicApi
4
+ */
5
+ export interface WsMessageHandler<T = string> {
6
+ message: T;
7
+ callback: (...args: any[]) => Observable<any> | Promise<any>;
8
+ isAckHandledManually: boolean;
9
+ }
10
+ /**
11
+ * @publicApi
12
+ */
13
+ export interface WebSocketAdapter<TServer = any, TClient = any, TOptions = any> {
14
+ create(port: number, options?: TOptions): TServer;
15
+ bindClientConnect(server: TServer, callback: Function): any;
16
+ bindClientDisconnect?(client: TClient, callback: Function): any;
17
+ bindMessageHandlers(client: TClient, handlers: WsMessageHandler[], transform: (data: any) => Observable<any>): any;
18
+ close(server: TServer): any;
19
+ }
node_modules/@nestjs/common/interfaces/websockets/web-socket-adapter.interface.js ADDED
@@ -0,0 +1,2 @@
 
 
 
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
node_modules/@nestjs/common/internal.d.ts ADDED
@@ -0,0 +1,30 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /**
2
+ * Internal module - not part of the public API.
3
+ * These exports are used by sibling @nestjs packages.
4
+ * Do not depend on these in your application code.
5
+ * @internal
6
+ * @module
7
+ */
8
+ export * from './constants.js';
9
+ export { RouteParamtypes } from './enums/route-paramtypes.enum.js';
10
+ export * from './utils/shared.utils.js';
11
+ export * from './utils/load-package.util.js';
12
+ export * from './utils/cli-colors.util.js';
13
+ export * from './utils/random-string-generator.util.js';
14
+ export * from './utils/select-exception-filter-metadata.util.js';
15
+ export type { Controller, Injectable } from './interfaces/index.js';
16
+ export type { NestApplicationContextOptions } from './interfaces/nest-application-context-options.interface.js';
17
+ export type { NestMicroserviceOptions } from './interfaces/microservices/nest-microservice-options.interface.js';
18
+ export type { CorsOptions, CorsOptionsDelegate, CustomOrigin, } from './interfaces/external/cors-options.interface.js';
19
+ export type { ExceptionFilterMetadata } from './interfaces/exceptions/exception-filter-metadata.interface.js';
20
+ export type { RpcExceptionFilterMetadata } from './interfaces/exceptions/rpc-exception-filter-metadata.interface.js';
21
+ export type { VersionValue } from './interfaces/version-options.interface.js';
22
+ export type { GlobalPrefixOptions } from './interfaces/global-prefix-options.interface.js';
23
+ export type { MiddlewareConfiguration, RouteInfo, } from './interfaces/middleware/middleware-configuration.interface.js';
24
+ export type { MiddlewareConfigProxy } from './interfaces/middleware/middleware-config-proxy.interface.js';
25
+ export type { ModuleMetadata } from './interfaces/modules/module-metadata.interface.js';
26
+ export type { HttpArgumentsHost, RpcArgumentsHost, WsArgumentsHost, } from './interfaces/features/arguments-host.interface.js';
27
+ export type { RequestHandler } from './interfaces/http/http-server.interface.js';
28
+ export type { GetOrResolveOptions, SelectOptions, } from './interfaces/nest-application-context.interface.js';
29
+ export type { ShutdownHooksOptions } from './interfaces/shutdown-hooks-options.interface.js';
30
+ export { assignMetadata } from './decorators/http/route-params.decorator.js';
node_modules/@nestjs/common/internal.js ADDED
@@ -0,0 +1,19 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /**
2
+ * Internal module - not part of the public API.
3
+ * These exports are used by sibling @nestjs packages.
4
+ * Do not depend on these in your application code.
5
+ * @internal
6
+ * @module
7
+ */
8
+ // Constants
9
+ export * from './constants.js';
10
+ // Enums (internal)
11
+ export { RouteParamtypes } from './enums/route-paramtypes.enum.js';
12
+ // Utils
13
+ export * from './utils/shared.utils.js';
14
+ export * from './utils/load-package.util.js';
15
+ export * from './utils/cli-colors.util.js';
16
+ export * from './utils/random-string-generator.util.js';
17
+ export * from './utils/select-exception-filter-metadata.util.js';
18
+ // Decorators (internal)
19
+ export { assignMetadata } from './decorators/http/route-params.decorator.js';
node_modules/@nestjs/common/module-utils/configurable-module.builder.d.ts ADDED
@@ -0,0 +1,93 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import { DynamicModule } from '../interfaces';
2
+ import { Logger } from '../services/logger.service';
3
+ import { DEFAULT_FACTORY_CLASS_METHOD_KEY, DEFAULT_METHOD_KEY } from './constants';
4
+ import { ConfigurableModuleHost } from './interfaces';
5
+ /**
6
+ * @publicApi
7
+ */
8
+ export interface ConfigurableModuleBuilderOptions {
9
+ /**
10
+ * Specifies what injection token should be used for the module options provider.
11
+ * By default, an auto-generated UUID will be used.
12
+ */
13
+ optionsInjectionToken?: string | symbol;
14
+ /**
15
+ * By default, an UUID will be used as a module options provider token.
16
+ * Explicitly specifying the "moduleName" will instruct the "ConfigurableModuleBuilder"
17
+ * to use a more descriptive provider token.
18
+ *
19
+ * For example, `moduleName: "Cache"` will auto-generate the provider token: "CACHE_MODULE_OPTIONS".
20
+ */
21
+ moduleName?: string;
22
+ /**
23
+ * Indicates whether module should always be "transient" - meaning,
24
+ * every time you call the static method to construct a dynamic module,
25
+ * regardless of what arguments you pass in, a new "unique" module will be created.
26
+ *
27
+ * @default false
28
+ */
29
+ alwaysTransient?: boolean;
30
+ }
31
+ /**
32
+ * Factory that lets you create configurable modules and
33
+ * provides a way to reduce the majority of dynamic module boilerplate.
34
+ *
35
+ * @publicApi
36
+ */
37
+ export declare class ConfigurableModuleBuilder<ModuleOptions, StaticMethodKey extends string = typeof DEFAULT_METHOD_KEY, FactoryClassMethodKey extends string = typeof DEFAULT_FACTORY_CLASS_METHOD_KEY, ExtraModuleDefinitionOptions = {}> {
38
+ protected readonly options: ConfigurableModuleBuilderOptions;
39
+ protected staticMethodKey: StaticMethodKey;
40
+ protected factoryClassMethodKey: FactoryClassMethodKey;
41
+ protected extras: ExtraModuleDefinitionOptions;
42
+ protected transformModuleDefinition: (definition: DynamicModule, extraOptions: ExtraModuleDefinitionOptions) => DynamicModule;
43
+ protected readonly logger: Logger;
44
+ constructor(options?: ConfigurableModuleBuilderOptions, parentBuilder?: ConfigurableModuleBuilder<ModuleOptions>);
45
+ /**
46
+ * Registers the "extras" object (a set of extra options that can be used to modify the dynamic module definition).
47
+ * Values you specify within the "extras" object will be used as default values (that can be overridden by module consumers).
48
+ *
49
+ * This method also applies the so-called "module definition transform function" that takes the auto-generated
50
+ * dynamic module object ("DynamicModule") and the actual consumer "extras" object as input parameters.
51
+ * The "extras" object consists of values explicitly specified by module consumers and default values.
52
+ *
53
+ * @example
54
+ * ```typescript
55
+ * .setExtras<{ isGlobal?: boolean }>({ isGlobal: false }, (definition, extras) =>
56
+ * ({ ...definition, global: extras.isGlobal })
57
+ * )
58
+ * ```
59
+ */
60
+ setExtras<ExtraModuleDefinitionOptions>(extras: ExtraModuleDefinitionOptions, transformDefinition?: (definition: DynamicModule, extras: ExtraModuleDefinitionOptions) => DynamicModule): ConfigurableModuleBuilder<ModuleOptions, StaticMethodKey, FactoryClassMethodKey, ExtraModuleDefinitionOptions>;
61
+ /**
62
+ * Dynamic modules must expose public static methods that let you pass in
63
+ * configuration parameters (control the module's behavior from the outside).
64
+ * Some frequently used names that you may have seen in other modules are:
65
+ * "forRoot", "forFeature", "register", "configure".
66
+ *
67
+ * This method "setClassMethodName" lets you specify the name of the
68
+ * method that will be auto-generated.
69
+ *
70
+ * @param key name of the method
71
+ */
72
+ setClassMethodName<StaticMethodKey extends string>(key: StaticMethodKey): ConfigurableModuleBuilder<ModuleOptions, StaticMethodKey, FactoryClassMethodKey, ExtraModuleDefinitionOptions>;
73
+ /**
74
+ * Asynchronously configured modules (that rely on other modules, i.e. "ConfigModule")
75
+ * let you pass the configuration factory class that will be registered and instantiated as a provider.
76
+ * This provider then will be used to retrieve the module's configuration. To provide the configuration,
77
+ * the corresponding factory method must be implemented.
78
+ *
79
+ * This method ("setFactoryMethodName") lets you control what method name will have to be
80
+ * implemented by the config factory (default is "create").
81
+ *
82
+ * @param key name of the method
83
+ */
84
+ setFactoryMethodName<FactoryClassMethodKey extends string>(key: FactoryClassMethodKey): ConfigurableModuleBuilder<ModuleOptions, StaticMethodKey, FactoryClassMethodKey, ExtraModuleDefinitionOptions>;
85
+ /**
86
+ * Returns an object consisting of multiple properties that lets you
87
+ * easily construct dynamic configurable modules. See "ConfigurableModuleHost" interface for more details.
88
+ */
89
+ build(): ConfigurableModuleHost<ModuleOptions, StaticMethodKey, FactoryClassMethodKey, ExtraModuleDefinitionOptions>;
90
+ private constructInjectionTokenString;
91
+ private createConfigurableModuleCls;
92
+ private createTypeProxy;
93
+ }
node_modules/@nestjs/common/module-utils/configurable-module.builder.js ADDED
@@ -0,0 +1,219 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ConfigurableModuleBuilder = void 0;
4
+ const logger_service_1 = require("../services/logger.service");
5
+ const random_string_generator_util_1 = require("../utils/random-string-generator.util");
6
+ const constants_1 = require("./constants");
7
+ const utils_1 = require("./utils");
8
+ /**
9
+ * Factory that lets you create configurable modules and
10
+ * provides a way to reduce the majority of dynamic module boilerplate.
11
+ *
12
+ * @publicApi
13
+ */
14
+ class ConfigurableModuleBuilder {
15
+ constructor(options = {}, parentBuilder) {
16
+ this.options = options;
17
+ this.logger = new logger_service_1.Logger(ConfigurableModuleBuilder.name);
18
+ if (parentBuilder) {
19
+ this.staticMethodKey = parentBuilder.staticMethodKey;
20
+ this.factoryClassMethodKey =
21
+ parentBuilder.factoryClassMethodKey;
22
+ this.transformModuleDefinition =
23
+ parentBuilder.transformModuleDefinition;
24
+ this.extras = parentBuilder.extras;
25
+ }
26
+ }
27
+ /**
28
+ * Registers the "extras" object (a set of extra options that can be used to modify the dynamic module definition).
29
+ * Values you specify within the "extras" object will be used as default values (that can be overridden by module consumers).
30
+ *
31
+ * This method also applies the so-called "module definition transform function" that takes the auto-generated
32
+ * dynamic module object ("DynamicModule") and the actual consumer "extras" object as input parameters.
33
+ * The "extras" object consists of values explicitly specified by module consumers and default values.
34
+ *
35
+ * @example
36
+ * ```typescript
37
+ * .setExtras<{ isGlobal?: boolean }>({ isGlobal: false }, (definition, extras) =>
38
+ * ({ ...definition, global: extras.isGlobal })
39
+ * )
40
+ * ```
41
+ */
42
+ setExtras(extras, transformDefinition = def => def) {
43
+ const builder = new ConfigurableModuleBuilder(this.options, this);
44
+ builder.extras = extras;
45
+ builder.transformModuleDefinition = transformDefinition;
46
+ return builder;
47
+ }
48
+ /**
49
+ * Dynamic modules must expose public static methods that let you pass in
50
+ * configuration parameters (control the module's behavior from the outside).
51
+ * Some frequently used names that you may have seen in other modules are:
52
+ * "forRoot", "forFeature", "register", "configure".
53
+ *
54
+ * This method "setClassMethodName" lets you specify the name of the
55
+ * method that will be auto-generated.
56
+ *
57
+ * @param key name of the method
58
+ */
59
+ setClassMethodName(key) {
60
+ const builder = new ConfigurableModuleBuilder(this.options, this);
61
+ builder.staticMethodKey = key;
62
+ return builder;
63
+ }
64
+ /**
65
+ * Asynchronously configured modules (that rely on other modules, i.e. "ConfigModule")
66
+ * let you pass the configuration factory class that will be registered and instantiated as a provider.
67
+ * This provider then will be used to retrieve the module's configuration. To provide the configuration,
68
+ * the corresponding factory method must be implemented.
69
+ *
70
+ * This method ("setFactoryMethodName") lets you control what method name will have to be
71
+ * implemented by the config factory (default is "create").
72
+ *
73
+ * @param key name of the method
74
+ */
75
+ setFactoryMethodName(key) {
76
+ const builder = new ConfigurableModuleBuilder(this.options, this);
77
+ builder.factoryClassMethodKey = key;
78
+ return builder;
79
+ }
80
+ /**
81
+ * Returns an object consisting of multiple properties that lets you
82
+ * easily construct dynamic configurable modules. See "ConfigurableModuleHost" interface for more details.
83
+ */
84
+ build() {
85
+ this.staticMethodKey ??= constants_1.DEFAULT_METHOD_KEY;
86
+ this.factoryClassMethodKey ??=
87
+ constants_1.DEFAULT_FACTORY_CLASS_METHOD_KEY;
88
+ this.options.optionsInjectionToken ??= this.options.moduleName
89
+ ? this.constructInjectionTokenString()
90
+ : (0, utils_1.generateOptionsInjectionToken)();
91
+ this.transformModuleDefinition ??= definition => definition;
92
+ return {
93
+ ConfigurableModuleClass: this.createConfigurableModuleCls(),
94
+ MODULE_OPTIONS_TOKEN: this.options.optionsInjectionToken,
95
+ ASYNC_OPTIONS_TYPE: this.createTypeProxy('ASYNC_OPTIONS_TYPE'),
96
+ OPTIONS_TYPE: this.createTypeProxy('OPTIONS_TYPE'),
97
+ };
98
+ }
99
+ constructInjectionTokenString() {
100
+ const moduleNameInSnakeCase = this.options
101
+ .moduleName.trim()
102
+ .split(/(?=[A-Z])/)
103
+ .join('_')
104
+ .toUpperCase();
105
+ return `${moduleNameInSnakeCase}_MODULE_OPTIONS`;
106
+ }
107
+ createConfigurableModuleCls() {
108
+ // eslint-disable-next-line @typescript-eslint/no-this-alias
109
+ const self = this;
110
+ const asyncMethodKey = this.staticMethodKey + constants_1.ASYNC_METHOD_SUFFIX;
111
+ class InternalModuleClass {
112
+ static [self.staticMethodKey](options) {
113
+ const providers = [
114
+ {
115
+ provide: self.options.optionsInjectionToken,
116
+ useValue: this.omitExtras(options, self.extras),
117
+ },
118
+ ];
119
+ if (self.options.alwaysTransient) {
120
+ providers.push({
121
+ provide: constants_1.CONFIGURABLE_MODULE_ID,
122
+ useValue: (0, random_string_generator_util_1.randomStringGenerator)(),
123
+ });
124
+ }
125
+ return self.transformModuleDefinition({
126
+ module: this,
127
+ providers,
128
+ }, {
129
+ ...self.extras,
130
+ ...options,
131
+ });
132
+ }
133
+ static [asyncMethodKey](options) {
134
+ const providers = this.createAsyncProviders(options);
135
+ if (self.options.alwaysTransient) {
136
+ providers.push({
137
+ provide: constants_1.CONFIGURABLE_MODULE_ID,
138
+ useValue: (0, random_string_generator_util_1.randomStringGenerator)(),
139
+ });
140
+ }
141
+ return self.transformModuleDefinition({
142
+ module: this,
143
+ imports: options.imports || [],
144
+ providers,
145
+ }, {
146
+ ...self.extras,
147
+ ...this.extractExtrasFromAsyncOptions(options, self.extras),
148
+ });
149
+ }
150
+ static omitExtras(input, extras) {
151
+ if (!extras) {
152
+ return input;
153
+ }
154
+ const moduleOptions = {};
155
+ const extrasKeys = Object.keys(extras);
156
+ Object.keys(input)
157
+ .filter(key => !extrasKeys.includes(key))
158
+ .forEach(key => {
159
+ moduleOptions[key] = input[key];
160
+ });
161
+ return moduleOptions;
162
+ }
163
+ static extractExtrasFromAsyncOptions(input, extras) {
164
+ if (!extras) {
165
+ return {};
166
+ }
167
+ const extrasOptions = {};
168
+ Object.keys(input)
169
+ .filter(key => !constants_1.ASYNC_OPTIONS_METADATA_KEYS.includes(key))
170
+ .forEach(key => {
171
+ extrasOptions[key] = input[key];
172
+ });
173
+ return extrasOptions;
174
+ }
175
+ static createAsyncProviders(options) {
176
+ if (options.useExisting || options.useFactory) {
177
+ if (options.inject && options.provideInjectionTokensFrom) {
178
+ return [
179
+ this.createAsyncOptionsProvider(options),
180
+ ...(0, utils_1.getInjectionProviders)(options.provideInjectionTokensFrom, options.inject),
181
+ ];
182
+ }
183
+ return [this.createAsyncOptionsProvider(options)];
184
+ }
185
+ return [
186
+ this.createAsyncOptionsProvider(options),
187
+ {
188
+ provide: options.useClass,
189
+ useClass: options.useClass,
190
+ },
191
+ ];
192
+ }
193
+ static createAsyncOptionsProvider(options) {
194
+ if (options.useFactory) {
195
+ return {
196
+ provide: self.options.optionsInjectionToken,
197
+ useFactory: options.useFactory,
198
+ inject: options.inject || [],
199
+ };
200
+ }
201
+ return {
202
+ provide: self.options.optionsInjectionToken,
203
+ useFactory: async (optionsFactory) => await optionsFactory[self.factoryClassMethodKey](),
204
+ inject: [options.useExisting || options.useClass],
205
+ };
206
+ }
207
+ }
208
+ return InternalModuleClass;
209
+ }
210
+ createTypeProxy(typeName) {
211
+ const proxy = new Proxy({}, {
212
+ get: () => {
213
+ throw new Error(`"${typeName}" is not supposed to be used as a value.`);
214
+ },
215
+ });
216
+ return proxy;
217
+ }
218
+ }
219
+ exports.ConfigurableModuleBuilder = ConfigurableModuleBuilder;
node_modules/@nestjs/common/module-utils/constants.d.ts ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
 
1
+ export declare const DEFAULT_METHOD_KEY = "register";
2
+ export declare const DEFAULT_FACTORY_CLASS_METHOD_KEY = "create";
3
+ export declare const ASYNC_METHOD_SUFFIX = "Async";
4
+ export declare const CONFIGURABLE_MODULE_ID = "CONFIGURABLE_MODULE_ID";
5
+ /**
6
+ * List of keys that are specific to ConfigurableModuleAsyncOptions
7
+ * and should be excluded when extracting user-defined extras.
8
+ */
9
+ export declare const ASYNC_OPTIONS_METADATA_KEYS: readonly ["useFactory", "useClass", "useExisting", "inject", "imports", "provideInjectionTokensFrom"];
node_modules/@nestjs/common/module-utils/constants.js ADDED
@@ -0,0 +1,19 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ASYNC_OPTIONS_METADATA_KEYS = exports.CONFIGURABLE_MODULE_ID = exports.ASYNC_METHOD_SUFFIX = exports.DEFAULT_FACTORY_CLASS_METHOD_KEY = exports.DEFAULT_METHOD_KEY = void 0;
4
+ exports.DEFAULT_METHOD_KEY = 'register';
5
+ exports.DEFAULT_FACTORY_CLASS_METHOD_KEY = 'create';
6
+ exports.ASYNC_METHOD_SUFFIX = 'Async';
7
+ exports.CONFIGURABLE_MODULE_ID = 'CONFIGURABLE_MODULE_ID';
8
+ /**
9
+ * List of keys that are specific to ConfigurableModuleAsyncOptions
10
+ * and should be excluded when extracting user-defined extras.
11
+ */
12
+ exports.ASYNC_OPTIONS_METADATA_KEYS = [
13
+ 'useFactory',
14
+ 'useClass',
15
+ 'useExisting',
16
+ 'inject',
17
+ 'imports',
18
+ 'provideInjectionTokensFrom',
19
+ ];
node_modules/@nestjs/common/module-utils/index.d.ts ADDED
@@ -0,0 +1,2 @@
 
 
 
1
+ export * from './configurable-module.builder';
2
+ export * from './interfaces';
node_modules/@nestjs/common/module-utils/index.js ADDED
@@ -0,0 +1,5 @@
 
 
 
 
 
 
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ const tslib_1 = require("tslib");
4
+ tslib_1.__exportStar(require("./configurable-module.builder"), exports);
5
+ tslib_1.__exportStar(require("./interfaces"), exports);
node_modules/@nestjs/common/module-utils/interfaces/configurable-module-async-options.interface.d.ts ADDED
@@ -0,0 +1,42 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import { FactoryProvider, ModuleMetadata, Provider, Type } from '../../interfaces';
2
+ import { DEFAULT_FACTORY_CLASS_METHOD_KEY } from '../constants';
3
+ /**
4
+ * Interface that must be implemented by the module options factory class.
5
+ * Method key varies depending on the "FactoryClassMethodKey" type argument.
6
+ *
7
+ * @publicApi
8
+ */
9
+ export type ConfigurableModuleOptionsFactory<ModuleOptions, FactoryClassMethodKey extends string> = Record<`${FactoryClassMethodKey}`, () => Promise<ModuleOptions> | ModuleOptions>;
10
+ /**
11
+ * Interface that represents the module async options object
12
+ * Factory method name varies depending on the "FactoryClassMethodKey" type argument.
13
+ *
14
+ * @publicApi
15
+ */
16
+ export interface ConfigurableModuleAsyncOptions<ModuleOptions, FactoryClassMethodKey extends string = typeof DEFAULT_FACTORY_CLASS_METHOD_KEY> extends Pick<ModuleMetadata, 'imports'> {
17
+ /**
18
+ * Injection token resolving to an existing provider. The provider must implement
19
+ * the corresponding interface.
20
+ */
21
+ useExisting?: Type<ConfigurableModuleOptionsFactory<ModuleOptions, FactoryClassMethodKey>>;
22
+ /**
23
+ * Injection token resolving to a class that will be instantiated as a provider.
24
+ * The class must implement the corresponding interface.
25
+ */
26
+ useClass?: Type<ConfigurableModuleOptionsFactory<ModuleOptions, FactoryClassMethodKey>>;
27
+ /**
28
+ * Function returning options (or a Promise resolving to options) to configure the
29
+ * module.
30
+ */
31
+ useFactory?: (...args: any[]) => Promise<ModuleOptions> | ModuleOptions;
32
+ /**
33
+ * Dependencies that a Factory may inject.
34
+ */
35
+ inject?: FactoryProvider['inject'];
36
+ /**
37
+ * List of parent module's providers that will be filtered to only provide necessary
38
+ * providers for the 'inject' array
39
+ * useful to pass options to nested async modules
40
+ */
41
+ provideInjectionTokensFrom?: Provider[];
42
+ }
node_modules/@nestjs/common/module-utils/interfaces/configurable-module-async-options.interface.js ADDED
@@ -0,0 +1,2 @@
 
 
 
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
node_modules/@nestjs/common/module-utils/interfaces/configurable-module-cls.interface.d.ts ADDED
@@ -0,0 +1,13 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import { DynamicModule } from '../../interfaces';
2
+ import { DEFAULT_FACTORY_CLASS_METHOD_KEY, DEFAULT_METHOD_KEY } from '../constants';
3
+ import { ConfigurableModuleAsyncOptions } from './configurable-module-async-options.interface';
4
+ /**
5
+ * Class that represents a blueprint/prototype for a configurable Nest module.
6
+ * This class provides static methods for constructing dynamic modules. Their names
7
+ * can be controlled through the "MethodKey" type argument.
8
+ *
9
+ * @publicApi
10
+ */
11
+ export type ConfigurableModuleCls<ModuleOptions, MethodKey extends string = typeof DEFAULT_METHOD_KEY, FactoryClassMethodKey extends string = typeof DEFAULT_FACTORY_CLASS_METHOD_KEY, ExtraModuleDefinitionOptions = {}> = {
12
+ new (): any;
13
+ } & Record<`${MethodKey}`, (options: ModuleOptions & Partial<ExtraModuleDefinitionOptions>) => DynamicModule> & Record<`${MethodKey}Async`, (options: ConfigurableModuleAsyncOptions<ModuleOptions, FactoryClassMethodKey> & Partial<ExtraModuleDefinitionOptions>) => DynamicModule>;
node_modules/@nestjs/common/module-utils/interfaces/configurable-module-cls.interface.js ADDED
@@ -0,0 +1,2 @@
 
 
 
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
node_modules/@nestjs/common/module-utils/interfaces/configurable-module-host.interface.d.ts ADDED
@@ -0,0 +1,62 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import { ConfigurableModuleAsyncOptions } from './configurable-module-async-options.interface';
2
+ import { ConfigurableModuleCls } from './configurable-module-cls.interface';
3
+ /**
4
+ * Configurable module host. See properties for more details
5
+ *
6
+ * @publicApi
7
+ */
8
+ export interface ConfigurableModuleHost<ModuleOptions = Record<string, unknown>, MethodKey extends string = string, FactoryClassMethodKey extends string = string, ExtraModuleDefinitionOptions = {}> {
9
+ /**
10
+ * Class that represents a blueprint/prototype for a configurable Nest module.
11
+ * This class provides static methods for constructing dynamic modules. Their names
12
+ * can be controlled through the "MethodKey" type argument.
13
+ *
14
+ * Your module class should inherit from this class to make the static methods available.
15
+ *
16
+ * @example
17
+ * ```typescript
18
+ * @Module({})
19
+ * class IntegrationModule extends ConfigurableModuleCls {
20
+ * // ...
21
+ * }
22
+ * ```
23
+ */
24
+ ConfigurableModuleClass: ConfigurableModuleCls<ModuleOptions, MethodKey, FactoryClassMethodKey, ExtraModuleDefinitionOptions>;
25
+ /**
26
+ * Module options provider token. Can be used to inject the "options object" to
27
+ * providers registered within the host module.
28
+ */
29
+ MODULE_OPTIONS_TOKEN: string | symbol;
30
+ /**
31
+ * Can be used to auto-infer the compound "async module options" type.
32
+ * Note: this property is not supposed to be used as a value.
33
+ *
34
+ * @example
35
+ * ```typescript
36
+ * @Module({})
37
+ * class IntegrationModule extends ConfigurableModuleCls {
38
+ * static module = initializer(IntegrationModule);
39
+ *
40
+ * static registerAsync(options: typeof ASYNC_OPTIONS_TYPE): DynamicModule {
41
+ * return super.registerAsync(options);
42
+ * }
43
+ * ```
44
+ */
45
+ ASYNC_OPTIONS_TYPE: ConfigurableModuleAsyncOptions<ModuleOptions, FactoryClassMethodKey> & Partial<ExtraModuleDefinitionOptions>;
46
+ /**
47
+ * Can be used to auto-infer the compound "module options" type (options interface + extra module definition options).
48
+ * Note: this property is not supposed to be used as a value.
49
+ *
50
+ * @example
51
+ * ```typescript
52
+ * @Module({})
53
+ * class IntegrationModule extends ConfigurableModuleCls {
54
+ * static module = initializer(IntegrationModule);
55
+ *
56
+ * static register(options: typeof OPTIONS_TYPE): DynamicModule {
57
+ * return super.register(options);
58
+ * }
59
+ * ```
60
+ */
61
+ OPTIONS_TYPE: ModuleOptions & Partial<ExtraModuleDefinitionOptions>;
62
+ }
node_modules/@nestjs/common/module-utils/interfaces/configurable-module-host.interface.js ADDED
@@ -0,0 +1,2 @@
 
 
 
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
node_modules/@nestjs/common/module-utils/interfaces/index.d.ts ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ export * from './configurable-module-async-options.interface';
2
+ export * from './configurable-module-cls.interface';
3
+ export * from './configurable-module-host.interface';
node_modules/@nestjs/common/module-utils/interfaces/index.js ADDED
@@ -0,0 +1,6 @@
 
 
 
 
 
 
 
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ const tslib_1 = require("tslib");
4
+ tslib_1.__exportStar(require("./configurable-module-async-options.interface"), exports);
5
+ tslib_1.__exportStar(require("./configurable-module-cls.interface"), exports);
6
+ tslib_1.__exportStar(require("./configurable-module-host.interface"), exports);
node_modules/@nestjs/common/module-utils/utils/generate-options-injection-token.util.d.ts ADDED
@@ -0,0 +1 @@
 
 
1
+ export declare function generateOptionsInjectionToken(): string;
node_modules/@nestjs/common/module-utils/utils/generate-options-injection-token.util.js ADDED
@@ -0,0 +1,8 @@
 
 
 
 
 
 
 
 
 
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.generateOptionsInjectionToken = generateOptionsInjectionToken;
4
+ const random_string_generator_util_1 = require("../../utils/random-string-generator.util");
5
+ function generateOptionsInjectionToken() {
6
+ const hash = (0, random_string_generator_util_1.randomStringGenerator)();
7
+ return `CONFIGURABLE_MODULE_OPTIONS[${hash}]`;
8
+ }
node_modules/@nestjs/common/module-utils/utils/get-injection-providers.util.d.ts ADDED
@@ -0,0 +1,8 @@
 
 
 
 
 
 
 
 
 
1
+ import { FactoryProvider, Provider } from '../../interfaces';
2
+ /**
3
+ *
4
+ * @param providers List of a module's providers
5
+ * @param tokens Injection tokens needed for a useFactory function (usually the module's options' token)
6
+ * @returns All the providers needed for the tokens' injection (searched recursively)
7
+ */
8
+ export declare function getInjectionProviders(providers: Provider[], tokens: FactoryProvider['inject']): Provider[];
node_modules/@nestjs/common/module-utils/utils/get-injection-providers.util.js ADDED
@@ -0,0 +1,35 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.getInjectionProviders = getInjectionProviders;
4
+ const shared_utils_1 = require("../../utils/shared.utils");
5
+ /**
6
+ * @param value
7
+ * @returns `true` if value is `OptionalFactoryDependency`
8
+ */
9
+ function isOptionalFactoryDependency(value) {
10
+ return (!(0, shared_utils_1.isUndefined)(value.token) &&
11
+ !(0, shared_utils_1.isUndefined)(value.optional) &&
12
+ !value.prototype);
13
+ }
14
+ const mapInjectToTokens = (t) => isOptionalFactoryDependency(t) ? t.token : t;
15
+ /**
16
+ *
17
+ * @param providers List of a module's providers
18
+ * @param tokens Injection tokens needed for a useFactory function (usually the module's options' token)
19
+ * @returns All the providers needed for the tokens' injection (searched recursively)
20
+ */
21
+ function getInjectionProviders(providers, tokens) {
22
+ const result = [];
23
+ let search = tokens.map(mapInjectToTokens);
24
+ while (search.length > 0) {
25
+ const match = (providers ?? []).filter(p => !result.includes(p) && // this prevents circular loops and duplication
26
+ (search.includes(p) || search.includes(p?.provide)));
27
+ result.push(...match);
28
+ // get injection tokens of the matched providers, if any
29
+ search = match
30
+ .filter(p => p?.inject)
31
+ .flatMap(p => p.inject)
32
+ .map(mapInjectToTokens);
33
+ }
34
+ return result;
35
+ }
node_modules/@nestjs/common/module-utils/utils/index.d.ts ADDED
@@ -0,0 +1,2 @@
 
 
 
1
+ export * from './generate-options-injection-token.util';
2
+ export * from './get-injection-providers.util';