DotNetDupe 4.0.6
C++17/20 Implementation of the .NET Base Class Library (BCL)
Loading...
Searching...
No Matches
LogManager.h
Go to the documentation of this file.
1#pragma once
2#include "Common.h"
3#include "System/String.h"
8#include <typeinfo>
9
10namespace DotNetDupe {
11 namespace Extensions {
12 namespace Logging {
13
59
60 }
61 }
62}
Defines common cross-platform macros, export decorators, and fundamental types.
#define DOTNETDUPE_API
Platform-specific linkage decoration for exporting or importing library symbols.
Definition Common.h:20
Provides reference-counted and weak pointer memory management primitives ensuring zero raw ownership.
High-performance UTF-8 / UTF-16 string manipulation class mirroring .NET System.String.
Central thread-safe static registry and entry point for application logging.
Definition LogManager.h:18
static DotNetDupe::System::SmartPointer< ILogger > GetConsoleLogger(const DotNetDupe::System::String &sCategoryName)
Creates a dedicated ConsoleLogger instance for the specified category.
static void Reset()
Resets the LogManager state, releasing all cached loggers and providers.
static DotNetDupe::System::SmartPointer< ILogger > GetLogger(const DotNetDupe::System::String &sCategoryName)
Retrieves or creates a cached ILogger instance for the given category name.
static DotNetDupe::System::SmartPointer< ILogger > GetFileLogger(const DotNetDupe::System::String &sCategoryName)
Creates a dedicated FileLogger instance for the specified category.
static const LoggerConfiguration & GetConfiguration()
Gets the active global LoggerConfiguration.
static void AddProvider(const DotNetDupe::System::SmartPointer< ILoggerProvider > &pProvider)
Adds an ILoggerProvider to the internal global LoggerFactory.
static DotNetDupe::System::SmartPointer< ILoggerOf< T > > GetLogger()
Retrieves a strongly-typed ILoggerOf<T> where the category name is derived from type T.
Definition LogManager.h:29
static void Configure(const LoggerConfiguration &config)
Sets the global LoggerConfiguration applied across created loggers.
Supports all classes in the DotNetDupe class hierarchy.
Definition Object.h:18
A unified smart pointer that supports both unique and shared ownership semantics.
Represents text as a sequence of UTF-8 code units with culture-invariant operations.
Definition String.h:74
Encapsulates logging system configuration options.