56 service_ = context_->moveit_cpp_->getNode()->create_service<std_srvs::srv::Empty>(
57 CLEAR_OCTOMAP_SERVICE_NAME,
58 [
this](
const std::shared_ptr<std_srvs::srv::Empty::Request>& req,
59 const std::shared_ptr<std_srvs::srv::Empty::Response>& res) {
return clearOctomap(req, res); });
62 void move_group::ClearOctomapService::clearOctomap(
const std::shared_ptr<std_srvs::srv::Empty::Request>& ,
63 const std::shared_ptr<std_srvs::srv::Empty::Response>& )
65 if (!context_->planning_scene_monitor_)
66 RCLCPP_ERROR(
getLogger(),
"Cannot clear octomap since planning scene monitor has not been initialized.");
68 RCLCPP_INFO(
getLogger(),
"Clearing octomap...");
69 context_->planning_scene_monitor_->clearOctomap();
70 RCLCPP_INFO(
getLogger(),
"Octomap cleared.");
73 #include <pluginlib/class_list_macros.hpp>
PLUGINLIB_EXPORT_CLASS(cached_ik_kinematics_plugin::CachedIKKinematicsPlugin< kdl_kinematics_plugin::KDLKinematicsPlugin >, kinematics::KinematicsBase)
void initialize() override
rclcpp::Logger getLogger()
rclcpp::Logger getLogger(const std::string &name)
Creates a namespaced logger.