SMACC2
Public Member Functions | Public Attributes | List of all members
sm_dance_bot::cl_string_publisher::CbStringPublisher Class Reference

#include <cb_string_publisher.hpp>

Inheritance diagram for sm_dance_bot::cl_string_publisher::CbStringPublisher:
Inheritance graph
Collaboration diagram for sm_dance_bot::cl_string_publisher::CbStringPublisher:
Collaboration graph

Public Member Functions

 CbStringPublisher (std::string msg)
 
virtual void runtimeConfigure () override
 
virtual void onEntry ()
 
void onExit () override
 
void onEntry () override
 
void onExit () override
 
- Public Member Functions inherited from smacc2::ISmaccClientBehavior
 ISmaccClientBehavior ()
 
virtual ~ISmaccClientBehavior ()
 
ISmaccStateMachinegetStateMachine ()
 
std::string getName () const
 
template<typename SmaccClientType >
void requiresClient (SmaccClientType *&storage)
 
template<typename SmaccComponentType >
void requiresComponent (SmaccComponentType *&storage)
 

Public Attributes

ClStringPublisherpublisherClient_
 
std::string msg_
 

Additional Inherited Members

- Protected Member Functions inherited from smacc2::ISmaccClientBehavior
virtual void runtimeConfigure ()
 
virtual void onEntry ()
 
virtual void onExit ()
 
template<typename EventType >
void postEvent (const EventType &ev)
 
template<typename EventType >
void postEvent ()
 
ISmaccStategetCurrentState ()
 
virtual void dispose ()
 
virtual rclcpp::Node::SharedPtr getNode ()
 
virtual rclcpp::Logger getLogger ()
 

Detailed Description

Definition at line 31 of file cb_string_publisher.hpp.

Constructor & Destructor Documentation

◆ CbStringPublisher()

sm_dance_bot::cl_string_publisher::CbStringPublisher::CbStringPublisher ( std::string  msg)
inline

Definition at line 37 of file cb_string_publisher.hpp.

References msg_.

Member Function Documentation

◆ onEntry()

virtual void sm_dance_bot::cl_string_publisher::CbStringPublisher::onEntry ( )
inlinevirtual

Reimplemented from smacc2::SmaccClientBehavior.

Definition at line 45 of file cb_string_publisher.hpp.

References smacc2::ISmaccClientBehavior::requiresClient().

Here is the call graph for this function:

◆ onExit()

void sm_dance_bot::cl_string_publisher::CbStringPublisher::onExit ( )
inlineoverridevirtual

Reimplemented from smacc2::SmaccClientBehavior.

Definition at line 47 of file cb_string_publisher.hpp.

48 {
49 std_msgs::msg::String rosmsg;
50 rosmsg.data = msg_;
52 }

References msg_, smacc2::client_bases::SmaccPublisherClient::publish(), and publisherClient_.

Here is the call graph for this function:

◆ runtimeConfigure()

virtual void sm_dance_bot::cl_string_publisher::CbStringPublisher::runtimeConfigure ( )
inlineoverridevirtual

Reimplemented from smacc2::ISmaccClientBehavior.

Definition at line 39 of file cb_string_publisher.hpp.

40 {
41 RCLCPP_INFO_STREAM(
42 getLogger(), "Creating CbStringPublisher behavior with stored message: " << msg_);
43 }

References smacc2::ISmaccClientBehavior::getLogger(), and msg_.

Here is the call graph for this function:

Member Data Documentation

◆ msg_

std::string sm_dance_bot::cl_string_publisher::CbStringPublisher::msg_

Definition at line 35 of file cb_string_publisher.hpp.

Referenced by CbStringPublisher(), onExit(), and runtimeConfigure().

◆ publisherClient_

ClStringPublisher* sm_dance_bot::cl_string_publisher::CbStringPublisher::publisherClient_

Definition at line 34 of file cb_string_publisher.hpp.

Referenced by onExit().


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