ACAPI_​Element_​GetComponents

Retrieves the components of an element.

    GSErrCode  ACAPI_Element_GetComponents (
        API_Guid&                          elemGuid
        GS::Array<API_ElemComponentID>&    elemComponents
    );

 

Parameters

elemGuid
[in] Guid of the element whose components have to be retrieved.
elemComponents
[out] The components of the specified element.

 

Return Values

NoError
The function has completed with success.
APIERR_BADID
The elemGuid did not refer to a valid element.

For other common API errors see the API Errors document.

Example

            
GSErrCode GetElemCompnentCount (const API_Guid& elemGuid, USize& componentCount)
{
    GS::Array<API_ElemComponentID> components;

    const GSErrCode error = ACAPI_Element_GetComponents (elemGuid, components);
    if (error == NoError) {
        componentCount = components.GetSize ();
    }

    return error;
}
            
        

Requirements

Version: API 25 or later
Header: ACAPinc.h

See Also

API_ElemComponentID