Class XMLEndpointParser

Inheritance Relationships

Base Type

Class Documentation

class XMLEndpointParser : private eprosima::fastrtps::xmlparser::XMLParser

Class XMLEndpointParser used to parse the XML file that contains information about remote endpoints.

Public Functions

XMLEndpointParser()
virtual ~XMLEndpointParser()
XMLP_ret loadXMLFile(std::string &filename)

Load the XML file

Parameters

filename – Name or data of the file to load and parse. The string could contain a filename (file://) or the XML content directly (data://), filename assumed if neither

Returns

True if correct.

XMLP_ret loadXMLNode(tinyxml2::XMLDocument &doc)

Load the XML node

Parameters

doc – Node to parse.

Returns

True if correct.

void loadXMLParticipantEndpoint(tinyxml2::XMLElement *xml_endpoint, StaticRTPSParticipantInfo *pdata)
XMLP_ret loadXMLReaderEndpoint(tinyxml2::XMLElement *xml_endpoint, StaticRTPSParticipantInfo *pdata)

Load a Reader endpoint.

Parameters
  • xml_endpoint – Reference of a tree child for a reader.

  • pdata – Pointer to the RTPSParticipantInfo where the reader must be added.

Returns

True if correctly added.

XMLP_ret loadXMLWriterEndpoint(tinyxml2::XMLElement *xml_endpoint, StaticRTPSParticipantInfo *pdata)

Load a Writer endpoint.

Parameters
  • xml_endpoint – Reference of a tree child for a writer.

  • pdata – Pointer to the RTPSParticipantInfo where the reader must be added.

Returns

True if correctly added.

XMLP_ret lookforReader(const char *partname, uint16_t id, rtps::ReaderProxyData **rdataptr)

Look for a reader in the previously loaded endpoints.

Parameters
  • partname[in] RTPSParticipant name

  • id[in] Id of the reader

  • rdataptr[out] Pointer to pointer to return the information.

Returns

True if found.

XMLP_ret lookforWriter(const char *partname, uint16_t id, rtps::WriterProxyData **wdataptr)

Look for a writer in the previously loaded endpoints.

Parameters
  • partname[in] RTPSParticipant name

  • id[in] Id of the writer

  • wdataptr[out] Pointer to pointer to return the information.

Returns

True if found