# RequestLogger Class

Module
import { RequestLogger } from "@tsed/common"
Source/packages/common/src/platform/domain/RequestLogger.ts

# Overview

class RequestLogger {
    readonly id: string;
    readonly url: string;
    readonly startDate: Date;
    maxStackSize: number;
    minimalRequestPicker: Function;
    completeRequestPicker: Function;
    info(obj: any): void;
    debug(obj: any, withRequest?: boolean): void;
    warn(obj: any): void;
    error(obj: any): void;
    trace(obj: any): void;
    flush(): void;
    isLevelEnabled(otherLevel: string | LogLevel): boolean;
    destroy(): void;
    protected getDuration(): number;
    protected getData(obj: any): any;
    protected run(level: LogLevel, cb: Function): void;
}

# Members

readonly id: string

readonly url: string

readonly startDate: Date

maxStackSize: number

minimalRequestPicker: Function

completeRequestPicker: Function

info(obj: any): void

debug(obj: any, withRequest?: boolean): void

warn(obj: any): void

error(obj: any): void

trace(obj: any): void

flush(): void

isLevelEnabled(otherLevel: string | LogLevel): boolean

destroy(): void

protected getDuration(): number

Return the duration between the time when LogIncomingRequest has handle the request and now.


protected getData(obj: any): any

protected run(level: LogLevel, cb: Function): void