OpenDDS::DCPS::DataWriterRemoteImpl Class Reference

Implements the OpenDDS::DCPS::DataWriterRemote interface. More...

#include <DataWriterRemoteImpl.h>

Collaboration diagram for OpenDDS::DCPS::DataWriterRemoteImpl:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 DataWriterRemoteImpl (DataWriterCallbacks *parent)
virtual ~DataWriterRemoteImpl ()
virtual void add_association (const RepoId &yourId, const ReaderAssociation &readers, bool active)
virtual void association_complete (const RepoId &remote_id)
virtual void remove_associations (const ReaderIdSeq &readers, CORBA::Boolean callback)
virtual void update_incompatible_qos (const IncompatibleQosStatus &status)
virtual void update_subscription_params (const RepoId &readerId, const DDS::StringSeq &exprParams)
void detach_parent ()

Private Attributes

DataWriterCallbacksparent_
ACE_Thread_Mutex mutex_

Detailed Description

Implements the OpenDDS::DCPS::DataWriterRemote interface.

Definition at line 31 of file DataWriterRemoteImpl.h.


Constructor & Destructor Documentation

OpenDDS::DCPS::DataWriterRemoteImpl::DataWriterRemoteImpl ( DataWriterCallbacks parent  )  [explicit]

Definition at line 15 of file DataWriterRemoteImpl.cpp.

00016   : parent_(parent)
00017 {
00018 }

OpenDDS::DCPS::DataWriterRemoteImpl::~DataWriterRemoteImpl (  )  [virtual]

Definition at line 22 of file DataWriterRemoteImpl.cpp.

00023 {
00024 }


Member Function Documentation

void OpenDDS::DCPS::DataWriterRemoteImpl::add_association ( const RepoId yourId,
const ReaderAssociation readers,
bool  active 
) [virtual]

Definition at line 45 of file DataWriterRemoteImpl.cpp.

References OpenDDS::DCPS::DataWriterCallbacks::add_association(), OpenDDS::DCPS::DCPS_debug_level, OpenDDS::DCPS::getDataWriter(), parent_, and OpenDDS::DCPS::ReaderAssociation::readerId.

00048 {
00049   if (DCPS_debug_level) {
00050     GuidConverter writer_converter(yourId);
00051     GuidConverter reader_converter(reader.readerId);
00052     ACE_DEBUG((LM_DEBUG, ACE_TEXT("(%P|%t) DataWriterRemoteImpl::add_association - ")
00053                ACE_TEXT("local %C remote %C\n"),
00054                std::string(writer_converter).c_str(),
00055                std::string(reader_converter).c_str()));
00056   }
00057 
00058   DataWriterCallbacks* parent = 0;
00059   DDS::DataWriter_var dwv;
00060   {
00061     ACE_GUARD(ACE_Thread_Mutex, g, this->mutex_);
00062     dwv = getDataWriter(this->parent_);
00063     parent = this->parent_;
00064   }
00065   if (parent) {
00066     parent->add_association(yourId, reader, active);
00067   }
00068 }

void OpenDDS::DCPS::DataWriterRemoteImpl::association_complete ( const RepoId remote_id  )  [virtual]

Definition at line 71 of file DataWriterRemoteImpl.cpp.

References OpenDDS::DCPS::DataWriterCallbacks::association_complete(), OpenDDS::DCPS::getDataWriter(), and parent_.

00072 {
00073   DataWriterCallbacks* parent = 0;
00074   DDS::DataWriter_var dwv;
00075   {
00076     ACE_GUARD(ACE_Thread_Mutex, g, this->mutex_);
00077     dwv = getDataWriter(this->parent_);
00078     parent = this->parent_;
00079   }
00080   if (parent) {
00081     parent->association_complete(remote_id);
00082   }
00083 }

void OpenDDS::DCPS::DataWriterRemoteImpl::detach_parent (  ) 

Definition at line 27 of file DataWriterRemoteImpl.cpp.

References parent_.

Referenced by OpenDDS::DCPS::InfoRepoDiscovery::removeDataWriterRemote().

00028 {
00029   ACE_GUARD(ACE_Thread_Mutex, g, this->mutex_);
00030   this->parent_ = 0;
00031 }

void OpenDDS::DCPS::DataWriterRemoteImpl::remove_associations ( const ReaderIdSeq readers,
CORBA::Boolean  callback 
) [virtual]

Definition at line 86 of file DataWriterRemoteImpl.cpp.

References OpenDDS::DCPS::getDataWriter(), parent_, and OpenDDS::DCPS::DataWriterCallbacks::remove_associations().

00088 {
00089   DataWriterCallbacks* parent = 0;
00090   DDS::DataWriter_var dwv;
00091   {
00092     ACE_GUARD(ACE_Thread_Mutex, g, this->mutex_);
00093     dwv = getDataWriter(this->parent_);
00094     parent = this->parent_;
00095   }
00096   if (parent) {
00097     parent->remove_associations(readers, notify_lost);
00098   }
00099 }

void OpenDDS::DCPS::DataWriterRemoteImpl::update_incompatible_qos ( const IncompatibleQosStatus status  )  [virtual]

Definition at line 102 of file DataWriterRemoteImpl.cpp.

References OpenDDS::DCPS::getDataWriter(), parent_, and OpenDDS::DCPS::DataWriterCallbacks::update_incompatible_qos().

00104 {
00105   DataWriterCallbacks* parent = 0;
00106   DDS::DataWriter_var dwv;
00107   {
00108     ACE_GUARD(ACE_Thread_Mutex, g, this->mutex_);
00109     dwv = getDataWriter(this->parent_);
00110     parent = this->parent_;
00111   }
00112   if (parent) {
00113     parent->update_incompatible_qos(status);
00114   }
00115 }

void OpenDDS::DCPS::DataWriterRemoteImpl::update_subscription_params ( const RepoId readerId,
const DDS::StringSeq exprParams 
) [virtual]

Definition at line 118 of file DataWriterRemoteImpl.cpp.

References OpenDDS::DCPS::getDataWriter(), parent_, and OpenDDS::DCPS::DataWriterCallbacks::update_subscription_params().

00120 {
00121   DataWriterCallbacks* parent = 0;
00122   DDS::DataWriter_var dwv;
00123   {
00124     ACE_GUARD(ACE_Thread_Mutex, g, this->mutex_);
00125     dwv = getDataWriter(this->parent_);
00126     parent = this->parent_;
00127   }
00128   if (parent) {
00129     parent->update_subscription_params(readerId, params);
00130   }
00131 }


Member Data Documentation

ACE_Thread_Mutex OpenDDS::DCPS::DataWriterRemoteImpl::mutex_ [private]

Definition at line 56 of file DataWriterRemoteImpl.h.

DataWriterCallbacks* OpenDDS::DCPS::DataWriterRemoteImpl::parent_ [private]

Definition at line 55 of file DataWriterRemoteImpl.h.

Referenced by add_association(), association_complete(), detach_parent(), remove_associations(), update_incompatible_qos(), and update_subscription_params().


The documentation for this class was generated from the following files:
Generated on Fri Feb 12 20:06:18 2016 for OpenDDS by  doxygen 1.4.7