25 #ifndef _DDS_XTYPES_DTYPE_HH 26 #define _DDS_XTYPES_DTYPE_HH 30 #include <dds/xtypes_typeobject.hh> 31 #include <dds/dds_typesupport.hh> 44 class DynamicTypeMember;
45 class DynamicTypeBuilder;
48 class DynamicDataReader;
49 class DynamicDataWriter;
51 DECLARE_CPP_UNBOUNDED_SEQ(
char *,
StringSeq );
52 DECLARE_CPP_UNBOUNDED_SEQ(
char *, IncludePathSeq );
53 DECLARE_CPP_UNBOUNDED_SEQ(
int, Int32Seq );
54 DECLARE_CPP_UNBOUNDED_SEQ(
unsigned int, UInt32Seq );
55 DECLARE_CPP_UNBOUNDED_SEQ(
short, Int16Seq );
56 DECLARE_CPP_UNBOUNDED_SEQ(
unsigned short, UInt16Seq );
57 DECLARE_CPP_UNBOUNDED_SEQ( int64_t, Int64Seq );
58 DECLARE_CPP_UNBOUNDED_SEQ( uint64_t, UInt64Seq );
59 DECLARE_CPP_UNBOUNDED_SEQ(
float, Float32Seq );
60 DECLARE_CPP_UNBOUNDED_SEQ(
double, Float64Seq );
61 DECLARE_CPP_UNBOUNDED_SEQ(
char, CharSeq );
62 DECLARE_CPP_UNBOUNDED_SEQ( cdx_char32_t, WcharSeq );
63 DECLARE_CPP_UNBOUNDED_SEQ(
unsigned char, BooleanSeq );
64 DECLARE_CPP_UNBOUNDED_SEQ(
unsigned char, ByteSeq );
65 DECLARE_CPP_UNBOUNDED_SEQ( cdx_char32_t *, WstringSeq );
67 DDS_CPP_MAP_DECLARE(
char *,
char *, coredx_map_compare_string, Parameters);
68 DDS_CPP_MAP_DECLARE(
char *, DynamicTypeMember *, coredx_map_compare_string, DynamicTypeMembersByName);
69 DDS_CPP_MAP_DECLARE(MemberId, DynamicTypeMember *, coredx_map_compare_uint32, DynamicTypeMembersById);
115 virtual class DynamicType * get_primitive_type (
const TypeKind kind ) = 0;
154 virtual class DynamicTypeBuilder * create_type_w_type_object (
const struct TypeObject * type_object ) = 0;
172 virtual class DynamicTypeBuilder * create_string_type (
const unsigned int bound ) = 0;
190 virtual class DynamicTypeBuilder * create_wstring_type (
const unsigned int bound ) = 0;
213 const unsigned int bound ) = 0;
240 const BoundSeq * bound ) = 0;
266 const unsigned int bound ) = 0;
278 virtual class DynamicTypeBuilder * create_bitset_type (
const unsigned int bound ) = 0;
310 const char * type_name,
311 const IncludePathSeq * include_paths ) = 0;
342 const char * type_name,
343 const IncludePathSeq * include_paths ) = 0;
380 virtual class DynamicTypeBuilder * create_enumeration_type(
const unsigned int bound = 32 ) = 0;
450 const char * type_name ) = 0;
455 virtual const char * get_type_name ( ) = 0;
466 virtual TypeSupport * narrow ( ) = 0;
474 virtual DataReader * alloc_datareader ( ) = 0;
475 virtual DataWriter * alloc_datawriter ( ) = 0;
528 const char * value );
543 unsigned char is_consistent ( );
648 unsigned char is_consistent ( );
669 char * default_value;
671 UnionCaseLabelSeq label;
672 unsigned char default_label;
701 unsigned char is_consistent ( );
737 virtual unsigned int get_annotation_count ( ) = 0;
744 const unsigned int idx ) = 0;
757 virtual MemberId get_id ( ) = 0;
763 virtual const char * get_name ( ) = 0;
767 virtual MemberFlag get_flags ( ) = 0;
806 virtual const char * get_name ( ) = 0;
812 virtual TypeKind get_kind ( ) = 0;
826 const char * name ) = 0;
834 virtual ReturnCode_t get_all_members_by_name ( DynamicTypeMembersByName * member ) = 0;
848 const MemberId
id ) = 0;
856 virtual ReturnCode_t get_all_members ( DynamicTypeMembersById * member ) = 0;
862 virtual unsigned int get_annotation_count ( ) = 0;
869 const unsigned int idx ) = 0;
876 virtual unsigned char equals (
const class DynamicType * other ) = 0;
949 virtual const char * get_name ( ) = 0;
956 virtual TypeKind get_kind ( ) = 0;
970 const char * name )
const = 0;
978 virtual ReturnCode_t get_all_members_by_name ( DynamicTypeMembersByName * member )
const = 0;
992 const MemberId
id )
const = 0;
1000 virtual ReturnCode_t get_all_members ( DynamicTypeMembersById * member )
const = 0;
1006 virtual unsigned int get_annotation_count ( ) = 0;
1013 const unsigned int * idx ) = 0;
1020 virtual unsigned char equals (
const class DynamicType * other ) = 0;
1143 virtual const class DynamicType * get_type (
void ) = 0;
1152 const MemberId
id ) = 0;
1156 virtual ReturnCode_t set_descriptor (
const MemberId
id,
1171 virtual unsigned char equals (
const class DynamicData * other ) = 0;
1175 virtual MemberId get_member_id_by_name (
const char * name ) = 0;
1179 virtual MemberId get_member_id_at_index (
const unsigned int index ) = 0;
1201 virtual unsigned int get_item_count ( ) = 0;
1207 virtual ReturnCode_t get_name_by_id (
const char ** name_str,
1208 const MemberId
id ) = 0;
1245 virtual ReturnCode_t clear_value (
const MemberId
id ) = 0;
1263 virtual class DynamicData * loan_value (
const MemberId
id ) = 0;
1291 const MemberId
id ) = 0;
1302 virtual ReturnCode_t set_int32_value (
const MemberId
id,
1303 const int value ) = 0;
1314 virtual ReturnCode_t get_uint32_value (
unsigned int * value,
1315 const MemberId
id ) = 0;
1326 virtual ReturnCode_t set_uint32_value (
const MemberId
id,
1327 const unsigned int value ) = 0;
1339 const MemberId
id ) = 0;
1350 virtual ReturnCode_t set_int16_value (
const MemberId
id,
1351 const short value ) = 0;
1362 virtual ReturnCode_t get_uint16_value (
unsigned short * value,
1363 const MemberId
id ) = 0;
1374 virtual ReturnCode_t set_uint16_value (
const MemberId
id,
1375 const unsigned short value ) = 0;
1386 virtual ReturnCode_t get_int64_value ( int64_t * value,
1387 const MemberId
id ) = 0;
1398 virtual ReturnCode_t set_int64_value (
const MemberId
id,
1399 const int64_t value ) = 0;
1410 virtual ReturnCode_t get_uint64_value ( uint64_t * value,
1411 const MemberId
id ) = 0;
1422 virtual ReturnCode_t set_uint64_value (
const MemberId
id,
1423 const uint64_t value ) = 0;
1434 virtual ReturnCode_t get_float32_value (
float * value,
1435 const MemberId
id ) = 0;
1446 virtual ReturnCode_t set_float32_value (
const MemberId
id,
1447 const float value ) = 0;
1458 virtual ReturnCode_t get_float64_value (
double * value,
1459 const MemberId
id ) = 0;
1470 virtual ReturnCode_t set_float64_value (
const MemberId
id,
1471 const double value ) = 0;
1483 const MemberId
id ) = 0;
1494 virtual ReturnCode_t set_char8_value (
const MemberId
id,
1495 const char value ) = 0;
1506 virtual ReturnCode_t get_char32_value ( cdx_char32_t * value,
1507 const MemberId
id ) = 0;
1518 virtual ReturnCode_t set_char32_value (
const MemberId
id,
1519 const cdx_char32_t value ) = 0;
1530 virtual ReturnCode_t get_byte_value (
unsigned char * value,
1531 const MemberId
id ) = 0;
1542 virtual ReturnCode_t set_byte_value (
const MemberId
id,
1543 const unsigned char value ) = 0;
1554 virtual ReturnCode_t get_boolean_value (
unsigned char * value,
1555 const MemberId
id ) = 0;
1566 virtual ReturnCode_t set_boolean_value (
const MemberId
id,
1567 const unsigned char value ) = 0;
1578 virtual ReturnCode_t get_string_value (
char * * value,
1579 const MemberId
id ) = 0;
1590 virtual ReturnCode_t set_string_value (
const MemberId
id,
1591 const char * value ) = 0;
1602 virtual ReturnCode_t get_wstring_value ( cdx_char32_t * * value,
1603 const MemberId
id ) = 0;
1614 virtual ReturnCode_t set_wstring_value (
const MemberId
id,
1615 const cdx_char32_t * value ) = 0;
1627 const MemberId
id ) = 0;
1638 virtual ReturnCode_t set_complex_value (
const MemberId
id,
1644 virtual ReturnCode_t get_int32_values ( Int32Seq * value,
1645 const MemberId
id ) = 0;
1650 virtual ReturnCode_t set_int32_values (
const MemberId
id,
1651 const Int32Seq * value ) = 0;
1656 virtual ReturnCode_t get_uint32_values ( UInt32Seq * value,
1657 const MemberId
id ) = 0;
1662 virtual ReturnCode_t set_uint32_values (
const MemberId
id,
1663 const UInt32Seq * value ) = 0;
1668 virtual ReturnCode_t get_int16_values ( Int16Seq * value,
1669 const MemberId
id ) = 0;
1674 virtual ReturnCode_t set_int16_values (
const MemberId
id,
1675 const Int16Seq * value ) = 0;
1680 virtual ReturnCode_t get_uint16_values ( UInt16Seq * value,
1681 const MemberId
id ) = 0;
1686 virtual ReturnCode_t set_uint16_values (
const MemberId
id,
1687 const UInt16Seq * value ) = 0;
1692 virtual ReturnCode_t get_int64_values ( Int64Seq * value,
1693 const MemberId
id ) = 0;
1698 virtual ReturnCode_t set_int64_values (
const MemberId
id,
1699 const Int64Seq * value ) = 0;
1704 virtual ReturnCode_t get_uint64_values ( UInt64Seq * value,
1705 const MemberId
id ) = 0;
1710 virtual ReturnCode_t set_uint64_values (
const MemberId
id,
1711 const UInt64Seq * value ) = 0;
1716 virtual ReturnCode_t get_float32_values ( Float32Seq * value,
1717 const MemberId
id ) = 0;
1722 virtual ReturnCode_t set_float32_values (
const MemberId
id,
1723 const Float32Seq * value ) = 0;
1728 virtual ReturnCode_t get_float64_values ( Float64Seq * value,
1729 const MemberId
id ) = 0;
1734 virtual ReturnCode_t set_float64_values (
const MemberId
id,
1735 const Float64Seq * value ) = 0;
1740 virtual ReturnCode_t get_char8_values ( CharSeq * value,
1741 const MemberId
id ) = 0;
1746 virtual ReturnCode_t set_char8_values (
const MemberId
id,
1747 const CharSeq * value ) = 0;
1752 virtual ReturnCode_t get_char32_values ( WcharSeq * value,
1753 const MemberId
id ) = 0;
1758 virtual ReturnCode_t set_char32_values (
const MemberId
id,
1759 const WcharSeq * value ) = 0;
1764 virtual ReturnCode_t get_byte_values ( ByteSeq * value,
1765 const MemberId
id ) = 0;
1770 virtual ReturnCode_t set_byte_values (
const MemberId
id,
1771 const ByteSeq * value ) = 0;
1776 virtual ReturnCode_t get_boolean_values ( BooleanSeq * value,
1777 const MemberId
id ) = 0;
1782 virtual ReturnCode_t set_boolean_values (
const MemberId
id,
1783 const BooleanSeq * value ) = 0;
1789 const MemberId
id ) = 0;
1794 virtual ReturnCode_t set_string_values (
const MemberId
id,
1800 virtual ReturnCode_t get_wstring_values ( WstringSeq * value,
1801 const MemberId
id ) = 0;
1806 virtual ReturnCode_t set_wstring_values (
const MemberId
id,
1807 const WstringSeq * value ) = 0;
1813 TypeObject * DynamicType_to_TypeObject(
DynamicType * dt);
class DynamicType * base_type
the 'base_type' of this type
Definition: xtypes_dtype.hh:578
A DynamicData object represents an individual data sample. It provides reflective getters and setters...
Definition: xtypes_dtype.hh:1129
long ReturnCode_t
Definition: dds.hh:200
BoundSeq bound
The bound property indicates the bound of collection and similar types.
Definition: xtypes_dtype.hh:598
The DataWriter entity provides an interface for the application to publish (write) data...
Definition: dds.hh:2179
The DomainParticipant is used to configure, create and destroy Publisher, Subscriber and Topic object...
Definition: dds.hh:1052
An instance of DynamicType represent a type’s schema: its physical name, kind, member definitions (i...
Definition: xtypes_dtype.hh:925
A AnnotationDescriptor object comprises the state of an annotation as it is applied to some element...
Definition: xtypes_dtype.hh:485
DDS::TypeObject * TypecodeQosPolicy_to_typeobject(TypecodeQosPolicy *tc_qos)
Helper function to get DDS::TypeObject from a discovered (or otherwise obtained) TypeCode byte buffer...
The Subscriber configures, creates, manages and destroys DataReaders.
Definition: dds.hh:1743
A TypeDescriptor comprises the state of a type.
Definition: xtypes_dtype.hh:551
TopicDescription is an abstract 'class' that provides the foundation for Topic, ContentFilteredTopic...
Definition: dds.hh:1956
TypeKind kind
the 'kind' of this type
Definition: xtypes_dtype.hh:562
The DataReaderListener provides asynchronous notification of DataReader events.
Definition: dds.hh:3334
An instance of this type is responsible for creating DynamicType and DynamicTypeSupport objects...
Definition: xtypes_dtype.hh:78
This type is responsible for creating DynamicData instances.
Definition: xtypes_dtype.hh:1030
The DataReader entity allows the application to subscribe to and read data.
Definition: dds.hh:2466
A MemberDescriptor comprises the state of a DynamicTypeMember.
Definition: xtypes_dtype.hh:657
Typecode representing the datatype a DataReader reads or a DataWriter writes.
Definition: dds_builtin.hh:1456
Topic is the basic description of data to be published or subscribed.
Definition: dds.hh:1997
Provides the DDS infrastructure.
Definition: dds_builtin_basic.hh:28
class DynamicType * discriminator_type
If this descriptor represents a union type, this field indicates the type of the discriminator of the...
Definition: xtypes_dtype.hh:582
class DynamicType * element_type
If this descriptor represents an array, sequence, or string type, this property indicates the element...
Definition: xtypes_dtype.hh:612
class DynamicType * type
Definition: xtypes_dtype.hh:496
DDS::sequence< char * > StringSeq
sequence of character pointers (c strings)
Definition: dds.hh:254
Structure that holds DataWriter Quality of Service policies.
Definition: dds.hh:589
unsigned long StatusMask
Definition: dds.hh:209
The DataWriterListener provides asynchronous notification of DataWriter events.
Definition: dds.hh:3233
Structure that holds DataReader Quality of Service policies.
Definition: dds.hh:674
ObjectName name
the 'name' of this type
Definition: xtypes_dtype.hh:565
The Publisher configures, creates, manages and destroys DataWriters.
Definition: dds.hh:1534
A DynamicTypeBuilder object represents the state of a particular type defined according to the Type S...
Definition: xtypes_dtype.hh:785
A DynamicTypeMember represents a "member" of a type. A "member" in this sense may be a member of an a...
Definition: xtypes_dtype.hh:713
class DynamicType * key_element_type
If this descriptor represents a map type, this property indicates the value element type of the map...
Definition: xtypes_dtype.hh:620
The DynamicTypeSupport interface extends the TypeSupport interface defined by the DDS specification...
Definition: xtypes_dtype.hh:411