Пример #1
0
 public void DisableLogging(LoggingInfo.LoggingSubsystem subsystem, LoggingInfo.LoggingType type)
 {
     try
     {
         this._renderer.SetLoggingStatus(subsystem, type, LoggingInfo.LogsStatus.Disable);
         AppUtil.LogEvent("NCache", subsystem.ToString() + " logging disabled successfully", EventLogEntryType.Information, EventCategories.Information, EventID.LoggingDisabled);
     }
     catch (Exception exc)
     {
         AppUtil.LogEvent("NCache", exc.ToString(), EventLogEntryType.Error, EventCategories.Error, EventID.GeneralError);
         throw;
     }
 }
Пример #2
0
 public void EnableLogging(LoggingInfo.LoggingSubsystem subsystem, LoggingInfo.LoggingType type)
 {
     try
     {
         this._renderer.SetLoggingStatus(subsystem, type, LoggingInfo.LogsStatus.Enable);
         AppUtil.LogEvent(RuntimeContext.CurrentContextName, subsystem.ToString() + " logging enabled successfully", EventLogEntryType.Information, EventCategories.Information, EventID.LoggingEnabled);
     }
     catch (Exception exc)
     {
         AppUtil.LogEvent(RuntimeContext.CurrentContextName, exc.ToString(), EventLogEntryType.Error, EventCategories.Error, EventID.GeneralError);
         throw;
     }
 }