1. ioctrl和print修改为module InternalSystem。

main
baocm 9 months ago
parent 51e99c4e22
commit b7a813b18f

@ -129,7 +129,7 @@ void MsgHandler::HandleDdsMsg(const std::map<std::string, std::string>& msg)
} }
} }
int MsgHandler::ParseDeviceMsg(std::vector<uint8_t>& data, IoCtrlRsp& rsp) int MsgHandler::ParseDeviceMsg(std::vector<uint8_t>& data, InternalSystem::IoCtrlRsp& rsp)
{ {
if (data[0] == this->device_id) if (data[0] == this->device_id)
{ {
@ -158,7 +158,7 @@ int MsgHandler::ParseDeviceMsg(std::vector<uint8_t>& data, IoCtrlRsp& rsp)
return 0; return 0;
} }
int MsgHandler::HandleDeviceMsg(IoCtrlRsp& rsp) int MsgHandler::HandleDeviceMsg(InternalSystem::IoCtrlRsp& rsp)
{ {
std::vector<uint8_t> m_RecvData; std::vector<uint8_t> m_RecvData;

@ -26,7 +26,7 @@ public:
~MsgHandler() = default; ~MsgHandler() = default;
void HandleDdsMsg(const std::map<std::string, std::string>& msg); void HandleDdsMsg(const std::map<std::string, std::string>& msg);
int HandleDeviceMsg(IoCtrlRsp& rsp); int HandleDeviceMsg(InternalSystem::IoCtrlRsp& rsp);
virtual bool OpenPort(const std::string& port, const std::string& baudrate); virtual bool OpenPort(const std::string& port, const std::string& baudrate);
virtual int SendDeviceMsg(std::vector<uint8_t>& data); virtual int SendDeviceMsg(std::vector<uint8_t>& data);
@ -39,7 +39,7 @@ public:
void ClosePort(); void ClosePort();
private: private:
int ParseDeviceMsg(std::vector<uint8_t>& data, IoCtrlRsp& rsp); int ParseDeviceMsg(std::vector<uint8_t>& data, InternalSystem::IoCtrlRsp& rsp);
}; };
#endif #endif

@ -47,7 +47,7 @@ PublisherApp::PublisherApp(
, publisher_(nullptr) , publisher_(nullptr)
, topic_(nullptr) , topic_(nullptr)
, writer_(nullptr) , writer_(nullptr)
, type_(new IoCtrlRspPubSubType()) , type_(new InternalSystem::IoCtrlRspPubSubType())
, matched_(0) , matched_(0)
, samples_sent_(0) , samples_sent_(0)
, stop_(false) , stop_(false)
@ -63,7 +63,7 @@ PublisherApp::PublisherApp(
participant_ = factory_->create_participant(domain_id, pqos, nullptr, StatusMask::none()); participant_ = factory_->create_participant(domain_id, pqos, nullptr, StatusMask::none());
if (participant_ == nullptr) if (participant_ == nullptr)
{ {
throw std::runtime_error("IoCtrlRsp Participant initialization failed"); throw std::runtime_error("InternalSystem::IoCtrlRsp Participant initialization failed");
} }
// Register the type // Register the type
@ -75,16 +75,16 @@ PublisherApp::PublisherApp(
publisher_ = participant_->create_publisher(pub_qos, nullptr, StatusMask::none()); publisher_ = participant_->create_publisher(pub_qos, nullptr, StatusMask::none());
if (publisher_ == nullptr) if (publisher_ == nullptr)
{ {
throw std::runtime_error("IoCtrlRsp Publisher initialization failed"); throw std::runtime_error("InternalSystem::IoCtrlRsp Publisher initialization failed");
} }
// Create the topic // Create the topic
TopicQos topic_qos = TOPIC_QOS_DEFAULT; TopicQos topic_qos = TOPIC_QOS_DEFAULT;
participant_->get_default_topic_qos(topic_qos); participant_->get_default_topic_qos(topic_qos);
topic_ = participant_->create_topic("IoCtrlRspTopic", type_.get_type_name(), topic_qos); topic_ = participant_->create_topic("InternalSystem::IoCtrlRspTopic", type_.get_type_name(), topic_qos);
if (topic_ == nullptr) if (topic_ == nullptr)
{ {
throw std::runtime_error("IoCtrlRsp Topic initialization failed"); throw std::runtime_error("InternalSystem::IoCtrlRsp Topic initialization failed");
} }
// Create the data writer // Create the data writer
@ -96,7 +96,7 @@ PublisherApp::PublisherApp(
writer_ = publisher_->create_datawriter(topic_, writer_qos, this, StatusMask::all()); writer_ = publisher_->create_datawriter(topic_, writer_qos, this, StatusMask::all());
if (writer_ == nullptr) if (writer_ == nullptr)
{ {
throw std::runtime_error("IoCtrlRsp DataWriter initialization failed"); throw std::runtime_error("InternalSystem::IoCtrlRsp DataWriter initialization failed");
} }
} }
@ -142,7 +142,7 @@ void PublisherApp::on_publication_matched(
void PublisherApp::run(std::shared_ptr<MsgHandler> handler) void PublisherApp::run(std::shared_ptr<MsgHandler> handler)
{ {
IoCtrlRsp rsp; InternalSystem::IoCtrlRsp rsp;
while (!is_stopped()) while (!is_stopped())
{ {
@ -179,7 +179,7 @@ bool PublisherApp::publish()
if (!is_stopped()) if (!is_stopped())
{ {
/* Initialize your structure here */ /* Initialize your structure here */
WeighRsp sample_; InternalSystem::IoCtrlRsp sample_;
ret = (RETCODE_OK == writer_->write(&sample_)); ret = (RETCODE_OK == writer_->write(&sample_));
} }
return ret; return ret;

@ -45,7 +45,7 @@ SubscriberApp::SubscriberApp(
, subscriber_(nullptr) , subscriber_(nullptr)
, topic_(nullptr) , topic_(nullptr)
, reader_(nullptr) , reader_(nullptr)
, type_(new IoCtrlReqPubSubType()) , type_(new InternalSystem::IoCtrlReqPubSubType())
, samples_received_(0) , samples_received_(0)
, stop_(false) , stop_(false)
{ {
@ -58,7 +58,7 @@ SubscriberApp::SubscriberApp(
participant_ = factory_->create_participant(domain_id, pqos, nullptr, StatusMask::none()); participant_ = factory_->create_participant(domain_id, pqos, nullptr, StatusMask::none());
if (participant_ == nullptr) if (participant_ == nullptr)
{ {
throw std::runtime_error("IoCtrlReq Participant initialization failed"); throw std::runtime_error("InternalSystem::IoCtrlReq Participant initialization failed");
} }
// Register the type // Register the type
@ -70,16 +70,16 @@ SubscriberApp::SubscriberApp(
subscriber_ = participant_->create_subscriber(sub_qos, nullptr, StatusMask::none()); subscriber_ = participant_->create_subscriber(sub_qos, nullptr, StatusMask::none());
if (subscriber_ == nullptr) if (subscriber_ == nullptr)
{ {
throw std::runtime_error("IoCtrlReq Subscriber initialization failed"); throw std::runtime_error("InternalSystem::IoCtrlReq Subscriber initialization failed");
} }
// Create the topic // Create the topic
TopicQos topic_qos = TOPIC_QOS_DEFAULT; TopicQos topic_qos = TOPIC_QOS_DEFAULT;
participant_->get_default_topic_qos(topic_qos); participant_->get_default_topic_qos(topic_qos);
topic_ = participant_->create_topic("IoCtrlReqTopic", type_.get_type_name(), topic_qos); topic_ = participant_->create_topic("InternalSystem::IoCtrlReqTopic", type_.get_type_name(), topic_qos);
if (topic_ == nullptr) if (topic_ == nullptr)
{ {
throw std::runtime_error("IoCtrlReq Topic initialization failed"); throw std::runtime_error("InternalSystem::IoCtrlReq Topic initialization failed");
} }
// Create the reader // Create the reader
@ -91,7 +91,7 @@ SubscriberApp::SubscriberApp(
reader_ = subscriber_->create_datareader(topic_, reader_qos, this, StatusMask::all()); reader_ = subscriber_->create_datareader(topic_, reader_qos, this, StatusMask::all());
if (reader_ == nullptr) if (reader_ == nullptr)
{ {
throw std::runtime_error("IoCtrlReq DataReader initialization failed"); throw std::runtime_error("InternalSystem::IoCtrlReq DataReader initialization failed");
} }
} }
@ -133,9 +133,9 @@ void SubscriberApp::on_data_available(
std::string topic_name = reader->get_topicdescription()->get_name(); std::string topic_name = reader->get_topicdescription()->get_name();
std::cout << topic_name << std::endl; std::cout << topic_name << std::endl;
if (topic_name == "IoCtrlReqTopic") if (topic_name == "InternalSystem::IoCtrlReqTopic")
{ {
IoCtrlReq sample_; InternalSystem::IoCtrlReq sample_;
while ((!is_stopped()) && (RETCODE_OK == reader->take_next_sample(&sample_, &info))) while ((!is_stopped()) && (RETCODE_OK == reader->take_next_sample(&sample_, &info)))
{ {
if ((info.instance_state == ALIVE_INSTANCE_STATE) && info.valid_data) if ((info.instance_state == ALIVE_INSTANCE_STATE) && info.valid_data)
@ -159,7 +159,7 @@ void SubscriberApp::run(std::shared_ptr<MsgHandler> handler)
{ {
if(!MsgData::IoCtrlReq_queue_.empty()) if(!MsgData::IoCtrlReq_queue_.empty())
{ {
IoCtrlReq req = std::move(MsgData::IoCtrlReq_queue_.front()); InternalSystem::IoCtrlReq req = std::move(MsgData::IoCtrlReq_queue_.front());
MsgData::IoCtrlReq_queue_.pop(); MsgData::IoCtrlReq_queue_.pop();
lock.unlock(); lock.unlock();
handler->HandleDdsMsg(req.msg()); handler->HandleDdsMsg(req.msg());

@ -69,7 +69,7 @@ std::string parse_signal(
} }
} }
std::queue<IoCtrlReq> MsgData::IoCtrlReq_queue_; std::queue<InternalSystem::IoCtrlReq> MsgData::IoCtrlReq_queue_;
std::mutex MsgData::queue_cv_mtx_; std::mutex MsgData::queue_cv_mtx_;
std::filesystem::path getExeDir() std::filesystem::path getExeDir()

@ -7,7 +7,7 @@
class MsgData { class MsgData {
public: public:
static std::queue<IoCtrlReq> IoCtrlReq_queue_; static std::queue<InternalSystem::IoCtrlReq> IoCtrlReq_queue_;
static std::mutex queue_cv_mtx_; static std::mutex queue_cv_mtx_;
}; };

@ -19,8 +19,8 @@
* This file was generated by the tool fastddsgen. * This file was generated by the tool fastddsgen.
*/ */
#ifndef FAST_DDS_GENERATED__SYSTEM_HPP #ifndef FAST_DDS_GENERATED__INTERNALSYSTEM_SYSTEM_HPP
#define FAST_DDS_GENERATED__SYSTEM_HPP #define FAST_DDS_GENERATED__INTERNALSYSTEM_SYSTEM_HPP
#include <cstdint> #include <cstdint>
#include <map> #include <map>
@ -52,6 +52,8 @@
#define SYSTEM_DllAPI #define SYSTEM_DllAPI
#endif // _WIN32 #endif // _WIN32
namespace InternalSystem {
/*! /*!
* @brief This class represents the structure LicencePlateReq defined by the user in the IDL file. * @brief This class represents the structure LicencePlateReq defined by the user in the IDL file.
* @ingroup System * @ingroup System
@ -1440,6 +1442,8 @@ private:
}; };
#endif // _FAST_DDS_GENERATED_SYSTEM_HPP_ } // namespace InternalSystem
#endif // _FAST_DDS_GENERATED_INTERNALSYSTEM_SYSTEM_HPP_

@ -1,50 +1,53 @@
@extensibility(APPENDABLE) @extensibility(APPENDABLE)
struct LicencePlateReq
{
unsigned long index;
map<string, string> msg;
};
struct LicencePlateRsp module InternalSystem
{ {
unsigned long index; struct LicencePlateReq
string licence; {
}; unsigned long index;
map<string, string> msg;
};
struct PrintReq struct LicencePlateRsp
{ {
unsigned long index; unsigned long index;
map<string, string> msg; string licence;
}; };
struct PrintRsp struct PrintReq
{ {
unsigned long index; unsigned long index;
string msg; map<string, string> msg;
}; };
struct WeighReq struct PrintRsp
{ {
unsigned long index; unsigned long index;
map<string, string> msg; string msg;
}; };
struct WeighRsp struct WeighReq
{ {
unsigned long index; unsigned long index;
float stable_weight; map<string, string> msg;
float instantaneous_weight; };
};
// private struct WeighRsp
struct IoCtrlReq {
{ unsigned long index;
unsigned long index; float stable_weight;
map<string, string> msg; float instantaneous_weight;
}; };
struct IoCtrlRsp struct IoCtrlReq
{ {
unsigned long index; unsigned long index;
map<string, string> msg; map<string, string> msg;
};
struct IoCtrlRsp
{
unsigned long index;
map<string, string> msg;
};
}; };

@ -19,34 +19,34 @@
* This file was generated by the tool fastddsgen. * This file was generated by the tool fastddsgen.
*/ */
#ifndef FAST_DDS_GENERATED__SYSTEMCDRAUX_HPP #ifndef FAST_DDS_GENERATED__INTERNALSYSTEM_SYSTEMCDRAUX_HPP
#define FAST_DDS_GENERATED__SYSTEMCDRAUX_HPP #define FAST_DDS_GENERATED__INTERNALSYSTEM_SYSTEMCDRAUX_HPP
#include "System.hpp" #include "System.hpp"
constexpr uint32_t PrintReq_max_cdr_typesize {16UL}; constexpr uint32_t InternalSystem_WeighRsp_max_cdr_typesize {16UL};
constexpr uint32_t PrintReq_max_key_cdr_typesize {0UL}; constexpr uint32_t InternalSystem_WeighRsp_max_key_cdr_typesize {0UL};
constexpr uint32_t LicencePlateRsp_max_cdr_typesize {268UL}; constexpr uint32_t InternalSystem_PrintRsp_max_cdr_typesize {268UL};
constexpr uint32_t LicencePlateRsp_max_key_cdr_typesize {0UL}; constexpr uint32_t InternalSystem_PrintRsp_max_key_cdr_typesize {0UL};
constexpr uint32_t LicencePlateReq_max_cdr_typesize {16UL}; constexpr uint32_t InternalSystem_WeighReq_max_cdr_typesize {16UL};
constexpr uint32_t LicencePlateReq_max_key_cdr_typesize {0UL}; constexpr uint32_t InternalSystem_WeighReq_max_key_cdr_typesize {0UL};
constexpr uint32_t WeighReq_max_cdr_typesize {16UL}; constexpr uint32_t InternalSystem_PrintReq_max_cdr_typesize {16UL};
constexpr uint32_t WeighReq_max_key_cdr_typesize {0UL}; constexpr uint32_t InternalSystem_PrintReq_max_key_cdr_typesize {0UL};
constexpr uint32_t PrintRsp_max_cdr_typesize {268UL}; constexpr uint32_t InternalSystem_LicencePlateReq_max_cdr_typesize {16UL};
constexpr uint32_t PrintRsp_max_key_cdr_typesize {0UL}; constexpr uint32_t InternalSystem_LicencePlateReq_max_key_cdr_typesize {0UL};
constexpr uint32_t WeighRsp_max_cdr_typesize {16UL}; constexpr uint32_t InternalSystem_IoCtrlRsp_max_cdr_typesize {16UL};
constexpr uint32_t WeighRsp_max_key_cdr_typesize {0UL}; constexpr uint32_t InternalSystem_IoCtrlRsp_max_key_cdr_typesize {0UL};
constexpr uint32_t IoCtrlRsp_max_cdr_typesize {16UL}; constexpr uint32_t InternalSystem_IoCtrlReq_max_cdr_typesize {16UL};
constexpr uint32_t IoCtrlRsp_max_key_cdr_typesize {0UL}; constexpr uint32_t InternalSystem_IoCtrlReq_max_key_cdr_typesize {0UL};
constexpr uint32_t IoCtrlReq_max_cdr_typesize {16UL}; constexpr uint32_t InternalSystem_LicencePlateRsp_max_cdr_typesize {268UL};
constexpr uint32_t IoCtrlReq_max_key_cdr_typesize {0UL}; constexpr uint32_t InternalSystem_LicencePlateRsp_max_key_cdr_typesize {0UL};
namespace eprosima { namespace eprosima {
@ -57,39 +57,39 @@ class CdrSizeCalculator;
eProsima_user_DllExport void serialize_key( eProsima_user_DllExport void serialize_key(
eprosima::fastcdr::Cdr& scdr, eprosima::fastcdr::Cdr& scdr,
const LicencePlateReq& data); const InternalSystem::LicencePlateReq& data);
eProsima_user_DllExport void serialize_key( eProsima_user_DllExport void serialize_key(
eprosima::fastcdr::Cdr& scdr, eprosima::fastcdr::Cdr& scdr,
const LicencePlateRsp& data); const InternalSystem::LicencePlateRsp& data);
eProsima_user_DllExport void serialize_key( eProsima_user_DllExport void serialize_key(
eprosima::fastcdr::Cdr& scdr, eprosima::fastcdr::Cdr& scdr,
const PrintReq& data); const InternalSystem::PrintReq& data);
eProsima_user_DllExport void serialize_key( eProsima_user_DllExport void serialize_key(
eprosima::fastcdr::Cdr& scdr, eprosima::fastcdr::Cdr& scdr,
const PrintRsp& data); const InternalSystem::PrintRsp& data);
eProsima_user_DllExport void serialize_key( eProsima_user_DllExport void serialize_key(
eprosima::fastcdr::Cdr& scdr, eprosima::fastcdr::Cdr& scdr,
const WeighReq& data); const InternalSystem::WeighReq& data);
eProsima_user_DllExport void serialize_key( eProsima_user_DllExport void serialize_key(
eprosima::fastcdr::Cdr& scdr, eprosima::fastcdr::Cdr& scdr,
const WeighRsp& data); const InternalSystem::WeighRsp& data);
eProsima_user_DllExport void serialize_key( eProsima_user_DllExport void serialize_key(
eprosima::fastcdr::Cdr& scdr, eprosima::fastcdr::Cdr& scdr,
const IoCtrlReq& data); const InternalSystem::IoCtrlReq& data);
eProsima_user_DllExport void serialize_key( eProsima_user_DllExport void serialize_key(
eprosima::fastcdr::Cdr& scdr, eprosima::fastcdr::Cdr& scdr,
const IoCtrlRsp& data); const InternalSystem::IoCtrlRsp& data);
} // namespace fastcdr } // namespace fastcdr
} // namespace eprosima } // namespace eprosima
#endif // FAST_DDS_GENERATED__SYSTEMCDRAUX_HPP #endif // FAST_DDS_GENERATED__INTERNALSYSTEM_SYSTEMCDRAUX_HPP

@ -19,8 +19,8 @@
* This file was generated by the tool fastddsgen. * This file was generated by the tool fastddsgen.
*/ */
#ifndef FAST_DDS_GENERATED__SYSTEMCDRAUX_IPP #ifndef FAST_DDS_GENERATED__INTERNALSYSTEM_SYSTEMCDRAUX_IPP
#define FAST_DDS_GENERATED__SYSTEMCDRAUX_IPP #define FAST_DDS_GENERATED__INTERNALSYSTEM_SYSTEMCDRAUX_IPP
#include "SystemCdrAux.hpp" #include "SystemCdrAux.hpp"
@ -37,9 +37,11 @@ namespace fastcdr {
template<> template<>
eProsima_user_DllExport size_t calculate_serialized_size( eProsima_user_DllExport size_t calculate_serialized_size(
eprosima::fastcdr::CdrSizeCalculator& calculator, eprosima::fastcdr::CdrSizeCalculator& calculator,
const LicencePlateReq& data, const InternalSystem::LicencePlateReq& data,
size_t& current_alignment) size_t& current_alignment)
{ {
using namespace InternalSystem;
static_cast<void>(data); static_cast<void>(data);
eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding();
@ -65,8 +67,10 @@ eProsima_user_DllExport size_t calculate_serialized_size(
template<> template<>
eProsima_user_DllExport void serialize( eProsima_user_DllExport void serialize(
eprosima::fastcdr::Cdr& scdr, eprosima::fastcdr::Cdr& scdr,
const LicencePlateReq& data) const InternalSystem::LicencePlateReq& data)
{ {
using namespace InternalSystem;
eprosima::fastcdr::Cdr::state current_state(scdr); eprosima::fastcdr::Cdr::state current_state(scdr);
scdr.begin_serialize_type(current_state, scdr.begin_serialize_type(current_state,
eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ?
@ -83,8 +87,10 @@ eProsima_user_DllExport void serialize(
template<> template<>
eProsima_user_DllExport void deserialize( eProsima_user_DllExport void deserialize(
eprosima::fastcdr::Cdr& cdr, eprosima::fastcdr::Cdr& cdr,
LicencePlateReq& data) InternalSystem::LicencePlateReq& data)
{ {
using namespace InternalSystem;
cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ?
eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 :
eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR,
@ -111,8 +117,9 @@ eProsima_user_DllExport void deserialize(
void serialize_key( void serialize_key(
eprosima::fastcdr::Cdr& scdr, eprosima::fastcdr::Cdr& scdr,
const LicencePlateReq& data) const InternalSystem::LicencePlateReq& data)
{ {
using namespace InternalSystem;
static_cast<void>(scdr); static_cast<void>(scdr);
static_cast<void>(data); static_cast<void>(data);
@ -126,9 +133,11 @@ void serialize_key(
template<> template<>
eProsima_user_DllExport size_t calculate_serialized_size( eProsima_user_DllExport size_t calculate_serialized_size(
eprosima::fastcdr::CdrSizeCalculator& calculator, eprosima::fastcdr::CdrSizeCalculator& calculator,
const LicencePlateRsp& data, const InternalSystem::LicencePlateRsp& data,
size_t& current_alignment) size_t& current_alignment)
{ {
using namespace InternalSystem;
static_cast<void>(data); static_cast<void>(data);
eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding();
@ -154,8 +163,10 @@ eProsima_user_DllExport size_t calculate_serialized_size(
template<> template<>
eProsima_user_DllExport void serialize( eProsima_user_DllExport void serialize(
eprosima::fastcdr::Cdr& scdr, eprosima::fastcdr::Cdr& scdr,
const LicencePlateRsp& data) const InternalSystem::LicencePlateRsp& data)
{ {
using namespace InternalSystem;
eprosima::fastcdr::Cdr::state current_state(scdr); eprosima::fastcdr::Cdr::state current_state(scdr);
scdr.begin_serialize_type(current_state, scdr.begin_serialize_type(current_state,
eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ?
@ -172,8 +183,10 @@ eProsima_user_DllExport void serialize(
template<> template<>
eProsima_user_DllExport void deserialize( eProsima_user_DllExport void deserialize(
eprosima::fastcdr::Cdr& cdr, eprosima::fastcdr::Cdr& cdr,
LicencePlateRsp& data) InternalSystem::LicencePlateRsp& data)
{ {
using namespace InternalSystem;
cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ?
eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 :
eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR,
@ -200,8 +213,9 @@ eProsima_user_DllExport void deserialize(
void serialize_key( void serialize_key(
eprosima::fastcdr::Cdr& scdr, eprosima::fastcdr::Cdr& scdr,
const LicencePlateRsp& data) const InternalSystem::LicencePlateRsp& data)
{ {
using namespace InternalSystem;
static_cast<void>(scdr); static_cast<void>(scdr);
static_cast<void>(data); static_cast<void>(data);
@ -215,9 +229,11 @@ void serialize_key(
template<> template<>
eProsima_user_DllExport size_t calculate_serialized_size( eProsima_user_DllExport size_t calculate_serialized_size(
eprosima::fastcdr::CdrSizeCalculator& calculator, eprosima::fastcdr::CdrSizeCalculator& calculator,
const PrintReq& data, const InternalSystem::PrintReq& data,
size_t& current_alignment) size_t& current_alignment)
{ {
using namespace InternalSystem;
static_cast<void>(data); static_cast<void>(data);
eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding();
@ -243,8 +259,10 @@ eProsima_user_DllExport size_t calculate_serialized_size(
template<> template<>
eProsima_user_DllExport void serialize( eProsima_user_DllExport void serialize(
eprosima::fastcdr::Cdr& scdr, eprosima::fastcdr::Cdr& scdr,
const PrintReq& data) const InternalSystem::PrintReq& data)
{ {
using namespace InternalSystem;
eprosima::fastcdr::Cdr::state current_state(scdr); eprosima::fastcdr::Cdr::state current_state(scdr);
scdr.begin_serialize_type(current_state, scdr.begin_serialize_type(current_state,
eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ?
@ -261,8 +279,10 @@ eProsima_user_DllExport void serialize(
template<> template<>
eProsima_user_DllExport void deserialize( eProsima_user_DllExport void deserialize(
eprosima::fastcdr::Cdr& cdr, eprosima::fastcdr::Cdr& cdr,
PrintReq& data) InternalSystem::PrintReq& data)
{ {
using namespace InternalSystem;
cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ?
eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 :
eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR,
@ -289,8 +309,9 @@ eProsima_user_DllExport void deserialize(
void serialize_key( void serialize_key(
eprosima::fastcdr::Cdr& scdr, eprosima::fastcdr::Cdr& scdr,
const PrintReq& data) const InternalSystem::PrintReq& data)
{ {
using namespace InternalSystem;
static_cast<void>(scdr); static_cast<void>(scdr);
static_cast<void>(data); static_cast<void>(data);
@ -304,9 +325,11 @@ void serialize_key(
template<> template<>
eProsima_user_DllExport size_t calculate_serialized_size( eProsima_user_DllExport size_t calculate_serialized_size(
eprosima::fastcdr::CdrSizeCalculator& calculator, eprosima::fastcdr::CdrSizeCalculator& calculator,
const PrintRsp& data, const InternalSystem::PrintRsp& data,
size_t& current_alignment) size_t& current_alignment)
{ {
using namespace InternalSystem;
static_cast<void>(data); static_cast<void>(data);
eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding();
@ -332,8 +355,10 @@ eProsima_user_DllExport size_t calculate_serialized_size(
template<> template<>
eProsima_user_DllExport void serialize( eProsima_user_DllExport void serialize(
eprosima::fastcdr::Cdr& scdr, eprosima::fastcdr::Cdr& scdr,
const PrintRsp& data) const InternalSystem::PrintRsp& data)
{ {
using namespace InternalSystem;
eprosima::fastcdr::Cdr::state current_state(scdr); eprosima::fastcdr::Cdr::state current_state(scdr);
scdr.begin_serialize_type(current_state, scdr.begin_serialize_type(current_state,
eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ?
@ -350,8 +375,10 @@ eProsima_user_DllExport void serialize(
template<> template<>
eProsima_user_DllExport void deserialize( eProsima_user_DllExport void deserialize(
eprosima::fastcdr::Cdr& cdr, eprosima::fastcdr::Cdr& cdr,
PrintRsp& data) InternalSystem::PrintRsp& data)
{ {
using namespace InternalSystem;
cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ?
eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 :
eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR,
@ -378,8 +405,9 @@ eProsima_user_DllExport void deserialize(
void serialize_key( void serialize_key(
eprosima::fastcdr::Cdr& scdr, eprosima::fastcdr::Cdr& scdr,
const PrintRsp& data) const InternalSystem::PrintRsp& data)
{ {
using namespace InternalSystem;
static_cast<void>(scdr); static_cast<void>(scdr);
static_cast<void>(data); static_cast<void>(data);
@ -393,9 +421,11 @@ void serialize_key(
template<> template<>
eProsima_user_DllExport size_t calculate_serialized_size( eProsima_user_DllExport size_t calculate_serialized_size(
eprosima::fastcdr::CdrSizeCalculator& calculator, eprosima::fastcdr::CdrSizeCalculator& calculator,
const WeighReq& data, const InternalSystem::WeighReq& data,
size_t& current_alignment) size_t& current_alignment)
{ {
using namespace InternalSystem;
static_cast<void>(data); static_cast<void>(data);
eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding();
@ -421,8 +451,10 @@ eProsima_user_DllExport size_t calculate_serialized_size(
template<> template<>
eProsima_user_DllExport void serialize( eProsima_user_DllExport void serialize(
eprosima::fastcdr::Cdr& scdr, eprosima::fastcdr::Cdr& scdr,
const WeighReq& data) const InternalSystem::WeighReq& data)
{ {
using namespace InternalSystem;
eprosima::fastcdr::Cdr::state current_state(scdr); eprosima::fastcdr::Cdr::state current_state(scdr);
scdr.begin_serialize_type(current_state, scdr.begin_serialize_type(current_state,
eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ?
@ -439,8 +471,10 @@ eProsima_user_DllExport void serialize(
template<> template<>
eProsima_user_DllExport void deserialize( eProsima_user_DllExport void deserialize(
eprosima::fastcdr::Cdr& cdr, eprosima::fastcdr::Cdr& cdr,
WeighReq& data) InternalSystem::WeighReq& data)
{ {
using namespace InternalSystem;
cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ?
eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 :
eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR,
@ -467,8 +501,9 @@ eProsima_user_DllExport void deserialize(
void serialize_key( void serialize_key(
eprosima::fastcdr::Cdr& scdr, eprosima::fastcdr::Cdr& scdr,
const WeighReq& data) const InternalSystem::WeighReq& data)
{ {
using namespace InternalSystem;
static_cast<void>(scdr); static_cast<void>(scdr);
static_cast<void>(data); static_cast<void>(data);
@ -482,9 +517,11 @@ void serialize_key(
template<> template<>
eProsima_user_DllExport size_t calculate_serialized_size( eProsima_user_DllExport size_t calculate_serialized_size(
eprosima::fastcdr::CdrSizeCalculator& calculator, eprosima::fastcdr::CdrSizeCalculator& calculator,
const WeighRsp& data, const InternalSystem::WeighRsp& data,
size_t& current_alignment) size_t& current_alignment)
{ {
using namespace InternalSystem;
static_cast<void>(data); static_cast<void>(data);
eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding();
@ -513,8 +550,10 @@ eProsima_user_DllExport size_t calculate_serialized_size(
template<> template<>
eProsima_user_DllExport void serialize( eProsima_user_DllExport void serialize(
eprosima::fastcdr::Cdr& scdr, eprosima::fastcdr::Cdr& scdr,
const WeighRsp& data) const InternalSystem::WeighRsp& data)
{ {
using namespace InternalSystem;
eprosima::fastcdr::Cdr::state current_state(scdr); eprosima::fastcdr::Cdr::state current_state(scdr);
scdr.begin_serialize_type(current_state, scdr.begin_serialize_type(current_state,
eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ?
@ -532,8 +571,10 @@ eProsima_user_DllExport void serialize(
template<> template<>
eProsima_user_DllExport void deserialize( eProsima_user_DllExport void deserialize(
eprosima::fastcdr::Cdr& cdr, eprosima::fastcdr::Cdr& cdr,
WeighRsp& data) InternalSystem::WeighRsp& data)
{ {
using namespace InternalSystem;
cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ?
eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 :
eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR,
@ -564,8 +605,9 @@ eProsima_user_DllExport void deserialize(
void serialize_key( void serialize_key(
eprosima::fastcdr::Cdr& scdr, eprosima::fastcdr::Cdr& scdr,
const WeighRsp& data) const InternalSystem::WeighRsp& data)
{ {
using namespace InternalSystem;
static_cast<void>(scdr); static_cast<void>(scdr);
static_cast<void>(data); static_cast<void>(data);
@ -581,9 +623,11 @@ void serialize_key(
template<> template<>
eProsima_user_DllExport size_t calculate_serialized_size( eProsima_user_DllExport size_t calculate_serialized_size(
eprosima::fastcdr::CdrSizeCalculator& calculator, eprosima::fastcdr::CdrSizeCalculator& calculator,
const IoCtrlReq& data, const InternalSystem::IoCtrlReq& data,
size_t& current_alignment) size_t& current_alignment)
{ {
using namespace InternalSystem;
static_cast<void>(data); static_cast<void>(data);
eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding();
@ -609,8 +653,10 @@ eProsima_user_DllExport size_t calculate_serialized_size(
template<> template<>
eProsima_user_DllExport void serialize( eProsima_user_DllExport void serialize(
eprosima::fastcdr::Cdr& scdr, eprosima::fastcdr::Cdr& scdr,
const IoCtrlReq& data) const InternalSystem::IoCtrlReq& data)
{ {
using namespace InternalSystem;
eprosima::fastcdr::Cdr::state current_state(scdr); eprosima::fastcdr::Cdr::state current_state(scdr);
scdr.begin_serialize_type(current_state, scdr.begin_serialize_type(current_state,
eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ?
@ -627,8 +673,10 @@ eProsima_user_DllExport void serialize(
template<> template<>
eProsima_user_DllExport void deserialize( eProsima_user_DllExport void deserialize(
eprosima::fastcdr::Cdr& cdr, eprosima::fastcdr::Cdr& cdr,
IoCtrlReq& data) InternalSystem::IoCtrlReq& data)
{ {
using namespace InternalSystem;
cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ?
eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 :
eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR,
@ -655,8 +703,9 @@ eProsima_user_DllExport void deserialize(
void serialize_key( void serialize_key(
eprosima::fastcdr::Cdr& scdr, eprosima::fastcdr::Cdr& scdr,
const IoCtrlReq& data) const InternalSystem::IoCtrlReq& data)
{ {
using namespace InternalSystem;
static_cast<void>(scdr); static_cast<void>(scdr);
static_cast<void>(data); static_cast<void>(data);
@ -670,9 +719,11 @@ void serialize_key(
template<> template<>
eProsima_user_DllExport size_t calculate_serialized_size( eProsima_user_DllExport size_t calculate_serialized_size(
eprosima::fastcdr::CdrSizeCalculator& calculator, eprosima::fastcdr::CdrSizeCalculator& calculator,
const IoCtrlRsp& data, const InternalSystem::IoCtrlRsp& data,
size_t& current_alignment) size_t& current_alignment)
{ {
using namespace InternalSystem;
static_cast<void>(data); static_cast<void>(data);
eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding(); eprosima::fastcdr::EncodingAlgorithmFlag previous_encoding = calculator.get_encoding();
@ -698,8 +749,10 @@ eProsima_user_DllExport size_t calculate_serialized_size(
template<> template<>
eProsima_user_DllExport void serialize( eProsima_user_DllExport void serialize(
eprosima::fastcdr::Cdr& scdr, eprosima::fastcdr::Cdr& scdr,
const IoCtrlRsp& data) const InternalSystem::IoCtrlRsp& data)
{ {
using namespace InternalSystem;
eprosima::fastcdr::Cdr::state current_state(scdr); eprosima::fastcdr::Cdr::state current_state(scdr);
scdr.begin_serialize_type(current_state, scdr.begin_serialize_type(current_state,
eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ? eprosima::fastcdr::CdrVersion::XCDRv2 == scdr.get_cdr_version() ?
@ -716,8 +769,10 @@ eProsima_user_DllExport void serialize(
template<> template<>
eProsima_user_DllExport void deserialize( eProsima_user_DllExport void deserialize(
eprosima::fastcdr::Cdr& cdr, eprosima::fastcdr::Cdr& cdr,
IoCtrlRsp& data) InternalSystem::IoCtrlRsp& data)
{ {
using namespace InternalSystem;
cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ? cdr.deserialize_type(eprosima::fastcdr::CdrVersion::XCDRv2 == cdr.get_cdr_version() ?
eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 : eprosima::fastcdr::EncodingAlgorithmFlag::DELIMIT_CDR2 :
eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR, eprosima::fastcdr::EncodingAlgorithmFlag::PLAIN_CDR,
@ -744,8 +799,9 @@ eProsima_user_DllExport void deserialize(
void serialize_key( void serialize_key(
eprosima::fastcdr::Cdr& scdr, eprosima::fastcdr::Cdr& scdr,
const IoCtrlRsp& data) const InternalSystem::IoCtrlRsp& data)
{ {
using namespace InternalSystem;
static_cast<void>(scdr); static_cast<void>(scdr);
static_cast<void>(data); static_cast<void>(data);
@ -760,5 +816,5 @@ void serialize_key(
} // namespace fastcdr } // namespace fastcdr
} // namespace eprosima } // namespace eprosima
#endif // FAST_DDS_GENERATED__SYSTEMCDRAUX_IPP #endif // FAST_DDS_GENERATED__INTERNALSYSTEM_SYSTEMCDRAUX_IPP

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

@ -38,6 +38,7 @@
using namespace eprosima::fastdds::dds::xtypes; using namespace eprosima::fastdds::dds::xtypes;
namespace InternalSystem {
// TypeIdentifier is returned by reference: dependent structures/unions are registered in this same method // TypeIdentifier is returned by reference: dependent structures/unions are registered in this same method
void register_LicencePlateReq_type_identifier( void register_LicencePlateReq_type_identifier(
TypeIdentifierPair& type_ids_LicencePlateReq) TypeIdentifierPair& type_ids_LicencePlateReq)
@ -46,21 +47,14 @@ void register_LicencePlateReq_type_identifier(
ReturnCode_t return_code_LicencePlateReq {eprosima::fastdds::dds::RETCODE_OK}; ReturnCode_t return_code_LicencePlateReq {eprosima::fastdds::dds::RETCODE_OK};
return_code_LicencePlateReq = return_code_LicencePlateReq =
eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers(
"LicencePlateReq", type_ids_LicencePlateReq); "InternalSystem::LicencePlateReq", type_ids_LicencePlateReq);
if (eprosima::fastdds::dds::RETCODE_OK != return_code_LicencePlateReq) if (eprosima::fastdds::dds::RETCODE_OK != return_code_LicencePlateReq)
{ {
StructTypeFlag struct_flags_LicencePlateReq = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::APPENDABLE, StructTypeFlag struct_flags_LicencePlateReq = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::APPENDABLE,
false, false); false, false);
QualifiedTypeName type_name_LicencePlateReq = "LicencePlateReq"; QualifiedTypeName type_name_LicencePlateReq = "InternalSystem::LicencePlateReq";
eprosima::fastcdr::optional<AppliedBuiltinTypeAnnotations> type_ann_builtin_LicencePlateReq; eprosima::fastcdr::optional<AppliedBuiltinTypeAnnotations> type_ann_builtin_LicencePlateReq;
eprosima::fastcdr::optional<AppliedAnnotationSeq> ann_custom_LicencePlateReq; eprosima::fastcdr::optional<AppliedAnnotationSeq> ann_custom_LicencePlateReq;
AppliedAnnotationSeq tmp_ann_custom_LicencePlateReq;
eprosima::fastcdr::optional<AppliedVerbatimAnnotation> verbatim_LicencePlateReq;
if (!tmp_ann_custom_LicencePlateReq.empty())
{
ann_custom_LicencePlateReq = tmp_ann_custom_LicencePlateReq;
}
CompleteTypeDetail detail_LicencePlateReq = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_LicencePlateReq, ann_custom_LicencePlateReq, type_name_LicencePlateReq.to_string()); CompleteTypeDetail detail_LicencePlateReq = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_LicencePlateReq, ann_custom_LicencePlateReq, type_name_LicencePlateReq.to_string());
CompleteStructHeader header_LicencePlateReq; CompleteStructHeader header_LicencePlateReq;
header_LicencePlateReq = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_LicencePlateReq); header_LicencePlateReq = TypeObjectUtils::build_complete_struct_header(TypeIdentifier(), detail_LicencePlateReq);
@ -205,7 +199,7 @@ void register_LicencePlateReq_type_identifier(
TypeObjectUtils::build_and_register_struct_type_object(struct_type_LicencePlateReq, type_name_LicencePlateReq.to_string(), type_ids_LicencePlateReq)) TypeObjectUtils::build_and_register_struct_type_object(struct_type_LicencePlateReq, type_name_LicencePlateReq.to_string(), type_ids_LicencePlateReq))
{ {
EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION,
"LicencePlateReq already registered in TypeObjectRegistry for a different type."); "InternalSystem::LicencePlateReq already registered in TypeObjectRegistry for a different type.");
} }
} }
} }
@ -217,12 +211,12 @@ void register_LicencePlateRsp_type_identifier(
ReturnCode_t return_code_LicencePlateRsp {eprosima::fastdds::dds::RETCODE_OK}; ReturnCode_t return_code_LicencePlateRsp {eprosima::fastdds::dds::RETCODE_OK};
return_code_LicencePlateRsp = return_code_LicencePlateRsp =
eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers(
"LicencePlateRsp", type_ids_LicencePlateRsp); "InternalSystem::LicencePlateRsp", type_ids_LicencePlateRsp);
if (eprosima::fastdds::dds::RETCODE_OK != return_code_LicencePlateRsp) if (eprosima::fastdds::dds::RETCODE_OK != return_code_LicencePlateRsp)
{ {
StructTypeFlag struct_flags_LicencePlateRsp = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::APPENDABLE, StructTypeFlag struct_flags_LicencePlateRsp = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::APPENDABLE,
false, false); false, false);
QualifiedTypeName type_name_LicencePlateRsp = "LicencePlateRsp"; QualifiedTypeName type_name_LicencePlateRsp = "InternalSystem::LicencePlateRsp";
eprosima::fastcdr::optional<AppliedBuiltinTypeAnnotations> type_ann_builtin_LicencePlateRsp; eprosima::fastcdr::optional<AppliedBuiltinTypeAnnotations> type_ann_builtin_LicencePlateRsp;
eprosima::fastcdr::optional<AppliedAnnotationSeq> ann_custom_LicencePlateRsp; eprosima::fastcdr::optional<AppliedAnnotationSeq> ann_custom_LicencePlateRsp;
CompleteTypeDetail detail_LicencePlateRsp = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_LicencePlateRsp, ann_custom_LicencePlateRsp, type_name_LicencePlateRsp.to_string()); CompleteTypeDetail detail_LicencePlateRsp = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_LicencePlateRsp, ann_custom_LicencePlateRsp, type_name_LicencePlateRsp.to_string());
@ -302,7 +296,7 @@ void register_LicencePlateRsp_type_identifier(
TypeObjectUtils::build_and_register_struct_type_object(struct_type_LicencePlateRsp, type_name_LicencePlateRsp.to_string(), type_ids_LicencePlateRsp)) TypeObjectUtils::build_and_register_struct_type_object(struct_type_LicencePlateRsp, type_name_LicencePlateRsp.to_string(), type_ids_LicencePlateRsp))
{ {
EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION,
"LicencePlateRsp already registered in TypeObjectRegistry for a different type."); "InternalSystem::LicencePlateRsp already registered in TypeObjectRegistry for a different type.");
} }
} }
} }
@ -314,12 +308,12 @@ void register_PrintReq_type_identifier(
ReturnCode_t return_code_PrintReq {eprosima::fastdds::dds::RETCODE_OK}; ReturnCode_t return_code_PrintReq {eprosima::fastdds::dds::RETCODE_OK};
return_code_PrintReq = return_code_PrintReq =
eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers(
"PrintReq", type_ids_PrintReq); "InternalSystem::PrintReq", type_ids_PrintReq);
if (eprosima::fastdds::dds::RETCODE_OK != return_code_PrintReq) if (eprosima::fastdds::dds::RETCODE_OK != return_code_PrintReq)
{ {
StructTypeFlag struct_flags_PrintReq = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::APPENDABLE, StructTypeFlag struct_flags_PrintReq = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::APPENDABLE,
false, false); false, false);
QualifiedTypeName type_name_PrintReq = "PrintReq"; QualifiedTypeName type_name_PrintReq = "InternalSystem::PrintReq";
eprosima::fastcdr::optional<AppliedBuiltinTypeAnnotations> type_ann_builtin_PrintReq; eprosima::fastcdr::optional<AppliedBuiltinTypeAnnotations> type_ann_builtin_PrintReq;
eprosima::fastcdr::optional<AppliedAnnotationSeq> ann_custom_PrintReq; eprosima::fastcdr::optional<AppliedAnnotationSeq> ann_custom_PrintReq;
CompleteTypeDetail detail_PrintReq = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_PrintReq, ann_custom_PrintReq, type_name_PrintReq.to_string()); CompleteTypeDetail detail_PrintReq = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_PrintReq, ann_custom_PrintReq, type_name_PrintReq.to_string());
@ -466,7 +460,7 @@ void register_PrintReq_type_identifier(
TypeObjectUtils::build_and_register_struct_type_object(struct_type_PrintReq, type_name_PrintReq.to_string(), type_ids_PrintReq)) TypeObjectUtils::build_and_register_struct_type_object(struct_type_PrintReq, type_name_PrintReq.to_string(), type_ids_PrintReq))
{ {
EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION,
"PrintReq already registered in TypeObjectRegistry for a different type."); "InternalSystem::PrintReq already registered in TypeObjectRegistry for a different type.");
} }
} }
} }
@ -478,12 +472,12 @@ void register_PrintRsp_type_identifier(
ReturnCode_t return_code_PrintRsp {eprosima::fastdds::dds::RETCODE_OK}; ReturnCode_t return_code_PrintRsp {eprosima::fastdds::dds::RETCODE_OK};
return_code_PrintRsp = return_code_PrintRsp =
eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers(
"PrintRsp", type_ids_PrintRsp); "InternalSystem::PrintRsp", type_ids_PrintRsp);
if (eprosima::fastdds::dds::RETCODE_OK != return_code_PrintRsp) if (eprosima::fastdds::dds::RETCODE_OK != return_code_PrintRsp)
{ {
StructTypeFlag struct_flags_PrintRsp = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::APPENDABLE, StructTypeFlag struct_flags_PrintRsp = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::APPENDABLE,
false, false); false, false);
QualifiedTypeName type_name_PrintRsp = "PrintRsp"; QualifiedTypeName type_name_PrintRsp = "InternalSystem::PrintRsp";
eprosima::fastcdr::optional<AppliedBuiltinTypeAnnotations> type_ann_builtin_PrintRsp; eprosima::fastcdr::optional<AppliedBuiltinTypeAnnotations> type_ann_builtin_PrintRsp;
eprosima::fastcdr::optional<AppliedAnnotationSeq> ann_custom_PrintRsp; eprosima::fastcdr::optional<AppliedAnnotationSeq> ann_custom_PrintRsp;
CompleteTypeDetail detail_PrintRsp = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_PrintRsp, ann_custom_PrintRsp, type_name_PrintRsp.to_string()); CompleteTypeDetail detail_PrintRsp = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_PrintRsp, ann_custom_PrintRsp, type_name_PrintRsp.to_string());
@ -563,7 +557,7 @@ void register_PrintRsp_type_identifier(
TypeObjectUtils::build_and_register_struct_type_object(struct_type_PrintRsp, type_name_PrintRsp.to_string(), type_ids_PrintRsp)) TypeObjectUtils::build_and_register_struct_type_object(struct_type_PrintRsp, type_name_PrintRsp.to_string(), type_ids_PrintRsp))
{ {
EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION,
"PrintRsp already registered in TypeObjectRegistry for a different type."); "InternalSystem::PrintRsp already registered in TypeObjectRegistry for a different type.");
} }
} }
} }
@ -575,12 +569,12 @@ void register_WeighReq_type_identifier(
ReturnCode_t return_code_WeighReq {eprosima::fastdds::dds::RETCODE_OK}; ReturnCode_t return_code_WeighReq {eprosima::fastdds::dds::RETCODE_OK};
return_code_WeighReq = return_code_WeighReq =
eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers(
"WeighReq", type_ids_WeighReq); "InternalSystem::WeighReq", type_ids_WeighReq);
if (eprosima::fastdds::dds::RETCODE_OK != return_code_WeighReq) if (eprosima::fastdds::dds::RETCODE_OK != return_code_WeighReq)
{ {
StructTypeFlag struct_flags_WeighReq = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::APPENDABLE, StructTypeFlag struct_flags_WeighReq = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::APPENDABLE,
false, false); false, false);
QualifiedTypeName type_name_WeighReq = "WeighReq"; QualifiedTypeName type_name_WeighReq = "InternalSystem::WeighReq";
eprosima::fastcdr::optional<AppliedBuiltinTypeAnnotations> type_ann_builtin_WeighReq; eprosima::fastcdr::optional<AppliedBuiltinTypeAnnotations> type_ann_builtin_WeighReq;
eprosima::fastcdr::optional<AppliedAnnotationSeq> ann_custom_WeighReq; eprosima::fastcdr::optional<AppliedAnnotationSeq> ann_custom_WeighReq;
CompleteTypeDetail detail_WeighReq = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_WeighReq, ann_custom_WeighReq, type_name_WeighReq.to_string()); CompleteTypeDetail detail_WeighReq = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_WeighReq, ann_custom_WeighReq, type_name_WeighReq.to_string());
@ -727,7 +721,7 @@ void register_WeighReq_type_identifier(
TypeObjectUtils::build_and_register_struct_type_object(struct_type_WeighReq, type_name_WeighReq.to_string(), type_ids_WeighReq)) TypeObjectUtils::build_and_register_struct_type_object(struct_type_WeighReq, type_name_WeighReq.to_string(), type_ids_WeighReq))
{ {
EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION,
"WeighReq already registered in TypeObjectRegistry for a different type."); "InternalSystem::WeighReq already registered in TypeObjectRegistry for a different type.");
} }
} }
} }
@ -739,12 +733,12 @@ void register_WeighRsp_type_identifier(
ReturnCode_t return_code_WeighRsp {eprosima::fastdds::dds::RETCODE_OK}; ReturnCode_t return_code_WeighRsp {eprosima::fastdds::dds::RETCODE_OK};
return_code_WeighRsp = return_code_WeighRsp =
eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers(
"WeighRsp", type_ids_WeighRsp); "InternalSystem::WeighRsp", type_ids_WeighRsp);
if (eprosima::fastdds::dds::RETCODE_OK != return_code_WeighRsp) if (eprosima::fastdds::dds::RETCODE_OK != return_code_WeighRsp)
{ {
StructTypeFlag struct_flags_WeighRsp = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::APPENDABLE, StructTypeFlag struct_flags_WeighRsp = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::APPENDABLE,
false, false); false, false);
QualifiedTypeName type_name_WeighRsp = "WeighRsp"; QualifiedTypeName type_name_WeighRsp = "InternalSystem::WeighRsp";
eprosima::fastcdr::optional<AppliedBuiltinTypeAnnotations> type_ann_builtin_WeighRsp; eprosima::fastcdr::optional<AppliedBuiltinTypeAnnotations> type_ann_builtin_WeighRsp;
eprosima::fastcdr::optional<AppliedAnnotationSeq> ann_custom_WeighRsp; eprosima::fastcdr::optional<AppliedAnnotationSeq> ann_custom_WeighRsp;
CompleteTypeDetail detail_WeighRsp = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_WeighRsp, ann_custom_WeighRsp, type_name_WeighRsp.to_string()); CompleteTypeDetail detail_WeighRsp = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_WeighRsp, ann_custom_WeighRsp, type_name_WeighRsp.to_string());
@ -846,7 +840,7 @@ void register_WeighRsp_type_identifier(
TypeObjectUtils::build_and_register_struct_type_object(struct_type_WeighRsp, type_name_WeighRsp.to_string(), type_ids_WeighRsp)) TypeObjectUtils::build_and_register_struct_type_object(struct_type_WeighRsp, type_name_WeighRsp.to_string(), type_ids_WeighRsp))
{ {
EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION,
"WeighRsp already registered in TypeObjectRegistry for a different type."); "InternalSystem::WeighRsp already registered in TypeObjectRegistry for a different type.");
} }
} }
} }
@ -858,12 +852,12 @@ void register_IoCtrlReq_type_identifier(
ReturnCode_t return_code_IoCtrlReq {eprosima::fastdds::dds::RETCODE_OK}; ReturnCode_t return_code_IoCtrlReq {eprosima::fastdds::dds::RETCODE_OK};
return_code_IoCtrlReq = return_code_IoCtrlReq =
eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers(
"IoCtrlReq", type_ids_IoCtrlReq); "InternalSystem::IoCtrlReq", type_ids_IoCtrlReq);
if (eprosima::fastdds::dds::RETCODE_OK != return_code_IoCtrlReq) if (eprosima::fastdds::dds::RETCODE_OK != return_code_IoCtrlReq)
{ {
StructTypeFlag struct_flags_IoCtrlReq = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::APPENDABLE, StructTypeFlag struct_flags_IoCtrlReq = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::APPENDABLE,
false, false); false, false);
QualifiedTypeName type_name_IoCtrlReq = "IoCtrlReq"; QualifiedTypeName type_name_IoCtrlReq = "InternalSystem::IoCtrlReq";
eprosima::fastcdr::optional<AppliedBuiltinTypeAnnotations> type_ann_builtin_IoCtrlReq; eprosima::fastcdr::optional<AppliedBuiltinTypeAnnotations> type_ann_builtin_IoCtrlReq;
eprosima::fastcdr::optional<AppliedAnnotationSeq> ann_custom_IoCtrlReq; eprosima::fastcdr::optional<AppliedAnnotationSeq> ann_custom_IoCtrlReq;
CompleteTypeDetail detail_IoCtrlReq = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_IoCtrlReq, ann_custom_IoCtrlReq, type_name_IoCtrlReq.to_string()); CompleteTypeDetail detail_IoCtrlReq = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_IoCtrlReq, ann_custom_IoCtrlReq, type_name_IoCtrlReq.to_string());
@ -1010,7 +1004,7 @@ void register_IoCtrlReq_type_identifier(
TypeObjectUtils::build_and_register_struct_type_object(struct_type_IoCtrlReq, type_name_IoCtrlReq.to_string(), type_ids_IoCtrlReq)) TypeObjectUtils::build_and_register_struct_type_object(struct_type_IoCtrlReq, type_name_IoCtrlReq.to_string(), type_ids_IoCtrlReq))
{ {
EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION,
"IoCtrlReq already registered in TypeObjectRegistry for a different type."); "InternalSystem::IoCtrlReq already registered in TypeObjectRegistry for a different type.");
} }
} }
} }
@ -1022,12 +1016,12 @@ void register_IoCtrlRsp_type_identifier(
ReturnCode_t return_code_IoCtrlRsp {eprosima::fastdds::dds::RETCODE_OK}; ReturnCode_t return_code_IoCtrlRsp {eprosima::fastdds::dds::RETCODE_OK};
return_code_IoCtrlRsp = return_code_IoCtrlRsp =
eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers( eprosima::fastdds::dds::DomainParticipantFactory::get_instance()->type_object_registry().get_type_identifiers(
"IoCtrlRsp", type_ids_IoCtrlRsp); "InternalSystem::IoCtrlRsp", type_ids_IoCtrlRsp);
if (eprosima::fastdds::dds::RETCODE_OK != return_code_IoCtrlRsp) if (eprosima::fastdds::dds::RETCODE_OK != return_code_IoCtrlRsp)
{ {
StructTypeFlag struct_flags_IoCtrlRsp = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::APPENDABLE, StructTypeFlag struct_flags_IoCtrlRsp = TypeObjectUtils::build_struct_type_flag(eprosima::fastdds::dds::xtypes::ExtensibilityKind::APPENDABLE,
false, false); false, false);
QualifiedTypeName type_name_IoCtrlRsp = "IoCtrlRsp"; QualifiedTypeName type_name_IoCtrlRsp = "InternalSystem::IoCtrlRsp";
eprosima::fastcdr::optional<AppliedBuiltinTypeAnnotations> type_ann_builtin_IoCtrlRsp; eprosima::fastcdr::optional<AppliedBuiltinTypeAnnotations> type_ann_builtin_IoCtrlRsp;
eprosima::fastcdr::optional<AppliedAnnotationSeq> ann_custom_IoCtrlRsp; eprosima::fastcdr::optional<AppliedAnnotationSeq> ann_custom_IoCtrlRsp;
CompleteTypeDetail detail_IoCtrlRsp = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_IoCtrlRsp, ann_custom_IoCtrlRsp, type_name_IoCtrlRsp.to_string()); CompleteTypeDetail detail_IoCtrlRsp = TypeObjectUtils::build_complete_type_detail(type_ann_builtin_IoCtrlRsp, ann_custom_IoCtrlRsp, type_name_IoCtrlRsp.to_string());
@ -1174,8 +1168,10 @@ void register_IoCtrlRsp_type_identifier(
TypeObjectUtils::build_and_register_struct_type_object(struct_type_IoCtrlRsp, type_name_IoCtrlRsp.to_string(), type_ids_IoCtrlRsp)) TypeObjectUtils::build_and_register_struct_type_object(struct_type_IoCtrlRsp, type_name_IoCtrlRsp.to_string(), type_ids_IoCtrlRsp))
{ {
EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION, EPROSIMA_LOG_ERROR(XTYPES_TYPE_REPRESENTATION,
"IoCtrlRsp already registered in TypeObjectRegistry for a different type."); "InternalSystem::IoCtrlRsp already registered in TypeObjectRegistry for a different type.");
} }
} }
} }
} // namespace InternalSystem

@ -19,8 +19,8 @@
* This file was generated by the tool fastddsgen. * This file was generated by the tool fastddsgen.
*/ */
#ifndef FAST_DDS_GENERATED__SYSTEM_TYPE_OBJECT_SUPPORT_HPP #ifndef FAST_DDS_GENERATED__INTERNALSYSTEM_SYSTEM_TYPE_OBJECT_SUPPORT_HPP
#define FAST_DDS_GENERATED__SYSTEM_TYPE_OBJECT_SUPPORT_HPP #define FAST_DDS_GENERATED__INTERNALSYSTEM_SYSTEM_TYPE_OBJECT_SUPPORT_HPP
#include <fastdds/dds/xtypes/type_representation/TypeObject.hpp> #include <fastdds/dds/xtypes/type_representation/TypeObject.hpp>
@ -37,6 +37,7 @@
#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC #ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC
namespace InternalSystem {
/** /**
* @brief Register LicencePlateReq related TypeIdentifier. * @brief Register LicencePlateReq related TypeIdentifier.
* Fully-descriptive TypeIdentifiers are directly registered. * Fully-descriptive TypeIdentifiers are directly registered.
@ -49,6 +50,7 @@
*/ */
eProsima_user_DllExport void register_LicencePlateReq_type_identifier( eProsima_user_DllExport void register_LicencePlateReq_type_identifier(
eprosima::fastdds::dds::xtypes::TypeIdentifierPair& type_ids); eprosima::fastdds::dds::xtypes::TypeIdentifierPair& type_ids);
/** /**
* @brief Register LicencePlateRsp related TypeIdentifier. * @brief Register LicencePlateRsp related TypeIdentifier.
* Fully-descriptive TypeIdentifiers are directly registered. * Fully-descriptive TypeIdentifiers are directly registered.
@ -61,6 +63,7 @@ eProsima_user_DllExport void register_LicencePlateReq_type_identifier(
*/ */
eProsima_user_DllExport void register_LicencePlateRsp_type_identifier( eProsima_user_DllExport void register_LicencePlateRsp_type_identifier(
eprosima::fastdds::dds::xtypes::TypeIdentifierPair& type_ids); eprosima::fastdds::dds::xtypes::TypeIdentifierPair& type_ids);
/** /**
* @brief Register PrintReq related TypeIdentifier. * @brief Register PrintReq related TypeIdentifier.
* Fully-descriptive TypeIdentifiers are directly registered. * Fully-descriptive TypeIdentifiers are directly registered.
@ -73,6 +76,7 @@ eProsima_user_DllExport void register_LicencePlateRsp_type_identifier(
*/ */
eProsima_user_DllExport void register_PrintReq_type_identifier( eProsima_user_DllExport void register_PrintReq_type_identifier(
eprosima::fastdds::dds::xtypes::TypeIdentifierPair& type_ids); eprosima::fastdds::dds::xtypes::TypeIdentifierPair& type_ids);
/** /**
* @brief Register PrintRsp related TypeIdentifier. * @brief Register PrintRsp related TypeIdentifier.
* Fully-descriptive TypeIdentifiers are directly registered. * Fully-descriptive TypeIdentifiers are directly registered.
@ -85,6 +89,7 @@ eProsima_user_DllExport void register_PrintReq_type_identifier(
*/ */
eProsima_user_DllExport void register_PrintRsp_type_identifier( eProsima_user_DllExport void register_PrintRsp_type_identifier(
eprosima::fastdds::dds::xtypes::TypeIdentifierPair& type_ids); eprosima::fastdds::dds::xtypes::TypeIdentifierPair& type_ids);
/** /**
* @brief Register WeighReq related TypeIdentifier. * @brief Register WeighReq related TypeIdentifier.
* Fully-descriptive TypeIdentifiers are directly registered. * Fully-descriptive TypeIdentifiers are directly registered.
@ -97,6 +102,7 @@ eProsima_user_DllExport void register_PrintRsp_type_identifier(
*/ */
eProsima_user_DllExport void register_WeighReq_type_identifier( eProsima_user_DllExport void register_WeighReq_type_identifier(
eprosima::fastdds::dds::xtypes::TypeIdentifierPair& type_ids); eprosima::fastdds::dds::xtypes::TypeIdentifierPair& type_ids);
/** /**
* @brief Register WeighRsp related TypeIdentifier. * @brief Register WeighRsp related TypeIdentifier.
* Fully-descriptive TypeIdentifiers are directly registered. * Fully-descriptive TypeIdentifiers are directly registered.
@ -109,6 +115,7 @@ eProsima_user_DllExport void register_WeighReq_type_identifier(
*/ */
eProsima_user_DllExport void register_WeighRsp_type_identifier( eProsima_user_DllExport void register_WeighRsp_type_identifier(
eprosima::fastdds::dds::xtypes::TypeIdentifierPair& type_ids); eprosima::fastdds::dds::xtypes::TypeIdentifierPair& type_ids);
/** /**
* @brief Register IoCtrlReq related TypeIdentifier. * @brief Register IoCtrlReq related TypeIdentifier.
* Fully-descriptive TypeIdentifiers are directly registered. * Fully-descriptive TypeIdentifiers are directly registered.
@ -121,6 +128,7 @@ eProsima_user_DllExport void register_WeighRsp_type_identifier(
*/ */
eProsima_user_DllExport void register_IoCtrlReq_type_identifier( eProsima_user_DllExport void register_IoCtrlReq_type_identifier(
eprosima::fastdds::dds::xtypes::TypeIdentifierPair& type_ids); eprosima::fastdds::dds::xtypes::TypeIdentifierPair& type_ids);
/** /**
* @brief Register IoCtrlRsp related TypeIdentifier. * @brief Register IoCtrlRsp related TypeIdentifier.
* Fully-descriptive TypeIdentifiers are directly registered. * Fully-descriptive TypeIdentifiers are directly registered.
@ -134,7 +142,9 @@ eProsima_user_DllExport void register_IoCtrlReq_type_identifier(
eProsima_user_DllExport void register_IoCtrlRsp_type_identifier( eProsima_user_DllExport void register_IoCtrlRsp_type_identifier(
eprosima::fastdds::dds::xtypes::TypeIdentifierPair& type_ids); eprosima::fastdds::dds::xtypes::TypeIdentifierPair& type_ids);
} // namespace InternalSystem
#endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC #endif // DOXYGEN_SHOULD_SKIP_THIS_PUBLIC
#endif // FAST_DDS_GENERATED__SYSTEM_TYPE_OBJECT_SUPPORT_HPP #endif // FAST_DDS_GENERATED__INTERNALSYSTEM_SYSTEM_TYPE_OBJECT_SUPPORT_HPP

@ -63,7 +63,7 @@ PublisherApp::PublisherApp(
participant_ = factory_->create_participant(domain_id, pqos, nullptr, StatusMask::none()); participant_ = factory_->create_participant(domain_id, pqos, nullptr, StatusMask::none());
if (participant_ == nullptr) if (participant_ == nullptr)
{ {
throw std::runtime_error("PrintRsp Participant initialization failed"); throw std::runtime_error("InternalSystem::PrintRsp Participant initialization failed");
} }
// Register the type // Register the type
@ -75,7 +75,7 @@ PublisherApp::PublisherApp(
publisher_ = participant_->create_publisher(pub_qos, nullptr, StatusMask::none()); publisher_ = participant_->create_publisher(pub_qos, nullptr, StatusMask::none());
if (publisher_ == nullptr) if (publisher_ == nullptr)
{ {
throw std::runtime_error("PrintRsp Publisher initialization failed"); throw std::runtime_error("InternalSystem::PrintRsp Publisher initialization failed");
} }
// Create the topic // Create the topic
@ -84,7 +84,7 @@ PublisherApp::PublisherApp(
topic_ = participant_->create_topic("PrintRspTopic", type_.get_type_name(), topic_qos); topic_ = participant_->create_topic("PrintRspTopic", type_.get_type_name(), topic_qos);
if (topic_ == nullptr) if (topic_ == nullptr)
{ {
throw std::runtime_error("PrintRsp Topic initialization failed"); throw std::runtime_error("InternalSystem::PrintRsp Topic initialization failed");
} }
// Create the data writer // Create the data writer
@ -96,7 +96,7 @@ PublisherApp::PublisherApp(
writer_ = publisher_->create_datawriter(topic_, writer_qos, this, StatusMask::all()); writer_ = publisher_->create_datawriter(topic_, writer_qos, this, StatusMask::all());
if (writer_ == nullptr) if (writer_ == nullptr)
{ {
throw std::runtime_error("PrintRsp DataWriter initialization failed"); throw std::runtime_error("InternalSystem::PrintRsp DataWriter initialization failed");
} }
} }
@ -149,14 +149,14 @@ void PublisherApp::run(std::shared_ptr<MsgHandler> handler)
{ {
if(!MsgData::PrintReq_queue_.empty()) if(!MsgData::PrintReq_queue_.empty())
{ {
PrintReq req = std::move(MsgData::PrintReq_queue_.front()); InternalSystem::PrintReq req = std::move(MsgData::PrintReq_queue_.front());
MsgData::PrintReq_queue_.pop(); MsgData::PrintReq_queue_.pop();
lock.unlock(); lock.unlock();
std::cout << "index: " << req.index() << std::endl; std::cout << "index: " << req.index() << std::endl;
handler->HandleDdsMsg(req.msg()); handler->HandleDdsMsg(req.msg());
PrintRsp rsp; InternalSystem::PrintRsp rsp;
rsp.index() = req.index(); rsp.index() = req.index();
rsp.msg() = "success"; rsp.msg() = "success";
writer_->write(&rsp); writer_->write(&rsp);
@ -190,7 +190,7 @@ bool PublisherApp::publish()
if (!is_stopped()) if (!is_stopped())
{ {
/* Initialize your structure here */ /* Initialize your structure here */
WeighRsp sample_; InternalSystem::LicencePlateRsp sample_;
ret = (RETCODE_OK == writer_->write(&sample_)); ret = (RETCODE_OK == writer_->write(&sample_));
} }
return ret; return ret;

@ -58,7 +58,7 @@ SubscriberApp::SubscriberApp(
participant_ = factory_->create_participant(domain_id, pqos, nullptr, StatusMask::none()); participant_ = factory_->create_participant(domain_id, pqos, nullptr, StatusMask::none());
if (participant_ == nullptr) if (participant_ == nullptr)
{ {
throw std::runtime_error("PrintReq Participant initialization failed"); throw std::runtime_error("InternalSystem::PrintReq Participant initialization failed");
} }
// Register the type // Register the type
@ -70,7 +70,7 @@ SubscriberApp::SubscriberApp(
subscriber_ = participant_->create_subscriber(sub_qos, nullptr, StatusMask::none()); subscriber_ = participant_->create_subscriber(sub_qos, nullptr, StatusMask::none());
if (subscriber_ == nullptr) if (subscriber_ == nullptr)
{ {
throw std::runtime_error("PrintReq Subscriber initialization failed"); throw std::runtime_error("InternalSystem::PrintReq Subscriber initialization failed");
} }
// Create the topic // Create the topic
@ -79,7 +79,7 @@ SubscriberApp::SubscriberApp(
topic_ = participant_->create_topic("PrintReqTopic", type_.get_type_name(), topic_qos); topic_ = participant_->create_topic("PrintReqTopic", type_.get_type_name(), topic_qos);
if (topic_ == nullptr) if (topic_ == nullptr)
{ {
throw std::runtime_error("PrintReq Topic initialization failed"); throw std::runtime_error("InternalSystem::PrintReq Topic initialization failed");
} }
// Create the reader // Create the reader
@ -91,7 +91,7 @@ SubscriberApp::SubscriberApp(
reader_ = subscriber_->create_datareader(topic_, reader_qos, this, StatusMask::all()); reader_ = subscriber_->create_datareader(topic_, reader_qos, this, StatusMask::all());
if (reader_ == nullptr) if (reader_ == nullptr)
{ {
throw std::runtime_error("PrintReq DataReader initialization failed"); throw std::runtime_error("InternalSystem::PrintReq DataReader initialization failed");
} }
} }
@ -135,7 +135,7 @@ void SubscriberApp::on_data_available(
if (topic_name == "PrintReqTopic") if (topic_name == "PrintReqTopic")
{ {
PrintReq sample_; InternalSystem::PrintReq sample_;
while ((!is_stopped()) && (RETCODE_OK == reader->take_next_sample(&sample_, &info))) while ((!is_stopped()) && (RETCODE_OK == reader->take_next_sample(&sample_, &info)))
{ {
if ((info.instance_state == ALIVE_INSTANCE_STATE) && info.valid_data) if ((info.instance_state == ALIVE_INSTANCE_STATE) && info.valid_data)

@ -64,7 +64,7 @@ std::string parse_signal(
} }
} }
std::queue<PrintReq> MsgData::PrintReq_queue_; std::queue<InternalSystem::PrintReq> MsgData::PrintReq_queue_;
std::mutex MsgData::queue_cv_mtx_; std::mutex MsgData::queue_cv_mtx_;
int main(int argc, char** argv) int main(int argc, char** argv)

@ -7,7 +7,7 @@
class MsgData { class MsgData {
public: public:
static std::queue<PrintReq> PrintReq_queue_; static std::queue<InternalSystem::PrintReq> PrintReq_queue_;
static std::mutex queue_cv_mtx_; static std::mutex queue_cv_mtx_;
}; };

Loading…
Cancel
Save