1 | import { INestApplication, INestApplicationContext, INestMicroservice } from '@nestjs/common';
|
2 | import { NestMicroserviceOptions } from '@nestjs/common/interfaces/microservices/nest-microservice-options.interface';
|
3 | import { NestApplicationContextOptions } from '@nestjs/common/interfaces/nest-application-context-options.interface';
|
4 | import { NestApplicationOptions } from '@nestjs/common/interfaces/nest-application-options.interface';
|
5 | import { AbstractHttpAdapter } from './adapters/http-adapter';
|
6 |
|
7 |
|
8 |
|
9 | export declare class NestFactoryStatic {
|
10 | private readonly logger;
|
11 | private abortOnError;
|
12 | private autoFlushLogs;
|
13 | |
14 |
|
15 |
|
16 |
|
17 |
|
18 |
|
19 |
|
20 |
|
21 |
|
22 | create<T extends INestApplication = INestApplication>(module: any, options?: NestApplicationOptions): Promise<T>;
|
23 | /**
|
24 | * Creates an instance of NestApplication with the specified `httpAdapter`.
|
25 | *
|
26 | * @param module Entry (root) application module class
|
27 | * @param httpAdapter Adapter to proxy the request/response cycle to
|
28 | * the underlying HTTP server
|
29 | * @param options List of options to initialize NestApplication
|
30 | *
|
31 | * @returns A promise that, when resolved,
|
32 | * contains a reference to the NestApplication instance.
|
33 | */
|
34 | create<T extends INestApplication = INestApplication>(module: any, httpAdapter: AbstractHttpAdapter, options?: NestApplicationOptions): Promise<T>;
|
35 | /**
|
36 | * Creates an instance of NestMicroservice.
|
37 | *
|
38 | * @param moduleCls Entry (root) application module class
|
39 | * @param options Optional microservice configuration
|
40 | *
|
41 | * @returns A promise that, when resolved,
|
42 | * contains a reference to the NestMicroservice instance.
|
43 | */
|
44 | createMicroservice<T extends object>(moduleCls: any, options?: NestMicroserviceOptions & T): Promise<INestMicroservice>;
|
45 | /**
|
46 | * Creates an instance of NestApplicationContext.
|
47 | *
|
48 | * @param moduleCls Entry (root) application module class
|
49 | * @param options Optional Nest application configuration
|
50 | *
|
51 | * @returns A promise that, when resolved,
|
52 | * contains a reference to the NestApplicationContext instance.
|
53 | */
|
54 | createApplicationContext(moduleCls: any, options?: NestApplicationContextOptions): Promise<INestApplicationContext>;
|
55 | private createNestInstance;
|
56 | private initialize;
|
57 | private handleInitializationError;
|
58 | private createProxy;
|
59 | private createExceptionProxy;
|
60 | private createExceptionZone;
|
61 | private registerLoggerConfiguration;
|
62 | private createHttpAdapter;
|
63 | private isHttpServer;
|
64 | private setAbortOnError;
|
65 | private createAdapterProxy;
|
66 | private createGraphInspector;
|
67 | }
|
68 | /**
|
69 | * Use NestFactory to create an application instance.
|
70 | *
|
71 | * ### Specifying an entry module
|
72 | *
|
73 | * Pass the required *root module* for the application via the module parameter.
|
74 | * By convention, it is usually called `ApplicationModule`. Starting with this
|
75 | * module, Nest assembles the dependency graph and begins the process of
|
76 | * Dependency Injection and instantiates the classes needed to launch your
|
77 | * application.
|
78 | *
|
79 | * @publicApi
|
80 | */
|
81 | export declare const NestFactory: NestFactoryStatic;
|