@@ -539,6 +539,32 @@ rmw_subscription_count_matched_publishers(
539539 const rmw_subscription_t * subscription ,
540540 size_t * publisher_count );
541541
542+ /// Retrieve the actual qos settings of the subscription.
543+ /**
544+ * Query the underlying middleware to determine the qos settings
545+ * of the subscription.
546+ * The actual configuration applied when using RMW_*_SYSTEM_DEFAULT
547+ * can only be resolved after the creation of the subscription, and it
548+ * depends on the underlying rmw implementation.
549+ * If the underlying setting in use can't be represented in ROS terms,
550+ * it will be set to RMW_*_UNKNOWN.
551+ * The value of avoid_ros_namespace_conventions field is not resolved
552+ * with this function. The rcl function rcl_subscription_get_actual_qos
553+ * resolves it.
554+ *
555+ * \param[in] subscription the subscription object to inspect
556+ * \param[out] qos the actual qos settings
557+ * \return `RMW_RET_OK` if successful, or
558+ * \return `RMW_RET_INVALID_ARGUMENT` if either argument is null, or
559+ * \return `RMW_RET_ERROR` if an unexpected error occurs.
560+ */
561+ RMW_PUBLIC
562+ RMW_WARN_UNUSED
563+ rmw_ret_t
564+ rmw_subscription_get_actual_qos (
565+ const rmw_subscription_t * subscription ,
566+ rmw_qos_profile_t * qos );
567+
542568/// Take an incoming message from a subscription.
543569/**
544570 * Take an incoming ROS message from a given subscription.
0 commit comments