Crate ogre_stream_ext

Source

Structs§

ItemTimeoutErr
StreamWithFinalizationCallback
A Stream wrapper that calls a closure once the Stream either ends or is cancelled:
StreamWithFinalizationCallbacks
A Stream wrapper that can call two different closures:
StreamWithItemTimeout
A Stream wrapper that will yield a timeout error if an item is not generated within a maximum specified time, closing the Stream in the next .poll()

Traits§

StreamExtCloseOnItemTimeout
The extension trait that adds .close_stream_on_item_timeout(max_duration_for_next_element) to all Streams.
StreamExtFinalizationCallback
The extension trait that adds .on_complete_or_cancellation(...) to all Streams.
StreamExtFinalizationCallbacks
The extension trait that adds .on_complete(...) and .on_cancellation(...) to all Streams.
TryCountExt
TryEnumerateAllExt
TryEnumerateExt

Functions§

throttle_stream
Takes the input_stream and the frequency elements_per_second and give out a stream with the same elements, but restricted at yielding elements in that frequency, at most.