A flexible and extensible .NET library for custom logging, supporting multiple logging engines, log broadcasting, and contextual logging with file path customization.
$ dotnet add package Oakrey.Applications.CustomLoggingThe "CustomLogging" project is a .NET 8 library designed to provide a flexible and extensible logging framework. It supports multiple logging engines, including console, debug, file, and in-memory logging, and allows for broadcasting log messages to multiple receivers.
CustomLoggerBroadcast allows broadcasting log messages to multiple logging engines simultaneously.
LogMessage provides a structured format for log entries, including log level, message, source, and indentation.
Supports Info, Warning, and Error log levels (LogLevel).
DocumentsCustomFilePathProvider provides a default implementation for managing log file paths in the user's documents folder.
Interfaces like ICustomLogger, ICustomLoggerEngine, and ICustomLoggerFilePathProvider allow for easy extension and customization.
Supports setting a current context item for more meaningful log entries. 1.
You can install the package via NuGet Package Manager, Package Manager Console or the .NET CLI.
Oakrey.Applications.CustomLogging and click Install.Run the following command in your terminal:
dotnet add package Oakrey.Applications.CustomLogging
Run the following command in your Package Manager Console:
Install-Package Oakrey.Applications.CustomLogging
Contributions are welcome! Feel free to open issues or submit pull requests to improve the package.
This project is licensed under the MIT License. See the LICENSE file for details.