Skip to content

Commit

Permalink
Adding is_intraprocess_only() method to RTPSParticipantImpl
Browse files Browse the repository at this point in the history
  • Loading branch information
MiguelCompany committed Dec 10, 2019
1 parent 4764e8e commit 3a7b60e
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/cpp/rtps/participant/RTPSParticipantImpl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ static EntityId_t TrustedWriter(const EntityId_t& reader)
c_EntityId_Unknown;
}

static bool is_intraprocess_only(
static bool should_be_intraprocess_only(
const RTPSParticipantAttributes& att)
{
return
Expand Down Expand Up @@ -105,6 +105,7 @@ RTPSParticipantImpl::RTPSParticipantImpl(
, mp_participantListener(plisten)
, mp_userParticipant(par)
, mp_mutex(new std::recursive_mutex())
, is_intraprocess_only_(should_be_intraprocess_only(PParam))
{
// Builtin transport by default
if (PParam.useBuiltinTransports)
Expand Down Expand Up @@ -241,7 +242,7 @@ RTPSParticipantImpl::RTPSParticipantImpl(
<< m_att.defaultUnicastLocatorList);
}

if (is_intraprocess_only(m_att))
if (is_intraprocess_only())
{
m_att.builtin.metatrafficUnicastLocatorList.clear();
m_att.defaultUnicastLocatorList.clear();
Expand Down
8 changes: 8 additions & 0 deletions src/cpp/rtps/participant/RTPSParticipantImpl.h
Original file line number Diff line number Diff line change
Expand Up @@ -276,6 +276,11 @@ class RTPSParticipantImpl

WLP* wlp();

bool is_intraprocess_only() const
{
return is_intraprocess_only_;
}

bool get_remote_writer_info(const GUID_t& writerGuid, WriterProxyData& returnedInfo);

bool get_remote_reader_info(const GUID_t& readerGuid, ReaderProxyData& returnedInfo);
Expand Down Expand Up @@ -410,6 +415,9 @@ class RTPSParticipantImpl
//!Participant Mutex
std::recursive_mutex* mp_mutex;

//!Will this participant use intraprocess only?
bool is_intraprocess_only_;

/*
* Flow controllers for this participant.
*/
Expand Down

0 comments on commit 3a7b60e

Please sign in to comment.