|
omega_h
Reliable mesh adaptation
|
Abstraction for asynchronous communication. More...
#include <Omega_h_future.hpp>
Public Types | |
| using | sendbuf_type = Read< T > |
| using | recvbuf_type = Write< T > |
| using | callback_type = std::function< Read< T >(recvbuf_type)> |
| post-processing callback for asynchronous communication | |
| using | additional_callback_type = std::function< Read< T >(Read< T >)> |
| optional additional processing callbacks (see add_callback method) | |
| using | requests_type = std::vector< int > |
Public Member Functions | |
| Future (Read< T > sendbuf, Write< T > recvbuf, const requests_type &&requests={}, const callback_type callback=[](recvbuf_type buf) -> Read< T > { return buf;}) | |
| Future (Write< T > recvbuf) | |
| no-op: no comm, no callback | |
| Future (Read< T > buf) | |
| no-op: no comm, no callback | |
| void | add_callback (const additional_callback_type &callback) |
| register a additional post-communication callback | |
| bool | completed () |
| Read< T > | get () |
Abstraction for asynchronous communication.
Hold both receive/send buffers and post-communication callbacks
| bool Omega_h::Future< T >::completed |
| Read< T > Omega_h::Future< T >::get |
wait for asynchronous operation completion, and return the result. This method can only be called once.