collectAllWindowed overloads
Synopses
Declared in <folly/coro/Collect.h>
Await a range of value‐less awaitables with bounded concurrency.
template<typename InputRange>
requires std::is_void_v<
semi_await_result_t<detail::range_reference_t<InputRange>>>
folly::coro::Task<void>
collectAllWindowed(
InputRange awaitables,
std::size_t maxConcurrency);
Await a range of awaitables with bounded concurrency, collecting results.
template<typename InputRange>
requires !std::is_void_v<
semi_await_result_t<detail::range_reference_t<InputRange>>>
folly::coro::Task<std::vector</* implementation-defined */>>
collectAllWindowed(
InputRange awaitables,
std::size_t maxConcurrency);
Await an rvalue vector of awaitables with bounded concurrency.
template<typename SemiAwaitable>
decltype(collectAllWindowed(
detail::MoveRange(awaitables), maxConcurrency))
collectAllWindowed(
std::vector<SemiAwaitable> awaitables,
std::size_t maxConcurrency);
Return Value
-
A Task that completes when every awaitable has finished.
-
A Task completing with a vector of the results in input order.
Parameters
Name |
Description |
awaitables |
The range of awaitables to await. |
maxConcurrency |
The maximum number of awaitables awaited at once. |
Created with MrDocs