QoS

group qos

This defines the public API of QoS and Policies in the Eclipse Cyclone DDS C language binding.

Defines

DDS_HAS_PROPERTY_LIST_QOS 1

Whether or not the “property list” QoS setting is supported in this version. If it is, the “dds.sec.” properties are treated specially, preventing the accidental creation of a non-secure participant by an implementation built without support for DDS Security.

DDS_LENGTH_UNLIMITED -1

Used for indicating unlimited length in dds_qset_resource_limits()

Typedefs

typedef struct dds_qos dds_qos_t

QoS datatype

QoS structure is opaque.

typedef enum dds_durability_kind dds_durability_kind_t

Durability QoS: Applies to Topic, DataReader, DataWriter.

typedef enum dds_history_kind dds_history_kind_t

History QoS: Applies to Topic, DataReader, DataWriter.

typedef enum dds_ownership_kind dds_ownership_kind_t

Ownership QoS: Applies to Topic, DataReader, DataWriter.

typedef enum dds_liveliness_kind dds_liveliness_kind_t

Liveliness QoS: Applies to Topic, DataReader, DataWriter.

typedef enum dds_reliability_kind dds_reliability_kind_t

Reliability QoS: Applies to Topic, DataReader, DataWriter.

typedef enum dds_destination_order_kind dds_destination_order_kind_t

DestinationOrder QoS: Applies to Topic, DataReader, DataWriter.

typedef enum dds_presentation_access_scope_kind dds_presentation_access_scope_kind_t

Presentation QoS: Applies to Publisher, Subscriber.

typedef enum dds_ignorelocal_kind dds_ignorelocal_kind_t

Ignore-local QoS: Applies to DataReader, DataWriter.

typedef enum dds_type_consistency_kind dds_type_consistency_kind_t

Type-consistency QoS: Applies to DataReader, DataWriter.

typedef int16_t dds_data_representation_id_t

Data Representation QoS: Applies to Topic, DataReader, DataWriter.

Enums

enum dds_durability_kind

Durability QoS: Applies to Topic, DataReader, DataWriter.

Values:

enumerator DDS_DURABILITY_VOLATILE

Volatile durability

enumerator DDS_DURABILITY_TRANSIENT_LOCAL

Transient Local durability

enumerator DDS_DURABILITY_TRANSIENT

Transient durability

enumerator DDS_DURABILITY_PERSISTENT

Persistent durability

enum dds_history_kind

History QoS: Applies to Topic, DataReader, DataWriter.

Values:

enumerator DDS_HISTORY_KEEP_LAST

Keep Last history

enumerator DDS_HISTORY_KEEP_ALL

Keep All history

enum dds_ownership_kind

Ownership QoS: Applies to Topic, DataReader, DataWriter.

Values:

enumerator DDS_OWNERSHIP_SHARED

Shared Ownership

enumerator DDS_OWNERSHIP_EXCLUSIVE

Exclusive Ownership

enum dds_liveliness_kind

Liveliness QoS: Applies to Topic, DataReader, DataWriter.

Values:

enumerator DDS_LIVELINESS_AUTOMATIC

Automatic liveliness

enumerator DDS_LIVELINESS_MANUAL_BY_PARTICIPANT

Manual by Participant liveliness

enumerator DDS_LIVELINESS_MANUAL_BY_TOPIC

Manual by Topic liveliness

enum dds_reliability_kind

Reliability QoS: Applies to Topic, DataReader, DataWriter.

Values:

enumerator DDS_RELIABILITY_BEST_EFFORT

Best Effort reliability

enumerator DDS_RELIABILITY_RELIABLE

Reliable reliability

enum dds_destination_order_kind

DestinationOrder QoS: Applies to Topic, DataReader, DataWriter.

Values:

enumerator DDS_DESTINATIONORDER_BY_RECEPTION_TIMESTAMP

order by reception timestamp

enumerator DDS_DESTINATIONORDER_BY_SOURCE_TIMESTAMP

order by source timestamp

enum dds_presentation_access_scope_kind

