rclcpp  master
C++ ROS Client Library API
Classes | Protected Types | Protected Member Functions | Static Protected Member Functions | Protected Attributes | List of all members
rclcpp::wait_set_policies::DynamicStorage Class Reference

WaitSet policy that provides dynamically sized storage. More...

#include <dynamic_storage.hpp>

Inheritance diagram for rclcpp::wait_set_policies::DynamicStorage:
Inheritance graph
[legend]
Collaboration diagram for rclcpp::wait_set_policies::DynamicStorage:
Collaboration graph
[legend]

Classes

class  SubscriptionEntry
 
class  WaitableEntry
 
class  WeakSubscriptionEntry
 
class  WeakWaitableEntry
 

Protected Types

using is_mutable = std::true_type
 
using SequenceOfWeakSubscriptions = std::vector< WeakSubscriptionEntry >
 
using SubscriptionsIterable = std::vector< SubscriptionEntry >
 
using SequenceOfWeakGuardConditions = std::vector< std::weak_ptr< rclcpp::GuardCondition > >
 
using GuardConditionsIterable = std::vector< std::shared_ptr< rclcpp::GuardCondition > >
 
using SequenceOfWeakTimers = std::vector< std::weak_ptr< rclcpp::TimerBase > >
 
using TimersIterable = std::vector< std::shared_ptr< rclcpp::TimerBase > >
 
using SequenceOfWeakClients = std::vector< std::weak_ptr< rclcpp::ClientBase > >
 
using ClientsIterable = std::vector< std::shared_ptr< rclcpp::ClientBase > >
 
using SequenceOfWeakServices = std::vector< std::weak_ptr< rclcpp::ServiceBase > >
 
using ServicesIterable = std::vector< std::shared_ptr< rclcpp::ServiceBase > >
 
using SequenceOfWeakWaitables = std::vector< WeakWaitableEntry >
 
using WaitablesIterable = std::vector< WaitableEntry >
 

Protected Member Functions

template<class ArrayOfExtraGuardConditions >
 DynamicStorage (const SubscriptionsIterable &subscriptions, const GuardConditionsIterable &guard_conditions, const ArrayOfExtraGuardConditions &extra_guard_conditions, const TimersIterable &timers, const ClientsIterable &clients, const ServicesIterable &services, const WaitablesIterable &waitables, rclcpp::Context::SharedPtr context)
 
 ~DynamicStorage ()=default
 
template<class ArrayOfExtraGuardConditions >
void storage_rebuild_rcl_wait_set (const ArrayOfExtraGuardConditions &extra_guard_conditions)
 
void storage_add_subscription (std::shared_ptr< rclcpp::SubscriptionBase > &&subscription)
 
void storage_remove_subscription (std::shared_ptr< rclcpp::SubscriptionBase > &&subscription)
 
void storage_add_guard_condition (std::shared_ptr< rclcpp::GuardCondition > &&guard_condition)
 
void storage_remove_guard_condition (std::shared_ptr< rclcpp::GuardCondition > &&guard_condition)
 
void storage_add_timer (std::shared_ptr< rclcpp::TimerBase > &&timer)
 
void storage_remove_timer (std::shared_ptr< rclcpp::TimerBase > &&timer)
 
void storage_add_client (std::shared_ptr< rclcpp::ClientBase > &&client)
 
void storage_remove_client (std::shared_ptr< rclcpp::ClientBase > &&client)
 
void storage_add_service (std::shared_ptr< rclcpp::ServiceBase > &&service)
 
void storage_remove_service (std::shared_ptr< rclcpp::ServiceBase > &&service)
 
void storage_add_waitable (std::shared_ptr< rclcpp::Waitable > &&waitable, std::shared_ptr< void > &&associated_entity)
 
void storage_remove_waitable (std::shared_ptr< rclcpp::Waitable > &&waitable)
 
void storage_prune_deleted_entities () noexcept
 
void storage_acquire_ownerships ()
 
void storage_release_ownerships ()
 
- Protected Member Functions inherited from rclcpp::wait_set_policies::detail::StoragePolicyCommon< false >
 StoragePolicyCommon (const SubscriptionsIterable &subscriptions, const GuardConditionsIterable &guard_conditions, const ExtraGuardConditionsIterable &extra_guard_conditions, const TimersIterable &timers, const ClientsIterable &clients, const ServicesIterable &services, const WaitablesIterable &waitables, rclcpp::Context::SharedPtr context)
 
 ~StoragePolicyCommon ()
 
