Update GattAttribute.h

Make minor copy edits for precise language and active voice.
pull/5549/head
Amanda Butler 2017-11-21 15:03:03 -06:00 committed by GitHub
parent d153af332c
commit 036ea46c8f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 21 additions and 21 deletions

View File

@ -34,23 +34,23 @@
* *
* Attributes are the building block of GATT servers: services are attributes, * Attributes are the building block of GATT servers: services are attributes,
* characteristics are groups of attributes and characteristic descriptors are * characteristics are groups of attributes and characteristic descriptors are
* attributes too. * attributes, too.
* *
* @par Typed values * @par Typed values
* *
* Attributes are typed values composed of a type and its associated value. The * Attributes are typed values composed of a type and its associated value. The
* attribute type identifies the attribute purpose and is modelled by a UUID * attribute type identifies the attribute purpose. A UUID read by the client
* read by the client during the discovery of the gatt server. The value of the * during the discovery of the GATT server models the attribute type. The value of the
* attribute is an array of bytes; its length may be fixed or variable. * attribute is an array of bytes; its length may be fixed or variable.
* *
* As an example a primary service is declared by an attribute with the type * As an example, a primary service is declared by an attribute with the type
* 0x2800 and the value of the attribute is the UUID of the service. * 0x2800, and the value of the attribute is the UUID of the service.
* *
* @par Attribute Access * @par Attribute Access
* *
* The GATT server is an array of attributes were each of the attributes is * The GATT server is an array of attributes in which a unique index identifies
* identified within the array by a unique index. That index is called the * each of the attributes within the array. That index is called the attribute
* attribute handle and clients use it to access to attributes within the server. * handle, and clients use it to access to attributes within the server.
* *
* @note Attributes do not contain information related to their permissions, * @note Attributes do not contain information related to their permissions,
* grouping or semantic. Higher level specifications define these concepts. * grouping or semantic. Higher level specifications define these concepts.
@ -60,9 +60,9 @@ public:
/** /**
* Representation of an attribute handle. * Representation of an attribute handle.
* *
* Each attribute in a GattServer have a unique handle that can be used by * Each attribute in a GattServer has a unique handle that clients can use
* clients to identify the attribute. The underlying BLE stack usually * to identify the attribute. The underlying BLE stack usually
* generates and assign handles to attributes. * generates and assigns handles to attributes.
*/ */
typedef ble::attribute_handle_t Handle_t; typedef ble::attribute_handle_t Handle_t;
@ -75,19 +75,19 @@ public:
/** /**
* Construct an attribute. * Construct an attribute.
* *
* Application code use attributes to model characteristic descriptors and * Application code uses attributes to model characteristic descriptors and
* characteristics values. * characteristics values.
* *
* @param[in] uuid The type of the attribute. * @param[in] uuid The type of the attribute.
* @param[in] valuePtr Pointer to the memory buffer which contains the * @param[in] valuePtr Pointer to the memory buffer, which contains the
* initial value of the attribute. The constructor does not make a copy of * initial value of the attribute. The constructor does not make a copy of
* the attribute buffer; as a consequence the memory buffer must remain * the attribute buffer; as a consequence, the memory buffer must remain
* valid during the lifetime of the attribute. * valid during the lifetime of the attribute.
* @param[in] len The length in bytes of this attribute's value. * @param[in] len The length in bytes of this attribute's value.
* @param[in] maxLen The length in bytes of the memory buffer containing the * @param[in] maxLen The length in bytes of the memory buffer containing the
* attribute value. It must be greater than or equal to @p len. * attribute value. It must be greater than or equal to @p len.
* @param[in] hasVariableLen Flag that indicate if the attribute's value * @param[in] hasVariableLen Flag that indicates whether the attribute's value
* length can changes over time. * length can change throughout time.
* *
* @par Example * @par Example
* *
@ -121,7 +121,7 @@ public:
/** /**
* Get the attribute's handle in the ATT table. * Get the attribute's handle in the ATT table.
* *
* @note The attribute's handle is set by the GattServer when services are * @note The GattServer sets the attribute's handle when services are
* inserted. * inserted.
* *
* @return The attribute's handle. * @return The attribute's handle.
@ -178,8 +178,8 @@ public:
/** /**
* Set the attribute handle. * Set the attribute handle.
* *
* @important This function is used internally by the GattServer and must * @important The GattServer uses this function internally.
* not be used by application code. * Application code must not use it.
* *
* @param[in] id The new attribute handle. * @param[in] id The new attribute handle.
*/ */
@ -199,7 +199,7 @@ public:
} }
/** /**
* Check whether the length of the attribute's value can change over time. * Check whether the length of the attribute's value can change throughout time.
* *
* @return true if the attribute value has a variable length and false * @return true if the attribute value has a variable length and false
* otherwise. * otherwise.
@ -231,7 +231,7 @@ private:
uint16_t _len; uint16_t _len;
/** /**
* Whether the length of the value can change over time. * Whether the length of the value can change throughout time.
*/ */
bool _hasVariableLen; bool _hasVariableLen;