Skip to content

Commit

Permalink
store full read id in binary dat
Browse files Browse the repository at this point in the history
  • Loading branch information
skoren committed Oct 5, 2017
1 parent c634a7b commit 065dde4
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/main/java/edu/umd/marbl/mhap/impl/SequenceSketch.java
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,10 @@ public static SequenceSketch fromByteStream(DataInputStream input, int offset) t
// dos.writeBoolean(this.id.isForward());
boolean isFwd = input.readBoolean();

// dos.writeInt(this.id.getHeaderId());
SequenceId id = new SequenceId(input.readLong() + offset, isFwd);
// dos.writeLong(this.id.getHeaderId());
// dos.writeUTF(this.id.getHeader());

SequenceId id = new SequenceId(input.readLong() + offset, isFwd, input.readUTF());

//dos.writeInt(this.sequenceLength);
int sequenceLength = input.readInt();
Expand Down Expand Up @@ -131,6 +133,7 @@ public byte[] getAsByteArray()
{
dos.writeBoolean(this.id.isForward());
dos.writeLong(this.id.getHeaderId());
dos.writeUTF(this.id.getHeader());
dos.writeInt(this.sequenceLength);
dos.write(mainHashesBytes);
dos.write(orderedHashesBytes);
Expand Down

0 comments on commit 065dde4

Please sign in to comment.