pub trait LinkStream: Debug {
    // Required methods
    fn next(&mut self) -> LocalBoxFuture<'_, Result<Option<Hash>>>;
    fn skip(&mut self, n: u64) -> LocalBoxFuture<'_, Result<()>>;
}
Expand description

A stream (async iterator) over the hashes of a collection.

Allows to get the next hash or skip a number of hashes. Does not implement Stream because of the extra skip method.

Required Methods§

source

fn next(&mut self) -> LocalBoxFuture<'_, Result<Option<Hash>>>

Get the next hash in the collection.

source

fn skip(&mut self, n: u64) -> LocalBoxFuture<'_, Result<()>>

Skip a number of hashes in the collection.

Implementors§