pub(crate) async fn read_column_defs<U>(&mut self, num: U) -> Result<Vec<Column>>
    where
        U: Into<usize>,
    {
        let num = num.into();
        debug_assert!(num > 0);
        let packets = self.read_packets(num).await?;
        let defs = packets
            .into_iter()
            .map(column_from_payload)
            .collect::<std::result::Result<Vec<Column>, _>>()
            .map_err(Error::from)?;

        if !self
            .capabilities()
            .contains(CapabilityFlags::CLIENT_DEPRECATE_EOF)
        {
            self.read_packet().await?;
        }

        Ok(defs)
    }
/// Low-level helpers, that reads the given number of column packets terminated by EOF packet.
///
/// Requires `num > 0`.
Low-level helpers, that reads the given number of column packets terminated by EOF packet.
Requires `num > 0`.
Low - level helpers that reads the given number of column packets terminated by EOF packet . Requires ` num > 0 ` .
pub(crate) async fn read_column_defs<U>(&mut self, num: U) -> Result<Vec<Column>>
    where
        U: Into<usize>,
    {
        let num = num.into();
        debug_assert!(num > 0);
        let packets = self.read_packets(num).await?;
        let defs = packets
            .into_iter()
            .map(column_from_payload)
            .collect::<std::result::Result<Vec<Column>, _>>()
            .map_err(Error::from)?;
        if !self
            .capabilities()
            .contains(CapabilityFlags::CLIENT_DEPRECATE_EOF)
        {
            self.read_packet().await?;
        }
        Ok(defs)
    }
pub ( crate ) async fn read_column_defs < U > ( & mut self , num : U ) -> Result < Vec < Column > > where U : Into < usize > , { let num = num . into ( ) ; debug_assert ! ( num 0 ) ; let packets = self . read_packets ( num ) . await ? ; let defs = packets . into_iter ( ) . map ( column_from_payload ) . collect :: < std :: result :: Result < Vec < Column > , _ > > ( ) . map_err ( Error :: from ) ? ; if ! self . capabilities ( ) . contains ( CapabilityFlags :: CLIENT_DEPRECATE_EOF ) { self . read_packet ( ) . await ? ; } Ok ( defs ) }
Low-level helpers, that reads the given number of column packets terminated by EOF packet.
Low - level helpers that reads the given number of column packets terminated by EOF packet .
&mut self
num
U
&mut self
num
U