CARLA
 
载入中...
搜索中...
未找到
TF2Error.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 TF2Error.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_TF2_MSGS_MSG_TF2ERROR_H_
23#define _FAST_DDS_GENERATED_TF2_MSGS_MSG_TF2ERROR_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(TF2Error_SOURCE)
47#define TF2Error_DllAPI __declspec( dllexport )
48#else
49#define TF2Error_DllAPI __declspec( dllimport )
50#endif // TF2Error_SOURCE
51#else
52#define TF2Error_DllAPI
53#endif // EPROSIMA_USER_DLL_EXPORT
54#else
55#define TF2Error_DllAPI
56#endif // _WIN32
57
58namespace eprosima {
59namespace fastcdr {
60class Cdr;
61} // namespace fastcdr
62} // namespace eprosima
63
64
65namespace tf2_msgs {
66 namespace msg {
67 const uint8_t TF2Error__NO_ERROR = 0;
68 const uint8_t TF2Error__LOOKUP_ERROR = 1;
72 const uint8_t TF2Error__TIMEOUT_ERROR = 5;
73 const uint8_t TF2Error__TRANSFORM_ERROR = 6;
74 /*!
75 * @brief This class represents the structure TF2Error defined by the user in the IDL file.
76 * @ingroup TF2ERROR
77 */
79 {
80 public:
81
82 /*!
83 * @brief Default constructor.
84 */
86
87 /*!
88 * @brief Default destructor.
89 */
91
92 /*!
93 * @brief Copy constructor.
94 * @param x Reference to the object tf2_msgs::msg::TF2Error that will be copied.
95 */
97 const TF2Error& x);
98
99 /*!
100 * @brief Move constructor.
101 * @param x Reference to the object tf2_msgs::msg::TF2Error that will be copied.
102 */
104 TF2Error&& x) noexcept;
105
106 /*!
107 * @brief Copy assignment.
108 * @param x Reference to the object tf2_msgs::msg::TF2Error that will be copied.
109 */
111 const TF2Error& x);
112
113 /*!
114 * @brief Move assignment.
115 * @param x Reference to the object tf2_msgs::msg::TF2Error that will be copied.
116 */
118 TF2Error&& x) noexcept;
119
120 /*!
121 * @brief Comparison operator.
122 * @param x tf2_msgs::msg::TF2Error object to compare.
123 */
125 const TF2Error& x) const;
126
127 /*!
128 * @brief Comparison operator.
129 * @param x tf2_msgs::msg::TF2Error object to compare.
130 */
132 const TF2Error& x) const;
133
134 /*!
135 * @brief This function sets a value in member error
136 * @param _error New value for member error
137 */
139 uint8_t _error);
140
141 /*!
142 * @brief This function returns the value of member error
143 * @return Value of member error
144 */
145 eProsima_user_DllExport uint8_t error() const;
146
147 /*!
148 * @brief This function returns a reference to member error
149 * @return Reference to member error
150 */
152
153 /*!
154 * @brief This function copies the value in member error_string
155 * @param _error_string New value to be copied in member error_string
156 */
158 const std::string& _error_string);
159
160 /*!
161 * @brief This function moves the value in member error_string
162 * @param _error_string New value to be moved in member error_string
163 */
165 std::string&& _error_string);
166
167 /*!
168 * @brief This function returns a constant reference to member error_string
169 * @return Constant reference to member error_string
170 */
171 eProsima_user_DllExport const std::string& error_string() const;
172
173 /*!
174 * @brief This function returns a reference to member error_string
175 * @return Reference to member error_string
176 */
178
179 /*!
180 * @brief This function returns the maximum serialized size of an object
181 * depending on the buffer alignment.
182 * @param current_alignment Buffer alignment.
183 * @return Maximum serialized size.
184 */
186 size_t current_alignment = 0);
187
188 /*!
189 * @brief This function returns the serialized size of a data depending on the buffer alignment.
190 * @param data Data which is calculated its serialized size.
191 * @param current_alignment Buffer alignment.
192 * @return Serialized size.
193 */
195 const tf2_msgs::msg::TF2Error& data,
196 size_t current_alignment = 0);
197
198 /*!
199 * @brief This function serializes an object using CDR serialization.
200 * @param cdr CDR serialization object.
201 */
203 eprosima::fastcdr::Cdr& cdr) const;
204
205 /*!
206 * @brief This function deserializes an object using CDR serialization.
207 * @param cdr CDR serialization object.
208 */
210 eprosima::fastcdr::Cdr& cdr);
211
212 /*!
213 * @brief This function returns the maximum serialized size of the Key of an object
214 * depending on the buffer alignment.
215 * @param current_alignment Buffer alignment.
216 * @return Maximum serialized size.
217 */
219 size_t current_alignment = 0);
220
221 /*!
222 * @brief This function tells you if the Key has been defined for this type
223 */
225
226 /*!
227 * @brief This function serializes the key members of an object using CDR serialization.
228 * @param cdr CDR serialization object.
229 */
231 eprosima::fastcdr::Cdr& cdr) const;
232
233 private:
234 uint8_t m_error;
235 std::string m_error_string;
236 };
237 } // namespace msg
238} // namespace tf2_msgs
239
240#endif // _FAST_DDS_GENERATED_TF2_MSGS_MSG_TF2ERROR_H_
#define eProsima_user_DllExport
Definition CameraInfo.h:44
This class represents the structure TF2Error defined by the user in the IDL file.
Definition TF2Error.h:79
eProsima_user_DllExport bool operator!=(const TF2Error &x) const
Comparison operator.
Definition TF2Error.cpp:90
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.
Definition TF2Error.cpp:96
eProsima_user_DllExport TF2Error & operator=(const TF2Error &x)
Copy assignment.
Definition TF2Error.cpp:66
std::string m_error_string
Definition TF2Error.h:235
eProsima_user_DllExport ~TF2Error()
Default destructor.
Definition TF2Error.cpp:48
eProsima_user_DllExport bool operator==(const TF2Error &x) const
Comparison operator.
Definition TF2Error.cpp:84
eProsima_user_DllExport void deserialize(eprosima::fastcdr::Cdr &cdr)
This function deserializes an object using CDR serialization.
Definition TF2Error.cpp:121
eProsima_user_DllExport TF2Error()
Default constructor.
Definition TF2Error.cpp:40
eProsima_user_DllExport void serialize(eprosima::fastcdr::Cdr &cdr) const
This function serializes an object using CDR serialization.
Definition TF2Error.cpp:114
eProsima_user_DllExport uint8_t error() const
This function returns the value of member error
Definition TF2Error.cpp:142
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...
Definition TF2Error.cpp:195
eProsima_user_DllExport void serializeKey(eprosima::fastcdr::Cdr &cdr) const
This function serializes the key members of an object using CDR serialization.
Definition TF2Error.cpp:207
eProsima_user_DllExport const std::string & error_string() const
This function returns a constant reference to member error_string
Definition TF2Error.cpp:180
static eProsima_user_DllExport bool isKeyDefined()
This function tells you if the Key has been defined for this type
Definition TF2Error.cpp:202
static eProsima_user_DllExport size_t getCdrSerializedSize(const tf2_msgs::msg::TF2Error &data, size_t current_alignment=0)
This function returns the serialized size of a data depending on the buffer alignment.
Definition TF2Error.cpp:103
const uint8_t TF2Error__CONNECTIVITY_ERROR
Definition TF2Error.h:69
const uint8_t TF2Error__NO_ERROR
Definition TF2Error.h:67
const uint8_t TF2Error__TIMEOUT_ERROR
Definition TF2Error.h:72
const uint8_t TF2Error__LOOKUP_ERROR
Definition TF2Error.h:68
const uint8_t TF2Error__EXTRAPOLATION_ERROR
Definition TF2Error.h:70
const uint8_t TF2Error__TRANSFORM_ERROR
Definition TF2Error.h:73
const uint8_t TF2Error__INVALID_ARGUMENT_ERROR
Definition TF2Error.h:71