Esempio n. 1
0
 private void Logger_OnRequestLog(object sender, RequestLogEventArgs e)
 {
     _rwLock.AcquireReaderLock(0);
     foreach (var logTarget in LogTargets)
     {
         logTarget.Append(e.Entry);
     }
     _rwLock.ReleaseReaderLock();
 }
Esempio n. 2
0
        /// <summary>
        /// 引发 <see cref="RequestLog"/> 事件
        /// </summary>

        protected virtual void OnRequestLog(RequestLogEventArgs e)
        {
            RequestLog?.Invoke(this, e);
        }