OpenDDS  Snapshot(2023/04/07-19:43)
Public Member Functions | Private Types | List of all members
QOS_DataReader_T< XML_QOS_TYPE, DDS_QOS_TYPE > Class Template Reference

#include <QOS_DataReader_T.h>

Inheritance diagram for QOS_DataReader_T< XML_QOS_TYPE, DDS_QOS_TYPE >:
Inheritance graph
[legend]
Collaboration diagram for QOS_DataReader_T< XML_QOS_TYPE, DDS_QOS_TYPE >:
Collaboration graph
[legend]

Public Member Functions

 QOS_DataReader_T ()
 
 ~QOS_DataReader_T ()
 
void read_qos (DDS_QOS_TYPE &, const XML_QOS_TYPE)
 
- Public Member Functions inherited from QOS_DwDrTp_Base_T< XML_QOS_TYPE, DDS_QOS_TYPE >
 QOS_DwDrTp_Base_T ()
 
 ~QOS_DwDrTp_Base_T ()
 
void read_qos (DDS_QOS_TYPE &, const XML_QOS_TYPE)
 

Private Types

typedef QOS_DwDrTp_Base_T< XML_QOS_TYPE, DDS_QOS_TYPE > DwDrTpBase
 

Detailed Description

template<typename XML_QOS_TYPE, typename DDS_QOS_TYPE>
class QOS_DataReader_T< XML_QOS_TYPE, DDS_QOS_TYPE >

Author
Marcel Smit (msmit.nosp@m.@rem.nosp@m.edy.n.nosp@m.l)

Starting point for parsing the DataReader QOS settings.

Definition at line 15 of file QOS_DataReader_T.h.

Member Typedef Documentation

◆ DwDrTpBase

template<typename XML_QOS_TYPE , typename DDS_QOS_TYPE >
typedef QOS_DwDrTp_Base_T<XML_QOS_TYPE, DDS_QOS_TYPE> QOS_DataReader_T< XML_QOS_TYPE, DDS_QOS_TYPE >::DwDrTpBase
private

Definition at line 25 of file QOS_DataReader_T.h.

Constructor & Destructor Documentation

◆ QOS_DataReader_T()

template<typename XML_QOS_TYPE , typename DDS_QOS_TYPE >
OPENDDS_BEGIN_VERSIONED_NAMESPACE_DECL QOS_DataReader_T< XML_QOS_TYPE, DDS_QOS_TYPE >::QOS_DataReader_T ( )

Definition at line 8 of file QOS_DataReader_T.cpp.

9 {
10 }

◆ ~QOS_DataReader_T()

template<typename XML_QOS_TYPE , typename DDS_QOS_TYPE >
QOS_DataReader_T< XML_QOS_TYPE, DDS_QOS_TYPE >::~QOS_DataReader_T ( )

Definition at line 13 of file QOS_DataReader_T.cpp.

14 {
15 }

Member Function Documentation

◆ read_qos()

template<typename XML_QOS_TYPE , typename DDS_QOS_TYPE >
void QOS_DataReader_T< XML_QOS_TYPE, DDS_QOS_TYPE >::read_qos ( DDS_QOS_TYPE &  dds_qos,
const XML_QOS_TYPE  xml_qos 
)

Definition at line 19 of file QOS_DataReader_T.cpp.

References ACE_DEBUG, ACE_TEXT(), OpenDDS::DCPS::DCPS_debug_level, QosCommon::get_duration(), QosCommon::get_type_consistency_kind(), LM_TRACE, and OPENDDS_END_VERSIONED_NAMESPACE_DECL.

Referenced by DataReaderQos_Handler::get_datareader_qos().

