pub fn write_vec_cb<W: Writer, T, F>(
    input: &[T],
    writer: &mut W,
    cb: &F,
) -> Result<(), ::std::io::Error>
where
    F: Fn(&T, &mut W) -> Result<(), ::std::io::Error>,
{
    BigSize(input.len() as u64).write(writer)?;
    for s in input {
        cb(s, writer)?;
    }
    Ok(())
}
/// Writes a vector of values to the given writer using the provided callback to
/// serialize each value.
Writes a vector of values to the given writer using the provided callback to
serialize each value.
Writes a vector of values to the given writer using the provided callback to serialize each value .
pub fn write_vec_cb<W: Writer, T, F>(
    input: &[T],
    writer: &mut W,
    cb: &F,
) -> Result<(), ::std::io::Error>
where
    F: Fn(&T, &mut W) -> Result<(), ::std::io::Error>,
{
    BigSize(input.len() as u64).write(writer)?;
    for s in input {
        cb(s, writer)?;
    }
    Ok(())
}
pub fn write_vec_cb < W : Writer , T , F > ( input : & [ T ] , writer : & mut W , cb : & F , ) -> Result < ( ) , :: std :: io :: Error > where F : Fn ( & T , & mut W ) -> Result < ( ) , :: std :: io :: Error > , { BigSize ( input . len ( ) as u64 ) . write ( writer ) ? ; for s in input { cb ( s , writer ) ? ; } Ok ( ( ) ) }
Writes a vector of values to the given writer using the provided callback to
serialize each value.
Writes a vector of values to the given writer using the provided callback to serialize each value .
input
&[T]
writer
&mut W
cb
&F