-
Notifications
You must be signed in to change notification settings - Fork 12
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
I/O API refactoring #84
Conversation
Codecov Report
@@ Coverage Diff @@
## master #84 +/- ##
========================================
- Coverage 83% 81.9% -1.1%
========================================
Files 63 60 -3
Lines 4142 4140 -2
Branches 432 432
========================================
- Hits 3438 3391 -47
- Misses 272 317 +45
Partials 432 432
Continue to review full report at Codecov.
|
@@ -136,38 +140,3 @@ | |||
#"(?i)\.bcf$" :bcf | |||
#"(?i)\.bed" :bed | |||
(throw (IllegalArgumentException. "Invalid file type")))) | |||
|
|||
(defn ^Closeable reader |
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.
How about leaving reader/writer
functions here?
It's true that they're unnecessary for developing apps, but I think those versatile functions are still useful for REPL.
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.
That causes cyclic load. cljam.io.sam
loads cljam.io.util
for cljam.io.sam/reader
, and cljam.io.util
loads cljam.io.sam
for cljam.io.util/reader
. If reader/writer
are realy necessary, I have to reconsider namespace allocation.
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.
Thank you for pointing that out. OK, Let's remove them.
@@ -136,38 +140,3 @@ | |||
#"(?i)\.bcf$" :bcf | |||
#"(?i)\.bed" :bed | |||
(throw (IllegalArgumentException. "Invalid file type")))) | |||
|
|||
(defn ^Closeable reader |
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.
Thank you for pointing that out. OK, Let's remove them.
Merged. Thank you! 👍 |
Thank you for review! |
Breaking refactoring of I/O API.
Old
cljam.io
is not user-friendly, moving tocljam.io.protocols
. Basically, this namespace should not be used directly on other projects. It can be used in cljam project or for advanced usage.Public namespaces related to a format and its binary equivalent are integrated. For example,
cljam.io.sam
supports SAM and BAM,cljam.io.vcf
supports VCF and BCF,cljam.io.sequence
supports FASTA and TwoBit.These have read/write functions wrapping
cljam.io.protocols
. Only commonly-used functions are wrapped. A user justrequire
a single namespace that handles a format.