MIRA
Public Member Functions | Protected Attributes | List of all members
SDOFutureCommon< R > Class Template Reference

Wrapper for boost::unique_future that is specialized for SDO processing. More...

#include <can/SDOFuture.h>

Inheritance diagram for SDOFutureCommon< R >:
Inheritance graph
[legend]

Public Member Functions

 SDOFutureCommon ()
 
 SDOFutureCommon (SDOClientBase *client, uint64 requestID)
 
 ~SDOFutureCommon ()
 
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 (SDOFutureCommon< R > &other)
 Swaps ownership of the asynchronous results associated with other and *this. More...
 

Protected Attributes

SDOClientBasemClient
 
uint64 mRequestID
 
boost::unique_future< R > mFuture
 

Detailed Description

template<typename R>
class mira::can::SDOFutureCommon< R >

Wrapper for boost::unique_future that is specialized for SDO processing.

This is a base class for the concrete derived SDOFuture classes.

Constructor & Destructor Documentation

◆ SDOFutureCommon() [1/2]

SDOFutureCommon ( )
inline

◆ SDOFutureCommon() [2/2]

SDOFutureCommon ( SDOClientBase client,
uint64  requestID 
)
inline

◆ ~SDOFutureCommon()

~SDOFutureCommon ( )
inline

Member Function Documentation

◆ isReady()

bool isReady ( ) const
inline

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()

bool hasValue ( ) const
inline

Returns true if the RPC call associated with this future has finished with a return value value rather than an exception.

◆ wait()

void wait ( ) const
inline

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.

◆ 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.

◆ swap()

void swap ( SDOFutureCommon< R > &  other)
inline

Swaps ownership of the asynchronous results associated with other and *this.

Member Data Documentation

◆ mClient

SDOClientBase* mClient
protected

◆ mRequestID

uint64 mRequestID
protected

◆ mFuture

boost::unique_future<R> mFuture
protected

The documentation for this class was generated from the following file: