15#ifndef TYPES_DYNAMIC_TYPE_BUILDER_H
16#define TYPES_DYNAMIC_TYPE_BUILDER_H
18#include <fastrtps/types/TypesBase.h>
19#include <fastrtps/types/DynamicTypePtr.h>
25class AnnotationDescriptor;
27class MemberDescriptor;
29class DynamicTypeMember;
59 const std::string& annotation_name,
60 const std::string& key,
61 const std::string& value);
77 const std::string& name);
83 const std::string& name,
88 const std::string& name,
90 const std::string& defaultValue);
94 const std::string& name,
96 const std::string& defaultValue,
97 const std::vector<uint64_t>& unionLabels,
102 const std::string& name,
107 const std::string& name,
109 const std::string& defaultValue);
113 const std::string& name,
115 const std::string& defaultValue,
116 const std::vector<uint64_t>& unionLabels,
117 bool isDefaultLabel);
122 const std::string& annotation_name,
123 const std::string& key,
124 const std::string& value);
132 const std::string& annotation_name,
133 const std::string& key,
134 const std::string& value);
Definition AnnotationDescriptor.h:29
Definition DynamicTypePtr.h:27
Definition DynamicTypeBuilderFactory.h:40
Definition DynamicTypeBuilder.h:32
RTPS_DllAPI ReturnCode_t add_member(MemberId id, const std::string &name, DynamicType_ptr type_, const std::string &defaultValue, const std::vector< uint64_t > &unionLabels, bool isDefaultLabel)
RTPS_DllAPI ReturnCode_t add_member(MemberId id, const std::string &name, DynamicType_ptr type_=DynamicType_ptr(nullptr))
MemberId current_member_id_
Definition DynamicTypeBuilder.h:50
RTPS_DllAPI ReturnCode_t add_member(const MemberDescriptor *descriptor)
ReturnCode_t copy_from_builder(const DynamicTypeBuilder *other)
RTPS_DllAPI ReturnCode_t add_member(MemberId id, const std::string &name, DynamicTypeBuilder *type_, const std::string &defaultValue, const std::vector< uint64_t > &unionLabels, bool isDefaultLabel)
ReturnCode_t _apply_annotation_to_member(MemberId id, AnnotationDescriptor &descriptor)
RTPS_DllAPI MemberId get_member_id_by_name(const std::string &name) const
RTPS_DllAPI ReturnCode_t add_member(MemberId id, const std::string &name, DynamicType_ptr type_, const std::string &defaultValue)
const TypeDescriptor * get_type_descriptor() const
Definition DynamicTypeBuilder.h:151
RTPS_DllAPI ReturnCode_t set_name(const std::string &name)
RTPS_DllAPI TypeKind get_kind() const
Definition DynamicTypeBuilder.h:142
RTPS_DllAPI ReturnCode_t add_member(MemberId id, const std::string &name, DynamicTypeBuilder *type_=nullptr)
std::string name_
Definition DynamicTypeBuilder.h:48
RTPS_DllAPI ReturnCode_t apply_annotation(AnnotationDescriptor &descriptor)
DynamicTypeBuilder(const DynamicTypeBuilder *builder)
RTPS_DllAPI std::string get_name() const
TypeDescriptor * descriptor_
Definition DynamicTypeBuilder.h:45
ReturnCode_t get_all_members(std::map< MemberId, DynamicTypeMember * > &members)
DynamicTypeBuilder(const TypeDescriptor *descriptor)
RTPS_DllAPI ReturnCode_t add_empty_member(uint32_t index, const std::string &name)
std::map< MemberId, DynamicTypeMember * > member_by_id_
Definition DynamicTypeBuilder.h:46
virtual ~DynamicTypeBuilder()
ReturnCode_t _apply_annotation_to_member(MemberId id, const std::string &annotation_name, const std::string &key, const std::string &value)
RTPS_DllAPI ReturnCode_t apply_annotation_to_member(MemberId id, const std::string &annotation_name, const std::string &key, const std::string &value)
RTPS_DllAPI ReturnCode_t add_member(MemberId id, const std::string &name, DynamicTypeBuilder *type_, const std::string &defaultValue)
TypeKind kind_
Definition DynamicTypeBuilder.h:49
std::map< std::string, DynamicTypeMember * > member_by_name_
Definition DynamicTypeBuilder.h:47
bool is_consistent() const
void refresh_member_ids()
RTPS_DllAPI ReturnCode_t apply_annotation(const std::string &annotation_name, const std::string &key, const std::string &value)
uint32_t max_index_
Definition DynamicTypeBuilder.h:51
bool is_discriminator_type() const
bool exists_member_by_name(const std::string &name) const
RTPS_DllAPI ReturnCode_t copy_from(const DynamicTypeBuilder *other)
RTPS_DllAPI ReturnCode_t apply_annotation_to_member(MemberId id, AnnotationDescriptor &descriptor)
RTPS_DllAPI DynamicType_ptr build()
bool check_union_configuration(const MemberDescriptor *descriptor)
Definition DynamicType.h:38
Definition MemberDescriptor.h:29
This class represents the enumeration ReturnCode_t.
Definition TypesBase.h:190
Definition TypeDescriptor.h:30
uint32_t MemberId
Definition TypesBase.h:285
octet TypeKind
Definition TypesBase.h:120
eProsima namespace.
Definition LibrarySettingsAttributes.h:23