Struct rust_htslib::bcf::header::HeaderView
source · Fields§
§inner: *mut bcf_hdr_t
Implementations§
source§impl HeaderView
impl HeaderView
pub fn new(inner: *mut bcf_hdr_t) -> Self
pub fn sample_count(&self) -> u32
pub fn samples(&self) -> Vec<&[u8]> ⓘ
pub fn rid2name(&self, rid: u32) -> &[u8] ⓘ
pub fn name2rid(&self, name: &[u8]) -> Result<u32, RidError>
pub fn info_type(&self, tag: &[u8]) -> Result<(TagType, TagLength), TagTypeError>
pub fn format_type(
&self,
tag: &[u8]
) -> Result<(TagType, TagLength), TagTypeError>
sourcepub fn name_to_id(&self, id: &[u8]) -> Result<Id, IdError>
pub fn name_to_id(&self, id: &[u8]) -> Result<Id, IdError>
Convert string ID (e.g., for a FILTER
value) to its numeric identifier.
sourcepub fn id_to_name(&self, id: Id) -> Vec<u8> ⓘ
pub fn id_to_name(&self, id: Id) -> Vec<u8> ⓘ
Convert integer representing an identifier (e.g., a FILTER
value) to its string
name.bam.
sourcepub fn sample_to_id(&self, id: &[u8]) -> Result<Id, SampleError>
pub fn sample_to_id(&self, id: &[u8]) -> Result<Id, SampleError>
Convert string sample name to its numeric identifier.
sourcepub fn id_to_sample(&self, id: Id) -> Vec<u8> ⓘ
pub fn id_to_sample(&self, id: Id) -> Vec<u8> ⓘ
Convert integer representing an contig to its name.
sourcepub fn header_records(&self) -> Vec<HeaderRecord> ⓘ
pub fn header_records(&self) -> Vec<HeaderRecord> ⓘ
Return structured HeaderRecord
s.