fn with<U, Fut, F, E>(self, f: F) -> With<Self, Item, U, Fut, F>
    where
        F: FnMut(U) -> Fut,
        Fut: Future<Output = Result<Item, E>>,
        E: From<Self::Error>,
        Self: Sized,
    {
        assert_sink::<U, E, _>(With::new(self, f))
    }
Composes a function *in front of* the sink.

This adapter produces a new sink that passes each value through the
given function `f` before sending it to `self`.

To process each value, `f` produces a *future*, which is then polled to
completion before passing its result down to the underlying sink. If the
future produces an error, that error is returned by the new sink.

Note that this function consumes the given sink, returning a wrapped
version, much like `Iterator::map`.
futures-util/src/sink/mod.rs