std::pair< void *, EntityT * > get_raw_pointer_from_smart_pointer (const std::shared_ptr< EntityT > &shared_pointer)
 
std::pair< std::shared_ptr< EntityT >, EntityT * > get_raw_pointer_from_smart_pointer (const std::weak_ptr< EntityT > &weak_pointer)
 
void storage_rebuild_rcl_wait_set_with_sets (const SubscriptionsIterable &subscriptions, const GuardConditionsIterable &guard_conditions, const ExtraGuardConditionsIterable &extra_guard_conditions, const TimersIterable &timers, const ClientsIterable &clients, const ServicesIterable &services, const WaitablesIterable &waitables)
 Rebuild the wait set, preparing it for the next wait call. More...
 
const rcl_wait_set_tstorage_get_rcl_wait_set () const
 
rcl_wait_set_tstorage_get_rcl_wait_set ()
 
void storage_flag_for_resize ()
 

Static Protected Member Functions

template<class EntityT , class SequenceOfEntitiesT >
static bool storage_has_entity (const EntityT &entity, const SequenceOfEntitiesT &entities)
 
template<class EntityT , class SequenceOfEntitiesT >
static auto storage_find_entity (const EntityT &entity, const SequenceOfEntitiesT &entities)
 

Protected Attributes

size_t ownership_reference_counter_ = 0
 
SequenceOfWeakSubscriptions subscriptions_
 
SubscriptionsIterable shared_subscriptions_
 
SequenceOfWeakGuardConditions guard_conditions_
 
GuardConditionsIterable shared_guard_conditions_
 
SequenceOfWeakTimers timers_
 
TimersIterable shared_timers_
 
SequenceOfWeakClients clients_
 
ClientsIterable shared_clients_
 
SequenceOfWeakServices services_
 
ServicesIterable shared_services_
 
SequenceOfWeakWaitables waitables_
 
WaitablesIterable shared_waitables_
 
- Protected Attributes inherited from rclcpp::wait_set_policies::detail::StoragePolicyCommon< false >
rcl_wait_set_t rcl_wait_set_
 
rclcpp::Context::SharedPtr context_
 
bool needs_pruning_
 
bool needs_resize_
 

Detailed Description

WaitSet policy that provides dynamically sized storage.

Member Typedef Documentation

◆ is_mutable

◆ SequenceOfWeakSubscriptions

◆ SubscriptionsIterable

◆ SequenceOfWeakGuardConditions

◆ GuardConditionsIterable

◆ SequenceOfWeakTimers

◆ TimersIterable

◆ SequenceOfWeakClients

◆ ClientsIterable

◆ SequenceOfWeakServices

◆ ServicesIterable

◆ SequenceOfWeakWaitables

◆ WaitablesIterable

Constructor & Destructor Documentation

◆ DynamicStorage()

template<class ArrayOfExtraGuardConditions >
rclcpp::wait_set_policies::DynamicStorage::DynamicStorage ( const SubscriptionsIterable subscriptions,
const GuardConditionsIterable guard_conditions,
const ArrayOfExtraGuardConditions &  extra_guard_conditions,
const TimersIterable timers,
const ClientsIterable clients,
const ServicesIterable services,
const WaitablesIterable waitables,
rclcpp::Context::SharedPtr  context 
)
inlineexplicitprotected

◆ ~DynamicStorage()

rclcpp::wait_set_policies::DynamicStorage::~DynamicStorage ( )
protecteddefault

Member Function Documentation

◆ storage_rebuild_rcl_wait_set()

template<class ArrayOfExtraGuardConditions >
void rclcpp::wait_set_policies::DynamicStorage::storage_rebuild_rcl_wait_set ( const ArrayOfExtraGuardConditions &  extra_guard_conditions)
inlineprotected

◆ storage_has_entity()

template<class EntityT , class SequenceOfEntitiesT >
static bool rclcpp::wait_set_policies::DynamicStorage::storage_has_entity ( const EntityT &  entity,
const SequenceOfEntitiesT &  entities 
)
inlinestaticprotected

◆ storage_find_entity()

template<class EntityT , class SequenceOfEntitiesT >
static auto rclcpp::wait_set_policies::DynamicStorage::storage_find_entity ( const EntityT &  entity,
const SequenceOfEntitiesT &  entities 
)
inlinestaticprotected

◆ storage_add_subscription()

void rclcpp::wait_set_policies::DynamicStorage::storage_add_subscription ( std::shared_ptr< rclcpp::SubscriptionBase > &&  subscription)
inlineprotected

