CARLA
 
载入中...
搜索中...
未找到
PointField.h
浏览该文件的文档.
1// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima).
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 * @file PointField.h
17 * This header file contains the declaration of the described types in the IDL file.
18 *
19 * This file was generated by the tool gen.
20 */
21
22#ifndef _FAST_DDS_GENERATED_SENSOR_MSGS_MSG_POINTFIELD_H_
23#define _FAST_DDS_GENERATED_SENSOR_MSGS_MSG_POINTFIELD_H_
24
25#include <fastrtps/utils/fixed_size_string.hpp>
26
27#include <stdint.h>
28#include <array>
29#include <string>
30#include <vector>
31#include <map>
32#include <bitset>
33
34#if defined(_WIN32)
35#if defined(EPROSIMA_USER_DLL_EXPORT)
36#define eProsima_user_DllExport __declspec( dllexport )
37#else
38#define eProsima_user_DllExport
39#endif // EPROSIMA_USER_DLL_EXPORT
40#else
41#define eProsima_user_DllExport
42#endif // _WIN32
43
44#if defined(_WIN32)
45#if defined(EPROSIMA_USER_DLL_EXPORT)
46#if defined(PointField_SOURCE)
47#define PointField_DllAPI __declspec( dllexport )
48#else
49#define PointField_DllAPI __declspec( dllimport )
50#endif // PointField_SOURCE
51#else
52#define PointField_DllAPI
53#endif // EPROSIMA_USER_DLL_EXPORT
54#else
55#define PointField_DllAPI
56#endif // _WIN32
57
58namespace eprosima {
59namespace fastcdr {
60class Cdr;
61} // namespace fastcdr
62} // namespace eprosima
63
64namespace sensor_msgs {
65 namespace msg {
66 const uint8_t PointField__INT8 = 1;
67 const uint8_t PointField__UINT8 = 2;
68 const uint8_t PointField__INT16 = 3;
69 const uint8_t PointField__UINT16 = 4;
70 const uint8_t PointField__INT32 = 5;
71 const uint8_t PointField__UINT32 = 6;
72 const uint8_t PointField__FLOAT32 = 7;
73 const uint8_t PointField__FLOAT64 = 8;
74
75 /*!
76 * @brief This class represents the structure PointField defined by the user in the IDL file.
77 * @ingroup POINTFIELD
78 */
80 {
81 public:
82
83 /*!
84 * @brief Default constructor.
85 */
87
88 /*!
89 * @brief Default destructor.
90 */
92
93 /*!
94 * @brief Copy constructor.
95 * @param x Reference to the object sensor_msgs::msg::PointField that will be copied.
96 */
98 const PointField& x);
99
100 /*!
101 * @brief Move constructor.
102 * @param x Reference to the object sensor_msgs::msg::PointField that will be copied.
103 */
105 PointField&& x) noexcept;
106
107 /*!
108 * @brief Copy assignment.
109 * @param x Reference to the object sensor_msgs::msg::PointField that will be copied.
110 */
112 const PointField& x);
113
114 /*!
115 * @brief Move assignment.
116 * @param x Reference to the object sensor_msgs::msg::PointField that will be copied.
117 */
119 PointField&& x) noexcept;
120
121 /*!
122 * @brief Comparison operator.
123 * @param x sensor_msgs::msg::PointField object to compare.
124 */
126 const PointField& x) const;
127
128 /*!
129 * @brief Comparison operator.
130 * @param x sensor_msgs::msg::PointField object to compare.
131 */
133 const PointField& x) const;
134
135 /*!
136 * @brief This function copies the value in member name
137 * @param _name New value to be copied in member name
138 */
140 const std::string& _name);
141
142 /*!
143 * @brief This function moves the value in member name
144 * @param _name New value to be moved in member name
145 */
147 std::string&& _name);
148
149 /*!
150 * @brief This function returns a constant reference to member name
151 * @return Constant reference to member name
152 */
153 eProsima_user_DllExport const std::string& name() const;
154
155 /*!
156 * @brief This function returns a reference to member name
157 * @return Reference to member name
158 */
159 eProsima_user_DllExport std::string& name();
160 /*!
161 * @brief This function sets a value in member offset
162 * @param _offset New value for member offset
163 */
165 uint32_t _offset);
166
167 /*!
168 * @brief This function returns the value of member offset
169 * @return Value of member offset
170 */
171 eProsima_user_DllExport uint32_t offset() const;
172
173 /*!
174 * @brief This function returns a reference to member offset
175 * @return Reference to member offset
176 */
178
179 /*!
180 * @brief This function sets a value in member datatype
181 * @param _datatype New value for member datatype
182 */
184 uint8_t _datatype);
185
186 /*!
187 * @brief This function returns the value of member datatype
188 * @return Value of member datatype
189 */
190 eProsima_user_DllExport uint8_t datatype() const;
191
192 /*!
193 * @brief This function returns a reference to member datatype
194 * @return Reference to member datatype
195 */
197
198 /*!
199 * @brief This function sets a value in member count
200 * @param _count New value for member count
201 */
203 uint32_t _count);
204
205 /*!
206 * @brief This function returns the value of member count
207 * @return Value of member count
208 */
209 eProsima_user_DllExport uint32_t count() const;
210
211 /*!
212 * @brief This function returns a reference to member count
213 * @return Reference to member count
214 */
215 eProsima_user_DllExport uint32_t& count();
216
217 /*!
218 * @brief This function returns the maximum serialized size of an object
219 * depending on the buffer alignment.
220 * @param current_alignment Buffer alignment.
221 * @return Maximum serialized size.
222 */
224 size_t current_alignment = 0);
225
226 /*!
227 * @brief This function returns the serialized size of a data depending on the buffer alignment.
228 * @param data Data which is calculated its serialized size.
229 * @param current_alignment Buffer alignment.
230 * @return Serialized size.
231 */
234 size_t current_alignment = 0);
235
236 /*!
237 * @brief This function serializes an object using CDR serialization.
238 * @param cdr CDR serialization object.
239 */
241 eprosima::fastcdr::Cdr& cdr) const;
242
243 /*!
244 * @brief This function deserializes an object using CDR serialization.
245 * @param cdr CDR serialization object.
246 */
248 eprosima::fastcdr::Cdr& cdr);
249
250 /*!
251 * @brief This function returns the maximum serialized size of the Key of an object
252 * depending on the buffer alignment.
253 * @param current_alignment Buffer alignment.
254 * @return Maximum serialized size.
255 */
257 size_t current_alignment = 0);
258
259 /*!
260 * @brief This function tells you if the Key has been defined for this type
261 */
263
264 /*!
265 * @brief This function serializes the key members of an object using CDR serialization.
266 * @param cdr CDR serialization object.
267 */
269 eprosima::fastcdr::Cdr& cdr) const;
270
271 private:
272 std::string m_name;
273 uint32_t m_offset;
274 uint8_t m_datatype;
275 uint32_t m_count;
276
277 };
278 } // namespace msg
279} // namespace sensor_msgs
280
281#endif // _FAST_DDS_GENERATED_SENSOR_MSGS_MSG_POINTFIELD_H_
#define eProsima_user_DllExport
Definition CameraInfo.h:44
This class represents the structure PointField defined by the user in the IDL file.
Definition PointField.h:80
eProsima_user_DllExport uint32_t offset() const
This function returns the value of member offset
static eProsima_user_DllExport bool isKeyDefined()
This function tells you if the Key has been defined for this type
eProsima_user_DllExport void deserialize(eprosima::fastcdr::Cdr &cdr)
This function deserializes an object using CDR serialization.
eProsima_user_DllExport PointField & operator=(const PointField &x)
Copy assignment.
static eProsima_user_DllExport size_t getKeyMaxCdrSerializedSize(size_t current_alignment=0)
This function returns the maximum serialized size of the Key of an object depending on the buffer ali...
eProsima_user_DllExport bool operator!=(const PointField &x) const
Comparison operator.
eProsima_user_DllExport uint32_t count() const
This function returns the value of member count
eProsima_user_DllExport PointField()
Default constructor.
static eProsima_user_DllExport size_t getMaxCdrSerializedSize(size_t current_alignment=0)
This function returns the maximum serialized size of an object depending on the buffer alignment.
static eProsima_user_DllExport size_t getCdrSerializedSize(const sensor_msgs::msg::PointField &data, size_t current_alignment=0)
This function returns the serialized size of a data depending on the buffer alignment.
eProsima_user_DllExport bool operator==(const PointField &x) const
Comparison operator.
eProsima_user_DllExport const std::string & name() const
This function returns a constant reference to member name
eProsima_user_DllExport uint8_t datatype() const
This function returns the value of member datatype
eProsima_user_DllExport ~PointField()
Default destructor.
eProsima_user_DllExport void serialize(eprosima::fastcdr::Cdr &cdr) const
This function serializes an object using CDR serialization.
eProsima_user_DllExport void serializeKey(eprosima::fastcdr::Cdr &cdr) const
This function serializes the key members of an object using CDR serialization.
const uint8_t PointField__FLOAT32
Definition PointField.h:72
const uint8_t PointField__UINT16
Definition PointField.h:69
const uint8_t PointField__INT32
Definition PointField.h:70
const uint8_t PointField__INT16
Definition PointField.h:68
const uint8_t PointField__INT8
Definition PointField.h:66
const uint8_t PointField__UINT32
Definition PointField.h:71
const uint8_t PointField__UINT8
Definition PointField.h:67
const uint8_t PointField__FLOAT64
Definition PointField.h:73