|
| 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 FlowControlPubSubTypes.h |
| 17 | + * This header file contains the declaration of the serialization functions. |
| 18 | + * |
| 19 | + * This file was generated by the tool fastddsgen. |
| 20 | + */ |
| 21 | + |
| 22 | + |
| 23 | +#ifndef _FAST_DDS_GENERATED_FLOWCONTROL_PUBSUBTYPES_H_ |
| 24 | +#define _FAST_DDS_GENERATED_FLOWCONTROL_PUBSUBTYPES_H_ |
| 25 | + |
| 26 | +#include <fastdds/dds/core/policy/QosPolicies.hpp> |
| 27 | +#include <fastdds/dds/topic/TopicDataType.hpp> |
| 28 | +#include <fastdds/rtps/common/InstanceHandle.h> |
| 29 | +#include <fastdds/rtps/common/SerializedPayload.h> |
| 30 | +#include <fastdds/utils/md5.h> |
| 31 | + |
| 32 | +#include "FlowControl.hpp" |
| 33 | + |
| 34 | + |
| 35 | +#if !defined(GEN_API_VER) || (GEN_API_VER != 2) |
| 36 | +#error \ |
| 37 | + Generated FlowControl is not compatible with current installed Fast DDS. Please, regenerate it with fastddsgen. |
| 38 | +#endif // GEN_API_VER |
| 39 | + |
| 40 | + |
| 41 | +/*! |
| 42 | + * @brief This class represents the TopicDataType of the type FlowControl defined by the user in the IDL file. |
| 43 | + * @ingroup FlowControl |
| 44 | + */ |
| 45 | +class FlowControlPubSubType : public eprosima::fastdds::dds::TopicDataType |
| 46 | +{ |
| 47 | +public: |
| 48 | + |
| 49 | + typedef FlowControl type; |
| 50 | + |
| 51 | + eProsima_user_DllExport FlowControlPubSubType(); |
| 52 | + |
| 53 | + eProsima_user_DllExport ~FlowControlPubSubType() override; |
| 54 | + |
| 55 | + eProsima_user_DllExport bool serialize( |
| 56 | + const void* const data, |
| 57 | + eprosima::fastdds::rtps::SerializedPayload_t* payload) override |
| 58 | + { |
| 59 | + return serialize(data, payload, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); |
| 60 | + } |
| 61 | + |
| 62 | + eProsima_user_DllExport bool serialize( |
| 63 | + const void* const data, |
| 64 | + eprosima::fastdds::rtps::SerializedPayload_t* payload, |
| 65 | + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; |
| 66 | + |
| 67 | + eProsima_user_DllExport bool deserialize( |
| 68 | + eprosima::fastdds::rtps::SerializedPayload_t* payload, |
| 69 | + void* data) override; |
| 70 | + |
| 71 | + eProsima_user_DllExport std::function<uint32_t()> getSerializedSizeProvider( |
| 72 | + const void* const data) override |
| 73 | + { |
| 74 | + return getSerializedSizeProvider(data, eprosima::fastdds::dds::DEFAULT_DATA_REPRESENTATION); |
| 75 | + } |
| 76 | + |
| 77 | + eProsima_user_DllExport std::function<uint32_t()> getSerializedSizeProvider( |
| 78 | + const void* const data, |
| 79 | + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; |
| 80 | + |
| 81 | + eProsima_user_DllExport bool getKey( |
| 82 | + const void* const data, |
| 83 | + eprosima::fastdds::rtps::InstanceHandle_t* ihandle, |
| 84 | + bool force_md5 = false) override; |
| 85 | + |
| 86 | + eProsima_user_DllExport void* createData() override; |
| 87 | + |
| 88 | + eProsima_user_DllExport void deleteData( |
| 89 | + void* data) override; |
| 90 | + |
| 91 | + //Register TypeObject representation in Fast DDS TypeObjectRegistry |
| 92 | + eProsima_user_DllExport void register_type_object_representation() override; |
| 93 | + |
| 94 | +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED |
| 95 | + eProsima_user_DllExport inline bool is_bounded() const override |
| 96 | + { |
| 97 | + return true; |
| 98 | + } |
| 99 | + |
| 100 | +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED |
| 101 | + |
| 102 | +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN |
| 103 | + eProsima_user_DllExport inline bool is_plain() const override |
| 104 | + { |
| 105 | + return false; |
| 106 | + } |
| 107 | + |
| 108 | + eProsima_user_DllExport inline bool is_plain( |
| 109 | + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override |
| 110 | + { |
| 111 | + static_cast<void>(data_representation); |
| 112 | + return false; |
| 113 | + } |
| 114 | + |
| 115 | +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN |
| 116 | + |
| 117 | +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE |
| 118 | + eProsima_user_DllExport inline bool construct_sample( |
| 119 | + void* memory) const override |
| 120 | + { |
| 121 | + static_cast<void>(memory); |
| 122 | + return false; |
| 123 | + } |
| 124 | + |
| 125 | +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE |
| 126 | + |
| 127 | + MD5 m_md5; |
| 128 | + unsigned char* m_keyBuffer; |
| 129 | + |
| 130 | +}; |
| 131 | + |
| 132 | +#endif // _FAST_DDS_GENERATED_FLOWCONTROL_PUBSUBTYPES_H_ |
| 133 | + |
0 commit comments