Nav2 Navigation Stack - kilted  kilted
ROS 2 Navigation Stack
main_server.cpp
1 // Copyright (c) 2020 Samsung Research Russia
2 // Copyright (c) 2018 Intel Corporation
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 
16 #include <memory>
17 #include <stdexcept>
18 #include <string>
19 
20 #include "nav2_map_server/map_saver.hpp"
21 #include "rclcpp/rclcpp.hpp"
22 
23 int main(int argc, char ** argv)
24 {
25  rclcpp::init(argc, argv);
26 
27  auto logger = rclcpp::get_logger("map_saver_server");
28  auto service_node = std::make_shared<nav2_map_server::MapSaver>();
29  rclcpp::spin(service_node->get_node_base_interface());
30  rclcpp::shutdown();
31  return 0;
32 }