@@ -3039,7 +3039,7 @@ rmw_count_services(
3039
3039
const char * service_name ,
3040
3040
size_t * count );
3041
3041
3042
- /// Get the unique identifier (gid ) of a publisher.
3042
+ /// Get the globally unique identifier (GID ) of a publisher.
3043
3043
/**
3044
3044
* <hr>
3045
3045
* Attribute | Adherence
@@ -3055,12 +3055,16 @@ rmw_count_services(
3055
3055
* Publishers are thread-safe objects, and so are all operations on them except for
3056
3056
* finalization.
3057
3057
* Therefore, it is safe to get the unique identifier from the same publisher concurrently.
3058
- * However, access to the gid is not synchronized.
3058
+ * However, access to the GID is not synchronized.
3059
3059
* It is not safe to read or write `gid` while rmw_get_gid_for_publisher() uses it.
3060
3060
*
3061
3061
* \pre Given `publisher` must be a valid publisher, as returned by rmw_create_publisher().
3062
3062
*
3063
- * \param[in] publisher Publisher to get a gid from.
3063
+ * This is expected to be globally unique within a ROS domain.
3064
+ * The identifier should be the same when reported both locally (where the entity was created)
3065
+ * and on remote hosts or processes.
3066
+ *
3067
+ * \param[in] publisher Publisher to get a GID from.
3064
3068
* \param[out] gid Publisher's unique identifier, populated on success
3065
3069
* but left unchanged on failure.
3066
3070
* \return `RMW_RET_OK` if successful, or
@@ -3075,7 +3079,7 @@ RMW_WARN_UNUSED
3075
3079
rmw_ret_t
3076
3080
rmw_get_gid_for_publisher (const rmw_publisher_t * publisher , rmw_gid_t * gid );
3077
3081
3078
- /// Get the unique identifier (gid ) of a service client.
3082
+ /// Get the globally unique identifier (GID ) of a service client.
3079
3083
/**
3080
3084
* <hr>
3081
3085
* Attribute | Adherence
@@ -3091,12 +3095,15 @@ rmw_get_gid_for_publisher(const rmw_publisher_t * publisher, rmw_gid_t * gid);
3091
3095
* Service clients are thread-safe objects, and so are all operations on them except for
3092
3096
* finalization.
3093
3097
* Therefore, it is safe to get the unique identifier from the same client concurrently.
3094
- * However, access to the gid is not synchronized.
3098
+ * However, access to the GID is not synchronized.
3095
3099
* It is not safe to read or write `gid` while rmw_get_gid_for_client() uses it.
3096
3100
*
3097
3101
* \pre Given `client` must be a valid service client, as returned by rmw_create_client().
3098
3102
*
3099
- * \param[in] client Service client to get a gid from.
3103
+ * This is expected to be globally unique within a ROS domain.
3104
+ * The identifier should be the same when reported both locally (where the entity was created)
3105
+ * and on remote hosts or processes.
3106
+ * \param[in] client Service client to get a GID from.
3100
3107
* \param[out] gid Service client's unique identifier, populated on success
3101
3108
* but left unchanged on failure.
3102
3109
* \return `RMW_RET_OK` if successful, or
@@ -3111,7 +3118,7 @@ RMW_WARN_UNUSED
3111
3118
rmw_ret_t
3112
3119
rmw_get_gid_for_client (const rmw_client_t * client , rmw_gid_t * gid );
3113
3120
3114
- /// Check if two unique identifiers (gids ) are equal.
3121
+ /// Check if two globally unique identifiers (GIDs ) are equal.
3115
3122
/**
3116
3123
* <hr>
3117
3124
* Attribute | Adherence
@@ -3125,14 +3132,14 @@ rmw_get_gid_for_client(const rmw_client_t * client, rmw_gid_t * gid);
3125
3132
*
3126
3133
* \par Thread-safety
3127
3134
* Unique identifier comparison is a reentrant function, but:
3128
- * - Access to both gids is read-only but it is not synchronized.
3135
+ * - Access to both GIDs is read-only but it is not synchronized.
3129
3136
* Concurrent `gid1` and `gid2` reads are safe, but concurrent reads and writes are not.
3130
3137
* - Access to primitive data-type arguments is not synchronized.
3131
3138
* It is not safe to read or write `result` while rmw_compare_gids_equal() uses it.
3132
3139
*
3133
3140
* \param[in] gid1 First unique identifier to compare.
3134
3141
* \param[in] gid2 Second unique identifier to compare.
3135
- * \param[out] result true if both gids are equal, false otherwise.
3142
+ * \param[out] result true if both GIDs are equal, false otherwise.
3136
3143
* \return `RMW_RET_OK` if successful, or
3137
3144
* \return `RMW_RET_INVALID_ARGUMENT` if `gid1` or `gid2` is NULL, or
3138
3145
* \return `RMW_RET_INCORRECT_RMW_IMPLEMENTATION` if the implementation
0 commit comments