Пример #1
0
 private static void DebugWrite(LogData logData)
 {
     System.Diagnostics.Debug.WriteLine(logData);
 }
Пример #2
0
        /// <summary>
        /// Initializes a new instance of the <see cref="LogBuilder" /> class.
        /// </summary>
        /// <param name="logLevel">The starting trace level.</param>
        /// <param name="writer">The delegate to write logs to.</param>
        /// <exception cref="System.ArgumentNullException">writer</exception>
        public LogBuilder(LogLevel logLevel, Action<LogData> writer)
        {
            if (writer == null)
                throw new ArgumentNullException("writer");

            _writer = writer;
            _data = new LogData();
            _data.LogLevel = logLevel;
            _data.FormatProvider = CultureInfo.InvariantCulture;
        }
Пример #3
0
 private static void DebugWrite(LogData logData)
 {
     System.Diagnostics.Debug.WriteLine(logData);
 }