|
template<class F , class... Args> |
AsyncTask< F, Args... > * | lely::ev::make_async_task (ev_exec_t *exec, F &&f, Args &&... args) |
| Creates a task containing a Callable and its arguments and a future that will eventually hold the result (or the exception, if thrown) of the invocation.
|
|
Future<::std::size_t, void > | lely::ev::when_all (ev_exec_t *exec, ::std::size_t n, ev_future_t *const *futures) |
|
template<class Allocator > |
Future<::std::size_t, void > | lely::ev::when_all (ev_exec_t *exec, const ::std::vector< ev_future_t *, Allocator > &futures) |
|
template<class InputIt > |
typename ::std::enable_if< !::std::is_convertible< InputIt, ev_future_t * >::value, Future<::std::size_t, void > >::type | lely::ev::when_all (ev_exec_t *exec, InputIt first, InputIt last) |
|
template<class... Futures> |
typename ::std::enable_if< compat::conjunction<::std::is_convertible< Futures, ev_future_t * >... >::value, Future<::std::size_t, void > >::type | lely::ev::when_all (ev_exec_t *exec, Futures &&... futures) |
|
Future<::std::size_t, void > | lely::ev::when_any (ev_exec_t *exec, ::std::size_t n, ev_future_t *const *futures) |
|
template<class Allocator > |
Future<::std::size_t, void > | lely::ev::when_any (ev_exec_t *exec, const ::std::vector< ev_future_t *, Allocator > &futures) |
|
template<class InputIt > |
typename ::std::enable_if< !::std::is_convertible< InputIt, ev_future_t * >::value, Future<::std::size_t, void > >::type | lely::ev::when_any (ev_exec_t *exec, InputIt first, InputIt last) |
|
template<class... Futures> |
typename ::std::enable_if< compat::conjunction<::std::is_convertible< Futures, ev_future_t * >... >::value, Future<::std::size_t, void > >::type | lely::ev::when_any (ev_exec_t *exec, Futures &&... futures) |
|
template<class E = ::std::error_code> |
Future< void, E > | lely::ev::make_empty_future () |
| Creates a shared state of type #lely::util::Result<void, E> that is immediately ready, with a successful result, then returns a future associated with that shared state. More...
|
|
template<class T , class E = ::std::error_code, class V = typename ::std::decay<T>::type> |
Future< V, E > | lely::ev::make_ready_future (T &&value) |
| Creates a shared state of type #lely::util::Result<V, E> that is immediately ready, with a successul result constructed from std::forward<T>(value) , then returns a future associated with that shared state. More...
|
|
template<class T , class E , class V = typename ::std::decay<E>::type> |
Future< T, V > | lely::ev::make_error_future (E &&error) |
| Creates a shared state of type #lely::util::Result<T, V> that is immediately ready, with a failure result constructed from std::forward<E>(error) , then returns a future associated with that shared state. More...
|
|
template<class F , class... Args> |
AsyncTask< F, Args... >::future_type | lely::ev::async (ev_exec_t *exec, F &&f, Args &&... args) |
| Creates a task containing a Callable and its arguments, submits it for execution to the specified executor and returns a future that will eventually hold the result (or the exception, if thrown) of the invocation.
|
|
This header file is part of the event library; it contains the C++ interface for the futures and promises.
- See also
- lely/ev/future.h
- Copyright
- 2018-2022 Lely Industries N.V.
- Author
- J. S. Seldenthuis jseld.nosp@m.enth.nosp@m.uis@l.nosp@m.ely..nosp@m.com
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Definition in file future.hpp.