Presentation QoS: Applies to Publisher, Subscriber.

Values:

enumerator DDS_PRESENTATION_INSTANCE

presentation scope per instance

enumerator DDS_PRESENTATION_TOPIC

presentation scope per topic

enumerator DDS_PRESENTATION_GROUP

presentation scope per group

enum dds_ignorelocal_kind

Ignore-local QoS: Applies to DataReader, DataWriter.

Values:

enumerator DDS_IGNORELOCAL_NONE

Don’t ignore local data

enumerator DDS_IGNORELOCAL_PARTICIPANT

Ignore local data from same participant

enumerator DDS_IGNORELOCAL_PROCESS

Ignore local data from same process

enum dds_type_consistency_kind

Type-consistency QoS: Applies to DataReader, DataWriter.

Values:

enumerator DDS_TYPE_CONSISTENCY_DISALLOW_TYPE_COERCION

Do not allow type coercion

enumerator DDS_TYPE_CONSISTENCY_ALLOW_TYPE_COERCION

Allow type coercion

Functions

dds_qos_t *dds_create_qos(void)

Allocate memory and initialize default QoS-policies.

Returns

- Pointer to the initialized dds_qos_t structure, NULL if unsuccessful.

void dds_delete_qos(dds_qos_t *qos)

Delete memory allocated to QoS-policies structure.

Parameters
  • qos[in] - Pointer to dds_qos_t structure

void dds_reset_qos(dds_qos_t *qos)

Reset a QoS-policies structure to default values.

Parameters
  • qos[inout] - Pointer to the dds_qos_t structure

dds_return_t dds_copy_qos(dds_qos_t *dst, const dds_qos_t *src)

Copy all QoS-policies from one structure to another.

Parameters
  • dst[inout] - Pointer to the destination dds_qos_t structure

  • src[in] - Pointer to the source dds_qos_t structure

Returns

- Return-code indicating success or failure

void dds_merge_qos(dds_qos_t *dst, const dds_qos_t *src)

Copy all QoS-policies from one structure to another, unless already set.

Policies are copied from src to dst, unless src already has the policy set to a non-default value.

Parameters
  • dst[inout] - Pointer to the destination qos structure

  • src[in] - Pointer to the source qos structure

bool dds_qos_equal(const dds_qos_t *a, const dds_qos_t *b)

Check if two qos structures contain the same set of QoS-policies.

Parameters
  • a[in] - Pointer to a qos structure

  • b[in] - Pointer to a qos structure

Returns

whether the two qos structures contain the same set of QoS-policies

Setters

group qos_setters

Functions

void dds_qset_userdata(dds_qos_t *qos, const void *value, size_t sz)

Set the userdata of a qos structure.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that will store the userdata

  • value[in] - Pointer to the userdata

  • sz[in] - Size of userdata stored in value

void dds_qset_topicdata(dds_qos_t *qos, const void *value, size_t sz)

Set the topicdata of a qos structure.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that will store the topicdata

  • value[in] - Pointer to the topicdata

  • sz[in] - Size of the topicdata stored in value

void dds_qset_groupdata(dds_qos_t *qos, const void *value, size_t sz)

Set the groupdata of a qos structure.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that will store the groupdata

  • value[in] - Pointer to the group data

  • sz[in] - Size of groupdata stored in value

void dds_qset_durability(dds_qos_t *qos, dds_durability_kind_t kind)

Set the durability policy of a qos structure.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that will store the policy

  • kind[in] - Durability kind value

void dds_qset_history(dds_qos_t *qos, dds_history_kind_t kind, int32_t depth)

Set the history policy of a qos structure.

Note that depth is only relevant for keep last. If you want limited history for keep all, use dds_qset_resource_limits().

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that will store the policy

  • kind[in] - History kind value

  • depth[in] - History depth value

void dds_qset_resource_limits(dds_qos_t *qos, int32_t max_samples, int32_t max_instances, int32_t max_samples_per_instance)

