mrs_lib
Various reusable classes, functions and utilities for use in MRS projects
Loading...
Searching...
No Matches
service_server_handler.h
Go to the documentation of this file.
1
5#pragma once
6
7#include <rclcpp/rclcpp.hpp>
8
9namespace mrs_lib
10{
11
12 /* class ServiceServerHandler //{ */
13
17 template <class ServiceType>
19 {
20
21 public:
22
23 using callback_t = typename rclcpp::Service<ServiceType>::CallbackType;
24
36 ServiceServerHandler(rclcpp::Node::SharedPtr& node, const std::string& address, const callback_t& cbk, const rclcpp::QoS& qos = rclcpp::ServicesQoS());
37
45
56 ServiceServerHandler(rclcpp::Node::SharedPtr& node, const std::string& address, const callback_t& cbk, const rclcpp::QoS& qos, const rclcpp::CallbackGroup::SharedPtr& callback_group);
57
67 ServiceServerHandler(rclcpp::Node::SharedPtr& node, const std::string& address, const callback_t& cbk, const rclcpp::CallbackGroup::SharedPtr& callback_group);
68
69 private:
70 rclcpp::CallbackGroup::SharedPtr callback_group_;
71 typename rclcpp::Service<ServiceType>::SharedPtr service_server_;
72 };
73
74 //}
75
76} // namespace mrs_lib
77
user wrapper of the service client handler implementation
Definition service_server_handler.h:19
ServiceServerHandler()
Default constructor to avoid having to use pointers.
Definition service_server_handler.hpp:25
All mrs_lib functions, classes, variables and definitions are contained in this namespace.
Definition attitude_converter.h:24
Implements the ServiceServerHandler wrapper to ROS2's ServiceServer.