-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Rewrite to add support for random-acces for Crypt4GHReader #83
Conversation
…ed by the underlying (encrypted) data stream.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
might want to bump https://github.com/neicnordic/crypt4gh/blob/master/internal/version/version.go#L10 to 1.8.0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
some small things.
how do you envision this being used in practice, some example code would help?
Codecov Report
❗ Your organization is not using the GitHub App Integration. As a result you may experience degraded service beginning May 15th. Please install the Github App Integration for your organization. Read more. @@ Coverage Diff @@
## master #83 +/- ##
==========================================
+ Coverage 58.47% 65.54% +7.07%
==========================================
Files 6 6
Lines 1103 1164 +61
==========================================
+ Hits 645 763 +118
+ Misses 330 281 -49
+ Partials 128 120 -8
Flags with carried forward coverage won't be shown. Click here to find out more.
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
Co-authored-by: Stefan Negru <blankdots@users.noreply.github.com>
Giving examples sounds like a good idea, but I'm a bit unsure where I should best do that, does someone else have opinions/suggestions?
? |
i vote for that, though it might be a new issue we need to create and find people to work on |
I can commit to creating a few small demos. Should not be a large task but it does feel like a separate PR. |
Unfortunately a large PR, apologies, even if I feel this is a simplification.
This PR adds opportunistic usage if the underlying data provider supports Seek, this allows for the main use case of reading small specific bits of large files. But this also allows for e.g. reading the end of a file first and then going back to an earlier position (if supported).
Interface changes are the addition of
Seek
andClose
to permitSeeker
andCloser
.GetHeader
has also changed fromfunc (c Crypt4GHReader) GetHeader() []byte
tofunc (c *Crypt4GHReader) GetHeader() []byte
.