20 {
21  // First start parsing the QOS settings which the DataWriter, the DataReader,
22  // and the Topic have in common
23 
24  DwDrTpBase::read_qos(dds_qos, xml_qos);
25 
26  // Now parse the topic-only QOS settings.
27 
28 // if (xml_qos->user_data())
29 // {
30  // TODO: Have a good look at this.
31 
32 // const std::string value = *xml_qos->user_data()->value();
33 //
34 // ACE_DEBUG((LM_TRACE,
35 // ACE_TEXT("QOS_DataReader_T<XML_QOS_TYPE, DDS_QOS_TYPE>::read_qos - ")
36 // ACE_TEXT("Set user_data to <%C>\n"),
37 // value.c_str()));
38 //
39 // dds_qos.user_data.value =
40 // *xml_qos->user_data()->value();
41 // }
42  if (xml_qos->time_based_filter_p())
43  {
44  if (xml_qos->time_based_filter().minimum_separation_p())
45  {
46  const ACE_TString sec(xml_qos->time_based_filter().minimum_separation().sec().c_str());
47  const ACE_TString nsec(xml_qos->time_based_filter().minimum_separation().nanosec().c_str());
48 
49  QosCommon::get_duration(dds_qos.time_based_filter.minimum_separation,
50  sec.fast_rep(),
51  nsec.fast_rep());
52 
54  {
55  ACE_DEBUG((LM_TRACE,
56  ACE_TEXT("QOS_DataReader_T<XML_QOS_TYPE, DDS_QOS_TYPE>::read_qos - ")
57  ACE_TEXT("Set time_based_filter minimum_separation to <%d:%u>\n"),
58  dds_qos.time_based_filter.minimum_separation.sec,
59  dds_qos.time_based_filter.minimum_separation.nanosec));
60  }
61  }
62  }
63  if (xml_qos->reader_data_lifecycle_p())
64  {
65  if (xml_qos->reader_data_lifecycle().autopurge_nowriter_samples_delay_p())
66  {
67  const ACE_TString sec(xml_qos->reader_data_lifecycle().autopurge_nowriter_samples_delay().sec().c_str());
68  const ACE_TString nsec(xml_qos->reader_data_lifecycle().autopurge_nowriter_samples_delay().nanosec().c_str());
69 
70  QosCommon::get_duration(dds_qos.reader_data_lifecycle.autopurge_nowriter_samples_delay,
71  sec.c_str(),
72  nsec.c_str());
73 
75  {
76  ACE_DEBUG((LM_TRACE,
77  ACE_TEXT("QOS_DataReader_T<XML_QOS_TYPE, DDS_QOS_TYPE>::read_qos - ")
78  ACE_TEXT("Set reader_data_lifecycle autopurge_nowriter_samples_delay to <%d:%u>\n"),
79  dds_qos.reader_data_lifecycle.autopurge_nowriter_samples_delay.sec,
80  dds_qos.reader_data_lifecycle.autopurge_nowriter_samples_delay.nanosec));
81  }
82  }
83  if (xml_qos->reader_data_lifecycle().autopurge_disposed_samples_delay_p())
84  {
85  const ACE_TString sec(xml_qos->reader_data_lifecycle().autopurge_disposed_samples_delay().sec().c_str());
86  const ACE_TString nsec(xml_qos->reader_data_lifecycle().autopurge_disposed_samples_delay().nanosec().c_str());
87 
88  QosCommon::get_duration(dds_qos.reader_data_lifecycle.autopurge_disposed_samples_delay,
89  sec.c_str(),
90  nsec.c_str());
91 
93  {
94  ACE_DEBUG((LM_TRACE,
95  ACE_TEXT("QOS_DataReader_T<XML_QOS_TYPE, DDS_QOS_TYPE>::read_qos - ")
96  ACE_TEXT("Set reader_data_lifecycle autopurge_disposed_samples_delay to <%d:%u>\n"),
97  dds_qos.reader_data_lifecycle.autopurge_disposed_samples_delay.sec,
98  dds_qos.reader_data_lifecycle.autopurge_disposed_samples_delay.nanosec));
99  }
100  }
101  }
102  if (xml_qos->type_consistency_p())
103  {
104  if (xml_qos->type_consistency().kind_p())
105  {
106  QosCommon::get_type_consistency_kind(xml_qos->type_consistency().kind(),
107  dds_qos.type_consistency.kind);
108 
110  {
111  ACE_DEBUG((LM_TRACE,
112  ACE_TEXT("QOS_DataReader_T<XML_QOS_TYPE, DDS_QOS_TYPE>::read_qos - ")
113  ACE_TEXT("set type_consistency kind to <%d>\n"),
114  dds_qos.type_consistency.kind));
115  }
116  }
117  if (xml_qos->type_consistency().ignore_sequence_bounds_p())
118  {
119  dds_qos.type_consistency.ignore_sequence_bounds =
120  xml_qos->type_consistency().ignore_sequence_bounds();
121 
123  {
124  ACE_DEBUG((LM_TRACE,
125  ACE_TEXT("QOS_DataReader_T<XML_QOS_TYPE, DDS_QOS_TYPE>::read_qos - ")
126  ACE_TEXT("Set ignore_sequence_bounds to <%d>\n"),
127  dds_qos.type_consistency.ignore_sequence_bounds));
128  }
129  }
130  if (xml_qos->type_consistency().ignore_string_bounds_p())
131  {
132  dds_qos.type_consistency.ignore_string_bounds =
133  xml_qos->type_consistency().ignore_string_bounds();
134 
136  {
137  ACE_DEBUG((LM_TRACE,
138  ACE_TEXT("QOS_DataReader_T<XML_QOS_TYPE, DDS_QOS_TYPE>::read_qos - ")
139  ACE_TEXT("Set ignore_string_bounds to <%d>\n"),
140  dds_qos.type_consistency.ignore_string_bounds));
141  }
142  }
143  if (xml_qos->type_consistency().ignore_member_names_p())
144  {
145  dds_qos.type_consistency.ignore_member_names =
146  xml_qos->type_consistency().ignore_member_names();
147 
149  {
150  ACE_DEBUG((LM_TRACE,
151  ACE_TEXT("QOS_DataReader_T<XML_QOS_TYPE, DDS_QOS_TYPE>::read_qos - ")
152  ACE_TEXT("Set ignore_member_names to <%d>\n"),
153  dds_qos.type_consistency.ignore_member_names));
154  }
155  }
156  if (xml_qos->type_consistency().prevent_type_widening_p())
157  {
158  dds_qos.type_consistency.prevent_type_widening =
159  xml_qos->type_consistency().prevent_type_widening();
160 
162  {
163  ACE_DEBUG((LM_TRACE,
164  ACE_TEXT("QOS_DataReader_T<XML_QOS_TYPE, DDS_QOS_TYPE>::read_qos - ")
165  ACE_TEXT("Set prevent_type_widening to <%d>\n"),
166  dds_qos.type_consistency.prevent_type_widening));
167  }
168  }
169  if (xml_qos->type_consistency().force_type_validation_p())
170  {
171  dds_qos.type_consistency.force_type_validation =
172  xml_qos->type_consistency().force_type_validation();
173 
175  {
176  ACE_DEBUG((LM_TRACE,
177  ACE_TEXT("QOS_DataReader_T<XML_QOS_TYPE, DDS_QOS_TYPE>::read_qos - ")
178  ACE_TEXT("Set force_type_validation to <%d>\n"),
179  dds_qos.type_consistency.force_type_validation));
180  }
181  }
182  }
183 }
#define ACE_DEBUG(X)
static void get_type_consistency_kind(::dds::typeConsistencyKind kind, ::DDS::TypeConsistencyEnforcementQosPolicyKind_t &dds_kind)
Definition: QOS_Common.cpp:181
void read_qos(DDS_QOS_TYPE &, const XML_QOS_TYPE)
static void get_duration(::DDS::Duration_t &duration, const ACE_TCHAR *sec, const ACE_TCHAR *nsec)
Definition: QOS_Common.cpp:56
OpenDDS_Dcps_Export unsigned int DCPS_debug_level
Definition: debug.cpp:30
ACE_TEXT("TCP_Factory")

The documentation for this class was generated from the following files: