Obtains the user data attached to an attribute.
GSErrCode ACAPI_Attribute_GetUserData ( API_Attr_Head* attrHead, API_AttributeUserData* userData );
Parameters
- attrHead
- [in] Header of the attribute (only fields typeID and index are used).
- userData
- [in/out] Pointer to the user data.
Return Values
NoError
- The function has completed with success.
APIERR_BADPARS
- Any of the passed parameters is
nullptr
APIERR_BADPLATFORMSIGN
- The user data contained platform sign is invalid (out of range)
APIERR_MEMFULL
- Out of memory
APIERR_NOUSERDATA
- No user data attached by the caller module
For other common API errors see the API Errors document.
Remarks
This function is used to get the user attached data from an atribute. The typeID
and index
fields of the DDD
record has to be filled to get the data attached to the attribute.
The caller should not allocate the userData->dataHdl field. It’s allocated by the function itself but should be destroyed after use by the caller!
Use the ACAPI_Attribute_SetUserData functions to push data into the attribute record.
Requirements
- Version: API 4.1 or later
- Header: ACAPinc.h
See Also
API_Attr_Head, API_AttributeUserData,
ACAPI_Attribute_SetUserData,
Attribute Manager, API Functions