Skip to content

Commit

Permalink
Fix progress reporting for gzipped vdjca
Browse files Browse the repository at this point in the history
  • Loading branch information
PoslavskySV committed Sep 8, 2015
1 parent b4a53fd commit 19cf4d6
Showing 1 changed file with 8 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,14 @@ public VDJCAlignmentsReader(String fileName, AlleleResolver alleleResolver) thro
}

public VDJCAlignmentsReader(File file, AlleleResolver alleleResolver) throws IOException {
this(IOUtil.createIS(file), alleleResolver, file.length());
CompressionType ct = CompressionType.detectCompressionType(file);
this.countingInputStream = new CountingInputStream(new FileInputStream(file));
if (ct == CompressionType.None)
this.input = new PrimitivI(new BufferedInputStream(countingInputStream, 65536));
else
this.input = new PrimitivI(ct.createInputStream(countingInputStream, 65536));
this.alleleResolver = alleleResolver;
this.size = file.length();
}

public VDJCAlignmentsReader(InputStream input, AlleleResolver alleleResolver) {
Expand Down

0 comments on commit 19cf4d6

Please sign in to comment.