ROS 2 rclcpp + rcl - rolling  rolling-e7363f10
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 "rcutils/allocator.h"
28 
29 #include "rcl/macros.h"
30 #include "rcl/publisher.h"
31 #include "rcl/subscription.h"
32 #include "rcl/types.h"
33 #include "rcl/visibility_control.h"
34 
35 typedef rmw_network_flow_endpoint_t rcl_network_flow_endpoint_t;
36 typedef rmw_network_flow_endpoint_array_t rcl_network_flow_endpoint_array_t;
37 typedef rmw_transport_protocol_t rcl_transport_protocol_t;
38 typedef rmw_internet_protocol_t rcl_internet_protocol_t;
39 
40 #define rcl_get_zero_initialized_network_flow_endpoint_array \
41  rmw_get_zero_initialized_network_flow_endpoint_array
42 #define rcl_network_flow_endpoint_array_fini rmw_network_flow_endpoint_array_fini
43 
44 #define rcl_network_flow_endpoint_get_transport_protocol_string \
45  rmw_network_flow_endpoint_get_transport_protocol_string
46 #define rcl_network_flow_endpoint_get_internet_protocol_string \
47  rmw_network_flow_endpoint_get_internet_protocol_string
48 
50 
82 RCL_PUBLIC
83 RCL_WARN_UNUSED
85 rcl_publisher_get_network_flow_endpoints(
86  const rcl_publisher_t * publisher,
87  rcutils_allocator_t * allocator,
88  rcl_network_flow_endpoint_array_t * network_flow_endpoint_array);
89 
91 
123 RCL_PUBLIC
124 RCL_WARN_UNUSED
125 rcl_ret_t
126 rcl_subscription_get_network_flow_endpoints(
127  const rcl_subscription_t * subscription,
128  rcutils_allocator_t * allocator,
129  rcl_network_flow_endpoint_array_t * network_flow_endpoint_array);
130 
131 #ifdef __cplusplus
132 }
133 #endif
134 
135 #endif // RCL__NETWORK_FLOW_ENDPOINTS_H_
Structure which encapsulates a ROS Publisher.
Definition: publisher.h:44
Structure which encapsulates a ROS Subscription.
Definition: subscription.h:48
rmw_ret_t rcl_ret_t
The type that holds an rcl return code.
Definition: types.h:25