Wrapper for boost::unique_future that is specialized for RPC processing.
More...
#include <rpc/RPCFuture.h>
|
| RPCFutureCommon () |
|
| RPCFutureCommon (AbstractRPCClient *client, const std::string &callId) |
|
| ~RPCFutureCommon () |
|
const std::string & | callId () |
| query call ID More...
|
|
bool | isReady () const |
| Checks to see if the result of the RPC call associated with this future is set. More...
|
|
bool | hasException () const |
| Returns true if the RPC call associated with this future has finished with an exception rather than a return value. More...
|
|
bool | hasValue () const |
| Returns true if the RPC call associated with this future has finished with a return value value rather than an exception. More...
|
|
void | wait () const |
| Waits and blocks the current thread until the result of the associated RPC call is ready. More...
|
|
template<typename Duration > |
bool | timedWait (Duration const &relTime) const |
| Waits and blocks the current thread until the result of the associated RPC call is ready, or the time duration specified by waitDuration has elapsed. More...
|
|
bool | timedWaitUntil (boost::system_time const &absTime) const |
| Waits and blocks the current thread until the result of the associated RPC call is ready, or the time point specified by waitDuration has passed. More...
|
|
void | swap (RPCFutureCommon< R > &other) |
| Swaps ownership of the asynchronous results associated with other and *this. More...
|
|
template<typename R>
class mira::RPCFutureCommon< R >
Wrapper for boost::unique_future that is specialized for RPC processing.
This is a base class for the concrete derived RPCFuture classes.
◆ RPCFutureCommon() [1/2]
◆ RPCFutureCommon() [2/2]
◆ ~RPCFutureCommon()
◆ callId()
const std::string& callId |
( |
| ) |
|
|
inline |
◆ isReady()
Checks to see if the result of the RPC call associated with this future is set.
◆ hasException()
bool hasException |
( |
| ) |
const |
|
inline |
Returns true if the RPC call associated with this future has finished with an exception rather than a return value.
◆ hasValue()
Returns true if the RPC call associated with this future has finished with a return value value rather than an exception.
◆ wait()
Waits and blocks the current thread until the result of the associated RPC call is ready.
This is an interruption point.
◆ timedWait()
bool timedWait |
( |
Duration const & |
relTime | ) |
const |
|
inline |
Waits and blocks the current thread until the result of the associated RPC call is ready, or the time duration specified by waitDuration has elapsed.
This is an interruption point.
- Returns
- false if the call is returning because the time specified was reached, true otherwise.
◆ timedWaitUntil()
bool timedWaitUntil |
( |
boost::system_time const & |
absTime | ) |
const |
|
inline |
Waits and blocks the current thread until the result of the associated RPC call is ready, or the time point specified by waitDuration has passed.
This is an interruption point.
- Returns
- false if the call is returning because the time specified was reached, true otherwise.
◆ swap()
Swaps ownership of the asynchronous results associated with other and *this.
◆ mClient
◆ mCallId
◆ mFuture
boost::unique_future<R> mFuture |
|
protected |
The documentation for this class was generated from the following file: