Ejemplo n.º 1
0
        private static void RawLog(LogEventKind kind, LogSource source, Exception exception, String message, Object[] items)
        {
            if (Handler is null)
            {
                return;
            }

            var li = new LogInformation
            {
                Kind      = kind,
                Source    = source,
                Timestamp = new TimeSpan(DateTime.UtcNow.Ticks),
                Message   = message,
                Exception = exception,
                Items     = items,
            };

            Handler.Enqueue(li);
        }
Ejemplo n.º 2
0
 public static void Warning(LogSource source, String message)
 {
     RawLog(LogEventKind.Warning, source, null, message, null);
 }
Ejemplo n.º 3
0
 public static void Information(LogSource source, Exception exception, String message, params Object[] items)
 {
     RawLog(LogEventKind.Information, source, exception, message, items);
 }
Ejemplo n.º 4
0
 public static void Information(LogSource source, Exception exception, String message)
 {
     RawLog(LogEventKind.Information, source, exception, message, null);
 }
Ejemplo n.º 5
0
 public static void Information(LogSource source, Exception exception)
 {
     RawLog(LogEventKind.Information, source, exception, null, null);
 }
Ejemplo n.º 6
0
 public static void Debug(LogSource source, String message, params Object[] items)
 {
     RawLog(LogEventKind.Debug, source, null, message, items);
 }
Ejemplo n.º 7
0
 public static void Debug(LogSource source, Exception exception)
 {
     RawLog(LogEventKind.Debug, source, exception, null, null);
 }
Ejemplo n.º 8
0
 public static void Error(LogSource source, String message)
 {
     RawLog(LogEventKind.Error, source, null, message, null);
 }
Ejemplo n.º 9
0
 public static void Critical(LogSource source, Exception exception, String message, params Object[] items)
 {
     RawLog(LogEventKind.Critical, source, exception, message, items);
 }
Ejemplo n.º 10
0
 public static void Critical(LogSource source, Exception exception, String message)
 {
     RawLog(LogEventKind.Critical, source, exception, message, null);
 }
Ejemplo n.º 11
0
 public static void Critical(LogSource source, Exception exception)
 {
     RawLog(LogEventKind.Critical, source, exception, null, null);
 }
Ejemplo n.º 12
0
 public static void Error(LogSource source, Exception exception, String message)
 {
     RawLog(LogEventKind.Error, source, exception, message, null);
 }
Ejemplo n.º 13
0
 public static void Error(LogSource source, Exception exception)
 {
     RawLog(LogEventKind.Error, source, exception, null, null);
 }
Ejemplo n.º 14
0
 public static void Warning(LogSource source, Exception exception)
 {
     RawLog(LogEventKind.Warning, source, exception, null, null);
 }
Ejemplo n.º 15
0
 public static void Debug(LogSource source, String message)
 {
     RawLog(LogEventKind.Debug, source, null, message, null);
 }
Ejemplo n.º 16
0
 public static void Warning(LogSource source, Exception exception, String message)
 {
     RawLog(LogEventKind.Warning, source, exception, message, null);
 }
Ejemplo n.º 17
0
 public LogSource(LogSource ls)
 {
     this.Copy(ls);
 }