< Summary - AsyncResponse (Release / net8.0+net10.0 / unit+integration)

Information
Class: Microsoft.Extensions.Logging.AsyncResponseLoggerExtensions
Assembly: AsyncResponse.Core
File(s): /home/runner/work/AsyncResponse/AsyncResponse/src/AsyncResponse.Core/Logging/AsyncResponseLoggerExtensions.cs
Line coverage
100%
Covered lines: 113
Uncovered lines: 0
Coverable lines: 113
Total lines: 367
Line coverage: 100%
Branch coverage
100%
Covered branches: 28
Total branches: 28
Branch coverage: 100%
Method coverage

Feature is only available for sponsors

Upgrade to PRO version

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity Line coverage
.cctor()100%11100%
LogDebug(...)100%11100%
LogDebug<T0>(...)100%11100%
LogDebug<T0, T1>(...)100%11100%
LogDebug<T0, T1, T2>(...)100%11100%
LogDebug<T0, T1, T2, T3>(...)100%11100%
LogDebug<T0, T1, T2, T3, T4>(...)100%11100%
LogDebug<T0, T1, T2, T3, T4, T5>(...)100%11100%
LogDebug(...)100%11100%
LogDebug<T0>(...)100%11100%
LogDebug<T0, T1>(...)100%11100%
LogDebug<T0, T1, T2>(...)100%11100%
LogDebug<T0, T1, T2, T3>(...)100%11100%
LogDebug<T0, T1, T2, T3, T4>(...)100%11100%
LogDebug<T0, T1, T2, T3, T4, T5>(...)100%11100%
LogInformation(...)100%11100%
LogInformation<T0>(...)100%11100%
LogInformation<T0, T1>(...)100%11100%
LogInformation<T0, T1, T2>(...)100%11100%
LogInformation<T0, T1, T2, T3>(...)100%11100%
LogInformation<T0, T1, T2, T3, T4>(...)100%11100%
LogInformation<T0, T1, T2, T3, T4, T5>(...)100%11100%
LogInformation(...)100%11100%
LogInformation<T0>(...)100%11100%
LogInformation<T0, T1>(...)100%11100%
LogInformation<T0, T1, T2>(...)100%11100%
LogInformation<T0, T1, T2, T3>(...)100%11100%
LogInformation<T0, T1, T2, T3, T4>(...)100%11100%
LogInformation<T0, T1, T2, T3, T4, T5>(...)100%11100%
LogWarning(...)100%11100%
LogWarning<T0>(...)100%11100%
LogWarning<T0, T1>(...)100%11100%
LogWarning<T0, T1, T2>(...)100%11100%
LogWarning<T0, T1, T2, T3>(...)100%11100%
LogWarning<T0, T1, T2, T3, T4>(...)100%11100%
LogWarning<T0, T1, T2, T3, T4, T5>(...)100%11100%
LogWarning(...)100%11100%
LogWarning<T0>(...)100%11100%
LogWarning<T0, T1>(...)100%11100%
LogWarning<T0, T1, T2>(...)100%11100%
LogWarning<T0, T1, T2, T3>(...)100%11100%
LogWarning<T0, T1, T2, T3, T4>(...)100%11100%
LogWarning<T0, T1, T2, T3, T4, T5>(...)100%11100%
LogError(...)100%11100%
LogError<T0>(...)100%11100%
LogError<T0, T1>(...)100%11100%
LogError<T0, T1, T2>(...)100%11100%
LogError<T0, T1, T2, T3>(...)100%11100%
LogError<T0, T1, T2, T3, T4>(...)100%11100%
LogError<T0, T1, T2, T3, T4, T5>(...)100%11100%
LogError(...)100%11100%
LogError<T0>(...)100%11100%
LogError<T0, T1>(...)100%11100%
LogError<T0, T1, T2>(...)100%11100%
LogError<T0, T1, T2, T3>(...)100%11100%
LogError<T0, T1, T2, T3, T4>(...)100%11100%
LogError<T0, T1, T2, T3, T4, T5>(...)100%11100%
Log(...)100%22100%
Log<T0>(...)100%22100%
Log<T0, T1>(...)100%22100%
Log<T0, T1, T2>(...)100%22100%
Log<T0, T1, T2, T3>(...)100%22100%
Log<T0, T1, T2, T3, T4>(...)100%22100%
Log<T0, T1, T2, T3, T4, T5>(...)100%22100%
.cctor()100%11100%
Get(...)100%22100%
.cctor()100%11100%
Get(...)100%22100%
.cctor()100%11100%
Get(...)100%22100%
.cctor()100%11100%
Get(...)100%22100%
.cctor()100%11100%
Get(...)100%22100%
.cctor()100%11100%
Get(...)100%22100%
.cctor()100%11100%
Get(...)100%22100%

