- Aldebaran documentation |
- C++ Libraries |
- index

libqi-api 2.8.7.4

- Main Page
- Related Pages
- Namespaces
- Classes
- Files
- Examples

- Class List
- Class Hierarchy
- Class Members

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | Protected Member Functions | List of all members
qi::ExecutionContext Class Referenceabstract

`#include <executioncontext.hpp>`

## Public Member Functions
virtual | ~ExecutionContext ()
virtual qi::Future< void > | async (const boost::function< void()> &callback, qi::SteadyClockTimePoint tp)=0
virtual qi::Future< void > | async (const boost::function< void()> &callback, qi::Duration delay)=0
template<typename R >
boost::disable_if < std::is_same< R, void > , qi::Future< R > >::type | async (const boost::function< R()> &callback, qi::Duration delay)
template<typename R >
boost::disable_if < std::is_same< R, void > , qi::Future< R > >::type | async (const boost::function< R()> &callback, qi::SteadyClockTimePoint tp)
template<typename R >
qi::Future< R > | async (const detail::Function< R()> &callback)
template<typename F >
void | post (F &&callback, ExecutionOptions options=defaultExecutionOptions())
| post a callback to be executed as soon as possible More...
template<typename F , typename R = ka::Decay<decltype(std::declval<F>()())>>
qi::Future< R > | asyncAt (F &&callback, qi::SteadyClockTimePoint tp, ExecutionOptions options=defaultExecutionOptions())
| call a callback asynchronously to be executed on tp More...
template<typename F , typename R = ka::Decay<decltype(std::declval<F>()())>>
qi::Future< R > | asyncDelay (F &&callback, qi::Duration delay, ExecutionOptions options=defaultExecutionOptions())
| call a callback asynchronously to be executed in delay More...
template<typename F >
auto | async (F &&callback, ExecutionOptions options=defaultExecutionOptions()) -> decltype(asyncDelay(std::forward< F >(callback), qi::Duration(0), options))
virtual bool | isInThisContext () const =0
| return true if the current thread is in this context More...
template<typename F , typename R >
Future< R > | asyncAt (F &&callback, qi::SteadyClockTimePoint tp, ExecutionOptions options)
template<typename F , typename R >
Future< R > | asyncDelay (F &&callback, qi::Duration delay, ExecutionOptions options)

## Protected Member Functions
virtual void | postImpl (boost::function< void()> callback, ExecutionOptions options)=0
virtual qi::Future< void > | asyncAtImpl (boost::function< void()> cb, qi::SteadyClockTimePoint tp, ExecutionOptions options)=0
virtual qi::Future< void > | asyncDelayImpl (boost::function< void()> cb, qi::Duration delay, ExecutionOptions options)=0

## Detailed Description

Definition at line 63 of file executioncontext.hpp.

## Constructor & Destructor Documentation

virtual qi::ExecutionContext::~ExecutionContext | ( |  | ) |
| inline virtual

Definition at line 66 of file executioncontext.hpp.

## Member Function Documentation

virtual qi::Future<void> qi::ExecutionContext::async | ( | const boost::function< void()> & | callback,
|  | qi::SteadyClockTimePoint | tp
| ) |  |
| pure virtual

call a callback asynchronously to be executed on tp

Deprecated:
  since 2.5

Implemented in qi::Strand, qi::EventLoop, and qi::StrandPrivate.

virtual qi::Future<void> qi::ExecutionContext::async | ( | const boost::function< void()> & | callback,
|  | qi::Duration | delay
| ) |  |
| pure virtual

call a callback asynchronously to be executed in delay

Deprecated:
  since 2.5

Implemented in qi::Strand, qi::EventLoop, and qi::StrandPrivate.

template<typename R >

boost::disable_if< std::is_same< R, void >, qi::Future< R > >::type qi::ExecutionContext::async | ( | const boost::function< R()> & | callback,
|  | qi::Duration | delay
| ) |  |

call a callback asynchronously to be executed in delay

Deprecated:
  since 2.5

Definition at line 194 of file executioncontext.hpp.

template<typename R >

boost::disable_if< std::is_same< R, void >, qi::Future< R > >::type qi::ExecutionContext::async | ( | const boost::function< R()> & | callback,
|  | qi::SteadyClockTimePoint | tp
| ) |  |

call a callback asynchronously to be executed on tp

Deprecated:
  since 2.5

Definition at line 211 of file executioncontext.hpp.

template<typename R >

qi::Future<R> qi::ExecutionContext::async | ( | const detail::Function< R()> & | callback | ) |
| inline

Deprecated:
  since 2.5

Definition at line 94 of file executioncontext.hpp.

template<typename F >

auto qi::ExecutionContext::async | ( | F && | callback,
|  | ExecutionOptions | options = `defaultExecutionOptions()`
| ) |  | -> decltype(asyncDelay(std::forward<F>(callback), qi::Duration(0), options))
| inline

Definition at line 112 of file executioncontext.hpp.

template<typename F , typename R = ka::Decay<decltype(std::declval<F>()())>>

qi::Future<R> qi::ExecutionContext::asyncAt | ( | F && | callback,
|  | qi::SteadyClockTimePoint | tp,
|  | ExecutionOptions | options = `defaultExecutionOptions()`
| ) |  |

call a callback asynchronously to be executed on tp

template<typename F , typename R >

Future<R> qi::ExecutionContext::asyncAt | ( | F && | callback,
|  | qi::SteadyClockTimePoint | tp,
|  | ExecutionOptions | options
| ) |  |

Definition at line 248 of file executioncontext.hpp.

virtual qi::Future<void> qi::ExecutionContext::asyncAtImpl | ( | boost::function< void()> | cb,
|  | qi::SteadyClockTimePoint | tp,
|  | ExecutionOptions | options
| ) |  |
| protected pure virtual

Implemented in qi::StrandPrivate.

template<typename F , typename R = ka::Decay<decltype(std::declval<F>()())>>

qi::Future<R> qi::ExecutionContext::asyncDelay | ( | F && | callback,
|  | qi::Duration | delay,
|  | ExecutionOptions | options = `defaultExecutionOptions()`
| ) |  |

call a callback asynchronously to be executed in delay

template<typename F , typename R >

Future<R> qi::ExecutionContext::asyncDelay | ( | F && | callback,
|  | qi::Duration | delay,
|  | ExecutionOptions | options
| ) |  |

Definition at line 260 of file executioncontext.hpp.

virtual qi::Future<void> qi::ExecutionContext::asyncDelayImpl | ( | boost::function< void()> | cb,
|  | qi::Duration | delay,
|  | ExecutionOptions | options
| ) |  |
| protected pure virtual

Implemented in qi::StrandPrivate.

virtual bool qi::ExecutionContext::isInThisContext | ( |  | ) | const
| pure virtual

return true if the current thread is in this context

Implemented in qi::Strand, qi::StrandPrivate, and qi::EventLoop.

template<typename F >

void qi::ExecutionContext::post | ( | F && | callback,
|  | ExecutionOptions | options = `defaultExecutionOptions()`
| ) |  |

post a callback to be executed as soon as possible

Definition at line 226 of file executioncontext.hpp.

virtual void qi::ExecutionContext::postImpl | ( | boost::function< void()> | callback,
|  | ExecutionOptions | options
| ) |  |
| protected pure virtual

Implemented in qi::StrandPrivate.

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

- /home/opennao/work/release-2.8/sdk/libqi/qi/detail/executioncontext.hpp