C++ YASMIN (Yet Another State MachINe)
Loading...
Searching...
No Matches
yasmin_ros
include
yasmin_ros
get_parameters_state.hpp
Go to the documentation of this file.
1
// Copyright (C) 2025 Miguel Ángel González Santamarta
2
//
3
// This program is free software: you can redistribute it and/or modify
4
// it under the terms of the GNU General Public License as published by
5
// the Free Software Foundation, either version 3 of the License, or
6
// (at your option) any later version.
7
//
8
// This program is distributed in the hope that it will be useful,
9
// but WITHOUT ANY WARRANTY; without even the implied warranty of
10
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11
// GNU General Public License for more details.
12
// You should have received a copy of the GNU General Public License
13
// along with this program. If not, see <https://www.gnu.org/licenses/>.
14
15
#ifndef YASMIN_ROS__GET_PARAMETER_STATE_HPP
16
#define YASMIN_ROS__GET_PARAMETER_STATE_HPP
17
18
#include <any>
19
#include <map>
20
#include <string>
21
22
#include "rclcpp/rclcpp.hpp"
23
#include "
yasmin/blackboard/blackboard.hpp
"
24
#include "
yasmin/state.hpp
"
25
#include "
yasmin_ros/basic_outcomes.hpp
"
26
#include "
yasmin_ros/yasmin_node.hpp
"
27
28
namespace
yasmin_ros
{
29
36
class
GetParametersState
:
public
yasmin::State
{
37
public
:
44
GetParametersState
(
const
std::map<std::string, std::any> ¶meters,
45
rclcpp::Node::SharedPtr node =
nullptr
);
46
53
std::string
54
execute
(std::shared_ptr<yasmin::blackboard::Blackboard> blackboard)
override
;
55
56
private
:
59
std::map<std::string, std::any>
parameters_
;
61
rclcpp::Node::SharedPtr
node_
;
62
};
63
64
}
// namespace yasmin_ros
65
66
#endif
// YASMIN_ROS__GET_PARAMETER_STATE_HPP
basic_outcomes.hpp
blackboard.hpp
yasmin::State
Represents a state in a state machine.
Definition
state.hpp:53
yasmin_ros::GetParametersState::parameters_
std::map< std::string, std::any > parameters_
Definition
get_parameters_state.hpp:59
yasmin_ros::GetParametersState::execute
std::string execute(std::shared_ptr< yasmin::blackboard::Blackboard > blackboard) override
Executes the state to retrieve parameters.
Definition
get_parameters_state.cpp:36
yasmin_ros::GetParametersState::node_
rclcpp::Node::SharedPtr node_
Shared pointer to the ROS 2 node.
Definition
get_parameters_state.hpp:61
yasmin_ros::GetParametersState::GetParametersState
GetParametersState(const std::map< std::string, std::any > ¶meters, rclcpp::Node::SharedPtr node=nullptr)
Constructs a GetParametersState with a map of parameters.
Definition
get_parameters_state.cpp:23
yasmin_ros
Definition
action_state.hpp:37
state.hpp
yasmin_node.hpp
Generated by
1.13.2