 |
Fast RTPS
Version 2.1.0
Fast RTPS
|
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>
25 class AnnotationDescriptor;
27 class MemberDescriptor;
29 class 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);
167 #endif // TYPES_DYNAMIC_TYPE_BUILDER_H
uint32_t MemberId
Definition: TypesBase.h:272
ReturnCode_t get_all_members(std::map< MemberId, DynamicTypeMember * > &members)
MemberId current_member_id_
Definition: DynamicTypeBuilder.h:50
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)
bool exists_member_by_name(const std::string &name) const
RTPS_DllAPI ReturnCode_t add_member(MemberId id, const std::string &name, DynamicTypeBuilder *type_, const std::string &defaultValue)
RTPS_DllAPI ReturnCode_t add_member(MemberId id, const std::string &name, DynamicType_ptr type_, const std::string &defaultValue)
RTPS_DllAPI ReturnCode_t add_member(MemberId id, const std::string &name, DynamicTypeBuilder *type_=nullptr)
ReturnCode_t _apply_annotation_to_member(MemberId id, AnnotationDescriptor &descriptor)
void refresh_member_ids()
uint32_t max_index_
Definition: DynamicTypeBuilder.h:51
Definition: DynamicType.h:38
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)
std::map< MemberId, DynamicTypeMember * > member_by_id_
Definition: DynamicTypeBuilder.h:46
ReturnCode_t _apply_annotation_to_member(MemberId id, const std::string &annotation_name, const std::string &key, const std::string &value)
TypeKind kind_
Definition: DynamicTypeBuilder.h:49
Definition: AnnotationDescriptor.h:29
Definition: TypeDescriptor.h:29
Definition: MemberDescriptor.h:29
DynamicTypeBuilder(const TypeDescriptor *descriptor)
octet TypeKind
Definition: TypesBase.h:115
Definition: DynamicTypeBuilder.h:32
DynamicTypeBuilder(const DynamicTypeBuilder *builder)
RTPS_DllAPI MemberId get_member_id_by_name(const std::string &name) const
bool check_union_configuration(const MemberDescriptor *descriptor)
Definition: TypesBase.h:204
TypeDescriptor * descriptor_
Definition: DynamicTypeBuilder.h:45
RTPS_DllAPI ReturnCode_t add_member(const MemberDescriptor *descriptor)
const TypeDescriptor * get_type_descriptor() const
Definition: DynamicTypeBuilder.h:151
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 std::string get_name() const
RTPS_DllAPI ReturnCode_t apply_annotation_to_member(MemberId id, AnnotationDescriptor &descriptor)
RTPS_DllAPI ReturnCode_t set_name(const std::string &name)
Definition: DynamicTypeBuilderFactory.h:40
RTPS_DllAPI ReturnCode_t apply_annotation(const std::string &annotation_name, const std::string &key, const std::string &value)
bool is_discriminator_type() const
RTPS_DllAPI ReturnCode_t add_empty_member(uint32_t index, const std::string &name)
ReturnCode_t copy_from_builder(const DynamicTypeBuilder *other)
RTPS_DllAPI ReturnCode_t copy_from(const DynamicTypeBuilder *other)
std::map< std::string, DynamicTypeMember * > member_by_name_
Definition: DynamicTypeBuilder.h:47
RTPS_DllAPI TypeKind get_kind() const
Definition: DynamicTypeBuilder.h:142
bool is_consistent() const
Definition: DynamicTypePtr.h:27
eProsima namespace.
Definition: LibrarySettingsAttributes.h:23
std::string name_
Definition: DynamicTypeBuilder.h:48
RTPS_DllAPI DynamicType_ptr build()
RTPS_DllAPI ReturnCode_t apply_annotation(AnnotationDescriptor &descriptor)
virtual ~DynamicTypeBuilder()
RTPS_DllAPI ReturnCode_t add_member(MemberId id, const std::string &name, DynamicType_ptr type_=DynamicType_ptr(nullptr))