Set the resource limits policy of a qos structure.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that will store the policy

  • max_samples[in] - Number of samples resource-limit value

  • max_instances[in] - Number of instances resource-limit value

  • max_samples_per_instance[in] - Number of samples per instance resource-limit value

void dds_qset_presentation(dds_qos_t *qos, dds_presentation_access_scope_kind_t access_scope, bool coherent_access, bool ordered_access)

Set the presentation policy of a qos structure.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that will store the policy

  • access_scope[in] - Access-scope kind

  • coherent_access[in] - Coherent access enable value

  • ordered_access[in] - Ordered access enable value

void dds_qset_lifespan(dds_qos_t *qos, dds_duration_t lifespan)

Set the lifespan policy of a qos structure.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that will store the policy

  • lifespan[in] - Lifespan duration (expiration time relative to source timestamp of a sample)

void dds_qset_deadline(dds_qos_t *qos, dds_duration_t deadline)

Set the deadline policy of a qos structure.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that will store the policy

  • deadline[in] - Deadline duration

void dds_qset_latency_budget(dds_qos_t *qos, dds_duration_t duration)

Set the latency-budget policy of a qos structure.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that will store the policy

  • duration[in] - Latency budget duration

void dds_qset_ownership(dds_qos_t *qos, dds_ownership_kind_t kind)

Set the ownership policy of a qos structure.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that will store the policy

  • kind[in] - Ownership kind

void dds_qset_ownership_strength(dds_qos_t *qos, int32_t value)

Set the ownership strength policy of a qos structure.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that will store the policy

  • value[in] - Ownership strength value

void dds_qset_liveliness(dds_qos_t *qos, dds_liveliness_kind_t kind, dds_duration_t lease_duration)

Set the liveliness policy of a qos structure.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that will store the policy

  • kind[in] - Liveliness kind

  • lease_duration[in] - Lease duration

void dds_qset_time_based_filter(dds_qos_t *qos, dds_duration_t minimum_separation)

Set the time-based filter policy of a qos structure.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that will store the policy

  • minimum_separation[in] - Minimum duration between sample delivery for an instance

void dds_qset_partition(dds_qos_t *qos, uint32_t n, const char **ps)

Set the partition policy of a qos structure.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that will store the policy

  • n[in] - Number of partitions stored in ps

  • ps[in] - Pointer to string(s) storing partition name(s)

void dds_qset_partition1(dds_qos_t *qos, const char *name)

Convenience function to set the partition policy of a qos structure to a single name. Name may be a null pointer.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that will store the policy

  • name[in] - Pointer to the name

void dds_qset_reliability(dds_qos_t *qos, dds_reliability_kind_t kind, dds_duration_t max_blocking_time)

Set the reliability policy of a qos structure.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that will store the policy

  • kind[in] - Reliability kind

  • max_blocking_time[in] - Max blocking duration applied when kind is reliable. This is how long the writer will block when its history is full.

void dds_qset_transport_priority(dds_qos_t *qos, int32_t value)

Set the transport-priority policy of a qos structure.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that will store the policy

  • value[in] - Priority value

void dds_qset_destination_order(dds_qos_t *qos, dds_destination_order_kind_t kind)

Set the destination-order policy of a qos structure.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that will store the policy

  • kind[in] - Destination-order kind

void dds_qset_writer_data_lifecycle(dds_qos_t *qos, bool autodispose)

Set the writer data-lifecycle policy of a qos structure.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that will store the policy

  • autodispose[in] - Automatic disposal of unregistered instances

void dds_qset_reader_data_lifecycle(dds_qos_t *qos, dds_duration_t autopurge_nowriter_samples_delay, dds_duration_t autopurge_disposed_samples_delay)

Set the reader data-lifecycle policy of a qos structure.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that will store the policy

  • autopurge_nowriter_samples_delay[in] - Delay for purging of samples from instances in a no-writers state

  • autopurge_disposed_samples_delay[in] - Delay for purging of samples from disposed instances

void dds_qset_writer_batching(dds_qos_t *qos, bool batch_updates)

Set the writer batching policy of a qos structure.

