summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoel Fischer <joeljfischer@gmail.com>2017-08-23 15:52:49 -0400
committerGitHub <noreply@github.com>2017-08-23 15:52:49 -0400
commita674dd924dfbf6772b250716a3b03620d8162805 (patch)
treee45ecc8e5f59c3f1aa39e48b484389475f90ea21
parent2a68f4bfd314211c79b9e5eb893f1d8de954f944 (diff)
parentfb22009e08ddc3b2af91319c94b4ffc32bc64289 (diff)
downloadsdl_ios-a674dd924dfbf6772b250716a3b03620d8162805.tar.gz
Merge pull request #685 from smartdevicelink/feature/SDL_0075_OEM_specific_HID_support_5.0
Implement SDL 0075 OEM Specific Human Interface Device v5.0
-rw-r--r--SmartDeviceLink-iOS.podspec3
-rw-r--r--SmartDeviceLink-iOS.xcodeproj/project.pbxproj48
-rw-r--r--SmartDeviceLink.podspec3
-rw-r--r--SmartDeviceLink/SDLFunctionID.m1
-rw-r--r--SmartDeviceLink/SDLHapticRect.h34
-rw-r--r--SmartDeviceLink/SDLHapticRect.m48
-rw-r--r--SmartDeviceLink/SDLNames.h6
-rw-r--r--SmartDeviceLink/SDLNames.m6
-rw-r--r--SmartDeviceLink/SDLNotificationConstants.h1
-rw-r--r--SmartDeviceLink/SDLNotificationConstants.m2
-rw-r--r--SmartDeviceLink/SDLNotificationDispatcher.m4
-rw-r--r--SmartDeviceLink/SDLProxyListener.h2
-rw-r--r--SmartDeviceLink/SDLRectangle.h56
-rw-r--r--SmartDeviceLink/SDLRectangle.m63
-rw-r--r--SmartDeviceLink/SDLSendHapticData.h37
-rw-r--r--SmartDeviceLink/SDLSendHapticData.m44
-rw-r--r--SmartDeviceLink/SDLSendHapticDataResponse.h19
-rw-r--r--SmartDeviceLink/SDLSendHapticDataResponse.m25
-rw-r--r--SmartDeviceLink/SDLVideoStreamingCapability.h6
-rw-r--r--SmartDeviceLink/SDLVideoStreamingCapability.m11
-rw-r--r--SmartDeviceLink/SmartDeviceLink.h4
-rw-r--r--SmartDeviceLinkTests/DevAPISpecs/SDLNotificationDispatcherSpec.m1
-rw-r--r--SmartDeviceLinkTests/ProtocolSpecs/SDLFunctionIDSpec.m4
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLSendHapticDataSpec.m62
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/ResponseSpecs/SDLSendHapticDataResponseSpec.m19
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLHapticRectSpec.m69
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLRectangleSpec.m58
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLSystemCapabilitySpec.m4
-rw-r--r--SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLVideoStreamingCapabilitySpec.m11
-rw-r--r--SmartDeviceLink_Example/Classes/ProxyManager.m7
30 files changed, 650 insertions, 8 deletions
diff --git a/SmartDeviceLink-iOS.podspec b/SmartDeviceLink-iOS.podspec
index e9021321c..98a358b92 100644
--- a/SmartDeviceLink-iOS.podspec
+++ b/SmartDeviceLink-iOS.podspec
@@ -104,6 +104,7 @@ ss.public_header_files = [
'SmartDeviceLink/SDLGetWaypointsResponse.h',
'SmartDeviceLink/SDLGlobalProperty.h',
'SmartDeviceLink/SDLGPSData.h',
+'SmartDeviceLink/SDLHapticRect.h',
'SmartDeviceLink/SDLHeadLampStatus.h',
'SmartDeviceLink/SDLHMICapabilities.h',
'SmartDeviceLink/SDLHMILevel.h',
@@ -222,6 +223,8 @@ ss.public_header_files = [
'SmartDeviceLink/SDLScrollableMessage.h',
'SmartDeviceLink/SDLScrollableMessageResponse.h',
'SmartDeviceLink/SDLSecurityType.h',
+'SmartDeviceLink/SDLSendHapticData.h',
+'SmartDeviceLink/SDLSendHapticDataResponse.h',
'SmartDeviceLink/SDLSendLocation.h',
'SmartDeviceLink/SDLSendLocationResponse.h',
'SmartDeviceLink/SDLSetAppIcon.h',
diff --git a/SmartDeviceLink-iOS.xcodeproj/project.pbxproj b/SmartDeviceLink-iOS.xcodeproj/project.pbxproj
index e85688fa3..6d3ced899 100644
--- a/SmartDeviceLink-iOS.xcodeproj/project.pbxproj
+++ b/SmartDeviceLink-iOS.xcodeproj/project.pbxproj
@@ -875,6 +875,9 @@
5DA49CE61F1EA83300E65FC5 /* SDLControlFramePayloadRPCStartService.m in Sources */ = {isa = PBXBuildFile; fileRef = 5DA49CE41F1EA83300E65FC5 /* SDLControlFramePayloadRPCStartService.m */; };
5DA8A0E91E955F710039C50D /* SDLStreamingMediaManagerConstants.m in Sources */ = {isa = PBXBuildFile; fileRef = DA8966F31E56977C00413EAB /* SDLStreamingMediaManagerConstants.m */; };
5DA8A0EA1E955FE00039C50D /* SDLLogModel.m in Sources */ = {isa = PBXBuildFile; fileRef = 5DBF06301E64A9C600A5CF03 /* SDLLogModel.m */; };
+ 5DADA7751F4DFED60084D17D /* SDLRectangle.h in Headers */ = {isa = PBXBuildFile; fileRef = 5DADA7731F4DFED60084D17D /* SDLRectangle.h */; settings = {ATTRIBUTES = (Public, ); }; };
+ 5DADA7761F4DFED60084D17D /* SDLRectangle.m in Sources */ = {isa = PBXBuildFile; fileRef = 5DADA7741F4DFED60084D17D /* SDLRectangle.m */; };
+ 5DADA7781F4E059E0084D17D /* SDLRectangleSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 5DADA7771F4E059E0084D17D /* SDLRectangleSpec.m */; };
5DAE06731BDEC6C000F9B498 /* SDLFileSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 5DAE06721BDEC6C000F9B498 /* SDLFileSpec.m */; };
5DAE06751BDEC6D600F9B498 /* SDLArtworkSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 5DAE06741BDEC6D600F9B498 /* SDLArtworkSpec.m */; };
5DB1BCD31D243A8E002FFC37 /* SDLDeleteFileOperationSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 5DB1BCD01D243A8E002FFC37 /* SDLDeleteFileOperationSpec.m */; };
@@ -939,6 +942,15 @@
5DE5ABB71B0E38C90067BB02 /* SDLSystemRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = 5D61FBD21A84238B00846EE7 /* SDLSystemRequest.h */; };
5DE5ABB81B0E38C90067BB02 /* SDLSystemRequestResponse.h in Headers */ = {isa = PBXBuildFile; fileRef = 5D61FBD41A84238B00846EE7 /* SDLSystemRequestResponse.h */; };
5DFFB9151BD7C89700DB3F04 /* SDLConnectionManagerType.h in Headers */ = {isa = PBXBuildFile; fileRef = 5DFFB9141BD7C89700DB3F04 /* SDLConnectionManagerType.h */; };
+ 8877F5EB1F34A3BE00DC128A /* SDLSendHapticDataSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 8877F5EA1F34A3BE00DC128A /* SDLSendHapticDataSpec.m */; };
+ 8877F5EE1F34A72200DC128A /* SDLSendHapticDataResponse.h in Headers */ = {isa = PBXBuildFile; fileRef = 8877F5EC1F34A72200DC128A /* SDLSendHapticDataResponse.h */; settings = {ATTRIBUTES = (Public, ); }; };
+ 8877F5EF1F34A72200DC128A /* SDLSendHapticDataResponse.m in Sources */ = {isa = PBXBuildFile; fileRef = 8877F5ED1F34A72200DC128A /* SDLSendHapticDataResponse.m */; };
+ 8877F5F11F34AA2D00DC128A /* SDLSendHapticDataResponseSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 8877F5F01F34AA2D00DC128A /* SDLSendHapticDataResponseSpec.m */; };
+ 88EED8381F33AE1700E6C42E /* SDLHapticRect.h in Headers */ = {isa = PBXBuildFile; fileRef = 88EED8361F33AE1700E6C42E /* SDLHapticRect.h */; settings = {ATTRIBUTES = (Public, ); }; };
+ 88EED8391F33AE1700E6C42E /* SDLHapticRect.m in Sources */ = {isa = PBXBuildFile; fileRef = 88EED8371F33AE1700E6C42E /* SDLHapticRect.m */; };
+ 88EED83B1F33BECB00E6C42E /* SDLHapticRectSpec.m in Sources */ = {isa = PBXBuildFile; fileRef = 88EED83A1F33BECB00E6C42E /* SDLHapticRectSpec.m */; };
+ 88EED83E1F33C5A400E6C42E /* SDLSendHapticData.h in Headers */ = {isa = PBXBuildFile; fileRef = 88EED83C1F33C5A400E6C42E /* SDLSendHapticData.h */; settings = {ATTRIBUTES = (Public, ); }; };
+ 88EED83F1F33C5A400E6C42E /* SDLSendHapticData.m in Sources */ = {isa = PBXBuildFile; fileRef = 88EED83D1F33C5A400E6C42E /* SDLSendHapticData.m */; };
8B7B319A1F2F7B5700BDC38D /* SDLVideoStreamingCodec.h in Headers */ = {isa = PBXBuildFile; fileRef = 8B7B31981F2F7B5700BDC38D /* SDLVideoStreamingCodec.h */; settings = {ATTRIBUTES = (Public, ); }; };
8B7B319B1F2F7B5700BDC38D /* SDLVideoStreamingCodec.m in Sources */ = {isa = PBXBuildFile; fileRef = 8B7B31991F2F7B5700BDC38D /* SDLVideoStreamingCodec.m */; };
8B7B319E1F2F7CF700BDC38D /* SDLVideoStreamingProtocol.h in Headers */ = {isa = PBXBuildFile; fileRef = 8B7B319C1F2F7CF700BDC38D /* SDLVideoStreamingProtocol.h */; settings = {ATTRIBUTES = (Public, ); }; };
@@ -1994,6 +2006,9 @@
5DA3F36F1BC4489A0026F2D0 /* SDLManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLManager.m; sourceTree = "<group>"; };
5DA49CE31F1EA83300E65FC5 /* SDLControlFramePayloadRPCStartService.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDLControlFramePayloadRPCStartService.h; sourceTree = "<group>"; };
5DA49CE41F1EA83300E65FC5 /* SDLControlFramePayloadRPCStartService.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLControlFramePayloadRPCStartService.m; sourceTree = "<group>"; };
+ 5DADA7731F4DFED60084D17D /* SDLRectangle.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDLRectangle.h; sourceTree = "<group>"; };
+ 5DADA7741F4DFED60084D17D /* SDLRectangle.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLRectangle.m; sourceTree = "<group>"; };
+ 5DADA7771F4E059E0084D17D /* SDLRectangleSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLRectangleSpec.m; sourceTree = "<group>"; };
5DAE06721BDEC6C000F9B498 /* SDLFileSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = SDLFileSpec.m; path = DevAPISpecs/SDLFileSpec.m; sourceTree = "<group>"; };
5DAE06741BDEC6D600F9B498 /* SDLArtworkSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = SDLArtworkSpec.m; path = DevAPISpecs/SDLArtworkSpec.m; sourceTree = "<group>"; };
5DB1BCD01D243A8E002FFC37 /* SDLDeleteFileOperationSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = SDLDeleteFileOperationSpec.m; path = DevAPISpecs/SDLDeleteFileOperationSpec.m; sourceTree = "<group>"; };
@@ -2062,6 +2077,15 @@
5DEE55BF1B8509CB004F0D0F /* SDLURLRequestTaskSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = SDLURLRequestTaskSpec.m; path = "UtilitiesSpecs/HTTP Connection/SDLURLRequestTaskSpec.m"; sourceTree = "<group>"; };
5DF2BB9C1B94E38A00CE5994 /* SDLURLSessionSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = SDLURLSessionSpec.m; path = "UtilitiesSpecs/HTTP Connection/SDLURLSessionSpec.m"; sourceTree = "<group>"; };
5DFFB9141BD7C89700DB3F04 /* SDLConnectionManagerType.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDLConnectionManagerType.h; sourceTree = "<group>"; };
+ 8877F5EA1F34A3BE00DC128A /* SDLSendHapticDataSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLSendHapticDataSpec.m; sourceTree = "<group>"; };
+ 8877F5EC1F34A72200DC128A /* SDLSendHapticDataResponse.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDLSendHapticDataResponse.h; sourceTree = "<group>"; };
+ 8877F5ED1F34A72200DC128A /* SDLSendHapticDataResponse.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLSendHapticDataResponse.m; sourceTree = "<group>"; };
+ 8877F5F01F34AA2D00DC128A /* SDLSendHapticDataResponseSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLSendHapticDataResponseSpec.m; sourceTree = "<group>"; };
+ 88EED8361F33AE1700E6C42E /* SDLHapticRect.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDLHapticRect.h; sourceTree = "<group>"; };
+ 88EED8371F33AE1700E6C42E /* SDLHapticRect.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLHapticRect.m; sourceTree = "<group>"; };
+ 88EED83A1F33BECB00E6C42E /* SDLHapticRectSpec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLHapticRectSpec.m; sourceTree = "<group>"; };
+ 88EED83C1F33C5A400E6C42E /* SDLSendHapticData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDLSendHapticData.h; sourceTree = "<group>"; };
+ 88EED83D1F33C5A400E6C42E /* SDLSendHapticData.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLSendHapticData.m; sourceTree = "<group>"; };
8B7B31981F2F7B5700BDC38D /* SDLVideoStreamingCodec.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDLVideoStreamingCodec.h; sourceTree = "<group>"; };
8B7B31991F2F7B5700BDC38D /* SDLVideoStreamingCodec.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SDLVideoStreamingCodec.m; sourceTree = "<group>"; };
8B7B319C1F2F7CF700BDC38D /* SDLVideoStreamingProtocol.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDLVideoStreamingProtocol.h; sourceTree = "<group>"; };
@@ -2382,6 +2406,7 @@
162E82631A9BDE8A00906325 /* SDLUnsubscribeVehicleDataSpec.m */,
DA9F7EA51DCC05F500ACAE48 /* SDLUnsubscribeWaypointsSpec.m */,
162E82641A9BDE8A00906325 /* SDLUpdateTurnListSpec.m */,
+ 8877F5EA1F34A3BE00DC128A /* SDLSendHapticDataSpec.m */,
);
path = RequestSpecs;
sourceTree = "<group>";
@@ -2435,6 +2460,7 @@
162E828C1A9BDE8A00906325 /* SDLUnsubscribeVehicleDataResponseSpec.m */,
DA9F7EAB1DCC062400ACAE48 /* SDLUnsubscribeWaypointsResponseSpec.m */,
162E828D1A9BDE8A00906325 /* SDLUpdateTurnListResponseSpec.m */,
+ 8877F5F01F34AA2D00DC128A /* SDLSendHapticDataResponseSpec.m */,
);
path = ResponseSpecs;
sourceTree = "<group>";
@@ -2458,6 +2484,7 @@
162E829A1A9BDE8A00906325 /* SDLECallInfoSpec.m */,
162E829B1A9BDE8A00906325 /* SDLEmergencyEventSpec.m */,
162E829C1A9BDE8A00906325 /* SDLGPSDataSpec.m */,
+ 88EED83A1F33BECB00E6C42E /* SDLHapticRectSpec.m */,
162E829D1A9BDE8A00906325 /* SDLHeadLampStatusSpec.m */,
5DE372A31ACB336600849FAA /* SDLHMICapabilitiesSpec.m */,
162E829E1A9BDE8A00906325 /* SDLHMIPermissionsSpec.m */,
@@ -2475,6 +2502,7 @@
162E82A51A9BDE8A00906325 /* SDLPermissionItemSpec.m */,
5D0A9F941F15585B00CC80DD /* SDLPhoneCapabilitySpec.m */,
162E82A61A9BDE8A00906325 /* SDLPresetBankCapabilitiesSpec.m */,
+ 5DADA7771F4E059E0084D17D /* SDLRectangleSpec.m */,
162E82A71A9BDE8A00906325 /* SDLScreenParamsSpec.m */,
162E82A81A9BDE8A00906325 /* SDLSingleTireStatusSpec.m */,
162E82A91A9BDE8A00906325 /* SDLSoftButtonCapabilitiesSpec.m */,
@@ -2915,6 +2943,8 @@
5D61FB771A84238B00846EE7 /* SDLResetGlobalProperties.m */,
5D61FB8E1A84238B00846EE7 /* SDLScrollableMessage.h */,
5D61FB8F1A84238B00846EE7 /* SDLScrollableMessage.m */,
+ 88EED83C1F33C5A400E6C42E /* SDLSendHapticData.h */,
+ 88EED83D1F33C5A400E6C42E /* SDLSendHapticData.m */,
5DCF76F31ACDBAD300BB647B /* SDLSendLocation.h */,
5DCF76F41ACDBAD300BB647B /* SDLSendLocation.m */,
5D61FB921A84238B00846EE7 /* SDLSetAppIcon.h */,
@@ -3014,6 +3044,8 @@
5D61FB791A84238B00846EE7 /* SDLResetGlobalPropertiesResponse.m */,
5D61FB901A84238B00846EE7 /* SDLScrollableMessageResponse.h */,
5D61FB911A84238B00846EE7 /* SDLScrollableMessageResponse.m */,
+ 8877F5EC1F34A72200DC128A /* SDLSendHapticDataResponse.h */,
+ 8877F5ED1F34A72200DC128A /* SDLSendHapticDataResponse.m */,
5DCF76F71ACDD7CD00BB647B /* SDLSendLocationResponse.h */,
5DCF76F81ACDD7CD00BB647B /* SDLSendLocationResponse.m */,
5D61FB941A84238B00846EE7 /* SDLSetAppIconResponse.h */,
@@ -3091,6 +3123,8 @@
5D61FAAE1A84238A00846EE7 /* SDLEmergencyEvent.m */,
5D61FACE1A84238A00846EE7 /* SDLGPSData.h */,
5D61FACF1A84238A00846EE7 /* SDLGPSData.m */,
+ 88EED8361F33AE1700E6C42E /* SDLHapticRect.h */,
+ 88EED8371F33AE1700E6C42E /* SDLHapticRect.m */,
5D61FAD01A84238A00846EE7 /* SDLHeadLampStatus.h */,
5D61FAD11A84238A00846EE7 /* SDLHeadLampStatus.m */,
5DE3729F1ACB2ED300849FAA /* SDLHMICapabilities.h */,
@@ -3127,6 +3161,8 @@
5D00AC7A1F15287E004000D9 /* SDLPhoneCapability.m */,
5D61FB4E1A84238B00846EE7 /* SDLPresetBankCapabilities.h */,
5D61FB4F1A84238B00846EE7 /* SDLPresetBankCapabilities.m */,
+ 5DADA7731F4DFED60084D17D /* SDLRectangle.h */,
+ 5DADA7741F4DFED60084D17D /* SDLRectangle.m */,
5D61FB8C1A84238B00846EE7 /* SDLScreenParams.h */,
5D61FB8D1A84238B00846EE7 /* SDLScreenParams.m */,
5D61FBAA1A84238B00846EE7 /* SDLSingleTireStatus.h */,
@@ -4307,6 +4343,7 @@
5D61FD811A84238C00846EE7 /* SDLSetAppIconResponse.h in Headers */,
5D61FC551A84238C00846EE7 /* SDLButtonName.h in Headers */,
5D616B531D59044400553F6B /* SDLErrorConstants.h in Headers */,
+ 5DADA7751F4DFED60084D17D /* SDLRectangle.h in Headers */,
5D61FD9F1A84238C00846EE7 /* SDLSoftButton.h in Headers */,
5DD67CBC1E661C84009CD394 /* SDLLogTargetOSLog.h in Headers */,
5D61FD551A84238C00846EE7 /* SDLPutFile.h in Headers */,
@@ -4354,6 +4391,7 @@
5D61FC761A84238C00846EE7 /* SDLDeleteFile.h in Headers */,
5D61FD211A84238C00846EE7 /* SDLOnVehicleData.h in Headers */,
DA9F7E731DCC004C00ACAE48 /* SDLGetWaypointsResponse.h in Headers */,
+ 88EED8381F33AE1700E6C42E /* SDLHapticRect.h in Headers */,
5DD67CC31E68AE82009CD394 /* SDLLogFileModuleMap.h in Headers */,
5D61FD7D1A84238C00846EE7 /* SDLScrollableMessageResponse.h in Headers */,
5D61FD431A84238C00846EE7 /* SDLProtocol.h in Headers */,
@@ -4441,6 +4479,7 @@
5D4D67B01D2FE2F900468B4A /* SDLResponseDispatcher.h in Headers */,
5D61FCF21A84238C00846EE7 /* SDLLockScreenStatus.h in Headers */,
5D00AC771F15283E004000D9 /* SDLNavigationCapability.h in Headers */,
+ 88EED83E1F33C5A400E6C42E /* SDLSendHapticData.h in Headers */,
5D61FCD31A84238C00846EE7 /* SDLImageResolution.h in Headers */,
8B7B319E1F2F7CF700BDC38D /* SDLVideoStreamingProtocol.h in Headers */,
5D61FD541A84238C00846EE7 /* SDLProxyListener.h in Headers */,
@@ -4466,6 +4505,7 @@
5D61FC721A84238C00846EE7 /* SDLDeleteCommand.h in Headers */,
5D61FC821A84238C00846EE7 /* SDLDeviceInfo.h in Headers */,
5D61FCA91A84238C00846EE7 /* SDLFileType.h in Headers */,
+ 8877F5EE1F34A72200DC128A /* SDLSendHapticDataResponse.h in Headers */,
DA8966F21E56973700413EAB /* SDLStreamingMediaManagerConstants.h in Headers */,
5DD67CB81E661C4A009CD394 /* SDLLogTargetFile.h in Headers */,
5D61FD591A84238C00846EE7 /* SDLReadDID.h in Headers */,
@@ -5030,6 +5070,8 @@
5D1665C91CF8CA3D00CC4CA1 /* SDLPermissionFilter.m in Sources */,
5D61FDBA1A84238C00846EE7 /* SDLSyncPDataResponse.m in Sources */,
5D61FDDC1A84238C00846EE7 /* SDLTriggerSource.m in Sources */,
+ 5DADA7761F4DFED60084D17D /* SDLRectangle.m in Sources */,
+ 88EED83F1F33C5A400E6C42E /* SDLSendHapticData.m in Sources */,
5D16545B1D3E7A1600554D93 /* SDLLifecycleManager.m in Sources */,
E9C32B971AB20BA200F283AF /* SDLTimer.m in Sources */,
5D61FCB61A84238C00846EE7 /* SDLGetVehicleData.m in Sources */,
@@ -5081,6 +5123,7 @@
5DA3F3551BC448060026F2D0 /* NSMapTable+Subscripting.m in Sources */,
5D61FCD61A84238C00846EE7 /* SDLImageType.m in Sources */,
5D4D67AD1D2ED37A00468B4A /* SDLNotificationDispatcher.m in Sources */,
+ 88EED8391F33AE1700E6C42E /* SDLHapticRect.m in Sources */,
DA9F7E9C1DCC052C00ACAE48 /* SDLLocationDetails.m in Sources */,
5D61FD7A1A84238C00846EE7 /* SDLScreenParams.m in Sources */,
5D61FC831A84238C00846EE7 /* SDLDeviceInfo.m in Sources */,
@@ -5089,6 +5132,7 @@
97E26DED1E807AD70074A3C7 /* SDLMutableDataQueue.m in Sources */,
5D61FD641A84238C00846EE7 /* SDLResetGlobalProperties.m in Sources */,
5D60088B1BE3ED540094A505 /* SDLStateMachine.m in Sources */,
+ 8877F5EF1F34A72200DC128A /* SDLSendHapticDataResponse.m in Sources */,
5D61FD181A84238C00846EE7 /* SDLOnPermissionsChange.m in Sources */,
5D61FD3E1A84238C00846EE7 /* SDLPrimaryAudioSource.m in Sources */,
5D61FC2A1A84238C00846EE7 /* SDLAbstractProtocol.m in Sources */,
@@ -5167,6 +5211,7 @@
162E837D1A9BDE8B00906325 /* SDLEmergencyEventSpec.m in Sources */,
162E82D31A9BDE8A00906325 /* SDLCarModeStatusSpec.m in Sources */,
8B7B31A91F2FB8BC00BDC38D /* SDLVideoStreamingProtocolSpec.m in Sources */,
+ 88EED83B1F33BECB00E6C42E /* SDLHapticRectSpec.m in Sources */,
162E82EA1A9BDE8B00906325 /* SDLLanguageSpec.m in Sources */,
5D76E3291D3D0A8800647CFA /* SDLFakeViewControllerPresenter.m in Sources */,
162E83331A9BDE8B00906325 /* SDLPerformInteractionSpec.m in Sources */,
@@ -5210,6 +5255,7 @@
162E83281A9BDE8B00906325 /* SDLDeleteCommandSpec.m in Sources */,
162E83531A9BDE8B00906325 /* SDLDiagnosticMessageResponseSpec.m in Sources */,
162E83671A9BDE8B00906325 /* SDLSliderResponseSpec.m in Sources */,
+ 8877F5F11F34AA2D00DC128A /* SDLSendHapticDataResponseSpec.m in Sources */,
162E836C1A9BDE8B00906325 /* SDLSystemRequestResponseSpec.m in Sources */,
162E833C1A9BDE8B00906325 /* SDLSetMediaClockTimerSpec.m in Sources */,
162E83061A9BDE8B00906325 /* SDLVehicleDataEventStatusSpec.m in Sources */,
@@ -5364,6 +5410,7 @@
162E838C1A9BDE8B00906325 /* SDLSoftButtonSpec.m in Sources */,
5DA23FF81F2FAF2D009C0313 /* SDLControlFramePayloadRPCStartServiceAckSpec.m in Sources */,
162E83191A9BDE8B00906325 /* SDLOnLanguageChangeSpec.m in Sources */,
+ 5DADA7781F4E059E0084D17D /* SDLRectangleSpec.m in Sources */,
5DB1BCDD1D243DC3002FFC37 /* SDLLifecycleConfigurationSpec.m in Sources */,
162E83611A9BDE8B00906325 /* SDLSetAppIconResponseSpec.m in Sources */,
162E83471A9BDE8B00906325 /* SDLUnsubscribeVehicleDataSpec.m in Sources */,
@@ -5405,6 +5452,7 @@
162E83321A9BDE8B00906325 /* SDLPerformAudioPassThruSpec.m in Sources */,
162E830B1A9BDE8B00906325 /* SDLVrCapabilitiesSpec.m in Sources */,
162E83081A9BDE8B00906325 /* SDLVehicleDataResultCodeSpec.m in Sources */,
+ 8877F5EB1F34A3BE00DC128A /* SDLSendHapticDataSpec.m in Sources */,
162E83621A9BDE8B00906325 /* SDLSetDisplayLayoutResponseSpec.m in Sources */,
162E832E1A9BDE8B00906325 /* SDLEndAudioPassThruSpec.m in Sources */,
1680B1191A9CD7AD00DBD79E /* SDLV2ProtocolMessageSpec.m in Sources */,
diff --git a/SmartDeviceLink.podspec b/SmartDeviceLink.podspec
index 1b76620b5..b14c8785f 100644
--- a/SmartDeviceLink.podspec
+++ b/SmartDeviceLink.podspec
@@ -104,6 +104,7 @@ ss.public_header_files = [
'SmartDeviceLink/SDLGetWaypointsResponse.h',
'SmartDeviceLink/SDLGlobalProperty.h',
'SmartDeviceLink/SDLGPSData.h',
+'SmartDeviceLink/SDLHapticRect.h',
'SmartDeviceLink/SDLHeadLampStatus.h',
'SmartDeviceLink/SDLHMICapabilities.h',
'SmartDeviceLink/SDLHMILevel.h',
@@ -222,6 +223,8 @@ ss.public_header_files = [
'SmartDeviceLink/SDLScrollableMessage.h',
'SmartDeviceLink/SDLScrollableMessageResponse.h',
'SmartDeviceLink/SDLSecurityType.h',
+'SmartDeviceLink/SDLSendHapticData.h',
+'SmartDeviceLink/SDLSendHapticDataResponse.h',
'SmartDeviceLink/SDLSendLocation.h',
'SmartDeviceLink/SDLSendLocationResponse.h',
'SmartDeviceLink/SDLSetAppIcon.h',
diff --git a/SmartDeviceLink/SDLFunctionID.m b/SmartDeviceLink/SDLFunctionID.m
index 58ff9c479..ed8f32d02 100644
--- a/SmartDeviceLink/SDLFunctionID.m
+++ b/SmartDeviceLink/SDLFunctionID.m
@@ -75,6 +75,7 @@ NS_ASSUME_NONNULL_BEGIN
@46: SDLNameSubscribeWaypoints,
@47: SDLNameUnsubscribeWaypoints,
@48: SDLNameGetSystemCapability,
+ @49: SDLNameSendHapticData,
@32768: SDLNameOnHMIStatus,
@32769: SDLNameOnAppInterfaceUnregistered,
@32770: SDLNameOnButtonEvent,
diff --git a/SmartDeviceLink/SDLHapticRect.h b/SmartDeviceLink/SDLHapticRect.h
new file mode 100644
index 000000000..295ea55af
--- /dev/null
+++ b/SmartDeviceLink/SDLHapticRect.h
@@ -0,0 +1,34 @@
+//
+// SDLHapticRect.h
+// SmartDeviceLink-iOS
+//
+// Created by Nicole on 8/3/17.
+// Copyright © 2017 smartdevicelink. All rights reserved.
+//
+
+#import <UIKit/UIKit.h>
+
+#import "SDLRPCStruct.h"
+
+@class SDLRectangle;
+
+NS_ASSUME_NONNULL_BEGIN
+
+/**
+ * Defines spatial for each user control object for video streaming application
+ */
+@interface SDLHapticRect : SDLRPCStruct
+
+- (instancetype)initWithId:(UInt32)id rect:(SDLRectangle *)rect;
+
+/**
+ * A user control spatial identifier
+ * Required, Integer, 0 - 2,000,000,000
+ */
+@property (strong, nonatomic) NSNumber<SDLUInt> *id;
+
+@property (strong, nonatomic) SDLRectangle *rect;
+
+@end
+
+NS_ASSUME_NONNULL_END
diff --git a/SmartDeviceLink/SDLHapticRect.m b/SmartDeviceLink/SDLHapticRect.m
new file mode 100644
index 000000000..330756d4c
--- /dev/null
+++ b/SmartDeviceLink/SDLHapticRect.m
@@ -0,0 +1,48 @@
+//
+// SDLHapticRect.m
+// SmartDeviceLink-iOS
+//
+// Created by Nicole on 8/3/17.
+// Copyright © 2017 smartdevicelink. All rights reserved.
+//
+
+#import "NSMutableDictionary+Store.h"
+#import "SDLHapticRect.h"
+#import "SDLNames.h"
+#import "SDLRectangle.h"
+
+NS_ASSUME_NONNULL_BEGIN
+
+@implementation SDLHapticRect
+
+- (instancetype)initWithId:(UInt32)id rect:(nonnull SDLRectangle *)rect {
+ self = [self init];
+ if (!self) {
+ return nil;
+ }
+
+ self.id = @(id);
+ self.rect = rect;
+
+ return self;
+}
+
+- (void)setId:(NSNumber<SDLInt> *)id {
+ [store sdl_setObject:id forName:SDLNameId];
+}
+
+- (NSNumber<SDLInt> *)id {
+ return [store sdl_objectForName:SDLNameId];
+}
+
+- (void)setRect:(SDLRectangle *)rect {
+ [store sdl_setObject:rect forName:SDLNameRect];
+}
+
+- (SDLRectangle *)rect {
+ return [store sdl_objectForName:SDLNameRect ofClass:SDLRectangle.class];
+}
+
+@end
+
+NS_ASSUME_NONNULL_END
diff --git a/SmartDeviceLink/SDLNames.h b/SmartDeviceLink/SDLNames.h
index 5bdcc52e5..1a3cd54bb 100644
--- a/SmartDeviceLink/SDLNames.h
+++ b/SmartDeviceLink/SDLNames.h
@@ -138,11 +138,14 @@ extern SDLName const SDLNameGetWaypointsEnabled;
extern SDLName const SDLNameGPS;
extern SDLName const SDLNameGraphic;
extern SDLName const SDLNameGraphicSupported;
+extern SDLName const SDLNameHapticRectData;
+extern SDLName const SDLNameHapticSpatialDataSupported;
extern SDLName const SDLNameHardware;
extern SDLName const SDLNameHashId;
extern SDLName const SDLNameHDOP;
extern SDLName const SDLNameHeading;
extern SDLName const SDLNameHeadLampStatus;
+extern SDLName const SDLNameHeight;
extern SDLName const SDLNameHelpPrompt;
extern SDLName const SDLNameHighBeamsOn;
extern SDLName const SDLNameHMIDisplayLanguage;
@@ -322,6 +325,7 @@ extern SDLName const SDLNameReadDID;
extern SDLName const SDLNameRearLeftDoorAjar;
extern SDLName const SDLNameRearRightDoorAjar;
extern SDLName const SDLNameReason;
+extern SDLName const SDLNameRect;
extern SDLName const SDLNameRegisterAppInterface;
extern SDLName const SDLNameRequest;
extern SDLName const SDLNameRequestType;
@@ -354,6 +358,8 @@ extern SDLName const SDLNameSecondaryImage;
extern SDLName const SDLNameSecondaryText;
extern SDLName const SDLNameSecond;
extern SDLName const SDLNameSeconds;
+extern SDLName const SDLNameSendHapticData;
+extern SDLName const SDLNameSendHapticDataResponse;
extern SDLName const SDLNameSendLocation;
extern SDLName const SDLNameSendLocationEnabled;
extern SDLName const SDLNameSetAppIcon;
diff --git a/SmartDeviceLink/SDLNames.m b/SmartDeviceLink/SDLNames.m
index 995cc20bf..264bac81a 100644
--- a/SmartDeviceLink/SDLNames.m
+++ b/SmartDeviceLink/SDLNames.m
@@ -135,11 +135,14 @@ SDLName const SDLNameGetWaypointsEnabled = @"getWayPointsEnabled";
SDLName const SDLNameGPS = @"gps";
SDLName const SDLNameGraphic = @"graphic";
SDLName const SDLNameGraphicSupported = @"graphicSupported";
+SDLName const SDLNameHapticRectData = @"hapticRectData";
+SDLName const SDLNameHapticSpatialDataSupported = @"hapticSpatialDataSupported";
SDLName const SDLNameHardware = @"hardware";
SDLName const SDLNameHashId = @"hashID";
SDLName const SDLNameHDOP = @"hdop";
SDLName const SDLNameHeading = @"heading";
SDLName const SDLNameHeadLampStatus = @"headLampStatus";
+SDLName const SDLNameHeight = @"height";
SDLName const SDLNameHelpPrompt = @"helpPrompt";
SDLName const SDLNameHighBeamsOn = @"highBeamsOn";
SDLName const SDLNameHMIDisplayLanguage = @"hmiDisplayLanguage";
@@ -316,6 +319,7 @@ SDLName const SDLNameReadDID = @"ReadDID";
SDLName const SDLNameRearLeftDoorAjar = @"rearLeftDoorAjar";
SDLName const SDLNameRearRightDoorAjar = @"rearRightDoorAjar";
SDLName const SDLNameReason = @"reason";
+SDLName const SDLNameRect = @"rect";
SDLName const SDLNameRegisterAppInterface = @"RegisterAppInterface";
SDLName const SDLNameRequest = @"request";
SDLName const SDLNameRequestType = @"requestType";
@@ -348,6 +352,8 @@ SDLName const SDLNameSecondaryImage = @"secondaryImage";
SDLName const SDLNameSecondaryText = @"secondaryText";
SDLName const SDLNameSecond = @"second";
SDLName const SDLNameSeconds = @"seconds";
+SDLName const SDLNameSendHapticData = @"SendHapticData";
+SDLName const SDLNameSendHapticDataResponse = @"SendHapticDataResponse";
SDLName const SDLNameSendLocation = @"SendLocation";
SDLName const SDLNameSendLocationEnabled = @"sendLocationEnabled";
SDLName const SDLNameSetAppIcon = @"SetAppIcon";
diff --git a/SmartDeviceLink/SDLNotificationConstants.h b/SmartDeviceLink/SDLNotificationConstants.h
index 9c9edca13..d313edb39 100644
--- a/SmartDeviceLink/SDLNotificationConstants.h
+++ b/SmartDeviceLink/SDLNotificationConstants.h
@@ -114,6 +114,7 @@ extern SDLNotificationName const SDLDidReceiveReadDIDResponse;
extern SDLNotificationName const SDLDidReceiveRegisterAppInterfaceResponse;
extern SDLNotificationName const SDLDidReceiveResetGlobalPropertiesResponse;
extern SDLNotificationName const SDLDidReceiveScrollableMessageResponse;
+extern SDLNotificationName const SDLDidReceiveSendHapticDataResponse;
extern SDLNotificationName const SDLDidReceiveSendLocationResponse;
extern SDLNotificationName const SDLDidReceiveSetAppIconResponse;
extern SDLNotificationName const SDLDidReceiveSetDisplayLayoutResponse;
diff --git a/SmartDeviceLink/SDLNotificationConstants.m b/SmartDeviceLink/SDLNotificationConstants.m
index b444a8857..1952f397b 100644
--- a/SmartDeviceLink/SDLNotificationConstants.m
+++ b/SmartDeviceLink/SDLNotificationConstants.m
@@ -47,6 +47,7 @@ SDLNotificationName const SDLDidReceiveReadDIDResponse = @"com.sdl.response.read
SDLNotificationName const SDLDidReceiveRegisterAppInterfaceResponse = @"com.sdl.response.registerAppInterface";
SDLNotificationName const SDLDidReceiveResetGlobalPropertiesResponse = @"com.sdl.response.resetGlobalProperties";
SDLNotificationName const SDLDidReceiveScrollableMessageResponse = @"com.sdl.response.scrollableMessage";
+SDLNotificationName const SDLDidReceiveSendHapticDataResponse = @"com.sdl.response.sendHapticData";
SDLNotificationName const SDLDidReceiveSendLocationResponse = @"com.sdl.response.sendLocation";
SDLNotificationName const SDLDidReceiveSetAppIconResponse = @"com.sdl.response.setAppIcon";
SDLNotificationName const SDLDidReceiveSetDisplayLayoutResponse = @"com.sdl.response.setDisplayLayout";
@@ -117,6 +118,7 @@ SDLNotificationName const SDLDidReceiveWaypointNotification = @"com.sdl.notifica
SDLDidReceiveRegisterAppInterfaceResponse,
SDLDidReceiveResetGlobalPropertiesResponse,
SDLDidReceiveScrollableMessageResponse,
+ SDLDidReceiveSendHapticDataResponse,
SDLDidReceiveSendLocationResponse,
SDLDidReceiveSetAppIconResponse,
SDLDidReceiveSetDisplayLayoutResponse,
diff --git a/SmartDeviceLink/SDLNotificationDispatcher.m b/SmartDeviceLink/SDLNotificationDispatcher.m
index 00ae1f962..81fbeee76 100644
--- a/SmartDeviceLink/SDLNotificationDispatcher.m
+++ b/SmartDeviceLink/SDLNotificationDispatcher.m
@@ -186,6 +186,10 @@ NS_ASSUME_NONNULL_BEGIN
[self postRPCResponseNotification:SDLDidReceiveScrollableMessageResponse response:response];
}
+- (void)onSendHapticDataResponse:(SDLSendHapticDataResponse *)response {
+ [self postRPCResponseNotification:SDLDidReceiveSendHapticDataResponse response:response];
+}
+
- (void)onSendLocationResponse:(SDLSendLocationResponse *)response {
[self postRPCResponseNotification:SDLDidReceiveSendLocationResponse response:response];
}
diff --git a/SmartDeviceLink/SDLProxyListener.h b/SmartDeviceLink/SDLProxyListener.h
index b3d29825c..a4b1e3c43 100644
--- a/SmartDeviceLink/SDLProxyListener.h
+++ b/SmartDeviceLink/SDLProxyListener.h
@@ -50,6 +50,7 @@
@class SDLRegisterAppInterfaceResponse;
@class SDLResetGlobalPropertiesResponse;
@class SDLScrollableMessageResponse;
+@class SDLSendHapticDataResponse;
@class SDLSendLocationResponse;
@class SDLSetAppIconResponse;
@class SDLSetDisplayLayoutResponse;
@@ -126,6 +127,7 @@ NS_ASSUME_NONNULL_BEGIN
- (void)onRegisterAppInterfaceResponse:(SDLRegisterAppInterfaceResponse *)response;
- (void)onResetGlobalPropertiesResponse:(SDLResetGlobalPropertiesResponse *)response;
- (void)onScrollableMessageResponse:(SDLScrollableMessageResponse *)response;
+- (void)onSendHapticDataResponse:(SDLSendHapticDataResponse *)response;
- (void)onSendLocationResponse:(SDLSendLocationResponse *)response;
- (void)onSetAppIconResponse:(SDLSetAppIconResponse *)response;
- (void)onSetDisplayLayoutResponse:(SDLSetDisplayLayoutResponse *)response;
diff --git a/SmartDeviceLink/SDLRectangle.h b/SmartDeviceLink/SDLRectangle.h
new file mode 100644
index 000000000..5395f6315
--- /dev/null
+++ b/SmartDeviceLink/SDLRectangle.h
@@ -0,0 +1,56 @@
+//
+// SDLRectangle.h
+// SmartDeviceLink-iOS
+//
+// Created by Joel Fischer on 8/23/17.
+// Copyright © 2017 smartdevicelink. All rights reserved.
+//
+
+#import <SmartDeviceLink/SmartDeviceLink.h>
+
+@interface SDLRectangle : SDLRPCStruct
+
+/**
+ Create a Rectangle
+
+ @param x The top-left x value
+ @param y The top-left y value
+ @param width The width
+ @param height The height
+ @return An new SDLRectangle object
+ */
+- (instancetype)initWithX:(float)x y:(float)y width:(float)width height:(float)height;
+
+/**
+ Create a Rectangle from a CGRect
+
+ @param rect The rectangle to use
+ @return An new SDLRectangle object
+ */
+- (instancetype)initWithCGRect:(CGRect)rect;
+
+/**
+ * The X-coordinate of the user control
+ * Required, Float
+ */
+@property (strong, nonatomic) NSNumber<SDLFloat> *x;
+
+/**
+ * The Y-coordinate of the user control
+ * Required, Float
+ */
+@property (strong, nonatomic) NSNumber<SDLFloat> *y;
+
+/**
+ * The width of the user control's bounding rectangle
+ * Required, Float
+ */
+@property (strong, nonatomic) NSNumber<SDLFloat> *width;
+
+/**
+ * The height of the user control's bounding rectangle
+ * Required, Float
+ */
+@property (strong, nonatomic) NSNumber<SDLFloat> *height;
+
+@end
diff --git a/SmartDeviceLink/SDLRectangle.m b/SmartDeviceLink/SDLRectangle.m
new file mode 100644
index 000000000..6a82312b9
--- /dev/null
+++ b/SmartDeviceLink/SDLRectangle.m
@@ -0,0 +1,63 @@
+//
+// SDLRectangle.m
+// SmartDeviceLink-iOS
+//
+// Created by Joel Fischer on 8/23/17.
+// Copyright © 2017 smartdevicelink. All rights reserved.
+//
+
+#import "NSMutableDictionary+Store.h"
+#import "SDLRectangle.h"
+#import "SDLNames.h"
+
+@implementation SDLRectangle
+
+- (instancetype)initWithX:(float)x y:(float)y width:(float)width height:(float)height {
+ self = [self init];
+ if (!self) { return nil; }
+
+ self.x = @(x);
+ self.y = @(y);
+ self.width = @(width);
+ self.height = @(height);
+
+ return self;
+}
+
+- (instancetype)initWithCGRect:(CGRect)rect {
+ return [self initWithX:rect.origin.x y:rect.origin.y width:rect.size.width height:rect.size.height];
+}
+
+- (void)setX:(NSNumber<SDLFloat> *)x {
+ [store sdl_setObject:x forName:SDLNameX];
+}
+
+- (NSNumber<SDLFloat> *)x {
+ return [store sdl_objectForName:SDLNameX];
+}
+
+- (void)setY:(NSNumber<SDLFloat> *)y {
+ [store sdl_setObject:y forName:SDLNameY];
+}
+
+- (NSNumber<SDLFloat> *)y {
+ return [store sdl_objectForName:SDLNameY];
+}
+
+- (void)setWidth:(NSNumber<SDLFloat> *)width {
+ [store sdl_setObject:width forName:SDLNameWidth];
+}
+
+- (NSNumber<SDLFloat> *)width {
+ return [store sdl_objectForName:SDLNameWidth];
+}
+
+- (void)setHeight:(NSNumber<SDLFloat> *)height {
+ [store sdl_setObject:height forName:SDLNameHeight];
+}
+
+- (NSNumber<SDLFloat> *)height {
+ return [store sdl_objectForName:SDLNameHeight];
+}
+
+@end
diff --git a/SmartDeviceLink/SDLSendHapticData.h b/SmartDeviceLink/SDLSendHapticData.h
new file mode 100644
index 000000000..c4c0f237c
--- /dev/null
+++ b/SmartDeviceLink/SDLSendHapticData.h
@@ -0,0 +1,37 @@
+//
+// SDLSendHapticData.h
+// SmartDeviceLink-iOS
+//
+// Created by Nicole on 8/3/17.
+// Copyright © 2017 smartdevicelink. All rights reserved.
+//
+
+#import <Foundation/Foundation.h>
+#import "SDLRPCRequest.h"
+
+@class SDLHapticRect;
+
+NS_ASSUME_NONNULL_BEGIN
+
+/**
+ * Sends the spatial data gathered from SDLCarWindow or VirtualDisplayEncoder to the HMI. This data will be utilized by the HMI to determine how and when haptic events should occur.
+ */
+@interface SDLSendHapticData : SDLRPCRequest
+
+/**
+ * Constructs a new SDLSendHapticData object indicated by the hapticSpatialData parameter
+ *
+ * @param hapticRectData Array of spatial data structures
+ */
+- (instancetype)initWithHapticRectData:(NSArray<SDLHapticRect *> *)hapticRectData;
+
+/**
+ * Array of spatial data structures that represent the locations of all user controls present on the HMI. This data should be updated if/when the application presents a new screen. When a request is sent, if successful, it will replace all spatial data previously sent through RPC. If an empty array is sent, the existing spatial data will be cleared
+ *
+ * Optional, Array of SDLHapticRect, Array size 0 - 1,000
+ */
+@property (strong, nonatomic, nullable) NSArray<SDLHapticRect *> *hapticRectData;
+
+@end
+
+NS_ASSUME_NONNULL_END
diff --git a/SmartDeviceLink/SDLSendHapticData.m b/SmartDeviceLink/SDLSendHapticData.m
new file mode 100644
index 000000000..d1f85988a
--- /dev/null
+++ b/SmartDeviceLink/SDLSendHapticData.m
@@ -0,0 +1,44 @@
+//
+// SDLSendHapticData.m
+// SmartDeviceLink-iOS
+//
+// Created by Nicole on 8/3/17.
+// Copyright © 2017 smartdevicelink. All rights reserved.
+//
+
+#import "NSMutableDictionary+Store.h"
+#import "SDLNames.h"
+#import "SDLSendHapticData.h"
+
+NS_ASSUME_NONNULL_BEGIN
+
+@implementation SDLSendHapticData
+
+- (instancetype)init {
+ if (self = [super initWithName:SDLNameSendHapticData]) {
+ }
+ return self;
+}
+
+- (instancetype)initWithHapticRectData:(NSArray<SDLHapticRect *> *)hapticRectData {
+ self = [self init];
+ if (!self) {
+ return nil;
+ }
+
+ self.hapticRectData = [hapticRectData mutableCopy];
+
+ return self;
+}
+
+- (void)setHapticRectData:(nullable NSArray<SDLHapticRect *> *)hapticRectData {
+ [parameters sdl_setObject:hapticRectData forName:SDLNameHapticRectData];
+}
+
+- (nullable NSArray<SDLHapticRect *> *)hapticRectData {
+ return [parameters sdl_objectForName:SDLNameHapticRectData];
+}
+
+@end
+
+NS_ASSUME_NONNULL_END
diff --git a/SmartDeviceLink/SDLSendHapticDataResponse.h b/SmartDeviceLink/SDLSendHapticDataResponse.h
new file mode 100644
index 000000000..c811c0e22
--- /dev/null
+++ b/SmartDeviceLink/SDLSendHapticDataResponse.h
@@ -0,0 +1,19 @@
+//
+// SDLSendHapticDataResponse.h
+// SmartDeviceLink-iOS
+//
+// Created by Nicole on 8/4/17.
+// Copyright © 2017 smartdevicelink. All rights reserved.
+//
+
+#import "SDLRPCResponse.h"
+
+NS_ASSUME_NONNULL_BEGIN
+/**
+ * SDLSendHapticDataResponse is sent when SDLSendHapticData has been called
+ */
+@interface SDLSendHapticDataResponse : SDLRPCResponse
+
+@end
+
+NS_ASSUME_NONNULL_END
diff --git a/SmartDeviceLink/SDLSendHapticDataResponse.m b/SmartDeviceLink/SDLSendHapticDataResponse.m
new file mode 100644
index 000000000..b1fa03607
--- /dev/null
+++ b/SmartDeviceLink/SDLSendHapticDataResponse.m
@@ -0,0 +1,25 @@
+
+//
+// SDLSendHapticDataResponse.m
+// SmartDeviceLink-iOS
+//
+// Created by Nicole on 8/4/17.
+// Copyright © 2017 smartdevicelink. All rights reserved.
+//
+
+#import "SDLNames.h"
+#import "SDLSendHapticDataResponse.h"
+
+NS_ASSUME_NONNULL_BEGIN
+
+@implementation SDLSendHapticDataResponse
+
+- (instancetype)init {
+ if (self = [super initWithName:SDLNameSendHapticDataResponse]) {
+ }
+ return self;
+}
+
+@end
+
+NS_ASSUME_NONNULL_END
diff --git a/SmartDeviceLink/SDLVideoStreamingCapability.h b/SmartDeviceLink/SDLVideoStreamingCapability.h
index a19ec1a68..86de1f1ac 100644
--- a/SmartDeviceLink/SDLVideoStreamingCapability.h
+++ b/SmartDeviceLink/SDLVideoStreamingCapability.h
@@ -15,7 +15,7 @@ NS_ASSUME_NONNULL_BEGIN
@interface SDLVideoStreamingCapability : SDLRPCStruct
-- (instancetype)initWithVideoStreaming:(nullable SDLImageResolution *)preferredResolution maxBitrate:(nullable NSNumber *)maxBitrate supportedFormats:(nullable NSArray<SDLVideoStreamingFormat *> *)supportedFormats;
+- (instancetype)initWithVideoStreaming:(nullable SDLImageResolution *)preferredResolution maxBitrate:(nullable NSNumber<SDLInt> *)maxBitrate supportedFormats:(nullable NSArray<SDLVideoStreamingFormat *> *)supportedFormats hapticDataSupported:(nullable NSNumber<SDLBool> *)hapticDataSupported;
/**
* @abstract The preferred resolution of a video stream for decoding and rendering on HMI, optional
*/
@@ -35,6 +35,10 @@ NS_ASSUME_NONNULL_BEGIN
*/
@property (nullable, strong, nonatomic) NSArray<SDLVideoStreamingFormat *> *supportedFormats;
+/**
+ True if the system can utilize the haptic spatial data from the source being streamed.
+ */
+@property (nullable, strong, nonatomic) NSNumber<SDLBool> *hapticSpatialDataSupported;
@end
diff --git a/SmartDeviceLink/SDLVideoStreamingCapability.m b/SmartDeviceLink/SDLVideoStreamingCapability.m
index cf4d33e98..75873a710 100644
--- a/SmartDeviceLink/SDLVideoStreamingCapability.m
+++ b/SmartDeviceLink/SDLVideoStreamingCapability.m
@@ -17,7 +17,7 @@ NS_ASSUME_NONNULL_BEGIN
@implementation SDLVideoStreamingCapability
-- (instancetype)initWithVideoStreaming:(nullable SDLImageResolution *)preferredResolution maxBitrate:(nullable NSNumber *)maxBitrate supportedFormats:(nullable NSArray<SDLVideoStreamingFormat *> *)supportedFormats {
+- (instancetype)initWithVideoStreaming:(nullable SDLImageResolution *)preferredResolution maxBitrate:(nullable NSNumber<SDLInt> *)maxBitrate supportedFormats:(nullable NSArray<SDLVideoStreamingFormat *> *)supportedFormats hapticDataSupported:(nullable NSNumber<SDLBool> *)hapticDataSupported {
self = [self init];
if (!self) {
return self;
@@ -26,6 +26,7 @@ NS_ASSUME_NONNULL_BEGIN
self.maxBitrate = maxBitrate;
self.preferredResolution = preferredResolution;
self.supportedFormats = supportedFormats;
+ self.hapticSpatialDataSupported = hapticDataSupported;
return self;
}
@@ -54,6 +55,14 @@ NS_ASSUME_NONNULL_BEGIN
return [store sdl_objectsForName:SDLNameSupportedFormats ofClass:SDLVideoStreamingFormat.class];
}
+- (void)setHapticSpatialDataSupported:(nullable NSNumber<SDLBool> *)hapticSpatialDataSupported {
+ [store sdl_setObject:hapticSpatialDataSupported forName:SDLNameHapticSpatialDataSupported];
+}
+
+- (nullable NSNumber<SDLBool> *)hapticSpatialDataSupported {
+ return [store sdl_objectForName:SDLNameHapticSpatialDataSupported];
+}
+
@end
NS_ASSUME_NONNULL_END
diff --git a/SmartDeviceLink/SmartDeviceLink.h b/SmartDeviceLink/SmartDeviceLink.h
index 7f9e4cc40..62824df42 100644
--- a/SmartDeviceLink/SmartDeviceLink.h
+++ b/SmartDeviceLink/SmartDeviceLink.h
@@ -72,6 +72,7 @@ FOUNDATION_EXPORT const unsigned char SmartDeviceLinkVersionString[];
#import "SDLRegisterAppInterface.h"
#import "SDLResetGlobalProperties.h"
#import "SDLScrollableMessage.h"
+#import "SDLSendHapticData.h"
#import "SDLSendLocation.h"
#import "SDLSetAppIcon.h"
#import "SDLSetDisplayLayout.h"
@@ -119,6 +120,7 @@ FOUNDATION_EXPORT const unsigned char SmartDeviceLinkVersionString[];
#import "SDLRegisterAppInterfaceResponse.h"
#import "SDLResetGlobalPropertiesResponse.h"
#import "SDLScrollableMessageResponse.h"
+#import "SDLSendHapticDataResponse.h"
#import "SDLSendLocationResponse.h"
#import "SDLSetAppIconResponse.h"
#import "SDLSetDisplayLayoutResponse.h"
@@ -176,6 +178,7 @@ FOUNDATION_EXPORT const unsigned char SmartDeviceLinkVersionString[];
#import "SDLECallInfo.h"
#import "SDLEmergencyEvent.h"
#import "SDLGPSData.h"
+#import "SDLHapticRect.h"
#import "SDLHMICapabilities.h"
#import "SDLHMIPermissions.h"
#import "SDLHeadLampStatus.h"
@@ -194,6 +197,7 @@ FOUNDATION_EXPORT const unsigned char SmartDeviceLinkVersionString[];
#import "SDLPermissionItem.h"
#import "SDLPhoneCapability.h"
#import "SDLPresetBankCapabilities.h"
+#import "SDLRectangle.h"
#import "SDLScreenParams.h"
#import "SDLSingleTireStatus.h"
#import "SDLSoftButton.h"
diff --git a/SmartDeviceLinkTests/DevAPISpecs/SDLNotificationDispatcherSpec.m b/SmartDeviceLinkTests/DevAPISpecs/SDLNotificationDispatcherSpec.m
index 3dff5dc9e..7c39d7b46 100644
--- a/SmartDeviceLinkTests/DevAPISpecs/SDLNotificationDispatcherSpec.m
+++ b/SmartDeviceLinkTests/DevAPISpecs/SDLNotificationDispatcherSpec.m
@@ -63,6 +63,7 @@ describe(@"a notification dispatcher", ^{
expect(@([testDispatcher respondsToSelector:@selector(onRegisterAppInterfaceResponse:)])).to(beTruthy());
expect(@([testDispatcher respondsToSelector:@selector(onResetGlobalPropertiesResponse:)])).to(beTruthy());
expect(@([testDispatcher respondsToSelector:@selector(onScrollableMessageResponse:)])).to(beTruthy());
+ expect(@([testDispatcher respondsToSelector:@selector(onSendHapticDataResponse:)])).to(beTruthy());
expect(@([testDispatcher respondsToSelector:@selector(onSendLocationResponse:)])).to(beTruthy());
expect(@([testDispatcher respondsToSelector:@selector(onSetAppIconResponse:)])).to(beTruthy());
expect(@([testDispatcher respondsToSelector:@selector(onSetDisplayLayoutResponse:)])).to(beTruthy());
diff --git a/SmartDeviceLinkTests/ProtocolSpecs/SDLFunctionIDSpec.m b/SmartDeviceLinkTests/ProtocolSpecs/SDLFunctionIDSpec.m
index 4ce79a843..0d7821202 100644
--- a/SmartDeviceLinkTests/ProtocolSpecs/SDLFunctionIDSpec.m
+++ b/SmartDeviceLinkTests/ProtocolSpecs/SDLFunctionIDSpec.m
@@ -60,6 +60,8 @@ describe(@"GetFunctionName Tests", ^ {
expect([functionID functionNameForId:45]).to(equal(SDLNameGetWaypoints));
expect([functionID functionNameForId:46]).to(equal(SDLNameSubscribeWaypoints));
expect([functionID functionNameForId:47]).to(equal(SDLNameUnsubscribeWaypoints));
+ expect([functionID functionNameForId:48]).to(equal(SDLNameGetSystemCapability));
+ expect([functionID functionNameForId:49]).to(equal(SDLNameSendHapticData));
expect([functionID functionNameForId:32768]).to(equal(SDLNameOnHMIStatus));
expect([functionID functionNameForId:32769]).to(equal(SDLNameOnAppInterfaceUnregistered));
expect([functionID functionNameForId:32770]).to(equal(SDLNameOnButtonEvent));
@@ -131,6 +133,8 @@ describe(@"GetFunctionID Tests", ^ {
expect([functionID functionIdForName:SDLNameGetWaypoints]).to(equal(@45));
expect([functionID functionIdForName:SDLNameSubscribeWaypoints]).to(equal(@46));
expect([functionID functionIdForName:SDLNameUnsubscribeWaypoints]).to(equal(@47));
+ expect([functionID functionIdForName:SDLNameGetSystemCapability]).to(equal(@48));
+ expect([functionID functionIdForName:SDLNameSendHapticData]).to(equal(@49));
expect([functionID functionIdForName:SDLNameOnHMIStatus]).to(equal(@32768));
expect([functionID functionIdForName:SDLNameOnAppInterfaceUnregistered]).to(equal(@32769));
expect([functionID functionIdForName:SDLNameOnButtonEvent]).to(equal(@32770));
diff --git a/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLSendHapticDataSpec.m b/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLSendHapticDataSpec.m
new file mode 100644
index 000000000..24bf7ddb2
--- /dev/null
+++ b/SmartDeviceLinkTests/RPCSpecs/RequestSpecs/SDLSendHapticDataSpec.m
@@ -0,0 +1,62 @@
+//
+// SDLSendHapticDataSpec.m
+// SmartDeviceLink-iOS
+//
+// Created by Nicole on 8/4/17.
+// Copyright © 2017 smartdevicelink. All rights reserved.
+//
+
+#import <Foundation/Foundation.h>
+
+#import <Quick/Quick.h>
+#import <Nimble/Nimble.h>
+
+#import "SDLNames.h"
+#import "SDLHapticRect.h"
+#import "SDLRectangle.h"
+#import "SDLSendHapticData.h"
+
+QuickSpecBegin(SDLSendHapticDataSpec)
+
+describe(@"Initialization Tests", ^ {
+ __block SDLHapticRect *testStruct = nil;
+
+ beforeEach(^{
+ testStruct = [[SDLHapticRect alloc] initWithId:123 rect:[[SDLRectangle alloc] initWithX:23.1 y:45.6 width:69.0 height:69]];
+ });
+
+ context(@"Getter/Setter Tests", ^ {
+ it(@"Should set and get correctly", ^ {
+ SDLSendHapticData *testRequest = [[SDLSendHapticData alloc] init];
+ testRequest.hapticRectData = [@[testStruct] mutableCopy];
+
+ expect(testRequest.hapticRectData).to(equal(@[testStruct]));
+ });
+ });
+
+ context(@"Init tests", ^{
+ it(@"Should get correctly when initialized with a dictionary", ^ {
+ NSMutableDictionary* dict = [@{SDLNameRequest:
+ @{SDLNameParameters:
+ @{SDLNameHapticRectData:@[testStruct]},
+ SDLNameOperationName:SDLNameSendHapticData}} mutableCopy];
+ SDLSendHapticData *testRequest = [[SDLSendHapticData alloc] initWithDictionary:dict];
+
+ expect(testRequest.hapticRectData).to(equal(@[testStruct]));
+ });
+
+ it(@"Should initialize correctly with initWithType:", ^{
+ SDLSendHapticData *testRequest = [[SDLSendHapticData alloc] initWithHapticRectData:@[testStruct]];
+
+ expect(testRequest.hapticRectData).to(equal(@[testStruct]));
+ });
+
+ it(@"Should return nil if not set", ^ {
+ SDLSendHapticData *testRequest = [[SDLSendHapticData alloc] init];
+
+ expect(testRequest.hapticRectData).to(beNil());
+ });
+ });
+});
+
+QuickSpecEnd
diff --git a/SmartDeviceLinkTests/RPCSpecs/ResponseSpecs/SDLSendHapticDataResponseSpec.m b/SmartDeviceLinkTests/RPCSpecs/ResponseSpecs/SDLSendHapticDataResponseSpec.m
new file mode 100644
index 000000000..29be138ad
--- /dev/null
+++ b/SmartDeviceLinkTests/RPCSpecs/ResponseSpecs/SDLSendHapticDataResponseSpec.m
@@ -0,0 +1,19 @@
+//
+// SDLSendHapticDataResponseSpec.m
+// SmartDeviceLink-iOS
+//
+// Created by Nicole on 8/4/17.
+// Copyright © 2017 smartdevicelink. All rights reserved.
+//
+
+#import <Foundation/Foundation.h>
+
+#import <Quick/Quick.h>
+#import <Nimble/Nimble.h>
+
+#import "SDLNames.h"
+#import "SDLSendHapticDataResponse.h"
+
+QuickSpecBegin(SDLSendHapticDataResponseSpec)
+
+QuickSpecEnd
diff --git a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLHapticRectSpec.m b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLHapticRectSpec.m
new file mode 100644
index 000000000..6235ea62f
--- /dev/null
+++ b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLHapticRectSpec.m
@@ -0,0 +1,69 @@
+//
+// SDLHapticRectSpec.m
+// SmartDeviceLink-iOS
+//
+// Created by Nicole on 8/3/17.
+// Copyright © 2017 smartdevicelink. All rights reserved.
+//
+
+#import <Foundation/Foundation.h>
+
+#import <Quick/Quick.h>
+#import <Nimble/Nimble.h>
+
+#import "SDLNames.h"
+#import "SDLHapticRect.h"
+#import "SDLRectangle.h"
+
+QuickSpecBegin(SDLHapticRectSpec)
+
+describe(@"Getter/Setter Tests", ^{
+ __block SDLRectangle *testRect = nil;
+ beforeEach(^{
+ testRect = [[SDLRectangle alloc] initWithX:1.2 y:42.3 width:78.9 height:69];
+ });
+
+ it(@"Should set and get correctly", ^{
+ SDLHapticRect *testStruct = [[SDLHapticRect alloc] init];
+
+ testStruct.id = @1;
+ testStruct.rect = testRect;
+
+ expect(testStruct.id).to(equal(@1));
+ expect(testStruct.rect).to(equal(testRect));
+ });
+
+ it(@"Should get correctly when initialized with parameters", ^{
+ SDLHapticRect *testStruct = [[SDLHapticRect alloc] initWithId:23 rect:testRect];
+
+ expect(testStruct.id).to(equal(@23));
+ expect(testStruct.rect).to(equal(testRect));
+ });
+
+ it(@"Should get correctly when initialized with a dict", ^{
+ NSMutableDictionary *dict = [@{SDLNameId:@2,
+ SDLNameRect: @{
+ SDLNameX:@20,
+ SDLNameY:@200,
+ SDLNameWidth:@2000,
+ SDLNameHeight:@3000
+ }
+ } mutableCopy];
+ SDLHapticRect *testStruct = [[SDLHapticRect alloc] initWithDictionary:dict];
+
+ expect(testStruct.id).to(equal(@2));
+ expect(testStruct.rect.x).to(equal(@20));
+ expect(testStruct.rect.y).to(equal(@200));
+ expect(testStruct.rect.width).to(equal(@2000));
+ expect(testStruct.rect.height).to(equal(@3000));
+ });
+
+ it(@"Should return nil if not set", ^{
+ SDLHapticRect *testStruct = [[SDLHapticRect alloc] init];
+
+ expect(testStruct.id).to(beNil());
+ expect(testStruct.rect).to(beNil());
+ });
+});
+
+QuickSpecEnd
diff --git a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLRectangleSpec.m b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLRectangleSpec.m
new file mode 100644
index 000000000..59749135d
--- /dev/null
+++ b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLRectangleSpec.m
@@ -0,0 +1,58 @@
+#import <Foundation/Foundation.h>
+
+#import <Quick/Quick.h>
+#import <Nimble/Nimble.h>
+
+#import "SDLNames.h"
+#import "SDLRectangle.h"
+
+QuickSpecBegin(SDLRectangleSpec)
+
+describe(@"Getter/Setter Tests", ^{
+ it(@"Should set and get correctly", ^{
+ SDLRectangle *testStruct = [[SDLRectangle alloc] init];
+
+ testStruct.x = @10;
+ testStruct.y = @100;
+ testStruct.width = @1000;
+ testStruct.height = @2000;
+
+ expect(testStruct.x).to(equal(@10));
+ expect(testStruct.y).to(equal(@100));
+ expect(testStruct.width).to(equal(@1000));
+ expect(testStruct.height).to(equal(@2000));
+ });
+
+ it(@"Should get correctly when initialized with parameters", ^{
+ SDLRectangle *testStruct = [[SDLRectangle alloc] initWithX:50.5 y:60.2 width:500 height:600];
+
+ expect(testStruct.x).to(beCloseTo(@50.5));
+ expect(testStruct.y).to(beCloseTo(@60.2));
+ expect(testStruct.width).to(equal(@500.0));
+ expect(testStruct.height).to(equal(@600.0));
+ });
+
+ it(@"Should get correctly when initialized with a dict", ^{
+ NSDictionary *dict = @{SDLNameX:@20,
+ SDLNameY:@200,
+ SDLNameWidth:@2000,
+ SDLNameHeight:@3000};
+ SDLRectangle *testStruct = [[SDLRectangle alloc] initWithDictionary:dict];
+
+ expect(testStruct.x).to(equal(@20));
+ expect(testStruct.y).to(equal(@200));
+ expect(testStruct.width).to(equal(@2000));
+ expect(testStruct.height).to(equal(@3000));
+ });
+
+ it(@"Should return nil if not set", ^{
+ SDLRectangle *testStruct = [[SDLRectangle alloc] init];
+
+ expect(testStruct.x).to(beNil());
+ expect(testStruct.y).to(beNil());
+ expect(testStruct.width).to(beNil());
+ expect(testStruct.height).to(beNil());
+ });
+});
+
+QuickSpecEnd
diff --git a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLSystemCapabilitySpec.m b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLSystemCapabilitySpec.m
index 0ab02a693..070eb774e 100644
--- a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLSystemCapabilitySpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLSystemCapabilitySpec.m
@@ -82,12 +82,12 @@ describe(@"Initialization tests", ^{
});
it(@"should initialize correctly with initWithVideoStreamingCapability:", ^{
-
SDLImageResolution* resolution = [[SDLImageResolution alloc] init];
resolution.resolutionWidth = @600;
resolution.resolutionHeight = @500;
NSNumber *maxBitrate = @100;
+ NSNumber *hapticDataSupported = @YES;
SDLVideoStreamingFormat *format1 = [[SDLVideoStreamingFormat alloc] init];
format1.codec = SDLVideoStreamingCodecH264;
@@ -99,7 +99,7 @@ describe(@"Initialization tests", ^{
NSArray<SDLVideoStreamingFormat *> *formatArray = @[format1, format2];
- SDLVideoStreamingCapability *testVidStruct = [[SDLVideoStreamingCapability alloc] initWithVideoStreaming:resolution maxBitrate:maxBitrate supportedFormats:formatArray];
+ SDLVideoStreamingCapability *testVidStruct = [[SDLVideoStreamingCapability alloc] initWithVideoStreaming:resolution maxBitrate:maxBitrate supportedFormats:formatArray hapticDataSupported:hapticDataSupported];
SDLSystemCapability *testStruct = [[SDLSystemCapability alloc] initWithVideoStreamingCapability:testVidStruct];
expect(testStruct.systemCapabilityType).to(equal(SDLSystemCapabilityTypeVideoStreaming));
diff --git a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLVideoStreamingCapabilitySpec.m b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLVideoStreamingCapabilitySpec.m
index 1c1d4cee8..c977e0db7 100644
--- a/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLVideoStreamingCapabilitySpec.m
+++ b/SmartDeviceLinkTests/RPCSpecs/StructSpecs/SDLVideoStreamingCapabilitySpec.m
@@ -22,12 +22,12 @@ QuickSpecBegin(SDLVideoStreamingCapabilitySpec)
describe(@"Initialization tests", ^{
it(@"Should get correctly when initialized with a dictionary", ^ {
-
SDLImageResolution* resolution = [[SDLImageResolution alloc] init];
resolution.resolutionWidth = @600;
resolution.resolutionHeight = @500;
NSNumber *maxBitrate = @100;
+ NSNumber *hapticDataSupported = @NO;
SDLVideoStreamingFormat *format1 = [[SDLVideoStreamingFormat alloc] init];
format1.codec = SDLVideoStreamingCodecH264;
@@ -41,13 +41,15 @@ describe(@"Initialization tests", ^{
NSMutableDictionary* dict = [@{SDLNamePreferredResolution: resolution,
SDLNameMaxBitrate: maxBitrate,
- SDLNameSupportedFormats: formatArray} mutableCopy];
+ SDLNameSupportedFormats: formatArray,
+ SDLNameHapticSpatialDataSupported: hapticDataSupported} mutableCopy];
SDLVideoStreamingCapability* testStruct = [[SDLVideoStreamingCapability alloc] initWithDictionary:dict];
expect(testStruct.preferredResolution).to(equal(resolution));
expect(testStruct.maxBitrate).to(equal(maxBitrate));
expect(testStruct.supportedFormats).to(equal(formatArray));
+ expect(testStruct.hapticSpatialDataSupported).to(equal(hapticDataSupported));
});
it(@"Should return nil if not set", ^ {
@@ -59,12 +61,12 @@ describe(@"Initialization tests", ^{
});
it(@"Should initialize correctly with initWithVideoStreaming:(SDLImageResolution *)preferredResolution (NSNumber *)maxBitrate (NSArray<SDLVideoStreamingFormat *> *)suportedFormats", ^ {
-
SDLImageResolution* resolution = [[SDLImageResolution alloc] init];
resolution.resolutionWidth = @600;
resolution.resolutionHeight = @500;
NSNumber *maxBitrate = @100;
+ NSNumber *hapticDataSupported = @YES;
SDLVideoStreamingFormat *format1 = [[SDLVideoStreamingFormat alloc] init];
format1.codec = SDLVideoStreamingCodecH264;
@@ -76,11 +78,12 @@ describe(@"Initialization tests", ^{
NSArray<SDLVideoStreamingFormat *> *formatArray = @[format1, format2];
- SDLVideoStreamingCapability *testStruct = [[SDLVideoStreamingCapability alloc] initWithVideoStreaming:resolution maxBitrate:maxBitrate supportedFormats:formatArray];
+ SDLVideoStreamingCapability *testStruct = [[SDLVideoStreamingCapability alloc] initWithVideoStreaming:resolution maxBitrate:maxBitrate supportedFormats:formatArray hapticDataSupported:hapticDataSupported];
expect(testStruct.preferredResolution).to(equal(resolution));
expect(testStruct.maxBitrate).to(equal(maxBitrate));
expect(testStruct.supportedFormats).to(equal(formatArray));
+ expect(testStruct.hapticSpatialDataSupported).to(equal(hapticDataSupported));
});
});
diff --git a/SmartDeviceLink_Example/Classes/ProxyManager.m b/SmartDeviceLink_Example/Classes/ProxyManager.m
index 0da979b4b..a992a043d 100644
--- a/SmartDeviceLink_Example/Classes/ProxyManager.m
+++ b/SmartDeviceLink_Example/Classes/ProxyManager.m
@@ -136,6 +136,13 @@ NS_ASSUME_NONNULL_BEGIN
show.graphic = [self.class sdlex_mainGraphicImage];
[self.sdlManager sendRequest:show];
+
+ SDLHapticRect *hapticRect = [[SDLHapticRect alloc] initWithId:1 rect:[[SDLRectangle alloc] initWithX:12.34 y:42.3 width:69 height:69]];
+ SDLSendHapticData *sendHaptic = [[SDLSendHapticData alloc] initWithHapticRectData:@[hapticRect]];
+
+ [self.sdlManager sendRequest:sendHaptic withResponseHandler:^(__kindof SDLRPCRequest * _Nullable request, __kindof SDLRPCResponse * _Nullable response, NSError * _Nullable error) {
+ NSLog(@"STOP");
+ }];
}
- (void)sdlex_setupPermissionsCallbacks {