SMACC2
Loading...
Searching...
No Matches
cl_ros2_timer::ClRos2Timer Class Reference

#include <cl_ros2_timer.hpp>

Inheritance diagram for cl_ros2_timer::ClRos2Timer:
Inheritance graph
Collaboration diagram for cl_ros2_timer::ClRos2Timer:
Collaboration graph

Public Member Functions

 ClRos2Timer (rclcpp::Duration duration, bool oneshot=false)
 
virtual ~ClRos2Timer ()
 
template<typename TOrthogonal , typename TClient >
void onComponentInitialization ()
 
- Public Member Functions inherited from smacc2::ISmaccClient
 ISmaccClient ()
 
virtual ~ISmaccClient ()
 
virtual void onInitialize ()
 
virtual std::string getName () const
 
template<typename TComponent >
TComponent * getComponent ()
 
template<typename TComponent >
TComponent * getComponent (std::string name)
 
template<typename TComponent >
TComponent * getComponent (int index)
 
virtual smacc2::introspection::TypeInfo::Ptr getType ()
 
ISmaccStateMachinegetStateMachine ()
 
template<typename TSmaccSignal , typename T >
void connectSignal (TSmaccSignal &signal, void(T::*callback)(), T *object)
 
template<typename SmaccClientType >
void requiresClient (SmaccClientType *&storage)
 
void getComponents (std::vector< std::shared_ptr< ISmaccComponent > > &components)
 
const std::vector< std::shared_ptr< ISmaccComponent > > & iterateComponents () const
 
template<typename EventType >
void postEvent (const EventType &ev)
 
template<typename EventType >
void postEvent ()
 

Private Attributes

rclcpp::Duration duration_
 
bool oneshot_
 

Additional Inherited Members

- Protected Member Functions inherited from smacc2::ISmaccClient
template<typename TOrthogonal , typename TClient >
void onComponentInitialization ()
 
template<typename TOrthogonal , typename TSourceObject >
void onOrthogonalAllocation ()
 
template<typename TOrthogonal , typename TSourceObject >
void onStateOrthogonalAllocation ()
 
template<typename SmaccComponentType , typename TOrthogonal , typename TClient , typename... TArgs>
SmaccComponentType * createComponent (TArgs... targs)
 
template<typename SmaccComponentType , typename TOrthogonal , typename TClient , typename... TArgs>
SmaccComponentType * createNamedComponent (std::string name, TArgs... targs)
 
rclcpp::Node::SharedPtr getNode ()
 
rclcpp::Logger getLogger ()
 
- Protected Attributes inherited from smacc2::ISmaccClient
std::map< ComponentKey, std::shared_ptr< smacc2::ISmaccComponent > > components_
 

Detailed Description

Definition at line 32 of file cl_ros2_timer.hpp.

Constructor & Destructor Documentation

◆ ClRos2Timer()

cl_ros2_timer::ClRos2Timer::ClRos2Timer ( rclcpp::Duration duration,
bool oneshot = false )

Definition at line 19 of file cl_ros2_timer.cpp.

20: duration_(duration), oneshot_(oneshot)
21{
22}

◆ ~ClRos2Timer()

cl_ros2_timer::ClRos2Timer::~ClRos2Timer ( )
virtual

Definition at line 24 of file cl_ros2_timer.cpp.

25{
26 // Components are automatically cleaned up by the framework
27}

Member Function Documentation

◆ onComponentInitialization()

template<typename TOrthogonal , typename TClient >
void cl_ros2_timer::ClRos2Timer::onComponentInitialization ( )
inline

Definition at line 41 of file cl_ros2_timer.hpp.

42 {
43 // Create the core timer component
46
47 // Create the timer listener component that requires CpRos2Timer
49 }
SmaccComponentType * createComponent(TArgs... targs)

References smacc2::ISmaccClient::createComponent(), duration_, and oneshot_.

Here is the call graph for this function:

Member Data Documentation

◆ duration_

rclcpp::Duration cl_ros2_timer::ClRos2Timer::duration_
private

Definition at line 52 of file cl_ros2_timer.hpp.

Referenced by onComponentInitialization().

◆ oneshot_

bool cl_ros2_timer::ClRos2Timer::oneshot_
private

Definition at line 53 of file cl_ros2_timer.hpp.

Referenced by onComponentInitialization().


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