When batching is disabled, each write/dispose/unregister operation results in its own RTPS message that is sent out onto the transport. For small data types, this means most messages (and hence network packets) are small. As a consequence the fixed cost of processing a message (or packet) increases load.

Enabling write batching causes the samples to be aggregated into a single larger RTPS message. This improves efficiency by spreading the fixed cost out over more samples. Naturally this increases latency a bit.

The batching mechanism may or may not send out packets on a write/&c. operation. It buffers only a limited amount and will send out what has been buffered when a new write/&c. can not be added. To guarantee that the buffered data is sent, one must call “dds_flush”.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that will store the policy

  • batch_updates[in] - Whether writes should be batched

void dds_qset_durability_service(dds_qos_t *qos, dds_duration_t service_cleanup_delay, dds_history_kind_t history_kind, int32_t history_depth, int32_t max_samples, int32_t max_instances, int32_t max_samples_per_instance)

Set the durability-service policy of a qos structure.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that will store the policy

  • service_cleanup_delay[in] - Delay for purging of abandoned instances from the durability service

  • history_kind[in] - History policy kind applied by the durability service

  • history_depth[in] - History policy depth applied by the durability service

  • max_samples[in] - Number of samples resource-limit policy applied by the durability service

  • max_instances[in] - Number of instances resource-limit policy applied by the durability service

  • max_samples_per_instance[in] - Number of samples per instance resource-limit policy applied by the durability service

void dds_qset_ignorelocal(dds_qos_t *qos, dds_ignorelocal_kind_t ignore)

Set the ignore-local policy of a qos structure.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that will store the policy

  • ignore[in] - True if readers and writers owned by the same participant should be ignored

void dds_qset_prop(dds_qos_t *qos, const char *name, const char *value)

Stores a property with the provided name and string value in a qos structure.

In the case a property with the provided name already exists in the qos structure, the value for this entry is overwritten with the provided string value. If more than one property with the provided name exists, only the value of the first of these properties is updated.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that will store the property

  • name[in] - Pointer to name of the property

  • value[in] - Pointer to a (null-terminated) string that will be stored

void dds_qunset_prop(dds_qos_t *qos, const char *name)

Removes the property with the provided name from a qos structure.

In case more than one property exists with this name, only the first property is removed.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that contains the property

  • name[in] - Pointer to name of the property

void dds_qset_bprop(dds_qos_t *qos, const char *name, const void *value, const size_t sz)

Stores the provided binary data as a property in a qos structure.

In the case a property with the provided name already exists in the qos structure, the value for this entry is overwritten with the provided data. If more than one property with the provided name exists, only the value of the first of these properties is updated.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that will store the property

  • name[in] - Pointer to name of the property

  • value[in] - Pointer to data to be stored in the property

  • sz[in] - Size of the data

void dds_qunset_bprop(dds_qos_t *qos, const char *name)

Removes the binary property with the provided name from a qos structure.

In case more than one binary property exists with this name, only the first binary property is removed.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that contains the binary property

  • name[in] - Pointer to name of the property

void dds_qset_type_consistency(dds_qos_t *qos, dds_type_consistency_kind_t kind, bool ignore_sequence_bounds, bool ignore_string_bounds, bool ignore_member_names, bool prevent_type_widening, bool force_type_validation)

Set the type consistency enforcement policy of a qos structure.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that will store the policy

  • kind[in] - Type consistency policy kind

  • ignore_sequence_bounds[in] - Ignore sequence bounds in type assignability checking

  • ignore_string_bounds[in] - Ignore string bounds in type assignability checking

  • ignore_member_names[in] - Ignore member names in type assignability checking

  • prevent_type_widening[in] - Prevent type widening in type assignability checking

  • force_type_validation[in] - Force type validation in assignability checking

void dds_qset_data_representation(dds_qos_t *qos, uint32_t n, const dds_data_representation_id_t *values)

Set the data representation of a qos structure.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that will store the policy

  • n[in] - Number of data representation values

  • values[in] - Data representation values

void dds_qset_entity_name(dds_qos_t *qos, const char *name)

Set the entity name.

