18.2.8.1.5. ReaderProxyData

class ReaderProxyData

Class ReaderProxyData, used to represent all the information on a Reader (both local and remote) with the purpose of implementing the discovery.

Public Functions

inline void set_sample_identity(const SampleIdentity &sid)

Set participant client server sample identity

Parameters

sid – valid SampleIdentity

inline SampleIdentity get_sample_identity() const

Retrieve participant SampleIdentity

Returns

SampleIdentity

uint32_t get_serialized_size(bool include_encapsulation) const

Get the size in bytes of the CDR serialization of this object.

Parameters

include_encapsulation – Whether to include the size of the encapsulation info.

Returns

size in bytes of the CDR serialization.

bool writeToCDRMessage(CDRMessage_t *msg, bool write_encapsulation) const

Write as a parameter list on a CDRMessage_t

Returns

True on success

bool readFromCDRMessage(CDRMessage_t *msg, const NetworkFactory &network, bool is_shm_transport_available, bool should_filter_locators, fastdds::rtps::VendorId_t source_vendor_id = c_VendorId_eProsima)

Read the information from a CDRMessage_t. The position of the message must be in the beginning on the parameter list.

Parameters
  • msg – Pointer to the message.

  • network – Reference to network factory for locator validation and transformation

  • is_shm_transport_available – Indicates whether the Reader is reachable by SHM.

  • should_filter_locators – Whether to retrieve the locators before the external locators filtering

  • source_vendor_id – VendorId of the source participant from which the message was received

Returns

true on success

void clear()

Clear (put to default) the information.

bool is_update_allowed(const ReaderProxyData &rdata) const

Check if this object can be updated with the information on another object.

Parameters

rdataReaderProxyData object to be checked.

Returns

true if this object can be updated with the information on rdata.

void update(ReaderProxyData *rdata)

Update the information (only certain fields will be updated).

Parameters

rdata – Pointer to the object from which we are going to update.

void copy(ReaderProxyData *rdata)

Copy ALL the information from another object.

Parameters

rdata – Pointer to the object from where the information must be copied.

Public Members

ReaderQos m_qos

Reader Qos.

security::EndpointSecurityAttributesMask security_attributes_

EndpointSecurityInfo.endpoint_security_attributes.

security::PluginEndpointSecurityAttributesMask plugin_security_attributes_

EndpointSecurityInfo.plugin_endpoint_security_attributes.