summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoel Fischer <joeljfischer@gmail.com>2020-09-18 12:58:55 -0400
committerJoel Fischer <joeljfischer@gmail.com>2020-09-18 12:58:55 -0400
commitd809ebfd42e3dfcbb5cfaaefcf56947fd4d21cef (patch)
tree793918ccc4ff9b60ce5650985283dbcd5a7ba955
parent61ecdedfb61e185fbe726e4b580f12f65282ae88 (diff)
parenteebe4e42dc87526f511bdbec7df25ec05a55acb3 (diff)
downloadsdl_ios-d809ebfd42e3dfcbb5cfaaefcf56947fd4d21cef.tar.gz
Merge branch 'develop' into feature/issue-1387-support-swift-package-manager
-rw-r--r--Example Apps/Example ObjC/RPCPermissionsManager.m2
-rw-r--r--Example Apps/Example ObjC/VehicleDataManager.m21
-rw-r--r--Example Apps/Example Swift/AudioManager.swift4
-rw-r--r--Example Apps/Example Swift/MenuManager.swift12
-rw-r--r--Example Apps/Example Swift/VehicleDataManager.swift8
-rw-r--r--SmartDeviceLink-iOS.xcodeproj/project.pbxproj72
-rw-r--r--SmartDeviceLink/SmartDeviceLink.h6
-rw-r--r--SmartDeviceLink/private/NSMutableDictionary+Store.h5
-rw-r--r--SmartDeviceLink/private/SDLChoiceSetManager.m6
-rw-r--r--SmartDeviceLink/private/SDLEncryptionLifecycleManager.m4
-rw-r--r--SmartDeviceLink/private/SDLFocusableItemLocator.m65
-rw-r--r--SmartDeviceLink/private/SDLH264VideoEncoder.h5
-rw-r--r--SmartDeviceLink/private/SDLLifecycleManager.m23
-rw-r--r--SmartDeviceLink/private/SDLLifecycleSystemRequestHandler.m2
-rw-r--r--SmartDeviceLink/private/SDLLockScreenConstants.h18
-rw-r--r--SmartDeviceLink/private/SDLLockScreenManager.m37
-rw-r--r--SmartDeviceLink/private/SDLLockScreenStatusInfo.h (renamed from SmartDeviceLink/public/SDLOnLockScreenStatus.h)19
-rw-r--r--SmartDeviceLink/private/SDLLockScreenStatusInfo.m45
-rw-r--r--SmartDeviceLink/private/SDLLockScreenStatusManager.h14
-rw-r--r--SmartDeviceLink/private/SDLLockScreenStatusManager.m52
-rw-r--r--SmartDeviceLink/private/SDLMenuManager.m1
-rw-r--r--SmartDeviceLink/private/SDLPermissionFilter.h24
-rw-r--r--SmartDeviceLink/private/SDLPermissionFilter.m19
-rw-r--r--SmartDeviceLink/private/SDLPresentChoiceSetOperation.m8
-rw-r--r--SmartDeviceLink/private/SDLPresentKeyboardOperation.m8
-rw-r--r--SmartDeviceLink/private/SDLProtocol.m14
-rw-r--r--SmartDeviceLink/private/SDLRPCParameterNames.h3
-rw-r--r--SmartDeviceLink/private/SDLResponseDispatcher.m8
-rw-r--r--SmartDeviceLink/private/SDLStreamingAudioLifecycleManager.m10
-rw-r--r--SmartDeviceLink/private/SDLStreamingVideoLifecycleManager.m29
-rw-r--r--SmartDeviceLink/private/SDLSubscribeButtonManager.m6
-rw-r--r--SmartDeviceLink/private/SDLSystemCapabilityObserver.h14
-rw-r--r--SmartDeviceLink/private/SDLSystemCapabilityObserver.m10
-rw-r--r--SmartDeviceLink/public/SDLAddCommand.h17
-rw-r--r--SmartDeviceLink/public/SDLAddCommand.m16
-rw-r--r--SmartDeviceLink/public/SDLAddSubMenu.h34
-rw-r--r--SmartDeviceLink/public/SDLAddSubMenu.m31
-rw-r--r--SmartDeviceLink/public/SDLAlert.h104
-rw-r--r--SmartDeviceLink/public/SDLAlert.m38
-rw-r--r--SmartDeviceLink/public/SDLAmbientLightStatus.h2
-rw-r--r--SmartDeviceLink/public/SDLAppHMIType.h2
-rw-r--r--SmartDeviceLink/public/SDLAppInterfaceUnregisteredReason.h2
-rw-r--r--SmartDeviceLink/public/SDLAppServiceManifest.h63
-rw-r--r--SmartDeviceLink/public/SDLAppServiceManifest.m65
-rw-r--r--SmartDeviceLink/public/SDLAppServiceType.h2
-rw-r--r--SmartDeviceLink/public/SDLAudioControlCapabilities.h20
-rw-r--r--SmartDeviceLink/public/SDLAudioControlCapabilities.m27
-rwxr-xr-xSmartDeviceLink/public/SDLAudioStreamManager.m8
-rw-r--r--SmartDeviceLink/public/SDLAudioStreamingIndicator.h2
-rw-r--r--SmartDeviceLink/public/SDLAudioStreamingState.h2
-rw-r--r--SmartDeviceLink/public/SDLAudioType.h2
-rw-r--r--SmartDeviceLink/public/SDLBitsPerSample.h2
-rw-r--r--SmartDeviceLink/public/SDLButtonEventMode.h2
-rw-r--r--SmartDeviceLink/public/SDLButtonName.h2
-rw-r--r--SmartDeviceLink/public/SDLButtonPress.h21
-rw-r--r--SmartDeviceLink/public/SDLButtonPress.m25
-rw-r--r--SmartDeviceLink/public/SDLButtonPressMode.h2
-rw-r--r--SmartDeviceLink/public/SDLCapacityUnit.h2
-rw-r--r--SmartDeviceLink/public/SDLCarModeStatus.h2
-rw-r--r--SmartDeviceLink/public/SDLCharacterSet.h14
-rw-r--r--SmartDeviceLink/public/SDLCharacterSet.m16
-rw-r--r--SmartDeviceLink/public/SDLClimateControlCapabilities.h55
-rw-r--r--SmartDeviceLink/public/SDLClimateControlCapabilities.m12
-rw-r--r--SmartDeviceLink/public/SDLClimateControlData.h30
-rw-r--r--SmartDeviceLink/public/SDLClimateControlData.m27
-rw-r--r--SmartDeviceLink/public/SDLCompassDirection.h2
-rw-r--r--SmartDeviceLink/public/SDLComponentVolumeStatus.h2
-rw-r--r--SmartDeviceLink/public/SDLConfiguration.h91
-rw-r--r--SmartDeviceLink/public/SDLConfiguration.m39
-rw-r--r--SmartDeviceLink/public/SDLDefrostZone.h2
-rw-r--r--SmartDeviceLink/public/SDLDeliveryMode.h2
-rw-r--r--SmartDeviceLink/public/SDLDeviceLevelStatus.h2
-rw-r--r--SmartDeviceLink/public/SDLDimension.h2
-rw-r--r--SmartDeviceLink/public/SDLDirection.h2
-rw-r--r--SmartDeviceLink/public/SDLDisplayCapability.h3
-rw-r--r--SmartDeviceLink/public/SDLDisplayCapability.m6
-rw-r--r--SmartDeviceLink/public/SDLDisplayMode.h2
-rw-r--r--SmartDeviceLink/public/SDLDisplayType.h28
-rw-r--r--SmartDeviceLink/public/SDLDistanceUnit.h2
-rw-r--r--SmartDeviceLink/public/SDLDriverDistractionState.h2
-rw-r--r--SmartDeviceLink/public/SDLECallConfirmationStatus.h2
-rw-r--r--SmartDeviceLink/public/SDLElectronicParkBrakeStatus.h2
-rw-r--r--SmartDeviceLink/public/SDLElectronicParkBrakeStatus.m2
-rw-r--r--SmartDeviceLink/public/SDLEmergencyEventType.h2
-rw-r--r--SmartDeviceLink/public/SDLEnum.h3
-rw-r--r--SmartDeviceLink/public/SDLFileManager.h9
-rw-r--r--SmartDeviceLink/public/SDLFileManager.m4
-rw-r--r--SmartDeviceLink/public/SDLFileType.h2
-rw-r--r--SmartDeviceLink/public/SDLFuelCutoffStatus.h2
-rw-r--r--SmartDeviceLink/public/SDLFuelType.h2
-rw-r--r--SmartDeviceLink/public/SDLGetInteriorVehicleData.h18
-rwxr-xr-xSmartDeviceLink/public/SDLGetInteriorVehicleData.m35
-rw-r--r--SmartDeviceLink/public/SDLGetVehicleData.h68
-rw-r--r--SmartDeviceLink/public/SDLGetVehicleData.m26
-rw-r--r--SmartDeviceLink/public/SDLGlobalProperty.h2
-rw-r--r--SmartDeviceLink/public/SDLHMILevel.h2
-rw-r--r--SmartDeviceLink/public/SDLHMISettingsControlCapabilities.h21
-rw-r--r--SmartDeviceLink/public/SDLHMISettingsControlCapabilities.m23
-rw-r--r--SmartDeviceLink/public/SDLHMIZoneCapabilities.h2
-rw-r--r--SmartDeviceLink/public/SDLHybridAppPreference.h2
-rw-r--r--SmartDeviceLink/public/SDLIgnitionStableStatus.h2
-rw-r--r--SmartDeviceLink/public/SDLIgnitionStatus.h2
-rw-r--r--SmartDeviceLink/public/SDLImage.h17
-rw-r--r--SmartDeviceLink/public/SDLImage.m17
-rw-r--r--SmartDeviceLink/public/SDLImageFieldName.h2
-rw-r--r--SmartDeviceLink/public/SDLImageType.h2
-rw-r--r--SmartDeviceLink/public/SDLInteractionMode.h2
-rw-r--r--SmartDeviceLink/public/SDLKeyboardDelegate.h8
-rw-r--r--SmartDeviceLink/public/SDLKeyboardEvent.h2
-rw-r--r--SmartDeviceLink/public/SDLKeyboardLayout.h2
-rw-r--r--SmartDeviceLink/public/SDLKeyboardProperties.h12
-rw-r--r--SmartDeviceLink/public/SDLKeyboardProperties.m4
-rw-r--r--SmartDeviceLink/public/SDLKeypressMode.h2
-rw-r--r--SmartDeviceLink/public/SDLLanguage.h2
-rw-r--r--SmartDeviceLink/public/SDLLayoutMode.h2
-rw-r--r--SmartDeviceLink/public/SDLLifecycleConfiguration.h28
-rw-r--r--SmartDeviceLink/public/SDLLifecycleConfiguration.m48
-rw-r--r--SmartDeviceLink/public/SDLLightControlCapabilities.h10
-rw-r--r--SmartDeviceLink/public/SDLLightControlCapabilities.m12
-rw-r--r--SmartDeviceLink/public/SDLLightName.h2
-rw-r--r--SmartDeviceLink/public/SDLLightStatus.h2
-rw-r--r--SmartDeviceLink/public/SDLLockScreenConfiguration.h20
-rw-r--r--SmartDeviceLink/public/SDLLockScreenConfiguration.m29
-rw-r--r--SmartDeviceLink/public/SDLLockScreenStatus.h29
-rw-r--r--SmartDeviceLink/public/SDLLockScreenStatus.m10
-rw-r--r--SmartDeviceLink/public/SDLLogConfiguration.h2
-rw-r--r--SmartDeviceLink/public/SDLLogConfiguration.m9
-rw-r--r--SmartDeviceLink/public/SDLLogManager.m6
-rw-r--r--SmartDeviceLink/public/SDLLogTargetAppleSystemLog.h3
-rw-r--r--SmartDeviceLink/public/SDLLogTargetAppleSystemLog.m3
-rw-r--r--SmartDeviceLink/public/SDLLogTargetOSLog.m17
-rw-r--r--SmartDeviceLink/public/SDLMacros.h29
-rw-r--r--SmartDeviceLink/public/SDLMaintenanceModeStatus.h2
-rw-r--r--SmartDeviceLink/public/SDLManagerDelegate.h8
-rw-r--r--SmartDeviceLink/public/SDLMassageCushion.h2
-rw-r--r--SmartDeviceLink/public/SDLMassageMode.h2
-rw-r--r--SmartDeviceLink/public/SDLMassageZone.h2
-rw-r--r--SmartDeviceLink/public/SDLMediaClockFormat.h2
-rw-r--r--SmartDeviceLink/public/SDLMediaServiceData.h19
-rw-r--r--SmartDeviceLink/public/SDLMediaServiceData.m5
-rw-r--r--SmartDeviceLink/public/SDLMediaType.h2
-rw-r--r--SmartDeviceLink/public/SDLMenuCell.h19
-rw-r--r--SmartDeviceLink/public/SDLMenuCell.m8
-rw-r--r--SmartDeviceLink/public/SDLMenuLayout.h2
-rw-r--r--SmartDeviceLink/public/SDLMetadataType.h2
-rw-r--r--SmartDeviceLink/public/SDLModuleType.h2
-rw-r--r--SmartDeviceLink/public/SDLNavigationAction.h2
-rw-r--r--SmartDeviceLink/public/SDLNavigationJunction.h2
-rw-r--r--SmartDeviceLink/public/SDLNotificationConstants.h12
-rw-r--r--SmartDeviceLink/public/SDLNotificationConstants.m1
-rw-r--r--SmartDeviceLink/public/SDLOnLockScreenStatus.m68
-rw-r--r--SmartDeviceLink/public/SDLPRNDL.h2
-rw-r--r--SmartDeviceLink/public/SDLPerformInteraction.h97
-rw-r--r--SmartDeviceLink/public/SDLPerformInteraction.m58
-rw-r--r--SmartDeviceLink/public/SDLPermissionConstants.h9
-rw-r--r--SmartDeviceLink/public/SDLPermissionManager.h52
-rw-r--r--SmartDeviceLink/public/SDLPermissionManager.m91
-rw-r--r--SmartDeviceLink/public/SDLPermissionStatus.h2
-rw-r--r--SmartDeviceLink/public/SDLPowerModeQualificationStatus.h2
-rw-r--r--SmartDeviceLink/public/SDLPowerModeStatus.h2
-rw-r--r--SmartDeviceLink/public/SDLPredefinedLayout.h2
-rw-r--r--SmartDeviceLink/public/SDLPrerecordedSpeech.h2
-rw-r--r--SmartDeviceLink/public/SDLPrimaryAudioSource.h2
-rw-r--r--SmartDeviceLink/public/SDLPutFile.h20
-rw-r--r--SmartDeviceLink/public/SDLPutFile.m26
-rw-r--r--SmartDeviceLink/public/SDLRPCFunctionNames.h2
-rw-r--r--SmartDeviceLink/public/SDLRPCMessage.h15
-rw-r--r--SmartDeviceLink/public/SDLRPCMessage.m8
-rw-r--r--SmartDeviceLink/public/SDLRPCMessageType.h2
-rw-r--r--SmartDeviceLink/public/SDLRadioBand.h2
-rw-r--r--SmartDeviceLink/public/SDLRadioControlCapabilities.h57
-rw-r--r--SmartDeviceLink/public/SDLRadioControlCapabilities.m50
-rw-r--r--SmartDeviceLink/public/SDLRadioControlData.h12
-rw-r--r--SmartDeviceLink/public/SDLRadioControlData.m15
-rw-r--r--SmartDeviceLink/public/SDLRadioState.h2
-rw-r--r--SmartDeviceLink/public/SDLRegisterAppInterface.h40
-rw-r--r--SmartDeviceLink/public/SDLRegisterAppInterface.m43
-rw-r--r--SmartDeviceLink/public/SDLRegisterAppInterfaceResponse.h10
-rw-r--r--SmartDeviceLink/public/SDLRegisterAppInterfaceResponse.m21
-rw-r--r--SmartDeviceLink/public/SDLRemoteControlCapabilities.h8
-rw-r--r--SmartDeviceLink/public/SDLRemoteControlCapabilities.m5
-rw-r--r--SmartDeviceLink/public/SDLRequestType.h2
-rw-r--r--SmartDeviceLink/public/SDLResult.h2
-rw-r--r--SmartDeviceLink/public/SDLSamplingRate.h2
-rw-r--r--SmartDeviceLink/public/SDLScrollableMessage.h10
-rw-r--r--SmartDeviceLink/public/SDLScrollableMessage.m4
-rw-r--r--SmartDeviceLink/public/SDLSeatControlCapabilities.h28
-rw-r--r--SmartDeviceLink/public/SDLSeatControlCapabilities.m34
-rw-r--r--SmartDeviceLink/public/SDLSeatControlData.h32
-rw-r--r--SmartDeviceLink/public/SDLSeatControlData.m40
-rw-r--r--SmartDeviceLink/public/SDLSeatMemoryActionType.h2
-rw-r--r--SmartDeviceLink/public/SDLServiceUpdateReason.h37
-rw-r--r--SmartDeviceLink/public/SDLServiceUpdateReason.m6
-rw-r--r--SmartDeviceLink/public/SDLSetGlobalProperties.h50
-rw-r--r--SmartDeviceLink/public/SDLSetGlobalProperties.m19
-rw-r--r--SmartDeviceLink/public/SDLSetMediaClockTimer.h25
-rw-r--r--SmartDeviceLink/public/SDLSetMediaClockTimer.m33
-rw-r--r--SmartDeviceLink/public/SDLSoftButtonType.h2
-rw-r--r--SmartDeviceLink/public/SDLSpeechCapabilities.h2
-rw-r--r--SmartDeviceLink/public/SDLStaticIconName.h2
-rw-r--r--SmartDeviceLink/public/SDLStreamingMediaConfiguration.h41
-rw-r--r--SmartDeviceLink/public/SDLStreamingMediaConfiguration.m54
-rw-r--r--SmartDeviceLink/public/SDLStreamingMediaManager.h18
-rw-r--r--SmartDeviceLink/public/SDLStreamingMediaManager.m19
-rw-r--r--SmartDeviceLink/public/SDLSubscribeVehicleData.h66
-rw-r--r--SmartDeviceLink/public/SDLSubscribeVehicleData.m26
-rw-r--r--SmartDeviceLink/public/SDLSupportedSeat.h17
-rw-r--r--SmartDeviceLink/public/SDLSupportedSeat.m3
-rw-r--r--SmartDeviceLink/public/SDLSyncMsgVersion.h47
-rw-r--r--SmartDeviceLink/public/SDLSyncMsgVersion.m61
-rw-r--r--SmartDeviceLink/public/SDLSystemAction.h2
-rw-r--r--SmartDeviceLink/public/SDLSystemCapabilityManager.h13
-rw-r--r--SmartDeviceLink/public/SDLSystemCapabilityManager.m24
-rwxr-xr-xSmartDeviceLink/public/SDLSystemCapabilityType.h2
-rw-r--r--SmartDeviceLink/public/SDLSystemContext.h2
-rw-r--r--SmartDeviceLink/public/SDLTBTState.h2
-rw-r--r--SmartDeviceLink/public/SDLTPMS.h2
-rw-r--r--SmartDeviceLink/public/SDLTemperatureUnit.h2
-rw-r--r--SmartDeviceLink/public/SDLTextAlignment.h2
-rw-r--r--SmartDeviceLink/public/SDLTextFieldName.h2
-rw-r--r--SmartDeviceLink/public/SDLTimerMode.h2
-rw-r--r--SmartDeviceLink/public/SDLTouchManager.h17
-rw-r--r--SmartDeviceLink/public/SDLTouchManager.m13
-rw-r--r--SmartDeviceLink/public/SDLTouchType.h2
-rw-r--r--SmartDeviceLink/public/SDLTransmissionType.h2
-rw-r--r--SmartDeviceLink/public/SDLTriggerSource.h2
-rw-r--r--SmartDeviceLink/public/SDLTurnSignal.h2
-rw-r--r--SmartDeviceLink/public/SDLUnsubscribeVehicleData.h66
-rw-r--r--SmartDeviceLink/public/SDLUnsubscribeVehicleData.m26
-rw-r--r--SmartDeviceLink/public/SDLUpdateMode.h2
-rw-r--r--SmartDeviceLink/public/SDLVehicleDataActiveStatus.h2
-rw-r--r--SmartDeviceLink/public/SDLVehicleDataEventStatus.h2
-rw-r--r--SmartDeviceLink/public/SDLVehicleDataNotificationStatus.h2
-rw-r--r--SmartDeviceLink/public/SDLVehicleDataResultCode.h2
-rw-r--r--SmartDeviceLink/public/SDLVehicleDataStatus.h2
-rw-r--r--SmartDeviceLink/public/SDLVehicleDataType.h2
-rw-r--r--SmartDeviceLink/public/SDLVentilationMode.h2
-rw-r--r--SmartDeviceLink/public/SDLVersion.h16
-rw-r--r--SmartDeviceLink/public/SDLVersion.m16
-rw-r--r--SmartDeviceLink/public/SDLVideoStreamingCapability.h11
-rw-r--r--SmartDeviceLink/public/SDLVideoStreamingCapability.m18
-rw-r--r--SmartDeviceLink/public/SDLVideoStreamingCodec.h2
-rw-r--r--SmartDeviceLink/public/SDLVideoStreamingProtocol.h2
-rw-r--r--SmartDeviceLink/public/SDLVideoStreamingState.h2
-rw-r--r--SmartDeviceLink/public/SDLVrCapabilities.h2
-rw-r--r--SmartDeviceLink/public/SDLWarningLightStatus.h2
-rw-r--r--SmartDeviceLink/public/SDLWayPointType.h2
-rw-r--r--SmartDeviceLink/public/SDLWindowType.h2
-rw-r--r--SmartDeviceLink/public/SDLWiperStatus.h2
-rw-r--r--SmartDeviceLinkTests/DevAPISpecs/SDLConfigurationSpec.m78
-rw-r--r--SmartDeviceLinkTests/DevAPISpecs/SDLLifecycleConfigurationSpec.m75
-rw-r--r--SmartDeviceLinkTests/DevAPISpecs/SDLLifecycleManagerSpec.m225
-rw-r--r--SmartDeviceLinkTests/DevAPISpecs/SDLLifecycleSystemRequestHandlerSpec.m2
-rw-r--r--SmartDeviceLinkTests/DevAPISpecs/SDLLockScreenConfigurationSpec.m20
-rw-r--r--SmartDeviceLinkTests/DevAPISpecs/SDLLockScreenManagerSpec.m316
-rw-r--r--SmartDeviceLinkTests/DevAPISpecs/SDLMenuCellSpec.m26
-rw-r--r--SmartDeviceLinkTests/DevAPISpecs/SDLPermissionFilterSpec.m122
-rw-r--r--SmartDeviceLinkTests/DevAPISpecs/SDLPermissionsManagerSpec.m1070
-rw-r--r--SmartDeviceLinkTests/DevAPISpecs/SDLPreloadChoicesOperationSpec.m23
-rw-r--r--SmartDeviceLinkTests/DevAPISpecs/SDLStreamingAudioLifecycleManagerSpec.m1
-rw-r--r--SmartDeviceLinkTests/DevAPISpecs/SDLStreamingMediaConfigurationSpec.m127
-rw-r--r--SmartDeviceLinkTests/DevAPISpecs/SDLStreamingVideoLifecycleManagerSpec.m1
-rw-r--r--SmartDeviceLinkTests/DevAPISpecs/SDLVersionSpec.m17
-rw-r--r--SmartDeviceLinkTests/LoggingSpecs/SDLLogConfigurationSpec.m14
-rw-r--r--SmartDeviceLinkTests/ProtocolSpecs/MessageSpecs/SDLProtocolSpec.m124
-rw-r--r--SmartDeviceLinkTests/ProxySpecs/SDLHapticManagerSpec.m78
-rw-r--r--SmartDeviceLinkTests/ProxySpecs/SDLLockScreenStatusManagerSpec.m118
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/EnumSpecs/SDLDisplayTypeSpec.m3
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/EnumSpecs/SDLLockScreenStatusSpec.m26
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/EnumSpecs/SDLServiceUpdateReasonSpec.m9
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/EnumSpecs/SDLSupportedSeatSpec.m3
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/NotificationSpecs/SDLOnLockScreenStatusSpec.m80
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLAddCommandSpec.m36
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLAddSubMenuSpec.m70
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLAlertSpec.m196
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLButtonPressSpec.m41
-rwxr-xr-xSmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLGetInteriorVehicleDataSpec.m49
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLGetVehicleDataSpec.m98
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLPerformInteractionSpec.m174
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLPutFileSpec.m79
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLRegisterAppInterfaceSpec.m145
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLScrollableMessageSpec.m29
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLSetGlobalPropertiesSpec.m112
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLSetMediaClockTimerSpec.m22
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLSubscribeVehicleDataSpec.m98
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLUnsubscribeVehicleDataSpec.m98
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/ResponseSpecs/SDLRegisterAppInterfaceResponseSpec.m81
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLAppServiceCapabilitySpec.m9
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLAppServiceManifestSpec.m153
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLAppServicesCapabilitiesSpec.m11
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLAudioControlCapabilitiesSpec.m73
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLClimateControlCapabilitiesSpec.m135
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLClimateControlDataSpec.m32
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLDisplayCapabilitySpec.m52
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLHMISettingsControlCapabilitiesSpec.m46
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLImageSpec.m27
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLKeyboardPropertiesSpec.m18
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLLightControlCapabilitiesSpec.m21
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLMediaServiceDataSpec.m26
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLRadioControlCapabilitiesSpec.m68
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLRadioControlDataSpec.m66
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLRemoteControlCapabilitiesSpec.m12
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLSeatControlCapabilitiesSpec.m54
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLSeatControlDataSpec.m96
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLSyncMsgVersionSpec.m59
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLVideoStreamingCapabilitySpec.m15
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/SuperclassSpecs/SDLRPCMessageSpec.m172
-rw-r--r--SmartDeviceLinkTests/SDLOnLockScreenStatusSpec.m53
-rw-r--r--SmartDeviceLinkTests/SDLSystemCapabilityManagerSpec.m35
-rw-r--r--SmartDeviceLinkTests/TestHapticRectViewController.h18
-rw-r--r--SmartDeviceLinkTests/TestHapticRectViewController.m38
-rw-r--r--SmartDeviceLinkTests/UtilitiesSpecs/Touches/SDLTouchManagerSpec.m13
-rw-r--r--generator/templates/base_struct_function.m.jinja22
-rw-r--r--generator/templates/functions/template.m.jinja22
-rw-r--r--generator/templates/structs/template.m.jinja21
-rw-r--r--generator/transformers/common_producer.py27
316 files changed, 2030 insertions, 6949 deletions
diff --git a/Example Apps/Example ObjC/RPCPermissionsManager.m b/Example Apps/Example ObjC/RPCPermissionsManager.m
index 93d2755e6..3370f18c2 100644
--- a/Example Apps/Example ObjC/RPCPermissionsManager.m
+++ b/Example Apps/Example ObjC/RPCPermissionsManager.m
@@ -96,7 +96,7 @@ NS_ASSUME_NONNULL_BEGIN
* @return A unique identifier for the subscription. This can be used to later to unsubscribe from the notifications.
*/
+ (SDLPermissionObserverIdentifier)sdlex_subscribeGroupPermissionsWithManager:(SDLManager *)manager permissionElements:(NSArray<SDLPermissionElement *> *)permissionElements groupType:(SDLPermissionGroupType)groupType {
- SDLPermissionObserverIdentifier observerId = [manager.permissionManager subscribeToRPCPermissions:permissionElements groupType:groupType withHandler:^(NSDictionary<SDLPermissionRPCName,SDLRPCPermissionStatus *> * _Nonnull change, SDLPermissionGroupStatus status) {
+ SDLPermissionObserverIdentifier observerId = [manager.permissionManager subscribeToRPCPermissions:permissionElements groupType:groupType withHandler:^(NSDictionary<SDLRPCFunctionName, SDLRPCPermissionStatus *> * _Nonnull change, SDLPermissionGroupStatus status) {
[self sdlex_logRPCGroupPermissions:permissionElements groupPermissionStatus:status individualPermissionStatuses:change];
}];
return observerId;
diff --git a/Example Apps/Example ObjC/VehicleDataManager.m b/Example Apps/Example ObjC/VehicleDataManager.m
index 3f6c57e15..f6192777a 100644
--- a/Example Apps/Example ObjC/VehicleDataManager.m
+++ b/Example Apps/Example ObjC/VehicleDataManager.m
@@ -145,12 +145,6 @@ NS_ASSUME_NONNULL_BEGIN
SDLLogD(@"App has permission to access vehicle data. Requesting vehicle data...");
SDLGetVehicleData *getAllVehicleData = [[SDLGetVehicleData alloc] initWithGps:@YES speed:@YES rpm:@YES instantFuelConsumption:@YES fuelRange:@YES externalTemperature:@YES turnSignal:@YES vin:@YES gearStatus:@YES tirePressure:@YES odometer:@YES beltStatus:@YES bodyInformation:@YES deviceStatus:@YES driverBraking:@YES wiperStatus:@YES headLampStatus:@YES engineTorque:@YES accPedalPosition:@YES steeringWheelAngle:@YES engineOilLife:@YES electronicParkBrakeStatus:@YES cloudAppVehicleID:@YES stabilityControlsStatus:@YES eCallInfo:@YES airbagStatus:@YES emergencyEvent:@YES clusterModeStatus:@YES myKey:@YES handsOffSteering:@YES windowStatus:@YES];
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- getAllVehicleData.fuelLevel = @YES;
- getAllVehicleData.fuelLevel_State = @YES;
- getAllVehicleData.prndl = @YES;
-#pragma clang diagnostic pop
[manager sendRequest:getAllVehicleData withResponseHandler:^(__kindof SDLRPCRequest * _Nullable request, __kindof SDLRPCResponse * _Nullable response, NSError * _Nullable error) {
if (error || ![response isKindOfClass:SDLGetVehicleDataResponse.class]) {
@@ -222,15 +216,9 @@ NS_ASSUME_NONNULL_BEGIN
} else if ([vehicleDataType isEqualToString:ACExternalTemperatureMenuName]) {
vehicleDataDescription = vehicleData.externalTemperature.description;
} else if ([vehicleDataType isEqualToString:ACFuelLevelMenuName]) {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- vehicleDataDescription = vehicleData.fuelLevel.description;
-#pragma clang diagnostic pop
+ vehicleDataDescription = vehicleData.fuelRange.firstObject.level.description;
} else if ([vehicleDataType isEqualToString:ACFuelLevelStateMenuName]) {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- vehicleDataDescription = vehicleData.fuelLevel_State.description;
-#pragma clang diagnostic pop
+ vehicleDataDescription = vehicleData.fuelRange.firstObject.levelState.description;
} else if ([vehicleDataType isEqualToString:ACFuelRangeMenuName]) {
vehicleDataDescription = vehicleData.fuelRange.description;
} else if ([vehicleDataType isEqualToString:ACGearStatusMenuName]) {
@@ -246,10 +234,7 @@ NS_ASSUME_NONNULL_BEGIN
} else if ([vehicleDataType isEqualToString:ACOdometerMenuName]) {
vehicleDataDescription = vehicleData.odometer.description;
} else if ([vehicleDataType isEqualToString:ACPRNDLMenuName]) {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- vehicleDataDescription = vehicleData.prndl.description;
-#pragma clang diagnostic pop
+ vehicleDataDescription = vehicleData.gearStatus.actualGear.description;
} else if ([vehicleDataType isEqualToString:ACSpeedMenuName]) {
vehicleDataDescription = vehicleData.speed.description;
} else if ([vehicleDataType isEqualToString:ACSteeringWheelAngleMenuName]) {
diff --git a/Example Apps/Example Swift/AudioManager.swift b/Example Apps/Example Swift/AudioManager.swift
index cfbc4538f..8300bcb18 100644
--- a/Example Apps/Example Swift/AudioManager.swift
+++ b/Example Apps/Example Swift/AudioManager.swift
@@ -19,7 +19,6 @@ fileprivate enum SpeechRecognitionAuthState {
case authorized, notAuthorized, badRegion
}
-@available(iOS 10.0, *)
class AudioManager: NSObject {
fileprivate let sdlManager: SDLManager
fileprivate var audioData: Data?
@@ -88,7 +87,6 @@ class AudioManager: NSObject {
// MARK: - Audio Pass Thru Notifications
-@available(iOS 10.0, *)
private extension AudioManager {
/// SDL streams the audio data as it is collected.
var audioDataReceivedHandler: SDLAudioPassThruHandler? {
@@ -144,7 +142,6 @@ private extension AudioManager {
// MARK: - Speech Recognition
-@available(iOS 10.0, *)
private extension AudioManager {
/// Configures speech recognition
func startSpeechRecognitionTask() {
@@ -186,7 +183,6 @@ private extension AudioManager {
// MARK: - Speech Recognition Authorization
-@available(iOS 10.0, *)
extension AudioManager: SFSpeechRecognizerDelegate {
func speechRecognizer(_ speechRecognizer: SFSpeechRecognizer, availabilityDidChange available: Bool) {
speechRecognitionAuthState = AudioManager.checkAuthorization(speechRecognizer: speechRecognizer)
diff --git a/Example Apps/Example Swift/MenuManager.swift b/Example Apps/Example Swift/MenuManager.swift
index 3981bc7fa..1b0830f48 100644
--- a/Example Apps/Example Swift/MenuManager.swift
+++ b/Example Apps/Example Swift/MenuManager.swift
@@ -90,15 +90,9 @@ private extension MenuManager {
/// - Parameter manager: The SDL Manager
/// - Returns: A SDLMenuCell object
class func menuCellRecordInCarMicrophoneAudio(with manager: SDLManager) -> SDLMenuCell {
- if #available(iOS 10.0, *) {
- let audioManager = AudioManager(sdlManager: manager)
- return SDLMenuCell(title: ACRecordInCarMicrophoneAudioMenuName, icon: SDLArtwork(image: UIImage(named: MicrophoneBWIconImageName)!.withRenderingMode(.alwaysTemplate), persistent: true, as: .PNG), voiceCommands: [ACRecordInCarMicrophoneAudioMenuName], handler: { _ in
- audioManager.startRecording()
- })
- }
-
- return SDLMenuCell(title: ACRecordInCarMicrophoneAudioMenuName, icon: SDLArtwork(image: UIImage(named: SpeakBWIconImageName)!.withRenderingMode(.alwaysTemplate), persistent: true, as: .PNG), voiceCommands: [ACRecordInCarMicrophoneAudioMenuName], handler: { _ in
- AlertManager.sendAlert(textField1: "Speech recognition feature only available on iOS 10+", sdlManager: manager)
+ let audioManager = AudioManager(sdlManager: manager)
+ return SDLMenuCell(title: ACRecordInCarMicrophoneAudioMenuName, icon: SDLArtwork(image: UIImage(named: MicrophoneBWIconImageName)!.withRenderingMode(.alwaysTemplate), persistent: true, as: .PNG), voiceCommands: [ACRecordInCarMicrophoneAudioMenuName], handler: { _ in
+ audioManager.startRecording()
})
}
diff --git a/Example Apps/Example Swift/VehicleDataManager.swift b/Example Apps/Example Swift/VehicleDataManager.swift
index 3c83f2ff9..87176a883 100644
--- a/Example Apps/Example Swift/VehicleDataManager.swift
+++ b/Example Apps/Example Swift/VehicleDataManager.swift
@@ -111,7 +111,7 @@ extension VehicleDataManager {
guard hasPermissionToAccessVehicleData(with: manager) else { return }
SDLLog.d("App has permission to access vehicle data. Requesting all vehicle data...")
- let getAllVehicleData = SDLGetVehicleData(accelerationPedalPosition: true, airbagStatus: true, beltStatus: true, bodyInformation: true, cloudAppVehicleID: true, clusterModeStatus: true, deviceStatus: true, driverBraking: true, eCallInfo: true, electronicParkBrakeStatus: true, emergencyEvent: true, engineOilLife: true, engineTorque: true, externalTemperature: true, fuelLevel: true, fuelLevelState: true, fuelRange: true, gps: true, headLampStatus: true, instantFuelConsumption: true, myKey: true, odometer: true, prndl: true, rpm: true, speed: true, steeringWheelAngle: true, tirePressure: true, turnSignal: true, vin: true, wiperStatus: true)
+ let getAllVehicleData = SDLGetVehicleData(gps: NSNumber(true), speed: NSNumber(true), rpm: NSNumber(true), instantFuelConsumption: NSNumber(true), fuelRange: NSNumber(true), externalTemperature: NSNumber(true), turnSignal: NSNumber(true), vin: NSNumber(true), gearStatus: NSNumber(true), tirePressure: NSNumber(true), odometer: NSNumber(true), beltStatus: NSNumber(true), bodyInformation: NSNumber(true), deviceStatus: NSNumber(true), driverBraking: NSNumber(true), wiperStatus: NSNumber(true), headLampStatus: NSNumber(true), engineTorque: NSNumber(true), accPedalPosition: NSNumber(true), steeringWheelAngle: NSNumber(true), engineOilLife: NSNumber(true), electronicParkBrakeStatus: NSNumber(true), cloudAppVehicleID: NSNumber(true), stabilityControlsStatus: NSNumber(true), eCallInfo: NSNumber(true), airbagStatus: NSNumber(true), emergencyEvent: NSNumber(true), clusterModeStatus: NSNumber(true), myKey: NSNumber(true), handsOffSteering: NSNumber(true), windowStatus: NSNumber(true))
manager.send(request: getAllVehicleData) { (request, response, error) in
guard didAccessVehicleDataSuccessfully(with: manager, response: response, error: error) else { return }
@@ -190,9 +190,9 @@ extension VehicleDataManager {
case ACExternalTemperatureMenuName:
vehicleDataDescription = vehicleData.externalTemperature?.description ?? notAvailable
case ACFuelLevelMenuName:
- vehicleDataDescription = vehicleData.fuelLevel?.description ?? notAvailable
+ vehicleDataDescription = vehicleData.fuelRange?.first?.level?.description ?? notAvailable
case ACFuelLevelStateMenuName:
- vehicleDataDescription = vehicleData.fuelLevel_State?.rawValue.rawValue ?? notAvailable
+ vehicleDataDescription = vehicleData.fuelRange?.first?.levelState?.rawValue.rawValue ?? notAvailable
case ACFuelRangeMenuName:
vehicleDataDescription = vehicleData.fuelRange?.description ?? notAvailable
case ACGPSMenuName:
@@ -206,7 +206,7 @@ extension VehicleDataManager {
case ACOdometerMenuName:
vehicleDataDescription = vehicleData.odometer?.description ?? notAvailable
case ACPRNDLMenuName:
- vehicleDataDescription = vehicleData.prndl?.rawValue.rawValue ?? notAvailable
+ vehicleDataDescription = vehicleData.gearStatus?.actualGear?.rawValue.rawValue ?? notAvailable
case ACSpeedMenuName:
vehicleDataDescription = vehicleData.speed?.description ?? notAvailable
case ACSteeringWheelAngleMenuName:
diff --git a/SmartDeviceLink-iOS.xcodeproj/project.pbxproj b/SmartDeviceLink-iOS.xcodeproj/project.pbxproj
index 2f37469b9..fdd22271d 100644
--- a/SmartDeviceLink-iOS.xcodeproj/project.pbxproj
+++ b/SmartDeviceLink-iOS.xcodeproj/project.pbxproj
@@ -52,7 +52,6 @@
162E82E91A9BDE8B00906325 /* SDLKeypressModeSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 162E82011A9BDE8A00906325 /* SDLKeypressModeSpec.m */; };
162E82EA1A9BDE8B00906325 /* SDLLanguageSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 162E82021A9BDE8A00906325 /* SDLLanguageSpec.m */; };
162E82EB1A9BDE8B00906325 /* SDLLayoutModeSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 162E82031A9BDE8A00906325 /* SDLLayoutModeSpec.m */; };
- 162E82EC1A9BDE8B00906325 /* SDLLockScreenStatusSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 162E82041A9BDE8A00906325 /* SDLLockScreenStatusSpec.m */; };
162E82ED1A9BDE8B00906325 /* SDLMaintenanceModeStatusSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 162E82051A9BDE8A00906325 /* SDLMaintenanceModeStatusSpec.m */; };
162E82EE1A9BDE8B00906325 /* SDLMediaClockFormatSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 162E82061A9BDE8A00906325 /* SDLMediaClockFormatSpec.m */; };
162E82EF1A9BDE8B00906325 /* SDLPermissionStatusSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 162E82071A9BDE8A00906325 /* SDLPermissionStatusSpec.m */; };
@@ -96,7 +95,6 @@
162E83171A9BDE8B00906325 /* SDLOnHMIStatusSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 162E82311A9BDE8A00906325 /* SDLOnHMIStatusSpec.m */; };
162E83181A9BDE8B00906325 /* SDLOnKeyboardInputSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 162E82321A9BDE8A00906325 /* SDLOnKeyboardInputSpec.m */; };
162E83191A9BDE8B00906325 /* SDLOnLanguageChangeSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 162E82331A9BDE8A00906325 /* SDLOnLanguageChangeSpec.m */; };
- 162E831A1A9BDE8B00906325 /* SDLOnLockScreenStatusSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 162E82341A9BDE8A00906325 /* SDLOnLockScreenStatusSpec.m */; };
162E831B1A9BDE8B00906325 /* SDLOnPermissionsChangeSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 162E82351A9BDE8A00906325 /* SDLOnPermissionsChangeSpec.m */; };
162E831C1A9BDE8B00906325 /* SDLOnSyncPDataSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 162E82361A9BDE8A00906325 /* SDLOnSyncPDataSpec.m */; };
162E831D1A9BDE8B00906325 /* SDLOnSystemRequestSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 162E82371A9BDE8A00906325 /* SDLOnSystemRequestSpec.m */; };
@@ -210,7 +208,6 @@
162E838B1A9BDE8B00906325 /* SDLSoftButtonCapabilitiesSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 162E82A91A9BDE8A00906325 /* SDLSoftButtonCapabilitiesSpec.m */; };
162E838C1A9BDE8B00906325 /* SDLSoftButtonSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 162E82AA1A9BDE8A00906325 /* SDLSoftButtonSpec.m */; };
162E838D1A9BDE8B00906325 /* SDLStartTimeSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 162E82AB1A9BDE8A00906325 /* SDLStartTimeSpec.m */; };
- 162E838E1A9BDE8B00906325 /* SDLSyncMsgVersionSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 162E82AC1A9BDE8A00906325 /* SDLSyncMsgVersionSpec.m */; };
162E838F1A9BDE8B00906325 /* SDLTextFieldSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 162E82AD1A9BDE8A00906325 /* SDLTextFieldSpec.m */; };
162E83901A9BDE8B00906325 /* SDLTireStatusSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 162E82AE1A9BDE8A00906325 /* SDLTireStatusSpec.m */; };
162E83911A9BDE8B00906325 /* SDLTouchCoordSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 162E82AF1A9BDE8A00906325 /* SDLTouchCoordSpec.m */; };
@@ -375,9 +372,7 @@
4A8BD2B524F935BC000945E3 /* SDLStationIDNumber.m in Sources */ = {isa = PBXBuildFile; fileRef = 4A8BD2A724F935BB000945E3 /* SDLStationIDNumber.m */; };
4A8BD2B624F935BC000945E3 /* SDLSystemCapability.h in Headers */ = {isa = PBXBuildFile; fileRef = 4A8BD2A824F935BB000945E3 /* SDLSystemCapability.h */; settings = {ATTRIBUTES = (Public, ); }; };
4A8BD2B724F935BC000945E3 /* SDLSoftButton.m in Sources */ = {isa = PBXBuildFile; fileRef = 4A8BD2A924F935BB000945E3 /* SDLSoftButton.m */; };
- 4A8BD2B824F935BC000945E3 /* SDLSyncMsgVersion.m in Sources */ = {isa = PBXBuildFile; fileRef = 4A8BD2AA24F935BC000945E3 /* SDLSyncMsgVersion.m */; };
4A8BD2B924F935BC000945E3 /* SDLSoftButton.h in Headers */ = {isa = PBXBuildFile; fileRef = 4A8BD2AB24F935BC000945E3 /* SDLSoftButton.h */; settings = {ATTRIBUTES = (Public, ); }; };
- 4A8BD2BA24F935BC000945E3 /* SDLSyncMsgVersion.h in Headers */ = {isa = PBXBuildFile; fileRef = 4A8BD2AC24F935BC000945E3 /* SDLSyncMsgVersion.h */; settings = {ATTRIBUTES = (Public, ); }; };
4A8BD2BB24F935BC000945E3 /* SDLStationIDNumber.h in Headers */ = {isa = PBXBuildFile; fileRef = 4A8BD2AD24F935BC000945E3 /* SDLStationIDNumber.h */; settings = {ATTRIBUTES = (Public, ); }; };
4A8BD2BC24F935BC000945E3 /* SDLSISData.m in Sources */ = {isa = PBXBuildFile; fileRef = 4A8BD2AE24F935BC000945E3 /* SDLSISData.m */; };
4A8BD2BD24F935BC000945E3 /* SDLStartTime.m in Sources */ = {isa = PBXBuildFile; fileRef = 4A8BD2AF24F935BC000945E3 /* SDLStartTime.m */; };
@@ -750,7 +745,6 @@
4ABB269324F7F9060061BF55 /* SDLTimer.h in Headers */ = {isa = PBXBuildFile; fileRef = 4ABB269124F7F9060061BF55 /* SDLTimer.h */; };
4ABB269624F7F9400061BF55 /* SDLRPCFunctionNames.h in Headers */ = {isa = PBXBuildFile; fileRef = 4ABB269424F7F93F0061BF55 /* SDLRPCFunctionNames.h */; settings = {ATTRIBUTES = (Public, ); }; };
4ABB269724F7F9400061BF55 /* SDLRPCFunctionNames.m in Sources */ = {isa = PBXBuildFile; fileRef = 4ABB269524F7F93F0061BF55 /* SDLRPCFunctionNames.m */; };
- 4ABB269924F7F9560061BF55 /* SDLMacros.h in Headers */ = {isa = PBXBuildFile; fileRef = 4ABB269824F7F9560061BF55 /* SDLMacros.h */; settings = {ATTRIBUTES = (Public, ); }; };
4ABB269C24F7F9710061BF55 /* SDLRPCParameterNames.h in Headers */ = {isa = PBXBuildFile; fileRef = 4ABB269A24F7F9710061BF55 /* SDLRPCParameterNames.h */; };
4ABB269D24F7F9710061BF55 /* SDLRPCParameterNames.m in Sources */ = {isa = PBXBuildFile; fileRef = 4ABB269B24F7F9710061BF55 /* SDLRPCParameterNames.m */; };
4ABB26A024F7F98C0061BF55 /* SDLLogFileModuleMap.h in Headers */ = {isa = PBXBuildFile; fileRef = 4ABB269E24F7F98C0061BF55 /* SDLLogFileModuleMap.h */; };
@@ -883,8 +877,6 @@
4ABB27AA24F7FFDA0061BF55 /* SDLMassageZone.h in Headers */ = {isa = PBXBuildFile; fileRef = 4ABB279E24F7FFD80061BF55 /* SDLMassageZone.h */; settings = {ATTRIBUTES = (Public, ); }; };
4ABB27AB24F7FFDA0061BF55 /* SDLMassageZone.m in Sources */ = {isa = PBXBuildFile; fileRef = 4ABB279F24F7FFD80061BF55 /* SDLMassageZone.m */; };
4ABB27AC24F7FFDA0061BF55 /* SDLMediaClockFormat.h in Headers */ = {isa = PBXBuildFile; fileRef = 4ABB27A024F7FFD80061BF55 /* SDLMediaClockFormat.h */; settings = {ATTRIBUTES = (Public, ); }; };
- 4ABB27AD24F7FFDA0061BF55 /* SDLLockScreenStatus.h in Headers */ = {isa = PBXBuildFile; fileRef = 4ABB27A124F7FFD90061BF55 /* SDLLockScreenStatus.h */; settings = {ATTRIBUTES = (Public, ); }; };
- 4ABB27AE24F7FFDA0061BF55 /* SDLLockScreenStatus.m in Sources */ = {isa = PBXBuildFile; fileRef = 4ABB27A224F7FFD90061BF55 /* SDLLockScreenStatus.m */; };
4ABB27AF24F7FFDA0061BF55 /* SDLMaintenanceModeStatus.m in Sources */ = {isa = PBXBuildFile; fileRef = 4ABB27A324F7FFD90061BF55 /* SDLMaintenanceModeStatus.m */; };
4ABB27B024F7FFDA0061BF55 /* SDLMassageCushion.h in Headers */ = {isa = PBXBuildFile; fileRef = 4ABB27A424F7FFD90061BF55 /* SDLMassageCushion.h */; settings = {ATTRIBUTES = (Public, ); }; };
4ABB27B124F7FFDA0061BF55 /* SDLMassageCushion.m in Sources */ = {isa = PBXBuildFile; fileRef = 4ABB27A524F7FFD90061BF55 /* SDLMassageCushion.m */; };
@@ -1000,7 +992,6 @@
4ABB28BE24F82A6A0061BF55 /* SDLOnSyncPData.m in Sources */ = {isa = PBXBuildFile; fileRef = 4ABB288E24F82A640061BF55 /* SDLOnSyncPData.m */; };
4ABB28BF24F82A6A0061BF55 /* SDLOnTBTClientState.m in Sources */ = {isa = PBXBuildFile; fileRef = 4ABB288F24F82A640061BF55 /* SDLOnTBTClientState.m */; };
4ABB28C024F82A6A0061BF55 /* SDLOnCommand.h in Headers */ = {isa = PBXBuildFile; fileRef = 4ABB289024F82A640061BF55 /* SDLOnCommand.h */; settings = {ATTRIBUTES = (Public, ); }; };
- 4ABB28C124F82A6A0061BF55 /* SDLOnLockScreenStatus.m in Sources */ = {isa = PBXBuildFile; fileRef = 4ABB289124F82A640061BF55 /* SDLOnLockScreenStatus.m */; };
4ABB28C224F82A6A0061BF55 /* SDLOnTouchEvent.h in Headers */ = {isa = PBXBuildFile; fileRef = 4ABB289224F82A640061BF55 /* SDLOnTouchEvent.h */; settings = {ATTRIBUTES = (Public, ); }; };
4ABB28C324F82A6A0061BF55 /* SDLOnAppInterfaceUnregistered.m in Sources */ = {isa = PBXBuildFile; fileRef = 4ABB289324F82A640061BF55 /* SDLOnAppInterfaceUnregistered.m */; };
4ABB28C424F82A6A0061BF55 /* SDLOnCommand.m in Sources */ = {isa = PBXBuildFile; fileRef = 4ABB289424F82A640061BF55 /* SDLOnCommand.m */; };
@@ -1017,7 +1008,6 @@
4ABB28CF24F82A6A0061BF55 /* SDLOnSystemRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = 4ABB289F24F82A660061BF55 /* SDLOnSystemRequest.m */; };
4ABB28D024F82A6A0061BF55 /* SDLOnWayPointChange.h in Headers */ = {isa = PBXBuildFile; fileRef = 4ABB28A024F82A660061BF55 /* SDLOnWayPointChange.h */; settings = {ATTRIBUTES = (Public, ); }; };
4ABB28D124F82A6A0061BF55 /* SDLOnButtonEvent.m in Sources */ = {isa = PBXBuildFile; fileRef = 4ABB28A124F82A660061BF55 /* SDLOnButtonEvent.m */; };
- 4ABB28D224F82A6A0061BF55 /* SDLOnLockScreenStatus.h in Headers */ = {isa = PBXBuildFile; fileRef = 4ABB28A224F82A660061BF55 /* SDLOnLockScreenStatus.h */; settings = {ATTRIBUTES = (Public, ); }; };
4ABB28D324F82A6A0061BF55 /* SDLOnSystemCapabilityUpdated.m in Sources */ = {isa = PBXBuildFile; fileRef = 4ABB28A324F82A660061BF55 /* SDLOnSystemCapabilityUpdated.m */; };
4ABB28D424F82A6A0061BF55 /* SDLOnEncodedSyncPData.m in Sources */ = {isa = PBXBuildFile; fileRef = 4ABB28A424F82A670061BF55 /* SDLOnEncodedSyncPData.m */; };
4ABB28D524F82A6A0061BF55 /* SDLOnButtonEvent.h in Headers */ = {isa = PBXBuildFile; fileRef = 4ABB28A524F82A670061BF55 /* SDLOnButtonEvent.h */; settings = {ATTRIBUTES = (Public, ); }; };
@@ -1633,6 +1623,8 @@
88B58DC922204C9E0011B063 /* SDLNavigationActionSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 88B58DC822204C9E0011B063 /* SDLNavigationActionSpec.m */; };
88B848C31F45E1A600DED768 /* TestResponse.m in Sources */ = {isa = PBXBuildFile; fileRef = 88B848C21F45E1A600DED768 /* TestResponse.m */; };
88B848C91F462E3600DED768 /* TestFileProgressResponse.m in Sources */ = {isa = PBXBuildFile; fileRef = 88B848C81F462E3600DED768 /* TestFileProgressResponse.m */; };
+ 88BB8054250136670025E9C8 /* SDLLockScreenStatusInfo.h in Headers */ = {isa = PBXBuildFile; fileRef = 88BB8050250136660025E9C8 /* SDLLockScreenStatusInfo.h */; };
+ 88BB8055250136670025E9C8 /* SDLLockScreenStatusInfo.m in Sources */ = {isa = PBXBuildFile; fileRef = 88BB8051250136660025E9C8 /* SDLLockScreenStatusInfo.m */; };
88BCEA952266592D00BB7E70 /* SDLIAPControlSessionSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 88BCEA942266592D00BB7E70 /* SDLIAPControlSessionSpec.m */; };
88C23E8822297C6000EA171F /* SDLRPCResponseNotificationSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 88C23E8722297C6000EA171F /* SDLRPCResponseNotificationSpec.m */; };
88C23E8A22297DE400EA171F /* SDLRPCNotificationNotificationSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 88C23E8922297DE400EA171F /* SDLRPCNotificationNotificationSpec.m */; };
@@ -1646,6 +1638,7 @@
88DF999122035D5A00477AC1 /* SDLIAPTransportSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 88DF999022035D5A00477AC1 /* SDLIAPTransportSpec.m */; };
88E6F1AA220E1720006156F9 /* SDLMediaTypeSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 88E6F1A9220E1720006156F9 /* SDLMediaTypeSpec.m */; };
88E6F1B0220E25B2006156F9 /* SDLMediaServiceDataSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 88E6F1AF220E25B2006156F9 /* SDLMediaServiceDataSpec.m */; };
+ 88EE1A452502DB3100FFEBA9 /* SDLLockScreenConstants.h in Headers */ = {isa = PBXBuildFile; fileRef = 88EE1A442502DB3100FFEBA9 /* SDLLockScreenConstants.h */; };
88EEC5B8220A2144005AA2F9 /* SDLPublishAppServiceSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 88EEC5B7220A2144005AA2F9 /* SDLPublishAppServiceSpec.m */; };
88EEC5BE220A3B8B005AA2F9 /* SDLPublishAppServiceResponseSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 88EEC5BD220A3B8B005AA2F9 /* SDLPublishAppServiceResponseSpec.m */; };
88EED83B1F33BECB00E6C42E /* SDLHapticRectSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 88EED83A1F33BECB00E6C42E /* SDLHapticRectSpec.m */; };
@@ -1653,6 +1646,8 @@
88F37A4D226F84BE00DF119B /* SDLIAPDataSessionSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 88F37A4C226F84BE00DF119B /* SDLIAPDataSessionSpec.m */; };
88F50D5F220B720E00F34648 /* SDLPerformAppServiceInteractionSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 88F50D5E220B720E00F34648 /* SDLPerformAppServiceInteractionSpec.m */; };
88F65133220C6DC300CAF321 /* SDLWeatherAlertSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 88F65132220C6DC300CAF321 /* SDLWeatherAlertSpec.m */; };
+ 88FBF7C2250132C1005EA0A4 /* SDLOnLockScreenStatusSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 88FBF7C1250132C1005EA0A4 /* SDLOnLockScreenStatusSpec.m */; };
+ 88FBF7C52501330F005EA0A4 /* TestHapticRectViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 88FBF7C42501330F005EA0A4 /* TestHapticRectViewController.m */; };
8B05F88922DD011300666CD8 /* SDLUnpublishAppServiceSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 8B05F88822DD011300666CD8 /* SDLUnpublishAppServiceSpec.m */; };
8B7B31A91F2FB8BC00BDC38D /* SDLVideoStreamingProtocolSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 8B7B31A81F2FB8BC00BDC38D /* SDLVideoStreamingProtocolSpec.m */; };
8B7B31AB1F2FB93500BDC38D /* SDLVideoStreamingCodecSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 8B7B31AA1F2FB93500BDC38D /* SDLVideoStreamingCodecSpec.m */; };
@@ -1834,7 +1829,6 @@
162E82011A9BDE8A00906325 /* SDLKeypressModeSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLKeypressModeSpec.m; sourceTree = "<group>"; };
162E82021A9BDE8A00906325 /* SDLLanguageSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLLanguageSpec.m; sourceTree = "<group>"; };
162E82031A9BDE8A00906325 /* SDLLayoutModeSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLLayoutModeSpec.m; sourceTree = "<group>"; };
- 162E82041A9BDE8A00906325 /* SDLLockScreenStatusSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLLockScreenStatusSpec.m; sourceTree = "<group>"; };
162E82051A9BDE8A00906325 /* SDLMaintenanceModeStatusSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLMaintenanceModeStatusSpec.m; sourceTree = "<group>"; };
162E82061A9BDE8A00906325 /* SDLMediaClockFormatSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLMediaClockFormatSpec.m; sourceTree = "<group>"; };
162E82071A9BDE8A00906325 /* SDLPermissionStatusSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLPermissionStatusSpec.m; sourceTree = "<group>"; };
@@ -1878,7 +1872,6 @@
162E82311A9BDE8A00906325 /* SDLOnHMIStatusSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLOnHMIStatusSpec.m; sourceTree = "<group>"; };
162E82321A9BDE8A00906325 /* SDLOnKeyboardInputSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLOnKeyboardInputSpec.m; sourceTree = "<group>"; };
162E82331A9BDE8A00906325 /* SDLOnLanguageChangeSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLOnLanguageChangeSpec.m; sourceTree = "<group>"; };
- 162E82341A9BDE8A00906325 /* SDLOnLockScreenStatusSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLOnLockScreenStatusSpec.m; sourceTree = "<group>"; };
162E82351A9BDE8A00906325 /* SDLOnPermissionsChangeSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLOnPermissionsChangeSpec.m; sourceTree = "<group>"; };
162E82361A9BDE8A00906325 /* SDLOnSyncPDataSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLOnSyncPDataSpec.m; sourceTree = "<group>"; };
162E82371A9BDE8A00906325 /* SDLOnSystemRequestSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLOnSystemRequestSpec.m; sourceTree = "<group>"; };
@@ -1994,7 +1987,6 @@
162E82A91A9BDE8A00906325 /* SDLSoftButtonCapabilitiesSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLSoftButtonCapabilitiesSpec.m; sourceTree = "<group>"; };
162E82AA1A9BDE8A00906325 /* SDLSoftButtonSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLSoftButtonSpec.m; sourceTree = "<group>"; };
162E82AB1A9BDE8A00906325 /* SDLStartTimeSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLStartTimeSpec.m; sourceTree = "<group>"; };
- 162E82AC1A9BDE8A00906325 /* SDLSyncMsgVersionSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLSyncMsgVersionSpec.m; sourceTree = "<group>"; };
162E82AD1A9BDE8A00906325 /* SDLTextFieldSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLTextFieldSpec.m; sourceTree = "<group>"; };
162E82AE1A9BDE8A00906325 /* SDLTireStatusSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLTireStatusSpec.m; sourceTree = "<group>"; };
162E82AF1A9BDE8A00906325 /* SDLTouchCoordSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLTouchCoordSpec.m; sourceTree = "<group>"; };
@@ -2162,9 +2154,7 @@
4A8BD2A724F935BB000945E3 /* SDLStationIDNumber.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = SDLStationIDNumber.m; path = public/SDLStationIDNumber.m; sourceTree = "<group>"; };
4A8BD2A824F935BB000945E3 /* SDLSystemCapability.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SDLSystemCapability.h; path = public/SDLSystemCapability.h; sourceTree = "<group>"; };
4A8BD2A924F935BB000945E3 /* SDLSoftButton.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = SDLSoftButton.m; path = public/SDLSoftButton.m; sourceTree = "<group>"; };
- 4A8BD2AA24F935BC000945E3 /* SDLSyncMsgVersion.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = SDLSyncMsgVersion.m; path = public/SDLSyncMsgVersion.m; sourceTree = "<group>"; };
4A8BD2AB24F935BC000945E3 /* SDLSoftButton.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SDLSoftButton.h; path = public/SDLSoftButton.h; sourceTree = "<group>"; };
- 4A8BD2AC24F935BC000945E3 /* SDLSyncMsgVersion.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SDLSyncMsgVersion.h; path = public/SDLSyncMsgVersion.h; sourceTree = "<group>"; };
4A8BD2AD24F935BC000945E3 /* SDLStationIDNumber.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SDLStationIDNumber.h; path = public/SDLStationIDNumber.h; sourceTree = "<group>"; };
4A8BD2AE24F935BC000945E3 /* SDLSISData.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = SDLSISData.m; path = public/SDLSISData.m; sourceTree = "<group>"; };
4A8BD2AF24F935BC000945E3 /* SDLStartTime.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = SDLStartTime.m; path = public/SDLStartTime.m; sourceTree = "<group>"; };
@@ -2540,7 +2530,6 @@
4ABB269124F7F9060061BF55 /* SDLTimer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SDLTimer.h; path = private/SDLTimer.h; sourceTree = "<group>"; };
4ABB269424F7F93F0061BF55 /* SDLRPCFunctionNames.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SDLRPCFunctionNames.h; path = public/SDLRPCFunctionNames.h; sourceTree = "<group>"; };
4ABB269524F7F93F0061BF55 /* SDLRPCFunctionNames.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = SDLRPCFunctionNames.m; path = public/SDLRPCFunctionNames.m; sourceTree = "<group>"; };
- 4ABB269824F7F9560061BF55 /* SDLMacros.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SDLMacros.h; path = public/SDLMacros.h; sourceTree = "<group>"; };
4ABB269A24F7F9710061BF55 /* SDLRPCParameterNames.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SDLRPCParameterNames.h; path = private/SDLRPCParameterNames.h; sourceTree = "<group>"; };
4ABB269B24F7F9710061BF55 /* SDLRPCParameterNames.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = SDLRPCParameterNames.m; path = private/SDLRPCParameterNames.m; sourceTree = "<group>"; };
4ABB269E24F7F98C0061BF55 /* SDLLogFileModuleMap.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SDLLogFileModuleMap.h; path = private/SDLLogFileModuleMap.h; sourceTree = "<group>"; };
@@ -2673,8 +2662,6 @@
4ABB279E24F7FFD80061BF55 /* SDLMassageZone.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SDLMassageZone.h; path = public/SDLMassageZone.h; sourceTree = "<group>"; };
4ABB279F24F7FFD80061BF55 /* SDLMassageZone.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = SDLMassageZone.m; path = public/SDLMassageZone.m; sourceTree = "<group>"; };
4ABB27A024F7FFD80061BF55 /* SDLMediaClockFormat.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SDLMediaClockFormat.h; path = public/SDLMediaClockFormat.h; sourceTree = "<group>"; };
- 4ABB27A124F7FFD90061BF55 /* SDLLockScreenStatus.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SDLLockScreenStatus.h; path = public/SDLLockScreenStatus.h; sourceTree = "<group>"; };
- 4ABB27A224F7FFD90061BF55 /* SDLLockScreenStatus.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = SDLLockScreenStatus.m; path = public/SDLLockScreenStatus.m; sourceTree = "<group>"; };
4ABB27A324F7FFD90061BF55 /* SDLMaintenanceModeStatus.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = SDLMaintenanceModeStatus.m; path = public/SDLMaintenanceModeStatus.m; sourceTree = "<group>"; };
4ABB27A424F7FFD90061BF55 /* SDLMassageCushion.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SDLMassageCushion.h; path = public/SDLMassageCushion.h; sourceTree = "<group>"; };
4ABB27A524F7FFD90061BF55 /* SDLMassageCushion.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = SDLMassageCushion.m; path = public/SDLMassageCushion.m; sourceTree = "<group>"; };
@@ -2792,7 +2779,6 @@
4ABB288E24F82A640061BF55 /* SDLOnSyncPData.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = SDLOnSyncPData.m; path = public/SDLOnSyncPData.m; sourceTree = "<group>"; };
4ABB288F24F82A640061BF55 /* SDLOnTBTClientState.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = SDLOnTBTClientState.m; path = public/SDLOnTBTClientState.m; sourceTree = "<group>"; };
4ABB289024F82A640061BF55 /* SDLOnCommand.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SDLOnCommand.h; path = public/SDLOnCommand.h; sourceTree = "<group>"; };
- 4ABB289124F82A640061BF55 /* SDLOnLockScreenStatus.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = SDLOnLockScreenStatus.m; path = public/SDLOnLockScreenStatus.m; sourceTree = "<group>"; };
4ABB289224F82A640061BF55 /* SDLOnTouchEvent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SDLOnTouchEvent.h; path = public/SDLOnTouchEvent.h; sourceTree = "<group>"; };
4ABB289324F82A640061BF55 /* SDLOnAppInterfaceUnregistered.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = SDLOnAppInterfaceUnregistered.m; path = public/SDLOnAppInterfaceUnregistered.m; sourceTree = "<group>"; };
4ABB289424F82A640061BF55 /* SDLOnCommand.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = SDLOnCommand.m; path = public/SDLOnCommand.m; sourceTree = "<group>"; };
@@ -2809,7 +2795,6 @@
4ABB289F24F82A660061BF55 /* SDLOnSystemRequest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = SDLOnSystemRequest.m; path = public/SDLOnSystemRequest.m; sourceTree = "<group>"; };
4ABB28A024F82A660061BF55 /* SDLOnWayPointChange.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SDLOnWayPointChange.h; path = public/SDLOnWayPointChange.h; sourceTree = "<group>"; };
4ABB28A124F82A660061BF55 /* SDLOnButtonEvent.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = SDLOnButtonEvent.m; path = public/SDLOnButtonEvent.m; sourceTree = "<group>"; };
- 4ABB28A224F82A660061BF55 /* SDLOnLockScreenStatus.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SDLOnLockScreenStatus.h; path = public/SDLOnLockScreenStatus.h; sourceTree = "<group>"; };
4ABB28A324F82A660061BF55 /* SDLOnSystemCapabilityUpdated.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = SDLOnSystemCapabilityUpdated.m; path = public/SDLOnSystemCapabilityUpdated.m; sourceTree = "<group>"; };
4ABB28A424F82A670061BF55 /* SDLOnEncodedSyncPData.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = SDLOnEncodedSyncPData.m; path = public/SDLOnEncodedSyncPData.m; sourceTree = "<group>"; };
4ABB28A524F82A670061BF55 /* SDLOnButtonEvent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SDLOnButtonEvent.h; path = public/SDLOnButtonEvent.h; sourceTree = "<group>"; };
@@ -3461,6 +3446,8 @@
88B848C21F45E1A600DED768 /* TestResponse.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = TestResponse.m; sourceTree = "<group>"; };
88B848C71F462E3600DED768 /* TestFileProgressResponse.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TestFileProgressResponse.h; sourceTree = "<group>"; };
88B848C81F462E3600DED768 /* TestFileProgressResponse.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = TestFileProgressResponse.m; sourceTree = "<group>"; };
+ 88BB8050250136660025E9C8 /* SDLLockScreenStatusInfo.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SDLLockScreenStatusInfo.h; path = private/SDLLockScreenStatusInfo.h; sourceTree = "<group>"; };
+ 88BB8051250136660025E9C8 /* SDLLockScreenStatusInfo.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = SDLLockScreenStatusInfo.m; path = private/SDLLockScreenStatusInfo.m; sourceTree = "<group>"; };
88BCEA942266592D00BB7E70 /* SDLIAPControlSessionSpec.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = SDLIAPControlSessionSpec.m; sourceTree = "<group>"; };
88C23E8522297BD500EA171F /* SDLRPCRequestNotificationSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLRPCRequestNotificationSpec.m; sourceTree = "<group>"; };
88C23E8722297C6000EA171F /* SDLRPCResponseNotificationSpec.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = SDLRPCResponseNotificationSpec.m; sourceTree = "<group>"; };
@@ -3475,6 +3462,7 @@
88DF999022035D5A00477AC1 /* SDLIAPTransportSpec.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = SDLIAPTransportSpec.m; sourceTree = "<group>"; };
88E6F1A9220E1720006156F9 /* SDLMediaTypeSpec.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = SDLMediaTypeSpec.m; sourceTree = "<group>"; };
88E6F1AF220E25B2006156F9 /* SDLMediaServiceDataSpec.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = SDLMediaServiceDataSpec.m; sourceTree = "<group>"; };
+ 88EE1A442502DB3100FFEBA9 /* SDLLockScreenConstants.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = SDLLockScreenConstants.h; path = private/SDLLockScreenConstants.h; sourceTree = "<group>"; };
88EEC5B7220A2144005AA2F9 /* SDLPublishAppServiceSpec.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = SDLPublishAppServiceSpec.m; sourceTree = "<group>"; };
88EEC5BD220A3B8B005AA2F9 /* SDLPublishAppServiceResponseSpec.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = SDLPublishAppServiceResponseSpec.m; sourceTree = "<group>"; };
88EED83A1F33BECB00E6C42E /* SDLHapticRectSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLHapticRectSpec.m; sourceTree = "<group>"; };
@@ -3482,6 +3470,9 @@
88F37A4C226F84BE00DF119B /* SDLIAPDataSessionSpec.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = SDLIAPDataSessionSpec.m; sourceTree = "<group>"; };
88F50D5E220B720E00F34648 /* SDLPerformAppServiceInteractionSpec.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = SDLPerformAppServiceInteractionSpec.m; sourceTree = "<group>"; };
88F65132220C6DC300CAF321 /* SDLWeatherAlertSpec.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = SDLWeatherAlertSpec.m; sourceTree = "<group>"; };
+ 88FBF7C1250132C1005EA0A4 /* SDLOnLockScreenStatusSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLOnLockScreenStatusSpec.m; sourceTree = "<group>"; };
+ 88FBF7C32501330F005EA0A4 /* TestHapticRectViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TestHapticRectViewController.h; sourceTree = "<group>"; };
+ 88FBF7C42501330F005EA0A4 /* TestHapticRectViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = TestHapticRectViewController.m; sourceTree = "<group>"; };
8B05F88822DD011300666CD8 /* SDLUnpublishAppServiceSpec.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = SDLUnpublishAppServiceSpec.m; sourceTree = "<group>"; };
8B7B31A81F2FB8BC00BDC38D /* SDLVideoStreamingProtocolSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLVideoStreamingProtocolSpec.m; sourceTree = "<group>"; };
8B7B31AA1F2FB93500BDC38D /* SDLVideoStreamingCodecSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLVideoStreamingCodecSpec.m; sourceTree = "<group>"; };
@@ -3718,7 +3709,6 @@
162E82031A9BDE8A00906325 /* SDLLayoutModeSpec.m */,
1EAA47712036AEF5000FE74B /* SDLLightNameSpec.m */,
1EAA476F2036AE89000FE74B /* SDLLightStatusSpec.m */,
- 162E82041A9BDE8A00906325 /* SDLLockScreenStatusSpec.m */,
162E82051A9BDE8A00906325 /* SDLMaintenanceModeStatusSpec.m */,
1EB59CCD202DC97900343A61 /* SDLMassageCushionSpec.m */,
1EB59CD1202DCA9B00343A61 /* SDLMassageModeSpec.m */,
@@ -3796,7 +3786,6 @@
1EE8C4531F38762E00FDC2CF /* SDLOnInteriorVehicleDataSpec.m */,
162E82321A9BDE8A00906325 /* SDLOnKeyboardInputSpec.m */,
162E82331A9BDE8A00906325 /* SDLOnLanguageChangeSpec.m */,
- 162E82341A9BDE8A00906325 /* SDLOnLockScreenStatusSpec.m */,
162E82351A9BDE8A00906325 /* SDLOnPermissionsChangeSpec.m */,
1EAA470D2032BF1D000FE74B /* SDLOnRCStatusSpec.m */,
889D0B9D24D07FF8008AD494 /* SDLOnSubtleAlertPressedSpec.m */,
@@ -4046,7 +4035,6 @@
162E82AA1A9BDE8A00906325 /* SDLSoftButtonSpec.m */,
1EAA477F2036C2C9000FE74B /* SDLStationIDNumberSpec.m */,
162E82AB1A9BDE8A00906325 /* SDLStartTimeSpec.m */,
- 162E82AC1A9BDE8A00906325 /* SDLSyncMsgVersionSpec.m */,
5D0A9F961F1559EC00CC80DD /* SDLSystemCapabilitySpec.m */,
1EE8C4511F38657D00FDC2CF /* SDLTemperatureSpec.m */,
9FA0CFFC22DF0687009CF344 /* SDLTemplateConfigurationSpec.m */,
@@ -4223,6 +4211,7 @@
4A9D02C02497F9AA00FBE99B /* Status Manager */ = {
isa = PBXGroup;
children = (
+ 4ABB255324F7E5460061BF55 /* SDLLockScreenManager.h */,
4ABB254724F7E49D0061BF55 /* SDLLockScreenStatusManager.h */,
4ABB254624F7E49D0061BF55 /* SDLLockScreenStatusManager.m */,
);
@@ -5120,8 +5109,6 @@
4A8BD2AF24F935BC000945E3 /* SDLStartTime.m */,
4A8BD2AD24F935BC000945E3 /* SDLStationIDNumber.h */,
4A8BD2A724F935BB000945E3 /* SDLStationIDNumber.m */,
- 4A8BD2AC24F935BC000945E3 /* SDLSyncMsgVersion.h */,
- 4A8BD2AA24F935BC000945E3 /* SDLSyncMsgVersion.m */,
4A8BD2A824F935BB000945E3 /* SDLSystemCapability.h */,
4A8BD2B024F935BC000945E3 /* SDLSystemCapability.m */,
4A8BD2C124F93801000945E3 /* SDLTemperature.h */,
@@ -5273,8 +5260,6 @@
4ABB277224F7FE900061BF55 /* SDLLightName.m */,
4ABB277824F7FEB90061BF55 /* SDLLightStatus.h */,
4ABB277924F7FEB90061BF55 /* SDLLightStatus.m */,
- 4ABB27A124F7FFD90061BF55 /* SDLLockScreenStatus.h */,
- 4ABB27A224F7FFD90061BF55 /* SDLLockScreenStatus.m */,
4ABB27A724F7FFDA0061BF55 /* SDLMaintenanceModeStatus.h */,
4ABB27A324F7FFD90061BF55 /* SDLMaintenanceModeStatus.m */,
4ABB27A424F7FFD90061BF55 /* SDLMassageCushion.h */,
@@ -5433,7 +5418,6 @@
4ABB268924F7F8F00061BF55 /* SDLGlobals.m */,
4ABB268D24F7F8FB0061BF55 /* SDLHexUtility.h */,
4ABB268C24F7F8FB0061BF55 /* SDLHexUtility.m */,
- 4ABB269824F7F9560061BF55 /* SDLMacros.h */,
4ABB269424F7F93F0061BF55 /* SDLRPCFunctionNames.h */,
4ABB269524F7F93F0061BF55 /* SDLRPCFunctionNames.m */,
4ABB269A24F7F9710061BF55 /* SDLRPCParameterNames.h */,
@@ -5473,8 +5457,6 @@
4ABB289624F82A650061BF55 /* SDLOnKeyboardInput.m */,
4ABB289824F82A650061BF55 /* SDLOnLanguageChange.h */,
4ABB28B224F82A680061BF55 /* SDLOnLanguageChange.m */,
- 4ABB28A224F82A660061BF55 /* SDLOnLockScreenStatus.h */,
- 4ABB289124F82A640061BF55 /* SDLOnLockScreenStatus.m */,
4ABB289C24F82A650061BF55 /* SDLOnPermissionsChange.h */,
4ABB28B424F82A680061BF55 /* SDLOnPermissionsChange.m */,
4ABB28A824F82A670061BF55 /* SDLOnRCStatus.h */,
@@ -5747,6 +5729,7 @@
isa = PBXGroup;
children = (
5D76E3261D3D0A4700647CFA /* Utilities */,
+ 88FBF7C1250132C1005EA0A4 /* SDLOnLockScreenStatusSpec.m */,
5D76E31B1D3805FF00647CFA /* SDLLockScreenManagerSpec.m */,
5D59DD461B14FDEE00BE744D /* SDLLockScreenStatusManagerSpec.m */,
);
@@ -5756,6 +5739,9 @@
5D76E31F1D39731100647CFA /* Utilities */ = {
isa = PBXGroup;
children = (
+ 88EE1A442502DB3100FFEBA9 /* SDLLockScreenConstants.h */,
+ 88BB8050250136660025E9C8 /* SDLLockScreenStatusInfo.h */,
+ 88BB8051250136660025E9C8 /* SDLLockScreenStatusInfo.m */,
4ABB253E24F7E48D0061BF55 /* SDLLockScreenPresenter.h */,
4ABB254024F7E48D0061BF55 /* SDLLockScreenPresenter.m */,
4ABB253C24F7E48D0061BF55 /* SDLLockScreenRootViewController.h */,
@@ -6244,7 +6230,6 @@
5D6F7A301BC5B7100070BF37 /* Lock Screen UI */,
4A9D02C02497F9AA00FBE99B /* Status Manager */,
5D76E31F1D39731100647CFA /* Utilities */,
- 4ABB255324F7E5460061BF55 /* SDLLockScreenManager.h */,
4ABB255224F7E5460061BF55 /* SDLLockScreenManager.m */,
);
name = "Lock Screen";
@@ -6709,6 +6694,15 @@
path = iAP;
sourceTree = "<group>";
};
+ 88FBF7C62501343E005EA0A4 /* Utilities */ = {
+ isa = PBXGroup;
+ children = (
+ 88FBF7C32501330F005EA0A4 /* TestHapticRectViewController.h */,
+ 88FBF7C42501330F005EA0A4 /* TestHapticRectViewController.m */,
+ );
+ name = Utilities;
+ sourceTree = "<group>";
+ };
88FF4E792215FEAF00A71361 /* Notifications */ = {
isa = PBXGroup;
children = (
@@ -6721,6 +6715,7 @@
DA1166D71D14601C00438CEA /* Touches */ = {
isa = PBXGroup;
children = (
+ 88FBF7C62501343E005EA0A4 /* Utilities */,
DA4353E71D2721680099B8C4 /* SDLTouchManagerSpec.m */,
DA4353E81D2721680099B8C4 /* SDLTouchSpec.m */,
DA4353DE1D271FD10099B8C4 /* CGPointUtilSpec.m */,
@@ -6945,7 +6940,6 @@
4A8BD28424F9343F000945E3 /* SDLRDSData.h in Headers */,
4ABB25BA24F7E70E0061BF55 /* SDLSoftButtonState.h in Headers */,
4ABB295224F843440061BF55 /* SDLGetAppServiceData.h in Headers */,
- 4ABB269924F7F9560061BF55 /* SDLMacros.h in Headers */,
4ABB273A24F7FD1D0061BF55 /* SDLDirection.h in Headers */,
4ABB25A224F7E6CE0061BF55 /* SDLDynamicMenuUpdateRunScore.h in Headers */,
4A8BD3B024F98ACE000945E3 /* SDLLogManager.h in Headers */,
@@ -6991,7 +6985,6 @@
4ABB291D24F842560061BF55 /* SDLCreateWindow.h in Headers */,
4ABB257324F7E5E80061BF55 /* SDLCheckChoiceVROptionalOperation.h in Headers */,
4A8BD2D924F93803000945E3 /* SDLTemplateConfiguration.h in Headers */,
- 4A8BD2BA24F935BC000945E3 /* SDLSyncMsgVersion.h in Headers */,
4ABB25FC24F7E8E10061BF55 /* SDLStreamingVideoScaleManager.h in Headers */,
4A8BD2F324F93872000945E3 /* SDLVehicleDataResult.h in Headers */,
4A8BD3AC24F98602000945E3 /* NSNumber+NumberType.h in Headers */,
@@ -7195,7 +7188,6 @@
4ABB280C24F824600061BF55 /* SDLSoftButtonType.h in Headers */,
4A8BD2DE24F93803000945E3 /* SDLTemplateColorScheme.h in Headers */,
4ABB250824F596920061BF55 /* SDLFileWrapper.h in Headers */,
- 4ABB28D224F82A6A0061BF55 /* SDLOnLockScreenStatus.h in Headers */,
4ABB285C24F828E00061BF55 /* SDLVehicleDataEventStatus.h in Headers */,
4ABB254324F7E48D0061BF55 /* SDLLockScreenPresenter.h in Headers */,
4ABB26D624F7FAFD0061BF55 /* SDLRPCNotification.h in Headers */,
@@ -7215,6 +7207,7 @@
4ABB257624F7E5E80061BF55 /* SDLPreloadChoicesOperation.h in Headers */,
4ABB28E724F82A6A0061BF55 /* SDLOnAudioPassThru.h in Headers */,
4ABB25AD24F7E6E10061BF55 /* SDLMenuManager.h in Headers */,
+ 88EE1A452502DB3100FFEBA9 /* SDLLockScreenConstants.h in Headers */,
4ABB254124F7E48D0061BF55 /* SDLLockScreenRootViewController.h in Headers */,
4ABB2A7124F847D40061BF55 /* SDLPublishAppServiceResponse.h in Headers */,
4A8BD2D724F93803000945E3 /* SDLTextField.h in Headers */,
@@ -7335,6 +7328,7 @@
4ABB25F724F7E7EF0061BF55 /* SDLTouchManagerDelegate.h in Headers */,
4A8BD34424F945CC000945E3 /* SDLControlFramePayloadNak.h in Headers */,
4A8BD36624F9461A000945E3 /* SDLProtocolMessage.h in Headers */,
+ 88BB8054250136670025E9C8 /* SDLLockScreenStatusInfo.h in Headers */,
4ABB27B324F7FFDA0061BF55 /* SDLMaintenanceModeStatus.h in Headers */,
4A8BD28524F9343F000945E3 /* SDLPhoneCapability.h in Headers */,
4ABB27F024F801B50061BF55 /* SDLPRNDL.h in Headers */,
@@ -7352,7 +7346,6 @@
4ABB269324F7F9060061BF55 /* SDLTimer.h in Headers */,
4A8BD2F924F93872000945E3 /* SDLVehicleDataType.h in Headers */,
4ABB279924F7FF0B0061BF55 /* SDLLanguage.h in Headers */,
- 4ABB27AD24F7FFDA0061BF55 /* SDLLockScreenStatus.h in Headers */,
4ABB285F24F828E00061BF55 /* SDLVehicleDataActiveStatus.h in Headers */,
4ABB267A24F7F6840061BF55 /* SDLIconArchiveFile.h in Headers */,
4ABB28EA24F82A6A0061BF55 /* SDLOnAppInterfaceUnregistered.h in Headers */,
@@ -7800,7 +7793,6 @@
4A8BD27F24F9343F000945E3 /* SDLRadioControlCapabilities.m in Sources */,
4ABB29EF24F847360061BF55 /* SDLUnsubscribeButton.m in Sources */,
4ABB24EC24F594F30061BF55 /* SDLFileManagerConfiguration.m in Sources */,
- 4ABB28C124F82A6A0061BF55 /* SDLOnLockScreenStatus.m in Sources */,
4A8BD2D424F93803000945E3 /* SDLTouchCoord.m in Sources */,
4ABB263B24F7F4470061BF55 /* SDLStreamingVideoLifecycleManager.m in Sources */,
4ABB2B9E24F850AE0061BF55 /* SDLImage.m in Sources */,
@@ -7922,6 +7914,7 @@
4ABB2A6124F847B10061BF55 /* SDLGetSystemCapabilityResponse.m in Sources */,
4ABB26A524F7F9B90061BF55 /* SDLLogFileModule.m in Sources */,
4ABB29E124F846880061BF55 /* SDLUnpublishAppService.m in Sources */,
+ 88BB8055250136670025E9C8 /* SDLLockScreenStatusInfo.m in Sources */,
4ABB285D24F828E00061BF55 /* SDLVehicleDataType.m in Sources */,
4ABB2A7424F847D40061BF55 /* SDLPerformAudioPassThruResponse.m in Sources */,
4ABB250124F596450061BF55 /* SDLUploadFileOperation.m in Sources */,
@@ -7960,7 +7953,6 @@
4ABB2B8324F8504A0061BF55 /* SDLHMICapabilities.m in Sources */,
4ABB2B6924F84FE50061BF55 /* SDLEqualizerSettings.m in Sources */,
4ABB276F24F7FE480061BF55 /* SDLIgnitionStableStatus.m in Sources */,
- 4A8BD2B824F935BC000945E3 /* SDLSyncMsgVersion.m in Sources */,
4ABB280824F824600061BF55 /* SDLSeatMemoryActionType.m in Sources */,
4ABB2A5324F847B10061BF55 /* SDLGetVehicleDataResponse.m in Sources */,
4ABB2B4A24F84EF50061BF55 /* SDLChoice.m in Sources */,
@@ -7994,7 +7986,6 @@
4ABB26B024F7F9DF0061BF55 /* SDLLogTargetOSLog.m in Sources */,
4ABB27DC24F800CA0061BF55 /* SDLPredefinedLayout.m in Sources */,
4A8BD30B24F938D6000945E3 /* SDLWeatherData.m in Sources */,
- 4ABB27AE24F7FFDA0061BF55 /* SDLLockScreenStatus.m in Sources */,
4ABB271624F7FC4E0061BF55 /* SDLCarModeStatus.m in Sources */,
4A8BD2F624F93872000945E3 /* SDLVehicleDataResult.m in Sources */,
4ABB254824F7E49D0061BF55 /* SDLLockScreenStatusManager.m in Sources */,
@@ -8334,6 +8325,7 @@
162E83721A9BDE8B00906325 /* SDLAudioPassThruCapabilitiesSpec.m in Sources */,
162E83681A9BDE8B00906325 /* SDLSpeakResponseSpec.m in Sources */,
B38D8E8224A1F53500B977D0 /* SDLCapacityUnitSpec.m in Sources */,
+ 88FBF7C52501330F005EA0A4 /* TestHapticRectViewController.m in Sources */,
1EB59CD8202DCCD500343A61 /* SDLMassageCushionFirmnessSpec.m in Sources */,
162E83661A9BDE8B00906325 /* SDLShowResponseSpec.m in Sources */,
5D9F50831BEA5C6100FEF399 /* SDLFileManagerSpec.m in Sources */,
@@ -8447,7 +8439,6 @@
8BBEA6091F324832003EEA26 /* SDLMetadataTypeSpec.m in Sources */,
5DAD5F8B20508F140025624C /* SDLSoftButtonObjectSpec.m in Sources */,
DA9F7E9E1DCC05B900ACAE48 /* SDLWaypointTypeSpec.m in Sources */,
- 162E838E1A9BDE8B00906325 /* SDLSyncMsgVersionSpec.m in Sources */,
5D76E31C1D3805FF00647CFA /* SDLLockScreenManagerSpec.m in Sources */,
162E82DA1A9BDE8B00906325 /* SDLDriverDistractionStateSpec.m in Sources */,
162E83631A9BDE8B00906325 /* SDLSetGlobalPropertiesResponseSpec.m in Sources */,
@@ -8541,7 +8532,6 @@
1E89B0DE2031636000A47992 /* SDLSeatControlDataSpec.m in Sources */,
88A4A0FA22242AB400C6F01D /* SDLNavigationServiceDataSpec.m in Sources */,
8831FA3D220207DA00B8FFB7 /* SDLServiceUpdateReasonSpec.m in Sources */,
- 162E831A1A9BDE8B00906325 /* SDLOnLockScreenStatusSpec.m in Sources */,
000DD57422EF0957005AB7A7 /* SDLReleaseInteriorVehicleDataModuleSpec.m in Sources */,
162E83431A9BDE8B00906325 /* SDLSyncPDataSpec.m in Sources */,
162E838B1A9BDE8B00906325 /* SDLSoftButtonCapabilitiesSpec.m in Sources */,
@@ -8642,6 +8632,7 @@
88D2AAE41F682BB20078D5B2 /* SDLLogConstantsSpec.m in Sources */,
162E836B1A9BDE8B00906325 /* SDLSyncPDataResponseSpec.m in Sources */,
8B7B31AF1F2FBA0200BDC38D /* SDLVideoStreamingCapabilitySpec.m in Sources */,
+ 88FBF7C2250132C1005EA0A4 /* SDLOnLockScreenStatusSpec.m in Sources */,
8B05F88922DD011300666CD8 /* SDLUnpublishAppServiceSpec.m in Sources */,
162E839B1A9BDE8B00906325 /* SDLRPCNotificationSpec.m in Sources */,
162E83581A9BDE8B00906325 /* SDLGetVehicleDataResponseSpec.m in Sources */,
@@ -8739,7 +8730,6 @@
1EB59CD0202DC9F200343A61 /* SDLSupportedSeatSpec.m in Sources */,
162E82EB1A9BDE8B00906325 /* SDLLayoutModeSpec.m in Sources */,
1680B1181A9CD7AD00DBD79E /* SDLV1ProtocolMessageSpec.m in Sources */,
- 162E82EC1A9BDE8B00906325 /* SDLLockScreenStatusSpec.m in Sources */,
DA96C0661D4D4F730022F520 /* SDLAppInfoSpec.m in Sources */,
75FF2E3822DF9D5900D0C13B /* SDLShowAppMenuResponseSpec.m in Sources */,
);
diff --git a/SmartDeviceLink/SmartDeviceLink.h b/SmartDeviceLink/SmartDeviceLink.h
index ff04e01cb..197e01b4c 100644
--- a/SmartDeviceLink/SmartDeviceLink.h
+++ b/SmartDeviceLink/SmartDeviceLink.h
@@ -165,7 +165,6 @@ FOUNDATION_EXPORT const unsigned char SmartDeviceLinkVersionString[];
#import "SDLOnInteriorVehicleData.h"
#import "SDLOnKeyboardInput.h"
#import "SDLOnLanguageChange.h"
-#import "SDLOnLockScreenStatus.h"
#import "SDLOnPermissionsChange.h"
#import "SDLOnRCStatus.h"
#import "SDLOnSubtleAlertPressed.h"
@@ -266,7 +265,6 @@ FOUNDATION_EXPORT const unsigned char SmartDeviceLinkVersionString[];
#import "SDLStabilityControlsStatus.h"
#import "SDLStartTime.h"
#import "SDLStationIDNumber.h"
-#import "SDLSyncMsgVersion.h"
#import "SDLMsgVersion.h"
#import "SDLSystemCapability.h"
#import "SDLTTSChunk.h"
@@ -339,7 +337,6 @@ FOUNDATION_EXPORT const unsigned char SmartDeviceLinkVersionString[];
#import "SDLKeypressMode.h"
#import "SDLLanguage.h"
#import "SDLLayoutMode.h"
-#import "SDLLockScreenStatus.h"
#import "SDLLightName.h"
#import "SDLLightStatus.h"
#import "SDLMaintenanceModeStatus.h"
@@ -495,6 +492,3 @@ FOUNDATION_EXPORT const unsigned char SmartDeviceLinkVersionString[];
#import "SDLLogTargetAppleSystemLog.h"
#import "SDLLogTargetFile.h"
#import "SDLLogTargetOSLog.h"
-
-#pragma mark Macros
-#import "SDLMacros.h"
diff --git a/SmartDeviceLink/private/NSMutableDictionary+Store.h b/SmartDeviceLink/private/NSMutableDictionary+Store.h
index 26493a1b8..58f8d7557 100644
--- a/SmartDeviceLink/private/NSMutableDictionary+Store.h
+++ b/SmartDeviceLink/private/NSMutableDictionary+Store.h
@@ -7,13 +7,12 @@
//
#import <Foundation/Foundation.h>
-#import "SDLMacros.h"
#import "SDLLogMacros.h"
NS_ASSUME_NONNULL_BEGIN
-typedef NSString* SDLRPCParameterName SDL_SWIFT_ENUM;
-typedef NSString* SDLEnum SDL_SWIFT_ENUM;
+typedef NSString* SDLRPCParameterName NS_TYPED_ENUM;
+typedef NSString* SDLEnum NS_TYPED_ENUM;
@interface NSDictionary (Store)
diff --git a/SmartDeviceLink/private/SDLChoiceSetManager.m b/SmartDeviceLink/private/SDLChoiceSetManager.m
index 2b8422134..80d691b87 100644
--- a/SmartDeviceLink/private/SDLChoiceSetManager.m
+++ b/SmartDeviceLink/private/SDLChoiceSetManager.m
@@ -98,11 +98,7 @@ UInt16 const ChoiceCellCancelIdMin = 1;
_stateMachine = [[SDLStateMachine alloc] initWithTarget:self initialState:SDLChoiceManagerStateShutdown states:[self.class sdl_stateTransitionDictionary]];
_transactionQueue = [self sdl_newTransactionQueue];
- if (@available(iOS 10.0, *)) {
- _readWriteQueue = dispatch_queue_create_with_target("com.sdl.screenManager.choiceSetManager.readWriteQueue", DISPATCH_QUEUE_SERIAL, [SDLGlobals sharedGlobals].sdlProcessingQueue);
- } else {
- _readWriteQueue = [SDLGlobals sharedGlobals].sdlProcessingQueue;
- }
+ _readWriteQueue = dispatch_queue_create_with_target("com.sdl.screenManager.choiceSetManager.readWriteQueue", DISPATCH_QUEUE_SERIAL, [SDLGlobals sharedGlobals].sdlProcessingQueue);
_preloadedMutableChoices = [NSMutableSet set];
_pendingMutablePreloadChoices = [NSMutableSet set];
diff --git a/SmartDeviceLink/private/SDLEncryptionLifecycleManager.m b/SmartDeviceLink/private/SDLEncryptionLifecycleManager.m
index b141080e4..8206a021f 100644
--- a/SmartDeviceLink/private/SDLEncryptionLifecycleManager.m
+++ b/SmartDeviceLink/private/SDLEncryptionLifecycleManager.m
@@ -38,7 +38,7 @@ typedef NSString SDLVehicleMake;
@property (strong, nonatomic, readwrite) SDLStateMachine *encryptionStateMachine;
@property (copy, nonatomic, nullable) SDLHMILevel currentHMILevel;
-@property (strong, nonatomic, nullable) NSMutableDictionary<SDLPermissionRPCName, SDLPermissionItem *> *permissions;
+@property (strong, nonatomic, nullable) NSMutableDictionary<SDLRPCFunctionName, SDLPermissionItem *> *permissions;
@property (assign, nonatomic) BOOL requiresEncryption;
@property (strong, nonatomic) SDLConfiguration *configuration;
@@ -60,7 +60,7 @@ typedef NSString SDLVehicleMake;
_requiresEncryption = NO;
_securityManagers = [NSMutableDictionary dictionary];
_encryptionStateMachine = [[SDLStateMachine alloc] initWithTarget:self initialState:SDLEncryptionLifecycleManagerStateStopped states:[self.class sdl_encryptionStateTransitionDictionary]];
- _permissions = [NSMutableDictionary<SDLPermissionRPCName, SDLPermissionItem *> dictionary];
+ _permissions = [NSMutableDictionary<SDLRPCFunctionName, SDLPermissionItem *> dictionary];
_configuration = configuration;
for (Class securityManagerClass in _configuration.encryptionConfig.securityManagers) {
diff --git a/SmartDeviceLink/private/SDLFocusableItemLocator.m b/SmartDeviceLink/private/SDLFocusableItemLocator.m
index e416c2a3a..fbd0c956a 100644
--- a/SmartDeviceLink/private/SDLFocusableItemLocator.m
+++ b/SmartDeviceLink/private/SDLFocusableItemLocator.m
@@ -63,22 +63,18 @@ NS_ASSUME_NONNULL_BEGIN
}
- (void)updateInterfaceLayout {
- if (@available(iOS 9.0, *)) {
- [self.focusableViews removeAllObjects];
- [self sdl_parseViewHierarchy:self.viewController.view];
-
- // If there is a preferred view, move it to the front of the array
- NSUInteger preferredViewIndex = [self.focusableViews indexOfObject:self.viewController.view.subviews.lastObject.preferredFocusedView];
- if (preferredViewIndex != NSNotFound && self.focusableViews.count > 1) {
- [self.focusableViews exchangeObjectAtIndex:preferredViewIndex withObjectAtIndex:0];
- }
+ [self.focusableViews removeAllObjects];
+ [self sdl_parseViewHierarchy:self.viewController.view];
- SDLLogD(@"Updated VC layout, sending new haptic rects");
- SDLLogV(@"For focusable views: %@", self.focusableViews);
- [self sdl_sendHapticRPC];
- } else {
- SDLLogE(@"Attempted to update user interface layout, but it only works on iOS 9.0+");
+ // If there is a preferred view, move it to the front of the array
+ NSUInteger preferredViewIndex = [self.focusableViews indexOfObject:(UIView *)self.viewController.preferredFocusEnvironments.firstObject];
+ if (preferredViewIndex != NSNotFound && self.focusableViews.count > 1) {
+ [self.focusableViews exchangeObjectAtIndex:preferredViewIndex withObjectAtIndex:0];
}
+
+ SDLLogD(@"Updated VC layout, sending new haptic rects");
+ SDLLogV(@"For focusable views: %@", self.focusableViews);
+ [self sdl_sendHapticRPC];
}
/**
@@ -94,28 +90,27 @@ NS_ASSUME_NONNULL_BEGIN
SDLLogD(@"Parsing UIView heirarchy");
SDLLogV(@"UIView: %@", currentView);
- if (@available(iOS 9.0, *)) {
- // Finding focusable subviews
- NSArray *focusableSubviews = [currentView.subviews filteredArrayUsingPredicate:[NSPredicate predicateWithBlock:^BOOL(UIView * _Nullable evaluatedObject, NSDictionary<NSString *,id> * _Nullable bindings) {
- return (evaluatedObject.canBecomeFocused || [evaluatedObject isKindOfClass:[UIButton class]]);
- }]];
- SDLLogV(@"Found focusable subviews: %@", focusableSubviews);
-
- BOOL isButton = [currentView isKindOfClass:[UIButton class]];
- if ((currentView.canBecomeFocused || isButton) && focusableSubviews.count == 0) {
- //if current view is focusable and it doesn't have any focusable sub views then add the current view and return
- [self.focusableViews addObject:currentView];
- return;
- } else if (currentView.subviews.count > 0) {
- // if current view has focusable sub views parse them recursively
- NSArray<UIView *> *subviews = currentView.subviews;
-
- for (UIView *childView in subviews) {
- [self sdl_parseViewHierarchy:childView];
- }
- } else {
- return;
+
+ // Finding focusable subviews
+ NSArray *focusableSubviews = [currentView.subviews filteredArrayUsingPredicate:[NSPredicate predicateWithBlock:^BOOL(UIView * _Nullable evaluatedObject, NSDictionary<NSString *,id> * _Nullable bindings) {
+ return (evaluatedObject.canBecomeFocused || [evaluatedObject isKindOfClass:[UIButton class]]);
+ }]];
+ SDLLogV(@"Found focusable subviews: %@", focusableSubviews);
+
+ BOOL isButton = [currentView isKindOfClass:[UIButton class]];
+ if ((currentView.canBecomeFocused || isButton) && focusableSubviews.count == 0) {
+ //if current view is focusable and it doesn't have any focusable sub views then add the current view and return
+ [self.focusableViews addObject:currentView];
+ return;
+ } else if (currentView.subviews.count > 0) {
+ // if current view has focusable sub views parse them recursively
+ NSArray<UIView *> *subviews = currentView.subviews;
+
+ for (UIView *childView in subviews) {
+ [self sdl_parseViewHierarchy:childView];
}
+ } else {
+ return;
}
}
diff --git a/SmartDeviceLink/private/SDLH264VideoEncoder.h b/SmartDeviceLink/private/SDLH264VideoEncoder.h
index 58bde0508..ccb70f424 100644
--- a/SmartDeviceLink/private/SDLH264VideoEncoder.h
+++ b/SmartDeviceLink/private/SDLH264VideoEncoder.h
@@ -9,7 +9,6 @@
#import <Foundation/Foundation.h>
#import <VideoToolbox/VideoToolbox.h>
-#import "SDLMacros.h"
#import "SDLVideoStreamingProtocol.h"
#import "SDLVideoEncoderDelegate.h"
@@ -42,11 +41,7 @@ extern NSString *const SDLErrorDomainVideoEncoder;
/**
* Provides default video encoder settings used.
*/
-#if SDL_SUPPORTS_CLASS_PROPERTIES
@property (class, strong, nonatomic, readonly) NSDictionary<NSString *, id> *defaultVideoEncoderSettings;
-#else
-+ (NSDictionary<NSString *, id>*)defaultVideoEncoderSettings;
-#endif
/**
* The pixel buffer pool reference returned back from an active VTCompressionSessionRef encoder.
diff --git a/SmartDeviceLink/private/SDLLifecycleManager.m b/SmartDeviceLink/private/SDLLifecycleManager.m
index 97842dcd1..8d25b79f7 100644
--- a/SmartDeviceLink/private/SDLLifecycleManager.m
+++ b/SmartDeviceLink/private/SDLLifecycleManager.m
@@ -158,12 +158,7 @@ NSString *const BackgroundTaskTransportName = @"com.sdl.transport.backgroundTask
_rpcOperationQueue = [[NSOperationQueue alloc] init];
_rpcOperationQueue.name = @"com.sdl.lifecycle.rpcOperation.concurrent";
_rpcOperationQueue.underlyingQueue = [SDLGlobals sharedGlobals].sdlConcurrentQueue;
-
- if (@available(iOS 10.0, *)) {
- _lifecycleQueue = dispatch_queue_create_with_target("com.sdl.lifecycle", DISPATCH_QUEUE_SERIAL, [SDLGlobals sharedGlobals].sdlProcessingQueue);
- } else {
- _lifecycleQueue = [SDLGlobals sharedGlobals].sdlProcessingQueue;
- }
+ _lifecycleQueue = dispatch_queue_create_with_target("com.sdl.lifecycle", DISPATCH_QUEUE_SERIAL, [SDLGlobals sharedGlobals].sdlProcessingQueue);
_currentVRLanguage = _configuration.lifecycleConfig.language;
@@ -419,11 +414,10 @@ NSString *const BackgroundTaskTransportName = @"com.sdl.transport.backgroundTask
SDLLanguage actualHMILanguage = self.registerResponse.hmiDisplayLanguage;
SDLLanguage actualVRLanguage = self.registerResponse.language;
- BOOL oldDelegateCanUpdateLifecycle = [self.delegate respondsToSelector:@selector(managerShouldUpdateLifecycleToLanguage:)];
BOOL delegateCanUpdateLifecycle = [self.delegate respondsToSelector:@selector(managerShouldUpdateLifecycleToLanguage:hmiLanguage:)];
// language mismatch? but actual language is a supported language? and delegate has implemented method?
- if ((delegateCanUpdateLifecycle || oldDelegateCanUpdateLifecycle)
+ if (delegateCanUpdateLifecycle
&& ([supportedLanguages containsObject:actualHMILanguage] || [supportedLanguages containsObject:actualVRLanguage])
&& (![actualHMILanguage isEqualToEnum:desiredHMILanguage] || ![actualVRLanguage isEqualToEnum:desiredVRLanguage])) {
// If the delegate is implemented, AND the new HMI / VR language is a supported language, AND the new HMI / VR language is not the current language, THEN go to the updating configuration state and see if the dev wants to change the registration.
@@ -440,15 +434,9 @@ NSString *const BackgroundTaskTransportName = @"com.sdl.transport.backgroundTask
SDLLogD(@"Updating configuration due to language mismatch. New language: %@, new hmiLanguage: %@", actualLanguage, actualHMILanguage);
SDLLifecycleConfigurationUpdate *configUpdate = nil;
- BOOL supportsNewDelegate = [self.delegate respondsToSelector:@selector(managerShouldUpdateLifecycleToLanguage:hmiLanguage:)];
- BOOL supportsOldDelegate = [self.delegate respondsToSelector:@selector(managerShouldUpdateLifecycleToLanguage:)];
- if (supportsNewDelegate) {
+ BOOL delegateRespondsToSelector = [self.delegate respondsToSelector:@selector(managerShouldUpdateLifecycleToLanguage:hmiLanguage:)];
+ if (delegateRespondsToSelector) {
configUpdate = [self.delegate managerShouldUpdateLifecycleToLanguage:actualLanguage hmiLanguage:actualHMILanguage];
- } else if (supportsOldDelegate) {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- configUpdate = [self.delegate managerShouldUpdateLifecycleToLanguage:actualLanguage];
-#pragma clang diagnostic pop
}
if (configUpdate) {
@@ -622,13 +610,10 @@ NSString *const BackgroundTaskTransportName = @"com.sdl.transport.backgroundTask
- (void)sdl_sendAppIcon:(nullable SDLFile *)appIcon withCompletion:(void (^)(void))completion {
// If no app icon was set, just move on to ready
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated"
if (appIcon == nil || ![self.systemCapabilityManager.defaultMainWindowCapability.imageTypeSupported containsObject:SDLImageTypeDynamic]) {
completion();
return;
}
-#pragma clang diagnostic pop
[self.fileManager uploadFile:appIcon completionHandler:^(BOOL success, NSUInteger bytesAvailable, NSError *_Nullable error) {
// These errors could be recoverable (particularly "cannot overwrite"), so we'll still attempt to set the app icon
diff --git a/SmartDeviceLink/private/SDLLifecycleSystemRequestHandler.m b/SmartDeviceLink/private/SDLLifecycleSystemRequestHandler.m
index 354dca8dd..2acf97aa4 100644
--- a/SmartDeviceLink/private/SDLLifecycleSystemRequestHandler.m
+++ b/SmartDeviceLink/private/SDLLifecycleSystemRequestHandler.m
@@ -90,7 +90,7 @@ typedef void (^URLSessionDownloadTaskCompletionHandler)(NSURL *location, NSURLRe
}
}
- [[UIApplication sharedApplication] openURL:urlScheme];
+ [[UIApplication sharedApplication] openURL:urlScheme options:@{} completionHandler:nil];
}
- (void)sdl_handleSystemRequestProprietary:(SDLOnSystemRequest *)request {
diff --git a/SmartDeviceLink/private/SDLLockScreenConstants.h b/SmartDeviceLink/private/SDLLockScreenConstants.h
new file mode 100644
index 000000000..0865666ae
--- /dev/null
+++ b/SmartDeviceLink/private/SDLLockScreenConstants.h
@@ -0,0 +1,18 @@
+//
+// SDLLockScreenConstants.h
+// SmartDeviceLink-iOS
+//
+// Created by Nicole on 9/4/20.
+// Copyright © 2020 smartdevicelink. All rights reserved.
+//
+
+NS_ASSUME_NONNULL_BEGIN
+
+/// Describes the status of the lock screen
+typedef NS_ENUM(NSUInteger, SDLLockScreenStatus) {
+ SDLLockScreenStatusOff, // LockScreen is not required
+ SDLLockScreenStatusOptional, // LockScreen is optional
+ SDLLockScreenStatusRequired // LockScreen is required
+};
+
+NS_ASSUME_NONNULL_END
diff --git a/SmartDeviceLink/private/SDLLockScreenManager.m b/SmartDeviceLink/private/SDLLockScreenManager.m
index 34ceee0bd..85d570543 100644
--- a/SmartDeviceLink/private/SDLLockScreenManager.m
+++ b/SmartDeviceLink/private/SDLLockScreenManager.m
@@ -12,11 +12,10 @@
#import "SDLLogMacros.h"
#import "SDLLockScreenConfiguration.h"
#import "SDLLockScreenStatusManager.h"
-#import "SDLLockScreenStatus.h"
#import "SDLLockScreenViewController.h"
#import "SDLNotificationConstants.h"
#import "SDLNotificationDispatcher.h"
-#import "SDLOnLockScreenStatus.h"
+#import "SDLLockScreenStatusInfo.h"
#import "SDLOnDriverDistraction.h"
#import "SDLRPCNotificationNotification.h"
#import "SDLViewControllerPresentable.h"
@@ -31,11 +30,7 @@ NS_ASSUME_NONNULL_BEGIN
@property (strong, nonatomic) id<SDLViewControllerPresentable> presenter;
@property (strong, nonatomic) SDLLockScreenStatusManager *statusManager;
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
-@property (strong, nonatomic, nullable) SDLOnLockScreenStatus *lastLockNotification;
-#pragma clang diagnostic pop
-
+@property (strong, nonatomic, nullable) SDLLockScreenStatusInfo *lastLockNotification;
@property (strong, nonatomic, nullable) SDLOnDriverDistraction *lastDriverDistractionNotification;
@property (assign, nonatomic, readwrite, getter=isLockScreenDismissable) BOOL lockScreenDismissable;
@property (assign, nonatomic) BOOL lockScreenDismissedByUser;
@@ -58,10 +53,7 @@ NS_ASSUME_NONNULL_BEGIN
_lockScreenDismissedByUser = NO;
_statusManager = [[SDLLockScreenStatusManager alloc] initWithNotificationDispatcher:dispatcher];
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(sdl_lockScreenStatusDidChange:) name:SDLDidChangeLockScreenStatusNotification object:_statusManager];
-#pragma clang diagnostic pop
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(sdl_lockScreenIconReceived:) name:SDLDidReceiveLockScreenIcon object:nil];
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(sdl_appDidBecomeActive:) name:UIApplicationDidBecomeActiveNotification object:nil];
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(sdl_driverDistractionStateDidChange:) name:SDLDidChangeDriverDistractionStateNotification object:dispatcher];
@@ -135,14 +127,10 @@ NS_ASSUME_NONNULL_BEGIN
#pragma mark - Notification Selectors
- (void)sdl_lockScreenStatusDidChange:(SDLRPCNotificationNotification *)notification {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- if (![notification isNotificationMemberOfClass:[SDLOnLockScreenStatus class]]) {
-#pragma clang diagnostic pop
- return;
- }
+ SDLLockScreenStatusInfo *lockScreenStatus = (SDLLockScreenStatusInfo *)notification.userInfo[SDLNotificationUserInfoObject];
+ if (lockScreenStatus == nil) { return; }
- self.lastLockNotification = notification.notification;
+ self.lastLockNotification = lockScreenStatus;
[self sdl_checkLockScreen];
}
@@ -200,26 +188,17 @@ NS_ASSUME_NONNULL_BEGIN
if (self.canPresent) {
[self.presenter updateLockScreenToShow:YES withCompletionHandler:nil];
}
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- } else if ([self.lastLockNotification.lockScreenStatus isEqualToEnum:SDLLockScreenStatusRequired]) {
-#pragma clang diagnostic pop
+ } else if (self.lastLockNotification.lockScreenStatus == SDLLockScreenStatusRequired) {
if (self.canPresent && !self.lockScreenDismissedByUser) {
[self.presenter updateLockScreenToShow:YES withCompletionHandler:nil];
}
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- } else if ([self.lastLockNotification.lockScreenStatus isEqualToEnum:SDLLockScreenStatusOptional]) {
-#pragma clang diagnostic pop
+ } else if (self.lastLockNotification.lockScreenStatus == SDLLockScreenStatusOptional) {
if (self.config.displayMode == SDLLockScreenConfigurationDisplayModeOptionalOrRequired && self.canPresent && !self.lockScreenDismissedByUser) {
[self.presenter updateLockScreenToShow:YES withCompletionHandler:nil];
} else if (self.config.displayMode != SDLLockScreenConfigurationDisplayModeOptionalOrRequired) {
[self.presenter updateLockScreenToShow:NO withCompletionHandler:nil];
}
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- } else if ([self.lastLockNotification.lockScreenStatus isEqualToEnum:SDLLockScreenStatusOff]) {
-#pragma clang diagnostic pop
+ } else if (self.lastLockNotification.lockScreenStatus == SDLLockScreenStatusOff) {
[self.presenter updateLockScreenToShow:NO withCompletionHandler:nil];
}
}
diff --git a/SmartDeviceLink/public/SDLOnLockScreenStatus.h b/SmartDeviceLink/private/SDLLockScreenStatusInfo.h
index ce1b2cd62..753a2a1b7 100644
--- a/SmartDeviceLink/public/SDLOnLockScreenStatus.h
+++ b/SmartDeviceLink/private/SDLLockScreenStatusInfo.h
@@ -1,13 +1,12 @@
//
-// SDLOnLockScreenStatus.h
+// SDLLockScreenStatusInfo.h
// SmartDeviceLink
//
#import "SDLRPCNotification.h"
#import "SDLHMILevel.h"
-#import "SDLLockScreenStatus.h"
-
+#import "SDLLockScreenConstants.h"
/**
To help prevent driver distraction, any SmartDeviceLink application is required to implement a lockscreen that must be enforced while the application is active on the system while the vehicle is in motion.
@@ -23,29 +22,29 @@
NS_ASSUME_NONNULL_BEGIN
-__deprecated
-@interface SDLOnLockScreenStatus : SDLRPCNotification
+@interface SDLLockScreenStatusInfo : NSObject
+
+- (instancetype)initWithDriverDistractionStatus:(nullable NSNumber<SDLBool> *)driverDistractionStatus userSelected:(nullable NSNumber<SDLBool> *)userSelected lockScreenStatus:(SDLLockScreenStatus)lockScreenStatus hmiLevel:(nullable SDLHMILevel)hmiLevel;
/**
Get the current driver distraction status(i.e. whether driver distraction rules are in effect, or not)
*/
-@property (strong, nonatomic) NSNumber<SDLBool> *driverDistractionStatus;
+@property (strong, nonatomic, nullable) NSNumber<SDLBool> *driverDistractionStatus;
/**
Get user selection status for the application (has the app been selected via hmi or voice command)
*/
-
-@property (strong, nonatomic) NSNumber<SDLBool> *userSelected;
+@property (strong, nonatomic, nullable) NSNumber<SDLBool> *userSelected;
/**
Indicates if the lockscreen should be required, optional or off
*/
-@property (strong, nonatomic) SDLLockScreenStatus lockScreenStatus;
+@property (assign, nonatomic) SDLLockScreenStatus lockScreenStatus;
/**
Get HMILevel in effect for the application
*/
-@property (strong, nonatomic) SDLHMILevel hmiLevel;
+@property (strong, nonatomic, nullable) SDLHMILevel hmiLevel;
@end
diff --git a/SmartDeviceLink/private/SDLLockScreenStatusInfo.m b/SmartDeviceLink/private/SDLLockScreenStatusInfo.m
new file mode 100644
index 000000000..d7395c11f
--- /dev/null
+++ b/SmartDeviceLink/private/SDLLockScreenStatusInfo.m
@@ -0,0 +1,45 @@
+//
+// SDLLockScreenStatusInfo.m
+// SmartDeviceLink
+//
+
+#import "SDLLockScreenStatusInfo.h"
+
+#import "NSMutableDictionary+Store.h"
+#import "SDLHMILevel.h"
+#import "SDLRPCParameterNames.h"
+#import "SDLRPCFunctionNames.h"
+
+NS_ASSUME_NONNULL_BEGIN
+
+@implementation SDLLockScreenStatusInfo
+
+- (instancetype)init {
+ self = [super init];
+ if (!self) { return nil; }
+
+ _lockScreenStatus = SDLLockScreenStatusOff;
+
+ return self;
+}
+
+- (instancetype)initWithDriverDistractionStatus:(nullable NSNumber<SDLBool> *)driverDistractionStatus userSelected:(nullable NSNumber<SDLBool> *)userSelected lockScreenStatus:(SDLLockScreenStatus)lockScreenStatus hmiLevel:(nullable SDLHMILevel)hmiLevel {
+ self = [self init];
+ if (!self) {
+ return nil;
+ }
+ _driverDistractionStatus = driverDistractionStatus;
+ _userSelected = userSelected;
+ _lockScreenStatus = lockScreenStatus;
+ _hmiLevel = hmiLevel;
+
+ return self;
+}
+
+- (NSString *)description {
+ return [NSString stringWithFormat:@"driverDistractionStatus: %@, userSelected: %@, lockScreenStatus: %lu, hmiLevel: %@", self.driverDistractionStatus, self.userSelected, (unsigned long)self.lockScreenStatus, self.hmiLevel];
+}
+
+@end
+
+NS_ASSUME_NONNULL_END
diff --git a/SmartDeviceLink/private/SDLLockScreenStatusManager.h b/SmartDeviceLink/private/SDLLockScreenStatusManager.h
index 4230f6d2a..fd8cff605 100644
--- a/SmartDeviceLink/private/SDLLockScreenStatusManager.h
+++ b/SmartDeviceLink/private/SDLLockScreenStatusManager.h
@@ -6,23 +6,23 @@
#import <Foundation/Foundation.h>
#import "SDLHMILevel.h"
-#import "SDLLockScreenStatus.h"
+#import "SDLLockScreenConstants.h"
@class SDLNotificationDispatcher;
-@class SDLOnLockScreenStatus;
+@class SDLLockScreenStatusInfo;
NS_ASSUME_NONNULL_BEGIN
+static NSString *const SDLDidChangeLockScreenStatusNotification = @"com.sdl.notification.lockScreenStatus";
+
+
@interface SDLLockScreenStatusManager : NSObject
@property (assign, nonatomic) BOOL userSelected;
@property (assign, nonatomic) BOOL driverDistracted;
@property (nullable, strong, nonatomic) SDLHMILevel hmiLevel;
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
-@property (strong, nonatomic, readonly) SDLLockScreenStatus lockScreenStatus;
-@property (strong, nonatomic, readonly) SDLOnLockScreenStatus *lockScreenStatusNotification;
-#pragma clang diagnostic pop
+@property (assign, nonatomic, readonly) SDLLockScreenStatus lockScreenStatus;
+@property (strong, nonatomic, readonly) SDLLockScreenStatusInfo *lockScreenStatusNotification;
- (instancetype)init NS_UNAVAILABLE;
- (instancetype)initWithNotificationDispatcher:(SDLNotificationDispatcher *)dispatcher;
diff --git a/SmartDeviceLink/private/SDLLockScreenStatusManager.m b/SmartDeviceLink/private/SDLLockScreenStatusManager.m
index e661abd80..3b15b60ff 100644
--- a/SmartDeviceLink/private/SDLLockScreenStatusManager.m
+++ b/SmartDeviceLink/private/SDLLockScreenStatusManager.m
@@ -5,13 +5,12 @@
#import "SDLLockScreenStatusManager.h"
-#import "SDLLockScreenStatus.h"
#import "SDLLogMacros.h"
#import "SDLNotificationConstants.h"
#import "SDLNotificationDispatcher.h"
#import "SDLOnDriverDistraction.h"
#import "SDLOnHMIStatus.h"
-#import "SDLOnLockScreenStatus.h"
+#import "SDLLockScreenStatusInfo.h"
#import "SDLRPCNotificationNotification.h"
NS_ASSUME_NONNULL_BEGIN
@@ -19,6 +18,7 @@ NS_ASSUME_NONNULL_BEGIN
@interface SDLLockScreenStatusManager ()
@property (assign, nonatomic) BOOL haveDriverDistractionStatus;
+@property (weak, nonatomic) SDLNotificationDispatcher *notificationDispatcher;
@end
@@ -34,6 +34,7 @@ NS_ASSUME_NONNULL_BEGIN
_userSelected = NO;
_driverDistracted = NO;
_haveDriverDistractionStatus = NO;
+ _notificationDispatcher = dispatcher;
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(sdl_hmiStatusDidUpdate:) name:SDLDidChangeHMIStatusNotification object:dispatcher];
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(sdl_driverDistractionDidUpdate:) name:SDLDidChangeDriverDistractionStateNotification object:dispatcher];
@@ -65,89 +66,52 @@ NS_ASSUME_NONNULL_BEGIN
#pragma mark Custom Getters
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
-- (SDLOnLockScreenStatus *)lockScreenStatusNotification {
- SDLOnLockScreenStatus *notification = [[SDLOnLockScreenStatus alloc] init];
-#pragma clang diagnostic pop
- notification.driverDistractionStatus = @(self.driverDistracted);
- notification.hmiLevel = self.hmiLevel;
- notification.userSelected = @(self.userSelected);
- notification.lockScreenStatus = self.lockScreenStatus;
-
+- (SDLLockScreenStatusInfo *)lockScreenStatusNotification {
+ SDLLockScreenStatusInfo *notification = [[SDLLockScreenStatusInfo alloc] initWithDriverDistractionStatus:@(self.driverDistracted) userSelected:@(self.userSelected) lockScreenStatus:self.lockScreenStatus hmiLevel:self.hmiLevel];
return notification;
}
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- (SDLLockScreenStatus)lockScreenStatus {
-#pragma clang diagnostic pop
if (self.hmiLevel == nil || [self.hmiLevel isEqualToEnum:SDLHMILevelNone]) {
// App is not active on the car
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
return SDLLockScreenStatusOff;
-#pragma clang diagnostic pop
} else if ([self.hmiLevel isEqualToEnum:SDLHMILevelBackground]) {
// App is in the background on the car
if (self.userSelected) {
// It was user selected
if (self.haveDriverDistractionStatus && !self.driverDistracted) {
// We have the distraction status, and the driver is not distracted
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
return SDLLockScreenStatusOptional;
-#pragma clang diagnostic pop
} else {
// We don't have the distraction status, and/or the driver is distracted
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
return SDLLockScreenStatusRequired;
-#pragma clang diagnostic pop
}
} else {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
return SDLLockScreenStatusOff;
-#pragma clang diagnostic pop
}
} else if ([self.hmiLevel isEqualToEnum:SDLHMILevelFull] || [self.hmiLevel isEqualToEnum:SDLHMILevelLimited]) {
// App is in the foreground on the car in some manner
if (self.haveDriverDistractionStatus && !self.driverDistracted) {
// We have the distraction status, and the driver is not distracted
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
return SDLLockScreenStatusOptional;
-#pragma clang diagnostic pop
} else {
// We don't have the distraction status, and/or the driver is distracted
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
return SDLLockScreenStatusRequired;
-#pragma clang diagnostic pop
}
} else {
// This shouldn't be possible.
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
return SDLLockScreenStatusOff;
-#pragma clang diagnostic pop
}
}
#pragma mark - Utilities
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
-- (void)sdl_postLockScreenStatus:(SDLOnLockScreenStatus *)statusNotification {
- SDLRPCNotificationNotification *notification = [[SDLRPCNotificationNotification alloc] initWithName:SDLDidChangeLockScreenStatusNotification object:self rpcNotification:statusNotification];
-#pragma clang diagnostic pop
+- (void)sdl_postLockScreenStatus:(SDLLockScreenStatusInfo *)statusNotification {
+ SDLLogD(@"Lock screen status changed: %@", statusNotification);
- SDLLogD(@"Lock screen status changed. Sending new notification: %@", notification);
- [[NSNotificationCenter defaultCenter] postNotification:notification];
+ [self.notificationDispatcher postNotificationName:SDLDidChangeLockScreenStatusNotification infoObject:statusNotification];
}
-
#pragma mark - Observers
- (void)sdl_hmiStatusDidUpdate:(SDLRPCNotificationNotification *)notification {
diff --git a/SmartDeviceLink/private/SDLMenuManager.m b/SmartDeviceLink/private/SDLMenuManager.m
index 8cef8caef..af91dc3a1 100644
--- a/SmartDeviceLink/private/SDLMenuManager.m
+++ b/SmartDeviceLink/private/SDLMenuManager.m
@@ -527,7 +527,6 @@ UInt32 const MenuCellIdMin = 1;
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
return ![self.systemCapabilityManager.displays.firstObject.displayName isEqualToString:SDLDisplayTypeGen38Inch];
#pragma clang diagnostic pop
-
}
}
diff --git a/SmartDeviceLink/private/SDLPermissionFilter.h b/SmartDeviceLink/private/SDLPermissionFilter.h
index e733d2331..71437d2b7 100644
--- a/SmartDeviceLink/private/SDLPermissionFilter.h
+++ b/SmartDeviceLink/private/SDLPermissionFilter.h
@@ -27,11 +27,6 @@ NS_ASSUME_NONNULL_BEGIN
@property (assign, nonatomic, readonly) SDLPermissionGroupType groupType;
/**
- * The block that will be called on status changes to this filter group.
- */
-@property (copy, nonatomic, readonly) SDLPermissionsChangedHandler handler;
-
-/**
* The block that will be called on status changes to RPC permission status objects
*/
@property (copy, nonatomic, readonly) SDLRPCPermissionStatusChangedHandler rpcPermissionStatusHandler;
@@ -45,18 +40,7 @@ NS_ASSUME_NONNULL_BEGIN
- (instancetype)init NS_UNAVAILABLE;
/**
- * Create a new permission filter group with a SDLPermissionsChangedHandler.
- *
- * @param rpcNames The names of the RPCs to watch permissions of.
- * @param groupType The type of notifications to be sent for this filter group.
- * @param handler The block observer to be called when changes occur.
- *
- * @return An instance of `SDLPermissionFilter`.
- */
-- (instancetype)initWithPermissions:(NSArray<SDLPermissionElement *> *)rpcNames groupType:(SDLPermissionGroupType)groupType permissionsHandler:(SDLPermissionsChangedHandler)handler;
-
-/**
- * Create a new permission filter group with a SDLRPCPermissionStatusChangedHandler.
+ * Create a new permission filter group.
*
* @param rpcNames The names of the RPCs to watch permissions of.
* @param groupType The type of notifications to be sent for this filter group.
@@ -76,13 +60,13 @@ NS_ASSUME_NONNULL_BEGIN
- (BOOL)isEqualToFilter:(SDLPermissionFilter *)otherFilter;
/**
- * Converts an array of SDLPermissionElement objects to an array of SDLPermissionRPCName objects
+ * Gets all the RPC names from an array of SDLPermissionElements
*
* @param permissionElements The permission elements to convert.
*
- * @return An array of SDLPermissionRPCName objects
+ * @return An array of RPC names
*/
-- (NSArray<SDLPermissionRPCName> *)rpcNamesFromPermissionElements:(NSArray<SDLPermissionElement *> *)permissionElements;
+- (NSArray<SDLRPCFunctionName> *)rpcNamesFromPermissionElements:(NSArray<SDLPermissionElement *> *)permissionElements;
@end
diff --git a/SmartDeviceLink/private/SDLPermissionFilter.m b/SmartDeviceLink/private/SDLPermissionFilter.m
index c2ed47a3e..11ee06c3e 100644
--- a/SmartDeviceLink/private/SDLPermissionFilter.m
+++ b/SmartDeviceLink/private/SDLPermissionFilter.m
@@ -15,20 +15,6 @@ NS_ASSUME_NONNULL_BEGIN
#pragma mark - Lifecycle
-- (instancetype)initWithPermissions:(NSArray<SDLPermissionElement *> *)rpcNames groupType:(SDLPermissionGroupType)groupType permissionsHandler:(SDLPermissionsChangedHandler)observer {
- self = [super init];
- if (!self) {
- return nil;
- }
-
- _identifier = [NSUUID UUID];
- _permissionElements = rpcNames;
- _groupType = groupType;
- _handler = observer;
-
- return self;
-}
-
- (instancetype)initWithPermissions:(NSArray<SDLPermissionElement *> *)rpcNames groupType:(SDLPermissionGroupType)groupType permissionStatusHandler:(SDLRPCPermissionStatusChangedHandler)permissionStatusHandler {
self = [super init];
if (!self) { return nil; }
@@ -43,7 +29,7 @@ NS_ASSUME_NONNULL_BEGIN
#pragma mark - Helpers
-- (NSArray<SDLPermissionRPCName> *)rpcNamesFromPermissionElements:(NSArray<SDLPermissionElement *> *)permissionElements {
+- (NSArray<SDLRPCFunctionName> *)rpcNamesFromPermissionElements:(NSArray<SDLPermissionElement *> *)permissionElements {
NSMutableArray *rpcNames = [[NSMutableArray alloc] init];
for (SDLPermissionElement *element in permissionElements) {
[rpcNames addObject:element.rpcName];
@@ -56,9 +42,8 @@ NS_ASSUME_NONNULL_BEGIN
#pragma mark - NSCopying
- (id)copyWithZone:(nullable NSZone *)zone {
- SDLPermissionFilter *newFilter = [[self.class allocWithZone:zone] initWithPermissions:[_permissionElements copyWithZone:zone] groupType:_groupType permissionsHandler:[_handler copyWithZone:zone]];
+ SDLPermissionFilter *newFilter = [[self.class allocWithZone:zone] initWithPermissions:[_permissionElements copyWithZone:zone] groupType:_groupType permissionStatusHandler:[_rpcPermissionStatusHandler copyWithZone:zone]];
newFilter->_identifier = _identifier;
- newFilter->_rpcPermissionStatusHandler = _rpcPermissionStatusHandler;
return newFilter;
}
diff --git a/SmartDeviceLink/private/SDLPresentChoiceSetOperation.m b/SmartDeviceLink/private/SDLPresentChoiceSetOperation.m
index 3787fb996..0788b0b97 100644
--- a/SmartDeviceLink/private/SDLPresentChoiceSetOperation.m
+++ b/SmartDeviceLink/private/SDLPresentChoiceSetOperation.m
@@ -281,14 +281,6 @@ NS_ASSUME_NONNULL_BEGIN
weakself.keyboardProperties.autoCompleteText = (newList.count > 0) ? newList.firstObject : nil;
[weakself sdl_updateKeyboardPropertiesWithCompletionHandler:nil];
}];
- } else if ([self.keyboardDelegate respondsToSelector:@selector(updateAutocompleteWithInput:completionHandler:)]) {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- [self.keyboardDelegate updateAutocompleteWithInput:onKeyboard.data completionHandler:^(NSString * _Nullable updatedAutocompleteText) {
- weakself.keyboardProperties.autoCompleteText = updatedAutocompleteText;
- [weakself sdl_updateKeyboardPropertiesWithCompletionHandler:nil];
- }];
-#pragma clang diagnostic pop
}
if ([self.keyboardDelegate respondsToSelector:@selector(updateCharacterSetWithInput:completionHandler:)]) {
diff --git a/SmartDeviceLink/private/SDLPresentKeyboardOperation.m b/SmartDeviceLink/private/SDLPresentKeyboardOperation.m
index 27d865ea5..633ccfba6 100644
--- a/SmartDeviceLink/private/SDLPresentKeyboardOperation.m
+++ b/SmartDeviceLink/private/SDLPresentKeyboardOperation.m
@@ -195,14 +195,6 @@ NS_ASSUME_NONNULL_BEGIN
weakself.keyboardProperties.autoCompleteText = (newList.count > 0) ? newList.firstObject : nil;
[weakself sdl_updateKeyboardPropertiesWithCompletionHandler:nil];
}];
- } else if ([self.keyboardDelegate respondsToSelector:@selector(updateAutocompleteWithInput:completionHandler:)]) {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- [self.keyboardDelegate updateAutocompleteWithInput:onKeyboard.data completionHandler:^(NSString * _Nullable updatedAutocompleteText) {
- weakself.keyboardProperties.autoCompleteText = updatedAutocompleteText;
- [weakself sdl_updateKeyboardPropertiesWithCompletionHandler:nil];
- }];
-#pragma clang diagnostic pop
}
if ([self.keyboardDelegate respondsToSelector:@selector(updateCharacterSetWithInput:completionHandler:)]) {
diff --git a/SmartDeviceLink/private/SDLProtocol.m b/SmartDeviceLink/private/SDLProtocol.m
index ad660eb79..a76e6a24d 100644
--- a/SmartDeviceLink/private/SDLProtocol.m
+++ b/SmartDeviceLink/private/SDLProtocol.m
@@ -527,6 +527,20 @@ NS_ASSUME_NONNULL_BEGIN
// TODO: Hash id?
} break;
+ case SDLServiceTypeAudio: {
+ SDLControlFramePayloadRPCStartServiceAck *startServiceACKPayload = [[SDLControlFramePayloadRPCStartServiceAck alloc] initWithData:startServiceACK.payload];
+
+ if (startServiceACKPayload.mtu != SDLControlFrameInt64NotFound) {
+ [[SDLGlobals sharedGlobals] setDynamicMTUSize:(NSUInteger)startServiceACKPayload.mtu forServiceType:SDLServiceTypeAudio];
+ }
+ } break;
+ case SDLServiceTypeVideo: {
+ SDLControlFramePayloadRPCStartServiceAck *startServiceACKPayload = [[SDLControlFramePayloadRPCStartServiceAck alloc] initWithData:startServiceACK.payload];
+
+ if (startServiceACKPayload.mtu != SDLControlFrameInt64NotFound) {
+ [[SDLGlobals sharedGlobals] setDynamicMTUSize:(NSUInteger)startServiceACKPayload.mtu forServiceType:SDLServiceTypeVideo];
+ }
+ } break;
default:
break;
}
diff --git a/SmartDeviceLink/private/SDLRPCParameterNames.h b/SmartDeviceLink/private/SDLRPCParameterNames.h
index 8813ec0c2..7222039de 100644
--- a/SmartDeviceLink/private/SDLRPCParameterNames.h
+++ b/SmartDeviceLink/private/SDLRPCParameterNames.h
@@ -32,11 +32,10 @@
// SDLRPCParameterNames.h
#import <Foundation/Foundation.h>
-#import "SDLMacros.h"
NS_ASSUME_NONNULL_BEGIN
-typedef NSString* SDLRPCParameterName SDL_SWIFT_ENUM;
+typedef NSString* SDLRPCParameterName NS_TYPED_ENUM;
extern SDLRPCParameterName const SDLRPCParameterNameACEnable;
extern SDLRPCParameterName const SDLRPCParameterNameACEnableAvailable;
diff --git a/SmartDeviceLink/private/SDLResponseDispatcher.m b/SmartDeviceLink/private/SDLResponseDispatcher.m
index 5408ba9ed..56ed29832 100644
--- a/SmartDeviceLink/private/SDLResponseDispatcher.m
+++ b/SmartDeviceLink/private/SDLResponseDispatcher.m
@@ -64,13 +64,7 @@ NS_ASSUME_NONNULL_BEGIN
if (!self) {
return nil;
}
-
- if (@available(iOS 10.0, *)) {
- _readWriteQueue = dispatch_queue_create_with_target("com.sdl.lifecycle.responseDispatcher", DISPATCH_QUEUE_SERIAL, [SDLGlobals sharedGlobals].sdlProcessingQueue);
- } else {
- _readWriteQueue = [SDLGlobals sharedGlobals].sdlProcessingQueue;
- }
-
+ _readWriteQueue = dispatch_queue_create_with_target("com.sdl.lifecycle.responseDispatcher", DISPATCH_QUEUE_SERIAL, [SDLGlobals sharedGlobals].sdlProcessingQueue);
_rpcResponseHandlerMap = [NSMapTable mapTableWithKeyOptions:NSMapTableCopyIn valueOptions:NSMapTableCopyIn];
_rpcRequestDictionary = [NSMutableDictionary dictionary];
_commandHandlerMap = [NSMapTable mapTableWithKeyOptions:NSMapTableCopyIn valueOptions:NSMapTableCopyIn];
diff --git a/SmartDeviceLink/private/SDLStreamingAudioLifecycleManager.m b/SmartDeviceLink/private/SDLStreamingAudioLifecycleManager.m
index af806d779..5e77bb305 100644
--- a/SmartDeviceLink/private/SDLStreamingAudioLifecycleManager.m
+++ b/SmartDeviceLink/private/SDLStreamingAudioLifecycleManager.m
@@ -64,12 +64,6 @@ NS_ASSUME_NONNULL_BEGIN
_requestedEncryptionType = configuration.streamingMediaConfig.maximumDesiredEncryption;
NSMutableArray<NSString *> *tempMakeArray = [NSMutableArray array];
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- for (Class securityManagerClass in configuration.streamingMediaConfig.securityManagers) {
- [tempMakeArray addObjectsFromArray:[securityManagerClass availableMakes].allObjects];
- }
-#pragma clang diagnostic pop
for (Class securityManagerClass in configuration.encryptionConfig.securityManagers) {
[tempMakeArray addObjectsFromArray:[securityManagerClass availableMakes].allObjects];
}
@@ -201,10 +195,6 @@ NS_ASSUME_NONNULL_BEGIN
SDLControlFramePayloadAudioStartServiceAck *audioAckPayload = [[SDLControlFramePayloadAudioStartServiceAck alloc] initWithData:startServiceACK.payload];
SDLLogD(@"Request to start audio service ACKed on transport %@, with payload: %@", protocol.transport, audioAckPayload);
- if (audioAckPayload.mtu != SDLControlFrameInt64NotFound) {
- [[SDLGlobals sharedGlobals] setDynamicMTUSize:(NSUInteger)audioAckPayload.mtu forServiceType:SDLServiceTypeAudio];
- }
-
[self.audioStreamStateMachine transitionToState:SDLAudioStreamManagerStateReady];
}
diff --git a/SmartDeviceLink/private/SDLStreamingVideoLifecycleManager.m b/SmartDeviceLink/private/SDLStreamingVideoLifecycleManager.m
index b5f75cf32..5d1236a98 100644
--- a/SmartDeviceLink/private/SDLStreamingVideoLifecycleManager.m
+++ b/SmartDeviceLink/private/SDLStreamingVideoLifecycleManager.m
@@ -116,10 +116,8 @@ typedef void(^SDLVideoCapabilityResponseHandler)(SDLVideoStreamingCapability *_N
if (configuration.streamingMediaConfig.rootViewController != nil) {
NSAssert(configuration.streamingMediaConfig.enableForcedFramerateSync, @"When using CarWindow (rootViewController != nil), forceFrameRateSync must be YES");
- if (@available(iOS 9.0, *)) {
- SDLLogD(@"Initializing focusable item locator");
- _focusableItemManager = [[SDLFocusableItemLocator alloc] initWithViewController:configuration.streamingMediaConfig.rootViewController connectionManager:_connectionManager videoScaleManager:_videoScaleManager];
- }
+ SDLLogD(@"Initializing focusable item locator");
+ _focusableItemManager = [[SDLFocusableItemLocator alloc] initWithViewController:configuration.streamingMediaConfig.rootViewController connectionManager:_connectionManager videoScaleManager:_videoScaleManager];
SDLLogD(@"Initializing CarWindow");
_carWindow = [[SDLCarWindow alloc] initWithStreamManager:self configuration:configuration.streamingMediaConfig];
@@ -140,12 +138,6 @@ typedef void(^SDLVideoCapabilityResponseHandler)(SDLVideoStreamingCapability *_N
_videoStreamingState = SDLVideoStreamingStateNotStreamable;
NSMutableArray<NSString *> *tempMakeArray = [NSMutableArray array];
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- for (Class securityManagerClass in configuration.streamingMediaConfig.securityManagers) {
- [tempMakeArray addObjectsFromArray:[securityManagerClass availableMakes].allObjects];
- }
-#pragma clang diagnostic pop
for (Class securityManagerClass in configuration.encryptionConfig.securityManagers) {
[tempMakeArray addObjectsFromArray:[securityManagerClass availableMakes].allObjects];
}
@@ -486,11 +478,7 @@ typedef void(^SDLVideoCapabilityResponseHandler)(SDLVideoStreamingCapability *_N
NSInteger targetFramerate = ((NSNumber *)strongSelf.videoEncoderSettings[(__bridge NSString *)kVTCompressionPropertyKey_ExpectedFrameRate]).integerValue;
SDLLogD(@"Initializing CADisplayLink with framerate: %ld", (long)targetFramerate);
strongSelf.displayLink = [CADisplayLink displayLinkWithTarget:strongSelf selector:@selector(sdl_displayLinkFired:)];
- if (@available(iOS 10, *)) {
- strongSelf.displayLink.preferredFramesPerSecond = targetFramerate;
- } else {
- strongSelf.displayLink.frameInterval = (60 / targetFramerate);
- }
+ strongSelf.displayLink.preferredFramesPerSecond = targetFramerate;
[strongSelf.displayLink addToRunLoop:[NSRunLoop currentRunLoop] forMode:NSRunLoopCommonModes];
});
} else {
@@ -520,10 +508,6 @@ typedef void(^SDLVideoCapabilityResponseHandler)(SDLVideoStreamingCapability *_N
SDLControlFramePayloadVideoStartServiceAck *videoAckPayload = [[SDLControlFramePayloadVideoStartServiceAck alloc] initWithData:startServiceACK.payload];
SDLLogD(@"Request to start video service ACKed on transport %@, with payload: %@", protocol.transport, videoAckPayload);
- if (videoAckPayload.mtu != SDLControlFrameInt64NotFound) {
- [[SDLGlobals sharedGlobals] setDynamicMTUSize:(NSUInteger)videoAckPayload.mtu forServiceType:SDLServiceTypeVideo];
- }
-
// This is the definitive screen size that will be used
if ((videoAckPayload.height != SDLControlFrameInt32NotFound || videoAckPayload.height != 0) && (videoAckPayload.width != SDLControlFrameInt32NotFound && videoAckPayload.width != 0)) {
self.videoScaleManager.displayViewportResolution = CGSizeMake(videoAckPayload.width, videoAckPayload.height);
@@ -721,11 +705,8 @@ typedef void(^SDLVideoCapabilityResponseHandler)(SDLVideoStreamingCapability *_N
- (void)sdl_displayLinkFired:(CADisplayLink *)displayLink {
NSAssert([NSThread isMainThread], @"Display link should always fire on the main thread");
- if (@available(iOS 10.0, *)) {
- SDLLogV(@"DisplayLink frame fired, duration: %f, last frame timestamp: %f, target timestamp: %f", displayLink.duration, displayLink.timestamp, displayLink.targetTimestamp);
- } else {
- SDLLogV(@"DisplayLink frame fired, duration: %f, last frame timestamp: %f, target timestamp: (not available)", displayLink.duration, displayLink.timestamp);
- }
+
+ SDLLogV(@"DisplayLink frame fired, duration: %f, last frame timestamp: %f, target timestamp: %f", displayLink.duration, displayLink.timestamp, displayLink.targetTimestamp);
[self.touchManager syncFrame];
[self.carWindow syncFrame];
diff --git a/SmartDeviceLink/private/SDLSubscribeButtonManager.m b/SmartDeviceLink/private/SDLSubscribeButtonManager.m
index f311291c5..5492b2362 100644
--- a/SmartDeviceLink/private/SDLSubscribeButtonManager.m
+++ b/SmartDeviceLink/private/SDLSubscribeButtonManager.m
@@ -43,11 +43,7 @@ NS_ASSUME_NONNULL_BEGIN
self = [super init];
if (!self) { return nil; }
- if (@available(iOS 10.0, *)) {
- _readWriteQueue = dispatch_queue_create_with_target("com.sdl.subscribeButtonManager.readWriteQueue", DISPATCH_QUEUE_SERIAL, [SDLGlobals sharedGlobals].sdlProcessingQueue);
- } else {
- _readWriteQueue = [SDLGlobals sharedGlobals].sdlProcessingQueue;
- }
+ _readWriteQueue = dispatch_queue_create_with_target("com.sdl.subscribeButtonManager.readWriteQueue", DISPATCH_QUEUE_SERIAL, [SDLGlobals sharedGlobals].sdlProcessingQueue);
_connectionManager = connectionManager;
_subscribeButtonObservers = [NSMutableDictionary dictionary];
diff --git a/SmartDeviceLink/private/SDLSystemCapabilityObserver.h b/SmartDeviceLink/private/SDLSystemCapabilityObserver.h
index 11a6acfc1..0e08c028e 100644
--- a/SmartDeviceLink/private/SDLSystemCapabilityObserver.h
+++ b/SmartDeviceLink/private/SDLSystemCapabilityObserver.h
@@ -33,11 +33,6 @@ typedef void (^SDLCapabilityUpdateWithErrorHandler)(SDLSystemCapability *_Nullab
*/
@property (assign, nonatomic) SEL selector;
-/**
- A block called when the observer is triggered
- */
-@property (copy, nonatomic) SDLCapabilityUpdateHandler block __deprecated_msg("use updateBlock instead");
-
/// A block called when the observer is triggered
@property (copy, nonatomic) SDLCapabilityUpdateWithErrorHandler updateBlock;
@@ -50,15 +45,6 @@ typedef void (^SDLCapabilityUpdateWithErrorHandler)(SDLSystemCapability *_Nullab
*/
- (instancetype)initWithObserver:(id<NSObject>)observer selector:(SEL)selector;
-/**
- Create an observer using an object and a callback block
-
- @param observer The object that can be used to unsubscribe the block
- @param block The block that will be called when the subscription triggers
- @return The observer
- */
-- (instancetype)initWithObserver:(id<NSObject>)observer block:(SDLCapabilityUpdateHandler)block __deprecated_msg("use initWithObserver:updateHandler: instead");
-
/// Create an observer using an object and a callback block
/// @param observer The object that can be used to unsubscribe the block
diff --git a/SmartDeviceLink/private/SDLSystemCapabilityObserver.m b/SmartDeviceLink/private/SDLSystemCapabilityObserver.m
index 7b6ef0b0e..f4bd3eb7a 100644
--- a/SmartDeviceLink/private/SDLSystemCapabilityObserver.m
+++ b/SmartDeviceLink/private/SDLSystemCapabilityObserver.m
@@ -22,16 +22,6 @@ NS_ASSUME_NONNULL_BEGIN
return self;
}
-- (instancetype)initWithObserver:(id<NSObject>)observer block:(SDLCapabilityUpdateHandler)block {
- self = [super init];
- if (!self) { return nil; }
-
- _observer = observer;
- _block = block;
-
- return self;
-}
-
- (instancetype)initWithObserver:(id<NSObject>)observer updateHandler:(SDLCapabilityUpdateWithErrorHandler)block {
self = [super init];
if (!self) { return nil; }
diff --git a/SmartDeviceLink/public/SDLAddCommand.h b/SmartDeviceLink/public/SDLAddCommand.h
index 8265395f5..ea5968970 100644
--- a/SmartDeviceLink/public/SDLAddCommand.h
+++ b/SmartDeviceLink/public/SDLAddCommand.h
@@ -74,23 +74,6 @@ NS_ASSUME_NONNULL_BEGIN
* @param position The menu item's row number in the menu.
* @param iconValue The unique name used to upload the image to Core.
* @param iconType Whether the image is static or dynamic.
- * @param handler Called when the menu item is selected and/or when the VR system recognizes a phrase in `vrCommands`
- * @return A SDLAddCommand object
- */
-- (instancetype)initWithId:(UInt32)commandId vrCommands:(nullable NSArray<NSString *> *)vrCommands menuName:(NSString *)menuName parentId:(UInt32)parentId position:(UInt16)position iconValue:(nullable NSString *)iconValue iconType:(nullable SDLImageType)iconType handler:(nullable SDLRPCCommandNotificationHandler)handler __deprecated_msg("Use initWithId:vrCommands:menuName:parentId:position:iconValue:iconType:iconIsTemplate:handler: instead");
-
-/**
- * Convenience init for creating a menu item with text and a custom icon.
- *
- * @warning The icon must be uploaded to Core before being displayed in the menu.
- *
- * @param commandId A unique id for the menu item.
- * @param vrCommands One or more voice recognition phrases. If recognized by the VR system, the handler will be called.
- * @param menuName The text that will appear in the menu.
- * @param parentId The command id of the parent menu if menu item is in a submenu. If not in a submenu, the parentId is 0.
- * @param position The menu item's row number in the menu.
- * @param iconValue The unique name used to upload the image to Core.
- * @param iconType Whether the image is static or dynamic.
* @param iconIsTemplate Whether or not the image is a template that can be (re)colored by the SDL HMI
* @param handler Called when the menu item is selected and/or when the VR system recognizes a phrase in `vrCommands`
* @return A SDLAddCommand object
diff --git a/SmartDeviceLink/public/SDLAddCommand.m b/SmartDeviceLink/public/SDLAddCommand.m
index 0613f3193..83da5658f 100644
--- a/SmartDeviceLink/public/SDLAddCommand.m
+++ b/SmartDeviceLink/public/SDLAddCommand.m
@@ -58,22 +58,6 @@ NS_ASSUME_NONNULL_BEGIN
return self;
}
-- (instancetype)initWithId:(UInt32)commandId vrCommands:(nullable NSArray<NSString *> *)vrCommands menuName:(NSString *)menuName parentId:(UInt32)parentId position:(UInt16)position iconValue:(nullable NSString *)iconValue iconType:(nullable SDLImageType)iconType handler:(nullable SDLRPCCommandNotificationHandler)handler {
- self = [self initWithId:commandId vrCommands:vrCommands menuName:menuName handler:handler];
- if (!self) {
- return nil;
- }
-
- self.menuParams.parentID = @(parentId);
- self.menuParams.position = @(position);
-
- if (iconValue != nil && iconType != nil) {
- self.cmdIcon = [[SDLImage alloc] initWithName:iconValue ofType:iconType isTemplate:NO];
- }
-
- return self;
-}
-
- (instancetype)initWithId:(UInt32)commandId vrCommands:(nullable NSArray<NSString *> *)vrCommands menuName:(NSString *)menuName parentId:(UInt32)parentId position:(UInt16)position iconValue:(nullable NSString *)iconValue iconType:(nullable SDLImageType)iconType iconIsTemplate:(BOOL)iconIsTemplate handler:(nullable SDLRPCCommandNotificationHandler)handler {
self = [self initWithId:commandId vrCommands:vrCommands menuName:menuName handler:handler];
if (!self) {
diff --git a/SmartDeviceLink/public/SDLAddSubMenu.h b/SmartDeviceLink/public/SDLAddSubMenu.h
index fbd8d872c..2de2f466d 100644
--- a/SmartDeviceLink/public/SDLAddSubMenu.h
+++ b/SmartDeviceLink/public/SDLAddSubMenu.h
@@ -73,40 +73,6 @@ NS_ASSUME_NONNULL_BEGIN
*/
- (instancetype)initWithMenuID:(UInt32)menuID menuName:(NSString *)menuName position:(nullable NSNumber<SDLUInt> *)position menuIcon:(nullable SDLImage *)menuIcon menuLayout:(nullable SDLMenuLayout)menuLayout parentID:(nullable NSNumber<SDLUInt> *)parentID;
-/// Convenience init for creating an add submenu
-///
-/// @param menuId A menu id
-/// @param menuName The menu name
-/// @return An SDLAddSubMenu object
-- (instancetype)initWithId:(UInt32)menuId menuName:(NSString *)menuName __deprecated_msg("Use initWithMenuID:menuName: instead");
-
-/// Convenience init for creating an add submenu
-///
-/// @param menuId A menu id
-/// @param menuName The menu name
-/// @param position The position within the menu to add
-/// @return An SDLAddSubMenu object
-- (instancetype)initWithId:(UInt32)menuId menuName:(NSString *)menuName position:(UInt8)position __deprecated_msg("Use initWithMenuID:menuName:position:menuIcon:menuLayout:parentID: instead");
-
-/// Convenience init for creating an add submenu
-///
-/// @param menuId A menu id
-/// @param menuName The menu name
-/// @param icon The icon to show on the menu item
-/// @param position The position within the menu to add
-/// @return An SDLAddSubMenu object
-- (instancetype)initWithId:(UInt32)menuId menuName:(NSString *)menuName menuIcon:(nullable SDLImage *)icon position:(UInt8)position __deprecated_msg("Use initWithMenuID:menuName:position:menuIcon:menuLayout:parentID: instead");
-
-/// Convenience init for creating an add submenu with all properties.
-///
-/// @param menuId A menu id
-/// @param menuName The menu name
-/// @param menuLayout The sub-menu layout
-/// @param icon The icon to show on the menu item
-/// @param position The position within the menu to add
-/// @return An SDLAddSubMenu object
-- (instancetype)initWithId:(UInt32)menuId menuName:(NSString *)menuName menuLayout:(nullable SDLMenuLayout)menuLayout menuIcon:(nullable SDLImage *)icon position:(UInt8)position __deprecated_msg("Use initWithMenuID:menuName:position:menuIcon:menuLayout:parentID: instead");
-
/**
* a Menu ID that identifies a sub menu
* @discussion This value is used in
diff --git a/SmartDeviceLink/public/SDLAddSubMenu.m b/SmartDeviceLink/public/SDLAddSubMenu.m
index 3e0b0bdd0..06a615df1 100644
--- a/SmartDeviceLink/public/SDLAddSubMenu.m
+++ b/SmartDeviceLink/public/SDLAddSubMenu.m
@@ -50,37 +50,6 @@ NS_ASSUME_NONNULL_BEGIN
}
#pragma clang diagnostic pop
-- (instancetype)initWithId:(UInt32)menuId menuName:(NSString *)menuName {
- self = [self init];
- if (!self) {
- return nil;
- }
-
- self.menuID = @(menuId);
- self.menuName = menuName;
-
- return self;
-}
-
-- (instancetype)initWithId:(UInt32)menuId menuName:(NSString *)menuName position:(UInt8)position {
- return [self initWithId:menuId menuName:menuName menuLayout:nil menuIcon:nil position:position];
-}
-
-- (instancetype)initWithId:(UInt32)menuId menuName:(NSString *)menuName menuIcon:(nullable SDLImage *)icon position:(UInt8)position {
- return [self initWithId:menuId menuName:menuName menuLayout:nil menuIcon:icon position:position];
-}
-
-- (instancetype)initWithId:(UInt32)menuId menuName:(NSString *)menuName menuLayout:(nullable SDLMenuLayout)menuLayout menuIcon:(nullable SDLImage *)icon position:(UInt8)position {
- self = [self initWithId:menuId menuName:menuName];
- if (!self) { return nil; }
-
- self.position = @(position);
- self.menuIcon = icon;
- self.menuLayout = menuLayout;
-
- return self;
-}
-
- (instancetype)initWithMenuID:(UInt32)menuID menuName:(NSString *)menuName {
self = [self init];
if (!self) {
diff --git a/SmartDeviceLink/public/SDLAlert.h b/SmartDeviceLink/public/SDLAlert.h
index 6a9a25e57..f18ea0c10 100644
--- a/SmartDeviceLink/public/SDLAlert.h
+++ b/SmartDeviceLink/public/SDLAlert.h
@@ -59,110 +59,6 @@ NS_ASSUME_NONNULL_BEGIN
- (instancetype)initWithAlertText1:(nullable NSString *)alertText1 alertText2:(nullable NSString *)alertText2 alertText3:(nullable NSString *)alertText3 softButtons:(nullable NSArray<SDLSoftButton *> *)softButtons playTone:(BOOL)playTone ttsChunks:(nullable NSArray<SDLTTSChunk *> *)ttsChunks duration:(UInt16)duration progressIndicator:(BOOL)progressIndicator alertIcon:(nullable SDLImage *)icon cancelID:(UInt32)cancelID;
/**
- Convenience init for creating an alert with two lines of text and a timeout.
-
- @param alertText1 The first line of the alert
- @param alertText2 The second line of the alert
- @param duration The duration of the displayed portion of the alert, in milliseconds
- @return An SDLAlert object
- */
-- (instancetype)initWithAlertText1:(nullable NSString *)alertText1 alertText2:(nullable NSString *)alertText2 duration:(UInt16)duration __deprecated_msg("Use initWithAlertText1:alertText2:alertText3:softButtons:playTone:ttsChunks:duration:progressIndicator:alertIcon:cancelID: instead");
-
-/**
- Convenience init for creating an alert with three lines of text.
-
- @param alertText1 The first line of the alert
- @param alertText2 The second line of the alert
- @param alertText3 The third line of the alert
- @return An SDLAlert object
- */
-- (instancetype)initWithAlertText1:(nullable NSString *)alertText1 alertText2:(nullable NSString *)alertText2 alertText3:(nullable NSString *)alertText3 __deprecated_msg("Use initWithAlertText1:alertText2:alertText3:softButtons:playTone:ttsChunks:duration:progressIndicator:alertIcon:cancelID: instead");
-
-/**
- Convenience init for creating an alert with three lines of text and a timeout.
-
- @param alertText1 The first line of the alert
- @param alertText2 The second line of the alert
- @param alertText3 The third line of the alert
- @param duration The duration of the displayed portion of the alert, in milliseconds
- @return An SDLAlert object
- */
-- (instancetype)initWithAlertText1:(nullable NSString *)alertText1 alertText2:(nullable NSString *)alertText2 alertText3:(nullable NSString *)alertText3 duration:(UInt16)duration __deprecated_msg("Use initWithAlertText1:alertText2:alertText3:softButtons:playTone:ttsChunks:duration:progressIndicator:alertIcon:cancelID: instead");
-
-/**
- Convenience init for creating an alert with three lines of text and a timeout.
-
- @param alertText1 The first line of the alert
- @param alertText2 The second line of the alert
- @param alertText3 The third line of the alert
- @param duration The duration of the displayed portion of the alert, in milliseconds
- @param softButtons Buttons for the alert
- @return An SDLAlert object
- */
-- (instancetype)initWithAlertText1:(nullable NSString *)alertText1 alertText2:(nullable NSString *)alertText2 alertText3:(nullable NSString *)alertText3 duration:(UInt16)duration softButtons:(nullable NSArray<SDLSoftButton *> *)softButtons __deprecated_msg("Use initWithAlertText1:alertText2:alertText3:softButtons:playTone:ttsChunks:duration:progressIndicator:alertIcon:cancelID: instead");
-
-/**
- Convenience init for creating a speech-only alert.
-
- @param ttsText Speech to be played
- @param playTone Whether the alert tone should be played before the TTS is spoken
- @return An SDLAlert object
- */
-- (instancetype)initWithTTS:(nullable NSString *)ttsText playTone:(BOOL)playTone __deprecated_msg("Use initWithTTS:playTone: instead");
-
-/**
- Convenience init for creating an alert with two lines of text, optional sound cues, and a timout.
-
- @param ttsText Speech to be played
- @param alertText1 The first line of the alert
- @param alertText2 The second line of the alert
- @param playTone Whether the alert tone should be played before the TTS is spoken
- @param duration The duration of the displayed portion of the alert, in milliseconds
- @return An SDLAlert object
- */
-- (instancetype)initWithTTS:(nullable NSString *)ttsText alertText1:(nullable NSString *)alertText1 alertText2:(nullable NSString *)alertText2 playTone:(BOOL)playTone duration:(UInt16)duration __deprecated_msg("Use initWithAlertText1:alertText2:alertText3:softButtons:playTone:ttsChunks:duration:progressIndicator:alertIcon:cancelID: instead");
-
-/**
- Convenience init for creating an alert with three lines of text, optional sound cues, and a timout.
-
- @param ttsText Speech to be played
- @param alertText1 The first line of the alert
- @param alertText2 The second line of the alert
- @param alertText3 The third line of the alert
- @param playTone Whether the alert tone should be played before the TTS is spoken
- @param duration The duration of the displayed portion of the alert, in milliseconds
- @return An SDLAlert object
- */
-- (instancetype)initWithTTS:(nullable NSString *)ttsText alertText1:(nullable NSString *)alertText1 alertText2:(nullable NSString *)alertText2 alertText3:(nullable NSString *)alertText3 playTone:(BOOL)playTone duration:(UInt16)duration __deprecated_msg("Use initWithAlertText1:alertText2:alertText3:softButtons:playTone:ttsChunks:duration:progressIndicator:alertIcon:cancelID: instead");
-
-/**
- Convenience init for creating an alert with three lines of text, soft buttons, and optional sound cues.
-
- @param ttsChunks Speech or a sound file to be played when the alert shows
- @param alertText1 The first line of the alert
- @param alertText2 The second line of the alert
- @param alertText3 The third line of the alert
- @param playTone Whether the alert tone should be played before the TTS is spoken
- @param softButtons Buttons for the alert
- @return An SDLAlert object
- */
-- (instancetype)initWithTTSChunks:(nullable NSArray<SDLTTSChunk *> *)ttsChunks alertText1:(nullable NSString *)alertText1 alertText2:(nullable NSString *)alertText2 alertText3:(nullable NSString *)alertText3 playTone:(BOOL)playTone softButtons:(nullable NSArray<SDLSoftButton *> *)softButtons __deprecated_msg("Use initWithAlertText1:alertText2:alertText3:softButtons:playTone:ttsChunks:duration:progressIndicator:alertIcon:cancelID: instead");
-
-/**
- Convenience init for creating an alert with three lines of text, soft buttons, optional sound cues, and a timout.
-
- @param ttsChunks Speech or a sound file to be played when the alert shows
- @param alertText1 The first line of the alert
- @param alertText2 The second line of the alert
- @param alertText3 The third line of the alert
- @param playTone Whether the alert tone should be played before the TTS is spoken
- @param duration The duration of the displayed portion of the alert, in milliseconds
- @param softButtons Buttons for the alert
- @return An SDLAlert object
- */
-- (instancetype)initWithTTSChunks:(nullable NSArray<SDLTTSChunk *> *)ttsChunks alertText1:(nullable NSString *)alertText1 alertText2:(nullable NSString *)alertText2 alertText3:(nullable NSString *)alertText3 playTone:(BOOL)playTone duration:(UInt16)duration softButtons:(nullable NSArray<SDLSoftButton *> *)softButtons __deprecated_msg("Use initWithAlertText1:alertText2:alertText3:softButtons:playTone:ttsChunks:duration:progressIndicator:alertIcon:cancelID: instead");
-
-/**
The first line of the alert text field.
@discussion At least either `alertText1`, `alertText2` or `ttsChunks` need to be provided.
diff --git a/SmartDeviceLink/public/SDLAlert.m b/SmartDeviceLink/public/SDLAlert.m
index 041943a29..3533ae5f6 100644
--- a/SmartDeviceLink/public/SDLAlert.m
+++ b/SmartDeviceLink/public/SDLAlert.m
@@ -9,7 +9,6 @@
#import "SDLSoftButton.h"
#import "SDLTTSChunk.h"
-static UInt16 const DefaultAlertDuration = 5000;
NS_ASSUME_NONNULL_BEGIN
@@ -47,51 +46,14 @@ NS_ASSUME_NONNULL_BEGIN
return [self initWithAlertText:alertText1 alertText2:alertText2 alertText3:alertText3 softButtons:softButtons playTone:playTone ttsChunks:ttsChunks duration:@(duration) progressIndicator:progressIndicator alertIcon:icon cancelID:@(cancelID)];
}
-- (instancetype)initWithTTS:(nullable NSString *)ttsText playTone:(BOOL)playTone {
- return [self initWithTTS:ttsText alertText1:nil alertText2:nil playTone:playTone duration:DefaultAlertDuration];
-}
-
- (instancetype)initWithAlertText:(nullable NSString *)alertText softButtons:(nullable NSArray<SDLSoftButton *> *)softButtons playTone:(BOOL)playTone ttsChunks:(nullable NSArray<SDLTTSChunk *> *)ttsChunks alertIcon:(nullable SDLImage *)icon cancelID:(UInt32)cancelID {
return [self initWithAlertText:alertText alertText2:nil alertText3:nil softButtons:softButtons playTone:playTone ttsChunks:ttsChunks duration:nil progressIndicator:false alertIcon:icon cancelID:@(cancelID)];
}
-- (instancetype)initWithAlertText1:(nullable NSString *)alertText1 alertText2:(nullable NSString *)alertText2 alertText3:(nullable NSString *)alertText3 {
- return [self initWithAlertText1:alertText1 alertText2:alertText2 alertText3:alertText3 duration:DefaultAlertDuration];
-}
-
-- (instancetype)initWithAlertText1:(nullable NSString *)alertText1 alertText2:(nullable NSString *)alertText2 duration:(UInt16)duration {
- return [self initWithAlertText1:alertText1 alertText2:alertText2 alertText3:nil duration:duration];
-}
-
-- (instancetype)initWithAlertText1:(nullable NSString *)alertText1 alertText2:(nullable NSString *)alertText2 alertText3:(nullable NSString *)alertText3 duration:(UInt16)duration {
- return [self initWithAlertText1:alertText1 alertText2:alertText2 alertText3:alertText3 duration:duration softButtons:nil];
-}
-
-- (instancetype)initWithAlertText1:(nullable NSString *)alertText1 alertText2:(nullable NSString *)alertText2 alertText3:(nullable NSString *)alertText3 duration:(UInt16)duration softButtons:(nullable NSArray<SDLSoftButton *> *)softButtons {
- return [self initWithTTSChunks:nil alertText1:alertText1 alertText2:alertText2 alertText3:alertText3 playTone:NO duration:duration softButtons:softButtons];
-}
-
-- (instancetype)initWithTTS:(nullable NSString *)ttsText alertText1:(nullable NSString *)alertText1 alertText2:(nullable NSString *)alertText2 playTone:(BOOL)playTone duration:(UInt16)duration {
- return [self initWithTTS:ttsText alertText1:alertText1 alertText2:alertText2 alertText3:nil playTone:playTone duration:duration];
-}
-
-- (instancetype)initWithTTS:(nullable NSString *)ttsText alertText1:(nullable NSString *)alertText1 alertText2:(nullable NSString *)alertText2 alertText3:(nullable NSString *)alertText3 playTone:(BOOL)playTone duration:(UInt16)duration {
- NSArray *ttsChunks = [SDLTTSChunk textChunksFromString:ttsText];
- return [self initWithTTSChunks:ttsChunks alertText1:alertText1 alertText2:alertText2 alertText3:alertText3 playTone:playTone duration:duration softButtons:nil];
-}
-
- (instancetype)initWithTTSChunks:(nullable NSArray<SDLTTSChunk *> *)ttsChunks playTone:(BOOL)playTone {
return [self initWithAlertText:nil alertText2:nil alertText3:nil softButtons:nil playTone:playTone ttsChunks:ttsChunks duration:nil progressIndicator:false alertIcon:nil cancelID:nil];
}
-- (instancetype)initWithTTSChunks:(nullable NSArray<SDLTTSChunk *> *)ttsChunks alertText1:(nullable NSString *)alertText1 alertText2:(nullable NSString *)alertText2 alertText3:(nullable NSString *)alertText3 playTone:(BOOL)playTone softButtons:(nullable NSArray<SDLSoftButton *> *)softButtons {
- return [self initWithTTSChunks:ttsChunks alertText1:alertText1 alertText2:alertText2 alertText3:alertText3 playTone:playTone duration:DefaultAlertDuration softButtons:softButtons];
-}
-
-- (instancetype)initWithTTSChunks:(nullable NSArray<SDLTTSChunk *> *)ttsChunks alertText1:(nullable NSString *)alertText1 alertText2:(nullable NSString *)alertText2 alertText3:(nullable NSString *)alertText3 playTone:(BOOL)playTone duration:(UInt16)duration softButtons:(nullable NSArray<SDLSoftButton *> *)softButtons {
- return [self initWithAlertText:alertText1 alertText2:alertText2 alertText3:alertText3 softButtons:softButtons playTone:playTone ttsChunks:ttsChunks duration:@(duration) progressIndicator:false alertIcon:nil cancelID:nil];
-}
-
#pragma mark - Getters and Setters
- (void)setAlertText1:(nullable NSString *)alertText1 {
diff --git a/SmartDeviceLink/public/SDLAmbientLightStatus.h b/SmartDeviceLink/public/SDLAmbientLightStatus.h
index f4663ec61..cac4a1099 100644
--- a/SmartDeviceLink/public/SDLAmbientLightStatus.h
+++ b/SmartDeviceLink/public/SDLAmbientLightStatus.h
@@ -9,7 +9,7 @@
*
* @since SDL 3.0
*/
-typedef SDLEnum SDLAmbientLightStatus SDL_SWIFT_ENUM;
+typedef SDLEnum SDLAmbientLightStatus NS_TYPED_ENUM;
/**
* Represents a "night" ambient light status
diff --git a/SmartDeviceLink/public/SDLAppHMIType.h b/SmartDeviceLink/public/SDLAppHMIType.h
index 6cd653cd2..314f5bc67 100644
--- a/SmartDeviceLink/public/SDLAppHMIType.h
+++ b/SmartDeviceLink/public/SDLAppHMIType.h
@@ -9,7 +9,7 @@
*
* @since SDL 2.0
*/
-typedef SDLEnum SDLAppHMIType SDL_SWIFT_ENUM;
+typedef SDLEnum SDLAppHMIType NS_TYPED_ENUM;
/**
* The App will have default rights.
diff --git a/SmartDeviceLink/public/SDLAppInterfaceUnregisteredReason.h b/SmartDeviceLink/public/SDLAppInterfaceUnregisteredReason.h
index e8093025d..63260e425 100644
--- a/SmartDeviceLink/public/SDLAppInterfaceUnregisteredReason.h
+++ b/SmartDeviceLink/public/SDLAppInterfaceUnregisteredReason.h
@@ -9,7 +9,7 @@
*
* @since SDL 1.0
*/
-typedef SDLEnum SDLAppInterfaceUnregisteredReason SDL_SWIFT_ENUM;
+typedef SDLEnum SDLAppInterfaceUnregisteredReason NS_TYPED_ENUM;
/**
diff --git a/SmartDeviceLink/public/SDLAppServiceManifest.h b/SmartDeviceLink/public/SDLAppServiceManifest.h
index 1548181a1..3998e8a2c 100644
--- a/SmartDeviceLink/public/SDLAppServiceManifest.h
+++ b/SmartDeviceLink/public/SDLAppServiceManifest.h
@@ -14,7 +14,6 @@
@class SDLImage;
@class SDLMediaServiceManifest;
@class SDLNavigationServiceManifest;
-@class SDLSyncMsgVersion;
@class SDLMsgVersion;
@class SDLWeatherServiceManifest;
@@ -40,19 +39,6 @@ NS_ASSUME_NONNULL_BEGIN
* @param serviceName Unique name of this service
* @param serviceIcon The file name of the icon to be associated with this service
* @param allowAppConsumers If true, app service consumers beyond the IVI system will be able to access this service. If false, only the IVI system will be able consume the service. If not provided, it is assumed to be false
- * @param rpcSpecVersion This is the max RPC Spec version the app service understands
- * @param handledRPCs This field contains the Function IDs for the RPCs that this service intends to handle correctly
- * @param mediaServiceManifest A media service manifest
- * @return A SDLAppServiceManifest object
- */
-- (instancetype)initWithMediaServiceName:(nullable NSString *)serviceName serviceIcon:(nullable SDLImage *)serviceIcon allowAppConsumers:(BOOL)allowAppConsumers rpcSpecVersion:(nullable SDLSyncMsgVersion *)rpcSpecVersion handledRPCs:(nullable NSArray<NSNumber<SDLInt> *> *)handledRPCs mediaServiceManifest:(nullable SDLMediaServiceManifest *)mediaServiceManifest __deprecated_msg(("Use initWithMediaServiceName:serviceIcon:allowAppConsumers:maxRPCSpecVersion:handledRPCs:mediaServiceManifest instead"));
-
-/**
- * Convenience init for a media service manifest.
- *
- * @param serviceName Unique name of this service
- * @param serviceIcon The file name of the icon to be associated with this service
- * @param allowAppConsumers If true, app service consumers beyond the IVI system will be able to access this service. If false, only the IVI system will be able consume the service. If not provided, it is assumed to be false
* @param maxRPCSpecVersion This is the max RPC Spec version the app service understands
* @param handledRPCs This field contains the Function IDs for the RPCs that this service intends to handle correctly
* @param mediaServiceManifest A media service manifest
@@ -66,19 +52,6 @@ NS_ASSUME_NONNULL_BEGIN
* @param serviceName Unique name of this service
* @param serviceIcon The file name of the icon to be associated with this service
* @param allowAppConsumers If true, app service consumers beyond the IVI system will be able to access this service. If false, only the IVI system will be able consume the service. If not provided, it is assumed to be false
- * @param rpcSpecVersion This is the max RPC Spec version the app service understands
- * @param handledRPCs This field contains the Function IDs for the RPCs that this service intends to handle correctly
- * @param weatherServiceManifest A weather service manifest
- * @return A SDLAppServiceManifest object
- */
-- (instancetype)initWithWeatherServiceName:(nullable NSString *)serviceName serviceIcon:(nullable SDLImage *)serviceIcon allowAppConsumers:(BOOL)allowAppConsumers rpcSpecVersion:(nullable SDLSyncMsgVersion *)rpcSpecVersion handledRPCs:(nullable NSArray<NSNumber<SDLInt> *> *)handledRPCs weatherServiceManifest:(nullable SDLWeatherServiceManifest *)weatherServiceManifest __deprecated_msg(("Use initWithWeatherServiceName:serviceIcon:allowAppConsumers::maxRPCSpecVersion:handledRPCs:weatherServiceManifest instead"));
-
-/**
- * Convenience init for a weather service manifest.
- *
- * @param serviceName Unique name of this service
- * @param serviceIcon The file name of the icon to be associated with this service
- * @param allowAppConsumers If true, app service consumers beyond the IVI system will be able to access this service. If false, only the IVI system will be able consume the service. If not provided, it is assumed to be false
* @param maxRPCSpecVersion This is the max RPC Spec version the app service understands
* @param handledRPCs This field contains the Function IDs for the RPCs that this service intends to handle correctly
* @param weatherServiceManifest A weather service manifest
@@ -92,19 +65,6 @@ NS_ASSUME_NONNULL_BEGIN
* @param serviceName Unique name of this service
* @param serviceIcon The file name of the icon to be associated with this service
* @param allowAppConsumers If true, app service consumers beyond the IVI system will be able to access this service. If false, only the IVI system will be able consume the service. If not provided, it is assumed to be false
- * @param rpcSpecVersion This is the max RPC Spec version the app service understands
- * @param handledRPCs This field contains the Function IDs for the RPCs that this service intends to handle correctly
- * @param navigationServiceManifest A navigation service manifest
- * @return A SDLAppServiceManifest object
- */
-- (instancetype)initWithNavigationServiceName:(nullable NSString *)serviceName serviceIcon:(nullable SDLImage *)serviceIcon allowAppConsumers:(BOOL)allowAppConsumers rpcSpecVersion:(nullable SDLSyncMsgVersion *)rpcSpecVersion handledRPCs:(nullable NSArray<NSNumber<SDLInt> *> *)handledRPCs navigationServiceManifest:(nullable SDLNavigationServiceManifest *)navigationServiceManifest __deprecated_msg(("Use initWithNavigationServiceName:serviceIcon:allowAppConsumers:macRPCSpecVersion:handledRPCs:navigationServiceManifest instead"));
-
-/**
- * Convenience init for a navigation service manifest.
- *
- * @param serviceName Unique name of this service
- * @param serviceIcon The file name of the icon to be associated with this service
- * @param allowAppConsumers If true, app service consumers beyond the IVI system will be able to access this service. If false, only the IVI system will be able consume the service. If not provided, it is assumed to be false
* @param maxRPCSpecVersion This is the max RPC Spec version the app service understands
* @param handledRPCs This field contains the Function IDs for the RPCs that this service intends to handle correctly
* @param navigationServiceManifest A navigation service manifest
@@ -119,22 +79,6 @@ NS_ASSUME_NONNULL_BEGIN
* @param serviceType The type of service that is to be offered by this app
* @param serviceIcon The file name of the icon to be associated with this service
* @param allowAppConsumers If true, app service consumers beyond the IVI system will be able to access this service. If false, only the IVI system will be able consume the service. If not provided, it is assumed to be false
- * @param rpcSpecVersion This is the max RPC Spec version the app service understands
- * @param handledRPCs This field contains the Function IDs for the RPCs that this service intends to handle correctly
- * @param mediaServiceManifest A media service manifest
- * @param weatherServiceManifest A weather service manifest
- * @param navigationServiceManifest A navigation service manifest
- * @return A SDLAppServiceManifest object
- */
-- (instancetype)initWithServiceName:(nullable NSString *)serviceName serviceType:(SDLAppServiceType)serviceType serviceIcon:(nullable SDLImage *)serviceIcon allowAppConsumers:(BOOL)allowAppConsumers rpcSpecVersion:(nullable SDLSyncMsgVersion *)rpcSpecVersion handledRPCs:(nullable NSArray<NSNumber<SDLInt> *> *)handledRPCs mediaServiceManifest:(nullable SDLMediaServiceManifest *)mediaServiceManifest weatherServiceManifest:(nullable SDLWeatherServiceManifest *)weatherServiceManifest navigationServiceManifest:(nullable SDLNavigationServiceManifest *)navigationServiceManifest __deprecated_msg(("Use initWithServiceName:serviceType:serviceIcon:allowAppConsumers:maxRPCSpecVersion:handledRPCs:mediaServiceManifest:weatherServiceManifest:navigationServiceManifest instead"));
-
-/**
- * Convenience init for all parameters.
- *
- * @param serviceName Unique name of this service
- * @param serviceType The type of service that is to be offered by this app
- * @param serviceIcon The file name of the icon to be associated with this service
- * @param allowAppConsumers If true, app service consumers beyond the IVI system will be able to access this service. If false, only the IVI system will be able consume the service. If not provided, it is assumed to be false
* @param maxRPCSpecVersion This is the max RPC Spec version the app service understands
* @param handledRPCs This field contains the Function IDs for the RPCs that this service intends to handle correctly
* @param mediaServiceManifest A media service manifest
@@ -175,13 +119,6 @@ NS_ASSUME_NONNULL_BEGIN
/**
* This is the max RPC Spec version the app service understands. This is important during the RPC passthrough functionality. If not included, it is assumed the max version of the module is acceptable.
*
- * SyncMsgVersion, Optional
- */
-@property (nullable, strong, nonatomic) SDLSyncMsgVersion *rpcSpecVersion __deprecated_msg(("Use maxRPCSpecVersion instead"));
-
-/**
- * This is the max RPC Spec version the app service understands. This is important during the RPC passthrough functionality. If not included, it is assumed the max version of the module is acceptable.
- *
* SDLMsgVersion, Optional
*/
@property (nullable, strong, nonatomic) SDLMsgVersion *maxRPCSpecVersion;
diff --git a/SmartDeviceLink/public/SDLAppServiceManifest.m b/SmartDeviceLink/public/SDLAppServiceManifest.m
index fe5849145..a49a99517 100644
--- a/SmartDeviceLink/public/SDLAppServiceManifest.m
+++ b/SmartDeviceLink/public/SDLAppServiceManifest.m
@@ -14,7 +14,6 @@
#import "SDLImage.h"
#import "SDLMediaServiceManifest.h"
#import "SDLNavigationServiceManifest.h"
-#import "SDLSyncMsgVersion.h"
#import "SDLMsgVersion.h"
#import "SDLWeatherServiceManifest.h"
@@ -33,48 +32,6 @@ NS_ASSUME_NONNULL_BEGIN
return self;
}
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
-- (instancetype)initWithMediaServiceName:(nullable NSString *)serviceName serviceIcon:(nullable SDLImage *)serviceIcon allowAppConsumers:(BOOL)allowAppConsumers rpcSpecVersion:(nullable SDLSyncMsgVersion *)rpcSpecVersion handledRPCs:(nullable NSArray<NSNumber<SDLInt> *> *)handledRPCs mediaServiceManifest:(nullable SDLMediaServiceManifest *)mediaServiceManifest {
- return [self initWithServiceName:serviceName serviceType:SDLAppServiceTypeMedia serviceIcon:serviceIcon allowAppConsumers:allowAppConsumers rpcSpecVersion:rpcSpecVersion handledRPCs:handledRPCs mediaServiceManifest:mediaServiceManifest weatherServiceManifest:nil navigationServiceManifest:nil];
-}
-#pragma clang diagnostic pop
-
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
-- (instancetype)initWithWeatherServiceName:(nullable NSString *)serviceName serviceIcon:(nullable SDLImage *)serviceIcon allowAppConsumers:(BOOL)allowAppConsumers rpcSpecVersion:(nullable SDLSyncMsgVersion *)rpcSpecVersion handledRPCs:(nullable NSArray<NSNumber<SDLInt> *> *)handledRPCs weatherServiceManifest:(nullable SDLWeatherServiceManifest *)weatherServiceManifest {
- return [self initWithServiceName:serviceName serviceType:SDLAppServiceTypeWeather serviceIcon:serviceIcon allowAppConsumers:allowAppConsumers rpcSpecVersion:rpcSpecVersion handledRPCs:handledRPCs mediaServiceManifest:nil weatherServiceManifest:weatherServiceManifest navigationServiceManifest:nil];
-}
-#pragma clang diagnostic pop
-
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
-- (instancetype)initWithNavigationServiceName:(nullable NSString *)serviceName serviceIcon:(nullable SDLImage *)serviceIcon allowAppConsumers:(BOOL)allowAppConsumers rpcSpecVersion:(nullable SDLSyncMsgVersion *)rpcSpecVersion handledRPCs:(nullable NSArray<NSNumber<SDLInt> *> *)handledRPCs navigationServiceManifest:(nullable SDLNavigationServiceManifest *)navigationServiceManifest {
- return [self initWithServiceName:serviceName serviceType:SDLAppServiceTypeNavigation serviceIcon:serviceIcon allowAppConsumers:allowAppConsumers rpcSpecVersion:rpcSpecVersion handledRPCs:handledRPCs mediaServiceManifest:nil weatherServiceManifest:nil navigationServiceManifest:navigationServiceManifest];
-}
-#pragma clang diagnostic pop
-
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
-- (instancetype)initWithServiceName:(nullable NSString *)serviceName serviceType:(SDLAppServiceType)serviceType serviceIcon:(nullable SDLImage *)serviceIcon allowAppConsumers:(BOOL)allowAppConsumers rpcSpecVersion:(nullable SDLSyncMsgVersion *)rpcSpecVersion handledRPCs:(nullable NSArray<NSNumber<SDLInt> *> *)handledRPCs mediaServiceManifest:(nullable SDLMediaServiceManifest *)mediaServiceManifest weatherServiceManifest:(nullable SDLWeatherServiceManifest *)weatherServiceManifest navigationServiceManifest:(nullable SDLNavigationServiceManifest *)navigationServiceManifest {
- self = [self initWithAppServiceType:serviceType];
- if (!self) {
- return self;
- }
-
- self.serviceName = serviceName;
- self.serviceIcon = serviceIcon;
- self.allowAppConsumers = @(allowAppConsumers);
- self.rpcSpecVersion = rpcSpecVersion;
- self.handledRPCs = handledRPCs;
- self.mediaServiceManifest = mediaServiceManifest;
- self.weatherServiceManifest = weatherServiceManifest;
- self.navigationServiceManifest = navigationServiceManifest;
-
- return self;
-}
-#pragma clang diagnostic pop
-
- (instancetype)initWithMediaServiceName:(nullable NSString *)serviceName serviceIcon:(nullable SDLImage *)serviceIcon allowAppConsumers:(BOOL)allowAppConsumers maxRPCSpecVersion:(nullable SDLMsgVersion *)maxRPCSpecVersion handledRPCs:(nullable NSArray<NSNumber<SDLInt> *> *)handledRPCs mediaServiceManifest:(nullable SDLMediaServiceManifest *)mediaServiceManifest {
return [self initWithServiceName:serviceName serviceType:SDLAppServiceTypeMedia serviceIcon:serviceIcon allowAppConsumers:allowAppConsumers maxRPCSpecVersion:maxRPCSpecVersion handledRPCs:handledRPCs mediaServiceManifest:mediaServiceManifest weatherServiceManifest:nil navigationServiceManifest:nil];
}
@@ -138,28 +95,6 @@ NS_ASSUME_NONNULL_BEGIN
return [self.store sdl_objectForName:SDLRPCParameterNameAllowAppConsumers ofClass:NSNumber.class error:nil];
}
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
-- (void)setRpcSpecVersion:(nullable SDLSyncMsgVersion *)rpcSpecVersion {
- if (rpcSpecVersion == nil) {
- [self.store sdl_setObject:nil forName:SDLRPCParameterNameRPCSpecVersion];
- return;
- }
- SDLMsgVersion *maxRPCSpecVersion = [[SDLMsgVersion alloc] initWithMajorVersion:(uint8_t)rpcSpecVersion.majorVersion.unsignedIntValue minorVersion:(uint8_t)rpcSpecVersion.minorVersion.unsignedIntValue patchVersion:(uint8_t)rpcSpecVersion.patchVersion.unsignedIntValue];
- [self.store sdl_setObject:maxRPCSpecVersion forName:SDLRPCParameterNameRPCSpecVersion];
-}
-
-- (nullable SDLSyncMsgVersion *)rpcSpecVersion {
- SDLMsgVersion *maxRPCSpecVersion = [self.store sdl_objectForName:SDLRPCParameterNameRPCSpecVersion ofClass:SDLMsgVersion.class error:nil];
-
- if(maxRPCSpecVersion == nil) {
- return [self.store sdl_objectForName:SDLRPCParameterNameRPCSpecVersion ofClass:SDLSyncMsgVersion.class error:nil];
- }
-
- return [[SDLSyncMsgVersion alloc] initWithMajorVersion:(uint8_t)maxRPCSpecVersion.majorVersion.unsignedIntValue minorVersion:(uint8_t)maxRPCSpecVersion.minorVersion.unsignedIntValue patchVersion:(uint8_t)maxRPCSpecVersion.patchVersion.unsignedIntValue];
-}
-#pragma clang diagnostic pop
-
- (void)setMaxRPCSpecVersion:(nullable SDLMsgVersion *)maxRPCSpecVersion {
[self.store sdl_setObject:maxRPCSpecVersion forName:SDLRPCParameterNameRPCSpecVersion];
}
diff --git a/SmartDeviceLink/public/SDLAppServiceType.h b/SmartDeviceLink/public/SDLAppServiceType.h
index 920f5109b..d1b98f067 100644
--- a/SmartDeviceLink/public/SDLAppServiceType.h
+++ b/SmartDeviceLink/public/SDLAppServiceType.h
@@ -11,7 +11,7 @@
/**
* Enumeration listing possible app service types.
*/
-typedef SDLEnum SDLAppServiceType SDL_SWIFT_ENUM;
+typedef SDLEnum SDLAppServiceType NS_TYPED_ENUM;
/**
* The app will have a service type of media.
diff --git a/SmartDeviceLink/public/SDLAudioControlCapabilities.h b/SmartDeviceLink/public/SDLAudioControlCapabilities.h
index 7c2d6bba4..f596b081b 100644
--- a/SmartDeviceLink/public/SDLAudioControlCapabilities.h
+++ b/SmartDeviceLink/public/SDLAudioControlCapabilities.h
@@ -15,14 +15,6 @@ NS_ASSUME_NONNULL_BEGIN
/**
Constructs a newly allocated SDLAudioControlCapabilities object with audio control module name (max 100 chars)
-
- @param name The short friendly name of the audio control module.
- @return An instance of the SDLAudioControlCapabilities class.
- */
-- (instancetype)initWithModuleName:(NSString *)name __deprecated_msg("Use initWithModuleName:moduleInfo: instead");
-
-/**
- Constructs a newly allocated SDLAudioControlCapabilities object with audio control module name (max 100 chars)
@param name The short friendly name of the audio control module.
@param moduleInfo Information about a RC module, including its id.
@@ -31,18 +23,6 @@ NS_ASSUME_NONNULL_BEGIN
- (instancetype)initWithModuleName:(NSString *)name moduleInfo:(nullable SDLModuleInfo *)moduleInfo;
/**
- Constructs a newly allocated SDLAudioControlCapabilities object with given parameters
-
- @param name The short friendly name of the audio control module.
- @param sourceAvailable Availability of the control of audio source.
- @param volumeAvailable Availability of the volume of audio source.
- @param equalizerAvailable Availability of the equalizer of audio source.
- @param equalizerMaxChannelID Equalizer channel ID (between 1-100).
- @return An instance of the SDLAudioControlCapabilities class.
- */
-- (instancetype)initWithModuleName:(NSString *)name sourceAvailable:(nullable NSNumber<SDLBool> *)sourceAvailable keepContextAvailable:(nullable NSNumber<SDLBool> *)keepContextAvailable volumeAvailable:(nullable NSNumber<SDLBool> *)volumeAvailable equalizerAvailable:(nullable NSNumber<SDLBool> *)equalizerAvailable equalizerMaxChannelID:(nullable NSNumber<SDLInt> *)equalizerMaxChannelID __deprecated_msg("Use initWithModuleName:moduleInfo:sourceAvailable:keepContextAvailable:volumeAvailable:equalizerAvailable:equalizerMaxChannelID: instead");
-
-/**
Constructs a newly allocated SDLAudioControlCapabilities object with given parameters
@param name The short friendly name of the audio control module.
diff --git a/SmartDeviceLink/public/SDLAudioControlCapabilities.m b/SmartDeviceLink/public/SDLAudioControlCapabilities.m
index bc7ff568d..68832efe2 100644
--- a/SmartDeviceLink/public/SDLAudioControlCapabilities.m
+++ b/SmartDeviceLink/public/SDLAudioControlCapabilities.m
@@ -9,16 +9,6 @@ NS_ASSUME_NONNULL_BEGIN
@implementation SDLAudioControlCapabilities
-- (instancetype)initWithModuleName:(NSString *)name {
- self = [self init];
- if (!self) {
- return nil;
- }
- self.moduleName = name;
-
- return self;
-}
-
- (instancetype)initWithModuleName:(NSString *)name moduleInfo:(nullable SDLModuleInfo *)moduleInfo {
self = [self init];
if (!self) {
@@ -30,21 +20,6 @@ NS_ASSUME_NONNULL_BEGIN
return self;
}
-- (instancetype)initWithModuleName:(NSString *)name sourceAvailable:(nullable NSNumber<SDLBool> *)sourceAvailable keepContextAvailable:(nullable NSNumber<SDLBool> *)keepContextAvailable volumeAvailable:(nullable NSNumber<SDLBool> *)volumeAvailable equalizerAvailable:(nullable NSNumber<SDLBool> *)equalizerAvailable equalizerMaxChannelID:(nullable NSNumber<SDLInt> *)equalizerMaxChannelID {
- self = [self init];
- if (!self) {
- return nil;
- }
- self.moduleName = name;
- self.sourceAvailable = sourceAvailable;
- self.keepContextAvailable = keepContextAvailable;
- self.volumeAvailable = volumeAvailable;
- self.equalizerAvailable = equalizerAvailable;
- self.equalizerMaxChannelId = equalizerMaxChannelID;
-
- return self;
-}
-
- (instancetype)initWithModuleName:(NSString *)name moduleInfo:(nullable SDLModuleInfo *)moduleInfo sourceAvailable:(nullable NSNumber<SDLBool> *)sourceAvailable keepContextAvailable:(nullable NSNumber<SDLBool> *)keepContextAvailable volumeAvailable:(nullable NSNumber<SDLBool> *)volumeAvailable equalizerAvailable:(nullable NSNumber<SDLBool> *)equalizerAvailable equalizerMaxChannelID:(nullable NSNumber<SDLInt> *)equalizerMaxChannelID {
self = [self init];
if (!self) {
@@ -60,10 +35,8 @@ NS_ASSUME_NONNULL_BEGIN
self.equalizerMaxChannelId = equalizerMaxChannelID;
return self;
-
}
-
- (void)setModuleName:(NSString *)moduleName {
[self.store sdl_setObject:moduleName forName:SDLRPCParameterNameModuleName];
}
diff --git a/SmartDeviceLink/public/SDLAudioStreamManager.m b/SmartDeviceLink/public/SDLAudioStreamManager.m
index f8486272a..35b492cce 100755
--- a/SmartDeviceLink/public/SDLAudioStreamManager.m
+++ b/SmartDeviceLink/public/SDLAudioStreamManager.m
@@ -39,13 +39,7 @@ NS_ASSUME_NONNULL_BEGIN
_mutableQueue = [NSMutableArray array];
_shouldPlayWhenReady = NO;
-
- if (@available(iOS 10.0, *)) {
- _audioQueue = dispatch_queue_create_with_target("com.sdl.audiomanager.transcode", DISPATCH_QUEUE_SERIAL, [SDLGlobals sharedGlobals].sdlProcessingQueue);
- } else {
- _audioQueue = [SDLGlobals sharedGlobals].sdlProcessingQueue;
- }
-
+ _audioQueue = dispatch_queue_create_with_target("com.sdl.audiomanager.transcode", DISPATCH_QUEUE_SERIAL, [SDLGlobals sharedGlobals].sdlProcessingQueue);
_streamManager = streamManager;
return self;
diff --git a/SmartDeviceLink/public/SDLAudioStreamingIndicator.h b/SmartDeviceLink/public/SDLAudioStreamingIndicator.h
index 61590002f..8ae6423e8 100644
--- a/SmartDeviceLink/public/SDLAudioStreamingIndicator.h
+++ b/SmartDeviceLink/public/SDLAudioStreamingIndicator.h
@@ -9,7 +9,7 @@
*
* @since SDL 4.6
*/
-typedef SDLEnum SDLAudioStreamingIndicator SDL_SWIFT_ENUM;
+typedef SDLEnum SDLAudioStreamingIndicator NS_TYPED_ENUM;
/**
* Default playback indicator.
diff --git a/SmartDeviceLink/public/SDLAudioStreamingState.h b/SmartDeviceLink/public/SDLAudioStreamingState.h
index 6aa746757..da557f8f3 100644
--- a/SmartDeviceLink/public/SDLAudioStreamingState.h
+++ b/SmartDeviceLink/public/SDLAudioStreamingState.h
@@ -9,7 +9,7 @@
*
* @since SDL 1.0
*/
-typedef SDLEnum SDLAudioStreamingState SDL_SWIFT_ENUM;
+typedef SDLEnum SDLAudioStreamingState NS_TYPED_ENUM;
/**
* Currently streaming audio, if any, is audible to user.
diff --git a/SmartDeviceLink/public/SDLAudioType.h b/SmartDeviceLink/public/SDLAudioType.h
index 283be1ea8..d7d869e91 100644
--- a/SmartDeviceLink/public/SDLAudioType.h
+++ b/SmartDeviceLink/public/SDLAudioType.h
@@ -7,7 +7,7 @@
/**
Describes different audio type options for PerformAudioPassThru
*/
-typedef SDLEnum SDLAudioType SDL_SWIFT_ENUM;
+typedef SDLEnum SDLAudioType NS_TYPED_ENUM;
/**
* PCM raw audio
diff --git a/SmartDeviceLink/public/SDLBitsPerSample.h b/SmartDeviceLink/public/SDLBitsPerSample.h
index 366dab9ef..899ab6906 100644
--- a/SmartDeviceLink/public/SDLBitsPerSample.h
+++ b/SmartDeviceLink/public/SDLBitsPerSample.h
@@ -9,7 +9,7 @@
*
* @since SDL 2.0
*/
-typedef SDLEnum SDLBitsPerSample SDL_SWIFT_ENUM;
+typedef SDLEnum SDLBitsPerSample NS_TYPED_ENUM;
/**
* 8 bits per sample
diff --git a/SmartDeviceLink/public/SDLButtonEventMode.h b/SmartDeviceLink/public/SDLButtonEventMode.h
index 5facb9f73..081ee5ceb 100644
--- a/SmartDeviceLink/public/SDLButtonEventMode.h
+++ b/SmartDeviceLink/public/SDLButtonEventMode.h
@@ -9,7 +9,7 @@
*
* @since SDL 1.0
*/
-typedef SDLEnum SDLButtonEventMode SDL_SWIFT_ENUM;
+typedef SDLEnum SDLButtonEventMode NS_TYPED_ENUM;
/**
* The button was released
diff --git a/SmartDeviceLink/public/SDLButtonName.h b/SmartDeviceLink/public/SDLButtonName.h
index 4f6007fb5..e9495322f 100644
--- a/SmartDeviceLink/public/SDLButtonName.h
+++ b/SmartDeviceLink/public/SDLButtonName.h
@@ -13,7 +13,7 @@
*
* @since SDL 1.0
*/
-typedef SDLEnum SDLButtonName SDL_SWIFT_ENUM;
+typedef SDLEnum SDLButtonName NS_TYPED_ENUM;
/**
* Represents the button usually labeled "OK". A typical use of this button is for the user to press it to make a selection. Prior to SDL Core 5.0 (iOS Proxy v.6.1), Ok was used for both "OK" buttons *AND* PlayPause. In 5.0, PlayPause was introduced to reduce confusion, and you should use the one you intend for your use case (usually PlayPause). Until the next proxy breaking change, however, subscribing to this button name will continue to subscribe you to PlayPause so that your code does not break. That means that if you subscribe to both Ok and PlayPause, you will receive duplicate notifications.
diff --git a/SmartDeviceLink/public/SDLButtonPress.h b/SmartDeviceLink/public/SDLButtonPress.h
index c5769ca6d..ee7717072 100644
--- a/SmartDeviceLink/public/SDLButtonPress.h
+++ b/SmartDeviceLink/public/SDLButtonPress.h
@@ -21,27 +21,6 @@ Constructs a newly allocated SDLButtonPress object with the given parameters
@param buttonName the name of the button
@param moduleType the module where the button should be pressed
-
-@return An instance of the SDLButtonPress class.
-*/
-- (instancetype)initWithButtonName:(SDLButtonName)buttonName moduleType:(SDLModuleType)moduleType __deprecated_msg(("Use initWithButtonName:moduleType:moduleId:buttonPressMode: instead"));;
-
-/**
-Constructs a newly allocated SDLButtonPress object with the given parameters
-
-@param buttonName the name of the button
-@param moduleType the module where the button should be pressed
-@param moduleId the id of the module
-
-@return An instance of the SDLButtonPress class.
-*/
-- (instancetype)initWithButtonName:(SDLButtonName)buttonName moduleType:(SDLModuleType)moduleType moduleId:(nullable NSString *)moduleId __deprecated_msg(("Use initWithButtonName:moduleType:moduleId:buttonPressMode: instead"));;
-
-/**
-Constructs a newly allocated SDLButtonPress object with the given parameters
-
-@param buttonName the name of the button
-@param moduleType the module where the button should be pressed
@param moduleId the id of the module
@param buttonPressMode indicates LONG or SHORT button press event
diff --git a/SmartDeviceLink/public/SDLButtonPress.m b/SmartDeviceLink/public/SDLButtonPress.m
index 419f0d7f6..c2047ca6c 100644
--- a/SmartDeviceLink/public/SDLButtonPress.m
+++ b/SmartDeviceLink/public/SDLButtonPress.m
@@ -20,31 +20,6 @@ NS_ASSUME_NONNULL_BEGIN
}
#pragma clang diagnostic pop
-- (instancetype)initWithButtonName:(SDLButtonName) buttonName moduleType:(SDLModuleType)moduleType {
- self = [self init];
- if (!self) {
- return nil;
- }
-
- self.buttonName = buttonName;
- self.moduleType = moduleType;
-
- return self;
-}
-
-- (instancetype)initWithButtonName:(SDLButtonName)buttonName moduleType:(SDLModuleType)moduleType moduleId:(nullable NSString *)moduleId {
- self = [self init];
- if (!self) {
- return nil;
- }
-
- self.buttonName = buttonName;
- self.moduleType = moduleType;
- self.moduleId = moduleId;
-
- return self;
-}
-
- (instancetype)initWithButtonName:(SDLButtonName)buttonName moduleType:(SDLModuleType)moduleType moduleId:(nullable NSString *)moduleId buttonPressMode:(SDLButtonPressMode)buttonPressMode {
self = [self init];
if (!self) {
diff --git a/SmartDeviceLink/public/SDLButtonPressMode.h b/SmartDeviceLink/public/SDLButtonPressMode.h
index 0272e0eab..934a37022 100644
--- a/SmartDeviceLink/public/SDLButtonPressMode.h
+++ b/SmartDeviceLink/public/SDLButtonPressMode.h
@@ -9,7 +9,7 @@
*
* @since SDL 1.0
*/
-typedef SDLEnum SDLButtonPressMode SDL_SWIFT_ENUM;
+typedef SDLEnum SDLButtonPressMode NS_TYPED_ENUM;
/**
* A button was released, after it was pressed for a long time. Actual timing is defined by the head unit and may vary.
diff --git a/SmartDeviceLink/public/SDLCapacityUnit.h b/SmartDeviceLink/public/SDLCapacityUnit.h
index 415bd18c5..0661ff3fc 100644
--- a/SmartDeviceLink/public/SDLCapacityUnit.h
+++ b/SmartDeviceLink/public/SDLCapacityUnit.h
@@ -37,7 +37,7 @@ NS_ASSUME_NONNULL_BEGIN
/**
* @since SDL 7.0.0
*/
-typedef SDLEnum SDLCapacityUnit SDL_SWIFT_ENUM;
+typedef SDLEnum SDLCapacityUnit NS_TYPED_ENUM;
extern SDLCapacityUnit const SDLCapacityUnitKilograms;
diff --git a/SmartDeviceLink/public/SDLCarModeStatus.h b/SmartDeviceLink/public/SDLCarModeStatus.h
index e98ada744..4cf148919 100644
--- a/SmartDeviceLink/public/SDLCarModeStatus.h
+++ b/SmartDeviceLink/public/SDLCarModeStatus.h
@@ -9,7 +9,7 @@
* Since SmartDeviceLink 2.0
*/
-typedef SDLEnum SDLCarModeStatus SDL_SWIFT_ENUM;
+typedef SDLEnum SDLCarModeStatus NS_TYPED_ENUM;
/**
Provides carmode NORMAL to each module.
diff --git a/SmartDeviceLink/public/SDLCharacterSet.h b/SmartDeviceLink/public/SDLCharacterSet.h
index 9cd096573..6a3be17e7 100644
--- a/SmartDeviceLink/public/SDLCharacterSet.h
+++ b/SmartDeviceLink/public/SDLCharacterSet.h
@@ -38,43 +38,31 @@
*
* @since SDL 1.0.0
*/
-typedef SDLEnum SDLCharacterSet SDL_SWIFT_ENUM;
+typedef SDLEnum SDLCharacterSet NS_TYPED_ENUM;
/**
* @deprecated
* @since SDL 7.0.0
*/
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
extern SDLCharacterSet const SDLCharacterSetType2 __deprecated_msg("Use Ascii, Iso88591, or Utf8 instead");
-#pragma clang diagnostic pop
/**
* @deprecated
* @since SDL 7.0.0
*/
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
extern SDLCharacterSet const SDLCharacterSetType5 __deprecated_msg("Use Ascii, Iso88591, or Utf8 instead");
-#pragma clang diagnostic pop
/**
* @deprecated
* @since SDL 7.0.0
*/
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
extern SDLCharacterSet const SDLCharacterSetCID1 __deprecated_msg("Use Ascii, Iso88591, or Utf8 instead");
-#pragma clang diagnostic pop
/**
* @deprecated
* @since SDL 7.0.0
*/
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
extern SDLCharacterSet const SDLCharacterSetCID2 __deprecated_msg("Use Ascii, Iso88591, or Utf8 instead");
-#pragma clang diagnostic pop
/**
* ASCII as defined in https://en.wikipedia.org/wiki/ASCII as defined in codes 0-127. Non-printable characters such as tabs and back spaces are ignored.
diff --git a/SmartDeviceLink/public/SDLCharacterSet.m b/SmartDeviceLink/public/SDLCharacterSet.m
index 47b595f7e..503ee31da 100644
--- a/SmartDeviceLink/public/SDLCharacterSet.m
+++ b/SmartDeviceLink/public/SDLCharacterSet.m
@@ -32,26 +32,10 @@
#import "SDLCharacterSet.h"
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
SDLCharacterSet const SDLCharacterSetType2 = @"TYPE2SET";
-#pragma clang diagnostic pop
-
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
SDLCharacterSet const SDLCharacterSetType5 = @"TYPE5SET";
-#pragma clang diagnostic pop
-
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
SDLCharacterSet const SDLCharacterSetCID1 = @"CID1SET";
-#pragma clang diagnostic pop
-
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
SDLCharacterSet const SDLCharacterSetCID2 = @"CID2SET";
-#pragma clang diagnostic pop
-
SDLCharacterSet const SDLCharacterSetAscii = @"ASCII";
SDLCharacterSet const SDLCharacterSetIso88591 = @"ISO_8859_1";
SDLCharacterSet const SDLCharacterSetUtf8 = @"UTF_8";
diff --git a/SmartDeviceLink/public/SDLClimateControlCapabilities.h b/SmartDeviceLink/public/SDLClimateControlCapabilities.h
index 351b8dd79..a0eb2a690 100644
--- a/SmartDeviceLink/public/SDLClimateControlCapabilities.h
+++ b/SmartDeviceLink/public/SDLClimateControlCapabilities.h
@@ -14,61 +14,6 @@ NS_ASSUME_NONNULL_BEGIN
*/
@interface SDLClimateControlCapabilities : SDLRPCStruct
-/// Convenience init to describe the climate control capabilities.
-///
-/// @param moduleName The short friendly name of the climate control module
-/// @param fanSpeedAvailable Availability of the control of fan speed
-/// @param desiredTemperatureAvailable Availability of the control of desired temperature
-/// @param acEnableAvailable Availability of the control of turn on/off AC
-/// @param acMaxEnableAvailable Availability of the control of enable/disable air conditioning is ON on the maximum level
-/// @param circulateAirEnableAvailable Availability of the control of enable/disable circulate Air mode
-/// @param autoModeEnableAvailable Availability of the control of enable/disable auto mode
-/// @param dualModeEnableAvailable Availability of the control of enable/disable dual mode
-/// @param defrostZoneAvailable Availability of the control of defrost zones
-/// @param ventilationModeAvailable Availability of the control of air ventilation mode
-/// @return An SDLClimateControlCapabilities object
-- (instancetype)initWithModuleName:(NSString *)moduleName fanSpeedAvailable:(BOOL)fanSpeedAvailable desiredTemperatureAvailable:(BOOL)desiredTemperatureAvailable acEnableAvailable:(BOOL)acEnableAvailable acMaxEnableAvailable:(BOOL)acMaxEnableAvailable circulateAirAvailable:(BOOL)circulateAirEnableAvailable autoModeEnableAvailable:(BOOL)autoModeEnableAvailable dualModeEnableAvailable:(BOOL)dualModeEnableAvailable defrostZoneAvailable:(BOOL)defrostZoneAvailable ventilationModeAvailable:(BOOL)ventilationModeAvailable __deprecated_msg("Use initWithModuleName:fanSpeedAvailable:desiredTemperatureAvailable:acEnableAvailable:acMaxEnableAvailable:circulateAirAvailable:autoModeEnableAvailable: dualModeEnableAvailable:defrostZoneAvailable:ventilationModeAvailable: heatedSteeringWheelAvailable:heatedWindshieldAvailable: heatedRearWindowAvailable:heatedMirrorsAvailable: climateEnableAvailable: instead");
-
-
-/// Convenience init to describe the climate control capabilities.
-///
-/// @param moduleName The short friendly name of the climate control module
-/// @param fanSpeedAvailable Availability of the control of fan speed
-/// @param desiredTemperatureAvailable Availability of the control of desired temperature
-/// @param acEnableAvailable Availability of the control of turn on/off AC
-/// @param acMaxEnableAvailable Availability of the control of enable/disable air conditioning is ON on the maximum level
-/// @param circulateAirEnableAvailable Availability of the control of enable/disable circulate Air mode
-/// @param autoModeEnableAvailable Availability of the control of enable/disable auto mode
-/// @param dualModeEnableAvailable Availability of the control of enable/disable dual mode
-/// @param defrostZoneAvailable Availability of the control of defrost zones
-/// @param ventilationModeAvailable Availability of the control of air ventilation mode
-/// @param heatedSteeringWheelAvailable Availability of the control (enable/disable) of heated Steering Wheel
-/// @param heatedWindshieldAvailable Availability of the control (enable/disable) of heated Windshield
-/// @param heatedRearWindowAvailable Availability of the control (enable/disable) of heated Rear Window
-/// @param heatedMirrorsAvailable Availability of the control (enable/disable) of heated Mirrors
-/// @return An SDLClimateControlCapabilities object
-- (instancetype)initWithModuleName:(NSString *)moduleName fanSpeedAvailable:(BOOL)fanSpeedAvailable desiredTemperatureAvailable:(BOOL)desiredTemperatureAvailable acEnableAvailable:(BOOL)acEnableAvailable acMaxEnableAvailable:(BOOL)acMaxEnableAvailable circulateAirAvailable:(BOOL)circulateAirEnableAvailable autoModeEnableAvailable:(BOOL)autoModeEnableAvailable dualModeEnableAvailable:(BOOL)dualModeEnableAvailable defrostZoneAvailable:(BOOL)defrostZoneAvailable ventilationModeAvailable:(BOOL)ventilationModeAvailable heatedSteeringWheelAvailable:(BOOL)heatedSteeringWheelAvailable heatedWindshieldAvailable:(BOOL)heatedWindshieldAvailable heatedRearWindowAvailable:(BOOL)heatedRearWindowAvailable heatedMirrorsAvailable:(BOOL)heatedMirrorsAvailable __deprecated_msg("Use initWithModuleName:fanSpeedAvailable:desiredTemperatureAvailable:acEnableAvailable:acMaxEnableAvailable:circulateAirAvailable:autoModeEnableAvailable: dualModeEnableAvailable:defrostZoneAvailable:ventilationModeAvailable: heatedSteeringWheelAvailable:heatedWindshieldAvailable: heatedRearWindowAvailable:heatedMirrorsAvailable: climateEnableAvailable: instead");
-
-/// Convenience init to describe the climate control capabilities.
-///
-/// @param moduleName The short friendly name of the climate control module
-/// @param fanSpeedAvailable Availability of the control of fan speed
-/// @param desiredTemperatureAvailable Availability of the control of desired temperature
-/// @param acEnableAvailable Availability of the control of turn on/off AC
-/// @param acMaxEnableAvailable Availability of the control of enable/disable air conditioning is ON on the maximum level
-/// @param circulateAirEnableAvailable Availability of the control of enable/disable circulate Air mode
-/// @param autoModeEnableAvailable Availability of the control of enable/disable auto mode
-/// @param dualModeEnableAvailable Availability of the control of enable/disable dual mode
-/// @param defrostZoneAvailable Availability of the control of defrost zones
-/// @param ventilationModeAvailable Availability of the control of air ventilation mode
-/// @param heatedSteeringWheelAvailable Availability of the control (enable/disable) of heated Steering Wheel
-/// @param heatedWindshieldAvailable Availability of the control (enable/disable) of heated Windshield
-/// @param heatedRearWindowAvailable Availability of the control (enable/disable) of heated Rear Window
-/// @param heatedMirrorsAvailable Availability of the control (enable/disable) of heated Mirrors
-/// @param climateEnableAvailable Availability of the control of enable/disable climate control
-/// @return An SDLClimateControlCapabilities object
-- (instancetype)initWithModuleName:(NSString *)moduleName fanSpeedAvailable:(BOOL)fanSpeedAvailable desiredTemperatureAvailable:(BOOL)desiredTemperatureAvailable acEnableAvailable:(BOOL)acEnableAvailable acMaxEnableAvailable:(BOOL)acMaxEnableAvailable circulateAirAvailable:(BOOL)circulateAirEnableAvailable autoModeEnableAvailable:(BOOL)autoModeEnableAvailable dualModeEnableAvailable:(BOOL)dualModeEnableAvailable defrostZoneAvailable:(BOOL)defrostZoneAvailable ventilationModeAvailable:(BOOL)ventilationModeAvailable heatedSteeringWheelAvailable:(BOOL)heatedSteeringWheelAvailable heatedWindshieldAvailable:(BOOL)heatedWindshieldAvailable heatedRearWindowAvailable:(BOOL)heatedRearWindowAvailable heatedMirrorsAvailable:(BOOL)heatedMirrorsAvailable climateEnableAvailable:(BOOL)climateEnableAvailable __deprecated_msg("Use initWithModuleName: moduleId:fanSpeedAvailable:desiredTemperatureAvailable:acEnableAvailable:acMaxEnableAvailable:circulateAirAvailable:autoModeEnableAvailable: dualModeEnableAvailable:defrostZoneAvailable:ventilationModeAvailable: heatedSteeringWheelAvailable:heatedWindshieldAvailable: heatedRearWindowAvailable:heatedMirrorsAvailable: climateEnableAvailable: instead");
-
/// Convenience init to describe the climate control capabilities with all properities.
///
/// @param moduleName The short friendly name of the climate control module.
diff --git a/SmartDeviceLink/public/SDLClimateControlCapabilities.m b/SmartDeviceLink/public/SDLClimateControlCapabilities.m
index 5742cb82c..fb173cfed 100644
--- a/SmartDeviceLink/public/SDLClimateControlCapabilities.m
+++ b/SmartDeviceLink/public/SDLClimateControlCapabilities.m
@@ -10,18 +10,6 @@ NS_ASSUME_NONNULL_BEGIN
@implementation SDLClimateControlCapabilities
-- (instancetype)initWithModuleName:(NSString *)moduleName fanSpeedAvailable:(BOOL)fanSpeedAvailable desiredTemperatureAvailable:(BOOL)desiredTemperatureAvailable acEnableAvailable:(BOOL)acEnableAvailable acMaxEnableAvailable:(BOOL)acMaxEnableAvailable circulateAirAvailable:(BOOL)circulateAirEnableAvailable autoModeEnableAvailable:(BOOL)autoModeEnableAvailable dualModeEnableAvailable:(BOOL)dualModeEnableAvailable defrostZoneAvailable:(BOOL)defrostZoneAvailable ventilationModeAvailable:(BOOL)ventilationModeAvailable {
- return [self initWithModuleName:moduleName fanSpeedAvailable:fanSpeedAvailable desiredTemperatureAvailable:desiredTemperatureAvailable acEnableAvailable:acEnableAvailable acMaxEnableAvailable:acMaxEnableAvailable circulateAirAvailable:circulateAirEnableAvailable autoModeEnableAvailable:autoModeEnableAvailable dualModeEnableAvailable:dualModeEnableAvailable defrostZoneAvailable:defrostZoneAvailable ventilationModeAvailable:ventilationModeAvailable heatedSteeringWheelAvailable:NO heatedWindshieldAvailable:NO heatedRearWindowAvailable:NO heatedMirrorsAvailable:NO];
-}
-
-- (instancetype)initWithModuleName:(NSString *)moduleName fanSpeedAvailable:(BOOL)fanSpeedAvailable desiredTemperatureAvailable:(BOOL)desiredTemperatureAvailable acEnableAvailable:(BOOL)acEnableAvailable acMaxEnableAvailable:(BOOL)acMaxEnableAvailable circulateAirAvailable:(BOOL)circulateAirEnableAvailable autoModeEnableAvailable:(BOOL)autoModeEnableAvailable dualModeEnableAvailable:(BOOL)dualModeEnableAvailable defrostZoneAvailable:(BOOL)defrostZoneAvailable ventilationModeAvailable:(BOOL)ventilationModeAvailable heatedSteeringWheelAvailable:(BOOL)steeringWheelAvailable heatedWindshieldAvailable:(BOOL)windshieldAvailable heatedRearWindowAvailable:(BOOL)rearWindowAvailable heatedMirrorsAvailable:(BOOL)mirrorsAvailable {
- return [self initWithModuleName:moduleName fanSpeedAvailable:fanSpeedAvailable desiredTemperatureAvailable:desiredTemperatureAvailable acEnableAvailable:acEnableAvailable acMaxEnableAvailable:acMaxEnableAvailable circulateAirAvailable:circulateAirEnableAvailable autoModeEnableAvailable:autoModeEnableAvailable dualModeEnableAvailable:dualModeEnableAvailable defrostZoneAvailable:defrostZoneAvailable ventilationModeAvailable:ventilationModeAvailable heatedSteeringWheelAvailable:steeringWheelAvailable heatedWindshieldAvailable:windshieldAvailable heatedRearWindowAvailable:rearWindowAvailable heatedMirrorsAvailable:mirrorsAvailable climateEnableAvailable:NO];
-}
-
-- (instancetype)initWithModuleName:(NSString *)moduleName fanSpeedAvailable:(BOOL)fanSpeedAvailable desiredTemperatureAvailable:(BOOL)desiredTemperatureAvailable acEnableAvailable:(BOOL)acEnableAvailable acMaxEnableAvailable:(BOOL)acMaxEnableAvailable circulateAirAvailable:(BOOL)circulateAirEnableAvailable autoModeEnableAvailable:(BOOL)autoModeEnableAvailable dualModeEnableAvailable:(BOOL)dualModeEnableAvailable defrostZoneAvailable:(BOOL)defrostZoneAvailable ventilationModeAvailable:(BOOL)ventilationModeAvailable heatedSteeringWheelAvailable:(BOOL)steeringWheelAvailable heatedWindshieldAvailable:(BOOL)windshieldAvailable heatedRearWindowAvailable:(BOOL)rearWindowAvailable heatedMirrorsAvailable:(BOOL)mirrorsAvailable climateEnableAvailable:(BOOL)climateEnableAvailable{
- return [self initWithModuleName:moduleName moduleInfo:nil fanSpeedAvailable:fanSpeedAvailable desiredTemperatureAvailable:desiredTemperatureAvailable acEnableAvailable:acEnableAvailable acMaxEnableAvailable:acMaxEnableAvailable circulateAirAvailable:circulateAirEnableAvailable autoModeEnableAvailable:autoModeEnableAvailable dualModeEnableAvailable:dualModeEnableAvailable defrostZoneAvailable:defrostZoneAvailable ventilationModeAvailable:ventilationModeAvailable heatedSteeringWheelAvailable:steeringWheelAvailable heatedWindshieldAvailable:windshieldAvailable heatedRearWindowAvailable:rearWindowAvailable heatedMirrorsAvailable:mirrorsAvailable climateEnableAvailable:NO];
-}
-
- (instancetype)initWithModuleName:(NSString *)moduleName moduleInfo:(nullable SDLModuleInfo *)moduleInfo fanSpeedAvailable:(BOOL)fanSpeedAvailable desiredTemperatureAvailable:(BOOL)desiredTemperatureAvailable acEnableAvailable:(BOOL)acEnableAvailable acMaxEnableAvailable:(BOOL)acMaxEnableAvailable circulateAirAvailable:(BOOL)circulateAirEnableAvailable autoModeEnableAvailable:(BOOL)autoModeEnableAvailable dualModeEnableAvailable:(BOOL)dualModeEnableAvailable defrostZoneAvailable:(BOOL)defrostZoneAvailable ventilationModeAvailable:(BOOL)ventilationModeAvailable heatedSteeringWheelAvailable:(BOOL)steeringWheelAvailable heatedWindshieldAvailable:(BOOL)windshieldAvailable heatedRearWindowAvailable:(BOOL)rearWindowAvailable heatedMirrorsAvailable:(BOOL)mirrorsAvailable climateEnableAvailable:(BOOL)climateEnableAvailable{
self = [self init];
if (!self) {
diff --git a/SmartDeviceLink/public/SDLClimateControlData.h b/SmartDeviceLink/public/SDLClimateControlData.h
index f811967d5..7282c70ce 100644
--- a/SmartDeviceLink/public/SDLClimateControlData.h
+++ b/SmartDeviceLink/public/SDLClimateControlData.h
@@ -16,36 +16,6 @@ NS_ASSUME_NONNULL_BEGIN
*/
@interface SDLClimateControlData : SDLRPCStruct
-/// Convenience init for climate control data.
-/// @param fanSpeed Speed of Fan in integer
-/// @param desiredTemperature Desired Temperature in SDLTemperature
-/// @param acEnable Represents if AC is enabled
-/// @param circulateAirEnable Represents if circulation of air is enabled
-/// @param autoModeEnable Represents if auto mode is enabled
-/// @param defrostZone Represents the kind of defrost zone
-/// @param dualModeEnable Represents if dual mode is enabled
-/// @param acMaxEnable Represents if ac max is enabled
-/// @param ventilationMode Represents the kind of ventilation zone
-/// @return An SDLClimateControlData object
-- (instancetype)initWithFanSpeed:(nullable NSNumber<SDLInt> *)fanSpeed desiredTemperature:(nullable SDLTemperature *)desiredTemperature acEnable:(nullable NSNumber<SDLBool> *)acEnable circulateAirEnable:(nullable NSNumber<SDLBool> *)circulateAirEnable autoModeEnable:(nullable NSNumber<SDLBool> *)autoModeEnable defrostZone:(nullable SDLDefrostZone)defrostZone dualModeEnable:(nullable NSNumber<SDLBool> *)dualModeEnable acMaxEnable:(nullable NSNumber<SDLBool> *)acMaxEnable ventilationMode:(nullable SDLVentilationMode)ventilationMode __deprecated_msg("Use initWithFanSpeed:desiredTemperature:acEnable:circulateAirEnable:autoModeEnable:defrostZone: dualModeEnable:acMaxEnable:ventilationMode:heatedSteeringWheelEnable: heatedWindshieldEnable:heatedRearWindowEnable:heatedMirrorsEnable:climateEnable instead");
-
-/// Convenience init for climate control data.
-/// @param fanSpeed Speed of Fan in integer
-/// @param desiredTemperature Desired Temperature in SDLTemperature
-/// @param acEnable Represents if AC is enabled
-/// @param circulateAirEnable Represents if circulation of air is enabled
-/// @param autoModeEnable Represents if auto mode is enabled
-/// @param defrostZone Represents the kind of defrost zone
-/// @param dualModeEnable Represents if dual mode is enabled
-/// @param acMaxEnable Represents if ac max is enabled
-/// @param ventilationMode Represents the kind of ventilation zone
-/// @param heatedSteeringWheelEnable Represents if heated steering wheel is enabled
-/// @param heatedWindshieldEnable Represents if heated windshield is enabled
-/// @param heatedRearWindowEnable Represents if heated rear window is enabled
-/// @param heatedMirrorsEnable Represents if heated mirrors are enabled
-/// @return An SDLClimateControlData object
-- (instancetype)initWithFanSpeed:(nullable NSNumber<SDLInt> *)fanSpeed desiredTemperature:(nullable SDLTemperature *)desiredTemperature acEnable:(nullable NSNumber<SDLBool> *)acEnable circulateAirEnable:(nullable NSNumber<SDLBool> *)circulateAirEnable autoModeEnable:(nullable NSNumber<SDLBool> *)autoModeEnable defrostZone:(nullable SDLDefrostZone)defrostZone dualModeEnable:(nullable NSNumber<SDLBool> *)dualModeEnable acMaxEnable:(nullable NSNumber<SDLBool> *)acMaxEnable ventilationMode:(nullable SDLVentilationMode)ventilationMode heatedSteeringWheelEnable:(nullable NSNumber<SDLBool> *)heatedSteeringWheelEnable heatedWindshieldEnable:(nullable NSNumber<SDLBool> *)heatedWindshieldEnable heatedRearWindowEnable:(nullable NSNumber<SDLBool> *)heatedRearWindowEnable heatedMirrorsEnable:(nullable NSNumber<SDLBool> *)heatedMirrorsEnable __deprecated_msg("Use initWithFanSpeed:desiredTemperature:acEnable:circulateAirEnable:autoModeEnable:defrostZone: dualModeEnable:acMaxEnable:ventilationMode:heatedSteeringWheelEnable: heatedWindshieldEnable:heatedRearWindowEnable:heatedMirrorsEnable:climateEnable instead");
-
/// Convenience init for climate control data with all properties.
/// @param fanSpeed Speed of Fan in integer
/// @param desiredTemperature Desired Temperature in SDLTemperature
diff --git a/SmartDeviceLink/public/SDLClimateControlData.m b/SmartDeviceLink/public/SDLClimateControlData.m
index bed8ba365..8d5482845 100644
--- a/SmartDeviceLink/public/SDLClimateControlData.m
+++ b/SmartDeviceLink/public/SDLClimateControlData.m
@@ -11,33 +11,6 @@ NS_ASSUME_NONNULL_BEGIN
@implementation SDLClimateControlData
-- (instancetype)initWithFanSpeed:(nullable NSNumber<SDLInt> *)fanSpeed desiredTemperature:(nullable SDLTemperature *)desiredTemperature acEnable:(nullable NSNumber<SDLBool> *)acEnable circulateAirEnable:(nullable NSNumber<SDLBool> *)circulateAirEnable autoModeEnable:(nullable NSNumber<SDLBool> *)autoModeEnable defrostZone:(nullable SDLDefrostZone)defrostZone dualModeEnable:(nullable NSNumber<SDLBool> *)dualModeEnable acMaxEnable:(nullable NSNumber<SDLBool> *)acMaxEnable ventilationMode:(nullable SDLVentilationMode)ventilationMode {
- return [self initWithFanSpeed:fanSpeed desiredTemperature:desiredTemperature acEnable:acEnable circulateAirEnable:circulateAirEnable autoModeEnable:autoModeEnable defrostZone:defrostZone dualModeEnable:dualModeEnable acMaxEnable:acMaxEnable ventilationMode:ventilationMode heatedSteeringWheelEnable:@NO heatedWindshieldEnable:@NO heatedRearWindowEnable:@NO heatedMirrorsEnable:@NO];
-}
-
-- (instancetype)initWithFanSpeed:(nullable NSNumber<SDLInt> *)fanSpeed desiredTemperature:(nullable SDLTemperature *)desiredTemperature acEnable:(nullable NSNumber<SDLBool> *)acEnable circulateAirEnable:(nullable NSNumber<SDLBool> *)circulateAirEnable autoModeEnable:(nullable NSNumber<SDLBool> *)autoModeEnable defrostZone:(nullable SDLDefrostZone)defrostZone dualModeEnable:(nullable NSNumber<SDLBool> *)dualModeEnable acMaxEnable:(nullable NSNumber<SDLBool> *)acMaxEnable ventilationMode:(nullable SDLVentilationMode)ventilationMode heatedSteeringWheelEnable:(nullable NSNumber<SDLBool> *)heatedSteeringWheelEnable heatedWindshieldEnable:(nullable NSNumber<SDLBool> *)heatedWindshieldEnable heatedRearWindowEnable:(nullable NSNumber<SDLBool> *)heatedRearWindowEnable heatedMirrorsEnable:(nullable NSNumber<SDLBool> *)heatedMirrorsEnable {
- self = [self init];
- if (!self) {
- return nil;
- }
-
- self.fanSpeed = fanSpeed;
- self.desiredTemperature = desiredTemperature;
- self.acEnable = acEnable;
- self.circulateAirEnable = circulateAirEnable;
- self.autoModeEnable = autoModeEnable;
- self.defrostZone = defrostZone;
- self.dualModeEnable = dualModeEnable;
- self.acMaxEnable = acMaxEnable;
- self.ventilationMode = ventilationMode;
- self.heatedSteeringWheelEnable = heatedSteeringWheelEnable;
- self.heatedWindshieldEnable = heatedWindshieldEnable;
- self.heatedRearWindowEnable = heatedRearWindowEnable;
- self.heatedMirrorsEnable = heatedMirrorsEnable;
-
- return self;
-}
-
- (instancetype)initWithFanSpeed:(nullable NSNumber<SDLInt> *)fanSpeed desiredTemperature:(nullable SDLTemperature *)desiredTemperature acEnable:(nullable NSNumber<SDLBool> *)acEnable circulateAirEnable:(nullable NSNumber<SDLBool> *)circulateAirEnable autoModeEnable:(nullable NSNumber<SDLBool> *)autoModeEnable defrostZone:(nullable SDLDefrostZone)defrostZone dualModeEnable:(nullable NSNumber<SDLBool> *)dualModeEnable acMaxEnable:(nullable NSNumber<SDLBool> *)acMaxEnable ventilationMode:(nullable SDLVentilationMode)ventilationMode heatedSteeringWheelEnable:(nullable NSNumber<SDLBool> *)heatedSteeringWheelEnable heatedWindshieldEnable:(nullable NSNumber<SDLBool> *)heatedWindshieldEnable heatedRearWindowEnable:(nullable NSNumber<SDLBool> *)heatedRearWindowEnable heatedMirrorsEnable:(nullable NSNumber<SDLBool> *)heatedMirrorsEnable climateEnable:(nullable NSNumber<SDLBool> *)climateEnable {
self = [self init];
if (!self) {
diff --git a/SmartDeviceLink/public/SDLCompassDirection.h b/SmartDeviceLink/public/SDLCompassDirection.h
index ed11f0310..583753f7a 100644
--- a/SmartDeviceLink/public/SDLCompassDirection.h
+++ b/SmartDeviceLink/public/SDLCompassDirection.h
@@ -9,7 +9,7 @@
*
* @since SDL 2.0
*/
-typedef SDLEnum SDLCompassDirection SDL_SWIFT_ENUM;
+typedef SDLEnum SDLCompassDirection NS_TYPED_ENUM;
/**
* Direction North
diff --git a/SmartDeviceLink/public/SDLComponentVolumeStatus.h b/SmartDeviceLink/public/SDLComponentVolumeStatus.h
index dc710a573..368b20e2b 100644
--- a/SmartDeviceLink/public/SDLComponentVolumeStatus.h
+++ b/SmartDeviceLink/public/SDLComponentVolumeStatus.h
@@ -9,7 +9,7 @@
*
* @since SDL 2.0
*/
-typedef SDLEnum SDLComponentVolumeStatus SDL_SWIFT_ENUM;
+typedef SDLEnum SDLComponentVolumeStatus NS_TYPED_ENUM;
/**
* Unknown SDLComponentVolumeStatus
diff --git a/SmartDeviceLink/public/SDLConfiguration.h b/SmartDeviceLink/public/SDLConfiguration.h
index 17c7dc6ee..063c8c87a 100644
--- a/SmartDeviceLink/public/SDLConfiguration.h
+++ b/SmartDeviceLink/public/SDLConfiguration.h
@@ -75,97 +75,6 @@ NS_ASSUME_NONNULL_BEGIN
*/
- (instancetype)initWithLifecycle:(SDLLifecycleConfiguration *)lifecycleConfig lockScreen:(nullable SDLLockScreenConfiguration *)lockScreenConfig logging:(nullable SDLLogConfiguration *)logConfig streamingMedia:(nullable SDLStreamingMediaConfiguration *)streamingMediaConfig fileManager:(nullable SDLFileManagerConfiguration *)fileManagerConfig encryption:(nullable SDLEncryptionConfiguration *)encryptionConfig;
-
-#pragma mark - Deprecated Initializers
-
-/**
- * Creates a new configuration to be passed to the SDLManager with custom lifecycle, lock screen and logging configurations.
- *
- * @param lifecycleConfig The lifecycle configuration to be used.
- * @param lockScreenConfig The lockscreen configuration to be used. If nil, the `enabledConfiguration` will be used.
- * @param logConfig The logging configuration to be used. If nil, the `defaultConfiguration` will be used.
- * @return The configuration
- */
-- (instancetype)initWithLifecycle:(SDLLifecycleConfiguration *)lifecycleConfig lockScreen:(nullable SDLLockScreenConfiguration *)lockScreenConfig logging:(nullable SDLLogConfiguration *)logConfig __deprecated_msg("Use initWithLifecycle:lockScreen:logging:fileManager:encryption: instead");
-
-/**
- * Creates a new configuration to be passed to the SDLManager with custom lifecycle, lock screen, logging and file manager configurations.
- *
- * @param lifecycleConfig The lifecycle configuration to be used.
- * @param lockScreenConfig The lockscreen configuration to be used. If nil, the `enabledConfiguration` will be used.
- * @param logConfig The logging configuration to be used. If nil, the `defaultConfiguration` will be used.
- * @param fileManagerConfig The file manager configuration to be used or `defaultConfiguration` if nil.
- * @return The configuration
- */
-- (instancetype)initWithLifecycle:(SDLLifecycleConfiguration *)lifecycleConfig lockScreen:(nullable SDLLockScreenConfiguration *)lockScreenConfig logging:(nullable SDLLogConfiguration *)logConfig fileManager:(nullable SDLFileManagerConfiguration *)fileManagerConfig __deprecated_msg("Use initWithLifecycle:lockScreen:logging:fileManager:encryption: instead");
-
-/**
- * Creates a new configuration to be passed to the SDLManager with custom lifecycle, lock screen, logging and streaming media configurations.
- *
- * @param lifecycleConfig The lifecycle configuration to be used.
- * @param lockScreenConfig The lockscreen configuration to be used. If nil, the `enabledConfiguration` will be used.
- * @param logConfig The logging configuration to be used. If nil, the `defaultConfiguration` will be used.
- * @param streamingMediaConfig The streaming media configuration to be used or nil if not used.
- * @return The configuration
- */
-- (instancetype)initWithLifecycle:(SDLLifecycleConfiguration *)lifecycleConfig lockScreen:(nullable SDLLockScreenConfiguration *)lockScreenConfig logging:(nullable SDLLogConfiguration *)logConfig streamingMedia:(nullable SDLStreamingMediaConfiguration *)streamingMediaConfig __deprecated_msg("Use initWithLifecycle:lockScreen:logging:streamingMedia:fileManager:encryption: instead");
-
-/**
- * Creates a new configuration to be passed to the SDLManager with custom lifecycle, lock screen, logging, streaming media and file manager configurations.
- *
- * @param lifecycleConfig The lifecycle configuration to be used.
- * @param lockScreenConfig The lockscreen configuration to be used. If nil, the `enabledConfiguration` will be used.
- * @param logConfig The logging configuration to be used. If nil, the `defaultConfiguration` will be used.
- * @param streamingMediaConfig The streaming media configuration to be used or nil if not used.
- * @param fileManagerConfig The file manager configuration to be used or `defaultConfiguration` if nil.
- * @return The configuration
- */
-- (instancetype)initWithLifecycle:(SDLLifecycleConfiguration *)lifecycleConfig lockScreen:(nullable SDLLockScreenConfiguration *)lockScreenConfig logging:(nullable SDLLogConfiguration *)logConfig streamingMedia:(nullable SDLStreamingMediaConfiguration *)streamingMediaConfig fileManager:(nullable SDLFileManagerConfiguration *)fileManagerConfig __deprecated_msg("Use initWithLifecycle:lockScreen:logging:streamingMedia:fileManager:encryption: instead");
-
-/**
- * Creates a new configuration to be passed to the SDLManager with custom lifecycle, lock screen, logging and file manager configurations.
- *
- * @param lifecycleConfig The lifecycle configuration to be used.
- * @param lockScreenConfig The lockscreen configuration to be used. If nil, the `enabledConfiguration` will be used.
- * @param logConfig The logging configuration to be used. If nil, the `defaultConfiguration` will be used.
- * @param fileManagerConfig The file manager configuration to be used or `defaultConfiguration` if nil.
- * @return The configuration
- */
-+ (instancetype)configurationWithLifecycle:(SDLLifecycleConfiguration *)lifecycleConfig lockScreen:(nullable SDLLockScreenConfiguration *)lockScreenConfig logging:(nullable SDLLogConfiguration *)logConfig fileManager:(nullable SDLFileManagerConfiguration *)fileManagerConfig __deprecated_msg("Use initWithLifecycle:lockScreen:logging:fileManager:encryption: instead") NS_SWIFT_UNAVAILABLE("Use an initializer instead");
-
-/**
- * Creates a new configuration to be passed to the SDLManager with custom lifecycle, lock screen, logging, streaming media and file manager configurations.
- *
- * @param lifecycleConfig The lifecycle configuration to be used.
- * @param lockScreenConfig The lockscreen configuration to be used. If nil, the `enabledConfiguration` will be used.
- * @param logConfig The logging configuration to be used. If nil, the `defaultConfiguration` will be used.
- * @param streamingMediaConfig The streaming media configuration to be used or nil if not used.
- * @param fileManagerConfig The file manager configuration to be used or `defaultConfiguration` if nil.
- * @return The configuration
- */
-+ (instancetype)configurationWithLifecycle:(SDLLifecycleConfiguration *)lifecycleConfig lockScreen:(nullable SDLLockScreenConfiguration *)lockScreenConfig logging:(nullable SDLLogConfiguration *)logConfig streamingMedia:(nullable SDLStreamingMediaConfiguration *)streamingMediaConfig fileManager:(nullable SDLFileManagerConfiguration *)fileManagerConfig __deprecated_msg("Use initWithLifecycle:lockScreen:logging:streamingMedia:fileManager:encryption: instead") NS_SWIFT_UNAVAILABLE("Use an initializer instead");
-
-/**
- * Creates a new configuration to be passed to the SDLManager with custom lifecycle, lock screen, logging and streaming media configurations.
- *
- * @param lifecycleConfig The lifecycle configuration to be used.
- * @param lockScreenConfig The lockscreen configuration to be used. If nil, the `enabledConfiguration` will be used.
- * @param logConfig The logging configuration to be used. If nil, the `defaultConfiguration` will be used.
- * @param streamingMediaConfig The streaming media configuration to be used or nil if not used.
- * @return The configuration
- */
-+ (instancetype)configurationWithLifecycle:(SDLLifecycleConfiguration *)lifecycleConfig lockScreen:(nullable SDLLockScreenConfiguration *)lockScreenConfig logging:(nullable SDLLogConfiguration *)logConfig streamingMedia:(nullable SDLStreamingMediaConfiguration *)streamingMediaConfig __deprecated_msg("Use initWithLifecycle:lockScreen:logging:streamingMedia:fileManager:encryption: instead") NS_SWIFT_UNAVAILABLE("Use an initializer instead");
-
-/**
- * Creates a new configuration to be passed to the SDLManager with custom lifecycle, lock screen and logging configurations.
- *
- * @param lifecycleConfig The lifecycle configuration to be used.
- * @param lockScreenConfig The lockscreen configuration to be used. If nil, the `enabledConfiguration` will be used.
- * @param logConfig The logging configuration to be used. If nil, the `defaultConfiguration` will be used.
- * @return The configuration
- */
-+ (instancetype)configurationWithLifecycle:(SDLLifecycleConfiguration *)lifecycleConfig lockScreen:(nullable SDLLockScreenConfiguration *)lockScreenConfig logging:(nullable SDLLogConfiguration *)logConfig __deprecated_msg("Use initWithLifecycle:lockScreen:logging:fileManager:encryption: instead") NS_SWIFT_UNAVAILABLE("Use an initializer instead");
-
@end
NS_ASSUME_NONNULL_END
diff --git a/SmartDeviceLink/public/SDLConfiguration.m b/SmartDeviceLink/public/SDLConfiguration.m
index bd1e85fdc..360beff91 100644
--- a/SmartDeviceLink/public/SDLConfiguration.m
+++ b/SmartDeviceLink/public/SDLConfiguration.m
@@ -27,14 +27,6 @@ NS_ASSUME_NONNULL_BEGIN
return [self initWithLifecycle:lifecycleConfig lockScreen:lockScreenConfig logging:nil fileManager:nil encryption:nil];
}
-- (instancetype)initWithLifecycle:(SDLLifecycleConfiguration *)lifecycleConfig lockScreen:(nullable SDLLockScreenConfiguration *)lockScreenConfig logging:(nullable SDLLogConfiguration *)logConfig {
- return [self initWithLifecycle:lifecycleConfig lockScreen:lockScreenConfig logging:logConfig fileManager:nil encryption:nil];
-}
-
-- (instancetype)initWithLifecycle:(SDLLifecycleConfiguration *)lifecycleConfig lockScreen:(nullable SDLLockScreenConfiguration *)lockScreenConfig logging:(nullable SDLLogConfiguration *)logConfig fileManager:(nullable SDLFileManagerConfiguration *)fileManagerConfig {
- return [self initWithLifecycle:lifecycleConfig lockScreen:lockScreenConfig logging:logConfig fileManager:fileManagerConfig encryption:nil];
-}
-
- (instancetype)initWithLifecycle:(SDLLifecycleConfiguration *)lifecycleConfig lockScreen:(nullable SDLLockScreenConfiguration *)lockScreenConfig logging:(nullable SDLLogConfiguration *)logConfig fileManager:(nullable SDLFileManagerConfiguration *)fileManagerConfig encryption:(nullable SDLEncryptionConfiguration *)encryptionConfig {
return [self initWithLifecycle:lifecycleConfig lockScreen:lockScreenConfig logging:logConfig streamingMedia:nil fileManager:fileManagerConfig encryption:encryptionConfig];
}
@@ -47,22 +39,6 @@ NS_ASSUME_NONNULL_BEGIN
return [[self alloc] initWithLifecycle:lifecycleConfig lockScreen:lockScreenConfig logging:nil fileManager:nil encryption:nil];
}
-+ (instancetype)configurationWithLifecycle:(SDLLifecycleConfiguration *)lifecycleConfig lockScreen:(nullable SDLLockScreenConfiguration *)lockScreenConfig logging:(nullable SDLLogConfiguration *)logConfig {
- return [self configurationWithLifecycle:lifecycleConfig lockScreen:lockScreenConfig logging:logConfig fileManager:nil];
-}
-
-+ (instancetype)configurationWithLifecycle:(SDLLifecycleConfiguration *)lifecycleConfig lockScreen:(nullable SDLLockScreenConfiguration *)lockScreenConfig logging:(nullable SDLLogConfiguration *)logConfig fileManager:(nullable SDLFileManagerConfiguration *)fileManagerConfig {
- return [[self alloc] initWithLifecycle:lifecycleConfig lockScreen:lockScreenConfig logging:logConfig fileManager:fileManagerConfig encryption:nil];
-}
-
-- (instancetype)initWithLifecycle:(SDLLifecycleConfiguration *)lifecycleConfig lockScreen:(nullable SDLLockScreenConfiguration *)lockScreenConfig logging:(nullable SDLLogConfiguration *)logConfig streamingMedia:(nullable SDLStreamingMediaConfiguration *)streamingMediaConfig {
- return [self initWithLifecycle:lifecycleConfig lockScreen:lockScreenConfig logging:logConfig streamingMedia:streamingMediaConfig fileManager:nil encryption:nil];
-}
-
-- (instancetype)initWithLifecycle:(SDLLifecycleConfiguration *)lifecycleConfig lockScreen:(nullable SDLLockScreenConfiguration *)lockScreenConfig logging:(nullable SDLLogConfiguration *)logConfig streamingMedia:(nullable SDLStreamingMediaConfiguration *)streamingMediaConfig fileManager:(nullable SDLFileManagerConfiguration *)fileManagerConfig {
- return [self initWithLifecycle:lifecycleConfig lockScreen:lockScreenConfig logging:logConfig streamingMedia:streamingMediaConfig fileManager:fileManagerConfig encryption:nil];
-}
-
- (instancetype)initWithLifecycle:(SDLLifecycleConfiguration *)lifecycleConfig lockScreen:(nullable SDLLockScreenConfiguration *)lockScreenConfig logging:(nullable SDLLogConfiguration *)logConfig streamingMedia:(nullable SDLStreamingMediaConfiguration *)streamingMediaConfig fileManager:(nullable SDLFileManagerConfiguration *)fileManagerConfig encryption:(nullable SDLEncryptionConfiguration *)encryptionConfig {
self = [super init];
if (!self) {
@@ -86,24 +62,9 @@ NS_ASSUME_NONNULL_BEGIN
_fileManagerConfig = fileManagerConfig ?: [SDLFileManagerConfiguration defaultConfiguration];
_encryptionConfig = encryptionConfig ?: [SDLEncryptionConfiguration defaultConfiguration];
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- if (_encryptionConfig.securityManagers == nil && _streamingMediaConfig.securityManagers != nil) {
- _encryptionConfig.securityManagers = _streamingMediaConfig.securityManagers;
- }
-#pragma clang diagnostic pop
-
return self;
}
-+ (instancetype)configurationWithLifecycle:(SDLLifecycleConfiguration *)lifecycleConfig lockScreen:(nullable SDLLockScreenConfiguration *)lockScreenConfig logging:(nullable SDLLogConfiguration *)logConfig streamingMedia:(nullable SDLStreamingMediaConfiguration *)streamingMediaConfig {
- return [self configurationWithLifecycle:lifecycleConfig lockScreen:lockScreenConfig logging:logConfig streamingMedia:streamingMediaConfig fileManager:nil];
-}
-
-+ (instancetype)configurationWithLifecycle:(SDLLifecycleConfiguration *)lifecycleConfig lockScreen:(nullable SDLLockScreenConfiguration *)lockScreenConfig logging:(nullable SDLLogConfiguration *)logConfig streamingMedia:(nullable SDLStreamingMediaConfiguration *)streamingMediaConfig fileManager:(nullable SDLFileManagerConfiguration *)fileManagerConfig {
- return [[self alloc] initWithLifecycle:lifecycleConfig lockScreen:lockScreenConfig logging:logConfig streamingMedia:streamingMediaConfig fileManager:fileManagerConfig encryption:nil];
-}
-
#pragma mark - NSCopying
- (id)copyWithZone:(nullable NSZone *)zone {
diff --git a/SmartDeviceLink/public/SDLDefrostZone.h b/SmartDeviceLink/public/SDLDefrostZone.h
index 04519a6a2..a8879745b 100644
--- a/SmartDeviceLink/public/SDLDefrostZone.h
+++ b/SmartDeviceLink/public/SDLDefrostZone.h
@@ -9,7 +9,7 @@
*
* @since SDL 2.0
*/
-typedef SDLEnum SDLDefrostZone SDL_SWIFT_ENUM;
+typedef SDLEnum SDLDefrostZone NS_TYPED_ENUM;
/**
* A SDLDefrostZone with the value of *FRONT*
diff --git a/SmartDeviceLink/public/SDLDeliveryMode.h b/SmartDeviceLink/public/SDLDeliveryMode.h
index 61f9dcf29..3f584f5f4 100644
--- a/SmartDeviceLink/public/SDLDeliveryMode.h
+++ b/SmartDeviceLink/public/SDLDeliveryMode.h
@@ -6,7 +6,7 @@
/**
* Specifies the mode in which the sendLocation request is sent. Used in SendLocation.
*/
-typedef SDLEnum SDLDeliveryMode SDL_SWIFT_ENUM;
+typedef SDLEnum SDLDeliveryMode NS_TYPED_ENUM;
/**
* User is prompted on HMI
diff --git a/SmartDeviceLink/public/SDLDeviceLevelStatus.h b/SmartDeviceLink/public/SDLDeviceLevelStatus.h
index fb6a58d24..d68d8b819 100644
--- a/SmartDeviceLink/public/SDLDeviceLevelStatus.h
+++ b/SmartDeviceLink/public/SDLDeviceLevelStatus.h
@@ -9,7 +9,7 @@
*
* @since SDL 2.0
*/
-typedef SDLEnum SDLDeviceLevelStatus SDL_SWIFT_ENUM;
+typedef SDLEnum SDLDeviceLevelStatus NS_TYPED_ENUM;
/**
* Device battery level is zero bars
diff --git a/SmartDeviceLink/public/SDLDimension.h b/SmartDeviceLink/public/SDLDimension.h
index a1c5ab858..480e1812d 100644
--- a/SmartDeviceLink/public/SDLDimension.h
+++ b/SmartDeviceLink/public/SDLDimension.h
@@ -9,7 +9,7 @@
*
* @since SDL 2.0
*/
-typedef SDLEnum SDLDimension SDL_SWIFT_ENUM;
+typedef SDLEnum SDLDimension NS_TYPED_ENUM;
/**
* No GPS at all
diff --git a/SmartDeviceLink/public/SDLDirection.h b/SmartDeviceLink/public/SDLDirection.h
index 7f21ca385..0eb164559 100644
--- a/SmartDeviceLink/public/SDLDirection.h
+++ b/SmartDeviceLink/public/SDLDirection.h
@@ -11,7 +11,7 @@
/**
* A navigation direction.
*/
-typedef SDLEnum SDLDirection SDL_SWIFT_ENUM;
+typedef SDLEnum SDLDirection NS_TYPED_ENUM;
/**
* Direction left
diff --git a/SmartDeviceLink/public/SDLDisplayCapability.h b/SmartDeviceLink/public/SDLDisplayCapability.h
index 7be6a589e..b021a6a10 100644
--- a/SmartDeviceLink/public/SDLDisplayCapability.h
+++ b/SmartDeviceLink/public/SDLDisplayCapability.h
@@ -23,9 +23,6 @@ NS_ASSUME_NONNULL_BEGIN
*/
- (instancetype)initWithDisplayName:(NSString *)displayName;
-/// This method is broken (the types don't match the parameter names) and will always return nil. Use initWithDisplayName:windowCapabilities:windowTypeSupported: instead.
-- (instancetype)initWithDisplayName:(NSString *)displayName windowTypeSupported:(nullable NSArray<SDLWindowCapability *> *)windowTypeSupported windowCapabilities:(nullable NSArray<SDLWindowTypeCapabilities *> *)windowCapabilities __deprecated_msg("This method is broken and will return nil every time. Use initWithDisplayName:windowCapabilities:windowTypeSupported: instead");
-
/**
Init with all the properities
diff --git a/SmartDeviceLink/public/SDLDisplayCapability.m b/SmartDeviceLink/public/SDLDisplayCapability.m
index 04c23cca2..f70f9c024 100644
--- a/SmartDeviceLink/public/SDLDisplayCapability.m
+++ b/SmartDeviceLink/public/SDLDisplayCapability.m
@@ -28,12 +28,6 @@
return self;
}
-- (instancetype)initWithDisplayName:(NSString *)displayName windowTypeSupported:(NSArray<SDLWindowCapability *> *)windowTypeSupported windowCapabilities:(NSArray<SDLWindowTypeCapabilities *> *)windowCapabilities {
- SDLLogE(@"This method is broken (the types don't match the parameter names) and will always return nil. Use initWithDisplayName:windowCapabilities:windowTypeSupported: instead.");
-
- return nil;
-}
-
- (instancetype)initWithDisplayName:(NSString *)displayName windowCapabilities:(nullable NSArray<SDLWindowCapability *> *)windowCapabilities windowTypeSupported:(nullable NSArray<SDLWindowTypeCapabilities *> *)windowTypeSupported {
self = [self initWithDisplayName:displayName];
if (!self) {
diff --git a/SmartDeviceLink/public/SDLDisplayMode.h b/SmartDeviceLink/public/SDLDisplayMode.h
index e570243f5..c32de0874 100644
--- a/SmartDeviceLink/public/SDLDisplayMode.h
+++ b/SmartDeviceLink/public/SDLDisplayMode.h
@@ -8,7 +8,7 @@
*
* @since SDL 1.0
*/
-typedef SDLEnum SDLDisplayMode SDL_SWIFT_ENUM;
+typedef SDLEnum SDLDisplayMode NS_TYPED_ENUM;
/**
* @abstract Display Mode : DAY
diff --git a/SmartDeviceLink/public/SDLDisplayType.h b/SmartDeviceLink/public/SDLDisplayType.h
index 14ee845f9..89f19db7d 100644
--- a/SmartDeviceLink/public/SDLDisplayType.h
+++ b/SmartDeviceLink/public/SDLDisplayType.h
@@ -9,61 +9,63 @@
@warning This should not be used to identify features of a display, this is a deprecated parameter.
- @since SDL 1.0
+ @deprecated
+ @history SDL 1.0.0
+ @since SDL 5.0.0
*/
-typedef SDLEnum SDLDisplayType SDL_SWIFT_ENUM;
+typedef SDLEnum SDLDisplayType NS_TYPED_ENUM __deprecated;
/**
* This display type provides a 2-line x 20 character "dot matrix" display.
*/
-extern SDLDisplayType const SDLDisplayTypeCID;
+extern SDLDisplayType const SDLDisplayTypeCID __deprecated;
/**
* Display type 2
*/
-extern SDLDisplayType const SDLDisplayTypeType2;
+extern SDLDisplayType const SDLDisplayTypeType2 __deprecated;
/**
* Display type 5
*/
-extern SDLDisplayType const SDLDisplayTypeType5;
+extern SDLDisplayType const SDLDisplayTypeType5 __deprecated;
/**
* This display type provides an 8 inch touchscreen display.
*/
-extern SDLDisplayType const SDLDisplayTypeNGN;
+extern SDLDisplayType const SDLDisplayTypeNGN __deprecated;
/**
* Display type Gen 28 DMA
*/
-extern SDLDisplayType const SDLDisplayTypeGen28DMA;
+extern SDLDisplayType const SDLDisplayTypeGen28DMA __deprecated;
/**
* Display type Gen 26 DMA
*/
-extern SDLDisplayType const SDLDisplayTypeGen26DMA;
+extern SDLDisplayType const SDLDisplayTypeGen26DMA __deprecated;
/**
* Display type MFD3
*/
-extern SDLDisplayType const SDLDisplayTypeMFD3;
+extern SDLDisplayType const SDLDisplayTypeMFD3 __deprecated;
/**
* Display type MFD4
*/
-extern SDLDisplayType const SDLDisplayTypeMFD4;
+extern SDLDisplayType const SDLDisplayTypeMFD4 __deprecated;
/**
* Display type MFD5
*/
-extern SDLDisplayType const SDLDisplayTypeMFD5;
+extern SDLDisplayType const SDLDisplayTypeMFD5 __deprecated;
/**
* Display type Gen 3 8-inch
*/
-extern SDLDisplayType const SDLDisplayTypeGen38Inch;
+extern SDLDisplayType const SDLDisplayTypeGen38Inch __deprecated;
/**
* Display type Generic
*/
-extern SDLDisplayType const SDLDisplayTypeGeneric;
+extern SDLDisplayType const SDLDisplayTypeGeneric __deprecated;
diff --git a/SmartDeviceLink/public/SDLDistanceUnit.h b/SmartDeviceLink/public/SDLDistanceUnit.h
index 12092b92e..6d84ce1fc 100644
--- a/SmartDeviceLink/public/SDLDistanceUnit.h
+++ b/SmartDeviceLink/public/SDLDistanceUnit.h
@@ -6,7 +6,7 @@
/**
* Wiper Status
*/
-typedef SDLEnum SDLDistanceUnit SDL_SWIFT_ENUM;
+typedef SDLEnum SDLDistanceUnit NS_TYPED_ENUM;
/**
* @abstract SDLDistanceUnit: *MILES*
diff --git a/SmartDeviceLink/public/SDLDriverDistractionState.h b/SmartDeviceLink/public/SDLDriverDistractionState.h
index 88b26b36b..147da214f 100644
--- a/SmartDeviceLink/public/SDLDriverDistractionState.h
+++ b/SmartDeviceLink/public/SDLDriverDistractionState.h
@@ -9,7 +9,7 @@
*
* @since SDL 1.0
*/
-typedef SDLEnum SDLDriverDistractionState SDL_SWIFT_ENUM;
+typedef SDLEnum SDLDriverDistractionState NS_TYPED_ENUM;
/**
* Driver distraction rules are in effect.
diff --git a/SmartDeviceLink/public/SDLECallConfirmationStatus.h b/SmartDeviceLink/public/SDLECallConfirmationStatus.h
index 763cf0ec2..eb22847cd 100644
--- a/SmartDeviceLink/public/SDLECallConfirmationStatus.h
+++ b/SmartDeviceLink/public/SDLECallConfirmationStatus.h
@@ -9,7 +9,7 @@
Since SmartDeviceLink 2.0
*/
-typedef SDLEnum SDLECallConfirmationStatus SDL_SWIFT_ENUM;
+typedef SDLEnum SDLECallConfirmationStatus NS_TYPED_ENUM;
/**
No E-Call signal triggered.
diff --git a/SmartDeviceLink/public/SDLElectronicParkBrakeStatus.h b/SmartDeviceLink/public/SDLElectronicParkBrakeStatus.h
index c0faaad55..4a60943b4 100644
--- a/SmartDeviceLink/public/SDLElectronicParkBrakeStatus.h
+++ b/SmartDeviceLink/public/SDLElectronicParkBrakeStatus.h
@@ -7,7 +7,7 @@
/**
Reflects the status of the Electronic Parking Brake. A Vehicle Data Type.
*/
-typedef SDLEnum SDLElectronicParkBrakeStatus SDL_SWIFT_ENUM;
+typedef SDLEnum SDLElectronicParkBrakeStatus NS_TYPED_ENUM;
/**
Parking brake actuators have been fully applied.
diff --git a/SmartDeviceLink/public/SDLElectronicParkBrakeStatus.m b/SmartDeviceLink/public/SDLElectronicParkBrakeStatus.m
index 23b55caa3..7f3ed9d0b 100644
--- a/SmartDeviceLink/public/SDLElectronicParkBrakeStatus.m
+++ b/SmartDeviceLink/public/SDLElectronicParkBrakeStatus.m
@@ -8,7 +8,7 @@
#import "SDLElectronicParkBrakeStatus.h"
-typedef SDLEnum SDLElectronicParkBrakeStatus SDL_SWIFT_ENUM;
+typedef SDLEnum SDLElectronicParkBrakeStatus NS_TYPED_ENUM;
SDLElectronicParkBrakeStatus const SDLElectronicParkBrakeStatusClosed = @"CLOSED";
diff --git a/SmartDeviceLink/public/SDLEmergencyEventType.h b/SmartDeviceLink/public/SDLEmergencyEventType.h
index 4b93558f5..c549f9bf5 100644
--- a/SmartDeviceLink/public/SDLEmergencyEventType.h
+++ b/SmartDeviceLink/public/SDLEmergencyEventType.h
@@ -9,7 +9,7 @@
Since SmartDeviceLink 2.0
*/
-typedef SDLEnum SDLEmergencyEventType SDL_SWIFT_ENUM;
+typedef SDLEnum SDLEmergencyEventType NS_TYPED_ENUM;
/**
No emergency event has happened.
diff --git a/SmartDeviceLink/public/SDLEnum.h b/SmartDeviceLink/public/SDLEnum.h
index c62a733e5..3984eb894 100644
--- a/SmartDeviceLink/public/SDLEnum.h
+++ b/SmartDeviceLink/public/SDLEnum.h
@@ -3,12 +3,11 @@
#import <Foundation/Foundation.h>
-#import "SDLMacros.h"
NS_ASSUME_NONNULL_BEGIN
/// NSString SDLEnum typedef
-typedef NSString* SDLEnum SDL_SWIFT_ENUM;
+typedef NSString* SDLEnum NS_TYPED_ENUM;
/// Extensions to NSString specifically for SDL string enums
@interface NSString (SDLEnum)
diff --git a/SmartDeviceLink/public/SDLFileManager.h b/SmartDeviceLink/public/SDLFileManager.h
index 91a0201d5..24b589a2a 100644
--- a/SmartDeviceLink/public/SDLFileManager.h
+++ b/SmartDeviceLink/public/SDLFileManager.h
@@ -64,15 +64,6 @@ typedef void (^SDLFileManagerStartupCompletionHandler)(BOOL success, NSError *__
- (instancetype)init NS_UNAVAILABLE;
/**
- * Creates a new file manager with a specified connection manager
- *
- * @param manager A connection manager to use to forward on RPCs
- *
- * @return An instance of SDLFileManager
- */
-- (instancetype)initWithConnectionManager:(id<SDLConnectionManagerType>)manager __deprecated_msg("Use initWithConnectionManager:configuration: instead");
-
-/**
* Creates a new file manager with a specified connection manager and configuration
*
* @param manager A connection manager to use to forward on RPCs
diff --git a/SmartDeviceLink/public/SDLFileManager.m b/SmartDeviceLink/public/SDLFileManager.m
index 0e34ab3f5..2acafe62b 100644
--- a/SmartDeviceLink/public/SDLFileManager.m
+++ b/SmartDeviceLink/public/SDLFileManager.m
@@ -61,10 +61,6 @@ SDLFileManagerState *const SDLFileManagerStateStartupError = @"StartupError";
#pragma mark - Lifecycle
-- (instancetype)initWithConnectionManager:(id<SDLConnectionManagerType>)manager {
- return [self initWithConnectionManager:manager configuration:[SDLFileManagerConfiguration defaultConfiguration]];
-}
-
- (instancetype)initWithConnectionManager:(id<SDLConnectionManagerType>)manager configuration:(SDLFileManagerConfiguration *)configuration {
self = [super init];
if (!self) {
diff --git a/SmartDeviceLink/public/SDLFileType.h b/SmartDeviceLink/public/SDLFileType.h
index 00612e1d0..8dca7e87c 100644
--- a/SmartDeviceLink/public/SDLFileType.h
+++ b/SmartDeviceLink/public/SDLFileType.h
@@ -9,7 +9,7 @@
*
* @since SDL 2.0
*/
-typedef SDLEnum SDLFileType SDL_SWIFT_ENUM;
+typedef SDLEnum SDLFileType NS_TYPED_ENUM;
/**
* file type: Bitmap (BMP)
diff --git a/SmartDeviceLink/public/SDLFuelCutoffStatus.h b/SmartDeviceLink/public/SDLFuelCutoffStatus.h
index 22adb18c0..c700b5734 100644
--- a/SmartDeviceLink/public/SDLFuelCutoffStatus.h
+++ b/SmartDeviceLink/public/SDLFuelCutoffStatus.h
@@ -9,7 +9,7 @@
*
* @since SDL 2.0
*/
-typedef SDLEnum SDLFuelCutoffStatus SDL_SWIFT_ENUM;
+typedef SDLEnum SDLFuelCutoffStatus NS_TYPED_ENUM;
/**
* Fuel is cut off
diff --git a/SmartDeviceLink/public/SDLFuelType.h b/SmartDeviceLink/public/SDLFuelType.h
index a87c1f332..646d17f04 100644
--- a/SmartDeviceLink/public/SDLFuelType.h
+++ b/SmartDeviceLink/public/SDLFuelType.h
@@ -11,7 +11,7 @@
/**
* Enumeration listing possible fuel types.
*/
-typedef SDLEnum SDLFuelType SDL_SWIFT_ENUM;
+typedef SDLEnum SDLFuelType NS_TYPED_ENUM;
/**
* Fuel type: Gasoline
diff --git a/SmartDeviceLink/public/SDLGetInteriorVehicleData.h b/SmartDeviceLink/public/SDLGetInteriorVehicleData.h
index baddec94d..2f0e08783 100644
--- a/SmartDeviceLink/public/SDLGetInteriorVehicleData.h
+++ b/SmartDeviceLink/public/SDLGetInteriorVehicleData.h
@@ -39,24 +39,6 @@ NS_ASSUME_NONNULL_BEGIN
/// @return An SDLGetInteriorVehicleData object
- (instancetype)initAndUnsubscribeToModuleType:(SDLModuleType)moduleType moduleId:(NSString *)moduleId;
-/// Convenience init to get information of a particular module type.
-///
-/// @param moduleType The type of a RC module to retrieve module data from the vehicle
-/// @return An SDLGetInteriorVehicleData object
-- (instancetype)initWithModuleType:(SDLModuleType)moduleType __deprecated_msg("Use initWithModuleType:moduleId: instead");
-
-/// Convenience init to get information and subscribe to a particular module type.
-///
-/// @param moduleType The type of a RC module to retrieve module data from the vehicle
-/// @return An SDLGetInteriorVehicleData object
-- (instancetype)initAndSubscribeToModuleType:(SDLModuleType)moduleType __deprecated_msg("Use initAndSubscribeToModuleType:moduleId: instead");
-
-/// Convenience init to unsubscribe from particular module type.
-///
-/// @param moduleType The type of a RC module to retrieve module data from the vehicle
-/// @return An SDLGetInteriorVehicleData object
-- (instancetype)initAndUnsubscribeToModuleType:(SDLModuleType)moduleType __deprecated_msg("Use initAndUnsubscribeToModuleType:moduleId:");
-
/**
* The type of a RC module to retrieve module data from the vehicle.
*
diff --git a/SmartDeviceLink/public/SDLGetInteriorVehicleData.m b/SmartDeviceLink/public/SDLGetInteriorVehicleData.m
index 57f0aa833..520622164 100755
--- a/SmartDeviceLink/public/SDLGetInteriorVehicleData.m
+++ b/SmartDeviceLink/public/SDLGetInteriorVehicleData.m
@@ -58,41 +58,6 @@ NS_ASSUME_NONNULL_BEGIN
return self;
}
-- (instancetype)initWithModuleType:(SDLModuleType)moduleType; {
- self = [self init];
- if (!self) {
- return nil;
- }
-
- self.moduleType = moduleType;
-
- return self;
-}
-
-- (instancetype)initAndSubscribeToModuleType:(SDLModuleType)moduleType {
- self = [self init];
- if (!self) {
- return nil;
- }
-
- self.moduleType = moduleType;
- self.subscribe = @(YES);
-
- return self;
-}
-
-- (instancetype)initAndUnsubscribeToModuleType:(SDLModuleType)moduleType {
- self = [self init];
- if (!self) {
- return nil;
- }
-
- self.moduleType = moduleType;
- self.subscribe = @(NO);
-
- return self;
-}
-
- (void)setModuleType:(SDLModuleType)moduleType {
[self.parameters sdl_setObject:moduleType forName:SDLRPCParameterNameModuleType];
}
diff --git a/SmartDeviceLink/public/SDLGetVehicleData.h b/SmartDeviceLink/public/SDLGetVehicleData.h
index 2fc9644ca..e8c30889c 100644
--- a/SmartDeviceLink/public/SDLGetVehicleData.h
+++ b/SmartDeviceLink/public/SDLGetVehicleData.h
@@ -24,74 +24,6 @@ NS_ASSUME_NONNULL_BEGIN
* @param airbagStatus Get airbagStatus data
* @param beltStatus Get beltStatus data
* @param bodyInformation Get bodyInformation data
- * @param clusterModeStatus Get clusterModeStatus data
- * @param deviceStatus Get deviceStatus data
- * @param driverBraking Get driverBraking data
- * @param eCallInfo Get eCallInfo data
- * @param emergencyEvent Get emergencyEvent data
- * @param engineTorque Get engineTorque data
- * @param externalTemperature Get externalTemperature data
- * @param fuelLevel Get fuelLevel data
- * @param fuelLevelState Get fuelLevelState data
- * @param gps Get gps data
- * @param headLampStatus Get headLampStatus data
- * @param instantFuelConsumption Get instantFuelConsumption data
- * @param myKey Get myKey data
- * @param odometer Get odometer data
- * @param prndl Get prndl data
- * @param rpm Get rpm data
- * @param speed Get speed data
- * @param steeringWheelAngle Get steeringWheelAngle data
- * @param tirePressure Get tirePressure data
- * @param vin Get vin data
- * @param wiperStatus Get wiperStatus data
- * @return A SDLGetVehicleData object
- */
-- (instancetype)initWithAccelerationPedalPosition:(BOOL)accelerationPedalPosition airbagStatus:(BOOL)airbagStatus beltStatus:(BOOL)beltStatus bodyInformation:(BOOL)bodyInformation clusterModeStatus:(BOOL)clusterModeStatus deviceStatus:(BOOL)deviceStatus driverBraking:(BOOL)driverBraking eCallInfo:(BOOL)eCallInfo emergencyEvent:(BOOL)emergencyEvent engineTorque:(BOOL)engineTorque externalTemperature:(BOOL)externalTemperature fuelLevel:(BOOL)fuelLevel fuelLevelState:(BOOL)fuelLevelState gps:(BOOL)gps headLampStatus:(BOOL)headLampStatus instantFuelConsumption:(BOOL)instantFuelConsumption myKey:(BOOL)myKey odometer:(BOOL)odometer prndl:(BOOL)prndl rpm:(BOOL)rpm speed:(BOOL)speed steeringWheelAngle:(BOOL)steeringWheelAngle tirePressure:(BOOL)tirePressure vin:(BOOL)vin wiperStatus:(BOOL)wiperStatus __deprecated_msg("Use initWithGps:speed:rpm:instantFuelConsumption:fuelRange:externalTemperature:turnSignal:vin:gearStatus:tirePressure:odometer:beltStatus:bodyInformation:deviceStatus:driverBraking:wiperStatus:headLampStatus:engineTorque:accPedalPosition:steeringWheelAngle:engineOilLife:electronicParkBrakeStatus:cloudAppVehicleID:stabilityControlsStatus:eCallInfo:airbagStatus:emergencyEvent:clusterModeStatus:myKey:handsOffSteering:windowStatus: instead");
-
-/**
- * Convenience init for getting data for all possible vehicle data items.
- *
- * @param accelerationPedalPosition Get accelerationPedalPosition data
- * @param airbagStatus Get airbagStatus data
- * @param beltStatus Get beltStatus data
- * @param bodyInformation Get bodyInformation data
- * @param clusterModeStatus Get clusterModeStatus data
- * @param deviceStatus Get deviceStatus data
- * @param driverBraking Get driverBraking data
- * @param eCallInfo Get eCallInfo data
- * @param electronicParkBrakeStatus Get electronicParkBrakeStatus data
- * @param emergencyEvent Get emergencyEvent data
- * @param engineOilLife Get engineOilLife data
- * @param engineTorque Get engineTorque data
- * @param externalTemperature Get externalTemperature data
- * @param fuelLevel Get fuelLevel data
- * @param fuelLevelState Get fuelLevelState data
- * @param fuelRange Get fuelRange data
- * @param gps Get gps data
- * @param headLampStatus Get headLampStatus data
- * @param instantFuelConsumption Get instantFuelConsumption data
- * @param myKey Get myKey data
- * @param odometer Get odometer data
- * @param prndl Get prndl data
- * @param rpm Get rpm data
- * @param speed Get speed data
- * @param steeringWheelAngle Get steeringWheelAngle data
- * @param tirePressure Get tirePressure data
- * @param turnSignal Get turnSignal data
- * @param vin Get vin data
- * @param wiperStatus Get wiperStatus data
- * @return A SDLGetVehicleData object
- */
-- (instancetype)initWithAccelerationPedalPosition:(BOOL)accelerationPedalPosition airbagStatus:(BOOL)airbagStatus beltStatus:(BOOL)beltStatus bodyInformation:(BOOL)bodyInformation clusterModeStatus:(BOOL)clusterModeStatus deviceStatus:(BOOL)deviceStatus driverBraking:(BOOL)driverBraking eCallInfo:(BOOL)eCallInfo electronicParkBrakeStatus:(BOOL)electronicParkBrakeStatus emergencyEvent:(BOOL)emergencyEvent engineOilLife:(BOOL)engineOilLife engineTorque:(BOOL)engineTorque externalTemperature:(BOOL)externalTemperature fuelLevel:(BOOL)fuelLevel fuelLevelState:(BOOL)fuelLevelState fuelRange:(BOOL)fuelRange gps:(BOOL)gps headLampStatus:(BOOL)headLampStatus instantFuelConsumption:(BOOL)instantFuelConsumption myKey:(BOOL)myKey odometer:(BOOL)odometer prndl:(BOOL)prndl rpm:(BOOL)rpm speed:(BOOL)speed steeringWheelAngle:(BOOL)steeringWheelAngle tirePressure:(BOOL)tirePressure turnSignal:(BOOL)turnSignal vin:(BOOL)vin wiperStatus:(BOOL)wiperStatus __deprecated_msg("Use initWithGps:speed:rpm:instantFuelConsumption:fuelRange:externalTemperature:turnSignal:vin:gearStatus:tirePressure:odometer:beltStatus:bodyInformation:deviceStatus:driverBraking:wiperStatus:headLampStatus:engineTorque:accPedalPosition:steeringWheelAngle:engineOilLife:electronicParkBrakeStatus:cloudAppVehicleID:stabilityControlsStatus:eCallInfo:airbagStatus:emergencyEvent:clusterModeStatus:myKey:handsOffSteering:windowStatus: instead");
-
-/**
- * Convenience init for getting data for all possible vehicle data items.
- *
- * @param accelerationPedalPosition Get accelerationPedalPosition data
- * @param airbagStatus Get airbagStatus data
- * @param beltStatus Get beltStatus data
- * @param bodyInformation Get bodyInformation data
* @param cloudAppVehicleID Get cloudAppVehicleID data
* @param clusterModeStatus Get clusterModeStatus data
* @param deviceStatus Get deviceStatus data
diff --git a/SmartDeviceLink/public/SDLGetVehicleData.m b/SmartDeviceLink/public/SDLGetVehicleData.m
index 15b4e8063..abae28008 100644
--- a/SmartDeviceLink/public/SDLGetVehicleData.m
+++ b/SmartDeviceLink/public/SDLGetVehicleData.m
@@ -23,32 +23,6 @@ NS_ASSUME_NONNULL_BEGIN
}
#pragma clang diagnostic pop
-- (instancetype)initWithAccelerationPedalPosition:(BOOL)accelerationPedalPosition airbagStatus:(BOOL)airbagStatus beltStatus:(BOOL)beltStatus bodyInformation:(BOOL)bodyInformation clusterModeStatus:(BOOL)clusterModeStatus deviceStatus:(BOOL)deviceStatus driverBraking:(BOOL)driverBraking eCallInfo:(BOOL)eCallInfo emergencyEvent:(BOOL)emergencyEvent engineTorque:(BOOL)engineTorque externalTemperature:(BOOL)externalTemperature fuelLevel:(BOOL)fuelLevel fuelLevelState:(BOOL)fuelLevelState gps:(BOOL)gps headLampStatus:(BOOL)headLampStatus instantFuelConsumption:(BOOL)instantFuelConsumption myKey:(BOOL)myKey odometer:(BOOL)odometer prndl:(BOOL)prndl rpm:(BOOL)rpm speed:(BOOL)speed steeringWheelAngle:(BOOL)steeringWheelAngle tirePressure:(BOOL)tirePressure vin:(BOOL)vin wiperStatus:(BOOL)wiperStatus {
- self = [self initWithGps:@(gps) speed:@(speed) rpm:@(rpm) instantFuelConsumption:@(instantFuelConsumption) fuelRange:nil externalTemperature:@(externalTemperature) turnSignal:nil vin:@(vin) gearStatus:nil tirePressure:@(tirePressure) odometer:@(odometer) beltStatus:@(beltStatus) bodyInformation:@(bodyInformation) deviceStatus:@(deviceStatus) driverBraking:@(driverBraking) wiperStatus:@(wiperStatus) headLampStatus:@(headLampStatus) engineTorque:@(engineTorque) accPedalPosition:@(accelerationPedalPosition) steeringWheelAngle:@(steeringWheelAngle) engineOilLife:nil electronicParkBrakeStatus:nil cloudAppVehicleID:nil stabilityControlsStatus:nil eCallInfo:@(eCallInfo) airbagStatus:@(airbagStatus) emergencyEvent:@(emergencyEvent) clusterModeStatus:@(clusterModeStatus) myKey:@(myKey) handsOffSteering:nil windowStatus:nil];
- if (self) {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- self.fuelLevel = @(fuelLevel);
- self.fuelLevel_State = @(fuelLevelState);
- self.prndl = @(prndl);
-#pragma clang diagnostic pop
- }
- return self;
-}
-
-- (instancetype)initWithAccelerationPedalPosition:(BOOL)accelerationPedalPosition airbagStatus:(BOOL)airbagStatus beltStatus:(BOOL)beltStatus bodyInformation:(BOOL)bodyInformation clusterModeStatus:(BOOL)clusterModeStatus deviceStatus:(BOOL)deviceStatus driverBraking:(BOOL)driverBraking eCallInfo:(BOOL)eCallInfo electronicParkBrakeStatus:(BOOL)electronicParkBrakeStatus emergencyEvent:(BOOL)emergencyEvent engineOilLife:(BOOL)engineOilLife engineTorque:(BOOL)engineTorque externalTemperature:(BOOL)externalTemperature fuelLevel:(BOOL)fuelLevel fuelLevelState:(BOOL)fuelLevelState fuelRange:(BOOL)fuelRange gps:(BOOL)gps headLampStatus:(BOOL)headLampStatus instantFuelConsumption:(BOOL)instantFuelConsumption myKey:(BOOL)myKey odometer:(BOOL)odometer prndl:(BOOL)prndl rpm:(BOOL)rpm speed:(BOOL)speed steeringWheelAngle:(BOOL)steeringWheelAngle tirePressure:(BOOL)tirePressure turnSignal:(BOOL)turnSignal vin:(BOOL)vin wiperStatus:(BOOL)wiperStatus {
- self = [self initWithGps:@(gps) speed:@(speed) rpm:@(rpm) instantFuelConsumption:@(instantFuelConsumption) fuelRange:@(fuelRange) externalTemperature:@(externalTemperature) turnSignal:@(turnSignal) vin:@(vin) gearStatus:nil tirePressure:@(tirePressure) odometer:@(odometer) beltStatus:@(beltStatus) bodyInformation:@(bodyInformation) deviceStatus:@(deviceStatus) driverBraking:@(driverBraking) wiperStatus:@(wiperStatus) headLampStatus:@(headLampStatus) engineTorque:@(engineTorque) accPedalPosition:@(accelerationPedalPosition) steeringWheelAngle:@(steeringWheelAngle) engineOilLife:@(engineOilLife) electronicParkBrakeStatus:@(electronicParkBrakeStatus) cloudAppVehicleID:nil stabilityControlsStatus:nil eCallInfo:@(eCallInfo) airbagStatus:@(airbagStatus) emergencyEvent:@(emergencyEvent) clusterModeStatus:@(clusterModeStatus) myKey:@(myKey) handsOffSteering:nil windowStatus:nil];
- if (self) {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- self.fuelLevel = @(fuelLevel);
- self.fuelLevel_State = @(fuelLevelState);
- self.prndl = @(prndl);
-#pragma clang diagnostic pop
- }
- return self;
-}
-
- (instancetype)initWithAccelerationPedalPosition:(BOOL)accelerationPedalPosition airbagStatus:(BOOL)airbagStatus beltStatus:(BOOL)beltStatus bodyInformation:(BOOL)bodyInformation cloudAppVehicleID:(BOOL)cloudAppVehicleID clusterModeStatus:(BOOL)clusterModeStatus deviceStatus:(BOOL)deviceStatus driverBraking:(BOOL)driverBraking eCallInfo:(BOOL)eCallInfo electronicParkBrakeStatus:(BOOL)electronicParkBrakeStatus emergencyEvent:(BOOL)emergencyEvent engineOilLife:(BOOL)engineOilLife engineTorque:(BOOL)engineTorque externalTemperature:(BOOL)externalTemperature fuelLevel:(BOOL)fuelLevel fuelLevelState:(BOOL)fuelLevelState fuelRange:(BOOL)fuelRange gps:(BOOL)gps headLampStatus:(BOOL)headLampStatus instantFuelConsumption:(BOOL)instantFuelConsumption myKey:(BOOL)myKey odometer:(BOOL)odometer prndl:(BOOL)prndl rpm:(BOOL)rpm speed:(BOOL)speed steeringWheelAngle:(BOOL)steeringWheelAngle tirePressure:(BOOL)tirePressure turnSignal:(BOOL)turnSignal vin:(BOOL)vin wiperStatus:(BOOL)wiperStatus {
self = [self initWithGps:@(gps) speed:@(speed) rpm:@(rpm) instantFuelConsumption:@(instantFuelConsumption) fuelRange:@(fuelRange) externalTemperature:@(externalTemperature) turnSignal:@(turnSignal) vin:@(vin) gearStatus:nil tirePressure:@(tirePressure) odometer:@(odometer) beltStatus:@(beltStatus) bodyInformation:@(bodyInformation) deviceStatus:@(deviceStatus) driverBraking:@(driverBraking) wiperStatus:@(wiperStatus) headLampStatus:@(headLampStatus) engineTorque:@(engineTorque) accPedalPosition:@(accelerationPedalPosition) steeringWheelAngle:@(steeringWheelAngle) engineOilLife:@(engineOilLife) electronicParkBrakeStatus:@(electronicParkBrakeStatus) cloudAppVehicleID:@(cloudAppVehicleID) stabilityControlsStatus:nil eCallInfo:@(eCallInfo) airbagStatus:@(airbagStatus) emergencyEvent:@(emergencyEvent) clusterModeStatus:@(clusterModeStatus) myKey:@(myKey) handsOffSteering:nil windowStatus:nil];
if (self) {
diff --git a/SmartDeviceLink/public/SDLGlobalProperty.h b/SmartDeviceLink/public/SDLGlobalProperty.h
index 9175288cb..60dfef02f 100644
--- a/SmartDeviceLink/public/SDLGlobalProperty.h
+++ b/SmartDeviceLink/public/SDLGlobalProperty.h
@@ -9,7 +9,7 @@
*
* @since SDL 1.0
*/
-typedef SDLEnum SDLGlobalProperty SDL_SWIFT_ENUM;
+typedef SDLEnum SDLGlobalProperty NS_TYPED_ENUM;
/**
* The help prompt to be spoken if the user needs assistance during a user-initiated interaction.
diff --git a/SmartDeviceLink/public/SDLHMILevel.h b/SmartDeviceLink/public/SDLHMILevel.h
index ff457519c..700afd4c4 100644
--- a/SmartDeviceLink/public/SDLHMILevel.h
+++ b/SmartDeviceLink/public/SDLHMILevel.h
@@ -9,7 +9,7 @@
*
* @since SDL 1.0
*/
-typedef SDLEnum SDLHMILevel SDL_SWIFT_ENUM;
+typedef SDLEnum SDLHMILevel NS_TYPED_ENUM;
/**
* The application has full use of the SDL HMI. The app may output via TTS, display, or streaming audio and may gather input via VR, Menu, and button presses
diff --git a/SmartDeviceLink/public/SDLHMISettingsControlCapabilities.h b/SmartDeviceLink/public/SDLHMISettingsControlCapabilities.h
index b79ec606b..d86e284f5 100644
--- a/SmartDeviceLink/public/SDLHMISettingsControlCapabilities.h
+++ b/SmartDeviceLink/public/SDLHMISettingsControlCapabilities.h
@@ -13,15 +13,6 @@ NS_ASSUME_NONNULL_BEGIN
/**
Constructs a newly allocated SDLHMISettingsControlCapabilities object with moduleName
-
- @param moduleName The short friendly name of the hmi setting module
-
- @return An instance of the SDLHMISettingsControlCapabilities class
- */
-- (instancetype)initWithModuleName:(NSString *)moduleName __deprecated_msg("Use initWithModuleName:moduleInfo:");
-
-/**
- Constructs a newly allocated SDLHMISettingsControlCapabilities object with moduleName
@param moduleName The short friendly name of the hmi setting module
@param moduleInfo Information about a RC module, including its id.
@@ -32,18 +23,6 @@ NS_ASSUME_NONNULL_BEGIN
/**
Constructs a newly allocated SDLHMISettingsControlCapabilities object with given parameters
-
- @param moduleName The short friendly name of the hmi setting module
- @param distanceUnitAvailable Availability of the control of distance unit.
- @param temperatureUnitAvailable Availability of the control of temperature unit.
- @param displayModeUnitAvailable Availability of the control of displayMode unit.
-
- @return An instance of the SDLHMISettingsControlCapabilities class
- */
-- (instancetype)initWithModuleName:(NSString *)moduleName distanceUnitAvailable:(BOOL)distanceUnitAvailable temperatureUnitAvailable:(BOOL)temperatureUnitAvailable displayModeUnitAvailable:(BOOL)displayModeUnitAvailable __deprecated_msg("Use initWithModuleName:moduleInfo:distanceUnitAvailable:distanceUnitAvailable:temperatureUnitAvailable:displayModeUnitAvailable:");
-
-/**
- Constructs a newly allocated SDLHMISettingsControlCapabilities object with given parameters
@param moduleName The short friendly name of the hmi setting module.
@param moduleInfo Information about a RC module, including its id.
diff --git a/SmartDeviceLink/public/SDLHMISettingsControlCapabilities.m b/SmartDeviceLink/public/SDLHMISettingsControlCapabilities.m
index d7dab5f6f..c0117b793 100644
--- a/SmartDeviceLink/public/SDLHMISettingsControlCapabilities.m
+++ b/SmartDeviceLink/public/SDLHMISettingsControlCapabilities.m
@@ -9,16 +9,6 @@ NS_ASSUME_NONNULL_BEGIN
@implementation SDLHMISettingsControlCapabilities
-- (instancetype)initWithModuleName:(NSString *)moduleName {
- self = [self init];
- if(!self) {
- return nil;
- }
- self.moduleName = moduleName;
-
- return self;
-}
-
- (instancetype)initWithModuleName:(NSString *)moduleName moduleInfo:(nullable SDLModuleInfo *)moduleInfo {
self = [self init];
if(!self) {
@@ -30,19 +20,6 @@ NS_ASSUME_NONNULL_BEGIN
return self;
}
-- (instancetype)initWithModuleName:(NSString *)moduleName distanceUnitAvailable:(BOOL)distanceUnitAvailable temperatureUnitAvailable:(BOOL)temperatureUnitAvailable displayModeUnitAvailable:(BOOL)displayModeUnitAvailable {
- self = [self init];
- if(!self) {
- return nil;
- }
- self.moduleName = moduleName;
- self.distanceUnitAvailable = @(distanceUnitAvailable);
- self.temperatureUnitAvailable = @(temperatureUnitAvailable);
- self.displayModeUnitAvailable = @(displayModeUnitAvailable);
-
- return self;
-}
-
- (instancetype)initWithModuleName:(NSString *)moduleName moduleInfo:(nullable SDLModuleInfo *)moduleInfo distanceUnitAvailable:(BOOL)distanceUnitAvailable temperatureUnitAvailable:(BOOL)temperatureUnitAvailable displayModeUnitAvailable:(BOOL)displayModeUnitAvailable {
self = [self init];
if(!self) {
diff --git a/SmartDeviceLink/public/SDLHMIZoneCapabilities.h b/SmartDeviceLink/public/SDLHMIZoneCapabilities.h
index b4b023fa0..b5ba44656 100644
--- a/SmartDeviceLink/public/SDLHMIZoneCapabilities.h
+++ b/SmartDeviceLink/public/SDLHMIZoneCapabilities.h
@@ -9,7 +9,7 @@
*
* @since SDL 1.0
*/
-typedef SDLEnum SDLHMIZoneCapabilities SDL_SWIFT_ENUM;
+typedef SDLEnum SDLHMIZoneCapabilities NS_TYPED_ENUM;
/**
* Indicates HMI available for front seat passengers.
diff --git a/SmartDeviceLink/public/SDLHybridAppPreference.h b/SmartDeviceLink/public/SDLHybridAppPreference.h
index 171edba2c..6b1a56dba 100644
--- a/SmartDeviceLink/public/SDLHybridAppPreference.h
+++ b/SmartDeviceLink/public/SDLHybridAppPreference.h
@@ -11,7 +11,7 @@
/**
* Enumeration for the user's preference of which app type to use when both are available.
*/
-typedef SDLEnum SDLHybridAppPreference SDL_SWIFT_ENUM;
+typedef SDLEnum SDLHybridAppPreference NS_TYPED_ENUM;
/**
* App preference of mobile.
diff --git a/SmartDeviceLink/public/SDLIgnitionStableStatus.h b/SmartDeviceLink/public/SDLIgnitionStableStatus.h
index 4dc750eca..9216e7d22 100644
--- a/SmartDeviceLink/public/SDLIgnitionStableStatus.h
+++ b/SmartDeviceLink/public/SDLIgnitionStableStatus.h
@@ -9,7 +9,7 @@
*
* @since SDL 2.0
*/
-typedef SDLEnum SDLIgnitionStableStatus SDL_SWIFT_ENUM;
+typedef SDLEnum SDLIgnitionStableStatus NS_TYPED_ENUM;
/**
* The current ignition switch status is considered not to be stable.
diff --git a/SmartDeviceLink/public/SDLIgnitionStatus.h b/SmartDeviceLink/public/SDLIgnitionStatus.h
index 519031218..94d7c47e2 100644
--- a/SmartDeviceLink/public/SDLIgnitionStatus.h
+++ b/SmartDeviceLink/public/SDLIgnitionStatus.h
@@ -9,7 +9,7 @@
*
* @since SDL 2.0
*/
-typedef SDLEnum SDLIgnitionStatus SDL_SWIFT_ENUM;
+typedef SDLEnum SDLIgnitionStatus NS_TYPED_ENUM;
/**
* Ignition status currently unknown
diff --git a/SmartDeviceLink/public/SDLImage.h b/SmartDeviceLink/public/SDLImage.h
index 83a05b664..6fba849da 100644
--- a/SmartDeviceLink/public/SDLImage.h
+++ b/SmartDeviceLink/public/SDLImage.h
@@ -21,15 +21,6 @@ NS_ASSUME_NONNULL_BEGIN
*
* @param name The unique name used to upload the image to SDL Core
* @param imageType Describes whether the image is static or dynamic
- * @return A SDLImage object
- */
-- (instancetype)initWithName:(NSString *)name ofType:(SDLImageType)imageType __deprecated_msg("Use initWithName:ofType:isTemplate: instead");
-
-/**
- * Convenience init for displaying a dynamic image. The image must be uploaded to SDL Core before being displayed.
- *
- * @param name The unique name used to upload the image to SDL Core
- * @param imageType Describes whether the image is static or dynamic
* @param isTemplate Whether or not the image is a template that can be (re)colored by the SDL HMI. Static images are templates by default.
* @return A SDLImage object
*/
@@ -39,14 +30,6 @@ NS_ASSUME_NONNULL_BEGIN
* Convenience init for displaying a dynamic image. The image must be uploaded to SDL Core before being displayed.
*
* @param name The unique name used to upload the image to SDL Core
- * @return A SDLImage object
- */
-- (instancetype)initWithName:(NSString *)name __deprecated_msg("Use initWithName:isTemplate: instead");
-
-/**
- * Convenience init for displaying a dynamic image. The image must be uploaded to SDL Core before being displayed.
- *
- * @param name The unique name used to upload the image to SDL Core
* @param isTemplate Whether or not the image is a template that can be (re)colored by the SDL HMI
* @return A SDLImage object
*/
diff --git a/SmartDeviceLink/public/SDLImage.m b/SmartDeviceLink/public/SDLImage.m
index 740cb4584..19c46cffe 100644
--- a/SmartDeviceLink/public/SDLImage.m
+++ b/SmartDeviceLink/public/SDLImage.m
@@ -10,19 +10,6 @@ NS_ASSUME_NONNULL_BEGIN
@implementation SDLImage
-- (instancetype)initWithName:(NSString *)name ofType:(SDLImageType)imageType {
- self = [self init];
- if (!self) {
- return nil;
- }
-
- self.value = name;
- self.imageType = imageType;
- self.isTemplate = @NO;
-
- return self;
-}
-
- (instancetype)initWithName:(NSString *)name ofType:(SDLImageType)imageType isTemplate:(BOOL)isTemplate {
self = [self init];
if (!self) {
@@ -36,10 +23,6 @@ NS_ASSUME_NONNULL_BEGIN
return self;
}
-- (instancetype)initWithName:(NSString *)name {
- return [self initWithName:name ofType:SDLImageTypeDynamic];
-}
-
- (instancetype)initWithName:(NSString *)name isTemplate:(BOOL)isTemplate {
return [self initWithName:name ofType:SDLImageTypeDynamic isTemplate:isTemplate];
}
diff --git a/SmartDeviceLink/public/SDLImageFieldName.h b/SmartDeviceLink/public/SDLImageFieldName.h
index c50e17b04..0bac7e2a8 100644
--- a/SmartDeviceLink/public/SDLImageFieldName.h
+++ b/SmartDeviceLink/public/SDLImageFieldName.h
@@ -38,7 +38,7 @@
@since SmartDeviceLink 3.0
*/
-typedef SDLEnum SDLImageFieldName SDL_SWIFT_ENUM;
+typedef SDLEnum SDLImageFieldName NS_TYPED_ENUM;
/**
The image field for Alert
diff --git a/SmartDeviceLink/public/SDLImageType.h b/SmartDeviceLink/public/SDLImageType.h
index f06245ed3..06c27b78a 100644
--- a/SmartDeviceLink/public/SDLImageType.h
+++ b/SmartDeviceLink/public/SDLImageType.h
@@ -9,7 +9,7 @@
@since SDL 2.0
*/
-typedef SDLEnum SDLImageType SDL_SWIFT_ENUM;
+typedef SDLEnum SDLImageType NS_TYPED_ENUM;
/**
Activate an icon that shipped with the IVI system by passing a hex value.
diff --git a/SmartDeviceLink/public/SDLInteractionMode.h b/SmartDeviceLink/public/SDLInteractionMode.h
index f0ff203a0..326195f43 100644
--- a/SmartDeviceLink/public/SDLInteractionMode.h
+++ b/SmartDeviceLink/public/SDLInteractionMode.h
@@ -9,7 +9,7 @@
@since SDL 1.0
*/
-typedef SDLEnum SDLInteractionMode SDL_SWIFT_ENUM;
+typedef SDLEnum SDLInteractionMode NS_TYPED_ENUM;
/**
Interaction Mode : Manual Only
diff --git a/SmartDeviceLink/public/SDLKeyboardDelegate.h b/SmartDeviceLink/public/SDLKeyboardDelegate.h
index 5637a2a45..652066d64 100644
--- a/SmartDeviceLink/public/SDLKeyboardDelegate.h
+++ b/SmartDeviceLink/public/SDLKeyboardDelegate.h
@@ -66,14 +66,6 @@ typedef void(^SDLKeyboardCharacterSetCompletionHandler)(NSArray<NSString *> *_Nu
- (SDLKeyboardProperties *)customKeyboardConfiguration;
/**
- Implement this if you wish to update the KeyboardProperties.autoCompleteText as the user updates their input. This is called upon a KEYPRESS event.
-
- @param currentInputText The user's full current input text
- @param completionHandler A completion handler to update the autoCompleteText
- */
-- (void)updateAutocompleteWithInput:(NSString *)currentInputText completionHandler:(SDLKeyboardAutocompleteCompletionHandler)completionHandler __deprecated_msg("Use updateAutocompleteWithInput:autoCompleteResultsHandler:");
-
-/**
Implement this if you wish to updated the KeyboardProperties.autoCompleteList as the user updates their input. This is called upon a KEYPRESS event.
This allows you to present a list of options that the user can use to fill in the search / text box with suggestions you provide.
diff --git a/SmartDeviceLink/public/SDLKeyboardEvent.h b/SmartDeviceLink/public/SDLKeyboardEvent.h
index 02fbf7554..1ac7b67e4 100644
--- a/SmartDeviceLink/public/SDLKeyboardEvent.h
+++ b/SmartDeviceLink/public/SDLKeyboardEvent.h
@@ -9,7 +9,7 @@
@since SmartDeviceLink 3.0
*/
-typedef SDLEnum SDLKeyboardEvent SDL_SWIFT_ENUM;
+typedef SDLEnum SDLKeyboardEvent NS_TYPED_ENUM;
/**
The use has pressed the keyboard key (applies to both SINGLE_KEYPRESS and RESEND_CURRENT_ENTRY modes).
diff --git a/SmartDeviceLink/public/SDLKeyboardLayout.h b/SmartDeviceLink/public/SDLKeyboardLayout.h
index ea36434ff..4b4e97550 100644
--- a/SmartDeviceLink/public/SDLKeyboardLayout.h
+++ b/SmartDeviceLink/public/SDLKeyboardLayout.h
@@ -9,7 +9,7 @@
Since SmartDeviceLink 3.0
*/
-typedef SDLEnum SDLKeyboardLayout SDL_SWIFT_ENUM;
+typedef SDLEnum SDLKeyboardLayout NS_TYPED_ENUM;
/**
QWERTY layout (the name comes from the first six keys<br> appearing on the top left letter row of the keyboard and read from left to right)
diff --git a/SmartDeviceLink/public/SDLKeyboardProperties.h b/SmartDeviceLink/public/SDLKeyboardProperties.h
index 19b494eb2..5939d398f 100644
--- a/SmartDeviceLink/public/SDLKeyboardProperties.h
+++ b/SmartDeviceLink/public/SDLKeyboardProperties.h
@@ -21,18 +21,6 @@ NS_ASSUME_NONNULL_BEGIN
@param layout The layout of the keyboard
@param keypressMode The mode of keypresses to use
@param limitedCharacterList A list of characters restricting what the user is allowed to press
- @param autoCompleteText A string to show the user to complete what they are typing
- @return The RPC object
- */
-- (instancetype)initWithLanguage:(nullable SDLLanguage)language layout:(nullable SDLKeyboardLayout)layout keypressMode:(nullable SDLKeypressMode)keypressMode limitedCharacterList:(nullable NSArray<NSString *> *)limitedCharacterList autoCompleteText:(nullable NSString *)autoCompleteText __deprecated_msg(("use initWithLanguagelayout:keypressMode:limitedCharacterList:autoCompleteText:autoCompleteList: instead"));
-
-/**
- Create a Keyboard Properties RPC object
-
- @param language The language to set the keyboard to
- @param layout The layout of the keyboard
- @param keypressMode The mode of keypresses to use
- @param limitedCharacterList A list of characters restricting what the user is allowed to press
@param autoCompleteText A string to show to user to complete what they are typing
@param autoCompleteList A list of strings to show the user to complete what they are typing.
@return The RPC object
diff --git a/SmartDeviceLink/public/SDLKeyboardProperties.m b/SmartDeviceLink/public/SDLKeyboardProperties.m
index 0adb701e2..5f6fa82dd 100644
--- a/SmartDeviceLink/public/SDLKeyboardProperties.m
+++ b/SmartDeviceLink/public/SDLKeyboardProperties.m
@@ -10,10 +10,6 @@ NS_ASSUME_NONNULL_BEGIN
@implementation SDLKeyboardProperties
-- (instancetype)initWithLanguage:(nullable SDLLanguage)language layout:(nullable SDLKeyboardLayout)layout keypressMode:(nullable SDLKeypressMode)keypressMode limitedCharacterList:(nullable NSArray<NSString *> *)limitedCharacterList autoCompleteText:(nullable NSString *)autoCompleteText {
- return [self initWithLanguage:language layout:layout keypressMode:keypressMode limitedCharacterList:limitedCharacterList autoCompleteText:autoCompleteText autoCompleteList:nil];
-}
-
- (instancetype)initWithLanguage:(nullable SDLLanguage)language layout:(nullable SDLKeyboardLayout)layout keypressMode:(nullable SDLKeypressMode)keypressMode limitedCharacterList:(nullable NSArray<NSString *> *)limitedCharacterList autoCompleteText:(nullable NSString *)autoCompleteText autoCompleteList:(nullable NSArray<NSString *> *)autoCompleteList {
self = [self init];
if (!self) {
diff --git a/SmartDeviceLink/public/SDLKeypressMode.h b/SmartDeviceLink/public/SDLKeypressMode.h
index 839926c5f..7607c4d3e 100644
--- a/SmartDeviceLink/public/SDLKeypressMode.h
+++ b/SmartDeviceLink/public/SDLKeypressMode.h
@@ -13,7 +13,7 @@
@since SmartDeviceLink 3.0
*/
-typedef SDLEnum SDLKeypressMode SDL_SWIFT_ENUM;
+typedef SDLEnum SDLKeypressMode NS_TYPED_ENUM;
/**
SINGLE_KEYPRESS:<br>Each and every User`s keypress must be reported (new notification for every newly entered single symbol).
diff --git a/SmartDeviceLink/public/SDLLanguage.h b/SmartDeviceLink/public/SDLLanguage.h
index 0224475b6..98a962625 100644
--- a/SmartDeviceLink/public/SDLLanguage.h
+++ b/SmartDeviceLink/public/SDLLanguage.h
@@ -9,7 +9,7 @@
@since SDL 1.0
*/
-typedef SDLEnum SDLLanguage SDL_SWIFT_ENUM;
+typedef SDLEnum SDLLanguage NS_TYPED_ENUM;
/**
English_SA
diff --git a/SmartDeviceLink/public/SDLLayoutMode.h b/SmartDeviceLink/public/SDLLayoutMode.h
index 3cb7db7ba..583a32578 100644
--- a/SmartDeviceLink/public/SDLLayoutMode.h
+++ b/SmartDeviceLink/public/SDLLayoutMode.h
@@ -9,7 +9,7 @@
*
* @since SDL 3.0
*/
-typedef SDLEnum SDLLayoutMode SDL_SWIFT_ENUM;
+typedef SDLEnum SDLLayoutMode NS_TYPED_ENUM;
/**
* This mode causes the interaction to display the previous set of choices as icons.
diff --git a/SmartDeviceLink/public/SDLLifecycleConfiguration.h b/SmartDeviceLink/public/SDLLifecycleConfiguration.h
index f2b59301b..af14f4402 100644
--- a/SmartDeviceLink/public/SDLLifecycleConfiguration.h
+++ b/SmartDeviceLink/public/SDLLifecycleConfiguration.h
@@ -39,16 +39,6 @@ typedef NS_OPTIONS(NSUInteger, SDLSecondaryTransports) {
/**
* A production configuration that runs using IAP. Additional functionality should be customized on the properties.
*
- * @param appName The name of the app.
- * @param appId The app id to be used. This should be registered with the head unit's manufacturer.
- *
- * @return The lifecycle configuration
- */
-+ (SDLLifecycleConfiguration *)defaultConfigurationWithAppName:(NSString *)appName appId:(NSString *)appId NS_SWIFT_NAME(init(appName:appId:)) __deprecated_msg("Use defaultConfigurationWithAppName:fullAppId: instead");
-
-/**
- * A production configuration that runs using IAP. Additional functionality should be customized on the properties.
- *
* @param appName The name of the app.
* @param fullAppId The full app id to be used. This should be registered with the head unit's manufacturer. When set, the `appId` parameter will be set automatically to the first 10 non-dash characters of the `fullAppId`.
*
@@ -59,20 +49,8 @@ typedef NS_OPTIONS(NSUInteger, SDLSecondaryTransports) {
/**
* A debug configuration that runs using TCP. Additional functionality should be customized on the properties.
*
- * @param appName The name of the app.
- * @param appId The app id to be used. This should be registered with the head unit's manufacturer.
- * @param ipAddress The ip address of the server to connect to
- * @param port The port of the server to connect to
- *
- * @return The lifecycle configuration
- */
-+ (SDLLifecycleConfiguration *)debugConfigurationWithAppName:(NSString *)appName appId:(NSString *)appId ipAddress:(NSString *)ipAddress port:(UInt16)port NS_SWIFT_NAME(init(appName:appId:ipAddress:port:)) __deprecated_msg("Use debugConfigurationWithAppName:fullAppId:ipAddress:port: instead");
-
-/**
- * A debug configuration that runs using TCP. Additional functionality should be customized on the properties.
- *
* @param appName The name of the app.
- * @param fullAppId The full app id to be used. This should be registered with the head unit's manufacturer. When set, the `appId` parameter will be set automatically to the first 10 non-dash characters of the `fullAppId`.
+ * @param fullAppId The full app id to be used. This should be registered with the head unit's manufacturer. When set, the `appId` parameter will be set automatically to the first 10 non-dash characters of the `fullAppId` if the `fullAppId` is a valid UUID string. Otherwise, the `appId` parameter will be set to the same string as the `fullAppId` parameter. If you want to set the `appId` parameter separately, set the `fullAppId` here, then set the `appId` parameter separately.
* @param ipAddress The ip address of the server to connect to
* @param port The port of the server to connect to
*
@@ -107,14 +85,14 @@ typedef NS_OPTIONS(NSUInteger, SDLSecondaryTransports) {
*
* Required
*/
-@property (copy, nonatomic, readonly) NSString *appId;
+@property (copy, nonatomic) NSString *appId;
/**
* The full app id. This must be the same as the full app id received from the SDL developer portal.
*
* Optional
*
- * @discussion The `fullAppId` is used to authenticate apps that connect with head units that implement SDL Core v.5.0 and newer. If connecting with older head units, the `fullAppId` can be truncated to create the required `appId` needed to register the app. The `appId` is the first 10 non-dash ("-") characters of the `fullAppId` (e.g. if you have a `fullAppId` of 123e4567-e89b-12d3-a456-426655440000, the `appId` will be 123e4567e8).
+ * @discussion The `fullAppId` is used to authenticate apps that connect with modules that support RPC spec v.5.0 and newer. If connecting with older modules, the `fullAppId` may be truncated to create the required `appId` needed to register the app on older modules. The `appId` is the first 10 non-dash ("-") characters of the `fullAppId` (e.g. if you have a `fullAppId` of 123e4567-e89b-12d3-a456-426655440000, the `appId` will be 123e4567e8).
*/
@property (copy, nonatomic, nullable, readonly) NSString *fullAppId;
diff --git a/SmartDeviceLink/public/SDLLifecycleConfiguration.m b/SmartDeviceLink/public/SDLLifecycleConfiguration.m
index 09847120d..47af7e63b 100644
--- a/SmartDeviceLink/public/SDLLifecycleConfiguration.m
+++ b/SmartDeviceLink/public/SDLLifecycleConfiguration.m
@@ -31,25 +31,23 @@ static NSUInteger const AppIdCharacterCount = 10;
#pragma mark Lifecycle
-+ (SDLLifecycleConfiguration *)defaultConfigurationWithAppName:(NSString *)appName appId:(NSString *)appId {
- return [[self alloc] initDefaultConfigurationWithAppName:appName fullAppId:nil appId:appId];
-}
-
+ (SDLLifecycleConfiguration *)defaultConfigurationWithAppName:(NSString *)appName fullAppId:(NSString *)fullAppId {
- return [[self alloc] initDefaultConfigurationWithAppName:appName fullAppId:fullAppId appId:fullAppId];
-}
-
-+ (SDLLifecycleConfiguration *)debugConfigurationWithAppName:(NSString *)appName appId:(NSString *)appId ipAddress:(NSString *)ipAddress port:(UInt16)port {
- return [[self alloc] initDefaultConfigurationWithAppName:appName fullAppId:nil appId:appId ipAddress:ipAddress port:port];
+ return [[self alloc] initDefaultConfigurationWithAppName:appName fullAppId:fullAppId];
}
+ (SDLLifecycleConfiguration *)debugConfigurationWithAppName:(NSString *)appName fullAppId:(NSString *)fullAppId ipAddress:(NSString *)ipAddress port:(UInt16)port {
- return [[self alloc] initDefaultConfigurationWithAppName:appName fullAppId:fullAppId appId:fullAppId ipAddress:ipAddress port:port];
+ SDLLifecycleConfiguration *config = [[self alloc] initDefaultConfigurationWithAppName:appName fullAppId:fullAppId];
+
+ config.tcpDebugMode = YES;
+ config.tcpDebugIPAddress = ipAddress;
+ config.tcpDebugPort = port;
+
+ return config;
}
#pragma mark Initalization Helpers
-- (instancetype)initDefaultConfigurationWithAppName:(NSString *)appName fullAppId:(nullable NSString *)fullAppId appId:(NSString *)appId {
+- (instancetype)initDefaultConfigurationWithAppName:(NSString *)appName fullAppId:(NSString *)fullAppId {
self = [super init];
if (!self) {
return nil;
@@ -72,21 +70,11 @@ static NSUInteger const AppIdCharacterCount = 10;
_allowedSecondaryTransports = SDLSecondaryTransportsTCP;
_fullAppId = fullAppId;
- _appId = fullAppId != nil ? [self.class sdlex_shortAppIdFromFullAppId:fullAppId] : appId;
+ _appId = [self.class sdl_isValidUUID:fullAppId] ? [self.class sdl_shortAppIdFromFullAppId:fullAppId] : fullAppId;
return self;
}
-- (instancetype)initDefaultConfigurationWithAppName:(NSString *)appName fullAppId:(nullable NSString *)fullAppId appId:(nullable NSString *)appId ipAddress:(NSString *)ipAddress port:(UInt16)port {
- SDLLifecycleConfiguration *config = [self initDefaultConfigurationWithAppName:appName fullAppId:fullAppId appId:appId];
-
- config.tcpDebugMode = YES;
- config.tcpDebugIPAddress = ipAddress;
- config.tcpDebugPort = port;
-
- return config;
-}
-
#pragma mark - Computed Properties
- (BOOL)isMedia {
@@ -124,8 +112,8 @@ static NSUInteger const AppIdCharacterCount = 10;
* @param fullAppId A `fullAppId`
* @return An `appID` made of the first 10 non-dash characters of the "fullAppID"
*/
-+ (NSString *)sdlex_shortAppIdFromFullAppId:(NSString *)fullAppId {
- NSString *filteredString = [self sdlex_filterDashesFromText:fullAppId];
++ (NSString *)sdl_shortAppIdFromFullAppId:(NSString *)fullAppId {
+ NSString *filteredString = [self sdl_filterDashesFromText:fullAppId];
return [filteredString substringToIndex:MIN(AppIdCharacterCount, filteredString.length)];
}
@@ -135,15 +123,23 @@ static NSUInteger const AppIdCharacterCount = 10;
* @param text The string
* @return The string with all dash characters removed
*/
-+ (NSString *)sdlex_filterDashesFromText:(NSString *)text {
++ (NSString *)sdl_filterDashesFromText:(NSString *)text {
NSCharacterSet *supportedCharacters = [NSCharacterSet characterSetWithCharactersInString:@"-"];
return [[text componentsSeparatedByCharactersInSet:supportedCharacters] componentsJoinedByString:@""];
}
+/// Checks if a string is a valid UUID
+/// @param uuidString A string
+/// @return True if the string is a valid UUID, false if not
++ (BOOL)sdl_isValidUUID:(NSString *)uuidString {
+ NSUUID *uuid = [[NSUUID alloc] initWithUUIDString:uuidString];
+ return uuid == nil ? NO : YES;
+}
+
#pragma mark - NSCopying
- (id)copyWithZone:(nullable NSZone *)zone {
- SDLLifecycleConfiguration *newConfig = [[self.class allocWithZone:zone] initDefaultConfigurationWithAppName:_appName fullAppId:_fullAppId appId:_appId];
+ SDLLifecycleConfiguration *newConfig = [[self.class allocWithZone:zone] initDefaultConfigurationWithAppName:_appName fullAppId:_fullAppId];
newConfig->_tcpDebugMode = _tcpDebugMode;
newConfig->_tcpDebugIPAddress = _tcpDebugIPAddress;
newConfig->_tcpDebugPort = _tcpDebugPort;
diff --git a/SmartDeviceLink/public/SDLLightControlCapabilities.h b/SmartDeviceLink/public/SDLLightControlCapabilities.h
index 13f709904..b062f3afa 100644
--- a/SmartDeviceLink/public/SDLLightControlCapabilities.h
+++ b/SmartDeviceLink/public/SDLLightControlCapabilities.h
@@ -15,16 +15,6 @@ NS_ASSUME_NONNULL_BEGIN
/**
Constructs a newly allocated SDLLightControlCapabilities object with given parameters
-
-
- @param moduleName friendly name of the light control module
- @param supportedLights array of available LightCapabilities
- @return An instance of the SDLLightControlCapabilities class
- */
-- (instancetype)initWithModuleName:(NSString *)moduleName supportedLights:(NSArray<SDLLightCapabilities *> *)supportedLights __deprecated_msg("Use initWithModuleName:moduleInfo:supportedLights:");
-
-/**
- Constructs a newly allocated SDLLightControlCapabilities object with given parameters
@param moduleName friendly name of the light control module
diff --git a/SmartDeviceLink/public/SDLLightControlCapabilities.m b/SmartDeviceLink/public/SDLLightControlCapabilities.m
index 4a899c2dd..759283647 100644
--- a/SmartDeviceLink/public/SDLLightControlCapabilities.m
+++ b/SmartDeviceLink/public/SDLLightControlCapabilities.m
@@ -10,18 +10,6 @@ NS_ASSUME_NONNULL_BEGIN
@implementation SDLLightControlCapabilities
-
-- (instancetype)initWithModuleName:(NSString *)moduleName supportedLights:(NSArray<SDLLightCapabilities *> *)supportedLights {
- self = [self init];
- if(!self) {
- return nil;
- }
- self.moduleName = moduleName;
- self.supportedLights = supportedLights;
-
- return self;
-}
-
- (instancetype)initWithModuleName:(NSString *)moduleName moduleInfo:(nullable SDLModuleInfo *)moduleInfo supportedLights:(NSArray<SDLLightCapabilities *> *)supportedLights {
self = [self init];
if(!self) {
diff --git a/SmartDeviceLink/public/SDLLightName.h b/SmartDeviceLink/public/SDLLightName.h
index 09a954f74..15cda053b 100644
--- a/SmartDeviceLink/public/SDLLightName.h
+++ b/SmartDeviceLink/public/SDLLightName.h
@@ -7,7 +7,7 @@
* The name that identifies the Light
*
*/
-typedef SDLEnum SDLLightName SDL_SWIFT_ENUM;
+typedef SDLEnum SDLLightName NS_TYPED_ENUM;
/**
* @abstract Represents the Light with name FRONT_LEFT_HIGH_BEAM.
diff --git a/SmartDeviceLink/public/SDLLightStatus.h b/SmartDeviceLink/public/SDLLightStatus.h
index ee9fc4ae6..108cd420d 100644
--- a/SmartDeviceLink/public/SDLLightStatus.h
+++ b/SmartDeviceLink/public/SDLLightStatus.h
@@ -7,7 +7,7 @@
* Reflects the status of Light.
*
*/
-typedef SDLEnum SDLLightStatus SDL_SWIFT_ENUM;
+typedef SDLEnum SDLLightStatus NS_TYPED_ENUM;
/**
* @abstract Light status currently on.
diff --git a/SmartDeviceLink/public/SDLLockScreenConfiguration.h b/SmartDeviceLink/public/SDLLockScreenConfiguration.h
index e3e966987..50989c974 100644
--- a/SmartDeviceLink/public/SDLLockScreenConfiguration.h
+++ b/SmartDeviceLink/public/SDLLockScreenConfiguration.h
@@ -39,19 +39,6 @@ typedef NS_ENUM(NSUInteger, SDLLockScreenConfigurationDisplayMode) {
@property (assign, nonatomic) SDLLockScreenConfigurationDisplayMode displayMode;
/**
- * Whether or not the lock screen should be shown in the "lock screen optional" state. Defaults to NO.
- *
- * In order for the "lock screen optional" state to occur, the following must be true:
- * 1. The app should have received at least 1 driver distraction notification (i.e. a `OnDriverDistraction` notification) from SDL Core. Older versions of Core did not send a notification immediately on connection.
- * 2. The driver is not distracted (i.e. the last `OnDriverDistraction` notification received was for a driver distraction state off).
- * 3. The `hmiLevel` can not be `NONE`.
- * 4. If the `hmiLevel` is currently `BACKGROUND` then the previous `hmiLevel` should have been `FULL` or `LIMITED` (i.e. the user should have interacted with app before it was backgrounded).
-
- * Since this has been deprecated, setting this to true will set `displayMode` to `OptionalOrRequired` if `enableAutomaticLockScreen` is true, or will have no effect if it is false.
- */
-@property (assign, nonatomic) BOOL showInOptionalState __deprecated_msg("Use displayMode SDLLockScreenConfigurationDisplayModeOptionalOrRequired to replicate this being YES");
-
-/**
If YES, then the lock screen can be dismissed with a downward swipe on compatible head units. Requires a connection of SDL 6.0+ and the head unit to enable the feature. Defaults to YES.
*/
@property (assign, nonatomic) BOOL enableDismissGesture;
@@ -62,13 +49,6 @@ typedef NS_ENUM(NSUInteger, SDLLockScreenConfigurationDisplayMode) {
@property (assign, nonatomic) BOOL showDeviceLogo;
/**
- If YES, the lock screen should be managed by SDL and automatically engage when necessary. If NO, then the lock screen will never be engaged. Defaults to YES.
-
- Since this has been deprecated, setting this to false will set `displayMode` to `Never`. Setting it back to true will set it to `RequiredOnly` if `showInOptionalState` is false, or `OptionalOrRequired` if it is true.
- */
-@property (assign, nonatomic, readonly) BOOL enableAutomaticLockScreen __deprecated_msg("Use displayMode SDLLockScreenConfigurationDisplayModeNever to replicate this being NO");
-
-/**
* The background color of the lock screen. This could be a branding color, or leave at the default for a dark blue-gray.
*/
@property (copy, nonatomic, readonly) UIColor *backgroundColor;
diff --git a/SmartDeviceLink/public/SDLLockScreenConfiguration.m b/SmartDeviceLink/public/SDLLockScreenConfiguration.m
index c5cdfa8e6..183e3bc1f 100644
--- a/SmartDeviceLink/public/SDLLockScreenConfiguration.m
+++ b/SmartDeviceLink/public/SDLLockScreenConfiguration.m
@@ -22,9 +22,6 @@ NS_ASSUME_NONNULL_BEGIN
}
_displayMode = mode;
- _enableAutomaticLockScreen = (mode == SDLLockScreenConfigurationDisplayModeNever) ? NO : YES;
- _showInOptionalState = (mode == SDLLockScreenConfigurationDisplayModeOptionalOrRequired) ? YES : NO;
-
_enableDismissGesture = enableDismissGesture;
_backgroundColor = backgroundColor;
_appIcon = appIcon;
@@ -62,32 +59,6 @@ NS_ASSUME_NONNULL_BEGIN
}
-#pragma mark - Setters / Getters
-
-- (void)setEnableAutomaticLockScreen:(BOOL)enableAutomaticLockScreen {
- _enableAutomaticLockScreen = enableAutomaticLockScreen;
-
- if (!_enableAutomaticLockScreen) {
- _displayMode = SDLLockScreenConfigurationDisplayModeNever;
- } else if (_showInOptionalState) {
- _displayMode = SDLLockScreenConfigurationDisplayModeOptionalOrRequired;
- } else {
- _displayMode = SDLLockScreenConfigurationDisplayModeRequiredOnly;
- }
-}
-
-- (void)setShowInOptionalState:(BOOL)showInOptionalState {
- _showInOptionalState = showInOptionalState;
-
- if (!_enableAutomaticLockScreen) {
- _displayMode = SDLLockScreenConfigurationDisplayModeNever;
- } else if (_showInOptionalState) {
- _displayMode = SDLLockScreenConfigurationDisplayModeOptionalOrRequired;
- } else {
- _displayMode = SDLLockScreenConfigurationDisplayModeRequiredOnly;
- }
-}
-
#pragma mark - NSCopying
- (id)copyWithZone:(nullable NSZone *)zone {
diff --git a/SmartDeviceLink/public/SDLLockScreenStatus.h b/SmartDeviceLink/public/SDLLockScreenStatus.h
deleted file mode 100644
index d5d4846b9..000000000
--- a/SmartDeviceLink/public/SDLLockScreenStatus.h
+++ /dev/null
@@ -1,29 +0,0 @@
-//
-// SDLLockScreenStatus.h
-// SmartDeviceLink
-//
-
-
-#import "SDLEnum.h"
-
-/**
- Describes what the status of the lock screen should be
-
- Used in OnLockScreenStatus
- */
-typedef SDLEnum SDLLockScreenStatus SDL_SWIFT_ENUM __deprecated;
-
-/**
- * LockScreen is Not Required
- */
-extern SDLLockScreenStatus const SDLLockScreenStatusOff __deprecated;
-
-/**
- * LockScreen is Optional
- */
-extern SDLLockScreenStatus const SDLLockScreenStatusOptional __deprecated;
-
-/**
- * LockScreen is Required
- */
-extern SDLLockScreenStatus const SDLLockScreenStatusRequired __deprecated;
diff --git a/SmartDeviceLink/public/SDLLockScreenStatus.m b/SmartDeviceLink/public/SDLLockScreenStatus.m
deleted file mode 100644
index 4b721ad8f..000000000
--- a/SmartDeviceLink/public/SDLLockScreenStatus.m
+++ /dev/null
@@ -1,10 +0,0 @@
-//
-// SDLLockScreenStatus.m
-// SmartDeviceLink
-//
-
-#import "SDLLockScreenStatus.h"
-
-SDLLockScreenStatus const SDLLockScreenStatusOff = @"OFF";
-SDLLockScreenStatus const SDLLockScreenStatusOptional = @"OPTIONAL";
-SDLLockScreenStatus const SDLLockScreenStatusRequired = @"REQUIRED";
diff --git a/SmartDeviceLink/public/SDLLogConfiguration.h b/SmartDeviceLink/public/SDLLogConfiguration.h
index 4b6b030cf..79347660c 100644
--- a/SmartDeviceLink/public/SDLLogConfiguration.h
+++ b/SmartDeviceLink/public/SDLLogConfiguration.h
@@ -63,7 +63,7 @@ NS_ASSUME_NONNULL_BEGIN
/**
- A default logger for production. This sets the format type to Default, the log level to Error, and only enables the ASL logger.
+ A default logger for production. This sets the format type to Default, the log level to Error, and the target to SDLLogTargetOSLog.
@return A default configuration that may be customized.
*/
diff --git a/SmartDeviceLink/public/SDLLogConfiguration.m b/SmartDeviceLink/public/SDLLogConfiguration.m
index 36141ce45..12f75173e 100644
--- a/SmartDeviceLink/public/SDLLogConfiguration.m
+++ b/SmartDeviceLink/public/SDLLogConfiguration.m
@@ -40,14 +40,7 @@ NS_ASSUME_NONNULL_BEGIN
return nil;
}
- NSOperatingSystemVersion osVersion = [NSProcessInfo processInfo].operatingSystemVersion;
-
- if (osVersion.majorVersion >= 10) {
- _targets = [NSSet setWithArray:@[[SDLLogTargetOSLog logger]]];
- } else {
- _targets = [NSSet setWithArray:@[[SDLLogTargetAppleSystemLog logger]]];
- }
-
+ _targets = [NSSet setWithArray:@[[SDLLogTargetOSLog logger]]];
_modules = [SDLLogFileModuleMap sdlModuleMap];
return self;
diff --git a/SmartDeviceLink/public/SDLLogManager.m b/SmartDeviceLink/public/SDLLogManager.m
index ae0fa317f..8540d21b9 100644
--- a/SmartDeviceLink/public/SDLLogManager.m
+++ b/SmartDeviceLink/public/SDLLogManager.m
@@ -340,11 +340,7 @@ static dispatch_queue_t _logQueue = NULL;
+ (dispatch_queue_t)logQueue {
static dispatch_once_t onceToken;
dispatch_once(&onceToken, ^{
- if (@available(iOS 10.0, *)) {
- _logQueue = dispatch_queue_create_with_target("com.sdl.log", DISPATCH_QUEUE_SERIAL, [SDLGlobals sharedGlobals].sdlProcessingQueue);
- } else {
- _logQueue = [SDLGlobals sharedGlobals].sdlProcessingQueue;
- }
+ _logQueue = dispatch_queue_create_with_target("com.sdl.log", DISPATCH_QUEUE_SERIAL, [SDLGlobals sharedGlobals].sdlProcessingQueue);
});
return _logQueue;
diff --git a/SmartDeviceLink/public/SDLLogTargetAppleSystemLog.h b/SmartDeviceLink/public/SDLLogTargetAppleSystemLog.h
index 39923a124..762059cc2 100644
--- a/SmartDeviceLink/public/SDLLogTargetAppleSystemLog.h
+++ b/SmartDeviceLink/public/SDLLogTargetAppleSystemLog.h
@@ -15,7 +15,10 @@ NS_ASSUME_NONNULL_BEGIN
/**
The Apple System Log target is an iOS 2.0+ compatible log target that logs to both the Console and to the System Log.
+
+ Deprecated. Please use SDLLogTargetOSLog instead.
*/
+__deprecated
@interface SDLLogTargetAppleSystemLog : NSObject <SDLLogTarget>
@end
diff --git a/SmartDeviceLink/public/SDLLogTargetAppleSystemLog.m b/SmartDeviceLink/public/SDLLogTargetAppleSystemLog.m
index c9cb3112b..d587fa231 100644
--- a/SmartDeviceLink/public/SDLLogTargetAppleSystemLog.m
+++ b/SmartDeviceLink/public/SDLLogTargetAppleSystemLog.m
@@ -20,7 +20,10 @@ NS_ASSUME_NONNULL_BEGIN
@end
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wdeprecated-implementations"
@implementation SDLLogTargetAppleSystemLog
+#pragma clang diagnostic pop
+ (id<SDLLogTarget>)logger {
return [[self alloc] init];
diff --git a/SmartDeviceLink/public/SDLLogTargetOSLog.m b/SmartDeviceLink/public/SDLLogTargetOSLog.m
index e5d87c293..c10ed2ba5 100644
--- a/SmartDeviceLink/public/SDLLogTargetOSLog.m
+++ b/SmartDeviceLink/public/SDLLogTargetOSLog.m
@@ -38,21 +38,16 @@ NS_ASSUME_NONNULL_BEGIN
}
- (BOOL)setupLogger {
- // If the iPhone OS is less than 10.0, os_log is not available.
- NSOperatingSystemVersion osVersion = [NSProcessInfo processInfo].operatingSystemVersion;
-
- return osVersion.majorVersion >= 10;
+ return YES;
}
- (void)logWithLog:(SDLLogModel *)log formattedLog:(NSString *)stringLog {
- if (@available(iOS 10.0, *)) {
- NSString *moduleName = log.moduleName ? log.moduleName : @"";
- if (self.clients[moduleName] == nil) {
- self.clients[moduleName] = os_log_create("com.sdl.log", moduleName.UTF8String);
- }
-
- os_log_with_type(self.clients[moduleName], [self oslogLevelForSDLLogLevel:log.level], "%{public}@", log.message);
+ NSString *moduleName = log.moduleName ? log.moduleName : @"";
+ if (self.clients[moduleName] == nil) {
+ self.clients[moduleName] = os_log_create("com.sdl.log", moduleName.UTF8String);
}
+
+ os_log_with_type(self.clients[moduleName], [self oslogLevelForSDLLogLevel:log.level], "%{public}@", log.message);
}
- (void)teardownLogger {
diff --git a/SmartDeviceLink/public/SDLMacros.h b/SmartDeviceLink/public/SDLMacros.h
deleted file mode 100644
index 1ab0bb6d0..000000000
--- a/SmartDeviceLink/public/SDLMacros.h
+++ /dev/null
@@ -1,29 +0,0 @@
-//
-// SDLMacros.h
-// SmartDeviceLink-iOS
-//
-// Created by Muller, Alexander (A.) on 10/17/16.
-// Copyright © 2016 smartdevicelink. All rights reserved.
-//
-
-#ifndef SDLMacros_h
-#define SDLMacros_h
-
-// Resolves issue of pre-xcode 8 versions due to NS_STRING_ENUM unavailability.
-#ifndef SDL_SWIFT_ENUM
- #if __has_attribute(swift_wrapper)
- #define SDL_SWIFT_ENUM NS_STRING_ENUM
- #else
- #define SDL_SWIFT_ENUM
- #endif
-#endif
-
-#ifndef SDL_SUPPORTS_CLASS_PROPERTIES
- #if defined(SWIFT_CLASS_EXTRA)
- #define SDL_SUPPORTS_CLASS_PROPERTIES FOUNDATION_SWIFT_SDK_EPOCH_AT_LEAST(8)
- #else
- #define SDL_SUPPORTS_CLASS_PROPERTIES NO
- #endif
-#endif
-
-#endif /* SDLMacros_h */
diff --git a/SmartDeviceLink/public/SDLMaintenanceModeStatus.h b/SmartDeviceLink/public/SDLMaintenanceModeStatus.h
index 0dba0bc68..ffc7b39ea 100644
--- a/SmartDeviceLink/public/SDLMaintenanceModeStatus.h
+++ b/SmartDeviceLink/public/SDLMaintenanceModeStatus.h
@@ -7,7 +7,7 @@
/**
* Describes the maintenence mode. Used in nothing.
*/
-typedef SDLEnum SDLMaintenanceModeStatus SDL_SWIFT_ENUM;
+typedef SDLEnum SDLMaintenanceModeStatus NS_TYPED_ENUM;
/**
* Maintenance Mode Status : Normal
diff --git a/SmartDeviceLink/public/SDLManagerDelegate.h b/SmartDeviceLink/public/SDLManagerDelegate.h
index f91a5ecb9..2b01af879 100644
--- a/SmartDeviceLink/public/SDLManagerDelegate.h
+++ b/SmartDeviceLink/public/SDLManagerDelegate.h
@@ -61,14 +61,6 @@ NS_ASSUME_NONNULL_BEGIN
/**
* Called when the lifecycle manager detected a language mismatch. In case of a language mismatch the manager should change the apps registration by updating the lifecycle configuration to the specified language. If the app can support the specified language it should return an Object of SDLLifecycleConfigurationUpdate, otherwise it should return nil to indicate that the language is not supported.
*
- * @param language The language of the connected head unit the manager is trying to update the configuration.
- * @return An object of SDLLifecycleConfigurationUpdate if the head unit language is supported, otherwise nil to indicate that the language is not supported.
- */
-- (nullable SDLLifecycleConfigurationUpdate *)managerShouldUpdateLifecycleToLanguage:(SDLLanguage)language __deprecated_msg("Use managerShouldUpdateLifecycleToLanguage:hmiLanguage");
-
-/**
- * Called when the lifecycle manager detected a language mismatch. In case of a language mismatch the manager should change the apps registration by updating the lifecycle configuration to the specified language. If the app can support the specified language it should return an Object of SDLLifecycleConfigurationUpdate, otherwise it should return nil to indicate that the language is not supported.
- *
* @param language The VR+TTS language of the connected head unit the manager is trying to update the configuration.
* @param hmiLanguage The HMI display language of the connected head unit the manager is trying to update the configuration.
* @return An object of SDLLifecycleConfigurationUpdate if the head unit language is supported, otherwise nil to indicate that the language is not supported.
diff --git a/SmartDeviceLink/public/SDLMassageCushion.h b/SmartDeviceLink/public/SDLMassageCushion.h
index f4886d312..a6242ae9a 100644
--- a/SmartDeviceLink/public/SDLMassageCushion.h
+++ b/SmartDeviceLink/public/SDLMassageCushion.h
@@ -6,7 +6,7 @@
/**
* The List possible cushions of a multi-contour massage seat.
*/
-typedef SDLEnum SDLMassageCushion SDL_SWIFT_ENUM;
+typedef SDLEnum SDLMassageCushion NS_TYPED_ENUM;
/**
* @abstract TOP LUMBAR cushions of a multi-contour massage seat
diff --git a/SmartDeviceLink/public/SDLMassageMode.h b/SmartDeviceLink/public/SDLMassageMode.h
index bcd0055ee..d2f85c805 100644
--- a/SmartDeviceLink/public/SDLMassageMode.h
+++ b/SmartDeviceLink/public/SDLMassageMode.h
@@ -6,7 +6,7 @@
/**
* The List possible modes of a massage zone.
*/
-typedef SDLEnum SDLMassageMode SDL_SWIFT_ENUM;
+typedef SDLEnum SDLMassageMode NS_TYPED_ENUM;
/**
* @abstract Massage Mode Status : OFF
diff --git a/SmartDeviceLink/public/SDLMassageZone.h b/SmartDeviceLink/public/SDLMassageZone.h
index 06b7aa438..434dd3941 100644
--- a/SmartDeviceLink/public/SDLMassageZone.h
+++ b/SmartDeviceLink/public/SDLMassageZone.h
@@ -6,7 +6,7 @@
/**
* List possible zones of a multi-contour massage seat.
*/
-typedef SDLEnum SDLMassageZone SDL_SWIFT_ENUM;
+typedef SDLEnum SDLMassageZone NS_TYPED_ENUM;
/**
* @abstract The back of a multi-contour massage seat. or SEAT_BACK
diff --git a/SmartDeviceLink/public/SDLMediaClockFormat.h b/SmartDeviceLink/public/SDLMediaClockFormat.h
index c16ebb8b5..ea45f78f2 100644
--- a/SmartDeviceLink/public/SDLMediaClockFormat.h
+++ b/SmartDeviceLink/public/SDLMediaClockFormat.h
@@ -16,7 +16,7 @@
@since SDL 1.0
*/
-typedef SDLEnum SDLMediaClockFormat SDL_SWIFT_ENUM;
+typedef SDLEnum SDLMediaClockFormat NS_TYPED_ENUM;
/**
* Media clock format: Clock1
diff --git a/SmartDeviceLink/public/SDLMediaServiceData.h b/SmartDeviceLink/public/SDLMediaServiceData.h
index 7d4d6180b..84ce78d1b 100644
--- a/SmartDeviceLink/public/SDLMediaServiceData.h
+++ b/SmartDeviceLink/public/SDLMediaServiceData.h
@@ -23,25 +23,6 @@ NS_ASSUME_NONNULL_BEGIN
* Convenience init
*
* @param mediaType The type of the currently playing or paused track
- * @param mediaTitle The name of the current playing media
- * @param mediaArtist The name of the current media artist
- * @param mediaAlbum The name of the current media album
- * @param playlistName The name of the playlist
- * @param isExplicit Whether or not the content currently playing contains explicit content
- * @param trackPlaybackProgress The current progress of the track
- * @param trackPlaybackDuration The total duration of the track
- * @param queuePlaybackProgress The current progress of the playback queue in seconds
- * @param queuePlaybackDuration The total duration of the playback queue in seconds
- * @param queueCurrentTrackNumber The current number (1 based) of the track in the playback queue
- * @param queueTotalTrackCount The total number of tracks in the playback queue
- * @return A SDLMediaServiceData object
- */
-- (instancetype)initWithMediaType:(nullable SDLMediaType)mediaType mediaTitle:(nullable NSString *)mediaTitle mediaArtist:(nullable NSString *)mediaArtist mediaAlbum:(nullable NSString *)mediaAlbum playlistName:(nullable NSString *)playlistName isExplicit:(BOOL)isExplicit trackPlaybackProgress:(UInt32)trackPlaybackProgress trackPlaybackDuration:(UInt32)trackPlaybackDuration queuePlaybackProgress:(UInt32)queuePlaybackProgress queuePlaybackDuration:(UInt32)queuePlaybackDuration queueCurrentTrackNumber:(UInt32)queueCurrentTrackNumber queueTotalTrackCount:(UInt32)queueTotalTrackCount __deprecated_msg("Use initWithMediaType:mediaImage:mediaTitle:mediaArtist:mediaAlbum:playlistName:isExplicit:trackPlaybackProgress:trackPlaybackDuration:queuePlaybackProgress:queuePlaybackDuration:queueCurrentTrackNumber:queueTotalTrackCount: instead");
-
-/**
- * Convenience init
- *
- * @param mediaType The type of the currently playing or paused track
* @param mediaImage The current artwork for the playing media.
* @param mediaTitle The name of the current playing media
* @param mediaArtist The name of the current media artist
diff --git a/SmartDeviceLink/public/SDLMediaServiceData.m b/SmartDeviceLink/public/SDLMediaServiceData.m
index 911ec7572..7b8e44f3d 100644
--- a/SmartDeviceLink/public/SDLMediaServiceData.m
+++ b/SmartDeviceLink/public/SDLMediaServiceData.m
@@ -16,11 +16,6 @@ NS_ASSUME_NONNULL_BEGIN
@implementation SDLMediaServiceData
-- (instancetype)initWithMediaType:(nullable SDLMediaType)mediaType mediaTitle:(nullable NSString *)mediaTitle mediaArtist:(nullable NSString *)mediaArtist mediaAlbum:(nullable NSString *)mediaAlbum playlistName:(nullable NSString *)playlistName isExplicit:(BOOL)isExplicit trackPlaybackProgress:(UInt32)trackPlaybackProgress trackPlaybackDuration:(UInt32)trackPlaybackDuration queuePlaybackProgress:(UInt32)queuePlaybackProgress queuePlaybackDuration:(UInt32)queuePlaybackDuration queueCurrentTrackNumber:(UInt32)queueCurrentTrackNumber queueTotalTrackCount:(UInt32)queueTotalTrackCount {
-
- return [self initWithMediaType:mediaType mediaImage:nil mediaTitle:mediaTitle mediaArtist:mediaArtist mediaAlbum:mediaAlbum playlistName:playlistName isExplicit:isExplicit trackPlaybackProgress:trackPlaybackProgress trackPlaybackDuration:trackPlaybackDuration queuePlaybackProgress:queuePlaybackProgress queuePlaybackDuration:queuePlaybackDuration queueCurrentTrackNumber:queueCurrentTrackNumber queueTotalTrackCount:queueTotalTrackCount];
-}
-
- (instancetype)initWithMediaType:(nullable SDLMediaType)mediaType mediaImage:(nullable SDLImage *)mediaImage mediaTitle:(nullable NSString *)mediaTitle mediaArtist:(nullable NSString *)mediaArtist mediaAlbum:(nullable NSString *)mediaAlbum playlistName:(nullable NSString *)playlistName isExplicit:(BOOL)isExplicit trackPlaybackProgress:(UInt32)trackPlaybackProgress trackPlaybackDuration:(UInt32)trackPlaybackDuration queuePlaybackProgress:(UInt32)queuePlaybackProgress queuePlaybackDuration:(UInt32)queuePlaybackDuration queueCurrentTrackNumber:(UInt32)queueCurrentTrackNumber queueTotalTrackCount:(UInt32)queueTotalTrackCount {
self = [self init];
if (!self) {
diff --git a/SmartDeviceLink/public/SDLMediaType.h b/SmartDeviceLink/public/SDLMediaType.h
index f7d1943c2..e90d94197 100644
--- a/SmartDeviceLink/public/SDLMediaType.h
+++ b/SmartDeviceLink/public/SDLMediaType.h
@@ -11,7 +11,7 @@
/**
* Enumeration listing possible media types.
*/
-typedef SDLEnum SDLMediaType SDL_SWIFT_ENUM;
+typedef SDLEnum SDLMediaType NS_TYPED_ENUM;
/**
* The app will have a media type of music.
diff --git a/SmartDeviceLink/public/SDLMenuCell.h b/SmartDeviceLink/public/SDLMenuCell.h
index d55360a8b..403294612 100644
--- a/SmartDeviceLink/public/SDLMenuCell.h
+++ b/SmartDeviceLink/public/SDLMenuCell.h
@@ -70,25 +70,6 @@ typedef void(^SDLMenuCellSelectionHandler)(SDLTriggerSource triggerSource);
Create a menu cell that has subcells and when selected will go into a deeper part of the menu
@param title The cell's primary text
- @param subCells The subcells that will appear when the cell is selected
- @return The menu cell
- */
-- (instancetype)initWithTitle:(NSString *)title subCells:(NSArray<SDLMenuCell *> *)subCells __deprecated_msg(("Use initWithTitle:icon:subcells: instead"));
-
-/**
- Create a menu cell that has subcells and when selected will go into a deeper part of the menu
-
- @param title The cell's primary text
- @param icon The cell's image
- @param subCells The subcells that will appear when the cell is selected
- @return The menu cell
- */
-- (instancetype)initWithTitle:(NSString *)title icon:(nullable SDLArtwork *)icon subCells:(NSArray<SDLMenuCell *> *)subCells __deprecated_msg("Use initWithTitle:icon:layout:subcells: instead");
-
-/**
- Create a menu cell that has subcells and when selected will go into a deeper part of the menu
-
- @param title The cell's primary text
@param icon The cell's image
@param layout The layout that the subCells will be layed out in if that submenu is entered
@param subCells The subcells that will appear when the cell is selected
diff --git a/SmartDeviceLink/public/SDLMenuCell.m b/SmartDeviceLink/public/SDLMenuCell.m
index 67281cb21..9a06411bc 100644
--- a/SmartDeviceLink/public/SDLMenuCell.m
+++ b/SmartDeviceLink/public/SDLMenuCell.m
@@ -36,14 +36,6 @@ NS_ASSUME_NONNULL_BEGIN
return self;
}
-- (instancetype)initWithTitle:(NSString *)title subCells:(NSArray<SDLMenuCell *> *)subCells {
- return [self initWithTitle:title icon:nil submenuLayout:nil subCells:subCells];
-}
-
-- (instancetype)initWithTitle:(NSString *)title icon:(nullable SDLArtwork *)icon subCells:(NSArray<SDLMenuCell *> *)subCells {
- return [self initWithTitle:title icon:icon submenuLayout:nil subCells:subCells];
-}
-
- (instancetype)initWithTitle:(NSString *)title icon:(nullable SDLArtwork *)icon submenuLayout:(nullable SDLMenuLayout)layout subCells:(NSArray<SDLMenuCell *> *)subCells {
self = [super init];
if (!self) { return nil; }
diff --git a/SmartDeviceLink/public/SDLMenuLayout.h b/SmartDeviceLink/public/SDLMenuLayout.h
index e2fe8e40a..c4904f5d7 100644
--- a/SmartDeviceLink/public/SDLMenuLayout.h
+++ b/SmartDeviceLink/public/SDLMenuLayout.h
@@ -11,7 +11,7 @@
/**
* Enum for each type of video streaming protocol, used in VideoStreamingFormat
*/
-typedef SDLEnum SDLMenuLayout SDL_SWIFT_ENUM;
+typedef SDLEnum SDLMenuLayout NS_TYPED_ENUM;
/**
* The menu should be laid out in a scrollable list format with one menu cell below the previous, each is stretched across the view
diff --git a/SmartDeviceLink/public/SDLMetadataType.h b/SmartDeviceLink/public/SDLMetadataType.h
index da79a4ac6..0a57a6e08 100644
--- a/SmartDeviceLink/public/SDLMetadataType.h
+++ b/SmartDeviceLink/public/SDLMetadataType.h
@@ -12,7 +12,7 @@
/**
* Text Field metadata types. Used in Show.
*/
-typedef SDLEnum SDLMetadataType SDL_SWIFT_ENUM;
+typedef SDLEnum SDLMetadataType NS_TYPED_ENUM;
/**
* The song / media title name
diff --git a/SmartDeviceLink/public/SDLModuleType.h b/SmartDeviceLink/public/SDLModuleType.h
index c69004e8a..a4091f41d 100644
--- a/SmartDeviceLink/public/SDLModuleType.h
+++ b/SmartDeviceLink/public/SDLModuleType.h
@@ -7,7 +7,7 @@
/**
* The type of remote control data. Used in ButtonPress, GetInteriorVehicleData, and ModuleData
*/
-typedef SDLEnum SDLModuleType SDL_SWIFT_ENUM;
+typedef SDLEnum SDLModuleType NS_TYPED_ENUM;
/**
* A SDLModuleType with the value of *CLIMATE*
diff --git a/SmartDeviceLink/public/SDLNavigationAction.h b/SmartDeviceLink/public/SDLNavigationAction.h
index 6cc0edd9e..7d6ff194a 100644
--- a/SmartDeviceLink/public/SDLNavigationAction.h
+++ b/SmartDeviceLink/public/SDLNavigationAction.h
@@ -11,7 +11,7 @@
/**
* A navigation action.
*/
-typedef SDLEnum SDLNavigationAction SDL_SWIFT_ENUM;
+typedef SDLEnum SDLNavigationAction NS_TYPED_ENUM;
/**
* Using this action plus a supplied direction can give the type of turn.
diff --git a/SmartDeviceLink/public/SDLNavigationJunction.h b/SmartDeviceLink/public/SDLNavigationJunction.h
index 36be6f0db..5ae7ec298 100644
--- a/SmartDeviceLink/public/SDLNavigationJunction.h
+++ b/SmartDeviceLink/public/SDLNavigationJunction.h
@@ -11,7 +11,7 @@
/**
* A navigation junction type.
*/
-typedef SDLEnum SDLNavigationJunction SDL_SWIFT_ENUM;
+typedef SDLEnum SDLNavigationJunction NS_TYPED_ENUM;
/**
* A junction that represents a standard intersection with a single road crossing another.
diff --git a/SmartDeviceLink/public/SDLNotificationConstants.h b/SmartDeviceLink/public/SDLNotificationConstants.h
index ce2b32392..321102cfe 100644
--- a/SmartDeviceLink/public/SDLNotificationConstants.h
+++ b/SmartDeviceLink/public/SDLNotificationConstants.h
@@ -18,15 +18,8 @@
NS_ASSUME_NONNULL_BEGIN
-// Resolves issue of using Swift 3 and pre-iOS 10 versions due to NSNotificationName unavailability.
-#if __IPHONE_OS_VERSION_MAX_ALLOWED <= __IPHONE_9_3
-#define NOTIFICATION_TYPEDEF NSString *
-#else
-#define NOTIFICATION_TYPEDEF NSNotificationName
-#endif
-
/// NSNotification names specific to incoming SDL RPC
-typedef NOTIFICATION_TYPEDEF SDLNotificationName;
+typedef NSNotificationName SDLNotificationName;
/// The key used in all SDL NSNotifications to extract the response or notification from the userInfo dictionary.
typedef NSString *SDLNotificationUserInfoKey;
@@ -139,9 +132,6 @@ extern SDLNotificationName const SDLDidBecomeReady;
/// Name for a notification sent by the user when their CarWindow view has been updated
extern SDLNotificationName const SDLDidUpdateProjectionView;
-/// Name for a LockScreenStatus notification RPC
-extern SDLNotificationName const SDLDidChangeLockScreenStatusNotification __deprecated_msg("This will be replaced in a future version where a fake RPC is not sent");
-
/**
* NSNotification names associated with specific RPC responses.
*/
diff --git a/SmartDeviceLink/public/SDLNotificationConstants.m b/SmartDeviceLink/public/SDLNotificationConstants.m
index c0b0577ed..dc0c7315f 100644
--- a/SmartDeviceLink/public/SDLNotificationConstants.m
+++ b/SmartDeviceLink/public/SDLNotificationConstants.m
@@ -25,7 +25,6 @@ SDLNotificationName const SDLDidReceiveLockScreenIcon = @"com.sdl.general.locksc
SDLNotificationName const SDLDidBecomeReady = @"com.sdl.notification.managerReady";
SDLNotificationName const SDLDidReceiveVehicleIconNotification = @"com.sdl.notification.vehicleIcon";
SDLNotificationName const SDLDidUpdateProjectionView = @"com.sdl.notification.projectionViewUpdate";
-SDLNotificationName const SDLDidChangeLockScreenStatusNotification = @"com.sdl.notification.lockScreenStatus";
#pragma mark - RPC Responses
SDLNotificationName const SDLDidReceiveAddCommandResponse = @"com.sdl.response.AddCommand";
diff --git a/SmartDeviceLink/public/SDLOnLockScreenStatus.m b/SmartDeviceLink/public/SDLOnLockScreenStatus.m
deleted file mode 100644
index 6264ea5fd..000000000
--- a/SmartDeviceLink/public/SDLOnLockScreenStatus.m
+++ /dev/null
@@ -1,68 +0,0 @@
-//
-// SDLOnLockScreenStatus.m
-// SmartDeviceLink
-//
-
-#import "SDLOnLockScreenStatus.h"
-
-#import "NSMutableDictionary+Store.h"
-#import "SDLHMILevel.h"
-#import "SDLLockScreenStatus.h"
-#import "SDLRPCParameterNames.h"
-#import "SDLRPCFunctionNames.h"
-
-NS_ASSUME_NONNULL_BEGIN
-
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-implementations"
-@implementation SDLOnLockScreenStatus
-#pragma clang diagnostic pop
-
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
-- (instancetype)init {
- if (self = [super initWithName:SDLRPCFunctionNameOnLockScreenStatus]) {
- }
- return self;
-}
-#pragma clang diagnostic pop
-
-- (void)setLockScreenStatus:(SDLLockScreenStatus)lockScreenStatus {
- [self.parameters sdl_setObject:lockScreenStatus forName:SDLRPCParameterNameOnLockScreenStatus];
-}
-
-- (SDLLockScreenStatus)lockScreenStatus {
- NSError *error = nil;
- return [self.parameters sdl_enumForName:SDLRPCParameterNameOnLockScreenStatus error:&error];
-}
-
-- (void)setHmiLevel:(SDLHMILevel)hmiLevel {
- [self.parameters sdl_setObject:hmiLevel forName:SDLRPCParameterNameHMILevel];
-}
-
-- (SDLHMILevel)hmiLevel {
- NSError *error = nil;
- return [self.parameters sdl_enumForName:SDLRPCParameterNameHMILevel error:&error];
-}
-
-- (void)setUserSelected:(NSNumber<SDLBool> *)userSelected {
- [self.parameters sdl_setObject:userSelected forName:SDLRPCParameterNameUserSelected];
-}
-
-- (NSNumber<SDLBool> *)userSelected {
- NSError *error = nil;
- return [self.parameters sdl_objectForName:SDLRPCParameterNameUserSelected ofClass:NSNumber.class error:&error];
-}
-
-- (void)setDriverDistractionStatus:(NSNumber<SDLBool> *)driverDistractionStatus {
- [self.parameters sdl_setObject:driverDistractionStatus forName:SDLRPCParameterNameDriverDistractionStatus];
-}
-
-- (NSNumber<SDLBool> *)driverDistractionStatus {
- NSError *error = nil;
- return [self.parameters sdl_objectForName:SDLRPCParameterNameDriverDistractionStatus ofClass:NSNumber.class error:&error];
-}
-
-@end
-
-NS_ASSUME_NONNULL_END
diff --git a/SmartDeviceLink/public/SDLPRNDL.h b/SmartDeviceLink/public/SDLPRNDL.h
index 4ab8032a3..904a0f218 100644
--- a/SmartDeviceLink/public/SDLPRNDL.h
+++ b/SmartDeviceLink/public/SDLPRNDL.h
@@ -9,7 +9,7 @@
*
* @since SDL 2.0
*/
-typedef SDLEnum SDLPRNDL SDL_SWIFT_ENUM;
+typedef SDLEnum SDLPRNDL NS_TYPED_ENUM;
/**
* Park
diff --git a/SmartDeviceLink/public/SDLPerformInteraction.h b/SmartDeviceLink/public/SDLPerformInteraction.h
index bc035ce04..c1d674b5b 100644
--- a/SmartDeviceLink/public/SDLPerformInteraction.h
+++ b/SmartDeviceLink/public/SDLPerformInteraction.h
@@ -59,103 +59,6 @@ NS_ASSUME_NONNULL_BEGIN
- (instancetype)initWithInitialText:(NSString *)initialText initialPrompt:(nullable NSArray<SDLTTSChunk *> *)initialPrompt interactionMode:(SDLInteractionMode)interactionMode interactionChoiceSetIDList:(NSArray<NSNumber<SDLUInt> *> *)interactionChoiceSetIDList helpPrompt:(nullable NSArray<SDLTTSChunk *> *)helpPrompt timeoutPrompt:(nullable NSArray<SDLTTSChunk *> *)timeoutPrompt timeout:(UInt16)timeout vrHelp:(nullable NSArray<SDLVRHelpItem *> *)vrHelp interactionLayout:(nullable SDLLayoutMode)interactionLayout cancelID:(UInt32)cancelID;
/**
- Convenience init for setting the a single visual or voice-recognition menu choice.
-
- @param interactionChoiceSetId Single interaction choice set ID to use with an interaction
- @return An SDLPerformInteraction object
- */
-- (instancetype)initWithInteractionChoiceSetId:(UInt16)interactionChoiceSetId __deprecated_msg("Use initWithInitialText:interactionMode:interactionChoiceSetIDList:cancelID: instead");
-
-/**
- Convenience init for setting the a visual or voice-recognition menu choices.
-
- @param interactionChoiceSetIdList List of interaction choice set IDs to use with an interaction
- @return An SDLPerformInteraction object
- */
-- (instancetype)initWithInteractionChoiceSetIdList:(NSArray<NSNumber<SDLUInt> *> *)interactionChoiceSetIdList __deprecated_msg("Use initWithInitialText:interactionMode:interactionChoiceSetIDList:cancelID: instead");
-
-/**
- Convenience init for creating a visual or voice-recognition menu with one choice.
-
- @param initialPrompt The initial prompt spoken to the user at the start of an interaction
- @param initialText Text to be displayed first
- @param interactionChoiceSetID Single interaction choice set ID to use with an interaction
- @return An SDLPerformInteraction object
- */
-- (instancetype)initWithInitialPrompt:(nullable NSString *)initialPrompt initialText:(NSString *)initialText interactionChoiceSetID:(UInt16)interactionChoiceSetID __deprecated_msg("Use initWithInitialText:interactionMode:interactionChoiceSetIDList:cancelID: instead");
-
-/**
- Convenience init for creating a visual or voice-recognition menu with one choice and VR help items.
-
- @param initialPrompt The initial prompt spoken to the user at the start of an interaction
- @param initialText Text to be displayed first
- @param interactionChoiceSetID Single interaction choice set ID to use with an interaction
- @param vrHelp Suggested voice recognition help items to display on-screen during a perform interaction
- @return An SDLPerformInteraction object
- */
-- (instancetype)initWithInitialPrompt:(nullable NSString *)initialPrompt initialText:(NSString *)initialText interactionChoiceSetID:(UInt16)interactionChoiceSetID vrHelp:(nullable NSArray<SDLVRHelpItem *> *)vrHelp __deprecated_msg("Use initWithInitialText:initialPrompt:interactionMode:interactionChoiceSetIDList:helpPrompt:timeoutPrompt:timeout:vrHelp:interactionLayout:cancelID: instead");
-
-/**
- Convenience init for creating a visual or voice-recognition menu using the default display layout and VR help items. Prompts are created from the passed strings.
-
- @param initialText Text to be displayed first
- @param initialPrompt The initial prompt spoken to the user at the start of an interaction
- @param interactionMode The method in which the user is notified and uses the interaction (voice, visual or both)
- @param interactionChoiceSetIDList List of interaction choice set IDs to use with an interaction
- @param helpPrompt The spoken text when a user speaks "help" when the interaction is occurring
- @param timeoutPrompt The text spoken when a VR interaction times out
- @param timeout Timeout in milliseconds
- @return An SDLPerformInteraction object
- */
-- (instancetype)initWithInitialPrompt:(nullable NSString *)initialPrompt initialText:(NSString *)initialText interactionChoiceSetIDList:(NSArray<NSNumber<SDLUInt> *> *)interactionChoiceSetIDList helpPrompt:(nullable NSString *)helpPrompt timeoutPrompt:(nullable NSString *)timeoutPrompt interactionMode:(SDLInteractionMode)interactionMode timeout:(UInt32)timeout __deprecated_msg("Use initWithInitialText:initialPrompt:interactionMode:interactionChoiceSetIDList:helpPrompt:timeoutPrompt:timeout:vrHelp:interactionLayout:cancelID: instead");
-
-/**
- Convenience init for creating a visual or voice-recognition menu using the default display layout. Prompts are created from the passed strings.
-
- @param initialText Text to be displayed first
- @param initialPrompt The initial prompt spoken to the user at the start of an interaction
- @param interactionMode The method in which the user is notified and uses the interaction (voice, visual or both)
- @param interactionChoiceSetIDList List of interaction choice set IDs to use with an interaction
- @param helpPrompt The spoken text when a user speaks "help" when the interaction is occurring
- @param timeoutPrompt The text spoken when a VR interaction times out
- @param timeout Timeout in milliseconds
- @param vrHelp Suggested voice recognition help items to display on-screen during a perform interaction
- @return An SDLPerformInteraction object
- */
-- (instancetype)initWithInitialPrompt:(nullable NSString *)initialPrompt initialText:(NSString *)initialText interactionChoiceSetIDList:(NSArray<NSNumber<SDLUInt> *> *)interactionChoiceSetIDList helpPrompt:(nullable NSString *)helpPrompt timeoutPrompt:(nullable NSString *)timeoutPrompt interactionMode:(SDLInteractionMode)interactionMode timeout:(UInt32)timeout vrHelp:(nullable NSArray<SDLVRHelpItem *> *)vrHelp __deprecated_msg("Use initWithInitialText:initialPrompt:interactionMode:interactionChoiceSetIDList:helpPrompt:timeoutPrompt:timeout:vrHelp:interactionLayout:cancelID: instead");
-
-/**
- Convenience init for creating a visual or voice-recognition menu using the default display layout.
-
- @param initialText Text to be displayed first
- @param initialChunks The initial prompt spoken to the user at the start of an interaction
- @param interactionMode The method in which the user is notified and uses the interaction (voice, visual or both)
- @param interactionChoiceSetIDList List of interaction choice set IDs to use with an interaction
- @param helpChunks The spoken text when a user speaks "help" when the interaction is occurring
- @param timeoutChunks The text spoken when a VR interaction times out
- @param timeout Timeout in milliseconds
- @param vrHelp Suggested voice recognition help items to display on-screen during a perform interaction
- @return An SDLPerformInteraction object
- */
-- (instancetype)initWithInitialChunks:(nullable NSArray<SDLTTSChunk *> *)initialChunks initialText:(NSString *)initialText interactionChoiceSetIDList:(NSArray<NSNumber<SDLUInt> *> *)interactionChoiceSetIDList helpChunks:(nullable NSArray<SDLTTSChunk *> *)helpChunks timeoutChunks:(nullable NSArray<SDLTTSChunk *> *)timeoutChunks interactionMode:(SDLInteractionMode)interactionMode timeout:(UInt32)timeout vrHelp:(nullable NSArray<SDLVRHelpItem *> *)vrHelp __deprecated_msg("Use initWithInitialText:initialPrompt:interactionMode:interactionChoiceSetIDList:helpPrompt:timeoutPrompt:timeout:vrHelp:interactionLayout:cancelID: instead");
-
-/**
- Convenience init for setting all parameters of a visual or voice-recognition menu.
-
- @param initialText Text to be displayed first
- @param initialChunks The initial prompt spoken to the user at the start of an interaction
- @param interactionMode The method in which the user is notified and uses the interaction (voice, visual or both)
- @param interactionChoiceSetIDList List of interaction choice set IDs to use with an interaction
- @param helpChunks The spoken text when a user speaks "help" when the interaction is occurring
- @param timeoutChunks The text spoken when a VR interaction times out
- @param timeout Timeout in milliseconds
- @param vrHelp Suggested voice recognition help items to display on-screen during a perform interaction
- @param layout For touchscreen interactions, the mode of how the choices are presented
- @return An SDLPerformInteraction object
- */
-- (instancetype)initWithInitialChunks:(nullable NSArray<SDLTTSChunk *> *)initialChunks initialText:(NSString *)initialText interactionChoiceSetIDList:(NSArray<NSNumber<SDLUInt> *> *)interactionChoiceSetIDList helpChunks:(nullable NSArray<SDLTTSChunk *> *)helpChunks timeoutChunks:(nullable NSArray<SDLTTSChunk *> *)timeoutChunks interactionMode:(SDLInteractionMode)interactionMode timeout:(UInt32)timeout vrHelp:(nullable NSArray<SDLVRHelpItem *> *)vrHelp interactionLayout:(nullable SDLLayoutMode)layout __deprecated_msg("Use initWithInitialText:initialPrompt:interactionMode:interactionChoiceSetIDList:helpPrompt:timeoutPrompt:timeout:vrHelp:interactionLayout:cancelID: instead");
-
-/**
Text to be displayed first.
String, Required
diff --git a/SmartDeviceLink/public/SDLPerformInteraction.m b/SmartDeviceLink/public/SDLPerformInteraction.m
index 540788531..e76621197 100644
--- a/SmartDeviceLink/public/SDLPerformInteraction.m
+++ b/SmartDeviceLink/public/SDLPerformInteraction.m
@@ -51,64 +51,6 @@ NS_ASSUME_NONNULL_BEGIN
return [self initWithInitialDisplayText:initialText initialPrompt:initialPrompt interactionMode:interactionMode interactionChoiceSetIDList:interactionChoiceSetIDList helpPrompt:helpPrompt timeoutPrompt:timeoutPrompt timeout:@(timeout) vrHelp:vrHelp interactionLayout:interactionLayout cancelID:@(cancelID)];
}
-
-- (instancetype)initWithInteractionChoiceSetId:(UInt16)interactionChoiceSetId {
- return [self initWithInteractionChoiceSetIdList:@[@(interactionChoiceSetId)]];
-}
-
-- (instancetype)initWithInitialPrompt:(nullable NSString *)initialPrompt initialText:(NSString *)initialText interactionChoiceSetID:(UInt16)interactionChoiceSetID {
- self = [self initWithInteractionChoiceSetId:interactionChoiceSetID];
- if (!self) {
- return nil;
- }
-
- self.initialPrompt = [SDLTTSChunk textChunksFromString:initialPrompt];
- self.initialText = initialText;
-
- return self;
-}
-
-- (instancetype)initWithInitialPrompt:(nullable NSString *)initialPrompt initialText:(NSString *)initialText interactionChoiceSetID:(UInt16)interactionChoiceSetID vrHelp:(nullable NSArray<SDLVRHelpItem *> *)vrHelp {
- self = [self initWithInitialPrompt:initialPrompt initialText:initialText interactionChoiceSetID:interactionChoiceSetID];
- if (!self) {
- return nil;
- }
-
- self.vrHelp = vrHelp;
-
- return self;
-}
-
-- (instancetype)initWithInitialPrompt:(nullable NSString *)initialPrompt initialText:(NSString *)initialText interactionChoiceSetIDList:(NSArray<NSNumber<SDLUInt> *> *)interactionChoiceSetIDList helpPrompt:(nullable NSString *)helpPrompt timeoutPrompt:(nullable NSString *)timeoutPrompt interactionMode:(SDLInteractionMode)interactionMode timeout:(UInt32)timeout {
- return [self initWithInitialPrompt:initialPrompt initialText:initialText interactionChoiceSetIDList:interactionChoiceSetIDList helpPrompt:helpPrompt timeoutPrompt:timeoutPrompt interactionMode:interactionMode timeout:timeout vrHelp:nil];
-}
-
-- (instancetype)initWithInitialPrompt:(nullable NSString *)initialPrompt initialText:(NSString *)initialText interactionChoiceSetIDList:(NSArray<NSNumber<SDLUInt> *> *)interactionChoiceSetIDList helpPrompt:(nullable NSString *)helpPrompt timeoutPrompt:(nullable NSString *)timeoutPrompt interactionMode:(SDLInteractionMode)interactionMode timeout:(UInt32)timeout vrHelp:(nullable NSArray<SDLVRHelpItem *> *)vrHelp {
- NSArray *initialChunks = [SDLTTSChunk textChunksFromString:initialPrompt];
- NSArray *helpChunks = [SDLTTSChunk textChunksFromString:helpPrompt];
- NSArray *timeoutChunks = [SDLTTSChunk textChunksFromString:timeoutPrompt];
- return [self initWithInitialChunks:initialChunks initialText:initialText interactionChoiceSetIDList:interactionChoiceSetIDList helpChunks:helpChunks timeoutChunks:timeoutChunks interactionMode:interactionMode timeout:timeout vrHelp:vrHelp];
-}
-
-- (instancetype)initWithInitialChunks:(nullable NSArray<SDLTTSChunk *> *)initialChunks initialText:(NSString *)initialText interactionChoiceSetIDList:(NSArray<NSNumber<SDLUInt> *> *)interactionChoiceSetIDList helpChunks:(nullable NSArray<SDLTTSChunk *> *)helpChunks timeoutChunks:(nullable NSArray<SDLTTSChunk *> *)timeoutChunks interactionMode:(SDLInteractionMode)interactionMode timeout:(UInt32)timeout vrHelp:(nullable NSArray<SDLVRHelpItem *> *)vrHelp {
- return [self initWithInitialChunks:initialChunks initialText:initialText interactionChoiceSetIDList:interactionChoiceSetIDList helpChunks:helpChunks timeoutChunks:timeoutChunks interactionMode:interactionMode timeout:timeout vrHelp:vrHelp interactionLayout:nil];
-}
-
-- (instancetype)initWithInitialChunks:(nullable NSArray<SDLTTSChunk *> *)initialChunks initialText:(NSString *)initialText interactionChoiceSetIDList:(NSArray<NSNumber<SDLUInt> *> *)interactionChoiceSetIDList helpChunks:(nullable NSArray<SDLTTSChunk *> *)helpChunks timeoutChunks:(nullable NSArray<SDLTTSChunk *> *)timeoutChunks interactionMode:(SDLInteractionMode)interactionMode timeout:(UInt32)timeout vrHelp:(nullable NSArray<SDLVRHelpItem *> *)vrHelp interactionLayout:(nullable SDLLayoutMode)layout {
- return [self initWithInitialDisplayText:initialText initialPrompt:initialChunks interactionMode:interactionMode interactionChoiceSetIDList:interactionChoiceSetIDList helpPrompt:helpChunks timeoutPrompt:timeoutChunks timeout:@(timeout) vrHelp:vrHelp interactionLayout:layout cancelID:nil];
-}
-
-- (instancetype)initWithInteractionChoiceSetIdList:(NSArray<NSNumber<SDLInt> *> *)interactionChoiceSetIdList {
- self = [self init];
- if (!self) {
- return nil;
- }
-
- self.interactionChoiceSetIDList = interactionChoiceSetIdList;
-
- return self;
-}
-
- (void)setInitialText:(NSString *)initialText {
[self.parameters sdl_setObject:initialText forName:SDLRPCParameterNameInitialText];
}
diff --git a/SmartDeviceLink/public/SDLPermissionConstants.h b/SmartDeviceLink/public/SDLPermissionConstants.h
index 8c7c1f0da..13b897ed5 100644
--- a/SmartDeviceLink/public/SDLPermissionConstants.h
+++ b/SmartDeviceLink/public/SDLPermissionConstants.h
@@ -18,7 +18,7 @@ NS_ASSUME_NONNULL_BEGIN
/// NSString typedef
///
/// SDLPermissionRPCName: The name of the permission
-typedef NSString *SDLPermissionRPCName;
+typedef NSString *SDLPermissionRPCName __deprecated_msg("Use SDLRPCFunctionName instead");
/// NSUUID typedef
///
@@ -67,12 +67,15 @@ typedef NS_ENUM(NSUInteger, SDLPermissionGroupStatus) {
* @param updatedPermissionStatuses A dictionary of the new current status of all subscription items; containing <key(String): RPC Name, object(BOOL): YES if the RPC is allowed, NO if it is not allowed>
* @param status The unified group status of the RPCs in the updatedPermissionStatuses dictionary. Allowed, if all RPCs are now allowed, Disallowed if all RPCs are now disallowed, or Mixed if some are allowed, and some are disallowed
*/
-typedef void (^SDLPermissionsChangedHandler)(NSDictionary<SDLPermissionRPCName, NSNumber *> *_Nonnull updatedPermissionStatuses, SDLPermissionGroupStatus status);
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wdeprecated-declarations"
+typedef void (^SDLPermissionsChangedHandler)(NSDictionary<SDLPermissionRPCName, NSNumber *> *_Nonnull updatedPermissionStatuses, SDLPermissionGroupStatus status) __deprecated_msg("Use SDLRPCPermissionStatusChangedHandler instead");
+#pragma clang diagnostic pop
/**
* A block that will be called when specified permissions change. It will return whether each RPC and its parameters are allowed as well as the permission group status of all the RPCs.
*
- * @param updatedPermissionStatuses A dictionary of the new current status of all subscription items; containing <key(String): SDLPermissionRPCName, object(SDLRPCPermissionStatus)>
+ * @param updatedPermissionStatuses A dictionary of the new current status of all subscription items; containing <key(String): SDLRPCFunctionName, object(SDLRPCPermissionStatus)>
* @param status The unified group status of the RPCs in the updatedPermissionStatuses dictionary. Allowed, if all RPCs are now allowed, Disallowed if all RPCs are now disallowed, or Mixed if some are allowed, and some are disallowed
*/
typedef void (^SDLRPCPermissionStatusChangedHandler)(NSDictionary<SDLRPCFunctionName, SDLRPCPermissionStatus *> *_Nonnull updatedPermissionStatuses, SDLPermissionGroupStatus status);
diff --git a/SmartDeviceLink/public/SDLPermissionManager.h b/SmartDeviceLink/public/SDLPermissionManager.h
index 4a1fc4577..93107c9ee 100644
--- a/SmartDeviceLink/public/SDLPermissionManager.h
+++ b/SmartDeviceLink/public/SDLPermissionManager.h
@@ -39,15 +39,6 @@ NS_ASSUME_NONNULL_BEGIN
- (void)stop;
/**
- * Determine if an individual RPC is allowed for the current HMI level
- *
- * @param rpcName The name of the RPC to be tested, for example, SDLShow
- *
- * @return YES if the RPC is allowed at the current HMI level, NO if not
- */
-- (BOOL)isRPCAllowed:(SDLPermissionRPCName)rpcName __deprecated_msg(("Use isRPCNameAllowed: instead"));
-
-/**
* Determine if an individual RPC is allowed for the current HMI level
*
* @param rpcName The name of the RPC to be tested, for example, SDLRPCFunctionNameShow
@@ -57,15 +48,6 @@ NS_ASSUME_NONNULL_BEGIN
- (BOOL)isRPCNameAllowed:(SDLRPCFunctionName)rpcName;
/**
- * Determine if all RPCs are allowed for the current HMI level
- *
- * @param rpcNames The RPCs to check
- *
- * @return AllAllowed if all of the permissions are allowed, AllDisallowed if all the permissions are disallowed, Any if some are allowed, and some are disallowed
- */
-- (SDLPermissionGroupStatus)groupStatusOfRPCs:(NSArray<SDLPermissionRPCName> *)rpcNames __deprecated_msg(("Use groupStatusOfRPCPermissions: instead"));
-
-/**
* Determine if all RPCs are allowed for the current HMI level
*
* @param rpcNames The RPCs to check
@@ -75,15 +57,6 @@ NS_ASSUME_NONNULL_BEGIN
- (SDLPermissionGroupStatus)groupStatusOfRPCPermissions:(NSArray<SDLPermissionElement *> *)rpcNames;
/**
- * Retrieve a dictionary with keys that are the passed in RPC names, and objects of an NSNumber<BOOL> specifying if that RPC is currently allowed
- *
- * @param rpcNames An array of RPC names to check
- *
- * @return A dictionary specifying if the passed in RPC names are currently allowed or not
- */
-- (NSDictionary<SDLPermissionRPCName, NSNumber *> *)statusOfRPCs:(NSArray<SDLPermissionRPCName> *)rpcNames __deprecated_msg(("Use statusesOfRPCPermissions: instead"));
-
-/**
* Retrieve a dictionary with keys that are the passed in RPC names, and objects of an NSNumber<BOOL> specifying if that RPC is currently allowed
*
* @param rpcNames An array of permission elements to check
@@ -93,24 +66,9 @@ NS_ASSUME_NONNULL_BEGIN
- (NSDictionary<SDLRPCFunctionName, SDLRPCPermissionStatus *> *)statusesOfRPCPermissions:(NSArray<SDLPermissionElement *> *)rpcNames;
/**
- * Add an observer for specified RPC names, with a callback that will be called whenever the value changes, as well as immediately with the current status.
+ * Subscribe to specified RPC names, with a callback that will be called whenever the value changes. Tthe callback will only return immediately if the groupType is set to SDLPermissionGroupTypeAny or if the groupType is set to SDLPermissionGroupTypeAllAllowed and all RPCs in the rpcNames parameter are allowed.
*
- * @warning This block will be captured by the SDLPermissionsManager, be sure to use [weakself/strongself](http://www.logicsector.com/ios/avoiding-objc-retain-cycles-with-weakself-and-strongself-the-easy-way/) if you are referencing self within your observer block.
- *
- * @warning The observer may be called before this method returns, do not attempt to remove the observer from within the observer. That could send `nil` to removeObserverForIdentifier:. If you want functionality like that, call groupStatusOfRPCs: instead.
- *
- * @param rpcNames The RPCs to be observed
- * @param groupType Affects the times that the observer block will be called. If Any, any change to any RPC in rpcNames will cause the observer block to be called. If AllAllowed, the block will be called when: 1. The observer is first set regardless of RPC status 2. Every RPC in rpcNames becomes allowed 3. The group of rpcNames goes from all being allowed to some or all being disallowed.
- * @param handler The block that will be called whenever permissions change.
- *
- * @return An identifier that can be passed to removeObserverForIdentifer: to remove the observer
- */
-- (SDLPermissionObserverIdentifier)addObserverForRPCs:(NSArray<SDLPermissionRPCName> *)rpcNames groupType:(SDLPermissionGroupType)groupType withHandler:(SDLPermissionsChangedHandler)handler __deprecated_msg(("Use subscribeToRPCPermissions:groupType:withHandler: instead"));
-
-/**
- * Subscribe to specified RPC names, with a callback that will be called whenever the value changes. Unlike addObserverForRPCs:groupType:withHandler:, the callback will only return immediately if the groupType is set to SDLPermissionGroupTypeAny or if the groupType is set to SDLPermissionGroupTypeAllAllowed and all RPCs in the rpcNames parameter are allowed.
- *
- * @warning The observer may be called before this method returns, do not attempt to remove the observer from within the observer. That could send `nil` to removeObserverForIdentifier:. If you want functionality like that, call groupStatusOfRPCs: instead.
+ * @warning The observer may be called before this method returns. Do not attempt to remove the observer from within the observer.
*
* @param permissionElements The permission elements to be observed
* @param groupType Affects the times that the observer block will be called. If Any, any change to any RPC in rpcNames will cause the observer block to be called. If AllAllowed, the block will be called when: 1. Every RPC in rpcNames becomes allowed 2. The group of rpcNames goes from all being allowed to some or all being disallowed.
@@ -132,12 +90,6 @@ NS_ASSUME_NONNULL_BEGIN
*/
- (void)removeObserverForIdentifier:(SDLPermissionObserverIdentifier)identifier;
-
-/**
- * Check whether or not an RPC needs encryption.
- */
-- (BOOL)rpcRequiresEncryption:(SDLPermissionRPCName)rpcName __deprecated_msg(("Use rpcNameRequiresEncryption: instead"));
-
/**
* Check whether or not an RPC needs encryption.
*/
diff --git a/SmartDeviceLink/public/SDLPermissionManager.m b/SmartDeviceLink/public/SDLPermissionManager.m
index aa9f14bf0..0e5301547 100644
--- a/SmartDeviceLink/public/SDLPermissionManager.m
+++ b/SmartDeviceLink/public/SDLPermissionManager.m
@@ -24,7 +24,7 @@ NS_ASSUME_NONNULL_BEGIN
@interface SDLPermissionManager ()
-@property (strong, nonatomic) NSMutableDictionary<SDLPermissionRPCName, SDLPermissionItem *> *permissions;
+@property (strong, nonatomic) NSMutableDictionary<SDLRPCFunctionName, SDLPermissionItem *> *permissions;
@property (strong, nonatomic) NSMutableArray<SDLPermissionFilter *> *filters;
@property (copy, nonatomic, nullable) SDLHMILevel currentHMILevel;
@property (assign, nonatomic) BOOL requiresEncryption;
@@ -43,7 +43,7 @@ NS_ASSUME_NONNULL_BEGIN
}
_currentHMILevel = nil;
- _permissions = [NSMutableDictionary<SDLPermissionRPCName, SDLPermissionItem *> dictionary];
+ _permissions = [NSMutableDictionary<SDLRPCFunctionName, SDLPermissionItem *> dictionary];
_filters = [NSMutableArray<SDLPermissionFilter *> array];
// Set up SDL status notifications
@@ -58,7 +58,7 @@ NS_ASSUME_NONNULL_BEGIN
}
- (void)stop {
- _permissions = [NSMutableDictionary<SDLPermissionRPCName, SDLPermissionItem *> dictionary];
+ _permissions = [NSMutableDictionary<SDLRPCFunctionName, SDLPermissionItem *> dictionary];
_filters = [NSMutableArray<SDLPermissionFilter *> array];
_currentHMILevel = nil;
}
@@ -66,15 +66,11 @@ NS_ASSUME_NONNULL_BEGIN
#pragma mark - Permissions available
-- (BOOL)isRPCAllowed:(NSString *)rpcName {
- return [self isRPCNameAllowed:rpcName];
-}
-
- (BOOL)isRPCNameAllowed:(SDLRPCFunctionName)rpcName {
return [self.class isRPCNameAllowed:rpcName permissions:self.permissions hmiLevel:self.currentHMILevel];
}
-+ (BOOL)isRPCNameAllowed:(SDLRPCFunctionName)rpcName permissions:(NSDictionary<SDLPermissionRPCName, SDLPermissionItem *> *)permissions hmiLevel:(SDLHMILevel)hmiLevel {
++ (BOOL)isRPCNameAllowed:(SDLRPCFunctionName)rpcName permissions:(NSDictionary<SDLRPCFunctionName, SDLPermissionItem *> *)permissions hmiLevel:(SDLHMILevel)hmiLevel {
if (permissions[rpcName] == nil || hmiLevel == nil) {
return NO;
}
@@ -83,10 +79,6 @@ NS_ASSUME_NONNULL_BEGIN
return [item.hmiPermissions.allowed containsObject:hmiLevel];
}
-- (SDLPermissionGroupStatus)groupStatusOfRPCs:(NSArray<SDLPermissionRPCName> *)rpcNames {
- return [self groupStatusOfRPCPermissions:[self sdl_createPermissionElementsFromRPCNames:rpcNames]];
-}
-
- (SDLPermissionGroupStatus)groupStatusOfRPCPermissions:(NSArray<SDLPermissionElement *> *)rpcNames {
if (self.currentHMILevel == nil) {
return SDLPermissionGroupStatusUnknown;
@@ -95,7 +87,7 @@ NS_ASSUME_NONNULL_BEGIN
return [self.class sdl_groupStatusOfRPCPermissions:rpcNames withPermissions:[self.permissions copy] hmiLevel:self.currentHMILevel];
}
-+ (SDLPermissionGroupStatus)sdl_groupStatusOfRPCPermissions:(NSArray<SDLPermissionElement *> *)rpcNames withPermissions:(NSDictionary<SDLPermissionRPCName, SDLPermissionItem *> *)permissions hmiLevel:(SDLHMILevel)hmiLevel {
++ (SDLPermissionGroupStatus)sdl_groupStatusOfRPCPermissions:(NSArray<SDLPermissionElement *> *)rpcNames withPermissions:(NSDictionary<SDLRPCFunctionName, SDLPermissionItem *> *)permissions hmiLevel:(SDLHMILevel)hmiLevel {
// If we don't have an HMI level, then just say everything is disallowed
if (hmiLevel == nil) {
return SDLPermissionGroupStatusUnknown;
@@ -146,13 +138,6 @@ NS_ASSUME_NONNULL_BEGIN
}
}
-- (NSDictionary<SDLPermissionRPCName, NSNumber *> *)statusOfRPCs:(NSArray<SDLPermissionRPCName> *)rpcNames {
- NSArray *permissionElementsArray = [self sdl_createPermissionElementsFromRPCNames:rpcNames];
-
- // Convert the dictionary returned from statusesOfRPCNames: to the correct return type
- return [self sdl_convertPermissionsStatusDictionaryToPermissionsBoolDictionary:[self statusesOfRPCPermissions:permissionElementsArray]];
-}
-
- (NSDictionary<SDLRPCFunctionName, SDLRPCPermissionStatus *> *)statusesOfRPCPermissions:(NSArray<SDLPermissionElement *> *)rpcNames {
NSMutableDictionary<SDLRPCFunctionName, SDLRPCPermissionStatus *> *permissionAllowedDict = [NSMutableDictionary dictionary];
@@ -179,18 +164,6 @@ NS_ASSUME_NONNULL_BEGIN
#pragma mark Add Observers
-- (SDLPermissionObserverIdentifier)addObserverForRPCs:(NSArray<SDLPermissionRPCName> *)rpcNames groupType:(SDLPermissionGroupType)groupType withHandler:(nonnull SDLPermissionsChangedHandler)handler {
- SDLPermissionFilter *filter = [[SDLPermissionFilter alloc] initWithPermissions:[self sdl_createPermissionElementsFromRPCNames:rpcNames] groupType:groupType permissionsHandler:handler];
-
- // Store the filter for later use
- [self.filters addObject:filter];
-
- // If there are permissions that fit the specifications, send immediately. Then return the identifier.
- [self sdl_callFilterObserver:filter];
-
- return filter.identifier;
-}
-
- (SDLPermissionObserverIdentifier)subscribeToRPCPermissions:(NSArray<SDLPermissionElement *> *)rpcNames groupType:(SDLPermissionGroupType)groupType withHandler:(SDLRPCPermissionStatusChangedHandler)handler {
SDLPermissionFilter *filter = [[SDLPermissionFilter alloc] initWithPermissions:rpcNames groupType:groupType permissionStatusHandler:handler];
@@ -209,13 +182,10 @@ NS_ASSUME_NONNULL_BEGIN
- (void)sdl_callFilterObserver:(SDLPermissionFilter *)filter {
SDLPermissionGroupStatus permissionStatus = [self groupStatusOfRPCPermissions:filter.permissionElements];
- if (filter.rpcPermissionStatusHandler != nil) {
- NSDictionary<SDLRPCFunctionName, SDLRPCPermissionStatus *> *allowedDict = [self statusesOfRPCPermissions:filter.permissionElements];
- filter.rpcPermissionStatusHandler(allowedDict, permissionStatus);
- } else if (filter.handler != nil) {
- NSDictionary<SDLRPCFunctionName, NSNumber *> *allowedDict = [self sdl_convertPermissionsStatusDictionaryToPermissionsBoolDictionary:[self statusesOfRPCPermissions:filter.permissionElements]];
- filter.handler(allowedDict, permissionStatus);
- }
+ if (filter.rpcPermissionStatusHandler == nil) { return; }
+
+ NSDictionary<SDLRPCFunctionName, SDLRPCPermissionStatus *> *allowedDict = [self statusesOfRPCPermissions:filter.permissionElements];
+ filter.rpcPermissionStatusHandler(allowedDict, permissionStatus);
}
#pragma mark Remove Observers
@@ -323,39 +293,6 @@ NS_ASSUME_NONNULL_BEGIN
#pragma mark Helper Methods
/**
- * HAX: Remove this when statusOfRPCs: is no longer supported. Converts a dictionary from <SDLRPCFunctionName, SDLRPCPermissionStatus*> to <SDLPermissionRPCName, NSNumber *>.
- *
- * @param permissionStatusDictionary The dictionary containing <SDLRPCFunctionName, SDLRPCPermissionStatus*> to convert.
- *
- * @return A <SDLPermissionRPCName, NSNumber *> dictionary.
- */
-- (NSDictionary<SDLPermissionRPCName, NSNumber *> *)sdl_convertPermissionsStatusDictionaryToPermissionsBoolDictionary:(NSDictionary<SDLRPCFunctionName, SDLRPCPermissionStatus*> *)permissionStatusDictionary {
- NSMutableDictionary *rpcNameDictionary = [[NSMutableDictionary alloc] init];
- [permissionStatusDictionary enumerateKeysAndObjectsUsingBlock:^(SDLRPCFunctionName _Nonnull key, SDLRPCPermissionStatus * _Nonnull obj, BOOL * _Nonnull stop) {
- [rpcNameDictionary setObject:@(obj.rpcAllowed) forKey:key];
- }];
-
- return rpcNameDictionary;
-}
-
-/**
- * Converts an array of RPC name strings to permission elements.
- *
- * @param rpcNames The RPC names to convert.
- *
- * @return An array of permission elements.
- */
-- (NSArray<SDLPermissionElement *> *)sdl_createPermissionElementsFromRPCNames:(NSArray<SDLRPCFunctionName> *)rpcNames {
- NSMutableArray *permissionElements = [[NSMutableArray alloc] init];
- for (NSString *rpcName in rpcNames) {
- SDLPermissionElement *permissionElement = [[SDLPermissionElement alloc] initWithRPCName:rpcName parameterPermissions:nil];
- [permissionElements addObject:permissionElement];
- }
-
- return [permissionElements copy];
-}
-
-/**
* Determine if a filter changes based on an HMI level change and the filter's group type settings. This will run through the filter's RPCs, check the permission for each and see if any permission within the filter changes based on some permission now being allowed when it wasn't, or not allowed when it was. This also takes into account the group type setting, so an All Allowed filter will return YES if and only if some permission changed *and* that causes a status change *to* or *from* Allowed.
*
* @param filter The filter to check
@@ -423,7 +360,7 @@ NS_ASSUME_NONNULL_BEGIN
@param updatedPermissions The set of updated permissions to test each filter against
@return An array of filters that contained one of the passed permissions
*/
-+ (NSArray<SDLPermissionFilter *> *)sdl_filterPermissionChangesForFilters:(NSArray<SDLPermissionFilter *> *)filters currentPermissions:(NSMutableDictionary<SDLPermissionRPCName, SDLPermissionItem *> *)currentPermissions updatedPermissions:(NSArray<SDLPermissionItem *> *)updatedPermissions {
++ (NSArray<SDLPermissionFilter *> *)sdl_filterPermissionChangesForFilters:(NSArray<SDLPermissionFilter *> *)filters currentPermissions:(NSMutableDictionary<SDLRPCFunctionName, SDLPermissionItem *> *)currentPermissions updatedPermissions:(NSArray<SDLPermissionItem *> *)updatedPermissions {
NSMutableArray<SDLPermissionFilter *> *modifiedFilters = [NSMutableArray arrayWithCapacity:filters.count];
// Loop through each updated permission item for each filter, if the filter had something modified, store it and go to the next filter
@@ -440,7 +377,7 @@ NS_ASSUME_NONNULL_BEGIN
return [modifiedFilters copy];
}
-+ (NSArray<SDLPermissionItem *> *)sdl_modifiedUpdatedPermissions:(NSArray<SDLPermissionItem *> *)permissionItems comparedToCurrentPermissions:(NSMutableDictionary<SDLPermissionRPCName, SDLPermissionItem *> *)currentPermissions {
++ (NSArray<SDLPermissionItem *> *)sdl_modifiedUpdatedPermissions:(NSArray<SDLPermissionItem *> *)permissionItems comparedToCurrentPermissions:(NSMutableDictionary<SDLRPCFunctionName, SDLPermissionItem *> *)currentPermissions {
NSMutableArray<SDLPermissionItem *> *modifiedPermissions = [NSMutableArray arrayWithCapacity:permissionItems.count];
for (SDLPermissionItem *item in permissionItems) {
@@ -462,10 +399,6 @@ NS_ASSUME_NONNULL_BEGIN
return NO;
}
-- (BOOL)rpcRequiresEncryption:(SDLPermissionRPCName)rpcName {
- return [self rpcNameRequiresEncryption:rpcName];
-}
-
- (BOOL)rpcNameRequiresEncryption:(SDLRPCFunctionName)rpcName {
if (self.permissions[rpcName].requireEncryption != nil) {
return self.permissions[rpcName].requireEncryption.boolValue;
@@ -477,7 +410,7 @@ NS_ASSUME_NONNULL_BEGIN
return [self.class sdl_isPermissionParameterAllowed:rpcName parameter:parameter permissionItems:self.permissions hmiLevel:self.currentHMILevel];
}
-+ (BOOL)sdl_isPermissionParameterAllowed:(SDLRPCFunctionName)rpcName parameter:(NSString *)parameter permissionItems:(NSDictionary<SDLPermissionRPCName, SDLPermissionItem *> *)permissionItems hmiLevel:(SDLHMILevel)hmiLevel {
++ (BOOL)sdl_isPermissionParameterAllowed:(SDLRPCFunctionName)rpcName parameter:(NSString *)parameter permissionItems:(NSDictionary<SDLRPCFunctionName, SDLPermissionItem *> *)permissionItems hmiLevel:(SDLHMILevel)hmiLevel {
SDLPermissionItem *permissionItem = permissionItems[rpcName];
if (permissionItem == nil || ![self isRPCNameAllowed:rpcName permissions:permissionItems hmiLevel:hmiLevel] || permissionItem.parameterPermissions == nil || permissionItem.parameterPermissions.allowed == nil) {
return NO;
diff --git a/SmartDeviceLink/public/SDLPermissionStatus.h b/SmartDeviceLink/public/SDLPermissionStatus.h
index 45b02417d..33f1534d6 100644
--- a/SmartDeviceLink/public/SDLPermissionStatus.h
+++ b/SmartDeviceLink/public/SDLPermissionStatus.h
@@ -9,7 +9,7 @@
*
* @since SDL 2.0
*/
-typedef SDLEnum SDLPermissionStatus SDL_SWIFT_ENUM;
+typedef SDLEnum SDLPermissionStatus NS_TYPED_ENUM;
/**
* permission: allowed
diff --git a/SmartDeviceLink/public/SDLPowerModeQualificationStatus.h b/SmartDeviceLink/public/SDLPowerModeQualificationStatus.h
index 837837e17..7f5002416 100644
--- a/SmartDeviceLink/public/SDLPowerModeQualificationStatus.h
+++ b/SmartDeviceLink/public/SDLPowerModeQualificationStatus.h
@@ -7,7 +7,7 @@
/**
Describes the power mode qualification status. Used in ClusterModeStatus.
*/
-typedef SDLEnum SDLPowerModeQualificationStatus SDL_SWIFT_ENUM;
+typedef SDLEnum SDLPowerModeQualificationStatus NS_TYPED_ENUM;
/**
An undefined status
diff --git a/SmartDeviceLink/public/SDLPowerModeStatus.h b/SmartDeviceLink/public/SDLPowerModeStatus.h
index 92c7d5c30..cbb23dff5 100644
--- a/SmartDeviceLink/public/SDLPowerModeStatus.h
+++ b/SmartDeviceLink/public/SDLPowerModeStatus.h
@@ -7,7 +7,7 @@
/**
The status of the car's power. Used in ClusterModeStatus.
*/
-typedef SDLEnum SDLPowerModeStatus SDL_SWIFT_ENUM;
+typedef SDLEnum SDLPowerModeStatus NS_TYPED_ENUM;
/**
The key is not in the ignition, and the power is off
diff --git a/SmartDeviceLink/public/SDLPredefinedLayout.h b/SmartDeviceLink/public/SDLPredefinedLayout.h
index 73a076eac..034bdcbcc 100644
--- a/SmartDeviceLink/public/SDLPredefinedLayout.h
+++ b/SmartDeviceLink/public/SDLPredefinedLayout.h
@@ -7,7 +7,7 @@
/**
A template layout an app uses to display information. The broad details of the layout are defined, but the details depend on the IVI system. Used in SetDisplayLayout.
*/
-typedef SDLEnum SDLPredefinedLayout SDL_SWIFT_ENUM;
+typedef SDLEnum SDLPredefinedLayout NS_TYPED_ENUM;
/**
A default layout
diff --git a/SmartDeviceLink/public/SDLPrerecordedSpeech.h b/SmartDeviceLink/public/SDLPrerecordedSpeech.h
index 090566327..32612cccc 100644
--- a/SmartDeviceLink/public/SDLPrerecordedSpeech.h
+++ b/SmartDeviceLink/public/SDLPrerecordedSpeech.h
@@ -7,7 +7,7 @@
/**
Contains information about the speech capabilities on the SDL platform. Used in RegisterAppInterfaceResponse to indicate capability.
*/
-typedef SDLEnum SDLPrerecordedSpeech SDL_SWIFT_ENUM;
+typedef SDLEnum SDLPrerecordedSpeech NS_TYPED_ENUM;
/**
A prerecorded help prompt
diff --git a/SmartDeviceLink/public/SDLPrimaryAudioSource.h b/SmartDeviceLink/public/SDLPrimaryAudioSource.h
index c02bd0927..c61b0dab9 100644
--- a/SmartDeviceLink/public/SDLPrimaryAudioSource.h
+++ b/SmartDeviceLink/public/SDLPrimaryAudioSource.h
@@ -9,7 +9,7 @@
*
* @since SDL 2.0
*/
-typedef SDLEnum SDLPrimaryAudioSource SDL_SWIFT_ENUM;
+typedef SDLEnum SDLPrimaryAudioSource NS_TYPED_ENUM;
/**
* Currently no source selected
diff --git a/SmartDeviceLink/public/SDLPutFile.h b/SmartDeviceLink/public/SDLPutFile.h
index 98a05fe69..40a4cc554 100644
--- a/SmartDeviceLink/public/SDLPutFile.h
+++ b/SmartDeviceLink/public/SDLPutFile.h
@@ -51,19 +51,6 @@ NS_ASSUME_NONNULL_BEGIN
* @param systemFile Whether or not the file is meant to be passed through Core to elsewhere on the system
* @param offset Offset in bytes for resuming partial data chunks
* @param length Length in bytes for resuming partial data chunks
- * @return A SDLPutFile object
- */
-- (instancetype)initWithFileName:(NSString *)fileName fileType:(SDLFileType)fileType persistentFile:(BOOL)persistentFile systemFile:(BOOL)systemFile offset:(UInt32)offset length:(UInt32)length __deprecated_msg("Use initWithFileName:fileType:persistentFile:systemFile:offset:length:crc: instead");
-
-/**
- * Convenience init for creating a putfile that is part of a multiple frame payload.
- *
- * @param fileName The file's name
- * @param fileType The file's format
- * @param persistentFile Whether or not the image should persist between ignition cycles
- * @param systemFile Whether or not the file is meant to be passed through Core to elsewhere on the system
- * @param offset Offset in bytes for resuming partial data chunks
- * @param length Length in bytes for resuming partial data chunks
* @param crc Checksum of the bulk data. Used by Core to check data integrity
* @return A SDLPutFile object
*/
@@ -84,13 +71,6 @@ NS_ASSUME_NONNULL_BEGIN
- (instancetype)initWithFileName:(NSString *)fileName fileType:(SDLFileType)fileType persistentFile:(BOOL)persistentFile systemFile:(BOOL)systemFile offset:(UInt32)offset length:(UInt32)length bulkData:(NSData *)bulkData;
/**
- * File reference name
- *
- * Required, max length 255 characters
- */
-@property (strong, nonatomic) NSString *syncFileName __deprecated_msg("use sdlFileName instead");
-
-/**
* File reference name
*
* Required, max length 255 characters
diff --git a/SmartDeviceLink/public/SDLPutFile.m b/SmartDeviceLink/public/SDLPutFile.m
index 2470be16d..eb1b6af6d 100644
--- a/SmartDeviceLink/public/SDLPutFile.m
+++ b/SmartDeviceLink/public/SDLPutFile.m
@@ -45,19 +45,6 @@ NS_ASSUME_NONNULL_BEGIN
return self;
}
-- (instancetype)initWithFileName:(NSString *)fileName fileType:(SDLFileType)fileType persistentFile:(BOOL)persistentFile systemFile:(BOOL)systemFile offset:(UInt32)offset length:(UInt32)length {
- self = [self initWithFileName:fileName fileType:fileType persistentFile:persistentFile];
- if (!self) {
- return nil;
- }
-
- self.systemFile = @(systemFile);
- self.offset = @(offset);
- self.length = @(length);
-
- return self;
-}
-
- (instancetype)initWithFileName:(NSString *)fileName fileType:(SDLFileType)fileType persistentFile:(BOOL)persistentFile systemFile:(BOOL)systemFile offset:(UInt32)offset length:(UInt32)length crc:(UInt64)crc {
self = [self initWithFileName:fileName fileType:fileType persistentFile:persistentFile];
if (!self) {
@@ -86,17 +73,8 @@ NS_ASSUME_NONNULL_BEGIN
#pragma mark - Getters and Setters
-- (void)setSyncFileName:(NSString *)syncFileName {
- [self.parameters sdl_setObject:syncFileName forName:SDLRPCParameterNameSyncFileName];
-}
-
-- (NSString *)syncFileName {
- NSError *error = nil;
- return [self.parameters sdl_objectForName:SDLRPCParameterNameSyncFileName ofClass:NSString.class error:&error];
-}
-
-- (void)setSdlFileName:(NSString *)syncFileName {
- [self.parameters sdl_setObject:syncFileName forName:SDLRPCParameterNameSyncFileName];
+- (void)setSdlFileName:(NSString *)sdlFileName {
+ [self.parameters sdl_setObject:sdlFileName forName:SDLRPCParameterNameSyncFileName];
}
- (NSString *)sdlFileName {
diff --git a/SmartDeviceLink/public/SDLRPCFunctionNames.h b/SmartDeviceLink/public/SDLRPCFunctionNames.h
index 180b69ad8..22384942b 100644
--- a/SmartDeviceLink/public/SDLRPCFunctionNames.h
+++ b/SmartDeviceLink/public/SDLRPCFunctionNames.h
@@ -11,7 +11,7 @@
/**
* All RPC request / response / notification names
*/
-typedef SDLEnum SDLRPCFunctionName SDL_SWIFT_ENUM;
+typedef SDLEnum SDLRPCFunctionName NS_TYPED_ENUM;
/// Function name for an AddCommand RPC
extern SDLRPCFunctionName const SDLRPCFunctionNameAddCommand;
diff --git a/SmartDeviceLink/public/SDLRPCMessage.h b/SmartDeviceLink/public/SDLRPCMessage.h
index c6b04071d..9378f67eb 100644
--- a/SmartDeviceLink/public/SDLRPCMessage.h
+++ b/SmartDeviceLink/public/SDLRPCMessage.h
@@ -21,13 +21,6 @@ NS_ASSUME_NONNULL_BEGIN
- (instancetype)initWithName:(NSString *)name __deprecated_msg("This is not intended to be a public facing API");
/**
- * Returns the function name.
- *
- * @return The function name
- */
-- (nullable NSString *)getFunctionName __deprecated_msg("Call the .name property instead");
-
-/**
* Sets the function name.
*
* @param functionName The function name
@@ -35,14 +28,6 @@ NS_ASSUME_NONNULL_BEGIN
- (void)setFunctionName:(nullable NSString *)functionName __deprecated_msg("This is not intended to be a public facing API");
/**
- * Returns the value associated with the provided key. If the key does not exist, null is returned.
- *
- * @param functionName The key name
- * @return The value associated with the function name
- */
-- (nullable NSObject *)getParameters:(NSString *)functionName __deprecated_msg("Call the .parameters property instead");
-
-/**
* Sets a key-value pair using the function name as the key.
*
* @param functionName The name for the key
diff --git a/SmartDeviceLink/public/SDLRPCMessage.m b/SmartDeviceLink/public/SDLRPCMessage.m
index 15a6dd49a..b71e1dec1 100644
--- a/SmartDeviceLink/public/SDLRPCMessage.m
+++ b/SmartDeviceLink/public/SDLRPCMessage.m
@@ -65,18 +65,10 @@ NS_ASSUME_NONNULL_BEGIN
}
#pragma clang diagnostic pop
-- (nullable NSString *)getFunctionName {
- return self.name;
-}
-
- (void)setFunctionName:(nullable NSString *)functionName {
[_function sdl_setObject:functionName forName:SDLRPCParameterNameOperationName];
}
-- (nullable NSObject *)getParameters:(NSString *)functionName {
- return [_parameters sdl_objectForName:functionName ofClass:NSObject.class error:nil];
-}
-
- (void)setParameters:(NSString *)functionName value:(nullable NSObject *)value {
[_parameters sdl_setObject:value forName:functionName];
}
diff --git a/SmartDeviceLink/public/SDLRPCMessageType.h b/SmartDeviceLink/public/SDLRPCMessageType.h
index ac0df1958..e0ca142ac 100644
--- a/SmartDeviceLink/public/SDLRPCMessageType.h
+++ b/SmartDeviceLink/public/SDLRPCMessageType.h
@@ -20,7 +20,7 @@ typedef NS_ENUM(Byte, SDLRPCMessageType) {
};
/// A type of RPC message
-typedef SDLEnum SDLRPCMessageTypeName SDL_SWIFT_ENUM;
+typedef SDLEnum SDLRPCMessageTypeName NS_TYPED_ENUM;
/// A request that will require a response
extern SDLRPCMessageTypeName const SDLRPCMessageTypeNameRequest;
diff --git a/SmartDeviceLink/public/SDLRadioBand.h b/SmartDeviceLink/public/SDLRadioBand.h
index 537706bca..7486f0d71 100644
--- a/SmartDeviceLink/public/SDLRadioBand.h
+++ b/SmartDeviceLink/public/SDLRadioBand.h
@@ -7,7 +7,7 @@
/**
Radio bands, such as AM and FM, used in RadioControlData
*/
-typedef SDLEnum SDLRadioBand SDL_SWIFT_ENUM;
+typedef SDLEnum SDLRadioBand NS_TYPED_ENUM;
/**
* Represents AM radio band
diff --git a/SmartDeviceLink/public/SDLRadioControlCapabilities.h b/SmartDeviceLink/public/SDLRadioControlCapabilities.h
index 0c35df16f..7f4aba92f 100644
--- a/SmartDeviceLink/public/SDLRadioControlCapabilities.h
+++ b/SmartDeviceLink/public/SDLRadioControlCapabilities.h
@@ -14,63 +14,6 @@ NS_ASSUME_NONNULL_BEGIN
/**
Constructs a newly allocated SDLRadioControlCapabilities object with given parameters.
-
- @param moduleName The short friendly name of the radio control module.
- @param radioEnableAvailable Availability of the control of enable/disable radio.
- @param radioBandAvailable Availability of the control of radio band.
- @param radioFrequencyAvailable Availability of the control of radio frequency.
- @param hdChannelAvailable Availability of the control of HD radio channel.
- @param rdsDataAvailable Availability of the getting Radio Data System (RDS) data.
- @param availableHDsAvailable Availability of the getting the number of available HD channels.
- @param stateAvailable Availability of the getting the Radio state.
- @param signalStrengthAvailable Availability of the getting the signal strength.
- @param signalChangeThresholdAvailable Availability of the getting the signal Change Threshold.
- @return An instance of the SDLRadioControlCapabilities class.
- */
-- (instancetype)initWithModuleName:(NSString *)moduleName radioEnableAvailable:(BOOL)radioEnableAvailable radioBandAvailable:(BOOL)radioBandAvailable radioFrequencyAvailable:(BOOL)radioFrequencyAvailable hdChannelAvailable:(BOOL)hdChannelAvailable rdsDataAvailable:(BOOL)rdsDataAvailable availableHDsAvailable:(BOOL)availableHDsAvailable stateAvailable:(BOOL)stateAvailable signalStrengthAvailable:(BOOL)signalStrengthAvailable signalChangeThresholdAvailable:(BOOL)signalChangeThresholdAvailable __deprecated_msg(("Use initWithModuleName:moduleName:radioEnableAvailable radioFrequencyAvailable:hdChannelAvailable:rdsDataAvailable:availableHDChannelsAvailable:stateAvailable:signalStrengthAvailable:signalChangeThresholdAvailable:hdRadioEnableAvailable:siriusXMRadioAvailable:sisDataAvailable: instead"));
-
-/**
- Constructs a newly allocated SDLRadioControlCapabilities object with given parameters.
-
- @param moduleName The short friendly name of the radio control module.
- @param radioEnableAvailable Availability of the control of enable/disable radio.
- @param radioBandAvailable Availability of the control of radio band.
- @param radioFrequencyAvailable Availability of the control of radio frequency.
- @param hdChannelAvailable Availability of the control of HD radio channel.
- @param rdsDataAvailable Availability of the getting Radio Data System (RDS) data.
- @param availableHDsAvailable Availability of the getting the number of available HD channels.
- @param stateAvailable Availability of the getting the Radio state.
- @param signalStrengthAvailable Availability of the getting the signal strength.
- @param signalChangeThresholdAvailable Availability of the getting the signal Change Threshold.
- @param hdRadioEnableAvailable Availability of the control of enable/disable HD radio.
- @param siriusXMRadioAvailable Availability of sirius XM radio.
- @param sisDataAvailable Availability of sis data.
- @return An instance of the SDLRadioControlCapabilities class
- */
-- (instancetype)initWithModuleName:(NSString *)moduleName radioEnableAvailable:(BOOL)radioEnableAvailable radioBandAvailable:(BOOL)radioBandAvailable radioFrequencyAvailable:(BOOL)radioFrequencyAvailable hdChannelAvailable:(BOOL)hdChannelAvailable rdsDataAvailable:(BOOL)rdsDataAvailable availableHDsAvailable:(BOOL)availableHDsAvailable stateAvailable:(BOOL)stateAvailable signalStrengthAvailable:(BOOL)signalStrengthAvailable signalChangeThresholdAvailable:(BOOL)signalChangeThresholdAvailable hdRadioEnableAvailable:(BOOL)hdRadioEnableAvailable siriusXMRadioAvailable:(BOOL)siriusXMRadioAvailable sisDataAvailable:(BOOL)sisDataAvailable __deprecated_msg(("Use initWithModuleName:moduleName:radioEnableAvailable radioFrequencyAvailable:hdChannelAvailable:rdsDataAvailable:availableHDChannelsAvailable:stateAvailable:signalStrengthAvailable:signalChangeThresholdAvailable:hdRadioEnableAvailable:siriusXMRadioAvailable:sisDataAvailable: instead"));
-
-/**
- Constructs a newly allocated SDLRadioControlCapabilities object with given parameters.
-
- @param moduleName The short friendly name of the radio control module.
- @param radioEnableAvailable Availability of the control of enable/disable radio.
- @param radioBandAvailable Availability of the control of radio band.
- @param radioFrequencyAvailable Availability of the control of radio frequency.
- @param hdChannelAvailable Availability of the control of HD radio channel.
- @param rdsDataAvailable Availability of the getting Radio Data System (RDS) data.
- @param availableHDChannelsAvailable Availability of the list of available HD sub-channel indexes.
- @param stateAvailable Availability of the getting the Radio state.
- @param signalStrengthAvailable Availability of the getting the signal strength.
- @param signalChangeThresholdAvailable Availability of the getting the signal Change Threshold.
- @param hdRadioEnableAvailable Availability of the control of enable/disable HD radio.
- @param siriusXMRadioAvailable Availability of sirius XM radio.
- @param sisDataAvailable Availability of sis data.
- @return An instance of the SDLRadioControlCapabilities class
- */
-- (instancetype)initWithModuleName:(NSString *)moduleName radioEnableAvailable:(BOOL)radioEnableAvailable radioBandAvailable:(BOOL)radioBandAvailable radioFrequencyAvailable:(BOOL)radioFrequencyAvailable hdChannelAvailable:(BOOL)hdChannelAvailable rdsDataAvailable:(BOOL)rdsDataAvailable availableHDChannelsAvailable:(BOOL)availableHDChannelsAvailable stateAvailable:(BOOL)stateAvailable signalStrengthAvailable:(BOOL)signalStrengthAvailable signalChangeThresholdAvailable:(BOOL)signalChangeThresholdAvailable hdRadioEnableAvailable:(BOOL)hdRadioEnableAvailable siriusXMRadioAvailable:(BOOL)siriusXMRadioAvailable sisDataAvailable:(BOOL)sisDataAvailable __deprecated_msg(("Use initWithModuleName:moduleName:moduleInfo:radioEnableAvailable radioFrequencyAvailable:hdChannelAvailable:rdsDataAvailable:availableHDChannelsAvailable:stateAvailable:signalStrengthAvailable:signalChangeThresholdAvailable:hdRadioEnableAvailable:siriusXMRadioAvailable:sisDataAvailable: instead"));
-
-/**
- Constructs a newly allocated SDLRadioControlCapabilities object with given parameters.
@param moduleName The short friendly name of the radio control module.
@param moduleInfo Information about a RC module, including its id.
diff --git a/SmartDeviceLink/public/SDLRadioControlCapabilities.m b/SmartDeviceLink/public/SDLRadioControlCapabilities.m
index 921e2e651..ac1894de7 100644
--- a/SmartDeviceLink/public/SDLRadioControlCapabilities.m
+++ b/SmartDeviceLink/public/SDLRadioControlCapabilities.m
@@ -10,56 +10,6 @@ NS_ASSUME_NONNULL_BEGIN
@implementation SDLRadioControlCapabilities
-- (instancetype)initWithModuleName:(NSString *)moduleName radioEnableAvailable:(BOOL)radioEnableAvailable radioBandAvailable:(BOOL)radioBandAvailable radioFrequencyAvailable:(BOOL)radioFrequencyAvailable hdChannelAvailable:(BOOL)hdChannelAvailable rdsDataAvailable:(BOOL)rdsDataAvailable availableHDsAvailable:(BOOL)availableHDsAvailable stateAvailable:(BOOL)stateAvailable signalStrengthAvailable:(BOOL)signalStrengthAvailable signalChangeThresholdAvailable:(BOOL)signalChangeThresholdAvailable {
- return [self initWithModuleName:moduleName radioEnableAvailable:radioEnableAvailable radioBandAvailable:radioBandAvailable radioFrequencyAvailable:radioFrequencyAvailable hdChannelAvailable:hdChannelAvailable rdsDataAvailable:rdsDataAvailable availableHDsAvailable:availableHDsAvailable stateAvailable:stateAvailable signalStrengthAvailable:signalStrengthAvailable signalChangeThresholdAvailable:signalChangeThresholdAvailable hdRadioEnableAvailable:NO siriusXMRadioAvailable:NO sisDataAvailable:NO];
-}
-
-- (instancetype)initWithModuleName:(NSString *)moduleName radioEnableAvailable:(BOOL)radioEnableAvailable radioBandAvailable:(BOOL)radioBandAvailable radioFrequencyAvailable:(BOOL)radioFrequencyAvailable hdChannelAvailable:(BOOL)hdChannelAvailable rdsDataAvailable:(BOOL)rdsDataAvailable availableHDsAvailable:(BOOL)availableHDsAvailable stateAvailable:(BOOL)stateAvailable signalStrengthAvailable:(BOOL)signalStrengthAvailable signalChangeThresholdAvailable:(BOOL)signalChangeThresholdAvailable hdRadioEnableAvailable:(BOOL)hdRadioEnableAvailable siriusXMRadioAvailable:(BOOL)siriusXMRadioAvailable sisDataAvailable:(BOOL)sisDataAvailable {
- self = [self init];
- if(!self){
- return nil;
- }
-
- self.moduleName = moduleName;
- self.radioEnableAvailable = @(radioEnableAvailable);
- self.radioBandAvailable = @(radioBandAvailable);
- self.radioFrequencyAvailable = @(radioFrequencyAvailable);
- self.hdChannelAvailable = @(hdChannelAvailable);
- self.rdsDataAvailable = @(rdsDataAvailable);
- self.availableHDsAvailable = @(availableHDsAvailable);
- self.stateAvailable = @(stateAvailable);
- self.signalStrengthAvailable = @(signalStrengthAvailable);
- self.signalChangeThresholdAvailable = @(signalChangeThresholdAvailable);
- self.hdRadioEnableAvailable = @(hdRadioEnableAvailable);
- self.siriusXMRadioAvailable = @(siriusXMRadioAvailable);
- self.sisDataAvailable = @(sisDataAvailable);
-
- return self;
-}
-
-- (instancetype)initWithModuleName:(NSString *)moduleName radioEnableAvailable:(BOOL)radioEnableAvailable radioBandAvailable:(BOOL)radioBandAvailable radioFrequencyAvailable:(BOOL)radioFrequencyAvailable hdChannelAvailable:(BOOL)hdChannelAvailable rdsDataAvailable:(BOOL)rdsDataAvailable availableHDChannelsAvailable:(BOOL)availableHDChannelsAvailable stateAvailable:(BOOL)stateAvailable signalStrengthAvailable:(BOOL)signalStrengthAvailable signalChangeThresholdAvailable:(BOOL)signalChangeThresholdAvailable hdRadioEnableAvailable:(BOOL)hdRadioEnableAvailable siriusXMRadioAvailable:(BOOL)siriusXMRadioAvailable sisDataAvailable:(BOOL)sisDataAvailable {
- self = [self init];
- if(!self){
- return nil;
- }
-
- self.moduleName = moduleName;
- self.radioEnableAvailable = @(radioEnableAvailable);
- self.radioBandAvailable = @(radioBandAvailable);
- self.radioFrequencyAvailable = @(radioFrequencyAvailable);
- self.hdChannelAvailable = @(hdChannelAvailable);
- self.rdsDataAvailable = @(rdsDataAvailable);
- self.availableHDChannelsAvailable = @(availableHDChannelsAvailable);
- self.stateAvailable = @(stateAvailable);
- self.signalStrengthAvailable = @(signalStrengthAvailable);
- self.signalChangeThresholdAvailable = @(signalChangeThresholdAvailable);
- self.hdRadioEnableAvailable = @(hdRadioEnableAvailable);
- self.siriusXMRadioAvailable = @(siriusXMRadioAvailable);
- self.sisDataAvailable = @(sisDataAvailable);
-
- return self;
-}
-
- (instancetype)initWithModuleName:(NSString *)moduleName moduleInfo:(nullable SDLModuleInfo *)moduleInfo radioEnableAvailable:(BOOL)radioEnableAvailable radioBandAvailable:(BOOL)radioBandAvailable radioFrequencyAvailable:(BOOL)radioFrequencyAvailable hdChannelAvailable:(BOOL)hdChannelAvailable rdsDataAvailable:(BOOL)rdsDataAvailable availableHDChannelsAvailable:(BOOL)availableHDChannelsAvailable stateAvailable:(BOOL)stateAvailable signalStrengthAvailable:(BOOL)signalStrengthAvailable signalChangeThresholdAvailable:(BOOL)signalChangeThresholdAvailable hdRadioEnableAvailable:(BOOL)hdRadioEnableAvailable siriusXMRadioAvailable:(BOOL)siriusXMRadioAvailable sisDataAvailable:(BOOL)sisDataAvailable {
self = [self init];
if(!self){
diff --git a/SmartDeviceLink/public/SDLRadioControlData.h b/SmartDeviceLink/public/SDLRadioControlData.h
index 182e6105e..523322b4c 100644
--- a/SmartDeviceLink/public/SDLRadioControlData.h
+++ b/SmartDeviceLink/public/SDLRadioControlData.h
@@ -24,18 +24,6 @@ NS_ASSUME_NONNULL_BEGIN
@param band Radio band value
@param hdChannel Current HD sub-channel
@param radioEnable whether or not radio is enabled
- @return An instance of the SDLRadioControlData class
- */
-- (instancetype)initWithFrequencyInteger:(nullable NSNumber<SDLInt> *)frequencyInteger frequencyFraction:(nullable NSNumber<SDLInt> *)frequencyFraction band:(nullable SDLRadioBand)band hdChannel:(nullable NSNumber<SDLInt> *)hdChannel radioEnable:(nullable NSNumber<SDLBool> *)radioEnable __deprecated_msg(("Use initWithFrequencyInteger:frequencyInteger:frequencyFraction:band:hdChannel:radioEnable:sisData: instead"));
-
-/**
- Constructs a newly allocated SDLRadioControlCapabilities object with given parameters.
-
- @param frequencyInteger integer part of the frequency
- @param frequencyFraction fractional part of the frequency
- @param band Radio band value
- @param hdChannel Current HD sub-channel
- @param radioEnable whether or not radio is enabled
@param hdRadioEnable whether or not hdradio is enabled
@return An instance of the SDLRadioControlData class
*/
diff --git a/SmartDeviceLink/public/SDLRadioControlData.m b/SmartDeviceLink/public/SDLRadioControlData.m
index 9fb82f080..59a4d21d9 100644
--- a/SmartDeviceLink/public/SDLRadioControlData.m
+++ b/SmartDeviceLink/public/SDLRadioControlData.m
@@ -12,21 +12,6 @@ NS_ASSUME_NONNULL_BEGIN
@implementation SDLRadioControlData
-- (instancetype)initWithFrequencyInteger:(nullable NSNumber<SDLInt> *)frequencyInteger frequencyFraction:(nullable NSNumber<SDLInt> *)frequencyFraction band:(nullable SDLRadioBand)band hdChannel:(nullable NSNumber<SDLInt> *)hdChannel radioEnable:(nullable NSNumber<SDLBool> *)radioEnable {
- self = [self init];
- if(!self) {
- return nil;
- }
-
- self.frequencyInteger = frequencyInteger;
- self.frequencyFraction = frequencyFraction;
- self.band = band;
- self.hdChannel = hdChannel;
- self.radioEnable = radioEnable;
-
- return self;
-}
-
- (instancetype)initWithFrequencyInteger:(nullable NSNumber<SDLInt> *)frequencyInteger frequencyFraction:(nullable NSNumber<SDLInt> *)frequencyFraction band:(nullable SDLRadioBand)band hdChannel:(nullable NSNumber<SDLInt> *)hdChannel radioEnable:(nullable NSNumber<SDLBool> *)radioEnable hdRadioEnable:(nullable NSNumber<SDLBool> *)hdRadioEnable {
self = [self init];
if(!self) {
diff --git a/SmartDeviceLink/public/SDLRadioState.h b/SmartDeviceLink/public/SDLRadioState.h
index ee5945a96..fe9963984 100644
--- a/SmartDeviceLink/public/SDLRadioState.h
+++ b/SmartDeviceLink/public/SDLRadioState.h
@@ -7,7 +7,7 @@
/**
* List possible states of a remote control radio module. Used in RadioControlData.
*/
-typedef SDLEnum SDLRadioState SDL_SWIFT_ENUM;
+typedef SDLEnum SDLRadioState NS_TYPED_ENUM;
/**
* Represents Radio state as ACQUIRING
diff --git a/SmartDeviceLink/public/SDLRegisterAppInterface.h b/SmartDeviceLink/public/SDLRegisterAppInterface.h
index d1b8298e7..805411b9a 100644
--- a/SmartDeviceLink/public/SDLRegisterAppInterface.h
+++ b/SmartDeviceLink/public/SDLRegisterAppInterface.h
@@ -9,7 +9,6 @@
@class SDLAppInfo;
@class SDLDeviceInfo;
@class SDLLifecycleConfiguration;
-@class SDLSyncMsgVersion;
@class SDLMsgVersion;
@class SDLTemplateColorScheme;
@class SDLTTSChunk;
@@ -50,36 +49,6 @@ NS_ASSUME_NONNULL_BEGIN
- (instancetype)initWithAppName:(NSString *)appName appId:(NSString *)appId languageDesired:(SDLLanguage)languageDesired;
/**
- * Convenience init for registering the application with an app name, app id, desired language, whether or not the app is a media app, app types, and the short app name.
- *
- * @param appName The mobile application's name
- * @param appId An appId used to validate app with policy table entries
- * @param languageDesired The language the application intends to use for user interaction
- * @param isMediaApp Indicates if the application is a media or a non-media application
- * @param appTypes A list of all applicable app types stating which classifications to be given to the app
- * @param shortAppName An abbreviated version of the mobile application's name
- * @return A SDLRegisterAppInterface object
- */
-- (instancetype)initWithAppName:(NSString *)appName appId:(NSString *)appId languageDesired:(SDLLanguage)languageDesired isMediaApp:(BOOL)isMediaApp appTypes:(NSArray<SDLAppHMIType> *)appTypes shortAppName:(nullable NSString *)shortAppName __deprecated_msg(("Use initWithAppName:appId:fullAppId:languageDesired:isMediaApp:appTypes:shortAppName:ttsName:vrSynonyms:hmiDisplayLanguageDesired:resumeHash:dayColorScheme:nightColorScheme: instead"));
-
-/**
- * Convenience init for registering the application with an app name, app id, desired language, whether or not the app is a media app, app types, the short app name, tts name, voice recognition synonyms, the hmi display language desired, and the resume hash.
- *
- * @param appName The mobile application's name
- * @param appId An appId used to validate app with policy table entries
- * @param languageDesired The language the application intends to use for user interaction
- * @param isMediaApp Indicates if the application is a media or a non-media application
- * @param appTypes A list of all applicable app types stating which classifications to be given to the app
- * @param shortAppName An abbreviated version of the mobile application's name
- * @param ttsName TTS string for VR recognition of the mobile application name
- * @param vrSynonyms Additional voice recognition commands
- * @param hmiDisplayLanguageDesired Current app's expected VR+TTS language
- * @param resumeHash ID used to uniquely identify current state of all app data that can persist through connection cycles
- * @return A SDLRegisterAppInterface object
- */
-- (instancetype)initWithAppName:(NSString *)appName appId:(NSString *)appId languageDesired:(SDLLanguage)languageDesired isMediaApp:(BOOL)isMediaApp appTypes:(NSArray<SDLAppHMIType> *)appTypes shortAppName:(nullable NSString *)shortAppName ttsName:(nullable NSArray<SDLTTSChunk *> *)ttsName vrSynonyms:(nullable NSArray<NSString *> *)vrSynonyms hmiDisplayLanguageDesired:(SDLLanguage)hmiDisplayLanguageDesired resumeHash:(nullable NSString *)resumeHash __deprecated_msg(("Use initWithAppName:appId:fullAppId:languageDesired:isMediaApp:appTypes:shortAppName:ttsName:vrSynonyms:hmiDisplayLanguageDesired:resumeHash:dayColorScheme:nightColorScheme: instead"));
-
-/**
* Convenience init for registering the application with all possible options.
*
* @param appName The mobile application's name
@@ -102,15 +71,6 @@ NS_ASSUME_NONNULL_BEGIN
/**
* Specifies the version number of the SmartDeviceLink protocol that is supported by the mobile application.
*
- * SDLSyncMsgVersion, Required
- *
- * @since SDL 1.0
- */
-@property (strong, nonatomic) SDLSyncMsgVersion *syncMsgVersion __deprecated_msg(("Use sdlMsgVersion instead"));
-
-/**
- * Specifies the version number of the SmartDeviceLink protocol that is supported by the mobile application.
- *
* SDLMsgVersion, Required
*
* @since SDL 1.0
diff --git a/SmartDeviceLink/public/SDLRegisterAppInterface.m b/SmartDeviceLink/public/SDLRegisterAppInterface.m
index 6fa2ed638..eced457ff 100644
--- a/SmartDeviceLink/public/SDLRegisterAppInterface.m
+++ b/SmartDeviceLink/public/SDLRegisterAppInterface.m
@@ -13,7 +13,6 @@
#import "SDLLifecycleConfiguration.h"
#import "SDLRPCParameterNames.h"
#import "SDLRPCFunctionNames.h"
-#import "SDLSyncMsgVersion.h"
#import "SDLMsgVersion.h"
#import "SDLTemplateColorScheme.h"
#import "SDLTTSChunk.h"
@@ -76,42 +75,17 @@ NS_ASSUME_NONNULL_BEGIN
return self;
}
-- (instancetype)initWithAppName:(NSString *)appName appId:(NSString *)appId languageDesired:(SDLLanguage)languageDesired isMediaApp:(BOOL)isMediaApp appTypes:(NSArray<SDLAppHMIType> *)appTypes shortAppName:(nullable NSString *)shortAppName {
+- (instancetype)initWithAppName:(NSString *)appName appId:(NSString *)appId fullAppId:(nullable NSString *)fullAppId languageDesired:(SDLLanguage)languageDesired isMediaApp:(BOOL)isMediaApp appTypes:(NSArray<SDLAppHMIType> *)appTypes shortAppName:(nullable NSString *)shortAppName ttsName:(nullable NSArray<SDLTTSChunk *> *)ttsName vrSynonyms:(nullable NSArray<NSString *> *)vrSynonyms hmiDisplayLanguageDesired:(SDLLanguage)hmiDisplayLanguageDesired resumeHash:(nullable NSString *)resumeHash dayColorScheme:(nullable SDLTemplateColorScheme *)dayColorScheme nightColorScheme:(nullable SDLTemplateColorScheme *)nightColorScheme {
self = [self initWithAppName:appName appId:appId languageDesired:languageDesired];
- if (!self) {
- return nil;
- }
+ self.fullAppID = fullAppId;
self.isMediaApplication = @(isMediaApp);
self.appHMIType = appTypes;
self.ngnMediaScreenAppName = shortAppName;
-
- return self;
-}
-
-- (instancetype)initWithAppName:(NSString *)appName appId:(NSString *)appId languageDesired:(SDLLanguage)languageDesired isMediaApp:(BOOL)isMediaApp appTypes:(NSArray<SDLAppHMIType> *)appTypes shortAppName:(nullable NSString *)shortAppName ttsName:(nullable NSArray<SDLTTSChunk *> *)ttsName vrSynonyms:(nullable NSArray<NSString *> *)vrSynonyms hmiDisplayLanguageDesired:(SDLLanguage)hmiDisplayLanguageDesired resumeHash:(nullable NSString *)resumeHash {
- self = [self initWithAppName:appName appId:appId languageDesired:languageDesired isMediaApp:isMediaApp appTypes:appTypes shortAppName:shortAppName];
- if (!self) {
- return nil;
- }
-
self.ttsName = [ttsName copy];
self.vrSynonyms = [vrSynonyms copy];
self.hmiDisplayLanguageDesired = hmiDisplayLanguageDesired;
self.hashID = resumeHash;
-
- return self;
-}
-
-- (instancetype)initWithAppName:(NSString *)appName appId:(NSString *)appId fullAppId:(nullable NSString *)fullAppId languageDesired:(SDLLanguage)languageDesired isMediaApp:(BOOL)isMediaApp appTypes:(NSArray<SDLAppHMIType> *)appTypes shortAppName:(nullable NSString *)shortAppName ttsName:(nullable NSArray<SDLTTSChunk *> *)ttsName vrSynonyms:(nullable NSArray<NSString *> *)vrSynonyms hmiDisplayLanguageDesired:(SDLLanguage)hmiDisplayLanguageDesired resumeHash:(nullable NSString *)resumeHash dayColorScheme:(nullable SDLTemplateColorScheme *)dayColorScheme nightColorScheme:(nullable SDLTemplateColorScheme *)nightColorScheme {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- self = [self initWithAppName:appName appId:appId languageDesired:languageDesired isMediaApp:isMediaApp appTypes:appTypes shortAppName:shortAppName ttsName:ttsName vrSynonyms:vrSynonyms hmiDisplayLanguageDesired:hmiDisplayLanguageDesired resumeHash:resumeHash];
-#pragma clang diagnostic pop
-
- if (!self) { return nil; }
-
- self.fullAppID = fullAppId;
self.dayColorScheme = dayColorScheme;
self.nightColorScheme = nightColorScheme;
@@ -120,19 +94,6 @@ NS_ASSUME_NONNULL_BEGIN
#pragma mark - Getters and Setters
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
-- (void)setSyncMsgVersion:(SDLSyncMsgVersion *)syncMsgVersion {
- SDLMsgVersion * sdlMsgVersion = [[SDLMsgVersion alloc] initWithMajorVersion:(uint8_t)syncMsgVersion.majorVersion.unsignedIntValue minorVersion:(uint8_t)syncMsgVersion.minorVersion.unsignedIntValue patchVersion:(uint8_t)syncMsgVersion.patchVersion.unsignedIntValue];
- [self.parameters sdl_setObject:sdlMsgVersion forName:SDLRPCParameterNameSyncMessageVersion];
-}
-
-- (SDLSyncMsgVersion *)syncMsgVersion {
- SDLMsgVersion * sdlMsgVersion = [self.parameters sdl_objectForName:SDLRPCParameterNameSyncMessageVersion ofClass:SDLMsgVersion.class error:nil];
- return [[SDLSyncMsgVersion alloc] initWithMajorVersion:(uint8_t)sdlMsgVersion.majorVersion.unsignedIntValue minorVersion:(uint8_t)sdlMsgVersion.minorVersion.unsignedIntValue patchVersion:(uint8_t)sdlMsgVersion.patchVersion.unsignedIntValue];
-}
-#pragma clang diagnostic pop
-
- (void)setSdlMsgVersion:(SDLMsgVersion *)sdlMsgVersion {
[self.parameters sdl_setObject:sdlMsgVersion forName:SDLRPCParameterNameSyncMessageVersion];
}
diff --git a/SmartDeviceLink/public/SDLRegisterAppInterfaceResponse.h b/SmartDeviceLink/public/SDLRegisterAppInterfaceResponse.h
index 20c9cf4e2..3538e22e3 100644
--- a/SmartDeviceLink/public/SDLRegisterAppInterfaceResponse.h
+++ b/SmartDeviceLink/public/SDLRegisterAppInterfaceResponse.h
@@ -16,7 +16,6 @@
@class SDLHMICapabilities;
@class SDLPresetBankCapabilities;
@class SDLSoftButtonCapabilities;
-@class SDLSyncMsgVersion;
@class SDLMsgVersion;
@class SDLVehicleType;
@@ -33,15 +32,6 @@ NS_ASSUME_NONNULL_BEGIN
/**
* Specifies the negotiated version number of the SmartDeviceLink protocol that is to be supported by the mobile application.
*
- * SDLSyncMsgVersion, Optional
- *
- * @since SDL 1.0
- */
-@property (nullable, strong, nonatomic) SDLSyncMsgVersion *syncMsgVersion __deprecated_msg(("Use sdlMsgVersion Instead"));
-
-/**
- * Specifies the negotiated version number of the SmartDeviceLink protocol that is to be supported by the mobile application.
- *
* SDLMsgVersion, Optional
*
* @since SDL 1.0
diff --git a/SmartDeviceLink/public/SDLRegisterAppInterfaceResponse.m b/SmartDeviceLink/public/SDLRegisterAppInterfaceResponse.m
index 5c081e9e6..fdc857cd2 100644
--- a/SmartDeviceLink/public/SDLRegisterAppInterfaceResponse.m
+++ b/SmartDeviceLink/public/SDLRegisterAppInterfaceResponse.m
@@ -13,7 +13,6 @@
#import "SDLRPCFunctionNames.h"
#import "SDLPresetBankCapabilities.h"
#import "SDLSoftButtonCapabilities.h"
-#import "SDLSyncMsgVersion.h"
#import "SDLMsgVersion.h"
#import "SDLVehicleType.h"
#import "SDLVrCapabilities.h"
@@ -31,26 +30,6 @@ NS_ASSUME_NONNULL_BEGIN
}
#pragma clang diagnostic pop
-- (void)setSyncMsgVersion:(nullable SDLSyncMsgVersion *)syncMsgVersion {
- if (syncMsgVersion == nil) {
- [self.parameters sdl_setObject:nil forName:SDLRPCParameterNameSyncMessageVersion];
- return;
- }
-
- SDLMsgVersion *sdlMsgVersion = [[SDLMsgVersion alloc] initWithMajorVersion:(uint8_t)syncMsgVersion.majorVersion.unsignedIntValue minorVersion:(uint8_t)syncMsgVersion.minorVersion.unsignedIntValue patchVersion:(uint8_t)syncMsgVersion.patchVersion.unsignedIntValue];
- [self.parameters sdl_setObject:sdlMsgVersion forName:SDLRPCParameterNameSyncMessageVersion];
-}
-
-- (nullable SDLSyncMsgVersion *)syncMsgVersion {
- SDLMsgVersion *sdlMsgVersion = [self.parameters sdl_objectForName:SDLRPCParameterNameSyncMessageVersion ofClass:SDLMsgVersion.class error:nil];
-
- if(sdlMsgVersion == nil) {
- return [self.parameters sdl_objectForName:SDLRPCParameterNameSyncMessageVersion ofClass:SDLSyncMsgVersion.class error:nil];
- }
-
- return [[SDLSyncMsgVersion alloc] initWithMajorVersion:(uint8_t)sdlMsgVersion.majorVersion.unsignedIntValue minorVersion:(uint8_t)sdlMsgVersion.minorVersion.unsignedIntValue patchVersion:(uint8_t)sdlMsgVersion.patchVersion.unsignedIntValue];
-}
-
- (void)setSdlMsgVersion:(nullable SDLMsgVersion *)sdlMsgVersion {
[self.parameters sdl_setObject:sdlMsgVersion forName:SDLRPCParameterNameSyncMessageVersion];
}
diff --git a/SmartDeviceLink/public/SDLRemoteControlCapabilities.h b/SmartDeviceLink/public/SDLRemoteControlCapabilities.h
index 2cdbf4f2e..6281aa566 100644
--- a/SmartDeviceLink/public/SDLRemoteControlCapabilities.h
+++ b/SmartDeviceLink/public/SDLRemoteControlCapabilities.h
@@ -19,14 +19,6 @@ NS_ASSUME_NONNULL_BEGIN
*/
@interface SDLRemoteControlCapabilities : SDLRPCStruct
-/// Constructs a newly allocated SDLRemoteControlCapabilities object
-///
-/// @param climateControlCapabilities Array of SDLClimateControlCapabilities
-/// @param radioControlCapabilities Array of SDLRadioControlCapabilities
-/// @param buttonCapabilities Array of SDLButtonCapabilities
-/// @return An instance of the SDLRemoteControlCapabilities class
-- (instancetype)initWithClimateControlCapabilities:(nullable NSArray<SDLClimateControlCapabilities *> *)climateControlCapabilities radioControlCapabilities:(nullable NSArray<SDLRadioControlCapabilities *> *)radioControlCapabilities buttonCapabilities:(nullable NSArray<SDLButtonCapabilities *> *)buttonCapabilities __deprecated_msg("Use initWithClimateControlCapabilities:climateControlCapabilities:radioControlCapabilities:buttonCapabilities:seatControlCapabilities:audioControlCapabilities:hmiSettingsControlCapabilities:lightControlCapabilities: instead");
-
/**
Constructs a newly allocated SDLRemoteControlCapabilities object with given parameters
diff --git a/SmartDeviceLink/public/SDLRemoteControlCapabilities.m b/SmartDeviceLink/public/SDLRemoteControlCapabilities.m
index 47b747aec..6024e34fa 100644
--- a/SmartDeviceLink/public/SDLRemoteControlCapabilities.m
+++ b/SmartDeviceLink/public/SDLRemoteControlCapabilities.m
@@ -17,11 +17,6 @@ NS_ASSUME_NONNULL_BEGIN
@implementation SDLRemoteControlCapabilities
-- (instancetype)initWithClimateControlCapabilities:(nullable NSArray<SDLClimateControlCapabilities *> *)climateControlCapabilities radioControlCapabilities:(nullable NSArray<SDLRadioControlCapabilities *> *)radioControlCapabilities buttonCapabilities:(nullable NSArray<SDLButtonCapabilities *> *)buttonCapabilities {
-
- return [self initWithClimateControlCapabilities:climateControlCapabilities radioControlCapabilities:radioControlCapabilities buttonCapabilities:buttonCapabilities seatControlCapabilities:nil audioControlCapabilities:nil hmiSettingsControlCapabilities:nil lightControlCapabilities:nil];
-}
-
- (instancetype)initWithClimateControlCapabilities:(nullable NSArray<SDLClimateControlCapabilities *> *)climateControlCapabilities radioControlCapabilities:(nullable NSArray<SDLRadioControlCapabilities *> *)radioControlCapabilities buttonCapabilities:(nullable NSArray<SDLButtonCapabilities *> *)buttonCapabilities seatControlCapabilities:(nullable NSArray<SDLSeatControlCapabilities *> *)seatControlCapabilities audioControlCapabilities:(nullable NSArray<SDLAudioControlCapabilities *> *)audioControlCapabilities hmiSettingsControlCapabilities:(nullable NSArray<SDLHMISettingsControlCapabilities *> *)hmiSettingsControlCapabilities lightControlCapabilities:(nullable NSArray<SDLLightControlCapabilities *> *)lightControlCapabilities {
self = [super init];
if (!self) {
diff --git a/SmartDeviceLink/public/SDLRequestType.h b/SmartDeviceLink/public/SDLRequestType.h
index 9f56d7bc3..f91444d53 100644
--- a/SmartDeviceLink/public/SDLRequestType.h
+++ b/SmartDeviceLink/public/SDLRequestType.h
@@ -7,7 +7,7 @@
/**
A type of system request. Used in SystemRequest.
*/
-typedef SDLEnum SDLRequestType SDL_SWIFT_ENUM;
+typedef SDLEnum SDLRequestType NS_TYPED_ENUM;
/**
An HTTP request
diff --git a/SmartDeviceLink/public/SDLResult.h b/SmartDeviceLink/public/SDLResult.h
index dd966102e..58624544c 100644
--- a/SmartDeviceLink/public/SDLResult.h
+++ b/SmartDeviceLink/public/SDLResult.h
@@ -9,7 +9,7 @@
*
* @since SDL 1.0
*/
-typedef SDLEnum SDLResult SDL_SWIFT_ENUM;
+typedef SDLEnum SDLResult NS_TYPED_ENUM;
/**
* The request succeeded
diff --git a/SmartDeviceLink/public/SDLSamplingRate.h b/SmartDeviceLink/public/SDLSamplingRate.h
index 4db452df3..ced15ffc2 100644
--- a/SmartDeviceLink/public/SDLSamplingRate.h
+++ b/SmartDeviceLink/public/SDLSamplingRate.h
@@ -9,7 +9,7 @@
@since SDL 2.0
*/
-typedef SDLEnum SDLSamplingRate SDL_SWIFT_ENUM;
+typedef SDLEnum SDLSamplingRate NS_TYPED_ENUM;
/**
Sampling rate of 8 kHz
diff --git a/SmartDeviceLink/public/SDLScrollableMessage.h b/SmartDeviceLink/public/SDLScrollableMessage.h
index f2abda1ed..a81dd0393 100644
--- a/SmartDeviceLink/public/SDLScrollableMessage.h
+++ b/SmartDeviceLink/public/SDLScrollableMessage.h
@@ -37,16 +37,6 @@ NS_ASSUME_NONNULL_BEGIN
- (instancetype)initWithMessage:(NSString *)message timeout:(UInt16)timeout softButtons:(nullable NSArray<SDLSoftButton *> *)softButtons cancelID:(UInt32)cancelID;
/**
- Convenience init for creating a scrolling message with text and buttons.
-
- @param message Body of text that can include newlines and tabs
- @param timeout Indicates how long of a timeout from the last action (i.e. scrolling message resets timeout)
- @param softButtons Buttons for the displayed scrollable message
- @return A SDLScrollableMessage object
- */
-- (instancetype)initWithMessage:(NSString *)message timeout:(UInt16)timeout softButtons:(nullable NSArray<SDLSoftButton *> *)softButtons __deprecated_msg("Use initWithMessage:timeout:softButtons:cancelID: instead");
-
-/**
Body of text that can include newlines and tabs.
String, Required, Max length 500 chars
diff --git a/SmartDeviceLink/public/SDLScrollableMessage.m b/SmartDeviceLink/public/SDLScrollableMessage.m
index 994becaa8..ef0208beb 100644
--- a/SmartDeviceLink/public/SDLScrollableMessage.m
+++ b/SmartDeviceLink/public/SDLScrollableMessage.m
@@ -40,10 +40,6 @@ NS_ASSUME_NONNULL_BEGIN
return [self initWithScrollableMessageBody:message timeout:@(timeout) softButtons:softButtons cancelID:@(cancelID)];
}
-- (instancetype)initWithMessage:(NSString *)message timeout:(UInt16)timeout softButtons:(nullable NSArray<SDLSoftButton *> *)softButtons {
- return [self initWithScrollableMessageBody:message timeout:@(timeout) softButtons:softButtons cancelID:nil];
-}
-
- (instancetype)initWithMessage:(NSString *)message {
return [self initWithScrollableMessageBody:message timeout:nil softButtons:nil cancelID:nil];
}
diff --git a/SmartDeviceLink/public/SDLSeatControlCapabilities.h b/SmartDeviceLink/public/SDLSeatControlCapabilities.h
index c55de4876..b85d9b3cb 100644
--- a/SmartDeviceLink/public/SDLSeatControlCapabilities.h
+++ b/SmartDeviceLink/public/SDLSeatControlCapabilities.h
@@ -12,12 +12,6 @@ NS_ASSUME_NONNULL_BEGIN
*/
@interface SDLSeatControlCapabilities : SDLRPCStruct
-/// Constructs a newly allocated SDLSeatControlCapabilities object with moduleName
-///
-/// @param moduleName The short friendly name of the module.
-/// @return An SDLSeatControlCapabilities object
-- (instancetype)initWithName:(NSString *)moduleName __deprecated_msg("Use initWithName:moduleInfo:");
-
/// Constructs a newly allocated SDLSeatControlCapabilities object with moduleName and moduleInfo
///
/// @param moduleName The short friendly name of the module.
@@ -25,28 +19,6 @@ NS_ASSUME_NONNULL_BEGIN
/// @return An SDLSeatControlCapabilities object
- (instancetype)initWithName:(NSString *)moduleName moduleInfo:(nullable SDLModuleInfo *)moduleInfo;
-/// Constructs a newly allocated SDLSeatControlCapabilities object with given parameters
-///
-/// @param moduleName The short friendly name of the module.
-/// @param heatingEnabledAvail Whether or not heating is available
-/// @param coolingEnabledAvail Whether or not heating is available
-/// @param heatingLevelAvail Whether or not heating level is available
-/// @param coolingLevelAvail Whether or not cooling level is available
-/// @param horizontalPositionAvail Whether or not horizontal Position is aavailable
-/// @param verticalPositionAvail Whether or not vertical position is available
-/// @param frontVerticalPositionAvail Whether or not front vertical position is available
-/// @param backVerticalPositionAvail Whether or not back vertical position is available
-/// @param backTitlAngleAvail Whether or not backTilt angle is available
-/// @param headSupportHorizontalPositionAvail Whether or not head supports for horizontal position is available
-/// @param headSupportVerticalPositionAvail Whether or not head supports for vertical position is available
-/// @param massageEnabledAvail Whether or not massage enabled is available
-/// @param massageModeAvail Whether or not massage mode is available
-/// @param massageCushionFirmnessAvail Whether or not massage cushion firmness is available
-/// @param memoryAvail Whether or not massage cushion firmness is available
-/// @return An SDLSeatControlCapabilities object
-- (instancetype)initWithName:(NSString *)moduleName heatingEnabledAvailable:(BOOL)heatingEnabledAvail
- coolingEnabledAvailable:(BOOL)coolingEnabledAvail heatingLevelAvailable:(BOOL)heatingLevelAvail coolingLevelAvailable:(BOOL)coolingLevelAvail horizontalPositionAvailable:(BOOL)horizontalPositionAvail verticalPositionAvailable:(BOOL)verticalPositionAvail frontVerticalPositionAvailable:(BOOL)frontVerticalPositionAvail backVerticalPositionAvailable:(BOOL)backVerticalPositionAvail backTiltAngleAvailable:(BOOL)backTitlAngleAvail headSupportHorizontalPositionAvailable:(BOOL)headSupportHorizontalPositionAvail headSupportVerticalPositionAvailable:(BOOL)headSupportVerticalPositionAvail massageEnabledAvailable:(BOOL)massageEnabledAvail massageModeAvailable:(BOOL)massageModeAvail massageCushionFirmnessAvailable:(BOOL)massageCushionFirmnessAvail memoryAvailable:(BOOL)memoryAvail __deprecated_msg("Use initWithName:moduleInfo:heatingEnabledAvailable:coolingEnabledAvailable:heatingLevelAvailable:coolingLevelAvailable:horizontalPositionAvailable:verticalPositionAvailable:frontVerticalPositionAvailable:backVerticalPositionAvailable:backTiltAngleAvailable:headSupportHorizontalPositionAvailable:headSupportVerticalPositionAvailable:massageEnabledAvailable:massageModeAvailable:massageCushionFirmnessAvailable:memoryAvailable:");
-
/// Constructs a newly allocated SDLSeatControlCapabilities object with all parameters
///
/// @param moduleName The short friendly name of the module.
diff --git a/SmartDeviceLink/public/SDLSeatControlCapabilities.m b/SmartDeviceLink/public/SDLSeatControlCapabilities.m
index 248c87db0..d7fec07ce 100644
--- a/SmartDeviceLink/public/SDLSeatControlCapabilities.m
+++ b/SmartDeviceLink/public/SDLSeatControlCapabilities.m
@@ -9,13 +9,6 @@ NS_ASSUME_NONNULL_BEGIN
@implementation SDLSeatControlCapabilities
-- (instancetype)initWithName:(NSString *)moduleName {
- if (self = [super init]) {
- self.moduleName = moduleName;
- }
- return self;
-}
-
- (instancetype)initWithName:(NSString *)moduleName moduleInfo:(nullable SDLModuleInfo *)moduleInfo {
if (self = [super init]) {
self.moduleName = moduleName;
@@ -24,33 +17,6 @@ NS_ASSUME_NONNULL_BEGIN
return self;
}
-- (instancetype)initWithName:(NSString *)moduleName heatingEnabledAvailable:(BOOL)heatingEnabledAvail coolingEnabledAvailable:(BOOL)coolingEnabledAvail heatingLevelAvailable:(BOOL)heatingLevelAvail coolingLevelAvailable:(BOOL)coolingLevelAvail horizontalPositionAvailable:(BOOL)horizontalPositionAvail verticalPositionAvailable:(BOOL)verticalPositionAvail frontVerticalPositionAvailable:(BOOL)frontVerticalPositionAvail backVerticalPositionAvailable:(BOOL)backVerticalPositionAvail backTiltAngleAvailable:(BOOL)backTitlAngleAvail headSupportHorizontalPositionAvailable:(BOOL)headSupportHorizontalPositionAvail headSupportVerticalPositionAvailable:(BOOL)headSupportVerticalPositionAvail massageEnabledAvailable:(BOOL)massageEnabledAvail massageModeAvailable:(BOOL)massageModeAvail massageCushionFirmnessAvailable:(BOOL)massageCushionFirmnessAvail memoryAvailable:(BOOL)memoryAvail {
-
- self = [super init];
- if (!self) {
- return nil;
- }
-
- self.moduleName = moduleName;
- self.heatingEnabledAvailable = @(heatingEnabledAvail);
- self.coolingEnabledAvailable = @(coolingEnabledAvail);
- self.heatingLevelAvailable = @(heatingLevelAvail);
- self.coolingLevelAvailable = @(coolingLevelAvail);
- self.horizontalPositionAvailable = @(horizontalPositionAvail);
- self.verticalPositionAvailable = @(verticalPositionAvail);
- self.frontVerticalPositionAvailable = @(frontVerticalPositionAvail);
- self.backVerticalPositionAvailable = @(backVerticalPositionAvail);
- self.backTiltAngleAvailable = @(backTitlAngleAvail);
- self.headSupportVerticalPositionAvailable = @(headSupportVerticalPositionAvail);
- self.headSupportHorizontalPositionAvailable = @(headSupportHorizontalPositionAvail);
- self.massageEnabledAvailable = @(massageEnabledAvail);
- self.massageModeAvailable = @(massageModeAvail);
- self.massageCushionFirmnessAvailable = @(massageCushionFirmnessAvail);
- self.memoryAvailable = @(memoryAvail);
-
- return self;
-}
-
- (instancetype)initWithName:(NSString *)moduleName moduleInfo:(nullable SDLModuleInfo *)moduleInfo heatingEnabledAvailable:(BOOL)heatingEnabledAvail
coolingEnabledAvailable:(BOOL)coolingEnabledAvail heatingLevelAvailable:(BOOL)heatingLevelAvail coolingLevelAvailable:(BOOL)coolingLevelAvail horizontalPositionAvailable:(BOOL)horizontalPositionAvail verticalPositionAvailable:(BOOL)verticalPositionAvail frontVerticalPositionAvailable:(BOOL)frontVerticalPositionAvail backVerticalPositionAvailable:(BOOL)backVerticalPositionAvail backTiltAngleAvailable:(BOOL)backTitlAngleAvail headSupportHorizontalPositionAvailable:(BOOL)headSupportHorizontalPositionAvail headSupportVerticalPositionAvailable:(BOOL)headSupportVerticalPositionAvail massageEnabledAvailable:(BOOL)massageEnabledAvail massageModeAvailable:(BOOL)massageModeAvail massageCushionFirmnessAvailable:(BOOL)massageCushionFirmnessAvail memoryAvailable:(BOOL)memoryAvail {
diff --git a/SmartDeviceLink/public/SDLSeatControlData.h b/SmartDeviceLink/public/SDLSeatControlData.h
index 9bc716392..1ad3c9ae1 100644
--- a/SmartDeviceLink/public/SDLSeatControlData.h
+++ b/SmartDeviceLink/public/SDLSeatControlData.h
@@ -17,6 +17,28 @@ NS_ASSUME_NONNULL_BEGIN
@interface SDLSeatControlData : SDLRPCStruct
+/**
+ * Convenience init for setting all possible seat control data
+ *
+ * @param heatingEnabled - heatingEnabled
+ * @param coolingEnabled - coolingEnabled
+ * @param heatingLevel - heatingLevel
+ * @param coolingLevel - coolingLevel
+ * @param horizontalPosition - horizontalPosition
+ * @param verticalPosition - verticalPosition
+ * @param frontVerticalPosition - frontVerticalPosition
+ * @param backVerticalPosition - backVerticalPosition
+ * @param backTiltAngle - backTiltAngle
+ * @param headSupportHorizontalPosition - headSupportHorizontalPosition
+ * @param headSupportVerticalPosition - headSupportVerticalPosition
+ * @param massageEnabled - massageEnabled
+ * @param massageMode - massageMode
+ * @param massageCushionFirmness - massageCushionFirmness
+ * @param memory - memory
+ * @return A SDLSeatControlData object
+ */
+- (instancetype)initWithHeatingEnabled:(nullable NSNumber<SDLBool> *)heatingEnabled coolingEnabled:(nullable NSNumber<SDLBool> *)coolingEnabled heatingLevel:(nullable NSNumber<SDLUInt> *)heatingLevel coolingLevel:(nullable NSNumber<SDLUInt> *)coolingLevel horizontalPosition:(nullable NSNumber<SDLUInt> *)horizontalPosition verticalPosition:(nullable NSNumber<SDLUInt> *)verticalPosition frontVerticalPosition:(nullable NSNumber<SDLUInt> *)frontVerticalPosition backVerticalPosition:(nullable NSNumber<SDLUInt> *)backVerticalPosition backTiltAngle:(nullable NSNumber<SDLUInt> *)backTiltAngle headSupportHorizontalPosition:(nullable NSNumber<SDLUInt> *)headSupportHorizontalPosition headSupportVerticalPosition:(nullable NSNumber<SDLUInt> *)headSupportVerticalPosition massageEnabled:(nullable NSNumber<SDLBool> *)massageEnabled massageMode:(nullable NSArray<SDLMassageModeData *> *)massageMode massageCushionFirmness:(nullable NSArray<SDLMassageCushionFirmness *> *)massageCushionFirmness memory:(nullable SDLSeatMemoryAction *)memory;
+
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
/**
@@ -25,10 +47,9 @@ Constructs a newly allocated SDLSeatControlData object with cushion and firmness
@param supportedSeat id of remote controllable seat.
@return An instance of the SDLSeatControlData class
*/
-- (instancetype)initWithId:(SDLSupportedSeat)supportedSeat;
+- (instancetype)initWithId:(SDLSupportedSeat)supportedSeat __deprecated_msg("Use initWithHeatingEnabled:coolingEnabled:heatingLevel:coolingLevel:horizontalPosition:verticalPosition:frontVerticalPosition:backVerticalPosition:backTiltAngle:headSupportHorizontalPosition:headSupportVerticalPosition:massageEnabled:massageMode:massageCushionFirmness:memory: instead");;
#pragma clang diagnostic pop
-
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
/**
@@ -52,19 +73,16 @@ Constructs a newly allocated SDLSeatControlData object with cushion and firmness
@param memoryAction type of action to be performed.
@return An instance of the SDLSeatControlData class
*/
-- (instancetype)initWithId:(SDLSupportedSeat)supportedSeat heatingEnabled:(BOOL)heatingEnable coolingEnable:(BOOL)coolingEnable heatingLevel:(UInt8)heatingLevel coolingLevel:(UInt8)coolingLevel horizontalPostion:(UInt8)horizontal verticalPostion:(UInt8)vertical frontVerticalPostion:(UInt8)frontVertical backVerticalPostion:(UInt8)backVertical backTiltAngle:(UInt8)backAngle headSupportedHorizontalPostion:(UInt8)headSupportedHorizontal headSupportedVerticalPostion:(UInt8)headSupportedVertical massageEnabled:(BOOL)massageEnable massageMode:(NSArray<SDLMassageModeData *> *)massageMode massageCussionFirmness:(NSArray<SDLMassageCushionFirmness *> *)firmness memory:(SDLSeatMemoryAction *)memoryAction;
+- (instancetype)initWithId:(SDLSupportedSeat)supportedSeat heatingEnabled:(BOOL)heatingEnable coolingEnable:(BOOL)coolingEnable heatingLevel:(UInt8)heatingLevel coolingLevel:(UInt8)coolingLevel horizontalPostion:(UInt8)horizontal verticalPostion:(UInt8)vertical frontVerticalPostion:(UInt8)frontVertical backVerticalPostion:(UInt8)backVertical backTiltAngle:(UInt8)backAngle headSupportedHorizontalPostion:(UInt8)headSupportedHorizontal headSupportedVerticalPostion:(UInt8)headSupportedVertical massageEnabled:(BOOL)massageEnable massageMode:(NSArray<SDLMassageModeData *> *)massageMode massageCussionFirmness:(NSArray<SDLMassageCushionFirmness *> *)firmness memory:(SDLSeatMemoryAction *)memoryAction __deprecated_msg("Use initWithHeatingEnabled:coolingEnabled:heatingLevel:coolingLevel:horizontalPosition:verticalPosition:frontVerticalPosition:backVerticalPosition:backTiltAngle:headSupportHorizontalPosition:headSupportVerticalPosition:massageEnabled:massageMode:massageCushionFirmness:memory: instead");
#pragma clang diagnostic pop
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
/**
* @abstract id of seat that is a remote controllable seat.
* @warning This should not be used to identify a seat, this is a deprecated parameter.
*
* Required
*/
-@property (strong, nonatomic) SDLSupportedSeat id;
-#pragma clang diagnostic pop
+@property (strong, nonatomic) SDLSupportedSeat id __deprecated;
/**
* @abstract Whether or not heating is enabled.
diff --git a/SmartDeviceLink/public/SDLSeatControlData.m b/SmartDeviceLink/public/SDLSeatControlData.m
index 6054cb908..39b7bd81b 100644
--- a/SmartDeviceLink/public/SDLSeatControlData.m
+++ b/SmartDeviceLink/public/SDLSeatControlData.m
@@ -31,30 +31,40 @@ NS_ASSUME_NONNULL_BEGIN
- (instancetype)initWithId:(SDLSupportedSeat)supportedSeat heatingEnabled:(BOOL)heatingEnable coolingEnable:(BOOL)coolingEnabled heatingLevel:(UInt8)heatingLevel coolingLevel:(UInt8)coolingLevel horizontalPostion:(UInt8)horizontal verticalPostion:(UInt8)vertical frontVerticalPostion:(UInt8)frontVertical backVerticalPostion:(UInt8)backVertical backTiltAngle:(UInt8)backAngle headSupportedHorizontalPostion:(UInt8)headSupportedHorizontal headSupportedVerticalPostion:(UInt8)headSupportedVertical massageEnabled:(BOOL)massageEnable massageMode:(NSArray<SDLMassageModeData *> *)massageMode massageCussionFirmness:(NSArray<SDLMassageCushionFirmness *> *)firmness memory:(SDLSeatMemoryAction *)memoryAction {
#pragma clang diagnostic pop
- self = [super init];
+ self = [self initWithHeatingEnabled:@(heatingEnable) coolingEnabled:@(coolingEnabled) heatingLevel:@(heatingLevel) coolingLevel:@(coolingLevel) horizontalPosition:@(horizontal) verticalPosition:@(vertical) frontVerticalPosition:@(frontVertical) backVerticalPosition:@(backVertical) backTiltAngle:@(backAngle) headSupportHorizontalPosition:@(headSupportedHorizontal) headSupportVerticalPosition:@(headSupportedVertical) massageEnabled:@(massageEnable) massageMode:massageMode massageCushionFirmness:firmness memory:memoryAction];
if (!self) {
return nil;
}
self.id = supportedSeat;
- self.heatingEnabled = @(heatingEnable);
- self.coolingEnabled = @(coolingEnabled);
- self.heatingLevel = @(heatingLevel);
- self.coolingLevel = @(coolingLevel);
- self.horizontalPosition = @(horizontal);
- self.verticalPosition = @(vertical);
- self.frontVerticalPosition = @(frontVertical);
- self.backVerticalPosition = @(backVertical);
- self.backTiltAngle = @(backAngle);
+ return self;
+}
+
+- (instancetype)initWithHeatingEnabled:(nullable NSNumber<SDLBool> *)heatingEnabled coolingEnabled:(nullable NSNumber<SDLBool> *)coolingEnabled heatingLevel:(nullable NSNumber<SDLUInt> *)heatingLevel coolingLevel:(nullable NSNumber<SDLUInt> *)coolingLevel horizontalPosition:(nullable NSNumber<SDLUInt> *)horizontalPosition verticalPosition:(nullable NSNumber<SDLUInt> *)verticalPosition frontVerticalPosition:(nullable NSNumber<SDLUInt> *)frontVerticalPosition backVerticalPosition:(nullable NSNumber<SDLUInt> *)backVerticalPosition backTiltAngle:(nullable NSNumber<SDLUInt> *)backTiltAngle headSupportHorizontalPosition:(nullable NSNumber<SDLUInt> *)headSupportHorizontalPosition headSupportVerticalPosition:(nullable NSNumber<SDLUInt> *)headSupportVerticalPosition massageEnabled:(nullable NSNumber<SDLBool> *)massageEnabled massageMode:(nullable NSArray<SDLMassageModeData *> *)massageMode massageCushionFirmness:(nullable NSArray<SDLMassageCushionFirmness *> *)massageCushionFirmness memory:(nullable SDLSeatMemoryAction *)memory {
+ self = [super init];
+ if (!self) {
+ return nil;
+ }
+
+ self.heatingEnabled = heatingEnabled;
+ self.coolingEnabled = coolingEnabled;
+ self.heatingLevel = heatingLevel;
+ self.coolingLevel = coolingLevel;
+
+ self.horizontalPosition = horizontalPosition;
+ self.verticalPosition = verticalPosition;
+ self.frontVerticalPosition = frontVerticalPosition;
+ self.backVerticalPosition = backVerticalPosition;
+ self.backTiltAngle = backTiltAngle;
- self.headSupportHorizontalPosition = @(headSupportedHorizontal);
- self.headSupportVerticalPosition = @(headSupportedVertical);
+ self.headSupportHorizontalPosition = headSupportHorizontalPosition;
+ self.headSupportVerticalPosition = headSupportVerticalPosition;
- self.massageEnabled = @(massageEnable);
+ self.massageEnabled = massageEnabled;
self.massageMode = massageMode;
- self.massageCushionFirmness = firmness;
- self.memory = memoryAction;
+ self.massageCushionFirmness = massageCushionFirmness;
+ self.memory = memory;
return self;
}
diff --git a/SmartDeviceLink/public/SDLSeatMemoryActionType.h b/SmartDeviceLink/public/SDLSeatMemoryActionType.h
index 9ac8eafae..41dbc2a5f 100644
--- a/SmartDeviceLink/public/SDLSeatMemoryActionType.h
+++ b/SmartDeviceLink/public/SDLSeatMemoryActionType.h
@@ -8,7 +8,7 @@
*
* @since SDL 2.0
*/
-typedef SDLEnum SDLSeatMemoryActionType SDL_SWIFT_ENUM;
+typedef SDLEnum SDLSeatMemoryActionType NS_TYPED_ENUM;
/**
* @abstract Save current seat postions and settings to seat memory.
diff --git a/SmartDeviceLink/public/SDLServiceUpdateReason.h b/SmartDeviceLink/public/SDLServiceUpdateReason.h
index 09a4c9865..6a8b6fbbe 100644
--- a/SmartDeviceLink/public/SDLServiceUpdateReason.h
+++ b/SmartDeviceLink/public/SDLServiceUpdateReason.h
@@ -11,29 +11,54 @@
/**
* Enumeration listing possible service update reasons.
*/
-typedef SDLEnum SDLServiceUpdateReason SDL_SWIFT_ENUM;
+typedef SDLEnum SDLServiceUpdateReason NS_TYPED_ENUM;
/**
* The service has just been published with the module and once activated to the primary service of its type, it will be ready for possible consumption.
*/
-extern SDLServiceUpdateReason const SDLServiceUpdatePublished;
+extern SDLServiceUpdateReason const SDLServiceUpdateReasonPublished;
+
+/**
+ * The service has just been published with the module and once activated to the primary service of its type, it will be ready for possible consumption.
+ */
+extern SDLServiceUpdateReason const SDLServiceUpdatePublished __deprecated_msg("Use SDLServiceUpdateReasonPublished instead");
+
+/**
+ * The service has just been unpublished with the module and is no longer accessible.
+ */
+extern SDLServiceUpdateReason const SDLServiceUpdateReasonRemoved;
/**
* The service has just been unpublished with the module and is no longer accessible.
*/
-extern SDLServiceUpdateReason const SDLServiceUpdateRemoved;
+extern SDLServiceUpdateReason const SDLServiceUpdateRemoved __deprecated_msg("Use SDLServiceUpdateReasonRemoved instead");
+
+/**
+ * The service is activated as the primary service of this type. All requests dealing with this service type will be handled by this service.
+ */
+extern SDLServiceUpdateReason const SDLServiceUpdateReasonActivated;
/**
* The service is activated as the primary service of this type. All requests dealing with this service type will be handled by this service.
*/
-extern SDLServiceUpdateReason const SDLServiceUpdateActivated;
+extern SDLServiceUpdateReason const SDLServiceUpdateActivated __deprecated_msg("Use SDLServiceUpdateReasonActivated instead");
+
+/**
+ * The service has been deactivated as the primary service of its type.
+ */
+extern SDLServiceUpdateReason const SDLServiceUpdateReasonDeactivated;
/**
* The service has been deactivated as the primary service of its type.
*/
-extern SDLServiceUpdateReason const SDLServiceUpdateDeactivated;
+extern SDLServiceUpdateReason const SDLServiceUpdateDeactivated __deprecated_msg("Use SDLServiceUpdateReasonDeactivated instead");
+
+/**
+ * The service has updated its manifest. This could imply updated capabilities.
+ */
+extern SDLServiceUpdateReason const SDLServiceUpdateReasonManifestUpdate;
/**
* The service has updated its manifest. This could imply updated capabilities.
*/
-extern SDLServiceUpdateReason const SDLServiceUpdateManifestUpdate;
+extern SDLServiceUpdateReason const SDLServiceUpdateManifestUpdate __deprecated_msg("Use SDLServiceUpdateReasonManifestUpdate instead");
diff --git a/SmartDeviceLink/public/SDLServiceUpdateReason.m b/SmartDeviceLink/public/SDLServiceUpdateReason.m
index 2a2fe9c82..28821ace4 100644
--- a/SmartDeviceLink/public/SDLServiceUpdateReason.m
+++ b/SmartDeviceLink/public/SDLServiceUpdateReason.m
@@ -8,6 +8,12 @@
#import "SDLServiceUpdateReason.h"
+SDLServiceUpdateReason const SDLServiceUpdateReasonPublished = @"PUBLISHED";
+SDLServiceUpdateReason const SDLServiceUpdateReasonRemoved = @"REMOVED";
+SDLServiceUpdateReason const SDLServiceUpdateReasonActivated = @"ACTIVATED";
+SDLServiceUpdateReason const SDLServiceUpdateReasonDeactivated = @"DEACTIVATED";
+SDLServiceUpdateReason const SDLServiceUpdateReasonManifestUpdate = @"MANIFEST_UPDATE";
+
SDLServiceUpdateReason const SDLServiceUpdatePublished = @"PUBLISHED";
SDLServiceUpdateReason const SDLServiceUpdateRemoved = @"REMOVED";
SDLServiceUpdateReason const SDLServiceUpdateActivated = @"ACTIVATED";
diff --git a/SmartDeviceLink/public/SDLSetGlobalProperties.h b/SmartDeviceLink/public/SDLSetGlobalProperties.h
index ef1746ad5..6968f8332 100644
--- a/SmartDeviceLink/public/SDLSetGlobalProperties.h
+++ b/SmartDeviceLink/public/SDLSetGlobalProperties.h
@@ -23,26 +23,6 @@ NS_ASSUME_NONNULL_BEGIN
@interface SDLSetGlobalProperties : SDLRPCRequest
/**
- Initialize SetGlobalProperties with help text and timeout text
-
- @param helpText A string that will be turned into TTS chunks for the help prompt
- @param timeoutText A string that will be turned into TTS chunks for the timeout prompt
- @return The SetGlobalProperties RPC
- */
-- (instancetype)initWithHelpText:(nullable NSString *)helpText timeoutText:(nullable NSString *)timeoutText __deprecated_msg("Use initWithHelpText:timeoutText:vrHelpTitle:vrHelp:menuTitle:menuIcon:keyboardProperties:menuLayout: instead");
-
-/**
- Initialize SetGlobalProperties with help text, timeout text, help title, and help items
-
- @param helpText A string that will be turned into TTS chunks for the help prompt
- @param timeoutText A string that will be turned into TTS chunks for the timeout prompt
- @param vrHelpTitle The title of the help interface prompt
- @param vrHelp The items of the help interface prompt
- @return The SetGlobalProperties RPC
- */
-- (instancetype)initWithHelpText:(nullable NSString *)helpText timeoutText:(nullable NSString *)timeoutText vrHelpTitle:(nullable NSString *)vrHelpTitle vrHelp:(nullable NSArray<SDLVRHelpItem *> *)vrHelp __deprecated_msg("Use initWithHelpText:timeoutText:vrHelpTitle:vrHelp:menuTitle:menuIcon:keyboardProperties:menuLayout: instead");
-
-/**
Initialize SetGlobalProperties with all possible items
@param helpText A string that will be turned into TTS chunks for the help prompt
@@ -52,24 +32,26 @@ NS_ASSUME_NONNULL_BEGIN
@param menuTitle The title of the menu button
@param menuIcon The icon on the menu button
@param keyboardProperties The properties of a keyboard prompt
+ @param menuLayout The layout of the top-level main menu
@return The SetGlobalProperties RPC
*/
-- (instancetype)initWithHelpText:(nullable NSString *)helpText timeoutText:(nullable NSString *)timeoutText vrHelpTitle:(nullable NSString *)vrHelpTitle vrHelp:(nullable NSArray<SDLVRHelpItem *> *)vrHelp menuTitle:(nullable NSString *)menuTitle menuIcon:(nullable SDLImage *)menuIcon keyboardProperties:(nullable SDLKeyboardProperties *)keyboardProperties __deprecated_msg("Use initWithHelpText:timeoutText:vrHelpTitle:vrHelp:menuTitle:menuIcon:keyboardProperties:menuLayout: instead");
+- (instancetype)initWithHelpText:(nullable NSString *)helpText timeoutText:(nullable NSString *)timeoutText vrHelpTitle:(nullable NSString *)vrHelpTitle vrHelp:(nullable NSArray<SDLVRHelpItem *> *)vrHelp menuTitle:(nullable NSString *)menuTitle menuIcon:(nullable SDLImage *)menuIcon keyboardProperties:(nullable SDLKeyboardProperties *)keyboardProperties menuLayout:(nullable SDLMenuLayout)menuLayout __deprecated_msg("Use initWithUserLocation:helpPrompt:timeoutPrompt:vrHelpTitle:vrHelp:menuTitle:menuIcon:keyboardProperties:menuLayout: instead");
/**
- Initialize SetGlobalProperties with all possible items
-
- @param helpText A string that will be turned into TTS chunks for the help prompt
- @param timeoutText A string that will be turned into TTS chunks for the timeout prompt
- @param vrHelpTitle The title of the help interface prompt
- @param vrHelp The items of the help interface prompt
- @param menuTitle The title of the menu button
- @param menuIcon The icon on the menu button
- @param keyboardProperties The properties of a keyboard prompt
- @param menuLayout The layout of the top-level main menu
- @return The SetGlobalProperties RPC
- */
-- (instancetype)initWithHelpText:(nullable NSString *)helpText timeoutText:(nullable NSString *)timeoutText vrHelpTitle:(nullable NSString *)vrHelpTitle vrHelp:(nullable NSArray<SDLVRHelpItem *> *)vrHelp menuTitle:(nullable NSString *)menuTitle menuIcon:(nullable SDLImage *)menuIcon keyboardProperties:(nullable SDLKeyboardProperties *)keyboardProperties menuLayout:(nullable SDLMenuLayout)menuLayout;
+* Convenience init for setting all possible global properties
+*
+* @param userLocation - userLocation
+* @param helpPrompt - helpPrompt
+* @param timeoutPrompt - timeoutPrompt
+* @param vrHelpTitle - vrHelpTitle
+* @param vrHelp - vrHelp
+* @param menuTitle - menuTitle
+* @param menuIcon - menuIcon
+* @param keyboardProperties - keyboardProperties
+* @param menuLayout - menuLayout
+* @return A SDLSetGlobalProperties object
+*/
+- (instancetype)initWithUserLocation:(nullable SDLSeatLocation *)userLocation helpPrompt:(nullable NSArray<SDLTTSChunk *> *)helpPrompt timeoutPrompt:(nullable NSArray<SDLTTSChunk *> *)timeoutPrompt vrHelpTitle:(nullable NSString *)vrHelpTitle vrHelp:(nullable NSArray<SDLVRHelpItem *> *)vrHelp menuTitle:(nullable NSString *)menuTitle menuIcon:(nullable SDLImage *)menuIcon keyboardProperties:(nullable SDLKeyboardProperties *)keyboardProperties menuLayout:(nullable SDLMenuLayout)menuLayout;
/**
Help prompt for when the user asks for help with an interface prompt
diff --git a/SmartDeviceLink/public/SDLSetGlobalProperties.m b/SmartDeviceLink/public/SDLSetGlobalProperties.m
index b502fcfd1..123623cda 100644
--- a/SmartDeviceLink/public/SDLSetGlobalProperties.m
+++ b/SmartDeviceLink/public/SDLSetGlobalProperties.m
@@ -26,31 +26,24 @@ NS_ASSUME_NONNULL_BEGIN
}
#pragma clang diagnostic pop
-- (instancetype)initWithHelpText:(nullable NSString *)helpText timeoutText:(nullable NSString *)timeoutText {
- return [self initWithHelpText:helpText timeoutText:timeoutText vrHelpTitle:nil vrHelp:nil menuTitle:nil menuIcon:nil keyboardProperties:nil menuLayout:nil];
-}
-
-- (instancetype)initWithHelpText:(nullable NSString *)helpText timeoutText:(nullable NSString *)timeoutText vrHelpTitle:(nullable NSString *)vrHelpTitle vrHelp:(nullable NSArray<SDLVRHelpItem *> *)vrHelp {
- return [self initWithHelpText:helpText timeoutText:timeoutText vrHelpTitle:vrHelpTitle vrHelp:vrHelp menuTitle:nil menuIcon:nil keyboardProperties:nil menuLayout:nil];
-}
-
-- (instancetype)initWithHelpText:(nullable NSString *)helpText timeoutText:(nullable NSString *)timeoutText vrHelpTitle:(nullable NSString *)vrHelpTitle vrHelp:(nullable NSArray<SDLVRHelpItem *> *)vrHelp menuTitle:(nullable NSString *)menuTitle menuIcon:(nullable SDLImage *)menuIcon keyboardProperties:(nullable SDLKeyboardProperties *)keyboardProperties {
- return [self initWithHelpText:helpText timeoutText:timeoutText vrHelpTitle:vrHelpTitle vrHelp:vrHelp menuTitle:menuTitle menuIcon:menuIcon keyboardProperties:keyboardProperties menuLayout:nil];
+- (instancetype)initWithHelpText:(nullable NSString *)helpText timeoutText:(nullable NSString *)timeoutText vrHelpTitle:(nullable NSString *)vrHelpTitle vrHelp:(nullable NSArray<SDLVRHelpItem *> *)vrHelp menuTitle:(nullable NSString *)menuTitle menuIcon:(nullable SDLImage *)menuIcon keyboardProperties:(nullable SDLKeyboardProperties *)keyboardProperties menuLayout:(nullable SDLMenuLayout)menuLayout {
+ return [self initWithUserLocation:nil helpPrompt:[SDLTTSChunk textChunksFromString:helpText] timeoutPrompt:[SDLTTSChunk textChunksFromString:timeoutText] vrHelpTitle:vrHelpTitle vrHelp:vrHelp menuTitle:menuTitle menuIcon:menuIcon keyboardProperties:keyboardProperties menuLayout:menuLayout];
}
-- (instancetype)initWithHelpText:(nullable NSString *)helpText timeoutText:(nullable NSString *)timeoutText vrHelpTitle:(nullable NSString *)vrHelpTitle vrHelp:(nullable NSArray<SDLVRHelpItem *> *)vrHelp menuTitle:(nullable NSString *)menuTitle menuIcon:(nullable SDLImage *)menuIcon keyboardProperties:(nullable SDLKeyboardProperties *)keyboardProperties menuLayout:(nullable SDLMenuLayout)menuLayout {
+- (instancetype)initWithUserLocation:(nullable SDLSeatLocation *)userLocation helpPrompt:(nullable NSArray<SDLTTSChunk *> *)helpPrompt timeoutPrompt:(nullable NSArray<SDLTTSChunk *> *)timeoutPrompt vrHelpTitle:(nullable NSString *)vrHelpTitle vrHelp:(nullable NSArray<SDLVRHelpItem *> *)vrHelp menuTitle:(nullable NSString *)menuTitle menuIcon:(nullable SDLImage *)menuIcon keyboardProperties:(nullable SDLKeyboardProperties *)keyboardProperties menuLayout:(nullable SDLMenuLayout)menuLayout {
self = [self init];
if (!self) {
return nil;
}
- self.helpPrompt = [SDLTTSChunk textChunksFromString:helpText];
- self.timeoutPrompt = [SDLTTSChunk textChunksFromString:timeoutText];
+ self.helpPrompt = helpPrompt;
+ self.timeoutPrompt = timeoutPrompt;
self.vrHelpTitle = vrHelpTitle;
self.vrHelp = [vrHelp mutableCopy];
self.menuTitle = menuTitle;
self.menuIcon = menuIcon;
self.keyboardProperties = keyboardProperties;
+ self.userLocation = userLocation;
self.menuLayout = menuLayout;
return self;
diff --git a/SmartDeviceLink/public/SDLSetMediaClockTimer.h b/SmartDeviceLink/public/SDLSetMediaClockTimer.h
index 6b40e5d96..4c8ccdd89 100644
--- a/SmartDeviceLink/public/SDLSetMediaClockTimer.h
+++ b/SmartDeviceLink/public/SDLSetMediaClockTimer.h
@@ -115,31 +115,6 @@ NS_ASSUME_NONNULL_BEGIN
*/
+ (instancetype)clearWithPlayPauseIndicator:(nullable SDLAudioStreamingIndicator)playPauseIndicator NS_SWIFT_NAME(clear(playPauseIndicator:));
-/// Convenience init to create a SDLSetMediaClockTimer object
-///
-/// @param updateMode The type of SetMediaClockTimer RPC
-/// @param hours Hour
-/// @param minutes Minuute
-/// @param seconds Seconds
-/// @param audioStreamingIndicator The audio streaming indicator used for a play/pause button
-/// @return An SDLSetMediaClockTimer object
-- (instancetype)initWithUpdateMode:(SDLUpdateMode)updateMode hours:(UInt8)hours minutes:(UInt8)minutes seconds:(UInt8)seconds audioStreamingIndicator:(SDLAudioStreamingIndicator)audioStreamingIndicator __deprecated_msg("Use a specific initializer");
-
-/// Convenience init to create a SDLSetMediaClockTimer object
-///
-/// @param updateMode The type of SetMediaClockTimer RPC
-/// @param hours Hour
-/// @param minutes Minuute
-/// @param seconds Seconds
-/// @return An SDLSetMediaClockTimer object
-- (instancetype)initWithUpdateMode:(SDLUpdateMode)updateMode hours:(UInt8)hours minutes:(UInt8)minutes seconds:(UInt8)seconds __deprecated_msg("Use a specific initializer");
-
-/// Convenience init to create a SDLSetMediaClockTimer object
-///
-/// @param updateMode he type of SetMediaClockTimer RPC
-/// @return An SDLSetMediaClockTimer object
-- (instancetype)initWithUpdateMode:(SDLUpdateMode)updateMode __deprecated_msg("Use a specific initializer");
-
/**
Create a SetMediaClockTimer RPC with all available parameters. It's recommended to use the specific initializers above.
diff --git a/SmartDeviceLink/public/SDLSetMediaClockTimer.m b/SmartDeviceLink/public/SDLSetMediaClockTimer.m
index ce536ce8f..bfbf77ec1 100644
--- a/SmartDeviceLink/public/SDLSetMediaClockTimer.m
+++ b/SmartDeviceLink/public/SDLSetMediaClockTimer.m
@@ -79,39 +79,6 @@ NS_ASSUME_NONNULL_BEGIN
return [[self alloc] initWithUpdateMode:SDLUpdateModeClear startTime:nil endTime:nil playPauseIndicator:playPauseIndicator];
}
-- (instancetype)initWithUpdateMode:(SDLUpdateMode)updateMode hours:(UInt8)hours minutes:(UInt8)minutes seconds:(UInt8)seconds audioStreamingIndicator:(SDLAudioStreamingIndicator)audioStreamingIndicator {
- self = [self initWithUpdateMode:updateMode hours:hours minutes:minutes seconds:seconds];
- if (!self) {
- return nil;
- }
-
- self.audioStreamingIndicator = audioStreamingIndicator;
-
- return self;
-}
-
-- (instancetype)initWithUpdateMode:(SDLUpdateMode)updateMode hours:(UInt8)hours minutes:(UInt8)minutes seconds:(UInt8)seconds {
- self = [self initWithUpdateMode:updateMode];
- if (!self) {
- return nil;
- }
-
- self.startTime = [[SDLStartTime alloc] initWithHours:hours minutes:minutes seconds:seconds];
-
- return self;
-}
-
-- (instancetype)initWithUpdateMode:(SDLUpdateMode)updateMode {
- self = [self init];
- if (!self) {
- return nil;
- }
-
- self.updateMode = updateMode;
-
- return self;
-}
-
- (void)setStartTime:(nullable SDLStartTime *)startTime {
[self.parameters sdl_setObject:startTime forName:SDLRPCParameterNameStartTime];
}
diff --git a/SmartDeviceLink/public/SDLSoftButtonType.h b/SmartDeviceLink/public/SDLSoftButtonType.h
index 0519ce1b0..777f64940 100644
--- a/SmartDeviceLink/public/SDLSoftButtonType.h
+++ b/SmartDeviceLink/public/SDLSoftButtonType.h
@@ -7,7 +7,7 @@
/**
SoftButtonType (TEXT / IMAGE / BOTH). Used by SoftButton.
*/
-typedef SDLEnum SDLSoftButtonType SDL_SWIFT_ENUM;
+typedef SDLEnum SDLSoftButtonType NS_TYPED_ENUM;
/**
Text kind Softbutton
diff --git a/SmartDeviceLink/public/SDLSpeechCapabilities.h b/SmartDeviceLink/public/SDLSpeechCapabilities.h
index 985de6171..974990707 100644
--- a/SmartDeviceLink/public/SDLSpeechCapabilities.h
+++ b/SmartDeviceLink/public/SDLSpeechCapabilities.h
@@ -9,7 +9,7 @@
*
* @since SDL 1.0
*/
-typedef SDLEnum SDLSpeechCapabilities SDL_SWIFT_ENUM;
+typedef SDLEnum SDLSpeechCapabilities NS_TYPED_ENUM;
/**
The SDL platform can speak text phrases.
diff --git a/SmartDeviceLink/public/SDLStaticIconName.h b/SmartDeviceLink/public/SDLStaticIconName.h
index db143a9c7..c2e731d79 100644
--- a/SmartDeviceLink/public/SDLStaticIconName.h
+++ b/SmartDeviceLink/public/SDLStaticIconName.h
@@ -11,7 +11,7 @@
/**
* Static icon names
*/
-typedef SDLEnum SDLStaticIconName SDL_SWIFT_ENUM;
+typedef SDLEnum SDLStaticIconName NS_TYPED_ENUM;
/**
* Static icon accept call / active phone call in progress / initiate a phone call
diff --git a/SmartDeviceLink/public/SDLStreamingMediaConfiguration.h b/SmartDeviceLink/public/SDLStreamingMediaConfiguration.h
index 9c73cda8f..2c1585f16 100644
--- a/SmartDeviceLink/public/SDLStreamingMediaConfiguration.h
+++ b/SmartDeviceLink/public/SDLStreamingMediaConfiguration.h
@@ -34,11 +34,6 @@ typedef NS_ENUM(NSUInteger, SDLCarWindowRenderingType) {
@interface SDLStreamingMediaConfiguration : NSObject <NSCopying>
/**
- * Set security managers which could be used. This is primarily used with video streaming applications to authenticate and perhaps encrypt traffic data.
- */
-@property (copy, nonatomic, nullable) NSArray<Class<SDLSecurityType>> *securityManagers __deprecated_msg("This is now unused, the security managers are taken in from SDLEncryptionConfiguration");
-
-/**
* What encryption level video/audio streaming should be. The default is SDLStreamingEncryptionFlagAuthenticateAndEncrypt.
*/
@property (assign, nonatomic) SDLStreamingEncryptionFlag maximumDesiredEncryption;
@@ -104,17 +99,6 @@ typedef NS_ENUM(NSUInteger, SDLCarWindowRenderingType) {
/**
Manually set all the properties to the streaming media configuration
- @param securityManagers The security managers to use or nil for none.
- @param encryptionFlag The maximum encrpytion supported. If the connected head unit supports less than set here, it will still connect, but if it supports more than set here, it will not connect.
- @param videoSettings Custom video encoder settings to be used in video streaming.
- @param rootViewController The UIViewController wih the content that is being streamed on, to use for haptics if needed and possible (only works for UIViews)
- @return The configuration
- */
-- (instancetype)initWithSecurityManagers:(nullable NSArray<Class<SDLSecurityType>> *)securityManagers encryptionFlag:(SDLStreamingEncryptionFlag)encryptionFlag videoSettings:(nullable NSDictionary<NSString *, id> *)videoSettings dataSource:(nullable id<SDLStreamingMediaManagerDataSource>)dataSource rootViewController:(nullable UIViewController *)rootViewController __deprecated_msg("Use initWithEncryptionFlag:videoSettings:dataSource:rootViewController: instead");
-
-/**
- Manually set all the properties to the streaming media configuration
-
@param encryptionFlag The maximum encrpytion supported. If the connected head unit supports less than set here, it will still connect, but if it supports more than set here, it will not connect.
@param videoSettings Custom video encoder settings to be used in video streaming.
@param rootViewController The UIViewController wih the content that is being streamed on, to use for haptics if needed and possible (only works for UIViews)
@@ -123,22 +107,6 @@ typedef NS_ENUM(NSUInteger, SDLCarWindowRenderingType) {
- (instancetype)initWithEncryptionFlag:(SDLStreamingEncryptionFlag)encryptionFlag videoSettings:(nullable NSDictionary<NSString *, id> *)videoSettings dataSource:(nullable id<SDLStreamingMediaManagerDataSource>)dataSource rootViewController:(nullable UIViewController *)rootViewController;
/**
- Create a secure configuration for each of the security managers provided.
-
- @param securityManagers The security managers to be used. The encryption flag will be set to AuthenticateAndEncrypt if any security managers are set.
- @return The configuration
- */
-- (instancetype)initWithSecurityManagers:(NSArray<Class<SDLSecurityType>> *)securityManagers __deprecated_msg("Use secureConfiguration instead");
-
-/**
- Create a secure configuration for each of the security managers provided.
-
- @param securityManagers The security managers to be used. The encryption flag will be set to AuthenticateAndEncrypt if any security managers are set.
- @return The configuration
- */
-+ (instancetype)secureConfigurationWithSecurityManagers:(NSArray<Class<SDLSecurityType>> *)securityManagers NS_SWIFT_UNAVAILABLE("Use an initializer instead") __deprecated_msg("Use secureConfiguration instead");
-
-/**
Create an insecure video streaming configuration. No security managers will be provided and the encryption flag will be set to None. If you'd like custom video encoder settings, you can set the property manually. This is equivalent to `init`.
@return The configuration
@@ -154,15 +122,6 @@ typedef NS_ENUM(NSUInteger, SDLCarWindowRenderingType) {
+ (instancetype)autostreamingInsecureConfigurationWithInitialViewController:(UIViewController *)initialViewController;
/**
- Create a CarWindow secure configuration with a view controller and security managers
-
- @param securityManagers The security managers available for secure streaming use
- @param initialViewController The initial view controller that will be streamed, this can be a basic `UIViewController` if you need to set your actual streaming view controller at a later time on `SDLManager.streamingManager.rootViewController`.
- @return The configuration
- */
-+ (instancetype)autostreamingSecureConfigurationWithSecurityManagers:(NSArray<Class<SDLSecurityType>> *)securityManagers initialViewController:(UIViewController *)initialViewController __deprecated_msg("Use autostreamingSecureConfigurationWithInitialViewController: instead");
-
-/**
Create a CarWindow secure configuration with a view controller.
@param initialViewController The initial view controller that will be streamed, this can be a basic `UIViewController` if you need to set your actual streaming view controller at a later time on `SDLManager.streamingManager.rootViewController`.
diff --git a/SmartDeviceLink/public/SDLStreamingMediaConfiguration.m b/SmartDeviceLink/public/SDLStreamingMediaConfiguration.m
index 4c82ddcfd..7438b2678 100644
--- a/SmartDeviceLink/public/SDLStreamingMediaConfiguration.m
+++ b/SmartDeviceLink/public/SDLStreamingMediaConfiguration.m
@@ -16,44 +16,22 @@ NS_ASSUME_NONNULL_BEGIN
@implementation SDLStreamingMediaConfiguration
- (instancetype)init {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- return [self initWithSecurityManagers:nil encryptionFlag:SDLStreamingEncryptionFlagNone videoSettings:nil dataSource:nil rootViewController:nil];
-#pragma clang diagnostic pop
+ return [self initWithEncryptionFlag:SDLStreamingEncryptionFlagNone videoSettings:nil dataSource:nil rootViewController:nil];
}
+ (instancetype)secureConfiguration {
- return [[self alloc] initWithEncryptionFlag:SDLStreamingEncryptionFlagAuthenticateAndEncrypt videoSettings:nil dataSource:nil rootViewController:nil];
+ return [[self alloc] initWithEncryptionFlag:SDLStreamingEncryptionFlagAuthenticateAndEncrypt videoSettings:nil dataSource:nil rootViewController:nil];
}
+ (instancetype)insecureConfiguration {
return [[self alloc] init];
}
-- (instancetype)initWithSecurityManagers:(nullable NSArray<Class<SDLSecurityType>> *)securityManagers encryptionFlag:(SDLStreamingEncryptionFlag)encryptionFlag videoSettings:(nullable NSDictionary<NSString *,id> *)videoSettings dataSource:(nullable id<SDLStreamingMediaManagerDataSource>)dataSource rootViewController:(nullable UIViewController *)rootViewController {
- self = [super init];
- if (!self) {
- return nil;
- }
-
- _securityManagers = securityManagers;
- _maximumDesiredEncryption = encryptionFlag;
- _customVideoEncoderSettings = videoSettings;
- _dataSource = dataSource;
- _rootViewController = rootViewController;
- _carWindowRenderingType = SDLCarWindowRenderingTypeLayer;
- _enableForcedFramerateSync = YES;
- _allowMultipleViewControllerOrientations = NO;
-
- return self;
-}
-
- (instancetype)initWithEncryptionFlag:(SDLStreamingEncryptionFlag)encryptionFlag videoSettings:(nullable NSDictionary<NSString *, id> *)videoSettings dataSource:(nullable id<SDLStreamingMediaManagerDataSource>)dataSource rootViewController:(nullable UIViewController *)rootViewController {
if (!self) {
return nil;
}
- _securityManagers = nil;
_maximumDesiredEncryption = encryptionFlag;
_customVideoEncoderSettings = videoSettings;
_dataSource = dataSource;
@@ -65,29 +43,8 @@ NS_ASSUME_NONNULL_BEGIN
return self;
}
-- (instancetype)initWithSecurityManagers:(NSArray<Class<SDLSecurityType>> *)securityManagers {
- NSAssert(securityManagers.count > 0, @"A secure streaming media configuration requires security managers to be passed.");
- SDLStreamingEncryptionFlag encryptionFlag = SDLStreamingEncryptionFlagAuthenticateAndEncrypt;
-
- return [self initWithSecurityManagers:securityManagers encryptionFlag:encryptionFlag videoSettings:nil dataSource:nil rootViewController:nil];
-}
-
-+ (instancetype)secureConfigurationWithSecurityManagers:(NSArray<Class<SDLSecurityType>> *)securityManagers {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- return [[self alloc] initWithSecurityManagers:securityManagers];
-#pragma clang diagnostic pop
-}
-
+ (instancetype)autostreamingInsecureConfigurationWithInitialViewController:(UIViewController *)initialViewController {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- return [[self alloc] initWithSecurityManagers:nil encryptionFlag:SDLStreamingEncryptionFlagNone videoSettings:nil dataSource:nil rootViewController:initialViewController];
-#pragma clang diagnostic pop
-}
-
-+ (instancetype)autostreamingSecureConfigurationWithSecurityManagers:(NSArray<Class<SDLSecurityType>> *)securityManagers initialViewController:(UIViewController *)initialViewController {
- return [[self alloc] initWithSecurityManagers:securityManagers encryptionFlag:SDLStreamingEncryptionFlagAuthenticateAndEncrypt videoSettings:nil dataSource:nil rootViewController:initialViewController];
+ return [[self alloc] initWithEncryptionFlag:SDLStreamingEncryptionFlagNone videoSettings:nil dataSource:nil rootViewController:initialViewController];
}
+ (instancetype)autostreamingSecureConfigurationWithInitialViewController:(UIViewController *)initialViewController {
@@ -97,10 +54,7 @@ NS_ASSUME_NONNULL_BEGIN
#pragma mark NSCopying
- (id)copyWithZone:(nullable NSZone *)zone {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLStreamingMediaConfiguration *newConfig = [[self.class allocWithZone:zone] initWithSecurityManagers:_securityManagers encryptionFlag:_maximumDesiredEncryption videoSettings:_customVideoEncoderSettings dataSource:_dataSource rootViewController:_rootViewController];
-#pragma clang diagnostic pop
+ SDLStreamingMediaConfiguration *newConfig = [[self.class allocWithZone:zone] initWithEncryptionFlag:_maximumDesiredEncryption videoSettings:_customVideoEncoderSettings dataSource:_dataSource rootViewController:_rootViewController];
newConfig.carWindowRenderingType = self.carWindowRenderingType;
newConfig.enableForcedFramerateSync = self.enableForcedFramerateSync;
diff --git a/SmartDeviceLink/public/SDLStreamingMediaManager.h b/SmartDeviceLink/public/SDLStreamingMediaManager.h
index 495f466cf..44ccec14b 100644
--- a/SmartDeviceLink/public/SDLStreamingMediaManager.h
+++ b/SmartDeviceLink/public/SDLStreamingMediaManager.h
@@ -126,11 +126,6 @@ NS_ASSUME_NONNULL_BEGIN
/// Create a new streaming media manager for navigation and projection apps with a specified configuration.
/// @param connectionManager The pass-through for RPCs
/// @param configuration This session's configuration
-- (instancetype)initWithConnectionManager:(id<SDLConnectionManagerType>)connectionManager configuration:(SDLConfiguration *)configuration __deprecated_msg("Use initWithConnectionManager:configuration:systemCapabilityManager: instead");
-
-/// Create a new streaming media manager for navigation and projection apps with a specified configuration.
-/// @param connectionManager The pass-through for RPCs
-/// @param configuration This session's configuration
/// @param systemCapabilityManager The system capability manager object for reading window capabilities
- (instancetype)initWithConnectionManager:(id<SDLConnectionManagerType>)connectionManager configuration:(SDLConfiguration *)configuration systemCapabilityManager:(nullable SDLSystemCapabilityManager *)systemCapabilityManager NS_DESIGNATED_INITIALIZER;
@@ -186,19 +181,6 @@ NS_ASSUME_NONNULL_BEGIN
*/
- (BOOL)sendAudioData:(NSData *)audioData;
-#pragma mark - Deprecated Methods
-
- /**
- * Start the audio feature of the manager. This is used internally. To use an SDLStreamingMediaManager, you should use the manager found on `SDLManager`.
- */
-- (void)startAudioWithProtocol:(SDLProtocol *)protocol __deprecated_msg("Use startWithProtocol: instead");
-
- /**
- * Start the video feature of the manager. This is used internally. To use an SDLStreamingMediaManager, you should use the manager found on `SDLManager`.
- */
-- (void)startVideoWithProtocol:(SDLProtocol *)protocol __deprecated_msg("Use startWithProtocol: instead");
-
-
@end
NS_ASSUME_NONNULL_END
diff --git a/SmartDeviceLink/public/SDLStreamingMediaManager.m b/SmartDeviceLink/public/SDLStreamingMediaManager.m
index 3b6a14890..8b072c6e3 100644
--- a/SmartDeviceLink/public/SDLStreamingMediaManager.m
+++ b/SmartDeviceLink/public/SDLStreamingMediaManager.m
@@ -54,10 +54,6 @@ NS_ASSUME_NONNULL_BEGIN
return self;
}
-- (instancetype)initWithConnectionManager:(id<SDLConnectionManagerType>)connectionManager configuration:(SDLConfiguration *)configuration {
- return [self initWithConnectionManager:connectionManager configuration:configuration systemCapabilityManager:nil];
-}
-
- (void)stop {
[self stopAudio];
[self stopVideo];
@@ -206,21 +202,6 @@ NS_ASSUME_NONNULL_BEGIN
}
}
-#pragma mark Deprecated
-
- - (void)startAudioWithProtocol:(SDLProtocol *)protocol {
- self.audioProtocol = protocol;
- [self.audioLifecycleManager startWithProtocol:protocol];
- self.audioStarted = YES;
-}
-
- - (void)startVideoWithProtocol:(SDLProtocol *)protocol {
- self.videoProtocol = protocol;
- [self.videoLifecycleManager startWithProtocol:protocol];
- self.videoStarted = YES;
-}
-
-
#pragma mark - Getters
- (SDLTouchManager *)touchManager {
diff --git a/SmartDeviceLink/public/SDLSubscribeVehicleData.h b/SmartDeviceLink/public/SDLSubscribeVehicleData.h
index daaf9cdad..27c830199 100644
--- a/SmartDeviceLink/public/SDLSubscribeVehicleData.h
+++ b/SmartDeviceLink/public/SDLSubscribeVehicleData.h
@@ -26,72 +26,6 @@ NS_ASSUME_NONNULL_BEGIN
* @param airbagStatus Subscribe to airbagStatus
* @param beltStatus Subscribe to beltStatus
* @param bodyInformation Subscribe to bodyInformation
- * @param clusterModeStatus Subscribe to clusterModeStatus
- * @param deviceStatus Subscribe to deviceStatus
- * @param driverBraking Subscribe to driverBraking
- * @param eCallInfo Subscribe to eCallInfo
- * @param emergencyEvent Subscribe to emergencyEvent
- * @param engineTorque Subscribe to engineTorque
- * @param externalTemperature Subscribe to externalTemperature
- * @param fuelLevel Subscribe to fuelLevel
- * @param fuelLevelState Subscribe to fuelLevelState
- * @param gps Subscribe to gps
- * @param headLampStatus Subscribe to headLampStatus
- * @param instantFuelConsumption Subscribe to instantFuelConsumption
- * @param myKey Subscribe to myKey
- * @param odometer Subscribe to odometer
- * @param prndl Subscribe to prndl
- * @param rpm Subscribe to rpm
- * @param speed Subscribe to speed
- * @param steeringWheelAngle Subscribe to steeringWheelAngle
- * @param tirePressure Subscribe to tirePressure
- * @param wiperStatus Subscribe to wiperStatus
- * @return A SDLSubscribeVehicleData object
- */
-- (instancetype)initWithAccelerationPedalPosition:(BOOL)accelerationPedalPosition airbagStatus:(BOOL)airbagStatus beltStatus:(BOOL)beltStatus bodyInformation:(BOOL)bodyInformation clusterModeStatus:(BOOL)clusterModeStatus deviceStatus:(BOOL)deviceStatus driverBraking:(BOOL)driverBraking eCallInfo:(BOOL)eCallInfo emergencyEvent:(BOOL)emergencyEvent engineTorque:(BOOL)engineTorque externalTemperature:(BOOL)externalTemperature fuelLevel:(BOOL)fuelLevel fuelLevelState:(BOOL)fuelLevelState gps:(BOOL)gps headLampStatus:(BOOL)headLampStatus instantFuelConsumption:(BOOL)instantFuelConsumption myKey:(BOOL)myKey odometer:(BOOL)odometer prndl:(BOOL)prndl rpm:(BOOL)rpm speed:(BOOL)speed steeringWheelAngle:(BOOL)steeringWheelAngle tirePressure:(BOOL)tirePressure wiperStatus:(BOOL)wiperStatus __deprecated_msg("Use initWithGps:speed:rpm:instantFuelConsumption:fuelRange:externalTemperature:turnSignal:gearStatus:tirePressure:odometer:beltStatus:bodyInformation:deviceStatus:driverBraking:wiperStatus:headLampStatus:engineTorque:accPedalPosition:steeringWheelAngle:engineOilLife:electronicParkBrakeStatus:cloudAppVehicleID:stabilityControlsStatus:eCallInfo:airbagStatus:emergencyEvent:clusterModeStatus:myKey:handsOffSteering:windowStatus: instead");
-
-/**
- * Convenience init for subscribing to all possible vehicle data items.
- *
- * @param accelerationPedalPosition Subscribe to accelerationPedalPosition
- * @param airbagStatus Subscribe to airbagStatus
- * @param beltStatus Subscribe to beltStatus
- * @param bodyInformation Subscribe to bodyInformation
- * @param clusterModeStatus Subscribe to clusterModeStatus
- * @param deviceStatus Subscribe to deviceStatus
- * @param driverBraking Subscribe to driverBraking
- * @param eCallInfo Subscribe to eCallInfo
- * @param electronicParkBrakeStatus Subscribe to electronicParkBrakeStatus
- * @param emergencyEvent Subscribe to emergencyEvent
- * @param engineOilLife Subscribe to engineOilLife
- * @param engineTorque Subscribe to engineTorque
- * @param externalTemperature Subscribe to externalTemperature
- * @param fuelLevel Subscribe to fuelLevel
- * @param fuelLevelState Subscribe to fuelLevelState
- * @param fuelRange Subscribe to fuelRange
- * @param gps Subscribe to gps
- * @param headLampStatus Subscribe to headLampStatus
- * @param instantFuelConsumption Subscribe to instantFuelConsumption
- * @param myKey Subscribe to myKey
- * @param odometer Subscribe to odometer
- * @param prndl Subscribe to prndl
- * @param rpm Subscribe to rpm
- * @param speed Subscribe to speed
- * @param steeringWheelAngle Subscribe to steeringWheelAngle
- * @param tirePressure Subscribe to tirePressure
- * @param turnSignal Subscribe to turnSignal
- * @param wiperStatus Subscribe to wiperStatus
- * @return A SDLSubscribeVehicleData object
- */
-- (instancetype)initWithAccelerationPedalPosition:(BOOL)accelerationPedalPosition airbagStatus:(BOOL)airbagStatus beltStatus:(BOOL)beltStatus bodyInformation:(BOOL)bodyInformation clusterModeStatus:(BOOL)clusterModeStatus deviceStatus:(BOOL)deviceStatus driverBraking:(BOOL)driverBraking eCallInfo:(BOOL)eCallInfo electronicParkBrakeStatus:(BOOL)electronicParkBrakeStatus emergencyEvent:(BOOL)emergencyEvent engineOilLife:(BOOL)engineOilLife engineTorque:(BOOL)engineTorque externalTemperature:(BOOL)externalTemperature fuelLevel:(BOOL)fuelLevel fuelLevelState:(BOOL)fuelLevelState fuelRange:(BOOL)fuelRange gps:(BOOL)gps headLampStatus:(BOOL)headLampStatus instantFuelConsumption:(BOOL)instantFuelConsumption myKey:(BOOL)myKey odometer:(BOOL)odometer prndl:(BOOL)prndl rpm:(BOOL)rpm speed:(BOOL)speed steeringWheelAngle:(BOOL)steeringWheelAngle tirePressure:(BOOL)tirePressure turnSignal:(BOOL)turnSignal wiperStatus:(BOOL)wiperStatus __deprecated_msg("Use initWithGps:speed:rpm:instantFuelConsumption:fuelRange:externalTemperature:turnSignal:gearStatus:tirePressure:odometer:beltStatus:bodyInformation:deviceStatus:driverBraking:wiperStatus:headLampStatus:engineTorque:accPedalPosition:steeringWheelAngle:engineOilLife:electronicParkBrakeStatus:cloudAppVehicleID:stabilityControlsStatus:eCallInfo:airbagStatus:emergencyEvent:clusterModeStatus:myKey:handsOffSteering:windowStatus: instead");
-
-/**
- * Convenience init for subscribing to all possible vehicle data items.
- *
- * @param accelerationPedalPosition Subscribe to accelerationPedalPosition
- * @param airbagStatus Subscribe to airbagStatus
- * @param beltStatus Subscribe to beltStatus
- * @param bodyInformation Subscribe to bodyInformation
* @param cloudAppVehicleID Subscribe to cloudAppVehicleID
* @param clusterModeStatus Subscribe to clusterModeStatus
* @param deviceStatus Subscribe to deviceStatus
diff --git a/SmartDeviceLink/public/SDLSubscribeVehicleData.m b/SmartDeviceLink/public/SDLSubscribeVehicleData.m
index 4b755ee60..0e8b39c53 100644
--- a/SmartDeviceLink/public/SDLSubscribeVehicleData.m
+++ b/SmartDeviceLink/public/SDLSubscribeVehicleData.m
@@ -23,32 +23,6 @@ NS_ASSUME_NONNULL_BEGIN
}
#pragma clang diagnostic pop
-- (instancetype)initWithAccelerationPedalPosition:(BOOL)accelerationPedalPosition airbagStatus:(BOOL)airbagStatus beltStatus:(BOOL)beltStatus bodyInformation:(BOOL)bodyInformation clusterModeStatus:(BOOL)clusterModeStatus deviceStatus:(BOOL)deviceStatus driverBraking:(BOOL)driverBraking eCallInfo:(BOOL)eCallInfo emergencyEvent:(BOOL)emergencyEvent engineTorque:(BOOL)engineTorque externalTemperature:(BOOL)externalTemperature fuelLevel:(BOOL)fuelLevel fuelLevelState:(BOOL)fuelLevelState gps:(BOOL)gps headLampStatus:(BOOL)headLampStatus instantFuelConsumption:(BOOL)instantFuelConsumption myKey:(BOOL)myKey odometer:(BOOL)odometer prndl:(BOOL)prndl rpm:(BOOL)rpm speed:(BOOL)speed steeringWheelAngle:(BOOL)steeringWheelAngle tirePressure:(BOOL)tirePressure wiperStatus:(BOOL)wiperStatus {
- self = [self initWithGps:@(gps) speed:@(speed) rpm:@(rpm) instantFuelConsumption:@(instantFuelConsumption) fuelRange:nil externalTemperature:@(externalTemperature) turnSignal:nil gearStatus:nil tirePressure:@(tirePressure) odometer:@(odometer) beltStatus:@(beltStatus) bodyInformation:@(bodyInformation) deviceStatus:@(deviceStatus) driverBraking:@(driverBraking) wiperStatus:@(wiperStatus) headLampStatus:@(headLampStatus) engineTorque:@(engineTorque) accPedalPosition:@(accelerationPedalPosition) steeringWheelAngle:@(steeringWheelAngle) engineOilLife:nil electronicParkBrakeStatus:nil cloudAppVehicleID:nil stabilityControlsStatus:nil eCallInfo:@(eCallInfo) airbagStatus:@(airbagStatus) emergencyEvent:@(emergencyEvent) clusterModeStatus:@(clusterModeStatus) myKey:@(myKey) handsOffSteering:nil windowStatus:nil];
- if (self) {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- self.fuelLevel = @(fuelLevel);
- self.fuelLevel_State = @(fuelLevelState);
- self.prndl = @(prndl);
-#pragma clang diagnostic pop
- }
- return self;
-}
-
-- (instancetype)initWithAccelerationPedalPosition:(BOOL)accelerationPedalPosition airbagStatus:(BOOL)airbagStatus beltStatus:(BOOL)beltStatus bodyInformation:(BOOL)bodyInformation clusterModeStatus:(BOOL)clusterModeStatus deviceStatus:(BOOL)deviceStatus driverBraking:(BOOL)driverBraking eCallInfo:(BOOL)eCallInfo electronicParkBrakeStatus:(BOOL)electronicParkBrakeStatus emergencyEvent:(BOOL)emergencyEvent engineOilLife:(BOOL)engineOilLife engineTorque:(BOOL)engineTorque externalTemperature:(BOOL)externalTemperature fuelLevel:(BOOL)fuelLevel fuelLevelState:(BOOL)fuelLevelState fuelRange:(BOOL)fuelRange gps:(BOOL)gps headLampStatus:(BOOL)headLampStatus instantFuelConsumption:(BOOL)instantFuelConsumption myKey:(BOOL)myKey odometer:(BOOL)odometer prndl:(BOOL)prndl rpm:(BOOL)rpm speed:(BOOL)speed steeringWheelAngle:(BOOL)steeringWheelAngle tirePressure:(BOOL)tirePressure turnSignal:(BOOL)turnSignal wiperStatus:(BOOL)wiperStatus {
- self = [self initWithGps:@(gps) speed:@(speed) rpm:@(rpm) instantFuelConsumption:@(instantFuelConsumption) fuelRange:@(fuelRange) externalTemperature:@(externalTemperature) turnSignal:@(turnSignal) gearStatus:nil tirePressure:@(tirePressure) odometer:@(odometer) beltStatus:@(beltStatus) bodyInformation:@(bodyInformation) deviceStatus:@(deviceStatus) driverBraking:@(driverBraking) wiperStatus:@(wiperStatus) headLampStatus:@(headLampStatus) engineTorque:@(engineTorque) accPedalPosition:@(accelerationPedalPosition) steeringWheelAngle:@(steeringWheelAngle) engineOilLife:@(engineOilLife) electronicParkBrakeStatus:@(electronicParkBrakeStatus) cloudAppVehicleID:nil stabilityControlsStatus:nil eCallInfo:@(eCallInfo) airbagStatus:@(airbagStatus) emergencyEvent:@(emergencyEvent) clusterModeStatus:@(clusterModeStatus) myKey:@(myKey) handsOffSteering:nil windowStatus:nil];
- if (self) {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- self.fuelLevel = @(fuelLevel);
- self.fuelLevel_State = @(fuelLevelState);
- self.prndl = @(prndl);
-#pragma clang diagnostic pop
- }
- return self;
-}
-
- (instancetype)initWithAccelerationPedalPosition:(BOOL)accelerationPedalPosition airbagStatus:(BOOL)airbagStatus beltStatus:(BOOL)beltStatus bodyInformation:(BOOL)bodyInformation cloudAppVehicleID:(BOOL)cloudAppVehicleID clusterModeStatus:(BOOL)clusterModeStatus deviceStatus:(BOOL)deviceStatus driverBraking:(BOOL)driverBraking eCallInfo:(BOOL)eCallInfo electronicParkBrakeStatus:(BOOL)electronicParkBrakeStatus emergencyEvent:(BOOL)emergencyEvent engineOilLife:(BOOL)engineOilLife engineTorque:(BOOL)engineTorque externalTemperature:(BOOL)externalTemperature fuelLevel:(BOOL)fuelLevel fuelLevelState:(BOOL)fuelLevelState fuelRange:(BOOL)fuelRange gps:(BOOL)gps headLampStatus:(BOOL)headLampStatus instantFuelConsumption:(BOOL)instantFuelConsumption myKey:(BOOL)myKey odometer:(BOOL)odometer prndl:(BOOL)prndl rpm:(BOOL)rpm speed:(BOOL)speed steeringWheelAngle:(BOOL)steeringWheelAngle tirePressure:(BOOL)tirePressure turnSignal:(BOOL)turnSignal wiperStatus:(BOOL)wiperStatus {
self = [self initWithGps:@(gps) speed:@(speed) rpm:@(rpm) instantFuelConsumption:@(instantFuelConsumption) fuelRange:@(fuelRange) externalTemperature:@(externalTemperature) turnSignal:@(turnSignal) gearStatus:nil tirePressure:@(tirePressure) odometer:@(odometer) beltStatus:@(beltStatus) bodyInformation:@(bodyInformation) deviceStatus:@(deviceStatus) driverBraking:@(driverBraking) wiperStatus:@(wiperStatus) headLampStatus:@(headLampStatus) engineTorque:@(engineTorque) accPedalPosition:@(accelerationPedalPosition) steeringWheelAngle:@(steeringWheelAngle) engineOilLife:@(engineOilLife) electronicParkBrakeStatus:@(electronicParkBrakeStatus) cloudAppVehicleID:@(cloudAppVehicleID) stabilityControlsStatus:nil eCallInfo:@(eCallInfo) airbagStatus:@(airbagStatus) emergencyEvent:@(emergencyEvent) clusterModeStatus:@(clusterModeStatus) myKey:@(myKey) handsOffSteering:nil windowStatus:nil];
if (self) {
diff --git a/SmartDeviceLink/public/SDLSupportedSeat.h b/SmartDeviceLink/public/SDLSupportedSeat.h
index 018e0514d..15f2887a1 100644
--- a/SmartDeviceLink/public/SDLSupportedSeat.h
+++ b/SmartDeviceLink/public/SDLSupportedSeat.h
@@ -5,22 +5,19 @@
/**
* List possible seats that is a remote controllable seat.
- * @warning This should not be used to supported seats, this is a deprecated parameter.
+ *
+ * @deprecated
+ * @history SDL 5.0.0
+ * @since SDL 6.0.0
*/
-typedef SDLEnum SDLSupportedSeat SDL_SWIFT_ENUM __deprecated;
+typedef SDLEnum SDLSupportedSeat NS_TYPED_ENUM __deprecated;
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
/**
* Save current seat positions and settings to seat memory.
*/
-extern SDLSupportedSeat const SDLSupportedSeatDriver;
-#pragma clang diagnostic pop
+extern SDLSupportedSeat const SDLSupportedSeatDriver __deprecated;
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
/**
* Restore / apply the seat memory settings to the current seat.
*/
-extern SDLSupportedSeat const SDLSupportedSeatFrontPassenger;
-#pragma clang diagnostic pop
+extern SDLSupportedSeat const SDLSupportedSeatFrontPassenger __deprecated;
diff --git a/SmartDeviceLink/public/SDLSupportedSeat.m b/SmartDeviceLink/public/SDLSupportedSeat.m
index 1260ced9d..f97678bb1 100644
--- a/SmartDeviceLink/public/SDLSupportedSeat.m
+++ b/SmartDeviceLink/public/SDLSupportedSeat.m
@@ -3,8 +3,5 @@
#import "SDLSupportedSeat.h"
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
SDLSupportedSeat const SDLSupportedSeatDriver = @"DRIVER";
SDLSupportedSeat const SDLSupportedSeatFrontPassenger = @"FRONT_PASSENGER";
-#pragma clang diagnostic pop
diff --git a/SmartDeviceLink/public/SDLSyncMsgVersion.h b/SmartDeviceLink/public/SDLSyncMsgVersion.h
deleted file mode 100644
index 7ef41b21d..000000000
--- a/SmartDeviceLink/public/SDLSyncMsgVersion.h
+++ /dev/null
@@ -1,47 +0,0 @@
-// SDLSyncMsgVersion.h
-//
-
-
-#import "SDLRPCMessage.h"
-
-NS_ASSUME_NONNULL_BEGIN
-
-/**
- * Specifies the version number of the SDL V4 interface. This is used by both the application and SDL to declare what interface version each is using.
- *
- * @since SDL 1.0
- */
-__deprecated_msg("Use SDLMsgVersion instead")
-@interface SDLSyncMsgVersion : SDLRPCStruct
-
-/// Convenience init to describe the SDL version
-///
-/// @param majorVersion The major version indicates versions that is not-compatible to previous versions
-/// @param minorVersion The minor version indicates a change to a previous version that should still allow to be run on an older version (with limited functionality)
-/// @param patchVersion Allows backward-compatible fixes to the API without increasing the minor version of the interface
-/// @return An SDLSyncMsgVersion object
-- (instancetype)initWithMajorVersion:(UInt8)majorVersion minorVersion:(UInt8)minorVersion patchVersion:(UInt8)patchVersion;
-
-/**
- * The major version indicates versions that is not-compatible to previous versions
- *
- * Required, Integer, 1 - 10
- */
-@property (strong, nonatomic) NSNumber<SDLInt> *majorVersion;
-/**
- * The minor version indicates a change to a previous version that should still allow to be run on an older version (with limited functionality)
- *
- * Required, Integer, 0 - 1000
- */
-@property (strong, nonatomic) NSNumber<SDLInt> *minorVersion;
-
-/**
- * Allows backward-compatible fixes to the API without increasing the minor version of the interface
- *
- * Optional, Integer, 0 - 1000
- */
-@property (strong, nonatomic, nullable) NSNumber<SDLInt> *patchVersion;
-
-@end
-
-NS_ASSUME_NONNULL_END
diff --git a/SmartDeviceLink/public/SDLSyncMsgVersion.m b/SmartDeviceLink/public/SDLSyncMsgVersion.m
deleted file mode 100644
index b922672ed..000000000
--- a/SmartDeviceLink/public/SDLSyncMsgVersion.m
+++ /dev/null
@@ -1,61 +0,0 @@
-// SDLSyncMsgVersion.m
-//
-
-
-#import "SDLSyncMsgVersion.h"
-
-#import "NSMutableDictionary+Store.h"
-#import "SDLRPCParameterNames.h"
-
-NS_ASSUME_NONNULL_BEGIN
-
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-implementations"
-@implementation SDLSyncMsgVersion
-#pragma clang diagnostic pop
-
-- (instancetype)initWithMajorVersion:(UInt8)majorVersion minorVersion:(UInt8)minorVersion patchVersion:(UInt8)patchVersion {
- self = [self init];
- if (!self) {
- return nil;
- }
-
- self.majorVersion = @(majorVersion);
- self.minorVersion = @(minorVersion);
- self.patchVersion = @(patchVersion);
-
- return self;
-}
-
-- (void)setMajorVersion:(NSNumber<SDLInt> *)majorVersion {
- [self.store sdl_setObject:majorVersion forName:SDLRPCParameterNameMajorVersion];
-}
-
-- (NSNumber<SDLInt> *)majorVersion {
- NSError *error = nil;
- return [self.store sdl_objectForName:SDLRPCParameterNameMajorVersion ofClass:NSNumber.class error:&error];
-}
-
-- (void)setMinorVersion:(NSNumber<SDLInt> *)minorVersion {
- [self.store sdl_setObject:minorVersion forName:SDLRPCParameterNameMinorVersion];
-}
-
-- (NSNumber<SDLInt> *)minorVersion {
- NSError *error = nil;
- return [self.store sdl_objectForName:SDLRPCParameterNameMinorVersion ofClass:NSNumber.class error:&error];
-}
-
-- (void)setPatchVersion:(nullable NSNumber<SDLInt> *)patchVersion {
- [self.store sdl_setObject:patchVersion forName:SDLRPCParameterNamePatchVersion];
-}
-
-- (nullable NSNumber<SDLInt> *)patchVersion {
- return [self.store sdl_objectForName:SDLRPCParameterNamePatchVersion ofClass:NSNumber.class error:nil];
-}
-
-- (NSString *)description {
- return [NSString stringWithFormat:@"%@.%@.%@", self.majorVersion, self.minorVersion, self.patchVersion];
-}
-@end
-
-NS_ASSUME_NONNULL_END
diff --git a/SmartDeviceLink/public/SDLSystemAction.h b/SmartDeviceLink/public/SDLSystemAction.h
index 9c302cf77..c88a9c6a8 100644
--- a/SmartDeviceLink/public/SDLSystemAction.h
+++ b/SmartDeviceLink/public/SDLSystemAction.h
@@ -7,7 +7,7 @@
/**
* Enumeration that describes system actions that can be triggered. Used in SoftButton.
*/
-typedef SDLEnum SDLSystemAction SDL_SWIFT_ENUM;
+typedef SDLEnum SDLSystemAction NS_TYPED_ENUM;
/**
A default soft button action
diff --git a/SmartDeviceLink/public/SDLSystemCapabilityManager.h b/SmartDeviceLink/public/SDLSystemCapabilityManager.h
index bbedc4c66..42467a2fb 100644
--- a/SmartDeviceLink/public/SDLSystemCapabilityManager.h
+++ b/SmartDeviceLink/public/SDLSystemCapabilityManager.h
@@ -249,19 +249,6 @@ typedef void (^SDLCapabilityUpdateWithErrorHandler)(SDLSystemCapability * _Nulla
*/
- (void)updateCapabilityType:(SDLSystemCapabilityType)type completionHandler:(SDLUpdateCapabilityHandler)handler;
-/// Subscribe to a particular capability type using a block callback.
-///
-/// On v5.1.0+ systems (where `supportsSubscriptions == YES`):
-/// This method will be called immediately with the current value if a subscription already exists and will be called every time the value is updated.
-///
-/// On sub-v5.1.0 systems (where `supportsSubscriptions == NO`):
-/// The method will be called immediately with the current value and will _not_ be automatically called every time the value is updated, unless the `type` is `DISPLAYS` which is supported on every version. If `updateCapabilityType:completionHandler` is called and a new value is retrieved, this value will be updated then. If this is the first subscription of this `SDLSystemCapabilityType`, then the value will be retrieved and returned.
-///
-/// @param type The type of capability to subscribe to
-/// @param block The block to be called when the capability is updated
-/// @return An object that can be used to unsubscribe the block using unsubscribeFromCapabilityType:withObserver: by passing it in the observer callback, or nil if the manager can't attempt the subscription for some reason (such as the app being in HMI_NONE and the type is not DISPLAYS).
-- (nullable id<NSObject>)subscribeToCapabilityType:(SDLSystemCapabilityType)type withBlock:(SDLCapabilityUpdateHandler)block __deprecated_msg("use subscribeToCapabilityType:withUpdateHandler: instead");
-
/// Subscribe to a particular capability type using a handler callback.
///
/// On v5.1.0+ systems (where `supportsSubscriptions == YES`):
diff --git a/SmartDeviceLink/public/SDLSystemCapabilityManager.m b/SmartDeviceLink/public/SDLSystemCapabilityManager.m
index 8c979a18e..8d7e14a78 100644
--- a/SmartDeviceLink/public/SDLSystemCapabilityManager.m
+++ b/SmartDeviceLink/public/SDLSystemCapabilityManager.m
@@ -94,12 +94,7 @@ typedef NSString * SDLServiceID;
return nil;
}
- if (@available(iOS 10.0, *)) {
- _readWriteQueue = dispatch_queue_create_with_target("com.sdl.systemCapabilityManager.readWriteQueue", DISPATCH_QUEUE_SERIAL, [SDLGlobals sharedGlobals].sdlProcessingQueue);
- } else {
- _readWriteQueue = [SDLGlobals sharedGlobals].sdlProcessingQueue;
- }
-
+ _readWriteQueue = dispatch_queue_create_with_target("com.sdl.systemCapabilityManager.readWriteQueue", DISPATCH_QUEUE_SERIAL, [SDLGlobals sharedGlobals].sdlProcessingQueue);
_connectionManager = manager;
_shouldConvertDeprecatedDisplayCapabilities = YES;
_appServicesCapabilitiesDictionary = [NSMutableDictionary dictionary];
@@ -477,7 +472,7 @@ typedef NSString * SDLServiceID;
SDLLogV(@"Saving app services capability update with new capabilities: %@", newCapabilities);
for (SDLAppServiceCapability *capability in newCapabilities.appServices) {
// If the capability has been removed, delete the saved capability; otherwise just update with the new capability
- SDLAppServiceCapability *newCapability = [capability.updateReason isEqualToEnum:SDLServiceUpdateRemoved] ? nil : capability;
+ SDLAppServiceCapability *newCapability = [capability.updateReason isEqualToEnum:SDLServiceUpdateReasonRemoved] ? nil : capability;
[SDLGlobals runSyncOnSerialSubQueue:self.readWriteQueue block:^{
self.appServicesCapabilitiesDictionary[capability.updatedAppServiceRecord.serviceID] = newCapability;
}];
@@ -533,14 +528,6 @@ typedef NSString * SDLServiceID;
#pragma mark Subscribing
-- (nullable id<NSObject>)subscribeToCapabilityType:(SDLSystemCapabilityType)type withBlock:(SDLCapabilityUpdateHandler)block {
- SDLLogD(@"Subscribing to capability type: %@ with a handler (DEPRECATED)", type);
- SDLSystemCapabilityObserver *observerObject = [[SDLSystemCapabilityObserver alloc] initWithObserver:[[NSObject alloc] init] block:block];
-
- id<NSObject> subscribedObserver = [self sdl_subscribeToCapabilityType:type observerObject:observerObject];
- return subscribedObserver;
-}
-
- (nullable id<NSObject>)subscribeToCapabilityType:(SDLSystemCapabilityType)type withUpdateHandler:(SDLCapabilityUpdateWithErrorHandler)handler {
SDLLogD(@"Subscribing to capability type: %@ with a handler", type);
SDLSystemCapabilityObserver *observerObject = [[SDLSystemCapabilityObserver alloc] initWithObserver:[[NSObject alloc] init] updateHandler:handler];
@@ -678,12 +665,7 @@ typedef NSString * SDLServiceID;
- (void)sdl_invokeObserver:(SDLSystemCapabilityObserver *)observer withCapabilityType:(SDLSystemCapabilityType)type capability:(nullable SDLSystemCapability *)capability error:(nullable NSError *)error {
BOOL subscribed = self.subscriptionStatus[type].boolValue || [type isEqualToEnum:SDLSystemCapabilityTypeDisplays];
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- if (observer.block != nil) {
- observer.block(capability);
-#pragma clang diagnostic pop
- } else if (observer.updateBlock != nil) {
+ if (observer.updateBlock != nil) {
observer.updateBlock(capability, subscribed, error);
} else {
if (![observer.observer respondsToSelector:observer.selector]) {
diff --git a/SmartDeviceLink/public/SDLSystemCapabilityType.h b/SmartDeviceLink/public/SDLSystemCapabilityType.h
index 2c5092794..0d184023b 100755
--- a/SmartDeviceLink/public/SDLSystemCapabilityType.h
+++ b/SmartDeviceLink/public/SDLSystemCapabilityType.h
@@ -35,7 +35,7 @@
/**
The type of system capability to get more information on. Used in GetSystemCapability.
*/
-typedef SDLEnum SDLSystemCapabilityType SDL_SWIFT_ENUM;
+typedef SDLEnum SDLSystemCapabilityType NS_TYPED_ENUM;
/**
The app services capability
diff --git a/SmartDeviceLink/public/SDLSystemContext.h b/SmartDeviceLink/public/SDLSystemContext.h
index 83fc8e43c..fbdb09d6f 100644
--- a/SmartDeviceLink/public/SDLSystemContext.h
+++ b/SmartDeviceLink/public/SDLSystemContext.h
@@ -9,7 +9,7 @@
*
* @since SDL 1.0
*/
-typedef SDLEnum SDLSystemContext SDL_SWIFT_ENUM;
+typedef SDLEnum SDLSystemContext NS_TYPED_ENUM;
/**
* No user interaction (user-initiated or app-initiated) is in progress.
diff --git a/SmartDeviceLink/public/SDLTBTState.h b/SmartDeviceLink/public/SDLTBTState.h
index d1fccb658..33f3a945c 100644
--- a/SmartDeviceLink/public/SDLTBTState.h
+++ b/SmartDeviceLink/public/SDLTBTState.h
@@ -7,7 +7,7 @@
/**
The turn-by-turn state, used in OnTBTClientState.
*/
-typedef SDLEnum SDLTBTState SDL_SWIFT_ENUM;
+typedef SDLEnum SDLTBTState NS_TYPED_ENUM;
/**
The route should be updated
diff --git a/SmartDeviceLink/public/SDLTPMS.h b/SmartDeviceLink/public/SDLTPMS.h
index 4831af523..23cab375b 100644
--- a/SmartDeviceLink/public/SDLTPMS.h
+++ b/SmartDeviceLink/public/SDLTPMS.h
@@ -7,7 +7,7 @@
/**
An enum representing values of the tire pressure monitoring system
*/
-typedef SDLEnum SDLTPMS SDL_SWIFT_ENUM;
+typedef SDLEnum SDLTPMS NS_TYPED_ENUM;
/**
If set the status of the tire is not known.
diff --git a/SmartDeviceLink/public/SDLTemperatureUnit.h b/SmartDeviceLink/public/SDLTemperatureUnit.h
index ff4b10ea8..e7bd4a0d6 100644
--- a/SmartDeviceLink/public/SDLTemperatureUnit.h
+++ b/SmartDeviceLink/public/SDLTemperatureUnit.h
@@ -8,7 +8,7 @@
/**
The unit of temperature to display. Used in Temperature.
*/
-typedef SDLEnum SDLTemperatureUnit SDL_SWIFT_ENUM;
+typedef SDLEnum SDLTemperatureUnit NS_TYPED_ENUM;
/**
Reflects the current HMI setting for temperature unit in Celsius
diff --git a/SmartDeviceLink/public/SDLTextAlignment.h b/SmartDeviceLink/public/SDLTextAlignment.h
index 5fafd443e..f9b0a16ee 100644
--- a/SmartDeviceLink/public/SDLTextAlignment.h
+++ b/SmartDeviceLink/public/SDLTextAlignment.h
@@ -9,7 +9,7 @@
*
* @since SDL 1.0
*/
-typedef SDLEnum SDLTextAlignment SDL_SWIFT_ENUM;
+typedef SDLEnum SDLTextAlignment NS_TYPED_ENUM;
/**
* Text aligned left.
diff --git a/SmartDeviceLink/public/SDLTextFieldName.h b/SmartDeviceLink/public/SDLTextFieldName.h
index a61146aa6..57d741026 100644
--- a/SmartDeviceLink/public/SDLTextFieldName.h
+++ b/SmartDeviceLink/public/SDLTextFieldName.h
@@ -37,7 +37,7 @@
*
* @since SDL 1.0
*/
-typedef SDLEnum SDLTextFieldName SDL_SWIFT_ENUM;
+typedef SDLEnum SDLTextFieldName NS_TYPED_ENUM;
/**
* The first line of the first set of main fields of the persistent display. Applies to SDLShow.
diff --git a/SmartDeviceLink/public/SDLTimerMode.h b/SmartDeviceLink/public/SDLTimerMode.h
index 9e0b27bbf..416b9df92 100644
--- a/SmartDeviceLink/public/SDLTimerMode.h
+++ b/SmartDeviceLink/public/SDLTimerMode.h
@@ -7,7 +7,7 @@
/**
The direction of a timer. Used in nothing.
*/
-typedef SDLEnum SDLTimerMode SDL_SWIFT_ENUM;
+typedef SDLEnum SDLTimerMode NS_TYPED_ENUM;
/**
The timer should count up.
diff --git a/SmartDeviceLink/public/SDLTouchManager.h b/SmartDeviceLink/public/SDLTouchManager.h
index c762d6822..4f0104d31 100644
--- a/SmartDeviceLink/public/SDLTouchManager.h
+++ b/SmartDeviceLink/public/SDLTouchManager.h
@@ -59,14 +59,7 @@ typedef void(^SDLTouchEventHandler)(SDLTouch *touch, SDLTouchType type);
@property (nonatomic, assign) CGFloat tapTimeThreshold;
/**
- Time (in seconds) between movement events to register panning or pinching callbacks.
-
- Default is 0.05 seconds.
- */
-@property (nonatomic, assign) CGFloat movementTimeThreshold __deprecated_msg("This is now unused, the movement time threshold is now synced to the framerate automatically");
-
-/**
- If set to NO, the display link syncing will be ignored and `movementTimeThreshold` will be used. Defaults to YES.
+ If set to NO, the display link syncing will be ignored. Defaults to YES.
*/
@property (assign, nonatomic) BOOL enableSyncedPanning;
@@ -88,14 +81,6 @@ typedef void(^SDLTouchEventHandler)(SDLTouch *touch, SDLTouchType type);
- (instancetype)init NS_UNAVAILABLE;
/**
- Initialize a touch manager with a hit tester if available
-
- @param hitTester The hit tester to be used to correlate a point with a view
- @return The initialized touch manager
- */
-- (instancetype)initWithHitTester:(nullable id<SDLFocusableItemHitTester>)hitTester __deprecated_msg("Use initWithHitTester:hitTester videoScaleManager: instead");
-
-/**
Initialize a touch manager with a hit tester and a video scale manager.
@param hitTester The hit tester to be used to correlate a point with a view
diff --git a/SmartDeviceLink/public/SDLTouchManager.m b/SmartDeviceLink/public/SDLTouchManager.m
index 242f4e46e..ad9eb4703 100644
--- a/SmartDeviceLink/public/SDLTouchManager.m
+++ b/SmartDeviceLink/public/SDLTouchManager.m
@@ -106,10 +106,6 @@ static NSUInteger const MaximumNumberOfTouches = 2;
@implementation SDLTouchManager
-- (instancetype)initWithHitTester:(nullable id<SDLFocusableItemHitTester>)hitTester {
- return [self initWithHitTester:hitTester videoScaleManager:[[SDLStreamingVideoScaleManager alloc] init]];
-}
-
- (instancetype)initWithHitTester:(nullable id<SDLFocusableItemHitTester>)hitTester videoScaleManager:(SDLStreamingVideoScaleManager *)videoScaleManager {
self = [super init];
if (!self) {
@@ -118,7 +114,6 @@ static NSUInteger const MaximumNumberOfTouches = 2;
_hitTester = hitTester;
_videoScaleManager = videoScaleManager;
- _movementTimeThreshold = 0.05f;
_tapTimeThreshold = 0.4f;
_tapDistanceThreshold = 50.0f;
_panDistanceThreshold = 8.0f;
@@ -257,14 +252,6 @@ static NSUInteger const MaximumNumberOfTouches = 2;
* @param touch Gesture information
*/
- (void)sdl_handleTouchMoved:(SDLTouch *)touch {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- if (!self.enableSyncedPanning &&
- ((touch.timeStamp - self.previousTouch.timeStamp) <= (self.movementTimeThreshold * NSEC_PER_USEC))) {
- return; // no-op
- }
-#pragma clang diagnostic pop
-
CGFloat xDelta = fabs(touch.location.x - self.firstTouch.location.x);
CGFloat yDelta = fabs(touch.location.y - self.firstTouch.location.y);
if (xDelta <= self.panDistanceThreshold && yDelta <= self.panDistanceThreshold) {
diff --git a/SmartDeviceLink/public/SDLTouchType.h b/SmartDeviceLink/public/SDLTouchType.h
index cce21c053..83faad3c2 100644
--- a/SmartDeviceLink/public/SDLTouchType.h
+++ b/SmartDeviceLink/public/SDLTouchType.h
@@ -7,7 +7,7 @@
/**
The type of a touch in a projection application. Used in OnTouchEvent.
*/
-typedef SDLEnum SDLTouchType SDL_SWIFT_ENUM;
+typedef SDLEnum SDLTouchType NS_TYPED_ENUM;
/**
The touch is the beginning of a finger pressed on the display.
diff --git a/SmartDeviceLink/public/SDLTransmissionType.h b/SmartDeviceLink/public/SDLTransmissionType.h
index 0a11ace1f..e85068b0d 100644
--- a/SmartDeviceLink/public/SDLTransmissionType.h
+++ b/SmartDeviceLink/public/SDLTransmissionType.h
@@ -37,7 +37,7 @@
*
* @since SDL 7.0
*/
-typedef SDLEnum SDLTransmissionType SDL_SWIFT_ENUM;
+typedef SDLEnum SDLTransmissionType NS_TYPED_ENUM;
/**
* Automatic transmission.
diff --git a/SmartDeviceLink/public/SDLTriggerSource.h b/SmartDeviceLink/public/SDLTriggerSource.h
index d6d44db53..f10e7f0b5 100644
--- a/SmartDeviceLink/public/SDLTriggerSource.h
+++ b/SmartDeviceLink/public/SDLTriggerSource.h
@@ -9,7 +9,7 @@
*
* @since SDL 1.0
*/
-typedef SDLEnum SDLTriggerSource SDL_SWIFT_ENUM;
+typedef SDLEnum SDLTriggerSource NS_TYPED_ENUM;
/**
* Selection made via menu
diff --git a/SmartDeviceLink/public/SDLTurnSignal.h b/SmartDeviceLink/public/SDLTurnSignal.h
index daca0b05b..34c9e7ea9 100644
--- a/SmartDeviceLink/public/SDLTurnSignal.h
+++ b/SmartDeviceLink/public/SDLTurnSignal.h
@@ -11,7 +11,7 @@
/**
* Enumeration that describes the status of the turn light indicator.
*/
-typedef SDLEnum SDLTurnSignal SDL_SWIFT_ENUM;
+typedef SDLEnum SDLTurnSignal NS_TYPED_ENUM;
/**
* Turn signal is OFF
diff --git a/SmartDeviceLink/public/SDLUnsubscribeVehicleData.h b/SmartDeviceLink/public/SDLUnsubscribeVehicleData.h
index 8e10e27dd..57acba53d 100644
--- a/SmartDeviceLink/public/SDLUnsubscribeVehicleData.h
+++ b/SmartDeviceLink/public/SDLUnsubscribeVehicleData.h
@@ -28,72 +28,6 @@ NS_ASSUME_NONNULL_BEGIN
* @param airbagStatus Unsubscribe to airbagStatus
* @param beltStatus Unsubscribe to beltStatus
* @param bodyInformation Unsubscribe to bodyInformation
- * @param clusterModeStatus Unsubscribe to clusterModeStatus
- * @param deviceStatus Unsubscribe to deviceStatus
- * @param driverBraking Unsubscribe to driverBraking
- * @param eCallInfo Unsubscribe to eCallInfo
- * @param emergencyEvent Unsubscribe to emergencyEvent
- * @param engineTorque Unsubscribe to engineTorque
- * @param externalTemperature Unsubscribe to externalTemperature
- * @param fuelLevel Unsubscribe to fuelLevel
- * @param fuelLevelState Unsubscribe to fuelLevelState
- * @param gps Unsubscribe to gps
- * @param headLampStatus Unsubscribe to headLampStatus
- * @param instantFuelConsumption Unsubscribe to instantFuelConsumption
- * @param myKey Unsubscribe to myKey
- * @param odometer Unsubscribe to odometer
- * @param prndl Unsubscribe to prndl
- * @param rpm Unsubscribe to rpm
- * @param speed Unsubscribe to speed
- * @param steeringWheelAngle Unsubscribe to steeringWheelAngle
- * @param tirePressure Unsubscribe to tirePressure
- * @param wiperStatus Unsubscribe to wiperStatus
- * @return A SDLUnsubscribeVehicleData object
- */
-- (instancetype)initWithAccelerationPedalPosition:(BOOL)accelerationPedalPosition airbagStatus:(BOOL)airbagStatus beltStatus:(BOOL)beltStatus bodyInformation:(BOOL)bodyInformation clusterModeStatus:(BOOL)clusterModeStatus deviceStatus:(BOOL)deviceStatus driverBraking:(BOOL)driverBraking eCallInfo:(BOOL)eCallInfo emergencyEvent:(BOOL)emergencyEvent engineTorque:(BOOL)engineTorque externalTemperature:(BOOL)externalTemperature fuelLevel:(BOOL)fuelLevel fuelLevelState:(BOOL)fuelLevelState gps:(BOOL)gps headLampStatus:(BOOL)headLampStatus instantFuelConsumption:(BOOL)instantFuelConsumption myKey:(BOOL)myKey odometer:(BOOL)odometer prndl:(BOOL)prndl rpm:(BOOL)rpm speed:(BOOL)speed steeringWheelAngle:(BOOL)steeringWheelAngle tirePressure:(BOOL)tirePressure wiperStatus:(BOOL)wiperStatus __deprecated_msg("Use initWithGps:speed:rpm:instantFuelConsumption:fuelRange:externalTemperature:turnSignal:gearStatus:tirePressure:odometer:beltStatus:bodyInformation:deviceStatus:driverBraking:wiperStatus:headLampStatus:engineTorque:accPedalPosition:steeringWheelAngle:engineOilLife:electronicParkBrakeStatus:cloudAppVehicleID:stabilityControlsStatus:eCallInfo:airbagStatus:emergencyEvent:clusterModeStatus:myKey:handsOffSteering:windowStatus: instead");
-
-/**
- * Convenience init for unsubscribing to all possible vehicle data items.
- *
- * @param accelerationPedalPosition Unsubscribe to accelerationPedalPosition
- * @param airbagStatus Unsubscribe to airbagStatus
- * @param beltStatus Unsubscribe to beltStatus
- * @param bodyInformation Unsubscribe to bodyInformation
- * @param clusterModeStatus Unsubscribe to clusterModeStatus
- * @param deviceStatus Unsubscribe to deviceStatus
- * @param driverBraking Unsubscribe to driverBraking
- * @param eCallInfo Unsubscribe to eCallInfo
- * @param electronicParkBrakeStatus Unsubscribe to electronicParkBrakeStatus
- * @param emergencyEvent Unsubscribe to emergencyEvent
- * @param engineOilLife Unsubscribe to engineOilLife
- * @param engineTorque Unsubscribe to engineTorque
- * @param externalTemperature Unsubscribe to externalTemperature
- * @param fuelLevel Unsubscribe to fuelLevel
- * @param fuelLevelState Unsubscribe to fuelLevelState
- * @param fuelRange Unsubscribe to fuelRange
- * @param gps Unsubscribe to gps
- * @param headLampStatus Unsubscribe to headLampStatus
- * @param instantFuelConsumption Unsubscribe to instantFuelConsumption
- * @param myKey Unsubscribe to myKey
- * @param odometer Unsubscribe to odometer
- * @param prndl Unsubscribe to prndl
- * @param rpm Unsubscribe to rpm
- * @param speed Unsubscribe to speed
- * @param steeringWheelAngle Unsubscribe to steeringWheelAngle
- * @param tirePressure Unsubscribe to tirePressure
- * @param turnSignal Unsubscribe to turnSignal
- * @param wiperStatus Unsubscribe to wiperStatus
- * @return A SDLUnsubscribeVehicleData object
- */
-- (instancetype)initWithAccelerationPedalPosition:(BOOL)accelerationPedalPosition airbagStatus:(BOOL)airbagStatus beltStatus:(BOOL)beltStatus bodyInformation:(BOOL)bodyInformation clusterModeStatus:(BOOL)clusterModeStatus deviceStatus:(BOOL)deviceStatus driverBraking:(BOOL)driverBraking eCallInfo:(BOOL)eCallInfo electronicParkBrakeStatus:(BOOL)electronicParkBrakeStatus emergencyEvent:(BOOL)emergencyEvent engineOilLife:(BOOL)engineOilLife engineTorque:(BOOL)engineTorque externalTemperature:(BOOL)externalTemperature fuelLevel:(BOOL)fuelLevel fuelLevelState:(BOOL)fuelLevelState fuelRange:(BOOL)fuelRange gps:(BOOL)gps headLampStatus:(BOOL)headLampStatus instantFuelConsumption:(BOOL)instantFuelConsumption myKey:(BOOL)myKey odometer:(BOOL)odometer prndl:(BOOL)prndl rpm:(BOOL)rpm speed:(BOOL)speed steeringWheelAngle:(BOOL)steeringWheelAngle tirePressure:(BOOL)tirePressure turnSignal:(BOOL)turnSignal wiperStatus:(BOOL)wiperStatus __deprecated_msg("Use initWithGps:speed:rpm:instantFuelConsumption:fuelRange:externalTemperature:turnSignal:gearStatus:tirePressure:odometer:beltStatus:bodyInformation:deviceStatus:driverBraking:wiperStatus:headLampStatus:engineTorque:accPedalPosition:steeringWheelAngle:engineOilLife:electronicParkBrakeStatus:cloudAppVehicleID:stabilityControlsStatus:eCallInfo:airbagStatus:emergencyEvent:clusterModeStatus:myKey:handsOffSteering:windowStatus: instead");
-
-/**
- * Convenience init for unsubscribing to all possible vehicle data items.
- *
- * @param accelerationPedalPosition Unsubscribe to accelerationPedalPosition
- * @param airbagStatus Unsubscribe to airbagStatus
- * @param beltStatus Unsubscribe to beltStatus
- * @param bodyInformation Unsubscribe to bodyInformation
* @param cloudAppVehicleID Unsubscribe to cloudAppVehicleID
* @param clusterModeStatus Unsubscribe to clusterModeStatus
* @param deviceStatus Unsubscribe to deviceStatus
diff --git a/SmartDeviceLink/public/SDLUnsubscribeVehicleData.m b/SmartDeviceLink/public/SDLUnsubscribeVehicleData.m
index 70d30b4c9..217c23ce5 100644
--- a/SmartDeviceLink/public/SDLUnsubscribeVehicleData.m
+++ b/SmartDeviceLink/public/SDLUnsubscribeVehicleData.m
@@ -23,32 +23,6 @@ NS_ASSUME_NONNULL_BEGIN
}
#pragma clang diagnostic pop
-- (instancetype)initWithAccelerationPedalPosition:(BOOL)accelerationPedalPosition airbagStatus:(BOOL)airbagStatus beltStatus:(BOOL)beltStatus bodyInformation:(BOOL)bodyInformation clusterModeStatus:(BOOL)clusterModeStatus deviceStatus:(BOOL)deviceStatus driverBraking:(BOOL)driverBraking eCallInfo:(BOOL)eCallInfo emergencyEvent:(BOOL)emergencyEvent engineTorque:(BOOL)engineTorque externalTemperature:(BOOL)externalTemperature fuelLevel:(BOOL)fuelLevel fuelLevelState:(BOOL)fuelLevelState gps:(BOOL)gps headLampStatus:(BOOL)headLampStatus instantFuelConsumption:(BOOL)instantFuelConsumption myKey:(BOOL)myKey odometer:(BOOL)odometer prndl:(BOOL)prndl rpm:(BOOL)rpm speed:(BOOL)speed steeringWheelAngle:(BOOL)steeringWheelAngle tirePressure:(BOOL)tirePressure wiperStatus:(BOOL)wiperStatus {
- self = [self initWithGps:@(gps) speed:@(speed) rpm:@(rpm) instantFuelConsumption:@(instantFuelConsumption) fuelRange:nil externalTemperature:@(externalTemperature) turnSignal:nil gearStatus:nil tirePressure:@(tirePressure) odometer:@(odometer) beltStatus:@(beltStatus) bodyInformation:@(bodyInformation) deviceStatus:@(deviceStatus) driverBraking:@(driverBraking) wiperStatus:@(wiperStatus) headLampStatus:@(headLampStatus) engineTorque:@(engineTorque) accPedalPosition:@(accelerationPedalPosition) steeringWheelAngle:@(steeringWheelAngle) engineOilLife:nil electronicParkBrakeStatus:nil cloudAppVehicleID:nil stabilityControlsStatus:nil eCallInfo:@(eCallInfo) airbagStatus:@(airbagStatus) emergencyEvent:@(emergencyEvent) clusterModeStatus:@(clusterModeStatus) myKey:@(myKey) handsOffSteering:nil windowStatus:nil];
- if (self) {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- self.fuelLevel = @(fuelLevel);
- self.fuelLevel_State = @(fuelLevelState);
- self.prndl = @(prndl);
-#pragma clang diagnostic pop
- }
- return self;
-}
-
-- (instancetype)initWithAccelerationPedalPosition:(BOOL)accelerationPedalPosition airbagStatus:(BOOL)airbagStatus beltStatus:(BOOL)beltStatus bodyInformation:(BOOL)bodyInformation clusterModeStatus:(BOOL)clusterModeStatus deviceStatus:(BOOL)deviceStatus driverBraking:(BOOL)driverBraking eCallInfo:(BOOL)eCallInfo electronicParkBrakeStatus:(BOOL)electronicParkBrakeStatus emergencyEvent:(BOOL)emergencyEvent engineOilLife:(BOOL)engineOilLife engineTorque:(BOOL)engineTorque externalTemperature:(BOOL)externalTemperature fuelLevel:(BOOL)fuelLevel fuelLevelState:(BOOL)fuelLevelState fuelRange:(BOOL)fuelRange gps:(BOOL)gps headLampStatus:(BOOL)headLampStatus instantFuelConsumption:(BOOL)instantFuelConsumption myKey:(BOOL)myKey odometer:(BOOL)odometer prndl:(BOOL)prndl rpm:(BOOL)rpm speed:(BOOL)speed steeringWheelAngle:(BOOL)steeringWheelAngle tirePressure:(BOOL)tirePressure turnSignal:(BOOL)turnSignal wiperStatus:(BOOL)wiperStatus {
- self = [self initWithGps:@(gps) speed:@(speed) rpm:@(rpm) instantFuelConsumption:@(instantFuelConsumption) fuelRange:@(fuelRange) externalTemperature:@(externalTemperature) turnSignal:@(turnSignal) gearStatus:nil tirePressure:@(tirePressure) odometer:@(odometer) beltStatus:@(beltStatus) bodyInformation:@(bodyInformation) deviceStatus:@(deviceStatus) driverBraking:@(driverBraking) wiperStatus:@(wiperStatus) headLampStatus:@(headLampStatus) engineTorque:@(engineTorque) accPedalPosition:@(accelerationPedalPosition) steeringWheelAngle:@(steeringWheelAngle) engineOilLife:@(engineOilLife) electronicParkBrakeStatus:@(electronicParkBrakeStatus) cloudAppVehicleID:nil stabilityControlsStatus:nil eCallInfo:@(eCallInfo) airbagStatus:@(airbagStatus) emergencyEvent:@(emergencyEvent) clusterModeStatus:@(clusterModeStatus) myKey:@(myKey) handsOffSteering:nil windowStatus:nil];
- if (self) {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- self.fuelLevel = @(fuelLevel);
- self.fuelLevel_State = @(fuelLevelState);
- self.prndl = @(prndl);
-#pragma clang diagnostic pop
- }
- return self;
-}
-
- (instancetype)initWithAccelerationPedalPosition:(BOOL)accelerationPedalPosition airbagStatus:(BOOL)airbagStatus beltStatus:(BOOL)beltStatus bodyInformation:(BOOL)bodyInformation cloudAppVehicleID:(BOOL)cloudAppVehicleID clusterModeStatus:(BOOL)clusterModeStatus deviceStatus:(BOOL)deviceStatus driverBraking:(BOOL)driverBraking eCallInfo:(BOOL)eCallInfo electronicParkBrakeStatus:(BOOL)electronicParkBrakeStatus emergencyEvent:(BOOL)emergencyEvent engineOilLife:(BOOL)engineOilLife engineTorque:(BOOL)engineTorque externalTemperature:(BOOL)externalTemperature fuelLevel:(BOOL)fuelLevel fuelLevelState:(BOOL)fuelLevelState fuelRange:(BOOL)fuelRange gps:(BOOL)gps headLampStatus:(BOOL)headLampStatus instantFuelConsumption:(BOOL)instantFuelConsumption myKey:(BOOL)myKey odometer:(BOOL)odometer prndl:(BOOL)prndl rpm:(BOOL)rpm speed:(BOOL)speed steeringWheelAngle:(BOOL)steeringWheelAngle tirePressure:(BOOL)tirePressure turnSignal:(BOOL)turnSignal wiperStatus:(BOOL)wiperStatus {
self = [self initWithGps:@(gps) speed:@(speed) rpm:@(rpm) instantFuelConsumption:@(instantFuelConsumption) fuelRange:@(fuelRange) externalTemperature:@(externalTemperature) turnSignal:@(turnSignal) gearStatus:nil tirePressure:@(tirePressure) odometer:@(odometer) beltStatus:@(beltStatus) bodyInformation:@(bodyInformation) deviceStatus:@(deviceStatus) driverBraking:@(driverBraking) wiperStatus:@(wiperStatus) headLampStatus:@(headLampStatus) engineTorque:@(engineTorque) accPedalPosition:@(accelerationPedalPosition) steeringWheelAngle:@(steeringWheelAngle) engineOilLife:@(engineOilLife) electronicParkBrakeStatus:@(electronicParkBrakeStatus) cloudAppVehicleID:@(cloudAppVehicleID) stabilityControlsStatus:nil eCallInfo:@(eCallInfo) airbagStatus:@(airbagStatus) emergencyEvent:@(emergencyEvent) clusterModeStatus:@(clusterModeStatus) myKey:@(myKey) handsOffSteering:nil windowStatus:nil];
if (self) {
diff --git a/SmartDeviceLink/public/SDLUpdateMode.h b/SmartDeviceLink/public/SDLUpdateMode.h
index 03748f3f7..fd9cafb2e 100644
--- a/SmartDeviceLink/public/SDLUpdateMode.h
+++ b/SmartDeviceLink/public/SDLUpdateMode.h
@@ -9,7 +9,7 @@
*
* @since SDL 1.0
*/
-typedef SDLEnum SDLUpdateMode SDL_SWIFT_ENUM;
+typedef SDLEnum SDLUpdateMode NS_TYPED_ENUM;
/**
* Starts the media clock timer counting upward, in increments of 1 second.
diff --git a/SmartDeviceLink/public/SDLVehicleDataActiveStatus.h b/SmartDeviceLink/public/SDLVehicleDataActiveStatus.h
index ceeabd350..bfcb31c5b 100644
--- a/SmartDeviceLink/public/SDLVehicleDataActiveStatus.h
+++ b/SmartDeviceLink/public/SDLVehicleDataActiveStatus.h
@@ -7,7 +7,7 @@
/**
Vehicle Data Activity Status. Used in nothing.
*/
-typedef SDLEnum SDLVehicleDataActiveStatus SDL_SWIFT_ENUM;
+typedef SDLEnum SDLVehicleDataActiveStatus NS_TYPED_ENUM;
/**
Inactive not confirmed
diff --git a/SmartDeviceLink/public/SDLVehicleDataEventStatus.h b/SmartDeviceLink/public/SDLVehicleDataEventStatus.h
index 1c78e2615..7a453e964 100644
--- a/SmartDeviceLink/public/SDLVehicleDataEventStatus.h
+++ b/SmartDeviceLink/public/SDLVehicleDataEventStatus.h
@@ -9,7 +9,7 @@
*
* @since SDL 2.0
*/
-typedef SDLEnum SDLVehicleDataEventStatus SDL_SWIFT_ENUM;
+typedef SDLEnum SDLVehicleDataEventStatus NS_TYPED_ENUM;
/**
No event
diff --git a/SmartDeviceLink/public/SDLVehicleDataNotificationStatus.h b/SmartDeviceLink/public/SDLVehicleDataNotificationStatus.h
index dca5d8466..40e28ab8d 100644
--- a/SmartDeviceLink/public/SDLVehicleDataNotificationStatus.h
+++ b/SmartDeviceLink/public/SDLVehicleDataNotificationStatus.h
@@ -9,7 +9,7 @@
*
* @since SDL 2.0
*/
-typedef SDLEnum SDLVehicleDataNotificationStatus SDL_SWIFT_ENUM;
+typedef SDLEnum SDLVehicleDataNotificationStatus NS_TYPED_ENUM;
/**
The vehicle data notification status is not supported
diff --git a/SmartDeviceLink/public/SDLVehicleDataResultCode.h b/SmartDeviceLink/public/SDLVehicleDataResultCode.h
index c90c5a594..9dd6f730f 100644
--- a/SmartDeviceLink/public/SDLVehicleDataResultCode.h
+++ b/SmartDeviceLink/public/SDLVehicleDataResultCode.h
@@ -7,7 +7,7 @@
/**
Vehicle Data Result Code. Used in DIDResult.
*/
-typedef SDLEnum SDLVehicleDataResultCode SDL_SWIFT_ENUM;
+typedef SDLEnum SDLVehicleDataResultCode NS_TYPED_ENUM;
/**
Individual vehicle data item / DTC / DID request or subscription successful
diff --git a/SmartDeviceLink/public/SDLVehicleDataStatus.h b/SmartDeviceLink/public/SDLVehicleDataStatus.h
index c0f2ffc55..16e32700a 100644
--- a/SmartDeviceLink/public/SDLVehicleDataStatus.h
+++ b/SmartDeviceLink/public/SDLVehicleDataStatus.h
@@ -9,7 +9,7 @@
*
* @since SDL 2.0
*/
-typedef SDLEnum SDLVehicleDataStatus SDL_SWIFT_ENUM;
+typedef SDLEnum SDLVehicleDataStatus NS_TYPED_ENUM;
/**
No data avaliable
diff --git a/SmartDeviceLink/public/SDLVehicleDataType.h b/SmartDeviceLink/public/SDLVehicleDataType.h
index 6084fd015..3426695d0 100644
--- a/SmartDeviceLink/public/SDLVehicleDataType.h
+++ b/SmartDeviceLink/public/SDLVehicleDataType.h
@@ -7,7 +7,7 @@
/**
* Defines the vehicle data types that can be published and/or subscribed to using SDLSubscribeVehicleData. Used in VehicleDataResult
*/
-typedef SDLEnum SDLVehicleDataType SDL_SWIFT_ENUM;
+typedef SDLEnum SDLVehicleDataType NS_TYPED_ENUM;
/**
* Vehicle Gear Status data
diff --git a/SmartDeviceLink/public/SDLVentilationMode.h b/SmartDeviceLink/public/SDLVentilationMode.h
index d3320e27e..ea47c5675 100644
--- a/SmartDeviceLink/public/SDLVentilationMode.h
+++ b/SmartDeviceLink/public/SDLVentilationMode.h
@@ -7,7 +7,7 @@
/**
The ventilation mode. Used in ClimateControlCapabilities
*/
-typedef SDLEnum SDLVentilationMode SDL_SWIFT_ENUM;
+typedef SDLEnum SDLVentilationMode NS_TYPED_ENUM;
/**
The upper ventilation mode
diff --git a/SmartDeviceLink/public/SDLVersion.h b/SmartDeviceLink/public/SDLVersion.h
index 22ff79dc7..1cd50510f 100644
--- a/SmartDeviceLink/public/SDLVersion.h
+++ b/SmartDeviceLink/public/SDLVersion.h
@@ -8,7 +8,6 @@
#import <Foundation/Foundation.h>
-@class SDLSyncMsgVersion;
@class SDLMsgVersion;
NS_ASSUME_NONNULL_BEGIN
@@ -56,21 +55,6 @@ NS_ASSUME_NONNULL_BEGIN
/// @return An SDLVersion object
+ (nullable instancetype)versionWithString:(NSString *)versionString;
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-implementations"
-/// Deprecated convenience init to set version using SDLSyncMsgVersion
-///
-/// @param syncMsgVersion Specifies the version number of the SmartDeviceLink protocol that is supported by the mobile application.
-/// @return An SDLVersion object
-- (instancetype)initWithSyncMsgVersion:(SDLSyncMsgVersion *)syncMsgVersion __deprecated_msg(("Use initWithSDLMsgVersion:sdlMsgVersion: instead"));
-
-/// Deprecated convenience init to set version using SDLSyncMsgVersion
-///
-/// @param syncMsgVersion Specifies the version number of the SmartDeviceLink protocol that is supported by the mobile application.
-/// @return An SDLVersion object
-+ (instancetype)versionWithSyncMsgVersion:(SDLSyncMsgVersion *)syncMsgVersion __deprecated_msg(("Use versionWithSDLMsgVersion:sdlMsgVersion instead"));
-#pragma clang diagnostic pop
-
/// Convenience init to set version using SDLMsgVersion
///
/// @param sdlMsgVersion Specifies the version number of the SmartDeviceLink protocol that is supported by the mobile application.
diff --git a/SmartDeviceLink/public/SDLVersion.m b/SmartDeviceLink/public/SDLVersion.m
index 9ec3e4824..75ddd42f9 100644
--- a/SmartDeviceLink/public/SDLVersion.m
+++ b/SmartDeviceLink/public/SDLVersion.m
@@ -8,7 +8,6 @@
#import "SDLVersion.h"
-#import "SDLSyncMsgVersion.h"
#import "SDLMsgVersion.h"
@@ -63,21 +62,6 @@ NS_ASSUME_NONNULL_BEGIN
return [[self alloc] initWithString:versionString];
}
-- (instancetype)initWithSyncMsgVersion:(SDLSyncMsgVersion *)syncMsgVersion {
- self = [super init];
- if (!self) { return nil; }
-
- _major = syncMsgVersion.majorVersion.unsignedIntegerValue;
- _minor = syncMsgVersion.minorVersion.unsignedIntegerValue;
- _patch = syncMsgVersion.patchVersion.unsignedIntegerValue;
-
- return self;
-}
-
-+ (instancetype)versionWithSyncMsgVersion:(SDLSyncMsgVersion *)syncMsgVersion {
- return [[self alloc] initWithSyncMsgVersion:syncMsgVersion];
-}
-
- (instancetype)initWithSDLMsgVersion:(SDLMsgVersion *)sdlMsgVersion {
self = [super init];
if (!self) { return nil; }
diff --git a/SmartDeviceLink/public/SDLVideoStreamingCapability.h b/SmartDeviceLink/public/SDLVideoStreamingCapability.h
index 17a446821..6a28c30bc 100644
--- a/SmartDeviceLink/public/SDLVideoStreamingCapability.h
+++ b/SmartDeviceLink/public/SDLVideoStreamingCapability.h
@@ -19,17 +19,6 @@ NS_ASSUME_NONNULL_BEGIN
@interface SDLVideoStreamingCapability : SDLRPCStruct
/**
-Convenience init for creating a video streaming capability.
-
-@param preferredResolution The preferred resolution of a video stream for decoding and rendering on HMI
-@param maxBitrate The maximum bitrate of video stream that is supported, in kbps
-@param supportedFormats Detailed information on each format supported by this system, in its preferred order
-@param hapticDataSupported True if the system can utilize the haptic spatial data from the source being streamed
-@return A SDLVideoStreamingCapability object
-*/
-- (instancetype)initWithPreferredResolution:(nullable SDLImageResolution *)preferredResolution maxBitrate:(int32_t)maxBitrate supportedFormats:(nullable NSArray<SDLVideoStreamingFormat *> *)supportedFormats hapticDataSupported:(BOOL)hapticDataSupported __deprecated_msg("Use initWithPreferredResolution:maxBitrate:supportedFormats:hapticDataSupported:diagonalScreenSize:pixelPerInch:scale: instead");
-
-/**
Convenience init for creating a video streaming capability with all parameters.
@param preferredResolution The preferred resolution of a video stream for decoding and rendering on HMI
diff --git a/SmartDeviceLink/public/SDLVideoStreamingCapability.m b/SmartDeviceLink/public/SDLVideoStreamingCapability.m
index 3239f5597..ec4f2c591 100644
--- a/SmartDeviceLink/public/SDLVideoStreamingCapability.m
+++ b/SmartDeviceLink/public/SDLVideoStreamingCapability.m
@@ -17,27 +17,19 @@ NS_ASSUME_NONNULL_BEGIN
@implementation SDLVideoStreamingCapability
-- (instancetype)initWithPreferredResolution:(nullable SDLImageResolution *)preferredResolution maxBitrate:(int32_t)maxBitrate supportedFormats:(nullable NSArray<SDLVideoStreamingFormat *> *)supportedFormats hapticDataSupported:(BOOL)hapticDataSupported {
- return [self initWithPreferredResolution:preferredResolution maxBitrate:@(maxBitrate) supportedFormats:supportedFormats hapticDataSupported:@(hapticDataSupported) diagonalScreenSize:nil ppi:nil scale:nil];
-}
-
- (instancetype)initWithPreferredResolution:(nullable SDLImageResolution *)preferredResolution maxBitrate:(int32_t)maxBitrate supportedFormats:(nullable NSArray<SDLVideoStreamingFormat *> *)supportedFormats hapticDataSupported:(BOOL)hapticDataSupported diagonalScreenSize:(float)diagonalScreenSize pixelPerInch:(float)pixelPerInch scale:(float)scale {
- return [self initWithPreferredResolution:preferredResolution maxBitrate:@(maxBitrate) supportedFormats:supportedFormats hapticDataSupported:@(hapticDataSupported) diagonalScreenSize:@(diagonalScreenSize) ppi:@(pixelPerInch) scale:@(scale)];
-}
-
-- (instancetype)initWithPreferredResolution:(nullable SDLImageResolution *)preferredResolution maxBitrate:(nullable NSNumber *)maxBitrate supportedFormats:(nullable NSArray<SDLVideoStreamingFormat *> *)supportedFormats hapticDataSupported:(nullable NSNumber *)hapticDataSupported diagonalScreenSize:(nullable NSNumber *)diagonalScreenSize ppi:(nullable NSNumber *)pixelPerInch scale:(nullable NSNumber *)scale {
self = [self init];
if (!self) {
return self;
}
- self.maxBitrate = maxBitrate;
+ self.maxBitrate = @(maxBitrate);
self.preferredResolution = preferredResolution;
self.supportedFormats = supportedFormats;
- self.hapticSpatialDataSupported = hapticDataSupported;
- self.diagonalScreenSize = diagonalScreenSize;
- self.pixelPerInch = pixelPerInch;
- self.scale = scale;
+ self.hapticSpatialDataSupported = @(hapticDataSupported);
+ self.diagonalScreenSize = @(diagonalScreenSize);
+ self.pixelPerInch = @(pixelPerInch);
+ self.scale = @(scale);
return self;
}
diff --git a/SmartDeviceLink/public/SDLVideoStreamingCodec.h b/SmartDeviceLink/public/SDLVideoStreamingCodec.h
index b547eaf74..20d9c2a31 100644
--- a/SmartDeviceLink/public/SDLVideoStreamingCodec.h
+++ b/SmartDeviceLink/public/SDLVideoStreamingCodec.h
@@ -8,7 +8,7 @@
/**
* Enum for each type of video streaming codec. Used in VideoStreamingFormat.
*/
-typedef SDLEnum SDLVideoStreamingCodec SDL_SWIFT_ENUM;
+typedef SDLEnum SDLVideoStreamingCodec NS_TYPED_ENUM;
/**
* H264
diff --git a/SmartDeviceLink/public/SDLVideoStreamingProtocol.h b/SmartDeviceLink/public/SDLVideoStreamingProtocol.h
index 1ebcbe9f8..8a285aa80 100644
--- a/SmartDeviceLink/public/SDLVideoStreamingProtocol.h
+++ b/SmartDeviceLink/public/SDLVideoStreamingProtocol.h
@@ -8,7 +8,7 @@
/**
* Enum for each type of video streaming protocol, used in VideoStreamingFormat
*/
-typedef SDLEnum SDLVideoStreamingProtocol SDL_SWIFT_ENUM;
+typedef SDLEnum SDLVideoStreamingProtocol NS_TYPED_ENUM;
/**
* RAW
diff --git a/SmartDeviceLink/public/SDLVideoStreamingState.h b/SmartDeviceLink/public/SDLVideoStreamingState.h
index 6ebe98b72..c09fea875 100644
--- a/SmartDeviceLink/public/SDLVideoStreamingState.h
+++ b/SmartDeviceLink/public/SDLVideoStreamingState.h
@@ -11,7 +11,7 @@
/**
* Enum for each type of video streaming protocol, used in VideoStreamingFormat
*/
-typedef SDLEnum SDLVideoStreamingState SDL_SWIFT_ENUM;
+typedef SDLEnum SDLVideoStreamingState NS_TYPED_ENUM;
/**
* STREAMABLE, the current app is allowed to stream video
diff --git a/SmartDeviceLink/public/SDLVrCapabilities.h b/SmartDeviceLink/public/SDLVrCapabilities.h
index ea4612bea..39ac75da8 100644
--- a/SmartDeviceLink/public/SDLVrCapabilities.h
+++ b/SmartDeviceLink/public/SDLVrCapabilities.h
@@ -9,7 +9,7 @@
*
* @since SDL 1.0
*/
-typedef SDLEnum SDLVRCapabilities SDL_SWIFT_ENUM;
+typedef SDLEnum SDLVRCapabilities NS_TYPED_ENUM;
/**
* The SDL platform is capable of recognizing spoken text in the current language.
diff --git a/SmartDeviceLink/public/SDLWarningLightStatus.h b/SmartDeviceLink/public/SDLWarningLightStatus.h
index f73e898c5..ad7be994c 100644
--- a/SmartDeviceLink/public/SDLWarningLightStatus.h
+++ b/SmartDeviceLink/public/SDLWarningLightStatus.h
@@ -9,7 +9,7 @@
*
* @since SDL 2.0
*/
-typedef SDLEnum SDLWarningLightStatus SDL_SWIFT_ENUM;
+typedef SDLEnum SDLWarningLightStatus NS_TYPED_ENUM;
/**
* The warning light is off
diff --git a/SmartDeviceLink/public/SDLWayPointType.h b/SmartDeviceLink/public/SDLWayPointType.h
index 06b672fac..639c75a7b 100644
--- a/SmartDeviceLink/public/SDLWayPointType.h
+++ b/SmartDeviceLink/public/SDLWayPointType.h
@@ -6,7 +6,7 @@
/**
The type of a navigation waypoint. Used in GetWayPoints.
*/
-typedef SDLEnum SDLWayPointType SDL_SWIFT_ENUM;
+typedef SDLEnum SDLWayPointType NS_TYPED_ENUM;
/**
All other waypoint types
diff --git a/SmartDeviceLink/public/SDLWindowType.h b/SmartDeviceLink/public/SDLWindowType.h
index 5dca1b3c3..7e47e3ad9 100644
--- a/SmartDeviceLink/public/SDLWindowType.h
+++ b/SmartDeviceLink/public/SDLWindowType.h
@@ -8,7 +8,7 @@
@since SDL 6.0
*/
-typedef SDLEnum SDLWindowType SDL_SWIFT_ENUM;
+typedef SDLEnum SDLWindowType NS_TYPED_ENUM;
/**
This window type describes the main window on a display.
diff --git a/SmartDeviceLink/public/SDLWiperStatus.h b/SmartDeviceLink/public/SDLWiperStatus.h
index 05fb748bf..23ddfac7a 100644
--- a/SmartDeviceLink/public/SDLWiperStatus.h
+++ b/SmartDeviceLink/public/SDLWiperStatus.h
@@ -7,7 +7,7 @@
/**
* The status of the windshield wipers. Used in retrieving vehicle data.
*/
-typedef SDLEnum SDLWiperStatus SDL_SWIFT_ENUM;
+typedef SDLEnum SDLWiperStatus NS_TYPED_ENUM;
/**
* Wiper is off
diff --git a/SmartDeviceLinkTests/DevAPISpecs/SDLConfigurationSpec.m b/SmartDeviceLinkTests/DevAPISpecs/SDLConfigurationSpec.m
index 73a973975..1d099305f 100644
--- a/SmartDeviceLinkTests/DevAPISpecs/SDLConfigurationSpec.m
+++ b/SmartDeviceLinkTests/DevAPISpecs/SDLConfigurationSpec.m
@@ -41,19 +41,6 @@ describe(@"a configuration", ^{
someEncryptionConfig = [SDLEncryptionConfiguration defaultConfiguration];
});
- it(@"initWithLifecycle:lockScreen:logging:", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testConfig = [[SDLConfiguration alloc] initWithLifecycle:someLifecycleConfig lockScreen:someLockscreenConfig logging:someLogConfig];
-
- expect(testConfig.lifecycleConfig).to(equal(someLifecycleConfig));
- expect(testConfig.lockScreenConfig).to(equal(someLockscreenConfig));
- expect(testConfig.loggingConfig).to(equal(someLogConfig));
- expect(testConfig.streamingMediaConfig).to(beNil());
- expect(testConfig.fileManagerConfig).toNot(beNil());
- #pragma clang diagnostic pop
- });
-
it(@"initWithLifecycle:lockScreen:logging:fileManager:", ^{
testConfig = [[SDLConfiguration alloc] initWithLifecycle:someLifecycleConfig lockScreen:someLockscreenConfig logging:someLogConfig fileManager:someFileManagerConfig encryption: someEncryptionConfig];
@@ -65,51 +52,12 @@ describe(@"a configuration", ^{
expect(testConfig.encryptionConfig).to(equal(someEncryptionConfig));
});
- it(@"configurationWithLifecycle:lockScreen:logging:", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testConfig = [SDLConfiguration configurationWithLifecycle:someLifecycleConfig lockScreen:someLockscreenConfig logging:someLogConfig];
-
- expect(testConfig.lifecycleConfig).to(equal(someLifecycleConfig));
- expect(testConfig.lockScreenConfig).to(equal(someLockscreenConfig));
- expect(testConfig.loggingConfig).to(equal(someLogConfig));
- expect(testConfig.streamingMediaConfig).to(beNil());
- expect(testConfig.fileManagerConfig).toNot(beNil());
- #pragma clang diagnostic pop
- });
-
- it(@"configurationWithLifecycle:lockScreen:logging:fileManager", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testConfig = [SDLConfiguration configurationWithLifecycle:someLifecycleConfig lockScreen:someLockscreenConfig logging:someLogConfig fileManager:someFileManagerConfig];
- #pragma clang diagnostic pop
-
- expect(testConfig.lifecycleConfig).to(equal(someLifecycleConfig));
- expect(testConfig.lockScreenConfig).to(equal(someLockscreenConfig));
- expect(testConfig.loggingConfig).to(equal(someLogConfig));
- expect(testConfig.streamingMediaConfig).to(beNil());
- expect(testConfig.fileManagerConfig).to(equal(someFileManagerConfig));
- });
-
describe(@"streaming media config", ^{
beforeEach(^{
someLifecycleConfig = [SDLLifecycleConfiguration defaultConfigurationWithAppName:someAppName fullAppId:someAppId];
someLifecycleConfig.appType = SDLAppHMITypeNavigation;
});
- it(@"initWithLifecycle:lockScreen:logging:streamingMedia:", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testConfig = [[SDLConfiguration alloc] initWithLifecycle:someLifecycleConfig lockScreen:someLockscreenConfig logging:someLogConfig streamingMedia:someStreamingConfig];
-
- expect(testConfig.lifecycleConfig).to(equal(someLifecycleConfig));
- expect(testConfig.lockScreenConfig).to(equal(someLockscreenConfig));
- expect(testConfig.loggingConfig).to(equal(someLogConfig));
- expect(testConfig.streamingMediaConfig).to(equal(someStreamingConfig));
- expect(testConfig.fileManagerConfig).toNot(beNil());
- #pragma clang diagnostic pop
- });
-
it(@"initWithLifecycle:lockScreen:logging:streamingMedia:fileManager:", ^{
testConfig = [[SDLConfiguration alloc] initWithLifecycle:someLifecycleConfig lockScreen:someLockscreenConfig logging:someLogConfig streamingMedia:someStreamingConfig fileManager:someFileManagerConfig encryption:[SDLEncryptionConfiguration defaultConfiguration]];
@@ -119,32 +67,6 @@ describe(@"a configuration", ^{
expect(testConfig.streamingMediaConfig).to(equal(someStreamingConfig));
expect(testConfig.fileManagerConfig).to(equal(someFileManagerConfig));
});
-
- it(@"configurationWithLifecycle:lockScreen:logging:streamingMedia:", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testConfig = [SDLConfiguration configurationWithLifecycle:someLifecycleConfig lockScreen:someLockscreenConfig logging:someLogConfig streamingMedia:someStreamingConfig];
-
- expect(testConfig.lifecycleConfig).to(equal(someLifecycleConfig));
- expect(testConfig.lockScreenConfig).to(equal(someLockscreenConfig));
- expect(testConfig.loggingConfig).to(equal(someLogConfig));
- expect(testConfig.streamingMediaConfig).to(equal(someStreamingConfig));
- expect(testConfig.fileManagerConfig).toNot(beNil());
- #pragma clang diagnostic pop
- });
-
- it(@"configurationWithLifecycle:lockScreen:logging:streamingMedia:fileManager:", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testConfig = [SDLConfiguration configurationWithLifecycle:someLifecycleConfig lockScreen:someLockscreenConfig logging:someLogConfig streamingMedia:someStreamingConfig fileManager:someFileManagerConfig];
- #pragma clang diagnostic pop
-
- expect(testConfig.lifecycleConfig).to(equal(someLifecycleConfig));
- expect(testConfig.lockScreenConfig).to(equal(someLockscreenConfig));
- expect(testConfig.loggingConfig).to(equal(someLogConfig));
- expect(testConfig.streamingMediaConfig).to(equal(someStreamingConfig));
- expect(testConfig.fileManagerConfig).to(equal(someFileManagerConfig));
- });
});
});
});
diff --git a/SmartDeviceLinkTests/DevAPISpecs/SDLLifecycleConfigurationSpec.m b/SmartDeviceLinkTests/DevAPISpecs/SDLLifecycleConfigurationSpec.m
index 9f49311f7..da30cb2eb 100644
--- a/SmartDeviceLinkTests/DevAPISpecs/SDLLifecycleConfigurationSpec.m
+++ b/SmartDeviceLinkTests/DevAPISpecs/SDLLifecycleConfigurationSpec.m
@@ -19,7 +19,7 @@
@interface SDLLifecycleConfiguration()
-+ (NSString *)sdlex_shortAppIdFromFullAppId:(NSString *)fullAppId;
++ (NSString *)sdl_shortAppIdFromFullAppId:(NSString *)fullAppId;
@end
@@ -29,9 +29,8 @@ QuickSpecBegin(SDLLifecycleConfigurationSpec)
describe(@"A lifecycle configuration", ^{
__block SDLLifecycleConfiguration *testConfig = nil;
__block NSString *testAppName = @"An App Name";
- __block NSString *testAppId = @"00542596";
- __block NSString *testFullAppId = @"-ab--987-adfa651kj-212346h3kjkaju";
- __block NSString *expectedGeneratedAppId = @"ab987adfa6";
+ __block NSString *testFullAppId = @"123e4567-e89b-12d3-a456-426614174000";
+ __block NSString *expectedGeneratedAppId = @"123e4567e8";
__block SDLVersion *baseVersion = nil;
beforeEach(^{
@@ -41,16 +40,6 @@ describe(@"A lifecycle configuration", ^{
context(@"created with a default configuration", ^{
context(@"should be successfully initialized", ^{
- it(@"defaultConfigurationWithAppName:appId:", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testConfig = [SDLLifecycleConfiguration defaultConfigurationWithAppName:testAppName appId:testAppId];
-
- expect(testConfig.appId).to(match(testAppId));
- expect(testConfig.fullAppId).to(beNil());
- #pragma clang diagnostic pop
- });
-
it(@"defaultConfigurationWithAppName:fullAppId:", ^{
testConfig = [SDLLifecycleConfiguration defaultConfigurationWithAppName:testAppName fullAppId:testFullAppId];
@@ -83,18 +72,20 @@ describe(@"A lifecycle configuration", ^{
__block NSArray<SDLTTSChunk *> *testTTSName = nil;
__block NSArray<NSString *> *testSynonyms = nil;
__block NSString *testResumeHashString = nil;
+ __block NSString *testAppId = nil;
beforeEach(^{
- testConfig = [SDLLifecycleConfiguration defaultConfigurationWithAppName:testAppName fullAppId:testFullAppId];
- });
-
- it(@"it should get and set correctly", ^{
testShortAppName = @"Short Name";
testTTSChunk = [[SDLTTSChunk alloc] initWithText:@"test tts name" type:SDLSpeechCapabilitiesText];
testTTSName = @[testTTSChunk];
testSynonyms = @[@"Test 1", @"Test 2", @"Test 3", @"Test 4"];
testResumeHashString = @"testing";
+ testAppId = @"pppppppppppppppppppppppppppppppppppppppppp";
+
+ testConfig = [SDLLifecycleConfiguration defaultConfigurationWithAppName:testAppName fullAppId:testFullAppId];
+ });
+ it(@"it should get and set correctly", ^{
testConfig.appType = SDLAppHMITypeMedia;
testConfig.additionalAppTypes = @[SDLAppHMITypeProjection];
testConfig.language = SDLLanguageArSa;
@@ -105,13 +96,14 @@ describe(@"A lifecycle configuration", ^{
testConfig.resumeHash = testResumeHashString;
testConfig.minimumProtocolVersion = [SDLVersion versionWithString:@"1.0.0"];
testConfig.minimumRPCVersion = [SDLVersion versionWithString:@"2.0.0"];
+ testConfig.appId = testAppId;
});
afterEach(^{
expect(testConfig.appName).to(match(testAppName));
expect(testConfig.shortAppName).to(match(testShortAppName));
expect(testConfig.fullAppId).to(match(testFullAppId));
- expect(testConfig.appId).to(match(expectedGeneratedAppId));
+ expect(testConfig.appId).to(match(testAppId));
expect(testConfig.tcpDebugMode).to(beFalse());
expect(testConfig.tcpDebugIPAddress).to(match(@"192.168.0.1"));
expect(@(testConfig.tcpDebugPort)).to(equal(@12345));
@@ -140,16 +132,6 @@ describe(@"A lifecycle configuration", ^{
});
context(@"should be successfully initialized", ^{
- it(@"debugConfigurationWithAppName:appId:ipAddress:port:", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testConfig = [SDLLifecycleConfiguration debugConfigurationWithAppName:testAppName appId:testAppId ipAddress:testIPAddress port:testPort];
-
- expect(testConfig.appId).to(match(testAppId));
- expect(testConfig.fullAppId).to(beNil());
- #pragma clang diagnostic pop
- });
-
it(@"debugConfigurationWithAppName:fullAppId:ipAddress:port:", ^{
testConfig = [SDLLifecycleConfiguration debugConfigurationWithAppName:testAppName fullAppId:testFullAppId ipAddress:testIPAddress port:testPort];
@@ -182,6 +164,7 @@ describe(@"A lifecycle configuration", ^{
__block NSArray<NSString *> *testSynonyms = nil;
__block NSString *testResumeHashString = nil;
__block SDLVersion *testVersion = nil;
+ __block NSString *testAppId = nil;
beforeEach(^{
testConfig = [SDLLifecycleConfiguration debugConfigurationWithAppName:testAppName fullAppId:testFullAppId ipAddress:testIPAddress port:testPort];
@@ -194,6 +177,7 @@ describe(@"A lifecycle configuration", ^{
testSynonyms = @[@"Test 1", @"Test 2", @"Test 3", @"Test 4"];
testResumeHashString = @"testing";
testVersion = [SDLVersion versionWithMajor:1 minor:0 patch:0];
+ testAppId = @"p&4rrqwervw-jolmk";
testConfig.appType = SDLAppHMITypeInformation;
testConfig.additionalAppTypes = @[SDLAppHMITypeProjection];
@@ -205,13 +189,14 @@ describe(@"A lifecycle configuration", ^{
testConfig.resumeHash = testResumeHashString;
testConfig.minimumRPCVersion = testVersion;
testConfig.minimumProtocolVersion = testVersion;
+ testConfig.appId = testAppId;
});
afterEach(^{
expect(testConfig.appName).to(match(testAppName));
expect(testConfig.shortAppName).to(match(testShortAppName));
expect(testConfig.fullAppId).to(match(testFullAppId));
- expect(testConfig.appId).to(match(expectedGeneratedAppId));
+ expect(testConfig.appId).to(match(testAppId));
expect(testConfig.tcpDebugMode).to(beTrue());
expect(testConfig.tcpDebugIPAddress).to(match(@"1.1.1.1"));
expect(@(testConfig.tcpDebugPort)).to(equal(@42));
@@ -232,34 +217,28 @@ describe(@"A lifecycle configuration", ^{
});
describe(@"When generating the `appId` from the `fullAppId`", ^{
- it(@"should return nil if full app id is nil", ^{
- NSString *testFullAppId = nil;
- NSString *appId = [SDLLifecycleConfiguration sdlex_shortAppIdFromFullAppId:testFullAppId];
- expect(appId).to(beNil());
- });
-
it(@"should return an empty string if the full app id is empty", ^{
NSString *testFullAppId = @"";
- NSString *appId = [SDLLifecycleConfiguration sdlex_shortAppIdFromFullAppId:testFullAppId];
+ NSString *appId = [SDLLifecycleConfiguration sdl_shortAppIdFromFullAppId:testFullAppId];
+ expect(appId).to(beEmpty());
+ });
+
+ it(@"should return an empty string if the full app id only has dashes", ^{
+ NSString *testFullAppId = @"--";
+ NSString *appId = [SDLLifecycleConfiguration sdl_shortAppIdFromFullAppId:testFullAppId];
expect(appId).to(beEmpty());
});
it(@"should return a string truncated to the first non-dash 10 characters", ^{
NSString *testFullAppId = @"34-uipe--k-rtqwedeftg-1";
- NSString *appId = [SDLLifecycleConfiguration sdlex_shortAppIdFromFullAppId:testFullAppId];
+ NSString *appId = [SDLLifecycleConfiguration sdl_shortAppIdFromFullAppId:testFullAppId];
expect(appId).to(match(@"34uipekrtq"));
});
- it(@"should return a string if the full app id is less than 10 characters", ^{
- NSString *testFullAppId = @"a";
- NSString *appId = [SDLLifecycleConfiguration sdlex_shortAppIdFromFullAppId:testFullAppId];
- expect(appId).to(match(@"a"));
- });
-
- it(@"should return an empty string if the full app id only has dash characters", ^{
- NSString *testFullAppId = @"-";
- NSString *appId = [SDLLifecycleConfiguration sdlex_shortAppIdFromFullAppId:testFullAppId];
- expect(appId).to(beEmpty());
+ it(@"should return the full app id if the full app id is less than 10 characters", ^{
+ NSString *testFullAppId = @"ab";
+ NSString *appId = [SDLLifecycleConfiguration sdl_shortAppIdFromFullAppId:testFullAppId];
+ expect(appId).to(equal(testFullAppId));
});
});
diff --git a/SmartDeviceLinkTests/DevAPISpecs/SDLLifecycleManagerSpec.m b/SmartDeviceLinkTests/DevAPISpecs/SDLLifecycleManagerSpec.m
index 55bc7336f..dfba05a0e 100644
--- a/SmartDeviceLinkTests/DevAPISpecs/SDLLifecycleManagerSpec.m
+++ b/SmartDeviceLinkTests/DevAPISpecs/SDLLifecycleManagerSpec.m
@@ -5,9 +5,12 @@
#import "SDLLifecycleManager.h"
#import "SDLAppServiceData.h"
+#import "SDLChangeRegistration.h"
#import "SDLConfiguration.h"
#import "SDLConnectionManagerType.h"
+#import "SDLEncryptionConfiguration.h"
#import "SDLError.h"
+#import "SDLFileManagerConfiguration.h"
#import "SDLFileManager.h"
#import "SDLGlobals.h"
#import "SDLHMILevel.h"
@@ -120,11 +123,11 @@ describe(@"a lifecycle manager", ^{
};
beforeEach(^{
- SDLLifecycleConfiguration *testLifecycleConfig = [SDLLifecycleConfiguration defaultConfigurationWithAppName:@"Test App" appId:@"Test Id"];
+ SDLLifecycleConfiguration *testLifecycleConfig = [SDLLifecycleConfiguration defaultConfigurationWithAppName:@"Test App" fullAppId:@"TestFullAppID"];
testLifecycleConfig.shortAppName = @"Short Name";
testLifecycleConfig.appType = SDLAppHMITypeNavigation;
- testConfig = [SDLConfiguration configurationWithLifecycle:testLifecycleConfig lockScreen:[SDLLockScreenConfiguration disabledConfiguration] logging:[SDLLogConfiguration defaultConfiguration] streamingMedia:[SDLStreamingMediaConfiguration insecureConfiguration]];
+ testConfig = [[SDLConfiguration alloc] initWithLifecycle:testLifecycleConfig lockScreen:[SDLLockScreenConfiguration disabledConfiguration] logging:[SDLLogConfiguration defaultConfiguration] streamingMedia:[SDLStreamingMediaConfiguration insecureConfiguration] fileManager:[SDLFileManagerConfiguration defaultConfiguration] encryption:[SDLEncryptionConfiguration defaultConfiguration]];
testConfig.lifecycleConfig.languagesSupported = @[SDLLanguageEnUs, SDLLanguageEnGb];
testConfig.lifecycleConfig.language = SDLLanguageEnUs;
testConfig.lifecycleConfig.minimumProtocolVersion = [SDLVersion versionWithMajor:2 minor:0 patch:0];
@@ -433,137 +436,103 @@ describe(@"a lifecycle manager", ^{
});
context(@"when the register response returns different language than the one passed with the lifecycle configuration", ^{
- context(@"using the deprecated delegate method", ^{
- __block TestOldConfigurationUpdateManagerDelegate *oldDelegate = nil;
- beforeEach(^{
- oldDelegate = OCMClassMock([TestOldConfigurationUpdateManagerDelegate class]);
- testManager.delegate = oldDelegate;
- });
-
- it(@"should should update the configuration when the app supports the head unit language", ^{
- SDLRegisterAppInterfaceResponse *registerAppInterfaceResponse = [[SDLRegisterAppInterfaceResponse alloc] init];
- registerAppInterfaceResponse.success = @YES;
- registerAppInterfaceResponse.resultCode = SDLResultWrongLanguage;
- registerAppInterfaceResponse.info = @"Language mismatch";
- registerAppInterfaceResponse.language = SDLLanguageEnGb;
- registerAppInterfaceResponse.hmiDisplayLanguage = SDLLanguageEnGb;
- testManager.registerResponse = registerAppInterfaceResponse;
-
- SDLLifecycleConfigurationUpdate *update = [[SDLLifecycleConfigurationUpdate alloc] initWithAppName:@"EnGb" shortAppName:@"E" ttsName:[SDLTTSChunk textChunksFromString:@"EnGb ttsName"] voiceRecognitionCommandNames:nil];
- OCMStub([testManager.delegate managerShouldUpdateLifecycleToLanguage:[OCMArg any]]).andReturn(update);
-
- setToStateWithEnterTransition(SDLLifecycleStateRegistered, SDLLifecycleStateUpdatingConfiguration);
- // Transition to StateSettingUpManagers to prevent assert error from the lifecycle machine
- [testManager.lifecycleStateMachine setToState:SDLLifecycleStateSettingUpManagers fromOldState:SDLLifecycleStateUpdatingConfiguration callEnterTransition:NO];
-
- expect(testManager.configuration.lifecycleConfig.language).toEventually(equal(SDLLanguageEnGb));
- expect(testManager.configuration.lifecycleConfig.appName).toEventually(equal(@"EnGb"));
- expect(testManager.configuration.lifecycleConfig.shortAppName).toEventually(equal(@"E"));
- expect(testManager.configuration.lifecycleConfig.ttsName).toEventually(equal([SDLTTSChunk textChunksFromString:@"EnGb ttsName"]));
-
- OCMVerify([testManager.delegate managerShouldUpdateLifecycleToLanguage:[OCMArg any]]);
- });
-
- it(@"should not update the configuration when the app does not support the head unit language", ^{
- SDLRegisterAppInterfaceResponse *registerAppInterfaceResponse = [[SDLRegisterAppInterfaceResponse alloc] init];
- registerAppInterfaceResponse.success = @YES;
- registerAppInterfaceResponse.resultCode = SDLResultWrongLanguage;
- registerAppInterfaceResponse.info = @"Language mismatch";
- registerAppInterfaceResponse.language = SDLLanguageDeDe;
- registerAppInterfaceResponse.hmiDisplayLanguage = SDLLanguageDeDe;
- testManager.registerResponse = registerAppInterfaceResponse;
-
- OCMStub([testManager.delegate managerShouldUpdateLifecycleToLanguage:[OCMArg any]]).andReturn(nil);
-
- setToStateWithEnterTransition(SDLLifecycleStateRegistered, SDLLifecycleStateUpdatingConfiguration);
- // Transition to StateSettingUpManagers to prevent assert error from the lifecycle machine
- [testManager.lifecycleStateMachine setToState:SDLLifecycleStateSettingUpManagers fromOldState:SDLLifecycleStateUpdatingConfiguration callEnterTransition:NO];
-
- expect(testManager.configuration.lifecycleConfig.language).toEventually(equal(SDLLanguageEnUs));
- expect(testManager.configuration.lifecycleConfig.appName).toEventually(equal(@"Test App"));
- expect(testManager.configuration.lifecycleConfig.shortAppName).toEventually(equal(@"Short Name"));
- expect(testManager.configuration.lifecycleConfig.ttsName).toEventually(beNil());
-
- OCMVerify([testManager.delegate managerShouldUpdateLifecycleToLanguage:[OCMArg any]]);
- });
+ __block TestNewConfigurationUpdateManagerDelegate *newDelegate = nil;
+ beforeEach(^{
+ newDelegate = OCMClassMock([TestNewConfigurationUpdateManagerDelegate class]);
+ testManager.delegate = newDelegate;
});
- context(@"using the updated delegate method", ^{
- __block TestNewConfigurationUpdateManagerDelegate *newDelegate = nil;
- beforeEach(^{
- newDelegate = OCMClassMock([TestNewConfigurationUpdateManagerDelegate class]);
- testManager.delegate = newDelegate;
- });
-
- it(@"should should update the configuration when the app supports the head unit language", ^{
- SDLRegisterAppInterfaceResponse *registerAppInterfaceResponse = [[SDLRegisterAppInterfaceResponse alloc] init];
- registerAppInterfaceResponse.success = @YES;
- registerAppInterfaceResponse.resultCode = SDLResultWrongLanguage;
- registerAppInterfaceResponse.info = @"Language mismatch";
- registerAppInterfaceResponse.language = SDLLanguageEnGb;
- registerAppInterfaceResponse.hmiDisplayLanguage = SDLLanguageEnGb;
- testManager.registerResponse = registerAppInterfaceResponse;
-
- SDLLifecycleConfigurationUpdate *update = [[SDLLifecycleConfigurationUpdate alloc] initWithAppName:@"EnGb" shortAppName:@"E" ttsName:[SDLTTSChunk textChunksFromString:@"EnGb ttsName"] voiceRecognitionCommandNames:nil];
- OCMStub([testManager.delegate managerShouldUpdateLifecycleToLanguage:[OCMArg any] hmiLanguage:[OCMArg any]]).andReturn(update);
-
- setToStateWithEnterTransition(SDLLifecycleStateRegistered, SDLLifecycleStateUpdatingConfiguration);
- // Transition to StateSettingUpManagers to prevent assert error from the lifecycle machine
- [testManager.lifecycleStateMachine setToState:SDLLifecycleStateSettingUpManagers fromOldState:SDLLifecycleStateUpdatingConfiguration callEnterTransition:NO];
-
- expect(testManager.configuration.lifecycleConfig.language).toEventually(equal(SDLLanguageEnGb));
- expect(testManager.configuration.lifecycleConfig.appName).toEventually(equal(@"EnGb"));
- expect(testManager.configuration.lifecycleConfig.shortAppName).toEventually(equal(@"E"));
- expect(testManager.configuration.lifecycleConfig.ttsName).toEventually(equal([SDLTTSChunk textChunksFromString:@"EnGb ttsName"]));
-
- OCMVerify([testManager.delegate managerShouldUpdateLifecycleToLanguage:[OCMArg any] hmiLanguage:[OCMArg any]]);
- });
-
- it(@"should not update the configuration when the app does not support the head unit language", ^{
- SDLRegisterAppInterfaceResponse *registerAppInterfaceResponse = [[SDLRegisterAppInterfaceResponse alloc] init];
- registerAppInterfaceResponse.success = @YES;
- registerAppInterfaceResponse.resultCode = SDLResultWrongLanguage;
- registerAppInterfaceResponse.info = @"Language mismatch";
- registerAppInterfaceResponse.language = SDLLanguageDeDe;
- registerAppInterfaceResponse.hmiDisplayLanguage = SDLLanguageDeDe;
- testManager.registerResponse = registerAppInterfaceResponse;
-
- OCMStub([testManager.delegate managerShouldUpdateLifecycleToLanguage:[OCMArg any] hmiLanguage:[OCMArg any]]).andReturn(nil);
-
- setToStateWithEnterTransition(SDLLifecycleStateRegistered, SDLLifecycleStateUpdatingConfiguration);
- // Transition to StateSettingUpManagers to prevent assert error from the lifecycle machine
- [testManager.lifecycleStateMachine setToState:SDLLifecycleStateSettingUpManagers fromOldState:SDLLifecycleStateUpdatingConfiguration callEnterTransition:NO];
+ it(@"should should update the configuration when the app supports the head unit language", ^{
+ SDLRegisterAppInterfaceResponse *registerAppInterfaceResponse = [[SDLRegisterAppInterfaceResponse alloc] init];
+ registerAppInterfaceResponse.success = @YES;
+ registerAppInterfaceResponse.resultCode = SDLResultWrongLanguage;
+ registerAppInterfaceResponse.info = @"Language mismatch";
+ registerAppInterfaceResponse.language = SDLLanguageEnGb;
+ registerAppInterfaceResponse.hmiDisplayLanguage = SDLLanguageEnGb;
+ testManager.registerResponse = registerAppInterfaceResponse;
+
+ SDLLifecycleConfigurationUpdate *update = [[SDLLifecycleConfigurationUpdate alloc] initWithAppName:@"EnGb" shortAppName:@"E" ttsName:[SDLTTSChunk textChunksFromString:@"EnGb ttsName"] voiceRecognitionCommandNames:@[@"EnGb", @"Gb"]];
+ OCMStub([testManager.delegate managerShouldUpdateLifecycleToLanguage:[OCMArg any] hmiLanguage:[OCMArg any]]).andReturn(update);
+
+ OCMExpect([protocolMock sendRPC:[OCMArg checkWithBlock:^BOOL(id value) {
+ SDLChangeRegistration *changeRegistration = (SDLChangeRegistration *)value;
+ expect(changeRegistration.appName).to(equal(update.appName));
+ expect(changeRegistration.ngnMediaScreenAppName).to(equal(update.shortAppName));
+ expect(changeRegistration.ttsName).to(equal(update.ttsName));
+ expect(changeRegistration.vrSynonyms).to(equal(@[@"EnGb", @"Gb"]));
+ return [value isKindOfClass:[SDLChangeRegistration class]];
+ }]]);
+
+ setToStateWithEnterTransition(SDLLifecycleStateRegistered, SDLLifecycleStateUpdatingConfiguration);
+ // Transition to StateSettingUpManagers to prevent assert error from the lifecycle machine
+ [testManager.lifecycleStateMachine setToState:SDLLifecycleStateSettingUpManagers fromOldState:SDLLifecycleStateUpdatingConfiguration callEnterTransition:NO];
+
+ expect(testManager.configuration.lifecycleConfig.language).toEventually(equal(SDLLanguageEnGb));
+ expect(testManager.currentVRLanguage).toEventually(equal(SDLLanguageEnGb));
+ expect(testManager.configuration.lifecycleConfig.appName).toEventually(equal(@"EnGb"));
+ expect(testManager.configuration.lifecycleConfig.shortAppName).toEventually(equal(@"E"));
+ expect(testManager.configuration.lifecycleConfig.ttsName).toEventually(equal([SDLTTSChunk textChunksFromString:@"EnGb ttsName"]));
+
+ OCMVerify([testManager.delegate managerShouldUpdateLifecycleToLanguage:[OCMArg any] hmiLanguage:[OCMArg any]]);
+ OCMVerifyAll(protocolMock);
+ });
- expect(testManager.configuration.lifecycleConfig.language).toEventually(equal(SDLLanguageEnUs));
- expect(testManager.configuration.lifecycleConfig.appName).toEventually(equal(@"Test App"));
- expect(testManager.configuration.lifecycleConfig.shortAppName).toEventually(equal(@"Short Name"));
- expect(testManager.configuration.lifecycleConfig.ttsName).toEventually(beNil());
+ it(@"should not update the configuration when the app does not support the head unit language or display language", ^{
+ SDLRegisterAppInterfaceResponse *registerAppInterfaceResponse = [[SDLRegisterAppInterfaceResponse alloc] init];
+ registerAppInterfaceResponse.success = @YES;
+ registerAppInterfaceResponse.resultCode = SDLResultWrongLanguage;
+ registerAppInterfaceResponse.info = @"Language mismatch";
+ registerAppInterfaceResponse.language = SDLLanguageDeDe;
+ registerAppInterfaceResponse.hmiDisplayLanguage = SDLLanguageDeDe;
+ testManager.registerResponse = registerAppInterfaceResponse;
- OCMVerify([testManager.delegate managerShouldUpdateLifecycleToLanguage:[OCMArg any] hmiLanguage:[OCMArg any]]);
- });
+ OCMStub([testManager.delegate managerShouldUpdateLifecycleToLanguage:[OCMArg any] hmiLanguage:[OCMArg any]]).andReturn(nil);
- it(@"should update if the hmi display language changes", ^{
- SDLRegisterAppInterfaceResponse *registerAppInterfaceResponse = [[SDLRegisterAppInterfaceResponse alloc] init];
- registerAppInterfaceResponse.success = @YES;
- registerAppInterfaceResponse.resultCode = SDLResultWrongLanguage;
- registerAppInterfaceResponse.info = @"Language mismatch";
- registerAppInterfaceResponse.language = SDLLanguageEnUs;
- registerAppInterfaceResponse.hmiDisplayLanguage = SDLLanguageEnGb;
- testManager.registerResponse = registerAppInterfaceResponse;
+ setToStateWithEnterTransition(SDLLifecycleStateRegistered, SDLLifecycleStateUpdatingConfiguration);
+ // Transition to StateSettingUpManagers to prevent assert error from the lifecycle machine
+ [testManager.lifecycleStateMachine setToState:SDLLifecycleStateSettingUpManagers fromOldState:SDLLifecycleStateUpdatingConfiguration callEnterTransition:NO];
- OCMStub([testManager.delegate managerShouldUpdateLifecycleToLanguage:[OCMArg any] hmiLanguage:[OCMArg any]]).andReturn(nil);
+ expect(testManager.configuration.lifecycleConfig.language).toEventually(equal(SDLLanguageEnUs));
+ expect(testManager.currentVRLanguage).toEventually(equal(SDLLanguageEnUs));
+ expect(testManager.configuration.lifecycleConfig.appName).toEventually(equal(@"Test App"));
+ expect(testManager.configuration.lifecycleConfig.shortAppName).toEventually(equal(@"Short Name"));
+ expect(testManager.configuration.lifecycleConfig.ttsName).toEventually(beNil());
- setToStateWithEnterTransition(SDLLifecycleStateRegistered, SDLLifecycleStateUpdatingConfiguration);
- // Transition to StateSettingUpManagers to prevent assert error from the lifecycle machine
- [testManager.lifecycleStateMachine setToState:SDLLifecycleStateSettingUpManagers fromOldState:SDLLifecycleStateUpdatingConfiguration callEnterTransition:NO];
-
- expect(testManager.configuration.lifecycleConfig.language).toEventually(equal(SDLLanguageEnUs));
- expect(testManager.configuration.lifecycleConfig.appName).toEventually(equal(@"Test App"));
- expect(testManager.configuration.lifecycleConfig.shortAppName).toEventually(equal(@"Short Name"));
- expect(testManager.configuration.lifecycleConfig.ttsName).toEventually(beNil());
+ OCMVerify([testManager.delegate managerShouldUpdateLifecycleToLanguage:[OCMArg any] hmiLanguage:[OCMArg any]]);
+ });
- OCMVerify([testManager.delegate managerShouldUpdateLifecycleToLanguage:[OCMArg any] hmiLanguage:[OCMArg any]]);
- });
+ it(@"should update when the app supports the head unit display language", ^{
+ SDLRegisterAppInterfaceResponse *registerAppInterfaceResponse = [[SDLRegisterAppInterfaceResponse alloc] init];
+ registerAppInterfaceResponse.success = @YES;
+ registerAppInterfaceResponse.resultCode = SDLResultWrongLanguage;
+ registerAppInterfaceResponse.info = @"Language mismatch";
+ registerAppInterfaceResponse.language = SDLLanguageEnUs;
+ registerAppInterfaceResponse.hmiDisplayLanguage = SDLLanguageEnGb;
+ testManager.registerResponse = registerAppInterfaceResponse;
+
+ SDLLifecycleConfigurationUpdate *update = [[SDLLifecycleConfigurationUpdate alloc] initWithAppName:@"EnGb" shortAppName:@"Gb" ttsName:nil voiceRecognitionCommandNames:nil];
+ OCMStub([testManager.delegate managerShouldUpdateLifecycleToLanguage:registerAppInterfaceResponse.language hmiLanguage:registerAppInterfaceResponse.hmiDisplayLanguage]).andReturn(update);
+
+ OCMExpect([protocolMock sendRPC:[OCMArg checkWithBlock:^BOOL(id value) {
+ SDLChangeRegistration *changeRegistration = (SDLChangeRegistration *)value;
+ expect(changeRegistration.appName).to(equal(update.appName));
+ expect(changeRegistration.ngnMediaScreenAppName).to(equal(update.shortAppName));
+ expect(changeRegistration.ttsName).to(beNil());
+ expect(changeRegistration.vrSynonyms).to(beNil());
+ return [value isKindOfClass:[SDLChangeRegistration class]];
+ }]]);
+
+ setToStateWithEnterTransition(SDLLifecycleStateRegistered, SDLLifecycleStateUpdatingConfiguration);
+ // Transition to StateSettingUpManagers to prevent assert error from the lifecycle machine
+ [testManager.lifecycleStateMachine setToState:SDLLifecycleStateSettingUpManagers fromOldState:SDLLifecycleStateUpdatingConfiguration callEnterTransition:NO];
+
+ expect(testManager.configuration.lifecycleConfig.language).toEventually(equal(SDLLanguageEnGb));
+ expect(testManager.currentVRLanguage).toEventually(equal(SDLLanguageEnUs));
+ expect(testManager.configuration.lifecycleConfig.appName).toEventually(equal(@"EnGb"));
+ expect(testManager.configuration.lifecycleConfig.shortAppName).toEventually(equal(@"Gb"));
+ expect(testManager.configuration.lifecycleConfig.ttsName).toEventually(beNil());
+
+ OCMVerify([testManager.delegate managerShouldUpdateLifecycleToLanguage:[OCMArg any] hmiLanguage:[OCMArg any]]);
});
});
});
@@ -803,7 +772,7 @@ describe(@"a lifecycle manager", ^{
context(@"if secondary transport is not allowed", ^{
beforeEach(^{
lifecycleConfig.allowedSecondaryTransports = SDLSecondaryTransportsNone;
- SDLConfiguration *config = [[SDLConfiguration alloc] initWithLifecycle:lifecycleConfig lockScreen:nil logging:nil fileManager:nil];
+ SDLConfiguration *config = [[SDLConfiguration alloc] initWithLifecycle:lifecycleConfig lockScreen:[SDLLockScreenConfiguration disabledConfiguration] logging:[SDLLogConfiguration defaultConfiguration] fileManager:[SDLFileManagerConfiguration defaultConfiguration] encryption:[SDLEncryptionConfiguration defaultConfiguration]];
testManager = [[SDLLifecycleManager alloc] initWithConfiguration:config delegate:nil];
[testManager.lifecycleStateMachine setToState:SDLLifecycleStateStarted fromOldState:nil callEnterTransition:YES];
});
@@ -817,7 +786,7 @@ describe(@"a lifecycle manager", ^{
beforeEach(^{
lifecycleConfig.allowedSecondaryTransports = SDLSecondaryTransportsTCP;
lifecycleConfig.appType = SDLAppHMITypeSocial;
- SDLConfiguration *config = [[SDLConfiguration alloc] initWithLifecycle:lifecycleConfig lockScreen:nil logging:nil fileManager:nil];
+ SDLConfiguration *config = [[SDLConfiguration alloc] initWithLifecycle:lifecycleConfig lockScreen:[SDLLockScreenConfiguration disabledConfiguration] logging:[SDLLogConfiguration defaultConfiguration] fileManager:[SDLFileManagerConfiguration defaultConfiguration] encryption:[SDLEncryptionConfiguration defaultConfiguration]];
testManager = [[SDLLifecycleManager alloc] initWithConfiguration:config delegate:nil];
[testManager.lifecycleStateMachine setToState:SDLLifecycleStateStarted fromOldState:nil callEnterTransition:YES];
});
@@ -831,7 +800,7 @@ describe(@"a lifecycle manager", ^{
beforeEach(^{
lifecycleConfig.allowedSecondaryTransports = SDLSecondaryTransportsTCP;
lifecycleConfig.appType = SDLAppHMITypeProjection;
- SDLConfiguration *config = [[SDLConfiguration alloc] initWithLifecycle:lifecycleConfig lockScreen:nil logging:nil streamingMedia:SDLStreamingMediaConfiguration.insecureConfiguration fileManager:nil];
+ SDLConfiguration *config = [[SDLConfiguration alloc] initWithLifecycle:lifecycleConfig lockScreen:[SDLLockScreenConfiguration disabledConfiguration] logging:[SDLLogConfiguration defaultConfiguration] streamingMedia:[SDLStreamingMediaConfiguration insecureConfiguration] fileManager:[SDLFileManagerConfiguration defaultConfiguration] encryption:[SDLEncryptionConfiguration defaultConfiguration]];
testManager = [[SDLLifecycleManager alloc] initWithConfiguration:config delegate:nil];
[testManager.lifecycleStateMachine setToState:SDLLifecycleStateStarted fromOldState:nil callEnterTransition:YES];
diff --git a/SmartDeviceLinkTests/DevAPISpecs/SDLLifecycleSystemRequestHandlerSpec.m b/SmartDeviceLinkTests/DevAPISpecs/SDLLifecycleSystemRequestHandlerSpec.m
index 01211e324..a722b218f 100644
--- a/SmartDeviceLinkTests/DevAPISpecs/SDLLifecycleSystemRequestHandlerSpec.m
+++ b/SmartDeviceLinkTests/DevAPISpecs/SDLLifecycleSystemRequestHandlerSpec.m
@@ -202,7 +202,7 @@ describe(@"SDLLifecycleSystemRequestHandler tests", ^{
OCMStub([mockedApplication sharedApplication]).andReturn(mockedApplication);
OCMExpect([mockedApplication openURL:[OCMArg checkWithBlock:^BOOL(id obj) {
return [((NSURL *)obj).absoluteString isEqualToString:@"myApp://"];
- }]]);
+ }] options:@{} completionHandler:nil]);
SDLRPCNotificationNotification *notification = [[SDLRPCNotificationNotification alloc] initWithName:SDLDidReceiveSystemRequestNotification object:nil rpcNotification:receivedSystemRequest];
[[NSNotificationCenter defaultCenter] postNotification:notification];
diff --git a/SmartDeviceLinkTests/DevAPISpecs/SDLLockScreenConfigurationSpec.m b/SmartDeviceLinkTests/DevAPISpecs/SDLLockScreenConfigurationSpec.m
index 2963efb96..f95c90e71 100644
--- a/SmartDeviceLinkTests/DevAPISpecs/SDLLockScreenConfigurationSpec.m
+++ b/SmartDeviceLinkTests/DevAPISpecs/SDLLockScreenConfigurationSpec.m
@@ -14,11 +14,6 @@ describe(@"a lock screen configuration", ^{
});
it(@"should properly set properties", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testConfig.enableAutomaticLockScreen).to(beFalse());
- expect(testConfig.showInOptionalState).to(beFalse());
-#pragma clang diagnostic pop
expect(testConfig.enableDismissGesture).to(beFalse());
expect(testConfig.showDeviceLogo).to(beFalse());
expect(testConfig.backgroundColor).to(equal([UIColor colorWithRed:(57.0/255.0) green:(78.0/255.0) blue:(96.0/255.0) alpha:1.0]));
@@ -33,11 +28,6 @@ describe(@"a lock screen configuration", ^{
});
it(@"should properly set properties", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testConfig.enableAutomaticLockScreen).to(beTrue());
- expect(testConfig.showInOptionalState).to(beFalse());
-#pragma clang diagnostic pop
expect(testConfig.enableDismissGesture).to(beTrue());
expect(testConfig.showDeviceLogo).to(beTrue());
expect(testConfig.backgroundColor).to(equal([UIColor colorWithRed:(57.0/255.0) green:(78.0/255.0) blue:(96.0/255.0) alpha:1.0]));
@@ -58,11 +48,6 @@ describe(@"a lock screen configuration", ^{
});
it(@"should properly set properties", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testConfig.enableAutomaticLockScreen).to(beTrue());
- expect(testConfig.showInOptionalState).to(beFalse());
-#pragma clang diagnostic pop
expect(testConfig.enableDismissGesture).to(beTrue());
expect(testConfig.showDeviceLogo).to(beTrue());
expect(testConfig.backgroundColor).to(equal([UIColor blueColor]));
@@ -81,11 +66,6 @@ describe(@"a lock screen configuration", ^{
});
it(@"should properly set properties", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testConfig.enableAutomaticLockScreen).to(beTrue());
- expect(testConfig.showInOptionalState).to(beFalse());
-#pragma clang diagnostic pop
expect(testConfig.enableDismissGesture).to(beTrue());
expect(testConfig.showDeviceLogo).to(beTrue());
expect(testConfig.backgroundColor).to(equal([UIColor colorWithRed:(57.0/255.0) green:(78.0/255.0) blue:(96.0/255.0) alpha:1.0]));
diff --git a/SmartDeviceLinkTests/DevAPISpecs/SDLLockScreenManagerSpec.m b/SmartDeviceLinkTests/DevAPISpecs/SDLLockScreenManagerSpec.m
index 9bcf9ba5f..50bf195be 100644
--- a/SmartDeviceLinkTests/DevAPISpecs/SDLLockScreenManagerSpec.m
+++ b/SmartDeviceLinkTests/DevAPISpecs/SDLLockScreenManagerSpec.m
@@ -5,12 +5,11 @@
#import "SDLFakeViewControllerPresenter.h"
#import "SDLLockScreenConfiguration.h"
#import "SDLLockScreenManager.h"
-#import "SDLLockScreenStatus.h"
+#import "SDLLockScreenStatusInfo.h"
#import "SDLLockScreenStatusManager.h"
#import "SDLLockScreenViewController.h"
#import "SDLNotificationConstants.h"
#import "SDLNotificationDispatcher.h"
-#import "SDLOnLockScreenStatus.h"
#import "SDLOnDriverDistraction.h"
#import "SDLRPCNotificationNotification.h"
@@ -21,11 +20,7 @@
@property (strong, nonatomic) id<SDLViewControllerPresentable> presenter;
@property (strong, nonatomic) SDLLockScreenStatusManager *statusManager;
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
-@property (strong, nonatomic, nullable) SDLOnLockScreenStatus *lastLockNotification;
-#pragma clang diagnostic pop
-
+@property (strong, nonatomic, nullable) SDLLockScreenStatusInfo *lastLockNotification;
@property (strong, nonatomic, nullable) SDLOnDriverDistraction *lastDriverDistractionNotification;
@property (assign, nonatomic, readwrite, getter=isLockScreenDismissable) BOOL lockScreenDismissable;
@property (assign, nonatomic) BOOL lockScreenDismissedByUser;
@@ -36,49 +31,52 @@ QuickSpecBegin(SDLLockScreenManagerSpec)
describe(@"a lock screen manager", ^{
__block SDLLockScreenManager *testManager = nil;
- __block SDLFakeViewControllerPresenter *fakeViewControllerPresenter = nil;
__block SDLNotificationDispatcher *dispatcherMock = nil;
-
+ __block id fakeViewControllerPresenter = nil;
+
beforeEach(^{
- fakeViewControllerPresenter = [[SDLFakeViewControllerPresenter alloc] init];
- dispatcherMock = OCMClassMock([SDLNotificationDispatcher class]);
+ testManager = nil;
+ dispatcherMock = nil;
+ fakeViewControllerPresenter = nil;
});
-
+
context(@"with a disabled configuration", ^{
beforeEach(^{
+ fakeViewControllerPresenter = OCMPartialMock([[SDLFakeViewControllerPresenter alloc] init]);
+ dispatcherMock = OCMClassMock([SDLNotificationDispatcher class]);
+
testManager = [[SDLLockScreenManager alloc] initWithConfiguration:[SDLLockScreenConfiguration disabledConfiguration] notificationDispatcher:dispatcherMock presenter:fakeViewControllerPresenter];
});
it(@"should set properties correctly", ^{
// Note: We can't check the "lockScreenPresented" flag on the Lock Screen Manager because it's a computer property checking the window
- expect(fakeViewControllerPresenter.shouldShowLockScreen).toEventually(beFalse());
+ expect(((SDLFakeViewControllerPresenter *)fakeViewControllerPresenter).shouldShowLockScreen).toEventually(beFalse());
expect(testManager.lockScreenViewController).to(beNil());
});
- describe(@"after it is started", ^{
+ describe(@"after the manager has been started", ^{
beforeEach(^{
[testManager start];
});
it(@"should not have a lock screen controller", ^{
- expect(fakeViewControllerPresenter.shouldShowLockScreen).toEventually(beFalse());
+ expect(((SDLFakeViewControllerPresenter *)fakeViewControllerPresenter).shouldShowLockScreen).toEventually(beFalse());
expect(testManager.lockScreenViewController).to(beNil());
});
describe(@"when the lock screen status becomes REQUIRED", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- __block SDLOnLockScreenStatus *testRequiredStatus = nil;
+ __block SDLLockScreenStatusInfo *testRequiredStatus = nil;
beforeEach(^{
- testRequiredStatus = [[SDLOnLockScreenStatus alloc] init];
+ testRequiredStatus = [[SDLLockScreenStatusInfo alloc] init];
testRequiredStatus.lockScreenStatus = SDLLockScreenStatusRequired;
- [dispatcherMock postNotificationName:SDLDidChangeLockScreenStatusNotification infoObject:testRequiredStatus];
-#pragma clang diagnostic pop
+ [[NSNotificationCenter defaultCenter] postNotificationName:SDLDidChangeLockScreenStatusNotification object:testManager.statusManager userInfo:@{SDLNotificationUserInfoObject: testRequiredStatus}];
});
it(@"should not have presented the lock screen", ^{
- expect(fakeViewControllerPresenter.shouldShowLockScreen).toEventually(beFalse());
+ OCMReject([fakeViewControllerPresenter updateLockScreenToShow:[OCMArg any] withCompletionHandler:nil]);
+
+ OCMVerifyAllWithDelay(fakeViewControllerPresenter, 0.5);
});
});
});
@@ -86,11 +84,14 @@ describe(@"a lock screen manager", ^{
context(@"with an enabled configuration", ^{
beforeEach(^{
+ fakeViewControllerPresenter = OCMPartialMock([[SDLFakeViewControllerPresenter alloc] init]);
+ dispatcherMock = OCMClassMock([SDLNotificationDispatcher class]);
+
testManager = [[SDLLockScreenManager alloc] initWithConfiguration:[SDLLockScreenConfiguration enabledConfiguration] notificationDispatcher:dispatcherMock presenter:fakeViewControllerPresenter];
});
-
+
it(@"should set properties correctly", ^{
- expect(fakeViewControllerPresenter.shouldShowLockScreen).toEventually(beFalse());
+ expect(((SDLFakeViewControllerPresenter *)fakeViewControllerPresenter).shouldShowLockScreen).toEventually(beFalse());
expect(testManager.lockScreenViewController).to(beNil());
});
@@ -98,115 +99,108 @@ describe(@"a lock screen manager", ^{
beforeEach(^{
[testManager start];
});
-
+
it(@"should set up the view controller correctly", ^{
- expect(fakeViewControllerPresenter.shouldShowLockScreen).toEventually(beFalse());
+ expect(((SDLFakeViewControllerPresenter *)fakeViewControllerPresenter).shouldShowLockScreen).toEventually(beFalse());
expect(testManager.lockScreenViewController).toNot(beNil());
expect(testManager.lockScreenViewController).to(beAnInstanceOf([SDLLockScreenViewController class]));
});
-
+
describe(@"when the lock screen status becomes REQUIRED", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- __block SDLOnLockScreenStatus *testRequiredStatus = nil;
-#pragma clang diagnostic pop
+ __block SDLLockScreenStatusInfo *testRequiredStatus = nil;
__block SDLOnDriverDistraction *testDriverDistraction = nil;
beforeEach(^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testRequiredStatus = [[SDLOnLockScreenStatus alloc] init];
+ testRequiredStatus = [[SDLLockScreenStatusInfo alloc] init];
testRequiredStatus.lockScreenStatus = SDLLockScreenStatusRequired;
- SDLRPCNotificationNotification *testLockStatusNotification = [[SDLRPCNotificationNotification alloc] initWithName:SDLDidChangeLockScreenStatusNotification object:testManager.statusManager rpcNotification:testRequiredStatus];
-#pragma clang diagnostic pop
- [[NSNotificationCenter defaultCenter] postNotification:testLockStatusNotification];
- });
-
- it(@"should have presented the lock screen", ^{
- expect(fakeViewControllerPresenter.shouldShowLockScreen).toEventually(beTrue());
+
+ testDriverDistraction = [[SDLOnDriverDistraction alloc] init];
+
+ [[NSNotificationCenter defaultCenter] postNotificationName:SDLDidChangeLockScreenStatusNotification object:testManager.statusManager userInfo:@{SDLNotificationUserInfoObject: testRequiredStatus}];
});
-
- it(@"should not have a vehicle icon", ^{
+
+ it(@"should have presented the lock screen and the lockscreen should not have a vehicle icon", ^{
+ OCMExpect([fakeViewControllerPresenter updateLockScreenToShow:YES withCompletionHandler:[OCMArg any]]);
+
+ OCMVerifyAllWithDelay(fakeViewControllerPresenter, 0.5);
+
expect(((SDLLockScreenViewController *)testManager.lockScreenViewController).vehicleIcon).to(beNil());
});
- describe(@"when a driver distraction notification is posted with lockScreenDismissableEnabled as true", ^{
+ describe(@"when a driver distraction notification is posted with lockScreenDismissableEnabled set to true", ^{
__block SDLRPCNotificationNotification *testDriverDistractionNotification = nil;
beforeEach(^{
- testDriverDistraction = [[SDLOnDriverDistraction alloc] init];
testDriverDistraction.lockScreenDismissalEnabled = @YES;
-
+
testDriverDistractionNotification = [[SDLRPCNotificationNotification alloc] initWithName:SDLDidChangeDriverDistractionStateNotification object:dispatcherMock rpcNotification:testDriverDistraction];
-
+
[[NSNotificationCenter defaultCenter] postNotification:testDriverDistractionNotification];
});
-
+
it(@"should be able to be dismissed", ^{
- expect(testManager.isLockScreenDismissable).toEventually(equal(YES));
+ expect(testManager.isLockScreenDismissable).toEventually(beTrue());
});
});
-
- describe(@"when a driver distraction notification is posted with lockScreenDismissableEnabled as false", ^{
+
+ describe(@"when a driver distraction notification is posted with lockScreenDismissableEnabled set to false", ^{
__block SDLRPCNotificationNotification *testDriverDistractionNotification = nil;
-
+
beforeEach(^{
- testDriverDistraction = [[SDLOnDriverDistraction alloc] init];
- testDriverDistraction.lockScreenDismissalEnabled = @0;
-
- testDriverDistractionNotification = [[SDLRPCNotificationNotification alloc] initWithName:SDLDidChangeDriverDistractionStateNotification object:nil rpcNotification:testDriverDistraction];
-
+ testDriverDistraction.lockScreenDismissalEnabled = @NO;
+
+ testDriverDistractionNotification = [[SDLRPCNotificationNotification alloc] initWithName:SDLDidChangeDriverDistractionStateNotification object:dispatcherMock rpcNotification:testDriverDistraction];
+
[[NSNotificationCenter defaultCenter] postNotification:testDriverDistractionNotification];
});
-
+
it(@"should not be able to be dismissed", ^{
- expect(testManager.isLockScreenDismissable).toEventually(equal(NO));
+ expect(testManager.isLockScreenDismissable).toEventually(beFalse());
});
-
});
-
- describe(@"when a driver distraction notification is posted with lockScreenDismissableEnabled nil bit", ^{
+
+ describe(@"when a driver distraction notification is posted with lockScreenDismissableEnabled set to nil", ^{
__block SDLRPCNotificationNotification *testDriverDistractionNotification = nil;
-
+
beforeEach(^{
- testDriverDistraction = [[SDLOnDriverDistraction alloc] init];
-
- testDriverDistractionNotification = [[SDLRPCNotificationNotification alloc] initWithName:SDLDidChangeDriverDistractionStateNotification object:nil rpcNotification:testDriverDistraction];
-
+ testDriverDistractionNotification = [[SDLRPCNotificationNotification alloc] initWithName:SDLDidChangeDriverDistractionStateNotification object:dispatcherMock rpcNotification:testDriverDistraction];
+
[[NSNotificationCenter defaultCenter] postNotification:testDriverDistractionNotification];
});
-
+
it(@"should not be able to be dismissed", ^{
- expect(testManager.isLockScreenDismissable).toEventually(equal(NO));
+ expect(testManager.isLockScreenDismissable).toEventually(beFalse());
});
-
});
-
+
describe(@"then the manager is stopped", ^{
beforeEach(^{
[testManager stop];
});
-
+
it(@"should have dismissed the lock screen", ^{
- expect(fakeViewControllerPresenter.shouldShowLockScreen).toEventually(beFalse());
+ OCMVerify([fakeViewControllerPresenter stopWithCompletionHandler:[OCMArg any]]);
+
+ expect(((SDLFakeViewControllerPresenter *)fakeViewControllerPresenter).shouldShowLockScreen).to(beFalse());
});
});
-
+
describe(@"then the status becomes OFF", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- __block SDLOnLockScreenStatus *testOffStatus = nil;
+ __block SDLLockScreenStatusInfo *testOffStatus = nil;
beforeEach(^{
- testOffStatus = [[SDLOnLockScreenStatus alloc] init];
+ testOffStatus = [[SDLLockScreenStatusInfo alloc] init];
testOffStatus.lockScreenStatus = SDLLockScreenStatusOff;
- SDLRPCNotificationNotification *testLockStatusNotification = [[SDLRPCNotificationNotification alloc] initWithName:SDLDidChangeLockScreenStatusNotification object:testManager.statusManager rpcNotification:testOffStatus];
-#pragma clang diagnostic pop
- [[NSNotificationCenter defaultCenter] postNotification:testLockStatusNotification];
+
+ [[NSNotificationCenter defaultCenter] postNotificationName:SDLDidChangeLockScreenStatusNotification object:testManager.statusManager userInfo:@{SDLNotificationUserInfoObject: testOffStatus}];
});
-
+
it(@"should have dismissed the lock screen", ^{
- expect(fakeViewControllerPresenter.shouldShowLockScreen).toEventually(beFalse());
+ OCMExpect([fakeViewControllerPresenter updateLockScreenToShow:NO withCompletionHandler:[OCMArg any]]);
+
+ OCMVerifyAllWithDelay(fakeViewControllerPresenter, 0.5);
+
+ expect(((SDLFakeViewControllerPresenter *)fakeViewControllerPresenter).shouldShowLockScreen).to(beFalse());
});
});
});
@@ -218,12 +212,16 @@ describe(@"a lock screen manager", ^{
SDLLockScreenConfiguration *testsConfig = [SDLLockScreenConfiguration enabledConfiguration];
beforeEach(^{
+ fakeViewControllerPresenter = OCMPartialMock([[SDLFakeViewControllerPresenter alloc] init]);
+ dispatcherMock = OCMClassMock([SDLNotificationDispatcher class]);
+
testIcon = [UIImage imageNamed:@"testImagePNG" inBundle:[NSBundle bundleForClass:self.class] compatibleWithTraitCollection:nil];
});
it(@"should should set the vehicle icon on the default lockscreen if showDeviceLogo set to true", ^{
testsConfig.showDeviceLogo = YES;
- fakeViewControllerPresenter.lockViewController = [[SDLLockScreenViewController alloc] init];
+
+ OCMStub([fakeViewControllerPresenter lockViewController]).andReturn([[SDLLockScreenViewController alloc] init]);
testManager = [[SDLLockScreenManager alloc] initWithConfiguration:testsConfig notificationDispatcher:dispatcherMock presenter:fakeViewControllerPresenter];
[[NSNotificationCenter defaultCenter] postNotificationName:SDLDidReceiveLockScreenIcon object:nil userInfo:@{ SDLNotificationUserInfoObject: testIcon }];
@@ -233,7 +231,7 @@ describe(@"a lock screen manager", ^{
it(@"should should not set the vehicle icon on the default lockscreen if showDeviceLogo set to false", ^{
testsConfig.showDeviceLogo = NO;
- fakeViewControllerPresenter.lockViewController = [[SDLLockScreenViewController alloc] init];
+ OCMStub([fakeViewControllerPresenter lockViewController]).andReturn([[SDLLockScreenViewController alloc] init]);
testManager = [[SDLLockScreenManager alloc] initWithConfiguration:testsConfig notificationDispatcher:dispatcherMock presenter:fakeViewControllerPresenter];
[[NSNotificationCenter defaultCenter] postNotificationName:SDLDidReceiveLockScreenIcon object:nil userInfo:@{ SDLNotificationUserInfoObject: testIcon }];
@@ -244,38 +242,41 @@ describe(@"a lock screen manager", ^{
it(@"should should not modify a custom lockscreen", ^{
testsConfig.showDeviceLogo = YES;
UIViewController *customLockScreen = [[UIViewController alloc] init];
- fakeViewControllerPresenter.lockViewController = customLockScreen;
+ OCMStub([fakeViewControllerPresenter lockViewController]).andReturn(customLockScreen);
testManager = [[SDLLockScreenManager alloc] initWithConfiguration:testsConfig notificationDispatcher:dispatcherMock presenter:fakeViewControllerPresenter];
[[NSNotificationCenter defaultCenter] postNotificationName:SDLDidReceiveLockScreenIcon object:nil userInfo:@{ SDLNotificationUserInfoObject: testIcon }];
- expect(fakeViewControllerPresenter.lockViewController).toEventually(equal(customLockScreen));
+ expect(((SDLFakeViewControllerPresenter *)fakeViewControllerPresenter).lockViewController).toEventually(equal(customLockScreen));
});
});
context(@"with a custom color configuration", ^{
__block UIColor *testColor = nil;
__block UIImage *testImage = nil;
-
+
beforeEach(^{
+ fakeViewControllerPresenter = OCMPartialMock([[SDLFakeViewControllerPresenter alloc] init]);
+ dispatcherMock = OCMClassMock([SDLNotificationDispatcher class]);
+
testColor = [UIColor blueColor];
testImage = [UIImage imageNamed:@"testImagePNG" inBundle:[NSBundle bundleForClass:self.class] compatibleWithTraitCollection:nil];
-
+
testManager = [[SDLLockScreenManager alloc] initWithConfiguration:[SDLLockScreenConfiguration enabledConfigurationWithAppIcon:testImage backgroundColor:testColor] notificationDispatcher:dispatcherMock presenter:fakeViewControllerPresenter];
});
-
+
it(@"should set properties correctly", ^{
- expect(fakeViewControllerPresenter.shouldShowLockScreen).toEventually(beFalse());
+ expect(((SDLFakeViewControllerPresenter *)fakeViewControllerPresenter).shouldShowLockScreen).to(beFalse());
expect(testManager.lockScreenViewController).to(beNil());
});
-
+
describe(@"after it's started", ^{
beforeEach(^{
[testManager start];
});
-
+
it(@"should set up the view controller correctly", ^{
- expect(fakeViewControllerPresenter.shouldShowLockScreen).toEventually(beFalse());
+ expect(((SDLFakeViewControllerPresenter *)fakeViewControllerPresenter).shouldShowLockScreen).toEventually(beFalse());
expect(testManager.lockScreenViewController).toNot(beNil());
expect(testManager.lockScreenViewController).to(beAnInstanceOf([SDLLockScreenViewController class]));
expect(((SDLLockScreenViewController *)testManager.lockScreenViewController).backgroundColor).to(equal(testColor));
@@ -283,27 +284,30 @@ describe(@"a lock screen manager", ^{
});
});
});
-
+
context(@"with a custom view controller configuration", ^{
__block UIViewController *testViewController = nil;
-
+
beforeEach(^{
+ fakeViewControllerPresenter = OCMPartialMock([[SDLFakeViewControllerPresenter alloc] init]);
+ dispatcherMock = OCMClassMock([SDLNotificationDispatcher class]);
+
testViewController = [[UIViewController alloc] init];
testManager = [[SDLLockScreenManager alloc] initWithConfiguration:[SDLLockScreenConfiguration enabledConfigurationWithViewController:testViewController] notificationDispatcher:dispatcherMock presenter:fakeViewControllerPresenter];
});
-
+
it(@"should set properties correctly", ^{
- expect(fakeViewControllerPresenter.shouldShowLockScreen).toEventually(beFalse());
+ expect(((SDLFakeViewControllerPresenter *)fakeViewControllerPresenter).shouldShowLockScreen).toEventually(beFalse());
expect(testManager.lockScreenViewController).to(beNil());
});
-
+
describe(@"after it's started", ^{
beforeEach(^{
[testManager start];
});
-
+
it(@"should set up the view controller correctly", ^{
- expect(fakeViewControllerPresenter.shouldShowLockScreen).toEventually(beFalse());
+ expect(((SDLFakeViewControllerPresenter *)fakeViewControllerPresenter).shouldShowLockScreen).toEventually(beFalse());
expect(testManager.lockScreenViewController).toNot(beNil());
expect(testManager.lockScreenViewController).toNot(beAnInstanceOf([SDLLockScreenViewController class]));
expect(testManager.lockScreenViewController).to(equal(testViewController));
@@ -313,6 +317,9 @@ describe(@"a lock screen manager", ^{
context(@"with a dismissable false configuration", ^{
beforeEach(^{
+ fakeViewControllerPresenter = OCMPartialMock([[SDLFakeViewControllerPresenter alloc] init]);
+ dispatcherMock = OCMClassMock([SDLNotificationDispatcher class]);
+
SDLLockScreenConfiguration *config = [SDLLockScreenConfiguration enabledConfiguration];
config.enableDismissGesture = NO;
@@ -324,11 +331,8 @@ describe(@"a lock screen manager", ^{
__block SDLRPCNotificationNotification *testDriverDistractionNotification = nil;
beforeEach(^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLOnLockScreenStatus *status = [[SDLOnLockScreenStatus alloc] init];
+ SDLLockScreenStatusInfo *status = [[SDLLockScreenStatusInfo alloc] init];
status.lockScreenStatus = SDLLockScreenStatusRequired;
-#pragma clang diagnostic pop
testManager.lastLockNotification = status;
SDLOnDriverDistraction *testDriverDistraction = [[SDLOnDriverDistraction alloc] init];
@@ -346,22 +350,12 @@ describe(@"a lock screen manager", ^{
});
describe(@"with an always enabled configuration", ^{
- __block SDLFakeViewControllerPresenter *fakeViewControllerPresenter = nil;
- __block SDLRPCNotificationNotification *testLockStatusNotification = nil;
-
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- __block SDLOnLockScreenStatus *testStatus = nil;
-#pragma clang diagnostic pop
+ __block SDLLockScreenStatusInfo *testStatus = nil;
beforeEach(^{
- fakeViewControllerPresenter = [[SDLFakeViewControllerPresenter alloc] init];
-
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testStatus = [[SDLOnLockScreenStatus alloc] init];
-#pragma clang diagnostic pop
+ fakeViewControllerPresenter = OCMPartialMock([[SDLFakeViewControllerPresenter alloc] init]);
+ testStatus = [[SDLLockScreenStatusInfo alloc] init];
SDLLockScreenConfiguration *config = [SDLLockScreenConfiguration enabledConfiguration];
config.displayMode = SDLLockScreenConfigurationDisplayModeAlways;
@@ -371,100 +365,84 @@ describe(@"a lock screen manager", ^{
context(@"receiving a lock screen status of required", ^{
beforeEach(^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
testStatus.lockScreenStatus = SDLLockScreenStatusRequired;
- testLockStatusNotification = [[SDLRPCNotificationNotification alloc] initWithName:SDLDidChangeLockScreenStatusNotification object:testManager.statusManager rpcNotification:testStatus];
-#pragma clang diagnostic pop
- [[NSNotificationCenter defaultCenter] postNotification:testLockStatusNotification];
+ OCMStub([fakeViewControllerPresenter lockViewController]).andReturn([[SDLLockScreenViewController alloc] init]);
+
+ [[NSNotificationCenter defaultCenter] postNotificationName:SDLDidChangeLockScreenStatusNotification object:testManager.statusManager userInfo:@{SDLNotificationUserInfoObject: testStatus}];
});
it(@"should present the lock screen if not already presented", ^{
- expect(fakeViewControllerPresenter.shouldShowLockScreen).toEventually(beTrue());
+ OCMExpect([fakeViewControllerPresenter updateLockScreenToShow:YES withCompletionHandler:[OCMArg any]]);
+
+ OCMVerifyAllWithDelay(fakeViewControllerPresenter, 0.5);
+
+ expect(((SDLFakeViewControllerPresenter *)fakeViewControllerPresenter).shouldShowLockScreen).toEventually(beTrue());
});
});
context(@"receiving a lock screen status of off", ^{
beforeEach(^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
testStatus.lockScreenStatus = SDLLockScreenStatusOff;
- testLockStatusNotification = [[SDLRPCNotificationNotification alloc] initWithName:SDLDidChangeLockScreenStatusNotification object:testManager.statusManager rpcNotification:testStatus];
-#pragma clang diagnostic pop
- [[NSNotificationCenter defaultCenter] postNotification:testLockStatusNotification];
+ OCMStub([fakeViewControllerPresenter lockViewController]).andReturn([[SDLLockScreenViewController alloc] init]);
+
+ [[NSNotificationCenter defaultCenter] postNotificationName:SDLDidChangeLockScreenStatusNotification object:testManager.statusManager userInfo:@{SDLNotificationUserInfoObject: testStatus}];
});
it(@"should present the lock screen if not already presented", ^{
- expect(fakeViewControllerPresenter.shouldShowLockScreen).toEventually(beTrue());
+ OCMExpect([fakeViewControllerPresenter updateLockScreenToShow:YES withCompletionHandler:[OCMArg any]]);
+
+ OCMVerifyAllWithDelay(fakeViewControllerPresenter, 0.5);
+
+ expect(((SDLFakeViewControllerPresenter *)fakeViewControllerPresenter).shouldShowLockScreen).toEventually(beTrue());
});
});
});
describe(@"A lock screen status of OPTIONAL", ^{
__block SDLLockScreenConfiguration *testLockScreenConfig = nil;
- __block id mockViewControllerPresenter = nil;
- __block SDLRPCNotificationNotification *testLockStatusNotification = nil;
+ __block SDLLockScreenStatusInfo *testOptionalStatus;
beforeEach(^{
- mockViewControllerPresenter = OCMClassMock([SDLFakeViewControllerPresenter class]);
+ fakeViewControllerPresenter = OCMClassMock([SDLFakeViewControllerPresenter class]);
testLockScreenConfig = [SDLLockScreenConfiguration enabledConfiguration];
+
+ testOptionalStatus = [[SDLLockScreenStatusInfo alloc] init];
+ testOptionalStatus.lockScreenStatus = SDLLockScreenStatusOptional;
});
- context(@"showInOptionalState is true", ^{
+ context(@"displayMode is set to always show the lockscreen", ^{
beforeEach(^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testLockScreenConfig.showInOptionalState = true;
-#pragma clang diagnostic pop
-
- testManager = [[SDLLockScreenManager alloc] initWithConfiguration:testLockScreenConfig notificationDispatcher:dispatcherMock presenter:mockViewControllerPresenter];
+ testLockScreenConfig.displayMode = SDLLockScreenConfigurationDisplayModeOptionalOrRequired;
+ testManager = [[SDLLockScreenManager alloc] initWithConfiguration:testLockScreenConfig notificationDispatcher:dispatcherMock presenter:fakeViewControllerPresenter];
testManager.canPresent = YES;
-
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLOnLockScreenStatus *testOptionalStatus = [[SDLOnLockScreenStatus alloc] init];
- testOptionalStatus.lockScreenStatus = SDLLockScreenStatusOptional;
- testLockStatusNotification = [[SDLRPCNotificationNotification alloc] initWithName:SDLDidChangeLockScreenStatusNotification object:testManager.statusManager rpcNotification:testOptionalStatus];
-#pragma clang diagnostic pop
});
it(@"should present the lock screen if not already presented", ^{
- OCMStub([mockViewControllerPresenter lockViewController]).andReturn([OCMArg any]);
- OCMExpect([mockViewControllerPresenter updateLockScreenToShow:YES withCompletionHandler:[OCMArg any]]).ignoringNonObjectArgs();
+ OCMStub([fakeViewControllerPresenter lockViewController]).andReturn([OCMArg any]);
+ OCMExpect([fakeViewControllerPresenter updateLockScreenToShow:YES withCompletionHandler:[OCMArg any]]).ignoringNonObjectArgs();
- [[NSNotificationCenter defaultCenter] postNotification:testLockStatusNotification];
+ [[NSNotificationCenter defaultCenter] postNotificationName:SDLDidChangeLockScreenStatusNotification object:testManager.statusManager userInfo:@{SDLNotificationUserInfoObject: testOptionalStatus}];
- OCMVerifyAllWithDelay(mockViewControllerPresenter, 0.5);
+ OCMVerifyAllWithDelay(fakeViewControllerPresenter, 0.5);
});
});
- context(@"showInOptionalState is false", ^{
+ context(@"displayMode is set to never show the lockscreen", ^{
beforeEach(^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testLockScreenConfig.showInOptionalState = false;
-#pragma clang diagnostic pop
-
- testManager = [[SDLLockScreenManager alloc] initWithConfiguration:testLockScreenConfig notificationDispatcher:dispatcherMock presenter:mockViewControllerPresenter];
+ testLockScreenConfig.displayMode = SDLLockScreenConfigurationDisplayModeNever;
+ testManager = [[SDLLockScreenManager alloc] initWithConfiguration:testLockScreenConfig notificationDispatcher:dispatcherMock presenter:fakeViewControllerPresenter];
testManager.canPresent = YES;
-
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLOnLockScreenStatus *testOptionalStatus = [[SDLOnLockScreenStatus alloc] init];
- testOptionalStatus.lockScreenStatus = SDLLockScreenStatusOptional;
- testLockStatusNotification = [[SDLRPCNotificationNotification alloc] initWithName:SDLDidChangeLockScreenStatusNotification object:testManager.statusManager rpcNotification:testOptionalStatus];
-#pragma clang diagnostic pop
});
it(@"should dismiss the lock screen if already presented", ^{
- OCMStub([mockViewControllerPresenter lockViewController]).andReturn([OCMArg any]);
- OCMExpect([mockViewControllerPresenter updateLockScreenToShow:NO withCompletionHandler:[OCMArg any]]).ignoringNonObjectArgs();
+ OCMStub([fakeViewControllerPresenter lockViewController]).andReturn([OCMArg any]);
+ OCMExpect([fakeViewControllerPresenter updateLockScreenToShow:NO withCompletionHandler:[OCMArg any]]).ignoringNonObjectArgs();
- [[NSNotificationCenter defaultCenter] postNotification:testLockStatusNotification];
+ [[NSNotificationCenter defaultCenter] postNotificationName:SDLDidChangeLockScreenStatusNotification object:testManager.statusManager userInfo:@{SDLNotificationUserInfoObject: testOptionalStatus}];
- OCMVerifyAllWithDelay(mockViewControllerPresenter, 0.5);
+ OCMVerifyAllWithDelay(fakeViewControllerPresenter, 0.5);
});
});
});
diff --git a/SmartDeviceLinkTests/DevAPISpecs/SDLMenuCellSpec.m b/SmartDeviceLinkTests/DevAPISpecs/SDLMenuCellSpec.m
index ab8b281fd..485b02b6d 100644
--- a/SmartDeviceLinkTests/DevAPISpecs/SDLMenuCellSpec.m
+++ b/SmartDeviceLinkTests/DevAPISpecs/SDLMenuCellSpec.m
@@ -35,32 +35,6 @@ describe(@"a menu cell", ^{
expect(testCell.subCells).to(beNil());
});
- it(@"should initialize properly as a submenu item", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testCell = [[SDLMenuCell alloc] initWithTitle:someTitle subCells:someSubcells];
-
- expect(testCell.title).to(equal(someTitle));
- expect(testCell.icon).to(beNil());
- expect(testCell.voiceCommands).to(beNil());
- expect(testCell.subCells).to(equal(someSubcells));
- expect(testCell.submenuLayout).to(beNil());
- #pragma clang diagnostic pop
- });
-
- it(@"should initialize properly as a submenu item with icon", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testCell = [[SDLMenuCell alloc] initWithTitle:someTitle icon:someArtwork subCells:someSubcells];
-
- expect(testCell.title).to(equal(someTitle));
- expect(testCell.icon).to(equal(someArtwork));
- expect(testCell.voiceCommands).to(beNil());
- expect(testCell.subCells).to(equal(someSubcells));
- expect(testCell.submenuLayout).to(beNil());
-#pragma clang diagnostic pop
- });
-
it(@"should initialize properly as a submenu item with icon and layout", ^{
testCell = [[SDLMenuCell alloc] initWithTitle:someTitle icon:someArtwork submenuLayout:testLayout subCells:someSubcells];
diff --git a/SmartDeviceLinkTests/DevAPISpecs/SDLPermissionFilterSpec.m b/SmartDeviceLinkTests/DevAPISpecs/SDLPermissionFilterSpec.m
index 757c6411b..d4b910005 100644
--- a/SmartDeviceLinkTests/DevAPISpecs/SDLPermissionFilterSpec.m
+++ b/SmartDeviceLinkTests/DevAPISpecs/SDLPermissionFilterSpec.m
@@ -7,7 +7,7 @@
QuickSpecBegin(SDLPermissionFilterSpec)
-describe(@"A filter", ^{
+describe(@"A permissions filter", ^{
__block NSString *testRPCName1 = nil;
__block NSString *testRPCName2 = nil;
__block SDLPermissionElement *testPermissionElement1 = nil;
@@ -24,88 +24,43 @@ describe(@"A filter", ^{
__block NSArray<SDLPermissionElement *> *testPermissionElements = nil;
__block SDLPermissionGroupType testGroupType = SDLPermissionGroupTypeAny;
__block SDLPermissionFilter *testFilter = nil;
-
- __block NSDictionary<SDLPermissionRPCName, NSNumber<SDLBool> *> *testObserverReturnChangedDict = nil;
- __block NSDictionary<SDLPermissionRPCName, SDLRPCPermissionStatus *> *testRPCPermissionStatusReturnChangedDict = nil;
+ __block NSDictionary<SDLRPCFunctionName, SDLRPCPermissionStatus *> *testRPCPermissionStatusReturnChangedDict = nil;
beforeEach(^{
testPermissionElements = @[testPermissionElement1, testPermissionElement2];
testGroupType = SDLPermissionGroupTypeAny;
+
+ testFilter = [[SDLPermissionFilter alloc] initWithPermissions:testPermissionElements groupType:testGroupType permissionStatusHandler:^(NSDictionary<SDLRPCFunctionName,SDLRPCPermissionStatus *> * _Nonnull change, SDLPermissionGroupStatus status) {
+ testRPCPermissionStatusReturnChangedDict = change;
+ }];
+ });
+
+ it(@"should set the permission elements array correctly", ^{
+ expect(testFilter.permissionElements).to(equal(testPermissionElements));
});
- context(@"using initWithRPCNames:changeType:permissionsHandler:rpcPermissionStatusHandler", ^{
- context(@"using SDLPermissionsChangedHandler init", ^{
- beforeEach(^{
- testFilter = [[SDLPermissionFilter alloc] initWithPermissions:testPermissionElements groupType:testGroupType permissionsHandler:^(NSDictionary<SDLPermissionRPCName,NSNumber *> * _Nonnull change, SDLPermissionGroupStatus status) {
- testObserverReturnChangedDict = change;
- }];
- });
-
- it(@"should set the rpcNames array correctly", ^{
- expect([testFilter rpcNamesFromPermissionElements:testPermissionElements]).to(equal([testFilter rpcNamesFromPermissionElements:testPermissionElements]));
- });
-
- describe(@"it should set up the observer correctly", ^{
- __block NSDictionary<SDLPermissionRPCName,NSNumber<SDLBool> *> *testObserverChangedDict = nil;
- __block NSNumber<SDLBool> *testRPCName1Bool = nil;
- __block NSNumber<SDLBool> *testRPCName2Bool = nil;
- __block SDLPermissionGroupStatus testObserverGroupStatus = SDLPermissionGroupStatusUnknown;
-
- beforeEach(^{
- testRPCName1Bool = @YES;
- testRPCName2Bool = @NO;
- testObserverChangedDict = @{testRPCName1: testRPCName1Bool,
- testRPCName2: testRPCName2Bool};
- testObserverGroupStatus = SDLPermissionGroupStatusMixed;
-
- testFilter.handler(testObserverChangedDict, testObserverGroupStatus);
- });
-
- it(@"should call the changedDict correctly", ^{
- expect(testObserverReturnChangedDict).to(equal(testObserverChangedDict));
- });
-
- it(@"should call the status correctly", ^{
- expect(@(testObserverGroupStatus)).to(equal(@(testObserverGroupStatus)));
- });
- });
+ describe(@"it should set up the observer correctly", ^{
+ __block NSDictionary<SDLRPCFunctionName, SDLRPCPermissionStatus *> *testObserverChangedDict = nil;
+ __block SDLRPCPermissionStatus *rpcPermissionStatus1 = nil;
+ __block SDLRPCPermissionStatus *rpcPermissionStatus2 = nil;
+ __block SDLPermissionGroupStatus testObserverGroupStatus = SDLPermissionGroupStatusUnknown;
+
+ beforeEach(^{
+ rpcPermissionStatus1 = [[SDLRPCPermissionStatus alloc] initWithRPCName:testRPCName1 isRPCAllowed:YES rpcParameters:nil];
+ rpcPermissionStatus2 = [[SDLRPCPermissionStatus alloc] initWithRPCName:testRPCName2 isRPCAllowed:NO rpcParameters:nil];
+ testObserverChangedDict = @{testRPCName1: rpcPermissionStatus1,
+ testRPCName2: rpcPermissionStatus2};
+ testObserverGroupStatus = SDLPermissionGroupStatusMixed;
+
+ testFilter.rpcPermissionStatusHandler(testObserverChangedDict, testObserverGroupStatus);
+ });
+
+ it(@"should call the changedDict correctly", ^{
+ expect(testRPCPermissionStatusReturnChangedDict).to(equal(testObserverChangedDict));
});
- context(@"using the SDLRPCPermissionStatusChangedHandler init", ^{
- beforeEach(^{
- testFilter = [[SDLPermissionFilter alloc] initWithPermissions:testPermissionElements groupType:testGroupType permissionStatusHandler:^(NSDictionary<SDLRPCFunctionName,SDLRPCPermissionStatus *> * _Nonnull change, SDLPermissionGroupStatus status) {
- testRPCPermissionStatusReturnChangedDict = change;
- }];
- });
-
- it(@"should set the permission elements array correctly", ^{
- expect(testFilter.permissionElements).to(equal(testPermissionElements));
- });
-
- describe(@"it should set up the observer correctly", ^{
- __block NSDictionary<SDLPermissionRPCName, SDLRPCPermissionStatus *> *testObserverChangedDict = nil;
- __block SDLRPCPermissionStatus *rpcPermissionStatus1 = nil;
- __block SDLRPCPermissionStatus *rpcPermissionStatus2 = nil;
- __block SDLPermissionGroupStatus testObserverGroupStatus = SDLPermissionGroupStatusUnknown;
-
- beforeEach(^{
- rpcPermissionStatus1 = [[SDLRPCPermissionStatus alloc] initWithRPCName:testRPCName1 isRPCAllowed:YES rpcParameters:nil];
- rpcPermissionStatus2 = [[SDLRPCPermissionStatus alloc] initWithRPCName:testRPCName2 isRPCAllowed:NO rpcParameters:nil];
- testObserverChangedDict = @{testRPCName1: rpcPermissionStatus1,
- testRPCName2: rpcPermissionStatus2};
- testObserverGroupStatus = SDLPermissionGroupStatusMixed;
-
- testFilter.rpcPermissionStatusHandler(testObserverChangedDict, testObserverGroupStatus);
- });
-
- it(@"should call the changedDict correctly", ^{
- expect(testRPCPermissionStatusReturnChangedDict).to(equal(testObserverChangedDict));
- });
-
- it(@"should call the status correctly", ^{
- expect(@(testObserverGroupStatus)).to(equal(@(testObserverGroupStatus)));
- });
- });
+ it(@"should call the status correctly", ^{
+ expect(@(testObserverGroupStatus)).to(equal(@(testObserverGroupStatus)));
});
});
});
@@ -115,23 +70,14 @@ describe(@"A filter", ^{
__block SDLPermissionFilter *testCopiedFilter = nil;
beforeEach(^{
- testFilter = [[SDLPermissionFilter alloc] initWithPermissions:@[testPermissionElement1] groupType:SDLPermissionGroupTypeAny permissionsHandler:^(NSDictionary<SDLPermissionRPCName,NSNumber *> * _Nonnull change, SDLPermissionGroupStatus status) {}];
+ testFilter = [[SDLPermissionFilter alloc] initWithPermissions:@[testPermissionElement1] groupType:SDLPermissionGroupTypeAny permissionStatusHandler:^(NSDictionary<SDLRPCFunctionName,SDLRPCPermissionStatus *> * _Nonnull updatedPermissionStatuses, SDLPermissionGroupStatus status) {}];
testCopiedFilter = [testFilter copy];
});
- it(@"should say copied filters are not the same instance", ^{
+ it(@"should copy correctly", ^{
expect(testCopiedFilter).toNot(beIdenticalTo(testFilter));
- });
-
- it(@"should copy the identifier correctly", ^{
expect(testCopiedFilter.identifier).to(equal(testFilter.identifier));
- });
-
- it(@"should copy the filter array correctly", ^{
expect(testCopiedFilter.permissionElements).to(equal(testFilter.permissionElements));
- });
-
- it(@"should copy the change type correctly", ^{
expect(@(testCopiedFilter.groupType)).to(equal(@(testFilter.groupType)));
});
});
@@ -142,10 +88,10 @@ describe(@"A filter", ^{
__block SDLPermissionFilter *testDifferentFilter = nil;
beforeEach(^{
- testSameFilter1 = [[SDLPermissionFilter alloc] initWithPermissions:@[testPermissionElement1] groupType:(SDLPermissionGroupType)SDLPermissionGroupTypeAny permissionsHandler:^(NSDictionary<SDLPermissionRPCName,NSNumber *> * _Nonnull change, SDLPermissionGroupStatus status) {}];
+ testSameFilter1 = [[SDLPermissionFilter alloc] initWithPermissions:@[testPermissionElement1] groupType:SDLPermissionGroupTypeAny permissionStatusHandler:^(NSDictionary<SDLRPCFunctionName,SDLRPCPermissionStatus *> * _Nonnull updatedPermissionStatuses, SDLPermissionGroupStatus status) {}];
testSameFilter2 = [testSameFilter1 copy];
- testDifferentFilter = [[SDLPermissionFilter alloc] initWithPermissions:@[testPermissionElement1] groupType:(SDLPermissionGroupType)SDLPermissionGroupTypeAny permissionsHandler:^(NSDictionary<SDLPermissionRPCName,NSNumber *> * _Nonnull change, SDLPermissionGroupStatus status) {}];
+ testDifferentFilter = [[SDLPermissionFilter alloc] initWithPermissions:@[testPermissionElement1] groupType:SDLPermissionGroupTypeAny permissionStatusHandler:^(NSDictionary<SDLRPCFunctionName,SDLRPCPermissionStatus *> * _Nonnull updatedPermissionStatuses, SDLPermissionGroupStatus status) {}];
});
it(@"should say copied filters are the same", ^{
diff --git a/SmartDeviceLinkTests/DevAPISpecs/SDLPermissionsManagerSpec.m b/SmartDeviceLinkTests/DevAPISpecs/SDLPermissionsManagerSpec.m
index 05020ef37..9888aab69 100644
--- a/SmartDeviceLinkTests/DevAPISpecs/SDLPermissionsManagerSpec.m
+++ b/SmartDeviceLinkTests/DevAPISpecs/SDLPermissionsManagerSpec.m
@@ -17,7 +17,7 @@
@interface SDLPermissionManager ()
-@property (strong, nonatomic) NSMutableDictionary<SDLPermissionRPCName, SDLPermissionItem *> *permissions;
+@property (strong, nonatomic) NSMutableDictionary<SDLRPCFunctionName, SDLPermissionItem *> *permissions;
@property (strong, nonatomic) NSMutableArray<SDLPermissionFilter *> *filters;
@property (copy, nonatomic, nullable) SDLHMILevel currentHMILevel;
@property (assign, nonatomic) BOOL requiresEncryption;
@@ -64,6 +64,7 @@ describe(@"SDLPermissionsManager", ^{
__block SDLPermissionElement *testPermissionElementAllAllowed = nil;
__block SDLPermissionElement *testPermissionElementFullLimitedAllowed = nil;
+ __block SDLPermissionElement *testPermissionElementFullLimitedBackgroundAllowed = nil;
__block SDLPermissionElement *testPermissionElementDisallowed = nil;
beforeEach(^{
@@ -152,6 +153,7 @@ describe(@"SDLPermissionsManager", ^{
// Permission Elements
testPermissionElementAllAllowed = [[SDLPermissionElement alloc] initWithRPCName:testRPCNameAllAllowed parameterPermissions:@[testRPCParameterNameAllAllowed]];
testPermissionElementFullLimitedAllowed = [[SDLPermissionElement alloc] initWithRPCName:testRPCNameFullLimitedAllowed parameterPermissions:@[testRPCParameterNameFullLimitedAllowed]];
+ testPermissionElementFullLimitedBackgroundAllowed = [[SDLPermissionElement alloc] initWithRPCName:testRPCNameFullLimitedBackgroundAllowed parameterPermissions: nil];
testPermissionElementDisallowed = [[SDLPermissionElement alloc] initWithRPCName:testRPCNameAllDisallowed parameterPermissions:@[testRPCParameterNameAllDisallowed]];
});
@@ -170,118 +172,47 @@ describe(@"SDLPermissionsManager", ^{
__block BOOL testResultBOOL = NO;
context(@"when no permissions exist", ^{
- context(@"deprecated isRPCAllowed: method", ^{
- beforeEach(^{
- someRPCName = @"some rpc name";
-
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testResultBOOL = [testPermissionsManager isRPCAllowed:someRPCName];
- #pragma clang diagnostic pop
- });
-
- it(@"should not be allowed", ^{
- expect(testResultBOOL).to(beFalse());
- });
- });
-
- context(@"isRPCNameAllowed: method", ^{
- beforeEach(^{
- someRPCFunctionName = @"SomeRPCFunctionName";
- testResultBOOL = [testPermissionsManager isRPCNameAllowed:someRPCName];
- });
+ it(@"should not be allowed", ^{
+ someRPCFunctionName = @"SomeRPCFunctionName";
+ testResultBOOL = [testPermissionsManager isRPCNameAllowed:someRPCName];
- it(@"should not be allowed", ^{
- expect(testResultBOOL).to(beFalse());
- });
+ expect(testResultBOOL).to(beFalse());
});
});
context(@"when permissions exist but no HMI level", ^{
- context(@"deprecated isRPCAllowed: method", ^{
- beforeEach(^{
- [[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testResultBOOL = [testPermissionsManager isRPCAllowed:testRPCNameAllAllowed];
- #pragma clang diagnostic pop
- });
-
- it(@"should not be allowed", ^{
- expect(testResultBOOL).to(beFalse());
- });
- });
-
- context(@"isRPCNameAllowed: method", ^{
- beforeEach(^{
- [[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
- testResultBOOL = [testPermissionsManager isRPCNameAllowed:someRPCName];
- });
+ it(@"should not be allowed", ^{
+ [[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
+ testResultBOOL = [testPermissionsManager isRPCNameAllowed:someRPCName];
- it(@"should not be allowed", ^{
- expect(testResultBOOL).to(beFalse());
- });
+ expect(testResultBOOL).to(beFalse());
});
});
context(@"when permissions exist", ^{
- context(@"deprecated isRPCAllowed: method", ^{
- context(@"and the permission is allowed", ^{
- beforeEach(^{
- [[NSNotificationCenter defaultCenter] postNotification:limitedHMINotification];
- [[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testResultBOOL = [testPermissionsManager isRPCAllowed:testRPCNameAllAllowed];
- #pragma clang diagnostic pop
- });
+ context(@"and the permission is allowed", ^{
+ beforeEach(^{
+ [[NSNotificationCenter defaultCenter] postNotification:limitedHMINotification];
+ [[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
- it(@"should be allowed", ^{
- expect(testResultBOOL).to(beTrue());
- });
+ testResultBOOL = [testPermissionsManager isRPCNameAllowed:testRPCNameAllAllowed];
});
- context(@"and the permission is denied", ^{
- beforeEach(^{
- [[NSNotificationCenter defaultCenter] postNotification:limitedHMINotification];
- [[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testResultBOOL = [testPermissionsManager isRPCAllowed:testRPCNameAllDisallowed];
- #pragma clang diagnostic pop
- });
-
- it(@"should be denied", ^{
- expect(testResultBOOL).to(beFalse());
- });
+ it(@"should be allowed", ^{
+ expect(testResultBOOL).to(beTrue());
});
});
- context(@"isRPCNameAllowed: method", ^{
- context(@"and the permission is allowed", ^{
- beforeEach(^{
- [[NSNotificationCenter defaultCenter] postNotification:limitedHMINotification];
- [[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
-
- testResultBOOL = [testPermissionsManager isRPCNameAllowed:testRPCNameAllAllowed];
- });
+ context(@"and the permission is denied", ^{
+ beforeEach(^{
+ [[NSNotificationCenter defaultCenter] postNotification:limitedHMINotification];
+ [[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
- it(@"should be allowed", ^{
- expect(testResultBOOL).to(beTrue());
- });
+ testResultBOOL = [testPermissionsManager isRPCNameAllowed:testRPCNameAllDisallowed];
});
- context(@"and the permission is denied", ^{
- beforeEach(^{
- [[NSNotificationCenter defaultCenter] postNotification:limitedHMINotification];
- [[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
-
- testResultBOOL = [testPermissionsManager isRPCNameAllowed:testRPCNameAllDisallowed];
- });
-
- it(@"should be denied", ^{
- expect(testResultBOOL).to(beFalse());
- });
+ it(@"should be denied", ^{
+ expect(testResultBOOL).to(beFalse());
});
});
});
@@ -291,123 +222,48 @@ describe(@"SDLPermissionsManager", ^{
__block SDLPermissionGroupStatus testResultStatus = SDLPermissionGroupStatusUnknown;
context(@"with no permissions data", ^{
- context(@"deprecated groupStatusOfRPCs: method", ^{
- beforeEach(^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testResultStatus = [testPermissionsManager groupStatusOfRPCs:@[testRPCNameAllAllowed, testRPCNameAllDisallowed]];
- #pragma clang diagnostic pop
- });
-
- it(@"should return unknown", ^{
- expect(@(testResultStatus)).to(equal(@(SDLPermissionGroupStatusUnknown)));
- });
- });
+ it(@"should return unknown", ^{
+ testResultStatus = [testPermissionsManager groupStatusOfRPCPermissions:@[testPermissionElementAllAllowed, testPermissionElementFullLimitedAllowed]];
- context(@"groupStatusOfRPCPermissions: method", ^{
- beforeEach(^{
- testResultStatus = [testPermissionsManager groupStatusOfRPCPermissions:@[testPermissionElementAllAllowed, testPermissionElementFullLimitedAllowed]];
- });
-
- it(@"should return unknown", ^{
- expect(@(testResultStatus)).to(equal(@(SDLPermissionGroupStatusUnknown)));
- });
+ expect(@(testResultStatus)).to(equal(@(SDLPermissionGroupStatusUnknown)));
});
});
context(@"for an all allowed group", ^{
- context(@"deprecated groupStatusOfRPCs: method", ^{
- beforeEach(^{
- [[NSNotificationCenter defaultCenter] postNotification:limitedHMINotification];
- [[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testResultStatus = [testPermissionsManager groupStatusOfRPCs:@[testRPCNameAllAllowed, testRPCNameFullLimitedAllowed]];
- #pragma clang diagnostic pop
- });
-
- it(@"should return allowed", ^{
- expect(@(testResultStatus)).to(equal(@(SDLPermissionGroupStatusAllowed)));
- });
- });
-
- context(@"groupStatusOfRPCPermissions: method", ^{
- beforeEach(^{
- [[NSNotificationCenter defaultCenter] postNotification:limitedHMINotification];
- [[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
+ it(@"should return allowed", ^{
+ [[NSNotificationCenter defaultCenter] postNotification:limitedHMINotification];
+ [[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
- testResultStatus = [testPermissionsManager groupStatusOfRPCPermissions:@[testPermissionElementAllAllowed, testPermissionElementFullLimitedAllowed]];
- });
+ testResultStatus = [testPermissionsManager groupStatusOfRPCPermissions:@[testPermissionElementAllAllowed, testPermissionElementFullLimitedAllowed]];
- it(@"should return allowed", ^{
- expect(@(testResultStatus)).to(equal(@(SDLPermissionGroupStatusAllowed)));
- });
+ expect(@(testResultStatus)).to(equal(@(SDLPermissionGroupStatusAllowed)));
});
});
context(@"for an all disallowed group", ^{
- context(@"deprecated groupStatusOfRPCs: method", ^{
- beforeEach(^{
- [[NSNotificationCenter defaultCenter] postNotification:backgroundHMINotification];
- [[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testResultStatus = [testPermissionsManager groupStatusOfRPCs:@[testRPCNameFullLimitedAllowed, testRPCNameAllDisallowed]];
- #pragma clang diagnostic pop
- });
-
- it(@"should return disallowed", ^{
- expect(@(testResultStatus)).to(equal(@(SDLPermissionGroupStatusDisallowed)));
- });
- });
-
- context(@"groupStatusOfRPCPermissions: method", ^{
- beforeEach(^{
- [[NSNotificationCenter defaultCenter] postNotification:backgroundHMINotification];
- [[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
+ it(@"should return disallowed", ^{
+ [[NSNotificationCenter defaultCenter] postNotification:backgroundHMINotification];
+ [[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
- testResultStatus = [testPermissionsManager groupStatusOfRPCPermissions:@[testPermissionElementFullLimitedAllowed, testPermissionElementDisallowed]];
- });
+ testResultStatus = [testPermissionsManager groupStatusOfRPCPermissions:@[testPermissionElementFullLimitedAllowed, testPermissionElementDisallowed]];
- it(@"should return disallowed", ^{
- expect(@(testResultStatus)).to(equal(@(SDLPermissionGroupStatusDisallowed)));
- });
+ expect(@(testResultStatus)).to(equal(@(SDLPermissionGroupStatusDisallowed)));
});
});
context(@"for a mixed group", ^{
- context(@"deprecated groupStatusOfRPCs: method", ^{
- beforeEach(^{
- [[NSNotificationCenter defaultCenter] postNotification:limitedHMINotification];
- [[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testResultStatus = [testPermissionsManager groupStatusOfRPCs:@[testRPCNameAllAllowed, testRPCNameAllDisallowed]];
- #pragma clang diagnostic pop
- });
-
- it(@"should return mixed", ^{
- expect(@(testResultStatus)).to(equal(@(SDLPermissionGroupStatusMixed)));
- });
- });
-
- context(@"groupStatusOfRPCPermissions: method", ^{
- beforeEach(^{
- [[NSNotificationCenter defaultCenter] postNotification:limitedHMINotification];
- [[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
+ it(@"should return mixed", ^{
+ [[NSNotificationCenter defaultCenter] postNotification:limitedHMINotification];
+ [[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
- testResultStatus = [testPermissionsManager groupStatusOfRPCPermissions:@[testPermissionElementAllAllowed, testPermissionElementDisallowed]];
- });
+ testResultStatus = [testPermissionsManager groupStatusOfRPCPermissions:@[testPermissionElementAllAllowed, testPermissionElementDisallowed]];
- it(@"should return mixed", ^{
- expect(@(testResultStatus)).to(equal(@(SDLPermissionGroupStatusMixed)));
- });
+ expect(@(testResultStatus)).to(equal(@(SDLPermissionGroupStatusMixed)));
});
});
});
describe(@"checking the status of RPCs", ^{
- __block NSDictionary<SDLPermissionRPCName, NSNumber *> *testResultPermissionStatusDict = nil;
__block NSDictionary<SDLRPCFunctionName, SDLRPCPermissionStatus *> *testResultRPCPermissionStatusDict = nil;
__block SDLRPCPermissionStatus *allowedResultStatus = nil;
__block SDLRPCPermissionStatus *disallowedResultStatus = nil;
@@ -418,87 +274,49 @@ describe(@"SDLPermissionsManager", ^{
__block SDLRPCPermissionStatus *testDisallowedStatus = nil;
context(@"with no permissions data", ^{
- context(@"deprecated statusOfRPCs: method", ^{
- beforeEach(^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testResultPermissionStatusDict = [testPermissionsManager statusOfRPCs:@[testRPCNameAllAllowed, testRPCNameAllDisallowed]];
- #pragma clang diagnostic pop
- });
-
- it(@"should return correct permission statuses", ^{
- expect(testResultPermissionStatusDict[testRPCNameAllAllowed]).to(equal(@NO));
- expect(testResultPermissionStatusDict[testRPCNameAllDisallowed]).to(equal(@NO));
- });
- });
+ it(@"should return the correct permission statuses", ^{
+ testResultRPCPermissionStatusDict = [testPermissionsManager statusesOfRPCPermissions:@[testPermissionElementAllAllowed, testPermissionElementDisallowed]];
+ allowedResultStatus = testResultRPCPermissionStatusDict[testPermissionElementAllAllowed.rpcName];
+ disallowedResultStatus = testResultRPCPermissionStatusDict[testPermissionElementDisallowed.rpcName];
- context(@"statusesOfRPCPermissions: method", ^{
- beforeEach(^{
- testResultRPCPermissionStatusDict = [testPermissionsManager statusesOfRPCPermissions:@[testPermissionElementAllAllowed, testPermissionElementDisallowed]];
- allowedResultStatus = testResultRPCPermissionStatusDict[testPermissionElementAllAllowed.rpcName];
- disallowedResultStatus = testResultRPCPermissionStatusDict[testPermissionElementDisallowed.rpcName];
-
- testAllowedDict = [[NSDictionary alloc] initWithObjectsAndKeys:@(0), testRPCParameterNameAllAllowed, nil];
- testAllowedStatus = [[SDLRPCPermissionStatus alloc] initWithRPCName:testPermissionElementAllAllowed.rpcName isRPCAllowed:YES rpcParameters:testAllowedDict];
- testDisallowedDict = [[NSDictionary alloc] initWithObjectsAndKeys:@(0), testRPCParameterNameAllDisallowed, nil];
- testDisallowedStatus = [[SDLRPCPermissionStatus alloc] initWithRPCName:testPermissionElementDisallowed.rpcName isRPCAllowed:YES rpcParameters:testDisallowedDict];
- });
+ testAllowedDict = [[NSDictionary alloc] initWithObjectsAndKeys:@(0), testRPCParameterNameAllAllowed, nil];
+ testAllowedStatus = [[SDLRPCPermissionStatus alloc] initWithRPCName:testPermissionElementAllAllowed.rpcName isRPCAllowed:YES rpcParameters:testAllowedDict];
+ testDisallowedDict = [[NSDictionary alloc] initWithObjectsAndKeys:@(0), testRPCParameterNameAllDisallowed, nil];
+ testDisallowedStatus = [[SDLRPCPermissionStatus alloc] initWithRPCName:testPermissionElementDisallowed.rpcName isRPCAllowed:YES rpcParameters:testDisallowedDict];
- it(@"should return the correct permission statuses", ^{
- expect(allowedResultStatus.rpcName).to(equal(testAllowedStatus.rpcName));
- expect(allowedResultStatus.rpcParameters).to(equal(testAllowedStatus.rpcParameters));
- expect(allowedResultStatus.rpcAllowed).to(equal(@NO));
+ expect(allowedResultStatus.rpcName).to(equal(testAllowedStatus.rpcName));
+ expect(allowedResultStatus.rpcParameters).to(equal(testAllowedStatus.rpcParameters));
+ expect(allowedResultStatus.rpcAllowed).to(equal(@NO));
- expect(disallowedResultStatus.rpcName).to(equal(testDisallowedStatus.rpcName));
- expect(disallowedResultStatus.rpcParameters).to(equal(testDisallowedStatus.rpcParameters));
- expect(disallowedResultStatus.rpcAllowed).to(equal(@NO));
- });
+ expect(disallowedResultStatus.rpcName).to(equal(testDisallowedStatus.rpcName));
+ expect(disallowedResultStatus.rpcParameters).to(equal(testDisallowedStatus.rpcParameters));
+ expect(disallowedResultStatus.rpcAllowed).to(equal(@NO));
});
});
context(@"with permissions data", ^{
- context(@"deprecated statusOfRPCs: method", ^{
- beforeEach(^{
- [[NSNotificationCenter defaultCenter] postNotification:limitedHMINotification];
- [[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testResultPermissionStatusDict = [testPermissionsManager statusOfRPCs:@[testRPCNameAllAllowed, testRPCNameAllDisallowed]];
- #pragma clang diagnostic pop
- });
-
- it(@"should return correct permission statuses", ^{
- expect(testResultPermissionStatusDict[testRPCNameAllAllowed]).to(equal(@YES));
- expect(testResultPermissionStatusDict[testRPCNameAllDisallowed]).to(equal(@NO));
- });
- });
-
- context(@"statusesOfRPCPermissions: method", ^{
- beforeEach(^{
- [[NSNotificationCenter defaultCenter] postNotification:limitedHMINotification];
- [[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
+ it(@"should return the correct permission statuses", ^{
+ [[NSNotificationCenter defaultCenter] postNotification:limitedHMINotification];
+ [[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
- testResultRPCPermissionStatusDict = [testPermissionsManager statusesOfRPCPermissions:@[testPermissionElementAllAllowed, testPermissionElementDisallowed]];
+ testResultRPCPermissionStatusDict = [testPermissionsManager statusesOfRPCPermissions:@[testPermissionElementAllAllowed, testPermissionElementDisallowed]];
- allowedResultStatus = testResultRPCPermissionStatusDict[testPermissionElementAllAllowed.rpcName];
- disallowedResultStatus = testResultRPCPermissionStatusDict[testPermissionElementDisallowed.rpcName];
+ allowedResultStatus = testResultRPCPermissionStatusDict[testPermissionElementAllAllowed.rpcName];
+ disallowedResultStatus = testResultRPCPermissionStatusDict[testPermissionElementDisallowed.rpcName];
- testAllowedDict = [[NSDictionary alloc] initWithObjectsAndKeys:@(1), testRPCParameterNameAllAllowed, nil];
- testAllowedStatus = [[SDLRPCPermissionStatus alloc] initWithRPCName:testPermissionElementAllAllowed.rpcName isRPCAllowed:YES rpcParameters:testAllowedDict];
+ testAllowedDict = [[NSDictionary alloc] initWithObjectsAndKeys:@(1), testRPCParameterNameAllAllowed, nil];
+ testAllowedStatus = [[SDLRPCPermissionStatus alloc] initWithRPCName:testPermissionElementAllAllowed.rpcName isRPCAllowed:YES rpcParameters:testAllowedDict];
- testDisallowedDict = [[NSDictionary alloc] initWithObjectsAndKeys:@(0), testRPCParameterNameAllDisallowed, nil];
- testDisallowedStatus = [[SDLRPCPermissionStatus alloc] initWithRPCName:testPermissionElementDisallowed.rpcName isRPCAllowed:NO rpcParameters:testDisallowedDict];
- });
+ testDisallowedDict = [[NSDictionary alloc] initWithObjectsAndKeys:@(0), testRPCParameterNameAllDisallowed, nil];
+ testDisallowedStatus = [[SDLRPCPermissionStatus alloc] initWithRPCName:testPermissionElementDisallowed.rpcName isRPCAllowed:NO rpcParameters:testDisallowedDict];
- it(@"should return the correct permission statuses", ^{
- expect(allowedResultStatus.rpcName).to(equal(testAllowedStatus.rpcName));
- expect(allowedResultStatus.rpcParameters).to(equal(testAllowedStatus.rpcParameters));
- expect(allowedResultStatus.rpcAllowed).to(equal(testAllowedStatus.rpcAllowed));
+ expect(allowedResultStatus.rpcName).to(equal(testAllowedStatus.rpcName));
+ expect(allowedResultStatus.rpcParameters).to(equal(testAllowedStatus.rpcParameters));
+ expect(allowedResultStatus.rpcAllowed).to(equal(testAllowedStatus.rpcAllowed));
- expect(disallowedResultStatus.rpcName).to(equal(testDisallowedStatus.rpcName));
- expect(disallowedResultStatus.rpcParameters).to(equal(testDisallowedStatus.rpcParameters));
- expect(disallowedResultStatus.rpcAllowed).to(equal(testDisallowedStatus.rpcAllowed));
- });
+ expect(disallowedResultStatus.rpcName).to(equal(testDisallowedStatus.rpcName));
+ expect(disallowedResultStatus.rpcParameters).to(equal(testDisallowedStatus.rpcParameters));
+ expect(disallowedResultStatus.rpcAllowed).to(equal(testDisallowedStatus.rpcAllowed));
});
});
});
@@ -508,654 +326,402 @@ describe(@"SDLPermissionsManager", ^{
context(@"when no data is present", ^{
__block BOOL testObserverCalled = NO;
__block SDLPermissionGroupStatus testObserverStatus = SDLPermissionGroupStatusUnknown;
- __block NSDictionary<SDLPermissionRPCName,NSNumber *> *testObserverChangeDict = nil;
+ __block NSDictionary<SDLRPCFunctionName,SDLRPCPermissionStatus *> *testObserverChangeDict = nil;
beforeEach(^{
testObserverCalled = NO;
testObserverStatus = SDLPermissionGroupStatusUnknown;
testObserverChangeDict = nil;
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- [testPermissionsManager addObserverForRPCs:@[testRPCNameAllAllowed, testRPCNameAllDisallowed] groupType:SDLPermissionGroupTypeAny withHandler:^(NSDictionary<SDLPermissionRPCName,NSNumber *> * _Nonnull change, SDLPermissionGroupStatus status) {
- testObserverChangeDict = change;
+
+ [testPermissionsManager subscribeToRPCPermissions:@[testPermissionElementAllAllowed, testPermissionElementDisallowed] groupType:SDLPermissionGroupTypeAny withHandler:^(NSDictionary<SDLRPCFunctionName,SDLRPCPermissionStatus *> * _Nonnull updatedPermissionStatuses, SDLPermissionGroupStatus status) {
+ testObserverChangeDict = updatedPermissionStatuses;
testObserverStatus = status;
testObserverCalled = YES;
}];
- #pragma clang diagnostic pop
});
it(@"should return correct permission statuses", ^{
expect(@(testObserverCalled)).to(equal(@YES));
expect(@(testObserverStatus)).to(equal(@(SDLPermissionGroupStatusUnknown)));
- expect(testObserverChangeDict[testRPCNameAllAllowed]).to(equal(@NO));
- expect(testObserverChangeDict[testRPCNameAllDisallowed]).to(equal(@NO));
+ expect(testObserverChangeDict[testRPCNameAllAllowed].rpcAllowed).to(equal(@NO));
+ expect(testObserverChangeDict[testRPCNameAllDisallowed].rpcAllowed).to(equal(@NO));
});
});
context(@"when data is already present", ^{
__block NSInteger numberOfTimesObserverCalled = 0;
- __block NSDictionary<SDLPermissionRPCName,NSNumber *> *testObserverBlockChangedDict = nil;
+ __block NSDictionary<SDLRPCFunctionName,SDLRPCPermissionStatus *> *testObserverBlockChangedDict = nil;
__block SDLPermissionGroupStatus testObserverReturnStatus = SDLPermissionGroupStatusUnknown;
+ beforeEach(^{
+ numberOfTimesObserverCalled = 0;
+ testObserverBlockChangedDict = nil;
+ testObserverReturnStatus = SDLPermissionGroupStatusUnknown;
+ });
+
context(@"to match an ANY observer", ^{
beforeEach(^{
- // Reset vars
- numberOfTimesObserverCalled = 0;
-
// Post the notification before setting the observer to make sure data is already present
// HMI Full & Limited allowed
[[NSNotificationCenter defaultCenter] postNotification:limitedHMINotification];
[[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
- // This should be called twice, once for each RPC being observed. It should be called immediately since data should already be present
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- [testPermissionsManager addObserverForRPCs:@[testRPCNameAllAllowed, testRPCNameAllDisallowed] groupType:SDLPermissionGroupTypeAny withHandler:^(NSDictionary<SDLPermissionRPCName, NSNumber *> * _Nonnull changedDict, SDLPermissionGroupStatus status) {
+ // This should be called should be called immediately since the `groupType` is `any`
+ [testPermissionsManager subscribeToRPCPermissions:@[testPermissionElementAllAllowed, testPermissionElementDisallowed] groupType:SDLPermissionGroupTypeAny withHandler:^(NSDictionary<SDLRPCFunctionName,SDLRPCPermissionStatus *> * _Nonnull updatedPermissionStatuses, SDLPermissionGroupStatus status) {
numberOfTimesObserverCalled++;
- testObserverBlockChangedDict = changedDict;
+ testObserverBlockChangedDict = updatedPermissionStatuses;
testObserverReturnStatus = status;
}];
- #pragma clang diagnostic pop
});
it(@"should call the observer with proper status", ^{
- expect(@(numberOfTimesObserverCalled)).to(equal(@1));
- expect(testObserverBlockChangedDict[testRPCNameAllAllowed]).to(equal(@YES));
- expect(testObserverBlockChangedDict[testRPCNameAllDisallowed]).to(equal(@NO));
- expect(testObserverBlockChangedDict.allKeys).to(haveCount(@2));
- expect(@(testObserverReturnStatus)).to(equal(@(SDLPermissionGroupStatusMixed)));
+ expect(numberOfTimesObserverCalled).to(equal(1));
+ expect(testObserverBlockChangedDict[testRPCNameAllAllowed].rpcAllowed).to(beTrue());
+ expect(testObserverBlockChangedDict[testRPCNameAllDisallowed].rpcAllowed).to(beFalse());
+ expect(testObserverBlockChangedDict.allKeys).to(haveCount(2));
+ expect(@(testObserverReturnStatus)).to(equal(SDLPermissionGroupStatusMixed));
});
});
- context(@"to match an all allowed observer", ^{
+ context(@"to match an All Allowed observer", ^{
beforeEach(^{
- // Reset vars
- numberOfTimesObserverCalled = 0;
-
// Post the notification before setting the observer to make sure data is already present
// HMI Full & Limited allowed, hmi level LIMITED
[[NSNotificationCenter defaultCenter] postNotification:limitedHMINotification];
[[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
- // This should be called twice, once for each RPC being observed. It should be called immediately since data should already be present
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- [testPermissionsManager addObserverForRPCs:@[testRPCNameAllAllowed, testRPCNameFullLimitedAllowed] groupType:SDLPermissionGroupTypeAllAllowed withHandler:^(NSDictionary<SDLPermissionRPCName,NSNumber *> * _Nonnull change, SDLPermissionGroupStatus status) {
+ // This should be called called immediately since data is already present and all rpcs are allowed
+ [testPermissionsManager subscribeToRPCPermissions:@[testPermissionElementAllAllowed, testPermissionElementFullLimitedAllowed] groupType:SDLPermissionGroupTypeAllAllowed withHandler:^(NSDictionary<SDLRPCFunctionName,SDLRPCPermissionStatus *> * _Nonnull updatedPermissionStatuses, SDLPermissionGroupStatus status) {
numberOfTimesObserverCalled++;
- testObserverBlockChangedDict = change;
+ testObserverBlockChangedDict = updatedPermissionStatuses;
testObserverReturnStatus = status;
}];
- #pragma clang diagnostic pop
});
it(@"should call the observer with proper status", ^{
- expect(@(numberOfTimesObserverCalled)).to(equal(@1));
- expect(testObserverBlockChangedDict[testRPCNameAllAllowed]).to(equal(@YES));
- expect(testObserverBlockChangedDict[testRPCNameFullLimitedAllowed]).to(equal(@YES));
- expect(testObserverBlockChangedDict.allKeys).to(haveCount(@2));
- expect(@(testObserverReturnStatus)).to(equal(@(SDLPermissionGroupStatusAllowed)));
+ expect(numberOfTimesObserverCalled).to(equal(1));
+ expect(testObserverBlockChangedDict[testRPCNameAllAllowed].rpcAllowed).to(beTrue());
+ expect(testObserverBlockChangedDict[testRPCNameFullLimitedAllowed].rpcAllowed).to(beTrue());
+ expect(testObserverBlockChangedDict.allKeys).to(haveCount(2));
+ expect(@(testObserverReturnStatus)).to(equal(SDLPermissionGroupStatusAllowed));
});
});
- context(@"that does not match an all allowed observer", ^{
+ context(@"that does not match an All Allowed observer", ^{
beforeEach(^{
- // Reset vars
- numberOfTimesObserverCalled = 0;
-
// Post the notification before setting the observer to make sure data is already present
// HMI Full & Limited allowed, hmi level NONE
[[NSNotificationCenter defaultCenter] postNotification:noneHMINotification];
[[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
- // This should be called twice, once for each RPC being observed. It should be called immediately since data should already be present
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- [testPermissionsManager addObserverForRPCs:@[testRPCNameAllDisallowed, testRPCNameFullLimitedAllowed] groupType:SDLPermissionGroupTypeAllAllowed withHandler:^(NSDictionary<SDLPermissionRPCName,NSNumber *> * _Nonnull change, SDLPermissionGroupStatus status) {
+ // This should not be called at all since not all rpcs are allowed
+ [testPermissionsManager subscribeToRPCPermissions:@[testPermissionElementDisallowed, testPermissionElementFullLimitedAllowed] groupType:SDLPermissionGroupTypeAllAllowed withHandler:^(NSDictionary<SDLRPCFunctionName,SDLRPCPermissionStatus *> * _Nonnull updatedPermissionStatuses, SDLPermissionGroupStatus status) {
numberOfTimesObserverCalled++;
+ testObserverBlockChangedDict = updatedPermissionStatuses;
testObserverReturnStatus = status;
}];
- #pragma clang diagnostic pop
});
- it(@"should call the observer with status Disallowed", ^{
- expect(@(numberOfTimesObserverCalled)).to(equal(@1));
- expect(@(testObserverReturnStatus)).to(equal(@(SDLPermissionGroupStatusDisallowed)));
+ it(@"should not call the observer", ^{
+ expect(numberOfTimesObserverCalled).to(equal(0));
+ expect(testObserverBlockChangedDict).to(beNil());
+ expect(@(testObserverReturnStatus)).to(equal(SDLPermissionGroupStatusUnknown));
});
});
});
});
- describe(@"adding a new observer with subscribeToRPCPermissions:groupType:Handler", ^{
- context(@"when no data is present", ^{
- __block BOOL testObserverCalled = NO;
-
- beforeEach(^{
- testObserverCalled = NO;
- [testPermissionsManager subscribeToRPCPermissions:@[testPermissionElementAllAllowed, testPermissionElementDisallowed] groupType:SDLPermissionGroupTypeAny withHandler:^(NSDictionary<SDLPermissionRPCName,NSNumber *> * _Nonnull change, SDLPermissionGroupStatus status) {
- testObserverCalled = YES;
- }];
- });
-
- it(@"should be called", ^{
- expect(testObserverCalled).to(beTrue());
- });
- });
-
- context(@"when data is present", ^{
- __block BOOL testObserverCalled = NO;
-
- beforeEach(^{
- testObserverCalled = NO;
-
- // Post the notification before setting the observer to make sure data is already present
- // HMI Full & Limited allowed
- [[NSNotificationCenter defaultCenter] postNotification:limitedHMINotification];
- [[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
-
- // This should not be called even with data currently present, the handler will only be called when an permissions update occurs after the RPC is subscribed to
- [testPermissionsManager subscribeToRPCPermissions:@[testPermissionElementAllAllowed, testPermissionElementDisallowed] groupType:SDLPermissionGroupTypeAny withHandler:^(NSDictionary<SDLPermissionRPCName,NSNumber *> * _Nonnull change, SDLPermissionGroupStatus status) {
- testObserverCalled = YES;
- }];
- });
-
- it(@"should be called", ^{
- expect(@(testObserverCalled)).to(beTrue());
- });
- });
- });
-
- context(@"updating an observer with new permission data", ^{
+ context(@"getting new permission data", ^{
__block NSInteger numberOfTimesObserverCalled = 0;
-
- __block SDLOnPermissionsChange *testPermissionChangeUpdate = nil;
- __block SDLPermissionItem *testPermissionUpdated = nil;
- __block NSMutableArray<NSDictionary<SDLPermissionRPCName,NSNumber*> *> *changeDicts = nil;
+ __block NSMutableArray<NSDictionary<SDLRPCFunctionName,SDLRPCPermissionStatus *> *> *changeDicts = nil;
__block NSMutableArray<NSNumber<SDLUInt> *> *testStatuses = nil;
- context(@"to match an ANY observer", ^{
- beforeEach(^{
- // Reset vars
- numberOfTimesObserverCalled = 0;
- changeDicts = [NSMutableArray array];
- testStatuses = [NSMutableArray array];
+ beforeEach(^{
+ numberOfTimesObserverCalled = 0;
+ changeDicts = [NSMutableArray array];
+ testStatuses = [NSMutableArray array];
+ });
+ context(@"with an ANY group type observer", ^{
+ beforeEach(^{
// Post the notification before setting the observer to make sure data is already present
// HMI Full & Limited allowed, hmi level LIMITED
[[NSNotificationCenter defaultCenter] postNotification:limitedHMINotification];
[[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
// Set an observer that should be called immediately for the preexisting data, then called again when new data is sent
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- [testPermissionsManager addObserverForRPCs:@[testRPCNameAllAllowed, testRPCNameAllDisallowed] groupType:SDLPermissionGroupTypeAny withHandler:^(NSDictionary<SDLPermissionRPCName,NSNumber *> * _Nonnull changedDict, SDLPermissionGroupStatus status) {
+ [testPermissionsManager subscribeToRPCPermissions:@[testPermissionElementAllAllowed, testPermissionElementDisallowed] groupType:SDLPermissionGroupTypeAny withHandler:^(NSDictionary<SDLRPCFunctionName,SDLRPCPermissionStatus *> * _Nonnull updatedPermissionStatuses, SDLPermissionGroupStatus status) {
numberOfTimesObserverCalled++;
- [changeDicts addObject:changedDict];
+ [changeDicts addObject:updatedPermissionStatuses];
}];
- #pragma clang diagnostic pop
+ });
+ it(@"should notify the observer when permissions have changed", ^{
// Create a permission update disallowing our current HMI level for the observed permission
- SDLParameterPermissions *testParameterPermissions = [[SDLParameterPermissions alloc] init];
SDLHMIPermissions *testHMIPermissionsUpdated = [[SDLHMIPermissions alloc] init];
testHMIPermissionsUpdated.allowed = @[SDLHMILevelBackground, SDLHMILevelFull];
testHMIPermissionsUpdated.userDisallowed = @[SDLHMILevelLimited, SDLHMILevelNone];
- testPermissionUpdated = [[SDLPermissionItem alloc] init];
+ SDLPermissionItem *testPermissionUpdated = [[SDLPermissionItem alloc] init];
testPermissionUpdated.rpcName = testRPCNameAllAllowed;
testPermissionUpdated.hmiPermissions = testHMIPermissionsUpdated;
- testPermissionUpdated.parameterPermissions = testParameterPermissions;
+ testPermissionUpdated.parameterPermissions = [[SDLParameterPermissions alloc] init];
- testPermissionChangeUpdate = [[SDLOnPermissionsChange alloc] init];
+ SDLOnPermissionsChange *testPermissionChangeUpdate = [[SDLOnPermissionsChange alloc] init];
testPermissionChangeUpdate.permissionItem = [NSArray arrayWithObject:testPermissionUpdated];
// Send the permission update
SDLRPCNotificationNotification *updatedNotification = [[SDLRPCNotificationNotification alloc] initWithName:SDLDidChangePermissionsNotification object:nil rpcNotification:testPermissionChangeUpdate];
[[NSNotificationCenter defaultCenter] postNotification:updatedNotification];
- });
- it(@"should call the observer twice", ^{
- expect(@(numberOfTimesObserverCalled)).to(equal(@2));
- });
+ expect(numberOfTimesObserverCalled).to(equal(2));
- it(@"should have proper data in the first change dict", ^{
expect(changeDicts[0].allKeys).to(contain(testRPCNameAllAllowed));
expect(changeDicts[0].allKeys).to(contain(testRPCNameAllDisallowed));
+ SDLRPCPermissionStatus *allAllowed1 = changeDicts[0][testRPCNameAllAllowed];
+ expect(allAllowed1.rpcAllowed).to(beTrue());
+ SDLRPCPermissionStatus *allDisallowed1 = changeDicts[0][testRPCNameAllDisallowed];
+ expect(allDisallowed1.rpcAllowed).to(beFalse());
- NSNumber<SDLBool> *allAllowed = changeDicts[0][testRPCNameAllAllowed];
- expect(allAllowed).to(equal(@YES));
-
- NSNumber<SDLBool> *allDisallowed = changeDicts[0][testRPCNameAllDisallowed];
- expect(allDisallowed).to(equal(@NO));
- });
-
- it(@"should have the proper data in the second change dict", ^{
expect(changeDicts[1].allKeys).to(contain(testRPCNameAllAllowed));
expect(changeDicts[1].allKeys).to(contain(testRPCNameAllDisallowed));
-
- NSNumber<SDLBool> *allAllowed = changeDicts[1][testRPCNameAllAllowed];
- expect(allAllowed).to(equal(@NO));
-
- NSNumber<SDLBool> *allDisallowed = changeDicts[1][testRPCNameAllDisallowed];
- expect(allDisallowed).to(equal(@NO));
+ SDLRPCPermissionStatus *allAllowed2 = changeDicts[1][testRPCNameAllAllowed];
+ expect(allAllowed2.rpcAllowed).to(beFalse());
+ SDLRPCPermissionStatus *allDisallowed2 = changeDicts[1][testRPCNameAllDisallowed];
+ expect(allDisallowed2.rpcAllowed).to(beFalse());
});
- describe(@"when the permission has not changed", ^{
- __block SDLOnPermissionsChange *testPermissionChangeUpdateNoChange = nil;
- __block SDLPermissionItem *testPermissionUpdatedNoChange = nil;
-
- beforeEach(^{
- numberOfTimesObserverCalled = 0;
-
- // Create a permission update disallowing our current HMI level for the observed permission
- SDLParameterPermissions *testParameterPermissions = [[SDLParameterPermissions alloc] init];
- SDLHMIPermissions *testHMIPermissionsUpdated = [[SDLHMIPermissions alloc] init];
- testHMIPermissionsUpdated.allowed = @[SDLHMILevelBackground, SDLHMILevelFull];
- testHMIPermissionsUpdated.userDisallowed = @[SDLHMILevelLimited, SDLHMILevelNone];
-
- testPermissionUpdatedNoChange = [[SDLPermissionItem alloc] init];
- testPermissionUpdatedNoChange.rpcName = testRPCNameAllAllowed;
- testPermissionUpdatedNoChange.hmiPermissions = testHMIPermissionsUpdated;
- testPermissionUpdatedNoChange.parameterPermissions = testParameterPermissions;
+ it(@"should not notify the observer if permissions have not changed", ^{
+ SDLOnPermissionsChange *testNoPermissionChangeUpdate = [[SDLOnPermissionsChange alloc] init];
+ testNoPermissionChangeUpdate.permissionItem = [NSArray arrayWithObject:testPermissionElementAllAllowed];
- testPermissionChangeUpdateNoChange = [[SDLOnPermissionsChange alloc] init];
- testPermissionChangeUpdateNoChange.permissionItem = [NSArray arrayWithObject:testPermissionUpdated];
+ // Send the permission update
+ SDLRPCNotificationNotification *updatedNotification = [[SDLRPCNotificationNotification alloc] initWithName:SDLDidChangePermissionsNotification object:nil rpcNotification:testNoPermissionChangeUpdate];
+ [[NSNotificationCenter defaultCenter] postNotification:updatedNotification];
- // Send the permission update
- SDLRPCNotificationNotification *updatedNotification = [[SDLRPCNotificationNotification alloc] initWithName:SDLDidChangePermissionsNotification object:nil rpcNotification:testPermissionChangeUpdate];
- [[NSNotificationCenter defaultCenter] postNotification:updatedNotification];
- });
+ expect(numberOfTimesObserverCalled).to(equal(1));
- it(@"should not call the filter observer again", ^{
- expect(numberOfTimesObserverCalled).to(equal(0));
- });
+ expect(changeDicts[0].allKeys).to(contain(testRPCNameAllAllowed));
+ expect(changeDicts[0].allKeys).to(contain(testRPCNameAllDisallowed));
+ SDLRPCPermissionStatus *allAllowed = changeDicts[0][testRPCNameAllAllowed];
+ expect(allAllowed.rpcAllowed).to(beTrue());
+ SDLRPCPermissionStatus *allDisallowed = changeDicts[0][testRPCNameAllDisallowed];
+ expect(allDisallowed.rpcAllowed).to(beFalse());
});
});
- context(@"to match an all allowed observer", ^{
+ context(@"with an All Allowed group type observer", ^{
beforeEach(^{
- // Reset vars
- numberOfTimesObserverCalled = 0;
- changeDicts = [NSMutableArray array];
- testStatuses = [NSMutableArray array];
-
// Post the notification before setting the observer to make sure data is already present
// HMI Full & Limited allowed, hmi level BACKGROUND
[[NSNotificationCenter defaultCenter] postNotification:backgroundHMINotification];
[[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
});
- context(@"so that it becomes All Allowed", ^{
- beforeEach(^{
- // Set an observer that should be called immediately for the preexisting data, then called again when new data is sent
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- [testPermissionsManager addObserverForRPCs:@[testRPCNameAllDisallowed, testRPCNameFullLimitedBackgroundAllowed] groupType:SDLPermissionGroupTypeAllAllowed withHandler:^(NSDictionary<SDLPermissionRPCName,NSNumber *> * _Nonnull change, SDLPermissionGroupStatus status) {
- numberOfTimesObserverCalled++;
- [changeDicts addObject:change];
- [testStatuses addObject:@(status)];
- }];
- #pragma clang diagnostic pop
-
- // Create a permission update allowing our current HMI level for the observed permission
- SDLParameterPermissions *testParameterPermissions = [[SDLParameterPermissions alloc] init];
- SDLHMIPermissions *testHMIPermissionsUpdated = [[SDLHMIPermissions alloc] init];
- testHMIPermissionsUpdated.allowed = @[SDLHMILevelLimited, SDLHMILevelNone, SDLHMILevelBackground, SDLHMILevelFull];
- testHMIPermissionsUpdated.userDisallowed = @[];
-
- testPermissionUpdated = [[SDLPermissionItem alloc] init];
- testPermissionUpdated.rpcName = testRPCNameAllDisallowed;
- testPermissionUpdated.hmiPermissions = testHMIPermissionsUpdated;
- testPermissionUpdated.parameterPermissions = testParameterPermissions;
-
- testPermissionChangeUpdate = [[SDLOnPermissionsChange alloc] init];
- testPermissionChangeUpdate.permissionItem = [NSArray arrayWithObject:testPermissionUpdated];
-
- // Send the permission update
- SDLRPCNotificationNotification *updatedNotification = [[SDLRPCNotificationNotification alloc] initWithName:SDLDidChangePermissionsNotification object:nil rpcNotification:testPermissionChangeUpdate];
- [[NSNotificationCenter defaultCenter] postNotification:updatedNotification];
- });
-
- it(@"should call the observer twice", ^{
- expect(@(numberOfTimesObserverCalled)).to(equal(@2));
- });
-
- it(@"should have proper data in the first change dict", ^{
- expect(changeDicts[0].allKeys).to(haveCount(@2));
- expect(testStatuses[0]).to(equal(@(SDLPermissionGroupStatusMixed)));
- });
-
- it(@"should have the proper data in the second change dict", ^{
- expect(changeDicts[1].allKeys).to(haveCount(@2));
- expect(testStatuses[1]).to(equal(@(SDLPermissionGroupStatusAllowed)));
- });
- });
-
- context(@"so that it goes from All Allowed to mixed", ^{
- beforeEach(^{
- // Set an observer that should be called immediately for the preexisting data, then called again when new data is sent
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- [testPermissionsManager addObserverForRPCs:@[testRPCNameAllAllowed] groupType:SDLPermissionGroupTypeAllAllowed withHandler:^(NSDictionary<SDLPermissionRPCName,NSNumber *> * _Nonnull change, SDLPermissionGroupStatus status) {
- numberOfTimesObserverCalled++;
- [changeDicts addObject:change];
- [testStatuses addObject:@(status)];
- }];
- #pragma clang diagnostic pop
-
- // Create a permission update disallowing our current HMI level for the observed permission
- SDLParameterPermissions *testParameterPermissions = [[SDLParameterPermissions alloc] init];
- SDLHMIPermissions *testHMIPermissionsUpdated = [[SDLHMIPermissions alloc] init];
- testHMIPermissionsUpdated.allowed = @[];
- testHMIPermissionsUpdated.userDisallowed = @[SDLHMILevelBackground, SDLHMILevelFull, SDLHMILevelLimited, SDLHMILevelNone];
-
- testPermissionUpdated = [[SDLPermissionItem alloc] init];
- testPermissionUpdated.rpcName = testRPCNameAllAllowed;
- testPermissionUpdated.hmiPermissions = testHMIPermissionsUpdated;
- testPermissionUpdated.parameterPermissions = testParameterPermissions;
-
- testPermissionChangeUpdate = [[SDLOnPermissionsChange alloc] init];
- testPermissionChangeUpdate.permissionItem = [NSArray arrayWithObject:testPermissionUpdated];
+ it(@"should notify the observer when permissions change from some-not-allowed to all-allowed", ^{
+ [testPermissionsManager subscribeToRPCPermissions:@[testPermissionElementAllAllowed, testPermissionElementFullLimitedAllowed] groupType:SDLPermissionGroupTypeAllAllowed withHandler:^(NSDictionary<SDLRPCFunctionName,SDLRPCPermissionStatus *> * _Nonnull updatedPermissionStatuses, SDLPermissionGroupStatus status) {
+ numberOfTimesObserverCalled++;
+ [changeDicts addObject:updatedPermissionStatuses];
+ [testStatuses addObject:@(status)];
+ }];
- // Send the permission update
- SDLRPCNotificationNotification *updatedNotification = [[SDLRPCNotificationNotification alloc] initWithName:SDLDidChangePermissionsNotification object:nil rpcNotification:testPermissionChangeUpdate];
- [[NSNotificationCenter defaultCenter] postNotification:updatedNotification];
- });
+ SDLHMIPermissions *testHMIPermissionsUpdated = [[SDLHMIPermissions alloc] init];
+ testHMIPermissionsUpdated.allowed = @[SDLHMILevelBackground, SDLHMILevelFull, SDLHMILevelLimited];
+ testHMIPermissionsUpdated.userDisallowed = @[SDLHMILevelNone];
- it(@"should call the observer twice", ^{
- expect(@(numberOfTimesObserverCalled)).to(equal(@2));
- });
+ SDLParameterPermissions *updatedParameterPermissions = [[SDLParameterPermissions alloc] init];
+ updatedParameterPermissions.userDisallowed = @[];
+ updatedParameterPermissions.allowed = @[testRPCNameFullLimitedAllowed];
- it(@"should have proper data in the first change dict", ^{
- expect(testStatuses[0]).to(equal(@(SDLPermissionGroupStatusAllowed)));
- expect(changeDicts[0].allKeys).to(contain(testRPCNameAllAllowed));
+ SDLPermissionItem *testPermissionUpdated = [[SDLPermissionItem alloc] init];
+ testPermissionUpdated.rpcName = testRPCNameFullLimitedAllowed;
+ testPermissionUpdated.hmiPermissions = testHMIPermissionsUpdated;
+ testPermissionUpdated.parameterPermissions = updatedParameterPermissions;
- NSNumber<SDLBool> *isAllowed = changeDicts[0][testRPCNameAllAllowed];
- expect(isAllowed).to(equal(@YES));
- });
+ SDLOnPermissionsChange *testPermissionChangeUpdate = [[SDLOnPermissionsChange alloc] init];
+ testPermissionChangeUpdate.permissionItem = [NSArray arrayWithObject:testPermissionUpdated];
- it(@"should have the proper data in the second change dict", ^{
- expect(testStatuses[1]).to(equal(@(SDLPermissionGroupStatusDisallowed)));
- expect(changeDicts[1].allKeys).to(contain(testRPCNameAllAllowed));
+ // Send the permission update
+ SDLRPCNotificationNotification *updatedNotification = [[SDLRPCNotificationNotification alloc] initWithName:SDLDidChangePermissionsNotification object:nil rpcNotification:testPermissionChangeUpdate];
+ [[NSNotificationCenter defaultCenter] postNotification:updatedNotification];
- NSNumber<SDLBool> *isAllowed = changeDicts[1][testRPCNameAllAllowed];
- expect(isAllowed).to(equal(@NO));
- });
+ expect(numberOfTimesObserverCalled).to(equal(1));
+ expect(testStatuses[0]).to(equal(SDLPermissionGroupStatusAllowed));
+ expect(changeDicts[0].allKeys).to(contain(testRPCNameFullLimitedAllowed));
+ SDLRPCPermissionStatus *isAllowed = changeDicts[0][testRPCNameFullLimitedAllowed];
+ expect(isAllowed.rpcAllowed).to(beTrue());
});
- });
- context(@"to not match an all allowed observer", ^{
- beforeEach(^{
- // Reset vars
- numberOfTimesObserverCalled = 0;
- changeDicts = [NSMutableArray array];
- testStatuses = [NSMutableArray array];
+ it(@"should notify the observer when permissions change from all-allowed to some-not-allowed", ^{
+ [testPermissionsManager subscribeToRPCPermissions:@[testPermissionElementAllAllowed] groupType:SDLPermissionGroupTypeAllAllowed withHandler:^(NSDictionary<SDLRPCFunctionName,SDLRPCPermissionStatus *> * _Nonnull updatedPermissionStatuses, SDLPermissionGroupStatus status) {
+ numberOfTimesObserverCalled++;
+ [changeDicts addObject:updatedPermissionStatuses];
+ [testStatuses addObject:@(status)];
+ }];
- // Post the notification before setting the observer to make sure data is already present
- // HMI Full & Limited allowed, hmi level BACKGROUND
- [[NSNotificationCenter defaultCenter] postNotification:backgroundHMINotification];
- [[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
- });
+ // Create a permission update disallowing our current HMI level for the observed permission
+ SDLParameterPermissions *testParameterPermissions = [[SDLParameterPermissions alloc] init];
+ SDLHMIPermissions *testHMIPermissionsUpdated = [[SDLHMIPermissions alloc] init];
+ testHMIPermissionsUpdated.allowed = @[];
+ testHMIPermissionsUpdated.userDisallowed = @[SDLHMILevelBackground, SDLHMILevelFull, SDLHMILevelLimited, SDLHMILevelNone];
- context(@"from mixed to disallowed", ^{
- beforeEach(^{
- // Set an observer that should be called immediately for the preexisting data, then called again when new data is sent
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- [testPermissionsManager addObserverForRPCs:@[testRPCNameAllAllowed, testRPCNameAllDisallowed] groupType:SDLPermissionGroupTypeAllAllowed withHandler:^(NSDictionary<SDLPermissionRPCName,NSNumber *> * _Nonnull change, SDLPermissionGroupStatus status) {
- numberOfTimesObserverCalled++;
- [changeDicts addObject:change];
- [testStatuses addObject:@(status)];
- }];
- #pragma clang diagnostic pop
+ SDLPermissionItem *testPermissionUpdated = [[SDLPermissionItem alloc] init];
+ testPermissionUpdated.rpcName = testRPCNameAllAllowed;
+ testPermissionUpdated.hmiPermissions = testHMIPermissionsUpdated;
+ testPermissionUpdated.parameterPermissions = testParameterPermissions;
- // Create a permission update disallowing our current HMI level for the observed permission
- SDLParameterPermissions *testParameterPermissions = [[SDLParameterPermissions alloc] init];
- SDLHMIPermissions *testHMIPermissionsUpdated = [[SDLHMIPermissions alloc] init];
- testHMIPermissionsUpdated.allowed = @[];
- testHMIPermissionsUpdated.userDisallowed = @[SDLHMILevelBackground, SDLHMILevelFull, SDLHMILevelLimited, SDLHMILevelNone];
+ SDLOnPermissionsChange *testPermissionChangeUpdate = [[SDLOnPermissionsChange alloc] init];
+ testPermissionChangeUpdate.permissionItem = [NSArray arrayWithObject:testPermissionUpdated];
- testPermissionUpdated = [[SDLPermissionItem alloc] init];
- testPermissionUpdated.rpcName = testRPCNameAllAllowed;
- testPermissionUpdated.hmiPermissions = testHMIPermissionsUpdated;
- testPermissionUpdated.parameterPermissions = testParameterPermissions;
+ // Send the permission update
+ SDLRPCNotificationNotification *updatedNotification = [[SDLRPCNotificationNotification alloc] initWithName:SDLDidChangePermissionsNotification object:nil rpcNotification:testPermissionChangeUpdate];
+ [[NSNotificationCenter defaultCenter] postNotification:updatedNotification];
- testPermissionChangeUpdate = [[SDLOnPermissionsChange alloc] init];
- testPermissionChangeUpdate.permissionItem = [NSArray arrayWithObject:testPermissionUpdated];
+ expect(numberOfTimesObserverCalled).to(equal(2));
- // Send the permission update
- SDLRPCNotificationNotification *updatedNotification = [[SDLRPCNotificationNotification alloc] initWithName:SDLDidChangePermissionsNotification object:nil rpcNotification:testPermissionChangeUpdate];
- [[NSNotificationCenter defaultCenter] postNotification:updatedNotification];
- });
+ expect(testStatuses[0]).to(equal(SDLPermissionGroupStatusAllowed));
+ expect(changeDicts[0].allKeys).to(contain(testRPCNameAllAllowed));
+ SDLRPCPermissionStatus *isAllowed1 = changeDicts[0][testRPCNameAllAllowed];
+ expect(isAllowed1.rpcAllowed).to(beTrue());
- it(@"should call the observer with a mixed status", ^{
- expect(@(numberOfTimesObserverCalled)).to(equal(@1));
- expect(testStatuses[0]).to(equal(@(SDLPermissionGroupStatusMixed)));
- });
+ expect(testStatuses[1]).to(equal(SDLPermissionGroupStatusDisallowed));
+ expect(changeDicts[1].allKeys).to(contain(testRPCNameAllAllowed));
+ SDLRPCPermissionStatus *isAllowed2 = changeDicts[1][testRPCNameAllAllowed];
+ expect(isAllowed2.rpcAllowed).to(beFalse());
});
- context(@"from disallowed to mixed", ^{
- beforeEach(^{
- // Set an observer that should be called immediately for the preexisting data, then called again when new data is sent
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- [testPermissionsManager addObserverForRPCs:@[testRPCNameFullLimitedAllowed, testRPCNameAllDisallowed] groupType:SDLPermissionGroupTypeAllAllowed withHandler:^(NSDictionary<SDLPermissionRPCName,NSNumber *> * _Nonnull change, SDLPermissionGroupStatus status) {
- numberOfTimesObserverCalled++;
- [changeDicts addObject:change];
- [testStatuses addObject:@(status)];
- }];
- #pragma clang diagnostic pop
+ it(@"should not notify the observer when permissions change from all-not-allowed (mixed) to all-not-allowed (disallowed)", ^{
+ [testPermissionsManager subscribeToRPCPermissions:@[testPermissionElementAllAllowed, testPermissionElementDisallowed] groupType:SDLPermissionGroupTypeAllAllowed withHandler:^(NSDictionary<SDLRPCFunctionName,SDLRPCPermissionStatus *> * _Nonnull updatedPermissionStatuses, SDLPermissionGroupStatus status) {
+ numberOfTimesObserverCalled++;
+ [changeDicts addObject:updatedPermissionStatuses];
+ [testStatuses addObject:@(status)];
+ }];
- // Create a permission update disallowing our current HMI level for the observed permission
- SDLParameterPermissions *testParameterPermissions = [[SDLParameterPermissions alloc] init];
- SDLHMIPermissions *testHMIPermissionsUpdated = [[SDLHMIPermissions alloc] init];
- testHMIPermissionsUpdated.allowed = @[SDLHMILevelLimited, SDLHMILevelBackground];
- testHMIPermissionsUpdated.userDisallowed = @[SDLHMILevelFull, SDLHMILevelNone];
+ // Create a permission update disallowing our current HMI level for the observed permission
+ SDLParameterPermissions *testParameterPermissions = [[SDLParameterPermissions alloc] init];
+ SDLHMIPermissions *testHMIPermissionsUpdated = [[SDLHMIPermissions alloc] init];
+ testHMIPermissionsUpdated.allowed = @[];
+ testHMIPermissionsUpdated.userDisallowed = @[SDLHMILevelBackground, SDLHMILevelFull, SDLHMILevelLimited, SDLHMILevelNone];
- testPermissionUpdated = [[SDLPermissionItem alloc] init];
- testPermissionUpdated.rpcName = testRPCNameAllAllowed;
- testPermissionUpdated.hmiPermissions = testHMIPermissionsUpdated;
- testPermissionUpdated.parameterPermissions = testParameterPermissions;
+ SDLPermissionItem *testPermissionUpdated = [[SDLPermissionItem alloc] init];
+ testPermissionUpdated.rpcName = testRPCNameAllAllowed;
+ testPermissionUpdated.hmiPermissions = testHMIPermissionsUpdated;
+ testPermissionUpdated.parameterPermissions = testParameterPermissions;
- testPermissionChangeUpdate = [[SDLOnPermissionsChange alloc] init];
- testPermissionChangeUpdate.permissionItem = [NSArray arrayWithObject:testPermissionUpdated];
+ SDLOnPermissionsChange *testPermissionChangeUpdate = [[SDLOnPermissionsChange alloc] init];
+ testPermissionChangeUpdate.permissionItem = [NSArray arrayWithObject:testPermissionUpdated];
- // Send the permission update
- SDLRPCNotificationNotification *updatedNotification = [[SDLRPCNotificationNotification alloc] initWithName:SDLDidChangePermissionsNotification object:nil rpcNotification:testPermissionChangeUpdate];
- [[NSNotificationCenter defaultCenter] postNotification:updatedNotification];
- });
+ // Send the permission update
+ SDLRPCNotificationNotification *updatedNotification = [[SDLRPCNotificationNotification alloc] initWithName:SDLDidChangePermissionsNotification object:nil rpcNotification:testPermissionChangeUpdate];
+ [[NSNotificationCenter defaultCenter] postNotification:updatedNotification];
- it(@"should call the observer", ^{
- expect(@(numberOfTimesObserverCalled)).to(equal(@1));
- expect(testStatuses[0]).to(equal(@(SDLPermissionGroupStatusDisallowed)));
- });
+ expect(numberOfTimesObserverCalled).to(equal(0));
+ expect(changeDicts).to(beEmpty());
+ expect(testStatuses).to(beEmpty());
});
});
});
- context(@"updating an observer with a new HMI level", ^{
+ context(@"getting a new HMI level", ^{
__block NSInteger numberOfTimesObserverCalled = 0;
- __block NSMutableArray<NSDictionary<SDLPermissionRPCName,NSNumber *> *> *changeDicts = nil;
+ __block NSMutableArray<NSDictionary<SDLRPCFunctionName,SDLRPCPermissionStatus *> *> *changeDicts = nil;
__block NSMutableArray<NSNumber<SDLUInt> *> *testStatuses = nil;
- context(@"to match an ANY observer", ^{
- beforeEach(^{
- // Reset vars
- numberOfTimesObserverCalled = 0;
- changeDicts = [NSMutableArray array];
- testStatuses = [NSMutableArray array];
+ beforeEach(^{
+ numberOfTimesObserverCalled = 0;
+ changeDicts = [NSMutableArray array];
+ testStatuses = [NSMutableArray array];
+ });
+ context(@"with an ANY group type observer", ^{
+ beforeEach(^{
// Post the notification before setting the observer to make sure data is already present
// HMI Full & Limited allowed, hmi level BACKGROUND
[[NSNotificationCenter defaultCenter] postNotification:backgroundHMINotification];
[[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
- // Set an observer that should be called immediately for the preexisting data, then called again when new data is sent
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- [testPermissionsManager addObserverForRPCs:@[testRPCNameAllAllowed, testRPCNameFullLimitedAllowed] groupType:SDLPermissionGroupTypeAny withHandler:^(NSDictionary<SDLPermissionRPCName,NSNumber *> * _Nonnull changedDict, SDLPermissionGroupStatus status) {
+ [testPermissionsManager subscribeToRPCPermissions:@[testPermissionElementAllAllowed, testPermissionElementFullLimitedAllowed] groupType:SDLPermissionGroupTypeAny withHandler:^(NSDictionary<SDLRPCFunctionName,SDLRPCPermissionStatus *> * _Nonnull updatedPermissionStatuses, SDLPermissionGroupStatus status) {
numberOfTimesObserverCalled++;
- [changeDicts addObject:changedDict];
+ [changeDicts addObject:updatedPermissionStatuses];
[testStatuses addObject:@(status)];
}];
- #pragma clang diagnostic pop
// Upgrade the HMI level to LIMITED
[[NSNotificationCenter defaultCenter] postNotification:limitedHMINotification];
});
- it(@"should call the observer twice", ^{
+ it(@"should notify the observer when the hmi level changes to allow or disallow any of the RPCs", ^{
expect(@(numberOfTimesObserverCalled)).to(equal(@2));
- });
-
- it(@"should have proper data in the first change dict", ^{
- NSNumber<SDLBool> *allAllowed = changeDicts[0][testRPCNameAllAllowed];
- expect(allAllowed).to(equal(@YES));
-
- NSNumber<SDLBool> *fullLimitedAllowed = changeDicts[0][testRPCNameFullLimitedAllowed];
- expect(fullLimitedAllowed).to(equal(@NO));
+ SDLRPCPermissionStatus *allAllowed1 = changeDicts[0][testRPCNameAllAllowed];
+ expect(allAllowed1.rpcAllowed).to(beTrue());
+ SDLRPCPermissionStatus *fullLimitedAllowed1 = changeDicts[0][testRPCNameFullLimitedAllowed];
+ expect(fullLimitedAllowed1.rpcAllowed).to(beFalse());
expect(testStatuses[0]).to(equal(@(SDLPermissionGroupStatusMixed)));
- });
-
- it(@"should have the proper data in the second change dict", ^{
- NSNumber<SDLBool> *allAllowed = changeDicts[1][testRPCNameAllAllowed];
- expect(allAllowed).to(equal(@YES));
-
- NSNumber<SDLBool> *fullLimitedAllowed = changeDicts[1][testRPCNameFullLimitedAllowed];
- expect(fullLimitedAllowed).to(equal(@YES));
+ SDLRPCPermissionStatus *allAllowed2 = changeDicts[1][testRPCNameAllAllowed];
+ expect(allAllowed2.rpcAllowed).to(beTrue());
+ SDLRPCPermissionStatus *fullLimitedAllowed2 = changeDicts[1][testRPCNameFullLimitedAllowed];
+ expect(fullLimitedAllowed2.rpcAllowed).to(beTrue());
expect(testStatuses[1]).to(equal(@(SDLPermissionGroupStatusAllowed)));
});
});
- context(@"to match an all allowed observer", ^{
+ context(@"with an All Allowed group type observer", ^{
beforeEach(^{
- // Reset vars
- numberOfTimesObserverCalled = 0;
- changeDicts = [NSMutableArray array];
- testStatuses = [NSMutableArray array];
-
// Post the notification before setting the observer to make sure data is already present
// HMI Full & Limited allowed, hmi level BACKGROUND
[[NSNotificationCenter defaultCenter] postNotification:backgroundHMINotification];
[[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
});
- context(@"so that it becomes All Allowed", ^{
- beforeEach(^{
- // Set an observer that should be called immediately for the preexisting data, then called again when new data is sent
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- [testPermissionsManager addObserverForRPCs:@[testRPCNameFullLimitedAllowed] groupType:SDLPermissionGroupTypeAllAllowed withHandler:^(NSDictionary<SDLPermissionRPCName,NSNumber *> * _Nonnull changedDict, SDLPermissionGroupStatus status) {
- numberOfTimesObserverCalled++;
- [changeDicts addObject:changedDict];
- [testStatuses addObject:@(status)];
- }];
- #pragma clang diagnostic pop
-
- [[NSNotificationCenter defaultCenter] postNotification:limitedHMINotification];
- });
-
- it(@"should call the observer", ^{
- expect(@(numberOfTimesObserverCalled)).to(equal(@2));
-
- expect(testStatuses[0]).to(equal(@(SDLPermissionGroupStatusDisallowed)));
- expect(testStatuses[1]).to(equal(@(SDLPermissionGroupStatusAllowed)));
- });
- });
-
- context(@"so that it goes from All Allowed to at least some disallowed", ^{
- beforeEach(^{
- // Set an observer that should be called immediately for the preexisting data, then called again when new data is sent
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- [testPermissionsManager addObserverForRPCs:@[testRPCNameFullLimitedBackgroundAllowed] groupType:SDLPermissionGroupTypeAllAllowed withHandler:^(NSDictionary<SDLPermissionRPCName,NSNumber *> * _Nonnull changedDict, SDLPermissionGroupStatus status) {
- numberOfTimesObserverCalled++;
- [changeDicts addObject:changedDict];
- [testStatuses addObject:@(status)];
- }];
- #pragma clang diagnostic pop
-
- [[NSNotificationCenter defaultCenter] postNotification:noneHMINotification];
- });
-
- it(@"should call the observer twice", ^{
- expect(@(numberOfTimesObserverCalled)).to(equal(@2));
- });
-
- it(@"should have proper data in the first change dict", ^{
- expect(changeDicts[0].allKeys).to(contain(testRPCNameFullLimitedBackgroundAllowed));
-
- NSNumber<SDLBool> *isAllowed = changeDicts[0][testRPCNameFullLimitedBackgroundAllowed];
- expect(isAllowed).to(equal(@YES));
-
- expect(testStatuses[0]).to(equal(@(SDLPermissionGroupStatusAllowed)));
- });
-
- it(@"should have the proper data in the second change dict", ^{
- expect(changeDicts[1].allKeys).to(contain(testRPCNameFullLimitedBackgroundAllowed));
+ it(@"should notify the observer when the hmi level changes the status from some-not-allowed to all-allowed", ^{
+ [testPermissionsManager subscribeToRPCPermissions:@[testPermissionElementFullLimitedAllowed] groupType:SDLPermissionGroupTypeAllAllowed withHandler:^(NSDictionary<SDLRPCFunctionName,SDLRPCPermissionStatus *> * _Nonnull updatedPermissionStatuses, SDLPermissionGroupStatus status) {
+ numberOfTimesObserverCalled++;
+ [changeDicts addObject:updatedPermissionStatuses];
+ [testStatuses addObject:@(status)];
+ }];
- NSNumber<SDLBool> *isAllowed = changeDicts[1][testRPCNameFullLimitedBackgroundAllowed];
- expect(isAllowed).to(equal(@NO));
+ [[NSNotificationCenter defaultCenter] postNotification:limitedHMINotification];
- expect(testStatuses[1]).to(equal(@(SDLPermissionGroupStatusDisallowed)));
- });
+ expect(numberOfTimesObserverCalled).to(equal(1));
+ expect(testStatuses[0]).to(equal(@(SDLPermissionGroupStatusAllowed)));
});
- });
-
- context(@"to not match an all allowed observer", ^{
- beforeEach(^{
- // Reset vars
- numberOfTimesObserverCalled = 0;
- changeDicts = [NSMutableArray array];
- testStatuses = [NSMutableArray array];
- // Post the notification before setting the observer to make sure data is already present
- // HMI Full & Limited allowed, hmi level BACKGROUND
- [[NSNotificationCenter defaultCenter] postNotification:backgroundHMINotification];
- [[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
- });
+ it(@"should notify the observer when the hmi level changes the status from all-allowed to some-not-allowed", ^{
+ [testPermissionsManager subscribeToRPCPermissions:@[testPermissionElementFullLimitedBackgroundAllowed] groupType:SDLPermissionGroupTypeAllAllowed withHandler:^(NSDictionary<SDLRPCFunctionName,SDLRPCPermissionStatus *> * _Nonnull updatedPermissionStatuses, SDLPermissionGroupStatus status) {
+ numberOfTimesObserverCalled++;
+ [changeDicts addObject:updatedPermissionStatuses];
+ [testStatuses addObject:@(status)];
+ }];
- context(@"that goes from disallowed to mixed", ^{
- beforeEach(^{
- // Set an observer that should be called immediately for the preexisting data, then called again when new data is sent
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- [testPermissionsManager addObserverForRPCs:@[testRPCNameFullLimitedAllowed, testRPCNameAllDisallowed] groupType:SDLPermissionGroupTypeAllAllowed withHandler:^(NSDictionary<SDLPermissionRPCName,NSNumber *> * _Nonnull changedDict, SDLPermissionGroupStatus status) {
- numberOfTimesObserverCalled++;
- [changeDicts addObject:changedDict];
- [testStatuses addObject:@(status)];
- }];
- #pragma clang diagnostic pop
+ [[NSNotificationCenter defaultCenter] postNotification:noneHMINotification];
- [[NSNotificationCenter defaultCenter] postNotification:limitedHMINotification];
- });
+ expect(numberOfTimesObserverCalled).to(equal(2));
- it(@"should call the observer", ^{
- expect(@(numberOfTimesObserverCalled)).to(equal(@1));
+ expect(changeDicts[0].allKeys).to(contain(testRPCNameFullLimitedBackgroundAllowed));
+ SDLRPCPermissionStatus *allAllowed1 = changeDicts[0][testRPCNameFullLimitedBackgroundAllowed];
+ expect(allAllowed1.rpcAllowed).to(beTrue());
+ expect(testStatuses[0]).to(equal(@(SDLPermissionGroupStatusAllowed)));
- expect(testStatuses[0]).to(equal(@(SDLPermissionGroupStatusDisallowed)));
- });
+ expect(changeDicts[1].allKeys).to(contain(testRPCNameFullLimitedBackgroundAllowed));
+ SDLRPCPermissionStatus *allAllowed2 = changeDicts[1][testRPCNameFullLimitedBackgroundAllowed];
+ expect(allAllowed2.rpcAllowed).to(beFalse());
+ expect(testStatuses[1]).to(equal(@(SDLPermissionGroupStatusDisallowed)));
});
- context(@"that goes from mixed to disallowed", ^{
- beforeEach(^{
- // Set an observer that should be called immediately for the preexisting data, then called again when new data is sent
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- [testPermissionsManager addObserverForRPCs:@[testRPCNameFullLimitedAllowed, testRPCNameFullLimitedBackgroundAllowed] groupType:SDLPermissionGroupTypeAllAllowed withHandler:^(NSDictionary<SDLPermissionRPCName,NSNumber *> * _Nonnull changedDict, SDLPermissionGroupStatus status) {
- numberOfTimesObserverCalled++;
- [changeDicts addObject:changedDict];
- [testStatuses addObject:@(status)];
- }];
- #pragma clang diagnostic pop
+ it(@"should not notify the observer when the hmi level changes but the status has not changed from all-allowed to some-not-allowed or from some-not-allowed to all-allowed", ^{
+ [testPermissionsManager subscribeToRPCPermissions:@[testPermissionElementFullLimitedBackgroundAllowed, testPermissionElementFullLimitedAllowed] groupType:SDLPermissionGroupTypeAllAllowed withHandler:^(NSDictionary<SDLRPCFunctionName,SDLRPCPermissionStatus *> * _Nonnull updatedPermissionStatuses, SDLPermissionGroupStatus status) {
+ numberOfTimesObserverCalled++;
+ [changeDicts addObject:updatedPermissionStatuses];
+ [testStatuses addObject:@(status)];
+ }];
- [[NSNotificationCenter defaultCenter] postNotification:noneHMINotification];
- });
+ [[NSNotificationCenter defaultCenter] postNotification:noneHMINotification];
- it(@"should call the observer", ^{
- expect(@(numberOfTimesObserverCalled)).to(equal(@1));
- expect(testStatuses[0]).to(equal(@(SDLPermissionGroupStatusMixed)));
- });
+ expect(numberOfTimesObserverCalled).to(equal(0));
+ expect(changeDicts).to(beEmpty());
+ expect(testStatuses).to(beEmpty());
});
});
});
@@ -1251,91 +817,77 @@ describe(@"SDLPermissionsManager", ^{
__block NSInteger numberOfTimesObserverCalled = 0;
beforeEach(^{
- // Reset vars
- numberOfTimesObserverCalled = 0;
-
- // Add two observers
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- NSUUID *observerId = [testPermissionsManager addObserverForRPCs:@[testRPCNameAllAllowed, testRPCNameFullLimitedAllowed] groupType:SDLPermissionGroupTypeAny withHandler:^(NSDictionary<SDLPermissionRPCName, NSNumber *> * _Nonnull changedDict, SDLPermissionGroupStatus status) {
+ // Add observer
+ SDLPermissionObserverIdentifier observerIdentifier = [testPermissionsManager subscribeToRPCPermissions:@[testPermissionElementAllAllowed] groupType:SDLPermissionGroupTypeAny withHandler:^(NSDictionary<SDLRPCFunctionName,NSNumber *> * _Nonnull change, SDLPermissionGroupStatus status) {
numberOfTimesObserverCalled++;
}];
- #pragma clang diagnostic pop
- // Remove one observer
- [testPermissionsManager removeObserverForIdentifier:observerId];
+ // Remove the observer
+ [testPermissionsManager removeObserverForIdentifier:observerIdentifier];
// Post a notification
[[NSNotificationCenter defaultCenter] postNotification:limitedHMINotification];
[[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
});
- it(@"should only call the observer once", ^{
- expect(@(numberOfTimesObserverCalled)).to(equal(@1));
+ it(@"should call the observer once (it should be called immediately after the subscription due to the `groupType` being set to `any`)", ^{
+ expect(numberOfTimesObserverCalled).to(equal(1));
});
});
context(@"removing a single observer and leaving one remaining", ^{
- __block NSUInteger numberOfTimesObserverCalled = 0;
+ __block NSInteger numberOfTimesObserver1Called = 0;
+ __block NSInteger numberOfTimesObserver2Called = 0;
beforeEach(^{
- // Reset vars
- numberOfTimesObserverCalled = 0;
-
// Add two observers
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- NSUUID *testRemovedObserverId = [testPermissionsManager addObserverForRPCs:@[testRPCNameAllAllowed, testRPCNameFullLimitedAllowed] groupType:SDLPermissionGroupTypeAny withHandler:^(NSDictionary<SDLPermissionRPCName,NSNumber *> * _Nonnull changedDict, SDLPermissionGroupStatus status) {
- numberOfTimesObserverCalled++;
+ SDLPermissionObserverIdentifier observerIdentifier1 = [testPermissionsManager subscribeToRPCPermissions:@[testPermissionElementAllAllowed, testPermissionElementFullLimitedAllowed] groupType:SDLPermissionGroupTypeAny withHandler:^(NSDictionary<SDLRPCFunctionName,NSNumber *> * _Nonnull change, SDLPermissionGroupStatus status) {
+ numberOfTimesObserver1Called++;
}];
- [testPermissionsManager addObserverForRPCs:@[testRPCNameAllAllowed, testRPCNameFullLimitedAllowed] groupType:SDLPermissionGroupTypeAny withHandler:^(NSDictionary<SDLPermissionRPCName,NSNumber *> * _Nonnull changedDict, SDLPermissionGroupStatus status) {
- numberOfTimesObserverCalled++;
+ [testPermissionsManager subscribeToRPCPermissions:@[testPermissionElementAllAllowed, testPermissionElementFullLimitedAllowed] groupType:SDLPermissionGroupTypeAny withHandler:^(NSDictionary<SDLRPCFunctionName,NSNumber *> * _Nonnull change, SDLPermissionGroupStatus status) {
+ numberOfTimesObserver2Called++;
}];
- #pragma clang diagnostic pop
- // Remove one observer
- [testPermissionsManager removeObserverForIdentifier:testRemovedObserverId];
+ // Remove one of the observers
+ [testPermissionsManager removeObserverForIdentifier:observerIdentifier1];
// Post a notification
[[NSNotificationCenter defaultCenter] postNotification:limitedHMINotification];
[[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
});
- it(@"should call three observers", ^{
- expect(@(numberOfTimesObserverCalled)).to(equal(@3));
+ it(@"should call the observers a total three times (the first two should be called immediately after the subscription due to the `groupType` being set to `any`)", ^{
+ expect(numberOfTimesObserver1Called).to(equal(1));
+ expect(numberOfTimesObserver2Called).to(equal(2));
});
});
context(@"removing all observers", ^{
- __block NSInteger numberOfTimesObserverCalled = 0;
+ __block NSInteger numberOfTimesObserver1Called = 0;
+ __block NSInteger numberOfTimesObserver2Called = 0;
beforeEach(^{
- // Reset vars
- numberOfTimesObserverCalled = 0;
-
// Add two observers
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- [testPermissionsManager addObserverForRPCs:@[testRPCNameAllAllowed, testRPCNameAllDisallowed] groupType:SDLPermissionGroupTypeAny withHandler:^(NSDictionary<SDLPermissionRPCName,NSNumber *> * _Nonnull changedDict, SDLPermissionGroupStatus status) {
- numberOfTimesObserverCalled++;
+ [testPermissionsManager subscribeToRPCPermissions:@[testPermissionElementAllAllowed, testPermissionElementFullLimitedAllowed] groupType:SDLPermissionGroupTypeAny withHandler:^(NSDictionary<SDLRPCFunctionName,NSNumber *> * _Nonnull change, SDLPermissionGroupStatus status) {
+ numberOfTimesObserver1Called++;
}];
- [testPermissionsManager addObserverForRPCs:@[testRPCNameAllAllowed, testRPCNameAllDisallowed] groupType:SDLPermissionGroupTypeAny withHandler:^(NSDictionary<SDLPermissionRPCName,NSNumber *> * _Nonnull changedDict, SDLPermissionGroupStatus status) {
- numberOfTimesObserverCalled++;
+ [testPermissionsManager subscribeToRPCPermissions:@[testPermissionElementAllAllowed, testPermissionElementFullLimitedAllowed] groupType:SDLPermissionGroupTypeAny withHandler:^(NSDictionary<SDLRPCFunctionName,NSNumber *> * _Nonnull change, SDLPermissionGroupStatus status) {
+ numberOfTimesObserver2Called++;
}];
- #pragma clang diagnostic pop
// Remove all observers
[testPermissionsManager removeAllObservers];
- // Add some permissions
+ // Post a notification
[[NSNotificationCenter defaultCenter] postNotification:limitedHMINotification];
[[NSNotificationCenter defaultCenter] postNotification:testPermissionsNotification];
});
- it(@"should not call the observer", ^{
- expect(@(numberOfTimesObserverCalled)).to(equal(@2));
+ it(@"should call each observer once (it should be called immediately after the subscription due to the `groupType` being set to `any`)", ^{
+ expect(numberOfTimesObserver1Called).to(equal(1));
+ expect(numberOfTimesObserver2Called).to(equal(1));
});
});
});
diff --git a/SmartDeviceLinkTests/DevAPISpecs/SDLPreloadChoicesOperationSpec.m b/SmartDeviceLinkTests/DevAPISpecs/SDLPreloadChoicesOperationSpec.m
index 986a01c61..c36e574fe 100644
--- a/SmartDeviceLinkTests/DevAPISpecs/SDLPreloadChoicesOperationSpec.m
+++ b/SmartDeviceLinkTests/DevAPISpecs/SDLPreloadChoicesOperationSpec.m
@@ -22,6 +22,7 @@ describe(@"a preload choices operation", ^{
__block TestConnectionManager *testConnectionManager = nil;
__block SDLFileManager *testFileManager = nil;
__block SDLPreloadChoicesOperation *testOp = nil;
+ __block NSString *testDisplayName = @"SDL_GENERIC";
__block NSData *cellArtData = [@"testart" dataUsingEncoding:NSUTF8StringEncoding];
@@ -80,7 +81,7 @@ describe(@"a preload choices operation", ^{
primaryTextField.name = SDLTextFieldNameMenuName;
windowCapability.textFields = @[];
- testOp = [[SDLPreloadChoicesOperation alloc] initWithConnectionManager:testConnectionManager fileManager:testFileManager displayName:SDLDisplayTypeGeneric windowCapability:windowCapability isVROptional:NO cellsToPreload:cellsWithArtwork];
+ testOp = [[SDLPreloadChoicesOperation alloc] initWithConnectionManager:testConnectionManager fileManager:testFileManager displayName:testDisplayName windowCapability:windowCapability isVROptional:NO cellsToPreload:cellsWithArtwork];
[testOp start];
NSArray<SDLCreateInteractionChoiceSet *> *receivedRequests = (NSArray<SDLCreateInteractionChoiceSet *> *)testConnectionManager.receivedRequests;
@@ -91,7 +92,7 @@ describe(@"a preload choices operation", ^{
context(@"only main text capabilities", ^{
it(@"should skip to preloading cells", ^{
- testOp = [[SDLPreloadChoicesOperation alloc] initWithConnectionManager:testConnectionManager fileManager:testFileManager displayName:SDLDisplayTypeGeneric windowCapability:windowCapability isVROptional:NO cellsToPreload:cellsWithArtwork];
+ testOp = [[SDLPreloadChoicesOperation alloc] initWithConnectionManager:testConnectionManager fileManager:testFileManager displayName:testDisplayName windowCapability:windowCapability isVROptional:NO cellsToPreload:cellsWithArtwork];
[testOp start];
expect(@(testOp.currentState)).to(equal(SDLPreloadChoicesOperationStatePreloadingChoices));
@@ -106,7 +107,7 @@ describe(@"a preload choices operation", ^{
OCMStub([testFileManager hasUploadedFile:[OCMArg isNotNil]]).andReturn(NO);
- testOp = [[SDLPreloadChoicesOperation alloc] initWithConnectionManager:testConnectionManager fileManager:testFileManager displayName:SDLDisplayTypeGeneric windowCapability:windowCapability isVROptional:NO cellsToPreload:cellsWithArtwork];
+ testOp = [[SDLPreloadChoicesOperation alloc] initWithConnectionManager:testConnectionManager fileManager:testFileManager displayName:testDisplayName windowCapability:windowCapability isVROptional:NO cellsToPreload:cellsWithArtwork];
[testOp start];
});
@@ -133,7 +134,7 @@ describe(@"a preload choices operation", ^{
beforeEach(^{
OCMStub([testFileManager hasUploadedFile:[OCMArg isNotNil]]).andReturn(YES);
- testOp = [[SDLPreloadChoicesOperation alloc] initWithConnectionManager:testConnectionManager fileManager:testFileManager displayName:SDLDisplayTypeGeneric windowCapability:windowCapability isVROptional:NO cellsToPreload:cellsWithArtwork];
+ testOp = [[SDLPreloadChoicesOperation alloc] initWithConnectionManager:testConnectionManager fileManager:testFileManager displayName:testDisplayName windowCapability:windowCapability isVROptional:NO cellsToPreload:cellsWithArtwork];
[testOp start];
});
@@ -148,7 +149,7 @@ describe(@"a preload choices operation", ^{
context(@"when artworks are static icons", ^{
beforeEach(^{
- testOp = [[SDLPreloadChoicesOperation alloc] initWithConnectionManager:testConnectionManager fileManager:testFileManager displayName:SDLDisplayTypeGeneric windowCapability:windowCapability isVROptional:NO cellsToPreload:cellsWithStaticIcon];
+ testOp = [[SDLPreloadChoicesOperation alloc] initWithConnectionManager:testConnectionManager fileManager:testFileManager displayName:testDisplayName windowCapability:windowCapability isVROptional:NO cellsToPreload:cellsWithStaticIcon];
[testOp start];
});
@@ -161,7 +162,7 @@ describe(@"a preload choices operation", ^{
beforeEach(^{
OCMStub([testFileManager hasUploadedFile:[OCMArg isNotNil]]).andReturn(NO);
- testOp = [[SDLPreloadChoicesOperation alloc] initWithConnectionManager:testConnectionManager fileManager:testFileManager displayName:SDLDisplayTypeGeneric windowCapability:windowCapability isVROptional:NO cellsToPreload:cellsWithArtwork];
+ testOp = [[SDLPreloadChoicesOperation alloc] initWithConnectionManager:testConnectionManager fileManager:testFileManager displayName:testDisplayName windowCapability:windowCapability isVROptional:NO cellsToPreload:cellsWithArtwork];
[testOp start];
});
@@ -191,7 +192,7 @@ describe(@"a preload choices operation", ^{
describe(@"assembling choices", ^{
it(@"should be correct with no text and VR required", ^{
- testOp = [[SDLPreloadChoicesOperation alloc] initWithConnectionManager:testConnectionManager fileManager:testFileManager displayName:SDLDisplayTypeGeneric windowCapability:windowCapability isVROptional:NO cellsToPreload:cellsWithoutArtwork];
+ testOp = [[SDLPreloadChoicesOperation alloc] initWithConnectionManager:testConnectionManager fileManager:testFileManager displayName:testDisplayName windowCapability:windowCapability isVROptional:NO cellsToPreload:cellsWithoutArtwork];
[testOp start];
NSArray<SDLCreateInteractionChoiceSet *> *receivedRequests = (NSArray<SDLCreateInteractionChoiceSet *> *)testConnectionManager.receivedRequests;
@@ -207,7 +208,7 @@ describe(@"a preload choices operation", ^{
primaryTextField.name = SDLTextFieldNameMenuName;
windowCapability.textFields = @[primaryTextField];
- testOp = [[SDLPreloadChoicesOperation alloc] initWithConnectionManager:testConnectionManager fileManager:testFileManager displayName:SDLDisplayTypeGeneric windowCapability:windowCapability isVROptional:NO cellsToPreload:cellsWithoutArtwork];
+ testOp = [[SDLPreloadChoicesOperation alloc] initWithConnectionManager:testConnectionManager fileManager:testFileManager displayName:testDisplayName windowCapability:windowCapability isVROptional:NO cellsToPreload:cellsWithoutArtwork];
[testOp start];
NSArray<SDLCreateInteractionChoiceSet *> *receivedRequests = (NSArray<SDLCreateInteractionChoiceSet *> *)testConnectionManager.receivedRequests;
@@ -226,7 +227,7 @@ describe(@"a preload choices operation", ^{
secondaryTextField.name = SDLTextFieldNameSecondaryText;
windowCapability.textFields = @[primaryTextField, secondaryTextField];
- testOp = [[SDLPreloadChoicesOperation alloc] initWithConnectionManager:testConnectionManager fileManager:testFileManager displayName:SDLDisplayTypeGeneric windowCapability:windowCapability isVROptional:NO cellsToPreload:cellsWithoutArtwork];
+ testOp = [[SDLPreloadChoicesOperation alloc] initWithConnectionManager:testConnectionManager fileManager:testFileManager displayName:testDisplayName windowCapability:windowCapability isVROptional:NO cellsToPreload:cellsWithoutArtwork];
[testOp start];
NSArray<SDLCreateInteractionChoiceSet *> *receivedRequests = (NSArray<SDLCreateInteractionChoiceSet *> *)testConnectionManager.receivedRequests;
@@ -247,7 +248,7 @@ describe(@"a preload choices operation", ^{
tertiaryTextField.name = SDLTextFieldNameTertiaryText;
windowCapability.textFields = @[primaryTextField, secondaryTextField, tertiaryTextField];
- testOp = [[SDLPreloadChoicesOperation alloc] initWithConnectionManager:testConnectionManager fileManager:testFileManager displayName:SDLDisplayTypeGeneric windowCapability:windowCapability isVROptional:NO cellsToPreload:cellsWithoutArtwork];
+ testOp = [[SDLPreloadChoicesOperation alloc] initWithConnectionManager:testConnectionManager fileManager:testFileManager displayName:testDisplayName windowCapability:windowCapability isVROptional:NO cellsToPreload:cellsWithoutArtwork];
[testOp start];
NSArray<SDLCreateInteractionChoiceSet *> *receivedRequests = (NSArray<SDLCreateInteractionChoiceSet *> *)testConnectionManager.receivedRequests;
@@ -261,7 +262,7 @@ describe(@"a preload choices operation", ^{
it(@"should be correct with VR optional", ^{
- testOp = [[SDLPreloadChoicesOperation alloc] initWithConnectionManager:testConnectionManager fileManager:testFileManager displayName:SDLDisplayTypeGeneric windowCapability:windowCapability isVROptional:YES cellsToPreload:cellsWithoutArtwork];
+ testOp = [[SDLPreloadChoicesOperation alloc] initWithConnectionManager:testConnectionManager fileManager:testFileManager displayName:testDisplayName windowCapability:windowCapability isVROptional:YES cellsToPreload:cellsWithoutArtwork];
[testOp start];
NSArray<SDLCreateInteractionChoiceSet *> *receivedRequests = (NSArray<SDLCreateInteractionChoiceSet *> *)testConnectionManager.receivedRequests;
diff --git a/SmartDeviceLinkTests/DevAPISpecs/SDLStreamingAudioLifecycleManagerSpec.m b/SmartDeviceLinkTests/DevAPISpecs/SDLStreamingAudioLifecycleManagerSpec.m
index 93d5e5829..4a39a0676 100644
--- a/SmartDeviceLinkTests/DevAPISpecs/SDLStreamingAudioLifecycleManagerSpec.m
+++ b/SmartDeviceLinkTests/DevAPISpecs/SDLStreamingAudioLifecycleManagerSpec.m
@@ -315,7 +315,6 @@ describe(@"the streaming audio manager", ^{
});
it(@"should have set all the right properties", ^{
- expect([[SDLGlobals sharedGlobals] mtuSizeForServiceType:SDLServiceTypeAudio]).to(equal(testMTU));
expect(streamingLifecycleManager.audioEncrypted).to(equal(YES));
expect(streamingLifecycleManager.currentAudioStreamState).to(equal(SDLAudioStreamManagerStateReady));
});
diff --git a/SmartDeviceLinkTests/DevAPISpecs/SDLStreamingMediaConfigurationSpec.m b/SmartDeviceLinkTests/DevAPISpecs/SDLStreamingMediaConfigurationSpec.m
index c3c934d55..5132e0551 100644
--- a/SmartDeviceLinkTests/DevAPISpecs/SDLStreamingMediaConfigurationSpec.m
+++ b/SmartDeviceLinkTests/DevAPISpecs/SDLStreamingMediaConfigurationSpec.m
@@ -11,85 +11,118 @@ QuickSpecBegin(SDLStreamingMediaConfigurationSpec)
describe(@"a streaming media configuration", ^{
__block SDLStreamingMediaConfiguration *testConfig = nil;
+ __block SDLFakeSecurityManager *testFakeSecurityManager = nil;
+ __block UIViewController *testViewController = nil;
+ __block SDLStreamingEncryptionFlag testEncryptionFlag = SDLStreamingEncryptionFlagNone;
+ __block SDLFakeStreamingManagerDataSource *testDataSource = nil;
+ __block NSDictionary<NSString *, id> *testVideoEncoderSettings = nil;
+
+ beforeEach(^{
+ testFakeSecurityManager = [[SDLFakeSecurityManager alloc] init];
+ testDataSource = [[SDLFakeStreamingManagerDataSource alloc] init];
+ testVideoEncoderSettings = @{
+ (__bridge NSString *)kVTCompressionPropertyKey_ExpectedFrameRate : @1
+ };
+ testViewController = [[UIViewController alloc] init];
+ testEncryptionFlag = SDLStreamingEncryptionFlagAuthenticateAndEncrypt;
+ });
- context(@"That is created with a full initializer", ^{
- __block SDLFakeSecurityManager *testFakeSecurityManager = nil;
- __block SDLStreamingEncryptionFlag testEncryptionFlag = SDLStreamingEncryptionFlagNone;
- __block SDLFakeStreamingManagerDataSource *testDataSource = nil;
- __block NSDictionary<NSString *, id> *testVideoEncoderSettings = nil;
- __block UIViewController *testViewController = nil;
-
- beforeEach(^{
- testFakeSecurityManager = [[SDLFakeSecurityManager alloc] init];
- testDataSource = [[SDLFakeStreamingManagerDataSource alloc] init];
- testVideoEncoderSettings = @{
- (__bridge NSString *)kVTCompressionPropertyKey_ExpectedFrameRate : @1
- };
- testViewController = [[UIViewController alloc] init];
- testEncryptionFlag = SDLStreamingEncryptionFlagAuthenticateAndEncrypt;
-
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testConfig = [[SDLStreamingMediaConfiguration alloc] initWithSecurityManagers:@[testFakeSecurityManager.class] encryptionFlag:testEncryptionFlag videoSettings:testVideoEncoderSettings dataSource:testDataSource rootViewController:testViewController];
- #pragma clang diagnostic pop
- });
+ context(@"That is created without the default secure/insecure settings", ^{
+ it(@"should have properly set all properties with initWithEncryptionFlag:videoSettings:dataSource:rootViewController:", ^{
+ testConfig = [[SDLStreamingMediaConfiguration alloc] initWithEncryptionFlag:testEncryptionFlag videoSettings:testVideoEncoderSettings dataSource:testDataSource rootViewController:testViewController];
- it(@"should have properly set properties using deprecated init", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testConfig.securityManagers).to(contain(testFakeSecurityManager.class));
-#pragma clang diagnostic pop
- expect(@(testConfig.maximumDesiredEncryption)).to(equal(@(SDLStreamingEncryptionFlagAuthenticateAndEncrypt)));
+ expect(@(testConfig.maximumDesiredEncryption)).to(equal(@(testEncryptionFlag)));
expect(testConfig.customVideoEncoderSettings).to(equal(testVideoEncoderSettings));
expect(testConfig.allowMultipleViewControllerOrientations).to(equal(NO));
expect(testConfig.dataSource).to(equal(testDataSource));
expect(testConfig.rootViewController).to(equal(testViewController));
+ expect(@(testConfig.carWindowRenderingType)).to(equal(@(SDLCarWindowRenderingTypeLayer)));
+ expect(testConfig.enableForcedFramerateSync).to(beTrue());
});
- it(@"should have properly set properties using deprecated init", ^{
- testConfig = [[SDLStreamingMediaConfiguration alloc] initWithEncryptionFlag:testEncryptionFlag videoSettings:testVideoEncoderSettings dataSource:testDataSource rootViewController:testViewController ];
+ it(@"should have properly set and insecure configuration with init", ^{
+ testConfig = [[SDLStreamingMediaConfiguration alloc] init];
- expect(@(testConfig.maximumDesiredEncryption)).to(equal(@(SDLStreamingEncryptionFlagAuthenticateAndEncrypt)));
- expect(testConfig.customVideoEncoderSettings).to(equal(testVideoEncoderSettings));
+ expect(@(testConfig.maximumDesiredEncryption)).to(equal(@(SDLStreamingEncryptionFlagNone)));
+ expect(testConfig.customVideoEncoderSettings).to(beNil());
expect(testConfig.allowMultipleViewControllerOrientations).to(equal(NO));
- expect(testConfig.dataSource).to(equal(testDataSource));
- expect(testConfig.rootViewController).to(equal(testViewController));
+ expect(testConfig.dataSource).to(beNil());
+ expect(testConfig.rootViewController).to(beNil());
+ expect(@(testConfig.carWindowRenderingType)).to(equal(@(SDLCarWindowRenderingTypeLayer)));
+ expect(testConfig.enableForcedFramerateSync).to(beTrue());
});
});
context(@"that is created with insecure settings", ^{
- beforeEach(^{
+ it(@"should have properly set properties with insecureConfiguration", ^{
testConfig = [SDLStreamingMediaConfiguration insecureConfiguration];
- });
- it(@"should have properly set properties", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testConfig.securityManagers).to(beNil());
-#pragma clang diagnostic pop
expect(@(testConfig.maximumDesiredEncryption)).to(equal(@(SDLStreamingEncryptionFlagNone)));
expect(testConfig.customVideoEncoderSettings).to(beNil());
expect(testConfig.allowMultipleViewControllerOrientations).to(equal(NO));
expect(testConfig.dataSource).to(beNil());
expect(testConfig.rootViewController).to(beNil());
+ expect(@(testConfig.carWindowRenderingType)).to(equal(@(SDLCarWindowRenderingTypeLayer)));
+ expect(testConfig.enableForcedFramerateSync).to(beTrue());
});
- });
- context(@"that is created with secure settings", ^{
- __block SDLFakeSecurityManager *testFakeSecurityManager = nil;
+ it(@"should have properly set properties with autostreamingInsecureConfigurationWithInitialViewController", ^{
+ testConfig = [SDLStreamingMediaConfiguration autostreamingInsecureConfigurationWithInitialViewController:testViewController];
- beforeEach(^{
- testFakeSecurityManager = [[SDLFakeSecurityManager alloc] init];
+ expect(@(testConfig.maximumDesiredEncryption)).to(equal(@(SDLStreamingEncryptionFlagNone)));
+ expect(testConfig.customVideoEncoderSettings).to(beNil());
+ expect(testConfig.allowMultipleViewControllerOrientations).to(equal(NO));
+ expect(testConfig.dataSource).to(beNil());
+ expect(testConfig.rootViewController).to(equal(testViewController));
+ expect(@(testConfig.carWindowRenderingType)).to(equal(@(SDLCarWindowRenderingTypeLayer)));
+ expect(testConfig.enableForcedFramerateSync).to(beTrue());
+ });
+ });
+ context(@"that is created with secure settings", ^{
+ it(@"should have properly set properties with secureConfiguration", ^{
testConfig = [SDLStreamingMediaConfiguration secureConfiguration];
- });
- it(@"should have properly set properties", ^{
expect(@(testConfig.maximumDesiredEncryption)).to(equal(@(SDLStreamingEncryptionFlagAuthenticateAndEncrypt)));
expect(testConfig.customVideoEncoderSettings).to(beNil());
expect(testConfig.allowMultipleViewControllerOrientations).to(equal(NO));
expect(testConfig.dataSource).to(beNil());
expect(testConfig.rootViewController).to(beNil());
+ expect(@(testConfig.carWindowRenderingType)).to(equal(@(SDLCarWindowRenderingTypeLayer)));
+ expect(testConfig.enableForcedFramerateSync).to(beTrue());
+ });
+
+ it(@"should have properly set properties with autostreamingSecureConfigurationWithInitialViewController:", ^{
+ testConfig = [SDLStreamingMediaConfiguration autostreamingSecureConfigurationWithInitialViewController:testViewController];
+
+ expect(@(testConfig.maximumDesiredEncryption)).to(equal(@(SDLStreamingEncryptionFlagAuthenticateAndEncrypt)));
+ expect(testConfig.customVideoEncoderSettings).to(beNil());
+ expect(testConfig.allowMultipleViewControllerOrientations).to(equal(NO));
+ expect(testConfig.dataSource).to(beNil());
+ expect(testConfig.rootViewController).to(equal(testViewController));
+ expect(@(testConfig.carWindowRenderingType)).to(equal(@(SDLCarWindowRenderingTypeLayer)));
+ expect(testConfig.enableForcedFramerateSync).to(beTrue());
+ });
+ });
+
+ context(@"copying a filter", ^{
+ __block SDLStreamingMediaConfiguration *testStreamingMediaConfiguration = nil;
+ __block SDLStreamingMediaConfiguration *testCopiedStreamingMediaConfiguration = nil;
+
+ beforeEach(^{
+ testStreamingMediaConfiguration = [[SDLStreamingMediaConfiguration alloc] initWithEncryptionFlag:testEncryptionFlag videoSettings:testVideoEncoderSettings dataSource:testDataSource rootViewController:testViewController];
+ testCopiedStreamingMediaConfiguration = [testStreamingMediaConfiguration copy];
+ });
+
+ it(@"should copy correctly", ^{
+ expect(testCopiedStreamingMediaConfiguration).toNot(beIdenticalTo(testStreamingMediaConfiguration));
+ expect(@(testCopiedStreamingMediaConfiguration.maximumDesiredEncryption)).to(equal(testStreamingMediaConfiguration.maximumDesiredEncryption));
+ expect(testCopiedStreamingMediaConfiguration.customVideoEncoderSettings).to(equal(testStreamingMediaConfiguration.customVideoEncoderSettings));
+ expect(testCopiedStreamingMediaConfiguration.dataSource).to(equal(testStreamingMediaConfiguration.dataSource));
+ expect(testCopiedStreamingMediaConfiguration.rootViewController).to(equal(testStreamingMediaConfiguration.rootViewController));
+ expect(@(testCopiedStreamingMediaConfiguration.carWindowRenderingType)).to(equal(testStreamingMediaConfiguration.carWindowRenderingType));
+ expect(testCopiedStreamingMediaConfiguration.enableForcedFramerateSync).to(equal(testStreamingMediaConfiguration.enableForcedFramerateSync));
+ expect(testCopiedStreamingMediaConfiguration.allowMultipleViewControllerOrientations).to(equal(testStreamingMediaConfiguration.allowMultipleViewControllerOrientations));
});
});
});
diff --git a/SmartDeviceLinkTests/DevAPISpecs/SDLStreamingVideoLifecycleManagerSpec.m b/SmartDeviceLinkTests/DevAPISpecs/SDLStreamingVideoLifecycleManagerSpec.m
index d2c2889db..c42e10961 100644
--- a/SmartDeviceLinkTests/DevAPISpecs/SDLStreamingVideoLifecycleManagerSpec.m
+++ b/SmartDeviceLinkTests/DevAPISpecs/SDLStreamingVideoLifecycleManagerSpec.m
@@ -556,7 +556,6 @@ describe(@"the streaming video manager", ^{
});
it(@"should have set all the right properties", ^{
- expect([[SDLGlobals sharedGlobals] mtuSizeForServiceType:SDLServiceTypeVideo]).to(equal(testMTU));
expect(@(CGSizeEqualToSize(streamingLifecycleManager.videoScaleManager.displayViewportResolution, CGSizeMake(testVideoWidth, testVideoHeight)))).to(beTrue());
expect(streamingLifecycleManager.videoEncrypted).to(equal(YES));
expect(streamingLifecycleManager.videoFormat).to(equal([[SDLVideoStreamingFormat alloc] initWithCodec:testVideoCodec protocol:testVideoProtocol]));
diff --git a/SmartDeviceLinkTests/DevAPISpecs/SDLVersionSpec.m b/SmartDeviceLinkTests/DevAPISpecs/SDLVersionSpec.m
index 9621f6e75..08dcb922c 100644
--- a/SmartDeviceLinkTests/DevAPISpecs/SDLVersionSpec.m
+++ b/SmartDeviceLinkTests/DevAPISpecs/SDLVersionSpec.m
@@ -1,7 +1,6 @@
#import <Quick/Quick.h>
#import <Nimble/Nimble.h>
-#import "SDLSyncMsgVersion.h"
#import "SDLMsgVersion.h"
#import "SDLVersion.h"
@@ -56,22 +55,6 @@ describe(@"a version object", ^{
});
});
- context(@"created from a SyncMsgVersion object", ^{
- beforeEach(^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLSyncMsgVersion *msgVersion = [[SDLSyncMsgVersion alloc] initWithMajorVersion:major minorVersion:minor patchVersion:patch];
- testVersion = [[SDLVersion alloc] initWithSyncMsgVersion:msgVersion];
-#pragma clang diagnostic pop
- });
-
- it(@"should match the parameters", ^{
- expect(testVersion.major).to(equal(major));
- expect(testVersion.minor).to(equal(minor));
- expect(testVersion.patch).to(equal(patch));
- });
- });
-
context(@"created from a SDLMsgVersion object", ^{
beforeEach(^{
SDLMsgVersion *msgVersion = [[SDLMsgVersion alloc] initWithMajorVersion:major minorVersion:minor patchVersion:patch];
diff --git a/SmartDeviceLinkTests/LoggingSpecs/SDLLogConfigurationSpec.m b/SmartDeviceLinkTests/LoggingSpecs/SDLLogConfigurationSpec.m
index d434f1269..df4d48691 100644
--- a/SmartDeviceLinkTests/LoggingSpecs/SDLLogConfigurationSpec.m
+++ b/SmartDeviceLinkTests/LoggingSpecs/SDLLogConfigurationSpec.m
@@ -22,12 +22,7 @@ describe(@"a log configuration", ^{
expect(@(testConfiguration.errorsAsynchronous)).to(equal(@NO));
expect(@(testConfiguration.areAssertionsDisabled)).to(equal(@NO));
expect(@(testConfiguration.globalLogLevel)).to(equal(@(SDLLogLevelError)));
-
- if ([NSProcessInfo processInfo].operatingSystemVersion.majorVersion >= 10) {
- expect([testConfiguration.targets anyObject].class).to(equal([SDLLogTargetOSLog class]));
- } else {
- expect([testConfiguration.targets anyObject].class).to(equal([SDLLogTargetAppleSystemLog class]));
- }
+ expect([testConfiguration.targets anyObject].class).to(equal([SDLLogTargetOSLog class]));
});
});
@@ -43,12 +38,7 @@ describe(@"a log configuration", ^{
expect(@(testConfiguration.errorsAsynchronous)).to(equal(@NO));
expect(@(testConfiguration.areAssertionsDisabled)).to(equal(@NO));
expect(@(testConfiguration.globalLogLevel)).to(equal(@(SDLLogLevelDebug)));
-
- if ([NSProcessInfo processInfo].operatingSystemVersion.majorVersion >= 10) {
- expect([testConfiguration.targets anyObject].class).to(equal([SDLLogTargetOSLog class]));
- } else {
- expect([testConfiguration.targets anyObject].class).to(equal([SDLLogTargetAppleSystemLog class]));
- }
+ expect([testConfiguration.targets anyObject].class).to(equal([SDLLogTargetOSLog class]));
});
});
});
diff --git a/SmartDeviceLinkTests/ProtocolSpecs/MessageSpecs/SDLProtocolSpec.m b/SmartDeviceLinkTests/ProtocolSpecs/MessageSpecs/SDLProtocolSpec.m
index b4e542012..483033569 100644
--- a/SmartDeviceLinkTests/ProtocolSpecs/MessageSpecs/SDLProtocolSpec.m
+++ b/SmartDeviceLinkTests/ProtocolSpecs/MessageSpecs/SDLProtocolSpec.m
@@ -399,6 +399,8 @@ describe(@"HandleProtocolSessionStarted tests", ^ {
__block id transportMock = nil;
__block SDLProtocol *testProtocol = nil;
__block id delegateMock = nil;
+ __block int64_t testMTU = 989786483;
+ __block int32_t hashId = 1545784;
beforeEach(^{
transportMock = OCMProtocolMock(@protocol(SDLTransportType));
@@ -419,7 +421,7 @@ describe(@"HandleProtocolSessionStarted tests", ^ {
context(@"If the service type is RPC", ^{
it(@"Should store the auth token and the protocol version and pass the start service along to the delegate", ^{
- SDLControlFramePayloadRPCStartServiceAck *testPayload = [[SDLControlFramePayloadRPCStartServiceAck alloc] initWithHashId:1545784 mtu:989786483 authToken:testAuthToken protocolVersion:@"5.2.0" secondaryTransports:nil audioServiceTransports:nil videoServiceTransports:nil];
+ SDLControlFramePayloadRPCStartServiceAck *testPayload = [[SDLControlFramePayloadRPCStartServiceAck alloc] initWithHashId:hashId mtu:testMTU authToken:testAuthToken protocolVersion:@"5.2.0" secondaryTransports:nil audioServiceTransports:nil videoServiceTransports:nil];
NSData *testData = testPayload.data;
SDLV2ProtocolHeader* testHeader = [[SDLV2ProtocolHeader alloc] initWithVersion:5];
@@ -443,7 +445,7 @@ describe(@"HandleProtocolSessionStarted tests", ^ {
});
it(@"Should store the protocol version, but not get the auth token, and pass the start service along to the delegate if the protocol version is greater than 5.0.0 but less than 5.2.0", ^{
- SDLControlFramePayloadRPCStartServiceAck *testPayload = [[SDLControlFramePayloadRPCStartServiceAck alloc] initWithHashId:1545784 mtu:989786483 authToken:testAuthToken protocolVersion:@"5.1.0" secondaryTransports:nil audioServiceTransports:nil videoServiceTransports:nil];
+ SDLControlFramePayloadRPCStartServiceAck *testPayload = [[SDLControlFramePayloadRPCStartServiceAck alloc] initWithHashId:hashId mtu:testMTU authToken:testAuthToken protocolVersion:@"5.1.0" secondaryTransports:nil audioServiceTransports:nil videoServiceTransports:nil];
NSData *testData = testPayload.data;
SDLV2ProtocolHeader* testHeader = [[SDLV2ProtocolHeader alloc] initWithVersion:5];
@@ -467,7 +469,7 @@ describe(@"HandleProtocolSessionStarted tests", ^ {
});
it(@"Should set the max head unit version using the header version if the protocol version is missing from the payload", ^{
- SDLControlFramePayloadRPCStartServiceAck *testPayload = [[SDLControlFramePayloadRPCStartServiceAck alloc] initWithHashId:1545784 mtu:989786483 authToken:nil protocolVersion:nil secondaryTransports:nil audioServiceTransports:nil videoServiceTransports:nil];
+ SDLControlFramePayloadRPCStartServiceAck *testPayload = [[SDLControlFramePayloadRPCStartServiceAck alloc] initWithHashId:hashId mtu:testMTU authToken:nil protocolVersion:nil secondaryTransports:nil audioServiceTransports:nil videoServiceTransports:nil];
NSData *testData = testPayload.data;
SDLV2ProtocolHeader* testHeader = [[SDLV2ProtocolHeader alloc] initWithVersion:5];
@@ -491,9 +493,9 @@ describe(@"HandleProtocolSessionStarted tests", ^ {
});
});
- context(@"If the service type is not RPC", ^{
+ context(@"If the service type is control", ^{
it(@"Should just pass the start service along to the delegate", ^{
- SDLControlFramePayloadRPCStartServiceAck *testPayload = [[SDLControlFramePayloadRPCStartServiceAck alloc] initWithHashId:1545784 mtu:989786483 authToken:testAuthToken protocolVersion:@"5.1.0" secondaryTransports:nil audioServiceTransports:nil videoServiceTransports:nil];
+ SDLControlFramePayloadRPCStartServiceAck *testPayload = [[SDLControlFramePayloadRPCStartServiceAck alloc] initWithHashId:hashId mtu:testMTU authToken:testAuthToken protocolVersion:@"5.1.0" secondaryTransports:nil audioServiceTransports:nil videoServiceTransports:nil];
NSData *testData = testPayload.data;
SDLV2ProtocolHeader* testHeader = [[SDLV2ProtocolHeader alloc] initWithVersion:5];
@@ -517,12 +519,68 @@ describe(@"HandleProtocolSessionStarted tests", ^ {
expect([SDLGlobals sharedGlobals].maxHeadUnitProtocolVersion.stringVersion).to(equal(@"0.0.0"));
});
});
+
+ context(@"If the service type is Audio", ^{
+ it(@"Should just pass the start service along to the delegate", ^{
+ SDLControlFramePayloadRPCStartServiceAck *testPayload = [[SDLControlFramePayloadRPCStartServiceAck alloc] initWithHashId:hashId mtu:testMTU authToken:testAuthToken protocolVersion:@"5.1.0" secondaryTransports:nil audioServiceTransports:nil videoServiceTransports:nil];
+ NSData *testData = testPayload.data;
+
+ SDLV2ProtocolHeader* testHeader = [[SDLV2ProtocolHeader alloc] initWithVersion:5];
+ testHeader.frameType = SDLFrameTypeControl;
+ testHeader.serviceType = SDLServiceTypeAudio;
+ testHeader.frameData = SDLFrameInfoStartServiceACK;
+ testHeader.sessionID = 0x93;
+ testHeader.bytesInPayload = (UInt32)testData.length;
+
+ SDLProtocolMessage *ackMessage = [SDLProtocolMessage messageWithHeader:testHeader andPayload:testData];
+ OCMExpect([delegateMock protocol:testProtocol didReceiveStartServiceACK:ackMessage]);
+
+ [testProtocol.protocolDelegateTable addObject:delegateMock];
+ [testProtocol protocol:testProtocol didReceiveStartServiceACK:ackMessage];
+
+ OCMVerifyAllWithDelay(delegateMock, 0.1);
+
+ // Should keep their default values
+ expect(testProtocol.authToken).to(beNil());
+ expect([SDLGlobals sharedGlobals].protocolVersion.stringVersion).to(equal(@"1.0.0"));
+ expect([[SDLGlobals sharedGlobals] mtuSizeForServiceType:SDLServiceTypeAudio]).to(equal(testMTU));
+ expect([SDLGlobals sharedGlobals].maxHeadUnitProtocolVersion.stringVersion).to(equal(@"0.0.0"));
+ });
+ });
+
+ context(@"If the service type is Video", ^{
+ it(@"Should just pass the start service along to the delegate", ^{
+ SDLControlFramePayloadRPCStartServiceAck *testPayload = [[SDLControlFramePayloadRPCStartServiceAck alloc] initWithHashId:hashId mtu:testMTU authToken:testAuthToken protocolVersion:@"5.1.0" secondaryTransports:nil audioServiceTransports:nil videoServiceTransports:nil];
+ NSData *testData = testPayload.data;
+
+ SDLV2ProtocolHeader* testHeader = [[SDLV2ProtocolHeader alloc] initWithVersion:5];
+ testHeader.frameType = SDLFrameTypeControl;
+ testHeader.serviceType = SDLServiceTypeVideo;
+ testHeader.frameData = SDLFrameInfoStartServiceACK;
+ testHeader.sessionID = 0x93;
+ testHeader.bytesInPayload = (UInt32)testData.length;
+
+ SDLProtocolMessage *ackMessage = [SDLProtocolMessage messageWithHeader:testHeader andPayload:testData];
+ OCMExpect([delegateMock protocol:testProtocol didReceiveStartServiceACK:ackMessage]);
+
+ [testProtocol.protocolDelegateTable addObject:delegateMock];
+ [testProtocol protocol:testProtocol didReceiveStartServiceACK:ackMessage];
+
+ OCMVerifyAllWithDelay(delegateMock, 0.1);
+
+ // Should keep their default values
+ expect(testProtocol.authToken).to(beNil());
+ expect([SDLGlobals sharedGlobals].protocolVersion.stringVersion).to(equal(@"1.0.0"));
+ expect([[SDLGlobals sharedGlobals] mtuSizeForServiceType:SDLServiceTypeVideo]).to(equal(testMTU));
+ expect([SDLGlobals sharedGlobals].maxHeadUnitProtocolVersion.stringVersion).to(equal(@"0.0.0"));
+ });
+ });
});
context(@"For protocol versions below 5.0.0", ^{
context(@"If the service type is RPC", ^{
it(@"Should store the protocol version and pass the start service along to the delegate", ^{
- SDLControlFramePayloadRPCStartServiceAck *testPayload = [[SDLControlFramePayloadRPCStartServiceAck alloc] initWithHashId:1545784 mtu:989786483 authToken:nil protocolVersion:@"3.1.0" secondaryTransports:nil audioServiceTransports:nil videoServiceTransports:nil];
+ SDLControlFramePayloadRPCStartServiceAck *testPayload = [[SDLControlFramePayloadRPCStartServiceAck alloc] initWithHashId:hashId mtu:testMTU authToken:nil protocolVersion:@"3.1.0" secondaryTransports:nil audioServiceTransports:nil videoServiceTransports:nil];
NSData *testData = testPayload.data;
SDLV2ProtocolHeader* testHeader = [[SDLV2ProtocolHeader alloc] initWithVersion:5];
@@ -547,7 +605,7 @@ describe(@"HandleProtocolSessionStarted tests", ^ {
context(@"If the service type is not RPC", ^{
it(@"Should just pass the start service along to the delegate", ^{
- SDLControlFramePayloadRPCStartServiceAck *testPayload = [[SDLControlFramePayloadRPCStartServiceAck alloc] initWithHashId:1545784 mtu:989786483 authToken:nil protocolVersion:@"4.1.0" secondaryTransports:nil audioServiceTransports:nil videoServiceTransports:nil];
+ SDLControlFramePayloadRPCStartServiceAck *testPayload = [[SDLControlFramePayloadRPCStartServiceAck alloc] initWithHashId:hashId mtu:testMTU authToken:nil protocolVersion:@"4.1.0" secondaryTransports:nil audioServiceTransports:nil videoServiceTransports:nil];
NSData *testData = testPayload.data;
SDLV2ProtocolHeader* testHeader = [[SDLV2ProtocolHeader alloc] initWithVersion:4];
@@ -569,6 +627,58 @@ describe(@"HandleProtocolSessionStarted tests", ^ {
OCMVerifyAllWithDelay(delegateMock, 0.1);
});
});
+
+ context(@"If the service type is Audio", ^{
+ it(@"Should just pass the start service along to the delegate", ^{
+ SDLControlFramePayloadRPCStartServiceAck *testPayload = [[SDLControlFramePayloadRPCStartServiceAck alloc] initWithHashId:hashId mtu:testMTU authToken:nil protocolVersion:@"4.1.0" secondaryTransports:nil audioServiceTransports:nil videoServiceTransports:nil];
+ NSData *testData = testPayload.data;
+
+ SDLV2ProtocolHeader* testHeader = [[SDLV2ProtocolHeader alloc] initWithVersion:4];
+ testHeader.frameType = SDLFrameTypeControl;
+ testHeader.serviceType = SDLServiceTypeAudio;
+ testHeader.frameData = SDLFrameInfoStartServiceACK;
+ testHeader.sessionID = 0x93;
+ testHeader.bytesInPayload = (UInt32)testData.length;
+
+ SDLProtocolMessage *ackMessage = [SDLProtocolMessage messageWithHeader:testHeader andPayload:testData];
+ OCMExpect([delegateMock protocol:testProtocol didReceiveStartServiceACK:ackMessage]);
+
+ [testProtocol.protocolDelegateTable addObject:delegateMock];
+ [testProtocol protocol:testProtocol didReceiveStartServiceACK:ackMessage];
+
+ // Should keep their default values
+ expect([SDLGlobals sharedGlobals].protocolVersion.stringVersion).to(equal(@"1.0.0"));
+ expect([[SDLGlobals sharedGlobals] mtuSizeForServiceType:SDLServiceTypeAudio]).to(equal(1024));
+ expect([SDLGlobals sharedGlobals].maxHeadUnitProtocolVersion.stringVersion).to(equal(@"0.0.0"));
+ OCMVerifyAllWithDelay(delegateMock, 0.1);
+ });
+ });
+
+ context(@"If the service type is Video", ^{
+ it(@"Should just pass the start service along to the delegate", ^{
+ SDLControlFramePayloadRPCStartServiceAck *testPayload = [[SDLControlFramePayloadRPCStartServiceAck alloc] initWithHashId:hashId mtu:testMTU authToken:nil protocolVersion:@"4.1.0" secondaryTransports:nil audioServiceTransports:nil videoServiceTransports:nil];
+ NSData *testData = testPayload.data;
+
+ SDLV2ProtocolHeader* testHeader = [[SDLV2ProtocolHeader alloc] initWithVersion:4];
+ testHeader.frameType = SDLFrameTypeControl;
+ testHeader.serviceType = SDLServiceTypeVideo;
+ testHeader.frameData = SDLFrameInfoStartServiceACK;
+ testHeader.sessionID = 0x93;
+ testHeader.bytesInPayload = (UInt32)testData.length;
+
+ SDLProtocolMessage *ackMessage = [SDLProtocolMessage messageWithHeader:testHeader andPayload:testData];
+ OCMExpect([delegateMock protocol:testProtocol didReceiveStartServiceACK:ackMessage]);
+
+ [testProtocol.protocolDelegateTable addObject:delegateMock];
+ [testProtocol protocol:testProtocol didReceiveStartServiceACK:ackMessage];
+
+ // Should keep their default values
+ expect([SDLGlobals sharedGlobals].protocolVersion.stringVersion).to(equal(@"1.0.0"));
+ expect([[SDLGlobals sharedGlobals] mtuSizeForServiceType:SDLServiceTypeVideo]).to(equal(1024));
+ expect([SDLGlobals sharedGlobals].maxHeadUnitProtocolVersion.stringVersion).to(equal(@"0.0.0"));
+ OCMVerifyAllWithDelay(delegateMock, 0.1);
+ });
+ });
});
});
diff --git a/SmartDeviceLinkTests/ProxySpecs/SDLHapticManagerSpec.m b/SmartDeviceLinkTests/ProxySpecs/SDLHapticManagerSpec.m
index c5e50301f..cec23d2ee 100644
--- a/SmartDeviceLinkTests/ProxySpecs/SDLHapticManagerSpec.m
+++ b/SmartDeviceLinkTests/ProxySpecs/SDLHapticManagerSpec.m
@@ -19,6 +19,7 @@
#import "SDLTouchCoord.h"
#import "SDLTouchEvent.h"
#import "SDLTouch.h"
+#import "TestHapticRectViewController.h"
BOOL compareRectangle(SDLRectangle *sdlRectangle, CGRect cgRect) {
expect(sdlRectangle.x).to(equal(cgRect.origin.x));
@@ -46,7 +47,7 @@ QuickSpecBegin(SDLHapticManagerSpec)
describe(@"the haptic manager", ^{
__block UIWindow *uiWindow;
- __block UIViewController *uiViewController;
+ __block TestHapticRectViewController *testHapticRectViewController;
__block SDLFocusableItemLocator *hapticManager;
__block SDLSendHapticData* sentHapticRequest;
@@ -58,23 +59,23 @@ describe(@"the haptic manager", ^{
beforeEach(^{
uiWindow = [[UIWindow alloc] init];
- uiViewController = [[UIViewController alloc] init];
- uiWindow.rootViewController = uiViewController;
+ testHapticRectViewController = [[TestHapticRectViewController alloc] init];
+ uiWindow.rootViewController = testHapticRectViewController;
sdlLifecycleManager = OCMProtocolMock(@protocol(SDLConnectionManagerType));
hapticManager = nil;
sentHapticRequest = nil;
- sdlStreamingVideoScaleManager = [[SDLStreamingVideoScaleManager alloc] initWithScale:1.0 displayViewportResolution:uiViewController.view.frame.size];
+ sdlStreamingVideoScaleManager = [[SDLStreamingVideoScaleManager alloc] initWithScale:1.0 displayViewportResolution:testHapticRectViewController.view.frame.size];
});
context(@"when disabled", ^{
beforeEach(^{
viewRect1 = CGRectMake(101, 101, 50, 50);
UITextField *textField1 = [[UITextField alloc] initWithFrame:viewRect1];
- [uiViewController.view addSubview:textField1];
+ [testHapticRectViewController.view addSubview:textField1];
- hapticManager = [[SDLFocusableItemLocator alloc] initWithViewController:uiViewController connectionManager:sdlLifecycleManager videoScaleManager:sdlStreamingVideoScaleManager];
+ hapticManager = [[SDLFocusableItemLocator alloc] initWithViewController:testHapticRectViewController connectionManager:sdlLifecycleManager videoScaleManager:sdlStreamingVideoScaleManager];
hapticManager.enableHapticDataRequests = NO;
[hapticManager updateInterfaceLayout];
});
@@ -94,7 +95,7 @@ describe(@"the haptic manager", ^{
context(@"when initialized with no focusable view", ^{
beforeEach(^{
- hapticManager = [[SDLFocusableItemLocator alloc] initWithViewController:uiViewController connectionManager:sdlLifecycleManager videoScaleManager:sdlStreamingVideoScaleManager];
+ hapticManager = [[SDLFocusableItemLocator alloc] initWithViewController:testHapticRectViewController connectionManager:sdlLifecycleManager videoScaleManager:sdlStreamingVideoScaleManager];
[hapticManager updateInterfaceLayout];
});
@@ -114,9 +115,9 @@ describe(@"the haptic manager", ^{
beforeEach(^{
viewRect1 = CGRectMake(101, 101, 50, 50);
UITextField *textField1 = [[UITextField alloc] initWithFrame:viewRect1];
- [uiViewController.view addSubview:textField1];
+ [testHapticRectViewController.view addSubview:textField1];
- hapticManager = [[SDLFocusableItemLocator alloc] initWithViewController:uiViewController connectionManager:sdlLifecycleManager videoScaleManager:sdlStreamingVideoScaleManager];
+ hapticManager = [[SDLFocusableItemLocator alloc] initWithViewController:testHapticRectViewController connectionManager:sdlLifecycleManager videoScaleManager:sdlStreamingVideoScaleManager];
hapticManager.enableHapticDataRequests = YES;
[hapticManager updateInterfaceLayout];
});
@@ -147,9 +148,9 @@ describe(@"the haptic manager", ^{
beforeEach(^{
viewRect1 = CGRectMake(101, 101, 50, 50);
UIButton *button = [[UIButton alloc] initWithFrame:viewRect1];
- [uiViewController.view addSubview:button];
+ [testHapticRectViewController.view addSubview:button];
- hapticManager = [[SDLFocusableItemLocator alloc] initWithViewController:uiViewController connectionManager:sdlLifecycleManager videoScaleManager:sdlStreamingVideoScaleManager];
+ hapticManager = [[SDLFocusableItemLocator alloc] initWithViewController:testHapticRectViewController connectionManager:sdlLifecycleManager videoScaleManager:sdlStreamingVideoScaleManager];
hapticManager.enableHapticDataRequests = YES;
[hapticManager updateInterfaceLayout];
});
@@ -178,17 +179,19 @@ describe(@"the haptic manager", ^{
context(@"when initialized with no views and then updated with two additional views", ^{
beforeEach(^{
- hapticManager = [[SDLFocusableItemLocator alloc] initWithViewController:uiViewController connectionManager:sdlLifecycleManager videoScaleManager:sdlStreamingVideoScaleManager];
+ hapticManager = [[SDLFocusableItemLocator alloc] initWithViewController:testHapticRectViewController connectionManager:sdlLifecycleManager videoScaleManager:sdlStreamingVideoScaleManager];
hapticManager.enableHapticDataRequests = YES;
[hapticManager updateInterfaceLayout];
viewRect1 = CGRectMake(101, 101, 50, 50);
UITextField *textField1 = [[UITextField alloc] initWithFrame:viewRect1];
- [uiViewController.view addSubview:textField1];
+ textField1.tag = 2;
+ [testHapticRectViewController.view addSubview:textField1];
- viewRect2 = CGRectMake(201, 201, 50, 50);
+ viewRect2 = CGRectMake(333, 333, 50, 50);
UITextField *textField2 = [[UITextField alloc] initWithFrame:viewRect2];
- [uiViewController.view addSubview:textField2];
+ textField2.tag = 1; // Preferred focus view
+ [testHapticRectViewController.view addSubview:textField2];
[hapticManager updateInterfaceLayout];
});
@@ -222,7 +225,7 @@ describe(@"the haptic manager", ^{
context(@"when initialized with nested views", ^{
beforeEach(^{
UITextField *textField = [[UITextField alloc] initWithFrame:CGRectMake(101, 101, 50, 50)];
- [uiViewController.view addSubview:textField];
+ [testHapticRectViewController.view addSubview:textField];
viewRect1 = CGRectMake(110, 110, 10, 10);
UITextField *textField1 = [[UITextField alloc] initWithFrame:viewRect1];
@@ -232,7 +235,7 @@ describe(@"the haptic manager", ^{
UITextField *textField2 = [[UITextField alloc] initWithFrame:viewRect2];
[textField addSubview:textField2];
- hapticManager = [[SDLFocusableItemLocator alloc] initWithViewController:uiViewController connectionManager:sdlLifecycleManager videoScaleManager:sdlStreamingVideoScaleManager];
+ hapticManager = [[SDLFocusableItemLocator alloc] initWithViewController:testHapticRectViewController connectionManager:sdlLifecycleManager videoScaleManager:sdlStreamingVideoScaleManager];
hapticManager.enableHapticDataRequests = YES;
[hapticManager updateInterfaceLayout];
});
@@ -266,7 +269,7 @@ describe(@"the haptic manager", ^{
context(@"when initialized with nested button views", ^{
beforeEach(^{
UIButton *button = [[UIButton alloc] initWithFrame:CGRectMake(101, 101, 50, 50)];
- [uiViewController.view addSubview:button];
+ [testHapticRectViewController.view addSubview:button];
viewRect1 = CGRectMake(110, 110, 10, 10);
UIButton *button1 = [[UIButton alloc] initWithFrame:viewRect1];
@@ -276,7 +279,7 @@ describe(@"the haptic manager", ^{
UITextField *textField2 = [[UITextField alloc] initWithFrame:viewRect2];
[button addSubview:textField2];
- hapticManager = [[SDLFocusableItemLocator alloc] initWithViewController:uiViewController connectionManager:sdlLifecycleManager videoScaleManager:sdlStreamingVideoScaleManager];
+ hapticManager = [[SDLFocusableItemLocator alloc] initWithViewController:testHapticRectViewController connectionManager:sdlLifecycleManager videoScaleManager:sdlStreamingVideoScaleManager];
hapticManager.enableHapticDataRequests = YES;
[hapticManager updateInterfaceLayout];
});
@@ -319,13 +322,13 @@ describe(@"the haptic manager", ^{
viewRect1 = CGRectMake(101, 101, 50, 50);
UITextField *textField1 = [[UITextField alloc] initWithFrame:viewRect1];
- [uiViewController.view addSubview:textField1];
+ [testHapticRectViewController.view addSubview:textField1];
viewRect2 = CGRectMake(201, 201, 50, 50);
UITextField *textField2 = [[UITextField alloc] initWithFrame:viewRect2];
- [uiViewController.view addSubview:textField2];
+ [testHapticRectViewController.view addSubview:textField2];
- hapticManager = [[SDLFocusableItemLocator alloc] initWithViewController:uiViewController connectionManager:sdlLifecycleManager videoScaleManager:sdlStreamingVideoScaleManager];
+ hapticManager = [[SDLFocusableItemLocator alloc] initWithViewController:testHapticRectViewController connectionManager:sdlLifecycleManager videoScaleManager:sdlStreamingVideoScaleManager];
hapticManager.enableHapticDataRequests = YES;
[hapticManager updateInterfaceLayout];
@@ -348,6 +351,7 @@ describe(@"the haptic manager", ^{
});
});
+ // FIXME
context(@"when initialized with one view and notified after adding one more view", ^{
beforeEach(^{
OCMStub([sdlLifecycleManager sendConnectionManagerRequest:[OCMArg checkWithBlock:^BOOL(id value){
@@ -360,15 +364,17 @@ describe(@"the haptic manager", ^{
viewRect1 = CGRectMake(101, 101, 50, 50);
UITextField *textField1 = [[UITextField alloc] initWithFrame:viewRect1];
- [uiViewController.view addSubview:textField1];
+ textField1.tag = 2;
+ [testHapticRectViewController.view addSubview:textField1];
- hapticManager = [[SDLFocusableItemLocator alloc] initWithViewController:uiViewController connectionManager:sdlLifecycleManager videoScaleManager:sdlStreamingVideoScaleManager];
+ hapticManager = [[SDLFocusableItemLocator alloc] initWithViewController:testHapticRectViewController connectionManager:sdlLifecycleManager videoScaleManager:sdlStreamingVideoScaleManager];
hapticManager.enableHapticDataRequests = YES;
[hapticManager updateInterfaceLayout];
viewRect2 = CGRectMake(201, 201, 50, 50);
UITextField *textField2 = [[UITextField alloc] initWithFrame:viewRect2];
- [uiViewController.view addSubview:textField2];
+ textField2.tag = 1; // Preferred focus view
+ [testHapticRectViewController.view addSubview:textField2];
});
context(@"when not started", ^{
@@ -416,7 +422,7 @@ describe(@"the haptic manager", ^{
context(@"when stopped", ^{
beforeEach(^{
[hapticManager stop];
- for (UIView *subview in uiViewController.view.subviews) { [subview removeFromSuperview]; }
+ for (UIView *subview in testHapticRectViewController.view.subviews) { [subview removeFromSuperview]; }
[[NSNotificationCenter defaultCenter] postNotificationName:SDLDidUpdateProjectionView object:nil];
});
@@ -431,12 +437,12 @@ describe(@"the haptic manager", ^{
context(@"when touched inside a view", ^{
beforeEach(^{
UITextField *textField1 = [[UITextField alloc] initWithFrame:CGRectMake(101, 101, 50, 50)];
- [uiViewController.view addSubview:textField1];
+ [testHapticRectViewController.view addSubview:textField1];
UITextField *textField2 = [[UITextField alloc] initWithFrame:CGRectMake(201, 201, 50, 50)];
- [uiViewController.view addSubview:textField2];
+ [testHapticRectViewController.view addSubview:textField2];
- hapticManager = [[SDLFocusableItemLocator alloc] initWithViewController:uiViewController connectionManager:sdlLifecycleManager videoScaleManager:sdlStreamingVideoScaleManager];
+ hapticManager = [[SDLFocusableItemLocator alloc] initWithViewController:testHapticRectViewController connectionManager:sdlLifecycleManager videoScaleManager:sdlStreamingVideoScaleManager];
hapticManager.enableHapticDataRequests = YES;
[hapticManager updateInterfaceLayout];
});
@@ -453,12 +459,12 @@ describe(@"the haptic manager", ^{
context(@"when touched in overlapping views' area", ^{
beforeEach(^{
UITextField *textField1 = [[UITextField alloc] initWithFrame:CGRectMake(101, 101, 50, 50)];
- [uiViewController.view addSubview:textField1];
+ [testHapticRectViewController.view addSubview:textField1];
UITextField *textField2 = [[UITextField alloc] initWithFrame:CGRectMake(126, 126, 50, 50)];
- [uiViewController.view addSubview:textField2];
+ [testHapticRectViewController.view addSubview:textField2];
- hapticManager = [[SDLFocusableItemLocator alloc] initWithViewController:uiViewController connectionManager:sdlLifecycleManager videoScaleManager:sdlStreamingVideoScaleManager];
+ hapticManager = [[SDLFocusableItemLocator alloc] initWithViewController:testHapticRectViewController connectionManager:sdlLifecycleManager videoScaleManager:sdlStreamingVideoScaleManager];
hapticManager.enableHapticDataRequests = YES;
[hapticManager updateInterfaceLayout];
});
@@ -474,7 +480,7 @@ describe(@"the haptic manager", ^{
UITextField *textField1 = [[UITextField alloc] initWithFrame:CGRectMake(101, 101, 50, 50)];
[uiWindow insertSubview:textField1 aboveSubview:uiWindow];
- hapticManager = [[SDLFocusableItemLocator alloc] initWithViewController:uiViewController connectionManager:sdlLifecycleManager videoScaleManager:sdlStreamingVideoScaleManager];
+ hapticManager = [[SDLFocusableItemLocator alloc] initWithViewController:testHapticRectViewController connectionManager:sdlLifecycleManager videoScaleManager:sdlStreamingVideoScaleManager];
hapticManager.enableHapticDataRequests = YES;
[hapticManager updateInterfaceLayout];
});
@@ -486,16 +492,16 @@ describe(@"the haptic manager", ^{
describe(@"scaling", ^{
__block float testUpdatedScale = 0.0;
- __block CGSize testScreenSize = uiViewController.view.frame.size;
+ __block CGSize testScreenSize = testHapticRectViewController.view.frame.size;
beforeEach(^{
viewRect1 = CGRectMake(320, 600, 100, 100);
UIButton *button = [[UIButton alloc] initWithFrame:viewRect1];
- [uiViewController.view addSubview:button];
+ [testHapticRectViewController.view addSubview:button];
sentHapticRequest = nil;
- hapticManager = [[SDLFocusableItemLocator alloc] initWithViewController:uiViewController connectionManager:sdlLifecycleManager videoScaleManager:sdlStreamingVideoScaleManager];
+ hapticManager = [[SDLFocusableItemLocator alloc] initWithViewController:testHapticRectViewController connectionManager:sdlLifecycleManager videoScaleManager:sdlStreamingVideoScaleManager];
hapticManager.enableHapticDataRequests = YES;
});
diff --git a/SmartDeviceLinkTests/ProxySpecs/SDLLockScreenStatusManagerSpec.m b/SmartDeviceLinkTests/ProxySpecs/SDLLockScreenStatusManagerSpec.m
index 758da74d9..7bca387e4 100644
--- a/SmartDeviceLinkTests/ProxySpecs/SDLLockScreenStatusManagerSpec.m
+++ b/SmartDeviceLinkTests/ProxySpecs/SDLLockScreenStatusManagerSpec.m
@@ -8,12 +8,11 @@
#import "SDLOnDriverDistraction.h"
#import "SDLHMILevel.h"
+#import "SDLLockScreenStatusInfo.h"
#import "SDLLockScreenStatusManager.h"
-#import "SDLLockScreenStatus.h"
#import "SDLNotificationConstants.h"
#import "SDLNotificationDispatcher.h"
#import "SDLOnHMIStatus.h"
-#import "SDLOnLockScreenStatus.h"
#import "SDLRPCNotificationNotification.h"
@@ -21,7 +20,7 @@ QuickSpecBegin(SDLLockScreenStatusManagerSpec)
describe(@"the lockscreen status manager", ^{
__block SDLLockScreenStatusManager *testManager;
- __block SDLNotificationDispatcher *mockDispatcher;
+ __block id mockDispatcher;
beforeEach(^{
mockDispatcher = OCMClassMock([SDLNotificationDispatcher class]);
@@ -108,10 +107,7 @@ describe(@"the lockscreen status manager", ^{
});
it(@"should return lock screen off", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testManager.lockScreenStatus).to(equal(SDLLockScreenStatusOff));
-#pragma clang diagnostic pop
+ expect(@(testManager.lockScreenStatus)).to(equal(SDLLockScreenStatusOff));
});
});
@@ -121,10 +117,7 @@ describe(@"the lockscreen status manager", ^{
});
it(@"should return lock screen off", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testManager.lockScreenStatus).to(equal(SDLLockScreenStatusOff));
-#pragma clang diagnostic pop
+ expect(@(testManager.lockScreenStatus)).to(equal(SDLLockScreenStatusOff));
});
});
@@ -140,10 +133,7 @@ describe(@"the lockscreen status manager", ^{
context(@"if we do not set the driver distraction state", ^{
it(@"should return lock screen required", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testManager.lockScreenStatus).to(equal(SDLLockScreenStatusRequired));
-#pragma clang diagnostic pop
+ expect(@(testManager.lockScreenStatus)).to(equal(SDLLockScreenStatusRequired));
});
});
@@ -153,10 +143,7 @@ describe(@"the lockscreen status manager", ^{
});
it(@"should return lock screen optional", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testManager.lockScreenStatus).to(equal(SDLLockScreenStatusOptional));
-#pragma clang diagnostic pop
+ expect(@(testManager.lockScreenStatus)).to(equal(SDLLockScreenStatusOptional));
});
});
@@ -166,10 +153,7 @@ describe(@"the lockscreen status manager", ^{
});
it(@"should return lock screen required", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testManager.lockScreenStatus).to(equal(SDLLockScreenStatusRequired));
-#pragma clang diagnostic pop
+ expect(@(testManager.lockScreenStatus)).to(equal(SDLLockScreenStatusRequired));
});
});
});
@@ -180,10 +164,7 @@ describe(@"the lockscreen status manager", ^{
});
it(@"should return lock screen off", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testManager.lockScreenStatus).to(equal(SDLLockScreenStatusOff));
-#pragma clang diagnostic pop
+ expect(@(testManager.lockScreenStatus)).to(equal(SDLLockScreenStatusOff));
});
});
});
@@ -195,10 +176,7 @@ describe(@"the lockscreen status manager", ^{
context(@"if we do not set the driver distraction state", ^{
it(@"should return lock screen required", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testManager.lockScreenStatus).to(equal(SDLLockScreenStatusRequired));
-#pragma clang diagnostic pop
+ expect(@(testManager.lockScreenStatus)).to(equal(SDLLockScreenStatusRequired));
});
});
@@ -208,10 +186,7 @@ describe(@"the lockscreen status manager", ^{
});
it(@"should return lock screen optional", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testManager.lockScreenStatus).to(equal(SDLLockScreenStatusOptional));
-#pragma clang diagnostic pop
+ expect(@(testManager.lockScreenStatus)).to(equal(SDLLockScreenStatusOptional));
});
});
@@ -221,10 +196,7 @@ describe(@"the lockscreen status manager", ^{
});
it(@"should return lock screen required", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testManager.lockScreenStatus).to(equal(SDLLockScreenStatusRequired));
-#pragma clang diagnostic pop
+ expect(@(testManager.lockScreenStatus)).to(equal(SDLLockScreenStatusRequired));
});
});
});
@@ -236,10 +208,7 @@ describe(@"the lockscreen status manager", ^{
context(@"if we do not set the driver distraction state", ^{
it(@"should return lock screen required", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testManager.lockScreenStatus).to(equal(SDLLockScreenStatusRequired));
-#pragma clang diagnostic pop
+ expect(@(testManager.lockScreenStatus)).to(equal(SDLLockScreenStatusRequired));
});
});
@@ -249,10 +218,7 @@ describe(@"the lockscreen status manager", ^{
});
it(@"should return lock screen optional", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testManager.lockScreenStatus).to(equal(SDLLockScreenStatusOptional));
-#pragma clang diagnostic pop
+ expect(@(testManager.lockScreenStatus)).to(equal(SDLLockScreenStatusOptional));
});
});
@@ -262,21 +228,14 @@ describe(@"the lockscreen status manager", ^{
});
it(@"should return lock screen required", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testManager.lockScreenStatus).to(equal(SDLLockScreenStatusRequired));
-#pragma clang diagnostic pop
+ expect(@(testManager.lockScreenStatus)).to(equal(SDLLockScreenStatusRequired));
});
});
});
});
describe(@"when sending a lock screen status notification", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- __block SDLOnLockScreenStatus *onLockScreenStatusNotification = nil;
-#pragma clang diagnostic pop
-
+ __block SDLLockScreenStatusInfo *onLockScreenStatusNotification = nil;
beforeEach(^{
testManager.userSelected = YES;
testManager.driverDistracted = NO;
@@ -298,55 +257,46 @@ describe(@"the lockscreen status manager", ^{
});
it(@"should properly return lock screen status", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(onLockScreenStatusNotification.lockScreenStatus).to(equal(SDLLockScreenStatusOptional));
-#pragma clang diagnostic pop
+ expect(@(onLockScreenStatusNotification.lockScreenStatus)).to(equal(SDLLockScreenStatusOptional));
});
});
describe(@"when receiving an HMI status", ^{
- __block id lockScreenIconObserver = nil;
beforeEach(^{
- SDLOnHMIStatus *hmiStatus = [[SDLOnHMIStatus alloc] initWithHMILevel:SDLHMILevelFull systemContext:SDLSystemContextMain audioStreamingState:SDLAudioStreamingStateAudible videoStreamingState:nil windowID:nil];
- SDLRPCNotificationNotification *notification = [[SDLRPCNotificationNotification alloc] initWithName:SDLDidChangeHMIStatusNotification object:mockDispatcher rpcNotification:hmiStatus];
+ OCMExpect([mockDispatcher postNotificationName:SDLDidChangeLockScreenStatusNotification infoObject:[OCMArg checkWithBlock:^BOOL(id value) {
+ SDLLockScreenStatusInfo *lockScreenStatusInfo = (SDLLockScreenStatusInfo *)value;
+ expect(lockScreenStatusInfo.hmiLevel).to(equal(SDLHMILevelFull));
+ return [lockScreenStatusInfo isKindOfClass:[SDLLockScreenStatusInfo class]];
+ }]]);
- lockScreenIconObserver = OCMObserverMock();
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- [[NSNotificationCenter defaultCenter] addMockObserver:lockScreenIconObserver name:SDLDidChangeLockScreenStatusNotification object:testManager];
- [[lockScreenIconObserver expect] notificationWithName:SDLDidChangeLockScreenStatusNotification object:[OCMArg any] userInfo:[OCMArg any]];
-#pragma clang diagnostic pop
-
- [[NSNotificationCenter defaultCenter] postNotification:notification];
+ SDLOnHMIStatus *hmiStatus = [[SDLOnHMIStatus alloc] initWithHMILevel:SDLHMILevelFull systemContext:SDLSystemContextMain audioStreamingState:SDLAudioStreamingStateAudible videoStreamingState:nil windowID:nil];
+ SDLRPCNotificationNotification *hmiStatusNotification = [[SDLRPCNotificationNotification alloc] initWithName:SDLDidChangeHMIStatusNotification object:mockDispatcher rpcNotification:hmiStatus];
+ [[NSNotificationCenter defaultCenter] postNotification:hmiStatusNotification];
});
it(@"should update the driver distraction status and send a notification", ^{
expect(testManager.hmiLevel).to(equal(SDLHMILevelFull));
- OCMVerifyAll(lockScreenIconObserver);
+ OCMVerifyAllWithDelay(mockDispatcher, 0.5);
});
});
describe(@"when receiving a driver distraction status", ^{
- __block id lockScreenIconObserver = nil;
beforeEach(^{
+ OCMExpect([mockDispatcher postNotificationName:SDLDidChangeLockScreenStatusNotification infoObject:[OCMArg checkWithBlock:^BOOL(id value) {
+ SDLLockScreenStatusInfo *lockScreenStatusInfo = (SDLLockScreenStatusInfo *)value;
+ expect(lockScreenStatusInfo.driverDistractionStatus).to(beTrue());
+ return [lockScreenStatusInfo isKindOfClass:[SDLLockScreenStatusInfo class]];
+ }]]);
+
SDLOnDriverDistraction *driverDistraction = [[SDLOnDriverDistraction alloc] init];
driverDistraction.state = SDLDriverDistractionStateOn;
- SDLRPCNotificationNotification *notification = [[SDLRPCNotificationNotification alloc] initWithName:SDLDidChangeDriverDistractionStateNotification object:mockDispatcher rpcNotification:driverDistraction];
-
- lockScreenIconObserver = OCMObserverMock();
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- [[NSNotificationCenter defaultCenter] addMockObserver:lockScreenIconObserver name:SDLDidChangeLockScreenStatusNotification object:testManager];
- [[lockScreenIconObserver expect] notificationWithName:SDLDidChangeLockScreenStatusNotification object:[OCMArg any] userInfo:[OCMArg any]];
-#pragma clang diagnostic pop
-
- [[NSNotificationCenter defaultCenter] postNotification:notification];
+ SDLRPCNotificationNotification *driverDistractionStateNotification = [[SDLRPCNotificationNotification alloc] initWithName:SDLDidChangeDriverDistractionStateNotification object:mockDispatcher rpcNotification:driverDistraction];
+ [[NSNotificationCenter defaultCenter] postNotification:driverDistractionStateNotification];
});
it(@"should update the driver distraction status and send a notification", ^{
expect(testManager.driverDistracted).to(beTrue());
- OCMVerifyAll(lockScreenIconObserver);
+ OCMVerifyAllWithDelay(mockDispatcher, 0.5);
});
});
});
diff --git a/SmartDeviceLinkTests/RPCSpecs/EnumSpecs/SDLDisplayTypeSpec.m b/SmartDeviceLinkTests/RPCSpecs/EnumSpecs/SDLDisplayTypeSpec.m
index 46aaa3411..3c76b43a7 100644
--- a/SmartDeviceLinkTests/RPCSpecs/EnumSpecs/SDLDisplayTypeSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/EnumSpecs/SDLDisplayTypeSpec.m
@@ -14,6 +14,8 @@ QuickSpecBegin(SDLDisplayTypeSpec)
describe(@"Individual Enum Value Tests", ^ {
it(@"Should match internal values", ^ {
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wdeprecated-declarations"
expect(SDLDisplayTypeCID).to(equal(@"CID"));
expect(SDLDisplayTypeType2).to(equal(@"TYPE2"));
expect(SDLDisplayTypeType5).to(equal(@"TYPE5"));
@@ -25,6 +27,7 @@ describe(@"Individual Enum Value Tests", ^ {
expect(SDLDisplayTypeMFD5).to(equal(@"MFD5"));
expect(SDLDisplayTypeGen38Inch).to(equal(@"GEN3_8-INCH"));
expect(SDLDisplayTypeGeneric).to(equal(@"SDL_GENERIC"));
+#pragma clang diagnostic pop
});
});
diff --git a/SmartDeviceLinkTests/RPCSpecs/EnumSpecs/SDLLockScreenStatusSpec.m b/SmartDeviceLinkTests/RPCSpecs/EnumSpecs/SDLLockScreenStatusSpec.m
deleted file mode 100644
index d6aaf4036..000000000
--- a/SmartDeviceLinkTests/RPCSpecs/EnumSpecs/SDLLockScreenStatusSpec.m
+++ /dev/null
@@ -1,26 +0,0 @@
-//
-// SDLLockScreenStatusSpec.m
-// SmartDeviceLink
-
-
-#import <Foundation/Foundation.h>
-
-#import <Quick/Quick.h>
-#import <Nimble/Nimble.h>
-
-#import "SDLLockScreenStatus.h"
-
-QuickSpecBegin(SDLLockScreenStatusSpec)
-
-describe(@"Individual Enum Value Tests", ^ {
- it(@"Should match internal values", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(SDLLockScreenStatusOff).to(equal(@"OFF"));
- expect(SDLLockScreenStatusOptional).to(equal(@"OPTIONAL"));
- expect(SDLLockScreenStatusRequired).to(equal(@"REQUIRED"));
-#pragma clang diagnostic pop
- });
-});
-
-QuickSpecEnd
diff --git a/SmartDeviceLinkTests/RPCSpecs/EnumSpecs/SDLServiceUpdateReasonSpec.m b/SmartDeviceLinkTests/RPCSpecs/EnumSpecs/SDLServiceUpdateReasonSpec.m
index a66d2df97..7dd7522e6 100644
--- a/SmartDeviceLinkTests/RPCSpecs/EnumSpecs/SDLServiceUpdateReasonSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/EnumSpecs/SDLServiceUpdateReasonSpec.m
@@ -15,11 +15,20 @@ QuickSpecBegin(SDLServiceUpdateReasonSpec)
describe(@"Individual Enum Value Tests", ^{
it(@"Should match internal values", ^{
+ expect(SDLServiceUpdateReasonPublished).to(equal(@"PUBLISHED"));
+ expect(SDLServiceUpdateReasonRemoved).to(equal(@"REMOVED"));
+ expect(SDLServiceUpdateReasonActivated).to(equal(@"ACTIVATED"));
+ expect(SDLServiceUpdateReasonDeactivated).to(equal(@"DEACTIVATED"));
+ expect(SDLServiceUpdateReasonManifestUpdate).to(equal(@"MANIFEST_UPDATE"));
+
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wdeprecated-declarations"
expect(SDLServiceUpdatePublished).to(equal(@"PUBLISHED"));
expect(SDLServiceUpdateRemoved).to(equal(@"REMOVED"));
expect(SDLServiceUpdateActivated).to(equal(@"ACTIVATED"));
expect(SDLServiceUpdateDeactivated).to(equal(@"DEACTIVATED"));
expect(SDLServiceUpdateManifestUpdate).to(equal(@"MANIFEST_UPDATE"));
+#pragma clang diagnostic pop
});
});
diff --git a/SmartDeviceLinkTests/RPCSpecs/EnumSpecs/SDLSupportedSeatSpec.m b/SmartDeviceLinkTests/RPCSpecs/EnumSpecs/SDLSupportedSeatSpec.m
index d01bda43f..581802716 100644
--- a/SmartDeviceLinkTests/RPCSpecs/EnumSpecs/SDLSupportedSeatSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/EnumSpecs/SDLSupportedSeatSpec.m
@@ -14,8 +14,11 @@ QuickSpecBegin(SDLSupportedSeatSpec)
describe(@"Individual Enum Value Tests", ^ {
it(@"Should match internal values", ^ {
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wdeprecated-declarations"
expect(SDLSupportedSeatDriver).to(equal(@"DRIVER"));
expect(SDLSupportedSeatFrontPassenger).to(equal(@"FRONT_PASSENGER"));
+#pragma clang diagnostic pop
});
});
diff --git a/SmartDeviceLinkTests/RPCSpecs/NotificationSpecs/SDLOnLockScreenStatusSpec.m b/SmartDeviceLinkTests/RPCSpecs/NotificationSpecs/SDLOnLockScreenStatusSpec.m
deleted file mode 100644
index da9c091df..000000000
--- a/SmartDeviceLinkTests/RPCSpecs/NotificationSpecs/SDLOnLockScreenStatusSpec.m
+++ /dev/null
@@ -1,80 +0,0 @@
-//
-// SDLOnLockScreenStatusSpec.m
-// SmartDeviceLink
-
-
-#import <Foundation/Foundation.h>
-
-#import <Quick/Quick.h>
-#import <Nimble/Nimble.h>
-
-#import "SDLOnLockScreenStatus.h"
-#import "SDLHMILevel.h"
-#import "SDLLockScreenStatus.h"
-#import "SDLRPCParameterNames.h"
-#import "SDLRPCFunctionNames.h"
-
-QuickSpecBegin(SDLOnLockScreenStatusSpec)
-
-describe(@"Getter/Setter Tests", ^ {
- it(@"Should set and get correctly", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLOnLockScreenStatus* testNotification = [[SDLOnLockScreenStatus alloc] init];
-#pragma clang diagnostic pop
- testNotification.driverDistractionStatus = @NO;
- testNotification.userSelected = @3;
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testNotification.lockScreenStatus = SDLLockScreenStatusRequired;
-#pragma clang diagnostic pop
- testNotification.hmiLevel = SDLHMILevelNone;
-
- expect(testNotification.driverDistractionStatus).to(equal(@NO));
- expect(testNotification.userSelected).to(equal(@3));
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testNotification.lockScreenStatus).to(equal(SDLLockScreenStatusRequired));
-#pragma clang diagnostic pop
- expect(testNotification.hmiLevel).to(equal(SDLHMILevelNone));
- });
-
- it(@"Should get correctly when initialized", ^ {
- NSMutableDictionary* dict = [@{SDLRPCParameterNameNotification:
- @{SDLRPCParameterNameParameters:
- @{@"driverDistractionStatus":@NO,
- @"userSelected":@3,
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- @"OnLockScreenStatus":SDLLockScreenStatusRequired,
-#pragma clang diagnostic pop
- @"hmiLevel":SDLHMILevelNone},
- SDLRPCParameterNameOperationName:@"OnLockScreenStatus"}} mutableCopy];
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLOnLockScreenStatus* testNotification = [[SDLOnLockScreenStatus alloc] initWithDictionary:dict];
-#pragma clang diagnostic pop
-
- expect(testNotification.driverDistractionStatus).to(equal(@NO));
- expect(testNotification.userSelected).to(equal(@3));
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testNotification.lockScreenStatus).to(equal(SDLLockScreenStatusRequired));
-#pragma clang diagnostic pop
- expect(testNotification.hmiLevel).to(equal(SDLHMILevelNone));
- });
-
- it(@"Should return nil if not set", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLOnLockScreenStatus* testNotification = [[SDLOnLockScreenStatus alloc] init];
-#pragma clang diagnostic pop
-
- expect(testNotification.driverDistractionStatus).to(beNil());
- expect(testNotification.userSelected).to(beNil());
- expect(testNotification.lockScreenStatus).to(beNil());
- expect(testNotification.hmiLevel).to(beNil());
- });
-});
-
-QuickSpecEnd
diff --git a/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLAddCommandSpec.m b/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLAddCommandSpec.m
index c89033af5..d036ba1ec 100644
--- a/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLAddCommandSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLAddCommandSpec.m
@@ -117,42 +117,6 @@ describe(@"initializers", ^{
});
});
- context(@"initWithId:vrCommands:menuName:parentId:position:iconValue:iconType:handler:", ^{
- __block UInt32 parentId = 1234;
- __block UInt16 position = 2;
-
- it(@"should initialize with an image", ^{
- NSString *iconValue = @"Icon";
- SDLImageType imageType = SDLImageTypeDynamic;
-
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testCommand = [[SDLAddCommand alloc] initWithId:commandId vrCommands:vrCommands menuName:menuName parentId:parentId position:position iconValue:iconValue iconType:imageType handler:nil];
-
- expect(testCommand.cmdID).to(equal(commandId));
- expect(testCommand.vrCommands).to(equal(vrCommands));
- expect(testCommand.menuParams.menuName).toNot(beNil());
- expect(testCommand.menuParams.parentID).to(equal(parentId));
- expect(testCommand.menuParams.position).to(equal(position));
- expect(testCommand.cmdIcon).toNot(beNil());
- #pragma clang diagnostic pop
- });
-
- it(@"should initialize without an image", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testCommand = [[SDLAddCommand alloc] initWithId:commandId vrCommands:vrCommands menuName:menuName parentId:parentId position:position iconValue:nil iconType:nil handler:nil];
-
- expect(testCommand.cmdID).to(equal(commandId));
- expect(testCommand.vrCommands).to(equal(vrCommands));
- expect(testCommand.menuParams.menuName).toNot(beNil());
- expect(testCommand.menuParams.parentID).to(equal(parentId));
- expect(testCommand.menuParams.position).to(equal(position));
- expect(testCommand.cmdIcon).to(beNil());
- #pragma clang diagnostic pop
- });
- });
-
context(@"initWithId:vrCommands:menuName:parentId:position:iconValue:iconType:iconIsTemplate:handler:", ^{
__block UInt32 parentId = 12345;
__block UInt16 position = 0;
diff --git a/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLAddSubMenuSpec.m b/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLAddSubMenuSpec.m
index 17ce72c6c..3dffd0961 100644
--- a/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLAddSubMenuSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLAddSubMenuSpec.m
@@ -27,19 +27,6 @@ describe(@"Getter/Setter Tests", ^ {
image = [[SDLImage alloc] initWithName:@"Test" isTemplate:false];
});
- it(@"should correctly initialize with initWithId:menuName:", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLAddSubMenu *testRequest = [[SDLAddSubMenu alloc] initWithId:menuId menuName:menuName];
- #pragma clang diagnostic pop
-
- expect(testRequest.menuID).to(equal(@(menuId)));
- expect(testRequest.position).to(beNil());
- expect(testRequest.menuName).to(equal(menuName));
- expect(testRequest.menuIcon).to(beNil());
- expect(testRequest.parentID).to(beNil());
- });
-
it(@"should correctly initialize with initWithMenuID:menuName:", ^{
SDLAddSubMenu *testRequest = [[SDLAddSubMenu alloc] initWithMenuID:menuId menuName:menuName];
@@ -50,46 +37,6 @@ describe(@"Getter/Setter Tests", ^ {
expect(testRequest.parentID).to(beNil());
});
- it(@"should correctly initialize with initWithId:menuName:position:", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLAddSubMenu *testRequest = [[SDLAddSubMenu alloc] initWithId:menuId menuName:menuName position:position];
-
- expect(testRequest.menuID).to(equal(@(menuId)));
- expect(testRequest.position).to(equal(@(position)));
- expect(testRequest.menuName).to(equal(menuName));
- expect(testRequest.menuIcon).to(beNil());
- expect(testRequest.parentID).to(beNil());
- #pragma clang diagnostic pop
- });
-
- it(@"should correctly initialize with initWithId:menuName:menuIcon:position:", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLAddSubMenu *testRequest = [[SDLAddSubMenu alloc] initWithId:menuId menuName:menuName menuIcon:image position:position];
-
- expect(testRequest.menuID).to(equal(@(menuId)));
- expect(testRequest.position).to(equal(@(position)));
- expect(testRequest.menuName).to(equal(menuName));
- expect(testRequest.menuIcon).to(equal(image));
- expect(testRequest.parentID).to(beNil());
-#pragma clang diagnostic pop
- });
-
- it(@"should correctly initialize with initWithId:menuName:menuLayout:menuIcon:position:", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLAddSubMenu *testRequest = [[SDLAddSubMenu alloc] initWithId:menuId menuName:menuName menuLayout:testLayout menuIcon:image position:position];
- #pragma clang diagnostic pop
-
- expect(testRequest.menuID).to(equal(@(menuId)));
- expect(testRequest.position).to(equal(@(position)));
- expect(testRequest.menuName).to(equal(menuName));
- expect(testRequest.menuIcon).to(equal(image));
- expect(testRequest.menuLayout).to(equal(testLayout));
- expect(testRequest.parentID).to(beNil());
- });
-
it(@"should correctly initialize with initWithMenuID:menuName:menuLayout:menuIcon:position:parentID:", ^{
SDLAddSubMenu *testRequest = [[SDLAddSubMenu alloc] initWithMenuID:menuId menuName:menuName position:@(position) menuIcon:image menuLayout:testLayout parentID:parentID];
@@ -102,23 +49,25 @@ describe(@"Getter/Setter Tests", ^ {
});
it(@"Should set and get correctly", ^ {
- SDLAddSubMenu* testRequest = [[SDLAddSubMenu alloc] init];
+ SDLAddSubMenu *testRequest = [[SDLAddSubMenu alloc] init];
testRequest.menuID = @4345645;
testRequest.position = @27;
testRequest.menuName = @"Welcome to the menu";
testRequest.menuIcon = image;
testRequest.menuLayout = testLayout;
+ testRequest.parentID = parentID;
expect(testRequest.menuID).to(equal(@(menuId)));
expect(testRequest.position).to(equal(@(position)));
expect(testRequest.menuName).to(equal(menuName));
expect(testRequest.menuIcon).to(equal(image));
expect(testRequest.menuLayout).to(equal(testLayout));
+ expect(testRequest.parentID).to(equal(parentID));
});
it(@"Should get correctly when initialized", ^ {
- NSMutableDictionary<NSString *, id> *dict = [@{SDLRPCParameterNameRequest:
+ NSDictionary *dict = @{SDLRPCParameterNameRequest:
@{SDLRPCParameterNameParameters:
@{SDLRPCParameterNameMenuID: @(menuId),
SDLRPCParameterNamePosition: @(position),
@@ -129,27 +78,26 @@ describe(@"Getter/Setter Tests", ^ {
SDLRPCParameterNameMenuLayout: testLayout,
SDLRPCParameterNameParentID: parentID
},
- SDLRPCParameterNameOperationName:SDLRPCFunctionNameAddSubMenu}} mutableCopy];
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLAddSubMenu* testRequest = [[SDLAddSubMenu alloc] initWithDictionary:dict];
-#pragma clang diagnostic pop
+ SDLRPCParameterNameOperationName:SDLRPCFunctionNameAddSubMenu}};
+ SDLAddSubMenu *testRequest = [[SDLAddSubMenu alloc] initWithDictionary:dict];
expect(testRequest.menuID).to(equal(@(menuId)));
expect(testRequest.position).to(equal(@(position)));
expect(testRequest.menuName).to(equal(menuName));
expect(testRequest.menuIcon.value).to(equal(@"Test"));
expect(testRequest.menuLayout).to(equal(testLayout));
+ expect(testRequest.parentID).to(equal(parentID));
});
it(@"Should return nil if not set", ^ {
- SDLAddSubMenu* testRequest = [[SDLAddSubMenu alloc] init];
+ SDLAddSubMenu *testRequest = [[SDLAddSubMenu alloc] init];
expect(testRequest.menuID).to(beNil());
expect(testRequest.position).to(beNil());
expect(testRequest.menuName).to(beNil());
expect(testRequest.menuIcon).to(beNil());
expect(testRequest.menuLayout).to(beNil());
+ expect(testRequest.parentID).to(beNil());
});
});
diff --git a/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLAlertSpec.m b/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLAlertSpec.m
index ec30bbbd9..1ae635343 100644
--- a/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLAlertSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLAlertSpec.m
@@ -14,8 +14,6 @@
QuickSpecBegin(SDLAlertSpec)
-static UInt16 const SDLDefaultDuration = 5000;
-
describe(@"Getter/Setter Tests", ^ {
__block SDLAlert *testRequest = nil;
__block NSString *testAlertText1 = @"alert#1";
@@ -86,23 +84,20 @@ describe(@"Getter/Setter Tests", ^ {
describe(@"Initializing", ^{
it(@"Should initialize correctly with a dictionary", ^{
- NSDictionary<NSString *, id> *dict = @{SDLRPCParameterNameRequest:
- @{SDLRPCParameterNameParameters:
- @{SDLRPCParameterNameAlertText1:testAlertText1,
- SDLRPCParameterNameAlertText2:testAlertText2,
- SDLRPCParameterNameAlertText3:testAlertText3,
- SDLRPCParameterNameTTSChunks:testTTSChunks,
- SDLRPCParameterNameDuration:@(testDuration),
- SDLRPCParameterNamePlayTone:@(testPlayTone),
- SDLRPCParameterNameProgressIndicator:@(testProgressIndicator),
- SDLRPCParameterNameSoftButtons:testSoftButtons,
- SDLRPCParameterNameAlertIcon:testImage,
- SDLRPCParameterNameCancelID:@(testCancelID)},
- SDLRPCParameterNameOperationName:SDLRPCFunctionNameAlert}};
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
+ NSDictionary *dict = @{SDLRPCParameterNameRequest:
+ @{SDLRPCParameterNameParameters:
+ @{SDLRPCParameterNameAlertText1:testAlertText1,
+ SDLRPCParameterNameAlertText2:testAlertText2,
+ SDLRPCParameterNameAlertText3:testAlertText3,
+ SDLRPCParameterNameTTSChunks:testTTSChunks,
+ SDLRPCParameterNameDuration:@(testDuration),
+ SDLRPCParameterNamePlayTone:@(testPlayTone),
+ SDLRPCParameterNameProgressIndicator:@(testProgressIndicator),
+ SDLRPCParameterNameSoftButtons:testSoftButtons,
+ SDLRPCParameterNameAlertIcon:testImage,
+ SDLRPCParameterNameCancelID:@(testCancelID)},
+ SDLRPCParameterNameOperationName:SDLRPCFunctionNameAlert}};
testRequest = [[SDLAlert alloc] initWithDictionary:dict];
- #pragma clang diagnostic pop
expect(testRequest.alertText1).to(equal(testAlertText1));
expect(testRequest.alertText2).to(equal(testAlertText2));
@@ -148,137 +143,8 @@ describe(@"Getter/Setter Tests", ^ {
expect(testRequest.cancelID).to(equal(testCancelID));
});
- it(@"Should initialize correctly with initWithAlertText1:alertText2:duration:", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testRequest = [[SDLAlert alloc] initWithAlertText1:testAlertText1 alertText2:testAlertText2 duration:testDuration];
- #pragma clang diagnostic pop
-
- expect(testRequest.alertText1).to(equal(testAlertText1));
- expect(testRequest.alertText2).to(equal(testAlertText2));
- expect(testRequest.alertText3).to(beNil());
- expect(testRequest.ttsChunks).to(beNil());
- expect(testRequest.duration).to(equal(testDuration));
- expect(testRequest.playTone).to(beFalse());
- expect(testRequest.progressIndicator).to(beFalse());
- expect(testRequest.softButtons).to(beNil());
- expect(testRequest.alertIcon).to(beNil());
- expect(testRequest.cancelID).to(beNil());
- });
-
- it(@"Should initialize correctly with initWithAlertText1:alertText2:alertText3:", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testRequest = [[SDLAlert alloc] initWithAlertText1:testAlertText1 alertText2:testAlertText2 alertText3:testAlertText3];
- #pragma clang diagnostic pop
-
- expect(testRequest.alertText1).to(equal(testAlertText1));
- expect(testRequest.alertText2).to(equal(testAlertText2));
- expect(testRequest.alertText3).to(equal(testAlertText3));
- expect(testRequest.ttsChunks).to(beNil());
- expect(testRequest.duration).to(equal(SDLDefaultDuration));
- expect(testRequest.playTone).to(beFalse());
- expect(testRequest.progressIndicator).to(beFalse());
- expect(testRequest.softButtons).to(beNil());
- expect(testRequest.alertIcon).to(beNil());
- expect(testRequest.cancelID).to(beNil());
- });
-
- it(@"Should initialize correctly with initWithAlertText1:alertText2:alertText3:duration", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testRequest = [[SDLAlert alloc] initWithAlertText1:testAlertText1 alertText2:testAlertText2 alertText3:testAlertText3 duration:testDuration];
- #pragma clang diagnostic pop
-
- expect(testRequest.alertText1).to(equal(testAlertText1));
- expect(testRequest.alertText2).to(equal(testAlertText2));
- expect(testRequest.alertText3).to(equal(testAlertText3));
- expect(testRequest.ttsChunks).to(beNil());
- expect(testRequest.duration).to(equal(testDuration));
- expect(testRequest.playTone).to(beFalse());
- expect(testRequest.progressIndicator).to(beFalse());
- expect(testRequest.softButtons).to(beNil());
- expect(testRequest.alertIcon).to(beNil());
- expect(testRequest.cancelID).to(beNil());
- });
-
- it(@"Should initialize correctly with initWithAlertText1:alertText2:alertText3:duration:softButtons:", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testRequest = [[SDLAlert alloc] initWithAlertText1:testAlertText1 alertText2:testAlertText2 alertText3:testAlertText3 duration:testDuration softButtons:testSoftButtons];
- #pragma clang diagnostic pop
-
- expect(testRequest.alertText1).to(equal(testAlertText1));
- expect(testRequest.alertText2).to(equal(testAlertText2));
- expect(testRequest.alertText3).to(equal(testAlertText3));
- expect(testRequest.ttsChunks).to(beNil());
- expect(testRequest.duration).to(equal(testDuration));
- expect(testRequest.playTone).to(beFalse());
- expect(testRequest.progressIndicator).to(beFalse());
- expect(testRequest.softButtons).to(equal(testSoftButtons));
- expect(testRequest.alertIcon).to(beNil());
- expect(testRequest.cancelID).to(beNil());
- });
-
- it(@"Should initialize correctly with initWithTTS:playTone:", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testRequest = [[SDLAlert alloc] initWithTTS:testTTSString playTone:testPlayTone];
- #pragma clang diagnostic pop
-
- expect(testRequest.alertText1).to(beNil());
- expect(testRequest.alertText2).to(beNil());
- expect(testRequest.alertText3).to(beNil());
- expect(testRequest.ttsChunks).to(equal([SDLTTSChunk textChunksFromString:testTTSString]));
- expect(testRequest.duration).to(equal(SDLDefaultDuration));
- expect(testRequest.playTone).to(equal(testPlayTone));
- expect(testRequest.progressIndicator).to(beFalse());
- expect(testRequest.softButtons).to(beNil());
- expect(testRequest.alertIcon).to(beNil());
- expect(testRequest.cancelID).to(beNil());
- });
-
- it(@"Should initialize correctly with initWithTTS:alertText1:alertText2:playTone:duration:", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testRequest = [[SDLAlert alloc] initWithTTS:testTTSString alertText1:testAlertText1 alertText2:testAlertText2 playTone:testPlayTone duration:testDuration];
- #pragma clang diagnostic pop
-
- expect(testRequest.alertText1).to(equal(testAlertText1));
- expect(testRequest.alertText2).to(equal(testAlertText2));
- expect(testRequest.alertText3).to(beNil());
- expect(testRequest.ttsChunks).to(equal([SDLTTSChunk textChunksFromString:testTTSString]));
- expect(testRequest.duration).to(equal(testDuration));
- expect(testRequest.playTone).to(equal(testPlayTone));
- expect(testRequest.progressIndicator).to(beFalse());
- expect(testRequest.softButtons).to(beNil());
- expect(testRequest.alertIcon).to(beNil());
- expect(testRequest.cancelID).to(beNil());
- });
-
- it(@"Should initialize correctly with initWithTTS:alertText1:alertText2:alertText3:playTone:duration:", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testRequest = [[SDLAlert alloc] initWithTTS:testTTSString alertText1:testAlertText1 alertText2:testAlertText2 alertText3:testAlertText3 playTone:testPlayTone duration:testDuration];
- #pragma clang diagnostic pop
-
- expect(testRequest.alertText1).to(equal(testAlertText1));
- expect(testRequest.alertText2).to(equal(testAlertText2));
- expect(testRequest.alertText3).to(equal(testAlertText3));
- expect(testRequest.ttsChunks).to(equal([SDLTTSChunk textChunksFromString:testTTSString]));
- expect(testRequest.duration).to(equal(testDuration));
- expect(testRequest.playTone).to(equal(testPlayTone));
- expect(testRequest.progressIndicator).to(beFalse());
- expect(testRequest.softButtons).to(beNil());
- expect(testRequest.alertIcon).to(beNil());
- expect(testRequest.cancelID).to(beNil());
- });
-
it(@"Should initialize correctly with initWithTTSChunks:playTone:", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
testRequest = [[SDLAlert alloc] initWithTTSChunks:testTTSChunks playTone:testPlayTone];
- #pragma clang diagnostic pop
expect(testRequest.alertText1).to(beNil());
expect(testRequest.alertText2).to(beNil());
@@ -291,42 +157,6 @@ describe(@"Getter/Setter Tests", ^ {
expect(testRequest.alertIcon).to(beNil());
expect(testRequest.cancelID).to(beNil());
});
-
- it(@"Should initialize correctly with initWithTTSChunks:alertText1:alertText2:alertText3:playTone:softButtons:", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testRequest = [[SDLAlert alloc] initWithTTSChunks:testTTSChunks alertText1:testAlertText1 alertText2:testAlertText2 alertText3:testAlertText3 playTone:testPlayTone softButtons:testSoftButtons];
- #pragma clang diagnostic pop
-
- expect(testRequest.alertText1).to(equal(testAlertText1));
- expect(testRequest.alertText2).to(equal(testAlertText2));
- expect(testRequest.alertText3).to(equal(testAlertText3));
- expect(testRequest.ttsChunks).to(equal(testTTSChunks));
- expect(testRequest.duration).to(equal(SDLDefaultDuration));
- expect(testRequest.playTone).to(equal(testPlayTone));
- expect(testRequest.progressIndicator).to(beFalse());
- expect(testRequest.softButtons).to(equal(testSoftButtons));
- expect(testRequest.alertIcon).to(beNil());
- expect(testRequest.cancelID).to(beNil());
- });
-
- it(@"Should initialize correctly with initWithTTSChunks:alertText1:alertText2:alertText3:playTone:duration:softButtons:", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testRequest = [[SDLAlert alloc] initWithTTSChunks:testTTSChunks alertText1:testAlertText1 alertText2:testAlertText2 alertText3:testAlertText3 playTone:testPlayTone duration:testDuration softButtons:testSoftButtons];
- #pragma clang diagnostic pop
-
- expect(testRequest.alertText1).to(equal(testAlertText1));
- expect(testRequest.alertText2).to(equal(testAlertText2));
- expect(testRequest.alertText3).to(equal(testAlertText3));
- expect(testRequest.ttsChunks).to(equal(testTTSChunks));
- expect(testRequest.duration).to(equal(testDuration));
- expect(testRequest.playTone).to(equal(testPlayTone));
- expect(testRequest.progressIndicator).to(beFalse());
- expect(testRequest.softButtons).to(equal(testSoftButtons));
- expect(testRequest.alertIcon).to(beNil());
- expect(testRequest.cancelID).to(beNil());
- });
});
afterEach(^{
diff --git a/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLButtonPressSpec.m b/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLButtonPressSpec.m
index d9a49d20c..cb411cf76 100644
--- a/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLButtonPressSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLButtonPressSpec.m
@@ -30,22 +30,18 @@ describe(@"Getter/Setter Tests", ^ {
expect(testRequest.moduleId).to(equal(@"123"));
expect(testRequest.buttonName).to(equal(SDLButtonNameAC));
expect(testRequest.buttonPressMode).to(equal(SDLButtonPressModeShort));
-
});
it(@"Should get correctly when initialized with a dictionary", ^ {
- NSMutableDictionary<NSString *, id> *dict = [@{SDLRPCParameterNameRequest:
- @{SDLRPCParameterNameParameters:
- @{SDLRPCParameterNameModuleType : SDLModuleTypeClimate,
- SDLRPCParameterNameButtonName : SDLButtonNameAC,
- SDLRPCParameterNameButtonPressMode : SDLButtonPressModeShort,
- SDLRPCParameterNameModuleId:@"123"
- },
- SDLRPCParameterNameOperationName:SDLRPCFunctionNameButtonPress}} mutableCopy];
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLButtonPress* testRequest = [[SDLButtonPress alloc] initWithDictionary:dict];
-#pragma clang diagnostic pop
+ NSDictionary *dict = @{SDLRPCParameterNameRequest:
+ @{SDLRPCParameterNameParameters:
+ @{SDLRPCParameterNameModuleType : SDLModuleTypeClimate,
+ SDLRPCParameterNameButtonName : SDLButtonNameAC,
+ SDLRPCParameterNameButtonPressMode : SDLButtonPressModeShort,
+ SDLRPCParameterNameModuleId:@"123"
+ },
+ SDLRPCParameterNameOperationName:SDLRPCFunctionNameButtonPress}};
+ SDLButtonPress *testRequest = [[SDLButtonPress alloc] initWithDictionary:dict];
expect(testRequest.moduleType).to(equal(SDLModuleTypeClimate));
expect(testRequest.moduleId).to(equal(@"123"));
@@ -53,25 +49,6 @@ describe(@"Getter/Setter Tests", ^ {
expect(testRequest.buttonPressMode).to(equal(SDLButtonPressModeShort));
});
- it(@"Should get correctly when initialized with initWithButtonName:moduleType:", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLButtonPress *testRequest = [[SDLButtonPress alloc] initWithButtonName:SDLButtonNameAC moduleType:SDLModuleTypeClimate];
-#pragma clang diagnostic pop
- expect(testRequest.buttonName).to(equal(SDLButtonNameAC));
- expect(testRequest.moduleType).to(equal(SDLModuleTypeClimate));
- });
-
- it(@"Should get correctly when initialized with initWithButtonName:moduleType:moduleId:", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLButtonPress *testRequest = [[SDLButtonPress alloc] initWithButtonName:SDLButtonNameAC moduleType:SDLModuleTypeClimate moduleId:@"123"];
-#pragma clang diagnostic pop
- expect(testRequest.buttonName).to(equal(SDLButtonNameAC));
- expect(testRequest.moduleType).to(equal(SDLModuleTypeClimate));
- expect(testRequest.moduleId).to(equal(@"123"));
- });
-
it(@"Should get correctly when initialized with initWithButtonName:moduleType:moduleId:buttonPressMode:", ^ {
SDLButtonPress *testRequest = [[SDLButtonPress alloc] initWithButtonName:SDLButtonNameAC moduleType:SDLModuleTypeClimate moduleId:@"123" buttonPressMode:SDLButtonPressModeShort];
diff --git a/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLGetInteriorVehicleDataSpec.m b/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLGetInteriorVehicleDataSpec.m
index 3a4d63f4f..55e6ead8a 100755
--- a/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLGetInteriorVehicleDataSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLGetInteriorVehicleDataSpec.m
@@ -28,16 +28,13 @@ describe(@"Getter/Setter Tests", ^ {
});
it(@"Should get correctly when initialized with a dictionary", ^ {
- NSMutableDictionary<NSString *, id> *dict = [@{SDLRPCParameterNameRequest:
- @{SDLRPCParameterNameParameters:
- @{SDLRPCParameterNameModuleType : SDLModuleTypeRadio,
- SDLRPCParameterNameModuleId: @"123",
- SDLRPCParameterNameSubscribe : @YES},
- SDLRPCParameterNameOperationName:SDLRPCFunctionNameGetInteriorVehicleData}} mutableCopy];
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLGetInteriorVehicleData* testRequest = [[SDLGetInteriorVehicleData alloc] initWithDictionary:dict];
-#pragma clang diagnostic pop
+ NSDictionary *dict = @{SDLRPCParameterNameRequest:
+ @{SDLRPCParameterNameParameters:
+ @{SDLRPCParameterNameModuleType : SDLModuleTypeRadio,
+ SDLRPCParameterNameModuleId: @"123",
+ SDLRPCParameterNameSubscribe : @YES},
+ SDLRPCParameterNameOperationName:SDLRPCFunctionNameGetInteriorVehicleData}};
+ SDLGetInteriorVehicleData *testRequest = [[SDLGetInteriorVehicleData alloc] initWithDictionary:dict];
expect(testRequest.moduleType).to(equal(SDLModuleTypeRadio));
expect(testRequest.subscribe).to(equal(@YES));
@@ -45,16 +42,6 @@ describe(@"Getter/Setter Tests", ^ {
});
it(@"Should get correctly when initialized with module type", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLGetInteriorVehicleData* testRequest = [[SDLGetInteriorVehicleData alloc] initWithModuleType:SDLModuleTypeRadio];
-#pragma clang diagnostic pop
-
- expect(testRequest.moduleType).to(equal(SDLModuleTypeRadio));
- expect(testRequest.moduleId).to(beNil());
- });
-
- it(@"Should get correctly when initialized with module type", ^ {
SDLGetInteriorVehicleData* testRequest = [[SDLGetInteriorVehicleData alloc] initWithModuleType:SDLModuleTypeRadio moduleId:@"123"];
expect(testRequest.moduleType).to(equal(SDLModuleTypeRadio));
@@ -62,17 +49,6 @@ describe(@"Getter/Setter Tests", ^ {
});
it(@"Should get correctly when initialized with module type and subscribe", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLGetInteriorVehicleData* testRequest = [[SDLGetInteriorVehicleData alloc] initAndSubscribeToModuleType:SDLModuleTypeRadio];
-#pragma clang diagnostic pop
-
- expect(testRequest.moduleType).to(equal(SDLModuleTypeRadio));
- expect(testRequest.subscribe).to(equal(@YES));
- expect(testRequest.moduleId).to(beNil());
- });
-
- it(@"Should get correctly when initialized with module type and subscribe", ^ {
SDLGetInteriorVehicleData* testRequest = [[SDLGetInteriorVehicleData alloc] initAndSubscribeToModuleType:SDLModuleTypeRadio moduleId:@"123"];
expect(testRequest.moduleType).to(equal(SDLModuleTypeRadio));
@@ -80,17 +56,6 @@ describe(@"Getter/Setter Tests", ^ {
expect(testRequest.moduleId).to(equal(@"123"));
});
- it(@"Should get correctly when initialized with module type and unsubscribe", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLGetInteriorVehicleData* testRequest = [[SDLGetInteriorVehicleData alloc] initAndUnsubscribeToModuleType:SDLModuleTypeRadio];
-#pragma clang diagnostic pop
-
- expect(testRequest.moduleType).to(equal(SDLModuleTypeRadio));
- expect(testRequest.subscribe).to(equal(@NO));
- expect(testRequest.moduleId).to(beNil());
- });
-
it(@"Should get correctly when initialized with module type and unsubscribe", ^ {
SDLGetInteriorVehicleData* testRequest = [[SDLGetInteriorVehicleData alloc] initAndUnsubscribeToModuleType:SDLModuleTypeRadio moduleId:@"123"];
diff --git a/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLGetVehicleDataSpec.m b/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLGetVehicleDataSpec.m
index 464677b44..84d1806df 100644
--- a/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLGetVehicleDataSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLGetVehicleDataSpec.m
@@ -239,104 +239,6 @@ describe(@"initializers", ^{
});
});
- context(@"initWithAccelerationPedalPosition:airbagStatus:beltStatus:bodyInformation:clusterModeStatus:deviceStatus:driverBraking:eCallInfo:emergencyEvent:engineTorque:externalTemperature:fuelLevel:fuelLevelState:gps:headLampStatus:instantFuelConsumption:myKey:odometer:prndl:rpm:speed:steeringWheelAngle:tirePressure:wiperStatus:windowStatus:", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLGetVehicleData *testRequest = [[SDLGetVehicleData alloc] initWithAccelerationPedalPosition:YES airbagStatus:YES beltStatus:YES bodyInformation:YES clusterModeStatus:YES deviceStatus:YES driverBraking:YES eCallInfo:YES emergencyEvent:YES engineTorque:YES externalTemperature:YES fuelLevel:YES fuelLevelState:YES gps:YES headLampStatus:YES instantFuelConsumption:YES myKey:YES odometer:YES prndl:YES rpm:YES speed:YES steeringWheelAngle:YES tirePressure:YES vin:YES wiperStatus:YES];
-#pragma clang diagnostic pop
-
- it(@"expect all properties to be set properly", ^{
- expect(testRequest.accPedalPosition).to(equal(@YES));
- expect(testRequest.airbagStatus).to(equal(@YES));
- expect(testRequest.beltStatus).to(equal(@YES));
- expect(testRequest.bodyInformation).to(equal(@YES));
- expect(testRequest.cloudAppVehicleID).to(beNil());
- expect(testRequest.clusterModeStatus).to(equal(@YES));
- expect(testRequest.deviceStatus).to(equal(@YES));
- expect(testRequest.driverBraking).to(equal(@YES));
- expect(testRequest.eCallInfo).to(equal(@YES));
- expect(testRequest.electronicParkBrakeStatus).to(beNil());
- expect(testRequest.emergencyEvent).to(equal(@YES));
- expect(testRequest.engineOilLife).to(beNil());
- expect(testRequest.engineTorque).to(equal(@YES));
- expect(testRequest.externalTemperature).to(equal(@YES));
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testRequest.fuelLevel).to(equal(@YES));
- expect(testRequest.fuelLevel_State).to(equal(@YES));
-#pragma clang diagnostic pop
- expect(testRequest.fuelRange).to(beNil());
- expect(testRequest.gearStatus).to(beNil());
- expect(testRequest.gps).to(equal(@YES));
- expect(testRequest.handsOffSteering).to(beNil());
- expect(testRequest.headLampStatus).to(equal(@YES));
- expect(testRequest.instantFuelConsumption).to(equal(@YES));
- expect(testRequest.myKey).to(equal(@YES));
- expect(testRequest.odometer).to(equal(@YES));
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testRequest.prndl).to(equal(@YES));
-#pragma clang diagnostic pop
- expect(testRequest.rpm).to(equal(@YES));
- expect(testRequest.speed).to(equal(@YES));
- expect(testRequest.stabilityControlsStatus).to(beNil());
- expect(testRequest.steeringWheelAngle).to(equal(@YES));
- expect(testRequest.tirePressure).to(equal(@YES));
- expect(testRequest.turnSignal).to(beNil());
- expect(testRequest.windowStatus).to(beNil());
- expect(testRequest.wiperStatus).to(equal(@YES));
- });
- });
-
- context(@"initWithAccelerationPedalPosition:airbagStatus:beltStatus:bodyInformation:clusterModeStatus:deviceStatus:driverBraking:eCallInfo:emergencyEvent:engineOilLife:engineTorque:externalTemperature:fuelLevel:fuelLevelState:gps:headLampStatus:instantFuelConsumption:myKey:odometer:prndl:rpm:speed:steeringWheelAngle:tirePressure:wiperStatus:", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLGetVehicleData *testRequest = [[SDLGetVehicleData alloc] initWithAccelerationPedalPosition:YES airbagStatus:YES beltStatus:YES bodyInformation:YES clusterModeStatus:YES deviceStatus:YES driverBraking:YES eCallInfo:YES electronicParkBrakeStatus:YES emergencyEvent:YES engineOilLife:YES engineTorque:YES externalTemperature:YES fuelLevel:YES fuelLevelState:YES fuelRange:YES gps:YES headLampStatus:YES instantFuelConsumption:YES myKey:YES odometer:YES prndl:YES rpm:YES speed:YES steeringWheelAngle:YES tirePressure:YES turnSignal:YES vin:YES wiperStatus:YES];
-#pragma clang diagnostic pop
-
- it(@"expect all properties to be set properly", ^{
- expect(testRequest.accPedalPosition).to(equal(@YES));
- expect(testRequest.airbagStatus).to(equal(@YES));
- expect(testRequest.beltStatus).to(equal(@YES));
- expect(testRequest.bodyInformation).to(equal(@YES));
- expect(testRequest.cloudAppVehicleID).to(beNil());
- expect(testRequest.clusterModeStatus).to(equal(@YES));
- expect(testRequest.deviceStatus).to(equal(@YES));
- expect(testRequest.driverBraking).to(equal(@YES));
- expect(testRequest.eCallInfo).to(equal(@YES));
- expect(testRequest.electronicParkBrakeStatus).to(equal(@YES));
- expect(testRequest.emergencyEvent).to(equal(@YES));
- expect(testRequest.engineOilLife).to(equal(@YES));
- expect(testRequest.engineTorque).to(equal(@YES));
- expect(testRequest.externalTemperature).to(equal(@YES));
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testRequest.fuelLevel).to(equal(@YES));
- expect(testRequest.fuelLevel_State).to(equal(@YES));
-#pragma clang diagnostic push
- expect(testRequest.fuelRange).to(equal(@YES));
- expect(testRequest.gearStatus).to(beNil());
- expect(testRequest.gps).to(equal(@YES));
- expect(testRequest.handsOffSteering).to(beNil());
- expect(testRequest.headLampStatus).to(equal(@YES));
- expect(testRequest.instantFuelConsumption).to(equal(@YES));
- expect(testRequest.myKey).to(equal(@YES));
- expect(testRequest.odometer).to(equal(@YES));
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testRequest.prndl).to(equal(@YES));
-#pragma clang diagnostic pop
- expect(testRequest.rpm).to(equal(@YES));
- expect(testRequest.speed).to(equal(@YES));
- expect(testRequest.stabilityControlsStatus).to(beNil());
- expect(testRequest.steeringWheelAngle).to(equal(@YES));
- expect(testRequest.tirePressure).to(equal(@YES));
- expect(testRequest.turnSignal).to(equal(@YES));
- expect(testRequest.windowStatus).to(beNil());
- expect(testRequest.wiperStatus).to(equal(@YES));
- });
- });
-
context(@"initWithAccelerationPedalPosition:airbagStatus:beltStatus:bodyInformation:cloudAppVehicleID:clusterModeStatus:deviceStatus:driverBraking:eCallInfo:emergencyEvent:engineOilLife:engineTorque:externalTemperature:fuelLevel:fuelLevelState:gps:headLampStatus:instantFuelConsumption:myKey:odometer:prndl:rpm:speed:steeringWheelAngle:tirePressure:wiperStatus:", ^{
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
diff --git a/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLPerformInteractionSpec.m b/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLPerformInteractionSpec.m
index aa28359d3..69ee0698f 100644
--- a/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLPerformInteractionSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLPerformInteractionSpec.m
@@ -25,7 +25,6 @@ describe(@"Getter/Setter Tests", ^ {
__block NSString *testInitialPromptString = nil;
__block SDLInteractionMode testInteractionMode = SDLInteractionModeVoiceRecognitionOnly;
__block NSArray<NSNumber<SDLUInt> *> *testInteractionChoiceSetIDList = nil;
- __block UInt16 testInteractionChoiceSetID = 48212;
__block NSString *testHelpPromptString = nil;
__block NSArray<SDLTTSChunk *> *testHelpPrompt = nil;
__block NSString *testTimeoutPromptString = nil;
@@ -95,23 +94,20 @@ describe(@"Getter/Setter Tests", ^ {
describe(@"Initializing", ^{
it(@"Should initialize correctly with a dictionary", ^ {
- NSDictionary<NSString *, id> *dict = @{SDLRPCParameterNameRequest:
- @{SDLRPCParameterNameParameters:
- @{SDLRPCParameterNameInitialText:testInitialText,
- SDLRPCParameterNameInitialPrompt:testInitialPrompt,
- SDLRPCParameterNameInteractionMode:testInteractionMode,
- SDLRPCParameterNameInteractionChoiceSetIdList:testInteractionChoiceSetIDList,
- SDLRPCParameterNameHelpPrompt:testHelpPrompt,
- SDLRPCParameterNameTimeoutPrompt:testTimeoutPrompt,
- SDLRPCParameterNameTimeout:@(testTimeout),
- SDLRPCParameterNameVRHelp:testVRHelp,
- SDLRPCParameterNameInteractionLayout:testinteractionLayout,
- SDLRPCParameterNameCancelID:@(testCancelID)},
- SDLRPCParameterNameOperationName:SDLRPCFunctionNamePerformInteraction}};
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
+ NSDictionary *dict = @{SDLRPCParameterNameRequest:
+ @{SDLRPCParameterNameParameters:
+ @{SDLRPCParameterNameInitialText:testInitialText,
+ SDLRPCParameterNameInitialPrompt:testInitialPrompt,
+ SDLRPCParameterNameInteractionMode:testInteractionMode,
+ SDLRPCParameterNameInteractionChoiceSetIdList:testInteractionChoiceSetIDList,
+ SDLRPCParameterNameHelpPrompt:testHelpPrompt,
+ SDLRPCParameterNameTimeoutPrompt:testTimeoutPrompt,
+ SDLRPCParameterNameTimeout:@(testTimeout),
+ SDLRPCParameterNameVRHelp:testVRHelp,
+ SDLRPCParameterNameInteractionLayout:testinteractionLayout,
+ SDLRPCParameterNameCancelID:@(testCancelID)},
+ SDLRPCParameterNameOperationName:SDLRPCFunctionNamePerformInteraction}};
testRequest = [[SDLPerformInteraction alloc] initWithDictionary:dict];
- #pragma clang diagnostic pop
expect(testRequest.initialText).to(equal(testInitialText));
expect(testRequest.initialPrompt).to(equal(testInitialPrompt));
@@ -156,150 +152,6 @@ describe(@"Getter/Setter Tests", ^ {
expect(testRequest.interactionLayout).to(equal(testinteractionLayout));
expect(testRequest.cancelID).to(equal(testCancelID));
});
-
- it(@"Should initialize correctly with initWithInteractionChoiceSetId:", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testRequest = [[SDLPerformInteraction alloc] initWithInteractionChoiceSetId:testInteractionChoiceSetID];
- #pragma clang diagnostic pop
-
- expect(testRequest.initialText).to(beNil());
- expect(testRequest.initialPrompt).to(beNil());
- expect(testRequest.interactionMode).to(beNil());
- expect(testRequest.interactionChoiceSetIDList).to(equal(@[@(testInteractionChoiceSetID)]));
- expect(testRequest.helpPrompt).to(beNil());
- expect(testRequest.timeoutPrompt).to(beNil());
- expect(testRequest.timeout).to(beNil());
- expect(testRequest.vrHelp).to(beNil());
- expect(testRequest.interactionLayout).to(beNil());
- expect(testRequest.cancelID).to(beNil());
- });
-
- it(@"Should initialize correctly with initWithInteractionChoiceSetIdList:", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testRequest = [[SDLPerformInteraction alloc] initWithInteractionChoiceSetIdList:testInteractionChoiceSetIDList];
- #pragma clang diagnostic pop
-
- expect(testRequest.initialText).to(beNil());
- expect(testRequest.initialPrompt).to(beNil());
- expect(testRequest.interactionMode).to(beNil());
- expect(testRequest.interactionChoiceSetIDList).to(equal(testInteractionChoiceSetIDList));
- expect(testRequest.helpPrompt).to(beNil());
- expect(testRequest.timeoutPrompt).to(beNil());
- expect(testRequest.timeout).to(beNil());
- expect(testRequest.vrHelp).to(beNil());
- expect(testRequest.interactionLayout).to(beNil());
- expect(testRequest.cancelID).to(beNil());
- });
-
- it(@"Should initialize correctly with initWithInitialPrompt:initialText:interactionChoiceSetID:", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testRequest = [[SDLPerformInteraction alloc] initWithInitialPrompt:testInitialPromptString initialText:testInitialText interactionChoiceSetID:testInteractionChoiceSetID];
- #pragma clang diagnostic pop
-
- expect(testRequest.initialText).to(equal(testInitialText));
- expect(testRequest.initialPrompt).to(equal([SDLTTSChunk textChunksFromString:testInitialPromptString]));
- expect(testRequest.interactionMode).to(beNil());
- expect(testRequest.interactionChoiceSetIDList).to(equal(@[@(testInteractionChoiceSetID)]));
- expect(testRequest.helpPrompt).to(beNil());
- expect(testRequest.timeoutPrompt).to(beNil());
- expect(testRequest.timeout).to(beNil());
- expect(testRequest.vrHelp).to(beNil());
- expect(testRequest.interactionLayout).to(beNil());
- expect(testRequest.cancelID).to(beNil());
- });
-
- it(@"Should initialize correctly with initWithInitialPrompt:initialText:interactionChoiceSetID:vrHelp:", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testRequest = [[SDLPerformInteraction alloc] initWithInitialPrompt:testInitialPromptString initialText:testInitialText interactionChoiceSetID:testInteractionChoiceSetID vrHelp:testVRHelp];
- #pragma clang diagnostic pop
-
- expect(testRequest.initialText).to(equal(testInitialText));
- expect(testRequest.initialPrompt).to(equal([SDLTTSChunk textChunksFromString:testInitialPromptString]));
- expect(testRequest.interactionMode).to(beNil());
- expect(testRequest.interactionChoiceSetIDList).to(equal(@[@(testInteractionChoiceSetID)]));
- expect(testRequest.helpPrompt).to(beNil());
- expect(testRequest.timeoutPrompt).to(beNil());
- expect(testRequest.timeout).to(beNil());
- expect(testRequest.vrHelp).to(equal(testVRHelp));
- expect(testRequest.interactionLayout).to(beNil());
- expect(testRequest.cancelID).to(beNil());
- });
-
- it(@"Should initialize correctly with initWithInitialPrompt:initialText:interactionChoiceSetIDList:helpPrompt:timeoutPrompt:interactionMode:timeout:", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testRequest = [[SDLPerformInteraction alloc] initWithInitialPrompt:testInitialPromptString initialText:testInitialText interactionChoiceSetIDList:testInteractionChoiceSetIDList helpPrompt:testHelpPromptString timeoutPrompt:testTimeoutPromptString interactionMode:testInteractionMode timeout:testTimeout];
- #pragma clang diagnostic pop
-
- expect(testRequest.initialText).to(equal(testInitialText));
- expect(testRequest.initialPrompt).to(equal([SDLTTSChunk textChunksFromString:testInitialPromptString]));
- expect(testRequest.interactionMode).to(equal(testInteractionMode));
- expect(testRequest.interactionChoiceSetIDList).to(equal(testInteractionChoiceSetIDList));
- expect(testRequest.helpPrompt).to(equal([SDLTTSChunk textChunksFromString:testHelpPromptString]));
- expect(testRequest.timeoutPrompt).to(equal([SDLTTSChunk textChunksFromString:testTimeoutPromptString]));
- expect(testRequest.timeout).to(equal(testTimeout));
- expect(testRequest.vrHelp).to(beNil());
- expect(testRequest.interactionLayout).to(beNil());
- expect(testRequest.cancelID).to(beNil());
- });
-
- it(@"Should initialize correctly with initWithInitialPrompt:initialText:interactionChoiceSetIDList:helpPrompt:timeoutPrompt:interactionMode:timeout:vrHelp:", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testRequest = [[SDLPerformInteraction alloc] initWithInitialPrompt:testInitialPromptString initialText:testInitialText interactionChoiceSetIDList:testInteractionChoiceSetIDList helpPrompt:testHelpPromptString timeoutPrompt:testTimeoutPromptString interactionMode:testInteractionMode timeout:testTimeout vrHelp:testVRHelp];
- #pragma clang diagnostic pop
-
- expect(testRequest.initialText).to(equal(testInitialText));
- expect(testRequest.initialPrompt).to(equal([SDLTTSChunk textChunksFromString:testInitialPromptString]));
- expect(testRequest.interactionMode).to(equal(testInteractionMode));
- expect(testRequest.interactionChoiceSetIDList).to(equal(testInteractionChoiceSetIDList));
- expect(testRequest.helpPrompt).to(equal([SDLTTSChunk textChunksFromString:testHelpPromptString]));
- expect(testRequest.timeoutPrompt).to(equal([SDLTTSChunk textChunksFromString:testTimeoutPromptString]));
- expect(testRequest.timeout).to(equal(testTimeout));
- expect(testRequest.vrHelp).to(equal(testVRHelp));
- expect(testRequest.interactionLayout).to(beNil());
- expect(testRequest.cancelID).to(beNil());
- });
-
- it(@"Should initialize correctly with initWithInitialChunks:initialText:interactionChoiceSetIDList:helpChunks:timeoutChunks:interactionMode:timeout:vrHelp:", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testRequest = [[SDLPerformInteraction alloc] initWithInitialChunks:testInitialPrompt initialText:testInitialText interactionChoiceSetIDList:testInteractionChoiceSetIDList helpChunks:testHelpPrompt timeoutChunks:testTimeoutPrompt interactionMode:testInteractionMode timeout:testTimeout vrHelp:testVRHelp];
- #pragma clang diagnostic pop
-
- expect(testRequest.initialText).to(equal(testInitialText));
- expect(testRequest.initialPrompt).to(equal(testInitialPrompt));
- expect(testRequest.interactionMode).to(equal(testInteractionMode));
- expect(testRequest.interactionChoiceSetIDList).to(equal(testInteractionChoiceSetIDList));
- expect(testRequest.helpPrompt).to(equal(testHelpPrompt));
- expect(testRequest.timeoutPrompt).to(equal(testTimeoutPrompt));
- expect(testRequest.timeout).to(equal(testTimeout));
- expect(testRequest.vrHelp).to(equal(testVRHelp));
- expect(testRequest.interactionLayout).to(beNil());
- expect(testRequest.cancelID).to(beNil());
- });
-
- it(@"Should initialize correctly with initWithInitialChunks:initialText:interactionChoiceSetIDList:helpChunks:timeoutChunks:interactionMode:timeout:vrHelp:interactionLayout:", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testRequest = [[SDLPerformInteraction alloc] initWithInitialChunks:testInitialPrompt initialText:testInitialText interactionChoiceSetIDList:testInteractionChoiceSetIDList helpChunks:testHelpPrompt timeoutChunks:testTimeoutPrompt interactionMode:testInteractionMode timeout:testTimeout vrHelp:testVRHelp interactionLayout:testinteractionLayout];
- #pragma clang diagnostic pop
-
- expect(testRequest.initialText).to(equal(testInitialText));
- expect(testRequest.initialPrompt).to(equal(testInitialPrompt));
- expect(testRequest.interactionMode).to(equal(testInteractionMode));
- expect(testRequest.interactionChoiceSetIDList).to(equal(testInteractionChoiceSetIDList));
- expect(testRequest.helpPrompt).to(equal(testHelpPrompt));
- expect(testRequest.timeoutPrompt).to(equal(testTimeoutPrompt));
- expect(testRequest.timeout).to(equal(testTimeout));
- expect(testRequest.vrHelp).to(equal(testVRHelp));
- expect(testRequest.interactionLayout).to(equal(testinteractionLayout));
- expect(testRequest.cancelID).to(beNil());
- });
});
afterEach(^{
diff --git a/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLPutFileSpec.m b/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLPutFileSpec.m
index 890cb9ff0..8fbea1f66 100644
--- a/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLPutFileSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLPutFileSpec.m
@@ -41,29 +41,21 @@ describe(@"Getter/Setter Tests", ^ {
expect(testRequest.offset).to(equal(@987654321));
expect(testRequest.length).to(equal(@123456789));
expect(testRequest.crc).to(equal(0xffffffff));
-
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testRequest.syncFileName).to(equal(@"fileName"));
-#pragma clang diagnostic pop
});
it(@"Should get and set correctly when initialized", ^ {
- NSMutableDictionary* dict = [@{SDLRPCParameterNameRequest:
- @{SDLRPCParameterNameParameters:
+ NSDictionary *dict = @{SDLRPCParameterNameRequest:
+ @{SDLRPCParameterNameParameters:
@{ SDLRPCParameterNameSyncFileName:@"fileName",
- SDLRPCParameterNameFileType:SDLFileTypeJPEG,
- SDLRPCParameterNamePersistentFile:@YES,
- SDLRPCParameterNameSystemFile:@NO,
- SDLRPCParameterNameOffset:@987654321,
- SDLRPCParameterNameLength:@123456789,
+ SDLRPCParameterNameFileType:SDLFileTypeJPEG,
+ SDLRPCParameterNamePersistentFile:@YES,
+ SDLRPCParameterNameSystemFile:@NO,
+ SDLRPCParameterNameOffset:@987654321,
+ SDLRPCParameterNameLength:@123456789,
SDLRPCParameterNameCRC:@0xffffffff},
- SDLRPCParameterNameOperationName:SDLRPCFunctionNamePutFile}} mutableCopy];
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLPutFile* testRequest = [[SDLPutFile alloc] initWithDictionary:dict];
-#pragma clang diagnostic pop
-
+ SDLRPCParameterNameOperationName:SDLRPCFunctionNamePutFile}};
+ SDLPutFile *testRequest = [[SDLPutFile alloc] initWithDictionary:dict];
+
expect(testRequest.sdlFileName).to(equal(@"fileName"));
expect(testRequest.fileType).to(equal(SDLFileTypeJPEG));
expect(testRequest.persistentFile).to(equal(@YES));
@@ -71,11 +63,6 @@ describe(@"Getter/Setter Tests", ^ {
expect(testRequest.offset).to(equal(@987654321));
expect(testRequest.length).to(equal(@123456789));
expect(testRequest.crc).to(equal(@0xffffffff));
-
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testRequest.syncFileName).to(equal(@"fileName"));
-#pragma clang diagnostic pop
});
});
@@ -114,11 +101,6 @@ describe(@"initializers", ^{
expect(testRequest.length).to(beNil());
expect(testRequest.crc).to(beNil());
expect(testRequest.bulkData).to(beNil());
-
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testRequest.syncFileName).to(beNil());
-#pragma clang diagnostic pop
});
context(@"initWithFileName:fileType:", ^{
@@ -132,11 +114,6 @@ describe(@"initializers", ^{
expect(testRequest.length).to(beNil());
expect(testRequest.crc).to(beNil());
expect(testRequest.bulkData).to(beNil());
-
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testRequest.syncFileName).to(equal(@"fileName"));
-#pragma clang diagnostic pop
});
context(@"initWithFileName:fileType:persistentFile:", ^{
@@ -150,32 +127,6 @@ describe(@"initializers", ^{
expect(testRequest.length).to(beNil());
expect(testRequest.crc).to(beNil());
expect(testRequest.bulkData).to(beNil());
-
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testRequest.syncFileName).to(equal(@"fileName"));
-#pragma clang diagnostic pop
- });
-
- context(@"initWithFileName:fileType:persistentFile:systemFile:offset:length:", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLPutFile *testRequest = [[SDLPutFile alloc] initWithFileName:@"fileName" fileType:SDLFileTypeMP3 persistentFile:true systemFile:true offset:45 length:34];
-#pragma clang diagnostic pop
-
- expect(testRequest.sdlFileName).to(equal(@"fileName"));
- expect(testRequest.fileType).to(equal(SDLFileTypeMP3));
- expect(testRequest.persistentFile).to(beTrue());
- expect(testRequest.systemFile).to(beTrue());
- expect(testRequest.offset).to(equal(@45));
- expect(testRequest.length).to(equal(34));
- expect(testRequest.crc).to(beNil());
- expect(testRequest.bulkData).to(beNil());
-
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testRequest.syncFileName).to(equal(@"fileName"));
-#pragma clang diagnostic pop
});
context(@"initWithFileName:fileType:persistentFile:systemFile:offset:length:crc:", ^{
@@ -189,11 +140,6 @@ describe(@"initializers", ^{
expect(testRequest.length).to(equal(@34));
expect(testRequest.crc).to(equal(0xffffffff));
expect(testRequest.bulkData).to(beNil());
-
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testRequest.syncFileName).to(equal(@"fileName"));
-#pragma clang diagnostic pop
});
context(@"initWithFileName:fileType:persistentFile:systemFile:offset:length:bulkData:", ^{
@@ -210,11 +156,6 @@ describe(@"initializers", ^{
expect(testRequest.length).to(equal(@4));
expect(testRequest.bulkData).to(equal(testFileData));
expect(testRequest.crc).to(equal(testFileCRC32Checksum));
-
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testRequest.syncFileName).to(equal(@"fileName"));
-#pragma clang diagnostic pop
});
});
diff --git a/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLRegisterAppInterfaceSpec.m b/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLRegisterAppInterfaceSpec.m
index 9905b9ebf..ae5adf8ad 100644
--- a/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLRegisterAppInterfaceSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLRegisterAppInterfaceSpec.m
@@ -17,7 +17,6 @@
#import "SDLRPCParameterNames.h"
#import "SDLRPCFunctionNames.h"
#import "SDLRegisterAppInterface.h"
-#import "SDLSyncMsgVersion.h"
#import "SDLMsgVersion.h"
#import "SDLTemplateColorScheme.h"
#import "SDLTTSChunk.h"
@@ -29,8 +28,8 @@ describe(@"RegisterAppInterface Tests", ^{
__block SDLRegisterAppInterface *testRegisterAppInterface = nil;
__block NSString *appName = @"app56";
__block NSString *appId = @"123456789";
- __block NSString *fullAppId = @"123-e4567-e89b-12d3-a456-426655440000";
- __block NSString *expectedAppId = @"123e4567e8";
+ __block NSString *fullAppId = @"e5bafdfa-f921-11ea-adc1-0242ac120002";
+ __block NSString *expectedAppId = @"e5bafdfaf9";
__block NSString *shortAppName = @"whatisanngn";
__block NSString *resumeHash = @"gercd35grw2";
__block NSString *vrSynonyms = @"app56";
@@ -38,27 +37,15 @@ describe(@"RegisterAppInterface Tests", ^{
__block NSArray<SDLAppHMIType> *appTypes = @[SDLAppHMITypeMedia, SDLAppHMITypeNavigation, SDLAppHMITypeInformation];
__block SDLLanguage language = SDLLanguageElGr;
__block SDLLanguage hmiDisplayLanguage = SDLLanguageArSa;
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- __block SDLSyncMsgVersion *version = nil;
-#pragma clang diagnostic pop
__block SDLMsgVersion *msgVersion = nil;
__block SDLTTSChunk *chunk = nil;
__block SDLDeviceInfo *info = nil;
__block SDLAppInfo *appInfo = nil;
__block SDLTemplateColorScheme *colorScheme = nil;
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- __block SDLSyncMsgVersion *currentSyncMsgVersion = [[SDLSyncMsgVersion alloc] initWithMajorVersion:7 minorVersion:0 patchVersion:0];
-#pragma clang diagnostic pop
__block SDLMsgVersion * currentSDLMsgVersion = [[SDLMsgVersion alloc] initWithMajorVersion:7 minorVersion:0 patchVersion:0];
beforeEach(^{
testRegisterAppInterface = nil;
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- version = [[SDLSyncMsgVersion alloc] initWithMajorVersion:0 minorVersion:0 patchVersion:0];
-#pragma clang diagnostic pop
msgVersion = [[SDLMsgVersion alloc] initWithMajorVersion:0 minorVersion:0 patchVersion:0];
chunk = [[SDLTTSChunk alloc] init];
info = [[SDLDeviceInfo alloc] init];
@@ -68,10 +55,6 @@ describe(@"RegisterAppInterface Tests", ^{
it(@"Should set and get correctly", ^ {
testRegisterAppInterface = [[SDLRegisterAppInterface alloc] init];
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testRegisterAppInterface.syncMsgVersion = version;
-#pragma clang diagnostic pop
testRegisterAppInterface.appName = appName;
testRegisterAppInterface.ttsName = @[chunk];
testRegisterAppInterface.ngnMediaScreenAppName = shortAppName;
@@ -87,12 +70,8 @@ describe(@"RegisterAppInterface Tests", ^{
testRegisterAppInterface.appInfo = appInfo;
testRegisterAppInterface.dayColorScheme = colorScheme;
testRegisterAppInterface.nightColorScheme = colorScheme;
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testRegisterAppInterface.syncMsgVersion).to(equal(version));
-#pragma clang diagnostic pop
testRegisterAppInterface.sdlMsgVersion = msgVersion;
- expect(testRegisterAppInterface.sdlMsgVersion).to(equal(msgVersion));
+
expect(testRegisterAppInterface.appName).to(equal(appName));
expect(testRegisterAppInterface.ttsName).to(contain(chunk));
expect(testRegisterAppInterface.ngnMediaScreenAppName).to(equal(shortAppName));
@@ -108,12 +87,12 @@ describe(@"RegisterAppInterface Tests", ^{
expect(testRegisterAppInterface.appInfo).to(equal(appInfo));
expect(testRegisterAppInterface.dayColorScheme).to(equal(colorScheme));
expect(testRegisterAppInterface.nightColorScheme).to(equal(colorScheme));
+ expect(testRegisterAppInterface.sdlMsgVersion).to(equal(msgVersion));
});
describe(@"Setting With Dictionary", ^{
- __block NSDictionary *dict = nil;
beforeEach( ^{
- dict = @{SDLRPCParameterNameRequest:
+ NSDictionary *dict = @{SDLRPCParameterNameRequest:
@{SDLRPCParameterNameParameters:
@{SDLRPCParameterNameSyncMessageVersion:@{
SDLRPCParameterNameMajorVersion: @7,
@@ -137,46 +116,9 @@ describe(@"RegisterAppInterface Tests", ^{
SDLRPCParameterNameNightColorScheme: colorScheme,
},
SDLRPCParameterNameOperationName:SDLRPCFunctionNameRegisterAppInterface}};
- });
-
- it(@"Should get correctly when initialized with a dictionary and get syncMsgVersion first", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLRegisterAppInterface* testRegisterAppInterface = [[SDLRegisterAppInterface alloc] initWithDictionary:dict];
-#pragma clang diagnostic pop
-
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testRegisterAppInterface.syncMsgVersion).to(equal(currentSyncMsgVersion));
-#pragma clang diagnostic pop
- expect(testRegisterAppInterface.sdlMsgVersion).to(equal(currentSDLMsgVersion));
- expect(testRegisterAppInterface.appName).to(match(appName));
- expect(testRegisterAppInterface.ttsName).to(equal([@[chunk] mutableCopy]));
- expect(testRegisterAppInterface.ngnMediaScreenAppName).to(match(shortAppName));
- expect(testRegisterAppInterface.vrSynonyms).to(equal(@[vrSynonyms]));
- expect(testRegisterAppInterface.isMediaApplication).to(equal(isMediaApp));
- expect(testRegisterAppInterface.languageDesired).to(equal(SDLLanguageNoNo));
- expect(testRegisterAppInterface.hmiDisplayLanguageDesired).to(equal(SDLLanguagePtPt));
- expect(testRegisterAppInterface.appHMIType).to(equal(appTypes));
- expect(testRegisterAppInterface.hashID).to(match(resumeHash));
- expect(testRegisterAppInterface.deviceInfo).to(equal(info));
- expect(testRegisterAppInterface.fullAppID).to(match(fullAppId));
- expect(testRegisterAppInterface.appID).to(match(appId));
- expect(testRegisterAppInterface.appInfo).to(equal(appInfo));
- expect(testRegisterAppInterface.dayColorScheme).to(equal(colorScheme));
- expect(testRegisterAppInterface.nightColorScheme).to(equal(colorScheme));
- });
+ SDLRegisterAppInterface *testRegisterAppInterface = [[SDLRegisterAppInterface alloc] initWithDictionary:dict];
- it(@"Should get correctly when initialized with a dictionary and sdlMsgVersion first", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLRegisterAppInterface* testRegisterAppInterface = [[SDLRegisterAppInterface alloc] initWithDictionary:dict];
-#pragma clang diagnostic pop
expect(testRegisterAppInterface.sdlMsgVersion).to(equal(currentSDLMsgVersion));
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testRegisterAppInterface.syncMsgVersion).to(equal(currentSyncMsgVersion));
-#pragma clang diagnostic pop
expect(testRegisterAppInterface.appName).to(match(appName));
expect(testRegisterAppInterface.ttsName).to(equal([@[chunk] mutableCopy]));
expect(testRegisterAppInterface.ngnMediaScreenAppName).to(match(shortAppName));
@@ -198,10 +140,7 @@ describe(@"RegisterAppInterface Tests", ^{
describe(@"initializers", ^{
it(@"init", ^{
testRegisterAppInterface = [[SDLRegisterAppInterface alloc] init];
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testRegisterAppInterface.syncMsgVersion).to(equal(version));
-#pragma clang diagnostic pop
+
expect(testRegisterAppInterface.sdlMsgVersion).to(beNil());
expect(testRegisterAppInterface.appName).to(beNil());
expect(testRegisterAppInterface.ttsName).to(beNil());
@@ -231,14 +170,10 @@ describe(@"RegisterAppInterface Tests", ^{
testLifecyleConfiguration.voiceRecognitionCommandNames = @[vrSynonyms];
testLifecyleConfiguration.dayColorScheme = colorScheme;
testLifecyleConfiguration.nightColorScheme = colorScheme;
-
SDLRegisterAppInterface *testRegisterAppInterface = [[SDLRegisterAppInterface alloc] initWithLifecycleConfiguration:testLifecyleConfiguration];
+
expect(testRegisterAppInterface.fullAppID).to(match(fullAppId));
expect(testRegisterAppInterface.appID).to(match(expectedAppId));
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testRegisterAppInterface.syncMsgVersion).to(equal(currentSyncMsgVersion));
-#pragma clang diagnostic pop
expect(testRegisterAppInterface.sdlMsgVersion).to(equal(currentSDLMsgVersion));
expect(testRegisterAppInterface.appName).to(equal(appName));
expect(testRegisterAppInterface.ttsName).to(contain(chunk));
@@ -263,10 +198,6 @@ describe(@"RegisterAppInterface Tests", ^{
expect(testRegisterAppInterface.fullAppID).to(beNil());
expect(testRegisterAppInterface.appID).to(match(appId));
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testRegisterAppInterface.syncMsgVersion).to(equal(currentSyncMsgVersion));
-#pragma clang diagnostic pop
expect(testRegisterAppInterface.sdlMsgVersion).to(equal(currentSDLMsgVersion));
expect(testRegisterAppInterface.appName).to(equal(appName));
expect(testRegisterAppInterface.ttsName).to(beNil());
@@ -283,71 +214,11 @@ describe(@"RegisterAppInterface Tests", ^{
expect(testRegisterAppInterface.nightColorScheme).to(beNil());
});
- it(@"initWithAppName:appId:languageDesired:isMediaApp:appTypes:shortAppName:", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLRegisterAppInterface *testRegisterAppInterface = [[SDLRegisterAppInterface alloc] initWithAppName:appName appId:appId languageDesired:language isMediaApp:isMediaApp appTypes:appTypes shortAppName:shortAppName];
-#pragma clang diagnostic pop
- expect(testRegisterAppInterface.fullAppID).to(beNil());
- expect(testRegisterAppInterface.appID).to(match(appId));
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testRegisterAppInterface.syncMsgVersion).to(equal(currentSyncMsgVersion));
-#pragma clang diagnostic pop
- expect(testRegisterAppInterface.sdlMsgVersion).to(equal(currentSDLMsgVersion));
- expect(testRegisterAppInterface.appName).to(equal(appName));
- expect(testRegisterAppInterface.ttsName).to(beNil());
- expect(testRegisterAppInterface.ngnMediaScreenAppName).to(equal(shortAppName));
- expect(testRegisterAppInterface.appHMIType).to(contain(SDLAppHMITypeMedia));
- expect(testRegisterAppInterface.appHMIType).to(contain(SDLAppHMITypeNavigation));
- expect(testRegisterAppInterface.appHMIType).to(contain(SDLAppHMITypeInformation));
- expect(testRegisterAppInterface.isMediaApplication).to(equal(isMediaApp));
- expect(testRegisterAppInterface.hashID).to(beNil());
- expect(testRegisterAppInterface.languageDesired).to(equal(language));
- expect(testRegisterAppInterface.hmiDisplayLanguageDesired).to(equal(language));
- expect(testRegisterAppInterface.vrSynonyms).to(beNil());
- expect(testRegisterAppInterface.deviceInfo).toNot(beNil());
- expect(testRegisterAppInterface.appInfo).toNot(beNil());
- expect(testRegisterAppInterface.dayColorScheme).to(beNil());
- expect(testRegisterAppInterface.nightColorScheme).to(beNil());
- });
- it(@"initWithAppName:appId:languageDesired:isMediaApp:appTypes:shortAppName:ttsName:vrSynonyms:hmiDisplayLanguageDesired:resumeHash:", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLRegisterAppInterface *testRegisterAppInterface = [[SDLRegisterAppInterface alloc] initWithAppName:appName appId:appId languageDesired:language isMediaApp:isMediaApp appTypes:appTypes shortAppName:shortAppName ttsName:@[chunk] vrSynonyms:@[vrSynonyms] hmiDisplayLanguageDesired:hmiDisplayLanguage resumeHash:resumeHash];
-#pragma clang diagnostic pop
- expect(testRegisterAppInterface.fullAppID).to(beNil());
- expect(testRegisterAppInterface.appID).to(match(appId));
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testRegisterAppInterface.syncMsgVersion).to(equal(currentSyncMsgVersion));
-#pragma clang diagnostic pop
- expect(testRegisterAppInterface.sdlMsgVersion).to(equal(currentSDLMsgVersion));
- expect(testRegisterAppInterface.appName).to(equal(appName));
- expect(testRegisterAppInterface.ttsName).to(contain(chunk));
- expect(testRegisterAppInterface.ngnMediaScreenAppName).to(equal(shortAppName));
- expect(testRegisterAppInterface.appHMIType).to(contain(SDLAppHMITypeMedia));
- expect(testRegisterAppInterface.appHMIType).to(contain(SDLAppHMITypeNavigation));
- expect(testRegisterAppInterface.appHMIType).to(contain(SDLAppHMITypeInformation));
- expect(testRegisterAppInterface.isMediaApplication).to(equal(isMediaApp));
- expect(testRegisterAppInterface.hashID).to(match(resumeHash));
- expect(testRegisterAppInterface.languageDesired).to(equal(language));
- expect(testRegisterAppInterface.hmiDisplayLanguageDesired).to(equal(hmiDisplayLanguage));
- expect(testRegisterAppInterface.vrSynonyms).to(contain(vrSynonyms));
- expect(testRegisterAppInterface.deviceInfo).toNot(beNil());
- expect(testRegisterAppInterface.appInfo).toNot(beNil());
- expect(testRegisterAppInterface.dayColorScheme).to(beNil());
- expect(testRegisterAppInterface.nightColorScheme).to(beNil());
- });
it(@"initWithAppName:appId:fullAppId:languageDesired:isMediaApp:appTypes:shortAppName:ttsName:vrSynonyms:hmiDisplayLanguageDesired:resumeHash:dayColorScheme:nightColorScheme:", ^{
SDLRegisterAppInterface *testRegisterAppInterface = [[SDLRegisterAppInterface alloc] initWithAppName:appName appId:appId fullAppId:fullAppId languageDesired:language isMediaApp:isMediaApp appTypes:appTypes shortAppName:shortAppName ttsName:@[chunk] vrSynonyms:@[vrSynonyms] hmiDisplayLanguageDesired:hmiDisplayLanguage resumeHash:resumeHash dayColorScheme:colorScheme nightColorScheme:colorScheme];
expect(testRegisterAppInterface.fullAppID).to(match(fullAppId));
expect(testRegisterAppInterface.appID).to(match(appId));
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testRegisterAppInterface.syncMsgVersion).to(equal(currentSyncMsgVersion));
-#pragma clang diagnostic pop
expect(testRegisterAppInterface.sdlMsgVersion).to(equal(currentSDLMsgVersion));
expect(testRegisterAppInterface.appName).to(equal(appName));
expect(testRegisterAppInterface.ttsName).to(contain(chunk));
diff --git a/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLScrollableMessageSpec.m b/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLScrollableMessageSpec.m
index 58a86d751..adfc1a4bb 100644
--- a/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLScrollableMessageSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLScrollableMessageSpec.m
@@ -55,17 +55,14 @@ describe(@"Getter/Setter Tests", ^ {
describe(@"Initializing", ^{
it(@"Should initialize correctly with a dictionary", ^ {
- NSDictionary<NSString *, id> *dict = @{SDLRPCParameterNameRequest:
- @{SDLRPCParameterNameParameters:
- @{SDLRPCParameterNameScrollableMessageBody:testScrollableMessageBody,
- SDLRPCParameterNameTimeout:@(testTimeout),
- SDLRPCParameterNameSoftButtons:testSoftButtons,
- SDLRPCParameterNameCancelID:@(testCancelID)},
- SDLRPCParameterNameOperationName:SDLRPCFunctionNameScrollableMessage}};
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
+ NSDictionary *dict = @{SDLRPCParameterNameRequest:
+ @{SDLRPCParameterNameParameters:
+ @{SDLRPCParameterNameScrollableMessageBody:testScrollableMessageBody,
+ SDLRPCParameterNameTimeout:@(testTimeout),
+ SDLRPCParameterNameSoftButtons:testSoftButtons,
+ SDLRPCParameterNameCancelID:@(testCancelID)},
+ SDLRPCParameterNameOperationName:SDLRPCFunctionNameScrollableMessage}};
testRequest = [[SDLScrollableMessage alloc] initWithDictionary:dict];
- #pragma clang diagnostic pop
expect(testRequest.scrollableMessageBody).to(equal(testScrollableMessageBody));
expect(testRequest.timeout).to(equal(testTimeout));
@@ -91,18 +88,6 @@ describe(@"Getter/Setter Tests", ^ {
expect(testRequest.softButtons).to(equal(testSoftButtons));
expect(testRequest.cancelID).to(equal(testCancelID));
});
-
- it(@"Should initialize correctly with initWithMessage:timeout:softButtons:", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testRequest = [[SDLScrollableMessage alloc] initWithMessage:testScrollableMessageBody timeout:testTimeout softButtons:testSoftButtons];
- #pragma clang diagnostic pop
-
- expect(testRequest.scrollableMessageBody).to(equal(testScrollableMessageBody));
- expect(testRequest.timeout).to(equal(testTimeout));
- expect(testRequest.softButtons).to(equal(testSoftButtons));
- expect(testRequest.cancelID).to(beNil());
- });
});
afterEach(^{
diff --git a/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLSetGlobalPropertiesSpec.m b/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLSetGlobalPropertiesSpec.m
index e875e411c..f8ab52596 100644
--- a/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLSetGlobalPropertiesSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLSetGlobalPropertiesSpec.m
@@ -10,75 +10,114 @@
#import "SDLImage.h"
#import "SDLKeyboardProperties.h"
+#import "SDLMenuLayout.h"
#import "SDLRPCParameterNames.h"
#import "SDLRPCFunctionNames.h"
+#import "SDLSeatLocation.h"
#import "SDLSetGlobalProperties.h"
#import "SDLTTSChunk.h"
#import "SDLVrHelpItem.h"
-#import "SDLSeatLocation.h"
QuickSpecBegin(SDLSetGlobalPropertiesSpec)
-SDLTTSChunk* chunk1 = [[SDLTTSChunk alloc] init];
-SDLTTSChunk* chunk2 = [[SDLTTSChunk alloc] init];
-SDLVRHelpItem* help = [[SDLVRHelpItem alloc] init];
-SDLImage* image = [[SDLImage alloc] init];
-SDLKeyboardProperties* keyboard = [[SDLKeyboardProperties alloc] init];
+NSString *menuTitle = @"TheNewMenu";
+NSString *vrHelpTitle = @"vr";
+NSString *helpTest = @"TheHelpText";
+NSString *timeoutTest = @"timeout Test";
+SDLTTSChunk *chunk1 = [[SDLTTSChunk alloc] initWithText:@"chunk 1" type:SDLSpeechCapabilitiesText];
+SDLTTSChunk *chunk2 = [[SDLTTSChunk alloc] initWithText:@"chunk 2" type:SDLSpeechCapabilitiesText];
+SDLVRHelpItem *help = [[SDLVRHelpItem alloc] init];
+SDLImage *image = [[SDLImage alloc] init];
+SDLKeyboardProperties *keyboard = [[SDLKeyboardProperties alloc] init];
SDLSeatLocation *seatLocation = [[SDLSeatLocation alloc] init];
+SDLMenuLayout menuLayout = SDLMenuLayoutList;
describe(@"Getter/Setter Tests", ^ {
it(@"Should set and get correctly", ^ {
- SDLSetGlobalProperties* testRequest = [[SDLSetGlobalProperties alloc] init];
+ SDLSetGlobalProperties *testRequest = [[SDLSetGlobalProperties alloc] init];
- testRequest.helpPrompt = [@[chunk1] mutableCopy];
- testRequest.timeoutPrompt = [@[chunk2] mutableCopy];
- testRequest.vrHelpTitle = @"vr";
- testRequest.vrHelp = [@[help] mutableCopy];
- testRequest.menuTitle = @"TheNewMenu";
+ testRequest.helpPrompt = @[chunk1];
+ testRequest.timeoutPrompt = @[chunk2];
+ testRequest.vrHelpTitle = vrHelpTitle;
+ testRequest.vrHelp = @[help];
+ testRequest.menuTitle = menuTitle;
testRequest.menuIcon = image;
testRequest.keyboardProperties = keyboard;
testRequest.userLocation = seatLocation;
+ testRequest.menuLayout = menuLayout;
- expect(testRequest.helpPrompt).to(equal([@[chunk1] mutableCopy]));
- expect(testRequest.timeoutPrompt).to(equal([@[chunk2] mutableCopy]));
+ expect(testRequest.helpPrompt).to(equal(@[chunk1]));
+ expect(testRequest.timeoutPrompt).to(equal(@[chunk2]));
expect(testRequest.vrHelpTitle).to(equal(@"vr"));
- expect(testRequest.vrHelp).to(equal([@[help] mutableCopy]));
+ expect(testRequest.vrHelp).to(equal(@[help]));
expect(testRequest.menuTitle).to(equal(@"TheNewMenu"));
expect(testRequest.menuIcon).to(equal(image));
expect(testRequest.keyboardProperties).to(equal(keyboard));
expect(testRequest.userLocation).to(equal(seatLocation));
+ expect(testRequest.menuLayout).to(equal(menuLayout));
});
- it(@"Should get correctly when initialized", ^ {
- NSMutableDictionary<NSString *, id> *dict = [@{SDLRPCParameterNameRequest:
- @{SDLRPCParameterNameParameters:
- @{SDLRPCParameterNameHelpPrompt:[@[chunk1] mutableCopy],
- SDLRPCParameterNameTimeoutPrompt:[@[chunk2] mutableCopy],
- SDLRPCParameterNameVRHelpTitle:@"vr",
- SDLRPCParameterNameVRHelp:[@[help] mutableCopy],
- SDLRPCParameterNameMenuTitle:@"TheNewMenu",
- SDLRPCParameterNameUserLocation: seatLocation,
- SDLRPCParameterNameMenuIcon:image,
- SDLRPCParameterNameKeyboardProperties:keyboard},
- SDLRPCParameterNameOperationName:SDLRPCFunctionNameSetGlobalProperties}} mutableCopy];
+ it(@"Should initialize correctly with a dictionary", ^ {
+ NSDictionary *dict = @{SDLRPCParameterNameRequest:
+ @{SDLRPCParameterNameParameters:
+ @{SDLRPCParameterNameHelpPrompt:@[chunk1],
+ SDLRPCParameterNameTimeoutPrompt:@[chunk2],
+ SDLRPCParameterNameVRHelpTitle:@"vr",
+ SDLRPCParameterNameVRHelp:@[help],
+ SDLRPCParameterNameMenuTitle:@"TheNewMenu",
+ SDLRPCParameterNameUserLocation: seatLocation,
+ SDLRPCParameterNameMenuIcon:image,
+ SDLRPCParameterNameKeyboardProperties:keyboard,
+ SDLRPCParameterNameMenuLayout:menuLayout
+ },
+ SDLRPCParameterNameOperationName:SDLRPCFunctionNameSetGlobalProperties}};
+ SDLSetGlobalProperties *testRequest = [[SDLSetGlobalProperties alloc] initWithDictionary:dict];
+
+ expect(testRequest.helpPrompt).to(equal(@[chunk1]));
+ expect(testRequest.timeoutPrompt).to(equal(@[chunk2]));
+ expect(testRequest.vrHelpTitle).to(equal(vrHelpTitle));
+ expect(testRequest.vrHelp).to(equal(@[help]));
+ expect(testRequest.menuTitle).to(equal(menuTitle));
+ expect(testRequest.menuIcon).to(equal(image));
+ expect(testRequest.keyboardProperties).to(equal(keyboard));
+ expect(testRequest.userLocation).to(equal(seatLocation));
+ expect(testRequest.menuLayout).to(equal(menuLayout));
+ });
+
+ it(@"Should init correctly with initWithUserLocation:helpPrompt:timeoutPrompt:vrHelpTitle:vrHelp:menuTitle:menuIcon:keyboardProperties:menuLayout:", ^ {
+ SDLSetGlobalProperties *testRequest = [[SDLSetGlobalProperties alloc] initWithUserLocation:seatLocation helpPrompt:[SDLTTSChunk textChunksFromString:helpTest] timeoutPrompt:[SDLTTSChunk textChunksFromString:timeoutTest] vrHelpTitle:vrHelpTitle vrHelp:@[help] menuTitle:menuTitle menuIcon:image keyboardProperties:keyboard menuLayout:menuLayout];
+
+ expect(testRequest.helpPrompt).to(equal([SDLTTSChunk textChunksFromString:helpTest]));
+ expect(testRequest.timeoutPrompt).to(equal([SDLTTSChunk textChunksFromString:timeoutTest]));
+ expect(testRequest.vrHelpTitle).to(equal(vrHelpTitle));
+ expect(testRequest.vrHelp).to(equal(@[help]));
+ expect(testRequest.menuTitle).to(equal(menuTitle));
+ expect(testRequest.menuIcon).to(equal(image));
+ expect(testRequest.keyboardProperties).to(equal(keyboard));
+ expect(testRequest.userLocation).to(equal(seatLocation));
+ expect(testRequest.menuLayout).to(equal(menuLayout));
+ });
+
+ it(@"Should init correctly with initWithHelpText:timeoutText:vrHelpTitle:vrHelp:menuTitle:menuIcon:keyboardProperties:menuLayout:", ^ {
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLSetGlobalProperties* testRequest = [[SDLSetGlobalProperties alloc] initWithDictionary:dict];
+ SDLSetGlobalProperties *testRequest = [[SDLSetGlobalProperties alloc] initWithHelpText:helpTest timeoutText:timeoutTest vrHelpTitle:vrHelpTitle vrHelp:@[help] menuTitle:menuTitle menuIcon:image keyboardProperties:keyboard menuLayout:menuLayout];
#pragma clang diagnostic pop
-
- expect(testRequest.helpPrompt).to(equal([@[chunk1] mutableCopy]));
- expect(testRequest.timeoutPrompt).to(equal([@[chunk2] mutableCopy]));
- expect(testRequest.vrHelpTitle).to(equal(@"vr"));
- expect(testRequest.vrHelp).to(equal([@[help] mutableCopy]));
- expect(testRequest.menuTitle).to(equal(@"TheNewMenu"));
+
+ expect(testRequest.helpPrompt).to(equal([SDLTTSChunk textChunksFromString:helpTest]));
+ expect(testRequest.timeoutPrompt).to(equal([SDLTTSChunk textChunksFromString:timeoutTest]));
+ expect(testRequest.vrHelpTitle).to(equal(vrHelpTitle));
+ expect(testRequest.vrHelp).to(equal(@[help]));
+ expect(testRequest.menuTitle).to(equal(menuTitle));
expect(testRequest.menuIcon).to(equal(image));
expect(testRequest.keyboardProperties).to(equal(keyboard));
- expect(testRequest.userLocation).to(equal(seatLocation));
+ expect(testRequest.userLocation).to(beNil());
+ expect(testRequest.menuLayout).to(equal(menuLayout));
});
it(@"Should return nil if not set", ^ {
- SDLSetGlobalProperties* testRequest = [[SDLSetGlobalProperties alloc] init];
+ SDLSetGlobalProperties *testRequest = [[SDLSetGlobalProperties alloc] init];
expect(testRequest.helpPrompt).to(beNil());
expect(testRequest.timeoutPrompt).to(beNil());
@@ -88,6 +127,7 @@ describe(@"Getter/Setter Tests", ^ {
expect(testRequest.menuIcon).to(beNil());
expect(testRequest.keyboardProperties).to(beNil());
expect(testRequest.userLocation).to(beNil());
+ expect(testRequest.menuLayout).to(beNil());
});
});
diff --git a/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLSetMediaClockTimerSpec.m b/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLSetMediaClockTimerSpec.m
index 255ce747d..721ba0b86 100644
--- a/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLSetMediaClockTimerSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLSetMediaClockTimerSpec.m
@@ -27,18 +27,16 @@ describe(@"SetMediaClocktimer Spec", ^ {
describe(@"when initialized", ^{
it(@"should properly initialize with initWithDictionary:", ^{
- NSMutableDictionary* dict = [@{SDLRPCParameterNameRequest:
- @{SDLRPCParameterNameParameters:
- @{SDLRPCParameterNameStartTime:time1,
- SDLRPCParameterNameEndTime:time2,
- SDLRPCParameterNameUpdateMode:testUpdateMode,
- SDLRPCParameterNameAudioStreamingIndicator:testIndicator
- },
- SDLRPCParameterNameOperationName:SDLRPCFunctionNameSetMediaClockTimer}} mutableCopy];
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLSetMediaClockTimer* testRequest = [[SDLSetMediaClockTimer alloc] initWithDictionary:dict];
-#pragma clang diagnostic pop
+ NSDictionary *dict = @{SDLRPCParameterNameRequest:
+ @{SDLRPCParameterNameParameters:
+ @{SDLRPCParameterNameStartTime:time1,
+ SDLRPCParameterNameEndTime:time2,
+ SDLRPCParameterNameUpdateMode:testUpdateMode,
+ SDLRPCParameterNameAudioStreamingIndicator:testIndicator
+ },
+ SDLRPCParameterNameOperationName:SDLRPCFunctionNameSetMediaClockTimer}
+ };
+ SDLSetMediaClockTimer *testRequest = [[SDLSetMediaClockTimer alloc] initWithDictionary:dict];
expect(testRequest.startTime).to(equal(time1));
expect(testRequest.endTime).to(equal(time2));
diff --git a/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLSubscribeVehicleDataSpec.m b/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLSubscribeVehicleDataSpec.m
index 4a8370ffc..d7a6753f1 100644
--- a/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLSubscribeVehicleDataSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLSubscribeVehicleDataSpec.m
@@ -240,104 +240,6 @@ describe(@"test initializers", ^{
});
});
- context(@"initWithAccelerationPedalPosition:airbagStatus:beltStatus:bodyInformation:clusterModeStatus:deviceStatus:driverBraking:eCallInfo:emergencyEvent:engineOilLife:engineTorque:externalTemperature:fuelLevel:fuelLevelState:gps:headLampStatus:instantFuelConsumption:myKey:odometer:prndl:rpm:speed:steeringWheelAngle:tirePressure:wiperStatus:", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLSubscribeVehicleData* testRequest = [[SDLSubscribeVehicleData alloc] initWithAccelerationPedalPosition:YES airbagStatus:YES beltStatus:YES bodyInformation:YES clusterModeStatus:YES deviceStatus:YES driverBraking:YES eCallInfo:YES electronicParkBrakeStatus:YES emergencyEvent:YES engineOilLife:YES engineTorque:YES externalTemperature:YES fuelLevel:YES fuelLevelState:YES fuelRange:YES gps:YES headLampStatus:YES instantFuelConsumption:YES myKey:YES odometer:YES prndl:YES rpm:YES speed:YES steeringWheelAngle:YES tirePressure:YES turnSignal:YES wiperStatus:YES];
-#pragma clang diagnostic pop
-
- it(@"expect all properties to be set properly", ^{
- expect(testRequest.accPedalPosition).to(equal(@YES));
- expect(testRequest.airbagStatus).to(equal(@YES));
- expect(testRequest.beltStatus).to(equal(@YES));
- expect(testRequest.bodyInformation).to(equal(@YES));
- expect(testRequest.cloudAppVehicleID).to(beNil());
- expect(testRequest.clusterModeStatus).to(equal(@YES));
- expect(testRequest.deviceStatus).to(equal(@YES));
- expect(testRequest.driverBraking).to(equal(@YES));
- expect(testRequest.eCallInfo).to(equal(@YES));
- expect(testRequest.electronicParkBrakeStatus).to(equal(@YES));
- expect(testRequest.emergencyEvent).to(equal(@YES));
- expect(testRequest.engineOilLife).to(equal(@YES));
- expect(testRequest.engineTorque).to(equal(@YES));
- expect(testRequest.externalTemperature).to(equal(@YES));
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testRequest.fuelLevel).to(equal(@YES));
- expect(testRequest.fuelLevel_State).to(equal(@YES));
-#pragma clang diagnostic pop
- expect(testRequest.fuelRange).to(equal(@YES));
- expect(testRequest.gearStatus).to(beNil());
- expect(testRequest.gps).to(equal(@YES));
- expect(testRequest.handsOffSteering).to(beNil());
- expect(testRequest.headLampStatus).to(equal(@YES));
- expect(testRequest.instantFuelConsumption).to(equal(@YES));
- expect(testRequest.myKey).to(equal(@YES));
- expect(testRequest.odometer).to(equal(@YES));
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testRequest.prndl).to(equal(@YES));
-#pragma clang diagnostic pop
- expect(testRequest.rpm).to(equal(@YES));
- expect(testRequest.speed).to(equal(@YES));
- expect(testRequest.stabilityControlsStatus).to(beNil());
- expect(testRequest.steeringWheelAngle).to(equal(@YES));
- expect(testRequest.tirePressure).to(equal(@YES));
- expect(testRequest.turnSignal).to(equal(@YES));
- expect(testRequest.windowStatus).to(beNil());
- expect(testRequest.wiperStatus).to(equal(@YES));
- });
- });
-
- context(@"initWithAccelerationPedalPosition:airbagStatus:beltStatus:bodyInformation:clusterModeStatus:deviceStatus:driverBraking:eCallInfo:emergencyEvent:engineTorque:externalTemperature:fuelLevel:fuelLevelState:gps:headLampStatus:instantFuelConsumption:myKey:odometer:prndl:rpm:speed:steeringWheelAngle:tirePressure:wiperStatus:", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLSubscribeVehicleData* testRequest = [[SDLSubscribeVehicleData alloc] initWithAccelerationPedalPosition:YES airbagStatus:YES beltStatus:YES bodyInformation:YES clusterModeStatus:YES deviceStatus:YES driverBraking:YES eCallInfo:YES emergencyEvent:YES engineTorque:YES externalTemperature:YES fuelLevel:YES fuelLevelState:YES gps:YES headLampStatus:YES instantFuelConsumption:YES myKey:YES odometer:YES prndl:YES rpm:YES speed:YES steeringWheelAngle:YES tirePressure:YES wiperStatus:YES];
-#pragma clang diagnostic pop
-
- it(@"expect all properties to be set properly", ^{
- expect(testRequest.accPedalPosition).to(equal(@YES));
- expect(testRequest.airbagStatus).to(equal(@YES));
- expect(testRequest.beltStatus).to(equal(@YES));
- expect(testRequest.bodyInformation).to(equal(@YES));
- expect(testRequest.cloudAppVehicleID).to(beNil());
- expect(testRequest.clusterModeStatus).to(equal(@YES));
- expect(testRequest.deviceStatus).to(equal(@YES));
- expect(testRequest.driverBraking).to(equal(@YES));
- expect(testRequest.eCallInfo).to(equal(@YES));
- expect(testRequest.electronicParkBrakeStatus).to(beNil());
- expect(testRequest.emergencyEvent).to(equal(@YES));
- expect(testRequest.engineOilLife).to(beNil());
- expect(testRequest.engineTorque).to(equal(@YES));
- expect(testRequest.externalTemperature).to(equal(@YES));
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testRequest.fuelLevel).to(equal(@YES));
- expect(testRequest.fuelLevel_State).to(equal(@YES));
-#pragma clang diagnostic pop
- expect(testRequest.fuelRange).to(beNil());
- expect(testRequest.gearStatus).to(beNil());
- expect(testRequest.gps).to(equal(@YES));
- expect(testRequest.handsOffSteering).to(beNil());
- expect(testRequest.headLampStatus).to(equal(@YES));
- expect(testRequest.instantFuelConsumption).to(equal(@YES));
- expect(testRequest.myKey).to(equal(@YES));
- expect(testRequest.odometer).to(equal(@YES));
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testRequest.prndl).to(equal(@YES));
-#pragma clang diagnostic pop
- expect(testRequest.rpm).to(equal(@YES));
- expect(testRequest.speed).to(equal(@YES));
- expect(testRequest.stabilityControlsStatus).to(beNil());
- expect(testRequest.steeringWheelAngle).to(equal(@YES));
- expect(testRequest.tirePressure).to(equal(@YES));
- expect(testRequest.turnSignal).to(beNil());
- expect(testRequest.windowStatus).to(beNil());
- expect(testRequest.wiperStatus).to(equal(@YES));
- });
- });
-
context(@"initWithGps:speed:rpm:instantFuelConsumption:fuelRange:externalTemperature:turnSignal:gearStatus:tirePressure:odometer:beltStatus:bodyInformation:deviceStatus:driverBraking:wiperStatus:headLampStatus:engineTorque:accPedalPosition:steeringWheelAngle:engineOilLife:electronicParkBrakeStatus:cloudAppVehicleID:stabilityControlsStatus:eCallInfo:airbagStatus:emergencyEvent:clusterModeStatus:myKey:handsOffSteering:windowStatus:", ^{
SDLSubscribeVehicleData* testRequest = [[SDLSubscribeVehicleData alloc] initWithGps:@YES speed:@YES rpm:@YES instantFuelConsumption:@YES fuelRange:@YES externalTemperature:@YES turnSignal:@YES gearStatus:@YES tirePressure:@YES odometer:@YES beltStatus:@YES bodyInformation:@YES deviceStatus:@YES driverBraking:@YES wiperStatus:@YES headLampStatus:@YES engineTorque:@YES accPedalPosition:@YES steeringWheelAngle:@YES engineOilLife:@YES electronicParkBrakeStatus:@YES cloudAppVehicleID:@YES stabilityControlsStatus:@YES eCallInfo:@YES airbagStatus:@YES emergencyEvent:@YES clusterModeStatus:@YES myKey:@YES handsOffSteering:@YES windowStatus:@YES];
diff --git a/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLUnsubscribeVehicleDataSpec.m b/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLUnsubscribeVehicleDataSpec.m
index 30472e0b0..2023224e9 100644
--- a/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLUnsubscribeVehicleDataSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLUnsubscribeVehicleDataSpec.m
@@ -239,55 +239,6 @@ describe(@"test initializers", ^{
});
});
- context(@"initWithAccelerationPedalPosition:airbagStatus:beltStatus:bodyInformation:clusterModeStatus:deviceStatus:driverBraking:eCallInfo:electronicParkBrakeStatus:emergencyEvent:engineOilLife:engineTorque:externalTemperature:fuelLevel:fuelLevelState:fuelRange:gps:headLampStatus:instantFuelConsumption:myKey:odometer:prndl:rpm:speed:steeringWheelAngle:tirePressure:turnSignal:wiperStatus:", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLUnsubscribeVehicleData *testRequest = [[SDLUnsubscribeVehicleData alloc] initWithAccelerationPedalPosition:YES airbagStatus:YES beltStatus:YES bodyInformation:YES clusterModeStatus:YES deviceStatus:YES driverBraking:YES eCallInfo:YES electronicParkBrakeStatus:YES emergencyEvent:YES engineOilLife:YES engineTorque:YES externalTemperature:YES fuelLevel:YES fuelLevelState:YES fuelRange:YES gps:YES headLampStatus:YES instantFuelConsumption:YES myKey:YES odometer:YES prndl:YES rpm:YES speed:YES steeringWheelAngle:YES tirePressure:YES turnSignal:YES wiperStatus:YES];
-#pragma clang diagnostic pop
-
- it(@"expect all properties to be set properly", ^{
- expect(testRequest.accPedalPosition).to(equal(@YES));
- expect(testRequest.airbagStatus).to(equal(@YES));
- expect(testRequest.beltStatus).to(equal(@YES));
- expect(testRequest.bodyInformation).to(equal(@YES));
- expect(testRequest.cloudAppVehicleID).to(beNil());
- expect(testRequest.clusterModeStatus).to(equal(@YES));
- expect(testRequest.deviceStatus).to(equal(@YES));
- expect(testRequest.driverBraking).to(equal(@YES));
- expect(testRequest.eCallInfo).to(equal(@YES));
- expect(testRequest.electronicParkBrakeStatus).to(equal(@YES));
- expect(testRequest.emergencyEvent).to(equal(@YES));
- expect(testRequest.engineOilLife).to(equal(@YES));
- expect(testRequest.engineTorque).to(equal(@YES));
- expect(testRequest.externalTemperature).to(equal(@YES));
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testRequest.fuelLevel).to(equal(@YES));
- expect(testRequest.fuelLevel_State).to(equal(@YES));
-#pragma clang diagnostic push
- expect(testRequest.fuelRange).to(equal(@YES));
- expect(testRequest.gearStatus).to(beNil());
- expect(testRequest.gps).to(equal(@YES));
- expect(testRequest.handsOffSteering).to(beNil());
- expect(testRequest.headLampStatus).to(equal(@YES));
- expect(testRequest.instantFuelConsumption).to(equal(@YES));
- expect(testRequest.myKey).to(equal(@YES));
- expect(testRequest.odometer).to(equal(@YES));
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testRequest.prndl).to(equal(@YES));
-#pragma clang diagnostic pop
- expect(testRequest.rpm).to(equal(@YES));
- expect(testRequest.speed).to(equal(@YES));
- expect(testRequest.stabilityControlsStatus).to(beNil());
- expect(testRequest.steeringWheelAngle).to(equal(@YES));
- expect(testRequest.tirePressure).to(equal(@YES));
- expect(testRequest.turnSignal).to(equal(@YES));
- expect(testRequest.windowStatus).to(beNil());
- expect(testRequest.wiperStatus).to(equal(@YES));
- });
- });
-
context(@"initWithAccelerationPedalPosition:airbagStatus:beltStatus:bodyInformation:cloudAppVehicleID:clusterModeStatus:deviceStatus:driverBraking:eCallInfo:electronicParkBrakeStatus:emergencyEvent:engineOilLife:engineTorque:externalTemperature:fuelLevel:fuelLevelState:fuelRange:gps:headLampStatus:instantFuelConsumption:myKey:odometer:prndl:rpm:speed:steeringWheelAngle:tirePressure:turnSignal:wiperStatus:", ^{
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
@@ -336,55 +287,6 @@ describe(@"test initializers", ^{
});
});
- context (@"initWithAccelerationPedalPosition:airbagStatus:beltStatus:bodyInformation:clusterModeStatus:deviceStatus:driverBraking:eCallInfo:emergencyEvent:engineTorque:externalTemperature:fuelLevel:fuelLevelState:gps:headLampStatus:instantFuelConsumption:myKey:odometer:prndl:rpm:speed:steeringWheelAngle:tirePressure:wiperStatus:", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLUnsubscribeVehicleData *testRequest = [[SDLUnsubscribeVehicleData alloc] initWithAccelerationPedalPosition:YES airbagStatus:YES beltStatus:YES bodyInformation:YES clusterModeStatus:YES deviceStatus:YES driverBraking:YES eCallInfo:YES emergencyEvent:YES engineTorque:YES externalTemperature:YES fuelLevel:YES fuelLevelState:YES gps:YES headLampStatus:YES instantFuelConsumption:YES myKey:YES odometer:YES prndl:YES rpm:YES speed:YES steeringWheelAngle:YES tirePressure:YES wiperStatus:YES];
-#pragma clang diagnostic pop
-
- it(@"expect all properties to be set properly", ^{
- expect(testRequest.accPedalPosition).to(equal(@YES));
- expect(testRequest.airbagStatus).to(equal(@YES));
- expect(testRequest.beltStatus).to(equal(@YES));
- expect(testRequest.bodyInformation).to(equal(@YES));
- expect(testRequest.cloudAppVehicleID).to(beNil());
- expect(testRequest.clusterModeStatus).to(equal(@YES));
- expect(testRequest.deviceStatus).to(equal(@YES));
- expect(testRequest.driverBraking).to(equal(@YES));
- expect(testRequest.eCallInfo).to(equal(@YES));
- expect(testRequest.electronicParkBrakeStatus).to(beNil());
- expect(testRequest.emergencyEvent).to(equal(@YES));
- expect(testRequest.engineOilLife).to(beNil());
- expect(testRequest.engineTorque).to(equal(@YES));
- expect(testRequest.externalTemperature).to(equal(@YES));
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testRequest.fuelLevel).to(equal(@YES));
- expect(testRequest.fuelLevel_State).to(equal(@YES));
-#pragma clang diagnostic push
- expect(testRequest.fuelRange).to(beNil());
- expect(testRequest.gearStatus).to(beNil());
- expect(testRequest.gps).to(equal(@YES));
- expect(testRequest.handsOffSteering).to(beNil());
- expect(testRequest.headLampStatus).to(equal(@YES));
- expect(testRequest.instantFuelConsumption).to(equal(@YES));
- expect(testRequest.myKey).to(equal(@YES));
- expect(testRequest.odometer).to(equal(@YES));
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testRequest.prndl).to(equal(@YES));
-#pragma clang diagnostic pop
- expect(testRequest.rpm).to(equal(@YES));
- expect(testRequest.speed).to(equal(@YES));
- expect(testRequest.stabilityControlsStatus).to(beNil());
- expect(testRequest.steeringWheelAngle).to(equal(@YES));
- expect(testRequest.tirePressure).to(equal(@YES));
- expect(testRequest.turnSignal).to(beNil());
- expect(testRequest.windowStatus).to(beNil());
- expect(testRequest.wiperStatus).to(equal(@YES));
- });
- });
-
context (@"initWithGps:speed:rpm:instantFuelConsumption:fuelRange:externalTemperature:turnSignal:gearStatus:tirePressure:odometer:beltStatus:bodyInformation:deviceStatus:driverBraking:wiperStatus:headLampStatus:engineTorque:accPedalPosition:steeringWheelAngle:engineOilLife:electronicParkBrakeStatus:cloudAppVehicleID:stabilityControlsStatus:eCallInfo:airbagStatus:emergencyEvent:clusterModeStatus:myKey:handsOffSteering:windowStatus:", ^{
SDLUnsubscribeVehicleData *testRequest = [[SDLUnsubscribeVehicleData alloc] initWithGps:@YES speed:@YES rpm:@YES instantFuelConsumption:@YES fuelRange:@YES externalTemperature:@YES turnSignal:@YES gearStatus:@YES tirePressure:@YES odometer:@YES beltStatus:@YES bodyInformation:@YES deviceStatus:@YES driverBraking:@YES wiperStatus:@YES headLampStatus:@YES engineTorque:@YES accPedalPosition:@YES steeringWheelAngle:@YES engineOilLife:@YES electronicParkBrakeStatus:@YES cloudAppVehicleID:@YES stabilityControlsStatus:@YES eCallInfo:@YES airbagStatus:@YES emergencyEvent:@YES clusterModeStatus:@YES myKey:@YES handsOffSteering:@YES windowStatus:@YES];
diff --git a/SmartDeviceLinkTests/RPCSpecs/ResponseSpecs/SDLRegisterAppInterfaceResponseSpec.m b/SmartDeviceLinkTests/RPCSpecs/ResponseSpecs/SDLRegisterAppInterfaceResponseSpec.m
index 16eb19315..d7e776aab 100644
--- a/SmartDeviceLinkTests/RPCSpecs/ResponseSpecs/SDLRegisterAppInterfaceResponseSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/ResponseSpecs/SDLRegisterAppInterfaceResponseSpec.m
@@ -15,10 +15,6 @@
QuickSpecBegin(SDLRegisterAppInterfaceResponseSpec)
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
-__block SDLSyncMsgVersion* version = [[SDLSyncMsgVersion alloc] initWithMajorVersion:0 minorVersion:0 patchVersion:0];
-#pragma clang diagnostic pop
__block SDLMsgVersion *sdlVersion = [[SDLMsgVersion alloc] initWithMajorVersion:0 minorVersion:0 patchVersion:0];
__block SDLDisplayCapabilities* info = [[SDLDisplayCapabilities alloc] init];
__block SDLButtonCapabilities* button = [[SDLButtonCapabilities alloc] init];
@@ -31,10 +27,7 @@ __block SDLHMICapabilities *hmiCapabilities = [[SDLHMICapabilities alloc] init];
describe(@"Getter/Setter Tests", ^ {
it(@"Should set and get correctly", ^ {
SDLRegisterAppInterfaceResponse* testResponse = [[SDLRegisterAppInterfaceResponse alloc] init];
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testResponse.syncMsgVersion = version;
-#pragma clang diagnostic pop
+
testResponse.language = SDLLanguageEsMx;
testResponse.hmiDisplayLanguage = SDLLanguageRuRu;
#pragma clang diagnostic push
@@ -56,11 +49,8 @@ describe(@"Getter/Setter Tests", ^ {
testResponse.sdlVersion = @"sdlVersion";
testResponse.systemSoftwareVersion = @"systemSoftwareVersion";
testResponse.iconResumed = @YES;
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testResponse.syncMsgVersion).to(equal(version));
-#pragma clang diagnostic pop
testResponse.sdlMsgVersion = sdlVersion;
+
expect(testResponse.sdlMsgVersion).to(equal(sdlVersion));
expect(testResponse.language).to(equal(SDLLanguageEsMx));
expect(testResponse.hmiDisplayLanguage).to(equal(SDLLanguageRuRu));
@@ -84,11 +74,10 @@ describe(@"Getter/Setter Tests", ^ {
expect(testResponse.systemSoftwareVersion).to(equal(@"systemSoftwareVersion"));
expect(testResponse.iconResumed).to(beTrue());
});
- describe(@"Setting With Dictionary", ^{
- __block NSDictionary *dict = nil;
+ describe(@"Setting With Dictionary", ^{
beforeEach( ^{
- dict = @{SDLRPCParameterNameRequest:
+ NSDictionary *dict = @{SDLRPCParameterNameRequest:
@{SDLRPCParameterNameParameters:
@{SDLRPCParameterNameSyncMessageVersion:@{
SDLRPCParameterNameMajorVersion: @6,
@@ -115,26 +104,14 @@ describe(@"Getter/Setter Tests", ^ {
SDLRPCParameterNameIconResumed: @YES,
},
SDLRPCParameterNameOperationName:SDLRPCFunctionNameRegisterAppInterface}};
- });
-
- it(@"Should get correctly when initialized with a dictionary and get syncMsgVersion first", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLRegisterAppInterfaceResponse* testResponse = [[SDLRegisterAppInterfaceResponse alloc] initWithDictionary:dict];
-#pragma clang diagnostic pop
+ SDLRegisterAppInterfaceResponse *testResponse = [[SDLRegisterAppInterfaceResponse alloc] initWithDictionary:dict];
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testResponse.syncMsgVersion).to(equal([[SDLSyncMsgVersion alloc] initWithMajorVersion:6 minorVersion:0 patchVersion:0]));
-#pragma clang diagnostic pop
expect(testResponse.sdlMsgVersion).to(equal([[SDLMsgVersion alloc] initWithMajorVersion:6 minorVersion:0 patchVersion:0]));
expect(testResponse.language).to(equal(SDLLanguageEsMx));
expect(testResponse.hmiDisplayLanguage).to(equal(SDLLanguageRuRu));
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wdeprecated"
expect(testResponse.displayCapabilities).to(equal(info));
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated"
expect(testResponse.buttonCapabilities).to(equal(@[button]));
expect(testResponse.softButtonCapabilities).to(equal(@[softButton]));
expect(testResponse.presetBankCapabilities).to(equal(presetBank));
@@ -151,48 +128,13 @@ describe(@"Getter/Setter Tests", ^ {
expect(testResponse.sdlVersion).to(equal(@"sdlVersion"));
expect(testResponse.systemSoftwareVersion).to(equal(@"systemSoftwareVersion"));
expect(testResponse.iconResumed).to(beTrue());
- });
- it(@"Should get correctly when initialized with a dictionary and get sdlMsgVersion first", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLRegisterAppInterfaceResponse* testResponse = [[SDLRegisterAppInterfaceResponse alloc] initWithDictionary:dict];
-#pragma clang diagnostic pop
- expect(testResponse.sdlMsgVersion).to(equal([[SDLMsgVersion alloc] initWithMajorVersion:6 minorVersion:0 patchVersion:0]));
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testResponse.syncMsgVersion).to(equal([[SDLSyncMsgVersion alloc] initWithMajorVersion:6 minorVersion:0 patchVersion:0]));
-#pragma clang diagnostic pop
- expect(testResponse.language).to(equal(SDLLanguageEsMx));
- expect(testResponse.hmiDisplayLanguage).to(equal(SDLLanguageRuRu));
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated"
- expect(testResponse.displayCapabilities).to(equal(info));
- expect(testResponse.buttonCapabilities).to(equal(@[button]));
- expect(testResponse.softButtonCapabilities).to(equal(@[softButton]));
- expect(testResponse.presetBankCapabilities).to(equal(presetBank));
-#pragma clang diagnostic pop
- expect(testResponse.hmiZoneCapabilities).to(equal(@[SDLHMIZoneCapabilitiesBack, SDLHMIZoneCapabilitiesFront]));
- expect(testResponse.speechCapabilities).to(equal(@[SDLSpeechCapabilitiesSAPIPhonemes, SDLSpeechCapabilitiesSilence]));
- expect(testResponse.vrCapabilities).to(equal(@[SDLVRCapabilitiesText]));
- expect(testResponse.audioPassThruCapabilities).to(equal(@[audioPassThru]));
- expect(testResponse.pcmStreamCapabilities).to(equal(audioPassThru));
- expect(testResponse.vehicleType).to(equal(vehicle));
- expect(testResponse.prerecordedSpeech).to(equal(@[SDLPrerecordedSpeechListen, SDLPrerecordedSpeechHelp]));
- expect(testResponse.supportedDiagModes).to(equal(@[@67, @99, @111]));
- expect(testResponse.hmiCapabilities).to(equal(hmiCapabilities));
- expect(testResponse.sdlVersion).to(equal(@"sdlVersion"));
- expect(testResponse.systemSoftwareVersion).to(equal(@"systemSoftwareVersion"));
- expect(testResponse.iconResumed).to(beTrue());
});
});
it(@"Should return nil if not set", ^ {
- SDLRegisterAppInterfaceResponse* testResponse = [[SDLRegisterAppInterfaceResponse alloc] init];
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testResponse.syncMsgVersion).to(beNil());
-#pragma clang diagnostic pop
+ SDLRegisterAppInterfaceResponse *testResponse = [[SDLRegisterAppInterfaceResponse alloc] init];
+
expect(testResponse.sdlMsgVersion).to(beNil());
expect(testResponse.language).to(beNil());
expect(testResponse.hmiDisplayLanguage).to(beNil());
@@ -241,15 +183,8 @@ describe(@"Getter/Setter Tests", ^ {
SDLRPCParameterNameIconResumed: NSNull.null,
},
SDLRPCParameterNameOperationName:SDLRPCFunctionNameRegisterAppInterface}};
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLRegisterAppInterfaceResponse* testResponse = [[SDLRegisterAppInterfaceResponse alloc] initWithDictionary:dict];
-#pragma clang diagnostic pop
+ SDLRegisterAppInterfaceResponse *testResponse = [[SDLRegisterAppInterfaceResponse alloc] initWithDictionary:dict];
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expectAction(^{ [testResponse syncMsgVersion]; }).to(raiseException());
-#pragma clang diagnostic pop
expectAction(^{ [testResponse sdlMsgVersion]; }).to(raiseException());
expectAction(^{ [testResponse language]; }).to(raiseException());
expectAction(^{ [testResponse hmiDisplayLanguage]; }).to(raiseException());
diff --git a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLAppServiceCapabilitySpec.m b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLAppServiceCapabilitySpec.m
index b39ad49b7..413def97b 100644
--- a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLAppServiceCapabilitySpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLAppServiceCapabilitySpec.m
@@ -20,11 +20,8 @@ describe(@"Getter/Setter Tests", ^{
__block SDLAppServiceRecord *testUpdatedAppServiceRecord = nil;
beforeEach(^{
- testUpdateReason = SDLServiceUpdateActivated;
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
+ testUpdateReason = SDLServiceUpdateReasonActivated;
testUpdatedAppServiceRecord = [[SDLAppServiceRecord alloc] initWithDictionary:@{SDLRPCParameterNameServiceID:@"1234", SDLRPCParameterNameServicePublished:@YES}];
-#pragma clang diagnostic pop
});
it(@"Should set and get correctly", ^{
@@ -40,10 +37,8 @@ describe(@"Getter/Setter Tests", ^{
NSDictionary *dict = @{SDLRPCParameterNameUpdateReason:testUpdateReason,
SDLRPCParameterNameUpdatedAppServiceRecord:testUpdatedAppServiceRecord
};
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
SDLAppServiceCapability *testStruct = [[SDLAppServiceCapability alloc] initWithDictionary:dict];
-#pragma clang diagnostic pop
+
expect(testStruct.updateReason).to(equal(testUpdateReason));
expect(testStruct.updatedAppServiceRecord).to(equal(testUpdatedAppServiceRecord));
});
diff --git a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLAppServiceManifestSpec.m b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLAppServiceManifestSpec.m
index 0bdc9fff4..e1c37c04a 100644
--- a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLAppServiceManifestSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLAppServiceManifestSpec.m
@@ -18,7 +18,6 @@
#import "SDLRPCParameterNames.h"
#import "SDLRPCFunctionNames.h"
#import "SDLMsgVersion.h"
-#import "SDLSyncMsgVersion.h"
#import "SDLWeatherServiceManifest.h"
QuickSpecBegin(SDLAppServiceManifestSpec)
@@ -29,10 +28,6 @@ describe(@"Getter/Setter Tests", ^ {
__block SDLAppServiceType testAppServiceType = nil;
__block SDLImage *testServiceIcon = nil;
__block NSNumber<SDLBool> *testAllowAppConsumers = nil;
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- __block SDLSyncMsgVersion *testSyncMsgVersion = nil;
-#pragma clang diagnostic pop
__block SDLMsgVersion *testSDLMsgVersion = nil;
__block NSArray<NSNumber<SDLInt> *> *testHandledRPCs = nil;
__block SDLWeatherServiceManifest *testWeatherServiceManifest = nil;
@@ -45,10 +40,6 @@ describe(@"Getter/Setter Tests", ^ {
testAppServiceType = SDLAppServiceTypeNavigation;
testServiceIcon = [[SDLImage alloc] initWithName:@"testImage" isTemplate:false];
testAllowAppConsumers = @YES;
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testSyncMsgVersion = [[SDLSyncMsgVersion alloc] initWithMajorVersion:5 minorVersion:2 patchVersion:1];
-#pragma clang diagnostic pop
testSDLMsgVersion = [[SDLMsgVersion alloc] initWithMajorVersion:5 minorVersion:2 patchVersion:1];
testHandledRPCs = [[NSArray alloc] initWithObjects:[SDLFunctionID.sharedInstance functionIdForName:SDLRPCFunctionNameAddCommand], [SDLFunctionID.sharedInstance functionIdForName:SDLRPCFunctionNameCreateInteractionChoiceSet], nil];
testWeatherServiceManifest = [[SDLWeatherServiceManifest alloc] initWithCurrentForecastSupported:true maxMultidayForecastAmount:3 maxHourlyForecastAmount:0 maxMinutelyForecastAmount:0 weatherForLocationSupported:false];
@@ -63,10 +54,6 @@ describe(@"Getter/Setter Tests", ^ {
testStruct.serviceType = testServiceType;
testStruct.serviceIcon = testServiceIcon;
testStruct.allowAppConsumers = testAllowAppConsumers;
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testStruct.rpcSpecVersion = testSyncMsgVersion;
-#pragma clang diagnostic pop
testStruct.handledRPCs = testHandledRPCs;
testStruct.weatherServiceManifest = testWeatherServiceManifest;
testStruct.mediaServiceManifest = testMediaServiceManifest;
@@ -76,10 +63,6 @@ describe(@"Getter/Setter Tests", ^ {
expect(testStruct.serviceType).to(match(testServiceType));
expect(testStruct.serviceIcon).to(equal(testServiceIcon));
expect(testStruct.allowAppConsumers).to(beTrue());
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testStruct.rpcSpecVersion).to(equal(testSyncMsgVersion));
-#pragma clang diagnostic pop
testStruct.maxRPCSpecVersion = testSDLMsgVersion;
expect(testStruct.maxRPCSpecVersion).to(equal(testSDLMsgVersion));
expect(testStruct.maxRPCSpecVersion).to(equal(testSDLMsgVersion));
@@ -105,47 +88,18 @@ describe(@"Getter/Setter Tests", ^ {
SDLRPCParameterNameMediaServiceManifest:testMediaServiceManifest,
SDLRPCParameterNameNavigationServiceManifest:testNavigationServiceManifest
};
- });
- it(@"Should get correctly when initialized with a dictionary and using SycMsgVersion", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLAppServiceManifest *testStruct = [[SDLAppServiceManifest alloc] initWithDictionary:dict];
-#pragma clang diagnostic pop
- expect(testStruct.serviceName).to(match(testServiceName));
- expect(testStruct.serviceType).to(equal(testServiceType));
- expect(testStruct.serviceIcon).to(equal(testServiceIcon));
- expect(testStruct.allowAppConsumers).to(beTrue());
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testStruct.rpcSpecVersion).to(equal([[SDLSyncMsgVersion alloc] initWithMajorVersion:5 minorVersion:1 patchVersion:0]));
-#pragma clang diagnostic pop
- expect(testStruct.maxRPCSpecVersion).to(equal([[SDLMsgVersion alloc] initWithMajorVersion:5 minorVersion:1 patchVersion:0]));
- expect(testStruct.handledRPCs).to(equal(testHandledRPCs));
- expect(testStruct.weatherServiceManifest).to(equal(testWeatherServiceManifest));
- expect(testStruct.mediaServiceManifest).to(equal(testMediaServiceManifest));
- expect(testStruct.navigationServiceManifest).to(equal(testNavigationServiceManifest));
- });
+ SDLAppServiceManifest *testStruct = [[SDLAppServiceManifest alloc] initWithDictionary:dict];
- it(@"Should get correctly when initialized with a dictionary and using SDLMsgVersion", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLAppServiceManifest *testStruct = [[SDLAppServiceManifest alloc] initWithDictionary:dict];
-#pragma clang diagnostic pop
expect(testStruct.serviceName).to(match(testServiceName));
expect(testStruct.serviceType).to(equal(testServiceType));
expect(testStruct.serviceIcon).to(equal(testServiceIcon));
expect(testStruct.allowAppConsumers).to(beTrue());
expect(testStruct.maxRPCSpecVersion).to(equal([[SDLMsgVersion alloc] initWithMajorVersion:5 minorVersion:1 patchVersion:0]));
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testStruct.rpcSpecVersion).to(equal([[SDLSyncMsgVersion alloc] initWithMajorVersion:5 minorVersion:1 patchVersion:0]));
-#pragma clang diagnostic pop
expect(testStruct.handledRPCs).to(equal(testHandledRPCs));
expect(testStruct.weatherServiceManifest).to(equal(testWeatherServiceManifest));
expect(testStruct.mediaServiceManifest).to(equal(testMediaServiceManifest));
expect(testStruct.navigationServiceManifest).to(equal(testNavigationServiceManifest));
-
});
});
@@ -156,10 +110,6 @@ describe(@"Getter/Setter Tests", ^ {
expect(testStruct.serviceType).to(equal(testAppServiceType));
expect(testStruct.serviceIcon).to(beNil());
expect(testStruct.allowAppConsumers).to(beNil());
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testStruct.rpcSpecVersion).to(beNil());
-#pragma clang diagnostic pop
expect(testStruct.maxRPCSpecVersion).to(beNil());
expect(testStruct.handledRPCs).to(beNil());
expect(testStruct.weatherServiceManifest).to(beNil());
@@ -167,26 +117,6 @@ describe(@"Getter/Setter Tests", ^ {
expect(testStruct.navigationServiceManifest).to(beNil());
});
- it(@"Should init correctly with initWithMediaServiceName:serviceIcon:allowAppConsumers:rpcSpecVersion:handledRPCs:mediaServiceManifest:", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLAppServiceManifest *testStruct = [[SDLAppServiceManifest alloc] initWithMediaServiceName:testServiceName serviceIcon:testServiceIcon allowAppConsumers:testAllowAppConsumers rpcSpecVersion:testSyncMsgVersion handledRPCs:testHandledRPCs mediaServiceManifest:testMediaServiceManifest];
-#pragma clang diagnostic pop
- expect(testStruct.serviceName).to(match(testServiceName));
- expect(testStruct.serviceType).to(equal(SDLAppServiceTypeMedia));
- expect(testStruct.serviceIcon).to(equal(testServiceIcon));
- expect(testStruct.allowAppConsumers).to(beTrue());
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testStruct.rpcSpecVersion).to(equal(testSyncMsgVersion));
-#pragma clang diagnostic pop
- expect(testStruct.maxRPCSpecVersion).to(equal(testSDLMsgVersion));
- expect(testStruct.handledRPCs).to(equal(testHandledRPCs));
- expect(testStruct.weatherServiceManifest).to(beNil());
- expect(testStruct.mediaServiceManifest).to(equal(testMediaServiceManifest));
- expect(testStruct.navigationServiceManifest).to(beNil());
- });
-
it(@"Should init correctly with initWithMediaServiceName:serviceIcon:allowAppConsumers:maxRPCSpecVersion:handledRPCs:mediaServiceManifest:", ^{
SDLAppServiceManifest *testStruct = [[SDLAppServiceManifest alloc] initWithMediaServiceName:testServiceName serviceIcon:testServiceIcon allowAppConsumers:testAllowAppConsumers maxRPCSpecVersion:testSDLMsgVersion handledRPCs:testHandledRPCs mediaServiceManifest:testMediaServiceManifest];
@@ -194,10 +124,6 @@ describe(@"Getter/Setter Tests", ^ {
expect(testStruct.serviceType).to(equal(SDLAppServiceTypeMedia));
expect(testStruct.serviceIcon).to(equal(testServiceIcon));
expect(testStruct.allowAppConsumers).to(beTrue());
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testStruct.rpcSpecVersion).to(equal(testSyncMsgVersion));
-#pragma clang diagnostic pop
expect(testStruct.maxRPCSpecVersion).to(equal(testSDLMsgVersion));
expect(testStruct.handledRPCs).to(equal(testHandledRPCs));
expect(testStruct.weatherServiceManifest).to(beNil());
@@ -205,26 +131,6 @@ describe(@"Getter/Setter Tests", ^ {
expect(testStruct.navigationServiceManifest).to(beNil());
});
- it(@"Should init correctly with initWithWeatherServiceName:serviceIcon:allowAppConsumers:rpcSpecVersion:handledRPCs:weatherServiceManifest:", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLAppServiceManifest *testStruct = [[SDLAppServiceManifest alloc] initWithWeatherServiceName:testServiceName serviceIcon:testServiceIcon allowAppConsumers:testAllowAppConsumers rpcSpecVersion:testSyncMsgVersion handledRPCs:testHandledRPCs weatherServiceManifest:testWeatherServiceManifest];
-#pragma clang diagnostic pop
- expect(testStruct.serviceName).to(match(testServiceName));
- expect(testStruct.serviceType).to(equal(SDLAppServiceTypeWeather));
- expect(testStruct.serviceIcon).to(equal(testServiceIcon));
- expect(testStruct.allowAppConsumers).to(beTrue());
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testStruct.rpcSpecVersion).to(equal(testSyncMsgVersion));
-#pragma clang diagnostic pop
- expect(testStruct.maxRPCSpecVersion).to(equal(testSDLMsgVersion));
- expect(testStruct.handledRPCs).to(equal(testHandledRPCs));
- expect(testStruct.weatherServiceManifest).to(equal(testWeatherServiceManifest));
- expect(testStruct.mediaServiceManifest).to(beNil());
- expect(testStruct.navigationServiceManifest).to(beNil());
- });
-
it(@"Should init correctly with initWithWeatherServiceName:serviceIcon:allowAppConsumers:maxRPCSpecVersion:handledRPCs:weatherServiceManifest:", ^{
SDLAppServiceManifest *testStruct = [[SDLAppServiceManifest alloc] initWithWeatherServiceName:testServiceName serviceIcon:testServiceIcon allowAppConsumers:testAllowAppConsumers maxRPCSpecVersion:testSDLMsgVersion handledRPCs:testHandledRPCs weatherServiceManifest:testWeatherServiceManifest];
@@ -232,10 +138,6 @@ describe(@"Getter/Setter Tests", ^ {
expect(testStruct.serviceType).to(equal(SDLAppServiceTypeWeather));
expect(testStruct.serviceIcon).to(equal(testServiceIcon));
expect(testStruct.allowAppConsumers).to(beTrue());
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testStruct.rpcSpecVersion).to(equal(testSyncMsgVersion));
-#pragma clang diagnostic pop
expect(testStruct.maxRPCSpecVersion).to(equal(testSDLMsgVersion));
expect(testStruct.handledRPCs).to(equal(testHandledRPCs));
expect(testStruct.weatherServiceManifest).to(equal(testWeatherServiceManifest));
@@ -243,27 +145,6 @@ describe(@"Getter/Setter Tests", ^ {
expect(testStruct.navigationServiceManifest).to(beNil());
});
-
- it(@"Should init correctly with initWithNavigationServiceName:serviceIcon:allowAppConsumers:rpcSpecVersion:handledRPCs:navigationServiceManifest:", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLAppServiceManifest *testStruct = [[SDLAppServiceManifest alloc] initWithNavigationServiceName:testServiceName serviceIcon:testServiceIcon allowAppConsumers:testAllowAppConsumers rpcSpecVersion:testSyncMsgVersion handledRPCs:testHandledRPCs navigationServiceManifest:testNavigationServiceManifest];
-#pragma clang diagnostic pop
- expect(testStruct.serviceName).to(match(testServiceName));
- expect(testStruct.serviceType).to(equal(SDLAppServiceTypeNavigation));
- expect(testStruct.serviceIcon).to(equal(testServiceIcon));
- expect(testStruct.allowAppConsumers).to(beTrue());
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testStruct.rpcSpecVersion).to(equal(testSyncMsgVersion));
-#pragma clang diagnostic pop
- expect(testStruct.maxRPCSpecVersion).to(equal(testSDLMsgVersion));
- expect(testStruct.handledRPCs).to(equal(testHandledRPCs));
- expect(testStruct.weatherServiceManifest).to(beNil());
- expect(testStruct.mediaServiceManifest).to(beNil());
- expect(testStruct.navigationServiceManifest).to(equal(testNavigationServiceManifest));
- });
-
it(@"Should init correctly with initWithNavigationServiceName:serviceIcon:allowAppConsumers:maxRPCSpecVersion:handledRPCs:navigationServiceManifest:", ^{
SDLAppServiceManifest *testStruct = [[SDLAppServiceManifest alloc] initWithNavigationServiceName:testServiceName serviceIcon:testServiceIcon allowAppConsumers:testAllowAppConsumers maxRPCSpecVersion:testSDLMsgVersion handledRPCs:testHandledRPCs navigationServiceManifest:testNavigationServiceManifest];
@@ -271,10 +152,6 @@ describe(@"Getter/Setter Tests", ^ {
expect(testStruct.serviceType).to(equal(SDLAppServiceTypeNavigation));
expect(testStruct.serviceIcon).to(equal(testServiceIcon));
expect(testStruct.allowAppConsumers).to(beTrue());
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testStruct.rpcSpecVersion).to(equal(testSyncMsgVersion));
-#pragma clang diagnostic pop
expect(testStruct.maxRPCSpecVersion).to(equal(testSDLMsgVersion));
expect(testStruct.handledRPCs).to(equal(testHandledRPCs));
expect(testStruct.weatherServiceManifest).to(beNil());
@@ -282,26 +159,6 @@ describe(@"Getter/Setter Tests", ^ {
expect(testStruct.navigationServiceManifest).to(equal(testNavigationServiceManifest));
});
- it(@"Should init correctly with initWithServiceName:serviceType:serviceIcon:allowAppConsumers:rpcSpecVersion:handledRPCs:mediaServiceManifest:weatherServiceManifest:navigationServiceManifest:", ^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLAppServiceManifest *testStruct = [[SDLAppServiceManifest alloc] initWithServiceName:testServiceName serviceType:testServiceType serviceIcon:testServiceIcon allowAppConsumers:testAllowAppConsumers rpcSpecVersion:testSyncMsgVersion handledRPCs:testHandledRPCs mediaServiceManifest:testMediaServiceManifest weatherServiceManifest:testWeatherServiceManifest navigationServiceManifest:testNavigationServiceManifest];
-#pragma clang diagnostic pop
- expect(testStruct.serviceName).to(match(testServiceName));
- expect(testStruct.serviceType).to(equal(testServiceType));
- expect(testStruct.serviceIcon).to(equal(testServiceIcon));
- expect(testStruct.allowAppConsumers).to(beTrue());
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testStruct.rpcSpecVersion).to(equal(testSyncMsgVersion));
-#pragma clang diagnostic pop
- expect(testStruct.maxRPCSpecVersion).to(equal(testSDLMsgVersion));
- expect(testStruct.handledRPCs).to(equal(testHandledRPCs));
- expect(testStruct.weatherServiceManifest).to(equal(testWeatherServiceManifest));
- expect(testStruct.mediaServiceManifest).to(equal(testMediaServiceManifest));
- expect(testStruct.navigationServiceManifest).to(equal(testNavigationServiceManifest));
- });
-
it(@"Should init correctly with initWithServiceName:serviceType:serviceIcon:allowAppConsumers:maxRPCSpecVersion:handledRPCs:mediaServiceManifest:weatherServiceManifest:navigationServiceManifest:", ^{
SDLAppServiceManifest *testStruct = [[SDLAppServiceManifest alloc] initWithServiceName:testServiceName serviceType:testServiceType serviceIcon:testServiceIcon allowAppConsumers:testAllowAppConsumers maxRPCSpecVersion:testSDLMsgVersion handledRPCs:testHandledRPCs mediaServiceManifest:testMediaServiceManifest weatherServiceManifest:testWeatherServiceManifest navigationServiceManifest:testNavigationServiceManifest];
@@ -309,10 +166,6 @@ describe(@"Getter/Setter Tests", ^ {
expect(testStruct.serviceType).to(equal(testServiceType));
expect(testStruct.serviceIcon).to(equal(testServiceIcon));
expect(testStruct.allowAppConsumers).to(beTrue());
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testStruct.rpcSpecVersion).to(equal(testSyncMsgVersion));
-#pragma clang diagnostic pop
expect(testStruct.maxRPCSpecVersion).to(equal(testSDLMsgVersion));
expect(testStruct.handledRPCs).to(equal(testHandledRPCs));
expect(testStruct.weatherServiceManifest).to(equal(testWeatherServiceManifest));
@@ -327,10 +180,6 @@ describe(@"Getter/Setter Tests", ^ {
expect(testStruct.serviceType).to(beNil());
expect(testStruct.serviceIcon).to(beNil());
expect(testStruct.allowAppConsumers).to(beNil());
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testStruct.rpcSpecVersion).to(beNil());
-#pragma clang diagnostic pop
expect(testStruct.maxRPCSpecVersion).to(beNil());
expect(testStruct.handledRPCs).to(beNil());
expect(testStruct.weatherServiceManifest).to(beNil());
diff --git a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLAppServicesCapabilitiesSpec.m b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLAppServicesCapabilitiesSpec.m
index 14b88578f..f0a673253 100644
--- a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLAppServicesCapabilitiesSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLAppServicesCapabilitiesSpec.m
@@ -19,10 +19,7 @@ describe(@"Getter/Setter Tests", ^{
__block NSArray<SDLAppServiceCapability *> *testAppServices = nil;
beforeEach(^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testAppServices = @[[[SDLAppServiceCapability alloc] initWithDictionary:@{SDLRPCParameterNameUpdateReason:SDLServiceUpdateRemoved}]];
-#pragma clang diagnostic pop
+ testAppServices = @[[[SDLAppServiceCapability alloc] initWithDictionary:@{SDLRPCParameterNameUpdateReason:SDLServiceUpdateReasonRemoved}]];
});
it(@"Should set and get correctly", ^{
@@ -39,12 +36,8 @@ describe(@"Getter/Setter Tests", ^{
});
it(@"Should get correctly when initialized with a dictionary", ^{
- NSDictionary *dict = @{SDLRPCParameterNameAppServices:testAppServices
- };
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
+ NSDictionary *dict = @{SDLRPCParameterNameAppServices:testAppServices};
SDLAppServicesCapabilities *testStruct = [[SDLAppServicesCapabilities alloc] initWithDictionary:dict];
-#pragma clang diagnostic pop
expect(testStruct.appServices).to(equal(testAppServices));
});
diff --git a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLAudioControlCapabilitiesSpec.m b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLAudioControlCapabilitiesSpec.m
index d23b64eba..5ad2a0d22 100644
--- a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLAudioControlCapabilitiesSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLAudioControlCapabilitiesSpec.m
@@ -33,7 +33,7 @@ describe(@"Getter/Setter Tests", ^ {
});
it(@"Should set and get correctly", ^ {
- SDLAudioControlCapabilities* testStruct = [[SDLAudioControlCapabilities alloc] init];
+ SDLAudioControlCapabilities *testStruct = [[SDLAudioControlCapabilities alloc] init];
testStruct.moduleName = @"module";
testStruct.moduleInfo = testModuleInfo;
@@ -52,23 +52,8 @@ describe(@"Getter/Setter Tests", ^ {
expect(testStruct.equalizerMaxChannelId).to(equal(@56));
});
- it(@"Should set and get correctly", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLAudioControlCapabilities* testStruct = [[SDLAudioControlCapabilities alloc] initWithModuleName:@"module"];
-#pragma clang diagnostic pop
-
- expect(testStruct.moduleName).to(equal(@"module"));
- expect(testStruct.moduleInfo).to(beNil());
- expect(testStruct.sourceAvailable).to(beNil());
- expect(testStruct.keepContextAvailable).to(beNil());
- expect(testStruct.volumeAvailable).to(beNil());
- expect(testStruct.equalizerAvailable).to(beNil());
- expect(testStruct.equalizerMaxChannelId).to(beNil());
- });
-
- it(@"Should set and get correctly", ^ {
- SDLAudioControlCapabilities* testStruct = [[SDLAudioControlCapabilities alloc] initWithModuleName:@"module" moduleInfo:testModuleInfo];
+ it(@"Should initialize correctly with initWithModuleName:moduleInfo:", ^ {
+ SDLAudioControlCapabilities *testStruct = [[SDLAudioControlCapabilities alloc] initWithModuleName:@"module" moduleInfo:testModuleInfo];
expect(testStruct.moduleName).to(equal(@"module"));
expect(testStruct.moduleInfo).to(equal(testModuleInfo));
@@ -78,28 +63,10 @@ describe(@"Getter/Setter Tests", ^ {
expect(testStruct.equalizerAvailable).to(beNil());
expect(testStruct.equalizerMaxChannelId).to(beNil());
});
-
- it(@"Should set and get correctly", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLAudioControlCapabilities* testStruct = [[SDLAudioControlCapabilities alloc] initWithModuleName:@"module" sourceAvailable:@NO keepContextAvailable:@NO volumeAvailable:@YES equalizerAvailable:@NO equalizerMaxChannelID:@34];
-#pragma clang diagnostic pop
-
- expect(testStruct.moduleName).to(equal(@"module"));
- expect(testStruct.moduleInfo).to(beNil());
- expect(testStruct.sourceAvailable).to(equal(@(NO)));
- expect(testStruct.keepContextAvailable).to(equal(@NO));
- expect(testStruct.volumeAvailable).to(equal(@(YES)));
- expect(testStruct.equalizerAvailable).to(equal(@(NO)));
- expect(testStruct.equalizerMaxChannelId).to(equal(@34));
- });
- it(@"Should set and get correctly", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLAudioControlCapabilities* testStruct = [[SDLAudioControlCapabilities alloc] initWithModuleName:@"module" moduleInfo:testModuleInfo sourceAvailable:@NO keepContextAvailable:@NO volumeAvailable:@YES equalizerAvailable:@NO equalizerMaxChannelID:@34];
-#pragma clang diagnostic pop
-
+ it(@"Should initialize correctly with initWithModuleName:moduleInfo:sourceAvailable:keepContextAvailable:volumeAvailable:equalizerAvailable:equalizerMaxChannelID:", ^ {
+ SDLAudioControlCapabilities *testStruct = [[SDLAudioControlCapabilities alloc] initWithModuleName:@"module" moduleInfo:testModuleInfo sourceAvailable:@NO keepContextAvailable:@NO volumeAvailable:@YES equalizerAvailable:@NO equalizerMaxChannelID:@34];
+
expect(testStruct.moduleName).to(equal(@"module"));
expect(testStruct.moduleInfo).to(equal(testModuleInfo));
expect(testStruct.sourceAvailable).to(equal(@(NO)));
@@ -109,20 +76,16 @@ describe(@"Getter/Setter Tests", ^ {
expect(testStruct.equalizerMaxChannelId).to(equal(@34));
});
-
- it(@"Should get correctly when initialized", ^ {
- NSMutableDictionary* dict = [@{SDLRPCParameterNameModuleName:@"module",
- SDLRPCParameterNameModuleInfo:testModuleInfo,
- SDLRPCParameterNameSourceAvailable:@(NO),
- SDLRPCParameterNameKeepContextAvailable: @YES,
- SDLRPCParameterNameVolumeAvailable:@(YES),
- SDLRPCParameterNameEqualizerAvailable:@(NO),
- SDLRPCParameterNameEqualizerMaxChannelId:@12
- } mutableCopy];
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLAudioControlCapabilities* testStruct = [[SDLAudioControlCapabilities alloc] initWithDictionary:dict];
-#pragma clang diagnostic pop
+ it(@"Should initialize correctly with a dictionary", ^ {
+ NSDictionary *dict = @{SDLRPCParameterNameModuleName:@"module",
+ SDLRPCParameterNameModuleInfo:testModuleInfo,
+ SDLRPCParameterNameSourceAvailable:@(NO),
+ SDLRPCParameterNameKeepContextAvailable: @YES,
+ SDLRPCParameterNameVolumeAvailable:@(YES),
+ SDLRPCParameterNameEqualizerAvailable:@(NO),
+ SDLRPCParameterNameEqualizerMaxChannelId:@12
+ };
+ SDLAudioControlCapabilities *testStruct = [[SDLAudioControlCapabilities alloc] initWithDictionary:dict];
expect(testStruct.moduleName).to(equal(@"module"));
expect(testStruct.moduleInfo).to(equal(testModuleInfo));
@@ -131,11 +94,10 @@ describe(@"Getter/Setter Tests", ^ {
expect(testStruct.volumeAvailable).to(equal(@(YES)));
expect(testStruct.equalizerAvailable).to(equal(@(NO)));
expect(testStruct.equalizerMaxChannelId).to(equal(@12));
-
});
it(@"Should return nil if not set", ^ {
- SDLAudioControlCapabilities* testStruct = [[SDLAudioControlCapabilities alloc] init];
+ SDLAudioControlCapabilities *testStruct = [[SDLAudioControlCapabilities alloc] init];
expect(testStruct.moduleName).to(beNil());
expect(testStruct.moduleInfo).to(beNil());
@@ -144,7 +106,6 @@ describe(@"Getter/Setter Tests", ^ {
expect(testStruct.volumeAvailable).to(beNil());
expect(testStruct.equalizerAvailable).to(beNil());
expect(testStruct.equalizerMaxChannelId).to(beNil());
-
});
});
diff --git a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLClimateControlCapabilitiesSpec.m b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLClimateControlCapabilitiesSpec.m
index 0322426fb..7460a85bc 100644
--- a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLClimateControlCapabilitiesSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLClimateControlCapabilitiesSpec.m
@@ -3,20 +3,19 @@
// SmartDeviceLink-iOS
//
-#import <Foundation/Foundation.h>
-
#import <Quick/Quick.h>
#import <Nimble/Nimble.h>
#import "SDLClimateControlCapabilities.h"
#import "SDLDefrostZone.h"
-#import "SDLVentilationMode.h"
#import "SDLRPCParameterNames.h"
+#import "SDLVentilationMode.h"
QuickSpecBegin(SDLClimateControlCapabilitiesSpec)
describe(@"Getter/Setter Tests", ^ {
+ __block NSString *testModuleName = @"Name";
__block SDLModuleInfo *testModuleInfo = nil;
__block SDLGrid *testGird = nil;
@@ -35,9 +34,8 @@ describe(@"Getter/Setter Tests", ^ {
});
it(@"Should set and get correctly", ^ {
-
SDLClimateControlCapabilities* testStruct = [[SDLClimateControlCapabilities alloc] init];
- testStruct.moduleName = @"Name";
+ testStruct.moduleName = testModuleName;
testStruct.moduleInfo = testModuleInfo;
testStruct.fanSpeedAvailable = @YES;
testStruct.desiredTemperatureAvailable = @NO;
@@ -56,7 +54,7 @@ describe(@"Getter/Setter Tests", ^ {
testStruct.heatedMirrorsAvailable = @(NO);
testStruct.climateEnableAvailable = @(NO);
- expect(testStruct.moduleName).to(equal(@"Name"));
+ expect(testStruct.moduleName).to(equal(testModuleName));
expect(testStruct.moduleInfo).to(equal(testModuleInfo));
expect(testStruct.fanSpeedAvailable).to(equal(@YES));
expect(testStruct.desiredTemperatureAvailable).to(equal(@NO));
@@ -77,32 +75,29 @@ describe(@"Getter/Setter Tests", ^ {
});
- it(@"Should get correctly when initialized", ^ {
- NSMutableDictionary<NSString *, id> *dict = [@{SDLRPCParameterNameModuleName:@"Name",
- SDLRPCParameterNameModuleInfo:testModuleInfo,
- SDLRPCParameterNameFanSpeedAvailable:@YES,
- SDLRPCParameterNameDesiredTemperatureAvailable:@NO,
- SDLRPCParameterNameACEnableAvailable:@NO,
- SDLRPCParameterNameACMaxEnableAvailable:@NO,
- SDLRPCParameterNameCirculateAirEnableAvailable:@YES,
- SDLRPCParameterNameAutoModeEnableAvailable:@NO,
- SDLRPCParameterNameDualModeEnableAvailable:@NO,
- SDLRPCParameterNameDefrostZoneAvailable:@YES,
- SDLRPCParameterNameDefrostZone:[@[SDLDefrostZoneFront] copy],
- SDLRPCParameterNameVentilationModeAvailable:@NO,
- SDLRPCParameterNameVentilationMode:[@[SDLVentilationModeUpper] copy],
- SDLRPCParameterNameHeatedSteeringWheelAvailable:@YES,
- SDLRPCParameterNameHeatedWindshieldAvailable:@NO,
- SDLRPCParameterNameHeatedRearWindowAvailable:@YES,
- SDLRPCParameterNameHeatedMirrorsAvailable:@NO,
- SDLRPCParameterNameClimateEnableAvailable:@NO,
- } mutableCopy];
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLClimateControlCapabilities* testStruct = [[SDLClimateControlCapabilities alloc] initWithDictionary:dict];
-#pragma clang diagnostic pop
-
- expect(testStruct.moduleName).to(equal(@"Name"));
+ it(@"Should get correctly when initialized with a dictionary", ^ {
+ NSDictionary *dict = @{SDLRPCParameterNameModuleName:testModuleName,
+ SDLRPCParameterNameModuleInfo:testModuleInfo,
+ SDLRPCParameterNameFanSpeedAvailable:@YES,
+ SDLRPCParameterNameDesiredTemperatureAvailable:@NO,
+ SDLRPCParameterNameACEnableAvailable:@NO,
+ SDLRPCParameterNameACMaxEnableAvailable:@NO,
+ SDLRPCParameterNameCirculateAirEnableAvailable:@YES,
+ SDLRPCParameterNameAutoModeEnableAvailable:@NO,
+ SDLRPCParameterNameDualModeEnableAvailable:@NO,
+ SDLRPCParameterNameDefrostZoneAvailable:@YES,
+ SDLRPCParameterNameDefrostZone:[@[SDLDefrostZoneFront] copy],
+ SDLRPCParameterNameVentilationModeAvailable:@NO,
+ SDLRPCParameterNameVentilationMode:[@[SDLVentilationModeUpper] copy],
+ SDLRPCParameterNameHeatedSteeringWheelAvailable:@YES,
+ SDLRPCParameterNameHeatedWindshieldAvailable:@NO,
+ SDLRPCParameterNameHeatedRearWindowAvailable:@YES,
+ SDLRPCParameterNameHeatedMirrorsAvailable:@NO,
+ SDLRPCParameterNameClimateEnableAvailable:@NO,
+ };
+ SDLClimateControlCapabilities *testStruct = [[SDLClimateControlCapabilities alloc] initWithDictionary:dict];
+
+ expect(testStruct.moduleName).to(equal(testModuleName));
expect(testStruct.moduleInfo).to(equal(testModuleInfo));
expect(testStruct.fanSpeedAvailable).to(equal(@YES));
expect(testStruct.desiredTemperatureAvailable).to(equal(@NO));
@@ -122,75 +117,27 @@ describe(@"Getter/Setter Tests", ^ {
expect(testStruct.climateEnableAvailable).to(equal(@NO));
});
- it(@"Should get correctly when initialized with module data and other climate control capabilities parameters", ^ {
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLClimateControlCapabilities* testStruct = [[SDLClimateControlCapabilities alloc] initWithModuleName:@"Name" fanSpeedAvailable:YES desiredTemperatureAvailable:NO acEnableAvailable:NO acMaxEnableAvailable:YES circulateAirAvailable:NO autoModeEnableAvailable:NO dualModeEnableAvailable:NO defrostZoneAvailable:YES ventilationModeAvailable:YES];
-
- expect(testStruct.moduleName).to(equal(@"Name"));
- expect(testStruct.moduleInfo).to(beNil());
- expect(testStruct.fanSpeedAvailable).to(equal(@YES));
- expect(testStruct.desiredTemperatureAvailable).to(equal(@NO));
- expect(testStruct.acEnableAvailable).to(equal(@NO));
- expect(testStruct.acMaxEnableAvailable).to(equal(@YES));
- expect(testStruct.circulateAirEnableAvailable).to(equal(@NO));
- expect(testStruct.autoModeEnableAvailable).to(equal(@NO));
- expect(testStruct.dualModeEnableAvailable).to(equal(@NO));
- expect(testStruct.defrostZoneAvailable).to(equal(@YES));
- expect(testStruct.ventilationModeAvailable).to(equal(@YES));
- expect(testStruct.heatedSteeringWheelAvailable).to(equal(@NO));
- expect(testStruct.heatedWindshieldAvailable).to(equal(@NO));
- expect(testStruct.heatedRearWindowAvailable).to(equal(@NO));
- expect(testStruct.heatedMirrorsAvailable).to(equal(@NO));
- expect(testStruct.climateEnableAvailable).to(equal(@NO));
- #pragma clang diagnostic pop
- });
-
- it(@"Should get correctly when initialized with module data and other climate control capabilities parameters", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLClimateControlCapabilities* testStruct = [[SDLClimateControlCapabilities alloc] initWithModuleName:@"Name" fanSpeedAvailable:YES desiredTemperatureAvailable:NO acEnableAvailable:NO acMaxEnableAvailable:YES circulateAirAvailable:NO autoModeEnableAvailable:NO dualModeEnableAvailable:NO defrostZoneAvailable:YES ventilationModeAvailable:YES heatedSteeringWheelAvailable:YES heatedWindshieldAvailable:NO heatedRearWindowAvailable:YES heatedMirrorsAvailable:NO];
-#pragma clang diagnostic pop
-
- expect(testStruct.moduleName).to(equal(@"Name"));
- expect(testStruct.moduleInfo).to(beNil());
- expect(testStruct.fanSpeedAvailable).to(equal(@YES));
- expect(testStruct.desiredTemperatureAvailable).to(equal(@NO));
- expect(testStruct.acEnableAvailable).to(equal(@NO));
- expect(testStruct.acMaxEnableAvailable).to(equal(@YES));
- expect(testStruct.circulateAirEnableAvailable).to(equal(@NO));
- expect(testStruct.autoModeEnableAvailable).to(equal(@NO));
- expect(testStruct.dualModeEnableAvailable).to(equal(@NO));
- expect(testStruct.defrostZoneAvailable).to(equal(@YES));
- expect(testStruct.ventilationModeAvailable).to(equal(@YES));
- expect(testStruct.heatedSteeringWheelAvailable).to(equal(@YES));
- expect(testStruct.heatedWindshieldAvailable).to(equal(@NO));
- expect(testStruct.heatedRearWindowAvailable).to(equal(@YES));
- expect(testStruct.heatedMirrorsAvailable).to(equal(@NO));
-#pragma clang diagnostic pop
- });
-
- it(@"Should get correctly when initialized with module data and other climate control capabilities parameters", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLClimateControlCapabilities* testStruct = [[SDLClimateControlCapabilities alloc] initWithModuleName:@"Name" fanSpeedAvailable:YES desiredTemperatureAvailable:NO acEnableAvailable:NO acMaxEnableAvailable:YES circulateAirAvailable:NO autoModeEnableAvailable:NO dualModeEnableAvailable:NO defrostZoneAvailable:YES ventilationModeAvailable:YES heatedSteeringWheelAvailable:YES heatedWindshieldAvailable:NO heatedRearWindowAvailable:YES heatedMirrorsAvailable:NO climateEnableAvailable:NO];
-#pragma clang diagnostic pop
+ it(@"Should get correctly when initialized with initWithModuleName:moduleInfo:fanSpeedAvailable:desiredTemperatureAvailable:acEnableAvailable:acMaxEnableAvailable:circulateAirAvailable:autoModeEnableAvailable:dualModeEnableAvailable:defrostZoneAvailable:ventilationModeAvailable:heatedSteeringWheelAvailable:heatedWindshieldAvailable:heatedRearWindowAvailable:heatedMirrorsAvailable:climateEnableAvailable:", ^ {
+ SDLClimateControlCapabilities *testStruct = [[SDLClimateControlCapabilities alloc] initWithModuleName:testModuleName moduleInfo:testModuleInfo fanSpeedAvailable:YES desiredTemperatureAvailable:YES acEnableAvailable:YES acMaxEnableAvailable:YES circulateAirAvailable:YES autoModeEnableAvailable:YES dualModeEnableAvailable:YES defrostZoneAvailable:YES ventilationModeAvailable:YES heatedSteeringWheelAvailable:YES heatedWindshieldAvailable:YES heatedRearWindowAvailable:YES heatedMirrorsAvailable:YES climateEnableAvailable:YES];
- expect(testStruct.moduleName).to(equal(@"Name"));
+ expect(testStruct.moduleName).to(equal(testModuleName));
+ expect(testStruct.moduleInfo).to(equal(testModuleInfo));
expect(testStruct.fanSpeedAvailable).to(equal(@YES));
- expect(testStruct.desiredTemperatureAvailable).to(equal(@NO));
- expect(testStruct.acEnableAvailable).to(equal(@NO));
+ expect(testStruct.desiredTemperatureAvailable).to(equal(@YES));
+ expect(testStruct.acEnableAvailable).to(equal(@YES));
expect(testStruct.acMaxEnableAvailable).to(equal(@YES));
- expect(testStruct.circulateAirEnableAvailable).to(equal(@NO));
- expect(testStruct.autoModeEnableAvailable).to(equal(@NO));
- expect(testStruct.dualModeEnableAvailable).to(equal(@NO));
+ expect(testStruct.circulateAirEnableAvailable).to(equal(@YES));
+ expect(testStruct.autoModeEnableAvailable).to(equal(@YES));
+ expect(testStruct.dualModeEnableAvailable).to(equal(@YES));
expect(testStruct.defrostZoneAvailable).to(equal(@YES));
expect(testStruct.ventilationModeAvailable).to(equal(@YES));
expect(testStruct.heatedSteeringWheelAvailable).to(equal(@YES));
- expect(testStruct.heatedWindshieldAvailable).to(equal(@NO));
+ expect(testStruct.heatedWindshieldAvailable).to(equal(@YES));
expect(testStruct.heatedRearWindowAvailable).to(equal(@YES));
- expect(testStruct.heatedMirrorsAvailable).to(equal(@NO));
- expect(testStruct.climateEnableAvailable).to(equal(@NO));
+ expect(testStruct.heatedMirrorsAvailable).to(equal(@YES));
+ expect(testStruct.climateEnableAvailable).to(equal(@YES));
+ expect(testStruct.defrostZone).to(beNil());
+ expect(testStruct.ventilationMode).to(beNil());
});
it(@"Should return nil if not set", ^ {
diff --git a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLClimateControlDataSpec.m b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLClimateControlDataSpec.m
index 6c4a04c8a..ff4f35fcd 100644
--- a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLClimateControlDataSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLClimateControlDataSpec.m
@@ -63,28 +63,6 @@ describe(@"Getter/Setter Tests", ^ {
});
it(@"Should get correctly when initialized with FanSpeed and other climate control parameters", ^ {
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLClimateControlData* testStruct = [[SDLClimateControlData alloc] initWithFanSpeed:@43 desiredTemperature:desiredTemp acEnable:@YES circulateAirEnable:@YES autoModeEnable:@NO defrostZone:SDLDefrostZoneFront dualModeEnable:@NO acMaxEnable:@YES ventilationMode:SDLVentilationModeBoth];
-
- expect(testStruct.fanSpeed).to(equal(@43));
- expect(testStruct.desiredTemperature).to(equal(desiredTemp));
- expect(testStruct.acEnable).to(equal(YES));
- expect(testStruct.circulateAirEnable).to(equal(YES));
- expect(testStruct.autoModeEnable).to(equal(NO));
- expect(testStruct.defrostZone).to(equal(SDLDefrostZoneFront));
- expect(testStruct.dualModeEnable).to(equal(NO));
- expect(testStruct.acMaxEnable).to(equal(YES));
- expect(testStruct.ventilationMode).to(equal(SDLVentilationModeBoth));
- expect(testStruct.heatedSteeringWheelEnable).to(equal(NO));
- expect(testStruct.heatedWindshieldEnable).to(equal(NO));
- expect(testStruct.heatedRearWindowEnable).to(equal(NO));
- expect(testStruct.heatedMirrorsEnable).to(equal(NO));
- expect(testStruct.climateEnable).to(beNil());
- #pragma clang diagnostic pop
- });
-
- it(@"Should get correctly when initialized with FanSpeed and other climate control parameters", ^ {
SDLClimateControlData* testStruct = [[SDLClimateControlData alloc] initWithFanSpeed:@43 desiredTemperature:desiredTemp acEnable:@YES circulateAirEnable:@YES autoModeEnable:@NO defrostZone:SDLDefrostZoneFront dualModeEnable:@NO acMaxEnable:@YES ventilationMode:SDLVentilationModeBoth heatedSteeringWheelEnable:@NO heatedWindshieldEnable:@YES heatedRearWindowEnable:@NO heatedMirrorsEnable:@YES climateEnable:@YES];
expect(testStruct.fanSpeed).to(equal(@43));
@@ -104,7 +82,7 @@ describe(@"Getter/Setter Tests", ^ {
});
it(@"Should get correctly when initialized with a dictionary", ^ {
- NSMutableDictionary<NSString *, id> *dict = [@{SDLRPCParameterNameFanSpeed : @43,
+ NSDictionary *dict = @{SDLRPCParameterNameFanSpeed : @43,
SDLRPCParameterNameCurrentTemperature : currentTemp,
SDLRPCParameterNameDesiredTemperature : desiredTemp,
SDLRPCParameterNameACEnable : @YES,
@@ -119,13 +97,9 @@ describe(@"Getter/Setter Tests", ^ {
SDLRPCParameterNameHeatedRearWindowEnable:@NO,
SDLRPCParameterNameHeatedMirrorsEnable:@YES,
SDLRPCParameterNameClimateEnable:@YES,
- } mutableCopy];
+ };
+ SDLClimateControlData *testStruct = [[SDLClimateControlData alloc] initWithDictionary:dict];
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLClimateControlData* testStruct = [[SDLClimateControlData alloc] initWithDictionary:dict];
-#pragma clang diagnostic pop
-
expect(testStruct.fanSpeed).to(equal(@43));
expect(testStruct.currentTemperature).to(equal(currentTemp));
expect(testStruct.desiredTemperature).to(equal(desiredTemp));
diff --git a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLDisplayCapabilitySpec.m b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLDisplayCapabilitySpec.m
index 1d0aad819..c984f0725 100644
--- a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLDisplayCapabilitySpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLDisplayCapabilitySpec.m
@@ -5,21 +5,19 @@
#import <Quick/Quick.h>
#import <Nimble/Nimble.h>
-#import "SDLRPCParameterNames.h"
-#import "SDLWindowTypeCapabilities.h"
-#import "SDLWindowCapability.h"
+#import "SDLButtonCapabilities.h"
#import "SDLDisplayCapability.h"
-#import "SDLTextField.h"
#import "SDLImageField.h"
#import "SDLImageType.h"
-#import "SDLButtonCapabilities.h"
+#import "SDLRPCParameterNames.h"
#import "SDLSoftButtonCapabilities.h"
+#import "SDLTextField.h"
+#import "SDLWindowCapability.h"
+#import "SDLWindowTypeCapabilities.h"
QuickSpecBegin(SDLDisplayCapabilitySpec)
describe(@"Getter/Setter Tests", ^ {
-
-
__block SDLWindowCapability* testWindowCapability = nil;
__block SDLWindowTypeCapabilities* testWindowTypeCapabilities = nil;
__block SDLTextField *testTextField = nil;
@@ -64,10 +62,9 @@ describe(@"Getter/Setter Tests", ^ {
testWindowCapability.buttonCapabilities = @[testButtonCapabilities];
testWindowCapability.softButtonCapabilities = @[testSoftButtonscapabilities];
});
-
-
+
it(@"Should set and get correctly", ^ {
- SDLDisplayCapability* testStruct = [[SDLDisplayCapability alloc] init];
+ SDLDisplayCapability *testStruct = [[SDLDisplayCapability alloc] init];
testStruct.displayName = testDisplayName;
testStruct.windowCapabilities = @[testWindowCapability];
testStruct.windowTypeSupported = @[testWindowTypeCapabilities];
@@ -84,6 +81,41 @@ describe(@"Getter/Setter Tests", ^ {
expect(testStruct.windowCapabilities.firstObject.buttonCapabilities.firstObject.longPressAvailable).to(equal(@YES));
expect(testStruct.windowCapabilities.firstObject.buttonCapabilities.firstObject.name).to(equal(SDLButtonNameOk));
});
+
+ it(@"Should get correctly when initialized with a dictionary", ^ {
+ NSDictionary *dict = @{SDLRPCParameterNameDisplayName: testDisplayName,
+ SDLRPCParameterNameWindowCapabilities: @[testWindowCapability],
+ SDLRPCParameterNameWindowTypeSupported: @[testWindowTypeCapabilities]};
+ SDLDisplayCapability *testStruct = [[SDLDisplayCapability alloc] initWithDictionary:dict];
+
+ expect(testStruct.displayName).to(equal(testDisplayName));
+ expect(testStruct.windowCapabilities).to(equal(@[testWindowCapability]));
+ expect(testStruct.windowTypeSupported).to(equal(@[testWindowTypeCapabilities]));
+ });
+
+ it(@"Should initialize correctly with initWithDisplayName:", ^{
+ SDLDisplayCapability *testStruct = [[SDLDisplayCapability alloc] initWithDisplayName:testDisplayName];
+
+ expect(testStruct.displayName).to(equal(testDisplayName));
+ expect(testStruct.windowCapabilities).to(beNil());
+ expect(testStruct.windowTypeSupported).to(beNil());
+ });
+
+ it(@"Should initialize correctly with initWithDisplayName:windowCapabilities:windowTypeSupported:", ^{
+ SDLDisplayCapability *testStruct = [[SDLDisplayCapability alloc] initWithDisplayName:testDisplayName windowCapabilities:@[testWindowCapability] windowTypeSupported:@[testWindowTypeCapabilities]];
+
+ expect(testStruct.displayName).to(equal(testDisplayName));
+ expect(testStruct.windowCapabilities).to(equal(@[testWindowCapability]));
+ expect(testStruct.windowTypeSupported).to(equal(@[testWindowTypeCapabilities]));
+ });
+
+ it(@"Should be nil if not set", ^{
+ SDLDisplayCapability *testStruct = [[SDLDisplayCapability alloc] init];
+
+ expect(testStruct.displayName).to(beNil());
+ expect(testStruct.windowCapabilities).to(beNil());
+ expect(testStruct.windowTypeSupported).to(beNil());
+ });
});
QuickSpecEnd
diff --git a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLHMISettingsControlCapabilitiesSpec.m b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLHMISettingsControlCapabilitiesSpec.m
index 9906477d4..ee8f72fbc 100644
--- a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLHMISettingsControlCapabilitiesSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLHMISettingsControlCapabilitiesSpec.m
@@ -47,47 +47,18 @@ describe(@"Getter/Setter Tests", ^ {
expect(testStruct.temperatureUnitAvailable).to(equal(@(NO)));
expect(testStruct.displayModeUnitAvailable).to(equal(@(YES)));
});
-
- it(@"Should set and get correctly", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLHMISettingsControlCapabilities* testStruct = [[SDLHMISettingsControlCapabilities alloc] initWithModuleName:@"displayMode"];
-#pragma clang diagnostic pop
-
- expect(testStruct.moduleName).to(equal(@"displayMode"));
- expect(testStruct.moduleInfo).to(beNil());
- expect(testStruct.distanceUnitAvailable).to(beNil());
- expect(testStruct.temperatureUnitAvailable).to(beNil());
- expect(testStruct.displayModeUnitAvailable).to(beNil());
- });
- it(@"Should set and get correctly", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
+ it(@"Should init correctly with initWithModuleName:moduleInfo:", ^ {
SDLHMISettingsControlCapabilities* testStruct = [[SDLHMISettingsControlCapabilities alloc] initWithModuleName:@"displayMode" moduleInfo:testModuleInfo];
-#pragma clang diagnostic pop
-
+
expect(testStruct.moduleName).to(equal(@"displayMode"));
expect(testStruct.moduleInfo).to(equal(testModuleInfo));
expect(testStruct.distanceUnitAvailable).to(beNil());
expect(testStruct.temperatureUnitAvailable).to(beNil());
expect(testStruct.displayModeUnitAvailable).to(beNil());
});
-
- it(@"Should set and get correctly", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLHMISettingsControlCapabilities* testStruct = [[SDLHMISettingsControlCapabilities alloc] initWithModuleName:@"displayMode" distanceUnitAvailable:NO temperatureUnitAvailable:YES displayModeUnitAvailable:NO];
-#pragma clang diagnostic pop
-
- expect(testStruct.moduleName).to(equal(@"displayMode"));
- expect(testStruct.moduleInfo).to(beNil());
- expect(testStruct.distanceUnitAvailable).to(equal(@(NO)));
- expect(testStruct.temperatureUnitAvailable).to(equal(@(YES)));
- expect(testStruct.displayModeUnitAvailable).to(equal(@(NO)));
- });
- it(@"Should set and get correctly", ^ {
+ it(@"Should init correctly with initWithModuleName:moduleInfo:distanceUnitAvailable:temperatureUnitAvailable:displayModeUnitAvailable:", ^ {
SDLHMISettingsControlCapabilities* testStruct = [[SDLHMISettingsControlCapabilities alloc] initWithModuleName:@"displayMode" moduleInfo:testModuleInfo distanceUnitAvailable:NO temperatureUnitAvailable:YES displayModeUnitAvailable:NO];
expect(testStruct.moduleName).to(equal(@"displayMode"));
@@ -98,23 +69,19 @@ describe(@"Getter/Setter Tests", ^ {
});
it(@"Should get correctly when initialized", ^ {
- NSMutableDictionary* dict = [@{SDLRPCParameterNameModuleName:@"temperatureUnit",
+ NSDictionary *dict = @{SDLRPCParameterNameModuleName:@"temperatureUnit",
SDLRPCParameterNameModuleInfo:testModuleInfo,
SDLRPCParameterNameTemperatureUnitAvailable:@(YES),
SDLRPCParameterNameDistanceUnitAvailable:@(YES),
SDLRPCParameterNameDisplayModeUnitAvailable:@(NO)
- } mutableCopy];
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLHMISettingsControlCapabilities* testStruct = [[SDLHMISettingsControlCapabilities alloc] initWithDictionary:dict];
-#pragma clang diagnostic pop
+ };
+ SDLHMISettingsControlCapabilities *testStruct = [[SDLHMISettingsControlCapabilities alloc] initWithDictionary:dict];
expect(testStruct.moduleName).to(equal(@"temperatureUnit"));
expect(testStruct.moduleInfo).to(equal(testModuleInfo));
expect(testStruct.distanceUnitAvailable).to(equal(@(YES)));
expect(testStruct.temperatureUnitAvailable).to(equal(@(YES)));
expect(testStruct.displayModeUnitAvailable).to(equal(@(NO)));
-
});
it(@"Should return nil if not set", ^ {
@@ -125,7 +92,6 @@ describe(@"Getter/Setter Tests", ^ {
expect(testStruct.distanceUnitAvailable).to(beNil());
expect(testStruct.temperatureUnitAvailable).to(beNil());
expect(testStruct.displayModeUnitAvailable).to(beNil());
-
});
});
diff --git a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLImageSpec.m b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLImageSpec.m
index 85bac3a78..1237c194a 100644
--- a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLImageSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLImageSpec.m
@@ -51,10 +51,7 @@ describe(@"Getter/Setter Tests", ^{
SDLRPCParameterNameImageType:imageType,
SDLRPCParameterNameImageTemplate:@YES
} mutableCopy];
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
testSDLImage = [[SDLImage alloc] initWithDictionary:dict];
-#pragma clang diagnostic pop
expectedValue = value;
expectedImageType = imageType;
@@ -95,18 +92,6 @@ describe(@"initializers", ^{
expect(testImage.isTemplate).to(beNil());
});
- context(@"initWithName:ofType:", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testImage = [[SDLImage alloc] initWithName:testValue ofType:testImageType];
-
- expect(testImage).toNot(beNil());
- expect(testImage.value).to(equal(testValue));
- expect(testImage.imageType).to(equal(testImageType));
- expect(testImage.isTemplate).to(beFalse());
- #pragma clang diagnostic pop
- });
-
context(@"initWithName:ofType:isTemplate", ^{
testImage = [[SDLImage alloc] initWithName:testValue ofType:testImageType isTemplate:testIsTemplate];
@@ -116,18 +101,6 @@ describe(@"initializers", ^{
expect(testImage.isTemplate).to(equal(testIsTemplate));
});
- context(@"initWithName:", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testImage = [[SDLImage alloc] initWithName:testValue];
-
- expect(testImage).toNot(beNil());
- expect(testImage.value).to(equal(testValue));
- expect(testImage.imageType).to(equal(SDLImageTypeDynamic));
- expect(testImage.isTemplate).to(beFalse());
- #pragma clang diagnostic pop
- });
-
context(@"initWithName:isTemplate", ^{
testImage = [[SDLImage alloc] initWithName:testValue isTemplate:testIsTemplate];
diff --git a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLKeyboardPropertiesSpec.m b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLKeyboardPropertiesSpec.m
index a4d0d32a3..7b1e28362 100644
--- a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLKeyboardPropertiesSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLKeyboardPropertiesSpec.m
@@ -43,7 +43,7 @@ describe(@"Getter/Setter Tests", ^ {
expect(testStruct.autoCompleteList).to(equal(testAutoCompleteList));
});
- it(@"Should get correctly when initialized", ^ {
+ it(@"Should get correctly when initialized with a dictionary", ^ {
NSDictionary* dict = @{SDLRPCParameterNameLanguage: testLanguage,
SDLRPCParameterNameKeyboardLayout: testLayout,
SDLRPCParameterNameKeypressMode: testMode,
@@ -51,11 +51,19 @@ describe(@"Getter/Setter Tests", ^ {
SDLRPCParameterNameAutoCompleteText: testAutoCompleteText,
SDLRPCParameterNameAutoCompleteList: testAutoCompleteList
};
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
SDLKeyboardProperties* testStruct = [[SDLKeyboardProperties alloc] initWithDictionary:dict];
-#pragma clang diagnostic pop
-
+
+ expect(testStruct.language).to(equal(testLanguage));
+ expect(testStruct.keyboardLayout).to(equal(testLayout));
+ expect(testStruct.keypressMode).to(equal(testMode));
+ expect(testStruct.limitedCharacterList).to(equal(testLimitedCharacterList));
+ expect(testStruct.autoCompleteText).to(equal(testAutoCompleteText));
+ expect(testStruct.autoCompleteList).to(equal(testAutoCompleteList));
+ });
+
+ it(@"Should get correctly when initialized with initWithLanguage:layout:keypressMode:limitedCharacterList:autoCompleteText:autoCompleteList:", ^ {
+ SDLKeyboardProperties *testStruct = [[SDLKeyboardProperties alloc] initWithLanguage:testLanguage layout:testLayout keypressMode:testMode limitedCharacterList:testLimitedCharacterList autoCompleteText:testAutoCompleteText autoCompleteList:testAutoCompleteList];
+
expect(testStruct.language).to(equal(testLanguage));
expect(testStruct.keyboardLayout).to(equal(testLayout));
expect(testStruct.keypressMode).to(equal(testMode));
diff --git a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLLightControlCapabilitiesSpec.m b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLLightControlCapabilitiesSpec.m
index 404dc2aeb..82ffd22cf 100644
--- a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLLightControlCapabilitiesSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLLightControlCapabilitiesSpec.m
@@ -48,18 +48,6 @@ describe(@"Getter/Setter Tests", ^ {
});
it(@"Should set and get correctly", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLLightControlCapabilities* testStruct = [[SDLLightControlCapabilities alloc] initWithModuleName:@"moduleName" supportedLights:[@[somelightCapabilities] copy]];
-#pragma clang diagnostic pop
-
- expect(testStruct.moduleName).to(equal(@"moduleName"));
- expect(testStruct.moduleInfo).to(beNil());
- expect(testStruct.supportedLights).to(equal([@[somelightCapabilities] copy]));
-
- });
-
- it(@"Should set and get correctly", ^ {
SDLLightControlCapabilities* testStruct = [[SDLLightControlCapabilities alloc] initWithModuleName:@"moduleName" moduleInfo:testModuleInfo supportedLights:[@[somelightCapabilities] copy]];
expect(testStruct.moduleName).to(equal(@"moduleName"));
@@ -69,14 +57,11 @@ describe(@"Getter/Setter Tests", ^ {
});
it(@"Should get correctly when initialized", ^ {
- NSMutableDictionary* dict = [@{SDLRPCParameterNameModuleName:@"moduleName",
+ NSDictionary *dict = @{SDLRPCParameterNameModuleName:@"moduleName",
SDLRPCParameterNameModuleInfo:testModuleInfo,
SDLRPCParameterNameSupportedLights:[@[somelightCapabilities] copy]
- } mutableCopy];
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLLightControlCapabilities* testStruct = [[SDLLightControlCapabilities alloc] initWithDictionary:dict];
-#pragma clang diagnostic pop
+ };
+ SDLLightControlCapabilities *testStruct = [[SDLLightControlCapabilities alloc] initWithDictionary:dict];
expect(testStruct.moduleName).to(equal(@"moduleName"));
expect(testStruct.moduleInfo).to(equal(testModuleInfo));
diff --git a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLMediaServiceDataSpec.m b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLMediaServiceDataSpec.m
index 24a215b11..37bc5b867 100644
--- a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLMediaServiceDataSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLMediaServiceDataSpec.m
@@ -87,32 +87,9 @@ describe(@"Getter/Setter Tests", ^{
SDLRPCParameterNameQueueCurrentTrackNumber:@(testQueueCurrentTrackNumber),
SDLRPCParameterNameQueueTotalTrackCount:@(testQueueTotalTrackCount)
};
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
SDLMediaServiceData *testStruct = [[SDLMediaServiceData alloc] initWithDictionary:dict];
-#pragma clang diagnostic pop
-
- expect(testStruct.mediaImage).to(equal(testMediaImage));
- expect(testStruct.mediaType).to(equal(testMediaType));
- expect(testStruct.mediaTitle).to(equal(testMediaTitle));
- expect(testStruct.mediaArtist).to(equal(testMediaArtist));
- expect(testStruct.mediaAlbum).to(equal(testMediaAlbum));
- expect(testStruct.playlistName).to(equal(testPlaylistName));
- expect(testStruct.isExplicit).to(equal(testIsExplicit));
- expect(testStruct.trackPlaybackProgress).to(equal(testTrackPlaybackProgress));
- expect(testStruct.trackPlaybackDuration).to(equal(testTrackPlaybackDuration));
- expect(testStruct.queuePlaybackProgress).to(equal(testQueuePlaybackProgress));
- expect(testStruct.queuePlaybackDuration).to(equal(testQueuePlaybackDuration));
- expect(testStruct.queueCurrentTrackNumber).to(equal(testQueueCurrentTrackNumber));
- expect(testStruct.queueTotalTrackCount).to(equal(testQueueTotalTrackCount));
- });
-
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- it(@"Should get correctly when initialized with initWithMediaType:mediaTitle:mediaArtist:mediaAlbum:playlistName:isExplicit:trackPlaybackProgress:trackPlaybackDuration:queuePlaybackProgress:queuePlaybackDuration:queueCurrentTrackNumber:queueTotalTrackCount:", ^{
- SDLMediaServiceData *testStruct = [[SDLMediaServiceData alloc] initWithMediaType:testMediaType mediaTitle:testMediaTitle mediaArtist:testMediaArtist mediaAlbum:testMediaAlbum playlistName:testPlaylistName isExplicit:testIsExplicit trackPlaybackProgress:testTrackPlaybackProgress trackPlaybackDuration:testTrackPlaybackDuration queuePlaybackProgress:testQueuePlaybackProgress queuePlaybackDuration:testQueuePlaybackDuration queueCurrentTrackNumber:testQueueCurrentTrackNumber queueTotalTrackCount:testQueueTotalTrackCount];
-#pragma clang diagnostic pop
+ expect(testStruct.mediaImage).to(equal(testMediaImage));
expect(testStruct.mediaType).to(equal(testMediaType));
expect(testStruct.mediaTitle).to(equal(testMediaTitle));
expect(testStruct.mediaArtist).to(equal(testMediaArtist));
@@ -125,7 +102,6 @@ describe(@"Getter/Setter Tests", ^{
expect(testStruct.queuePlaybackDuration).to(equal(testQueuePlaybackDuration));
expect(testStruct.queueCurrentTrackNumber).to(equal(testQueueCurrentTrackNumber));
expect(testStruct.queueTotalTrackCount).to(equal(testQueueTotalTrackCount));
- expect(testStruct.mediaImage).to(beNil());
});
it(@"Should get correctly when initialized with initWithMediaType:mediaImage:mediaTitle:mediaArtist:mediaAlbum:playlistName:isExplicit:trackPlaybackProgress:trackPlaybackDuration:queuePlaybackProgress:queuePlaybackDuration:queueCurrentTrackNumber:queueTotalTrackCount:", ^{
diff --git a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLRadioControlCapabilitiesSpec.m b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLRadioControlCapabilitiesSpec.m
index bd7aed6b1..8d3584096 100644
--- a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLRadioControlCapabilitiesSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLRadioControlCapabilitiesSpec.m
@@ -54,12 +54,11 @@ describe(@"Initialization tests", ^{
expect(testStruct.hdRadioEnableAvailable).to(beNil());
expect(testStruct.siriusXMRadioAvailable).to(beNil());
expect(testStruct.sisDataAvailable).to(beNil());
-
});
it(@"should properly initialize initWithDictionary", ^{
- NSMutableDictionary* dict = [@{SDLRPCParameterNameModuleName : @"someName",
+ NSDictionary *dict = @{SDLRPCParameterNameModuleName : @"someName",
SDLRPCParameterNameModuleInfo: testModuleInfo,
SDLRPCParameterNameRadioEnableAvailable : @YES,
SDLRPCParameterNameRadioBandAvailable : @YES,
@@ -74,12 +73,9 @@ describe(@"Initialization tests", ^{
SDLRPCParameterNameHDRadioEnableAvailable : @YES,
SDLRPCParameterNameSiriusXMRadioAvailable : @NO,
SDLRPCParameterNameSISDataAvailable: @YES
- } mutableCopy];
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLRadioControlCapabilities* testStruct = [[SDLRadioControlCapabilities alloc] initWithDictionary:dict];
-#pragma clang diagnostic pop
-
+ };
+ SDLRadioControlCapabilities *testStruct = [[SDLRadioControlCapabilities alloc] initWithDictionary:dict];
+
expect(testStruct.moduleName).to(equal(@"someName"));
expect(testStruct.moduleInfo).to(equal(testModuleInfo));
expect(testStruct.radioEnableAvailable).to(equal(@YES));
@@ -100,7 +96,6 @@ describe(@"Initialization tests", ^{
expect(testStruct.hdRadioEnableAvailable).to(equal(@YES));
expect(testStruct.siriusXMRadioAvailable).to(equal(@NO));
expect(testStruct.sisDataAvailable).to(equal(@YES));
-
});
it(@"Should set and get correctly", ^{
@@ -147,7 +142,6 @@ describe(@"Initialization tests", ^{
expect(testStruct.hdRadioEnableAvailable).to(equal(@YES));
expect(testStruct.siriusXMRadioAvailable).to(equal(@YES));
expect(testStruct.sisDataAvailable).to(equal(@YES));
-
});
it(@"Should get correctly when initialized with Module Name and other radio control capabilite's parameters", ^ {
@@ -167,61 +161,7 @@ describe(@"Initialization tests", ^{
expect(testStruct.hdRadioEnableAvailable).to(equal(YES));
expect(testStruct.siriusXMRadioAvailable).to(equal(@YES));
expect(testStruct.sisDataAvailable).to(equal(@YES));
-
- });
-
- it(@"Should get correctly when initialized with Module Name and other radio control capability parameters", ^ {
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLRadioControlCapabilities* testStruct = [[SDLRadioControlCapabilities alloc] initWithModuleName:@"someName" radioEnableAvailable:YES radioBandAvailable:NO radioFrequencyAvailable:YES hdChannelAvailable:NO rdsDataAvailable:NO availableHDsAvailable:NO stateAvailable:YES signalStrengthAvailable:YES signalChangeThresholdAvailable:NO];
-
- expect(testStruct.moduleName).to(equal(@"someName"));
- expect(testStruct.moduleInfo).to(beNil());
- expect(testStruct.radioEnableAvailable).to(equal(@YES));
- expect(testStruct.radioBandAvailable).to(equal(@NO));
- expect(testStruct.radioFrequencyAvailable).to(equal(@YES));
- expect(testStruct.hdChannelAvailable).to(equal(@NO));
- expect(testStruct.rdsDataAvailable).to(equal(@NO));
- expect(testStruct.availableHDsAvailable).to(equal(@NO));
- expect(testStruct.stateAvailable).to(equal(@YES));
- expect(testStruct.signalStrengthAvailable).to(equal(@YES));
- expect(testStruct.signalChangeThresholdAvailable).to(equal(@NO));
- expect(testStruct.hdRadioEnableAvailable).to(equal(@NO));
- expect(testStruct.siriusXMRadioAvailable).to(equal(@NO));
- #pragma clang diagnostic pop
});
-
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- it(@"Should get correctly when initialized with Module Name and other radio control capabilite's parameters", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLRadioControlCapabilities* testStruct = [[SDLRadioControlCapabilities alloc] initWithModuleName:@"someName" radioEnableAvailable:YES radioBandAvailable:NO radioFrequencyAvailable:YES hdChannelAvailable:NO rdsDataAvailable:NO availableHDsAvailable:NO stateAvailable:YES signalStrengthAvailable:YES signalChangeThresholdAvailable:NO hdRadioEnableAvailable:YES siriusXMRadioAvailable:YES sisDataAvailable:YES];
-#pragma clang diagnostic pop
-
-
- expect(testStruct.moduleName).to(equal(@"someName"));
- expect(testStruct.moduleInfo).to(beNil());
- expect(testStruct.radioEnableAvailable).to(equal(@YES));
- expect(testStruct.radioBandAvailable).to(equal(@NO));
- expect(testStruct.radioFrequencyAvailable).to(equal(@YES));
- expect(testStruct.hdChannelAvailable).to(equal(@NO));
- expect(testStruct.rdsDataAvailable).to(equal(@NO));
-
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- expect(testStruct.availableHDsAvailable).to(equal(@NO));
-#pragma clang diagnostic pop
-
- expect(testStruct.stateAvailable).to(equal(@YES));
- expect(testStruct.signalStrengthAvailable).to(equal(@YES));
- expect(testStruct.signalChangeThresholdAvailable).to(equal(@NO));
- expect(testStruct.hdRadioEnableAvailable).to(equal(YES));
- expect(testStruct.siriusXMRadioAvailable).to(equal(@YES));
- expect(testStruct.sisDataAvailable).to(equal(@YES));
-
- });
-
});
QuickSpecEnd
diff --git a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLRadioControlDataSpec.m b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLRadioControlDataSpec.m
index a29ff574d..c8fb5b773 100644
--- a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLRadioControlDataSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLRadioControlDataSpec.m
@@ -16,7 +16,8 @@
#import "SDLRPCParameterNames.h"
QuickSpecBegin(SDLRadioControlDataSpec)
-__block SDLRDSData* someRdsData = [[SDLRDSData alloc] init];
+__block SDLRDSData *someRdsData = [[SDLRDSData alloc] init];
+__block SDLSISData *testSISData = [[SDLSISData alloc] init];
describe(@"Initialization tests", ^{
@@ -38,10 +39,11 @@ describe(@"Initialization tests", ^{
expect(testStruct.radioEnable).to(beNil());
expect(testStruct.state).to(beNil());
expect(testStruct.hdRadioEnable).to(beNil());
+ expect(testStruct.sisData).to(beNil());
});
it(@"should properly initialize initWithDictionary", ^{
- NSMutableDictionary* dict = [@{SDLRPCParameterNameFrequencyInteger : @101,
+ NSDictionary *dict = @{SDLRPCParameterNameFrequencyInteger : @101,
SDLRPCParameterNameFrequencyFraction : @7,
SDLRPCParameterNameBand : SDLRadioBandAM,
SDLRPCParameterNameRDSData : someRdsData,
@@ -52,13 +54,11 @@ describe(@"Initialization tests", ^{
SDLRPCParameterNameSignalChangeThreshold : @76,
SDLRPCParameterNameRadioEnable : @YES,
SDLRPCParameterNameState : SDLRadioStateNotFound,
- SDLRPCParameterNameHDRadioEnable : @NO
- } mutableCopy];
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLRadioControlData* testStruct = [[SDLRadioControlData alloc] initWithDictionary:dict];
-#pragma clang diagnostic pop
-
+ SDLRPCParameterNameHDRadioEnable : @NO,
+ SDLRPCParameterNameSISData : testSISData
+ };
+ SDLRadioControlData *testStruct = [[SDLRadioControlData alloc] initWithDictionary:dict];
+
expect(testStruct.frequencyInteger).to(equal(@101));
expect(testStruct.frequencyFraction).to(equal(@7));
expect(testStruct.band).to(equal(SDLRadioBandAM));
@@ -73,6 +73,7 @@ describe(@"Initialization tests", ^{
expect(testStruct.radioEnable).to(equal(@YES));
expect(testStruct.state).to(equal(SDLRadioStateNotFound));
expect(testStruct.hdRadioEnable).to(equal(@NO));
+ expect(testStruct.sisData).to(equal(testSISData));
});
it(@"Should set and get correctly", ^{
@@ -89,6 +90,7 @@ describe(@"Initialization tests", ^{
testStruct.radioEnable = @YES;
testStruct.state = SDLRadioStateNotFound;
testStruct.hdRadioEnable = @YES;
+ testStruct.sisData = testSISData;
expect(testStruct.frequencyInteger).to(equal(@101));
expect(testStruct.frequencyFraction).to(equal(@7));
@@ -102,50 +104,11 @@ describe(@"Initialization tests", ^{
expect(testStruct.radioEnable).to(equal(@YES));
expect(testStruct.state).to(equal(SDLRadioStateNotFound));
expect(testStruct.hdRadioEnable).to(equal(@YES));
- });
-
- it(@"Should get correctly when initialized with Module Name and other radio control capabilities parameters", ^ {
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLRadioControlData* testStruct = [[SDLRadioControlData alloc] initWithFrequencyInteger:@101 frequencyFraction:@7 band:SDLRadioBandAM hdChannel:@2 radioEnable:@YES];
-
- expect(testStruct.frequencyInteger).to(equal(@101));
- expect(testStruct.frequencyFraction).to(equal(@7));
- expect(testStruct.band).to(equal(SDLRadioBandAM));
- expect(testStruct.hdChannel).to(equal(@2));
- expect(testStruct.radioEnable).to(equal(@YES));
- #pragma clang diagnostic pop
+ expect(testStruct.sisData).to(equal(testSISData));
});
it(@"Should get correctly when initialized with Module Name and other radio control capabilities parameters", ^ {
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLRadioControlData* testStruct = [[SDLRadioControlData alloc] initWithFrequencyInteger:@101 frequencyFraction:@7 band:SDLRadioBandAM hdChannel:@2 radioEnable:@YES];
-
- expect(testStruct.frequencyInteger).to(equal(@101));
- expect(testStruct.frequencyFraction).to(equal(@7));
- expect(testStruct.band).to(equal(SDLRadioBandAM));
- expect(testStruct.hdChannel).to(equal(@2));
- expect(testStruct.radioEnable).to(equal(@YES));
- #pragma clang diagnostic pop
- });
-
- it(@"Should get correctly when initialized with Module Name and other radio control capabilities parameters", ^ {
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLRadioControlData* testStruct = [[SDLRadioControlData alloc] initWithFrequencyInteger:@101 frequencyFraction:@7 band:SDLRadioBandAM hdChannel:@2 radioEnable:@YES];
-
- expect(testStruct.frequencyInteger).to(equal(@101));
- expect(testStruct.frequencyFraction).to(equal(@7));
- expect(testStruct.band).to(equal(SDLRadioBandAM));
- expect(testStruct.hdChannel).to(equal(@2));
- expect(testStruct.radioEnable).to(equal(@YES));
- expect(testStruct.sisData).to(beNil());
- #pragma clang diagnostic pop
- });
-
- it(@"Should get correctly when initialized with Module Name and other radio control capabilities parameters", ^ {
- SDLRadioControlData* testStruct = [[SDLRadioControlData alloc] initWithFrequencyInteger:@101 frequencyFraction:@7 band:SDLRadioBandAM hdChannel:@2 radioEnable:@YES hdRadioEnable:@YES];
+ SDLRadioControlData *testStruct = [[SDLRadioControlData alloc] initWithFrequencyInteger:@101 frequencyFraction:@7 band:SDLRadioBandAM hdChannel:@2 radioEnable:@YES hdRadioEnable:@YES];
expect(testStruct.frequencyInteger).to(equal(@101));
expect(testStruct.frequencyFraction).to(equal(@7));
@@ -178,9 +141,6 @@ describe(@"Initialization tests", ^{
expect(testStruct.frequencyInteger).to(equal(@101));
expect(testStruct.band).to(equal(SDLRadioBandXM));
});
-
-
-
});
QuickSpecEnd
diff --git a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLRemoteControlCapabilitiesSpec.m b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLRemoteControlCapabilitiesSpec.m
index fb914d85c..464d5048c 100644
--- a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLRemoteControlCapabilitiesSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLRemoteControlCapabilitiesSpec.m
@@ -87,18 +87,6 @@ describe(@"Initialization tests", ^{
});
it(@"Should get correctly when initialized with climateControlCapabilities and other RemoteControlCapabilities parameters", ^ {
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLRemoteControlCapabilities* testStruct = [[SDLRemoteControlCapabilities alloc] initWithClimateControlCapabilities:[@[someClimateControlCapabilities] copy] radioControlCapabilities:[@[someRadioControlCapabilities] copy] buttonCapabilities:[@[someButtonControlCapabilities] copy]];
-
- expect(testStruct.seatControlCapabilities).to(beNil());
- expect(testStruct.climateControlCapabilities).to(equal(([@[someClimateControlCapabilities] copy])));
- expect(testStruct.radioControlCapabilities).to(equal([@[someRadioControlCapabilities] copy]));
- expect(testStruct.buttonCapabilities).to(equal([@[someButtonControlCapabilities] copy]));
- #pragma clang diagnostic pop
- });
-
- it(@"Should get correctly when initialized with climateControlCapabilities and other RemoteControlCapabilities parameters", ^ {
SDLRemoteControlCapabilities* testStruct = [[SDLRemoteControlCapabilities alloc] initWithClimateControlCapabilities:[@[someClimateControlCapabilities] copy] radioControlCapabilities:[@[someRadioControlCapabilities] copy] buttonCapabilities:[@[someButtonControlCapabilities] copy] seatControlCapabilities:[@[someSeatControlCapabilities] copy] audioControlCapabilities:[@[someAudioControlCapabilities] copy] hmiSettingsControlCapabilities:[@[someHMISettingsControlCapabilities] copy] lightControlCapabilities:[@[someLightControlCapabilities] copy]];
expect(testStruct.climateControlCapabilities).to(equal(([@[someClimateControlCapabilities] copy])));
diff --git a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLSeatControlCapabilitiesSpec.m b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLSeatControlCapabilitiesSpec.m
index 31912578d..f31908ba6 100644
--- a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLSeatControlCapabilitiesSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLSeatControlCapabilitiesSpec.m
@@ -71,59 +71,6 @@ describe(@"Getter/Setter Tests", ^ {
expect(testStruct.massageModeAvailable).to(equal(@YES));
expect(testStruct.massageCushionFirmnessAvailable).to(equal(@NO));
expect(testStruct.memoryAvailable).to(equal(@NO));
-
- });
-
- it(@"Should set and get correctly", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLSeatControlCapabilities* testStruct = [[SDLSeatControlCapabilities alloc] initWithName:@"moduleName" heatingEnabledAvailable:YES coolingEnabledAvailable:NO heatingLevelAvailable:YES coolingLevelAvailable:NO horizontalPositionAvailable:NO verticalPositionAvailable:NO frontVerticalPositionAvailable:NO backVerticalPositionAvailable:NO backTiltAngleAvailable:YES headSupportHorizontalPositionAvailable:NO headSupportVerticalPositionAvailable:YES massageEnabledAvailable:NO massageModeAvailable:YES massageCushionFirmnessAvailable:NO memoryAvailable:YES];
-#pragma clang diagnostic pop
-
- expect(testStruct.moduleName).to(equal(@"moduleName"));
- expect(testStruct.moduleInfo).to(beNil());
- expect(testStruct.heatingEnabledAvailable).to(equal(@YES));
- expect(testStruct.coolingEnabledAvailable).to(equal(@NO));
- expect(testStruct.heatingLevelAvailable).to(equal(@YES));
- expect(testStruct.coolingLevelAvailable).to(equal(@NO));
- expect(testStruct.horizontalPositionAvailable).to(equal(@NO));
- expect(testStruct.verticalPositionAvailable).to(equal(@NO));
- expect(testStruct.frontVerticalPositionAvailable).to(equal(@NO));
- expect(testStruct.backVerticalPositionAvailable).to(equal(@NO));
- expect(testStruct.backTiltAngleAvailable).to(equal(@YES));
- expect(testStruct.headSupportHorizontalPositionAvailable).to(equal(@NO));
- expect(testStruct.headSupportVerticalPositionAvailable).to(equal(@YES));
- expect(testStruct.massageEnabledAvailable).to(equal(@NO));
- expect(testStruct.massageModeAvailable).to(equal(@YES));
- expect(testStruct.massageCushionFirmnessAvailable).to(equal(@NO));
- expect(testStruct.memoryAvailable).to(equal(@YES));
-
- });
-
- it(@"Should set and get correctly", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLSeatControlCapabilities* testStruct = [[SDLSeatControlCapabilities alloc] initWithName:@"moduleName"];
-#pragma clang diagnostic pop
-
- expect(testStruct.moduleName).to(equal(@"moduleName"));
- expect(testStruct.moduleInfo).to(beNil());
- expect(testStruct.heatingEnabledAvailable).to(beNil());
- expect(testStruct.heatingEnabledAvailable).to(beNil());
- expect(testStruct.heatingLevelAvailable).to(beNil());
- expect(testStruct.coolingLevelAvailable).to(beNil());
- expect(testStruct.horizontalPositionAvailable).to(beNil());
- expect(testStruct.verticalPositionAvailable).to(beNil());
- expect(testStruct.frontVerticalPositionAvailable).to(beNil());
- expect(testStruct.backVerticalPositionAvailable).to(beNil());
- expect(testStruct.backTiltAngleAvailable).to(beNil());
- expect(testStruct.headSupportHorizontalPositionAvailable).to(beNil());
- expect(testStruct.headSupportVerticalPositionAvailable).to(beNil());
- expect(testStruct.massageEnabledAvailable).to(beNil());
- expect(testStruct.massageModeAvailable).to(beNil());
- expect(testStruct.massageCushionFirmnessAvailable).to(beNil());
- expect(testStruct.memoryAvailable).to(beNil());
-
});
it(@"Should set and get correctly", ^ {
@@ -146,7 +93,6 @@ describe(@"Getter/Setter Tests", ^ {
expect(testStruct.massageModeAvailable).to(beNil());
expect(testStruct.massageCushionFirmnessAvailable).to(beNil());
expect(testStruct.memoryAvailable).to(beNil());
-
});
it(@"Should set and get correctly", ^ {
diff --git a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLSeatControlDataSpec.m b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLSeatControlDataSpec.m
index ee3a4638e..d6e4f368e 100644
--- a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLSeatControlDataSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLSeatControlDataSpec.m
@@ -17,15 +17,19 @@
QuickSpecBegin(SDLSeatControlDataSpec)
-SDLMassageCushionFirmness* massageCushionFirmness = [[SDLMassageCushionFirmness alloc] init];
+SDLMassageCushionFirmness *massageCushionFirmness = [[SDLMassageCushionFirmness alloc] init];
SDLMassageModeData *massageModeData = [[SDLMassageModeData alloc] init];
SDLSeatMemoryAction *seatMemoryAction = [[SDLSeatMemoryAction alloc] init];
describe(@"Getter/Setter Tests", ^ {
it(@"Should set and get correctly", ^ {
- SDLSeatControlData* testStruct = [[SDLSeatControlData alloc] init];
+ SDLSeatControlData *testStruct = [[SDLSeatControlData alloc] init];
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wdeprecated-declarations"
testStruct.id = SDLSupportedSeatDriver;
+#pragma clang diagnostic pop
+
testStruct.heatingEnabled = @NO;
testStruct.coolingEnabled = @YES;
testStruct.heatingLevel = @25;
@@ -41,11 +45,14 @@ describe(@"Getter/Setter Tests", ^ {
testStruct.headSupportVerticalPosition = @43;
testStruct.massageEnabled = @YES;
- testStruct.massageMode = [@[massageModeData] copy];
- testStruct.massageCushionFirmness = [@[massageCushionFirmness] copy];
+ testStruct.massageMode = @[massageModeData];
+ testStruct.massageCushionFirmness = @[massageCushionFirmness];
testStruct.memory = seatMemoryAction;
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wdeprecated-declarations"
expect(testStruct.id).to(equal(SDLSupportedSeatDriver));
+#pragma clang diagnostic pop
expect(testStruct.heatingEnabled).to(equal(@NO));
expect(testStruct.coolingEnabled).to(equal(@YES));
expect(testStruct.heatingLevel).to(equal(@25));
@@ -58,16 +65,45 @@ describe(@"Getter/Setter Tests", ^ {
expect(testStruct.headSupportHorizontalPosition).to(equal(@3));
expect(testStruct.headSupportVerticalPosition).to(equal(@43));
expect(testStruct.massageEnabled).to(equal(@YES));
- expect(testStruct.massageMode).to(equal([@[massageModeData] copy]));
- expect(testStruct.massageCushionFirmness).to(equal([@[massageCushionFirmness] copy]));
+ expect(testStruct.massageMode).to(equal(@[massageModeData]));
+ expect(testStruct.massageCushionFirmness).to(equal(@[massageCushionFirmness]));
expect(testStruct.memory).to(equal(seatMemoryAction));
+ });
+
+ it(@"Should get correctly when initialized with initWithHeatingEnabled:coolingEnabled:heatingLevel:coolingLevel:horizontalPosition:verticalPosition:frontVerticalPosition:backVerticalPosition:backTiltAngle:headSupportHorizontalPosition:headSupportVerticalPosition:massageEnabled:massageMode:massageCushionFirmness:memory:", ^ {
+ SDLSeatControlData *testStruct = [[SDLSeatControlData alloc] initWithHeatingEnabled:@NO coolingEnabled:@YES heatingLevel:@25 coolingLevel:@10 horizontalPosition:@23 verticalPosition:@25 frontVerticalPosition:@12 backVerticalPosition:@25 backTiltAngle:@2 headSupportHorizontalPosition:@3 headSupportVerticalPosition:@43 massageEnabled:@YES massageMode:@[massageModeData] massageCushionFirmness:@[massageCushionFirmness] memory:seatMemoryAction];
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wdeprecated-declarations"
+ expect(testStruct.id).to(beNil());
+#pragma clang diagnostic pop
+ expect(testStruct.heatingEnabled).to(equal(@NO));
+ expect(testStruct.coolingEnabled).to(equal(@YES));
+ expect(testStruct.heatingLevel).to(equal(@25));
+ expect(testStruct.coolingLevel).to(equal(@10));
+ expect(testStruct.horizontalPosition).to(equal(@23));
+ expect(testStruct.verticalPosition).to(equal(@25));
+ expect(testStruct.frontVerticalPosition).to(equal(@12));
+ expect(testStruct.backVerticalPosition).to(equal(@25));
+ expect(testStruct.backTiltAngle).to(equal(@2));
+ expect(testStruct.headSupportHorizontalPosition).to(equal(@3));
+ expect(testStruct.headSupportVerticalPosition).to(equal(@43));
+ expect(testStruct.massageEnabled).to(equal(@YES));
+ expect(testStruct.massageMode).to(equal(@[massageModeData]));
+ expect(testStruct.massageCushionFirmness).to(equal(@[massageCushionFirmness]));
+ expect(testStruct.memory).to(equal(seatMemoryAction));
});
- it(@"Should set and get correctly", ^ {
- SDLSeatControlData* testStruct = [[SDLSeatControlData alloc] initWithId:SDLSupportedSeatDriver heatingEnabled:NO coolingEnable:YES heatingLevel:25 coolingLevel:10 horizontalPostion:23 verticalPostion:25 frontVerticalPostion:12 backVerticalPostion:25 backTiltAngle:2 headSupportedHorizontalPostion:3 headSupportedVerticalPostion:43 massageEnabled:YES massageMode:[@[massageModeData] copy] massageCussionFirmness:[@[massageCushionFirmness] copy] memory:seatMemoryAction];
+ it(@"Should get correctly when initialized with initWithId:heatingEnabled:coolingEnable:heatingLevel:coolingLevel:horizontalPostion:verticalPostion:frontVerticalPostion:backVerticalPostion:backTiltAngle: headSupportedHorizontalPostion:headSupportedVerticalPostion:massageEnabled:massageMode:massageCussionFirmness:memory:", ^ {
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wdeprecated-declarations"
+ SDLSeatControlData *testStruct = [[SDLSeatControlData alloc] initWithId:SDLSupportedSeatDriver heatingEnabled:NO coolingEnable:YES heatingLevel:25 coolingLevel:10 horizontalPostion:23 verticalPostion:25 frontVerticalPostion:12 backVerticalPostion:25 backTiltAngle:2 headSupportedHorizontalPostion:3 headSupportedVerticalPostion:43 massageEnabled:YES massageMode:@[massageModeData] massageCussionFirmness:@[massageCushionFirmness] memory:seatMemoryAction];
+#pragma clang diagnostic pop
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wdeprecated-declarations"
expect(testStruct.id).to(equal(SDLSupportedSeatDriver));
+#pragma clang diagnostic pop
expect(testStruct.heatingEnabled).to(equal(@NO));
expect(testStruct.coolingEnabled).to(equal(@YES));
expect(testStruct.heatingLevel).to(equal(@25));
@@ -80,16 +116,21 @@ describe(@"Getter/Setter Tests", ^ {
expect(testStruct.headSupportHorizontalPosition).to(equal(@3));
expect(testStruct.headSupportVerticalPosition).to(equal(@43));
expect(testStruct.massageEnabled).to(equal(@YES));
- expect(testStruct.massageMode).to(equal([@[massageModeData] copy]));
- expect(testStruct.massageCushionFirmness).to(equal([@[massageCushionFirmness] copy]));
+ expect(testStruct.massageMode).to(equal(@[massageModeData]));
+ expect(testStruct.massageCushionFirmness).to(equal(@[massageCushionFirmness]));
expect(testStruct.memory).to(equal(seatMemoryAction));
-
});
- it(@"Should set and get correctly", ^ {
- SDLSeatControlData* testStruct = [[SDLSeatControlData alloc] initWithId:SDLSupportedSeatDriver];
+ it(@"Should get correctly when initialized with initWithId:", ^ {
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wdeprecated-declarations"
+ SDLSeatControlData *testStruct = [[SDLSeatControlData alloc] initWithId:SDLSupportedSeatDriver];
+#pragma clang diagnostic pop
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wdeprecated-declarations"
expect(testStruct.id).to(equal(SDLSupportedSeatDriver));
+#pragma clang diagnostic pop
expect(testStruct.heatingEnabled).to(beNil());
expect(testStruct.coolingEnabled).to(beNil());
expect(testStruct.heatingLevel).to(beNil());
@@ -108,8 +149,10 @@ describe(@"Getter/Setter Tests", ^ {
});
- it(@"Should get correctly when initialized", ^ {
- NSMutableDictionary* dict = [@{SDLRPCParameterNameId:SDLSupportedSeatDriver,
+ it(@"Should get correctly when initialized with a dictionary", ^ {
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wdeprecated-declarations"
+ NSDictionary *dict = @{SDLRPCParameterNameId:SDLSupportedSeatDriver,
SDLRPCParameterNameHeatingEnabled:@NO,
SDLRPCParameterNameCoolingEnabled:@YES,
SDLRPCParameterNameHeatingLevel:@25,
@@ -122,16 +165,18 @@ describe(@"Getter/Setter Tests", ^ {
SDLRPCParameterNameHeadSupportHorizontalPosition:@3,
SDLRPCParameterNameHeadSupportVerticalPosition:@43,
SDLRPCParameterNameMassageEnabled:@YES,
- SDLRPCParameterNameMassageMode:[@[massageModeData] mutableCopy],
- SDLRPCParameterNameMassageCushionFirmness:[@[massageCushionFirmness] mutableCopy],
+ SDLRPCParameterNameMassageMode:@[massageModeData],
+ SDLRPCParameterNameMassageCushionFirmness:@[massageCushionFirmness],
SDLRPCParameterNameMemory:seatMemoryAction
- } mutableCopy];
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLSeatControlData *testStruct = [[SDLSeatControlData alloc] initWithDictionary:dict];
+ };
#pragma clang diagnostic pop
+ SDLSeatControlData *testStruct = [[SDLSeatControlData alloc] initWithDictionary:dict];
+
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wdeprecated-declarations"
expect(testStruct.id).to(equal(SDLSupportedSeatDriver));
+#pragma clang diagnostic pop
expect(testStruct.heatingEnabled).to(equal(@NO));
expect(testStruct.coolingEnabled).to(equal(@YES));
expect(testStruct.heatingLevel).to(equal(@25));
@@ -144,15 +189,18 @@ describe(@"Getter/Setter Tests", ^ {
expect(testStruct.headSupportHorizontalPosition).to(equal(@3));
expect(testStruct.headSupportVerticalPosition).to(equal(@43));
expect(testStruct.massageEnabled).to(equal(@YES));
- expect(testStruct.massageMode).to(equal([@[massageModeData] mutableCopy]));
- expect(testStruct.massageCushionFirmness).to(equal([@[massageCushionFirmness] mutableCopy]));
+ expect(testStruct.massageMode).to(equal(@[massageModeData]));
+ expect(testStruct.massageCushionFirmness).to(equal(@[massageCushionFirmness]));
expect(testStruct.memory).to(equal(seatMemoryAction));
});
it(@"Should return nil if not set", ^ {
- SDLSeatControlData* testStruct = [[SDLSeatControlData alloc] init];
+ SDLSeatControlData *testStruct = [[SDLSeatControlData alloc] init];
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wdeprecated-declarations"
expect(testStruct.id).to(beNil());
+#pragma clang diagnostic pop
expect(testStruct.heatingEnabled).to(beNil());
expect(testStruct.coolingEnabled).to(beNil());
expect(testStruct.heatingLevel).to(beNil());
diff --git a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLSyncMsgVersionSpec.m b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLSyncMsgVersionSpec.m
deleted file mode 100644
index 7e4458fca..000000000
--- a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLSyncMsgVersionSpec.m
+++ /dev/null
@@ -1,59 +0,0 @@
-//
-// SDLSyncMsgVersionSpec.m
-// SmartDeviceLink
-
-
-#import <Foundation/Foundation.h>
-
-#import <Quick/Quick.h>
-#import <Nimble/Nimble.h>
-
-#import "SDLSyncMsgVersion.h"
-#import "SDLRPCParameterNames.h"
-
-QuickSpecBegin(SDLSyncMsgVersionSpec)
-
-describe(@"Getter/Setter Tests", ^ {
- it(@"Should set and get correctly", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLSyncMsgVersion* testStruct = [[SDLSyncMsgVersion alloc] init];
-#pragma clang diagnostic pop
-
- testStruct.majorVersion = @4;
- testStruct.minorVersion = @532;
- testStruct.patchVersion = @12;
-
- expect(testStruct.majorVersion).to(equal(@4));
- expect(testStruct.minorVersion).to(equal(@532));
- expect(testStruct.patchVersion).to(equal(@12));
- });
-
- it(@"Should get correctly when initialized", ^ {
- NSMutableDictionary* dict = [@{SDLRPCParameterNameMajorVersion:@4,
- SDLRPCParameterNameMinorVersion:@532,
- SDLRPCParameterNamePatchVersion:@12} mutableCopy];
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLSyncMsgVersion* testStruct = [[SDLSyncMsgVersion alloc] initWithDictionary:dict];
-#pragma clang diagnostic pop
-
- expect(testStruct.majorVersion).to(equal(@4));
- expect(testStruct.minorVersion).to(equal(@532));
- expect(testStruct.patchVersion).to(equal(@12));
- });
-
- it(@"Should return nil if not set", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLSyncMsgVersion* testStruct = [[SDLSyncMsgVersion alloc] init];
-#pragma clang diagnostic pop
-
-
- expect(testStruct.majorVersion).to(beNil());
- expect(testStruct.minorVersion).to(beNil());
- expect(testStruct.patchVersion).to(beNil());
- });
-});
-
-QuickSpecEnd
diff --git a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLVideoStreamingCapabilitySpec.m b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLVideoStreamingCapabilitySpec.m
index 5cbb03022..857a05d61 100644
--- a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLVideoStreamingCapabilitySpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLVideoStreamingCapabilitySpec.m
@@ -89,21 +89,6 @@ describe(@"Initialization tests", ^{
expect(testStruct.pixelPerInch).to(equal(testPixelPerInch));
expect(testStruct.scale).to(equal(testScale));
});
-
- it(@"Should initialize correctly with deprecated initWithPreferredResolution:maxBitrate:supportedFormats:hapticDataSupported", ^ {
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLVideoStreamingCapability *testStruct = [[SDLVideoStreamingCapability alloc] initWithPreferredResolution:testPreferredResolution maxBitrate:testMaxBitrate supportedFormats:testVideoStreamingFormats hapticDataSupported:testHapticDataSupported];
- #pragma clang diagnostic pop
-
- expect(testStruct.preferredResolution).to(equal(testPreferredResolution));
- expect(testStruct.maxBitrate).to(equal(testMaxBitrate));
- expect(testStruct.supportedFormats).to(equal(testVideoStreamingFormats));
- expect(testStruct.hapticSpatialDataSupported).to(equal(testHapticDataSupported));
- expect(testStruct.diagonalScreenSize).to(beNil());
- expect(testStruct.pixelPerInch).to(beNil());
- expect(testStruct.scale).to(beNil());
- });
});
QuickSpecEnd
diff --git a/SmartDeviceLinkTests/RPCSpecs/SuperclassSpecs/SDLRPCMessageSpec.m b/SmartDeviceLinkTests/RPCSpecs/SuperclassSpecs/SDLRPCMessageSpec.m
index c6ebbe9dc..f1baa88fc 100644
--- a/SmartDeviceLinkTests/RPCSpecs/SuperclassSpecs/SDLRPCMessageSpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/SuperclassSpecs/SDLRPCMessageSpec.m
@@ -13,139 +13,85 @@
QuickSpecBegin(SDLRPCMessageSpec)
-describe(@"Readonly Property Tests", ^ {
- it(@"Should get name correctly when initialized with name", ^ {
+describe(@"Getter/Setter Tests", ^ {
+ __block NSString *testRPCName = @"Test RPC Name";
+ __block NSString *testNameKey = @"firstName";
+ __block NSString *testNameValue = @"George";
+ __block NSString *testAgeKey = @"age";
+ __block NSNumber *testAgeValue = @25;
+ const char *testString = "ImportantData";
+ __block NSData *testBulkData = nil;
+
+ beforeEach(^{
+ testBulkData = [NSData dataWithBytes:testString length:strlen(testString)];;
+ });
+
+ it(@"should get correctly when initialized with initWithName:", ^ {
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLRPCMessage* testMessage = [[SDLRPCMessage alloc] initWithName:@"Poorly Named"];
+ SDLRPCMessage *testMessage = [[SDLRPCMessage alloc] initWithName:testRPCName];
#pragma clang diagnostic pop
- expect(testMessage.name).to(equal(@"Poorly Named"));
+ expect(testMessage.name).to(equal(testRPCName));
+ expect(testMessage.parameters).to(beEmpty());
+ expect(testMessage.bulkData).to(beNil());
+ expect(testMessage.messageType).to(equal(SDLRPCParameterNameRequest));
});
- it(@"Should get correctly when initialized with dictionary", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLRPCMessage* testMessage = [[SDLRPCMessage alloc] initWithDictionary:[@{SDLRPCParameterNameNotification:
- @{SDLRPCParameterNameParameters:
- @{@"name":@"George"},
- SDLRPCParameterNameOperationName:@"Poorly Named"}} mutableCopy]];
-#pragma clang diagnostic pop
-
- expect(testMessage.name).to(equal(@"Poorly Named"));
+ it(@"should get correctly when initialized with a dictionary", ^ {
+ NSDictionary *dict = @{SDLRPCParameterNameNotification:
+ @{SDLRPCParameterNameParameters:
+ @{testNameKey:testNameValue,
+ testAgeKey:testAgeValue,
+ },
+ SDLRPCParameterNameOperationName:testRPCName
+ },
+ SDLRPCParameterNameBulkData:testBulkData,
+ };
+ SDLRPCMessage *testMessage = [[SDLRPCMessage alloc] initWithDictionary:dict];
+
+ expect(testMessage.name).to(equal(testRPCName));
+ expect(testMessage.parameters[testNameKey]).to(equal(testNameValue));
+ expect(testMessage.parameters[testAgeKey]).to(equal(testAgeValue));
+ expect(testMessage.bulkData).to(equal(testBulkData));
+ expect([NSString stringWithUTF8String:testMessage.bulkData.bytes]).to(equal([NSString stringWithUTF8String:testBulkData.bytes]));
expect(testMessage.messageType).to(equal(SDLRPCParameterNameNotification));
});
-});
-describe(@"Parameter Tests", ^ {
- it(@"Should set and get correctly", ^ {
+ it(@"should set and get correctly", ^ {
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLRPCMessage* testMessage = [[SDLRPCMessage alloc] initWithName:@""];
-
- [testMessage setParameters:@"ADogAPanicInAPagoda" value:@"adogaPAnIcinaPAgoDA"];
- expect([testMessage getParameters:@"ADogAPanicInAPagoda"]).to(equal(@"adogaPAnIcinaPAgoDA"));
+ SDLRPCMessage *testMessage = [[SDLRPCMessage alloc] initWithName:testRPCName];
#pragma clang diagnostic pop
- expect(testMessage.parameters[@"ADogAPanicInAPagoda"]).to(equal(@"adogaPAnIcinaPAgoDA"));
- });
-
- it(@"Should get correctly when initialized", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLRPCMessage* testMessage = [[SDLRPCMessage alloc] initWithDictionary:[@{SDLRPCParameterNameResponse:
- @{SDLRPCParameterNameParameters:
- @{@"age":@25},
- SDLRPCParameterNameOperationName:@"Nameless"}} mutableCopy]];
-#pragma clang diagnostic pop
-
- expect(testMessage.parameters[@"age"]).to(equal(@25));
- });
-
- it(@"Should be nil if not set", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLRPCMessage* testMessage = [[SDLRPCMessage alloc] initWithName:@""];
-
- expect(testMessage.parameters[@"ADogAPanicInAPagoda"]).to(beNil());
-#pragma clang diagnostic pop
- });
-});
+ testMessage.parameters[testAgeKey] = testAgeValue;
+ testMessage.parameters[testNameKey] = testNameValue;
+ testMessage.bulkData = testBulkData;
-describe(@"FunctionName Tests", ^ {
- it(@"Should set and get correctly", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLRPCMessage* testMessage = [[SDLRPCMessage alloc] initWithName:@""];
-
- [testMessage setFunctionName:@"Functioning"];
-#pragma clang diagnostic pop
-
- expect(testMessage.name).to(equal(@"Functioning"));
+ expect(testMessage.name).to(equal(testRPCName));
+ expect(testMessage.parameters[testAgeKey]).to(equal(testAgeValue));
+ expect(testMessage.parameters[testNameKey]).to(equal(testNameValue));
+ expect(testMessage.bulkData).to(equal(testBulkData));
+ expect([NSString stringWithUTF8String:testMessage.bulkData.bytes]).to(equal([NSString stringWithUTF8String:testBulkData.bytes]));
+ expect(testMessage.messageType).to(equal(SDLRPCParameterNameRequest));
});
-
- it(@"Should get correctly when initialized", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLRPCMessage* testMessage = [[SDLRPCMessage alloc] initWithDictionary:[@{SDLRPCParameterNameRequest:
- @{SDLRPCParameterNameParameters:
- @{@"age":@25},
- SDLRPCParameterNameOperationName:@"DoNothing"}} mutableCopy]];
-#pragma clang diagnostic pop
-
- expect(testMessage.name).to(equal(@"DoNothing"));
+ it(@"should set and get correctly with setter methods", ^ {
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- testMessage = [[SDLRPCMessage alloc] initWithName:@"DoSomething"];
+ SDLRPCMessage *testMessage = [[SDLRPCMessage alloc] initWithName:@""];
+ [testMessage setFunctionName:testRPCName];
+ [testMessage setParameters:testAgeKey value:testAgeValue];
+ [testMessage setParameters:testNameKey value:testNameValue];
+ [testMessage setBulkData:testBulkData];
#pragma clang diagnostic pop
-
- expect(testMessage.name).to(equal(@"DoSomething"));
- });
-
- it(@"Should be nil if not set", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLRPCMessage* testMessage = [[SDLRPCMessage alloc] initWithDictionary:[@{SDLRPCParameterNameNotification:
- @{SDLRPCParameterNameParameters:
- @{}}} mutableCopy]];
-#pragma clang diagnostic pop
- expect(testMessage.name).to(beNil());
- });
-});
-describe(@"BulkDataTests", ^ {
- it(@"Should set and get correctly", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLRPCMessage* testMessage = [[SDLRPCMessage alloc] initWithName:@""];
-#pragma clang diagnostic pop
-
- const char* testString = "ImportantData";
- testMessage.bulkData = [NSData dataWithBytes:testString length:strlen(testString)];
-
- expect([NSString stringWithUTF8String:testMessage.bulkData.bytes]).to(equal(@"ImportantData"));
- });
-
- it(@"Should get correctly when initialized", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLRPCMessage* testMessage = [[SDLRPCMessage alloc] initWithDictionary:[@{SDLRPCParameterNameNotification:
- @{SDLRPCParameterNameParameters:
- @{}},
- SDLRPCParameterNameBulkData:[NSData dataWithBytes:"ImageData" length:strlen("ImageData")]} mutableCopy]];
-#pragma clang diagnostic pop
-
- expect(testMessage.bulkData).to(equal([NSData dataWithBytes:"ImageData" length:strlen("ImageData")]));
- });
-
- it(@"Should be nil if not set", ^ {
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLRPCMessage* testMessage = [[SDLRPCMessage alloc] initWithName:@""];
-#pragma clang diagnostic pop
-
- expect(testMessage.bulkData).to(beNil());
+ expect(testMessage.name).to(equal(testRPCName));
+ expect(testMessage.parameters[testAgeKey]).to(equal(testAgeValue));
+ expect(testMessage.parameters[testNameKey]).to(equal(testNameValue));
+ expect(testMessage.bulkData).to(equal(testBulkData));
+ expect([NSString stringWithUTF8String:testMessage.bulkData.bytes]).to(equal([NSString stringWithUTF8String:testBulkData.bytes]));
+ expect(testMessage.messageType).to(equal(SDLRPCParameterNameRequest));
});
});
diff --git a/SmartDeviceLinkTests/SDLOnLockScreenStatusSpec.m b/SmartDeviceLinkTests/SDLOnLockScreenStatusSpec.m
new file mode 100644
index 000000000..d23891f7d
--- /dev/null
+++ b/SmartDeviceLinkTests/SDLOnLockScreenStatusSpec.m
@@ -0,0 +1,53 @@
+//
+// SDLLockScreenStatusInfoSpec.m
+// SmartDeviceLink
+
+
+#import <Quick/Quick.h>
+#import <Nimble/Nimble.h>
+
+#import "SDLLockScreenStatusInfo.h"
+#import "SDLHMILevel.h"
+#import "SDLRPCParameterNames.h"
+
+QuickSpecBegin(SDLLockScreenStatusInfoSpec)
+
+describe(@"Getter/Setter Tests", ^ {
+ __block bool testDriverDistractionStatus = NO;
+ __block int testUserSelected = 3;
+ __block SDLLockScreenStatus testLockScreenStatus = SDLLockScreenStatusOptional;
+ __block SDLHMILevel testHMILevel = SDLHMILevelBackground;
+
+ it(@"Should set and get correctly", ^ {
+ SDLLockScreenStatusInfo *testNotification = [[SDLLockScreenStatusInfo alloc] init];
+ testNotification.driverDistractionStatus = @(testDriverDistractionStatus);
+ testNotification.userSelected = @(testUserSelected);
+ testNotification.lockScreenStatus = testLockScreenStatus;
+ testNotification.hmiLevel = testHMILevel;
+
+ expect(testNotification.driverDistractionStatus).to(beFalse());
+ expect(testNotification.userSelected).to(equal(testUserSelected));
+ expect(@(testNotification.lockScreenStatus)).to(equal(testLockScreenStatus));
+ expect(testNotification.hmiLevel).to(equal(testHMILevel));
+ });
+
+ it(@"Should init correctly with initWithDriverDistractionStatus:serSelected:lockScreenStatus:hmiLevel:", ^ {
+ SDLLockScreenStatusInfo *testNotification = [[SDLLockScreenStatusInfo alloc] initWithDriverDistractionStatus:@(testDriverDistractionStatus) userSelected:@(testUserSelected) lockScreenStatus:testLockScreenStatus hmiLevel:testHMILevel];
+
+ expect(testNotification.driverDistractionStatus).to(beFalse());
+ expect(testNotification.userSelected).to(equal(testUserSelected));
+ expect(@(testNotification.lockScreenStatus)).to(equal(testLockScreenStatus));
+ expect(testNotification.hmiLevel).to(equal(testHMILevel));
+ });
+
+ it(@"Should return the default values if not set", ^ {
+ SDLLockScreenStatusInfo *testNotification = [[SDLLockScreenStatusInfo alloc] init];
+
+ expect(testNotification.driverDistractionStatus).to(beNil());
+ expect(testNotification.userSelected).to(beNil());
+ expect(@(testNotification.lockScreenStatus)).to(equal(SDLLockScreenStatusOff));
+ expect(testNotification.hmiLevel).to(beNil());
+ });
+});
+
+QuickSpecEnd
diff --git a/SmartDeviceLinkTests/SDLSystemCapabilityManagerSpec.m b/SmartDeviceLinkTests/SDLSystemCapabilityManagerSpec.m
index 69cf46202..d07586e7e 100644
--- a/SmartDeviceLinkTests/SDLSystemCapabilityManagerSpec.m
+++ b/SmartDeviceLinkTests/SDLSystemCapabilityManagerSpec.m
@@ -665,14 +665,11 @@ describe(@"System capability manager", ^{
__block TestSystemCapabilityObserver *navigationObserver = nil;
__block TestSystemCapabilityObserver *videoStreamingObserver = nil;
__block TestSystemCapabilityObserver *displaysObserver = nil;
-
- __block NSUInteger observerTriggeredCount = 0;
__block NSUInteger handlerTriggeredCount = 0;
beforeEach(^{
testSystemCapabilityManager.currentHMILevel = SDLHMILevelFull;
- observerTriggeredCount = 0;
handlerTriggeredCount = 0;
[SDLGlobals sharedGlobals].rpcVersion = [SDLVersion versionWithString:@"5.1.0"]; // supports subscriptions
@@ -701,17 +698,9 @@ describe(@"System capability manager", ^{
});
context(@"from a GetSystemCapabilitiesResponse", ^{
- __block id blockObserver = nil;
__block id handlerObserver = nil;
beforeEach(^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- blockObserver = [testSystemCapabilityManager subscribeToCapabilityType:SDLSystemCapabilityTypePhoneCall withBlock:^(SDLSystemCapability * _Nonnull systemCapability) {
- observerTriggeredCount++;
- }];
-#pragma clang diagnostic pop
-
handlerObserver = [testSystemCapabilityManager subscribeToCapabilityType:SDLSystemCapabilityTypePhoneCall withUpdateHandler:^(SDLSystemCapability * _Nullable capability, BOOL subscribed, NSError * _Nullable error) {
handlerTriggeredCount++;
}];
@@ -725,7 +714,6 @@ describe(@"System capability manager", ^{
it(@"should not notify subscribers of new data because it was sent outside of the SCM", ^{
expect(handlerTriggeredCount).toEventually(equal(1));
- expect(observerTriggeredCount).toEventually(equal(1));
expect(phoneObserver.selectorCalledCount).toEventually(equal(0));
expect(navigationObserver.selectorCalledCount).toEventually(equal(0));
@@ -743,7 +731,6 @@ describe(@"System capability manager", ^{
beforeEach(^{
[testSystemCapabilityManager unsubscribeFromCapabilityType:SDLSystemCapabilityTypePhoneCall withObserver:phoneObserver];
[testSystemCapabilityManager unsubscribeFromCapabilityType:SDLSystemCapabilityTypePhoneCall withObserver:handlerObserver];
- [testSystemCapabilityManager unsubscribeFromCapabilityType:SDLSystemCapabilityTypePhoneCall withObserver:blockObserver];
SDLGetSystemCapabilityResponse *testResponse = [[SDLGetSystemCapabilityResponse alloc] init];
testResponse.systemCapability = [[SDLSystemCapability alloc] initWithPhoneCapability:[[SDLPhoneCapability alloc] initWithDialNumber:YES]];
@@ -754,7 +741,6 @@ describe(@"System capability manager", ^{
it(@"should not notify the subscriber of the new data", ^{
expect(handlerTriggeredCount).toEventually(equal(1));
- expect(observerTriggeredCount).toEventually(equal(1));
expect(phoneObserver.selectorCalledCount).toEventually(equal(0)); // No change from above
expect(navigationObserver.selectorCalledCount).toEventually(equal(0));
@@ -766,17 +752,9 @@ describe(@"System capability manager", ^{
});
context(@"from an OnSystemCapabilities notification", ^{
- __block id blockObserver = nil;
__block id handlerObserver = nil;
beforeEach(^{
-#pragma clang diagnostic push
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
- blockObserver = [testSystemCapabilityManager subscribeToCapabilityType:SDLSystemCapabilityTypePhoneCall withBlock:^(SDLSystemCapability * _Nonnull systemCapability) {
- observerTriggeredCount++;
- }];
-#pragma clang diagnostic pop
-
handlerObserver = [testSystemCapabilityManager subscribeToCapabilityType:SDLSystemCapabilityTypePhoneCall withUpdateHandler:^(SDLSystemCapability * _Nullable capability, BOOL subscribed, NSError * _Nullable error) {
handlerTriggeredCount++;
}];
@@ -789,7 +767,6 @@ describe(@"System capability manager", ^{
it(@"should notify subscribers of the new data", ^{
expect(handlerTriggeredCount).toEventually(equal(2));
- expect(observerTriggeredCount).toEventually(equal(2));
expect(phoneObserver.selectorCalledCount).toEventually(equal(1));
expect(navigationObserver.selectorCalledCount).toEventually(equal(0));
@@ -806,7 +783,6 @@ describe(@"System capability manager", ^{
describe(@"unsubscribing", ^{
beforeEach(^{
[testSystemCapabilityManager unsubscribeFromCapabilityType:SDLSystemCapabilityTypePhoneCall withObserver:phoneObserver];
- [testSystemCapabilityManager unsubscribeFromCapabilityType:SDLSystemCapabilityTypePhoneCall withObserver:blockObserver];
SDLGetSystemCapabilityResponse *testResponse = [[SDLGetSystemCapabilityResponse alloc] init];
testResponse.systemCapability = [[SDLSystemCapability alloc] initWithPhoneCapability:[[SDLPhoneCapability alloc] initWithDialNumber:YES]];
@@ -817,7 +793,6 @@ describe(@"System capability manager", ^{
it(@"should not notify the subscriber of the new data", ^{
expect(phoneObserver.selectorCalledCount).toEventually(equal(1)); // No change from above
- expect(observerTriggeredCount).toEventually(equal(2));
expect(navigationObserver.selectorCalledCount).toEventually(equal(0));
expect(videoStreamingObserver.selectorCalledCount).toEventually(equal(0));
expect(displaysObserver.selectorCalledCount).toEventually(equal(1));
@@ -854,16 +829,16 @@ describe(@"System capability manager", ^{
describe(@"when sending the merge update", ^{
it(@"should correctly merge", ^{
- deleteCapability.updateReason = SDLServiceUpdateRemoved;
+ deleteCapability.updateReason = SDLServiceUpdateReasonRemoved;
deleteCapability.updatedAppServiceRecord.servicePublished = @NO;
deleteCapability.updatedAppServiceRecord.serviceActive = @NO;
- updateCapability.updateReason = SDLServiceUpdateActivated;
+ updateCapability.updateReason = SDLServiceUpdateReasonActivated;
updateCapability.updatedAppServiceRecord.serviceActive = @YES;
SDLAppServiceManifest *newCapabilityManifest = [[SDLAppServiceManifest alloc] initWithMediaServiceName:@"New me" serviceIcon:nil allowAppConsumers:YES maxRPCSpecVersion:nil handledRPCs:nil mediaServiceManifest:[[SDLMediaServiceManifest alloc] init]];
SDLAppServiceRecord *newCapabilityRecord = [[SDLAppServiceRecord alloc] initWithServiceID:@"3456" serviceManifest:newCapabilityManifest servicePublished:YES serviceActive:NO];
- newCapability = [[SDLAppServiceCapability alloc] initWithUpdateReason:SDLServiceUpdatePublished updatedAppServiceRecord:newCapabilityRecord];
+ newCapability = [[SDLAppServiceCapability alloc] initWithUpdateReason:SDLServiceUpdateReasonPublished updatedAppServiceRecord:newCapabilityRecord];
SDLAppServicesCapabilities *appServicesUpdate = [[SDLAppServicesCapabilities alloc] initWithAppServices:@[deleteCapability, updateCapability, newCapability]];
SDLSystemCapability *appServiceCapability = [[SDLSystemCapability alloc] initWithAppServicesCapabilities:appServicesUpdate];
@@ -877,10 +852,10 @@ describe(@"System capability manager", ^{
SDLAppServiceCapability *firstCapability = testSystemCapabilityManager.appServicesCapabilities.appServices.firstObject;
SDLAppServiceCapability *secondCapability = testSystemCapabilityManager.appServicesCapabilities.appServices.lastObject;
- expect(firstCapability.updateReason).to(equal(SDLServiceUpdatePublished));
+ expect(firstCapability.updateReason).to(equal(SDLServiceUpdateReasonPublished));
expect(firstCapability.updatedAppServiceRecord.serviceID).to(equal(@"3456"));
- expect(secondCapability.updateReason).to(equal(SDLServiceUpdateActivated));
+ expect(secondCapability.updateReason).to(equal(SDLServiceUpdateReasonActivated));
expect(secondCapability.updatedAppServiceRecord.serviceID).to(equal(@"2345"));
expect(secondCapability.updatedAppServiceRecord.serviceActive).to(beTrue());
});
diff --git a/SmartDeviceLinkTests/TestHapticRectViewController.h b/SmartDeviceLinkTests/TestHapticRectViewController.h
new file mode 100644
index 000000000..ccb656551
--- /dev/null
+++ b/SmartDeviceLinkTests/TestHapticRectViewController.h
@@ -0,0 +1,18 @@
+//
+// TestHapticRectViewController.h
+// SmartDeviceLinkTests
+//
+// Created by Nicole on 9/1/20.
+// Copyright © 2020 smartdevicelink. All rights reserved.
+//
+
+#import <UIKit/UIKit.h>
+
+NS_ASSUME_NONNULL_BEGIN
+
+/// Test view controller for testing the SDLFocusableItemLocator's preferredFocusEnvironments
+@interface TestHapticRectViewController : UIViewController
+
+@end
+
+NS_ASSUME_NONNULL_END
diff --git a/SmartDeviceLinkTests/TestHapticRectViewController.m b/SmartDeviceLinkTests/TestHapticRectViewController.m
new file mode 100644
index 000000000..2dd346429
--- /dev/null
+++ b/SmartDeviceLinkTests/TestHapticRectViewController.m
@@ -0,0 +1,38 @@
+//
+// TestHapticRectViewController.m
+// SmartDeviceLinkTests
+//
+// Created by Nicole on 9/1/20.
+// Copyright © 2020 smartdevicelink. All rights reserved.
+//
+
+#import "TestHapticRectViewController.h"
+
+@interface TestHapticRectViewController ()
+
+@end
+
+@implementation TestHapticRectViewController
+
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wdeprecated-implementations"
+- (UIView *)preferredFocusedView {
+ return (UIView *)self.preferredFocusEnvironments.firstObject;
+}
+#pragma clang diagnostic pop
+
+/// Return the subviews sorted by their tag values in acending order
+- (NSArray<id<UIFocusEnvironment>> *)preferredFocusEnvironments {
+ NSArray<UIView *> *subViews = self.view.subviews;
+
+ NSArray *preferredFocusViews;
+ preferredFocusViews = [subViews sortedArrayUsingComparator:^NSComparisonResult(id a, id b) {
+ NSNumber *first = [NSNumber numberWithLong:[(UIView*)a tag]];
+ NSNumber *second = [NSNumber numberWithLong:[(UIView*)b tag]];
+ return [first compare:second];
+ }];
+
+ return preferredFocusViews;
+}
+
+@end
diff --git a/SmartDeviceLinkTests/UtilitiesSpecs/Touches/SDLTouchManagerSpec.m b/SmartDeviceLinkTests/UtilitiesSpecs/Touches/SDLTouchManagerSpec.m
index a138cbd92..42db9c3fc 100644
--- a/SmartDeviceLinkTests/UtilitiesSpecs/Touches/SDLTouchManagerSpec.m
+++ b/SmartDeviceLinkTests/UtilitiesSpecs/Touches/SDLTouchManagerSpec.m
@@ -91,19 +91,6 @@ describe(@"SDLTouchManager Tests", ^{
__block SDLTouchManager *touchManager = nil;
context(@"initializing", ^{
- it(@"Should initialize correctly with initWithHitTester", ^{
- #pragma clang diagnostic push
- #pragma clang diagnostic ignored "-Wdeprecated-declarations"
- SDLTouchManager *touchManager = [[SDLTouchManager alloc] initWithHitTester:nil];
- #pragma clang diagnostic pop
- expect(touchManager.touchEventDelegate).to(beNil());
- expect(@(touchManager.tapDistanceThreshold)).to(equal(@50));
- expect(@(touchManager.tapTimeThreshold)).to(beCloseTo(@0.4).within(0.0001));
- expect(@(touchManager.isTouchEnabled)).to(beTruthy());
- expect(touchManager.videoScaleManager.scale).to(equal(1.0));
- expect(@(CGRectEqualToRect(touchManager.videoScaleManager.appViewportFrame, CGRectZero))).to(beTrue());
- });
-
it(@"Should initialize correctly with initWithHitTester:videoScaleManager:", ^{
SDLTouchManager *touchManager = [[SDLTouchManager alloc] initWithHitTester:nil videoScaleManager:[[SDLStreamingVideoScaleManager alloc] init]];
expect(touchManager.touchEventDelegate).to(beNil());
diff --git a/generator/templates/base_struct_function.m.jinja2 b/generator/templates/base_struct_function.m.jinja2
index ee17b5ccf..4294858d4 100644
--- a/generator/templates/base_struct_function.m.jinja2
+++ b/generator/templates/base_struct_function.m.jinja2
@@ -2,8 +2,6 @@
"templates/functions/template.m" and "templates/structs/template.m". -#}
{% include 'copyright.jinja2' %}
{%- block imports %}
-#import "{{name}}.h"
-#import "NSMutableDictionary+Store.h"
{%- for import in imports %}
#import "{{import}}.h"
{%- endfor %}
diff --git a/generator/templates/functions/template.m.jinja2 b/generator/templates/functions/template.m.jinja2
index 9809b8df2..a8871754e 100644
--- a/generator/templates/functions/template.m.jinja2
+++ b/generator/templates/functions/template.m.jinja2
@@ -2,8 +2,6 @@
{% extends "base_struct_function.m.jinja2" %}
{% block imports %}
{{super()}}
-#import "SDLRPCFunctionNames.h"
-#import "SDLRPCParameterNames.h"
{%- endblock %}
{% block constructors %}
#pragma clang diagnostic push
diff --git a/generator/templates/structs/template.m.jinja2 b/generator/templates/structs/template.m.jinja2
index 488b076af..0e538c3ea 100644
--- a/generator/templates/structs/template.m.jinja2
+++ b/generator/templates/structs/template.m.jinja2
@@ -2,6 +2,5 @@
{% extends "base_struct_function.m.jinja2" %}
{% block imports %}
{{super()}}
-#import "SDLRPCParameterNames.h"
{%- endblock %}
{% set parameters_store = 'store' %} \ No newline at end of file
diff --git a/generator/transformers/common_producer.py b/generator/transformers/common_producer.py
index 16adea071..f3ac8c5bd 100644
--- a/generator/transformers/common_producer.py
+++ b/generator/transformers/common_producer.py
@@ -49,6 +49,11 @@ class InterfaceProducerCommon(ABC):
:param render: dictionary with pre filled entries, which going to be filled/changed by reference
:return: dictionary which going to be applied to Jinja2 template
"""
+
+ importsKey = 'imports'
+ enumKey = 'enum'
+ structKey = 'struct'
+
if item.description:
render['description'] = self.extract_description(item.description)
if item.since:
@@ -64,6 +69,28 @@ class InterfaceProducerCommon(ABC):
render['params'][param.name] = self.extract_param(param, item.name)
if isinstance(item, (Struct, Function)):
self.extract_imports(param, render['imports'])
+
+ # Add additional known imports to the import list
+ if isinstance(item, (Struct, Function)):
+ name = 'SDL' + item.name
+ render[importsKey]['.m'].add( "NSMutableDictionary+Store" )
+ render[importsKey]['.m'].add(name)
+ render[importsKey]['.h'][enumKey] = list(render[importsKey]['.h'][enumKey])
+ (render[importsKey]['.h'][enumKey]).sort()
+ render[importsKey]['.h'][structKey] = list(render[importsKey]['.h'][structKey])
+ (render[importsKey]['.h'][structKey]).sort()
+
+ if isinstance(item, Struct):
+ name = 'SDL' + item.name
+ render[importsKey]['.m'].add( "SDLRPCParameterNames" )
+
+ if isinstance(item, Function):
+ render[importsKey]['.m'].add( "SDLRPCFunctionNames" )
+ render[importsKey]['.m'].add( "SDLRPCParameterNames" )
+
+ # Sort the import list to ensure they appear in alphabetical order in the template
+ render[importsKey]['.m'] = list(render[importsKey]['.m'])
+ (render[importsKey]['.m']).sort()
if 'constructors' not in render and isinstance(item, (Struct, Function)):
render['constructors'] = self.extract_constructors(render['params'])