api: follow the interface rename of the sensor key to topic

move_base_core renamed the string argument of the add/get/remove sensor
functions from five different *_name spellings to topic, because it is the key
that has to match observation_sources and sensor_store_params.yaml rather than
a free-form label. The overrides here follow so declaration and definition read
the same.

Parameter names only; no signature, no behaviour, no ABI. The member
map_name_save_ is untouched - it is not this key.
This commit is contained in:
2026-08-27 12:06:14 +07:00
parent 857194367f
commit b18b06465f
2 changed files with 74 additions and 50 deletions

View File

@@ -188,30 +188,30 @@ public:
void setRobotFootprint(const std::vector<robot_geometry_msgs::Point>& fprt) override;
std::vector<robot_geometry_msgs::Point> getRobotFootprint() override;
void addStaticMap(const std::string& map_name, robot_nav_msgs::OccupancyGrid map) override;
void addLaserScan(const std::string& laser_scan_name,
void addStaticMap(const std::string& topic, robot_nav_msgs::OccupancyGrid map) override;
void addLaserScan(const std::string& topic,
robot_sensor_msgs::LaserScan laser_scan) override;
void addPointCloud(const std::string& point_cloud_name,
void addPointCloud(const std::string& topic,
robot_sensor_msgs::PointCloud point_cloud) override;
void addPointCloud2(const std::string& point_cloud2_name,
void addPointCloud2(const std::string& topic,
robot_sensor_msgs::PointCloud2 point_cloud2) override;
void addDepthCameraData(const std::string& topic,
robot_sensor_msgs::DepthCameraData::ConstPtr data) override;
robot_nav_msgs::OccupancyGrid getStaticMap(const std::string& map_name) override;
robot_sensor_msgs::LaserScan getLaserScan(const std::string& laser_scan_name) override;
robot_sensor_msgs::PointCloud getPointCloud(const std::string& point_cloud_name) override;
robot_sensor_msgs::PointCloud2 getPointCloud2(const std::string& point_cloud2_name) override;
robot_nav_msgs::OccupancyGrid getStaticMap(const std::string& topic) override;
robot_sensor_msgs::LaserScan getLaserScan(const std::string& topic) override;
robot_sensor_msgs::PointCloud getPointCloud(const std::string& topic) override;
robot_sensor_msgs::PointCloud2 getPointCloud2(const std::string& topic) override;
std::map<std::string, robot_nav_msgs::OccupancyGrid> getAllStaticMaps() override;
std::map<std::string, robot_sensor_msgs::LaserScan> getAllLaserScans() override;
std::map<std::string, robot_sensor_msgs::PointCloud> getAllPointClouds() override;
std::map<std::string, robot_sensor_msgs::PointCloud2> getAllPointCloud2s() override;
bool removeStaticMap(const std::string& map_name) override;
bool removeLaserScan(const std::string& laser_scan_name) override;
bool removePointCloud(const std::string& point_cloud_name) override;
bool removePointCloud2(const std::string& point_cloud2_name) override;
bool removeStaticMap(const std::string& topic) override;
bool removeLaserScan(const std::string& topic) override;
bool removePointCloud(const std::string& topic) override;
bool removePointCloud2(const std::string& topic) override;
bool removeAllStaticMaps() override;
bool removeAllLaserScans() override;
@@ -219,7 +219,7 @@ public:
bool removeAllPointCloud2s() override;
bool removeAllData() override;
void addOdometry(const std::string& odometry_name, robot_nav_msgs::Odometry odometry) override;
void addOdometry(const std::string& topic, robot_nav_msgs::Odometry odometry) override;
bool moveTo(const robot_geometry_msgs::PoseStamped& goal, double xy_goal_tolerance,
double yaw_goal_tolerance) override;