1 | import { ArgumentsHost, ExceptionFilter, HttpServer } from '@nestjs/common';
|
2 | import { AbstractHttpAdapter } from '../adapters';
|
3 | import { HttpAdapterHost } from '../helpers/http-adapter-host';
|
4 | export declare class BaseExceptionFilter<T = any> implements ExceptionFilter<T> {
|
5 | protected readonly applicationRef?: HttpServer;
|
6 | private static readonly logger;
|
7 | protected readonly httpAdapterHost?: HttpAdapterHost;
|
8 | constructor(applicationRef?: HttpServer);
|
9 | catch(exception: T, host: ArgumentsHost): void;
|
10 | handleUnknownError(exception: T, host: ArgumentsHost, applicationRef: AbstractHttpAdapter | HttpServer): void;
|
11 | isExceptionObject(err: any): err is Error;
|
12 | /**
|
13 | * Checks if the thrown error comes from the "http-errors" library.
|
14 | * @param err error object
|
15 | */
|
16 | isHttpError(err: any): err is {
|
17 | statusCode: number;
|
18 | message: string;
|
19 | };
|
20 | }
|