pub fn values<'a>(
        &'a self,
        header: &'a vcf::Header,
        string_map: &'a StringMap,
    ) -> impl Iterator<Item = io::Result<vcf::record::info::Field>> + 'a {
        use crate::reader::record::info::read_info_field;
        let mut reader = &self.buf[..];
        (0..self.len()).map(move |_| read_info_field(&mut reader, header.infos(), string_map))
    }
/// Returns an iterator over all info fields.
///
/// # Examples
///
/// ```
/// # use std::io;
/// use noodles_bcf::{header::StringMap, record::Info};
/// use noodles_vcf::{self as vcf, record::info::{field::{Key, Value}, Field}, Header};
///
/// let header = vcf::Header::builder()
///     .add_info(vcf::header::Info::from(Key::AlleleCount))
///     .add_info(vcf::header::Info::from(Key::TotalDepth))
///     .build();
///
/// let string_map = StringMap::from(&header);
///
/// let data = vec![
///     0x11, 0x01, 0x11, 0x05, // AC=5
///     0x11, 0x02, 0x11, 0x08, // DP=8
/// ];
///
/// let info = Info::new(data, 2);
/// let mut fields = info.values(&header, &string_map);
///
/// assert_eq!(
///     fields.next().transpose()?,
///     Some(Field::new(Key::AlleleCount, Some(Value::Integer(5))))
/// );
///
/// assert_eq!(
///     fields.next().transpose()?,
///     Some(Field::new(Key::TotalDepth, Some(Value::Integer(8))))
/// );
///
/// assert!(fields.next().is_none());
/// # Ok::<_, io::Error>(())
/// ```
Returns an iterator over all info fields.
Returns an iterator over all info fields .
pub fn values<'a>(
        &'a self,
        header: &'a vcf::Header,
        string_map: &'a StringMap,
    ) -> impl Iterator<Item = io::Result<vcf::record::info::Field>> + 'a {
        use crate::reader::record::info::read_info_field;
        let mut reader = &self.buf[..];
        (0..self.len()).map(move |_| read_info_field(&mut reader, header.infos(), string_map))
    }
pub fn values < ' a > ( & ' a self , header : & ' a vcf :: Header , string_map : & ' a StringMap , ) -> impl Iterator < Item = io :: Result < vcf :: record :: info :: Field > > + ' a { use crate :: reader :: record :: info :: read_info_field ; let mut reader = & self . buf [ .. ] ; ( 0 .. self . len ( ) ) . map ( move | _ | read_info_field ( & mut reader , header . infos ( ) , string_map ) ) }
Returns an iterator over all info fields.
Returns an iterator over all info fields .
&'a self
header
&'a vcf::Header
string_map
&'a StringMap
&'a self
header
&'a vcf::Header
string_map
&'a StringMap
examples
None
use std::io;
use noodles_bcf::{header::StringMap, record::Info};
use noodles_vcf::{self as vcf, record::info::{field::{Key, Value}, Field}, Header}.

let header = vcf::Header::builder()
.add_info(vcf::header::Info::from(Key::AlleleCount))
.add_info(vcf::header::Info::from(Key::TotalDepth))
.build().

let string_map = StringMap::from(&header).



let info = Info::new(data, 2);
let mut fields = info.values(&header, &string_map).

assert_eq!(
fields.next().transpose()?,
Some(Field::new(Key::AlleleCount, Some(Value::Integer(5))))
).

assert_eq!(
fields.next().transpose()?,
Some(Field::new(Key::TotalDepth, Some(Value::Integer(8))))
).

assert!(fields.next().is_none()).
use noodles_bcf :: { header :: StringMap record :: Info } ; use noodles_vcf :: { self as vcf record :: info :: { field :: { Key Value } Field } Header } . let header = vcf :: Header :: builder () . add_info ( vcf :: header :: Info :: from ( Key :: AlleleCount )) . add_info ( vcf :: header :: Info :: from ( Key :: TotalDepth )) . build () . let string_map = StringMap :: from ( &header ) . let info = Info :: new ( data 2 ) ; let mut fields = info . values ( &header &string_map ) . assert_eq! ( fields . next () . transpose () ? Some ( Field :: new ( Key :: AlleleCount Some ( Value :: Integer ( 5 )))) ) . assert_eq! ( fields . next () . transpose () ? Some ( Field :: new ( Key :: TotalDepth Some ( Value :: Integer ( 8 )))) ) . assert! ( fields . next () . is_none () ) .
ok::<_, io::error>(())
None