VCFHeader

Wrapper around bcf_hdr_t

Q: Why do we have VCFHeader, but not SAMHeader? A: Most (all)? of the SAM (bam1_t) manipulation functions do not require a ptr to the header, whereas almost all of the VCF (bcf1_t) manipulation functions do. Therefore, we track bcf_hdr_t* inside each VCFRecord; this is wrapped by VCFHeader for future convenience (for example, now we have @property nsamples; may move the tag reader and writer functions here?)

In order to avoid double free()'ing an instance bcf_hdr_t, this wrapper will be the authoritative holder of of bcf_hdr_t ptrs, it shall be passed around by reference, and copies are disabled.

Destructor

~this
~this()

Undocumented in source.

Postblit

this(this)
this(this)

Undocumented in source.

Members

Functions

nsamples
int nsamples()

Number of samples in the header

sequences
string[] sequences()

List of contigs in the header

Variables

hdr
bcf_hdr_t* hdr;

Pointer to htslib BCF/VCF header struct; will be freed from VCFHeader dtor

Meta