diff options
author | Michael R. Crusoe <michael.crusoe@gmail.com> | 2019-12-13 08:35:12 +0100 |
---|---|---|
committer | Michael R. Crusoe <michael.crusoe@gmail.com> | 2019-12-13 08:35:12 +0100 |
commit | b6f8d993debe2dac00f25e1879bf66183c0f0de5 (patch) | |
tree | 625547cba8e261b61e98ea95de9333cd8375603d /vcfbuf.h | |
parent | 99b9763265e6b80dcd2965fc3a752c17b6514b45 (diff) |
New upstream version 1.10
Diffstat (limited to 'vcfbuf.h')
-rw-r--r-- | vcfbuf.h | 15 |
1 files changed, 14 insertions, 1 deletions
@@ -1,6 +1,6 @@ /* The MIT License - Copyright (c) 2017 Genome Research Ltd. + Copyright (c) 2017-2019 Genome Research Ltd. Author: Petr Danecek <pd3@sanger.ac.uk> @@ -44,6 +44,7 @@ typedef enum VCFBUF_NSITES, // leave at max this many sites in the window VCFBUF_AF_TAG, // use this INFO tag with LD_NSITES VCFBUF_OVERLAP_WIN, // keep only overlapping variants in the window + VCFBUF_RMDUP, // remove duplicate sites (completely) } vcfbuf_opt_t; @@ -64,6 +65,18 @@ void vcfbuf_destroy(vcfbuf_t *buf); */ bcf1_t *vcfbuf_push(vcfbuf_t *buf, bcf1_t *rec, int swap); +/* + * vcfbuf_peek() - return pointer to i-th record in the buffer but do not remove it from the buffer + * @idx: 0-based index to buffered lines + */ +bcf1_t *vcfbuf_peek(vcfbuf_t *buf, int idx); + +/* + * vcfbuf_remove() - return pointer to i-th record in the buffer and remove it from the buffer + * @idx: 0-based index to buffered lines + */ +bcf1_t *vcfbuf_remove(vcfbuf_t *buf, int idx); + bcf1_t *vcfbuf_flush(vcfbuf_t *buf, int flush_all); /* |