UNPKG

@autorest/common

Version:
26 lines 886 B
import { LogInfo, LogLevel } from "./types"; import { LoggerProcessor } from "."; export interface LogSuppression { code: string; from?: string[] | string; where?: string[] | string; } export interface FilterLoggerOptions { level: LogLevel; suppressions?: LogSuppression[]; } /** * Logger adding filtering functionality based on: * - level: only show log with level higher than the configuration. * - suppression: List of code that should not be logged. */ export declare class FilterLogger implements LoggerProcessor { private level; private suppressions; constructor(options: FilterLoggerOptions); process(log: LogInfo): LogInfo | undefined; private filterSuppressions; private matchesSourceFilter; } export declare function shouldLogLevel(log: LogInfo, level: LogLevel): boolean; //# sourceMappingURL=filter-logger-processor.d.ts.map