Skip to main content

log-more > ConfigurationManager

ConfigurationManager class​

A static class used to manage the log-more configuration data

Signature:
export declare class ConfigurationManager 

Properties​

PropertyModifiersTypeDescription
getConfigstatic() => Result<LogMoreConfig>Get the current log configuration object
getConfigItemstatic<T>(name: string) => Result<T>Get an item from the current log configuration object
getLogEventConfigstatic(type: string) => LogEventConfigGet the current configuration for a specified log event type
getLogEventRegistrystatic() => Result<TypedIndexable<LogEventConfig>>Get all of the current configurations for the defined for log event types
setConfigstatic(params?: Partial<LogMoreConfig<LogEventConfig<import("./types").ResultConfig<import("@log-more/base").CallbackFunction<unknown, import("@log-more/base").IResult<unknown, any, any>, unknown, import("@log-more/base").IResult<unknown, any, any>>>, import("./types").ReportConfig<import("./types").FormatFunction<unknown, Result<unknown>, import("@log-more/base").FormattedData, import("@log-more/base").Report<import("@log-more/base").FormattedData>, Result<import("@log-more/base").Report<import("@log-more/base").FormattedData>>>, import("./types").CaptureFunction<import("@log-more/base").FormattedData, import("@log-more/base").Report<import("@log-more/base").FormattedData>, unknown, Result<unknown>>, import("./types").ReportFunction<unknown, Result<unknown>, unknown, Result<unknown>>>>, import("@log-more/base").UserConfig>> | undefined) => ResultSet the configuration for how logging should be handled
setConfigItemstatic<T = unknown>(name: string, value: T) => ResultSet a specific item value on the configuration object
tryGetLogEventConfigstatic(type: string) => Result<LogEventConfig>Get the current configuration for a specified log event type

Methods​

MethodModifiersDescription
init(defaultConfig)staticA function used to initialize the configuration in memory