#include <waitable.hpp>
◆ ~Waitable()
virtual rclcpp::Waitable::~Waitable |
( |
| ) |
|
|
virtualdefault |
◆ get_number_of_ready_subscriptions()
virtual size_t rclcpp::Waitable::get_number_of_ready_subscriptions |
( |
| ) |
|
|
virtual |
Get the number of ready subscriptions.
Returns a value of 0 by default. This should be overridden if the Waitable contains one or more subscriptions.
- Returns
- The number of subscriptions associated with the Waitable.
◆ get_number_of_ready_timers()
virtual size_t rclcpp::Waitable::get_number_of_ready_timers |
( |
| ) |
|
|
virtual |
Get the number of ready timers.
Returns a value of 0 by default. This should be overridden if the Waitable contains one or more timers.
- Returns
- The number of timers associated with the Waitable.
◆ get_number_of_ready_clients()
virtual size_t rclcpp::Waitable::get_number_of_ready_clients |
( |
| ) |
|
|
virtual |
Get the number of ready clients.
Returns a value of 0 by default. This should be overridden if the Waitable contains one or more clients.
- Returns
- The number of clients associated with the Waitable.
◆ get_number_of_ready_events()
virtual size_t rclcpp::Waitable::get_number_of_ready_events |
( |
| ) |
|
|
virtual |
Get the number of ready events.
Returns a value of 0 by default. This should be overridden if the Waitable contains one or more events.
- Returns
- The number of events associated with the Waitable.
Reimplemented in rclcpp::QOSEventHandlerBase.
◆ get_number_of_ready_services()
virtual size_t rclcpp::Waitable::get_number_of_ready_services |
( |
| ) |
|
|
virtual |
Get the number of ready services.
Returns a value of 0 by default. This should be overridden if the Waitable contains one or more services.
- Returns
- The number of services associated with the Waitable.
◆ get_number_of_ready_guard_conditions()
virtual size_t rclcpp::Waitable::get_number_of_ready_guard_conditions |
( |
| ) |
|
|
virtual |
◆ add_to_wait_set()
virtual bool rclcpp::Waitable::add_to_wait_set |
( |
rcl_wait_set_t * |
wait_set | ) |
|
|
pure virtual |
◆ is_ready()
◆ execute()
virtual void rclcpp::Waitable::execute |
( |
| ) |
|
|
pure virtual |
Execute any entities of the Waitable that are ready.
Before calling this method, the Waitable should be added to a wait set, waited on, and then updated.
Example usage:
bool add_ret = waitable.add_to_wait_set(wait_set);
rcl_ret_t wait_ret = rcl_wait(wait_set);
waitable.update(wait_set);
waitable.execute();
Implemented in rclcpp::experimental::SubscriptionIntraProcessBase, rclcpp::QOSEventHandler< EventCallbackT, ParentHandleT >, rclcpp::executors::StaticExecutorEntitiesCollector, and rclcpp::experimental::SubscriptionIntraProcess< MessageT, Alloc, Deleter, CallbackMessageT >.
◆ exchange_in_use_by_wait_set_state()
bool rclcpp::Waitable::exchange_in_use_by_wait_set_state |
( |
bool |
in_use_state | ) |
|
Exchange the "in use by wait set" state for this timer.
This is used to ensure this timer is not used by multiple wait sets at the same time.
- Parameters
-
[in] | in_use_state | the new state to exchange into the state, true indicates it is now in use by a wait set, and false is that it is no longer in use by a wait set. |
- Returns
- the previous state.
The documentation for this class was generated from the following file: