diff options
Diffstat (limited to 'src/components/policy/policy_external/include/policy/policy_table')
-rw-r--r-- | src/components/policy/policy_external/include/policy/policy_table/enums.h | 381 | ||||
-rw-r--r-- | src/components/policy/policy_external/include/policy/policy_table/types.h | 12 |
2 files changed, 384 insertions, 9 deletions
diff --git a/src/components/policy/policy_external/include/policy/policy_table/enums.h b/src/components/policy/policy_external/include/policy/policy_table/enums.h index 4f8ae5c98d..34864c5602 100644 --- a/src/components/policy/policy_external/include/policy/policy_table/enums.h +++ b/src/components/policy/policy_external/include/policy/policy_table/enums.h @@ -44,6 +44,7 @@ enum Priority { P_VOICECOM, P_COMMUNICATION, P_NORMAL, + P_PROJECTION, P_NONE, }; @@ -66,20 +67,24 @@ enum Parameter { P_SPEED, P_ENGINETORQUE, P_EXTERNALTEMPERATURE, + P_TURNSIGNAL, P_FUELLEVEL, P_FUELLEVEL_STATE, P_HEADLAMPSTATUS, P_INSTANTFUELCONSUMPTION, + P_FUELRANGE, P_ODOMETER, P_TIREPRESSURE, P_WIPERSTATUS, P_VIN, P_ACCPEDALPOSITION, P_BELTSTATUS, + P_ELECTRONICPARKBRAKESTATUS, P_DRIVERBRAKING, P_PRNDL, P_RPM, P_STEERINGWHEELANGLE, + P_ENGINEOILLIFE, P_MYKEY, P_AIRBAGSTATUS, P_BODYINFORMATION, @@ -88,7 +93,6 @@ enum Parameter { P_EMERGENCYEVENT, P_ECALLINFO, P_ABS_STATE, - P_TURN_SIGNAL, P_FUEL_RANGE, P_TIRE_PRESSURE_VALUE, P_TPMS, @@ -147,7 +151,9 @@ enum RequestType { RT_VEHICLE_DIAGNOSTICS, RT_EMERGENCY, RT_MEDIA, - RT_FOTA + RT_FOTA, + RT_OEM_SPECIFIC, + RT_EMPTY // Added to allow empty Request Types handling }; bool IsValidEnum(RequestType val); @@ -165,11 +171,382 @@ bool EnumFromJsonString(const std::string& literal, Input* result); enum ModuleType { MT_CLIMATE, MT_RADIO, + MT_SEAT, + MT_AUDIO, + MT_LIGHT, + MT_HMI_SETTINGS, + MT_EMPTY }; bool IsValidEnum(ModuleType val); const char* EnumToJsonString(ModuleType val); bool EnumFromJsonString(const std::string& literal, ModuleType* result); +/** + * @brief Enumeration FunctionID. + * + * Enumeration linking function names with function IDs in AppLink protocol. + * Assumes enumeration starts at value 0. + */ +enum FunctionID { + /** + * @brief RESERVED. + */ + RESERVED = 0, + + /** + * @brief RegisterAppInterfaceID. + */ + RegisterAppInterfaceID = 1, + + /** + * @brief UnregisterAppInterfaceID. + */ + UnregisterAppInterfaceID = 2, + + /** + * @brief SetGlobalPropertiesID. + */ + SetGlobalPropertiesID = 3, + + /** + * @brief ResetGlobalPropertiesID. + */ + ResetGlobalPropertiesID = 4, + + /** + * @brief AddCommandID. + */ + AddCommandID = 5, + + /** + * @brief DeleteCommandID. + */ + DeleteCommandID = 6, + + /** + * @brief AddSubMenuID. + */ + AddSubMenuID = 7, + + /** + * @brief DeleteSubMenuID. + */ + DeleteSubMenuID = 8, + + /** + * @brief CreateInteractionChoiceSetID. + */ + CreateInteractionChoiceSetID = 9, + + /** + * @brief PerformInteractionID. + */ + PerformInteractionID = 10, + + /** + * @brief DeleteInteractionChoiceSetID. + */ + DeleteInteractionChoiceSetID = 11, + + /** + * @brief AlertID. + */ + AlertID = 12, + + /** + * @brief ShowID. + */ + ShowID = 13, + + /** + * @brief SpeakID. + */ + SpeakID = 14, + + /** + * @brief SetMediaClockTimerID. + */ + SetMediaClockTimerID = 15, + + /** + * @brief PerformAudioPassThruID. + */ + PerformAudioPassThruID = 16, + + /** + * @brief EndAudioPassThruID. + */ + EndAudioPassThruID = 17, + + /** + * @brief SubscribeButtonID. + */ + SubscribeButtonID = 18, + + /** + * @brief UnsubscribeButtonID. + */ + UnsubscribeButtonID = 19, + + /** + * @brief SubscribeVehicleDataID. + */ + SubscribeVehicleDataID = 20, + + /** + * @brief UnsubscribeVehicleDataID. + */ + UnsubscribeVehicleDataID = 21, + + /** + * @brief GetVehicleDataID. + */ + GetVehicleDataID = 22, + + /** + * @brief ReadDIDID. + */ + ReadDIDID = 23, + + /** + * @brief GetDTCsID. + */ + GetDTCsID = 24, + + /** + * @brief ScrollableMessageID. + */ + ScrollableMessageID = 25, + + /** + * @brief SliderID. + */ + SliderID = 26, + + /** + * @brief ShowConstantTBTID. + */ + ShowConstantTBTID = 27, + + /** + * @brief AlertManeuverID. + */ + AlertManeuverID = 28, + + /** + * @brief UpdateTurnListID. + */ + UpdateTurnListID = 29, + + /** + * @brief ChangeRegistrationID. + */ + ChangeRegistrationID = 30, + + /** + * @brief GenericResponseID. + */ + GenericResponseID = 31, + + /** + * @brief PutFileID. + */ + PutFileID = 32, + + /** + * @brief DeleteFileID. + */ + DeleteFileID = 33, + + /** + * @brief ListFilesID. + */ + ListFilesID = 34, + + /** + * @brief SetAppIconID. + */ + SetAppIconID = 35, + + /** + * @brief SetDisplayLayoutID. + */ + SetDisplayLayoutID = 36, + + /** + * @brief DiagnosticMessageID. + */ + DiagnosticMessageID = 37, + + /** + * @brief SystemRequestID. + */ + SystemRequestID = 38, + + /** + * @brief SendLocationID. + */ + SendLocationID = 39, + + /** + * @brief DialNumberID. + */ + DialNumberID = 40, + + /** + * @brief ButtonPressID. + */ + ButtonPressID = 41, + + /** + * @brief GetInteriorVehicleDataID. + */ + GetInteriorVehicleDataID = 43, + + /** + * @brief SetInteriorVehicleDataID. + */ + SetInteriorVehicleDataID = 44, + + /** + * @brief GetWayPointsID. + */ + GetWayPointsID = 45, + + /** + * @brief SubscribeWayPointsID. + */ + SubscribeWayPointsID = 46, + + /** + * @brief UnsubscribeWayPointsID. + */ + UnsubscribeWayPointsID = 47, + + /** + * @brief GetSystemCapabilityID. + */ + GetSystemCapabilityID = 48, + + /** + * @brief SendHapticDataID. + */ + SendHapticDataID = 49, + + /** + * @brief OnHMIStatusID. + */ + OnHMIStatusID = 32768, + + /** + * @brief OnAppInterfaceUnregisteredID. + */ + OnAppInterfaceUnregisteredID = 32769, + + /** + * @brief OnButtonEventID. + */ + OnButtonEventID = 32770, + + /** + * @brief OnButtonPressID. + */ + OnButtonPressID = 32771, + + /** + * @brief OnVehicleDataID. + */ + OnVehicleDataID = 32772, + + /** + * @brief OnCommandID. + */ + OnCommandID = 32773, + + /** + * @brief OnTBTClientStateID. + */ + OnTBTClientStateID = 32774, + + /** + * @brief OnDriverDistractionID. + */ + OnDriverDistractionID = 32775, + + /** + * @brief OnPermissionsChangeID. + */ + OnPermissionsChangeID = 32776, + + /** + * @brief OnAudioPassThruID. + */ + OnAudioPassThruID = 32777, + + /** + * @brief OnLanguageChangeID. + */ + OnLanguageChangeID = 32778, + + /** + * @brief OnKeyboardInputID. + */ + OnKeyboardInputID = 32779, + + /** + * @brief OnTouchEventID. + */ + OnTouchEventID = 32780, + + /** + * @brief OnSystemRequestID. + */ + OnSystemRequestID = 32781, + + /** + * @brief OnHashChangeID. + */ + OnHashChangeID = 32782, + + /** + * @brief OnInteriorVehicleDataID. + */ + OnInteriorVehicleDataID = 32783, + + /** + * @brief OnWayPointChangeID. + */ + OnWayPointChangeID = 32784, + + /** + * @brief OnRCStatusID. + */ + OnRCStatusID = 32785, + + /** + * @brief EncodedSyncPDataID. + */ + EncodedSyncPDataID = 65536, + + /** + * @brief SyncPDataID. + */ + SyncPDataID = 65537, + + /** + * @brief OnEncodedSyncPDataID. + */ + OnEncodedSyncPDataID = 98304, + + /** + * @brief OnSyncPDataID. + */ + OnSyncPDataID = 98305 +}; +bool IsValidEnum(FunctionID val); +const char* EnumToJsonString(FunctionID val); +bool EnumFromJsonString(const std::string& literal, FunctionID* result); + extern const std::string kDefaultApp; extern const std::string kPreDataConsentApp; extern const std::string kDeviceApp; diff --git a/src/components/policy/policy_external/include/policy/policy_table/types.h b/src/components/policy/policy_external/include/policy/policy_table/types.h index 53f5a35b99..68e29a97ee 100644 --- a/src/components/policy/policy_external/include/policy/policy_table/types.h +++ b/src/components/policy/policy_external/include/policy/policy_table/types.h @@ -78,7 +78,7 @@ typedef Map<URL, 1, 255> URLList; typedef Map<URLList, 1, 255> ServiceEndpoints; typedef uint8_t NumberOfNotificationsType; -typedef Map<Integer<NumberOfNotificationsType, 0, 255>, 0, 6> +typedef Map<Integer<NumberOfNotificationsType, 0, 255>, 0, 7> NumberOfNotificationsPerMinute; typedef Array<Integer<uint16_t, 1, 1000>, 0, 5> SecondsBetweenRetries; @@ -102,11 +102,11 @@ typedef Map<DeviceParams, 0, 255> DeviceData; typedef Array<Enum<RequestType>, 0, 255> RequestsTypeArray; -#ifdef SDL_REMOTE_CONTROL +typedef Strings RequestSubTypes; + typedef Map<Strings, 0, 255> RemoteRpcs; typedef Map<RemoteRpcs, 0, 255> AccessModules; typedef Array<Enum<ModuleType>, 0, 255> ModuleTypes; -#endif // SDL_REMOTE_CONTROL typedef AppHMIType AppHmiType; typedef std::vector<AppHMIType> AppHmiTypes; @@ -173,11 +173,10 @@ struct ApplicationParams : PolicyBase { Optional<Strings> nicknames; Optional<AppHMITypes> AppHMIType; Optional<RequestTypes> RequestType; + Optional<RequestSubTypes> RequestSubType; Optional<Integer<uint16_t, 0, 65225> > memory_kb; Optional<Integer<uint32_t, 0, UINT_MAX> > heart_beat_timeout_ms; -#ifdef SDL_REMOTE_CONTROL mutable Optional<ModuleTypes> moduleType; -#endif // SDL_REMOTE_CONTROL public: ApplicationParams(); @@ -197,9 +196,7 @@ struct ApplicationParams : PolicyBase { private: bool Validate() const; -#ifdef SDL_REMOTE_CONTROL bool ValidateModuleTypes() const; -#endif // SDL_REMOTE_CONTROL }; struct ApplicationPoliciesSection : CompositeType { @@ -306,6 +303,7 @@ struct ModuleConfig : CompositeType { Optional<String<0, 10> > preloaded_date; Optional<String<0, 65535> > certificate; Optional<Boolean> preloaded_pt; + Optional<Boolean> full_app_id_supported; public: ModuleConfig(); |