Struct rust_htslib::bcf::header::Header [] [src]

pub struct Header {
    pub inner: *mut bcf_hdr_t,
    pub subset: Option<SampleSubset>,
}

A BCF header.

Fields

Methods

impl Header
[src]

[src]

Create a new (empty) Header.

[src]

Create a new Header using the given `HeaderView as the template.

After construction, you can modify the header independently from the template header.

Arguments

  • header - The HeaderView to use as the template.

[src]

Create a new Header using the given HeaderView as as template, but subsetting to the given samples.

Arguments

  • header - The HeaderView to use for the template.
  • samples - A slice of byte-encoded ([u8]) sample names.

Important traits for &'a mut W
[src]

Add a sample to the header.

Arguments

  • sample - Name of the sample to add (to the end of the sample list).

Important traits for &'a mut W
[src]

Add a record to the header.

Arguments

  • record - String representation of the header line

Example

This example is not tested
header.push_record(format!("##contig=<ID={},length={}>", "chrX", 155270560).as_bytes());

Important traits for &'a mut W
[src]

Remove an FILTER entry from header.

Arguments

  • tag - Name of the FLT tag to remove.

Important traits for &'a mut W
[src]

Remove an INFO entry from header.

Arguments

  • tag - Name of the INFO tag to remove.

Important traits for &'a mut W
[src]

Remove an FORMAT entry from header.

Arguments

  • tag - Name of the FORMAT tag to remove.

Important traits for &'a mut W
[src]

Remove a contig entry from header.

Arguments

  • tag - Name of the FORMAT tag to remove.

Important traits for &'a mut W
[src]

Remove a structured entry from header.

Arguments

  • tag - Name of the structured tag to remove.

Important traits for &'a mut W
[src]

Remove a generic entry from header.

Arguments

  • tag - Name of the generic tag to remove.

Trait Implementations

impl Debug for Header
[src]

[src]

Formats the value using the given formatter. Read more

impl Drop for Header
[src]

[src]

Executes the destructor for this type. Read more

Auto Trait Implementations

impl !Send for Header

impl !Sync for Header