private CorpusZipMetadata ReadCorpusZipMetadata()
 {
     using var stream = FileSystem.File.OpenRead(GetCorpusMetadataPath());
     return(CorpusZipMetadata.Deserialize(stream));
 }
 private void SaveCorpusMetadata(CorpusZipMetadata metadata)
 {
     using var stream = FileSystem.File.OpenWrite(GetCorpusMetadataPath());
     metadata.Serialize(stream);
 }
 public CorpusZipReader(string path, IDocumentDataSerializer <T> dataSerializer, IFileSystem fileSystem) : base(path, fileSystem)
 {
     this.dataSerializer = dataSerializer;
     metadata            = ReadCorpusZipMetadata();
 }