public void ChangeLogFile()
 {
     lock (this) {
         if (file != null)
         {
             logFiles.Close(file);
         }
         file = logFiles.Open(LogPath(pathFormat), true);
     }
 }
 public void ChangeLogFile()
 {
     lock (this) {
         if (file != null)
         {
             logFiles.Close(file);
         }
         var path = LogPath(pathFormat);
         file = logFiles.Open(path, WillAppend(path));
     }
 }
 override public void Dispose()
 {
     if (file != null)
     {
         logs.Close(file);
     }
     file = null;
 }