When using this QoS to initialize a participant, publisher, subscriber, reader or writer it will take the name set here. This name is visible over discovery and can be used to make sense of network in tooling.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that will store the entity name.

  • name[in] - Pointer to the entity name to set.

void dds_qset_psmx_instances(dds_qos_t *qos, uint32_t n, const char **values)

Set the supported PSMX instances of a qos structure.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that will store the policy

  • n[in] - Number of PSMX instances

  • values[in] - Names of the PSMX instances kind values

Getters

group qos_getters

Functions

bool dds_qget_userdata(const dds_qos_t *qos, void **value, size_t *sz)

Get the userdata from a qos structure.

Parameters
  • qos[in] - Pointer to a dds_qos_t structure storing the policy

  • value[inout] - Pointer that will store the userdata. If sz = 0, then a null pointer, else it is a pointer to an allocated buffer of sz+1 bytes where the last byte is always 0

  • sz[inout] - Pointer that will store the size of userdata

Returns

- false iff any of the arguments is invalid or the qos is not present in the qos object

bool dds_qget_topicdata(const dds_qos_t *qos, void **value, size_t *sz)

Get the topicdata from a qos structure.

Parameters
  • qos[in] - Pointer to a dds_qos_t structure storing the policy

  • value[inout] - Pointer that will store the topicdata. If sz = 0, then a null pointer, else it is a pointer to an allocated buffer of sz+1 bytes where the last byte is always 0

  • sz[inout] - Pointer that will store the size of topicdata

Returns

- false iff any of the arguments is invalid or the qos is not present in the qos object

bool dds_qget_groupdata(const dds_qos_t *qos, void **value, size_t *sz)

Get the groupdata from a qos structure.

Parameters
  • qos[in] - Pointer to a dds_qos_t structure storing the policy

  • value[inout] - Pointer that will store the groupdata. If sz = 0, then a null pointer, else it is a pointer to an allocated buffer of sz+1 bytes where the last byte is always 0

  • sz[inout] - Pointer that will store the size of groupdata

Returns

- false iff any of the arguments is invalid or the qos is not present in the qos object

bool dds_qget_durability(const dds_qos_t *qos, dds_durability_kind_t *kind)

Get the durability policy from a qos structure.

Parameters
  • qos[in] - Pointer to a dds_qos_t structure storing the policy

  • kind[inout] - Pointer that will store the durability kind

Returns

- false iff any of the arguments is invalid or the qos is not present in the qos object

bool dds_qget_history(const dds_qos_t *qos, dds_history_kind_t *kind, int32_t *depth)

Get the history policy from a qos structure.

Parameters
  • qos[in] - Pointer to a dds_qos_t structure storing the policy

  • kind[inout] - Pointer that will store the history kind (optional)

  • depth[inout] - Pointer that will store the history depth (optional)

Returns

- false iff any of the arguments is invalid or the qos is not present in the qos object

bool dds_qget_resource_limits(const dds_qos_t *qos, int32_t *max_samples, int32_t *max_instances, int32_t *max_samples_per_instance)

Get the resource-limits policy from a qos structure.

Parameters
  • qos[in] - Pointer to a dds_qos_t structure storing the policy

  • max_samples[inout] - Pointer that will store the number of samples resource-limit (optional)

  • max_instances[inout] - Pointer that will store the number of instances resource-limit (optional)

  • max_samples_per_instance[inout] - Pointer that will store the number of samples per instance resource-limit (optional)

Returns

- false iff any of the arguments is invalid or the qos is not present in the qos object

bool dds_qget_presentation(const dds_qos_t *qos, dds_presentation_access_scope_kind_t *access_scope, bool *coherent_access, bool *ordered_access)

Get the presentation policy from a qos structure.

Parameters
  • qos[in] - Pointer to a dds_qos_t structure storing the policy

  • access_scope[inout] - Pointer that will store access scope kind (optional)

  • coherent_access[inout] - Pointer that will store coherent access enable value (optional)

  • ordered_access[inout] - Pointer that will store orderede access enable value (optional)

Returns

