Skip to content

Commit

Permalink
Refs #21349. Fix in fastdds_python
Browse files Browse the repository at this point in the history
Signed-off-by: Ricardo González Moreno <ricardo@richiware.dev>
  • Loading branch information
richiware committed Jul 17, 2024
1 parent d3f4532 commit c7052c3
Show file tree
Hide file tree
Showing 73 changed files with 1,952 additions and 41 deletions.
2 changes: 2 additions & 0 deletions examples/cpp/configuration/ConfigurationPubSubTypes.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,8 @@ class ConfigurationPubSubType : public eprosima::fastdds::dds::TopicDataType

#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE

private:

eprosima::fastdds::MD5 md5_;
unsigned char* key_buffer_;

Expand Down
2 changes: 2 additions & 0 deletions examples/cpp/content_filter/HelloWorldPubSubTypes.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,8 @@ class HelloWorldPubSubType : public eprosima::fastdds::dds::TopicDataType

#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE

private:

eprosima::fastdds::MD5 md5_;
unsigned char* key_buffer_;

Expand Down
2 changes: 2 additions & 0 deletions examples/cpp/custom_payload_pool/HelloWorldPubSubTypes.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,8 @@ class HelloWorldPubSubType : public eprosima::fastdds::dds::TopicDataType

#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE

private:

eprosima::fastdds::MD5 md5_;
unsigned char* key_buffer_;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,8 @@ class FlowControlExamplePubSubType : public eprosima::fastdds::dds::TopicDataTyp

#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE

private:

eprosima::fastdds::MD5 md5_;
unsigned char* key_buffer_;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,8 @@ class HelloWorldPubSubType : public eprosima::fastdds::dds::TopicDataType

#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE

private:

eprosima::fastdds::MD5 md5_;
unsigned char* key_buffer_;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,8 @@ class HelloWorldPubSubType : public eprosima::fastdds::dds::TopicDataType

#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE

private:

eprosima::fastdds::MD5 md5_;
unsigned char* key_buffer_;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,8 @@ class HelloWorldPubSubType : public eprosima::fastdds::dds::TopicDataType

#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE

private:

eprosima::fastdds::MD5 md5_;
unsigned char* key_buffer_;

Expand Down
2 changes: 2 additions & 0 deletions examples/cpp/dds/Keys/samplePubSubTypes.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,8 @@ class samplePubSubType : public eprosima::fastdds::dds::TopicDataType

#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE

private:

eprosima::fastdds::MD5 md5_;
unsigned char* key_buffer_;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,8 @@ class HelloWorldPubSubType : public eprosima::fastdds::dds::TopicDataType

#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE

private:

eprosima::fastdds::MD5 md5_;
unsigned char* key_buffer_;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -151,10 +151,11 @@ class LoanableHelloWorldPubSubType : public eprosima::fastdds::dds::TopicDataTyp

#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE

private:

eprosima::fastdds::MD5 md5_;
unsigned char* key_buffer_;

private:

static constexpr bool is_plain_xcdrv1_impl()
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -151,10 +151,11 @@ class LoanableHelloWorldPubSubType : public eprosima::fastdds::dds::TopicDataTyp

#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE

private:

eprosima::fastdds::MD5 md5_;
unsigned char* key_buffer_;

private:

static constexpr bool is_plain_xcdrv1_impl()
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -151,10 +151,11 @@ class DeliveryMechanismsPubSubType : public eprosima::fastdds::dds::TopicDataTyp

#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE

private:

eprosima::fastdds::MD5 md5_;
unsigned char* key_buffer_;

private:

static constexpr bool is_plain_xcdrv1_impl()
{
Expand Down
2 changes: 2 additions & 0 deletions examples/cpp/discovery_server/HelloWorldPubSubTypes.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,8 @@ class HelloWorldPubSubType : public eprosima::fastdds::dds::TopicDataType

#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE

private:

eprosima::fastdds::MD5 md5_;
unsigned char* key_buffer_;

Expand Down
2 changes: 2 additions & 0 deletions examples/cpp/hello_world/HelloWorldPubSubTypes.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,8 @@ class HelloWorldPubSubType : public eprosima::fastdds::dds::TopicDataType

#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE

private:

eprosima::fastdds::MD5 md5_;
unsigned char* key_buffer_;

Expand Down
4 changes: 4 additions & 0 deletions examples/cpp/request_reply/types/CalculatorPubSubTypes.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,8 @@ class CalculatorRequestTypePubSubType : public eprosima::fastdds::dds::TopicData

#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE

private:

eprosima::fastdds::MD5 md5_;
unsigned char* key_buffer_;

Expand Down Expand Up @@ -191,6 +193,8 @@ class CalculatorReplyTypePubSubType : public eprosima::fastdds::dds::TopicDataTy

#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE

private:

eprosima::fastdds::MD5 md5_;
unsigned char* key_buffer_;

Expand Down
2 changes: 2 additions & 0 deletions examples/cpp/security/HelloWorldPubSubTypes.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,8 @@ class HelloWorldPubSubType : public eprosima::fastdds::dds::TopicDataType

#endif // TOPIC_DATA_TYPE_API_HAS_CONSTRUCT_SAMPLE

private:

eprosima::fastdds::MD5 md5_;
unsigned char* key_buffer_;

Expand Down
15 changes: 8 additions & 7 deletions include/fastdds/dds/topic/TopicDataType.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -83,8 +83,8 @@ class TopicDataType
*/
FASTDDS_EXPORTED_API virtual bool serialize(
const void* const data,
fastdds::rtps::SerializedPayload_t& payload,
DataRepresentationId_t data_representation) = 0;
rtps::SerializedPayload_t& payload,
eprosima::fastdds::dds::DataRepresentationId_t data_representation) = 0;

/**
* Deserialize method, it should be implemented by the user, since it is abstract.
Expand All @@ -94,7 +94,7 @@ class TopicDataType
* @return True if correct.
*/
FASTDDS_EXPORTED_API virtual bool deserialize(
fastdds::rtps::SerializedPayload_t& payload,
rtps::SerializedPayload_t& payload,
void* data) = 0;

/*!
Expand All @@ -106,14 +106,15 @@ class TopicDataType
*/
FASTDDS_EXPORTED_API virtual uint32_t calculate_serialized_size(
const void* const data,
DataRepresentationId_t data_representation) = 0;
eprosima::fastdds::dds::DataRepresentationId_t data_representation) = 0;

/**
* Create a Data Type.
*
* @return Void pointer to the created object.
*/
FASTDDS_EXPORTED_API virtual void* create_data() = 0;

/**
* Remove a previously created object.
*
Expand All @@ -131,8 +132,8 @@ class TopicDataType
* @return True if correct.
*/
FASTDDS_EXPORTED_API virtual bool compute_key(
fastdds::rtps::SerializedPayload_t& payload,
fastdds::rtps::InstanceHandle_t& ihandle,
rtps::SerializedPayload_t& payload,
rtps::InstanceHandle_t& ihandle,
bool force_md5 = false) = 0;

/**
Expand All @@ -145,7 +146,7 @@ class TopicDataType
*/
FASTDDS_EXPORTED_API virtual bool compute_key(
const void* const data,
fastdds::rtps::InstanceHandle_t& ihandle,
rtps::InstanceHandle_t& ihandle,
bool force_md5 = false) = 0;

/**
Expand Down
Loading

0 comments on commit c7052c3

Please sign in to comment.