DataReaderQos_Handler.cpp
Go to the documentation of this file.00001 #include "DataReaderQos_Handler.h"
00002 #include "QOS_DataReader_T.h"
00003 #include "dds/DCPS/debug.h"
00004
00005 OPENDDS_BEGIN_VERSIONED_NAMESPACE_DECL
00006
00007 bool
00008 DataReaderQos_Handler::get_datareader_qos (DDS::DataReaderQos& dr_qos,
00009 dds::qosProfile * profile,
00010 const ACE_TCHAR * name)
00011 {
00012 if (name)
00013 {
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024 }
00025 else
00026 {
00027 if (profile->count_datareader_qos () == 0)
00028 {
00029 if (OpenDDS::DCPS::DCPS_debug_level > 7)
00030 {
00031 ACE_DEBUG ((LM_TRACE,
00032 ACE_TEXT ("DataReaderQos_Handler::get_datareader_qos - ")
00033 ACE_TEXT ("No DataReader QOS available in profile <%C>\n"),
00034 profile->name ().c_str ()));
00035 }
00036 return true;
00037 }
00038
00039 dds::qosProfile::datareader_qos_iterator dr_it = profile->begin_datareader_qos ();
00040 return DataReaderQos_Handler::get_datareader_qos (dr_qos, dr_it->get ());
00041 }
00042
00043 ACE_ERROR ((LM_DEBUG,
00044 ACE_TEXT ("DataReaderQos_Handler::get_datareader_qos - ")
00045 ACE_TEXT ("Unable to find DataReaderQos <%C>\n"),
00046 name));
00047 return false;
00048 }
00049
00050 bool
00051 DataReaderQos_Handler::get_datareader_qos (DDS::DataReaderQos& dr_qos,
00052 dds::datareaderQos * dr)
00053 {
00054 typedef QOS_DataReader_T<dds::datareaderQos*, DDS::DataReaderQos> dr_type;
00055 dr_type datareader_qos_handler;
00056 datareader_qos_handler.read_qos (dr_qos, dr);
00057
00058 return true;
00059 }
00060
00061 OPENDDS_END_VERSIONED_NAMESPACE_DECL