internal static IEnumerable <RarVolume> GetParts(FileInfo fileInfo, ReaderOptions options)
        {
            FileInfoRarArchiveVolume part = new FileInfoRarArchiveVolume(fileInfo, options);

            yield return(part);

            ArchiveHeader ah = part.ArchiveHeader;

            if (!ah.IsVolume)
            {
                yield break; //if file isn't volume then there is no reason to look
            }
            fileInfo = GetNextFileInfo(ah, part.FileParts.FirstOrDefault() as FileInfoRarFilePart);
            //we use fileinfo because rar is dumb and looks at file names rather than archive info for another volume
            while (fileInfo != null && fileInfo.Exists)
            {
                part = new FileInfoRarArchiveVolume(fileInfo, options);

                fileInfo = GetNextFileInfo(ah, part.FileParts.FirstOrDefault() as FileInfoRarFilePart);
                yield return(part);
            }
        }
 internal FileInfoRarFilePart(FileInfoRarArchiveVolume volume, string?password, MarkHeader mh, FileHeader fh, FileInfo fi)
     : base(mh, fh, volume.Index, volume.Stream, password)
 {
     FileInfo = fi;
 }