Program Listing for File XMLEndpointParser.h
↰ Return to documentation for file (/tmp/ws/src/fastrtps/include/fastrtps/xmlparser/XMLEndpointParser.h
)
// Copyright 2016 Proyectos y Sistemas de Mantenimiento SL (eProsima).
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
#ifndef XMLENDPOINTPARSER_H_
#define XMLENDPOINTPARSER_H_
#ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC
#include <cstdint>
#include <set>
#include <string>
#include <vector>
#include <tinyxml2.h>
#include <fastdds/rtps/builtin/data/ReaderProxyData.h>
#include <fastdds/rtps/builtin/data/WriterProxyData.h>
#include <fastrtps/xmlparser/XMLParserCommon.h>
#include <fastrtps/xmlparser/XMLParser.h>
namespace tinyxml2 {
class XMLElement;
class XMLDocument;
} // namespace tinyxml2
namespace eprosima {
namespace fastrtps {
namespace rtps {
class ReaderProxyData;
class WriterProxyData;
} // namespace rtps
namespace xmlparser {
class StaticRTPSParticipantInfo
{
public:
StaticRTPSParticipantInfo()
{
}
virtual ~StaticRTPSParticipantInfo()
{
}
std::string m_RTPSParticipantName;
std::vector<rtps::ReaderProxyData*> m_readers;
std::vector<rtps::WriterProxyData*> m_writers;
};
class XMLEndpointParser : XMLParser
{
public:
XMLEndpointParser();
virtual ~XMLEndpointParser();
XMLP_ret loadXMLFile(
std::string& filename);
XMLP_ret loadXMLNode(
tinyxml2::XMLDocument& doc);
void loadXMLParticipantEndpoint(
tinyxml2::XMLElement* xml_endpoint,
StaticRTPSParticipantInfo* pdata);
XMLP_ret loadXMLReaderEndpoint(
tinyxml2::XMLElement* xml_endpoint,
StaticRTPSParticipantInfo* pdata);
XMLP_ret loadXMLWriterEndpoint(
tinyxml2::XMLElement* xml_endpoint,
StaticRTPSParticipantInfo* pdata);
XMLP_ret lookforReader(
const char* partname,
uint16_t id,
rtps::ReaderProxyData** rdataptr);
XMLP_ret lookforWriter(
const char* partname,
uint16_t id,
rtps::WriterProxyData** wdataptr);
private:
XMLP_ret get_disable_positive_acks_qos(
tinyxml2::XMLElement* elem,
DisablePositiveACKsQosPolicy& disable_positive_acks_qos);
std::set<int16_t> m_endpointIds;
std::set<uint32_t> m_entityIds;
std::vector<StaticRTPSParticipantInfo*> m_RTPSParticipants;
};
} /* xmlparser */
} /* namespace */
} /* namespace eprosima */
#endif // ifndef DOXYGEN_SHOULD_SKIP_THIS_PUBLIC
#endif /* XMLENDPOINTPARSER_H_ */