From e387d45a18717bb986d966613e50854ea6676b28 Mon Sep 17 00:00:00 2001 From: Autumn60 Date: Sat, 13 Jul 2024 20:18:45 +0900 Subject: [PATCH 1/2] replace getData() to get_data() Signed-off-by: Autumn60 --- .../include/wheel_stuck_utils/ros/no_callback_subscription.hpp | 2 +- src/sample/simple_int_subscriber/src/polling_int_subscriber.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/common/wheel_stuck_utils/include/wheel_stuck_utils/ros/no_callback_subscription.hpp b/src/common/wheel_stuck_utils/include/wheel_stuck_utils/ros/no_callback_subscription.hpp index 19e0c43..ede7c41 100644 --- a/src/common/wheel_stuck_utils/include/wheel_stuck_utils/ros/no_callback_subscription.hpp +++ b/src/common/wheel_stuck_utils/include/wheel_stuck_utils/ros/no_callback_subscription.hpp @@ -37,7 +37,7 @@ class NoCallbackSubscription noexec_subscription_options); } - typename TMessage::ConstSharedPtr getData() + typename TMessage::ConstSharedPtr get_data() { auto data = std::make_shared(); rclcpp::MessageInfo message_info; diff --git a/src/sample/simple_int_subscriber/src/polling_int_subscriber.cpp b/src/sample/simple_int_subscriber/src/polling_int_subscriber.cpp index 26e9bf2..6ab4a23 100644 --- a/src/sample/simple_int_subscriber/src/polling_int_subscriber.cpp +++ b/src/sample/simple_int_subscriber/src/polling_int_subscriber.cpp @@ -30,7 +30,7 @@ PollingIntSubscriber::PollingIntSubscriber(const rclcpp::NodeOptions & options) void PollingIntSubscriber::update() { - const auto msg = sub_->getData(); + const auto msg = sub_->get_data(); if (msg) { std::cout << "Received: '" << msg->data << "'" << std::endl; } else { From 7d28e244cfb40a766f9ed57ed8014d4392c71227 Mon Sep 17 00:00:00 2001 From: Autumn60 Date: Sat, 13 Jul 2024 20:27:52 +0900 Subject: [PATCH 2/2] replace getData to get_data Signed-off-by: Autumn60 --- src/planning/dwa_planner/src/dwa_planner.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/planning/dwa_planner/src/dwa_planner.cpp b/src/planning/dwa_planner/src/dwa_planner.cpp index 396d257..dd357be 100644 --- a/src/planning/dwa_planner/src/dwa_planner.cpp +++ b/src/planning/dwa_planner/src/dwa_planner.cpp @@ -149,7 +149,7 @@ bool DWAPlanner::subscribe_and_validate() bool DWAPlanner::try_subscribe_map() { - auto map_msg = map_sub_->getData(); + auto map_msg = map_sub_->get_data(); if (!map_msg) return false; map_ = map_msg; return true; @@ -157,7 +157,7 @@ bool DWAPlanner::try_subscribe_map() bool DWAPlanner::try_subscribe_odom() { - auto odom_msg = odom_sub_->getData(); + auto odom_msg = odom_sub_->get_data(); if (!odom_msg) return false; odom_ = odom_msg; return true; @@ -165,7 +165,7 @@ bool DWAPlanner::try_subscribe_odom() bool DWAPlanner::try_subscribe_goal() { - auto goal_msg = goal_sub_->getData(); + auto goal_msg = goal_sub_->get_data(); if (!goal_msg) return false; goal_ = goal_msg; return true;