File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -4432,10 +4432,15 @@ void dds_qos_examples()
4432
4432
// This example only applies to DataWriter entities
4433
4433
DataWriterQos writer_qos;
4434
4434
// The TransportPriorityQosPolicy is constructed with value 0 by default
4435
- // Change the strength to 12
4435
+ // Change the value to 12
4436
4436
writer_qos.transport_priority ().value = 12 ;
4437
4437
// Use modified QoS in the creation of the corresponding DataWriter
4438
4438
writer_ = publisher_->create_datawriter (topic_, writer_qos);
4439
+
4440
+ // Change the TransportPriorityQosPolicy at runtime
4441
+ writer_qos.transport_priority ().value = 23 ;
4442
+ // Update the QoS in the corresponding entity
4443
+ writer_->set_qos (writer_qos);
4439
4444
// !--
4440
4445
}
4441
4446
You can’t perform that action at this time.
0 commit comments