/// Read entries as an Async Stream from a given position. This method deserialized the Key and Value based on the
/// inferred type.
Read entries as an Async Stream from a given position. This method deserialized the Key and Value based on the
inferred type.
Read entries as an Async Stream from a given position . This method deserialized the Key and Value based on the inferred type .
pub fn read_entries_stream_from_position<'stream, 'map: 'stream, K: 'map, V: 'map>(
        &'map self,
        max_entries_at_once: i32,
        mut from_position: i64,
    ) -> impl Stream<Item = Result<(K, V, Version, i64), TableError>> + 'stream
    where
        K: Serialize + serde::de::DeserializeOwned + std::marker::Unpin,
        V: Serialize + serde::de::DeserializeOwned + std::marker::Unpin,
    {
        try_stream! {
            loop {
                let res: (Vec<(Vec<u8>, Vec<u8>,Version)>, i64)  = self.read_entries_raw_delta(max_entries_at_once, from_position).await?;
                let (entries, last_position) = res;
                if entries.is_empty() {
                    break;
                } else {
                    for (key_raw, value_raw, version) in entries {
                        let key: K = from_slice(key_raw.as_slice()).expect("error during deserialization");
                        let value: V = from_slice(value_raw.as_slice()).expect("error during deserialization");
                        yield (key, value, version, last_position)
                    }
                    from_position = last_position;
                }
            }
        }
    }
pub fn read_entries_stream_from_position < ' stream , ' map : ' stream , K : ' map , V : ' map > ( & ' map self , max_entries_at_once : i32 , mut from_position : i64 , ) -> impl Stream < Item = Result < ( K , V , Version , i64 ) , TableError > > + ' stream where K : Serialize + serde :: de :: DeserializeOwned + std :: marker :: Unpin , V : Serialize + serde :: de :: DeserializeOwned + std :: marker :: Unpin , { try_stream ! { loop { let res ( Vec ( Vec u8 Vec u8 Version ) i64 ) self read_entries_raw_delta ( max_entries_at_once from_position ) await let ( entries last_position ) res if entries is_empty ( ) { break } else { for ( key_raw value_raw version ) in entries { let key K from_slice ( key_raw as_slice ( ) ) expect ( " " ) let value V from_slice ( value_raw as_slice ( ) ) expect ( " " ) yield ( key value version last_position ) } from_position last_position } } } }
Read entries as an Async Stream from a given position.
Read entries as an Async Stream from a given position .
&'map self
max_entries_at_once
i32
from_position
i64