ACAPI_​Override_​GetOverrideCombination

Retrieves an override combination identified by its guid or name.

        GSErrCode  ACAPI_Override_GetOverrideCombination (
            API_OverrideCombination&          combination,
            GS::Array<API_Guid>*              ruleList = nullptr
        );
    

 

Parameters

combination
[in] The guid field specifies the combination to retrieve. If the guid field is APINULLGuid, then the name field is used to find the combination.
[out] The retrieved combination.
ruleList
[out] If not a nullptr, then the list of guids of the rules that the combination “contains”.

 

Return Values

NoError
The function has completed with success.
APIERR_BADID
The guid or name did not refer to a valid override rule.

For other common API errors see the API Errors document.

 

Example



GSErrCode GetOverrideCombinationNames (GS::Array<GS::UniString>& combinationNames)
{
    GS::Array<API_Guid> combinationsGuids;
    GSErrCode error = ACAPI_Override_GetOverrideCombinationList (combinationsGuids);
    if (error == NoError) {
        for (USize i = 0; i < combinationsGuids.GetSize(); ++i) {
            API_OverrideCombination combination = {combinationsGuids[i]};
            error = ACAPI_Override_GetOverrideCombination (combination, nullptr);
            if (error == NoError) {
                combinationNames.Push (combination.name);
            }
        }
    }

    return error;
}

For more detailed examples, please see the Override_Test add-on.

 

Requirements

Version: API 20 or later
Header: ACAPinc.h

 

See Also

Visual Override,
API Functions