Struct Unfold
#[must_use = "sinks do nothing unless polled"]
pub struct Unfold<T, F, R> { /* private fields */ }
Sink for the unfold function.
Trait Implementations
impl<'__pin, T, F, R> Unpin for Unfold<T, F, R>
where
PinnedFieldsOf<__Origin<'__pin, T, F, R>>: Unpin,
impl<T, F, R, Item, E> Sink<Item> for Unfold<T, F, R>
where
F: FnMut(T, Item) -> R,
R: Future<Output = Result<T, E>>,
type Error = E;fn poll_ready(self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll<Result<(), Self::Error>>fn start_send(self: Pin<&mut Self>, item: Item) -> Result<(), Self::Error>fn poll_flush(self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll<Result<(), Self::Error>>fn poll_close(self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll<Result<(), Self::Error>>
impl<T: Debug, F: Debug, R: Debug> Debug for Unfold<T, F, R>
fn fmt(&self, f: &mut Formatter<'_>) -> Result
Auto Trait Implementations
impl<T, F, R> Freeze for Unfold<T, F, R>
where
F: Freeze,
UnfoldState<T, R>: Freeze,
impl<T, F, R> RefUnwindSafe for Unfold<T, F, R>
where
F: RefUnwindSafe,
UnfoldState<T, R>: RefUnwindSafe,
impl<T, F, R> Send for Unfold<T, F, R>
where
F: Send,
UnfoldState<T, R>: Send,
impl<T, F, R> Sync for Unfold<T, F, R>
where
F: Sync,
UnfoldState<T, R>: Sync,
impl<T, F, R> UnsafeUnpin for Unfold<T, F, R>
where
F: UnsafeUnpin,
UnfoldState<T, R>: UnsafeUnpin,
impl<T, F, R> UnwindSafe for Unfold<T, F, R>
where
F: UnwindSafe,
UnfoldState<T, R>: UnwindSafe,
Blanket Implementations
impl<T> Any for Unfold<T, F, R>
where
T: 'static + ?Sized,
fn type_id(&self) -> TypeId
impl<T> Borrow<T> for Unfold<T, F, R>
where
T: ?Sized,
fn borrow(&self) -> &T
impl<T> BorrowMut<T> for Unfold<T, F, R>
where
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
impl<T> From<T> for Unfold<T, F, R>
fn from(t: T) -> TReturns the argument unchanged.
impl<T, Item> SinkExt<Item> for Unfold<T, F, R>
where
T: Sink<Item> + ?Sized,
impl<T, U> Into<U> for Unfold<T, F, R>
where
U: From<T>,
fn into(self) -> UCalls
U::from(self).That is, this conversion is whatever the implementation of
[From]<T> for Uchooses to do.
impl<T, U> TryFrom<U> for Unfold<T, F, R>
where
U: Into<T>,
type Error = never;fn try_from(value: U) -> Result<T, never>
impl<T, U> TryInto<U> for Unfold<T, F, R>
where
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error;fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>