Skip to content

Commit

Permalink
Fix conflict
Browse files Browse the repository at this point in the history
Signed-off-by: Javier Gil Aviles <[email protected]>
  • Loading branch information
Javgilavi committed Feb 3, 2025
1 parent d2c3c07 commit 96feb3c
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 112 deletions.
111 changes: 0 additions & 111 deletions src/cpp/fastdds/domain/DomainParticipantFactory.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -341,125 +341,14 @@ ReturnCode_t DomainParticipantFactory::get_participant_qos_from_profile(
return RETCODE_BAD_PARAMETER;
}

<<<<<<< HEAD
=======
ReturnCode_t DomainParticipantFactory::get_participant_qos_from_xml(
const std::string& xml,
DomainParticipantQos& qos) const
{
ParticipantAttributes attr;
if (XMLP_ret::XML_OK == XMLProfileManager::fill_participant_attributes_from_xml(xml, attr, false))
{
qos = default_participant_qos_;
utils::set_qos_from_attributes(qos, attr.rtps);
return RETCODE_OK;
}

return RETCODE_BAD_PARAMETER;
}

ReturnCode_t DomainParticipantFactory::get_participant_qos_from_xml(
const std::string& xml,
DomainParticipantQos& qos,
const std::string& profile_name) const
{
if (profile_name.empty())
{
EPROSIMA_LOG_ERROR(DDS_DOMAIN, "Provided profile name must be non-empty");
return RETCODE_BAD_PARAMETER;
}

ParticipantAttributes attr;
if (XMLP_ret::XML_OK == XMLProfileManager::fill_participant_attributes_from_xml(xml, attr, true, profile_name))
{
qos = default_participant_qos_;
utils::set_qos_from_attributes(qos, attr.rtps);
return RETCODE_OK;
}

return RETCODE_BAD_PARAMETER;
}

ReturnCode_t DomainParticipantFactory::get_default_participant_qos_from_xml(
const std::string& xml,
DomainParticipantQos& qos) const
{
ParticipantAttributes attr;
if (XMLP_ret::XML_OK == XMLProfileManager::fill_default_participant_attributes_from_xml(xml, attr, true))
{
qos = default_participant_qos_;
utils::set_qos_from_attributes(qos, attr.rtps);
return RETCODE_OK;
}

return RETCODE_BAD_PARAMETER;
}

>>>>>>> 55cf7b2a (Fix log category name macro collision in `MacOS` (#5585) (#5595))
ReturnCode_t DomainParticipantFactory::get_participant_extended_qos_from_profile(
const std::string& profile_name,
DomainParticipantExtendedQos& extended_qos) const
{
extended_qos = default_participant_qos_;
ParticipantAttributes attr;
if (XMLP_ret::XML_OK == XMLProfileManager::fillParticipantAttributes(profile_name, attr, false))
{
<<<<<<< HEAD
=======
extended_qos = default_participant_qos_;
utils::set_extended_qos_from_attributes(extended_qos, attr);
return RETCODE_OK;
}

return RETCODE_BAD_PARAMETER;
}

ReturnCode_t DomainParticipantFactory::get_participant_extended_qos_from_xml(
const std::string& xml,
DomainParticipantExtendedQos& extended_qos) const
{
ParticipantAttributes attr;
if (XMLP_ret::XML_OK == XMLProfileManager::fill_participant_attributes_from_xml(xml, attr, false))
{
extended_qos = default_participant_qos_;
utils::set_extended_qos_from_attributes(extended_qos, attr);
return RETCODE_OK;
}

return RETCODE_BAD_PARAMETER;
}

ReturnCode_t DomainParticipantFactory::get_participant_extended_qos_from_xml(
const std::string& xml,
DomainParticipantExtendedQos& extended_qos,
const std::string& profile_name) const
{
if (profile_name.empty())
{
EPROSIMA_LOG_ERROR(DDS_DOMAIN, "Provided profile name must be non-empty");
return RETCODE_BAD_PARAMETER;
}

ParticipantAttributes attr;
if (XMLP_ret::XML_OK == XMLProfileManager::fill_participant_attributes_from_xml(xml, attr, true, profile_name))
{
extended_qos = default_participant_qos_;
utils::set_extended_qos_from_attributes(extended_qos, attr);
return RETCODE_OK;
}

return RETCODE_BAD_PARAMETER;
}

ReturnCode_t DomainParticipantFactory::get_default_participant_extended_qos_from_xml(
const std::string& xml,
DomainParticipantExtendedQos& extended_qos) const
{
ParticipantAttributes attr;
if (XMLP_ret::XML_OK == XMLProfileManager::fill_default_participant_attributes_from_xml(xml, attr, true))
{
extended_qos = default_participant_qos_;
>>>>>>> 55cf7b2a (Fix log category name macro collision in `MacOS` (#5585) (#5595))
utils::set_extended_qos_from_attributes(extended_qos, attr);
return RETCODE_OK;
}
Expand Down
2 changes: 1 addition & 1 deletion test/blackbox/common/DDSBlackboxTestsBasic.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1087,7 +1087,7 @@ TEST(DDSBasic, participant_factory_output_log_error_no_macro_collision)

auto dpf = DomainParticipantFactory::get_shared_instance();
DomainParticipantQos qos;
dpf->get_participant_qos_from_xml("", qos, "");
dpf->get_participant_qos_from_profile("", qos);
Log::Flush();
ASSERT_GE(n_logs.load(), 1u);
}
Expand Down

0 comments on commit 96feb3c

Please sign in to comment.