[−][src]Struct rust_htslib::bcf::header::Header   
A BCF header.
Fields
inner: *mut bcf_hdr_tsubset: Option<SampleSubset>Implementations
impl Header[src]
pub fn new() -> Self[src]
Create a new (empty) Header.
pub fn from_template(header: &HeaderView) -> Self[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- TheHeaderViewto use as the template.
pub fn from_template_subset(
    header: &HeaderView, 
    samples: &[&[u8]]
) -> Result<Self>[src]
header: &HeaderView,
samples: &[&[u8]]
) -> Result<Self>
Create a new Header using the given HeaderView as as template, but subsetting to the
given samples.
Arguments
header- TheHeaderViewto use for the template.samples- A slice of byte-encoded ([u8]) sample names.
pub fn push_sample(&mut self, sample: &[u8]) -> &mut Self[src]
Add a sample to the header.
Arguments
sample- Name of the sample to add (to the end of the sample list).
pub fn push_record(&mut self, record: &[u8]) -> &mut Self[src]
Add a record to the header.
Arguments
record- String representation of the header line
Example
ⓘ
header.push_record(format!("##contig=<ID={},length={}>", "chrX", 155270560).as_bytes());
pub fn remove_filter(&mut self, tag: &[u8]) -> &mut Self[src]
pub fn remove_info(&mut self, tag: &[u8]) -> &mut Self[src]
pub fn remove_format(&mut self, tag: &[u8]) -> &mut Self[src]
pub fn remove_contig(&mut self, tag: &[u8]) -> &mut Self[src]
pub fn remove_structured(&mut self, tag: &[u8]) -> &mut Self[src]
pub fn remove_generic(&mut self, tag: &[u8]) -> &mut Self[src]
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for Header[src]
impl !Send for Header[src]
impl !Sync for Header[src]
impl Unpin for Header[src]
impl UnwindSafe for Header[src]
Blanket Implementations
impl<T> Any for T where
    T: 'static + ?Sized, [src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
    T: ?Sized, [src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
    T: ?Sized, [src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T[src]
impl<T> From<T> for T[src]
impl<T, U> Into<U> for T where
    U: From<T>, [src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
    U: Into<T>, [src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]
impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, [src]
U: TryFrom<T>,