1) Initiate sending GetListOfPermissions with “appID” parameter in the following cases:
1.1) After receiving SDL.ActivateApp{isPermissionsConsentNeeded: true} from SDL.
Note: appID is known from the corresponding SDL.ActivateApp request.
1.2) After receiving SDL.OnAppPermissionChanged{appID, appPermissionsConsentNeeded: true} from SDL.
1.3) After the User presses the button to change the permissions for the application.
1.4) After ignition on to retrieve the "External UCS Status" setting stored on SDL.
2) Initiate sending GetListOfPermissions without “appID” parameter in the following cases:
2.1) After the User presses the button to change the permissions of all currently registered applications.
When GetListOfPermissions is requested without “appID” parameter, the response of PermissionItem array contains the PermissionGroups (“name” parameters) for all the applications as a whole and “allowed” parameter is common for each group (e.g. if at least one of the applications has disallowed parameter for some group, “allowed” value returned for this group in the context of all application must be false). (For more details see the diagram GetListOfPermissions without appID).
3) Store the pair of values id<->name of PermissionItem structure which were obtained via GetListOfPermissions response. These pairs will be used for future notifications via OnAppPermissionConsent in case user’s choice for the application to allow some functionality has been updated (For more details see OnAppPermissionConsent (id<->name dependency).
4) Display the received “External UCS Status” in the appropriate UI screen (For more details see the picture ExternalConsentStatus).
a) The information about the application (name, ID, etc.) is provided by SDL via either BasicCommunication.UpdateAppList or BasicCommunication.OnAppRegistered RPCs.
b) If HMI has never sent externalConsentStatus before (via OnAppPermissionConsent), SDL will respond with empty array.
c) User can go to settings on HMI and enable or disable "External UCS" for an "entity". HMI will notify SDL accordingly (see figure ExternalConsentStatus).
d) The resulting allowance of functional grouping is informed by parameter “allowedFunctions” to HMI in accordance with result of ExternalConsentStatus.
Name | Type | Mandatory | Additional |
---|---|---|---|
appID | Integer | false |
Name | Type | Mandatory | Additional |
---|---|---|---|
allowedFunctions | Common.PermissionItem | true | array: true minsize: 0 maxsize: 100 |
externalConsentStatus | Common.ExternalConsentStatus | true | array: true minsize: 0 maxsize: 100 |
{ "id" : 143, "jsonrpc" : "2.0", "method" : "SDL.GetListOfPermissions", "params" : { "appID" : 65596 } }
{ "id": 143, "jsonrpc": "2.0", "result": { "allowedFunctions": [ { "name": "Location-1", "id": 1234, "allowed": true }, { "name": "Notifications", "id": 76876, "allowed": false } ], "externalConsentStatus": [ { "entityType": 0, "entityID": 126, "status": "ON" } ], "code": 0, "method": "SDL.GetListOfPermissions" } }
{ "id" : 143, "jsonrpc" : "2.0", "error" : { "code" : 15, "message" : " A command cannot be executed because there is NO specified with appID application registered ", "data" : { "method" : "SDL.GetListOfPermissions" } } }