OpenDDS::DCPS::EndpointRegistry Class Reference

#include <StaticDiscovery.h>

List of all members.

Classes

struct  Reader
struct  StaticDiscGuidDomainEqual
struct  StaticDiscGuidPartEqual
struct  Topic
struct  Writer

Public Member Functions

typedef OPENDDS_MAP (OPENDDS_STRING, Topic) TopicMapType
typedef OPENDDS_MAP (OPENDDS_STRING, DDS::DataReaderQos) DataReaderQosMapType
typedef OPENDDS_MAP (OPENDDS_STRING, DDS::DataWriterQos) DataWriterQosMapType
typedef OPENDDS_MAP (OPENDDS_STRING, DDS::SubscriberQos) SubscriberQosMapType
typedef OPENDDS_MAP (OPENDDS_STRING, DDS::PublisherQos) PublisherQosMapType
typedef OPENDDS_SET_CMP (RepoId, GUID_tKeyLessThan) RepoIdSetType
typedef OPENDDS_MAP_CMP (RepoId, Reader, GUID_tKeyLessThan) ReaderMapType
typedef OPENDDS_MAP_CMP (RepoId, Writer, GUID_tKeyLessThan) WriterMapType
void match ()

Static Public Member Functions

static EntityId_t build_id (const unsigned char *entity_key, const unsigned char entity_kind)
static RepoId build_id (DDS::DomainId_t domain, const unsigned char *participant_id, const EntityId_t &entity_id)

Public Attributes

TopicMapType topic_map
DataReaderQosMapType datareaderqos_map
DataWriterQosMapType datawriterqos_map
SubscriberQosMapType subscriberqos_map
PublisherQosMapType publisherqos_map
ReaderMapType reader_map
WriterMapType writer_map

Detailed Description

Definition at line 36 of file StaticDiscovery.h.


Member Function Documentation

RepoId OpenDDS::DCPS::EndpointRegistry::build_id ( DDS::DomainId_t  domain,
const unsigned char *  participant_id,
const EntityId_t entity_id 
) [static]

Definition at line 649 of file StaticDiscovery.cpp.

References ACE_OS::memcpy(), and OpenDDS::DCPS::VENDORID_OCI.

00652 {
00653   RepoId id;
00654   id.guidPrefix[0] = VENDORID_OCI[0];
00655   id.guidPrefix[1] = VENDORID_OCI[1];
00656   // id.guidPrefix[2] = domain[0]
00657   // id.guidPrefix[3] = domain[1]
00658   // id.guidPrefix[4] = domain[2]
00659   // id.guidPrefix[5] = domain[3]
00660   DDS::DomainId_t netdom = ACE_HTONL(domain);
00661   ACE_OS::memcpy(&id.guidPrefix[2], &netdom, sizeof(DDS::DomainId_t));
00662   // id.guidPrefix[6] = participant[0]
00663   // id.guidPrefix[7] = participant[1]
00664   // id.guidPrefix[8] = participant[2]
00665   // id.guidPrefix[9] = participant[3]
00666   // id.guidPrefix[10] = participant[4]
00667   // id.guidPrefix[11] = participant[5]
00668   ACE_OS::memcpy(&id.guidPrefix[6], participant_id, 6);
00669   id.entityId = entity_id;
00670   return id;
00671 }

Here is the call graph for this function:

EntityId_t OpenDDS::DCPS::EndpointRegistry::build_id ( const unsigned char *  entity_key,
const unsigned char  entity_kind 
) [static]

Definition at line 637 of file StaticDiscovery.cpp.

References OpenDDS::DCPS::EntityId_t::entityKey, and OpenDDS::DCPS::EntityId_t::entityKind.

Referenced by OpenDDS::DCPS::StaticDiscovery::add_domain_participant(), OpenDDS::DCPS::StaticDiscovery::parse_endpoints(), OpenDDS::DCPS::StaticDiscovery::pre_reader(), and OpenDDS::DCPS::StaticDiscovery::pre_writer().

00639 {
00640   EntityId_t retval;
00641   retval.entityKey[0] = entity_key[0];
00642   retval.entityKey[1] = entity_key[1];
00643   retval.entityKey[2] = entity_key[2];
00644   retval.entityKind = entity_kind;
00645   return retval;
00646 }

Here is the caller graph for this function:

void OpenDDS::DCPS::EndpointRegistry::match (  ) 

Definition at line 34 of file StaticDiscovery.cpp.