- false iff any of the arguments is invalid or the qos is not present in the qos object

bool dds_qget_lifespan(const dds_qos_t *qos, dds_duration_t *lifespan)

Get the lifespan policy from a qos structure.

Parameters
  • qos[in] - Pointer to a dds_qos_t structure storing the policy

  • lifespan[inout] - Pointer that will store lifespan duration

Returns

- false iff any of the arguments is invalid or the qos is not present in the qos object

bool dds_qget_deadline(const dds_qos_t *qos, dds_duration_t *deadline)

Get the deadline policy from a qos structure.

Parameters
  • qos[in] - Pointer to a dds_qos_t structure storing the policy

  • deadline[inout] - Pointer that will store deadline duration

Returns

- false iff any of the arguments is invalid or the qos is not present in the qos object

bool dds_qget_latency_budget(const dds_qos_t *qos, dds_duration_t *duration)

Get the latency-budget policy from a qos structure.

Parameters
  • qos[in] - Pointer to a dds_qos_t structure storing the policy

  • duration[inout] - Pointer that will store latency-budget duration

Returns

- false iff any of the arguments is invalid or the qos is not present in the qos object

bool dds_qget_ownership(const dds_qos_t *qos, dds_ownership_kind_t *kind)

Get the ownership policy from a qos structure.

Parameters
  • qos[in] - Pointer to a dds_qos_t structure storing the policy

  • kind[inout] - Pointer that will store the ownership kind

Returns

- false iff any of the arguments is invalid or the qos is not present in the qos object

bool dds_qget_ownership_strength(const dds_qos_t *qos, int32_t *value)

Get the ownership strength qos policy.

Parameters
  • qos[in] - Pointer to a dds_qos_t structure storing the policy

  • value[inout] - Pointer that will store the ownership strength value

Returns

- false iff any of the arguments is invalid or the qos is not present in the qos object

bool dds_qget_liveliness(const dds_qos_t *qos, dds_liveliness_kind_t *kind, dds_duration_t *lease_duration)

Get the liveliness qos policy.

Parameters
  • qos[in] - Pointer to a dds_qos_t structure storing the policy

  • kind[inout] - Pointer that will store the liveliness kind (optional)

  • lease_duration[inout] - Pointer that will store the liveliness lease duration (optional)

Returns

- false iff any of the arguments is invalid or the qos is not present in the qos object

bool dds_qget_time_based_filter(const dds_qos_t *qos, dds_duration_t *minimum_separation)

Get the time-based filter qos policy.

Parameters
  • qos[in] - Pointer to a dds_qos_t structure storing the policy

  • minimum_separation[inout] - Pointer that will store the minimum separation duration (optional)

Returns

- false iff any of the arguments is invalid or the qos is not present in the qos object

bool dds_qget_partition(const dds_qos_t *qos, uint32_t *n, char ***ps)

Get the partition qos policy.

Parameters
  • qos[in] - Pointer to a dds_qos_t structure storing the policy

  • n[inout] - Pointer that will store the number of partitions (optional)

  • ps[inout] - Pointer that will store the string(s) containing partition name(s) (optional)

Returns

- false iff any of the arguments is invalid or the qos is not present in the qos object

bool dds_qget_reliability(const dds_qos_t *qos, dds_reliability_kind_t *kind, dds_duration_t *max_blocking_time)

Get the reliability qos policy.

Parameters
  • qos[in] - Pointer to a dds_qos_t structure storing the policy

  • kind[inout] - Pointer that will store the reliability kind (optional)

  • max_blocking_time[inout] - Pointer that will store the max blocking time for reliable reliability (optional)

Returns

- false iff any of the arguments is invalid or the qos is not present in the qos object

bool dds_qget_transport_priority(const dds_qos_t *qos, int32_t *value)

Get the transport priority qos policy.

Parameters
  • qos[in] - Pointer to a dds_qos_t structure storing the policy

  • value[inout] - Pointer that will store the transport priority value

Returns

- false iff any of the arguments is invalid or the qos is not present in the qos object

