ROS 2 rclcpp + rcl - kilted  kilted
ROS 2 C++ Client Library with ROS Client Library
network_flow_endpoints.h
1 // Copyright 2020 Ericsson AB
2 //
3 // Licensed under the Apache License, Version 2.0 (the "License");
4 // you may not use this file except in compliance with the License.
5 // You may obtain a copy of the License at
6 //
7 // http://www.apache.org/licenses/LICENSE-2.0
8 //
9 // Unless required by applicable law or agreed to in writing, software
10 // distributed under the License is distributed on an "AS IS" BASIS,
11 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 // See the License for the specific language governing permissions and
13 // limitations under the License.
14 
15 
16 #ifndef RCL__NETWORK_FLOW_ENDPOINTS_H_
17 #define RCL__NETWORK_FLOW_ENDPOINTS_H_
18 
19 #ifdef __cplusplus
20 extern "C"
21 {
22 #endif
23 
24 #include <rmw/network_flow_endpoint.h>
25 #include <rmw/network_flow_endpoint_array.h>
26 
27 #include "rcl/allocator.h"
28 #include "rcl/arguments.h"
29 #include "rcl/context.h"
30 #include "rcl/macros.h"
31 #include "rcl/publisher.h"
32 #include "rcl/subscription.h"
33 #include "rcl/types.h"
34 #include "rcl/visibility_control.h"
35 
36 typedef rmw_network_flow_endpoint_t rcl_network_flow_endpoint_t;
37 typedef rmw_network_flow_endpoint_array_t rcl_network_flow_endpoint_array_t;
38 typedef rmw_transport_protocol_t rcl_transport_protocol_t;
39 typedef rmw_internet_protocol_t rcl_internet_protocol_t;
40 
41 #define rcl_get_zero_initialized_network_flow_endpoint_array \
42  rmw_get_zero_initialized_network_flow_endpoint_array
43 #define rcl_network_flow_endpoint_array_fini rmw_network_flow_endpoint_array_fini
44 
45 #define rcl_network_flow_endpoint_get_transport_protocol_string \
46  rmw_network_flow_endpoint_get_transport_protocol_string
47 #define rcl_network_flow_endpoint_get_internet_protocol_string \
48  rmw_network_flow_endpoint_get_internet_protocol_string
49 
51 
83 RCL_PUBLIC
84 RCL_WARN_UNUSED
86 rcl_publisher_get_network_flow_endpoints(
87  const rcl_publisher_t * publisher,
88  rcutils_allocator_t * allocator,
89  rcl_network_flow_endpoint_array_t * network_flow_endpoint_array);
90 
92 
124 RCL_PUBLIC
125 RCL_WARN_UNUSED
126 rcl_ret_t
127 rcl_subscription_get_network_flow_endpoints(
128  const rcl_subscription_t * subscription,
129  rcutils_allocator_t * allocator,
130  rcl_network_flow_endpoint_array_t * network_flow_endpoint_array);
131 
132 #ifdef __cplusplus
133 }
134 #endif
135 
136 #endif // RCL__NETWORK_FLOW_ENDPOINTS_H_
Structure which encapsulates a ROS Publisher.
Definition: publisher.h:37
Structure which encapsulates a ROS Subscription.
Definition: subscription.h:40
rmw_ret_t rcl_ret_t
The type that holds an rcl return code.
Definition: types.h:24