use futures::Stream;
use crate::runtime::Handle;
pub trait BlockingRuntime {
type BlockingIterator<'a, R: 'a>: Iterator<Item = R> + 'a;
fn handle(&self) -> Handle;
fn block_on<Fut, R>(&self, fut: Fut) -> R
where
Fut: Future<Output = R>;
fn block_on_stream<'a, S, R>(&self, stream: S) -> Self::BlockingIterator<'a, R>
where
S: Stream<Item = R> + Send + 'a,
R: Send + 'a;
}