import { LoggerBuilder , LoggerConfigurationBuilder , LogLevel } from "simplr-logger" ; const LoggerConfiguration = new LoggerConfigurationBuilder ( ) . SetDefaultLogLevel ( LogLevel . Information ) . Build ( ) ; export const Logger = new LoggerBuilder ( LoggerConfiguration ) ; export namespace LoggerHelpers { /**
     * Returns string keys of LogLevel.
     */ export function GetLogLevelKeys ( ) { return Object . values ( LogLevel ) . filter ( x => typeof x === "string" ) ; } export function ParseLogLevelKey ( key ) { const logLevelEnum = LogLevel as any as { [ key ] : number ; } ; if ( logLevelEnum [ key ] == null ) { throw `LogLevel ${ key } was not found.` ; } return logLevelEnum [ key ] ; } export function SetLogLevel ( level ) { Logger . UpdateConfiguration ( updater => updater . SetDefaultLogLevel ( level ) . Build ( ) , false ) ; } }