References OpenDDS::DCPS::EndpointRegistry::Writer::best_effort_readers, DDS::BEST_EFFORT_RELIABILITY_QOS, OpenDDS::DCPS::EndpointRegistry::Reader::best_effort_writers, OpenDDS::DCPS::compatibleQOS(), OpenDDS::DCPS::GUID_t::guidPrefix, OpenDDS::DCPS::EndpointRegistry::Writer::publisher_qos, OpenDDS::DCPS::EndpointRegistry::Reader::qos, OpenDDS::DCPS::EndpointRegistry::Writer::qos, reader_map, DDS::DataReaderQos::reliability, OpenDDS::DCPS::EndpointRegistry::Writer::reliable_readers, DDS::RELIABLE_RELIABILITY_QOS, OpenDDS::DCPS::EndpointRegistry::Reader::reliable_writers, OpenDDS::DCPS::EndpointRegistry::Reader::subscriber_qos, OpenDDS::DCPS::EndpointRegistry::Writer::topic_name, OpenDDS::DCPS::EndpointRegistry::Reader::topic_name, OpenDDS::DCPS::EndpointRegistry::Reader::trans_info, OpenDDS::DCPS::EndpointRegistry::Writer::trans_info, and writer_map.

Referenced by OpenDDS::DCPS::StaticDiscovery::load_configuration().

00035 {
00036   for (WriterMapType::iterator wp = writer_map.begin(), wp_limit = writer_map.end();
00037        wp != wp_limit;
00038        ++wp) {
00039     const RepoId& writerid = wp->first;
00040     Writer& writer = wp->second;
00041     for (ReaderMapType::iterator rp = reader_map.begin(), rp_limit = reader_map.end();
00042          rp != rp_limit;
00043          ++rp) {
00044       const RepoId& readerid = rp->first;
00045       Reader& reader = rp->second;
00046 
00047       if (StaticDiscGuidDomainEqual()(readerid.guidPrefix, writerid.guidPrefix) &&
00048           !StaticDiscGuidPartEqual()(readerid.guidPrefix, writerid.guidPrefix) &&
00049           reader.topic_name == writer.topic_name) {
00050         // Different participants, same topic.
00051         IncompatibleQosStatus writerStatus = {0, 0, 0, DDS::QosPolicyCountSeq()};
00052         IncompatibleQosStatus readerStatus = {0, 0, 0, DDS::QosPolicyCountSeq()};
00053         const TransportLocatorSeq& writer_trans_info = writer.trans_info;
00054         const TransportLocatorSeq& reader_trans_info = reader.trans_info;
00055         const DDS::DataWriterQos& writer_qos = writer.qos;
00056         const DDS::DataReaderQos& reader_qos = reader.qos;
00057         const DDS::PublisherQos& publisher_qos = writer.publisher_qos;
00058         const DDS::SubscriberQos& subscriber_qos = reader.subscriber_qos;
00059 
00060         if (compatibleQOS(&writerStatus, &readerStatus, writer_trans_info, reader_trans_info,
00061                           &writer_qos, &reader_qos, &publisher_qos, &subscriber_qos)) {
00062           switch (reader.qos.reliability.kind) {
00063           case DDS::BEST_EFFORT_RELIABILITY_QOS:
00064             writer.best_effort_readers.insert(readerid);
00065             reader.best_effort_writers.insert(writerid);
00066             break;
00067           case DDS::RELIABLE_RELIABILITY_QOS:
00068             writer.reliable_readers.insert(readerid);
00069             reader.reliable_writers.insert(writerid);
00070             break;
00071           }
00072         }
00073       }
00074     }
00075   }
00076 }

Here is the call graph for this function:

Here is the caller graph for this function:

typedef OpenDDS::DCPS::EndpointRegistry::OPENDDS_MAP ( OPENDDS_STRING  ,
DDS::PublisherQos   
)
typedef OpenDDS::DCPS::EndpointRegistry::OPENDDS_MAP ( OPENDDS_STRING  ,
DDS::SubscriberQos   
)
typedef OpenDDS::DCPS::EndpointRegistry::OPENDDS_MAP ( OPENDDS_STRING  ,
DDS::DataWriterQos   
)
typedef OpenDDS::DCPS::EndpointRegistry::OPENDDS_MAP ( OPENDDS_STRING  ,
DDS::DataReaderQos   
)
typedef OpenDDS::DCPS::EndpointRegistry::OPENDDS_MAP ( OPENDDS_STRING  ,
Topic   
)
typedef OpenDDS::DCPS::EndpointRegistry::OPENDDS_MAP_CMP ( RepoId  ,
Writer  ,
GUID_tKeyLessThan   
)
typedef OpenDDS::DCPS::EndpointRegistry::OPENDDS_MAP_CMP ( RepoId  ,
Reader  ,
GUID_tKeyLessThan   
)
typedef OpenDDS::DCPS::EndpointRegistry::OPENDDS_SET_CMP ( RepoId  ,
GUID_tKeyLessThan   
)

Member Data Documentation


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Generated on 10 Aug 2018 for OpenDDS by  doxygen 1.6.1