bool dds_qget_destination_order(const dds_qos_t *qos, dds_destination_order_kind_t *kind)

Get the destination-order qos policy.

Parameters
  • qos[in] - Pointer to a dds_qos_t structure storing the policy

  • kind[inout] - Pointer that will store the destination-order kind

Returns

- false iff any of the arguments is invalid or the qos is not present in the qos object

bool dds_qget_writer_data_lifecycle(const dds_qos_t *qos, bool *autodispose)

Get the writer data-lifecycle qos policy.

Parameters
  • qos[in] - Pointer to a dds_qos_t structure storing the policy

  • autodispose[inout] - Pointer that will store the autodispose unregistered instances enable value

Returns

- false iff any of the arguments is invalid or the qos is not present in the qos object

bool dds_qget_reader_data_lifecycle(const dds_qos_t *qos, dds_duration_t *autopurge_nowriter_samples_delay, dds_duration_t *autopurge_disposed_samples_delay)

Get the reader data-lifecycle qos policy.

Parameters
  • qos[in] - Pointer to a dds_qos_t structure storing the policy

  • autopurge_nowriter_samples_delay[inout] - Pointer that will store the delay for auto-purging samples from instances in a no-writer state (optional)

  • autopurge_disposed_samples_delay[inout] - Pointer that will store the delay for auto-purging of disposed instances (optional)

Returns

- false iff any of the arguments is invalid or the qos is not present in the qos object

bool dds_qget_writer_batching(const dds_qos_t *qos, bool *batch_updates)

Get the writer batching qos policy.

Parameters
  • qos[in] - Pointer to a dds_qos_t structure storing the policy

  • batch_updates[inout] - Pointer that will store the batching enable value

Returns

- false iff any of the arguments is invalid or the qos is not present in the qos object

bool dds_qget_durability_service(const dds_qos_t *qos, dds_duration_t *service_cleanup_delay, dds_history_kind_t *history_kind, int32_t *history_depth, int32_t *max_samples, int32_t *max_instances, int32_t *max_samples_per_instance)

Get the durability-service qos policy values.

Parameters
  • qos[in] - Pointer to a dds_qos_t structure storing the policy

  • service_cleanup_delay[inout] - Pointer that will store the delay for purging of abandoned instances from the durability service (optional)

  • history_kind[inout] - Pointer that will store history policy kind applied by the durability service (optional)

  • history_depth[inout] - Pointer that will store history policy depth applied by the durability service (optional)

  • max_samples[inout] - Pointer that will store number of samples resource-limit policy applied by the durability service (optional)

  • max_instances[inout] - Pointer that will store number of instances resource-limit policy applied by the durability service (optional)

  • max_samples_per_instance[inout] - Pointer that will store number of samples per instance resource-limit policy applied by the durability service (optional)

Returns

- false iff any of the arguments is invalid or the qos is not present in the qos object

bool dds_qget_ignorelocal(const dds_qos_t *qos, dds_ignorelocal_kind_t *ignore)

Get the ignore-local qos policy.

Parameters
  • qos[in] - Pointer to a dds_qos_t structure storing the policy

  • ignore[inout] - Pointer that will store whether to ignore readers/writers owned by the same participant (optional)

Returns

- false iff any of the arguments is invalid or the qos is not present in the qos object

bool dds_qget_propnames(const dds_qos_t *qos, uint32_t *n, char ***names)

Gets the names of the properties from a qos structure.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that contains properties

  • n[inout] - Pointer to number of property names that are returned (optional)

  • names[inout] - Pointer that will store the string(s) containing property name(s) (optional). This function will allocate the memory for the list of names and for the strings containing the names; the caller gets ownership of the allocated memory

Returns

- false iff any of the arguments is invalid or the qos is not present in the qos object

bool dds_qget_prop(const dds_qos_t *qos, const char *name, char **value)

Get the value of the property with the provided name from a qos structure.

In case more than one property exists with this name, the value for the first property with this name will be returned.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that contains the property

  • name[in] - Pointer to name of the property

  • value[inout] - Pointer to a string that will store the value of the property. The memory for storing the string value will be allocated by this function and the caller gets ownership of the allocated memory

