pub(crate) fn deserialize(buf: &[u8]) -> Result<Self> {
        // create a reader so we can convert the document
        let mut cursor = io::Cursor::new(buf);
        let document = bson::Document::from_reader(&mut cursor).map_err(ForcepError::MetaDe)?;

        bson::from_document(document).map_err(ForcepError::MetaDe)
    }
/// Deserializes a slice of bytes into metadata
Deserializes a slice of bytes into metadata
Deserializes a slice of bytes into metadata
pub(crate) fn deserialize(buf: &[u8]) -> Result<Self> {
        // create a reader so we can convert the document
        let mut cursor = io::Cursor::new(buf);
        let document = bson::Document::from_reader(&mut cursor).map_err(ForcepError::MetaDe)?;
        bson::from_document(document).map_err(ForcepError::MetaDe)
    }
pub ( crate ) fn deserialize ( buf : & [ u8 ] ) -> Result < Self > { // create a reader so we can convert the document let mut cursor = io :: Cursor :: new ( buf ) ; let document = bson :: Document :: from_reader ( & mut cursor ) . map_err ( ForcepError :: MetaDe ) ? ; bson :: from_document ( document ) . map_err ( ForcepError :: MetaDe ) }
Deserializes a slice of bytes into metadata
Deserializes a slice of bytes into metadata
buf
&[u8]
buf
&[u8]