public void AddTarget(LogLevel min, LogLevel max, Target target)
        {
            if (frozen)
                throw new InvalidOperationException("Cannot modify config after initialization");

            lock (bindingsLock)
                bindings.Add(new TargetBinding(min, max, target));
        }
 public LogWriteOperation(Target target, IEnumerable<LogEventInfo> entries, bool success)
 {
     Target = target;
     this.entries = new List<LogEventInfo>(entries);
     Success = success;
 }
 public void AddTarget(LogLevel level, Target target)
 {
     AddTarget(level, level, target);
 }
 public LogWriteOperation(Target target, LogEventInfo entry, bool success)
     : this(target, new List<LogEventInfo>() { entry }, success)
 {
 }
Exemple #5
0
 internal TargetBinding(LogLevel min, LogLevel max, Target target)
 {
     MinLevel = min;
     MaxLevel = max;
     Target = target;
 }
Exemple #6
0
 internal TargetBinding(LogLevel min, LogLevel max, Target target)
 {
     this.MinLevel = min;
     this.MaxLevel = max;
     this.Target = target;
 }
Exemple #7
0
 internal LogWriteOperation(Target target, LogEventInfo entry, bool success)
 {
     _target = target;
     _entry = entry;
     _success = success;
 }
 public void AddTarget(LogLevel min, LogLevel max, Target target)
 {
     lock (_bindingsLock)
         this.Bindings.Add(new TargetBinding(min, max, target));
 }