node-web-mvc
Version:
node spring mvc
73 lines (72 loc) • 2.06 kB
TypeScript
import http from 'http';
import https from 'https';
import http2 from 'http2';
import { HotOptions } from '../hmr/src';
import { ClazzType } from '../interface/declare';
import RuntimeAnnotation from './annotations/annotation/RuntimeAnnotation';
interface BaseServerOptions {
/**
* 设置当前服务的端口
*/
port: number;
/**
* 设置当前服务的基础路由目录 默认为 /
*/
base?: string;
}
interface HttpServerOptions extends http.ServerOptions, BaseServerOptions {
httpType?: 'http';
}
interface HttpsServerOptions extends https.ServerOptions, BaseServerOptions {
httpType: 'https';
}
interface Http2ServerOptions extends http2.ServerOptions, BaseServerOptions {
httpType: 'http2';
}
export type NodeServerOptions = HttpServerOptions | HttpsServerOptions | Http2ServerOptions;
export declare class SpringBootApplication {
/**
* 需要排除的自动配置类
*/
exclude?: ClazzType[];
/**
* 根据名称来设定需要排除的自动配置类
*/
excludeName?: string[];
/**
* 要排除的扫描文件
*/
excludeScan?: string | string[];
/**
* 扫描模块目录, 默认为当前启动目录
*/
scanBasePackages: string | string[];
/**
* 是否关闭默认的启动日志
*/
launchLogOff?: boolean;
/**
* 是否开启swagger文档
*/
swagger?: boolean;
/**
* 热更新配置
* @param meta
*/
hot?: HotOptions | HotOptions['cwd'];
/**
* http服务配置
*/
server?: NodeServerOptions;
/**
* 是否为构建后的启动
*/
isDist?: boolean;
protected onInitialize(): void;
constructor(meta: RuntimeAnnotation);
}
declare const _default: {
(target: Function): any;
(options: import("./annotations/Target").CreateOptions<typeof SpringBootApplication>): ClassDecorator;
} & import("./annotations/annotation/type").LinkAnnotationType<typeof SpringBootApplication> & typeof SpringBootApplication;
export default _default;