OpenDDS
Snapshot(2023/04/07-19:43)
|
Implements the DDS::Topic interface. More...
#include <TopicImpl.h>
Private Attributes | |
DDS::TopicQos | qos_ |
The topic qos. More... | |
ACE_Thread_Mutex | listener_mutex_ |
Mutex to protect listener info. More... | |
DDS::StatusMask | listener_mask_ |
DDS::TopicListener_var | listener_ |
The topic listener. More... | |
GUID_t | id_ |
The id given by discovery. More... | |
ACE_Thread_Mutex | status_mutex_ |
Mutex to protect status info. More... | |
DDS::InconsistentTopicStatus | inconsistent_topic_status_ |
unique_ptr< Monitor > | monitor_ |
Pointer to the monitor object for this entity. More... | |
Implements the DDS::Topic interface.
See the DDS specification, OMG formal/2015-04-10, for a description of the interface this class is implementing.
Definition at line 37 of file TopicImpl.h.
OpenDDS::DCPS::TopicImpl::TopicImpl | ( | const char * | topic_name, |
const char * | type_name, | ||
OpenDDS::DCPS::TypeSupport_ptr | type_support, | ||
const DDS::TopicQos & | qos, | ||
DDS::TopicListener_ptr | a_listener, | ||
const DDS::StatusMask & | mask, | ||
DomainParticipantImpl * | participant | ||
) |
Definition at line 26 of file TopicImpl.cpp.
References _duplicate(), inconsistent_topic_status_, monitor_, TheServiceParticipant, DDS::InconsistentTopicStatus::total_count, and DDS::InconsistentTopicStatus::total_count_change.
|
virtual |
Definition at line 47 of file TopicImpl.cpp.
bool OpenDDS::DCPS::TopicImpl::check_data_representation | ( | const DDS::DataRepresentationIdSeq & | qos_ids, |
bool | is_data_writer | ||
) |
Compare the QoS of the IDL Type and the Topic/DataWriter/DataReader to see whether the type matches all values in the QoS.
Definition at line 232 of file TopicImpl.cpp.
References ACE_ERROR, LM_NOTICE, OpenDDS::DCPS::log_level, OpenDDS::DCPS::LogLevel::Notice, OPENDDS_END_VERSIONED_NAMESPACE_DECL, OpenDDS::DCPS::repr_seq_to_string(), and OpenDDS::DCPS::TopicDescriptionImpl::type_support_.
|
virtual |
Implements DDS::Entity.
Definition at line 127 of file TopicImpl.cpp.
References ACE_ERROR, ACE_TEXT(), ACE_String_Base< char >::c_str(), OpenDDS::DCPS::CREATED, OpenDDS::DCPS::DCPS_debug_level, OpenDDS::DCPS::FOUND, OpenDDS::DCPS::DomainParticipantImpl::get_domain_id(), OpenDDS::DCPS::DomainParticipantImpl::get_id(), OpenDDS::DCPS::GUID_UNKNOWN, id_, OpenDDS::DCPS::EntityImpl::is_enabled(), LM_ERROR, monitor_, OpenDDS::DCPS::TopicDescriptionImpl::participant_, qos_, DDS::RETCODE_ERROR, DDS::RETCODE_OK, DDS::RETCODE_PRECONDITION_NOT_MET, OpenDDS::DCPS::EntityImpl::set_enabled(), TheServiceParticipant, OpenDDS::DCPS::TopicDescriptionImpl::topic_name_, OpenDDS::DCPS::topicstatus_to_string(), OpenDDS::DCPS::TopicDescriptionImpl::type_name_, and OpenDDS::DCPS::TopicDescriptionImpl::type_support_.
Referenced by OpenDDS::DCPS::DomainParticipantImpl::create_new_topic().
|
virtual |
This method is not defined in the IDL and is defined for internal use. Return the id given by discovery.
Reimplemented from OpenDDS::DCPS::EntityImpl.
Definition at line 172 of file TopicImpl.cpp.
References id_.
Referenced by OpenDDS::DCPS::DomainParticipantImpl::delete_topic_i(), OpenDDS::DCPS::TopicMonitorImpl::report(), and OpenDDS::DCPS::DWMonitorImpl::report().
|
virtual |
Definition at line 117 of file TopicImpl.cpp.
References DDS::INCONSISTENT_TOPIC_STATUS, inconsistent_topic_status_, DDS::RETCODE_OK, OpenDDS::DCPS::EntityImpl::set_status_changed_flag(), status_mutex_, and DDS::InconsistentTopicStatus::total_count_change.
|
virtual |
Implements OpenDDS::DCPS::EntityImpl.
Definition at line 178 of file TopicImpl.cpp.
References OpenDDS::DCPS::EntityImpl::get_entity_instance_handle(), id_, OpenDDS::DCPS::TopicDescriptionImpl::participant_, and OpenDDS::DCPS::rchandle_from().
|
virtual |
Implements DDS::Topic.
Definition at line 110 of file TopicImpl.cpp.
References listener_, and listener_mutex_.
|
virtual |
|
virtual |
Implements OpenDDS::DCPS::TopicCallbacks.
Definition at line 203 of file TopicImpl.cpp.
References DDS::INCONSISTENT_TOPIC_STATUS, inconsistent_topic_status_, listener_, OpenDDS::DCPS::DomainParticipantImpl::listener_for(), listener_mask_, listener_mutex_, OpenDDS::DCPS::EntityImpl::notify_status_condition(), OpenDDS::DCPS::TopicDescriptionImpl::participant_, ACE_Guard< ACE_LOCK >::release(), OpenDDS::DCPS::EntityImpl::set_status_changed_flag(), status_mutex_, DDS::InconsistentTopicStatus::total_count, and DDS::InconsistentTopicStatus::total_count_change.
|
virtual |
Definition at line 100 of file TopicImpl.cpp.
References listener_, listener_mask_, listener_mutex_, and DDS::RETCODE_OK.
|
virtual |
Definition at line 51 of file TopicImpl.cpp.
References ACE_ERROR_RETURN, ACE_TEXT(), OpenDDS::DCPS::Qos_Helper::changeable(), OpenDDS::DCPS::Qos_Helper::consistent(), OpenDDS::DCPS::EntityImpl::enabled_, OpenDDS::DCPS::DomainParticipantImpl::get_domain_id(), OpenDDS::DCPS::DomainParticipantImpl::get_id(), id_, LM_ERROR, OPENDDS_NO_DURABILITY_KIND_TRANSIENT_PERSISTENT_COMPATIBILITY_CHECK, OPENDDS_NO_DURABILITY_SERVICE_COMPATIBILITY_CHECK, OPENDDS_NO_OWNERSHIP_KIND_EXCLUSIVE_COMPATIBILITY_CHECK, OPENDDS_NO_OWNERSHIP_PROFILE_COMPATIBILITY_CHECK, OpenDDS::DCPS::TopicDescriptionImpl::participant_, qos_, DDS::RETCODE_ERROR, DDS::RETCODE_IMMUTABLE_POLICY, DDS::RETCODE_INCONSISTENT_POLICY, DDS::RETCODE_OK, DDS::RETCODE_UNSUPPORTED, TheServiceParticipant, and OpenDDS::DCPS::Qos_Helper::valid().
const char * OpenDDS::DCPS::TopicImpl::topic_name | ( | ) | const |
Definition at line 190 of file TopicImpl.cpp.
References ACE_String_Base< char >::c_str(), and OpenDDS::DCPS::TopicDescriptionImpl::topic_name_.
|
virtual |
Reimplemented from OpenDDS::DCPS::EntityImpl.
Definition at line 197 of file TopicImpl.cpp.
const char * OpenDDS::DCPS::TopicImpl::type_name | ( | ) | const |
Definition at line 184 of file TopicImpl.cpp.
References ACE_String_Base< char >::c_str(), and OpenDDS::DCPS::TopicDescriptionImpl::type_name_.
|
private |
The id given by discovery.
Definition at line 106 of file TopicImpl.h.
Referenced by enable(), get_id(), get_instance_handle(), and set_qos().
|
private |
Count of discovered (readers/writers using) topics with the same topic name but different characteristics (typename)
Definition at line 112 of file TopicImpl.h.
Referenced by get_inconsistent_topic_status(), inconsistent_topic(), and TopicImpl().
|
private |
The topic listener.
Definition at line 103 of file TopicImpl.h.
Referenced by get_listener(), inconsistent_topic(), and set_listener().
|
private |
The mask for which kind of events the listener will be notified about.
Definition at line 101 of file TopicImpl.h.
Referenced by inconsistent_topic(), and set_listener().
|
private |
Mutex to protect listener info.
Definition at line 98 of file TopicImpl.h.
Referenced by get_listener(), inconsistent_topic(), and set_listener().
|
private |
Pointer to the monitor object for this entity.
Definition at line 115 of file TopicImpl.h.
Referenced by enable(), and TopicImpl().
|
private |
The topic qos.
Definition at line 95 of file TopicImpl.h.
|
private |
Mutex to protect status info.
Definition at line 109 of file TopicImpl.h.
Referenced by get_inconsistent_topic_status(), and inconsistent_topic().