Returns

- false iff any of the arguments is invalid, the qos is not present in the qos object or there was no property found with the provided name

bool dds_qget_bpropnames(const dds_qos_t *qos, uint32_t *n, char ***names)

Gets the names of the binary properties from a qos structure.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that contains binary properties

  • n[inout] - Pointer to number of binary property names that are returned (optional)

  • names[inout] - Pointer that will store the string(s) containing binary property name(s) (optional). This function will allocate the memory for the list of names and for the strings containing the names; the caller gets ownership of the allocated memory

Returns

- false iff any of the arguments is invalid or the qos is not present in the qos object

bool dds_qget_bprop(const dds_qos_t *qos, const char *name, void **value, size_t *sz)

Get the value of the binary property with the provided name from a qos structure.

In case more than one binary property exists with this name, the value for the first binary property with this name will be returned.

Parameters
  • qos[inout] - Pointer to a dds_qos_t structure that contains the property

  • name[in] - Pointer to name of the binary property

  • value[inout] - Pointer to a buffer that will store the value of the property. If sz = 0 then a NULL pointer. The memory for storing the value will be allocated by this function and the caller gets ownership of the allocated memory

  • sz[inout] - Pointer that will store the size of the returned buffer.

Returns

- false iff any of the arguments is invalid, the qos is not present in the qos object or there was no binary property found with the provided name

bool dds_qget_type_consistency(const dds_qos_t *qos, dds_type_consistency_kind_t *kind, bool *ignore_sequence_bounds, bool *ignore_string_bounds, bool *ignore_member_names, bool *prevent_type_widening, bool *force_type_validation)

Get the type consistency enforcement qos policy values.

Parameters
  • qos[in] - Pointer to a dds_qos_t structure storing the policy

  • kind[inout] - Pointer that will store the type consistency enforcement kind (optional)

  • ignore_sequence_bounds[inout] - Pointer that will store the boolean value for ignoring sequence bounds in type assignability checking (optional)

  • ignore_string_bounds[inout] - Pointer that will store the boolean value for ignoring string bounds in type assignability checking (optional)

  • ignore_member_names[inout] - Pointer that will store the boolean value for ignoring member names in type assignability checking (optional)

  • prevent_type_widening[inout] - Pointer that will store the boolean value to prevent type widening in type assignability checking (optional)

  • force_type_validation[inout] - Pointer that will store the boolean value to force type validation in assignability checking (optional)

Returns

- false iff any of the arguments is invalid or the qos is not present in the qos object

bool dds_qget_data_representation(const dds_qos_t *qos, uint32_t *n, dds_data_representation_id_t **values)

Get the data representation qos policy value.

Returns the data representation values that are set in the provided QoS object and stores the number of values in out parameter ‘n’. In case the ‘values’ parameter is provided, this function will allocate a buffer that contains the data representation values, and set ‘values’ to point to this buffer. It is the responsibility of the caller to free the memory of this buffer.

Parameters
  • qos[in] - Pointer to a dds_qos_t structure storing the policy

  • n[inout] - Pointer that will store the number of data representation values

  • values[inout] - Pointer that will store the data representation values (optional)

Returns

- false iff any of the arguments is invalid or the qos is not present in the qos object

bool dds_qget_entity_name(const dds_qos_t *qos, char **name)

Get the entity name from a qos structure.

Parameters
  • qos[in] - Pointer to a dds_qos_t structure storing the entity name

  • name[inout] - Pointer to a string that will store the returned entity name

Returns

- false iff any of the arguments is invalid or the qos is not present in the qos object or if a buffer to store the name could not be allocated.

bool dds_qget_psmx_instances(const dds_qos_t *qos, uint32_t *n_out, char ***values)

Gets the names of the PSMX instances set in a qos structure.

Parameters
  • qos – Pointer to a dds_qos_t structure

  • n_out – Number of PSMX instance names returned

  • values – Names of the PSMX instances

Returns

bool indicating success or failure