Gazebo Transport

API Reference

13.4.0
CIface.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2019 Open Source Robotics Foundation
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 */
17 
18 #ifndef INCLUDE_GZ_TRANSPORT_CIFACE_H_
19 #define INCLUDE_GZ_TRANSPORT_CIFACE_H_
20 
21 #include "gz/transport/Export.hh"
22 
23 #ifdef __cplusplus
24 extern "C" {
25 #endif
26  typedef struct SubscribeOpts
27  {
28  // cppcheck-suppress unusedStructMember
29  unsigned int msgsPerSec;
31 
33  typedef struct GzTransportNode GzTransportNode;
34 
41  GzTransportNode GZ_TRANSPORT_VISIBLE *gzTransportNodeCreate(
42  const char *_partition);
43 
46  void GZ_TRANSPORT_VISIBLE
48 
54  int GZ_TRANSPORT_VISIBLE
56  const char *_topic,
57  const char *_msgType);
58 
59 
66  int GZ_TRANSPORT_VISIBLE
68  const char *_topic,
69  const void *_data,
70  const char *_msgType);
71 
78  int GZ_TRANSPORT_VISIBLE
80  const char *_topic,
81  void (*_callback)(const char *, size_t, const char *, void *),
82  void *_userData);
83 
91  int GZ_TRANSPORT_VISIBLE
93  const char *_topic, SubscribeOpts _opts,
94  void (*_callback)(const char *, size_t, const char *, void *),
95  void *_userData);
96 
103  int GZ_TRANSPORT_VISIBLE
105  void (*_callback)(char *, size_t, char *, void *),
106  void *_userData);
107 
112  int GZ_TRANSPORT_VISIBLE
113  gzTransportUnsubscribe(GzTransportNode *_node, const char *_topic);
114 
118  void GZ_TRANSPORT_VISIBLE gzTransportWaitForShutdown();
119 
120  const auto GZ_DEPRECATED(12) ignTransportNodeCreate = gzTransportNodeCreate;
121  const auto GZ_DEPRECATED(12) ignTransportNodeDestroy = gzTransportNodeDestroy;
122  const auto GZ_DEPRECATED(12) ignTransportAdvertise = gzTransportAdvertise;
123  const auto GZ_DEPRECATED(12) ignTransportPublish = gzTransportPublish;
124  const auto GZ_DEPRECATED(12) ignTransportSubscribe = gzTransportSubscribe;
125  const auto GZ_DEPRECATED(12) ignTransportSubscribeOptions = gzTransportSubscribeOptions;
126  const auto GZ_DEPRECATED(12) ignTransportSubscribeNonConst = gzTransportSubscribeNonConst;
127  const auto GZ_DEPRECATED(12) ignTransportUnsubscribe = gzTransportUnsubscribe;
128  const auto GZ_DEPRECATED(12) ignTransportWaitForShutdown = gzTransportWaitForShutdown;
129 
130 #ifdef __cplusplus
131 }
132 #endif
133 
134 // INCLUDE_GZ_TRANSPORT_CIFACE_H_
135 #endif