File(s)

/home/runner/work/AsyncResponse/AsyncResponse/src/AsyncResponse.Core/Logging/AsyncResponseLoggerExtensions.cs

#LineLine coverage
 1using System.Collections.Concurrent;
 2
 3namespace Microsoft.Extensions.Logging;
 4
 5internal static class AsyncResponseLoggerExtensions
 6{
 37    private static readonly LogDefineOptions Options = new() { SkipEnabledCheck = true };
 8
 9    /// <summary>Runs the LogDebug operation.</summary>
 10    public static void LogDebug(this ILogger logger, string message)
 211        => Log(logger, LogLevel.Debug, exception: null, message);
 12
 13    /// <summary>Runs the LogDebug operation.</summary>
 14    public static void LogDebug<T0>(this ILogger logger, string message, T0 arg0)
 315        => Log(logger, LogLevel.Debug, exception: null, message, arg0);
 16
 17    /// <summary>Runs the LogDebug operation.</summary>
 18    public static void LogDebug<T0, T1>(this ILogger logger, string message, T0 arg0, T1 arg1)
 319        => Log(logger, LogLevel.Debug, exception: null, message, arg0, arg1);
 20
 21    /// <summary>Runs the LogDebug operation.</summary>
 22    public static void LogDebug<T0, T1, T2>(this ILogger logger, string message, T0 arg0, T1 arg1, T2 arg2)
 323        => Log(logger, LogLevel.Debug, exception: null, message, arg0, arg1, arg2);
 24
 25    /// <summary>Runs the LogDebug operation.</summary>
 26    public static void LogDebug<T0, T1, T2, T3>(this ILogger logger, string message, T0 arg0, T1 arg1, T2 arg2, T3 arg3)
 327        => Log(logger, LogLevel.Debug, exception: null, message, arg0, arg1, arg2, arg3);
 28
 29    /// <summary>Runs the LogDebug operation.</summary>
 30    public static void LogDebug<T0, T1, T2, T3, T4>(this ILogger logger, string message, T0 arg0, T1 arg1, T2 arg2, T3 a
 331        => Log(logger, LogLevel.Debug, exception: null, message, arg0, arg1, arg2, arg3, arg4);
 32
 33    /// <summary>Runs the LogDebug operation.</summary>
 34    public static void LogDebug<T0, T1, T2, T3, T4, T5>(this ILogger logger, string message, T0 arg0, T1 arg1, T2 arg2, 
 235        => Log(logger, LogLevel.Debug, exception: null, message, arg0, arg1, arg2, arg3, arg4, arg5);
 36
 37    /// <summary>Runs the LogDebug operation.</summary>
 38    public static void LogDebug(this ILogger logger, Exception? exception, string message)
 239        => Log(logger, LogLevel.Debug, exception, message);
 40
 41    /// <summary>Runs the LogDebug operation.</summary>
 42    public static void LogDebug<T0>(this ILogger logger, Exception? exception, string message, T0 arg0)
 343        => Log(logger, LogLevel.Debug, exception, message, arg0);
 44
 45    /// <summary>Runs the LogDebug operation.</summary>
 46    public static void LogDebug<T0, T1>(this ILogger logger, Exception? exception, string message, T0 arg0, T1 arg1)
 347        => Log(logger, LogLevel.Debug, exception, message, arg0, arg1);
 48
 49    /// <summary>Runs the LogDebug operation.</summary>
 50    public static void LogDebug<T0, T1, T2>(this ILogger logger, Exception? exception, string message, T0 arg0, T1 arg1,
 351        => Log(logger, LogLevel.Debug, exception, message, arg0, arg1, arg2);
 52
 53    /// <summary>Runs the LogDebug operation.</summary>
 54    public static void LogDebug<T0, T1, T2, T3>(this ILogger logger, Exception? exception, string message, T0 arg0, T1 a
 255        => Log(logger, LogLevel.Debug, exception, message, arg0, arg1, arg2, arg3);
 56
 57    /// <summary>Runs the LogDebug operation.</summary>
 58    public static void LogDebug<T0, T1, T2, T3, T4>(this ILogger logger, Exception? exception, string message, T0 arg0, 
 259        => Log(logger, LogLevel.Debug, exception, message, arg0, arg1, arg2, arg3, arg4);
 60
 61    /// <summary>Runs the LogDebug operation.</summary>
 62    public static void LogDebug<T0, T1, T2, T3, T4, T5>(this ILogger logger, Exception? exception, string message, T0 ar
 263        => Log(logger, LogLevel.Debug, exception, message, arg0, arg1, arg2, arg3, arg4, arg5);
 64
 65    /// <summary>Runs the LogInformation operation.</summary>
 66    public static void LogInformation(this ILogger logger, string message)
 267        => Log(logger, LogLevel.Information, exception: null, message);
 68
 69    /// <summary>Runs the LogInformation operation.</summary>
 70    public static void LogInformation<T0>(this ILogger logger, string message, T0 arg0)
 371        => Log(logger, LogLevel.Information, exception: null, message, arg0);
 72
 73    /// <summary>Runs the LogInformation operation.</summary>
 74    public static void LogInformation<T0, T1>(this ILogger logger, string message, T0 arg0, T1 arg1)
 375        => Log(logger, LogLevel.Information, exception: null, message, arg0, arg1);
 76
 77    /// <summary>Runs the LogInformation operation.</summary>
 78    public static void LogInformation<T0, T1, T2>(this ILogger logger, string message, T0 arg0, T1 arg1, T2 arg2)
 379        => Log(logger, LogLevel.Information, exception: null, message, arg0, arg1, arg2);
 80
 81    /// <summary>Runs the LogInformation operation.</summary>
 82    public static void LogInformation<T0, T1, T2, T3>(this ILogger logger, string message, T0 arg0, T1 arg1, T2 arg2, T3
 383        => Log(logger, LogLevel.Information, exception: null, message, arg0, arg1, arg2, arg3);
 84
 85    /// <summary>Runs the LogInformation operation.</summary>
 86    public static void LogInformation<T0, T1, T2, T3, T4>(this ILogger logger, string message, T0 arg0, T1 arg1, T2 arg2
 387        => Log(logger, LogLevel.Information, exception: null, message, arg0, arg1, arg2, arg3, arg4);
 88
 89    /// <summary>Runs the LogInformation operation.</summary>
 90    public static void LogInformation<T0, T1, T2, T3, T4, T5>(this ILogger logger, string message, T0 arg0, T1 arg1, T2 
 291        => Log(logger, LogLevel.Information, exception: null, message, arg0, arg1, arg2, arg3, arg4, arg5);
 92
 93    /// <summary>Runs the LogInformation operation.</summary>
 94    public static void LogInformation(this ILogger logger, Exception? exception, string message)
 295        => Log(logger, LogLevel.Information, exception, message);
 96
 97    /// <summary>Runs the LogInformation operation.</summary>
 98    public static void LogInformation<T0>(this ILogger logger, Exception? exception, string message, T0 arg0)
 299        => Log(logger, LogLevel.Information, exception, message, arg0);
 100
 101    /// <summary>Runs the LogInformation operation.</summary>
 102    public static void LogInformation<T0, T1>(this ILogger logger, Exception? exception, string message, T0 arg0, T1 arg
 2103        => Log(logger, LogLevel.Information, exception, message, arg0, arg1);
 104
 105    /// <summary>Runs the LogInformation operation.</summary>
 106    public static void LogInformation<T0, T1, T2>(this ILogger logger, Exception? exception, string message, T0 arg0, T1
 2107        => Log(logger, LogLevel.Information, exception, message, arg0, arg1, arg2);
 108
 109    /// <summary>Runs the LogInformation operation.</summary>
 110    public static void LogInformation<T0, T1, T2, T3>(this ILogger logger, Exception? exception, string message, T0 arg0
 2111        => Log(logger, LogLevel.Information, exception, message, arg0, arg1, arg2, arg3);
 112
 113    /// <summary>Runs the LogInformation operation.</summary>
 114    public static void LogInformation<T0, T1, T2, T3, T4>(this ILogger logger, Exception? exception, string message, T0 
 2115        => Log(logger, LogLevel.Information, exception, message, arg0, arg1, arg2, arg3, arg4);
 116
 117    /// <summary>Runs the LogInformation operation.</summary>
 118    public static void LogInformation<T0, T1, T2, T3, T4, T5>(this ILogger logger, Exception? exception, string message,
 2119        => Log(logger, LogLevel.Information, exception, message, arg0, arg1, arg2, arg3, arg4, arg5);
 120
 121    /// <summary>Runs the LogWarning operation.</summary>
 122    public static void LogWarning(this ILogger logger, string message)
 3123        => Log(logger, LogLevel.Warning, exception: null, message);
 124
 125    /// <summary>Runs the LogWarning operation.</summary>
 126    public static void LogWarning<T0>(this ILogger logger, string message, T0 arg0)
 3127        => Log(logger, LogLevel.Warning, exception: null, message, arg0);
 128
 129    /// <summary>Runs the LogWarning operation.</summary>
 130    public static void LogWarning<T0, T1>(this ILogger logger, string message, T0 arg0, T1 arg1)
 3131        => Log(logger, LogLevel.Warning, exception: null, message, arg0, arg1);
 132
 133    /// <summary>Runs the LogWarning operation.</summary>
 134    public static void LogWarning<T0, T1, T2>(this ILogger logger, string message, T0 arg0, T1 arg1, T2 arg2)
 3135        => Log(logger, LogLevel.Warning, exception: null, message, arg0, arg1, arg2);
 136
 137    /// <summary>Runs the LogWarning operation.</summary>
 138    public static void LogWarning<T0, T1, T2, T3>(this ILogger logger, string message, T0 arg0, T1 arg1, T2 arg2, T3 arg
 3139        => Log(logger, LogLevel.Warning, exception: null, message, arg0, arg1, arg2, arg3);
 140
 141    /// <summary>Runs the LogWarning operation.</summary>
 142    public static void LogWarning<T0, T1, T2, T3, T4>(this ILogger logger, string message, T0 arg0, T1 arg1, T2 arg2, T3
 2143        => Log(logger, LogLevel.Warning, exception: null, message, arg0, arg1, arg2, arg3, arg4);
 144
 145    /// <summary>Runs the LogWarning operation.</summary>
 146    public static void LogWarning<T0, T1, T2, T3, T4, T5>(this ILogger logger, string message, T0 arg0, T1 arg1, T2 arg2
 2147        => Log(logger, LogLevel.Warning, exception: null, message, arg0, arg1, arg2, arg3, arg4, arg5);
 148
 149    /// <summary>Runs the LogWarning operation.</summary>
 150    public static void LogWarning(this ILogger logger, Exception? exception, string message)
 2151        => Log(logger, LogLevel.Warning, exception, message);
 152
 153    /// <summary>Runs the LogWarning operation.</summary>
 154    public static void LogWarning<T0>(this ILogger logger, Exception? exception, string message, T0 arg0)
 3155        => Log(logger, LogLevel.Warning, exception, message, arg0);
 156
 157    /// <summary>Runs the LogWarning operation.</summary>
 158    public static void LogWarning<T0, T1>(this ILogger logger, Exception? exception, string message, T0 arg0, T1 arg1)
 3159        => Log(logger, LogLevel.Warning, exception, message, arg0, arg1);
 160
 161    /// <summary>Runs the LogWarning operation.</summary>
 162    public static void LogWarning<T0, T1, T2>(this ILogger logger, Exception? exception, string message, T0 arg0, T1 arg
 3163        => Log(logger, LogLevel.Warning, exception, message, arg0, arg1, arg2);
 164
 165    /// <summary>Runs the LogWarning operation.</summary>
 166    public static void LogWarning<T0, T1, T2, T3>(this ILogger logger, Exception? exception, string message, T0 arg0, T1
 2167        => Log(logger, LogLevel.Warning, exception, message, arg0, arg1, arg2, arg3);
 168
 169    /// <summary>Runs the LogWarning operation.</summary>
 170    public static void LogWarning<T0, T1, T2, T3, T4>(this ILogger logger, Exception? exception, string message, T0 arg0
 2171        => Log(logger, LogLevel.Warning, exception, message, arg0, arg1, arg2, arg3, arg4);
 172
 173    /// <summary>Runs the LogWarning operation.</summary>
 174    public static void LogWarning<T0, T1, T2, T3, T4, T5>(this ILogger logger, Exception? exception, string message, T0 
 2175        => Log(logger, LogLevel.Warning, exception, message, arg0, arg1, arg2, arg3, arg4, arg5);
 176
 177    /// <summary>Runs the LogError operation.</summary>
 178    public static void LogError(this ILogger logger, string message)
 2179        => Log(logger, LogLevel.Error, exception: null, message);
 180
 181    /// <summary>Runs the LogError operation.</summary>
 182    public static void LogError<T0>(this ILogger logger, string message, T0 arg0)
 2183        => Log(logger, LogLevel.Error, exception: null, message, arg0);
 184
 185    /// <summary>Runs the LogError operation.</summary>
 186    public static void LogError<T0, T1>(this ILogger logger, string message, T0 arg0, T1 arg1)
 2187        => Log(logger, LogLevel.Error, exception: null, message, arg0, arg1);
 188
 189    /// <summary>Runs the LogError operation.</summary>
 190    public static void LogError<T0, T1, T2>(this ILogger logger, string message, T0 arg0, T1 arg1, T2 arg2)
 2191        => Log(logger, LogLevel.Error, exception: null, message, arg0, arg1, arg2);
 192
 193    /// <summary>Runs the LogError operation.</summary>
 194    public static void LogError<T0, T1, T2, T3>(this ILogger logger, string message, T0 arg0, T1 arg1, T2 arg2, T3 arg3)
 2195        => Log(logger, LogLevel.Error, exception: null, message, arg0, arg1, arg2, arg3);
 196
 197    /// <summary>Runs the LogError operation.</summary>
 198    public static void LogError<T0, T1, T2, T3, T4>(this ILogger logger, string message, T0 arg0, T1 arg1, T2 arg2, T3 a
 2199        => Log(logger, LogLevel.Error, exception: null, message, arg0, arg1, arg2, arg3, arg4);
 200
 201    /// <summary>Runs the LogError operation.</summary>
 202    public static void LogError<T0, T1, T2, T3, T4, T5>(this ILogger logger, string message, T0 arg0, T1 arg1, T2 arg2, 
 2203        => Log(logger, LogLevel.Error, exception: null, message, arg0, arg1, arg2, arg3, arg4, arg5);
 204
 205    /// <summary>Runs the LogError operation.</summary>
 206    public static void LogError(this ILogger logger, Exception? exception, string message)
 3207        => Log(logger, LogLevel.Error, exception, message);
 208
 209    /// <summary>Runs the LogError operation.</summary>
 210    public static void LogError<T0>(this ILogger logger, Exception? exception, string message, T0 arg0)
 3211        => Log(logger, LogLevel.Error, exception, message, arg0);
 212
 213    /// <summary>Runs the LogError operation.</summary>
 214    public static void LogError<T0, T1>(this ILogger logger, Exception? exception, string message, T0 arg0, T1 arg1)
 3215        => Log(logger, LogLevel.Error, exception, message, arg0, arg1);
 216
 217    /// <summary>Runs the LogError operation.</summary>
 218    public static void LogError<T0, T1, T2>(this ILogger logger, Exception? exception, string message, T0 arg0, T1 arg1,
 3219        => Log(logger, LogLevel.Error, exception, message, arg0, arg1, arg2);
 220
 221    /// <summary>Runs the LogError operation.</summary>
 222    public static void LogError<T0, T1, T2, T3>(this ILogger logger, Exception? exception, string message, T0 arg0, T1 a
 3223        => Log(logger, LogLevel.Error, exception, message, arg0, arg1, arg2, arg3);
 224
 225    /// <summary>Runs the LogError operation.</summary>
 226    public static void LogError<T0, T1, T2, T3, T4>(this ILogger logger, Exception? exception, string message, T0 arg0, 
 2227        => Log(logger, LogLevel.Error, exception, message, arg0, arg1, arg2, arg3, arg4);
 228
 229    /// <summary>Runs the LogError operation.</summary>
 230    public static void LogError<T0, T1, T2, T3, T4, T5>(this ILogger logger, Exception? exception, string message, T0 ar
 2231        => Log(logger, LogLevel.Error, exception, message, arg0, arg1, arg2, arg3, arg4, arg5);
 232
 233    private static void Log(ILogger logger, LogLevel level, Exception? exception, string message)
 234    {
 3235        if (!logger.IsEnabled(level))
 3236            return;
 237
 3238        LogCache.Get(level, message)(logger, exception);
 3239    }
 240
 241    private static void Log<T0>(ILogger logger, LogLevel level, Exception? exception, string message, T0 arg0)
 242    {
 3243        if (!logger.IsEnabled(level))
 3244            return;
 245
 3246        LogCache<T0>.Get(level, message)(logger, arg0, exception);
 3247    }
 248
 249    private static void Log<T0, T1>(ILogger logger, LogLevel level, Exception? exception, string message, T0 arg0, T1 ar
 250    {
 3251        if (!logger.IsEnabled(level))
 3252            return;
 253
 3254        LogCache<T0, T1>.Get(level, message)(logger, arg0, arg1, exception);
 3255    }
 256
 257    private static void Log<T0, T1, T2>(ILogger logger, LogLevel level, Exception? exception, string message, T0 arg0, T
 258    {
 3259        if (!logger.IsEnabled(level))
 3260            return;
 261
 3262        LogCache<T0, T1, T2>.Get(level, message)(logger, arg0, arg1, arg2, exception);
 3263    }
 264
 265    private static void Log<T0, T1, T2, T3>(ILogger logger, LogLevel level, Exception? exception, string message, T0 arg
 266    {
 3267        if (!logger.IsEnabled(level))
 3268            return;
 269
 3270        LogCache<T0, T1, T2, T3>.Get(level, message)(logger, arg0, arg1, arg2, arg3, exception);
 3271    }
 272
 273    private static void Log<T0, T1, T2, T3, T4>(ILogger logger, LogLevel level, Exception? exception, string message, T0
 274    {
 3275        if (!logger.IsEnabled(level))
 3276            return;
 277
 3278        LogCache<T0, T1, T2, T3, T4>.Get(level, message)(logger, arg0, arg1, arg2, arg3, arg4, exception);
 3279    }
 280
 281    private static void Log<T0, T1, T2, T3, T4, T5>(ILogger logger, LogLevel level, Exception? exception, string message
 282    {
 2283        if (!logger.IsEnabled(level))
 2284            return;
 285
 2286        LogCache<T0, T1, T2, T3, T4, T5>.Get(level, message)(logger, arg0, arg1, arg2, arg3, arg4, arg5, exception);
 2287    }
 288
 289    private readonly record struct LogKey(LogLevel Level, string Message);
 290
 291    private static class LogCache
 292    {
 3293        private static readonly ConcurrentDictionary<LogKey, Action<ILogger, Exception?>> Delegates = new();
 294
 295        /// <summary>Runs the Get operation.</summary>
 296        public static Action<ILogger, Exception?> Get(LogLevel level, string message)
 3297            => Delegates.GetOrAdd(
 3298                new LogKey(level, message),
 3299                static key => LoggerMessage.Define(key.Level, default, key.Message, Options));
 300    }
 301
 302    private static class LogCache<T0>
 303    {
 3304        private static readonly ConcurrentDictionary<LogKey, Action<ILogger, T0, Exception?>> Delegates = new();
 305
 306        /// <summary>Runs the Get operation.</summary>
 307        public static Action<ILogger, T0, Exception?> Get(LogLevel level, string message)
 3308            => Delegates.GetOrAdd(
 3309                new LogKey(level, message),
 3310                static key => LoggerMessage.Define<T0>(key.Level, default, key.Message, Options));
 311    }
 312
 313    private static class LogCache<T0, T1>
 314    {
 3315        private static readonly ConcurrentDictionary<LogKey, Action<ILogger, T0, T1, Exception?>> Delegates = new();
 316
 317        /// <summary>Runs the Get operation.</summary>
 318        public static Action<ILogger, T0, T1, Exception?> Get(LogLevel level, string message)
 3319            => Delegates.GetOrAdd(
 3320                new LogKey(level, message),
 3321                static key => LoggerMessage.Define<T0, T1>(key.Level, default, key.Message, Options));
 322    }
 323
 324    private static class LogCache<T0, T1, T2>
 325    {
 3326        private static readonly ConcurrentDictionary<LogKey, Action<ILogger, T0, T1, T2, Exception?>> Delegates = new();
 327
 328        /// <summary>Runs the Get operation.</summary>
 329        public static Action<ILogger, T0, T1, T2, Exception?> Get(LogLevel level, string message)
 3330            => Delegates.GetOrAdd(
 3331                new LogKey(level, message),
 3332                static key => LoggerMessage.Define<T0, T1, T2>(key.Level, default, key.Message, Options));
 333    }
 334
 335    private static class LogCache<T0, T1, T2, T3>
 336    {
 3337        private static readonly ConcurrentDictionary<LogKey, Action<ILogger, T0, T1, T2, T3, Exception?>> Delegates = ne
 338
 339        /// <summary>Runs the Get operation.</summary>
 340        public static Action<ILogger, T0, T1, T2, T3, Exception?> Get(LogLevel level, string message)
 3341            => Delegates.GetOrAdd(
 3342                new LogKey(level, message),
 3343                static key => LoggerMessage.Define<T0, T1, T2, T3>(key.Level, default, key.Message, Options));
 344    }
 345
 346    private static class LogCache<T0, T1, T2, T3, T4>
 347    {
 3348        private static readonly ConcurrentDictionary<LogKey, Action<ILogger, T0, T1, T2, T3, T4, Exception?>> Delegates 
 349
 350        /// <summary>Runs the Get operation.</summary>
 351        public static Action<ILogger, T0, T1, T2, T3, T4, Exception?> Get(LogLevel level, string message)
 3352            => Delegates.GetOrAdd(
 3353                new LogKey(level, message),
 3354                static key => LoggerMessage.Define<T0, T1, T2, T3, T4>(key.Level, default, key.Message, Options));
 355    }
 356
 357    private static class LogCache<T0, T1, T2, T3, T4, T5>
 358    {
 2359        private static readonly ConcurrentDictionary<LogKey, Action<ILogger, T0, T1, T2, T3, T4, T5, Exception?>> Delega
 360
 361        /// <summary>Runs the Get operation.</summary>
 362        public static Action<ILogger, T0, T1, T2, T3, T4, T5, Exception?> Get(LogLevel level, string message)
 2363            => Delegates.GetOrAdd(
 2364                new LogKey(level, message),
 2365                static key => LoggerMessage.Define<T0, T1, T2, T3, T4, T5>(key.Level, default, key.Message, Options));
 366    }
 367}

Methods/Properties

.cctor()
LogDebug(Microsoft.Extensions.Logging.ILogger, string)
LogDebug<T0>(Microsoft.Extensions.Logging.ILogger, string, T0)
LogDebug<T0, T1>(Microsoft.Extensions.Logging.ILogger, string, T0, T1)
LogDebug<T0, T1, T2>(Microsoft.Extensions.Logging.ILogger, string, T0, T1, T2)
LogDebug<T0, T1, T2, T3>(Microsoft.Extensions.Logging.ILogger, string, T0, T1, T2, T3)
LogDebug<T0, T1, T2, T3, T4>(Microsoft.Extensions.Logging.ILogger, string, T0, T1, T2, T3, T4)
LogDebug<T0, T1, T2, T3, T4, T5>(Microsoft.Extensions.Logging.ILogger, string, T0, T1, T2, T3, T4, T5)
LogDebug(Microsoft.Extensions.Logging.ILogger, System.Exception, string)
LogDebug<T0>(Microsoft.Extensions.Logging.ILogger, System.Exception, string, T0)
LogDebug<T0, T1>(Microsoft.Extensions.Logging.ILogger, System.Exception, string, T0, T1)
LogDebug<T0, T1, T2>(Microsoft.Extensions.Logging.ILogger, System.Exception, string, T0, T1, T2)
LogDebug<T0, T1, T2, T3>(Microsoft.Extensions.Logging.ILogger, System.Exception, string, T0, T1, T2, T3)
LogDebug<T0, T1, T2, T3, T4>(Microsoft.Extensions.Logging.ILogger, System.Exception, string, T0, T1, T2, T3, T4)
LogDebug<T0, T1, T2, T3, T4, T5>(Microsoft.Extensions.Logging.ILogger, System.Exception, string, T0, T1, T2, T3, T4, T5)
LogInformation(Microsoft.Extensions.Logging.ILogger, string)
LogInformation<T0>(Microsoft.Extensions.Logging.ILogger, string, T0)
LogInformation<T0, T1>(Microsoft.Extensions.Logging.ILogger, string, T0, T1)
LogInformation<T0, T1, T2>(Microsoft.Extensions.Logging.ILogger, string, T0, T1, T2)
LogInformation<T0, T1, T2, T3>(Microsoft.Extensions.Logging.ILogger, string, T0, T1, T2, T3)
LogInformation<T0, T1, T2, T3, T4>(Microsoft.Extensions.Logging.ILogger, string, T0, T1, T2, T3, T4)
LogInformation<T0, T1, T2, T3, T4, T5>(Microsoft.Extensions.Logging.ILogger, string, T0, T1, T2, T3, T4, T5)
LogInformation(Microsoft.Extensions.Logging.ILogger, System.Exception, string)
LogInformation<T0>(Microsoft.Extensions.Logging.ILogger, System.Exception, string, T0)
LogInformation<T0, T1>(Microsoft.Extensions.Logging.ILogger, System.Exception, string, T0, T1)
LogInformation<T0, T1, T2>(Microsoft.Extensions.Logging.ILogger, System.Exception, string, T0, T1, T2)
LogInformation<T0, T1, T2, T3>(Microsoft.Extensions.Logging.ILogger, System.Exception, string, T0, T1, T2, T3)
LogInformation<T0, T1, T2, T3, T4>(Microsoft.Extensions.Logging.ILogger, System.Exception, string, T0, T1, T2, T3, T4)
LogInformation<T0, T1, T2, T3, T4, T5>(Microsoft.Extensions.Logging.ILogger, System.Exception, string, T0, T1, T2, T3, T4, T5)
LogWarning(Microsoft.Extensions.Logging.ILogger, string)
LogWarning<T0>(Microsoft.Extensions.Logging.ILogger, string, T0)
LogWarning<T0, T1>(Microsoft.Extensions.Logging.ILogger, string, T0, T1)
LogWarning<T0, T1, T2>(Microsoft.Extensions.Logging.ILogger, string, T0, T1, T2)
LogWarning<T0, T1, T2, T3>(Microsoft.Extensions.Logging.ILogger, string, T0, T1, T2, T3)
LogWarning<T0, T1, T2, T3, T4>(Microsoft.Extensions.Logging.ILogger, string, T0, T1, T2, T3, T4)
LogWarning<T0, T1, T2, T3, T4, T5>(Microsoft.Extensions.Logging.ILogger, string, T0, T1, T2, T3, T4, T5)
LogWarning(Microsoft.Extensions.Logging.ILogger, System.Exception, string)
LogWarning<T0>(Microsoft.Extensions.Logging.ILogger, System.Exception, string, T0)
LogWarning<T0, T1>(Microsoft.Extensions.Logging.ILogger, System.Exception, string, T0, T1)
LogWarning<T0, T1, T2>(Microsoft.Extensions.Logging.ILogger, System.Exception, string, T0, T1, T2)
LogWarning<T0, T1, T2, T3>(Microsoft.Extensions.Logging.ILogger, System.Exception, string, T0, T1, T2, T3)
LogWarning<T0, T1, T2, T3, T4>(Microsoft.Extensions.Logging.ILogger, System.Exception, string, T0, T1, T2, T3, T4)
LogWarning<T0, T1, T2, T3, T4, T5>(Microsoft.Extensions.Logging.ILogger, System.Exception, string, T0, T1, T2, T3, T4, T5)
LogError(Microsoft.Extensions.Logging.ILogger, string)
LogError<T0>(Microsoft.Extensions.Logging.ILogger, string, T0)
LogError<T0, T1>(Microsoft.Extensions.Logging.ILogger, string, T0, T1)
LogError<T0, T1, T2>(Microsoft.Extensions.Logging.ILogger, string, T0, T1, T2)
LogError<T0, T1, T2, T3>(Microsoft.Extensions.Logging.ILogger, string, T0, T1, T2, T3)
LogError<T0, T1, T2, T3, T4>(Microsoft.Extensions.Logging.ILogger, string, T0, T1, T2, T3, T4)
LogError<T0, T1, T2, T3, T4, T5>(Microsoft.Extensions.Logging.ILogger, string, T0, T1, T2, T3, T4, T5)
LogError(Microsoft.Extensions.Logging.ILogger, System.Exception, string)
LogError<T0>(Microsoft.Extensions.Logging.ILogger, System.Exception, string, T0)
LogError<T0, T1>(Microsoft.Extensions.Logging.ILogger, System.Exception, string, T0, T1)
LogError<T0, T1, T2>(Microsoft.Extensions.Logging.ILogger, System.Exception, string, T0, T1, T2)
LogError<T0, T1, T2, T3>(Microsoft.Extensions.Logging.ILogger, System.Exception, string, T0, T1, T2, T3)
LogError<T0, T1, T2, T3, T4>(Microsoft.Extensions.Logging.ILogger, System.Exception, string, T0, T1, T2, T3, T4)
LogError<T0, T1, T2, T3, T4, T5>(Microsoft.Extensions.Logging.ILogger, System.Exception, string, T0, T1, T2, T3, T4, T5)
Log(Microsoft.Extensions.Logging.ILogger, Microsoft.Extensions.Logging.LogLevel, System.Exception, string)
Log<T0>(Microsoft.Extensions.Logging.ILogger, Microsoft.Extensions.Logging.LogLevel, System.Exception, string, T0)
Log<T0, T1>(Microsoft.Extensions.Logging.ILogger, Microsoft.Extensions.Logging.LogLevel, System.Exception, string, T0, T1)
Log<T0, T1, T2>(Microsoft.Extensions.Logging.ILogger, Microsoft.Extensions.Logging.LogLevel, System.Exception, string, T0, T1, T2)
Log<T0, T1, T2, T3>(Microsoft.Extensions.Logging.ILogger, Microsoft.Extensions.Logging.LogLevel, System.Exception, string, T0, T1, T2, T3)
Log<T0, T1, T2, T3, T4>(Microsoft.Extensions.Logging.ILogger, Microsoft.Extensions.Logging.LogLevel, System.Exception, string, T0, T1, T2, T3, T4)
Log<T0, T1, T2, T3, T4, T5>(Microsoft.Extensions.Logging.ILogger, Microsoft.Extensions.Logging.LogLevel, System.Exception, string, T0, T1, T2, T3, T4, T5)
.cctor()
Get(Microsoft.Extensions.Logging.LogLevel, string)
.cctor()
Get(Microsoft.Extensions.Logging.LogLevel, string)
.cctor()
Get(Microsoft.Extensions.Logging.LogLevel, string)
.cctor()
Get(Microsoft.Extensions.Logging.LogLevel, string)
.cctor()
Get(Microsoft.Extensions.Logging.LogLevel, string)
.cctor()
Get(Microsoft.Extensions.Logging.LogLevel, string)
.cctor()
Get(Microsoft.Extensions.Logging.LogLevel, string)