DotNetDupe 4.0.6
C++17/20 Implementation of the .NET Base Class Library (BCL)
Loading...
Searching...
No Matches
AggregateLogger.h
Go to the documentation of this file.
1#pragma once
2#include "Common.h"
4
5
6namespace DotNetDupe {
7 namespace Extensions {
8 namespace Logging {
9
14 class AggregateLogger : public ILogger {
15 private:
16 struct Impl;
18
19 public:
22
25
29
33 DOTNETDUPE_API void Log(LogLevel logLevel, const DotNetDupe::System::String& message) override;
34
39 DOTNETDUPE_API void Log(LogLevel logLevel, const DotNetDupe::System::String& message,
41
45 DOTNETDUPE_API bool IsEnabled(LogLevel logLevel) const override;
46 };
47
48 }
49 }
50}
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
AggregateLogger()
Initializes an empty AggregateLogger composite.
void AddLogger(const DotNetDupe::System::SmartPointer< ILogger > &pLogger)
Adds a child ILogger destination to the dispatch list.
void Log(LogLevel logLevel, const DotNetDupe::System::String &message) override
Dispatches a plain text message to all attached child loggers.
~AggregateLogger() override
Destructor releasing aggregated loggers.
bool IsEnabled(LogLevel logLevel) const override
Checks if any attached child logger is enabled for the specified level.
Represents a type used to perform logging.
Definition ILogger.h:36
Represents a collection of keys and values.
Definition Dictionary.h:66
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
LogLevel
Defines logging severity levels.
Definition ILogger.h:15