◆ storage_remove_subscription()

void rclcpp::wait_set_policies::DynamicStorage::storage_remove_subscription ( std::shared_ptr< rclcpp::SubscriptionBase > &&  subscription)
inlineprotected

◆ storage_add_guard_condition()

void rclcpp::wait_set_policies::DynamicStorage::storage_add_guard_condition ( std::shared_ptr< rclcpp::GuardCondition > &&  guard_condition)
inlineprotected

◆ storage_remove_guard_condition()

void rclcpp::wait_set_policies::DynamicStorage::storage_remove_guard_condition ( std::shared_ptr< rclcpp::GuardCondition > &&  guard_condition)
inlineprotected

◆ storage_add_timer()

void rclcpp::wait_set_policies::DynamicStorage::storage_add_timer ( std::shared_ptr< rclcpp::TimerBase > &&  timer)
inlineprotected

◆ storage_remove_timer()

void rclcpp::wait_set_policies::DynamicStorage::storage_remove_timer ( std::shared_ptr< rclcpp::TimerBase > &&  timer)
inlineprotected

◆ storage_add_client()

void rclcpp::wait_set_policies::DynamicStorage::storage_add_client ( std::shared_ptr< rclcpp::ClientBase > &&  client)
inlineprotected

◆ storage_remove_client()

void rclcpp::wait_set_policies::DynamicStorage::storage_remove_client ( std::shared_ptr< rclcpp::ClientBase > &&  client)
inlineprotected

◆ storage_add_service()

void rclcpp::wait_set_policies::DynamicStorage::storage_add_service ( std::shared_ptr< rclcpp::ServiceBase > &&  service)
inlineprotected

◆ storage_remove_service()

void rclcpp::wait_set_policies::DynamicStorage::storage_remove_service ( std::shared_ptr< rclcpp::ServiceBase > &&  service)
inlineprotected

◆ storage_add_waitable()

void rclcpp::wait_set_policies::DynamicStorage::storage_add_waitable ( std::shared_ptr< rclcpp::Waitable > &&  waitable,
std::shared_ptr< void > &&  associated_entity 
)
inlineprotected

◆ storage_remove_waitable()

void rclcpp::wait_set_policies::DynamicStorage::storage_remove_waitable ( std::shared_ptr< rclcpp::Waitable > &&  waitable)
inlineprotected

◆ storage_prune_deleted_entities()

void rclcpp::wait_set_policies::DynamicStorage::storage_prune_deleted_entities ( )
inlineprotectednoexcept

◆ storage_acquire_ownerships()

void rclcpp::wait_set_policies::DynamicStorage::storage_acquire_ownerships ( )
inlineprotected

◆ storage_release_ownerships()

void rclcpp::wait_set_policies::DynamicStorage::storage_release_ownerships ( )
inlineprotected

Member Data Documentation

◆ ownership_reference_counter_

size_t rclcpp::wait_set_policies::DynamicStorage::ownership_reference_counter_ = 0
protected

◆ subscriptions_

SequenceOfWeakSubscriptions rclcpp::wait_set_policies::DynamicStorage::subscriptions_
protected

◆ shared_subscriptions_

SubscriptionsIterable rclcpp::wait_set_policies::DynamicStorage::shared_subscriptions_
protected

◆ guard_conditions_

SequenceOfWeakGuardConditions rclcpp::wait_set_policies::DynamicStorage::guard_conditions_
protected

◆ shared_guard_conditions_

GuardConditionsIterable rclcpp::wait_set_policies::DynamicStorage::shared_guard_conditions_
protected

◆ timers_

SequenceOfWeakTimers rclcpp::wait_set_policies::DynamicStorage::timers_
protected

◆ shared_timers_

TimersIterable rclcpp::wait_set_policies::DynamicStorage::shared_timers_
protected

◆ clients_

SequenceOfWeakClients rclcpp::wait_set_policies::DynamicStorage::clients_
protected

◆ shared_clients_

ClientsIterable rclcpp::wait_set_policies::DynamicStorage::shared_clients_
protected

◆ services_

SequenceOfWeakServices rclcpp::wait_set_policies::DynamicStorage::services_
protected

◆ shared_services_

ServicesIterable rclcpp::wait_set_policies::DynamicStorage::shared_services_
protected

◆ waitables_

SequenceOfWeakWaitables rclcpp::wait_set_policies::DynamicStorage::waitables_
protected

◆ shared_waitables_

WaitablesIterable rclcpp::wait_set_policies::DynamicStorage::shared_waitables_
protected

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