SMACC2
Loading...
Searching...
No Matches
Public Member Functions | Private Attributes | List of all members
cl_nav2z::CpAmcl Class Reference

#include <cp_amcl.hpp>

Inheritance diagram for cl_nav2z::CpAmcl:
Inheritance graph
Collaboration diagram for cl_nav2z::CpAmcl:
Collaboration graph

Public Member Functions

 CpAmcl ()
 
virtual ~CpAmcl ()
 
std::string getName () const override
 
void onInitialize () override
 
void setInitialPose (const geometry_msgs::msg::PoseWithCovarianceStamped &initialpose)
 
- Public Member Functions inherited from smacc2::ISmaccComponent
 ISmaccComponent ()
 
virtual ~ISmaccComponent ()
 

Private Attributes

rclcpp::Publisher< geometry_msgs::msg::PoseWithCovarianceStamped >::SharedPtr initalPosePub_
 

Additional Inherited Members

- Protected Member Functions inherited from smacc2::ISmaccComponent
template<typename EventType >
void postEvent (const EventType &ev)
 
template<typename EventType >
void postEvent ()
 
template<typename TOrthogonal , typename TSourceObject >
void onOrthogonalAllocation ()
 
template<typename TComponent >
void requiresComponent (TComponent *&requiredComponentStorage, bool throwExceptionIfNotExist=false)
 
template<typename TComponent >
void requiresComponent (std::string name, TComponent *&requiredComponentStorage, bool throwExceptionIfNotExist=false)
 
template<typename TClient >
void requiresClient (TClient *&requiredClientStorage)
 
template<typename SmaccComponentType , typename TOrthogonal , typename TClient , typename... TArgs>
SmaccComponentTypecreateSiblingComponent (TArgs... targs)
 
template<typename SmaccComponentType , typename TOrthogonal , typename TClient , typename... TArgs>
SmaccComponentTypecreateSiblingNamedComponent (std::string name, TArgs... targs)
 
rclcpp::Node::SharedPtr getNode ()
 
rclcpp::Logger getLogger () const
 
ISmaccStateMachinegetStateMachine ()
 
- Protected Attributes inherited from smacc2::ISmaccComponent
ISmaccStateMachinestateMachine_
 
ISmaccClientowner_
 

Detailed Description

Definition at line 27 of file cp_amcl.hpp.

Constructor & Destructor Documentation

◆ CpAmcl()

cl_nav2z::CpAmcl::CpAmcl ( )

Definition at line 26 of file cp_amcl.cpp.

26{}

◆ ~CpAmcl()

cl_nav2z::CpAmcl::~CpAmcl ( )
virtual

Definition at line 28 of file cp_amcl.cpp.

28{}

Member Function Documentation

◆ getName()

std::string cl_nav2z::CpAmcl::getName ( ) const
overridevirtual

Reimplemented from smacc2::ISmaccComponent.

Definition at line 30 of file cp_amcl.cpp.

30{ return "AMCL"; }

◆ onInitialize()

void cl_nav2z::CpAmcl::onInitialize ( )
overridevirtual

Reimplemented from smacc2::ISmaccComponent.

Definition at line 32 of file cp_amcl.cpp.

33{
34 initalPosePub_ = getNode()->create_publisher<geometry_msgs::msg::PoseWithCovarianceStamped>(
35 "initialpose", rclcpp::QoS(10));
36}
rclcpp::Publisher< geometry_msgs::msg::PoseWithCovarianceStamped >::SharedPtr initalPosePub_
Definition cp_amcl.hpp:40
rclcpp::Node::SharedPtr getNode()

References smacc2::ISmaccComponent::getNode(), and initalPosePub_.

Here is the call graph for this function:

◆ setInitialPose()

void cl_nav2z::CpAmcl::setInitialPose ( const geometry_msgs::msg::PoseWithCovarianceStamped &  initialpose)

Definition at line 38 of file cp_amcl.cpp.

39{
40 initalPosePub_->publish(initialpose);
41}

References initalPosePub_.

Member Data Documentation

◆ initalPosePub_

rclcpp::Publisher<geometry_msgs::msg::PoseWithCovarianceStamped>::SharedPtr cl_nav2z::CpAmcl::initalPosePub_
private

Definition at line 40 of file cp_amcl.hpp.

Referenced by onInitialize(), and setInitialPose().


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