diff --git a/include/fastdds/dds/xtypes/type_representation/detail/dds_xtypes_typeobject.hpp b/include/fastdds/dds/xtypes/type_representation/detail/dds_xtypes_typeobject.hpp index 1600edbe905..622b5620e69 100644 --- a/include/fastdds/dds/xtypes/type_representation/detail/dds_xtypes_typeobject.hpp +++ b/include/fastdds/dds/xtypes/type_representation/detail/dds_xtypes_typeobject.hpp @@ -399,7 +399,11 @@ class TypeObjectHashId } selected_member_ = 0x00000001; - member_destructor_ = [&]() {m_hash.~EquivalenceHash();}; + member_destructor_ = [&]() + { + using namespace eprosima::fastdds::dds::xtypes; + m_hash.~EquivalenceHash(); + }; new(&m_hash) EquivalenceHash(); } @@ -2822,7 +2826,10 @@ class TypeIdentifier eProsima_user_DllExport TypeIdentifier() { selected_member_ = 0x00000001; - member_destructor_ = [&]() {m_no_value.~Dummy();}; + member_destructor_ = [&]() + { + m_no_value.~Dummy(); + }; new(&m_no_value) Dummy(); } @@ -3959,7 +3966,10 @@ class TypeIdentifier } selected_member_ = 0x00000001; - member_destructor_ = [&]() {m_no_value.~Dummy();}; + member_destructor_ = [&]() + { + m_no_value.~Dummy(); + }; new(&m_no_value) Dummy(); } @@ -3977,7 +3987,10 @@ class TypeIdentifier } selected_member_ = 0x00000002; - member_destructor_ = [&]() {m_string_sdefn.~StringSTypeDefn();}; + member_destructor_ = [&]() + { + m_string_sdefn.~StringSTypeDefn(); + }; new(&m_string_sdefn) StringSTypeDefn(); } @@ -3995,7 +4008,10 @@ class TypeIdentifier } selected_member_ = 0x00000003; - member_destructor_ = [&]() {m_string_ldefn.~StringLTypeDefn();}; + member_destructor_ = [&]() + { + m_string_ldefn.~StringLTypeDefn(); + }; new(&m_string_ldefn) StringLTypeDefn(); } @@ -4013,7 +4029,10 @@ class TypeIdentifier } selected_member_ = 0x00000004; - member_destructor_ = [&]() {m_seq_sdefn.~PlainSequenceSElemDefn();}; + member_destructor_ = [&]() + { + m_seq_sdefn.~PlainSequenceSElemDefn(); + }; new(&m_seq_sdefn) PlainSequenceSElemDefn(); } @@ -4031,7 +4050,10 @@ class TypeIdentifier } selected_member_ = 0x00000005; - member_destructor_ = [&]() {m_seq_ldefn.~PlainSequenceLElemDefn();}; + member_destructor_ = [&]() + { + m_seq_ldefn.~PlainSequenceLElemDefn(); + }; new(&m_seq_ldefn) PlainSequenceLElemDefn(); } @@ -4049,7 +4071,10 @@ class TypeIdentifier } selected_member_ = 0x00000006; - member_destructor_ = [&]() {m_array_sdefn.~PlainArraySElemDefn();}; + member_destructor_ = [&]() + { + m_array_sdefn.~PlainArraySElemDefn(); + }; new(&m_array_sdefn) PlainArraySElemDefn(); } @@ -4067,7 +4092,10 @@ class TypeIdentifier } selected_member_ = 0x00000007; - member_destructor_ = [&]() {m_array_ldefn.~PlainArrayLElemDefn();}; + member_destructor_ = [&]() + { + m_array_ldefn.~PlainArrayLElemDefn(); + }; new(&m_array_ldefn) PlainArrayLElemDefn(); } @@ -4085,7 +4113,10 @@ class TypeIdentifier } selected_member_ = 0x00000008; - member_destructor_ = [&]() {m_map_sdefn.~PlainMapSTypeDefn();}; + member_destructor_ = [&]() + { + m_map_sdefn.~PlainMapSTypeDefn(); + }; new(&m_map_sdefn) PlainMapSTypeDefn(); } @@ -4103,7 +4134,10 @@ class TypeIdentifier } selected_member_ = 0x00000009; - member_destructor_ = [&]() {m_map_ldefn.~PlainMapLTypeDefn();}; + member_destructor_ = [&]() + { + m_map_ldefn.~PlainMapLTypeDefn(); + }; new(&m_map_ldefn) PlainMapLTypeDefn(); } @@ -4121,7 +4155,10 @@ class TypeIdentifier } selected_member_ = 0x0000000a; - member_destructor_ = [&]() {m_sc_component_id.~StronglyConnectedComponentId();}; + member_destructor_ = [&]() + { + m_sc_component_id.~StronglyConnectedComponentId(); + }; new(&m_sc_component_id) StronglyConnectedComponentId(); } @@ -4139,7 +4176,11 @@ class TypeIdentifier } selected_member_ = 0x0000000b; - member_destructor_ = [&]() {m_equivalence_hash.~EquivalenceHash();}; + member_destructor_ = [&]() + { + using namespace eprosima::fastdds::dds::xtypes; + m_equivalence_hash.~EquivalenceHash(); + }; new(&m_equivalence_hash) EquivalenceHash(); } @@ -4157,7 +4198,10 @@ class TypeIdentifier } selected_member_ = 0x0000000c; - member_destructor_ = [&]() {m_extended_defn.~ExtendedTypeDefn();}; + member_destructor_ = [&]() + { + m_extended_defn.~ExtendedTypeDefn(); + }; new(&m_extended_defn) ExtendedTypeDefn(); } @@ -4303,7 +4347,10 @@ class AnnotationParameterValue eProsima_user_DllExport AnnotationParameterValue() { selected_member_ = 0x00000013; - member_destructor_ = [&]() {m_extended_value.~ExtendedAnnotationParameterValue();}; + member_destructor_ = [&]() + { + m_extended_value.~ExtendedAnnotationParameterValue(); + }; new(&m_extended_value) ExtendedAnnotationParameterValue(); } @@ -6094,7 +6141,10 @@ class AnnotationParameterValue } selected_member_ = 0x00000011; - member_destructor_ = [&]() {m_string8_value.~fixed_string();}; + member_destructor_ = [&]() + { + m_string8_value.~fixed_string(); + }; new(&m_string8_value) eprosima::fastcdr::fixed_string(); } @@ -6112,7 +6162,10 @@ class AnnotationParameterValue } selected_member_ = 0x00000012; - member_destructor_ = [&]() {m_string16_value.~basic_string();}; + member_destructor_ = [&]() + { + m_string16_value.~basic_string(); + }; new(&m_string16_value) std::wstring(); } @@ -6130,7 +6183,10 @@ class AnnotationParameterValue } selected_member_ = 0x00000013; - member_destructor_ = [&]() {m_extended_value.~ExtendedAnnotationParameterValue();}; + member_destructor_ = [&]() + { + m_extended_value.~ExtendedAnnotationParameterValue(); + }; new(&m_extended_value) ExtendedAnnotationParameterValue(); } @@ -20720,7 +20776,10 @@ class CompleteTypeObject eProsima_user_DllExport CompleteTypeObject() { selected_member_ = 0x0000000b; - member_destructor_ = [&]() {m_extended_type.~CompleteExtendedType();}; + member_destructor_ = [&]() + { + m_extended_type.~CompleteExtendedType(); + }; new(&m_extended_type) CompleteExtendedType(); } @@ -21759,7 +21818,10 @@ class CompleteTypeObject } selected_member_ = 0x00000001; - member_destructor_ = [&]() {m_alias_type.~CompleteAliasType();}; + member_destructor_ = [&]() + { + m_alias_type.~CompleteAliasType(); + }; new(&m_alias_type) CompleteAliasType(); } @@ -21777,7 +21839,10 @@ class CompleteTypeObject } selected_member_ = 0x00000002; - member_destructor_ = [&]() {m_annotation_type.~CompleteAnnotationType();}; + member_destructor_ = [&]() + { + m_annotation_type.~CompleteAnnotationType(); + }; new(&m_annotation_type) CompleteAnnotationType(); } @@ -21795,7 +21860,10 @@ class CompleteTypeObject } selected_member_ = 0x00000003; - member_destructor_ = [&]() {m_struct_type.~CompleteStructType();}; + member_destructor_ = [&]() + { + m_struct_type.~CompleteStructType(); + }; new(&m_struct_type) CompleteStructType(); } @@ -21813,7 +21881,10 @@ class CompleteTypeObject } selected_member_ = 0x00000004; - member_destructor_ = [&]() {m_union_type.~CompleteUnionType();}; + member_destructor_ = [&]() + { + m_union_type.~CompleteUnionType(); + }; new(&m_union_type) CompleteUnionType(); } @@ -21831,7 +21902,10 @@ class CompleteTypeObject } selected_member_ = 0x00000005; - member_destructor_ = [&]() {m_bitset_type.~CompleteBitsetType();}; + member_destructor_ = [&]() + { + m_bitset_type.~CompleteBitsetType(); + }; new(&m_bitset_type) CompleteBitsetType(); } @@ -21849,7 +21923,10 @@ class CompleteTypeObject } selected_member_ = 0x00000006; - member_destructor_ = [&]() {m_sequence_type.~CompleteSequenceType();}; + member_destructor_ = [&]() + { + m_sequence_type.~CompleteSequenceType(); + }; new(&m_sequence_type) CompleteSequenceType(); } @@ -21867,7 +21944,10 @@ class CompleteTypeObject } selected_member_ = 0x00000007; - member_destructor_ = [&]() {m_array_type.~CompleteArrayType();}; + member_destructor_ = [&]() + { + m_array_type.~CompleteArrayType(); + }; new(&m_array_type) CompleteArrayType(); } @@ -21885,7 +21965,10 @@ class CompleteTypeObject } selected_member_ = 0x00000008; - member_destructor_ = [&]() {m_map_type.~CompleteMapType();}; + member_destructor_ = [&]() + { + m_map_type.~CompleteMapType(); + }; new(&m_map_type) CompleteMapType(); } @@ -21903,7 +21986,10 @@ class CompleteTypeObject } selected_member_ = 0x00000009; - member_destructor_ = [&]() {m_enumerated_type.~CompleteEnumeratedType();}; + member_destructor_ = [&]() + { + m_enumerated_type.~CompleteEnumeratedType(); + }; new(&m_enumerated_type) CompleteEnumeratedType(); } @@ -21921,7 +22007,10 @@ class CompleteTypeObject } selected_member_ = 0x0000000a; - member_destructor_ = [&]() {m_bitmask_type.~CompleteBitmaskType();}; + member_destructor_ = [&]() + { + m_bitmask_type.~CompleteBitmaskType(); + }; new(&m_bitmask_type) CompleteBitmaskType(); } @@ -21939,7 +22028,10 @@ class CompleteTypeObject } selected_member_ = 0x0000000b; - member_destructor_ = [&]() {m_extended_type.~CompleteExtendedType();}; + member_destructor_ = [&]() + { + m_extended_type.~CompleteExtendedType(); + }; new(&m_extended_type) CompleteExtendedType(); } @@ -22078,7 +22170,10 @@ class MinimalTypeObject eProsima_user_DllExport MinimalTypeObject() { selected_member_ = 0x0000000b; - member_destructor_ = [&]() {m_extended_type.~MinimalExtendedType();}; + member_destructor_ = [&]() + { + m_extended_type.~MinimalExtendedType(); + }; new(&m_extended_type) MinimalExtendedType(); } @@ -23117,7 +23212,10 @@ class MinimalTypeObject } selected_member_ = 0x00000001; - member_destructor_ = [&]() {m_alias_type.~MinimalAliasType();}; + member_destructor_ = [&]() + { + m_alias_type.~MinimalAliasType(); + }; new(&m_alias_type) MinimalAliasType(); } @@ -23135,7 +23233,10 @@ class MinimalTypeObject } selected_member_ = 0x00000002; - member_destructor_ = [&]() {m_annotation_type.~MinimalAnnotationType();}; + member_destructor_ = [&]() + { + m_annotation_type.~MinimalAnnotationType(); + }; new(&m_annotation_type) MinimalAnnotationType(); } @@ -23153,7 +23254,10 @@ class MinimalTypeObject } selected_member_ = 0x00000003; - member_destructor_ = [&]() {m_struct_type.~MinimalStructType();}; + member_destructor_ = [&]() + { + m_struct_type.~MinimalStructType(); + }; new(&m_struct_type) MinimalStructType(); } @@ -23171,7 +23275,10 @@ class MinimalTypeObject } selected_member_ = 0x00000004; - member_destructor_ = [&]() {m_union_type.~MinimalUnionType();}; + member_destructor_ = [&]() + { + m_union_type.~MinimalUnionType(); + }; new(&m_union_type) MinimalUnionType(); } @@ -23189,7 +23296,10 @@ class MinimalTypeObject } selected_member_ = 0x00000005; - member_destructor_ = [&]() {m_bitset_type.~MinimalBitsetType();}; + member_destructor_ = [&]() + { + m_bitset_type.~MinimalBitsetType(); + }; new(&m_bitset_type) MinimalBitsetType(); } @@ -23207,7 +23317,10 @@ class MinimalTypeObject } selected_member_ = 0x00000006; - member_destructor_ = [&]() {m_sequence_type.~MinimalSequenceType();}; + member_destructor_ = [&]() + { + m_sequence_type.~MinimalSequenceType(); + }; new(&m_sequence_type) MinimalSequenceType(); } @@ -23225,7 +23338,10 @@ class MinimalTypeObject } selected_member_ = 0x00000007; - member_destructor_ = [&]() {m_array_type.~MinimalArrayType();}; + member_destructor_ = [&]() + { + m_array_type.~MinimalArrayType(); + }; new(&m_array_type) MinimalArrayType(); } @@ -23243,7 +23359,10 @@ class MinimalTypeObject } selected_member_ = 0x00000008; - member_destructor_ = [&]() {m_map_type.~MinimalMapType();}; + member_destructor_ = [&]() + { + m_map_type.~MinimalMapType(); + }; new(&m_map_type) MinimalMapType(); } @@ -23261,7 +23380,10 @@ class MinimalTypeObject } selected_member_ = 0x00000009; - member_destructor_ = [&]() {m_enumerated_type.~MinimalEnumeratedType();}; + member_destructor_ = [&]() + { + m_enumerated_type.~MinimalEnumeratedType(); + }; new(&m_enumerated_type) MinimalEnumeratedType(); } @@ -23279,7 +23401,10 @@ class MinimalTypeObject } selected_member_ = 0x0000000a; - member_destructor_ = [&]() {m_bitmask_type.~MinimalBitmaskType();}; + member_destructor_ = [&]() + { + m_bitmask_type.~MinimalBitmaskType(); + }; new(&m_bitmask_type) MinimalBitmaskType(); } @@ -23297,7 +23422,10 @@ class MinimalTypeObject } selected_member_ = 0x0000000b; - member_destructor_ = [&]() {m_extended_type.~MinimalExtendedType();}; + member_destructor_ = [&]() + { + m_extended_type.~MinimalExtendedType(); + }; new(&m_extended_type) MinimalExtendedType(); } @@ -23666,7 +23794,10 @@ class TypeObject } selected_member_ = 0x00000001; - member_destructor_ = [&]() {m_complete.~CompleteTypeObject();}; + member_destructor_ = [&]() + { + m_complete.~CompleteTypeObject(); + }; new(&m_complete) CompleteTypeObject(); } @@ -23684,7 +23815,10 @@ class TypeObject } selected_member_ = 0x00000002; - member_destructor_ = [&]() {m_minimal.~MinimalTypeObject();}; + member_destructor_ = [&]() + { + m_minimal.~MinimalTypeObject(); + }; new(&m_minimal) MinimalTypeObject(); } diff --git a/include/fastdds/dds/xtypes/type_representation/detail/dds_xtypes_typeobjectCdrAux.hpp b/include/fastdds/dds/xtypes/type_representation/detail/dds_xtypes_typeobjectCdrAux.hpp index 3e95d9f0a31..1b1113d7265 100644 --- a/include/fastdds/dds/xtypes/type_representation/detail/dds_xtypes_typeobjectCdrAux.hpp +++ b/include/fastdds/dds/xtypes/type_representation/detail/dds_xtypes_typeobjectCdrAux.hpp @@ -433,26 +433,18 @@ eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::Dummy& data); - - - - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::ExtendedAnnotationParameterValue& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::AppliedAnnotationParameter& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::AppliedAnnotation& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::AppliedVerbatimAnnotation& data); @@ -477,12 +469,10 @@ eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::CompleteStructMember& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::MinimalStructMember& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::AppliedBuiltinTypeAnnotations& data); @@ -511,7 +501,6 @@ eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::MinimalStructType& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::CommonUnionMember& data); @@ -520,12 +509,10 @@ eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::CompleteUnionMember& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::MinimalUnionMember& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::CommonDiscriminatorMember& data); @@ -562,12 +549,10 @@ eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::CompleteAnnotationParameter& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::MinimalAnnotationParameter& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::CompleteAnnotationHeader& data); @@ -676,7 +661,6 @@ eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::MinimalMapType& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::CommonEnumeratedLiteral& data); @@ -685,12 +669,10 @@ eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::CompleteEnumeratedLiteral& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::MinimalEnumeratedLiteral& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::CommonEnumeratedHeader& data); @@ -719,18 +701,14 @@ eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::CompleteBitflag& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::MinimalBitflag& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::CommonBitmaskHeader& data); - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::CompleteBitmaskType& data); @@ -747,12 +725,10 @@ eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::CompleteBitfield& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::MinimalBitfield& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::CompleteBitsetHeader& data); @@ -773,41 +749,31 @@ eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::CompleteExtendedType& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::MinimalExtendedType& data); - - - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::TypeIdentifierTypeObjectPair& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::TypeIdentifierPair& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::TypeIdentfierWithSize& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::TypeIdentifierWithDependencies& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::xtypes::TypeInformation& data); - } // namespace fastcdr } // namespace eprosima diff --git a/include/fastdds/dds/xtypes/type_representation/detail/dds_xtypes_typeobjectPubSubTypes.hpp b/include/fastdds/dds/xtypes/type_representation/detail/dds_xtypes_typeobjectPubSubTypes.hpp index 4ca6575f1b9..38388db53e3 100644 --- a/include/fastdds/dds/xtypes/type_representation/detail/dds_xtypes_typeobjectPubSubTypes.hpp +++ b/include/fastdds/dds/xtypes/type_representation/detail/dds_xtypes_typeobjectPubSubTypes.hpp @@ -48,65 +48,17 @@ namespace xtypes { typedef uint8_t EquivalenceKind; - - - typedef uint8_t TypeKind; - - - - - - - - - - - - - - - - - - - - - - - - - - - - typedef uint8_t TypeIdentiferKind; - - - - - - - - - - - - typedef eprosima::fastcdr::fixed_string MemberName; - typedef eprosima::fastcdr::fixed_string QualifiedTypeName; typedef uint8_t PrimitiveTypeId; typedef std::array EquivalenceHash; typedef std::array NameHash; typedef uint32_t LBound; typedef std::vector LBoundSeq; - typedef uint8_t SBound; typedef std::vector SBoundSeq; - - - typedef eprosima::fastdds::dds::xtypes::MemberFlag CollectionElementFlag; typedef eprosima::fastdds::dds::xtypes::MemberFlag StructMemberFlag; typedef eprosima::fastdds::dds::xtypes::MemberFlag UnionMemberFlag; @@ -116,8 +68,6 @@ typedef eprosima::fastdds::dds::xtypes::MemberFlag AnnotationParameterFlag; typedef eprosima::fastdds::dds::xtypes::MemberFlag AliasMemberFlag; typedef eprosima::fastdds::dds::xtypes::MemberFlag BitflagFlag; typedef eprosima::fastdds::dds::xtypes::MemberFlag BitsetMemberFlag; - - typedef eprosima::fastdds::dds::xtypes::TypeFlag StructTypeFlag; typedef eprosima::fastdds::dds::xtypes::TypeFlag UnionTypeFlag; typedef eprosima::fastdds::dds::xtypes::TypeFlag CollectionTypeFlag; @@ -127,8 +77,6 @@ typedef eprosima::fastdds::dds::xtypes::TypeFlag EnumTypeFlag; typedef eprosima::fastdds::dds::xtypes::TypeFlag BitmaskTypeFlag; typedef eprosima::fastdds::dds::xtypes::TypeFlag BitsetTypeFlag; - - #ifndef SWIG namespace detail { @@ -1225,12 +1173,9 @@ class DummyPubSubType : public eprosima::fastdds::dds::TopicDataType } }; - typedef std::vector TypeIdentifierSeq; typedef uint32_t MemberId; - - /*! * @brief This class represents the TopicDataType of the type ExtendedAnnotationParameterValue defined by the user in the IDL file. * @ingroup dds_xtypes_typeobject @@ -1312,7 +1257,6 @@ class ExtendedAnnotationParameterValuePubSubType : public eprosima::fastdds::dds }; - /*! * @brief This class represents the TopicDataType of the type AppliedAnnotationParameter defined by the user in the IDL file. * @ingroup dds_xtypes_typeobject @@ -7882,7 +7826,6 @@ class CompleteExtendedTypePubSubType : public eprosima::fastdds::dds::TopicDataT }; - /*! * @brief This class represents the TopicDataType of the type MinimalExtendedType defined by the user in the IDL file. * @ingroup dds_xtypes_typeobject @@ -7963,8 +7906,6 @@ class MinimalExtendedTypePubSubType : public eprosima::fastdds::dds::TopicDataTy unsigned char* key_buffer_; }; - - typedef std::vector TypeObjectSeq; typedef eprosima::fastdds::dds::xtypes::TypeObjectSeq StronglyConnectedComponent; diff --git a/src/cpp/fastdds/builtin/type_lookup_service/detail/TypeLookupTypes.hpp b/src/cpp/fastdds/builtin/type_lookup_service/detail/TypeLookupTypes.hpp index d7e6f778f1a..9c7f15a552b 100644 --- a/src/cpp/fastdds/builtin/type_lookup_service/detail/TypeLookupTypes.hpp +++ b/src/cpp/fastdds/builtin/type_lookup_service/detail/TypeLookupTypes.hpp @@ -640,7 +640,10 @@ class TypeLookup_getTypes_Result } selected_member_ = 0x00000001; - member_destructor_ = [&]() {m_result.~TypeLookup_getTypes_Out();}; + member_destructor_ = [&]() + { + m_result.~TypeLookup_getTypes_Out(); + }; new(&m_result) TypeLookup_getTypes_Out(); } @@ -1279,7 +1282,10 @@ class TypeLookup_getTypeDependencies_Result } selected_member_ = 0x00000001; - member_destructor_ = [&]() {m_result.~TypeLookup_getTypeDependencies_Out();}; + member_destructor_ = [&]() + { + m_result.~TypeLookup_getTypeDependencies_Out(); + }; new(&m_result) TypeLookup_getTypeDependencies_Out(); } @@ -1638,7 +1644,10 @@ class TypeLookup_Call } selected_member_ = 0x00000001; - member_destructor_ = [&]() {m_getTypes.~TypeLookup_getTypes_In();}; + member_destructor_ = [&]() + { + m_getTypes.~TypeLookup_getTypes_In(); + }; new(&m_getTypes) TypeLookup_getTypes_In(); } @@ -1656,7 +1665,10 @@ class TypeLookup_Call } selected_member_ = 0x00000002; - member_destructor_ = [&]() {m_getTypeDependencies.~TypeLookup_getTypeDependencies_In();}; + member_destructor_ = [&]() + { + m_getTypeDependencies.~TypeLookup_getTypeDependencies_In(); + }; new(&m_getTypeDependencies) TypeLookup_getTypeDependencies_In(); } @@ -2196,7 +2208,10 @@ class TypeLookup_Return } selected_member_ = 0x00000001; - member_destructor_ = [&]() {m_getType.~TypeLookup_getTypes_Result();}; + member_destructor_ = [&]() + { + m_getType.~TypeLookup_getTypes_Result(); + }; new(&m_getType) TypeLookup_getTypes_Result(); } @@ -2214,7 +2229,10 @@ class TypeLookup_Return } selected_member_ = 0x00000002; - member_destructor_ = [&]() {m_getTypeDependencies.~TypeLookup_getTypeDependencies_Result();}; + member_destructor_ = [&]() + { + m_getTypeDependencies.~TypeLookup_getTypeDependencies_Result(); + }; new(&m_getTypeDependencies) TypeLookup_getTypeDependencies_Result(); } diff --git a/src/cpp/fastdds/builtin/type_lookup_service/detail/TypeLookupTypesCdrAux.hpp b/src/cpp/fastdds/builtin/type_lookup_service/detail/TypeLookupTypesCdrAux.hpp index fff3b801356..452729bd490 100644 --- a/src/cpp/fastdds/builtin/type_lookup_service/detail/TypeLookupTypesCdrAux.hpp +++ b/src/cpp/fastdds/builtin/type_lookup_service/detail/TypeLookupTypesCdrAux.hpp @@ -180,7 +180,6 @@ eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::builtin::TypeLookup_getTypes_Out& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::builtin::TypeLookup_getTypeDependencies_In& data); @@ -189,13 +188,10 @@ eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::builtin::TypeLookup_getTypeDependencies_Out& data); - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::builtin::TypeLookup_Request& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::dds::builtin::TypeLookup_Reply& data); diff --git a/src/cpp/fastdds/builtin/type_lookup_service/detail/TypeLookupTypesPubSubTypes.cxx b/src/cpp/fastdds/builtin/type_lookup_service/detail/TypeLookupTypesPubSubTypes.cxx index dc0e8343ef3..d0bfd1d3ab1 100644 --- a/src/cpp/fastdds/builtin/type_lookup_service/detail/TypeLookupTypesPubSubTypes.cxx +++ b/src/cpp/fastdds/builtin/type_lookup_service/detail/TypeLookupTypesPubSubTypes.cxx @@ -401,7 +401,6 @@ namespace builtin { "TypeObject type representation support disabled in generated code"); } - TypeLookup_getTypeDependencies_InPubSubType::TypeLookup_getTypeDependencies_InPubSubType() { set_name("eprosima::fastdds::dds::builtin::TypeLookup_getTypeDependencies_In"); @@ -766,8 +765,6 @@ namespace builtin { "TypeObject type representation support disabled in generated code"); } - - TypeLookup_RequestPubSubType::TypeLookup_RequestPubSubType() { set_name("eprosima::fastdds::dds::builtin::TypeLookup_Request"); @@ -950,7 +947,6 @@ namespace builtin { "TypeObject type representation support disabled in generated code"); } - TypeLookup_ReplyPubSubType::TypeLookup_ReplyPubSubType() { set_name("eprosima::fastdds::dds::builtin::TypeLookup_Reply"); diff --git a/src/cpp/fastdds/builtin/type_lookup_service/detail/TypeLookupTypesPubSubTypes.hpp b/src/cpp/fastdds/builtin/type_lookup_service/detail/TypeLookupTypesPubSubTypes.hpp index 152db35ea63..46b1e3eee81 100644 --- a/src/cpp/fastdds/builtin/type_lookup_service/detail/TypeLookupTypesPubSubTypes.hpp +++ b/src/cpp/fastdds/builtin/type_lookup_service/detail/TypeLookupTypesPubSubTypes.hpp @@ -212,7 +212,6 @@ namespace builtin }; - /*! * @brief This class represents the TopicDataType of the type TypeLookup_getTypeDependencies_In defined by the user in the IDL file. * @ingroup TypeLookupTypes @@ -375,8 +374,6 @@ namespace builtin }; - - /*! * @brief This class represents the TopicDataType of the type TypeLookup_Request defined by the user in the IDL file. * @ingroup TypeLookupTypes @@ -458,7 +455,6 @@ namespace builtin }; - /*! * @brief This class represents the TopicDataType of the type TypeLookup_Reply defined by the user in the IDL file. * @ingroup TypeLookupTypes diff --git a/src/cpp/fastdds/builtin/type_lookup_service/detail/rpc_typesPubSubTypes.hpp b/src/cpp/fastdds/builtin/type_lookup_service/detail/rpc_typesPubSubTypes.hpp index 8d685a273cf..ad5a6e1d2d6 100644 --- a/src/cpp/fastdds/builtin/type_lookup_service/detail/rpc_typesPubSubTypes.hpp +++ b/src/cpp/fastdds/builtin/type_lookup_service/detail/rpc_typesPubSubTypes.hpp @@ -590,7 +590,6 @@ namespace rpc typedef uint8_t UnknownOperation; typedef uint8_t UnknownException; typedef uint8_t UnusedMember; - typedef eprosima::fastcdr::fixed_string<255> InstanceName; /*! diff --git a/src/cpp/fastdds/xtypes/type_representation/dds_xtypes_typeobjectCdrAux.ipp b/src/cpp/fastdds/xtypes/type_representation/dds_xtypes_typeobjectCdrAux.ipp index fa9d7637261..52f341d6e6f 100644 --- a/src/cpp/fastdds/xtypes/type_representation/dds_xtypes_typeobjectCdrAux.ipp +++ b/src/cpp/fastdds/xtypes/type_representation/dds_xtypes_typeobjectCdrAux.ipp @@ -153,28 +153,6 @@ eProsima_user_DllExport void deserialize( }); } - - - - - - - - - - - - - - - - - - - - - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, @@ -1818,10 +1796,6 @@ eProsima_user_DllExport void deserialize( }); } - - - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, @@ -2474,7 +2448,6 @@ void serialize_key( } - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, @@ -2574,7 +2547,6 @@ void serialize_key( } - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, @@ -3222,7 +3194,6 @@ void serialize_key( } - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, @@ -3327,7 +3298,6 @@ void serialize_key( } - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, @@ -4033,7 +4003,6 @@ void serialize_key( } - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, @@ -4254,7 +4223,6 @@ void serialize_key( } - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, @@ -4359,7 +4327,6 @@ void serialize_key( } - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, @@ -5305,7 +5272,6 @@ void serialize_key( } - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, @@ -5418,7 +5384,6 @@ void serialize_key( } - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, @@ -8168,7 +8133,6 @@ void serialize_key( } - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, @@ -8369,7 +8333,6 @@ void serialize_key( } - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, @@ -8474,7 +8437,6 @@ void serialize_key( } - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, @@ -9177,7 +9139,6 @@ void serialize_key( } - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, @@ -9282,7 +9243,6 @@ void serialize_key( } - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, @@ -9369,8 +9329,6 @@ void serialize_key( } - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, @@ -9803,7 +9761,6 @@ void serialize_key( } - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, @@ -9905,7 +9862,6 @@ void serialize_key( } - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, @@ -11202,8 +11158,6 @@ eProsima_user_DllExport void deserialize( }); } - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, @@ -11300,7 +11254,6 @@ void serialize_key( } - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, @@ -11397,7 +11350,6 @@ void serialize_key( } - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, @@ -11494,7 +11446,6 @@ void serialize_key( } - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, @@ -11607,7 +11558,6 @@ void serialize_key( } - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, @@ -11713,7 +11663,6 @@ void serialize_key( - } // namespace fastcdr } // namespace eprosima diff --git a/src/cpp/fastdds/xtypes/type_representation/dds_xtypes_typeobjectPubSubTypes.cxx b/src/cpp/fastdds/xtypes/type_representation/dds_xtypes_typeobjectPubSubTypes.cxx index 6d0d37f5ed2..0e4c791bbfd 100644 --- a/src/cpp/fastdds/xtypes/type_representation/dds_xtypes_typeobjectPubSubTypes.cxx +++ b/src/cpp/fastdds/xtypes/type_representation/dds_xtypes_typeobjectPubSubTypes.cxx @@ -2223,11 +2223,6 @@ void DummyPubSubType::register_type_object_representation() "TypeObject type representation support disabled in generated code"); } - - - - - ExtendedAnnotationParameterValuePubSubType::ExtendedAnnotationParameterValuePubSubType() { set_name("eprosima::fastdds::dds::xtypes::ExtendedAnnotationParameterValue"); @@ -2410,7 +2405,6 @@ void ExtendedAnnotationParameterValuePubSubType::register_type_object_representa "TypeObject type representation support disabled in generated code"); } - AppliedAnnotationParameterPubSubType::AppliedAnnotationParameterPubSubType() { set_name("eprosima::fastdds::dds::xtypes::AppliedAnnotationParameter"); @@ -2593,7 +2587,6 @@ void AppliedAnnotationParameterPubSubType::register_type_object_representation() "TypeObject type representation support disabled in generated code"); } - AppliedAnnotationPubSubType::AppliedAnnotationPubSubType() { set_name("eprosima::fastdds::dds::xtypes::AppliedAnnotation"); @@ -2776,7 +2769,6 @@ void AppliedAnnotationPubSubType::register_type_object_representation() "TypeObject type representation support disabled in generated code"); } - AppliedVerbatimAnnotationPubSubType::AppliedVerbatimAnnotationPubSubType() { set_name("eprosima::fastdds::dds::xtypes::AppliedVerbatimAnnotation"); @@ -3869,7 +3861,6 @@ void CompleteStructMemberPubSubType::register_type_object_representation() "TypeObject type representation support disabled in generated code"); } - MinimalStructMemberPubSubType::MinimalStructMemberPubSubType() { set_name("eprosima::fastdds::dds::xtypes::MinimalStructMember"); @@ -4052,7 +4043,6 @@ void MinimalStructMemberPubSubType::register_type_object_representation() "TypeObject type representation support disabled in generated code"); } - AppliedBuiltinTypeAnnotationsPubSubType::AppliedBuiltinTypeAnnotationsPubSubType() { set_name("eprosima::fastdds::dds::xtypes::AppliedBuiltinTypeAnnotations"); @@ -5327,7 +5317,6 @@ void MinimalStructTypePubSubType::register_type_object_representation() "TypeObject type representation support disabled in generated code"); } - CommonUnionMemberPubSubType::CommonUnionMemberPubSubType() { set_name("eprosima::fastdds::dds::xtypes::CommonUnionMember"); @@ -5692,7 +5681,6 @@ void CompleteUnionMemberPubSubType::register_type_object_representation() "TypeObject type representation support disabled in generated code"); } - MinimalUnionMemberPubSubType::MinimalUnionMemberPubSubType() { set_name("eprosima::fastdds::dds::xtypes::MinimalUnionMember"); @@ -5875,7 +5863,6 @@ void MinimalUnionMemberPubSubType::register_type_object_representation() "TypeObject type representation support disabled in generated code"); } - CommonDiscriminatorMemberPubSubType::CommonDiscriminatorMemberPubSubType() { set_name("eprosima::fastdds::dds::xtypes::CommonDiscriminatorMember"); @@ -7514,7 +7501,6 @@ void CompleteAnnotationParameterPubSubType::register_type_object_representation( "TypeObject type representation support disabled in generated code"); } - MinimalAnnotationParameterPubSubType::MinimalAnnotationParameterPubSubType() { set_name("eprosima::fastdds::dds::xtypes::MinimalAnnotationParameter"); @@ -7697,7 +7683,6 @@ void MinimalAnnotationParameterPubSubType::register_type_object_representation() "TypeObject type representation support disabled in generated code"); } - CompleteAnnotationHeaderPubSubType::CompleteAnnotationHeaderPubSubType() { set_name("eprosima::fastdds::dds::xtypes::CompleteAnnotationHeader"); @@ -12612,7 +12597,6 @@ void MinimalMapTypePubSubType::register_type_object_representation() "TypeObject type representation support disabled in generated code"); } - CommonEnumeratedLiteralPubSubType::CommonEnumeratedLiteralPubSubType() { set_name("eprosima::fastdds::dds::xtypes::CommonEnumeratedLiteral"); @@ -12977,7 +12961,6 @@ void CompleteEnumeratedLiteralPubSubType::register_type_object_representation() "TypeObject type representation support disabled in generated code"); } - MinimalEnumeratedLiteralPubSubType::MinimalEnumeratedLiteralPubSubType() { set_name("eprosima::fastdds::dds::xtypes::MinimalEnumeratedLiteral"); @@ -13160,7 +13143,6 @@ void MinimalEnumeratedLiteralPubSubType::register_type_object_representation() "TypeObject type representation support disabled in generated code"); } - CommonEnumeratedHeaderPubSubType::CommonEnumeratedHeaderPubSubType() { set_name("eprosima::fastdds::dds::xtypes::CommonEnumeratedHeader"); @@ -14435,7 +14417,6 @@ void CompleteBitflagPubSubType::register_type_object_representation() "TypeObject type representation support disabled in generated code"); } - MinimalBitflagPubSubType::MinimalBitflagPubSubType() { set_name("eprosima::fastdds::dds::xtypes::MinimalBitflag"); @@ -14618,7 +14599,6 @@ void MinimalBitflagPubSubType::register_type_object_representation() "TypeObject type representation support disabled in generated code"); } - CommonBitmaskHeaderPubSubType::CommonBitmaskHeaderPubSubType() { set_name("eprosima::fastdds::dds::xtypes::CommonBitmaskHeader"); @@ -14801,8 +14781,6 @@ void CommonBitmaskHeaderPubSubType::register_type_object_representation() "TypeObject type representation support disabled in generated code"); } - - CompleteBitmaskTypePubSubType::CompleteBitmaskTypePubSubType() { set_name("eprosima::fastdds::dds::xtypes::CompleteBitmaskType"); @@ -15531,7 +15509,6 @@ void CompleteBitfieldPubSubType::register_type_object_representation() "TypeObject type representation support disabled in generated code"); } - MinimalBitfieldPubSubType::MinimalBitfieldPubSubType() { set_name("eprosima::fastdds::dds::xtypes::MinimalBitfield"); @@ -15714,7 +15691,6 @@ void MinimalBitfieldPubSubType::register_type_object_representation() "TypeObject type representation support disabled in generated code"); } - CompleteBitsetHeaderPubSubType::CompleteBitsetHeaderPubSubType() { set_name("eprosima::fastdds::dds::xtypes::CompleteBitsetHeader"); @@ -16625,7 +16601,6 @@ void CompleteExtendedTypePubSubType::register_type_object_representation() "TypeObject type representation support disabled in generated code"); } - MinimalExtendedTypePubSubType::MinimalExtendedTypePubSubType() { set_name("eprosima::fastdds::dds::xtypes::MinimalExtendedType"); @@ -16808,10 +16783,6 @@ void MinimalExtendedTypePubSubType::register_type_object_representation() "TypeObject type representation support disabled in generated code"); } - - - - TypeIdentifierTypeObjectPairPubSubType::TypeIdentifierTypeObjectPairPubSubType() { set_name("eprosima::fastdds::dds::xtypes::TypeIdentifierTypeObjectPair"); @@ -16994,7 +16965,6 @@ void TypeIdentifierTypeObjectPairPubSubType::register_type_object_representation "TypeObject type representation support disabled in generated code"); } - TypeIdentifierPairPubSubType::TypeIdentifierPairPubSubType() { set_name("eprosima::fastdds::dds::xtypes::TypeIdentifierPair"); @@ -17177,7 +17147,6 @@ void TypeIdentifierPairPubSubType::register_type_object_representation() "TypeObject type representation support disabled in generated code"); } - TypeIdentfierWithSizePubSubType::TypeIdentfierWithSizePubSubType() { set_name("eprosima::fastdds::dds::xtypes::TypeIdentfierWithSize"); @@ -17360,7 +17329,6 @@ void TypeIdentfierWithSizePubSubType::register_type_object_representation() "TypeObject type representation support disabled in generated code"); } - TypeIdentifierWithDependenciesPubSubType::TypeIdentifierWithDependenciesPubSubType() { set_name("eprosima::fastdds::dds::xtypes::TypeIdentifierWithDependencies"); @@ -17543,7 +17511,6 @@ void TypeIdentifierWithDependenciesPubSubType::register_type_object_representati "TypeObject type representation support disabled in generated code"); } - TypeInformationPubSubType::TypeInformationPubSubType() { set_name("eprosima::fastdds::dds::xtypes::TypeInformation"); @@ -17727,7 +17694,6 @@ void TypeInformationPubSubType::register_type_object_representation() } - } // namespace xtypes diff --git a/src/cpp/statistics/types/monitorservice_types.hpp b/src/cpp/statistics/types/monitorservice_types.hpp index a3848e7d611..108be23e245 100644 --- a/src/cpp/statistics/types/monitorservice_types.hpp +++ b/src/cpp/statistics/types/monitorservice_types.hpp @@ -2114,7 +2114,10 @@ class MonitorServiceData } selected_member_ = 0x00000001; - member_destructor_ = [&]() {m_entity_proxy.~vector();}; + member_destructor_ = [&]() + { + m_entity_proxy.~vector(); + }; new(&m_entity_proxy) std::vector(); } @@ -2132,7 +2135,10 @@ class MonitorServiceData } selected_member_ = 0x00000002; - member_destructor_ = [&]() {m_connection_list.~vector();}; + member_destructor_ = [&]() + { + m_connection_list.~vector(); + }; new(&m_connection_list) std::vector(); } @@ -2150,7 +2156,10 @@ class MonitorServiceData } selected_member_ = 0x00000003; - member_destructor_ = [&]() {m_incompatible_qos_status.~IncompatibleQoSStatus_s();}; + member_destructor_ = [&]() + { + m_incompatible_qos_status.~IncompatibleQoSStatus_s(); + }; new(&m_incompatible_qos_status) IncompatibleQoSStatus_s(); } @@ -2168,7 +2177,11 @@ class MonitorServiceData } selected_member_ = 0x00000004; - member_destructor_ = [&]() {m_inconsistent_topic_status.~InconsistentTopicStatus_s();}; + member_destructor_ = [&]() + { + using namespace eprosima::fastdds::statistics; + m_inconsistent_topic_status.~InconsistentTopicStatus_s(); + }; new(&m_inconsistent_topic_status) InconsistentTopicStatus_s(); } @@ -2186,7 +2199,11 @@ class MonitorServiceData } selected_member_ = 0x00000005; - member_destructor_ = [&]() {m_liveliness_lost_status.~LivelinessLostStatus_s();}; + member_destructor_ = [&]() + { + using namespace eprosima::fastdds::statistics; + m_liveliness_lost_status.~LivelinessLostStatus_s(); + }; new(&m_liveliness_lost_status) LivelinessLostStatus_s(); } @@ -2204,7 +2221,10 @@ class MonitorServiceData } selected_member_ = 0x00000006; - member_destructor_ = [&]() {m_liveliness_changed_status.~LivelinessChangedStatus_s();}; + member_destructor_ = [&]() + { + m_liveliness_changed_status.~LivelinessChangedStatus_s(); + }; new(&m_liveliness_changed_status) LivelinessChangedStatus_s(); } @@ -2222,7 +2242,10 @@ class MonitorServiceData } selected_member_ = 0x00000007; - member_destructor_ = [&]() {m_deadline_missed_status.~DeadlineMissedStatus_s();}; + member_destructor_ = [&]() + { + m_deadline_missed_status.~DeadlineMissedStatus_s(); + }; new(&m_deadline_missed_status) DeadlineMissedStatus_s(); } @@ -2240,7 +2263,11 @@ class MonitorServiceData } selected_member_ = 0x00000008; - member_destructor_ = [&]() {m_sample_lost_status.~SampleLostStatus_s();}; + member_destructor_ = [&]() + { + using namespace eprosima::fastdds::statistics; + m_sample_lost_status.~SampleLostStatus_s(); + }; new(&m_sample_lost_status) SampleLostStatus_s(); } diff --git a/src/cpp/statistics/types/monitorservice_typesCdrAux.hpp b/src/cpp/statistics/types/monitorservice_typesCdrAux.hpp index 32c6ac80bb6..ae377fbd973 100644 --- a/src/cpp/statistics/types/monitorservice_typesCdrAux.hpp +++ b/src/cpp/statistics/types/monitorservice_typesCdrAux.hpp @@ -85,7 +85,6 @@ eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::statistics::BaseStatus_s& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::statistics::IncompatibleQoSStatus_s& data); @@ -98,11 +97,6 @@ eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::statistics::DeadlineMissedStatus_s& data); - - - - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::statistics::MonitorServiceStatusData& data); diff --git a/src/cpp/statistics/types/monitorservice_typesCdrAux.ipp b/src/cpp/statistics/types/monitorservice_typesCdrAux.ipp index 1ab16df87fd..2f14069c64c 100644 --- a/src/cpp/statistics/types/monitorservice_typesCdrAux.ipp +++ b/src/cpp/statistics/types/monitorservice_typesCdrAux.ipp @@ -338,7 +338,6 @@ void serialize_key( } - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, @@ -647,10 +646,6 @@ void serialize_key( } - - - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/src/cpp/statistics/types/monitorservice_typesPubSubTypes.cxx b/src/cpp/statistics/types/monitorservice_typesPubSubTypes.cxx index 1351597f57c..c6ee1832ded 100644 --- a/src/cpp/statistics/types/monitorservice_typesPubSubTypes.cxx +++ b/src/cpp/statistics/types/monitorservice_typesPubSubTypes.cxx @@ -577,7 +577,6 @@ namespace eprosima { register_BaseStatus_s_type_identifier(type_identifiers_); } - IncompatibleQoSStatus_sPubSubType::IncompatibleQoSStatus_sPubSubType() { set_name("eprosima::fastdds::statistics::IncompatibleQoSStatus_s"); @@ -1121,13 +1120,9 @@ namespace eprosima { register_DeadlineMissedStatus_s_type_identifier(type_identifiers_); } - - - namespace StatusKind { } // namespace StatusKind - MonitorServiceStatusDataPubSubType::MonitorServiceStatusDataPubSubType() { set_name("eprosima::fastdds::statistics::MonitorServiceStatusData"); diff --git a/src/cpp/statistics/types/monitorservice_typesPubSubTypes.hpp b/src/cpp/statistics/types/monitorservice_typesPubSubTypes.hpp index 5c62a2bba76..44eee1ea29f 100644 --- a/src/cpp/statistics/types/monitorservice_typesPubSubTypes.hpp +++ b/src/cpp/statistics/types/monitorservice_typesPubSubTypes.hpp @@ -537,18 +537,8 @@ namespace eprosima namespace StatusKind { typedef uint32_t StatusKind; - - - - - - - - - } // namespace StatusKind - /*! * @brief This class represents the TopicDataType of the type MonitorServiceStatusData defined by the user in the IDL file. * @ingroup monitorservice_types diff --git a/src/cpp/statistics/types/monitorservice_typesTypeObjectSupport.hpp b/src/cpp/statistics/types/monitorservice_typesTypeObjectSupport.hpp index 9d4484ba038..75350f992aa 100644 --- a/src/cpp/statistics/types/monitorservice_typesTypeObjectSupport.hpp +++ b/src/cpp/statistics/types/monitorservice_typesTypeObjectSupport.hpp @@ -208,15 +208,6 @@ eProsima_user_DllExport void register_StatusKind_type_identifier( - - - - - - - - - } // namespace StatusKind /** diff --git a/src/cpp/statistics/types/types.hpp b/src/cpp/statistics/types/types.hpp index 61d1e4b6a63..bc32cfdfba7 100644 --- a/src/cpp/statistics/types/types.hpp +++ b/src/cpp/statistics/types/types.hpp @@ -3774,7 +3774,10 @@ class Data } selected_member_ = 0x00000001; - member_destructor_ = [&]() {m_writer_reader_data.~WriterReaderData();}; + member_destructor_ = [&]() + { + m_writer_reader_data.~WriterReaderData(); + }; new(&m_writer_reader_data) WriterReaderData(); } @@ -3792,7 +3795,10 @@ class Data } selected_member_ = 0x00000002; - member_destructor_ = [&]() {m_locator2locator_data.~Locator2LocatorData();}; + member_destructor_ = [&]() + { + m_locator2locator_data.~Locator2LocatorData(); + }; new(&m_locator2locator_data) Locator2LocatorData(); } @@ -3810,7 +3816,10 @@ class Data } selected_member_ = 0x00000003; - member_destructor_ = [&]() {m_entity_data.~EntityData();}; + member_destructor_ = [&]() + { + m_entity_data.~EntityData(); + }; new(&m_entity_data) EntityData(); } @@ -3828,7 +3837,10 @@ class Data } selected_member_ = 0x00000004; - member_destructor_ = [&]() {m_entity2locator_traffic.~Entity2LocatorTraffic();}; + member_destructor_ = [&]() + { + m_entity2locator_traffic.~Entity2LocatorTraffic(); + }; new(&m_entity2locator_traffic) Entity2LocatorTraffic(); } @@ -3846,7 +3858,10 @@ class Data } selected_member_ = 0x00000005; - member_destructor_ = [&]() {m_entity_count.~EntityCount();}; + member_destructor_ = [&]() + { + m_entity_count.~EntityCount(); + }; new(&m_entity_count) EntityCount(); } @@ -3864,7 +3879,10 @@ class Data } selected_member_ = 0x00000006; - member_destructor_ = [&]() {m_discovery_time.~DiscoveryTime();}; + member_destructor_ = [&]() + { + m_discovery_time.~DiscoveryTime(); + }; new(&m_discovery_time) DiscoveryTime(); } @@ -3882,7 +3900,10 @@ class Data } selected_member_ = 0x00000007; - member_destructor_ = [&]() {m_sample_identity_count.~SampleIdentityCount();}; + member_destructor_ = [&]() + { + m_sample_identity_count.~SampleIdentityCount(); + }; new(&m_sample_identity_count) SampleIdentityCount(); } @@ -3900,7 +3921,10 @@ class Data } selected_member_ = 0x00000008; - member_destructor_ = [&]() {m_physical_data.~PhysicalData();}; + member_destructor_ = [&]() + { + m_physical_data.~PhysicalData(); + }; new(&m_physical_data) PhysicalData(); } diff --git a/src/cpp/statistics/types/typesCdrAux.hpp b/src/cpp/statistics/types/typesCdrAux.hpp index 8f393b28038..e2dd773d3ef 100644 --- a/src/cpp/statistics/types/typesCdrAux.hpp +++ b/src/cpp/statistics/types/typesCdrAux.hpp @@ -131,8 +131,6 @@ eProsima_user_DllExport void serialize_key( const eprosima::fastdds::statistics::PhysicalData& data); - - } // namespace fastcdr } // namespace eprosima diff --git a/src/cpp/statistics/types/typesCdrAux.ipp b/src/cpp/statistics/types/typesCdrAux.ipp index 1a6336bda94..a88d7f945c7 100644 --- a/src/cpp/statistics/types/typesCdrAux.ipp +++ b/src/cpp/statistics/types/typesCdrAux.ipp @@ -1542,7 +1542,6 @@ void serialize_key( } - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/src/cpp/statistics/types/typesPubSubTypes.cxx b/src/cpp/statistics/types/typesPubSubTypes.cxx index 0a285a7354c..5eac62c2f40 100644 --- a/src/cpp/statistics/types/typesPubSubTypes.cxx +++ b/src/cpp/statistics/types/typesPubSubTypes.cxx @@ -2574,7 +2574,6 @@ namespace eprosima { namespace EventKind { } // namespace EventKind - } // namespace statistics } // namespace fastdds diff --git a/src/cpp/statistics/types/typesPubSubTypes.hpp b/src/cpp/statistics/types/typesPubSubTypes.hpp index 3a7c7aa0ad6..5d95a2b6c73 100644 --- a/src/cpp/statistics/types/typesPubSubTypes.hpp +++ b/src/cpp/statistics/types/typesPubSubTypes.hpp @@ -1183,7 +1183,6 @@ namespace eprosima namespace EventKind { } // namespace EventKind - } // namespace statistics } // namespace fastdds } // namespace eprosima diff --git a/test/blackbox/types/core/core_types.hpp b/test/blackbox/types/core/core_types.hpp index c4512811876..ab16a5658d9 100644 --- a/test/blackbox/types/core/core_types.hpp +++ b/test/blackbox/types/core/core_types.hpp @@ -4103,7 +4103,10 @@ class Submessage eProsima_user_DllExport Submessage() { selected_member_ = 0x00000005; - member_destructor_ = [&]() {m_unknown_submsg.~SubmessageHeader();}; + member_destructor_ = [&]() + { + m_unknown_submsg.~SubmessageHeader(); + }; new(&m_unknown_submsg) SubmessageHeader(); } @@ -4662,7 +4665,10 @@ class Submessage } selected_member_ = 0x00000001; - member_destructor_ = [&]() {m_heartbeat_submsg.~HeartBeatSubmessage();}; + member_destructor_ = [&]() + { + m_heartbeat_submsg.~HeartBeatSubmessage(); + }; new(&m_heartbeat_submsg) HeartBeatSubmessage(); } @@ -4680,7 +4686,10 @@ class Submessage } selected_member_ = 0x00000002; - member_destructor_ = [&]() {m_info_ts_submsg.~InfoTimestampSubmessage();}; + member_destructor_ = [&]() + { + m_info_ts_submsg.~InfoTimestampSubmessage(); + }; new(&m_info_ts_submsg) InfoTimestampSubmessage(); } @@ -4698,7 +4707,10 @@ class Submessage } selected_member_ = 0x00000003; - member_destructor_ = [&]() {m_info_src_submsg.~InfoSourceSubmessage();}; + member_destructor_ = [&]() + { + m_info_src_submsg.~InfoSourceSubmessage(); + }; new(&m_info_src_submsg) InfoSourceSubmessage(); } @@ -4716,7 +4728,10 @@ class Submessage } selected_member_ = 0x00000004; - member_destructor_ = [&]() {m_info_dst_submsg.~InfoDestinationSubmessage();}; + member_destructor_ = [&]() + { + m_info_dst_submsg.~InfoDestinationSubmessage(); + }; new(&m_info_dst_submsg) InfoDestinationSubmessage(); } @@ -4734,7 +4749,10 @@ class Submessage } selected_member_ = 0x00000005; - member_destructor_ = [&]() {m_unknown_submsg.~SubmessageHeader();}; + member_destructor_ = [&]() + { + m_unknown_submsg.~SubmessageHeader(); + }; new(&m_unknown_submsg) SubmessageHeader(); } diff --git a/test/blackbox/types/core/core_typesCdrAux.hpp b/test/blackbox/types/core/core_typesCdrAux.hpp index c361c3987d7..17b0379e4db 100644 --- a/test/blackbox/types/core/core_typesCdrAux.hpp +++ b/test/blackbox/types/core/core_typesCdrAux.hpp @@ -133,7 +133,6 @@ eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::rtps::core::detail::Time_t& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::rtps::core::detail::SequenceNumberSet& data); @@ -146,8 +145,6 @@ eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::rtps::core::detail::Duration_t& data); - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::rtps::core::detail::StatusInfo_t& data); @@ -168,7 +165,6 @@ eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::rtps::core::SubmessageHeader& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::rtps::core::AckNackSubmessage& data); @@ -189,7 +185,6 @@ eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::rtps::core::InfoTimestampSubmessage& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::rtps::core::RTPSMessage& data); diff --git a/test/blackbox/types/core/core_typesCdrAux.ipp b/test/blackbox/types/core/core_typesCdrAux.ipp index 00cbe75317a..603dac576d9 100644 --- a/test/blackbox/types/core/core_typesCdrAux.ipp +++ b/test/blackbox/types/core/core_typesCdrAux.ipp @@ -770,7 +770,6 @@ void serialize_key( } - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, @@ -1085,8 +1084,6 @@ void serialize_key( } - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, @@ -1579,7 +1576,6 @@ void serialize_key( } - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/test/blackbox/types/core/core_typesPubSubTypes.cxx b/test/blackbox/types/core/core_typesPubSubTypes.cxx index b9d3fa3cc72..e33298324cf 100644 --- a/test/blackbox/types/core/core_typesPubSubTypes.cxx +++ b/test/blackbox/types/core/core_typesPubSubTypes.cxx @@ -1484,7 +1484,6 @@ namespace eprosima { register_Time_t_type_identifier(type_identifiers_); } - SequenceNumberSetPubSubType::SequenceNumberSetPubSubType() { set_name("eprosima::fastdds::rtps::core::detail::SequenceNumberSet"); @@ -2028,8 +2027,6 @@ namespace eprosima { register_Duration_t_type_identifier(type_identifiers_); } - - StatusInfo_tPubSubType::StatusInfo_tPubSubType() { set_name("eprosima::fastdds::rtps::core::detail::StatusInfo_t"); @@ -3845,7 +3842,6 @@ namespace eprosima { register_InfoTimestampSubmessage_type_identifier(type_identifiers_); } - RTPSMessagePubSubType::RTPSMessagePubSubType() { set_name("eprosima::fastdds::rtps::core::RTPSMessage"); diff --git a/test/blackbox/types/core/core_typesPubSubTypes.hpp b/test/blackbox/types/core/core_typesPubSubTypes.hpp index 10945b7926a..6005352c2b1 100644 --- a/test/blackbox/types/core/core_typesPubSubTypes.hpp +++ b/test/blackbox/types/core/core_typesPubSubTypes.hpp @@ -1756,7 +1756,6 @@ namespace eprosima }; - /*! * @brief This class represents the TopicDataType of the type RTPSMessage defined by the user in the IDL file. * @ingroup core_types diff --git a/test/blackbox/types/statistics/monitorservice_types.hpp b/test/blackbox/types/statistics/monitorservice_types.hpp index a3848e7d611..108be23e245 100644 --- a/test/blackbox/types/statistics/monitorservice_types.hpp +++ b/test/blackbox/types/statistics/monitorservice_types.hpp @@ -2114,7 +2114,10 @@ class MonitorServiceData } selected_member_ = 0x00000001; - member_destructor_ = [&]() {m_entity_proxy.~vector();}; + member_destructor_ = [&]() + { + m_entity_proxy.~vector(); + }; new(&m_entity_proxy) std::vector(); } @@ -2132,7 +2135,10 @@ class MonitorServiceData } selected_member_ = 0x00000002; - member_destructor_ = [&]() {m_connection_list.~vector();}; + member_destructor_ = [&]() + { + m_connection_list.~vector(); + }; new(&m_connection_list) std::vector(); } @@ -2150,7 +2156,10 @@ class MonitorServiceData } selected_member_ = 0x00000003; - member_destructor_ = [&]() {m_incompatible_qos_status.~IncompatibleQoSStatus_s();}; + member_destructor_ = [&]() + { + m_incompatible_qos_status.~IncompatibleQoSStatus_s(); + }; new(&m_incompatible_qos_status) IncompatibleQoSStatus_s(); } @@ -2168,7 +2177,11 @@ class MonitorServiceData } selected_member_ = 0x00000004; - member_destructor_ = [&]() {m_inconsistent_topic_status.~InconsistentTopicStatus_s();}; + member_destructor_ = [&]() + { + using namespace eprosima::fastdds::statistics; + m_inconsistent_topic_status.~InconsistentTopicStatus_s(); + }; new(&m_inconsistent_topic_status) InconsistentTopicStatus_s(); } @@ -2186,7 +2199,11 @@ class MonitorServiceData } selected_member_ = 0x00000005; - member_destructor_ = [&]() {m_liveliness_lost_status.~LivelinessLostStatus_s();}; + member_destructor_ = [&]() + { + using namespace eprosima::fastdds::statistics; + m_liveliness_lost_status.~LivelinessLostStatus_s(); + }; new(&m_liveliness_lost_status) LivelinessLostStatus_s(); } @@ -2204,7 +2221,10 @@ class MonitorServiceData } selected_member_ = 0x00000006; - member_destructor_ = [&]() {m_liveliness_changed_status.~LivelinessChangedStatus_s();}; + member_destructor_ = [&]() + { + m_liveliness_changed_status.~LivelinessChangedStatus_s(); + }; new(&m_liveliness_changed_status) LivelinessChangedStatus_s(); } @@ -2222,7 +2242,10 @@ class MonitorServiceData } selected_member_ = 0x00000007; - member_destructor_ = [&]() {m_deadline_missed_status.~DeadlineMissedStatus_s();}; + member_destructor_ = [&]() + { + m_deadline_missed_status.~DeadlineMissedStatus_s(); + }; new(&m_deadline_missed_status) DeadlineMissedStatus_s(); } @@ -2240,7 +2263,11 @@ class MonitorServiceData } selected_member_ = 0x00000008; - member_destructor_ = [&]() {m_sample_lost_status.~SampleLostStatus_s();}; + member_destructor_ = [&]() + { + using namespace eprosima::fastdds::statistics; + m_sample_lost_status.~SampleLostStatus_s(); + }; new(&m_sample_lost_status) SampleLostStatus_s(); } diff --git a/test/blackbox/types/statistics/monitorservice_typesCdrAux.hpp b/test/blackbox/types/statistics/monitorservice_typesCdrAux.hpp index 32c6ac80bb6..ae377fbd973 100644 --- a/test/blackbox/types/statistics/monitorservice_typesCdrAux.hpp +++ b/test/blackbox/types/statistics/monitorservice_typesCdrAux.hpp @@ -85,7 +85,6 @@ eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::statistics::BaseStatus_s& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::statistics::IncompatibleQoSStatus_s& data); @@ -98,11 +97,6 @@ eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::statistics::DeadlineMissedStatus_s& data); - - - - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const eprosima::fastdds::statistics::MonitorServiceStatusData& data); diff --git a/test/blackbox/types/statistics/monitorservice_typesCdrAux.ipp b/test/blackbox/types/statistics/monitorservice_typesCdrAux.ipp index 1ab16df87fd..2f14069c64c 100644 --- a/test/blackbox/types/statistics/monitorservice_typesCdrAux.ipp +++ b/test/blackbox/types/statistics/monitorservice_typesCdrAux.ipp @@ -338,7 +338,6 @@ void serialize_key( } - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, @@ -647,10 +646,6 @@ void serialize_key( } - - - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/test/blackbox/types/statistics/monitorservice_typesPubSubTypes.cxx b/test/blackbox/types/statistics/monitorservice_typesPubSubTypes.cxx index 1351597f57c..c6ee1832ded 100644 --- a/test/blackbox/types/statistics/monitorservice_typesPubSubTypes.cxx +++ b/test/blackbox/types/statistics/monitorservice_typesPubSubTypes.cxx @@ -577,7 +577,6 @@ namespace eprosima { register_BaseStatus_s_type_identifier(type_identifiers_); } - IncompatibleQoSStatus_sPubSubType::IncompatibleQoSStatus_sPubSubType() { set_name("eprosima::fastdds::statistics::IncompatibleQoSStatus_s"); @@ -1121,13 +1120,9 @@ namespace eprosima { register_DeadlineMissedStatus_s_type_identifier(type_identifiers_); } - - - namespace StatusKind { } // namespace StatusKind - MonitorServiceStatusDataPubSubType::MonitorServiceStatusDataPubSubType() { set_name("eprosima::fastdds::statistics::MonitorServiceStatusData"); diff --git a/test/blackbox/types/statistics/monitorservice_typesPubSubTypes.hpp b/test/blackbox/types/statistics/monitorservice_typesPubSubTypes.hpp index 5c62a2bba76..44eee1ea29f 100644 --- a/test/blackbox/types/statistics/monitorservice_typesPubSubTypes.hpp +++ b/test/blackbox/types/statistics/monitorservice_typesPubSubTypes.hpp @@ -537,18 +537,8 @@ namespace eprosima namespace StatusKind { typedef uint32_t StatusKind; - - - - - - - - - } // namespace StatusKind - /*! * @brief This class represents the TopicDataType of the type MonitorServiceStatusData defined by the user in the IDL file. * @ingroup monitorservice_types diff --git a/test/blackbox/types/statistics/monitorservice_typesTypeObjectSupport.hpp b/test/blackbox/types/statistics/monitorservice_typesTypeObjectSupport.hpp index 9d4484ba038..75350f992aa 100644 --- a/test/blackbox/types/statistics/monitorservice_typesTypeObjectSupport.hpp +++ b/test/blackbox/types/statistics/monitorservice_typesTypeObjectSupport.hpp @@ -208,15 +208,6 @@ eProsima_user_DllExport void register_StatusKind_type_identifier( - - - - - - - - - } // namespace StatusKind /** diff --git a/test/blackbox/types/statistics/types.hpp b/test/blackbox/types/statistics/types.hpp index 61d1e4b6a63..bc32cfdfba7 100644 --- a/test/blackbox/types/statistics/types.hpp +++ b/test/blackbox/types/statistics/types.hpp @@ -3774,7 +3774,10 @@ class Data } selected_member_ = 0x00000001; - member_destructor_ = [&]() {m_writer_reader_data.~WriterReaderData();}; + member_destructor_ = [&]() + { + m_writer_reader_data.~WriterReaderData(); + }; new(&m_writer_reader_data) WriterReaderData(); } @@ -3792,7 +3795,10 @@ class Data } selected_member_ = 0x00000002; - member_destructor_ = [&]() {m_locator2locator_data.~Locator2LocatorData();}; + member_destructor_ = [&]() + { + m_locator2locator_data.~Locator2LocatorData(); + }; new(&m_locator2locator_data) Locator2LocatorData(); } @@ -3810,7 +3816,10 @@ class Data } selected_member_ = 0x00000003; - member_destructor_ = [&]() {m_entity_data.~EntityData();}; + member_destructor_ = [&]() + { + m_entity_data.~EntityData(); + }; new(&m_entity_data) EntityData(); } @@ -3828,7 +3837,10 @@ class Data } selected_member_ = 0x00000004; - member_destructor_ = [&]() {m_entity2locator_traffic.~Entity2LocatorTraffic();}; + member_destructor_ = [&]() + { + m_entity2locator_traffic.~Entity2LocatorTraffic(); + }; new(&m_entity2locator_traffic) Entity2LocatorTraffic(); } @@ -3846,7 +3858,10 @@ class Data } selected_member_ = 0x00000005; - member_destructor_ = [&]() {m_entity_count.~EntityCount();}; + member_destructor_ = [&]() + { + m_entity_count.~EntityCount(); + }; new(&m_entity_count) EntityCount(); } @@ -3864,7 +3879,10 @@ class Data } selected_member_ = 0x00000006; - member_destructor_ = [&]() {m_discovery_time.~DiscoveryTime();}; + member_destructor_ = [&]() + { + m_discovery_time.~DiscoveryTime(); + }; new(&m_discovery_time) DiscoveryTime(); } @@ -3882,7 +3900,10 @@ class Data } selected_member_ = 0x00000007; - member_destructor_ = [&]() {m_sample_identity_count.~SampleIdentityCount();}; + member_destructor_ = [&]() + { + m_sample_identity_count.~SampleIdentityCount(); + }; new(&m_sample_identity_count) SampleIdentityCount(); } @@ -3900,7 +3921,10 @@ class Data } selected_member_ = 0x00000008; - member_destructor_ = [&]() {m_physical_data.~PhysicalData();}; + member_destructor_ = [&]() + { + m_physical_data.~PhysicalData(); + }; new(&m_physical_data) PhysicalData(); } diff --git a/test/blackbox/types/statistics/typesCdrAux.hpp b/test/blackbox/types/statistics/typesCdrAux.hpp index 8f393b28038..e2dd773d3ef 100644 --- a/test/blackbox/types/statistics/typesCdrAux.hpp +++ b/test/blackbox/types/statistics/typesCdrAux.hpp @@ -131,8 +131,6 @@ eProsima_user_DllExport void serialize_key( const eprosima::fastdds::statistics::PhysicalData& data); - - } // namespace fastcdr } // namespace eprosima diff --git a/test/blackbox/types/statistics/typesCdrAux.ipp b/test/blackbox/types/statistics/typesCdrAux.ipp index 1a6336bda94..a88d7f945c7 100644 --- a/test/blackbox/types/statistics/typesCdrAux.ipp +++ b/test/blackbox/types/statistics/typesCdrAux.ipp @@ -1542,7 +1542,6 @@ void serialize_key( } - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/test/blackbox/types/statistics/typesPubSubTypes.cxx b/test/blackbox/types/statistics/typesPubSubTypes.cxx index 0a285a7354c..5eac62c2f40 100644 --- a/test/blackbox/types/statistics/typesPubSubTypes.cxx +++ b/test/blackbox/types/statistics/typesPubSubTypes.cxx @@ -2574,7 +2574,6 @@ namespace eprosima { namespace EventKind { } // namespace EventKind - } // namespace statistics } // namespace fastdds diff --git a/test/blackbox/types/statistics/typesPubSubTypes.hpp b/test/blackbox/types/statistics/typesPubSubTypes.hpp index 3a7c7aa0ad6..5d95a2b6c73 100644 --- a/test/blackbox/types/statistics/typesPubSubTypes.hpp +++ b/test/blackbox/types/statistics/typesPubSubTypes.hpp @@ -1183,7 +1183,6 @@ namespace eprosima namespace EventKind { } // namespace EventKind - } // namespace statistics } // namespace fastdds } // namespace eprosima diff --git a/test/dds-types-test/annotations.hpp b/test/dds-types-test/annotations.hpp index bd172e1dc6f..d1dc7d61f4c 100644 --- a/test/dds-types-test/annotations.hpp +++ b/test/dds-types-test/annotations.hpp @@ -70,7 +70,6 @@ namespace AnnotationTest { } // namespace AnnotationTest - /*! * @brief This class represents the structure AnnotatedStruct defined by the user in the IDL file. * @ingroup annotations @@ -261,7 +260,6 @@ class EmptyAnnotatedStruct }; - /*! * @brief This class represents the structure BasicAnnotationsStruct defined by the user in the IDL file. * @ingroup annotations diff --git a/test/dds-types-test/annotationsCdrAux.hpp b/test/dds-types-test/annotationsCdrAux.hpp index dfa040a397d..b1819f200e1 100644 --- a/test/dds-types-test/annotationsCdrAux.hpp +++ b/test/dds-types-test/annotationsCdrAux.hpp @@ -63,7 +63,6 @@ eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const EmptyAnnotatedStruct& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const BasicAnnotationsStruct& data); diff --git a/test/dds-types-test/annotationsCdrAux.ipp b/test/dds-types-test/annotationsCdrAux.ipp index cd5f8c2f7e3..4a2f39293c2 100644 --- a/test/dds-types-test/annotationsCdrAux.ipp +++ b/test/dds-types-test/annotationsCdrAux.ipp @@ -164,7 +164,6 @@ void serialize_key( } - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/test/dds-types-test/annotationsPubSubTypes.cxx b/test/dds-types-test/annotationsPubSubTypes.cxx index fbc07585b37..2767ea989ff 100644 --- a/test/dds-types-test/annotationsPubSubTypes.cxx +++ b/test/dds-types-test/annotationsPubSubTypes.cxx @@ -393,7 +393,6 @@ void EmptyAnnotatedStructPubSubType::register_type_object_representation() register_EmptyAnnotatedStruct_type_identifier(type_identifiers_); } - BasicAnnotationsStructPubSubType::BasicAnnotationsStructPubSubType() { set_name("BasicAnnotationsStruct"); diff --git a/test/dds-types-test/annotationsPubSubTypes.hpp b/test/dds-types-test/annotationsPubSubTypes.hpp index 413d5a9a33c..bb44b1c0ebe 100644 --- a/test/dds-types-test/annotationsPubSubTypes.hpp +++ b/test/dds-types-test/annotationsPubSubTypes.hpp @@ -201,7 +201,6 @@ class EmptyAnnotatedStructPubSubType : public eprosima::fastdds::dds::TopicDataT }; - /*! * @brief This class represents the TopicDataType of the type BasicAnnotationsStruct defined by the user in the IDL file. * @ingroup annotations diff --git a/test/dds-types-test/arraysCdrAux.hpp b/test/dds-types-test/arraysCdrAux.hpp index 54b4733152d..b8c43166f56 100644 --- a/test/dds-types-test/arraysCdrAux.hpp +++ b/test/dds-types-test/arraysCdrAux.hpp @@ -568,8 +568,6 @@ eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const ArrayMultiDimensionBitset& data); - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const ArraySingleDimensionLiteralsShort& data); diff --git a/test/dds-types-test/arraysCdrAux.ipp b/test/dds-types-test/arraysCdrAux.ipp index 48eebe8c79d..9bbe829d482 100644 --- a/test/dds-types-test/arraysCdrAux.ipp +++ b/test/dds-types-test/arraysCdrAux.ipp @@ -4142,8 +4142,6 @@ void serialize_key( } - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/test/dds-types-test/arraysPubSubTypes.cxx b/test/dds-types-test/arraysPubSubTypes.cxx index 4343fc23546..cfc7709fcb3 100644 --- a/test/dds-types-test/arraysPubSubTypes.cxx +++ b/test/dds-types-test/arraysPubSubTypes.cxx @@ -9443,8 +9443,6 @@ void ArrayMultiDimensionBitsetPubSubType::register_type_object_representation() register_ArrayMultiDimensionBitset_type_identifier(type_identifiers_); } - - ArraySingleDimensionLiteralsShortPubSubType::ArraySingleDimensionLiteralsShortPubSubType() { set_name("ArraySingleDimensionLiteralsShort"); diff --git a/test/dds-types-test/arraysPubSubTypes.hpp b/test/dds-types-test/arraysPubSubTypes.hpp index 8c583976ee2..dc25b45d419 100644 --- a/test/dds-types-test/arraysPubSubTypes.hpp +++ b/test/dds-types-test/arraysPubSubTypes.hpp @@ -4251,8 +4251,6 @@ class ArrayMultiDimensionBitsetPubSubType : public eprosima::fastdds::dds::Topic }; - - /*! * @brief This class represents the TopicDataType of the type ArraySingleDimensionLiteralsShort defined by the user in the IDL file. * @ingroup arrays diff --git a/test/dds-types-test/constantsPubSubTypes.hpp b/test/dds-types-test/constantsPubSubTypes.hpp index c23af2163a8..18b4a30d1b0 100644 --- a/test/dds-types-test/constantsPubSubTypes.hpp +++ b/test/dds-types-test/constantsPubSubTypes.hpp @@ -39,13 +39,10 @@ #endif // FASTDDS_GEN_API_VER typedef int16_t alias_short; - - namespace const_module1 { typedef int16_t alias_short_moduled; - /*! * @brief This class represents the TopicDataType of the type ModuleConstsLiteralsStruct defined by the user in the IDL file. * @ingroup constants diff --git a/test/dds-types-test/constantsTypeObjectSupport.hpp b/test/dds-types-test/constantsTypeObjectSupport.hpp index 2b966f34fdb..80d44c6e68b 100644 --- a/test/dds-types-test/constantsTypeObjectSupport.hpp +++ b/test/dds-types-test/constantsTypeObjectSupport.hpp @@ -68,7 +68,6 @@ eProsima_user_DllExport void register_alias_short_moduled_type_identifier( - /** * @brief Register ModuleConstsLiteralsStruct related TypeIdentifier. * Fully-descriptive TypeIdentifiers are directly registered. diff --git a/test/dds-types-test/declarations.hpp b/test/dds-types-test/declarations.hpp index cc727057700..59bf6430b61 100644 --- a/test/dds-types-test/declarations.hpp +++ b/test/dds-types-test/declarations.hpp @@ -68,7 +68,6 @@ typedef std::vector RecursiveUnboundedSeqForwardUnion; typedef std::vector RecursiveBoundedSeqForwardUnion; - /*! * @brief This class represents the structure ForwardDeclarationsRecursiveStruct defined by the user in the IDL file. * @ingroup declarations diff --git a/test/dds-types-test/declarationsCdrAux.hpp b/test/dds-types-test/declarationsCdrAux.hpp index 2590c05308c..cb672f46ccc 100644 --- a/test/dds-types-test/declarationsCdrAux.hpp +++ b/test/dds-types-test/declarationsCdrAux.hpp @@ -60,7 +60,6 @@ eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const ForwardDeclarationsRecursiveStruct& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const ForwardStruct& data); @@ -77,8 +76,6 @@ eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const declarations_module::ModuledForwardStruct& data); - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const ModuledCommonNameStructure& data); diff --git a/test/dds-types-test/declarationsCdrAux.ipp b/test/dds-types-test/declarationsCdrAux.ipp index 9390d6dda79..e92e07a4aa6 100644 --- a/test/dds-types-test/declarationsCdrAux.ipp +++ b/test/dds-types-test/declarationsCdrAux.ipp @@ -653,7 +653,6 @@ void serialize_key( } - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/test/dds-types-test/declarationsPubSubTypes.cxx b/test/dds-types-test/declarationsPubSubTypes.cxx index 8835d319bd9..3fd9e94012a 100644 --- a/test/dds-types-test/declarationsPubSubTypes.cxx +++ b/test/dds-types-test/declarationsPubSubTypes.cxx @@ -211,7 +211,6 @@ void ForwardDeclarationsRecursiveStructPubSubType::register_type_object_represen "TypeObject type representation support disabled in generated code"); } - ForwardStructPubSubType::ForwardStructPubSubType() { set_name("ForwardStruct"); @@ -944,8 +943,6 @@ namespace declarations_module { "TypeObject type representation support disabled in generated code"); } - - } // namespace declarations_module ModuledCommonNameStructurePubSubType::ModuledCommonNameStructurePubSubType() diff --git a/test/dds-types-test/declarationsPubSubTypes.hpp b/test/dds-types-test/declarationsPubSubTypes.hpp index a3e57c0bc1b..13616bc7dc5 100644 --- a/test/dds-types-test/declarationsPubSubTypes.hpp +++ b/test/dds-types-test/declarationsPubSubTypes.hpp @@ -42,7 +42,6 @@ typedef std::vector RecursiveBoundedSeqForwardStruct; typedef std::vector RecursiveUnboundedSeqForwardUnion; typedef std::vector RecursiveBoundedSeqForwardUnion; - /*! * @brief This class represents the TopicDataType of the type ForwardDeclarationsRecursiveStruct defined by the user in the IDL file. * @ingroup declarations @@ -124,7 +123,6 @@ class ForwardDeclarationsRecursiveStructPubSubType : public eprosima::fastdds::d }; - /*! * @brief This class represents the TopicDataType of the type ForwardStruct defined by the user in the IDL file. * @ingroup declarations @@ -457,8 +455,6 @@ namespace declarations_module unsigned char* key_buffer_; }; - - } // namespace declarations_module /*! diff --git a/test/dds-types-test/enumerationsPubSubTypes.cxx b/test/dds-types-test/enumerationsPubSubTypes.cxx index 5e7e20b780b..2cec743f9af 100644 --- a/test/dds-types-test/enumerationsPubSubTypes.cxx +++ b/test/dds-types-test/enumerationsPubSubTypes.cxx @@ -34,7 +34,6 @@ using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; namespace Test { } // namespace Test - EnumStructurePubSubType::EnumStructurePubSubType() { set_name("EnumStructure"); diff --git a/test/dds-types-test/enumerationsPubSubTypes.hpp b/test/dds-types-test/enumerationsPubSubTypes.hpp index ac3f058018c..31785ea96d0 100644 --- a/test/dds-types-test/enumerationsPubSubTypes.hpp +++ b/test/dds-types-test/enumerationsPubSubTypes.hpp @@ -42,7 +42,6 @@ namespace Test { } // namespace Test - /*! * @brief This class represents the TopicDataType of the type EnumStructure defined by the user in the IDL file. * @ingroup enumerations diff --git a/test/dds-types-test/external.hpp b/test/dds-types-test/external.hpp index 7edaeda6ef3..8d9d588f9cb 100644 --- a/test/dds-types-test/external.hpp +++ b/test/dds-types-test/external.hpp @@ -3744,7 +3744,10 @@ class recursive_union } selected_member_ = 0x00000002; - member_destructor_ = [&]() {m_c.~recursive_union_container();}; + member_destructor_ = [&]() + { + m_c.~recursive_union_container(); + }; new(&m_c) recursive_union_container(); } @@ -4371,7 +4374,10 @@ class recursive_structure_container } selected_member_ = 0x00000002; - member_destructor_ = [&]() {m_ext.~external();}; + member_destructor_ = [&]() + { + m_ext.~external(); + }; new(&m_ext) eprosima::fastcdr::external(); } diff --git a/test/dds-types-test/externalCdrAux.hpp b/test/dds-types-test/externalCdrAux.hpp index c97303b7670..4b3e4f8c4db 100644 --- a/test/dds-types-test/externalCdrAux.hpp +++ b/test/dds-types-test/externalCdrAux.hpp @@ -220,18 +220,14 @@ eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const struct_external_optional& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const recursive_union_container& data); - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const recursive_test_1& data); - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const recursive_structure& data); diff --git a/test/dds-types-test/externalCdrAux.ipp b/test/dds-types-test/externalCdrAux.ipp index a25effd9e66..ac61ab3b970 100644 --- a/test/dds-types-test/externalCdrAux.ipp +++ b/test/dds-types-test/externalCdrAux.ipp @@ -1880,7 +1880,6 @@ void serialize_key( } - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, @@ -2210,7 +2209,6 @@ void serialize_key( } - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/test/dds-types-test/externalPubSubTypes.cxx b/test/dds-types-test/externalPubSubTypes.cxx index 837f538e136..8e173ff419f 100644 --- a/test/dds-types-test/externalPubSubTypes.cxx +++ b/test/dds-types-test/externalPubSubTypes.cxx @@ -4215,7 +4215,6 @@ void struct_external_optionalPubSubType::register_type_object_representation() "TypeObject type representation support disabled in generated code"); } - recursive_union_containerPubSubType::recursive_union_containerPubSubType() { set_name("recursive_union_container"); @@ -4398,7 +4397,6 @@ void recursive_union_containerPubSubType::register_type_object_representation() "TypeObject type representation support disabled in generated code"); } - recursive_test_1PubSubType::recursive_test_1PubSubType() { set_name("recursive_test_1"); @@ -4581,8 +4579,6 @@ void recursive_test_1PubSubType::register_type_object_representation() "TypeObject type representation support disabled in generated code"); } - - recursive_structurePubSubType::recursive_structurePubSubType() { set_name("recursive_structure"); diff --git a/test/dds-types-test/externalPubSubTypes.hpp b/test/dds-types-test/externalPubSubTypes.hpp index 95328b37a01..6c440e70d88 100644 --- a/test/dds-types-test/externalPubSubTypes.hpp +++ b/test/dds-types-test/externalPubSubTypes.hpp @@ -1902,7 +1902,6 @@ class struct_external_optionalPubSubType : public eprosima::fastdds::dds::TopicD }; - /*! * @brief This class represents the TopicDataType of the type recursive_union_container defined by the user in the IDL file. * @ingroup external @@ -1984,7 +1983,6 @@ class recursive_union_containerPubSubType : public eprosima::fastdds::dds::Topic }; - /*! * @brief This class represents the TopicDataType of the type recursive_test_1 defined by the user in the IDL file. * @ingroup external @@ -2066,8 +2064,6 @@ class recursive_test_1PubSubType : public eprosima::fastdds::dds::TopicDataType }; - - /*! * @brief This class represents the TopicDataType of the type recursive_structure defined by the user in the IDL file. * @ingroup external diff --git a/test/dds-types-test/helpers/basic_inner_typesCdrAux.hpp b/test/dds-types-test/helpers/basic_inner_typesCdrAux.hpp index d4bd5d62095..eed403e3203 100644 --- a/test/dds-types-test/helpers/basic_inner_typesCdrAux.hpp +++ b/test/dds-types-test/helpers/basic_inner_typesCdrAux.hpp @@ -59,18 +59,6 @@ eProsima_user_DllExport void serialize_key( const InnerEmptyStructureHelper& data); - - - - - - - - - - - - } // namespace fastcdr } // namespace eprosima diff --git a/test/dds-types-test/helpers/basic_inner_typesCdrAux.ipp b/test/dds-types-test/helpers/basic_inner_typesCdrAux.ipp index c4e34adf317..f9c2f87a086 100644 --- a/test/dds-types-test/helpers/basic_inner_typesCdrAux.ipp +++ b/test/dds-types-test/helpers/basic_inner_typesCdrAux.ipp @@ -393,16 +393,6 @@ eProsima_user_DllExport void deserialize( } - - - - - - - - - - } // namespace fastcdr } // namespace eprosima diff --git a/test/dds-types-test/helpers/basic_inner_typesPubSubTypes.cxx b/test/dds-types-test/helpers/basic_inner_typesPubSubTypes.cxx index 78a86e212e8..c2cebea5f2f 100644 --- a/test/dds-types-test/helpers/basic_inner_typesPubSubTypes.cxx +++ b/test/dds-types-test/helpers/basic_inner_typesPubSubTypes.cxx @@ -394,17 +394,5 @@ void InnerEmptyStructureHelperPubSubType::register_type_object_representation() } - - - - - - - - - - - - // Include auxiliary functions like for serializing/deserializing. #include "basic_inner_typesCdrAux.ipp" diff --git a/test/dds-types-test/helpers/basic_inner_typesPubSubTypes.hpp b/test/dds-types-test/helpers/basic_inner_typesPubSubTypes.hpp index 3a34f042fcc..17db366e887 100644 --- a/test/dds-types-test/helpers/basic_inner_typesPubSubTypes.hpp +++ b/test/dds-types-test/helpers/basic_inner_typesPubSubTypes.hpp @@ -200,9 +200,6 @@ class InnerEmptyStructureHelperPubSubType : public eprosima::fastdds::dds::Topic unsigned char* key_buffer_; }; - - - typedef eprosima::fastcdr::fixed_string<10> Inner_alias_bounded_string_helper; typedef std::wstring Inner_alias_bounded_wstring_helper; typedef std::array Inner_alias_array_helper; @@ -211,7 +208,5 @@ typedef std::map Inner_alias_map_helper; typedef InnerStructureHelper inner_structure_helper_alias; typedef InnerBitsetHelper inner_bitset_helper_alias; - - #endif // FAST_DDS_GENERATED__BASIC_INNER_TYPES_PUBSUBTYPES_HPP diff --git a/test/dds-types-test/inheritanceCdrAux.hpp b/test/dds-types-test/inheritanceCdrAux.hpp index a74bd263af3..57bac845bf4 100644 --- a/test/dds-types-test/inheritanceCdrAux.hpp +++ b/test/dds-types-test/inheritanceCdrAux.hpp @@ -100,9 +100,6 @@ eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const StructuresInheritanceStruct& data); - - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const BitsetsChildInheritanceStruct& data); diff --git a/test/dds-types-test/inheritancePubSubTypes.cxx b/test/dds-types-test/inheritancePubSubTypes.cxx index 56b7c160b93..6b79ba11412 100644 --- a/test/dds-types-test/inheritancePubSubTypes.cxx +++ b/test/dds-types-test/inheritancePubSubTypes.cxx @@ -1298,9 +1298,6 @@ void StructuresInheritanceStructPubSubType::register_type_object_representation( register_StructuresInheritanceStruct_type_identifier(type_identifiers_); } - - - BitsetsChildInheritanceStructPubSubType::BitsetsChildInheritanceStructPubSubType() { set_name("BitsetsChildInheritanceStruct"); diff --git a/test/dds-types-test/inheritancePubSubTypes.hpp b/test/dds-types-test/inheritancePubSubTypes.hpp index 5261daeadca..e3ee452fea6 100644 --- a/test/dds-types-test/inheritancePubSubTypes.hpp +++ b/test/dds-types-test/inheritancePubSubTypes.hpp @@ -606,9 +606,6 @@ class StructuresInheritanceStructPubSubType : public eprosima::fastdds::dds::Top }; - - - /*! * @brief This class represents the TopicDataType of the type BitsetsChildInheritanceStruct defined by the user in the IDL file. * @ingroup inheritance diff --git a/test/dds-types-test/unions.hpp b/test/dds-types-test/unions.hpp index 8165ed29359..9c155ff97c6 100644 --- a/test/dds-types-test/unions.hpp +++ b/test/dds-types-test/unions.hpp @@ -58,6 +58,12 @@ #define UNIONS_DllAPI #endif // _WIN32 +namespace Fixed_String_Module { + +typedef eprosima::fastcdr::fixed_string<20> fixed_string_in_module; + + +} // namespace Fixed_String_Module /*! * @brief This class represents the union Union_Short defined by the user in the IDL file. * @ingroup unions @@ -3801,7 +3807,10 @@ class Union_String } selected_member_ = 0x00000001; - member_destructor_ = [&]() {m_n.~basic_string();}; + member_destructor_ = [&]() + { + m_n.~basic_string(); + }; new(&m_n) std::string(); } @@ -4080,7 +4089,10 @@ class Union_WString } selected_member_ = 0x00000001; - member_destructor_ = [&]() {m_o.~basic_string();}; + member_destructor_ = [&]() + { + m_o.~basic_string(); + }; new(&m_o) std::wstring(); } @@ -4359,7 +4371,10 @@ class Union_BoundedString } selected_member_ = 0x00000001; - member_destructor_ = [&]() {m_bn.~Inner_alias_bounded_string_helper();}; + member_destructor_ = [&]() + { + m_bn.~Inner_alias_bounded_string_helper(); + }; new(&m_bn) Inner_alias_bounded_string_helper(); } @@ -4638,7 +4653,10 @@ class Union_BoundedWString } selected_member_ = 0x00000001; - member_destructor_ = [&]() {m_bo.~Inner_alias_bounded_wstring_helper();}; + member_destructor_ = [&]() + { + m_bo.~Inner_alias_bounded_wstring_helper(); + }; new(&m_bo) Inner_alias_bounded_wstring_helper(); } @@ -5185,7 +5203,10 @@ class Union_InnerBitMaskHelper } selected_member_ = 0x00000001; - member_destructor_ = [&]() {m_q.~InnerBitMaskHelper();}; + member_destructor_ = [&]() + { + m_q.~InnerBitMaskHelper(); + }; new(&m_q) InnerBitMaskHelper(); } @@ -5732,7 +5753,10 @@ class Union_Array } selected_member_ = 0x00000001; - member_destructor_ = [&]() {m_s.~Inner_alias_array_helper();}; + member_destructor_ = [&]() + { + m_s.~Inner_alias_array_helper(); + }; new(&m_s) Inner_alias_array_helper(); } @@ -6011,7 +6035,10 @@ class Union_Sequence } selected_member_ = 0x00000001; - member_destructor_ = [&]() {m_t.~vector();}; + member_destructor_ = [&]() + { + m_t.~vector(); + }; new(&m_t) std::vector(); } @@ -6290,7 +6317,10 @@ class Union_Map } selected_member_ = 0x00000001; - member_destructor_ = [&]() {m_u.~map();}; + member_destructor_ = [&]() + { + m_u.~map(); + }; new(&m_u) std::map(); } @@ -6569,7 +6599,10 @@ class Union_InnerUnionHelper } selected_member_ = 0x00000001; - member_destructor_ = [&]() {m_v.~InnerUnionHelper();}; + member_destructor_ = [&]() + { + m_v.~InnerUnionHelper(); + }; new(&m_v) InnerUnionHelper(); } @@ -6848,7 +6881,10 @@ class Union_InnerStructureHelper } selected_member_ = 0x00000001; - member_destructor_ = [&]() {m_w.~InnerStructureHelper();}; + member_destructor_ = [&]() + { + m_w.~InnerStructureHelper(); + }; new(&m_w) InnerStructureHelper(); } @@ -7127,7 +7163,10 @@ class Union_InnerBitsetHelper } selected_member_ = 0x00000001; - member_destructor_ = [&]() {m_x.~InnerBitsetHelper();}; + member_destructor_ = [&]() + { + m_x.~InnerBitsetHelper(); + }; new(&m_x) InnerBitsetHelper(); } @@ -12435,7 +12474,10 @@ class Union_Several_Fields } selected_member_ = 0x00000001; - member_destructor_ = [&]() {m_a.~InnerStructureHelper();}; + member_destructor_ = [&]() + { + m_a.~InnerStructureHelper(); + }; new(&m_a) InnerStructureHelper(); } @@ -12453,7 +12495,10 @@ class Union_Several_Fields } selected_member_ = 0x00000002; - member_destructor_ = [&]() {m_b.~InnerEmptyStructureHelper();}; + member_destructor_ = [&]() + { + m_b.~InnerEmptyStructureHelper(); + }; new(&m_b) InnerEmptyStructureHelper(); } @@ -12471,7 +12516,10 @@ class Union_Several_Fields } selected_member_ = 0x00000003; - member_destructor_ = [&]() {m_c.~Inner_alias_bounded_string_helper();}; + member_destructor_ = [&]() + { + m_c.~Inner_alias_bounded_string_helper(); + }; new(&m_c) Inner_alias_bounded_string_helper(); } @@ -12489,7 +12537,10 @@ class Union_Several_Fields } selected_member_ = 0x00000004; - member_destructor_ = [&]() {m_d.~Inner_alias_array_helper();}; + member_destructor_ = [&]() + { + m_d.~Inner_alias_array_helper(); + }; new(&m_d) Inner_alias_array_helper(); } @@ -12507,7 +12558,10 @@ class Union_Several_Fields } selected_member_ = 0x00000005; - member_destructor_ = [&]() {m_e.~Inner_alias_sequence_helper();}; + member_destructor_ = [&]() + { + m_e.~Inner_alias_sequence_helper(); + }; new(&m_e) Inner_alias_sequence_helper(); } @@ -12545,7 +12599,10 @@ class Union_Several_Fields_With_Default eProsima_user_DllExport Union_Several_Fields_With_Default() { selected_member_ = 0x00000006; - member_destructor_ = [&]() {m_f.~vector();}; + member_destructor_ = [&]() + { + m_f.~vector(); + }; new(&m_f) std::vector(); } @@ -13184,7 +13241,10 @@ class Union_Several_Fields_With_Default } selected_member_ = 0x00000001; - member_destructor_ = [&]() {m_a.~InnerStructureHelper();}; + member_destructor_ = [&]() + { + m_a.~InnerStructureHelper(); + }; new(&m_a) InnerStructureHelper(); } @@ -13202,7 +13262,10 @@ class Union_Several_Fields_With_Default } selected_member_ = 0x00000002; - member_destructor_ = [&]() {m_b.~InnerEmptyStructureHelper();}; + member_destructor_ = [&]() + { + m_b.~InnerEmptyStructureHelper(); + }; new(&m_b) InnerEmptyStructureHelper(); } @@ -13220,7 +13283,10 @@ class Union_Several_Fields_With_Default } selected_member_ = 0x00000003; - member_destructor_ = [&]() {m_c.~Inner_alias_bounded_string_helper();}; + member_destructor_ = [&]() + { + m_c.~Inner_alias_bounded_string_helper(); + }; new(&m_c) Inner_alias_bounded_string_helper(); } @@ -13238,7 +13304,10 @@ class Union_Several_Fields_With_Default } selected_member_ = 0x00000004; - member_destructor_ = [&]() {m_d.~Inner_alias_array_helper();}; + member_destructor_ = [&]() + { + m_d.~Inner_alias_array_helper(); + }; new(&m_d) Inner_alias_array_helper(); } @@ -13256,7 +13325,10 @@ class Union_Several_Fields_With_Default } selected_member_ = 0x00000005; - member_destructor_ = [&]() {m_e.~Inner_alias_sequence_helper();}; + member_destructor_ = [&]() + { + m_e.~Inner_alias_sequence_helper(); + }; new(&m_e) Inner_alias_sequence_helper(); } @@ -13274,7 +13346,10 @@ class Union_Several_Fields_With_Default } selected_member_ = 0x00000006; - member_destructor_ = [&]() {m_f.~vector();}; + member_destructor_ = [&]() + { + m_f.~vector(); + }; new(&m_f) std::vector(); } @@ -13299,6 +13374,289 @@ class Union_Several_Fields_With_Default std::function member_destructor_; }; +/*! + * @brief This class represents the union Union_Fixed_String_In_Module_Alias defined by the user in the IDL file. + * @ingroup unions + */ +class Union_Fixed_String_In_Module_Alias +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport Union_Fixed_String_In_Module_Alias() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~Union_Fixed_String_In_Module_Alias() + { + if (member_destructor_) + { + member_destructor_(); + } + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object Union_Fixed_String_In_Module_Alias that will be copied. + */ + eProsima_user_DllExport Union_Fixed_String_In_Module_Alias( + const Union_Fixed_String_In_Module_Alias& x) + { + m__d = x.m__d; + + switch (x.selected_member_) + { + case 0x00000001: + a_() = x.m_a; + break; + + } + } + + /*! + * @brief Move constructor. + * @param x Reference to the object Union_Fixed_String_In_Module_Alias that will be copied. + */ + eProsima_user_DllExport Union_Fixed_String_In_Module_Alias( + Union_Fixed_String_In_Module_Alias&& x) noexcept + { + m__d = x.m__d; + + switch (x.selected_member_) + { + case 0x00000001: + a_() = std::move(x.m_a); + break; + + } + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object Union_Fixed_String_In_Module_Alias that will be copied. + */ + eProsima_user_DllExport Union_Fixed_String_In_Module_Alias& operator =( + const Union_Fixed_String_In_Module_Alias& x) + { + m__d = x.m__d; + + switch (x.selected_member_) + { + case 0x00000001: + a_() = x.m_a; + break; + + } + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object Union_Fixed_String_In_Module_Alias that will be copied. + */ + eProsima_user_DllExport Union_Fixed_String_In_Module_Alias& operator =( + Union_Fixed_String_In_Module_Alias&& x) noexcept + { + m__d = x.m__d; + + switch (x.selected_member_) + { + case 0x00000001: + a_() = std::move(x.m_a); + break; + + } + + return *this; + } + + /*! + * @brief Comparison operator. + * @param x Union_Fixed_String_In_Module_Alias object to compare. + */ + eProsima_user_DllExport bool operator ==( + const Union_Fixed_String_In_Module_Alias& x) const + { + bool ret_value {false}; + + if (x.selected_member_ == selected_member_) + { + if (0x0FFFFFFFu != selected_member_) + { + if (x.m__d == m__d) + { + switch (selected_member_) + { + case 0x00000001: + ret_value = (x.m_a == m_a); + break; + + } + } + } + else + { + ret_value = true; + } + } + + return ret_value; + } + + /*! + * @brief Comparison operator. + * @param x Union_Fixed_String_In_Module_Alias object to compare. + */ + eProsima_user_DllExport bool operator !=( + const Union_Fixed_String_In_Module_Alias& x) const + { + return !(*this == x); + } + + /*! + * @brief This function sets the discriminator value. + * @param __d New value for the discriminator. + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the new value doesn't correspond to the selected union member. + */ + eProsima_user_DllExport void _d( + int32_t __d) + { + bool valid_discriminator = false; + + switch (__d) + { + case 0: + if (0x00000001 == selected_member_) + { + valid_discriminator = true; + } + break; + + } + + if (!valid_discriminator) + { + throw eprosima::fastcdr::exception::BadParamException("Discriminator doesn't correspond with the selected union member"); + } + + m__d = __d; + } + + /*! + * @brief This function returns the value of the discriminator. + * @return Value of the discriminator + */ + eProsima_user_DllExport int32_t _d() const + { + return m__d; + } + + /*! + * @brief This function copies the value in member a + * @param _a New value to be copied in member a + */ + eProsima_user_DllExport void a( + const Fixed_String_Module::fixed_string_in_module& _a) + { + a_() = _a; + m__d = 0; + } + + /*! + * @brief This function moves the value in member a + * @param _a New value to be moved in member a + */ + eProsima_user_DllExport void a( + Fixed_String_Module::fixed_string_in_module&& _a) + { + a_() = _a; + m__d = 0; + } + + /*! + * @brief This function returns a constant reference to member a + * @return Constant reference to member a + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport const Fixed_String_Module::fixed_string_in_module& a() const + { + if (0x00000001 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_a; + } + + /*! + * @brief This function returns a reference to member a + * @return Reference to member a + * @exception eprosima::fastcdr::exception::BadParamException This exception is thrown if the requested union member is not the current selection. + */ + eProsima_user_DllExport Fixed_String_Module::fixed_string_in_module& a() + { + if (0x00000001 != selected_member_) + { + throw eprosima::fastcdr::exception::BadParamException("This member has not been selected"); + } + + return m_a; + } + + + void _default() + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x0FFFFFFFu; + } + + +private: + + Fixed_String_Module::fixed_string_in_module& a_() + { + if (0x00000001 != selected_member_) + { + if (member_destructor_) + { + member_destructor_(); + } + + selected_member_ = 0x00000001; + member_destructor_ = [&]() + { + using namespace Fixed_String_Module; + m_a.~fixed_string_in_module(); + }; + new(&m_a) Fixed_String_Module::fixed_string_in_module(); + + } + + return m_a; + } + + + int32_t m__d {2147483647}; + + union + { + Fixed_String_Module::fixed_string_in_module m_a; + }; + + uint32_t selected_member_ {0x0FFFFFFFu}; + + std::function member_destructor_; +}; /*! * @brief This class represents the structure UnionShort defined by the user in the IDL file. * @ingroup unions @@ -19715,6 +20073,139 @@ class UnionShortExtraMember Union_Short m_var_union_short; int32_t m_var_long{0}; +}; +/*! + * @brief This class represents the structure UnionFixedStringAlias defined by the user in the IDL file. + * @ingroup unions + */ +class UnionFixedStringAlias +{ +public: + + /*! + * @brief Default constructor. + */ + eProsima_user_DllExport UnionFixedStringAlias() + { + } + + /*! + * @brief Default destructor. + */ + eProsima_user_DllExport ~UnionFixedStringAlias() + { + } + + /*! + * @brief Copy constructor. + * @param x Reference to the object UnionFixedStringAlias that will be copied. + */ + eProsima_user_DllExport UnionFixedStringAlias( + const UnionFixedStringAlias& x) + { + m_var_union_fixed_string_in_module_alias = x.m_var_union_fixed_string_in_module_alias; + + } + + /*! + * @brief Move constructor. + * @param x Reference to the object UnionFixedStringAlias that will be copied. + */ + eProsima_user_DllExport UnionFixedStringAlias( + UnionFixedStringAlias&& x) noexcept + { + m_var_union_fixed_string_in_module_alias = std::move(x.m_var_union_fixed_string_in_module_alias); + } + + /*! + * @brief Copy assignment. + * @param x Reference to the object UnionFixedStringAlias that will be copied. + */ + eProsima_user_DllExport UnionFixedStringAlias& operator =( + const UnionFixedStringAlias& x) + { + + m_var_union_fixed_string_in_module_alias = x.m_var_union_fixed_string_in_module_alias; + + return *this; + } + + /*! + * @brief Move assignment. + * @param x Reference to the object UnionFixedStringAlias that will be copied. + */ + eProsima_user_DllExport UnionFixedStringAlias& operator =( + UnionFixedStringAlias&& x) noexcept + { + + m_var_union_fixed_string_in_module_alias = std::move(x.m_var_union_fixed_string_in_module_alias); + return *this; + } + + /*! + * @brief Comparison operator. + * @param x UnionFixedStringAlias object to compare. + */ + eProsima_user_DllExport bool operator ==( + const UnionFixedStringAlias& x) const + { + return (m_var_union_fixed_string_in_module_alias == x.m_var_union_fixed_string_in_module_alias); + } + + /*! + * @brief Comparison operator. + * @param x UnionFixedStringAlias object to compare. + */ + eProsima_user_DllExport bool operator !=( + const UnionFixedStringAlias& x) const + { + return !(*this == x); + } + + /*! + * @brief This function copies the value in member var_union_fixed_string_in_module_alias + * @param _var_union_fixed_string_in_module_alias New value to be copied in member var_union_fixed_string_in_module_alias + */ + eProsima_user_DllExport void var_union_fixed_string_in_module_alias( + const Union_Fixed_String_In_Module_Alias& _var_union_fixed_string_in_module_alias) + { + m_var_union_fixed_string_in_module_alias = _var_union_fixed_string_in_module_alias; + } + + /*! + * @brief This function moves the value in member var_union_fixed_string_in_module_alias + * @param _var_union_fixed_string_in_module_alias New value to be moved in member var_union_fixed_string_in_module_alias + */ + eProsima_user_DllExport void var_union_fixed_string_in_module_alias( + Union_Fixed_String_In_Module_Alias&& _var_union_fixed_string_in_module_alias) + { + m_var_union_fixed_string_in_module_alias = std::move(_var_union_fixed_string_in_module_alias); + } + + /*! + * @brief This function returns a constant reference to member var_union_fixed_string_in_module_alias + * @return Constant reference to member var_union_fixed_string_in_module_alias + */ + eProsima_user_DllExport const Union_Fixed_String_In_Module_Alias& var_union_fixed_string_in_module_alias() const + { + return m_var_union_fixed_string_in_module_alias; + } + + /*! + * @brief This function returns a reference to member var_union_fixed_string_in_module_alias + * @return Reference to member var_union_fixed_string_in_module_alias + */ + eProsima_user_DllExport Union_Fixed_String_In_Module_Alias& var_union_fixed_string_in_module_alias() + { + return m_var_union_fixed_string_in_module_alias; + } + + + +private: + + Union_Fixed_String_In_Module_Alias m_var_union_fixed_string_in_module_alias; + }; #endif // _FAST_DDS_GENERATED_UNIONS_HPP_ diff --git a/test/dds-types-test/unionsCdrAux.hpp b/test/dds-types-test/unionsCdrAux.hpp index 97080a482b5..ee79c81beb2 100644 --- a/test/dds-types-test/unionsCdrAux.hpp +++ b/test/dds-types-test/unionsCdrAux.hpp @@ -97,6 +97,9 @@ constexpr uint32_t UnionInnerAliasHelper_max_cdr_typesize {16UL}; constexpr uint32_t UnionInnerAliasHelper_max_key_cdr_typesize {0UL}; +constexpr uint32_t UnionFixedStringAlias_max_cdr_typesize {37UL}; +constexpr uint32_t UnionFixedStringAlias_max_key_cdr_typesize {0UL}; + constexpr uint32_t UnionWChar_max_cdr_typesize {14UL}; constexpr uint32_t UnionWChar_max_key_cdr_typesize {0UL}; @@ -153,6 +156,7 @@ constexpr uint32_t UnionInnerEnumHelper_max_key_cdr_typesize {0UL}; + constexpr uint32_t UnionInnerStructureHelper_max_cdr_typesize {24UL}; constexpr uint32_t UnionInnerStructureHelper_max_key_cdr_typesize {0UL}; @@ -200,6 +204,7 @@ constexpr uint32_t UnionLongLong_max_key_cdr_typesize {0UL}; + constexpr uint32_t UnionString_max_cdr_typesize {272UL}; constexpr uint32_t UnionString_max_key_cdr_typesize {0UL}; @@ -379,12 +384,14 @@ eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const UnionSeveralFieldsWithDefault& data); - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const UnionShortExtraMember& data); +eProsima_user_DllExport void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const UnionFixedStringAlias& data); + } // namespace fastcdr } // namespace eprosima diff --git a/test/dds-types-test/unionsCdrAux.ipp b/test/dds-types-test/unionsCdrAux.ipp index 4247d00a70b..0b38c38a2aa 100644 --- a/test/dds-types-test/unionsCdrAux.ipp +++ b/test/dds-types-test/unionsCdrAux.ipp @@ -4963,6 +4963,115 @@ eProsima_user_DllExport void deserialize( }); } +template<> +eProsima_user_DllExport size_t calculate_serialized_size( + eprosima::fastcdr::CdrSizeCalculator& calculator, + const Union_Fixed_String_In_Module_Alias& data, + size_t& current_alignment) +{ + static_cast(data); + + eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); + size_t calculated_size {calculator.begin_calculate_type_serialized_size( + eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? + eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : + eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, + current_alignment)}; + + calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), data._d(), + current_alignment); + + switch (data._d()) + { + case 0: + calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(1), + data.a(), current_alignment); + break; + + default: + break; + } + + calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); + + return calculated_size; +} + + +template<> +eProsima_user_DllExport void serialize( + eprosima::fastcdr::Cdr& scdr, + const Union_Fixed_String_In_Module_Alias& data) +{ + eprosima::fastcdr::Cdr::state current_state(scdr); + scdr.begin_serialize_type(current_state, + eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? + eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : + eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); + + scdr << eprosima::fastcdr::MemberId(0) << data._d(); + + switch (data._d()) + { + case 0: + scdr << eprosima::fastcdr::MemberId(1) << data.a(); + break; + + default: + break; + } + + scdr.end_serialize_type(current_state); +} + +template<> +eProsima_user_DllExport void deserialize( + eprosima::fastcdr::Cdr& cdr, + Union_Fixed_String_In_Module_Alias& data) +{ + cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? + eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : + eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, + [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool + { + bool ret_value = true; + if (0 == mid.id) + { + int32_t discriminator; + dcdr >> discriminator; + + switch (discriminator) + { + case 0: + { + Fixed_String_Module::fixed_string_in_module a_value; + data.a(std::move(a_value)); + data._d(discriminator); + break; + } + + default: + data._default(); + break; + } + } + else + { + switch (data._d()) + { + case 0: + dcdr >> data.a(); + break; + + default: + break; + } + ret_value = false; + } + return ret_value; + }); +} + template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, @@ -8563,6 +8672,85 @@ void serialize_key( } +template<> +eProsima_user_DllExport size_t calculate_serialized_size( + eprosima::fastcdr::CdrSizeCalculator& calculator, + const UnionFixedStringAlias& data, + size_t& current_alignment) +{ + static_cast(data); + + eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); + size_t calculated_size {calculator.begin_calculate_type_serialized_size( + eprosima::fastcdr::CdrVersion::XCDRv2 == calculator.get_cdr_version() ? + eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : + eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, + current_alignment)}; + + + calculated_size += calculator.calculate_member_serialized_size(eprosima::fastcdr::MemberId(0), + data.var_union_fixed_string_in_module_alias(), current_alignment); + + + calculated_size += calculator.end_calculate_type_serialized_size(previous_encoding, current_alignment); + + return calculated_size; +} + +template<> +eProsima_user_DllExport void serialize( + eprosima::fastcdr::Cdr& scdr, + const UnionFixedStringAlias& data) +{ + eprosima::fastcdr::Cdr::state current_state(scdr); + scdr.begin_serialize_type(current_state, + eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? + eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : + eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR); + + scdr + << eprosima::fastcdr::MemberId(0) << data.var_union_fixed_string_in_module_alias() +; + scdr.end_serialize_type(current_state); +} + +template<> +eProsima_user_DllExport void deserialize( + eprosima::fastcdr::Cdr& cdr, + UnionFixedStringAlias& data) +{ + cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? + eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : + eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, + [&data](eprosima::fastcdr::Cdr& dcdr, const eprosima::fastcdr::MemberId& mid) -> bool + { + bool ret_value = true; + switch (mid.id) + { + case 0: + dcdr >> data.var_union_fixed_string_in_module_alias(); + break; + + default: + ret_value = false; + break; + } + return ret_value; + }); +} + +void serialize_key( + eprosima::fastcdr::Cdr& scdr, + const UnionFixedStringAlias& data) +{ + + static_cast(scdr); + static_cast(data); + scdr << data.var_union_fixed_string_in_module_alias(); + +} + + } // namespace fastcdr } // namespace eprosima diff --git a/test/dds-types-test/unionsPubSubTypes.cxx b/test/dds-types-test/unionsPubSubTypes.cxx index 6bdd0a1cfc5..d31d8289eb2 100644 --- a/test/dds-types-test/unionsPubSubTypes.cxx +++ b/test/dds-types-test/unionsPubSubTypes.cxx @@ -31,6 +31,9 @@ using SerializedPayload_t = eprosima::fastdds::rtps::SerializedPayload_t; using InstanceHandle_t = eprosima::fastdds::rtps::InstanceHandle_t; using DataRepresentationId_t = eprosima::fastdds::dds::DataRepresentationId_t; +namespace Fixed_String_Module { +} // namespace Fixed_String_Module + UnionShortPubSubType::UnionShortPubSubType() { set_name("UnionShort"); @@ -7452,8 +7455,6 @@ void UnionSeveralFieldsWithDefaultPubSubType::register_type_object_representatio register_UnionSeveralFieldsWithDefault_type_identifier(type_identifiers_); } - - UnionShortExtraMemberPubSubType::UnionShortExtraMemberPubSubType() { set_name("UnionShortExtraMember"); @@ -7635,6 +7636,187 @@ void UnionShortExtraMemberPubSubType::register_type_object_representation() register_UnionShortExtraMember_type_identifier(type_identifiers_); } +UnionFixedStringAliasPubSubType::UnionFixedStringAliasPubSubType() +{ + set_name("UnionFixedStringAlias"); + uint32_t type_size = UnionFixedStringAlias_max_cdr_typesize; + type_size += static_cast(eprosima::fastcdr::Cdr::alignment(type_size, 4)); /* possible submessage alignment */ + max_serialized_type_size = type_size + 4; /*encapsulation*/ + is_compute_key_provided = false; + uint32_t key_length = UnionFixedStringAlias_max_key_cdr_typesize > 16 ? UnionFixedStringAlias_max_key_cdr_typesize : 16; + key_buffer_ = reinterpret_cast(malloc(key_length)); + memset(key_buffer_, 0, key_length); +} + +UnionFixedStringAliasPubSubType::~UnionFixedStringAliasPubSubType() +{ + if (key_buffer_ != nullptr) + { + free(key_buffer_); + } +} + +bool UnionFixedStringAliasPubSubType::serialize( + const void* const data, + SerializedPayload_t& payload, + DataRepresentationId_t data_representation) +{ + const UnionFixedStringAlias* p_type = static_cast(data); + + // Object that manages the raw buffer. + eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload.data), payload.max_size); + // Object that serializes the data. + eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN, + data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? + eprosima::fastcdr::CdrVersion::XCDRv1 : eprosima::fastcdr::CdrVersion::XCDRv2); + payload.encapsulation = ser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; + ser.set_encoding_flag( + data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? + eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR : + eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2); + + try + { + // Serialize encapsulation + ser.serialize_encapsulation(); + // Serialize the object. + ser << *p_type; + } + catch (eprosima::fastcdr::exception::Exception& /*exception*/) + { + return false; + } + + // Get the serialized length + payload.length = static_cast(ser.get_serialized_data_length()); + return true; +} + +bool UnionFixedStringAliasPubSubType::deserialize( + SerializedPayload_t& payload, + void* data) +{ + try + { + // Convert DATA to pointer of your type + UnionFixedStringAlias* p_type = static_cast(data); + + // Object that manages the raw buffer. + eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(payload.data), payload.length); + + // Object that deserializes the data. + eprosima::fastcdr::Cdr deser(fastbuffer, eprosima::fastcdr::Cdr::DEFAULT_ENDIAN); + + // Deserialize encapsulation. + deser.read_encapsulation(); + payload.encapsulation = deser.endianness() == eprosima::fastcdr::Cdr::BIG_ENDIANNESS ? CDR_BE : CDR_LE; + + // Deserialize the object. + deser >> *p_type; + } + catch (eprosima::fastcdr::exception::Exception& /*exception*/) + { + return false; + } + + return true; +} + +uint32_t UnionFixedStringAliasPubSubType::calculate_serialized_size( + const void* const data, + DataRepresentationId_t data_representation) +{ + try + { + eprosima::fastcdr::CdrSizeCalculator calculator( + data_representation == DataRepresentationId_t::XCDR_DATA_REPRESENTATION ? + eprosima::fastcdr::CdrVersion::XCDRv1 :eprosima::fastcdr::CdrVersion::XCDRv2); + size_t current_alignment {0}; + return static_cast(calculator.calculate_serialized_size( + *static_cast(data), current_alignment)) + + 4u /*encapsulation*/; + } + catch (eprosima::fastcdr::exception::Exception& /*exception*/) + { + return 0; + } +} + +void* UnionFixedStringAliasPubSubType::create_data() +{ + return reinterpret_cast(new UnionFixedStringAlias()); +} + +void UnionFixedStringAliasPubSubType::delete_data( + void* data) +{ + delete(reinterpret_cast(data)); +} + +bool UnionFixedStringAliasPubSubType::compute_key( + SerializedPayload_t& payload, + InstanceHandle_t& handle, + bool force_md5) +{ + if (!is_compute_key_provided) + { + return false; + } + + UnionFixedStringAlias data; + if (deserialize(payload, static_cast(&data))) + { + return compute_key(static_cast(&data), handle, force_md5); + } + + return false; +} + +bool UnionFixedStringAliasPubSubType::compute_key( + const void* const data, + InstanceHandle_t& handle, + bool force_md5) +{ + if (!is_compute_key_provided) + { + return false; + } + + const UnionFixedStringAlias* p_type = static_cast(data); + + // Object that manages the raw buffer. + eprosima::fastcdr::FastBuffer fastbuffer(reinterpret_cast(key_buffer_), + UnionFixedStringAlias_max_key_cdr_typesize); + + // Object that serializes the data. + eprosima::fastcdr::Cdr ser(fastbuffer, eprosima::fastcdr::Cdr::BIG_ENDIANNESS, eprosima::fastcdr::CdrVersion::XCDRv2); + ser.set_encoding_flag(eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR2); + eprosima::fastcdr::serialize_key(ser, *p_type); + if (force_md5 || UnionFixedStringAlias_max_key_cdr_typesize > 16) + { + md5_.init(); + md5_.update(key_buffer_, static_cast(ser.get_serialized_data_length())); + md5_.finalize(); + for (uint8_t i = 0; i < 16; ++i) + { + handle.value[i] = md5_.digest[i]; + } + } + else + { + for (uint8_t i = 0; i < 16; ++i) + { + handle.value[i] = key_buffer_[i]; + } + } + return true; +} + +void UnionFixedStringAliasPubSubType::register_type_object_representation() +{ + register_UnionFixedStringAlias_type_identifier(type_identifiers_); +} + // Include auxiliary functions like for serializing/deserializing. #include "unionsCdrAux.ipp" diff --git a/test/dds-types-test/unionsPubSubTypes.hpp b/test/dds-types-test/unionsPubSubTypes.hpp index 4401752582c..10948e33342 100644 --- a/test/dds-types-test/unionsPubSubTypes.hpp +++ b/test/dds-types-test/unionsPubSubTypes.hpp @@ -38,6 +38,10 @@ Generated unions is not compatible with current installed Fast DDS. Please, regenerate it with fastddsgen. #endif // FASTDDS_GEN_API_VER +namespace Fixed_String_Module +{ + typedef eprosima::fastcdr::fixed_string<20> fixed_string_in_module; +} // namespace Fixed_String_Module /*! * @brief This class represents the TopicDataType of the type UnionShort defined by the user in the IDL file. @@ -3360,8 +3364,6 @@ class UnionSeveralFieldsWithDefaultPubSubType : public eprosima::fastdds::dds::T }; - - /*! * @brief This class represents the TopicDataType of the type UnionShortExtraMember defined by the user in the IDL file. * @ingroup unions @@ -3443,5 +3445,86 @@ class UnionShortExtraMemberPubSubType : public eprosima::fastdds::dds::TopicData }; +/*! + * @brief This class represents the TopicDataType of the type UnionFixedStringAlias defined by the user in the IDL file. + * @ingroup unions + */ +class UnionFixedStringAliasPubSubType : public eprosima::fastdds::dds::TopicDataType +{ +public: + + typedef UnionFixedStringAlias type; + + eProsima_user_DllExport UnionFixedStringAliasPubSubType(); + + eProsima_user_DllExport ~UnionFixedStringAliasPubSubType() override; + + eProsima_user_DllExport bool serialize( + const void* const data, + eprosima::fastdds::rtps::SerializedPayload_t& payload, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool deserialize( + eprosima::fastdds::rtps::SerializedPayload_t& payload, + void* data) override; + + eProsima_user_DllExport uint32_t calculate_serialized_size( + const void* const data, + eprosima::fastdds::dds::DataRepresentationId_t data_representation) override; + + eProsima_user_DllExport bool compute_key( + eprosima::fastdds::rtps::SerializedPayload_t& payload, + eprosima::fastdds::rtps::InstanceHandle_t& ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport bool compute_key( + const void* const data, + eprosima::fastdds::rtps::InstanceHandle_t& ihandle, + bool force_md5 = false) override; + + eProsima_user_DllExport void* create_data() override; + + eProsima_user_DllExport void delete_data( + void* data) override; + + //Register TypeObject representation in Fast DDS TypeObjectRegistry + eProsima_user_DllExport void register_type_object_representation() override; + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + eProsima_user_DllExport inline bool is_bounded() const override + { + return true; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_BOUNDED + +#ifdef TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + + eProsima_user_DllExport inline bool is_plain( + eprosima::fastdds::dds::DataRepresentationId_t data_representation) const override + { + static_cast(data_representation); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_IS_PLAIN + +#ifdef TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + eProsima_user_DllExport inline bool construct_sample( + void* memory) const override + { + static_cast(memory); + return false; + } + +#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE + +private: + + eprosima::fastdds::MD5 md5_; + unsigned char* key_buffer_; + +}; + #endif // FAST_DDS_GENERATED__UNIONS_PUBSUBTYPES_HPP diff --git a/test/dds-types-test/unionsTypeObjectSupport.cxx b/test/dds-types-test/unionsTypeObjectSupport.cxx index 3627bcb4382..3b0f9140924 100644 --- a/test/dds-types-test/unionsTypeObjectSupport.cxx +++ b/test/dds-types-test/unionsTypeObjectSupport.cxx @@ -39,6 +39,67 @@ using namespace eprosima::fastdds::dds::xtypes; +namespace Fixed_String_Module { +void register_fixed_string_in_module_type_identifier( + TypeIdentifierPair& type_ids_fixed_string_in_module) +{ + ReturnCode_t return_code_fixed_string_in_module {eprosima::fastdds::dds::RETCODE_OK}; + return_code_fixed_string_in_module = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Fixed_String_Module::fixed_string_in_module", type_ids_fixed_string_in_module); + if (eprosima::fastdds::dds::RETCODE_OK != return_code_fixed_string_in_module) + { + AliasTypeFlag alias_flags_fixed_string_in_module = 0; + QualifiedTypeName type_name_fixed_string_in_module = "Fixed_String_Module::fixed_string_in_module"; + eprosima::fastcdr::optional type_ann_builtin_fixed_string_in_module; + eprosima::fastcdr::optional ann_custom_fixed_string_in_module; + CompleteTypeDetail detail_fixed_string_in_module = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_fixed_string_in_module, ann_custom_fixed_string_in_module, type_name_fixed_string_in_module.to_string()); + CompleteAliasHeader header_fixed_string_in_module = TypeObjectUtils::build_complete_alias_header(detail_fixed_string_in_module); + AliasMemberFlag related_flags_fixed_string_in_module = 0; + return_code_fixed_string_in_module = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "anonymous_string_20", type_ids_fixed_string_in_module); + + if (eprosima::fastdds::dds::RETCODE_OK != return_code_fixed_string_in_module) + { + { + SBound bound = static_cast(20); + StringSTypeDefn string_sdefn = TypeObjectUtils::build_string_s_type_defn(bound); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_s_string_type_identifier(string_sdefn, + "anonymous_string_20", type_ids_fixed_string_in_module)) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "anonymous_string_20 already registered in TypeObjectRegistry for a different type."); + } + } + } + bool common_fixed_string_in_module_ec {false}; + CommonAliasBody common_fixed_string_in_module {TypeObjectUtils::build_common_alias_body(related_flags_fixed_string_in_module, + TypeObjectUtils::retrieve_complete_type_identifier(type_ids_fixed_string_in_module, common_fixed_string_in_module_ec))}; + if (!common_fixed_string_in_module_ec) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, "Fixed_String_Module::fixed_string_in_module related TypeIdentifier inconsistent."); + return; + } + eprosima::fastcdr::optional member_ann_builtin_fixed_string_in_module; + ann_custom_fixed_string_in_module.reset(); + CompleteAliasBody body_fixed_string_in_module = TypeObjectUtils::build_complete_alias_body(common_fixed_string_in_module, + member_ann_builtin_fixed_string_in_module, ann_custom_fixed_string_in_module); + CompleteAliasType alias_type_fixed_string_in_module = TypeObjectUtils::build_complete_alias_type(alias_flags_fixed_string_in_module, + header_fixed_string_in_module, body_fixed_string_in_module); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_alias_type_object(alias_type_fixed_string_in_module, + type_name_fixed_string_in_module.to_string(), type_ids_fixed_string_in_module)) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Fixed_String_Module::fixed_string_in_module already registered in TypeObjectRegistry for a different type."); + } + } +} + + +} // namespace Fixed_String_Module // TypeIdentifier is returned by reference: dependent structures/unions are registered in this same method void register_Union_Short_type_identifier( TypeIdentifierPair& type_ids_Union_Short) @@ -4601,6 +4662,95 @@ void register_Union_Several_Fields_With_Default_type_identifier( } } // TypeIdentifier is returned by reference: dependent structures/unions are registered in this same method +void register_Union_Fixed_String_In_Module_Alias_type_identifier( + TypeIdentifierPair& type_ids_Union_Fixed_String_In_Module_Alias) +{ + ReturnCode_t return_code_Union_Fixed_String_In_Module_Alias {eprosima::fastdds::dds::RETCODE_OK}; + return_code_Union_Fixed_String_In_Module_Alias = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Union_Fixed_String_In_Module_Alias", type_ids_Union_Fixed_String_In_Module_Alias); + if (eprosima::fastdds::dds::RETCODE_OK != return_code_Union_Fixed_String_In_Module_Alias) + { + UnionTypeFlag union_flags_Union_Fixed_String_In_Module_Alias = TypeObjectUtils::build_union_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::APPENDABLE, + false, false); + QualifiedTypeName type_name_Union_Fixed_String_In_Module_Alias = "Union_Fixed_String_In_Module_Alias"; + eprosima::fastcdr::optional type_ann_builtin_Union_Fixed_String_In_Module_Alias; + eprosima::fastcdr::optional ann_custom_Union_Fixed_String_In_Module_Alias; + CompleteTypeDetail detail_Union_Fixed_String_In_Module_Alias = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_Union_Fixed_String_In_Module_Alias, ann_custom_Union_Fixed_String_In_Module_Alias, type_name_Union_Fixed_String_In_Module_Alias.to_string()); + CompleteUnionHeader header_Union_Fixed_String_In_Module_Alias = TypeObjectUtils::build_complete_union_header(detail_Union_Fixed_String_In_Module_Alias); + UnionDiscriminatorFlag member_flags_Union_Fixed_String_In_Module_Alias = TypeObjectUtils::build_union_discriminator_flag(eprosima::fastdds::dds::xtypes::TryConstructFailAction::DISCARD, + false); + return_code_Union_Fixed_String_In_Module_Alias = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "_int32_t", type_ids_Union_Fixed_String_In_Module_Alias); + + if (return_code_Union_Fixed_String_In_Module_Alias != eprosima::fastdds::dds::RETCODE_OK) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Union discriminator TypeIdentifier unknown to TypeObjectRegistry."); + return; + } + CommonDiscriminatorMember common_Union_Fixed_String_In_Module_Alias; + if (EK_COMPLETE == type_ids_Union_Fixed_String_In_Module_Alias.type_identifier1()._d() || TK_NONE == type_ids_Union_Fixed_String_In_Module_Alias.type_identifier2()._d()) + { + common_Union_Fixed_String_In_Module_Alias = TypeObjectUtils::build_common_discriminator_member(member_flags_Union_Fixed_String_In_Module_Alias, type_ids_Union_Fixed_String_In_Module_Alias.type_identifier1()); + } + else if (EK_COMPLETE == type_ids_Union_Fixed_String_In_Module_Alias.type_identifier2()._d()) + { + common_Union_Fixed_String_In_Module_Alias = TypeObjectUtils::build_common_discriminator_member(member_flags_Union_Fixed_String_In_Module_Alias, type_ids_Union_Fixed_String_In_Module_Alias.type_identifier2()); + } + else + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Union_Fixed_String_In_Module_Alias discriminator TypeIdentifier inconsistent."); + return; + } + type_ann_builtin_Union_Fixed_String_In_Module_Alias.reset(); + ann_custom_Union_Fixed_String_In_Module_Alias.reset(); + CompleteDiscriminatorMember discriminator_Union_Fixed_String_In_Module_Alias = TypeObjectUtils::build_complete_discriminator_member(common_Union_Fixed_String_In_Module_Alias, + type_ann_builtin_Union_Fixed_String_In_Module_Alias, ann_custom_Union_Fixed_String_In_Module_Alias); + CompleteUnionMemberSeq member_seq_Union_Fixed_String_In_Module_Alias; + { + return_code_Union_Fixed_String_In_Module_Alias = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Fixed_String_Module::fixed_string_in_module", type_ids_Union_Fixed_String_In_Module_Alias); + + if (eprosima::fastdds::dds::RETCODE_OK != return_code_Union_Fixed_String_In_Module_Alias) + { + Fixed_String_Module::register_fixed_string_in_module_type_identifier(type_ids_Union_Fixed_String_In_Module_Alias); + } + UnionMemberFlag member_flags_a = TypeObjectUtils::build_union_member_flag(eprosima::fastdds::dds::xtypes::TryConstructFailAction::DISCARD, + false, false); + UnionCaseLabelSeq label_seq_a; + TypeObjectUtils::add_union_case_label(label_seq_a, static_cast(0)); + MemberId member_id_a = 0x00000001; + bool common_a_ec {false}; + CommonUnionMember common_a {TypeObjectUtils::build_common_union_member(member_id_a, + member_flags_a, TypeObjectUtils::retrieve_complete_type_identifier(type_ids_Union_Fixed_String_In_Module_Alias, + common_a_ec), label_seq_a)}; + if (!common_a_ec) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, "Union a member TypeIdentifier inconsistent."); + return; + } + MemberName name_a = "a"; + eprosima::fastcdr::optional member_ann_builtin_a; + ann_custom_Union_Fixed_String_In_Module_Alias.reset(); + CompleteMemberDetail detail_a = TypeObjectUtils::build_complete_member_detail(name_a, member_ann_builtin_a, ann_custom_Union_Fixed_String_In_Module_Alias); + CompleteUnionMember member_a = TypeObjectUtils::build_complete_union_member(common_a, detail_a); + TypeObjectUtils::add_complete_union_member(member_seq_Union_Fixed_String_In_Module_Alias, member_a); + } + CompleteUnionType union_type_Union_Fixed_String_In_Module_Alias = TypeObjectUtils::build_complete_union_type(union_flags_Union_Fixed_String_In_Module_Alias, header_Union_Fixed_String_In_Module_Alias, discriminator_Union_Fixed_String_In_Module_Alias, + member_seq_Union_Fixed_String_In_Module_Alias); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_union_type_object(union_type_Union_Fixed_String_In_Module_Alias, type_name_Union_Fixed_String_In_Module_Alias.to_string(), type_ids_Union_Fixed_String_In_Module_Alias)) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "Union_Fixed_String_In_Module_Alias already registered in TypeObjectRegistry for a different type."); + } + } +} +// TypeIdentifier is returned by reference: dependent structures/unions are registered in this same method void register_UnionShort_type_identifier( TypeIdentifierPair& type_ids_UnionShort) { @@ -7315,4 +7465,61 @@ void register_UnionShortExtraMember_type_identifier( } } } +// TypeIdentifier is returned by reference: dependent structures/unions are registered in this same method +void register_UnionFixedStringAlias_type_identifier( + TypeIdentifierPair& type_ids_UnionFixedStringAlias) +{ + + ReturnCode_t return_code_UnionFixedStringAlias {eprosima::fastdds::dds::RETCODE_OK}; + return_code_UnionFixedStringAlias = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "UnionFixedStringAlias", type_ids_UnionFixedStringAlias); + if (eprosima::fastdds::dds::RETCODE_OK != return_code_UnionFixedStringAlias) + { + StructTypeFlag struct_flags_UnionFixedStringAlias = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::APPENDABLE, + false, false); + QualifiedTypeName type_name_UnionFixedStringAlias = "UnionFixedStringAlias"; + eprosima::fastcdr::optional type_ann_builtin_UnionFixedStringAlias; + eprosima::fastcdr::optional ann_custom_UnionFixedStringAlias; + CompleteTypeDetail detail_UnionFixedStringAlias = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_UnionFixedStringAlias, ann_custom_UnionFixedStringAlias, type_name_UnionFixedStringAlias.to_string()); + CompleteStructHeader header_UnionFixedStringAlias; + header_UnionFixedStringAlias = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_UnionFixedStringAlias); + CompleteStructMemberSeq member_seq_UnionFixedStringAlias; + { + TypeIdentifierPair type_ids_var_union_fixed_string_in_module_alias; + ReturnCode_t return_code_var_union_fixed_string_in_module_alias {eprosima::fastdds::dds::RETCODE_OK}; + return_code_var_union_fixed_string_in_module_alias = + eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( + "Union_Fixed_String_In_Module_Alias", type_ids_var_union_fixed_string_in_module_alias); + + if (eprosima::fastdds::dds::RETCODE_OK != return_code_var_union_fixed_string_in_module_alias) + { + ::register_Union_Fixed_String_In_Module_Alias_type_identifier(type_ids_var_union_fixed_string_in_module_alias); + } + StructMemberFlag member_flags_var_union_fixed_string_in_module_alias = TypeObjectUtils::build_struct_member_flag(eprosima::fastdds::dds::xtypes::TryConstructFailAction::DISCARD, + false, false, false, false); + MemberId member_id_var_union_fixed_string_in_module_alias = 0x00000000; + bool common_var_union_fixed_string_in_module_alias_ec {false}; + CommonStructMember common_var_union_fixed_string_in_module_alias {TypeObjectUtils::build_common_struct_member(member_id_var_union_fixed_string_in_module_alias, member_flags_var_union_fixed_string_in_module_alias, TypeObjectUtils::retrieve_complete_type_identifier(type_ids_var_union_fixed_string_in_module_alias, common_var_union_fixed_string_in_module_alias_ec))}; + if (!common_var_union_fixed_string_in_module_alias_ec) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, "Structure var_union_fixed_string_in_module_alias member TypeIdentifier inconsistent."); + return; + } + MemberName name_var_union_fixed_string_in_module_alias = "var_union_fixed_string_in_module_alias"; + eprosima::fastcdr::optional member_ann_builtin_var_union_fixed_string_in_module_alias; + ann_custom_UnionFixedStringAlias.reset(); + CompleteMemberDetail detail_var_union_fixed_string_in_module_alias = TypeObjectUtils::build_complete_member_detail(name_var_union_fixed_string_in_module_alias, member_ann_builtin_var_union_fixed_string_in_module_alias, ann_custom_UnionFixedStringAlias); + CompleteStructMember member_var_union_fixed_string_in_module_alias = TypeObjectUtils::build_complete_struct_member(common_var_union_fixed_string_in_module_alias, detail_var_union_fixed_string_in_module_alias); + TypeObjectUtils::add_complete_struct_member(member_seq_UnionFixedStringAlias, member_var_union_fixed_string_in_module_alias); + } + CompleteStructType struct_type_UnionFixedStringAlias = TypeObjectUtils::build_complete_struct_type(struct_flags_UnionFixedStringAlias, header_UnionFixedStringAlias, member_seq_UnionFixedStringAlias); + if (eprosima::fastdds::dds::RETCODE_BAD_PARAMETER == + TypeObjectUtils::build_and_register_struct_type_object(struct_type_UnionFixedStringAlias, type_name_UnionFixedStringAlias.to_string(), type_ids_UnionFixedStringAlias)) + { + EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, + "UnionFixedStringAlias already registered in TypeObjectRegistry for a different type."); + } + } +} diff --git a/test/dds-types-test/unionsTypeObjectSupport.hpp b/test/dds-types-test/unionsTypeObjectSupport.hpp index d2757c9d758..b2bb2cad47f 100644 --- a/test/dds-types-test/unionsTypeObjectSupport.hpp +++ b/test/dds-types-test/unionsTypeObjectSupport.hpp @@ -38,6 +38,23 @@ #ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC +namespace Fixed_String_Module { +/** + * @brief Register fixed_string_in_module related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + * + * @param[out] TypeIdentifier of the registered type. + * The returned TypeIdentifier corresponds to the complete TypeIdentifier in case of hashed TypeIdentifiers. + * Invalid TypeIdentifier is returned in case of error. + */ +eProsima_user_DllExport void register_fixed_string_in_module_type_identifier( + eprosima::fastdds::dds::xtypes::TypeIdentifierPair& type_ids); + + + +} // namespace Fixed_String_Module /** * @brief Register Union_Short related TypeIdentifier. * Fully-descriptive TypeIdentifiers are directly registered. @@ -530,6 +547,18 @@ eProsima_user_DllExport void register_Union_Several_Fields_type_identifier( */ eProsima_user_DllExport void register_Union_Several_Fields_With_Default_type_identifier( eprosima::fastdds::dds::xtypes::TypeIdentifierPair& type_ids); +/** + * @brief Register Union_Fixed_String_In_Module_Alias related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + * + * @param[out] TypeIdentifier of the registered type. + * The returned TypeIdentifier corresponds to the complete TypeIdentifier in case of hashed TypeIdentifiers. + * Invalid TypeIdentifier is returned in case of error. + */ +eProsima_user_DllExport void register_Union_Fixed_String_In_Module_Alias_type_identifier( + eprosima::fastdds::dds::xtypes::TypeIdentifierPair& type_ids); /** * @brief Register UnionShort related TypeIdentifier. * Fully-descriptive TypeIdentifiers are directly registered. @@ -1058,6 +1087,18 @@ eProsima_user_DllExport void register_DefaultAnnotationExternalValue_type_identi */ eProsima_user_DllExport void register_UnionShortExtraMember_type_identifier( eprosima::fastdds::dds::xtypes::TypeIdentifierPair& type_ids); +/** + * @brief Register UnionFixedStringAlias related TypeIdentifier. + * Fully-descriptive TypeIdentifiers are directly registered. + * Hash TypeIdentifiers require to fill the TypeObject information and hash it, consequently, the TypeObject is + * indirectly registered as well. + * + * @param[out] TypeIdentifier of the registered type. + * The returned TypeIdentifier corresponds to the complete TypeIdentifier in case of hashed TypeIdentifiers. + * Invalid TypeIdentifier is returned in case of error. + */ +eProsima_user_DllExport void register_UnionFixedStringAlias_type_identifier( + eprosima::fastdds::dds::xtypes::TypeIdentifierPair& type_ids); #endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC diff --git a/test/dds/xtypes/TypeLookupServicePublisher.h b/test/dds/xtypes/TypeLookupServicePublisher.h index cfd9087b89c..5f004650b1b 100644 --- a/test/dds/xtypes/TypeLookupServicePublisher.h +++ b/test/dds/xtypes/TypeLookupServicePublisher.h @@ -877,6 +877,7 @@ class TypeLookupServicePublisher PUBLISHER_TYPE_CREATOR_FUNCTION(UnionDiscriminatorUShort); PUBLISHER_TYPE_CREATOR_FUNCTION(UnionDiscriminatorWChar); PUBLISHER_TYPE_CREATOR_FUNCTION(UnionDouble); + PUBLISHER_TYPE_CREATOR_FUNCTION(UnionFixedStringAlias); PUBLISHER_TYPE_CREATOR_FUNCTION(UnionFloat); PUBLISHER_TYPE_CREATOR_FUNCTION(UnionInnerAliasHelper); PUBLISHER_TYPE_CREATOR_FUNCTION(UnionInnerBitMaskHelper); diff --git a/test/dds/xtypes/TypeLookupServiceSubscriber.h b/test/dds/xtypes/TypeLookupServiceSubscriber.h index ca3bdd17ed3..3d568d8adcd 100644 --- a/test/dds/xtypes/TypeLookupServiceSubscriber.h +++ b/test/dds/xtypes/TypeLookupServiceSubscriber.h @@ -889,6 +889,7 @@ class TypeLookupServiceSubscriber SUBSCRIBER_TYPE_CREATOR_FUNCTION(UnionDiscriminatorUShort); SUBSCRIBER_TYPE_CREATOR_FUNCTION(UnionDiscriminatorWChar); SUBSCRIBER_TYPE_CREATOR_FUNCTION(UnionDouble); + SUBSCRIBER_TYPE_CREATOR_FUNCTION(UnionFixedStringAlias); SUBSCRIBER_TYPE_CREATOR_FUNCTION(UnionFloat); SUBSCRIBER_TYPE_CREATOR_FUNCTION(UnionInnerAliasHelper); SUBSCRIBER_TYPE_CREATOR_FUNCTION(UnionInnerBitMaskHelper); diff --git a/test/dds/xtypes/TypesTestsCases/Cases_structures.json b/test/dds/xtypes/TypesTestsCases/Cases_structures.json index 0b44fe74e52..4a33491dae0 100644 --- a/test/dds/xtypes/TypesTestsCases/Cases_structures.json +++ b/test/dds/xtypes/TypesTestsCases/Cases_structures.json @@ -618,7 +618,7 @@ "timeout": "10", "expected_matches": "1", "known_types": [ - "testing_2::foo" + "testing_1::foo" ] }, { @@ -639,7 +639,7 @@ "timeout": "10", "expected_matches": "1", "known_types": [ - "testing_1::foo" + "testing_2::foo" ] }, { diff --git a/test/dds/xtypes/TypesTestsCases/Cases_unions.json b/test/dds/xtypes/TypesTestsCases/Cases_unions.json index ae259f7822b..42d395a6207 100644 --- a/test/dds/xtypes/TypesTestsCases/Cases_unions.json +++ b/test/dds/xtypes/TypesTestsCases/Cases_unions.json @@ -399,6 +399,27 @@ } ] }, + { + "TestCase": "Case_unions_UnionFixedStringAlias", + "participants": [ + { + "kind": "publisher", + "samples": "10", + "timeout": "10", + "expected_matches": "1", + "known_types": [ + "UnionFixedStringAlias" + ] + }, + { + "kind": "subscriber", + "samples": "10", + "timeout": "10", + "expected_matches": "1", + "known_types": [] + } + ] + }, { "TestCase": "Case_unions_UnionFloat", "participants": [ diff --git a/test/dds/xtypes/update_header_and_create_cases.py b/test/dds/xtypes/update_header_and_create_cases.py index 00c6d65b180..c21c8b51263 100644 --- a/test/dds/xtypes/update_header_and_create_cases.py +++ b/test/dds/xtypes/update_header_and_create_cases.py @@ -21,7 +21,7 @@ def __init__(self): def extract_structures(self, idl_text): # Regular expressions for module and struct extraction - module_regexp = r'module\s+(\w+)\s*{((?:.|[\r\n])*?)\};\s*\};' + module_regexp = r'module\s+(\w+)\s*{((?:.|[\r\n])*?)\};' struct_regexp = r'struct\s+(\w+)(\s*:\s*\w+)?\s*\{([^}]+)' # Extract structures within modules @@ -34,7 +34,7 @@ def extract_structures(self, idl_text): # Find structures outside modules outside_structures = re.findall(struct_regexp, idl_text) - + # Remove duplicate structures for module_name, structures in module_structures.items(): for structure in structures: @@ -57,12 +57,12 @@ def process_idl_files(self, idls_path): with open(file_path, 'r') as file: content = file.read() module_structures, outside_structures = self.extract_structures(content) - + # Store struct information along with the IDL file name and module name for module_name, structures in module_structures.items(): for structure in structures: self.structs_info.add((structure[0], idl_file_name, module_name, idls_path)) - + # Store struct information for structures outside modules for structure in outside_structures: self.structs_info.add((structure[0], idl_file_name, "", idls_path)) @@ -119,7 +119,7 @@ def create_case_files(structs_info, struct_names_to_ignore): json.dump(case_data, f, indent=4) print(f"Created case file: {file_path}") - + def update_types_header_file(structs_info, typecode_path): # Update types header file with necessary includes header_file_path = os.path.join(os.path.dirname(__file__), 'TypeLookupServiceTestsTypes.h') @@ -181,7 +181,7 @@ def insert_macros(func_declaration, macro_name, structs_info, struct_names_to_ig lines = func_declaration.split('\n') lines = [line for line in lines if not re.match(rf'\s*{macro_name}\((\w+|\w+::\w+)\);', line)] # Remove existing macro lines updated_func = '\n'.join(lines) - + idx = updated_func.rfind(' }') if idx != -1: structs_info = sorted(list(structs_info), key=lambda x: (x[1], x[2], x[0]), reverse=True) # Sort structs_info alphabetically diff --git a/test/feature/dynamic_types/dds_types_tests/DynamicTypesUnionsDDSTypesTests.cpp b/test/feature/dynamic_types/dds_types_tests/DynamicTypesUnionsDDSTypesTests.cpp index 1ad333e0a96..c599d506529 100644 --- a/test/feature/dynamic_types/dds_types_tests/DynamicTypesUnionsDDSTypesTests.cpp +++ b/test/feature/dynamic_types/dds_types_tests/DynamicTypesUnionsDDSTypesTests.cpp @@ -31,161 +31,166 @@ namespace eprosima { namespace fastdds { namespace dds { -constexpr const char* struct_union_short_name = "UnionShort"; -constexpr const char* struct_union_ushort_name = "UnionUShort"; -constexpr const char* struct_union_long_name = "UnionLong"; -constexpr const char* struct_union_ulong_name = "UnionULong"; -constexpr const char* struct_union_long_long_name = "UnionLongLong"; -constexpr const char* struct_union_ulong_long_name = "UnionULongLong"; -constexpr const char* struct_union_float_name = "UnionFloat"; -constexpr const char* struct_union_double_name = "UnionDouble"; -constexpr const char* struct_union_long_double_name = "UnionLongDouble"; -constexpr const char* struct_union_bool_name = "UnionBoolean"; -constexpr const char* struct_union_byte_name = "UnionOctet"; -constexpr const char* struct_union_char_name = "UnionChar"; -constexpr const char* struct_union_wchar_name = "UnionWChar"; -constexpr const char* struct_union_string_name = "UnionString"; -constexpr const char* struct_union_wstring_name = "UnionWString"; -constexpr const char* struct_union_bounded_string_name = "UnionBoundedString"; -constexpr const char* struct_union_bounded_wstring_name = "UnionBoundedWString"; -constexpr const char* struct_union_enum_name = "UnionInnerEnumHelper"; -constexpr const char* struct_union_bitmask_name = "UnionInnerBitMaskHelper"; -constexpr const char* struct_union_alias_name = "UnionInnerAliasHelper"; -constexpr const char* struct_union_array_name = "UnionArray"; -constexpr const char* struct_union_seq_name = "UnionSequence"; -constexpr const char* struct_union_map_name = "UnionMap"; -constexpr const char* struct_union_union_name = "UnionInnerUnionHelper"; -constexpr const char* struct_union_struct_name = "UnionInnerStructureHelper"; -constexpr const char* struct_union_bitset_name = "UnionInnerBitsetHelper"; -constexpr const char* struct_union_short_discriminator_name = "UnionDiscriminatorShort"; -constexpr const char* struct_union_ushort_discriminator_name = "UnionDiscriminatorUShort"; -constexpr const char* struct_union_long_discriminator_name = "UnionDiscriminatorLong"; -constexpr const char* struct_union_ulong_discriminator_name = "UnionDiscriminatorULong"; -constexpr const char* struct_union_long_long_discriminator_name = "UnionDiscriminatorLongLong"; -constexpr const char* struct_union_ulong_long_discriminator_name = "UnionDiscriminatorULongLong"; -constexpr const char* struct_union_bool_discriminator_name = "UnionDiscriminatorBoolean"; -constexpr const char* struct_union_byte_discriminator_name = "UnionDiscriminatorOctet"; -constexpr const char* struct_union_char_discriminator_name = "UnionDiscriminatorChar"; -constexpr const char* struct_union_wchar_discriminator_name = "UnionDiscriminatorWChar"; -constexpr const char* struct_union_enum_discriminator_name = "UnionDiscriminatorEnum"; -constexpr const char* struct_union_enum_label_discriminator_name = "UnionDiscriminatorEnumLabel"; -constexpr const char* struct_union_alias_discriminator_name = "UnionDiscriminatorAlias"; -constexpr const char* struct_union_several_fields_name = "UnionSeveralFields"; -constexpr const char* struct_union_several_fields_with_default_name = "UnionSeveralFieldsWithDefault"; -constexpr const char* struct_union_short_extra_member_name = "UnionShortExtraMember"; - -constexpr const char* union_short_name = "Union_Short"; -constexpr const char* union_ushort_name = "Union_UShort"; -constexpr const char* union_long_name = "Union_Long"; -constexpr const char* union_ulong_name = "Union_ULong"; -constexpr const char* union_long_long_name = "Union_LongLong"; -constexpr const char* union_ulong_long_name = "Union_ULongLOng"; -constexpr const char* union_float_name = "Union_Float"; -constexpr const char* union_double_name = "Union_Double"; -constexpr const char* union_long_double_name = "Union_LongDouble"; -constexpr const char* union_bool_name = "Union_Boolean"; -constexpr const char* union_byte_name = "Union_Octet"; -constexpr const char* union_char_name = "Union_Char"; -constexpr const char* union_wchar_name = "Union_WChar"; -constexpr const char* union_string_name = "Union_String"; -constexpr const char* union_wstring_name = "Union_WString"; -constexpr const char* union_bounded_string_name = "Union_BoundedString"; -constexpr const char* union_bounded_wstring_name = "Union_BoundedWString"; -constexpr const char* union_enum_name = "Union_InnerEnumHelper"; -constexpr const char* union_bitmask_name = "Union_InnerBitMaskHelper"; -constexpr const char* union_alias_name = "Union_InnerAliasHelper"; -constexpr const char* union_array_name = "Union_Array"; -constexpr const char* union_seq_name = "Union_Sequence"; -constexpr const char* union_map_name = "Union_Map"; -constexpr const char* union_union_name = "Union_InnerUnionHelper"; -constexpr const char* union_struct_name = "Union_InnerStructureHelper"; -constexpr const char* union_bitset_name = "Union_InnerBitsetHelper"; -constexpr const char* union_short_discriminator_name = "Union_Discriminator_short"; -constexpr const char* union_ushort_discriminator_name = "Union_Discriminator_unsigned_short"; -constexpr const char* union_long_discriminator_name = "Union_Discriminator_long"; -constexpr const char* union_ulong_discriminator_name = "Union_Discriminator_unsigned_long"; -constexpr const char* union_long_long_discriminator_name = "Union_Discriminator_long_long"; -constexpr const char* union_ulong_long_discriminator_name = "Union_Discriminator_unsigned_long_long"; -constexpr const char* union_bool_discriminator_name = "Union_Discriminator_boolean"; -constexpr const char* union_byte_discriminator_name = "Union_Discriminator_octet"; -constexpr const char* union_char_discriminator_name = "Union_Discriminator_char"; -constexpr const char* union_wchar_discriminator_name = "Union_Discriminator_wchar"; -constexpr const char* union_enum_discriminator_name = "Union_Discriminator_enum"; -constexpr const char* union_enum_label_discriminator_name = "Union_Discriminator_enum_labels"; -constexpr const char* union_alias_discriminator_name = "Union_Discriminator_alias"; -constexpr const char* union_several_fields_name = "Union_Several_Fields"; -constexpr const char* union_several_fields_with_default_name = "Union_Several_Fields_With_Default"; - -constexpr const char* var_union_short_name = "var_union_short"; -constexpr const char* var_union_ushort_name = "var_union_ushort"; -constexpr const char* var_union_long_name = "var_union_long"; -constexpr const char* var_union_ulong_name = "var_union_ulong"; -constexpr const char* var_union_long_long_name = "var_union_long_long"; -constexpr const char* var_union_ulong_long_name = "var_union_ulong_long"; -constexpr const char* var_union_float_name = "var_union_float"; -constexpr const char* var_union_double_name = "var_union_double"; -constexpr const char* var_union_long_double_name = "var_union_long_double"; -constexpr const char* var_union_bool_name = "var_union_boolean"; -constexpr const char* var_union_byte_name = "var_union_octet"; -constexpr const char* var_union_char_name = "var_union_char"; -constexpr const char* var_union_wchar_name = "var_union_wchar"; -constexpr const char* var_union_string_name = "var_union_string"; -constexpr const char* var_union_wstring_name = "var_union_wstring"; -constexpr const char* var_union_bounded_string_name = "var_union_bounded_string"; -constexpr const char* var_union_bounded_wstring_name = "var_union_bounded_wstring"; -constexpr const char* var_union_enum_name = "var_union_my_enum"; -constexpr const char* var_union_bitmask_name = "var_union_my_bit_mask"; -constexpr const char* var_union_alias_name = "var_union_my_alias"; -constexpr const char* var_union_array_name = "var_union_array"; -constexpr const char* var_union_seq_name = "var_union_sequence"; -constexpr const char* var_union_map_name = "var_union_map"; -constexpr const char* var_union_union_name = "var_union_my_union"; -constexpr const char* var_union_struct_name = "var_union_my_structure"; -constexpr const char* var_union_bitset_name = "var_union_my_bitset"; -constexpr const char* var_union_short_discriminator_name = "var_union_discriminator_short"; -constexpr const char* var_union_ushort_discriminator_name = "var_union_discriminator_ushort"; -constexpr const char* var_union_long_discriminator_name = "var_union_discriminator_long"; -constexpr const char* var_union_ulong_discriminator_name = "var_union_discriminator_ulong"; -constexpr const char* var_union_long_long_discriminator_name = "var_union_discriminator_long_long"; -constexpr const char* var_union_ulong_long_discriminator_name = "var_union_discriminator_ulong_long"; -constexpr const char* var_union_bool_discriminator_name = "var_union_discriminator_boolean"; -constexpr const char* var_union_byte_discriminator_name = "var_union_discriminator_octet"; -constexpr const char* var_union_char_discriminator_name = "var_union_discriminator_char"; -constexpr const char* var_union_wchar_discriminator_name = "var_union_discriminator_wchar"; -constexpr const char* var_union_enum_discriminator_name = "var_union_discriminator_enum"; -constexpr const char* var_union_alias_discriminator_name = "var_union_discriminator_alias"; -constexpr const char* var_union_several_fields_name = "var_union_several_fields"; -constexpr const char* var_union_several_fields_with_default_name = "var_union_several_fields_with_default"; - -constexpr const char* var_union_member_a = "a"; -constexpr const char* var_union_member_b = "b"; -constexpr const char* var_union_member_c = "c"; -constexpr const char* var_union_member_d = "d"; -constexpr const char* var_union_member_e = "e"; -constexpr const char* var_union_member_f = "f"; -constexpr const char* var_union_member_g = "g"; -constexpr const char* var_union_member_h = "h"; -constexpr const char* var_union_member_i = "i"; -constexpr const char* var_union_member_j = "j"; -constexpr const char* var_union_member_k = "k"; -constexpr const char* var_union_member_l = "l"; -constexpr const char* var_union_member_m = "m"; -constexpr const char* var_union_member_n = "n"; -constexpr const char* var_union_member_o = "o"; -constexpr const char* var_union_member_bn = "bn"; -constexpr const char* var_union_member_bo = "bo"; -constexpr const char* var_union_member_p = "p"; -constexpr const char* var_union_member_q = "q"; -constexpr const char* var_union_member_r = "r"; -constexpr const char* var_union_member_s = "s"; -constexpr const char* var_union_member_t = "t"; -constexpr const char* var_union_member_u = "u"; -constexpr const char* var_union_member_v = "v"; -constexpr const char* var_union_member_w = "w"; -constexpr const char* var_union_member_x = "x"; -constexpr const char* var_union_first_member = "first"; -constexpr const char* var_union_second_member = "second"; -constexpr const char* var_union_third_member = "third"; +constexpr const char* struct_union_short_name {"UnionShort"}; +constexpr const char* struct_union_ushort_name {"UnionUShort"}; +constexpr const char* struct_union_long_name {"UnionLong"}; +constexpr const char* struct_union_ulong_name {"UnionULong"}; +constexpr const char* struct_union_long_long_name {"UnionLongLong"}; +constexpr const char* struct_union_ulong_long_name {"UnionULongLong"}; +constexpr const char* struct_union_float_name {"UnionFloat"}; +constexpr const char* struct_union_double_name {"UnionDouble"}; +constexpr const char* struct_union_long_double_name {"UnionLongDouble"}; +constexpr const char* struct_union_bool_name {"UnionBoolean"}; +constexpr const char* struct_union_byte_name {"UnionOctet"}; +constexpr const char* struct_union_char_name {"UnionChar"}; +constexpr const char* struct_union_wchar_name {"UnionWChar"}; +constexpr const char* struct_union_string_name {"UnionString"}; +constexpr const char* struct_union_wstring_name {"UnionWString"}; +constexpr const char* struct_union_bounded_string_name {"UnionBoundedString"}; +constexpr const char* struct_union_bounded_wstring_name {"UnionBoundedWString"}; +constexpr const char* struct_union_enum_name {"UnionInnerEnumHelper"}; +constexpr const char* struct_union_bitmask_name {"UnionInnerBitMaskHelper"}; +constexpr const char* struct_union_alias_name {"UnionInnerAliasHelper"}; +constexpr const char* struct_union_array_name {"UnionArray"}; +constexpr const char* struct_union_seq_name {"UnionSequence"}; +constexpr const char* struct_union_map_name {"UnionMap"}; +constexpr const char* struct_union_union_name {"UnionInnerUnionHelper"}; +constexpr const char* struct_union_struct_name {"UnionInnerStructureHelper"}; +constexpr const char* struct_union_bitset_name {"UnionInnerBitsetHelper"}; +constexpr const char* struct_union_short_discriminator_name {"UnionDiscriminatorShort"}; +constexpr const char* struct_union_ushort_discriminator_name {"UnionDiscriminatorUShort"}; +constexpr const char* struct_union_long_discriminator_name {"UnionDiscriminatorLong"}; +constexpr const char* struct_union_ulong_discriminator_name {"UnionDiscriminatorULong"}; +constexpr const char* struct_union_long_long_discriminator_name {"UnionDiscriminatorLongLong"}; +constexpr const char* struct_union_ulong_long_discriminator_name {"UnionDiscriminatorULongLong"}; +constexpr const char* struct_union_bool_discriminator_name {"UnionDiscriminatorBoolean"}; +constexpr const char* struct_union_byte_discriminator_name {"UnionDiscriminatorOctet"}; +constexpr const char* struct_union_char_discriminator_name {"UnionDiscriminatorChar"}; +constexpr const char* struct_union_wchar_discriminator_name {"UnionDiscriminatorWChar"}; +constexpr const char* struct_union_enum_discriminator_name {"UnionDiscriminatorEnum"}; +constexpr const char* struct_union_enum_label_discriminator_name {"UnionDiscriminatorEnumLabel"}; +constexpr const char* struct_union_alias_discriminator_name {"UnionDiscriminatorAlias"}; +constexpr const char* struct_union_several_fields_name {"UnionSeveralFields"}; +constexpr const char* struct_union_several_fields_with_default_name {"UnionSeveralFieldsWithDefault"}; +constexpr const char* struct_union_short_extra_member_name {"UnionShortExtraMember"}; +constexpr const char* struct_union_fixed_string_alias_name {"UnionFixedStringAlias"}; + +constexpr const char* union_short_name {"Union_Short"}; +constexpr const char* union_ushort_name {"Union_UShort"}; +constexpr const char* union_long_name {"Union_Long"}; +constexpr const char* union_ulong_name {"Union_ULong"}; +constexpr const char* union_long_long_name {"Union_LongLong"}; +constexpr const char* union_ulong_long_name {"Union_ULongLOng"}; +constexpr const char* union_float_name {"Union_Float"}; +constexpr const char* union_double_name {"Union_Double"}; +constexpr const char* union_long_double_name {"Union_LongDouble"}; +constexpr const char* union_bool_name {"Union_Boolean"}; +constexpr const char* union_byte_name {"Union_Octet"}; +constexpr const char* union_char_name {"Union_Char"}; +constexpr const char* union_wchar_name {"Union_WChar"}; +constexpr const char* union_string_name {"Union_String"}; +constexpr const char* union_wstring_name {"Union_WString"}; +constexpr const char* union_bounded_string_name {"Union_BoundedString"}; +constexpr const char* union_bounded_wstring_name {"Union_BoundedWString"}; +constexpr const char* union_enum_name {"Union_InnerEnumHelper"}; +constexpr const char* union_bitmask_name {"Union_InnerBitMaskHelper"}; +constexpr const char* union_alias_name {"Union_InnerAliasHelper"}; +constexpr const char* union_array_name {"Union_Array"}; +constexpr const char* union_seq_name {"Union_Sequence"}; +constexpr const char* union_map_name {"Union_Map"}; +constexpr const char* union_union_name {"Union_InnerUnionHelper"}; +constexpr const char* union_struct_name {"Union_InnerStructureHelper"}; +constexpr const char* union_bitset_name {"Union_InnerBitsetHelper"}; +constexpr const char* union_short_discriminator_name {"Union_Discriminator_short"}; +constexpr const char* union_ushort_discriminator_name {"Union_Discriminator_unsigned_short"}; +constexpr const char* union_long_discriminator_name {"Union_Discriminator_long"}; +constexpr const char* union_ulong_discriminator_name {"Union_Discriminator_unsigned_long"}; +constexpr const char* union_long_long_discriminator_name {"Union_Discriminator_long_long"}; +constexpr const char* union_ulong_long_discriminator_name {"Union_Discriminator_unsigned_long_long"}; +constexpr const char* union_bool_discriminator_name {"Union_Discriminator_boolean"}; +constexpr const char* union_byte_discriminator_name {"Union_Discriminator_octet"}; +constexpr const char* union_char_discriminator_name {"Union_Discriminator_char"}; +constexpr const char* union_wchar_discriminator_name {"Union_Discriminator_wchar"}; +constexpr const char* union_enum_discriminator_name {"Union_Discriminator_enum"}; +constexpr const char* union_enum_label_discriminator_name {"Union_Discriminator_enum_labels"}; +constexpr const char* union_alias_discriminator_name {"Union_Discriminator_alias"}; +constexpr const char* union_several_fields_name {"Union_Several_Fields"}; +constexpr const char* union_several_fields_with_default_name {"Union_Several_Fields_With_Default"}; +constexpr const char* union_fixed_string_in_module_alias_name {"Union_Fixed_String_In_Module_Alias"}; + +constexpr const char* alias_fixed_string_module_name {"Fixed_String_Module::fixed_string_in_module"}; + +constexpr const char* var_union_short_name {"var_union_short"}; +constexpr const char* var_union_ushort_name {"var_union_ushort"}; +constexpr const char* var_union_long_name {"var_union_long"}; +constexpr const char* var_union_ulong_name {"var_union_ulong"}; +constexpr const char* var_union_long_long_name {"var_union_long_long"}; +constexpr const char* var_union_ulong_long_name {"var_union_ulong_long"}; +constexpr const char* var_union_float_name {"var_union_float"}; +constexpr const char* var_union_double_name {"var_union_double"}; +constexpr const char* var_union_long_double_name {"var_union_long_double"}; +constexpr const char* var_union_bool_name {"var_union_boolean"}; +constexpr const char* var_union_byte_name {"var_union_octet"}; +constexpr const char* var_union_char_name {"var_union_char"}; +constexpr const char* var_union_wchar_name {"var_union_wchar"}; +constexpr const char* var_union_string_name {"var_union_string"}; +constexpr const char* var_union_wstring_name {"var_union_wstring"}; +constexpr const char* var_union_bounded_string_name {"var_union_bounded_string"}; +constexpr const char* var_union_bounded_wstring_name {"var_union_bounded_wstring"}; +constexpr const char* var_union_enum_name {"var_union_my_enum"}; +constexpr const char* var_union_bitmask_name {"var_union_my_bit_mask"}; +constexpr const char* var_union_alias_name {"var_union_my_alias"}; +constexpr const char* var_union_array_name {"var_union_array"}; +constexpr const char* var_union_seq_name {"var_union_sequence"}; +constexpr const char* var_union_map_name {"var_union_map"}; +constexpr const char* var_union_union_name {"var_union_my_union"}; +constexpr const char* var_union_struct_name {"var_union_my_structure"}; +constexpr const char* var_union_bitset_name {"var_union_my_bitset"}; +constexpr const char* var_union_short_discriminator_name {"var_union_discriminator_short"}; +constexpr const char* var_union_ushort_discriminator_name {"var_union_discriminator_ushort"}; +constexpr const char* var_union_long_discriminator_name {"var_union_discriminator_long"}; +constexpr const char* var_union_ulong_discriminator_name {"var_union_discriminator_ulong"}; +constexpr const char* var_union_long_long_discriminator_name {"var_union_discriminator_long_long"}; +constexpr const char* var_union_ulong_long_discriminator_name {"var_union_discriminator_ulong_long"}; +constexpr const char* var_union_bool_discriminator_name {"var_union_discriminator_boolean"}; +constexpr const char* var_union_byte_discriminator_name {"var_union_discriminator_octet"}; +constexpr const char* var_union_char_discriminator_name {"var_union_discriminator_char"}; +constexpr const char* var_union_wchar_discriminator_name {"var_union_discriminator_wchar"}; +constexpr const char* var_union_enum_discriminator_name {"var_union_discriminator_enum"}; +constexpr const char* var_union_alias_discriminator_name {"var_union_discriminator_alias"}; +constexpr const char* var_union_several_fields_name {"var_union_several_fields"}; +constexpr const char* var_union_several_fields_with_default_name {"var_union_several_fields_with_default"}; +constexpr const char* var_union_fixed_string_in_module_alias_name {"var_union_fixed_string_in_module_alias"}; + +constexpr const char* var_union_member_a {"a"}; +constexpr const char* var_union_member_b {"b"}; +constexpr const char* var_union_member_c {"c"}; +constexpr const char* var_union_member_d {"d"}; +constexpr const char* var_union_member_e {"e"}; +constexpr const char* var_union_member_f {"f"}; +constexpr const char* var_union_member_g {"g"}; +constexpr const char* var_union_member_h {"h"}; +constexpr const char* var_union_member_i {"i"}; +constexpr const char* var_union_member_j {"j"}; +constexpr const char* var_union_member_k {"k"}; +constexpr const char* var_union_member_l {"l"}; +constexpr const char* var_union_member_m {"m"}; +constexpr const char* var_union_member_n {"n"}; +constexpr const char* var_union_member_o {"o"}; +constexpr const char* var_union_member_bn {"bn"}; +constexpr const char* var_union_member_bo {"bo"}; +constexpr const char* var_union_member_p {"p"}; +constexpr const char* var_union_member_q {"q"}; +constexpr const char* var_union_member_r {"r"}; +constexpr const char* var_union_member_s {"s"}; +constexpr const char* var_union_member_t {"t"}; +constexpr const char* var_union_member_u {"u"}; +constexpr const char* var_union_member_v {"v"}; +constexpr const char* var_union_member_w {"w"}; +constexpr const char* var_union_member_x {"x"}; +constexpr const char* var_union_first_member {"first"}; +constexpr const char* var_union_second_member {"second"}; +constexpr const char* var_union_third_member {"third"}; TEST_F(DynamicTypesDDSTypesTest, DDSTypesTest_UnionShort) { @@ -2799,6 +2804,74 @@ TEST_F(DynamicTypesDDSTypesTest, DDSTypesTest_UnionShortExtraMember) EXPECT_EQ(DynamicDataFactory::get_instance()->delete_data(data), RETCODE_OK); } +TEST_F(DynamicTypesDDSTypesTest, DDSTypesTest_UnionFixedStringAlias) +{ + TypeDescriptor::_ref_type type_descriptor {traits::make_shared()}; + type_descriptor->kind(TK_STRUCTURE); + type_descriptor->name(struct_union_fixed_string_alias_name); + DynamicTypeBuilder::_ref_type struct_builder {DynamicTypeBuilderFactory::get_instance()->create_type(type_descriptor)}; + + type_descriptor = traits::make_shared(); + type_descriptor->kind(TK_UNION); + type_descriptor->name(union_fixed_string_in_module_alias_name); + type_descriptor->discriminator_type(DynamicTypeBuilderFactory::get_instance()->get_primitive_type(TK_INT32)); + DynamicTypeBuilder::_ref_type union_builder {DynamicTypeBuilderFactory::get_instance()->create_type(type_descriptor)}; + + type_descriptor = traits::make_shared(); + type_descriptor->kind(TK_ALIAS); + type_descriptor->name(alias_fixed_string_module_name); + type_descriptor->base_type(DynamicTypeBuilderFactory::get_instance()->create_string_type(20)->build()); + + MemberDescriptor::_ref_type member_descriptor {traits::make_shared()}; + member_descriptor->name(var_union_member_a); + member_descriptor->type(DynamicTypeBuilderFactory::get_instance()->create_type(type_descriptor)->build()); + member_descriptor->label({0}); + union_builder->add_member(member_descriptor); + + member_descriptor = traits::make_shared(); + member_descriptor->name(var_union_fixed_string_in_module_alias_name); + member_descriptor->type(union_builder->build()); + struct_builder->add_member(member_descriptor); + + DynamicType::_ref_type struct_type {struct_builder->build()}; + + DynamicData::_ref_type data {DynamicDataFactory::get_instance()->create_data(struct_type)}; + ASSERT_TRUE(data); + + DynamicData::_ref_type union_data = + data->loan_value(data->get_member_id_by_name(var_union_fixed_string_in_module_alias_name)); + ASSERT_TRUE(union_data); + + // Set value for fixed string + const std::string value {"Test"}; + std::string test_value; + EXPECT_EQ(union_data->set_string_value(union_data->get_member_id_by_name(var_union_member_a), value), RETCODE_OK); + EXPECT_EQ(data->return_loaned_value(union_data), RETCODE_OK); + + union_data = + data->loan_value(data->get_member_id_by_name(var_union_fixed_string_in_module_alias_name)); + ASSERT_TRUE(union_data); + EXPECT_EQ(union_data->get_string_value(test_value, union_data->get_member_id_by_name( + var_union_member_a)), RETCODE_OK); + EXPECT_EQ(value, test_value); + EXPECT_EQ(data->return_loaned_value(union_data), RETCODE_OK); + + for (auto encoding : encodings) + { + UnionFixedStringAlias struct_data; + TypeSupport static_pubsubType {new UnionFixedStringAliasPubSubType()}; + check_serialization_deserialization(struct_type, data, encoding, struct_data, + static_pubsubType); + EXPECT_EQ(struct_data.var_union_fixed_string_in_module_alias().a(), test_value); + } + + xtypes::TypeIdentifierPair static_type_ids; + register_UnionFixedStringAlias_type_identifier(static_type_ids); + check_typeobject_registry(struct_type, static_type_ids); + + EXPECT_EQ(DynamicDataFactory::get_instance()->delete_data(data), RETCODE_OK); +} + // This union is custom and serves to test a specific case used in internal type of DDS X-Types (TypeIdentifier). // No supported by Dynamic Language Binding. // TEST_F(DynamicTypesDDSTypesTest, DDSTypesTest_DefaultAnnotation) diff --git a/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypeCdrAux.hpp b/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypeCdrAux.hpp index fac8f0bf499..af7f2f5ce2d 100644 --- a/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypeCdrAux.hpp +++ b/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypeCdrAux.hpp @@ -43,8 +43,6 @@ eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const StructType& data); - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const ContentFilterTestType& data); diff --git a/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypeCdrAux.ipp b/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypeCdrAux.ipp index 47059d67d30..dfba53091ef 100644 --- a/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypeCdrAux.ipp +++ b/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypeCdrAux.ipp @@ -253,8 +253,6 @@ void serialize_key( } - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypePubSubTypes.cxx b/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypePubSubTypes.cxx index 2585b44b7fa..df06bb41a8f 100644 --- a/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypePubSubTypes.cxx +++ b/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypePubSubTypes.cxx @@ -212,8 +212,6 @@ void StructTypePubSubType::register_type_object_representation() register_StructType_type_identifier(type_identifiers_); } - - ContentFilterTestTypePubSubType::ContentFilterTestTypePubSubType() { set_name("ContentFilterTestType"); diff --git a/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypePubSubTypes.hpp b/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypePubSubTypes.hpp index fe817ca2f89..af5d966da5c 100644 --- a/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypePubSubTypes.hpp +++ b/test/unittest/dds/topic/DDSSQLFilter/data_types/ContentFilterTestTypePubSubTypes.hpp @@ -119,8 +119,6 @@ class StructTypePubSubType : public eprosima::fastdds::dds::TopicDataType }; - - /*! * @brief This class represents the TopicDataType of the type ContentFilterTestType defined by the user in the IDL file. * @ingroup ContentFilterTestType diff --git a/test/unittest/dds/xtypes/serializers/idl/types/union_struct/gen/union_struct.hpp b/test/unittest/dds/xtypes/serializers/idl/types/union_struct/gen/union_struct.hpp index eae3ccb64e6..0b504d56056 100644 --- a/test/unittest/dds/xtypes/serializers/idl/types/union_struct/gen/union_struct.hpp +++ b/test/unittest/dds/xtypes/serializers/idl/types/union_struct/gen/union_struct.hpp @@ -377,7 +377,10 @@ class BasicUnion } selected_member_ = 0x00000001; - member_destructor_ = [&]() {m_first.~basic_string();}; + member_destructor_ = [&]() + { + m_first.~basic_string(); + }; new(&m_first) std::string(); } @@ -430,7 +433,10 @@ class ComplexUnion eProsima_user_DllExport ComplexUnion() { selected_member_ = 0x00000002; - member_destructor_ = [&]() {m_fourth.~BasicUnion();}; + member_destructor_ = [&]() + { + m_fourth.~BasicUnion(); + }; new(&m_fourth) BasicUnion(); } @@ -757,7 +763,10 @@ class ComplexUnion } selected_member_ = 0x00000002; - member_destructor_ = [&]() {m_fourth.~BasicUnion();}; + member_destructor_ = [&]() + { + m_fourth.~BasicUnion(); + }; new(&m_fourth) BasicUnion(); } diff --git a/test/unittest/dds/xtypes/serializers/json/types/comprehensive_type/gen/ComprehensiveType.hpp b/test/unittest/dds/xtypes/serializers/json/types/comprehensive_type/gen/ComprehensiveType.hpp index 2823e0c00f6..8a8e7b05b1f 100644 --- a/test/unittest/dds/xtypes/serializers/json/types/comprehensive_type/gen/ComprehensiveType.hpp +++ b/test/unittest/dds/xtypes/serializers/json/types/comprehensive_type/gen/ComprehensiveType.hpp @@ -1052,7 +1052,10 @@ class InnerUnion } selected_member_ = 0x00000010; - member_destructor_ = [&]() {m_first.~PrimitivesStruct();}; + member_destructor_ = [&]() + { + m_first.~PrimitivesStruct(); + }; new(&m_first) PrimitivesStruct(); } @@ -1105,7 +1108,10 @@ class ComplexUnion eProsima_user_DllExport ComplexUnion() { selected_member_ = 0x00000002; - member_destructor_ = [&]() {m_fourth.~InnerUnion();}; + member_destructor_ = [&]() + { + m_fourth.~InnerUnion(); + }; new(&m_fourth) InnerUnion(); } @@ -1432,7 +1438,10 @@ class ComplexUnion } selected_member_ = 0x00000002; - member_destructor_ = [&]() {m_fourth.~InnerUnion();}; + member_destructor_ = [&]() + { + m_fourth.~InnerUnion(); + }; new(&m_fourth) InnerUnion(); } diff --git a/test/unittest/dds/xtypes/serializers/json/types/comprehensive_type/gen/ComprehensiveTypeCdrAux.hpp b/test/unittest/dds/xtypes/serializers/json/types/comprehensive_type/gen/ComprehensiveTypeCdrAux.hpp index db816b7a31a..8403b61ee56 100644 --- a/test/unittest/dds/xtypes/serializers/json/types/comprehensive_type/gen/ComprehensiveTypeCdrAux.hpp +++ b/test/unittest/dds/xtypes/serializers/json/types/comprehensive_type/gen/ComprehensiveTypeCdrAux.hpp @@ -49,15 +49,6 @@ eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const PrimitivesStruct& data); - - - - - - - - - eProsima_user_DllExport void serialize_key( eprosima::fastcdr::Cdr& scdr, const AllStruct& data); diff --git a/test/unittest/dds/xtypes/serializers/json/types/comprehensive_type/gen/ComprehensiveTypeCdrAux.ipp b/test/unittest/dds/xtypes/serializers/json/types/comprehensive_type/gen/ComprehensiveTypeCdrAux.ipp index 3173240ee07..6f60c7c19af 100644 --- a/test/unittest/dds/xtypes/serializers/json/types/comprehensive_type/gen/ComprehensiveTypeCdrAux.ipp +++ b/test/unittest/dds/xtypes/serializers/json/types/comprehensive_type/gen/ComprehensiveTypeCdrAux.ipp @@ -253,12 +253,6 @@ void serialize_key( } - - - - - - template<> eProsima_user_DllExport size_t calculate_serialized_size( eprosima::fastcdr::CdrSizeCalculator& calculator, diff --git a/test/unittest/dds/xtypes/serializers/json/types/comprehensive_type/gen/ComprehensiveTypePubSubTypes.cxx b/test/unittest/dds/xtypes/serializers/json/types/comprehensive_type/gen/ComprehensiveTypePubSubTypes.cxx index 3b6bdabff68..95347e2b0e8 100644 --- a/test/unittest/dds/xtypes/serializers/json/types/comprehensive_type/gen/ComprehensiveTypePubSubTypes.cxx +++ b/test/unittest/dds/xtypes/serializers/json/types/comprehensive_type/gen/ComprehensiveTypePubSubTypes.cxx @@ -212,15 +212,6 @@ void PrimitivesStructPubSubType::register_type_object_representation() register_PrimitivesStruct_type_identifier(type_identifiers_); } - - - - - - - - - AllStructPubSubType::AllStructPubSubType() { set_name("AllStruct"); diff --git a/test/unittest/dds/xtypes/serializers/json/types/comprehensive_type/gen/ComprehensiveTypePubSubTypes.hpp b/test/unittest/dds/xtypes/serializers/json/types/comprehensive_type/gen/ComprehensiveTypePubSubTypes.hpp index 984eaf6935c..ff05df51293 100644 --- a/test/unittest/dds/xtypes/serializers/json/types/comprehensive_type/gen/ComprehensiveTypePubSubTypes.hpp +++ b/test/unittest/dds/xtypes/serializers/json/types/comprehensive_type/gen/ComprehensiveTypePubSubTypes.hpp @@ -118,16 +118,11 @@ class PrimitivesStructPubSubType : public eprosima::fastdds::dds::TopicDataType unsigned char* key_buffer_; }; - - typedef PrimitivesStruct MyAliasedStruct; typedef MyEnum MyAliasedEnum; typedef eprosima::fastcdr::fixed_string<100> MyAliasedBoundedString; typedef MyAliasedEnum MyRecursiveAlias; - - - /*! * @brief This class represents the TopicDataType of the type AllStruct defined by the user in the IDL file. * @ingroup ComprehensiveType diff --git a/thirdparty/dds-types-test b/thirdparty/dds-types-test index 923dc5986cc..eff497269ee 160000 --- a/thirdparty/dds-types-test +++ b/thirdparty/dds-types-test @@ -1 +1 @@ -Subproject commit 923dc5986cc64bf34ceee2b20fdcb4c045907672 +Subproject commit eff497269eebe9dba3559f921b4e749804bf975c