public void Dispose()
 {
     if (writer != null)
     {
         writer.Dispose();
         writer = null;
     }
 }
 private BinaryLogWriter(string filePath)
 {
     this.filePath = filePath;
     this.writer   = new TreeBinaryWriter(filePath);
 }