[REFACTOR] Refactored logging & added support for Microsoft.Extensions.Logging. Added test WebApi project

This commit is contained in:
max
2024-11-17 22:51:54 +01:00
parent 58739c2aea
commit 737cbcfd11
31 changed files with 398 additions and 97 deletions

View File

@@ -0,0 +1,14 @@
using Microsoft.Extensions.Logging;
namespace DotBased.Logging.MEL;
public static class LoggerBuilderExtensions
{
public static ILoggingBuilder AddDotBased(this ILoggingBuilder builder, LogOptions options)
{
if (builder == null)
throw new ArgumentNullException(nameof(builder));
builder.AddProvider(new BasedLoggerProvider(options));
return builder;
}
}