From 85dff84fad17db40b0af4445926e029c9a5f9100 Mon Sep 17 00:00:00 2001 From: Serhii Mamontov Date: Fri, 6 Dec 2019 11:31:09 +0200 Subject: [PATCH] PubNub SDK 4.12.0 Release (#422) feat(push): add APNS over HTTP/2 support Added new interfaces (builder-based API also has been modified) which allow pass device push token / identifier (not only NSData) using specific push service type. feat(push): add notification payload helper Added class which simplify basic notifications composition for multiple platforms / provides at once. feat(keychain): make PNKeychain public Make public utility class which allow to manage data in Keychain (iOS). fix(history): handle disabled storage error (#421) Handle non-JSON response from History v2 endpoints when storage add-on not enabled for used keys. --- .pubnub.yml | 20 +- CHANGELOG | 8 +- .../project.pbxproj | 837 ++++++++++++------ .../xcschemes/Framework (Fabric).xcscheme | 76 -- .../xcschemes/Framework (OSX).xcscheme | 6 +- .../xcschemes/Framework (iOS).xcscheme | 6 +- .../xcschemes/Framework (tvOS).xcscheme | 6 +- .../xcschemes/Framework (watchOS).xcscheme | 6 +- .../xcschemes/Static PubNub (Fabric).xcscheme | 76 -- .../xcschemes/Static PubNub (iOS).xcscheme | 76 -- .../xcschemes/XCFramework (Catalyst).xcscheme | 67 -- .../xcschemes/XCFramework (Fabric).xcscheme | 76 -- .../xcschemes/XCFramework (iOS).xcscheme | 76 -- .../xcschemes/XCFramework (tvOS).xcscheme | 76 -- .../xcschemes/XCFramework (watchOS).xcscheme | 76 -- Framework/PubNub/Info.plist | 6 +- Framework/PubNub/PubNub-Fabric-Info.plist | 6 +- Framework/PubNub/PubNub-iOS-Info.plist | 6 +- Framework/PubNub/PubNub-tvOS-Info.plist | 6 +- Framework/PubNub/PubNub-watchOS-Info.plist | 6 +- PubNub.podspec | 6 +- PubNub/Core/PubNub+APNS.h | 332 ++++++- PubNub/Core/PubNub+APNS.m | 531 +++++++---- PubNub/Core/PubNub+Core.h | 3 +- PubNub/Core/PubNub+Core.m | 8 +- PubNub/Core/PubNub+History.m | 17 +- .../API Call/APNS/PNAPNSAPICallBuilder.h | 12 +- .../API Call/APNS/PNAPNSAPICallBuilder.m | 16 +- .../API Call/APNS/PNAPNSAuditAPICallBuilder.h | 60 +- .../API Call/APNS/PNAPNSAuditAPICallBuilder.m | 44 +- .../APNS/PNAPNSModificationAPICallBuilder.h | 65 +- .../APNS/PNAPNSModificationAPICallBuilder.m | 46 +- PubNub/Data/Managers/PNPublishSequence.m | 6 +- PubNub/Data/Managers/PNTelemetry.h | 5 +- PubNub/Data/Managers/PNTelemetry.m | 6 + PubNub/Data/PNConfiguration.m | 14 +- PubNub/Data/PNKeychain+Private.h | 32 + PubNub/Data/PNKeychain.m | 40 +- PubNub/Data/Service Objects/PNStatus.m | 2 + .../PNAPNSNotificationConfiguration+Private.h | 24 + .../APNS/PNAPNSNotificationConfiguration.h | 65 ++ .../APNS/PNAPNSNotificationConfiguration.m | 134 +++ .../APNS/PNAPNSNotificationPayload+Private.h | 24 + .../APNS/PNAPNSNotificationPayload.h | 49 + .../APNS/PNAPNSNotificationPayload.m | 115 +++ .../APNS/PNAPNSNotificationTarget+Private.h | 24 + .../APNS/PNAPNSNotificationTarget.h | 60 ++ .../APNS/PNAPNSNotificationTarget.m | 131 +++ .../PNBaseNotificationPayload+Private.h | 76 ++ .../PNBaseNotificationPayload.h | 34 + .../PNBaseNotificationPayload.m | 108 +++ .../PNFCMNotificationPayload.h | 64 ++ .../PNFCMNotificationPayload.m | 93 ++ .../PNMPNSNotificationPayload.h | 64 ++ .../PNMPNSNotificationPayload.m | 72 ++ .../PNNotificationsPayload.h | 123 +++ .../PNNotificationsPayload.m | 183 ++++ PubNub/Misc/Helpers/PNData.h | 2 +- PubNub/Misc/Helpers/PNData.m | 2 +- PubNub/Misc/Helpers/PNDate.h | 35 + PubNub/Misc/Helpers/PNDate.m | 64 ++ PubNub/Misc/Helpers/PNHelpers.h | 1 + PubNub/Misc/PNConstants.h | 4 +- PubNub/Misc/PNPrivateStructures.h | 39 +- PubNub/Misc/PNStructures.h | 56 ++ PubNub/Network/PNNetwork.h | 5 +- PubNub/Network/PNNetwork.m | 14 +- PubNub/Network/PNURLBuilder.h | 3 +- PubNub/Network/PNURLBuilder.m | 8 +- PubNub/Network/Parsers/PNHistoryParser.m | 20 +- .../Parsers/PNPushNotificationsAuditParser.h | 36 +- .../Parsers/PNPushNotificationsAuditParser.m | 10 +- ...PushNotificationsStateModificationParser.h | 32 +- ...PushNotificationsStateModificationParser.m | 12 +- .../Message/PNRemoveMessageActionRequest.h | 2 +- .../Message/PNRemoveMessageActionRequest.m | 5 +- .../Objects/PNBaseObjectsRequest+Private.h | 17 +- .../Requests/Objects/PNBaseObjectsRequest.h | 2 +- .../Requests/Objects/PNBaseObjectsRequest.m | 20 +- PubNub/Network/Requests/PNRequest+Private.h | 19 +- PubNub/Network/Requests/PNRequest.h | 2 +- PubNub/Network/Requests/PNRequest.m | 31 +- .../PNAddPushNotificationsRequest.h | 32 + .../PNAddPushNotificationsRequest.m | 49 + .../PNAuditPushNotificationsRequest.h | 25 + .../PNAuditPushNotificationsRequest.m | 30 + .../PNBasePushNotificationsRequest.h | 85 ++ .../PNBasePushNotificationsRequest.m | 161 ++++ .../PNRemoveAllPushNotificationsRequest.h | 25 + .../PNRemoveAllPushNotificationsRequest.m | 30 + .../PNRemovePushNotificationsRequest.h | 32 + .../PNRemovePushNotificationsRequest.m | 49 + README.md | 2 +- Tests/PubNub Tests.xcodeproj/project.pbxproj | 18 + .../PNMessageActionsIntegrationTest.m | 2 + .../PNAPNSIntegrationTest.m | 771 ++++++++++++++-- Tests/iOS Tests/Tests/PNAPNSTests.m | 8 +- .../PNNotificationPayloadBuilderTest.m | 828 +++++++++++++++++ VERSION | 2 +- 99 files changed, 5485 insertions(+), 1311 deletions(-) delete mode 100644 Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/Framework (Fabric).xcscheme delete mode 100644 Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/Static PubNub (Fabric).xcscheme delete mode 100644 Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/Static PubNub (iOS).xcscheme delete mode 100644 Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/XCFramework (Catalyst).xcscheme delete mode 100644 Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/XCFramework (Fabric).xcscheme delete mode 100644 Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/XCFramework (iOS).xcscheme delete mode 100644 Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/XCFramework (tvOS).xcscheme delete mode 100644 Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/XCFramework (watchOS).xcscheme create mode 100644 PubNub/Data/PNKeychain+Private.h create mode 100644 PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationConfiguration+Private.h create mode 100644 PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationConfiguration.h create mode 100644 PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationConfiguration.m create mode 100644 PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationPayload+Private.h create mode 100644 PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationPayload.h create mode 100644 PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationPayload.m create mode 100644 PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationTarget+Private.h create mode 100644 PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationTarget.h create mode 100644 PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationTarget.m create mode 100644 PubNub/Misc/Helpers/Notifications Payload/PNBaseNotificationPayload+Private.h create mode 100644 PubNub/Misc/Helpers/Notifications Payload/PNBaseNotificationPayload.h create mode 100644 PubNub/Misc/Helpers/Notifications Payload/PNBaseNotificationPayload.m create mode 100644 PubNub/Misc/Helpers/Notifications Payload/PNFCMNotificationPayload.h create mode 100644 PubNub/Misc/Helpers/Notifications Payload/PNFCMNotificationPayload.m create mode 100644 PubNub/Misc/Helpers/Notifications Payload/PNMPNSNotificationPayload.h create mode 100644 PubNub/Misc/Helpers/Notifications Payload/PNMPNSNotificationPayload.m create mode 100644 PubNub/Misc/Helpers/Notifications Payload/PNNotificationsPayload.h create mode 100644 PubNub/Misc/Helpers/Notifications Payload/PNNotificationsPayload.m create mode 100644 PubNub/Misc/Helpers/PNDate.h create mode 100644 PubNub/Misc/Helpers/PNDate.m create mode 100644 PubNub/Network/Requests/Push Notifications/PNAddPushNotificationsRequest.h create mode 100644 PubNub/Network/Requests/Push Notifications/PNAddPushNotificationsRequest.m create mode 100644 PubNub/Network/Requests/Push Notifications/PNAuditPushNotificationsRequest.h create mode 100644 PubNub/Network/Requests/Push Notifications/PNAuditPushNotificationsRequest.m create mode 100644 PubNub/Network/Requests/Push Notifications/PNBasePushNotificationsRequest.h create mode 100644 PubNub/Network/Requests/Push Notifications/PNBasePushNotificationsRequest.m create mode 100644 PubNub/Network/Requests/Push Notifications/PNRemoveAllPushNotificationsRequest.h create mode 100644 PubNub/Network/Requests/Push Notifications/PNRemoveAllPushNotificationsRequest.m create mode 100644 PubNub/Network/Requests/Push Notifications/PNRemovePushNotificationsRequest.h create mode 100644 PubNub/Network/Requests/Push Notifications/PNRemovePushNotificationsRequest.m create mode 100644 Tests/iOS Tests/Tests/Unit/Helpers/PNNotificationPayloadBuilderTest.m diff --git a/.pubnub.yml b/.pubnub.yml index 74c6e0deb..5c61577b4 100644 --- a/.pubnub.yml +++ b/.pubnub.yml @@ -1,13 +1,29 @@ --- name: objective-c scm: github.com/pubnub/objective-c -version: "4.11.1" +version: "4.12.0" schema: 1 changelog: - changes: - - text: "Added proper Catalyst framework support with separate build target 'XCFramework (Catalyst)' which is bundled with binaries which allow it to be used for: device / simulator and macOS" + text: "Added new interfaces (builder-based API also has been modified) which allow pass device push token / identifier (not only NSData) using specific push service type." + type: feature + - + text: "Added class which simplify basic notifications composition for multiple platforms / providers at once." + type: feature + - + text: "Exposed utility class which allow to manage data in Keychain (iOS)." + type: improvement + - + text: "Fixed non-JSON response handling from History v2 endpoints when storage add-on not enabled for used keys." + type: bug + date: Dec 5, 19 + version: v4.12.0 + - + changes: + - + text: "Added proper Catalyst framework support with separate build target 'XCFramework (Catalyst)' which is bundled with binaries which allow it to be used for: device / simulator and macOS." type: feature - text: "Changed build scripts which now produce XCFrameworks with separate slices for device and simulator instead of 'fat' binaries created with 'lipo'." diff --git a/CHANGELOG b/CHANGELOG index 60ebe07cb..81040b222 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,7 +1,13 @@ +05-12-2019 - 527edf0 - 4.12.0 +. added new interfaces (builder-based API also has been modified) which allow pass device push token / identifier (not only NSData) using specific push service type. +. added class which simplify basic notifications composition for multiple platforms / providers at once. +. exposed utility class which allow to manage data in Keychain (iOS). +. fix non-JSON response handling from History v2 endpoints when storage add-on not enabled for used keys. + 25-11-2019 - 9baf80c - 4.11.1 . changed headers visibility in frameworks project from 'project' to 'public'. . changed build scripts which now produce XCFrameworks with separate slices for device and simulator instead of 'fat' binaries created with 'lipo'. -. Added proper Catalyst framework support with separate build target 'XCFramework (Catalyst)' which is bundled with binaries which allow it to be used for: device / simulator and macOS. +. added proper Catalyst framework support with separate build target 'XCFramework (Catalyst)' which is bundled with binaries which allow it to be used for: device / simulator and macOS. 08-10-2019 - baef53b - 4.11.0 . add Message Actions API support which allow to: add, remove and fetch previously added actions. diff --git a/Framework/PubNub Framework.xcodeproj/project.pbxproj b/Framework/PubNub Framework.xcodeproj/project.pbxproj index d15a209ea..fc32c3cdb 100644 --- a/Framework/PubNub Framework.xcodeproj/project.pbxproj +++ b/Framework/PubNub Framework.xcodeproj/project.pbxproj @@ -73,7 +73,7 @@ }; A57A2FF3238A04F500DE8C68 /* XCFramework (Catalyst) */ = { isa = PBXAggregateTarget; - buildConfigurationList = A57A2FF6238A04F500DE8C68 /* Build configuration list for PBXAggregateTarget "XCFramework (Catalyst)" */; + buildConfigurationList = A57A3056238D61E600DE8C68 /* Build configuration list for PBXAggregateTarget "XCFramework (Catalyst)" */; buildPhases = ( A57A2FF4238A04F500DE8C68 /* Build Universal Binary */, A57A2FF5238A04F500DE8C68 /* Cleanup CocoaPods scripts */, @@ -1279,7 +1279,7 @@ 79A8BC911C58F93900015BDE /* PNJSON.h in Headers */ = {isa = PBXBuildFile; fileRef = 79CBB0B91BD03DE4001FC34D /* PNJSON.h */; }; 79A8BC921C58F93900015BDE /* PNTimeParser.h in Headers */ = {isa = PBXBuildFile; fileRef = 79CBB0EC1BD03DE4001FC34D /* PNTimeParser.h */; }; 79A8BC931C58F93900015BDE /* PNGZIP.h in Headers */ = {isa = PBXBuildFile; fileRef = 79CBB0B61BD03DE4001FC34D /* PNGZIP.h */; }; - 79A8BC941C58F93900015BDE /* PNKeychain.h in Headers */ = {isa = PBXBuildFile; fileRef = 79E2D0EC1C56434700BAA244 /* PNKeychain.h */; }; + 79A8BC941C58F93900015BDE /* PNKeychain.h in Headers */ = {isa = PBXBuildFile; fileRef = 79E2D0EC1C56434700BAA244 /* PNKeychain.h */; settings = {ATTRIBUTES = (Public, ); }; }; 79A8BC951C58F93900015BDE /* PNURLBuilder.h in Headers */ = {isa = PBXBuildFile; fileRef = 79CBB0F61BD03DE4001FC34D /* PNURLBuilder.h */; }; 79A8BC961C58F93900015BDE /* PNHelpers.h in Headers */ = {isa = PBXBuildFile; fileRef = 79CBB0B81BD03DE4001FC34D /* PNHelpers.h */; }; 79A8BC981C58F93900015BDE /* PNReachability.h in Headers */ = {isa = PBXBuildFile; fileRef = 79CBB0F21BD03DE4001FC34D /* PNReachability.h */; }; @@ -1642,12 +1642,12 @@ 79E20D2A1C8AEFF5001BC9CC /* PNSubscribeStatus+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = 79E20D231C8AEC5B001BC9CC /* PNSubscribeStatus+Private.h */; }; 79E20D2B1C8B0A70001BC9CC /* PNPresenceChannelGroupHereNowResult.h in Headers */ = {isa = PBXBuildFile; fileRef = 79CBB0901BD03DE4001FC34D /* PNPresenceChannelGroupHereNowResult.h */; settings = {ATTRIBUTES = (Public, ); }; }; 79E20D2C1C8B0AD5001BC9CC /* PNPushNotificationsStateModificationParser.h in Headers */ = {isa = PBXBuildFile; fileRef = 79CBB0E61BD03DE4001FC34D /* PNPushNotificationsStateModificationParser.h */; }; - 79E2D0EE1C56434700BAA244 /* PNKeychain.h in Headers */ = {isa = PBXBuildFile; fileRef = 79E2D0EC1C56434700BAA244 /* PNKeychain.h */; }; - 79E2D0EF1C56434700BAA244 /* PNKeychain.h in Headers */ = {isa = PBXBuildFile; fileRef = 79E2D0EC1C56434700BAA244 /* PNKeychain.h */; }; - 79E2D0F01C56434700BAA244 /* PNKeychain.h in Headers */ = {isa = PBXBuildFile; fileRef = 79E2D0EC1C56434700BAA244 /* PNKeychain.h */; }; - 79E2D0F11C56434700BAA244 /* PNKeychain.h in Headers */ = {isa = PBXBuildFile; fileRef = 79E2D0EC1C56434700BAA244 /* PNKeychain.h */; }; - 79E2D0F21C56434700BAA244 /* PNKeychain.h in Headers */ = {isa = PBXBuildFile; fileRef = 79E2D0EC1C56434700BAA244 /* PNKeychain.h */; }; - 79E2D0F31C56434700BAA244 /* PNKeychain.h in Headers */ = {isa = PBXBuildFile; fileRef = 79E2D0EC1C56434700BAA244 /* PNKeychain.h */; }; + 79E2D0EE1C56434700BAA244 /* PNKeychain.h in Headers */ = {isa = PBXBuildFile; fileRef = 79E2D0EC1C56434700BAA244 /* PNKeychain.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 79E2D0EF1C56434700BAA244 /* PNKeychain.h in Headers */ = {isa = PBXBuildFile; fileRef = 79E2D0EC1C56434700BAA244 /* PNKeychain.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 79E2D0F01C56434700BAA244 /* PNKeychain.h in Headers */ = {isa = PBXBuildFile; fileRef = 79E2D0EC1C56434700BAA244 /* PNKeychain.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 79E2D0F11C56434700BAA244 /* PNKeychain.h in Headers */ = {isa = PBXBuildFile; fileRef = 79E2D0EC1C56434700BAA244 /* PNKeychain.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 79E2D0F21C56434700BAA244 /* PNKeychain.h in Headers */ = {isa = PBXBuildFile; fileRef = 79E2D0EC1C56434700BAA244 /* PNKeychain.h */; settings = {ATTRIBUTES = (Public, ); }; }; + 79E2D0F31C56434700BAA244 /* PNKeychain.h in Headers */ = {isa = PBXBuildFile; fileRef = 79E2D0EC1C56434700BAA244 /* PNKeychain.h */; settings = {ATTRIBUTES = (Public, ); }; }; 79E2D0F41C56434700BAA244 /* PNKeychain.m in Sources */ = {isa = PBXBuildFile; fileRef = 79E2D0ED1C56434700BAA244 /* PNKeychain.m */; }; 79E2D0F51C56434700BAA244 /* PNKeychain.m in Sources */ = {isa = PBXBuildFile; fileRef = 79E2D0ED1C56434700BAA244 /* PNKeychain.m */; }; 79E2D0F61C56434700BAA244 /* PNKeychain.m in Sources */ = {isa = PBXBuildFile; fileRef = 79E2D0ED1C56434700BAA244 /* PNKeychain.m */; }; @@ -1680,6 +1680,20 @@ 79F90F241FDEC1DE007132A3 /* PNPresenceHeartbeatAPICallBuilder.m in Sources */ = {isa = PBXBuildFile; fileRef = 79F90F171FDEC1B9007132A3 /* PNPresenceHeartbeatAPICallBuilder.m */; }; 79F90F251FDEC1DE007132A3 /* PNPresenceHeartbeatAPICallBuilder.m in Sources */ = {isa = PBXBuildFile; fileRef = 79F90F171FDEC1B9007132A3 /* PNPresenceHeartbeatAPICallBuilder.m */; }; 79F90F261FDEC1DE007132A3 /* PNPresenceHeartbeatAPICallBuilder.m in Sources */ = {isa = PBXBuildFile; fileRef = 79F90F171FDEC1B9007132A3 /* PNPresenceHeartbeatAPICallBuilder.m */; }; + A5105B50238F027D00CB693D /* PNDate.h in Headers */ = {isa = PBXBuildFile; fileRef = A5105B4E238F027D00CB693D /* PNDate.h */; }; + A5105B51238F027D00CB693D /* PNDate.h in Headers */ = {isa = PBXBuildFile; fileRef = A5105B4E238F027D00CB693D /* PNDate.h */; }; + A5105B52238F027D00CB693D /* PNDate.h in Headers */ = {isa = PBXBuildFile; fileRef = A5105B4E238F027D00CB693D /* PNDate.h */; }; + A5105B53238F027D00CB693D /* PNDate.h in Headers */ = {isa = PBXBuildFile; fileRef = A5105B4E238F027D00CB693D /* PNDate.h */; }; + A5105B54238F027D00CB693D /* PNDate.h in Headers */ = {isa = PBXBuildFile; fileRef = A5105B4E238F027D00CB693D /* PNDate.h */; }; + A5105B55238F027D00CB693D /* PNDate.h in Headers */ = {isa = PBXBuildFile; fileRef = A5105B4E238F027D00CB693D /* PNDate.h */; }; + A5105B56238F027D00CB693D /* PNDate.h in Headers */ = {isa = PBXBuildFile; fileRef = A5105B4E238F027D00CB693D /* PNDate.h */; }; + A5105B57238F027D00CB693D /* PNDate.m in Sources */ = {isa = PBXBuildFile; fileRef = A5105B4F238F027D00CB693D /* PNDate.m */; }; + A5105B58238F027D00CB693D /* PNDate.m in Sources */ = {isa = PBXBuildFile; fileRef = A5105B4F238F027D00CB693D /* PNDate.m */; }; + A5105B59238F027D00CB693D /* PNDate.m in Sources */ = {isa = PBXBuildFile; fileRef = A5105B4F238F027D00CB693D /* PNDate.m */; }; + A5105B5A238F027D00CB693D /* PNDate.m in Sources */ = {isa = PBXBuildFile; fileRef = A5105B4F238F027D00CB693D /* PNDate.m */; }; + A5105B5B238F027D00CB693D /* PNDate.m in Sources */ = {isa = PBXBuildFile; fileRef = A5105B4F238F027D00CB693D /* PNDate.m */; }; + A5105B5C238F027D00CB693D /* PNDate.m in Sources */ = {isa = PBXBuildFile; fileRef = A5105B4F238F027D00CB693D /* PNDate.m */; }; + A5105B5D238F027D00CB693D /* PNDate.m in Sources */ = {isa = PBXBuildFile; fileRef = A5105B4F238F027D00CB693D /* PNDate.m */; }; A52DC1E62307E10B001F20B0 /* NSDateFormatter+PNCacheable.h in Headers */ = {isa = PBXBuildFile; fileRef = A52DC1E42307E10B001F20B0 /* NSDateFormatter+PNCacheable.h */; }; A52DC1E72307E10B001F20B0 /* NSDateFormatter+PNCacheable.h in Headers */ = {isa = PBXBuildFile; fileRef = A52DC1E42307E10B001F20B0 /* NSDateFormatter+PNCacheable.h */; }; A52DC1E82307E10B001F20B0 /* NSDateFormatter+PNCacheable.h in Headers */ = {isa = PBXBuildFile; fileRef = A52DC1E42307E10B001F20B0 /* NSDateFormatter+PNCacheable.h */; }; @@ -2338,6 +2352,13 @@ A55BCD29231D27F00019DB68 /* PNMessageAction+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A55BCD24231D27F00019DB68 /* PNMessageAction+Private.h */; }; A55BCD2A231D27F00019DB68 /* PNMessageAction+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A55BCD24231D27F00019DB68 /* PNMessageAction+Private.h */; }; A55BCD2B231D27F00019DB68 /* PNMessageAction+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A55BCD24231D27F00019DB68 /* PNMessageAction+Private.h */; }; + A55CA69D2397389100B24E02 /* PNKeychain+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A55CA69C2397389100B24E02 /* PNKeychain+Private.h */; }; + A55CA69E2397389100B24E02 /* PNKeychain+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A55CA69C2397389100B24E02 /* PNKeychain+Private.h */; }; + A55CA69F2397389100B24E02 /* PNKeychain+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A55CA69C2397389100B24E02 /* PNKeychain+Private.h */; }; + A55CA6A02397389100B24E02 /* PNKeychain+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A55CA69C2397389100B24E02 /* PNKeychain+Private.h */; }; + A55CA6A12397389100B24E02 /* PNKeychain+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A55CA69C2397389100B24E02 /* PNKeychain+Private.h */; }; + A55CA6A22397389100B24E02 /* PNKeychain+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A55CA69C2397389100B24E02 /* PNKeychain+Private.h */; }; + A55CA6A32397389100B24E02 /* PNKeychain+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A55CA69C2397389100B24E02 /* PNKeychain+Private.h */; }; A56865602300622C0014E17C /* PNMember+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A568655F2300622C0014E17C /* PNMember+Private.h */; }; A56865612300622C0014E17C /* PNMember+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A568655F2300622C0014E17C /* PNMember+Private.h */; }; A56865622300622C0014E17C /* PNMember+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A568655F2300622C0014E17C /* PNMember+Private.h */; }; @@ -2485,6 +2506,202 @@ A56FAEFD233161570072ADD6 /* PubNub+MessageActions.m in Sources */ = {isa = PBXBuildFile; fileRef = A56FAEF1233161570072ADD6 /* PubNub+MessageActions.m */; }; A56FAEFE233161570072ADD6 /* PubNub+MessageActions.m in Sources */ = {isa = PBXBuildFile; fileRef = A56FAEF1233161570072ADD6 /* PubNub+MessageActions.m */; }; A56FAEFF233161570072ADD6 /* PubNub+MessageActions.m in Sources */ = {isa = PBXBuildFile; fileRef = A56FAEF1233161570072ADD6 /* PubNub+MessageActions.m */; }; + A57A300D238D59B500DE8C68 /* PNAddPushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3003238D59B500DE8C68 /* PNAddPushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A300E238D59B500DE8C68 /* PNAddPushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3003238D59B500DE8C68 /* PNAddPushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A300F238D59B500DE8C68 /* PNAddPushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3003238D59B500DE8C68 /* PNAddPushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A3010238D59B500DE8C68 /* PNAddPushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3003238D59B500DE8C68 /* PNAddPushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A3011238D59B500DE8C68 /* PNAddPushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3003238D59B500DE8C68 /* PNAddPushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A3012238D59B500DE8C68 /* PNAddPushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3003238D59B500DE8C68 /* PNAddPushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A3013238D59B500DE8C68 /* PNAddPushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3003238D59B500DE8C68 /* PNAddPushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A3014238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3004238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.m */; }; + A57A3015238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3004238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.m */; }; + A57A3016238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3004238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.m */; }; + A57A3017238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3004238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.m */; }; + A57A3018238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3004238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.m */; }; + A57A3019238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3004238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.m */; }; + A57A301A238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3004238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.m */; }; + A57A301B238D59B500DE8C68 /* PNAuditPushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3005238D59B500DE8C68 /* PNAuditPushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A301C238D59B500DE8C68 /* PNAuditPushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3005238D59B500DE8C68 /* PNAuditPushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A301D238D59B500DE8C68 /* PNAuditPushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3005238D59B500DE8C68 /* PNAuditPushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A301E238D59B500DE8C68 /* PNAuditPushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3005238D59B500DE8C68 /* PNAuditPushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A301F238D59B500DE8C68 /* PNAuditPushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3005238D59B500DE8C68 /* PNAuditPushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A3020238D59B500DE8C68 /* PNAuditPushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3005238D59B500DE8C68 /* PNAuditPushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A3021238D59B500DE8C68 /* PNAuditPushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3005238D59B500DE8C68 /* PNAuditPushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A3022238D59B500DE8C68 /* PNRemovePushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3006238D59B500DE8C68 /* PNRemovePushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A3023238D59B500DE8C68 /* PNRemovePushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3006238D59B500DE8C68 /* PNRemovePushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A3024238D59B500DE8C68 /* PNRemovePushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3006238D59B500DE8C68 /* PNRemovePushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A3025238D59B500DE8C68 /* PNRemovePushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3006238D59B500DE8C68 /* PNRemovePushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A3026238D59B500DE8C68 /* PNRemovePushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3006238D59B500DE8C68 /* PNRemovePushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A3027238D59B500DE8C68 /* PNRemovePushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3006238D59B500DE8C68 /* PNRemovePushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A3028238D59B500DE8C68 /* PNRemovePushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3006238D59B500DE8C68 /* PNRemovePushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A3029238D59B500DE8C68 /* PNBasePushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3007238D59B500DE8C68 /* PNBasePushNotificationsRequest.m */; }; + A57A302A238D59B500DE8C68 /* PNBasePushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3007238D59B500DE8C68 /* PNBasePushNotificationsRequest.m */; }; + A57A302B238D59B500DE8C68 /* PNBasePushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3007238D59B500DE8C68 /* PNBasePushNotificationsRequest.m */; }; + A57A302C238D59B500DE8C68 /* PNBasePushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3007238D59B500DE8C68 /* PNBasePushNotificationsRequest.m */; }; + A57A302D238D59B500DE8C68 /* PNBasePushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3007238D59B500DE8C68 /* PNBasePushNotificationsRequest.m */; }; + A57A302E238D59B500DE8C68 /* PNBasePushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3007238D59B500DE8C68 /* PNBasePushNotificationsRequest.m */; }; + A57A302F238D59B500DE8C68 /* PNBasePushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3007238D59B500DE8C68 /* PNBasePushNotificationsRequest.m */; }; + A57A3030238D59B500DE8C68 /* PNAddPushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3008238D59B500DE8C68 /* PNAddPushNotificationsRequest.m */; }; + A57A3031238D59B500DE8C68 /* PNAddPushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3008238D59B500DE8C68 /* PNAddPushNotificationsRequest.m */; }; + A57A3032238D59B500DE8C68 /* PNAddPushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3008238D59B500DE8C68 /* PNAddPushNotificationsRequest.m */; }; + A57A3033238D59B500DE8C68 /* PNAddPushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3008238D59B500DE8C68 /* PNAddPushNotificationsRequest.m */; }; + A57A3034238D59B500DE8C68 /* PNAddPushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3008238D59B500DE8C68 /* PNAddPushNotificationsRequest.m */; }; + A57A3035238D59B500DE8C68 /* PNAddPushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3008238D59B500DE8C68 /* PNAddPushNotificationsRequest.m */; }; + A57A3036238D59B500DE8C68 /* PNAddPushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3008238D59B500DE8C68 /* PNAddPushNotificationsRequest.m */; }; + A57A3037238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3009238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A3038238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3009238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A3039238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3009238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A303A238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3009238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A303B238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3009238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A303C238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3009238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A303D238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3009238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A303E238D59B500DE8C68 /* PNRemovePushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A300A238D59B500DE8C68 /* PNRemovePushNotificationsRequest.m */; }; + A57A303F238D59B500DE8C68 /* PNRemovePushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A300A238D59B500DE8C68 /* PNRemovePushNotificationsRequest.m */; }; + A57A3040238D59B500DE8C68 /* PNRemovePushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A300A238D59B500DE8C68 /* PNRemovePushNotificationsRequest.m */; }; + A57A3041238D59B500DE8C68 /* PNRemovePushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A300A238D59B500DE8C68 /* PNRemovePushNotificationsRequest.m */; }; + A57A3042238D59B500DE8C68 /* PNRemovePushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A300A238D59B500DE8C68 /* PNRemovePushNotificationsRequest.m */; }; + A57A3043238D59B500DE8C68 /* PNRemovePushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A300A238D59B500DE8C68 /* PNRemovePushNotificationsRequest.m */; }; + A57A3044238D59B500DE8C68 /* PNRemovePushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A300A238D59B500DE8C68 /* PNRemovePushNotificationsRequest.m */; }; + A57A3045238D59B500DE8C68 /* PNAuditPushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A300B238D59B500DE8C68 /* PNAuditPushNotificationsRequest.m */; }; + A57A3046238D59B500DE8C68 /* PNAuditPushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A300B238D59B500DE8C68 /* PNAuditPushNotificationsRequest.m */; }; + A57A3047238D59B500DE8C68 /* PNAuditPushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A300B238D59B500DE8C68 /* PNAuditPushNotificationsRequest.m */; }; + A57A3048238D59B500DE8C68 /* PNAuditPushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A300B238D59B500DE8C68 /* PNAuditPushNotificationsRequest.m */; }; + A57A3049238D59B500DE8C68 /* PNAuditPushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A300B238D59B500DE8C68 /* PNAuditPushNotificationsRequest.m */; }; + A57A304A238D59B500DE8C68 /* PNAuditPushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A300B238D59B500DE8C68 /* PNAuditPushNotificationsRequest.m */; }; + A57A304B238D59B500DE8C68 /* PNAuditPushNotificationsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A300B238D59B500DE8C68 /* PNAuditPushNotificationsRequest.m */; }; + A57A304C238D59B500DE8C68 /* PNBasePushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A300C238D59B500DE8C68 /* PNBasePushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A304D238D59B500DE8C68 /* PNBasePushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A300C238D59B500DE8C68 /* PNBasePushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A304E238D59B500DE8C68 /* PNBasePushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A300C238D59B500DE8C68 /* PNBasePushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A304F238D59B500DE8C68 /* PNBasePushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A300C238D59B500DE8C68 /* PNBasePushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A3050238D59B500DE8C68 /* PNBasePushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A300C238D59B500DE8C68 /* PNBasePushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A3051238D59B500DE8C68 /* PNBasePushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A300C238D59B500DE8C68 /* PNBasePushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A3052238D59B500DE8C68 /* PNBasePushNotificationsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A300C238D59B500DE8C68 /* PNBasePushNotificationsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A3059238D65A200DE8C68 /* PNNotificationsPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3057238D65A200DE8C68 /* PNNotificationsPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A305A238D65A200DE8C68 /* PNNotificationsPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3057238D65A200DE8C68 /* PNNotificationsPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A305B238D65A200DE8C68 /* PNNotificationsPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3057238D65A200DE8C68 /* PNNotificationsPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A305C238D65A200DE8C68 /* PNNotificationsPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3057238D65A200DE8C68 /* PNNotificationsPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A305D238D65A200DE8C68 /* PNNotificationsPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3057238D65A200DE8C68 /* PNNotificationsPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A305E238D65A200DE8C68 /* PNNotificationsPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3057238D65A200DE8C68 /* PNNotificationsPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A305F238D65A200DE8C68 /* PNNotificationsPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3057238D65A200DE8C68 /* PNNotificationsPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A3060238D65A200DE8C68 /* PNNotificationsPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3058238D65A200DE8C68 /* PNNotificationsPayload.m */; }; + A57A3061238D65A200DE8C68 /* PNNotificationsPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3058238D65A200DE8C68 /* PNNotificationsPayload.m */; }; + A57A3062238D65A200DE8C68 /* PNNotificationsPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3058238D65A200DE8C68 /* PNNotificationsPayload.m */; }; + A57A3063238D65A200DE8C68 /* PNNotificationsPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3058238D65A200DE8C68 /* PNNotificationsPayload.m */; }; + A57A3064238D65A200DE8C68 /* PNNotificationsPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3058238D65A200DE8C68 /* PNNotificationsPayload.m */; }; + A57A3065238D65A200DE8C68 /* PNNotificationsPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3058238D65A200DE8C68 /* PNNotificationsPayload.m */; }; + A57A3066238D65A200DE8C68 /* PNNotificationsPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3058238D65A200DE8C68 /* PNNotificationsPayload.m */; }; + A57A3069238D6BCC00DE8C68 /* PNFCMNotificationPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3067238D6BCC00DE8C68 /* PNFCMNotificationPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A306A238D6BCC00DE8C68 /* PNFCMNotificationPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3067238D6BCC00DE8C68 /* PNFCMNotificationPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A306B238D6BCC00DE8C68 /* PNFCMNotificationPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3067238D6BCC00DE8C68 /* PNFCMNotificationPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A306C238D6BCC00DE8C68 /* PNFCMNotificationPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3067238D6BCC00DE8C68 /* PNFCMNotificationPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A306D238D6BCC00DE8C68 /* PNFCMNotificationPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3067238D6BCC00DE8C68 /* PNFCMNotificationPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A306E238D6BCC00DE8C68 /* PNFCMNotificationPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3067238D6BCC00DE8C68 /* PNFCMNotificationPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A306F238D6BCC00DE8C68 /* PNFCMNotificationPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3067238D6BCC00DE8C68 /* PNFCMNotificationPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A3070238D6BCC00DE8C68 /* PNFCMNotificationPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3068238D6BCC00DE8C68 /* PNFCMNotificationPayload.m */; }; + A57A3071238D6BCC00DE8C68 /* PNFCMNotificationPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3068238D6BCC00DE8C68 /* PNFCMNotificationPayload.m */; }; + A57A3072238D6BCC00DE8C68 /* PNFCMNotificationPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3068238D6BCC00DE8C68 /* PNFCMNotificationPayload.m */; }; + A57A3073238D6BCC00DE8C68 /* PNFCMNotificationPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3068238D6BCC00DE8C68 /* PNFCMNotificationPayload.m */; }; + A57A3074238D6BCC00DE8C68 /* PNFCMNotificationPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3068238D6BCC00DE8C68 /* PNFCMNotificationPayload.m */; }; + A57A3075238D6BCC00DE8C68 /* PNFCMNotificationPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3068238D6BCC00DE8C68 /* PNFCMNotificationPayload.m */; }; + A57A3076238D6BCC00DE8C68 /* PNFCMNotificationPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3068238D6BCC00DE8C68 /* PNFCMNotificationPayload.m */; }; + A57A3089238D751400DE8C68 /* PNMPNSNotificationPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3087238D751400DE8C68 /* PNMPNSNotificationPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A308A238D751400DE8C68 /* PNMPNSNotificationPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3087238D751400DE8C68 /* PNMPNSNotificationPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A308B238D751400DE8C68 /* PNMPNSNotificationPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3087238D751400DE8C68 /* PNMPNSNotificationPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A308C238D751400DE8C68 /* PNMPNSNotificationPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3087238D751400DE8C68 /* PNMPNSNotificationPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A308D238D751400DE8C68 /* PNMPNSNotificationPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3087238D751400DE8C68 /* PNMPNSNotificationPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A308E238D751400DE8C68 /* PNMPNSNotificationPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3087238D751400DE8C68 /* PNMPNSNotificationPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A308F238D751400DE8C68 /* PNMPNSNotificationPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3087238D751400DE8C68 /* PNMPNSNotificationPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A3090238D751400DE8C68 /* PNMPNSNotificationPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3088238D751400DE8C68 /* PNMPNSNotificationPayload.m */; }; + A57A3091238D751400DE8C68 /* PNMPNSNotificationPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3088238D751400DE8C68 /* PNMPNSNotificationPayload.m */; }; + A57A3092238D751400DE8C68 /* PNMPNSNotificationPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3088238D751400DE8C68 /* PNMPNSNotificationPayload.m */; }; + A57A3093238D751400DE8C68 /* PNMPNSNotificationPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3088238D751400DE8C68 /* PNMPNSNotificationPayload.m */; }; + A57A3094238D751400DE8C68 /* PNMPNSNotificationPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3088238D751400DE8C68 /* PNMPNSNotificationPayload.m */; }; + A57A3095238D751400DE8C68 /* PNMPNSNotificationPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3088238D751400DE8C68 /* PNMPNSNotificationPayload.m */; }; + A57A3096238D751400DE8C68 /* PNMPNSNotificationPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3088238D751400DE8C68 /* PNMPNSNotificationPayload.m */; }; + A57A3099238D784A00DE8C68 /* PNBaseNotificationPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3097238D784A00DE8C68 /* PNBaseNotificationPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A309A238D784A00DE8C68 /* PNBaseNotificationPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3097238D784A00DE8C68 /* PNBaseNotificationPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A309B238D784A00DE8C68 /* PNBaseNotificationPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3097238D784A00DE8C68 /* PNBaseNotificationPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A309C238D784A00DE8C68 /* PNBaseNotificationPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3097238D784A00DE8C68 /* PNBaseNotificationPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A309D238D784A00DE8C68 /* PNBaseNotificationPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3097238D784A00DE8C68 /* PNBaseNotificationPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A309E238D784A00DE8C68 /* PNBaseNotificationPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3097238D784A00DE8C68 /* PNBaseNotificationPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A309F238D784A00DE8C68 /* PNBaseNotificationPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A3097238D784A00DE8C68 /* PNBaseNotificationPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A30A0238D784A00DE8C68 /* PNBaseNotificationPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3098238D784A00DE8C68 /* PNBaseNotificationPayload.m */; }; + A57A30A1238D784A00DE8C68 /* PNBaseNotificationPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3098238D784A00DE8C68 /* PNBaseNotificationPayload.m */; }; + A57A30A2238D784A00DE8C68 /* PNBaseNotificationPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3098238D784A00DE8C68 /* PNBaseNotificationPayload.m */; }; + A57A30A3238D784A00DE8C68 /* PNBaseNotificationPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3098238D784A00DE8C68 /* PNBaseNotificationPayload.m */; }; + A57A30A4238D784A00DE8C68 /* PNBaseNotificationPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3098238D784A00DE8C68 /* PNBaseNotificationPayload.m */; }; + A57A30A5238D784A00DE8C68 /* PNBaseNotificationPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3098238D784A00DE8C68 /* PNBaseNotificationPayload.m */; }; + A57A30A6238D784A00DE8C68 /* PNBaseNotificationPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A3098238D784A00DE8C68 /* PNBaseNotificationPayload.m */; }; + A57A30A8238D78C400DE8C68 /* PNBaseNotificationPayload+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30A7238D78C400DE8C68 /* PNBaseNotificationPayload+Private.h */; }; + A57A30A9238D78C400DE8C68 /* PNBaseNotificationPayload+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30A7238D78C400DE8C68 /* PNBaseNotificationPayload+Private.h */; }; + A57A30AA238D78C400DE8C68 /* PNBaseNotificationPayload+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30A7238D78C400DE8C68 /* PNBaseNotificationPayload+Private.h */; }; + A57A30AB238D78C400DE8C68 /* PNBaseNotificationPayload+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30A7238D78C400DE8C68 /* PNBaseNotificationPayload+Private.h */; }; + A57A30AC238D78C400DE8C68 /* PNBaseNotificationPayload+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30A7238D78C400DE8C68 /* PNBaseNotificationPayload+Private.h */; }; + A57A30AD238D78C400DE8C68 /* PNBaseNotificationPayload+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30A7238D78C400DE8C68 /* PNBaseNotificationPayload+Private.h */; }; + A57A30AE238D78C400DE8C68 /* PNBaseNotificationPayload+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30A7238D78C400DE8C68 /* PNBaseNotificationPayload+Private.h */; }; + A57A30B2238DC6B600DE8C68 /* PNAPNSNotificationPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30B0238DC6B600DE8C68 /* PNAPNSNotificationPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A30B3238DC6B600DE8C68 /* PNAPNSNotificationPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30B0238DC6B600DE8C68 /* PNAPNSNotificationPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A30B4238DC6B600DE8C68 /* PNAPNSNotificationPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30B0238DC6B600DE8C68 /* PNAPNSNotificationPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A30B5238DC6B600DE8C68 /* PNAPNSNotificationPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30B0238DC6B600DE8C68 /* PNAPNSNotificationPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A30B6238DC6B600DE8C68 /* PNAPNSNotificationPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30B0238DC6B600DE8C68 /* PNAPNSNotificationPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A30B7238DC6B600DE8C68 /* PNAPNSNotificationPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30B0238DC6B600DE8C68 /* PNAPNSNotificationPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A30B8238DC6B600DE8C68 /* PNAPNSNotificationPayload.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30B0238DC6B600DE8C68 /* PNAPNSNotificationPayload.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A30B9238DC6B600DE8C68 /* PNAPNSNotificationPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A30B1238DC6B600DE8C68 /* PNAPNSNotificationPayload.m */; }; + A57A30BA238DC6B600DE8C68 /* PNAPNSNotificationPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A30B1238DC6B600DE8C68 /* PNAPNSNotificationPayload.m */; }; + A57A30BB238DC6B600DE8C68 /* PNAPNSNotificationPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A30B1238DC6B600DE8C68 /* PNAPNSNotificationPayload.m */; }; + A57A30BC238DC6B600DE8C68 /* PNAPNSNotificationPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A30B1238DC6B600DE8C68 /* PNAPNSNotificationPayload.m */; }; + A57A30BD238DC6B600DE8C68 /* PNAPNSNotificationPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A30B1238DC6B600DE8C68 /* PNAPNSNotificationPayload.m */; }; + A57A30BE238DC6B600DE8C68 /* PNAPNSNotificationPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A30B1238DC6B600DE8C68 /* PNAPNSNotificationPayload.m */; }; + A57A30BF238DC6B600DE8C68 /* PNAPNSNotificationPayload.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A30B1238DC6B600DE8C68 /* PNAPNSNotificationPayload.m */; }; + A57A30C2238DC71800DE8C68 /* PNAPNSNotificationConfiguration.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30C0238DC71800DE8C68 /* PNAPNSNotificationConfiguration.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A30C3238DC71800DE8C68 /* PNAPNSNotificationConfiguration.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30C0238DC71800DE8C68 /* PNAPNSNotificationConfiguration.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A30C4238DC71800DE8C68 /* PNAPNSNotificationConfiguration.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30C0238DC71800DE8C68 /* PNAPNSNotificationConfiguration.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A30C5238DC71800DE8C68 /* PNAPNSNotificationConfiguration.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30C0238DC71800DE8C68 /* PNAPNSNotificationConfiguration.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A30C6238DC71800DE8C68 /* PNAPNSNotificationConfiguration.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30C0238DC71800DE8C68 /* PNAPNSNotificationConfiguration.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A30C7238DC71800DE8C68 /* PNAPNSNotificationConfiguration.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30C0238DC71800DE8C68 /* PNAPNSNotificationConfiguration.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A30C8238DC71800DE8C68 /* PNAPNSNotificationConfiguration.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30C0238DC71800DE8C68 /* PNAPNSNotificationConfiguration.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A30C9238DC71800DE8C68 /* PNAPNSNotificationConfiguration.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A30C1238DC71800DE8C68 /* PNAPNSNotificationConfiguration.m */; }; + A57A30CA238DC71800DE8C68 /* PNAPNSNotificationConfiguration.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A30C1238DC71800DE8C68 /* PNAPNSNotificationConfiguration.m */; }; + A57A30CB238DC71800DE8C68 /* PNAPNSNotificationConfiguration.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A30C1238DC71800DE8C68 /* PNAPNSNotificationConfiguration.m */; }; + A57A30CC238DC71800DE8C68 /* PNAPNSNotificationConfiguration.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A30C1238DC71800DE8C68 /* PNAPNSNotificationConfiguration.m */; }; + A57A30CD238DC71800DE8C68 /* PNAPNSNotificationConfiguration.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A30C1238DC71800DE8C68 /* PNAPNSNotificationConfiguration.m */; }; + A57A30CE238DC71800DE8C68 /* PNAPNSNotificationConfiguration.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A30C1238DC71800DE8C68 /* PNAPNSNotificationConfiguration.m */; }; + A57A30CF238DC71800DE8C68 /* PNAPNSNotificationConfiguration.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A30C1238DC71800DE8C68 /* PNAPNSNotificationConfiguration.m */; }; + A57A30D1238DC7FF00DE8C68 /* PNAPNSNotificationConfiguration+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30D0238DC7FF00DE8C68 /* PNAPNSNotificationConfiguration+Private.h */; }; + A57A30D2238DC7FF00DE8C68 /* PNAPNSNotificationConfiguration+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30D0238DC7FF00DE8C68 /* PNAPNSNotificationConfiguration+Private.h */; }; + A57A30D3238DC7FF00DE8C68 /* PNAPNSNotificationConfiguration+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30D0238DC7FF00DE8C68 /* PNAPNSNotificationConfiguration+Private.h */; }; + A57A30D4238DC7FF00DE8C68 /* PNAPNSNotificationConfiguration+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30D0238DC7FF00DE8C68 /* PNAPNSNotificationConfiguration+Private.h */; }; + A57A30D5238DC7FF00DE8C68 /* PNAPNSNotificationConfiguration+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30D0238DC7FF00DE8C68 /* PNAPNSNotificationConfiguration+Private.h */; }; + A57A30D6238DC7FF00DE8C68 /* PNAPNSNotificationConfiguration+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30D0238DC7FF00DE8C68 /* PNAPNSNotificationConfiguration+Private.h */; }; + A57A30D7238DC7FF00DE8C68 /* PNAPNSNotificationConfiguration+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30D0238DC7FF00DE8C68 /* PNAPNSNotificationConfiguration+Private.h */; }; + A57A30DA238DC87400DE8C68 /* PNAPNSNotificationTarget.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30D8238DC87400DE8C68 /* PNAPNSNotificationTarget.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A30DB238DC87400DE8C68 /* PNAPNSNotificationTarget.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30D8238DC87400DE8C68 /* PNAPNSNotificationTarget.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A30DC238DC87400DE8C68 /* PNAPNSNotificationTarget.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30D8238DC87400DE8C68 /* PNAPNSNotificationTarget.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A30DD238DC87400DE8C68 /* PNAPNSNotificationTarget.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30D8238DC87400DE8C68 /* PNAPNSNotificationTarget.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A30DE238DC87400DE8C68 /* PNAPNSNotificationTarget.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30D8238DC87400DE8C68 /* PNAPNSNotificationTarget.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A30DF238DC87400DE8C68 /* PNAPNSNotificationTarget.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30D8238DC87400DE8C68 /* PNAPNSNotificationTarget.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A30E0238DC87400DE8C68 /* PNAPNSNotificationTarget.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30D8238DC87400DE8C68 /* PNAPNSNotificationTarget.h */; settings = {ATTRIBUTES = (Public, ); }; }; + A57A30E1238DC87400DE8C68 /* PNAPNSNotificationTarget.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A30D9238DC87400DE8C68 /* PNAPNSNotificationTarget.m */; }; + A57A30E2238DC87400DE8C68 /* PNAPNSNotificationTarget.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A30D9238DC87400DE8C68 /* PNAPNSNotificationTarget.m */; }; + A57A30E3238DC87400DE8C68 /* PNAPNSNotificationTarget.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A30D9238DC87400DE8C68 /* PNAPNSNotificationTarget.m */; }; + A57A30E4238DC87400DE8C68 /* PNAPNSNotificationTarget.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A30D9238DC87400DE8C68 /* PNAPNSNotificationTarget.m */; }; + A57A30E5238DC87400DE8C68 /* PNAPNSNotificationTarget.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A30D9238DC87400DE8C68 /* PNAPNSNotificationTarget.m */; }; + A57A30E6238DC87400DE8C68 /* PNAPNSNotificationTarget.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A30D9238DC87400DE8C68 /* PNAPNSNotificationTarget.m */; }; + A57A30E7238DC87400DE8C68 /* PNAPNSNotificationTarget.m in Sources */ = {isa = PBXBuildFile; fileRef = A57A30D9238DC87400DE8C68 /* PNAPNSNotificationTarget.m */; }; + A57A30E9238DCAAF00DE8C68 /* PNAPNSNotificationTarget+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30E8238DCAAF00DE8C68 /* PNAPNSNotificationTarget+Private.h */; }; + A57A30EA238DCAAF00DE8C68 /* PNAPNSNotificationTarget+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30E8238DCAAF00DE8C68 /* PNAPNSNotificationTarget+Private.h */; }; + A57A30EB238DCAAF00DE8C68 /* PNAPNSNotificationTarget+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30E8238DCAAF00DE8C68 /* PNAPNSNotificationTarget+Private.h */; }; + A57A30EC238DCAAF00DE8C68 /* PNAPNSNotificationTarget+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30E8238DCAAF00DE8C68 /* PNAPNSNotificationTarget+Private.h */; }; + A57A30ED238DCAAF00DE8C68 /* PNAPNSNotificationTarget+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30E8238DCAAF00DE8C68 /* PNAPNSNotificationTarget+Private.h */; }; + A57A30EE238DCAAF00DE8C68 /* PNAPNSNotificationTarget+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30E8238DCAAF00DE8C68 /* PNAPNSNotificationTarget+Private.h */; }; + A57A30EF238DCAAF00DE8C68 /* PNAPNSNotificationTarget+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30E8238DCAAF00DE8C68 /* PNAPNSNotificationTarget+Private.h */; }; + A57A30F1238DDCA300DE8C68 /* PNAPNSNotificationPayload+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30F0238DDCA200DE8C68 /* PNAPNSNotificationPayload+Private.h */; }; + A57A30F2238DDCA300DE8C68 /* PNAPNSNotificationPayload+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30F0238DDCA200DE8C68 /* PNAPNSNotificationPayload+Private.h */; }; + A57A30F3238DDCA300DE8C68 /* PNAPNSNotificationPayload+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30F0238DDCA200DE8C68 /* PNAPNSNotificationPayload+Private.h */; }; + A57A30F4238DDCA300DE8C68 /* PNAPNSNotificationPayload+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30F0238DDCA200DE8C68 /* PNAPNSNotificationPayload+Private.h */; }; + A57A30F5238DDCA300DE8C68 /* PNAPNSNotificationPayload+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30F0238DDCA200DE8C68 /* PNAPNSNotificationPayload+Private.h */; }; + A57A30F6238DDCA300DE8C68 /* PNAPNSNotificationPayload+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30F0238DDCA200DE8C68 /* PNAPNSNotificationPayload+Private.h */; }; + A57A30F7238DDCA300DE8C68 /* PNAPNSNotificationPayload+Private.h in Headers */ = {isa = PBXBuildFile; fileRef = A57A30F0238DDCA200DE8C68 /* PNAPNSNotificationPayload+Private.h */; }; A586A9E52337E581008856D2 /* PNFetchMessageActionsResult.m in Sources */ = {isa = PBXBuildFile; fileRef = A586A9E32337E581008856D2 /* PNFetchMessageActionsResult.m */; }; A586A9E62337E581008856D2 /* PNFetchMessageActionsResult.m in Sources */ = {isa = PBXBuildFile; fileRef = A586A9E32337E581008856D2 /* PNFetchMessageActionsResult.m */; }; A586A9E72337E581008856D2 /* PNFetchMessageActionsResult.m in Sources */ = {isa = PBXBuildFile; fileRef = A586A9E32337E581008856D2 /* PNFetchMessageActionsResult.m */; }; @@ -2992,6 +3209,8 @@ 79E2D0ED1C56434700BAA244 /* PNKeychain.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PNKeychain.m; sourceTree = ""; }; 79F90F171FDEC1B9007132A3 /* PNPresenceHeartbeatAPICallBuilder.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PNPresenceHeartbeatAPICallBuilder.m; sourceTree = ""; }; 79F90F181FDEC1B9007132A3 /* PNPresenceHeartbeatAPICallBuilder.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PNPresenceHeartbeatAPICallBuilder.h; sourceTree = ""; }; + A5105B4E238F027D00CB693D /* PNDate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = PNDate.h; sourceTree = ""; }; + A5105B4F238F027D00CB693D /* PNDate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = PNDate.m; sourceTree = ""; }; A52DC1E42307E10B001F20B0 /* NSDateFormatter+PNCacheable.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "NSDateFormatter+PNCacheable.h"; sourceTree = ""; }; A52DC1E52307E10B001F20B0 /* NSDateFormatter+PNCacheable.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = "NSDateFormatter+PNCacheable.m"; sourceTree = ""; }; A55A85CF22FD8077002D0A72 /* PubNub+Objects.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "PubNub+Objects.h"; sourceTree = ""; }; @@ -3086,6 +3305,7 @@ A55BCD14231D26110019DB68 /* PNMessageAction.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = PNMessageAction.h; sourceTree = ""; }; A55BCD15231D26110019DB68 /* PNMessageAction.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = PNMessageAction.m; sourceTree = ""; }; A55BCD24231D27F00019DB68 /* PNMessageAction+Private.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "PNMessageAction+Private.h"; sourceTree = ""; }; + A55CA69C2397389100B24E02 /* PNKeychain+Private.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "PNKeychain+Private.h"; sourceTree = ""; }; A568655F2300622C0014E17C /* PNMember+Private.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "PNMember+Private.h"; sourceTree = ""; }; A56865672300709F0014E17C /* PNFetchMembershipsResult.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = PNFetchMembershipsResult.h; sourceTree = ""; }; A56865682300709F0014E17C /* PNFetchMembershipsResult.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = PNFetchMembershipsResult.m; sourceTree = ""; }; @@ -3108,6 +3328,34 @@ A56FAEF0233161560072ADD6 /* PubNub+MessageActions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "PubNub+MessageActions.h"; sourceTree = ""; }; A56FAEF1233161570072ADD6 /* PubNub+MessageActions.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "PubNub+MessageActions.m"; sourceTree = ""; }; A57A2FF22389FA8700DE8C68 /* build_xcframework.sh */ = {isa = PBXFileReference; lastKnownFileType = text.script.sh; path = build_xcframework.sh; sourceTree = ""; }; + A57A3003238D59B500DE8C68 /* PNAddPushNotificationsRequest.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PNAddPushNotificationsRequest.h; sourceTree = ""; }; + A57A3004238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PNRemoveAllPushNotificationsRequest.m; sourceTree = ""; }; + A57A3005238D59B500DE8C68 /* PNAuditPushNotificationsRequest.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PNAuditPushNotificationsRequest.h; sourceTree = ""; }; + A57A3006238D59B500DE8C68 /* PNRemovePushNotificationsRequest.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PNRemovePushNotificationsRequest.h; sourceTree = ""; }; + A57A3007238D59B500DE8C68 /* PNBasePushNotificationsRequest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PNBasePushNotificationsRequest.m; sourceTree = ""; }; + A57A3008238D59B500DE8C68 /* PNAddPushNotificationsRequest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PNAddPushNotificationsRequest.m; sourceTree = ""; }; + A57A3009238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PNRemoveAllPushNotificationsRequest.h; sourceTree = ""; }; + A57A300A238D59B500DE8C68 /* PNRemovePushNotificationsRequest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PNRemovePushNotificationsRequest.m; sourceTree = ""; }; + A57A300B238D59B500DE8C68 /* PNAuditPushNotificationsRequest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PNAuditPushNotificationsRequest.m; sourceTree = ""; }; + A57A300C238D59B500DE8C68 /* PNBasePushNotificationsRequest.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PNBasePushNotificationsRequest.h; sourceTree = ""; }; + A57A3057238D65A200DE8C68 /* PNNotificationsPayload.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = PNNotificationsPayload.h; sourceTree = ""; }; + A57A3058238D65A200DE8C68 /* PNNotificationsPayload.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = PNNotificationsPayload.m; sourceTree = ""; }; + A57A3067238D6BCC00DE8C68 /* PNFCMNotificationPayload.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = PNFCMNotificationPayload.h; sourceTree = ""; }; + A57A3068238D6BCC00DE8C68 /* PNFCMNotificationPayload.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = PNFCMNotificationPayload.m; sourceTree = ""; }; + A57A3087238D751400DE8C68 /* PNMPNSNotificationPayload.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = PNMPNSNotificationPayload.h; sourceTree = ""; }; + A57A3088238D751400DE8C68 /* PNMPNSNotificationPayload.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = PNMPNSNotificationPayload.m; sourceTree = ""; }; + A57A3097238D784A00DE8C68 /* PNBaseNotificationPayload.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = PNBaseNotificationPayload.h; sourceTree = ""; }; + A57A3098238D784A00DE8C68 /* PNBaseNotificationPayload.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = PNBaseNotificationPayload.m; sourceTree = ""; }; + A57A30A7238D78C400DE8C68 /* PNBaseNotificationPayload+Private.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "PNBaseNotificationPayload+Private.h"; sourceTree = ""; }; + A57A30B0238DC6B600DE8C68 /* PNAPNSNotificationPayload.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PNAPNSNotificationPayload.h; sourceTree = ""; }; + A57A30B1238DC6B600DE8C68 /* PNAPNSNotificationPayload.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PNAPNSNotificationPayload.m; sourceTree = ""; }; + A57A30C0238DC71800DE8C68 /* PNAPNSNotificationConfiguration.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = PNAPNSNotificationConfiguration.h; sourceTree = ""; }; + A57A30C1238DC71800DE8C68 /* PNAPNSNotificationConfiguration.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = PNAPNSNotificationConfiguration.m; sourceTree = ""; }; + A57A30D0238DC7FF00DE8C68 /* PNAPNSNotificationConfiguration+Private.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "PNAPNSNotificationConfiguration+Private.h"; sourceTree = ""; }; + A57A30D8238DC87400DE8C68 /* PNAPNSNotificationTarget.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = PNAPNSNotificationTarget.h; sourceTree = ""; }; + A57A30D9238DC87400DE8C68 /* PNAPNSNotificationTarget.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = PNAPNSNotificationTarget.m; sourceTree = ""; }; + A57A30E8238DCAAF00DE8C68 /* PNAPNSNotificationTarget+Private.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "PNAPNSNotificationTarget+Private.h"; sourceTree = ""; }; + A57A30F0238DDCA200DE8C68 /* PNAPNSNotificationPayload+Private.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "PNAPNSNotificationPayload+Private.h"; sourceTree = ""; }; A586A9E32337E581008856D2 /* PNFetchMessageActionsResult.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = PNFetchMessageActionsResult.m; sourceTree = ""; }; A586A9E42337E581008856D2 /* PNFetchMessageActionsResult.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PNFetchMessageActionsResult.h; sourceTree = ""; }; A589756822FEF0F70093BD9A /* PNBaseObjectsRequest+Private.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "PNBaseObjectsRequest+Private.h"; sourceTree = ""; }; @@ -3484,6 +3732,7 @@ 79CBB0781BD03DE4001FC34D /* PNClientInformation.m */, 79CBB07A1BD03DE4001FC34D /* PNConfiguration.h */, 79CBB07B1BD03DE4001FC34D /* PNConfiguration.m */, + A55CA69C2397389100B24E02 /* PNKeychain+Private.h */, 79E2D0EC1C56434700BAA244 /* PNKeychain.h */, 79E2D0ED1C56434700BAA244 /* PNKeychain.m */, 79CBB0751BD03DE4001FC34D /* PNAES.h */, @@ -3613,6 +3862,7 @@ 79CBB0AB1BD03DE4001FC34D /* Helpers */ = { isa = PBXGroup; children = ( + A57A3055238D61E600DE8C68 /* Notifications Payload */, 79650C291E775E8300006F66 /* PNDefines.h */, 79650C2A1E775E8300006F66 /* PNLockSupport.h */, 79650C2B1E775E8300006F66 /* PNLockSupport.m */, @@ -3635,6 +3885,8 @@ 79CBB0B71BD03DE4001FC34D /* PNGZIP.m */, 79CBB0B21BD03DE4001FC34D /* PNData.h */, 79CBB0B31BD03DE4001FC34D /* PNData.m */, + A5105B4E238F027D00CB693D /* PNDate.h */, + A5105B4F238F027D00CB693D /* PNDate.m */, ); path = Helpers; sourceTree = ""; @@ -3850,6 +4102,7 @@ A55A874522FD8272002D0A72 /* Requests */ = { isa = PBXGroup; children = ( + A57A3002238D59B500DE8C68 /* Push Notifications */, A55BCCB023193A8C0019DB68 /* Actions */, A55A874722FD8272002D0A72 /* Objects */, A55A877122FD8272002D0A72 /* PNRequest+Private.h */, @@ -3985,6 +4238,56 @@ path = Message; sourceTree = ""; }; + A57A3002238D59B500DE8C68 /* Push Notifications */ = { + isa = PBXGroup; + children = ( + A57A3003238D59B500DE8C68 /* PNAddPushNotificationsRequest.h */, + A57A3008238D59B500DE8C68 /* PNAddPushNotificationsRequest.m */, + A57A3005238D59B500DE8C68 /* PNAuditPushNotificationsRequest.h */, + A57A300B238D59B500DE8C68 /* PNAuditPushNotificationsRequest.m */, + A57A3006238D59B500DE8C68 /* PNRemovePushNotificationsRequest.h */, + A57A300A238D59B500DE8C68 /* PNRemovePushNotificationsRequest.m */, + A57A3009238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.h */, + A57A3004238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.m */, + A57A300C238D59B500DE8C68 /* PNBasePushNotificationsRequest.h */, + A57A3007238D59B500DE8C68 /* PNBasePushNotificationsRequest.m */, + ); + path = "Push Notifications"; + sourceTree = ""; + }; + A57A3055238D61E600DE8C68 /* Notifications Payload */ = { + isa = PBXGroup; + children = ( + A57A30AF238DC6B600DE8C68 /* APNS */, + A57A3087238D751400DE8C68 /* PNMPNSNotificationPayload.h */, + A57A3088238D751400DE8C68 /* PNMPNSNotificationPayload.m */, + A57A3067238D6BCC00DE8C68 /* PNFCMNotificationPayload.h */, + A57A3068238D6BCC00DE8C68 /* PNFCMNotificationPayload.m */, + A57A30A7238D78C400DE8C68 /* PNBaseNotificationPayload+Private.h */, + A57A3097238D784A00DE8C68 /* PNBaseNotificationPayload.h */, + A57A3098238D784A00DE8C68 /* PNBaseNotificationPayload.m */, + A57A3057238D65A200DE8C68 /* PNNotificationsPayload.h */, + A57A3058238D65A200DE8C68 /* PNNotificationsPayload.m */, + ); + path = "Notifications Payload"; + sourceTree = ""; + }; + A57A30AF238DC6B600DE8C68 /* APNS */ = { + isa = PBXGroup; + children = ( + A57A30D0238DC7FF00DE8C68 /* PNAPNSNotificationConfiguration+Private.h */, + A57A30C0238DC71800DE8C68 /* PNAPNSNotificationConfiguration.h */, + A57A30C1238DC71800DE8C68 /* PNAPNSNotificationConfiguration.m */, + A57A30F0238DDCA200DE8C68 /* PNAPNSNotificationPayload+Private.h */, + A57A30B0238DC6B600DE8C68 /* PNAPNSNotificationPayload.h */, + A57A30B1238DC6B600DE8C68 /* PNAPNSNotificationPayload.m */, + A57A30E8238DCAAF00DE8C68 /* PNAPNSNotificationTarget+Private.h */, + A57A30D8238DC87400DE8C68 /* PNAPNSNotificationTarget.h */, + A57A30D9238DC87400DE8C68 /* PNAPNSNotificationTarget.m */, + ); + path = APNS; + sourceTree = ""; + }; /* End PBXGroup section */ /* Begin PBXHeadersBuildPhase section */ @@ -3992,6 +4295,7 @@ isa = PBXHeadersBuildPhase; buildActionMask = 2147483647; files = ( + A57A301B238D59B500DE8C68 /* PNAuditPushNotificationsRequest.h in Headers */, 79A238DE1D2E70BD00D080CD /* NSURLSessionConfiguration+PNConfigurationPrivate.h in Headers */, 791582771BD709C60084FC70 /* PNPushNotificationsStateModificationParser.h in Headers */, A58975B223005AAC0093BD9A /* PNManageMembershipsStatus.h in Headers */, @@ -4003,6 +4307,7 @@ A56865602300622C0014E17C /* PNMember+Private.h in Headers */, 791582A21BD709C60084FC70 /* PNChannelGroupModificationParser.h in Headers */, A55A85FB22FD80B9002D0A72 /* PNCreateUserAPICallBuilder.h in Headers */, + A57A3037238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.h in Headers */, 791582541BD709C60084FC70 /* PNChannelGroupClientStateResult.h in Headers */, A55A86E022FD81E3002D0A72 /* PNFetchUsersResult.h in Headers */, 791582611BD709C60084FC70 /* PNPushNotificationsAuditParser.h in Headers */, @@ -4013,8 +4318,10 @@ 791582561BD709C60084FC70 /* PNChannelGroupChannelsResult.h in Headers */, A55A867922FD80B9002D0A72 /* PNCreateSpaceAPICallBuilder.h in Headers */, 79F90F1A1FDEC1BA007132A3 /* PNPresenceHeartbeatAPICallBuilder.h in Headers */, + A57A30F1238DDCA300DE8C68 /* PNAPNSNotificationPayload+Private.h in Headers */, 79A0D8501DC22C950039A264 /* PNPresenceHereNowAPICallBuilder.h in Headers */, 79A0D85E1DC22C950039A264 /* PNStreamAPICallBuilder.h in Headers */, + A57A30C2238DC71800DE8C68 /* PNAPNSNotificationConfiguration.h in Headers */, 791582881BD709C60084FC70 /* PNNetworkResponseSerializer.h in Headers */, 791582571BD709C60084FC70 /* PNAPNSEnabledChannelsResult.h in Headers */, 791582591BD709C60084FC70 /* PNChannelClientStateResult.h in Headers */, @@ -4037,8 +4344,10 @@ 7915825E1BD709C60084FC70 /* PNObjectEventListener.h in Headers */, 797D605A22D2E41100E64C94 /* PNSignalAPICallBuilder.h in Headers */, A56865B9230173030014E17C /* PNSpaceDataChangeParser.h in Headers */, + A57A30DA238DC87400DE8C68 /* PNAPNSNotificationTarget.h in Headers */, 7915825C1BD709C60084FC70 /* PNChannelGroupsResult.h in Headers */, 79E20D151C8AEC3A001BC9CC /* PNEnvelopeInformation.h in Headers */, + A55CA69D2397389100B24E02 /* PNKeychain+Private.h in Headers */, A55A864122FD80B9002D0A72 /* PNFetchUsersAPICallBuilder.h in Headers */, 7925DB951D3FFCAC00857C0D /* PNLLogFileInformation.h in Headers */, A55A87FF22FD8272002D0A72 /* PNUpdateSpaceRequest.h in Headers */, @@ -4053,6 +4362,8 @@ 7915827A1BD709C60084FC70 /* PNPrivateStructures.h in Headers */, 79A3E428221569DA00F2ADB9 /* PNMessageCountParser.h in Headers */, 79A0D86C1DC22C950039A264 /* PNTimeAPICallBuilder.h in Headers */, + A57A300D238D59B500DE8C68 /* PNAddPushNotificationsRequest.h in Headers */, + A57A30A8238D78C400DE8C68 /* PNBaseNotificationPayload+Private.h in Headers */, 791582601BD709C60084FC70 /* PNClientInformation.h in Headers */, A55A87C722FD8272002D0A72 /* PNDeleteUserRequest.h in Headers */, A55A866B22FD80B9002D0A72 /* PNFetchSpacesAPICallBuilder.h in Headers */, @@ -4065,6 +4376,7 @@ A5A7AFF92349330F0060113B /* PNFetchMessageActionsRequest.h in Headers */, 7915829F1BD709C60084FC70 /* PubNub+CorePrivate.h in Headers */, A55A885322FD8272002D0A72 /* PNFetchMembersRequest.h in Headers */, + A57A3022238D59B500DE8C68 /* PNRemovePushNotificationsRequest.h in Headers */, A55A86EE22FD81E3002D0A72 /* PNCreateUserStatus.h in Headers */, A5A7B00E2349330F0060113B /* PNAddMessageActionRequest.h in Headers */, 79A0D8681DC22C950039A264 /* PNUnsubscribeAPICallBuilder.h in Headers */, @@ -4083,7 +4395,9 @@ 791582621BD709C60084FC70 /* PubNub+Subscribe.h in Headers */, A58975D223005BE60093BD9A /* PNMember.h in Headers */, A55A87DC22FD8272002D0A72 /* PNBaseObjectsRequest.h in Headers */, + A57A3089238D751400DE8C68 /* PNMPNSNotificationPayload.h in Headers */, 79A0D86E1DC22C950039A264 /* PNAPICallBuilder+Private.h in Headers */, + A57A30E9238DCAAF00DE8C68 /* PNAPNSNotificationTarget+Private.h in Headers */, A55A881B22FD8272002D0A72 /* PNFetchSpacesRequest.h in Headers */, A56865C9230173AA0014E17C /* PNObjectsDeleteParser.h in Headers */, 7915829D1BD709C60084FC70 /* PNStateListener.h in Headers */, @@ -4127,7 +4441,9 @@ 7915827E1BD709C60084FC70 /* PNURLBuilder.h in Headers */, A55A86BF22FD817E002D0A72 /* PNUser+Private.h in Headers */, 7915827C1BD709C60084FC70 /* PNTimeParser.h in Headers */, + A57A30D1238DC7FF00DE8C68 /* PNAPNSNotificationConfiguration+Private.h in Headers */, 791582721BD709C60084FC70 /* PNStructures.h in Headers */, + A57A304C238D59B500DE8C68 /* PNBasePushNotificationsRequest.h in Headers */, A55A881422FD8272002D0A72 /* PNCreateSpaceRequest.h in Headers */, 791582701BD709C60084FC70 /* PNTimeResult.h in Headers */, 7915826D1BD709C60084FC70 /* PNErrorCodes.h in Headers */, @@ -4143,6 +4459,7 @@ A5A7B0312349330F0060113B /* PNBaseMessageActionRequest.h in Headers */, A5A7B02A2349330F0060113B /* PNRemoveMessageActionRequest.h in Headers */, A586A9EC2337E581008856D2 /* PNFetchMessageActionsResult.h in Headers */, + A57A3099238D784A00DE8C68 /* PNBaseNotificationPayload.h in Headers */, 7915826F1BD709C60084FC70 /* PubNub+Core.h in Headers */, A55A878822FD8272002D0A72 /* PNUpdateUserRequest.h in Headers */, A55A863A22FD80B9002D0A72 /* PNFetchUserAPICallBuilder.h in Headers */, @@ -4159,6 +4476,7 @@ A55A871F22FD81E3002D0A72 /* PNUpdateSpaceStatus.h in Headers */, 791582931BD709C60084FC70 /* PNChannel.h in Headers */, 7915827F1BD709C60084FC70 /* PNHelpers.h in Headers */, + A5105B50238F027D00CB693D /* PNDate.h in Headers */, A5686599230170690014E17C /* PNFetchUsersParser.h in Headers */, A55A861722FD80B9002D0A72 /* PNUpdateUserAPICallBuilder.h in Headers */, 79A0D86A1DC22C950039A264 /* PNUnsubscribeChannelsOrGroupsAPICallBuilder.h in Headers */, @@ -4166,8 +4484,10 @@ 79ABD8911F01636B007634E0 /* PNTelemetry.h in Headers */, 7925DB871D3FFCAC00857C0D /* PNLLogger.h in Headers */, 793887041BEAD49100DCC662 /* PNNumber.h in Headers */, + A57A30B2238DC6B600DE8C68 /* PNAPNSNotificationPayload.h in Headers */, 7915828C1BD709C60084FC70 /* PNParser.h in Headers */, 7915828B1BD709C60084FC70 /* PNString.h in Headers */, + A57A3069238D6BCC00DE8C68 /* PNFCMNotificationPayload.h in Headers */, 791582741BD709C60084FC70 /* PNResult.h in Headers */, 791582731BD709C60084FC70 /* PNStatus.h in Headers */, A55A888B22FD8272002D0A72 /* PNRequest.h in Headers */, @@ -4182,6 +4502,7 @@ A56865892300729E0014E17C /* PNFetchMembersResult.h in Headers */, A56865692300709F0014E17C /* PNFetchMembershipsResult.h in Headers */, A55A868022FD80B9002D0A72 /* PNUpdateSpaceAPICallBuilder.h in Headers */, + A57A3059238D65A200DE8C68 /* PNNotificationsPayload.h in Headers */, 7915827B1BD709C60084FC70 /* PNJSON.h in Headers */, 791582751BD709C60084FC70 /* PubNub.h in Headers */, A55A887622FD8272002D0A72 /* PNManageMembersRequest.h in Headers */, @@ -4200,6 +4521,7 @@ isa = PBXHeadersBuildPhase; buildActionMask = 2147483647; files = ( + A57A301D238D59B500DE8C68 /* PNAuditPushNotificationsRequest.h in Headers */, 79A0D92C1DC230AB0039A264 /* PNStreamAPICallBuilder.h in Headers */, 79A238E01D2E70BD00D080CD /* NSURLSessionConfiguration+PNConfigurationPrivate.h in Headers */, A58975B423005AAC0093BD9A /* PNManageMembershipsStatus.h in Headers */, @@ -4211,6 +4533,7 @@ A56865622300622C0014E17C /* PNMember+Private.h in Headers */, 7915834B1BD709D10084FC70 /* PNChannelGroupModificationParser.h in Headers */, A55A85FD22FD80B9002D0A72 /* PNCreateUserAPICallBuilder.h in Headers */, + A57A3039238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.h in Headers */, 791582FD1BD709D10084FC70 /* PNChannelGroupClientStateResult.h in Headers */, A55A86E222FD81E3002D0A72 /* PNFetchUsersResult.h in Headers */, 7915830A1BD709D10084FC70 /* PNPushNotificationsAuditParser.h in Headers */, @@ -4221,8 +4544,10 @@ 791582FF1BD709D10084FC70 /* PNChannelGroupChannelsResult.h in Headers */, A55A867B22FD80B9002D0A72 /* PNCreateSpaceAPICallBuilder.h in Headers */, 79F90F1C1FDEC1C7007132A3 /* PNPresenceHeartbeatAPICallBuilder.h in Headers */, + A57A30F3238DDCA300DE8C68 /* PNAPNSNotificationPayload+Private.h in Headers */, 791583311BD709D10084FC70 /* PNNetworkResponseSerializer.h in Headers */, 79F85801219640C900BFD0B1 /* PNClientStateGetResult.h in Headers */, + A57A30C4238DC71800DE8C68 /* PNAPNSNotificationConfiguration.h in Headers */, 791583001BD709D10084FC70 /* PNAPNSEnabledChannelsResult.h in Headers */, 791583021BD709D10084FC70 /* PNChannelClientStateResult.h in Headers */, 79E20D261C8AEFF2001BC9CC /* PNSubscribeStatus+Private.h in Headers */, @@ -4245,8 +4570,10 @@ 791583301BD709D10084FC70 /* PNServiceData+Private.h in Headers */, 797D605C22D2E41100E64C94 /* PNSignalAPICallBuilder.h in Headers */, A56865BB230173030014E17C /* PNSpaceDataChangeParser.h in Headers */, + A57A30DC238DC87400DE8C68 /* PNAPNSNotificationTarget.h in Headers */, 791583071BD709D10084FC70 /* PNObjectEventListener.h in Headers */, 791583051BD709D10084FC70 /* PNChannelGroupsResult.h in Headers */, + A55CA69F2397389100B24E02 /* PNKeychain+Private.h in Headers */, A55A864322FD80B9002D0A72 /* PNFetchUsersAPICallBuilder.h in Headers */, 79E20D181C8AEC43001BC9CC /* PNEnvelopeInformation.h in Headers */, A55A880122FD8272002D0A72 /* PNUpdateSpaceRequest.h in Headers */, @@ -4261,6 +4588,8 @@ 79A0D9081DC230670039A264 /* PNStateAPICallBuilder.h in Headers */, 79A3E42A221569DA00F2ADB9 /* PNMessageCountParser.h in Headers */, 791583231BD709D10084FC70 /* PNPrivateStructures.h in Headers */, + A57A300F238D59B500DE8C68 /* PNAddPushNotificationsRequest.h in Headers */, + A57A30AA238D78C400DE8C68 /* PNBaseNotificationPayload+Private.h in Headers */, 791583091BD709D10084FC70 /* PNClientInformation.h in Headers */, A55A87C922FD8272002D0A72 /* PNDeleteUserRequest.h in Headers */, A55A866D22FD80B9002D0A72 /* PNFetchSpacesAPICallBuilder.h in Headers */, @@ -4273,6 +4602,7 @@ A5A7AFFB2349330F0060113B /* PNFetchMessageActionsRequest.h in Headers */, 7915832F1BD709D10084FC70 /* PNHeartbeatParser.h in Headers */, A55A885522FD8272002D0A72 /* PNFetchMembersRequest.h in Headers */, + A57A3024238D59B500DE8C68 /* PNRemovePushNotificationsRequest.h in Headers */, A55A86F022FD81E3002D0A72 /* PNCreateUserStatus.h in Headers */, A5A7B0102349330F0060113B /* PNAddMessageActionRequest.h in Headers */, 79A0D8901DC22F690039A264 /* PNAPNSAuditAPICallBuilder.h in Headers */, @@ -4291,7 +4621,9 @@ 7915833A1BD709D10084FC70 /* PNHistoryParser.h in Headers */, A58975D423005BE60093BD9A /* PNMember.h in Headers */, A55A87DE22FD8272002D0A72 /* PNBaseObjectsRequest.h in Headers */, + A57A308B238D751400DE8C68 /* PNMPNSNotificationPayload.h in Headers */, 791583111BD709D10084FC70 /* PNHistoryResult.h in Headers */, + A57A30EB238DCAAF00DE8C68 /* PNAPNSNotificationTarget+Private.h in Headers */, A55A881D22FD8272002D0A72 /* PNFetchSpacesRequest.h in Headers */, A56865CB230173AA0014E17C /* PNObjectsDeleteParser.h in Headers */, 79A0D9621DC231040039A264 /* PNUnsubscribeChannelsOrGroupsAPICallBuilder.h in Headers */, @@ -4335,7 +4667,9 @@ 791583191BD709D10084FC70 /* PNTimeResult.h in Headers */, A55A86C122FD817E002D0A72 /* PNUser+Private.h in Headers */, 79A0D8C01DC22FD60039A264 /* PNPresenceChannelHereNowAPICallBuilder.h in Headers */, + A57A30D3238DC7FF00DE8C68 /* PNAPNSNotificationConfiguration+Private.h in Headers */, 791583161BD709D10084FC70 /* PNErrorCodes.h in Headers */, + A57A304E238D59B500DE8C68 /* PNBasePushNotificationsRequest.h in Headers */, A55A881622FD8272002D0A72 /* PNCreateSpaceRequest.h in Headers */, 791583151BD709D10084FC70 /* PubNub+State.h in Headers */, 791583451BD709D10084FC70 /* PNConstants.h in Headers */, @@ -4351,6 +4685,7 @@ A5A7B0332349330F0060113B /* PNBaseMessageActionRequest.h in Headers */, A5A7B02C2349330F0060113B /* PNRemoveMessageActionRequest.h in Headers */, A586A9EE2337E581008856D2 /* PNFetchMessageActionsResult.h in Headers */, + A57A309B238D784A00DE8C68 /* PNBaseNotificationPayload.h in Headers */, 791583141BD709D10084FC70 /* PubNub+APNS.h in Headers */, A55A878A22FD8272002D0A72 /* PNUpdateUserRequest.h in Headers */, A55A863C22FD80B9002D0A72 /* PNFetchUserAPICallBuilder.h in Headers */, @@ -4367,6 +4702,7 @@ A55A872122FD81E3002D0A72 /* PNUpdateSpaceStatus.h in Headers */, 791583281BD709D10084FC70 /* PNHelpers.h in Headers */, 7925DB891D3FFCAC00857C0D /* PNLLogger.h in Headers */, + A5105B52238F027D00CB693D /* PNDate.h in Headers */, A568659B230170690014E17C /* PNFetchUsersParser.h in Headers */, A55A861922FD80B9002D0A72 /* PNUpdateUserAPICallBuilder.h in Headers */, 793887061BEAD4A700DCC662 /* PNNumber.h in Headers */, @@ -4374,8 +4710,10 @@ 791583351BD709D10084FC70 /* PNParser.h in Headers */, 79ABD8931F01636B007634E0 /* PNTelemetry.h in Headers */, 791583341BD709D10084FC70 /* PNString.h in Headers */, + A57A30B4238DC6B600DE8C68 /* PNAPNSNotificationPayload.h in Headers */, 79A0D95C1DC230FE0039A264 /* PNUnsubscribeAPICallBuilder.h in Headers */, 7915831D1BD709D10084FC70 /* PNResult.h in Headers */, + A57A306B238D6BCC00DE8C68 /* PNFCMNotificationPayload.h in Headers */, 7915831C1BD709D10084FC70 /* PNStatus.h in Headers */, 791583381BD709D10084FC70 /* PNArray.h in Headers */, A55A888D22FD8272002D0A72 /* PNRequest.h in Headers */, @@ -4390,6 +4728,7 @@ A568658B2300729E0014E17C /* PNFetchMembersResult.h in Headers */, A568656B2300709F0014E17C /* PNFetchMembershipsResult.h in Headers */, A55A868222FD80B9002D0A72 /* PNUpdateSpaceAPICallBuilder.h in Headers */, + A57A305B238D65A200DE8C68 /* PNNotificationsPayload.h in Headers */, 7915831E1BD709D10084FC70 /* PubNub.h in Headers */, 7915831F1BD709D10084FC70 /* PNAES.h in Headers */, A55A887822FD8272002D0A72 /* PNManageMembersRequest.h in Headers */, @@ -4412,8 +4751,11 @@ 798842B01C18F2D5003E8948 /* PNPushNotificationsStateModificationParser.h in Headers */, 79A238D51D2E70BD00D080CD /* NSURLSessionConfiguration+PNConfiguration.h in Headers */, 798842461C18F15C003E8948 /* PNPresenceChannelGroupHereNowResult.h in Headers */, + A57A30D6238DC7FF00DE8C68 /* PNAPNSNotificationConfiguration+Private.h in Headers */, A55A860022FD80B9002D0A72 /* PNCreateUserAPICallBuilder.h in Headers */, 798842A61C18F2D3003E8948 /* PNChannelGroupModificationParser.h in Headers */, + A57A30C7238DC71800DE8C68 /* PNAPNSNotificationConfiguration.h in Headers */, + A57A306E238D6BCC00DE8C68 /* PNFCMNotificationPayload.h in Headers */, 798842401C18F13C003E8948 /* PNChannelGroupClientStateResult.h in Headers */, 79A0D8C31DC22FD70039A264 /* PNPresenceChannelHereNowAPICallBuilder.h in Headers */, A55A879B22FD8272002D0A72 /* PNFetchUsersRequest.h in Headers */, @@ -4436,6 +4778,7 @@ 79650C331E775E9300006F66 /* PNDefines.h in Headers */, A55A867E22FD80B9002D0A72 /* PNCreateSpaceAPICallBuilder.h in Headers */, 7988423D1C18F128003E8948 /* PNAPNSEnabledChannelsResult.h in Headers */, + A57A3027238D59B500DE8C68 /* PNRemovePushNotificationsRequest.h in Headers */, A5A7AFD2234932F30060113B /* PNFetchMessagesActionsParser.h in Headers */, A55A861522FD80B9002D0A72 /* PNDeleteUserAPICallBuilder.h in Headers */, 79A0D8871DC22F520039A264 /* PNAPNSAPICallBuilder.h in Headers */, @@ -4446,12 +4789,14 @@ 798842421C18F146003E8948 /* PNClientStateUpdateStatus.h in Headers */, A55A889022FD8272002D0A72 /* PNRequest.h in Headers */, 79A0D8AB1DC22FA70039A264 /* PNHistoryAPICallBuilder.h in Headers */, + A57A303C238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.h in Headers */, 797D605F22D2E41100E64C94 /* PNSignalAPICallBuilder.h in Headers */, 798842AE1C18F2D5003E8948 /* PNPresenceWhereNowParser.h in Headers */, A5A7B0132349330F0060113B /* PNAddMessageActionRequest.h in Headers */, A55BCCFB231D222B0019DB68 /* PNRemoveMessageActionAPICallBuilder.h in Headers */, A55A86F322FD81E3002D0A72 /* PNCreateUserStatus.h in Headers */, 7960B6691F68122200FFAEBB /* PNDeleteMessageAPICallBuilder.h in Headers */, + A57A308E238D751400DE8C68 /* PNMPNSNotificationPayload.h in Headers */, A5A7AFFE2349330F0060113B /* PNFetchMessageActionsRequest.h in Headers */, 798842491C18F16A003E8948 /* PNPresenceWhereNowResult.h in Headers */, A55A864622FD80B9002D0A72 /* PNFetchUsersAPICallBuilder.h in Headers */, @@ -4475,10 +4820,12 @@ A56865BE230173030014E17C /* PNSpaceDataChangeParser.h in Headers */, 7988427D1C18F26E003E8948 /* PNObjectEventListener.h in Headers */, 798842431C18F14E003E8948 /* PNErrorStatus+Private.h in Headers */, + A57A30AD238D78C400DE8C68 /* PNBaseNotificationPayload+Private.h in Headers */, A55A874322FD825A002D0A72 /* PNUserDataChangeParser.h in Headers */, A55BCD1B231D26110019DB68 /* PNMessageAction.h in Headers */, 7925DB9A1D3FFCAC00857C0D /* PNLLogFileInformation.h in Headers */, A52DC1EB2307E10B001F20B0 /* NSDateFormatter+PNCacheable.h in Headers */, + A57A309E238D784A00DE8C68 /* PNBaseNotificationPayload.h in Headers */, 79650C391E775E9800006F66 /* PNLockSupport.h in Headers */, 79E20D1B1C8AEC4C001BC9CC /* PNEnvelopeInformation.h in Headers */, A568658E2300729E0014E17C /* PNFetchMembersResult.h in Headers */, @@ -4504,6 +4851,7 @@ 798842301C18F0A2003E8948 /* PubNub+CorePrivate.h in Headers */, A55A86CB22FD817E002D0A72 /* PNUser.h in Headers */, A56865EE230176760014E17C /* PNMembersParser.h in Headers */, + A55CA6A22397389100B24E02 /* PNKeychain+Private.h in Headers */, 798842B21C18F2D6003E8948 /* PNSubscribeParser.h in Headers */, 798842A91C18F2D4003E8948 /* PNHeartbeatParser.h in Headers */, 798842771C18F208003E8948 /* PNSubscribeStatus.h in Headers */, @@ -4512,18 +4860,22 @@ 79F85804219640CA00BFD0B1 /* PNClientStateGetResult.h in Headers */, 7988424B1C18F173003E8948 /* PNResult+Private.h in Headers */, 79A0D89F1DC22F850039A264 /* PNAPNSModificationAPICallBuilder.h in Headers */, + A57A30F6238DDCA300DE8C68 /* PNAPNSNotificationPayload+Private.h in Headers */, 798842741C18F1FB003E8948 /* PNStatus+Private.h in Headers */, 798842321C18F0AC003E8948 /* PubNub+Subscribe.h in Headers */, + A57A30DF238DC87400DE8C68 /* PNAPNSNotificationTarget.h in Headers */, 7988422C1C18F088003E8948 /* PubNub+Presence.h in Headers */, A55BCCA72319243F0019DB68 /* PNAddMessageActionStatus.h in Headers */, 798842371C18F104003E8948 /* PNConfiguration.h in Headers */, A55A885822FD8272002D0A72 /* PNFetchMembersRequest.h in Headers */, + A57A30B7238DC6B600DE8C68 /* PNAPNSNotificationPayload.h in Headers */, 7988423A1C18F116003E8948 /* PNStateListener.h in Headers */, A55A868522FD80B9002D0A72 /* PNUpdateSpaceAPICallBuilder.h in Headers */, A5897577230014090093BD9A /* PNManageMembershipsAPICallBuilder.h in Headers */, 798842AA1C18F2D4003E8948 /* PNHistoryParser.h in Headers */, 798842451C18F157003E8948 /* PNHistoryResult.h in Headers */, A55A87FD22FD8272002D0A72 /* PNManageSpaceDataRequest.h in Headers */, + A57A3051238D59B500DE8C68 /* PNBasePushNotificationsRequest.h in Headers */, A58975B723005AAC0093BD9A /* PNManageMembershipsStatus.h in Headers */, 7988424A1C18F16E003E8948 /* PNPublishStatus.h in Headers */, 7988422D1C18F08D003E8948 /* PubNub+Publish.h in Headers */, @@ -4535,6 +4887,7 @@ 798842441C18F151003E8948 /* PNErrorStatus.h in Headers */, A55A883522FD8272002D0A72 /* PNDeleteSpaceRequest.h in Headers */, 798842AB1C18F2D4003E8948 /* PNLeaveParser.h in Headers */, + A57A305E238D65A200DE8C68 /* PNNotificationsPayload.h in Headers */, A5A7B0362349330F0060113B /* PNBaseMessageActionRequest.h in Headers */, 7988424E1C18F182003E8948 /* PNServiceData.h in Headers */, A55A886622FD8272002D0A72 /* PNFetchMembershipsRequest.h in Headers */, @@ -4543,10 +4896,12 @@ A55A87CC22FD8272002D0A72 /* PNDeleteUserRequest.h in Headers */, 798842891C18F287003E8948 /* PNURLRequest.h in Headers */, 79A0D8B71DC22FBC0039A264 /* PNPresenceAPICallBuilder.h in Headers */, + A5105B55238F027D00CB693D /* PNDate.h in Headers */, 7988422E1C18F092003E8948 /* PubNub+State.h in Headers */, 798842781C18F20C003E8948 /* PNTimeResult.h in Headers */, A5A7AFE7234932F30060113B /* PNRemoveMessageActionParser.h in Headers */, A55A87B022FD8272002D0A72 /* PNFetchUserRequest.h in Headers */, + A57A3012238D59B500DE8C68 /* PNAddPushNotificationsRequest.h in Headers */, 798842841C18F286003E8948 /* PNDictionary.h in Headers */, A5A7AFD9234932F30060113B /* PNAddMessageActionParser.h in Headers */, 7988427C1C18F267003E8948 /* PNStructures.h in Headers */, @@ -4575,6 +4930,7 @@ A56865DE230175EC0014E17C /* PNMembershipsParser.h in Headers */, A55A87E122FD8272002D0A72 /* PNBaseObjectsRequest.h in Headers */, 798842861C18F286003E8948 /* PNHelpers.h in Headers */, + A57A30EE238DCAAF00DE8C68 /* PNAPNSNotificationTarget+Private.h in Headers */, 798842811C18F286003E8948 /* PNChannel.h in Headers */, A5897587230014160093BD9A /* PNFetchMembershipsAPICallBuilder.h in Headers */, A55A877F22FD8272002D0A72 /* PNObjectsPaginatedRequest.h in Headers */, @@ -4608,6 +4964,7 @@ 798842851C18F286003E8948 /* PNGZIP.h in Headers */, 798842341C18F0F6003E8948 /* PNAES.h in Headers */, A55A887B22FD8272002D0A72 /* PNManageMembersRequest.h in Headers */, + A57A3020238D59B500DE8C68 /* PNAuditPushNotificationsRequest.h in Headers */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -4645,6 +5002,7 @@ A55A879C22FD8272002D0A72 /* PNFetchUsersRequest.h in Headers */, 79A0D9301DC230AD0039A264 /* PNStreamAPICallBuilder.h in Headers */, 798843851C191579003E8948 /* PNChannelClientStateResult.h in Headers */, + A57A30AE238D78C400DE8C68 /* PNBaseNotificationPayload+Private.h in Headers */, 79E20D2A1C8AEFF5001BC9CC /* PNSubscribeStatus+Private.h in Headers */, 798843731C191579003E8948 /* PNClientStateUpdateStatus.h in Headers */, 7988438C1C191579003E8948 /* PNPresenceWhereNowParser.h in Headers */, @@ -4654,6 +5012,7 @@ A56FAEF8233161570072ADD6 /* PubNub+MessageActions.h in Headers */, 798843901C191579003E8948 /* PNPresenceHereNowParser.h in Headers */, 798843741C191579003E8948 /* PubNub+SubscribePrivate.h in Headers */, + A57A303D238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.h in Headers */, A55A87A322FD8272002D0A72 /* PNCreateUserRequest.h in Headers */, A55A870922FD81E3002D0A72 /* PNUpdateUserStatus.h in Headers */, 79A0D95A1DC230FB0039A264 /* PNSubscribeChannelsOrGroupsAPIBuilder.h in Headers */, @@ -4669,11 +5028,13 @@ A55A868622FD80B9002D0A72 /* PNUpdateSpaceAPICallBuilder.h in Headers */, 7988438A1C191579003E8948 /* PNServiceData+Private.h in Headers */, 7988436C1C191579003E8948 /* PNObjectEventListener.h in Headers */, + A57A30D7238DC7FF00DE8C68 /* PNAPNSNotificationConfiguration+Private.h in Headers */, A58975E723005CFB0093BD9A /* PNMembership+Private.h in Headers */, 798843621C191579003E8948 /* PNErrorStatus+Private.h in Headers */, 79E20D1C1C8AEC4C001BC9CC /* PNEnvelopeInformation.h in Headers */, A55A887C22FD8272002D0A72 /* PNManageMembersRequest.h in Headers */, 7925DB9B1D3FFCAC00857C0D /* PNLLogFileInformation.h in Headers */, + A57A3028238D59B500DE8C68 /* PNRemovePushNotificationsRequest.h in Headers */, 798843911C191579003E8948 /* PNClientStateParser.h in Headers */, A55A87B122FD8272002D0A72 /* PNFetchUserRequest.h in Headers */, 798843701C191579003E8948 /* PNRequestParameters.h in Headers */, @@ -4689,6 +5050,7 @@ 79A0D8C41DC22FD80039A264 /* PNPresenceChannelHereNowAPICallBuilder.h in Headers */, A55BCD0C231D22400019DB68 /* PNFetchMessagesActionsAPICallBuilder.h in Headers */, 798843661C191579003E8948 /* PubNub+ChannelGroup.h in Headers */, + A57A30EF238DCAAF00DE8C68 /* PNAPNSNotificationTarget+Private.h in Headers */, 798843651C191579003E8948 /* PNSubscriberResults.h in Headers */, 798843601C191579003E8948 /* PNClientInformation.h in Headers */, 798843581C191579003E8948 /* PubNub+CorePrivate.h in Headers */, @@ -4700,11 +5062,14 @@ A55A882822FD8272002D0A72 /* PNFetchSpaceRequest.h in Headers */, 7988434B1C191579003E8948 /* PNHeartbeatParser.h in Headers */, 798843451C191579003E8948 /* PNSubscribeStatus.h in Headers */, + A55CA6A32397389100B24E02 /* PNKeychain+Private.h in Headers */, A55A86BE22FD817E002D0A72 /* PNSpace.h in Headers */, 7988438B1C191579003E8948 /* PNResult+Private.h in Headers */, + A57A30C8238DC71800DE8C68 /* PNAPNSNotificationConfiguration.h in Headers */, A55BCCA82319243F0019DB68 /* PNAddMessageActionStatus.h in Headers */, A56865CF230173AA0014E17C /* PNObjectsDeleteParser.h in Headers */, A55A872C22FD81E3002D0A72 /* PNFetchSpacesResult.h in Headers */, + A57A305F238D65A200DE8C68 /* PNNotificationsPayload.h in Headers */, 79A0D9171DC2308A0039A264 /* PNStateModificationAPICallBuilder.h in Headers */, A55A86F422FD81E3002D0A72 /* PNCreateUserStatus.h in Headers */, 798843561C191579003E8948 /* PNStatus+Private.h in Headers */, @@ -4712,6 +5077,7 @@ 79A0D87C1DC22F240039A264 /* PNAPICallBuilder.h in Headers */, 79A0D8CF1DC22FFC0039A264 /* PNPresenceWhereNowAPICallBuilder.h in Headers */, 798843471C191579003E8948 /* PubNub+Subscribe.h in Headers */, + A57A308F238D751400DE8C68 /* PNMPNSNotificationPayload.h in Headers */, 798843891C191579003E8948 /* PubNub+Presence.h in Headers */, A55A886E22FD8272002D0A72 /* PNManageMembershipsRequest.h in Headers */, 798843861C191579003E8948 /* PNConfiguration.h in Headers */, @@ -4729,16 +5095,21 @@ 798843811C191579003E8948 /* PubNub+Publish.h in Headers */, 7988437A1C191579003E8948 /* PNReachability.h in Headers */, 79F85805219640CB00BFD0B1 /* PNClientStateGetResult.h in Headers */, + A57A309F238D784A00DE8C68 /* PNBaseNotificationPayload.h in Headers */, 798843791C191579003E8948 /* PubNub+History.h in Headers */, A589756F22FEF0F70093BD9A /* PNBaseObjectsRequest+Private.h in Headers */, 7988437D1C191579003E8948 /* PNClientState.h in Headers */, A55A879522FD8272002D0A72 /* PNManageUserDataRequest.h in Headers */, + A57A30E0238DC87400DE8C68 /* PNAPNSNotificationTarget.h in Headers */, 79F90F201FDEC1C9007132A3 /* PNPresenceHeartbeatAPICallBuilder.h in Headers */, 7988436D1C191579003E8948 /* PNErrorParser.h in Headers */, 7988435C1C191579003E8948 /* PNErrorStatus.h in Headers */, + A57A3021238D59B500DE8C68 /* PNAuditPushNotificationsRequest.h in Headers */, 79A0D9661DC231050039A264 /* PNUnsubscribeChannelsOrGroupsAPICallBuilder.h in Headers */, A55A86CC22FD817E002D0A72 /* PNUser.h in Headers */, 79A0D8F41DC230360039A264 /* PNPublishAPICallBuilder.h in Headers */, + A57A30B8238DC6B600DE8C68 /* PNAPNSNotificationPayload.h in Headers */, + A57A30F7238DDCA300DE8C68 /* PNAPNSNotificationPayload+Private.h in Headers */, 798843511C191579003E8948 /* PNLeaveParser.h in Headers */, 798843501C191579003E8948 /* PNServiceData.h in Headers */, 798843971C191579003E8948 /* PNURLRequest.h in Headers */, @@ -4762,6 +5133,7 @@ 798843481C191579003E8948 /* PNURLBuilder.h in Headers */, A55A867F22FD80B9002D0A72 /* PNCreateSpaceAPICallBuilder.h in Headers */, 798843951C191579003E8948 /* PNHeartbeat.h in Headers */, + A5105B56238F027D00CB693D /* PNDate.h in Headers */, 79A0D8A01DC22F850039A264 /* PNAPNSModificationAPICallBuilder.h in Headers */, 798843841C191579003E8948 /* PubNub+Time.h in Headers */, A586A9F22337E581008856D2 /* PNFetchMessageActionsResult.h in Headers */, @@ -4793,11 +5165,13 @@ A5A7AFD3234932F30060113B /* PNFetchMessagesActionsParser.h in Headers */, A55A888A22FD8272002D0A72 /* PNRequest+Private.h in Headers */, 798843771C191579003E8948 /* PNParser.h in Headers */, + A57A3052238D59B500DE8C68 /* PNBasePushNotificationsRequest.h in Headers */, 7988435F1C191579003E8948 /* PNStatus.h in Headers */, 798843441C191579003E8948 /* PNString.h in Headers */, A56865AF230172950014E17C /* PNFetchSpacesParser.h in Headers */, A55A867122FD80B9002D0A72 /* PNFetchSpacesAPICallBuilder.h in Headers */, 798843431C191579003E8948 /* PNResult.h in Headers */, + A57A3013238D59B500DE8C68 /* PNAddPushNotificationsRequest.h in Headers */, A55A861D22FD80B9002D0A72 /* PNUpdateUserAPICallBuilder.h in Headers */, 7988437B1C191579003E8948 /* PNArray.h in Headers */, A55A872522FD81E3002D0A72 /* PNUpdateSpaceStatus.h in Headers */, @@ -4808,6 +5182,7 @@ 79ABD8971F01636B007634E0 /* PNTelemetry.h in Headers */, A5A7AFFF2349330F0060113B /* PNFetchMessageActionsRequest.h in Headers */, 798843AA1C191692003E8948 /* PubNub.h in Headers */, + A57A306F238D6BCC00DE8C68 /* PNFCMNotificationPayload.h in Headers */, 79A0D90C1DC230680039A264 /* PNStateAPICallBuilder.h in Headers */, 7988435A1C191579003E8948 /* PNJSON.h in Headers */, A58975B823005AAC0093BD9A /* PNManageMembershipsStatus.h in Headers */, @@ -4824,6 +5199,7 @@ isa = PBXHeadersBuildPhase; buildActionMask = 2147483647; files = ( + A57A301C238D59B500DE8C68 /* PNAuditPushNotificationsRequest.h in Headers */, 79A0D92B1DC230AB0039A264 /* PNStreamAPICallBuilder.h in Headers */, 79A238DF1D2E70BD00D080CD /* NSURLSessionConfiguration+PNConfigurationPrivate.h in Headers */, A58975B323005AAC0093BD9A /* PNManageMembershipsStatus.h in Headers */, @@ -4835,6 +5211,7 @@ A56865612300622C0014E17C /* PNMember+Private.h in Headers */, 79A8BCBA1C58F93900015BDE /* PNChannelGroupModificationParser.h in Headers */, A55A85FC22FD80B9002D0A72 /* PNCreateUserAPICallBuilder.h in Headers */, + A57A3038238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.h in Headers */, 79A8BC6A1C58F93900015BDE /* PNChannelGroupClientStateResult.h in Headers */, A55A86E122FD81E3002D0A72 /* PNFetchUsersResult.h in Headers */, 79A8BC771C58F93900015BDE /* PNPushNotificationsAuditParser.h in Headers */, @@ -4845,8 +5222,10 @@ 79A8BC6C1C58F93900015BDE /* PNChannelGroupChannelsResult.h in Headers */, A55A867A22FD80B9002D0A72 /* PNCreateSpaceAPICallBuilder.h in Headers */, 79F90F1B1FDEC1C6007132A3 /* PNPresenceHeartbeatAPICallBuilder.h in Headers */, + A57A30F2238DDCA300DE8C68 /* PNAPNSNotificationPayload+Private.h in Headers */, 79A8BC9F1C58F93900015BDE /* PNNetworkResponseSerializer.h in Headers */, 79F85800219640C500BFD0B1 /* PNClientStateGetResult.h in Headers */, + A57A30C3238DC71800DE8C68 /* PNAPNSNotificationConfiguration.h in Headers */, 79A8BC6D1C58F93900015BDE /* PNAPNSEnabledChannelsResult.h in Headers */, 79A8BC6F1C58F93900015BDE /* PNChannelClientStateResult.h in Headers */, 79E20D251C8AEFF1001BC9CC /* PNSubscribeStatus+Private.h in Headers */, @@ -4869,8 +5248,10 @@ 79A8BC9E1C58F93900015BDE /* PNServiceData+Private.h in Headers */, 797D605B22D2E41100E64C94 /* PNSignalAPICallBuilder.h in Headers */, A56865BA230173030014E17C /* PNSpaceDataChangeParser.h in Headers */, + A57A30DB238DC87400DE8C68 /* PNAPNSNotificationTarget.h in Headers */, 79A8BC741C58F93900015BDE /* PNObjectEventListener.h in Headers */, 79A8BC721C58F93900015BDE /* PNChannelGroupsResult.h in Headers */, + A55CA69E2397389100B24E02 /* PNKeychain+Private.h in Headers */, A55A864222FD80B9002D0A72 /* PNFetchUsersAPICallBuilder.h in Headers */, 79E20D171C8AEC43001BC9CC /* PNEnvelopeInformation.h in Headers */, A55A880022FD8272002D0A72 /* PNUpdateSpaceRequest.h in Headers */, @@ -4885,6 +5266,8 @@ 79A0D9071DC230670039A264 /* PNStateAPICallBuilder.h in Headers */, 79A3E429221569DA00F2ADB9 /* PNMessageCountParser.h in Headers */, 79A8BC901C58F93900015BDE /* PNPrivateStructures.h in Headers */, + A57A300E238D59B500DE8C68 /* PNAddPushNotificationsRequest.h in Headers */, + A57A30A9238D78C400DE8C68 /* PNBaseNotificationPayload+Private.h in Headers */, 79A8BC761C58F93900015BDE /* PNClientInformation.h in Headers */, A55A87C822FD8272002D0A72 /* PNDeleteUserRequest.h in Headers */, A55A866C22FD80B9002D0A72 /* PNFetchSpacesAPICallBuilder.h in Headers */, @@ -4897,6 +5280,7 @@ A5A7AFFA2349330F0060113B /* PNFetchMessageActionsRequest.h in Headers */, 79A8BC9D1C58F93900015BDE /* PNHeartbeatParser.h in Headers */, A55A885422FD8272002D0A72 /* PNFetchMembersRequest.h in Headers */, + A57A3023238D59B500DE8C68 /* PNRemovePushNotificationsRequest.h in Headers */, A55A86EF22FD81E3002D0A72 /* PNCreateUserStatus.h in Headers */, A5A7B00F2349330F0060113B /* PNAddMessageActionRequest.h in Headers */, 79A0D88F1DC22F690039A264 /* PNAPNSAuditAPICallBuilder.h in Headers */, @@ -4915,7 +5299,9 @@ 79A8BCA81C58F93900015BDE /* PNHistoryParser.h in Headers */, A58975D323005BE60093BD9A /* PNMember.h in Headers */, A55A87DD22FD8272002D0A72 /* PNBaseObjectsRequest.h in Headers */, + A57A308A238D751400DE8C68 /* PNMPNSNotificationPayload.h in Headers */, 79A8BC7E1C58F93900015BDE /* PNHistoryResult.h in Headers */, + A57A30EA238DCAAF00DE8C68 /* PNAPNSNotificationTarget+Private.h in Headers */, A55A881C22FD8272002D0A72 /* PNFetchSpacesRequest.h in Headers */, A56865CA230173AA0014E17C /* PNObjectsDeleteParser.h in Headers */, 79A0D9611DC231030039A264 /* PNUnsubscribeChannelsOrGroupsAPICallBuilder.h in Headers */, @@ -4959,7 +5345,9 @@ 79A8BC861C58F93900015BDE /* PNTimeResult.h in Headers */, A55A86C022FD817E002D0A72 /* PNUser+Private.h in Headers */, 79A0D8BF1DC22FD60039A264 /* PNPresenceChannelHereNowAPICallBuilder.h in Headers */, + A57A30D2238DC7FF00DE8C68 /* PNAPNSNotificationConfiguration+Private.h in Headers */, 79A8BC831C58F93900015BDE /* PNErrorCodes.h in Headers */, + A57A304D238D59B500DE8C68 /* PNBasePushNotificationsRequest.h in Headers */, A55A881522FD8272002D0A72 /* PNCreateSpaceRequest.h in Headers */, 79A8BC821C58F93900015BDE /* PubNub+State.h in Headers */, 79A8BCB41C58F93900015BDE /* PNConstants.h in Headers */, @@ -4975,6 +5363,7 @@ A5A7B0322349330F0060113B /* PNBaseMessageActionRequest.h in Headers */, A5A7B02B2349330F0060113B /* PNRemoveMessageActionRequest.h in Headers */, A586A9ED2337E581008856D2 /* PNFetchMessageActionsResult.h in Headers */, + A57A309A238D784A00DE8C68 /* PNBaseNotificationPayload.h in Headers */, 79A8BC811C58F93900015BDE /* PubNub+APNS.h in Headers */, A55A878922FD8272002D0A72 /* PNUpdateUserRequest.h in Headers */, A55A863B22FD80B9002D0A72 /* PNFetchUserAPICallBuilder.h in Headers */, @@ -4991,6 +5380,7 @@ A55A872022FD81E3002D0A72 /* PNUpdateSpaceStatus.h in Headers */, 79A8BC961C58F93900015BDE /* PNHelpers.h in Headers */, 7925DB881D3FFCAC00857C0D /* PNLLogger.h in Headers */, + A5105B51238F027D00CB693D /* PNDate.h in Headers */, A568659A230170690014E17C /* PNFetchUsersParser.h in Headers */, A55A861822FD80B9002D0A72 /* PNUpdateUserAPICallBuilder.h in Headers */, 79A8BCAE1C58F93900015BDE /* PNNumber.h in Headers */, @@ -4998,8 +5388,10 @@ 79A8BCA31C58F93900015BDE /* PNParser.h in Headers */, 79ABD8921F01636B007634E0 /* PNTelemetry.h in Headers */, 79A8BCA21C58F93900015BDE /* PNString.h in Headers */, + A57A30B3238DC6B600DE8C68 /* PNAPNSNotificationPayload.h in Headers */, 79A0D95B1DC230FE0039A264 /* PNUnsubscribeAPICallBuilder.h in Headers */, 79A8BC8A1C58F93900015BDE /* PNResult.h in Headers */, + A57A306A238D6BCC00DE8C68 /* PNFCMNotificationPayload.h in Headers */, 79A8BC891C58F93900015BDE /* PNStatus.h in Headers */, 79A8BCA61C58F93900015BDE /* PNArray.h in Headers */, A55A888C22FD8272002D0A72 /* PNRequest.h in Headers */, @@ -5014,6 +5406,7 @@ A568658A2300729E0014E17C /* PNFetchMembersResult.h in Headers */, A568656A2300709F0014E17C /* PNFetchMembershipsResult.h in Headers */, A55A868122FD80B9002D0A72 /* PNUpdateSpaceAPICallBuilder.h in Headers */, + A57A305A238D65A200DE8C68 /* PNNotificationsPayload.h in Headers */, 79A8BC8B1C58F93900015BDE /* PubNub.h in Headers */, 79A8BC8C1C58F93900015BDE /* PNAES.h in Headers */, A55A887722FD8272002D0A72 /* PNManageMembersRequest.h in Headers */, @@ -5062,6 +5455,7 @@ A55A879A22FD8272002D0A72 /* PNFetchUsersRequest.h in Headers */, 79A0D92E1DC230AC0039A264 /* PNStreamAPICallBuilder.h in Headers */, 79ACC43B1C11BC4D0056523A /* PNChannelClientStateResult.h in Headers */, + A57A30AC238D78C400DE8C68 /* PNBaseNotificationPayload+Private.h in Headers */, 79E20D281C8AEFF3001BC9CC /* PNSubscribeStatus+Private.h in Headers */, 79ACC43C1C11BC4D0056523A /* PNClientStateUpdateStatus.h in Headers */, 79ACC4781C11BC4D0056523A /* PNPresenceWhereNowParser.h in Headers */, @@ -5071,6 +5465,7 @@ A56FAEF6233161570072ADD6 /* PubNub+MessageActions.h in Headers */, 79ACC4871C11BC4D0056523A /* PNPresenceHereNowParser.h in Headers */, 79ACC4841C11BC4D0056523A /* PubNub+SubscribePrivate.h in Headers */, + A57A303B238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.h in Headers */, A55A87A122FD8272002D0A72 /* PNCreateUserRequest.h in Headers */, A55A870722FD81E3002D0A72 /* PNUpdateUserStatus.h in Headers */, 79A0D9581DC230FA0039A264 /* PNSubscribeChannelsOrGroupsAPIBuilder.h in Headers */, @@ -5086,11 +5481,13 @@ A55A868422FD80B9002D0A72 /* PNUpdateSpaceAPICallBuilder.h in Headers */, 79ACC4691C11BC4D0056523A /* PNServiceData+Private.h in Headers */, 79ACC4401C11BC4D0056523A /* PNObjectEventListener.h in Headers */, + A57A30D5238DC7FF00DE8C68 /* PNAPNSNotificationConfiguration+Private.h in Headers */, A58975E523005CFB0093BD9A /* PNMembership+Private.h in Headers */, 79ACC43E1C11BC4D0056523A /* PNChannelGroupsResult.h in Headers */, 79E20D1A1C8AEC45001BC9CC /* PNEnvelopeInformation.h in Headers */, A55A887A22FD8272002D0A72 /* PNManageMembersRequest.h in Headers */, 7925DB991D3FFCAC00857C0D /* PNLLogFileInformation.h in Headers */, + A57A3026238D59B500DE8C68 /* PNRemovePushNotificationsRequest.h in Headers */, 79ACC47E1C11BC4D0056523A /* PNClientStateParser.h in Headers */, A55A87AF22FD8272002D0A72 /* PNFetchUserRequest.h in Headers */, 79ACC4721C11BC4D0056523A /* PNRequestParameters.h in Headers */, @@ -5106,6 +5503,7 @@ 79A0D8C21DC22FD70039A264 /* PNPresenceChannelHereNowAPICallBuilder.h in Headers */, A55BCD0A231D22400019DB68 /* PNFetchMessagesActionsAPICallBuilder.h in Headers */, 79ACC4421C11BC4D0056523A /* PNClientInformation.h in Headers */, + A57A30ED238DCAAF00DE8C68 /* PNAPNSNotificationTarget+Private.h in Headers */, 79ACC4411C11BC4D0056523A /* PNSubscriberResults.h in Headers */, 79ACC43F1C11BC4D0056523A /* PubNub+ChannelGroup.h in Headers */, 79ACC4821C11BC4D0056523A /* PubNub+CorePrivate.h in Headers */, @@ -5117,11 +5515,14 @@ A55A882622FD8272002D0A72 /* PNFetchSpaceRequest.h in Headers */, 79ACC4641C11BC4D0056523A /* PNSubscribeParser.h in Headers */, 79ACC4451C11BC4D0056523A /* PNSubscribeStatus.h in Headers */, + A55CA6A12397389100B24E02 /* PNKeychain+Private.h in Headers */, A55A86BC22FD817E002D0A72 /* PNSpace.h in Headers */, 79ACC4811C11BC4D0056523A /* PNResult+Private.h in Headers */, + A57A30C6238DC71800DE8C68 /* PNAPNSNotificationConfiguration.h in Headers */, A55BCCA62319243F0019DB68 /* PNAddMessageActionStatus.h in Headers */, A56865CD230173AA0014E17C /* PNObjectsDeleteParser.h in Headers */, A55A872A22FD81E3002D0A72 /* PNFetchSpacesResult.h in Headers */, + A57A305D238D65A200DE8C68 /* PNNotificationsPayload.h in Headers */, 79A0D9161DC230890039A264 /* PNStateModificationAPICallBuilder.h in Headers */, A55A86F222FD81E3002D0A72 /* PNCreateUserStatus.h in Headers */, 79ACC4661C11BC4D0056523A /* PNStatus+Private.h in Headers */, @@ -5129,6 +5530,7 @@ 79A0D87A1DC22F230039A264 /* PNAPICallBuilder.h in Headers */, 79A0D8CE1DC22FFB0039A264 /* PNPresenceWhereNowAPICallBuilder.h in Headers */, 79ACC4441C11BC4D0056523A /* PubNub+Subscribe.h in Headers */, + A57A308D238D751400DE8C68 /* PNMPNSNotificationPayload.h in Headers */, 79ACC4801C11BC4D0056523A /* PNStateListener.h in Headers */, A55A886C22FD8272002D0A72 /* PNManageMembershipsRequest.h in Headers */, 79ACC4731C11BC4D0056523A /* PNHistoryParser.h in Headers */, @@ -5146,16 +5548,21 @@ 79ACC4631C11BC4D0056523A /* PNReachability.h in Headers */, 79ACC44B1C11BC4D0056523A /* PubNub+History.h in Headers */, 79F85803219640CA00BFD0B1 /* PNClientStateGetResult.h in Headers */, + A57A309D238D784A00DE8C68 /* PNBaseNotificationPayload.h in Headers */, 79ACC4471C11BC4D0056523A /* PubNub+Publish.h in Headers */, A589756D22FEF0F70093BD9A /* PNBaseObjectsRequest+Private.h in Headers */, 79ACC46F1C11BC4D0056523A /* PNLeaveParser.h in Headers */, A55A879322FD8272002D0A72 /* PNManageUserDataRequest.h in Headers */, + A57A30DE238DC87400DE8C68 /* PNAPNSNotificationTarget.h in Headers */, 79F90F1E1FDEC1C7007132A3 /* PNPresenceHeartbeatAPICallBuilder.h in Headers */, 79ACC46B1C11BC4D0056523A /* PNClientState.h in Headers */, 79ACC45B1C11BC4D0056523A /* PNErrorParser.h in Headers */, + A57A301F238D59B500DE8C68 /* PNAuditPushNotificationsRequest.h in Headers */, 79A0D9641DC231040039A264 /* PNUnsubscribeChannelsOrGroupsAPICallBuilder.h in Headers */, A55A86CA22FD817E002D0A72 /* PNUser.h in Headers */, 79A0D8F21DC230360039A264 /* PNPublishAPICallBuilder.h in Headers */, + A57A30B6238DC6B600DE8C68 /* PNAPNSNotificationPayload.h in Headers */, + A57A30F5238DDCA300DE8C68 /* PNAPNSNotificationPayload+Private.h in Headers */, 79ACC4531C11BC4D0056523A /* PNErrorStatus.h in Headers */, 79ACC44C1C11BC4D0056523A /* PNServiceData.h in Headers */, 79ACC47A1C11BC4D0056523A /* PNDictionary.h in Headers */, @@ -5179,6 +5586,7 @@ 79ACC44E1C11BC4D0056523A /* PubNub+State.h in Headers */, A55A867D22FD80B9002D0A72 /* PNCreateSpaceAPICallBuilder.h in Headers */, 79ACC47F1C11BC4D0056523A /* PNConstants.h in Headers */, + A5105B54238F027D00CB693D /* PNDate.h in Headers */, 79A0D89E1DC22F840039A264 /* PNAPNSModificationAPICallBuilder.h in Headers */, 79ACC45A1C11BC4D0056523A /* PNHeartbeat.h in Headers */, A586A9F02337E581008856D2 /* PNFetchMessageActionsResult.h in Headers */, @@ -5210,11 +5618,13 @@ A5A7AFD1234932F30060113B /* PNFetchMessagesActionsParser.h in Headers */, A55A888822FD8272002D0A72 /* PNRequest+Private.h in Headers */, 79ACC46E1C11BC4D0056523A /* PNParser.h in Headers */, + A57A3050238D59B500DE8C68 /* PNBasePushNotificationsRequest.h in Headers */, 79ACC46D1C11BC4D0056523A /* PNString.h in Headers */, 79ACC4561C11BC4D0056523A /* PNResult.h in Headers */, A56865AD230172950014E17C /* PNFetchSpacesParser.h in Headers */, A55A866F22FD80B9002D0A72 /* PNFetchSpacesAPICallBuilder.h in Headers */, 79ACC4551C11BC4D0056523A /* PNStatus.h in Headers */, + A57A3011238D59B500DE8C68 /* PNAddPushNotificationsRequest.h in Headers */, A55A861B22FD80B9002D0A72 /* PNUpdateUserAPICallBuilder.h in Headers */, 79ACC4711C11BC4D0056523A /* PNArray.h in Headers */, A55A872322FD81E3002D0A72 /* PNUpdateSpaceStatus.h in Headers */, @@ -5225,6 +5635,7 @@ 79ABD8951F01636B007634E0 /* PNTelemetry.h in Headers */, A5A7AFFD2349330F0060113B /* PNFetchMessageActionsRequest.h in Headers */, 79ACC45F1C11BC4D0056523A /* PNGZIP.h in Headers */, + A57A306D238D6BCC00DE8C68 /* PNFCMNotificationPayload.h in Headers */, 79A0D90A1DC230680039A264 /* PNStateAPICallBuilder.h in Headers */, 79ACC45D1C11BC4D0056523A /* PNJSON.h in Headers */, A58975B623005AAC0093BD9A /* PNManageMembershipsStatus.h in Headers */, @@ -5241,6 +5652,7 @@ isa = PBXHeadersBuildPhase; buildActionMask = 2147483647; files = ( + A57A301E238D59B500DE8C68 /* PNAuditPushNotificationsRequest.h in Headers */, 79A0D92D1DC230AC0039A264 /* PNStreamAPICallBuilder.h in Headers */, 79A238E11D2E70BD00D080CD /* NSURLSessionConfiguration+PNConfigurationPrivate.h in Headers */, A58975B523005AAC0093BD9A /* PNManageMembershipsStatus.h in Headers */, @@ -5252,6 +5664,7 @@ A56865632300622C0014E17C /* PNMember+Private.h in Headers */, 79CBB16A1BD03DE4001FC34D /* PNChannelGroupModificationParser.h in Headers */, A55A85FE22FD80B9002D0A72 /* PNCreateUserAPICallBuilder.h in Headers */, + A57A303A238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.h in Headers */, 79CBB1241BD03DE4001FC34D /* PNChannelGroupClientStateResult.h in Headers */, A55A86E322FD81E3002D0A72 /* PNFetchUsersResult.h in Headers */, 79CBB17C1BD03DE4001FC34D /* PNPushNotificationsAuditParser.h in Headers */, @@ -5262,8 +5675,10 @@ 79CBB1221BD03DE4001FC34D /* PNChannelGroupChannelsResult.h in Headers */, A55A867C22FD80B9002D0A72 /* PNCreateSpaceAPICallBuilder.h in Headers */, 79F90F1D1FDEC1C7007132A3 /* PNPresenceHeartbeatAPICallBuilder.h in Headers */, + A57A30F4238DDCA300DE8C68 /* PNAPNSNotificationPayload+Private.h in Headers */, 79CBB1881BD03DE4001FC34D /* PNNetworkResponseSerializer.h in Headers */, 79F85802219640CA00BFD0B1 /* PNClientStateGetResult.h in Headers */, + A57A30C5238DC71800DE8C68 /* PNAPNSNotificationConfiguration.h in Headers */, 79CBB11E1BD03DE4001FC34D /* PNAPNSEnabledChannelsResult.h in Headers */, 79CBB1201BD03DE4001FC34D /* PNChannelClientStateResult.h in Headers */, 79E20D271C8AEFF2001BC9CC /* PNSubscribeStatus+Private.h in Headers */, @@ -5286,8 +5701,10 @@ 79CBB13C1BD03DE4001FC34D /* PNServiceData+Private.h in Headers */, 797D605D22D2E41100E64C94 /* PNSignalAPICallBuilder.h in Headers */, A56865BC230173030014E17C /* PNSpaceDataChangeParser.h in Headers */, + A57A30DD238DC87400DE8C68 /* PNAPNSNotificationTarget.h in Headers */, 79CBB1661BD03DE4001FC34D /* PNObjectEventListener.h in Headers */, 79CBB1261BD03DE4001FC34D /* PNChannelGroupsResult.h in Headers */, + A55CA6A02397389100B24E02 /* PNKeychain+Private.h in Headers */, A55A864422FD80B9002D0A72 /* PNFetchUsersAPICallBuilder.h in Headers */, 79E20D191C8AEC44001BC9CC /* PNEnvelopeInformation.h in Headers */, A55A880222FD8272002D0A72 /* PNUpdateSpaceRequest.h in Headers */, @@ -5302,6 +5719,8 @@ 79A0D9091DC230670039A264 /* PNStateAPICallBuilder.h in Headers */, 79A3E42B221569DA00F2ADB9 /* PNMessageCountParser.h in Headers */, 79CBB1171BD03DE4001FC34D /* PNClientInformation.h in Headers */, + A57A3010238D59B500DE8C68 /* PNAddPushNotificationsRequest.h in Headers */, + A57A30AB238D78C400DE8C68 /* PNBaseNotificationPayload+Private.h in Headers */, 79CBB1421BD03DE4001FC34D /* PNSubscriberResults.h in Headers */, A55A87CA22FD8272002D0A72 /* PNDeleteUserRequest.h in Headers */, A55A866E22FD80B9002D0A72 /* PNFetchSpacesAPICallBuilder.h in Headers */, @@ -5314,6 +5733,7 @@ A5A7AFFC2349330F0060113B /* PNFetchMessageActionsRequest.h in Headers */, 79CBB1821BD03DE4001FC34D /* PNSubscribeParser.h in Headers */, A55A885622FD8272002D0A72 /* PNFetchMembersRequest.h in Headers */, + A57A3025238D59B500DE8C68 /* PNRemovePushNotificationsRequest.h in Headers */, A55A86F122FD81E3002D0A72 /* PNCreateUserStatus.h in Headers */, A5A7B0112349330F0060113B /* PNAddMessageActionRequest.h in Headers */, 79A0D8911DC22F690039A264 /* PNAPNSAuditAPICallBuilder.h in Headers */, @@ -5332,7 +5752,9 @@ 79CBB12D1BD03DE4001FC34D /* PNHistoryResult.h in Headers */, A58975D523005BE60093BD9A /* PNMember.h in Headers */, A55A87DF22FD8272002D0A72 /* PNBaseObjectsRequest.h in Headers */, + A57A308C238D751400DE8C68 /* PNMPNSNotificationPayload.h in Headers */, 79CBB11A1BD03DE4001FC34D /* PNConfiguration.h in Headers */, + A57A30EC238DCAAF00DE8C68 /* PNAPNSNotificationTarget+Private.h in Headers */, A55A881E22FD8272002D0A72 /* PNFetchSpacesRequest.h in Headers */, A56865CC230173AA0014E17C /* PNObjectsDeleteParser.h in Headers */, 79A0D9631DC231040039A264 /* PNUnsubscribeChannelsOrGroupsAPICallBuilder.h in Headers */, @@ -5376,7 +5798,9 @@ 79CBB1631BD03DE4001FC34D /* PNErrorCodes.h in Headers */, A55A86C222FD817E002D0A72 /* PNUser+Private.h in Headers */, 79A0D8C11DC22FD60039A264 /* PNPresenceChannelHereNowAPICallBuilder.h in Headers */, + A57A30D4238DC7FF00DE8C68 /* PNAPNSNotificationConfiguration+Private.h in Headers */, 79CBB1061BD03DE4001FC34D /* PubNub+State.h in Headers */, + A57A304F238D59B500DE8C68 /* PNBasePushNotificationsRequest.h in Headers */, A55A881722FD8272002D0A72 /* PNCreateSpaceRequest.h in Headers */, 79CBB1621BD03DE4001FC34D /* PNConstants.h in Headers */, 79CBB10F1BD03DE4001FC34D /* PNHeartbeat.h in Headers */, @@ -5392,6 +5816,7 @@ A5A7B0342349330F0060113B /* PNBaseMessageActionRequest.h in Headers */, A5A7B02D2349330F0060113B /* PNRemoveMessageActionRequest.h in Headers */, A586A9EF2337E581008856D2 /* PNFetchMessageActionsResult.h in Headers */, + A57A309C238D784A00DE8C68 /* PNBaseNotificationPayload.h in Headers */, 79CBB1611BD03DE4001FC34D /* PNLogMacro.h in Headers */, A55A878B22FD8272002D0A72 /* PNUpdateUserRequest.h in Headers */, A55A863D22FD80B9002D0A72 /* PNFetchUserAPICallBuilder.h in Headers */, @@ -5408,6 +5833,7 @@ A55A872222FD81E3002D0A72 /* PNUpdateSpaceStatus.h in Headers */, 7925DB8A1D3FFCAC00857C0D /* PNLLogger.h in Headers */, 793887071BEAD4A800DCC662 /* PNNumber.h in Headers */, + A5105B53238F027D00CB693D /* PNDate.h in Headers */, A568659C230170690014E17C /* PNFetchUsersParser.h in Headers */, A55A861A22FD80B9002D0A72 /* PNUpdateUserAPICallBuilder.h in Headers */, 79CBB1671BD03DE4001FC34D /* PNParser.h in Headers */, @@ -5415,8 +5841,10 @@ 79CBB1571BD03DE4001FC34D /* PNString.h in Headers */, 79ABD8941F01636B007634E0 /* PNTelemetry.h in Headers */, 79CBB13A1BD03DE4001FC34D /* PNResult.h in Headers */, + A57A30B5238DC6B600DE8C68 /* PNAPNSNotificationPayload.h in Headers */, 79A0D95D1DC230FF0039A264 /* PNUnsubscribeAPICallBuilder.h in Headers */, 79CBB1401BD03DE4001FC34D /* PNStatus.h in Headers */, + A57A306C238D6BCC00DE8C68 /* PNFCMNotificationPayload.h in Headers */, 7925DB981D3FFCAC00857C0D /* PNLLogFileInformation.h in Headers */, 79CBB1481BD03DE4001FC34D /* PNArray.h in Headers */, A55A888E22FD8272002D0A72 /* PNRequest.h in Headers */, @@ -5431,6 +5859,7 @@ A568658C2300729E0014E17C /* PNFetchMembersResult.h in Headers */, A568656C2300709F0014E17C /* PNFetchMembershipsResult.h in Headers */, A55A868322FD80B9002D0A72 /* PNUpdateSpaceAPICallBuilder.h in Headers */, + A57A305C238D65A200DE8C68 /* PNNotificationsPayload.h in Headers */, 79CBB0421BD03D3F001FC34D /* PubNub.h in Headers */, 79CBB1151BD03DE4001FC34D /* PNAES.h in Headers */, A55A887922FD8272002D0A72 /* PNManageMembersRequest.h in Headers */, @@ -5601,7 +6030,7 @@ 79CBB0351BD03D3F001FC34D /* Project object */ = { isa = PBXProject; attributes = { - LastUpgradeCheck = 1020; + LastUpgradeCheck = 1120; ORGANIZATIONNAME = PubNub; TargetAttributes = { 791582051BD709C60084FC70 = { @@ -6266,12 +6695,14 @@ files = ( 791582151BD709C60084FC70 /* PNPushNotificationsStateModificationParser.m in Sources */, A55A87EA22FD8272002D0A72 /* PNFetchSpacesRequest.m in Sources */, + A57A30B9238DC6B600DE8C68 /* PNAPNSNotificationPayload.m in Sources */, 79A238D71D2E70BD00D080CD /* NSURLSessionConfiguration+PNConfiguration.m in Sources */, A55A884522FD8272002D0A72 /* PNManageMembershipsRequest.m in Sources */, A5A7AFDB234932F30060113B /* PNAddMessageActionParser.m in Sources */, A55A86FC22FD81E3002D0A72 /* PNCreateSpaceStatus.m in Sources */, 791582411BD709C60084FC70 /* PNPresenceChannelGroupHereNowResult.m in Sources */, 7915822A1BD709C60084FC70 /* PNChannelGroupModificationParser.m in Sources */, + A57A30C9238DC71800DE8C68 /* PNAPNSNotificationConfiguration.m in Sources */, 7915823F1BD709C60084FC70 /* PNChannelGroupClientStateResult.m in Sources */, 791582491BD709C60084FC70 /* PNPresenceChannelHereNowResult.m in Sources */, 79ABD8981F01636B007634E0 /* PNTelemetry.m in Sources */, @@ -6289,6 +6720,7 @@ 7915822D1BD709C60084FC70 /* PNChannelGroupChannelsResult.m in Sources */, 791582191BD709C60084FC70 /* PNChannelGroupAuditionParser.m in Sources */, 791582471BD709C60084FC70 /* PNAPNSEnabledChannelsResult.m in Sources */, + A57A303E238D59B500DE8C68 /* PNRemovePushNotificationsRequest.m in Sources */, 791582451BD709C60084FC70 /* PNNetworkResponseSerializer.m in Sources */, A58975C923005BD80093BD9A /* PNMembership.m in Sources */, 791582261BD709C60084FC70 /* PNChannelClientStateResult.m in Sources */, @@ -6300,6 +6732,7 @@ A55A862C22FD80B9002D0A72 /* PNCreateUserAPICallBuilder.m in Sources */, A55A86AA22FD817E002D0A72 /* PNUser.m in Sources */, 791582271BD709C60084FC70 /* PNPresenceWhereNowParser.m in Sources */, + A57A3030238D59B500DE8C68 /* PNAddPushNotificationsRequest.m in Sources */, 7915824C1BD709C60084FC70 /* PNPresenceHereNowParser.m in Sources */, A56865D0230173AA0014E17C /* PNObjectsDeleteParser.m in Sources */, A55A86CD22FD817E002D0A72 /* PNSpace.m in Sources */, @@ -6318,6 +6751,7 @@ 791582221BD709C60084FC70 /* PubNub+ChannelGroup.m in Sources */, A56865B0230172950014E17C /* PNFetchSpacesParser.m in Sources */, 7915824A1BD709C60084FC70 /* PNClientStateParser.m in Sources */, + A57A3090238D751400DE8C68 /* PNMPNSNotificationPayload.m in Sources */, 791582301BD709C60084FC70 /* PNSubscribeParser.m in Sources */, A55A87D522FD8272002D0A72 /* PNFetchUsersRequest.m in Sources */, A55A883E22FD8272002D0A72 /* PNBaseObjectsRequest.m in Sources */, @@ -6332,6 +6766,7 @@ 79A0D8631DC22C950039A264 /* PNStreamModificationAPICallBuilder.m in Sources */, A55A867222FD80B9002D0A72 /* PNDeleteSpaceAPICallBuilder.m in Sources */, A55A878122FD8272002D0A72 /* PNFetchUserRequest.m in Sources */, + A57A30A0238D784A00DE8C68 /* PNBaseNotificationPayload.m in Sources */, 79A0D8471DC22C950039A264 /* PNAPNSModificationAPICallBuilder.m in Sources */, A58975A9230014300093BD9A /* PNFetchMembersAPICallBuilder.m in Sources */, A55A86E722FD81E3002D0A72 /* PNFetchUsersResult.m in Sources */, @@ -6357,22 +6792,26 @@ A52DC1ED2307E10B001F20B0 /* NSDateFormatter+PNCacheable.m in Sources */, A56865E0230175EC0014E17C /* PNMembershipsParser.m in Sources */, A5A7AFC6234932F30060113B /* PNFetchMessagesActionsParser.m in Sources */, + A57A3029238D59B500DE8C68 /* PNBasePushNotificationsRequest.m in Sources */, A58975B923005AAC0093BD9A /* PNManageMembershipsStatus.m in Sources */, A56865902300729E0014E17C /* PNFetchMembersResult.m in Sources */, A55BCCED231D21840019DB68 /* PNAddMessageActionAPICallBuilder.m in Sources */, A55A864822FD80B9002D0A72 /* PNUpdateUserAPICallBuilder.m in Sources */, A55A877322FD8272002D0A72 /* PNRequest.m in Sources */, + A57A3060238D65A200DE8C68 /* PNNotificationsPayload.m in Sources */, 79A0D8531DC22C950039A264 /* PNPresenceWhereNowAPICallBuilder.m in Sources */, A55A870A22FD81E3002D0A72 /* PNUpdateUserStatus.m in Sources */, 7915824B1BD709C60084FC70 /* PubNub+Publish.m in Sources */, 79A0D85F1DC22C950039A264 /* PNStreamAPICallBuilder.m in Sources */, 7915820D1BD709C60084FC70 /* PNReachability.m in Sources */, + A57A3045238D59B500DE8C68 /* PNAuditPushNotificationsRequest.m in Sources */, A5A7B0072349330F0060113B /* PNBaseMessageActionRequest.m in Sources */, 79A0D8611DC22C950039A264 /* PNStreamAuditAPICallBuilder.m in Sources */, A55A87C022FD8272002D0A72 /* PNUpdateUserRequest.m in Sources */, 7915822F1BD709C60084FC70 /* PNClientState.m in Sources */, 7915821C1BD709C60084FC70 /* PNErrorStatus.m in Sources */, A5897599230014220093BD9A /* PNManageMembersAPICallBuilder.m in Sources */, + A57A30E1238DC87400DE8C68 /* PNAPNSNotificationTarget.m in Sources */, 7915822E1BD709C60084FC70 /* PNLeaveParser.m in Sources */, 791582361BD709C60084FC70 /* PNServiceData.m in Sources */, 79A0D8571DC22C950039A264 /* PNPublishSizeAPICallBuilder.m in Sources */, @@ -6385,10 +6824,12 @@ 791582331BD709C60084FC70 /* PNTimeParser.m in Sources */, A55A885A22FD8272002D0A72 /* PNManageMembersRequest.m in Sources */, 7915823E1BD709C60084FC70 /* PNURLBuilder.m in Sources */, + A5105B57238F027D00CB693D /* PNDate.m in Sources */, 791582101BD709C60084FC70 /* PNDictionary.m in Sources */, 791582321BD709C60084FC70 /* PNURLRequest.m in Sources */, A55BCD0D231D22400019DB68 /* PNFetchMessagesActionsAPICallBuilder.m in Sources */, A5897579230014090093BD9A /* PNManageMembershipsAPICallBuilder.m in Sources */, + A57A3070238D6BCC00DE8C68 /* PNFCMNotificationPayload.m in Sources */, 791582341BD709C60084FC70 /* PNTimeResult.m in Sources */, 791582201BD709C60084FC70 /* PNHeartbeat.m in Sources */, A55A87F122FD8272002D0A72 /* PNCreateSpaceRequest.m in Sources */, @@ -6420,6 +6861,7 @@ A5A7B01C2349330F0060113B /* PNFetchMessageActionsRequest.m in Sources */, 791582431BD709C60084FC70 /* PNStatus.m in Sources */, 79A0D8671DC22C950039A264 /* PNSubscribeChannelsOrGroupsAPIBuilder.m in Sources */, + A57A3014238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.m in Sources */, 793887051BEAD49100DCC662 /* PNNumber.m in Sources */, 79650C2E1E775E8300006F66 /* PNLockSupport.m in Sources */, 791582481BD709C60084FC70 /* PNResult.m in Sources */, @@ -6446,12 +6888,14 @@ files = ( 79A0D87E1DC22F460039A264 /* PNAPICallBuilder.m in Sources */, A55A87EC22FD8272002D0A72 /* PNFetchSpacesRequest.m in Sources */, + A57A30BB238DC6B600DE8C68 /* PNAPNSNotificationPayload.m in Sources */, 791582BE1BD709D10084FC70 /* PNPushNotificationsStateModificationParser.m in Sources */, A55A884722FD8272002D0A72 /* PNManageMembershipsRequest.m in Sources */, A5A7AFDD234932F30060113B /* PNAddMessageActionParser.m in Sources */, A55A86FE22FD81E3002D0A72 /* PNCreateSpaceStatus.m in Sources */, 79A238D91D2E70BD00D080CD /* NSURLSessionConfiguration+PNConfiguration.m in Sources */, 791582EA1BD709D10084FC70 /* PNPresenceChannelGroupHereNowResult.m in Sources */, + A57A30CB238DC71800DE8C68 /* PNAPNSNotificationConfiguration.m in Sources */, 791582D31BD709D10084FC70 /* PNChannelGroupModificationParser.m in Sources */, 791582E81BD709D10084FC70 /* PNChannelGroupClientStateResult.m in Sources */, 79ABD89A1F01636B007634E0 /* PNTelemetry.m in Sources */, @@ -6469,6 +6913,7 @@ 791582D61BD709D10084FC70 /* PNChannelGroupChannelsResult.m in Sources */, 79A0D8DE1DC230180039A264 /* PNPresenceChannelHereNowAPICallBuilder.m in Sources */, 79A0D8E41DC2301D0039A264 /* PNPresenceHereNowAPICallBuilder.m in Sources */, + A57A3040238D59B500DE8C68 /* PNRemovePushNotificationsRequest.m in Sources */, 79A0D91A1DC2309B0039A264 /* PNStateAPICallBuilder.m in Sources */, A58975CB23005BD80093BD9A /* PNMembership.m in Sources */, 79A0D93E1DC230DE0039A264 /* PNStreamAPICallBuilder.m in Sources */, @@ -6480,6 +6925,7 @@ A55A862E22FD80B9002D0A72 /* PNCreateUserAPICallBuilder.m in Sources */, A55A86AC22FD817E002D0A72 /* PNUser.m in Sources */, 791582EE1BD709D10084FC70 /* PNNetworkResponseSerializer.m in Sources */, + A57A3032238D59B500DE8C68 /* PNAddPushNotificationsRequest.m in Sources */, 79A0D9021DC230590039A264 /* PNPublishSizeAPICallBuilder.m in Sources */, A56865D2230173AA0014E17C /* PNObjectsDeleteParser.m in Sources */, A55A86CF22FD817E002D0A72 /* PNSpace.m in Sources */, @@ -6498,6 +6944,7 @@ 791582C31BD709D10084FC70 /* PNChannelGroupsResult.m in Sources */, A56865B2230172950014E17C /* PNFetchSpacesParser.m in Sources */, 79E20D1E1C8AEC51001BC9CC /* PNEnvelopeInformation.m in Sources */, + A57A3092238D751400DE8C68 /* PNMPNSNotificationPayload.m in Sources */, 7925DB9E1D3FFCAC00857C0D /* PNLLogFileInformation.m in Sources */, A55A87D722FD8272002D0A72 /* PNFetchUsersRequest.m in Sources */, A55A884022FD8272002D0A72 /* PNBaseObjectsRequest.m in Sources */, @@ -6512,6 +6959,7 @@ 791582D51BD709D10084FC70 /* PNClientInformation.m in Sources */, A55A867422FD80B9002D0A72 /* PNDeleteSpaceAPICallBuilder.m in Sources */, A55A878322FD8272002D0A72 /* PNFetchUserRequest.m in Sources */, + A57A30A2238D784A00DE8C68 /* PNBaseNotificationPayload.m in Sources */, 791582D21BD709D10084FC70 /* PNSubscriberResults.m in Sources */, A58975AB230014300093BD9A /* PNFetchMembersAPICallBuilder.m in Sources */, A55A86E922FD81E3002D0A72 /* PNFetchUsersResult.m in Sources */, @@ -6537,22 +6985,26 @@ A52DC1EF2307E10B001F20B0 /* NSDateFormatter+PNCacheable.m in Sources */, A56865E2230175EC0014E17C /* PNMembershipsParser.m in Sources */, A5A7AFC8234932F30060113B /* PNFetchMessagesActionsParser.m in Sources */, + A57A302B238D59B500DE8C68 /* PNBasePushNotificationsRequest.m in Sources */, A58975BB23005AAC0093BD9A /* PNManageMembershipsStatus.m in Sources */, A56865922300729E0014E17C /* PNFetchMembersResult.m in Sources */, A55BCCEF231D21840019DB68 /* PNAddMessageActionAPICallBuilder.m in Sources */, A55A864A22FD80B9002D0A72 /* PNUpdateUserAPICallBuilder.m in Sources */, A55A877522FD8272002D0A72 /* PNRequest.m in Sources */, + A57A3062238D65A200DE8C68 /* PNNotificationsPayload.m in Sources */, 791582BB1BD709D10084FC70 /* PNConfiguration.m in Sources */, A55A870C22FD81E3002D0A72 /* PNUpdateUserStatus.m in Sources */, 79A0D9681DC231350039A264 /* PNSubscribeAPIBuilder.m in Sources */, 791582F41BD709D10084FC70 /* PubNub+Publish.m in Sources */, 79A0D94A1DC230E80039A264 /* PNStreamModificationAPICallBuilder.m in Sources */, + A57A3047238D59B500DE8C68 /* PNAuditPushNotificationsRequest.m in Sources */, A5A7B0092349330F0060113B /* PNBaseMessageActionRequest.m in Sources */, 791582B61BD709D10084FC70 /* PNReachability.m in Sources */, A55A87C222FD8272002D0A72 /* PNUpdateUserRequest.m in Sources */, 791582B21BD709D10084FC70 /* PubNub+History.m in Sources */, 791582DF1BD709D10084FC70 /* PNServiceData.m in Sources */, A589759B230014220093BD9A /* PNManageMembersAPICallBuilder.m in Sources */, + A57A30E3238DC87400DE8C68 /* PNAPNSNotificationTarget.m in Sources */, 79A0D9261DC230A30039A264 /* PNStateModificationAPICallBuilder.m in Sources */, 791582D81BD709D10084FC70 /* PNClientState.m in Sources */, 791582D71BD709D10084FC70 /* PNLeaveParser.m in Sources */, @@ -6565,10 +7017,12 @@ 791582DD1BD709D10084FC70 /* PNTimeResult.m in Sources */, A55A885C22FD8272002D0A72 /* PNManageMembersRequest.m in Sources */, 79A0D8EA1DC230230039A264 /* PNPresenceWhereNowAPICallBuilder.m in Sources */, + A5105B59238F027D00CB693D /* PNDate.m in Sources */, 791582DC1BD709D10084FC70 /* PNTimeParser.m in Sources */, 791582DB1BD709D10084FC70 /* PNURLRequest.m in Sources */, A55BCD0F231D22400019DB68 /* PNFetchMessagesActionsAPICallBuilder.m in Sources */, A589757B230014090093BD9A /* PNManageMembershipsAPICallBuilder.m in Sources */, + A57A3072238D6BCC00DE8C68 /* PNFCMNotificationPayload.m in Sources */, 791582C61BD709D10084FC70 /* PubNub+State.m in Sources */, 791582B91BD709D10084FC70 /* PNDictionary.m in Sources */, A55A87F322FD8272002D0A72 /* PNCreateSpaceRequest.m in Sources */, @@ -6600,6 +7054,7 @@ A5A7B01E2349330F0060113B /* PNFetchMessageActionsRequest.m in Sources */, 79F857FB219640A200BFD0B1 /* PNClientStateGetResult.m in Sources */, 791582EC1BD709D10084FC70 /* PNStatus.m in Sources */, + A57A3016238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.m in Sources */, 79A0D9201DC2309F0039A264 /* PNStateAuditAPICallBuilder.m in Sources */, 793887081BEAD4DE00DCC662 /* PNNumber.m in Sources */, 79650C3C1E775EA000006F66 /* PNLockSupport.m in Sources */, @@ -6626,12 +7081,14 @@ files = ( 79A0D8811DC22F480039A264 /* PNAPICallBuilder.m in Sources */, A55A87EF22FD8272002D0A72 /* PNFetchSpacesRequest.m in Sources */, + A57A30BE238DC6B600DE8C68 /* PNAPNSNotificationPayload.m in Sources */, 798842BF1C18F2EB003E8948 /* PNPushNotificationsStateModificationParser.m in Sources */, A55A884A22FD8272002D0A72 /* PNManageMembershipsRequest.m in Sources */, A5A7AFE0234932F30060113B /* PNAddMessageActionParser.m in Sources */, A55A870122FD81E3002D0A72 /* PNCreateSpaceStatus.m in Sources */, 79A238DC1D2E70BD00D080CD /* NSURLSessionConfiguration+PNConfiguration.m in Sources */, 798842691C18F1E3003E8948 /* PNPresenceChannelGroupHereNowResult.m in Sources */, + A57A30CE238DC71800DE8C68 /* PNAPNSNotificationConfiguration.m in Sources */, 798842B51C18F2EA003E8948 /* PNChannelGroupModificationParser.m in Sources */, 798842641C18F1E3003E8948 /* PNChannelGroupClientStateResult.m in Sources */, 79ABD89D1F01636B007634E0 /* PNTelemetry.m in Sources */, @@ -6649,6 +7106,7 @@ 798842B41C18F2EA003E8948 /* PNChannelGroupAuditionParser.m in Sources */, 79A0D8E11DC230190039A264 /* PNPresenceChannelHereNowAPICallBuilder.m in Sources */, 79A0D8E71DC2301F0039A264 /* PNPresenceHereNowAPICallBuilder.m in Sources */, + A57A3043238D59B500DE8C68 /* PNRemovePushNotificationsRequest.m in Sources */, 79A0D91D1DC2309C0039A264 /* PNStateAPICallBuilder.m in Sources */, A58975CE23005BD80093BD9A /* PNMembership.m in Sources */, 79A0D9411DC230DF0039A264 /* PNStreamAPICallBuilder.m in Sources */, @@ -6660,6 +7118,7 @@ A55A863122FD80B9002D0A72 /* PNCreateUserAPICallBuilder.m in Sources */, A55A86AF22FD817E002D0A72 /* PNUser.m in Sources */, 798842A11C18F2C2003E8948 /* PNNetworkResponseSerializer.m in Sources */, + A57A3035238D59B500DE8C68 /* PNAddPushNotificationsRequest.m in Sources */, 79A0D9051DC2305B0039A264 /* PNPublishSizeAPICallBuilder.m in Sources */, A56865D5230173AA0014E17C /* PNObjectsDeleteParser.m in Sources */, A55A86D222FD817E002D0A72 /* PNSpace.m in Sources */, @@ -6678,6 +7137,7 @@ 798842651C18F1E3003E8948 /* PNChannelGroupsResult.m in Sources */, A56865B5230172950014E17C /* PNFetchSpacesParser.m in Sources */, 79E20D211C8AEC53001BC9CC /* PNEnvelopeInformation.m in Sources */, + A57A3095238D751400DE8C68 /* PNMPNSNotificationPayload.m in Sources */, 7925DBA11D3FFCAC00857C0D /* PNLLogFileInformation.m in Sources */, A55A87DA22FD8272002D0A72 /* PNFetchUsersRequest.m in Sources */, A55A884322FD8272002D0A72 /* PNBaseObjectsRequest.m in Sources */, @@ -6692,6 +7152,7 @@ 798842551C18F1C0003E8948 /* PubNub+ChannelGroup.m in Sources */, A55A867722FD80B9002D0A72 /* PNDeleteSpaceAPICallBuilder.m in Sources */, A55A878622FD8272002D0A72 /* PNFetchUserRequest.m in Sources */, + A57A30A5238D784A00DE8C68 /* PNBaseNotificationPayload.m in Sources */, 798842B61C18F2EA003E8948 /* PNClientStateParser.m in Sources */, A58975AE230014300093BD9A /* PNFetchMembersAPICallBuilder.m in Sources */, A55A86EC22FD81E3002D0A72 /* PNFetchUsersResult.m in Sources */, @@ -6717,22 +7178,26 @@ A52DC1F22307E10B001F20B0 /* NSDateFormatter+PNCacheable.m in Sources */, A56865E5230175EC0014E17C /* PNMembershipsParser.m in Sources */, A5A7AFCB234932F30060113B /* PNFetchMessagesActionsParser.m in Sources */, + A57A302E238D59B500DE8C68 /* PNBasePushNotificationsRequest.m in Sources */, A58975BE23005AAC0093BD9A /* PNManageMembershipsStatus.m in Sources */, A56865952300729E0014E17C /* PNFetchMembersResult.m in Sources */, A55BCCF2231D21840019DB68 /* PNAddMessageActionAPICallBuilder.m in Sources */, A55A864D22FD80B9002D0A72 /* PNUpdateUserAPICallBuilder.m in Sources */, A55A877822FD8272002D0A72 /* PNRequest.m in Sources */, + A57A3065238D65A200DE8C68 /* PNNotificationsPayload.m in Sources */, 798842521C18F1B6003E8948 /* PubNub+Presence.m in Sources */, A55A870F22FD81E3002D0A72 /* PNUpdateUserStatus.m in Sources */, 79A0D96B1DC231370039A264 /* PNSubscribeAPIBuilder.m in Sources */, 798842A21C18F2C2003E8948 /* PNReachability.m in Sources */, 79A0D94D1DC230EA0039A264 /* PNStreamModificationAPICallBuilder.m in Sources */, + A57A304A238D59B500DE8C68 /* PNAuditPushNotificationsRequest.m in Sources */, A5A7B00C2349330F0060113B /* PNBaseMessageActionRequest.m in Sources */, 798842511C18F1AE003E8948 /* PubNub+History.m in Sources */, A55A87C522FD8272002D0A72 /* PNUpdateUserRequest.m in Sources */, 798842531C18F1C0003E8948 /* PubNub+Publish.m in Sources */, 798842B71C18F2EA003E8948 /* PNErrorParser.m in Sources */, A589759E230014220093BD9A /* PNManageMembersAPICallBuilder.m in Sources */, + A57A30E6238DC87400DE8C68 /* PNAPNSNotificationTarget.m in Sources */, 79A0D9281DC230A40039A264 /* PNStateModificationAPICallBuilder.m in Sources */, 798842BA1C18F2EA003E8948 /* PNLeaveParser.m in Sources */, 7988426F1C18F1E3003E8948 /* PNServiceData.m in Sources */, @@ -6745,10 +7210,12 @@ 7988425C1C18F1C8003E8948 /* PNSubscriber.m in Sources */, A55A885F22FD8272002D0A72 /* PNManageMembersRequest.m in Sources */, 79A0D8ED1DC230240039A264 /* PNPresenceWhereNowAPICallBuilder.m in Sources */, + A5105B5C238F027D00CB693D /* PNDate.m in Sources */, 798842C21C18F2EB003E8948 /* PNTimeParser.m in Sources */, 798842731C18F1E3003E8948 /* PNTimeResult.m in Sources */, A55BCD12231D22400019DB68 /* PNFetchMessagesActionsAPICallBuilder.m in Sources */, A589757E230014090093BD9A /* PNManageMembershipsAPICallBuilder.m in Sources */, + A57A3075238D6BCC00DE8C68 /* PNFCMNotificationPayload.m in Sources */, 798842541C18F1C0003E8948 /* PubNub+State.m in Sources */, 7988428F1C18F292003E8948 /* PNDictionary.m in Sources */, A55A87F622FD8272002D0A72 /* PNCreateSpaceRequest.m in Sources */, @@ -6780,6 +7247,7 @@ A5A7B0212349330F0060113B /* PNFetchMessageActionsRequest.m in Sources */, 79F857FE219640AB00BFD0B1 /* PNClientStateGetResult.m in Sources */, 798842701C18F1E3003E8948 /* PNStatus.m in Sources */, + A57A3019238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.m in Sources */, 79A0D9231DC230A00039A264 /* PNStateAuditAPICallBuilder.m in Sources */, 798842921C18F292003E8948 /* PNString.m in Sources */, 79650C3F1E775EA100006F66 /* PNLockSupport.m in Sources */, @@ -6836,18 +7304,22 @@ A56FAEFF233161570072ADD6 /* PubNub+MessageActions.m in Sources */, 79A0D8821DC22F480039A264 /* PNAPICallBuilder.m in Sources */, A55A860F22FD80B9002D0A72 /* PNFetchUserAPICallBuilder.m in Sources */, + A57A30CF238DC71800DE8C68 /* PNAPNSNotificationConfiguration.m in Sources */, 798843371C191579003E8948 /* PNAPNSEnabledChannelsResult.m in Sources */, A55BCD13231D22400019DB68 /* PNFetchMessagesActionsAPICallBuilder.m in Sources */, 798843101C191579003E8948 /* PNNetworkResponseSerializer.m in Sources */, A55A87AA22FD8272002D0A72 /* PNDeleteUserRequest.m in Sources */, 797D606722D2E41100E64C94 /* PNSignalAPICallBuilder.m in Sources */, + A5105B5D238F027D00CB693D /* PNDate.m in Sources */, 798843121C191579003E8948 /* PNChannelClientStateResult.m in Sources */, 798843231C191579003E8948 /* PNClientStateUpdateStatus.m in Sources */, 798843241C191579003E8948 /* PNPresenceWhereNowParser.m in Sources */, 79A0D88E1DC22F630039A264 /* PNAPNSAPICallBuilder.m in Sources */, A55BCD03231D222B0019DB68 /* PNRemoveMessageActionAPICallBuilder.m in Sources */, + A57A301A238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.m in Sources */, 79A0D8EE1DC230240039A264 /* PNPresenceWhereNowAPICallBuilder.m in Sources */, 798843041C191579003E8948 /* PNPresenceWhereNowResult.m in Sources */, + A57A3066238D65A200DE8C68 /* PNNotificationsPayload.m in Sources */, 79A0D98A1DC2315F0039A264 /* PNTimeAPICallBuilder.m in Sources */, 79A3E40E2215699900F2ADB9 /* PNMessageCountAPICallBuilder.m in Sources */, 7988432D1C191579003E8948 /* PNPresenceHereNowParser.m in Sources */, @@ -6870,6 +7342,7 @@ A55BCD23231D26110019DB68 /* PNMessageAction.m in Sources */, A55A880C22FD8272002D0A72 /* PNDeleteSpaceRequest.m in Sources */, A55A864E22FD80B9002D0A72 /* PNUpdateUserAPICallBuilder.m in Sources */, + A57A3096238D751400DE8C68 /* PNMPNSNotificationPayload.m in Sources */, 798843131C191579003E8948 /* PNSubscriberResults.m in Sources */, 79A0D9241DC230A00039A264 /* PNStateAuditAPICallBuilder.m in Sources */, 79A0D9721DC2313C0039A264 /* PNSubscribeChannelsOrGroupsAPIBuilder.m in Sources */, @@ -6879,6 +7352,7 @@ A55A873D22FD825A002D0A72 /* PNUserDataChangeParser.m in Sources */, 7988431C1C191579003E8948 /* PNHeartbeatParser.m in Sources */, 798843011C191579003E8948 /* PNSubscribeStatus.m in Sources */, + A57A30E7238DC87400DE8C68 /* PNAPNSNotificationTarget.m in Sources */, A55A887522FD8272002D0A72 /* PNFetchMembersRequest.m in Sources */, 798843361C191579003E8948 /* PubNub+Subscribe.m in Sources */, 798843311C191579003E8948 /* PNHistoryParser.m in Sources */, @@ -6896,6 +7370,7 @@ A55BCCAF2319243F0019DB68 /* PNAddMessageActionStatus.m in Sources */, A55A86ED22FD81E3002D0A72 /* PNFetchUsersResult.m in Sources */, 7988430A1C191579003E8948 /* PubNub+History.m in Sources */, + A57A30BF238DC6B600DE8C68 /* PNAPNSNotificationPayload.m in Sources */, 798843001C191579003E8948 /* PubNub+Publish.m in Sources */, 798843261C191579003E8948 /* PNErrorParser.m in Sources */, 798843221C191579003E8948 /* PNLeaveParser.m in Sources */, @@ -6917,6 +7392,7 @@ A55A87D422FD8272002D0A72 /* PNCreateUserRequest.m in Sources */, A55A885222FD8272002D0A72 /* PNFetchMembershipsRequest.m in Sources */, A55A87F722FD8272002D0A72 /* PNCreateSpaceRequest.m in Sources */, + A57A3044238D59B500DE8C68 /* PNRemovePushNotificationsRequest.m in Sources */, A58975DF23005BE60093BD9A /* PNMember.m in Sources */, 798843211C191579003E8948 /* PNTimeParser.m in Sources */, 79A0D8D61DC230110039A264 /* PNPresenceAPICallBuilder.m in Sources */, @@ -6935,6 +7411,7 @@ A55A86B022FD817E002D0A72 /* PNUser.m in Sources */, 79650C401E775EA200006F66 /* PNLockSupport.m in Sources */, 7988430F1C191579003E8948 /* PubNub+APNS.m in Sources */, + A57A304B238D59B500DE8C68 /* PNAuditPushNotificationsRequest.m in Sources */, 7988430C1C191579003E8948 /* PNHeartbeat.m in Sources */, A55A888322FD8272002D0A72 /* PNObjectsPaginatedRequest.m in Sources */, 798843081C191579003E8948 /* PubNub+Time.m in Sources */, @@ -6950,7 +7427,9 @@ 79E2D0F91C56434700BAA244 /* PNKeychain.m in Sources */, 797D607022D2E44000E64C94 /* PNSignalStatus.m in Sources */, 79A3E435221569DA00F2ADB9 /* PNMessageCountParser.m in Sources */, + A57A30A6238D784A00DE8C68 /* PNBaseNotificationPayload.m in Sources */, 798843291C191579003E8948 /* PNChannel.m in Sources */, + A57A3076238D6BCC00DE8C68 /* PNFCMNotificationPayload.m in Sources */, 7988430D1C191579003E8948 /* PNNetwork.m in Sources */, 79A0D94E1DC230EA0039A264 /* PNStreamModificationAPICallBuilder.m in Sources */, 79A0D89A1DC22F800039A264 /* PNAPNSAuditAPICallBuilder.m in Sources */, @@ -6960,7 +7439,9 @@ A55A865522FD80B9002D0A72 /* PNUpdateSpaceAPICallBuilder.m in Sources */, 7960B6701F68123500FFAEBB /* PNDeleteMessageAPICallBuilder.m in Sources */, A55A865C22FD80B9002D0A72 /* PNCreateSpaceAPICallBuilder.m in Sources */, + A57A3036238D59B500DE8C68 /* PNAddPushNotificationsRequest.m in Sources */, A56865C6230173030014E17C /* PNSpaceDataChangeParser.m in Sources */, + A57A302F238D59B500DE8C68 /* PNBasePushNotificationsRequest.m in Sources */, A5A7AFE1234932F30060113B /* PNAddMessageActionParser.m in Sources */, 798843351C191579003E8948 /* PNStatus.m in Sources */, 798843331C191579003E8948 /* PNString.m in Sources */, @@ -6987,12 +7468,14 @@ files = ( 79A0D87D1DC22F460039A264 /* PNAPICallBuilder.m in Sources */, A55A87EB22FD8272002D0A72 /* PNFetchSpacesRequest.m in Sources */, + A57A30BA238DC6B600DE8C68 /* PNAPNSNotificationPayload.m in Sources */, 79A8BC2A1C58F93900015BDE /* PNPushNotificationsStateModificationParser.m in Sources */, A55A884622FD8272002D0A72 /* PNManageMembershipsRequest.m in Sources */, A5A7AFDC234932F30060113B /* PNAddMessageActionParser.m in Sources */, A55A86FD22FD81E3002D0A72 /* PNCreateSpaceStatus.m in Sources */, 79A238D81D2E70BD00D080CD /* NSURLSessionConfiguration+PNConfiguration.m in Sources */, 79A8BC571C58F93900015BDE /* PNPresenceChannelGroupHereNowResult.m in Sources */, + A57A30CA238DC71800DE8C68 /* PNAPNSNotificationConfiguration.m in Sources */, 79A8BC3F1C58F93900015BDE /* PNChannelGroupModificationParser.m in Sources */, 79A8BC561C58F93900015BDE /* PNChannelGroupClientStateResult.m in Sources */, 79ABD8991F01636B007634E0 /* PNTelemetry.m in Sources */, @@ -7010,6 +7493,7 @@ 79A8BC421C58F93900015BDE /* PNChannelGroupChannelsResult.m in Sources */, 79A0D8DD1DC230180039A264 /* PNPresenceChannelHereNowAPICallBuilder.m in Sources */, 79A0D8E31DC2301D0039A264 /* PNPresenceHereNowAPICallBuilder.m in Sources */, + A57A303F238D59B500DE8C68 /* PNRemovePushNotificationsRequest.m in Sources */, 79A0D9191DC2309A0039A264 /* PNStateAPICallBuilder.m in Sources */, A58975CA23005BD80093BD9A /* PNMembership.m in Sources */, 79A0D93D1DC230DD0039A264 /* PNStreamAPICallBuilder.m in Sources */, @@ -7021,6 +7505,7 @@ A55A862D22FD80B9002D0A72 /* PNCreateUserAPICallBuilder.m in Sources */, A55A86AB22FD817E002D0A72 /* PNUser.m in Sources */, 79A8BC5B1C58F93900015BDE /* PNNetworkResponseSerializer.m in Sources */, + A57A3031238D59B500DE8C68 /* PNAddPushNotificationsRequest.m in Sources */, 79A0D9011DC230590039A264 /* PNPublishSizeAPICallBuilder.m in Sources */, A56865D1230173AA0014E17C /* PNObjectsDeleteParser.m in Sources */, A55A86CE22FD817E002D0A72 /* PNSpace.m in Sources */, @@ -7039,6 +7524,7 @@ 79A8BC2F1C58F93900015BDE /* PNChannelGroupsResult.m in Sources */, A56865B1230172950014E17C /* PNFetchSpacesParser.m in Sources */, 79E20D1D1C8AEC51001BC9CC /* PNEnvelopeInformation.m in Sources */, + A57A3091238D751400DE8C68 /* PNMPNSNotificationPayload.m in Sources */, 7925DB9D1D3FFCAC00857C0D /* PNLLogFileInformation.m in Sources */, A55A87D622FD8272002D0A72 /* PNFetchUsersRequest.m in Sources */, A55A883F22FD8272002D0A72 /* PNBaseObjectsRequest.m in Sources */, @@ -7053,6 +7539,7 @@ 79A8BC411C58F93900015BDE /* PNClientInformation.m in Sources */, A55A867322FD80B9002D0A72 /* PNDeleteSpaceAPICallBuilder.m in Sources */, A55A878222FD8272002D0A72 /* PNFetchUserRequest.m in Sources */, + A57A30A1238D784A00DE8C68 /* PNBaseNotificationPayload.m in Sources */, 79A8BC3E1C58F93900015BDE /* PNSubscriberResults.m in Sources */, A58975AA230014300093BD9A /* PNFetchMembersAPICallBuilder.m in Sources */, A55A86E822FD81E3002D0A72 /* PNFetchUsersResult.m in Sources */, @@ -7078,22 +7565,26 @@ A52DC1EE2307E10B001F20B0 /* NSDateFormatter+PNCacheable.m in Sources */, A56865E1230175EC0014E17C /* PNMembershipsParser.m in Sources */, A5A7AFC7234932F30060113B /* PNFetchMessagesActionsParser.m in Sources */, + A57A302A238D59B500DE8C68 /* PNBasePushNotificationsRequest.m in Sources */, A58975BA23005AAC0093BD9A /* PNManageMembershipsStatus.m in Sources */, A56865912300729E0014E17C /* PNFetchMembersResult.m in Sources */, A55BCCEE231D21840019DB68 /* PNAddMessageActionAPICallBuilder.m in Sources */, A55A864922FD80B9002D0A72 /* PNUpdateUserAPICallBuilder.m in Sources */, A55A877422FD8272002D0A72 /* PNRequest.m in Sources */, + A57A3061238D65A200DE8C68 /* PNNotificationsPayload.m in Sources */, 79A8BC271C58F93900015BDE /* PNConfiguration.m in Sources */, A55A870B22FD81E3002D0A72 /* PNUpdateUserStatus.m in Sources */, 79A0D9671DC231350039A264 /* PNSubscribeAPIBuilder.m in Sources */, 79A8BC611C58F93900015BDE /* PubNub+Publish.m in Sources */, 79A0D9491DC230E80039A264 /* PNStreamModificationAPICallBuilder.m in Sources */, + A57A3046238D59B500DE8C68 /* PNAuditPushNotificationsRequest.m in Sources */, A5A7B0082349330F0060113B /* PNBaseMessageActionRequest.m in Sources */, 79A8BC221C58F93900015BDE /* PNReachability.m in Sources */, A55A87C122FD8272002D0A72 /* PNUpdateUserRequest.m in Sources */, 79A8BC1E1C58F93900015BDE /* PubNub+History.m in Sources */, 79A8BC4C1C58F93900015BDE /* PNServiceData.m in Sources */, A589759A230014220093BD9A /* PNManageMembersAPICallBuilder.m in Sources */, + A57A30E2238DC87400DE8C68 /* PNAPNSNotificationTarget.m in Sources */, 79A0D9251DC230A30039A264 /* PNStateModificationAPICallBuilder.m in Sources */, 79A8BC441C58F93900015BDE /* PNClientState.m in Sources */, 79A8BC431C58F93900015BDE /* PNLeaveParser.m in Sources */, @@ -7106,10 +7597,12 @@ 79A8BC4A1C58F93900015BDE /* PNTimeResult.m in Sources */, A55A885B22FD8272002D0A72 /* PNManageMembersRequest.m in Sources */, 79A0D8E91DC230220039A264 /* PNPresenceWhereNowAPICallBuilder.m in Sources */, + A5105B58238F027D00CB693D /* PNDate.m in Sources */, 79A8BC481C58F93900015BDE /* PNTimeParser.m in Sources */, 79A8BC471C58F93900015BDE /* PNURLRequest.m in Sources */, A55BCD0E231D22400019DB68 /* PNFetchMessagesActionsAPICallBuilder.m in Sources */, A589757A230014090093BD9A /* PNManageMembershipsAPICallBuilder.m in Sources */, + A57A3071238D6BCC00DE8C68 /* PNFCMNotificationPayload.m in Sources */, 79A8BC321C58F93900015BDE /* PubNub+State.m in Sources */, 79A8BC251C58F93900015BDE /* PNDictionary.m in Sources */, A55A87F222FD8272002D0A72 /* PNCreateSpaceRequest.m in Sources */, @@ -7141,6 +7634,7 @@ A5A7B01D2349330F0060113B /* PNFetchMessageActionsRequest.m in Sources */, 79F857FA219640A200BFD0B1 /* PNClientStateGetResult.m in Sources */, 79A8BC591C58F93900015BDE /* PNStatus.m in Sources */, + A57A3015238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.m in Sources */, 79A0D91F1DC2309F0039A264 /* PNStateAuditAPICallBuilder.m in Sources */, 79A8BC521C58F93900015BDE /* PNNumber.m in Sources */, 79650C3B1E775EA000006F66 /* PNLockSupport.m in Sources */, @@ -7197,18 +7691,22 @@ A56FAEFD233161570072ADD6 /* PubNub+MessageActions.m in Sources */, 79A0D8801DC22F470039A264 /* PNAPICallBuilder.m in Sources */, A55A860D22FD80B9002D0A72 /* PNFetchUserAPICallBuilder.m in Sources */, + A57A30CD238DC71800DE8C68 /* PNAPNSNotificationConfiguration.m in Sources */, 79ACC4291C11BC4D0056523A /* PNAPNSEnabledChannelsResult.m in Sources */, A55BCD11231D22400019DB68 /* PNFetchMessagesActionsAPICallBuilder.m in Sources */, 79ACC4271C11BC4D0056523A /* PNNetworkResponseSerializer.m in Sources */, A55A87A822FD8272002D0A72 /* PNDeleteUserRequest.m in Sources */, 797D606522D2E41100E64C94 /* PNSignalAPICallBuilder.m in Sources */, + A5105B5B238F027D00CB693D /* PNDate.m in Sources */, 79ACC4071C11BC4D0056523A /* PNChannelClientStateResult.m in Sources */, 79ACC4181C11BC4D0056523A /* PNClientStateUpdateStatus.m in Sources */, 79ACC4081C11BC4D0056523A /* PNPresenceWhereNowParser.m in Sources */, 79A0D88C1DC22F620039A264 /* PNAPNSAPICallBuilder.m in Sources */, A55BCD01231D222B0019DB68 /* PNRemoveMessageActionAPICallBuilder.m in Sources */, + A57A3018238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.m in Sources */, 79A0D8EC1DC230240039A264 /* PNPresenceWhereNowAPICallBuilder.m in Sources */, 79ACC3F81C11BC4D0056523A /* PNPresenceWhereNowResult.m in Sources */, + A57A3064238D65A200DE8C68 /* PNNotificationsPayload.m in Sources */, 79A0D9891DC2315E0039A264 /* PNTimeAPICallBuilder.m in Sources */, 79A3E40C2215699900F2ADB9 /* PNMessageCountAPICallBuilder.m in Sources */, 79ACC42E1C11BC4D0056523A /* PNPresenceHereNowParser.m in Sources */, @@ -7231,6 +7729,7 @@ A55BCD21231D26110019DB68 /* PNMessageAction.m in Sources */, A55A880A22FD8272002D0A72 /* PNDeleteSpaceRequest.m in Sources */, A55A864C22FD80B9002D0A72 /* PNUpdateUserAPICallBuilder.m in Sources */, + A57A3094238D751400DE8C68 /* PNMPNSNotificationPayload.m in Sources */, 79ACC4031C11BC4D0056523A /* PubNub+ChannelGroup.m in Sources */, 79A0D9221DC230A00039A264 /* PNStateAuditAPICallBuilder.m in Sources */, 79A0D9701DC2313B0039A264 /* PNSubscribeChannelsOrGroupsAPIBuilder.m in Sources */, @@ -7240,6 +7739,7 @@ A55A873B22FD825A002D0A72 /* PNUserDataChangeParser.m in Sources */, 79ACC4111C11BC4D0056523A /* PNSubscribeParser.m in Sources */, 79ACC3F21C11BC4D0056523A /* PNSubscribeStatus.m in Sources */, + A57A30E5238DC87400DE8C68 /* PNAPNSNotificationTarget.m in Sources */, A55A887322FD8272002D0A72 /* PNFetchMembersRequest.m in Sources */, 79ACC4281C11BC4D0056523A /* PubNub+Subscribe.m in Sources */, 79ACC41E1C11BC4D0056523A /* PubNub+Presence.m in Sources */, @@ -7257,6 +7757,7 @@ A55BCCAD2319243F0019DB68 /* PNAddMessageActionStatus.m in Sources */, A55A86EB22FD81E3002D0A72 /* PNFetchUsersResult.m in Sources */, 79ACC3EE1C11BC4D0056523A /* PNReachability.m in Sources */, + A57A30BD238DC6B600DE8C68 /* PNAPNSNotificationPayload.m in Sources */, 79ACC3EA1C11BC4D0056523A /* PubNub+History.m in Sources */, 79ACC4171C11BC4D0056523A /* PNServiceData.m in Sources */, 79ACC4101C11BC4D0056523A /* PNClientState.m in Sources */, @@ -7278,6 +7779,7 @@ A55A87D222FD8272002D0A72 /* PNCreateUserRequest.m in Sources */, A55A885022FD8272002D0A72 /* PNFetchMembershipsRequest.m in Sources */, A55A87F522FD8272002D0A72 /* PNCreateSpaceRequest.m in Sources */, + A57A3042238D59B500DE8C68 /* PNRemovePushNotificationsRequest.m in Sources */, A58975DD23005BE60093BD9A /* PNMember.m in Sources */, 79ACC4141C11BC4D0056523A /* PNTimeParser.m in Sources */, 79A0D8D41DC230100039A264 /* PNPresenceAPICallBuilder.m in Sources */, @@ -7296,6 +7798,7 @@ A55A86AE22FD817E002D0A72 /* PNUser.m in Sources */, 79650C3E1E775EA100006F66 /* PNLockSupport.m in Sources */, 79ACC3FC1C11BC4D0056523A /* PubNub+Time.m in Sources */, + A57A3049238D59B500DE8C68 /* PNAuditPushNotificationsRequest.m in Sources */, 79ACC3F91C11BC4D0056523A /* PubNub+APNS.m in Sources */, A55A888122FD8272002D0A72 /* PNObjectsPaginatedRequest.m in Sources */, 79ACC3ED1C11BC4D0056523A /* PubNub+Core.m in Sources */, @@ -7311,7 +7814,9 @@ 79E2D0F71C56434700BAA244 /* PNKeychain.m in Sources */, 797D606E22D2E44000E64C94 /* PNSignalStatus.m in Sources */, 79A3E433221569DA00F2ADB9 /* PNMessageCountParser.m in Sources */, + A57A30A4238D784A00DE8C68 /* PNBaseNotificationPayload.m in Sources */, 79ACC41A1C11BC4D0056523A /* PNNetwork.m in Sources */, + A57A3074238D6BCC00DE8C68 /* PNFCMNotificationPayload.m in Sources */, 79ACC4091C11BC4D0056523A /* PNChannel.m in Sources */, 79A0D94C1DC230EA0039A264 /* PNStreamModificationAPICallBuilder.m in Sources */, 79A0D8981DC22F7F0039A264 /* PNAPNSAuditAPICallBuilder.m in Sources */, @@ -7321,7 +7826,9 @@ A55A865322FD80B9002D0A72 /* PNUpdateSpaceAPICallBuilder.m in Sources */, 7960B66E1F68123400FFAEBB /* PNDeleteMessageAPICallBuilder.m in Sources */, A55A865A22FD80B9002D0A72 /* PNCreateSpaceAPICallBuilder.m in Sources */, + A57A3034238D59B500DE8C68 /* PNAddPushNotificationsRequest.m in Sources */, A56865C4230173030014E17C /* PNSpaceDataChangeParser.m in Sources */, + A57A302D238D59B500DE8C68 /* PNBasePushNotificationsRequest.m in Sources */, A5A7AFDF234932F30060113B /* PNAddMessageActionParser.m in Sources */, 79ACC4251C11BC4D0056523A /* PNStatus.m in Sources */, 79ACC41D1C11BC4D0056523A /* PNNumber.m in Sources */, @@ -7348,12 +7855,14 @@ files = ( 79A0D87F1DC22F470039A264 /* PNAPICallBuilder.m in Sources */, A55A87ED22FD8272002D0A72 /* PNFetchSpacesRequest.m in Sources */, + A57A30BC238DC6B600DE8C68 /* PNAPNSNotificationPayload.m in Sources */, 79CBB17F1BD03DE4001FC34D /* PNPushNotificationsStateModificationParser.m in Sources */, A55A884822FD8272002D0A72 /* PNManageMembershipsRequest.m in Sources */, A5A7AFDE234932F30060113B /* PNAddMessageActionParser.m in Sources */, A55A86FF22FD81E3002D0A72 /* PNCreateSpaceStatus.m in Sources */, 79A238DA1D2E70BD00D080CD /* NSURLSessionConfiguration+PNConfiguration.m in Sources */, 79CBB1301BD03DE4001FC34D /* PNPresenceChannelGroupHereNowResult.m in Sources */, + A57A30CC238DC71800DE8C68 /* PNAPNSNotificationConfiguration.m in Sources */, 79CBB16B1BD03DE4001FC34D /* PNChannelGroupModificationParser.m in Sources */, 79CBB1251BD03DE4001FC34D /* PNChannelGroupClientStateResult.m in Sources */, 79ABD89B1F01636B007634E0 /* PNTelemetry.m in Sources */, @@ -7371,6 +7880,7 @@ 79CBB1691BD03DE4001FC34D /* PNChannelGroupAuditionParser.m in Sources */, 79A0D8DF1DC230180039A264 /* PNPresenceChannelHereNowAPICallBuilder.m in Sources */, 79A0D8E51DC2301E0039A264 /* PNPresenceHereNowAPICallBuilder.m in Sources */, + A57A3041238D59B500DE8C68 /* PNRemovePushNotificationsRequest.m in Sources */, 79A0D91B1DC2309B0039A264 /* PNStateAPICallBuilder.m in Sources */, A58975CC23005BD80093BD9A /* PNMembership.m in Sources */, 79A0D93F1DC230DE0039A264 /* PNStreamAPICallBuilder.m in Sources */, @@ -7382,6 +7892,7 @@ A55A862F22FD80B9002D0A72 /* PNCreateUserAPICallBuilder.m in Sources */, A55A86AD22FD817E002D0A72 /* PNUser.m in Sources */, 79CBB11F1BD03DE4001FC34D /* PNAPNSEnabledChannelsResult.m in Sources */, + A57A3033238D59B500DE8C68 /* PNAddPushNotificationsRequest.m in Sources */, 79A0D9031DC2305A0039A264 /* PNPublishSizeAPICallBuilder.m in Sources */, A56865D3230173AA0014E17C /* PNObjectsDeleteParser.m in Sources */, A55A86D022FD817E002D0A72 /* PNSpace.m in Sources */, @@ -7400,6 +7911,7 @@ 79CBB1271BD03DE4001FC34D /* PNChannelGroupsResult.m in Sources */, A56865B3230172950014E17C /* PNFetchSpacesParser.m in Sources */, 79E20D1F1C8AEC52001BC9CC /* PNEnvelopeInformation.m in Sources */, + A57A3093238D751400DE8C68 /* PNMPNSNotificationPayload.m in Sources */, 7925DB9F1D3FFCAC00857C0D /* PNLLogFileInformation.m in Sources */, A55A87D822FD8272002D0A72 /* PNFetchUsersRequest.m in Sources */, A55A884122FD8272002D0A72 /* PNBaseObjectsRequest.m in Sources */, @@ -7414,6 +7926,7 @@ 79CBB1181BD03DE4001FC34D /* PNClientInformation.m in Sources */, A55A867522FD80B9002D0A72 /* PNDeleteSpaceAPICallBuilder.m in Sources */, A55A878422FD8272002D0A72 /* PNFetchUserRequest.m in Sources */, + A57A30A3238D784A00DE8C68 /* PNBaseNotificationPayload.m in Sources */, 79CBB18D1BD03DE4001FC34D /* PNRequestParameters.m in Sources */, A58975AC230014300093BD9A /* PNFetchMembersAPICallBuilder.m in Sources */, A55A86EA22FD81E3002D0A72 /* PNFetchUsersResult.m in Sources */, @@ -7439,22 +7952,26 @@ A52DC1F02307E10B001F20B0 /* NSDateFormatter+PNCacheable.m in Sources */, A56865E3230175EC0014E17C /* PNMembershipsParser.m in Sources */, A5A7AFC9234932F30060113B /* PNFetchMessagesActionsParser.m in Sources */, + A57A302C238D59B500DE8C68 /* PNBasePushNotificationsRequest.m in Sources */, A58975BC23005AAC0093BD9A /* PNManageMembershipsStatus.m in Sources */, A56865932300729E0014E17C /* PNFetchMembersResult.m in Sources */, A55BCCF0231D21840019DB68 /* PNAddMessageActionAPICallBuilder.m in Sources */, A55A864B22FD80B9002D0A72 /* PNUpdateUserAPICallBuilder.m in Sources */, A55A877622FD8272002D0A72 /* PNRequest.m in Sources */, + A57A3063238D65A200DE8C68 /* PNNotificationsPayload.m in Sources */, 79CBB11B1BD03DE4001FC34D /* PNConfiguration.m in Sources */, A55A870D22FD81E3002D0A72 /* PNUpdateUserStatus.m in Sources */, 79A0D9691DC231360039A264 /* PNSubscribeAPIBuilder.m in Sources */, 79CBB1051BD03DE4001FC34D /* PubNub+Publish.m in Sources */, 79A0D94B1DC230E90039A264 /* PNStreamModificationAPICallBuilder.m in Sources */, + A57A3048238D59B500DE8C68 /* PNAuditPushNotificationsRequest.m in Sources */, A5A7B00A2349330F0060113B /* PNBaseMessageActionRequest.m in Sources */, 79CBB1001BD03DE4001FC34D /* PubNub+History.m in Sources */, A55A87C322FD8272002D0A72 /* PNUpdateUserRequest.m in Sources */, 79CBB18B1BD03DE4001FC34D /* PNReachability.m in Sources */, 79CBB1751BD03DE4001FC34D /* PNLeaveParser.m in Sources */, A589759C230014220093BD9A /* PNManageMembersAPICallBuilder.m in Sources */, + A57A30E4238DC87400DE8C68 /* PNAPNSNotificationTarget.m in Sources */, 79A0D9271DC230A30039A264 /* PNStateModificationAPICallBuilder.m in Sources */, 79CBB16F1BD03DE4001FC34D /* PNErrorParser.m in Sources */, 79CBB13E1BD03DE4001FC34D /* PNServiceData.m in Sources */, @@ -7467,10 +7984,12 @@ 79CBB1471BD03DE4001FC34D /* PNTimeResult.m in Sources */, A55A885D22FD8272002D0A72 /* PNManageMembersRequest.m in Sources */, 79A0D8EB1DC230230039A264 /* PNPresenceWhereNowAPICallBuilder.m in Sources */, + A5105B5A238F027D00CB693D /* PNDate.m in Sources */, 79CBB1141BD03DE4001FC34D /* PNSubscriber.m in Sources */, 79CBB1071BD03DE4001FC34D /* PubNub+State.m in Sources */, A55BCD10231D22400019DB68 /* PNFetchMessagesActionsAPICallBuilder.m in Sources */, A589757C230014090093BD9A /* PNManageMembershipsAPICallBuilder.m in Sources */, + A57A3073238D6BCC00DE8C68 /* PNFCMNotificationPayload.m in Sources */, 79CBB18F1BD03DE4001FC34D /* PNURLBuilder.m in Sources */, 79CBB15A1BD03DE4001FC34D /* PNURLRequest.m in Sources */, A55A87F422FD8272002D0A72 /* PNCreateSpaceRequest.m in Sources */, @@ -7502,6 +8021,7 @@ A5A7B01F2349330F0060113B /* PNFetchMessageActionsRequest.m in Sources */, 79F857FC219640A300BFD0B1 /* PNClientStateGetResult.m in Sources */, 79CBB1581BD03DE4001FC34D /* PNString.m in Sources */, + A57A3017238D59B500DE8C68 /* PNRemoveAllPushNotificationsRequest.m in Sources */, 79A0D9211DC2309F0039A264 /* PNStateAuditAPICallBuilder.m in Sources */, 79CBB1411BD03DE4001FC34D /* PNStatus.m in Sources */, 79650C3D1E775EA100006F66 /* PNLockSupport.m in Sources */, @@ -7587,25 +8107,22 @@ CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; CLANG_WARN_COMMA = YES; CLANG_WARN_DOCUMENTATION_COMMENTS = YES; - CODE_SIGN_IDENTITY = "Apple Development"; + CODE_SIGN_IDENTITY = ""; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; - GCC_C_LANGUAGE_STANDARD = gnu11; INFOPLIST_FILE = "PubNub/PubNub-iOS-Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; IPHONEOS_DEPLOYMENT_TARGET = 9.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; MACOSX_DEPLOYMENT_TARGET = 10.11; - MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; OTHER_CFLAGS = ""; OTHER_LDFLAGS = ""; PRODUCT_BUNDLE_IDENTIFIER = "com.pubnub.pubnub-objc"; PRODUCT_NAME = PubNub; SKIP_INSTALL = YES; - SUPPORTED_PLATFORMS = "iphonesimulator iphoneos"; - SUPPORTS_MACCATALYST = YES; + SUPPORTED_PLATFORMS = "iphonesimulator iphoneos macosx"; SWIFT_VERSION = 3.0; TVOS_DEPLOYMENT_TARGET = 10.0; WATCHOS_DEPLOYMENT_TARGET = 4.0; @@ -7617,20 +8134,13 @@ buildSettings = { APPLICATION_EXTENSION_API_ONLY = YES; BITCODE_GENERATION_MODE = bitcode; - BUILD_LIBRARY_FOR_DISTRIBUTION = YES; - CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; CLANG_WARN_COMMA = YES; - CLANG_WARN_DOCUMENTATION_COMMENTS = YES; - CODE_SIGN_IDENTITY = "Apple Development"; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; - GCC_C_LANGUAGE_STANDARD = gnu11; INFOPLIST_FILE = "PubNub/PubNub-iOS-Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; IPHONEOS_DEPLOYMENT_TARGET = 9.0; @@ -7641,8 +8151,7 @@ PRODUCT_BUNDLE_IDENTIFIER = "com.pubnub.pubnub-objc"; PRODUCT_NAME = PubNub; SKIP_INSTALL = YES; - SUPPORTED_PLATFORMS = "iphonesimulator iphoneos"; - SUPPORTS_MACCATALYST = YES; + SUPPORTED_PLATFORMS = "iphonesimulator iphoneos macosx"; SWIFT_VERSION = 3.0; TVOS_DEPLOYMENT_TARGET = 10.0; WATCHOS_DEPLOYMENT_TARGET = 4.0; @@ -7653,22 +8162,17 @@ isa = XCBuildConfiguration; buildSettings = { APPLICATION_EXTENSION_API_ONLY = YES; - BUILD_LIBRARY_FOR_DISTRIBUTION = YES; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; - CODE_SIGN_IDENTITY = "Apple Development"; + BITCODE_GENERATION_MODE = bitcode; + "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; - GCC_C_LANGUAGE_STANDARD = gnu11; INFOPLIST_FILE = "PubNub/PubNub-watchOS-Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; IPHONEOS_DEPLOYMENT_TARGET = 9.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; MACOSX_DEPLOYMENT_TARGET = 10.11; - MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; OTHER_CFLAGS = ""; PRODUCT_BUNDLE_IDENTIFIER = "com.pubnub.pubnub-objc"; PRODUCT_NAME = PubNub; @@ -7685,16 +8189,12 @@ isa = XCBuildConfiguration; buildSettings = { APPLICATION_EXTENSION_API_ONLY = YES; - BUILD_LIBRARY_FOR_DISTRIBUTION = YES; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; - CODE_SIGN_IDENTITY = "Apple Development"; + BITCODE_GENERATION_MODE = bitcode; + "CODE_SIGN_IDENTITY[sdk=watchos*]" = ""; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; - GCC_C_LANGUAGE_STANDARD = gnu11; INFOPLIST_FILE = "PubNub/PubNub-watchOS-Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; IPHONEOS_DEPLOYMENT_TARGET = 9.0; @@ -7717,17 +8217,9 @@ buildSettings = { APPLICATION_EXTENSION_API_ONLY = YES; BITCODE_GENERATION_MODE = bitcode; - BUILD_LIBRARY_FOR_DISTRIBUTION = YES; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_ANALYZER_SECURITY_FLOATLOOPCOUNTER = NO; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; - CLANG_ENABLE_MODULE_DEBUGGING = YES; - CLANG_WARN_DOCUMENTATION_COMMENTS = YES; DEFINES_MODULE = YES; EXECUTABLE_EXTENSION = a; EXECUTABLE_PREFIX = ""; - GCC_C_LANGUAGE_STANDARD = gnu11; GCC_INLINES_ARE_PRIVATE_EXTERN = YES; GCC_PREPROCESSOR_DEFINITIONS = ( "DEBUG=1", @@ -7737,13 +8229,13 @@ GENERATE_MASTER_OBJECT_FILE = YES; IPHONEOS_DEPLOYMENT_TARGET = 9.0; MACOSX_DEPLOYMENT_TARGET = 10.11; - MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; OTHER_CFLAGS = ""; OTHER_LDFLAGS = ""; PRODUCT_NAME = PubNub; PUBLIC_HEADERS_FOLDER_PATH = Headers; + SEPARATE_STRIP = NO; SKIP_INSTALL = YES; - SUPPORTED_PLATFORMS = "iphonesimulator iphoneos"; + SUPPORTED_PLATFORMS = "iphonesimulator iphoneos macosx"; TVOS_DEPLOYMENT_TARGET = 10.0; WATCHOS_DEPLOYMENT_TARGET = 4.0; }; @@ -7754,17 +8246,9 @@ buildSettings = { APPLICATION_EXTENSION_API_ONLY = YES; BITCODE_GENERATION_MODE = bitcode; - BUILD_LIBRARY_FOR_DISTRIBUTION = YES; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_ANALYZER_SECURITY_FLOATLOOPCOUNTER = NO; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; - CLANG_ENABLE_MODULE_DEBUGGING = YES; - CLANG_WARN_DOCUMENTATION_COMMENTS = YES; DEFINES_MODULE = YES; EXECUTABLE_EXTENSION = a; EXECUTABLE_PREFIX = ""; - GCC_C_LANGUAGE_STANDARD = gnu11; GCC_INLINES_ARE_PRIVATE_EXTERN = YES; GCC_PREPROCESSOR_DEFINITIONS = "PN_STATIC_LIBRARY=1"; GENERATE_MASTER_OBJECT_FILE = YES; @@ -7774,8 +8258,9 @@ OTHER_LDFLAGS = ""; PRODUCT_NAME = PubNub; PUBLIC_HEADERS_FOLDER_PATH = Headers; + SEPARATE_STRIP = NO; SKIP_INSTALL = YES; - SUPPORTED_PLATFORMS = "iphonesimulator iphoneos"; + SUPPORTED_PLATFORMS = "iphonesimulator iphoneos macosx"; TVOS_DEPLOYMENT_TARGET = 10.0; WATCHOS_DEPLOYMENT_TARGET = 4.0; }; @@ -7786,18 +8271,13 @@ buildSettings = { APPLICATION_EXTENSION_API_ONLY = YES; BITCODE_GENERATION_MODE = bitcode; - BUILD_LIBRARY_FOR_DISTRIBUTION = YES; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; - GCC_C_LANGUAGE_STANDARD = gnu11; - GCC_INLINES_ARE_PRIVATE_EXTERN = YES; GENERATE_MASTER_OBJECT_FILE = YES; IPHONEOS_DEPLOYMENT_TARGET = 9.0; MACOSX_DEPLOYMENT_TARGET = 10.11; - MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; OTHER_CFLAGS = ""; PRODUCT_NAME = "Universal Static Framework"; SDKROOT = iphoneos; - SUPPORTED_PLATFORMS = "iphonesimulator iphoneos"; + SUPPORTED_PLATFORMS = "iphonesimulator iphoneos macosx"; TVOS_DEPLOYMENT_TARGET = 10.0; WATCHOS_DEPLOYMENT_TARGET = 4.0; }; @@ -7808,17 +8288,13 @@ buildSettings = { APPLICATION_EXTENSION_API_ONLY = YES; BITCODE_GENERATION_MODE = bitcode; - BUILD_LIBRARY_FOR_DISTRIBUTION = YES; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; - GCC_C_LANGUAGE_STANDARD = gnu11; - GCC_INLINES_ARE_PRIVATE_EXTERN = YES; GENERATE_MASTER_OBJECT_FILE = YES; IPHONEOS_DEPLOYMENT_TARGET = 9.0; MACOSX_DEPLOYMENT_TARGET = 10.11; OTHER_CFLAGS = ""; PRODUCT_NAME = "Universal Static Framework"; SDKROOT = iphoneos; - SUPPORTED_PLATFORMS = "iphonesimulator iphoneos"; + SUPPORTED_PLATFORMS = "iphonesimulator iphoneos macosx"; TVOS_DEPLOYMENT_TARGET = 10.0; WATCHOS_DEPLOYMENT_TARGET = 4.0; }; @@ -7829,16 +8305,9 @@ buildSettings = { APPLICATION_EXTENSION_API_ONLY = YES; BITCODE_GENERATION_MODE = bitcode; - BUILD_LIBRARY_FOR_DISTRIBUTION = YES; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; - CLANG_ENABLE_MODULE_DEBUGGING = YES; - CLANG_WARN_DOCUMENTATION_COMMENTS = YES; DEFINES_MODULE = YES; EXECUTABLE_EXTENSION = a; EXECUTABLE_PREFIX = ""; - GCC_C_LANGUAGE_STANDARD = gnu11; GCC_INLINES_ARE_PRIVATE_EXTERN = YES; GCC_PREPROCESSOR_DEFINITIONS = ( "DEBUG=1", @@ -7849,11 +8318,11 @@ GENERATE_MASTER_OBJECT_FILE = YES; IPHONEOS_DEPLOYMENT_TARGET = 9.0; MACOSX_DEPLOYMENT_TARGET = 10.11; - MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; OTHER_CFLAGS = ""; OTHER_LDFLAGS = ""; PRODUCT_NAME = PubNub; PUBLIC_HEADERS_FOLDER_PATH = Headers; + SEPARATE_STRIP = YES; SKIP_INSTALL = YES; TVOS_DEPLOYMENT_TARGET = 10.0; WATCHOS_DEPLOYMENT_TARGET = 4.0; @@ -7865,16 +8334,9 @@ buildSettings = { APPLICATION_EXTENSION_API_ONLY = YES; BITCODE_GENERATION_MODE = bitcode; - BUILD_LIBRARY_FOR_DISTRIBUTION = YES; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; - CLANG_ENABLE_MODULE_DEBUGGING = YES; - CLANG_WARN_DOCUMENTATION_COMMENTS = YES; DEFINES_MODULE = YES; EXECUTABLE_EXTENSION = a; EXECUTABLE_PREFIX = ""; - GCC_C_LANGUAGE_STANDARD = gnu11; GCC_INLINES_ARE_PRIVATE_EXTERN = YES; GCC_PREPROCESSOR_DEFINITIONS = ( "PN_STATIC_LIBRARY=1", @@ -7887,6 +8349,7 @@ OTHER_LDFLAGS = ""; PRODUCT_NAME = PubNub; PUBLIC_HEADERS_FOLDER_PATH = Headers; + SEPARATE_STRIP = YES; SKIP_INSTALL = YES; TVOS_DEPLOYMENT_TARGET = 10.0; WATCHOS_DEPLOYMENT_TARGET = 4.0; @@ -7897,24 +8360,17 @@ isa = XCBuildConfiguration; buildSettings = { APPLICATION_EXTENSION_API_ONLY = YES; - BUILD_LIBRARY_FOR_DISTRIBUTION = YES; - CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; - CLANG_WARN_DOCUMENTATION_COMMENTS = YES; - CODE_SIGN_IDENTITY = "Apple Development"; + BITCODE_GENERATION_MODE = bitcode; + "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; - GCC_C_LANGUAGE_STANDARD = gnu11; INFOPLIST_FILE = "PubNub/PubNub-tvOS-Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; IPHONEOS_DEPLOYMENT_TARGET = 9.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; MACOSX_DEPLOYMENT_TARGET = 10.11; - MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; OTHER_CFLAGS = ""; OTHER_LDFLAGS = ""; PRODUCT_BUNDLE_IDENTIFIER = "com.pubnub.pubnub-objc"; @@ -7932,18 +8388,12 @@ isa = XCBuildConfiguration; buildSettings = { APPLICATION_EXTENSION_API_ONLY = YES; - BUILD_LIBRARY_FOR_DISTRIBUTION = YES; - CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; - CLANG_WARN_DOCUMENTATION_COMMENTS = YES; - CODE_SIGN_IDENTITY = "Apple Development"; + BITCODE_GENERATION_MODE = bitcode; + "CODE_SIGN_IDENTITY[sdk=appletvos*]" = ""; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; - GCC_C_LANGUAGE_STANDARD = gnu11; INFOPLIST_FILE = "PubNub/PubNub-tvOS-Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; IPHONEOS_DEPLOYMENT_TARGET = 9.0; @@ -7966,23 +8416,14 @@ isa = XCBuildConfiguration; buildSettings = { APPLICATION_EXTENSION_API_ONLY = YES; - BUILD_LIBRARY_FOR_DISTRIBUTION = YES; - CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; - CLANG_WARN_DOCUMENTATION_COMMENTS = YES; - CODE_SIGN_IDENTITY = "Apple Development"; - GCC_C_LANGUAGE_STANDARD = gnu11; - GCC_INLINES_ARE_PRIVATE_EXTERN = YES; + BITCODE_GENERATION_MODE = bitcode; + CODE_SIGN_IDENTITY = ""; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; MACOSX_DEPLOYMENT_TARGET = 10.11; - MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; OTHER_CFLAGS = ""; PRODUCT_NAME = "Universal Framework"; SDKROOT = appletvos; - STRIP_STYLE = debugging; SUPPORTED_PLATFORMS = "appletvsimulator appletvos"; - TARGETED_DEVICE_FAMILY = 3; TVOS_DEPLOYMENT_TARGET = 10.0; WATCHOS_DEPLOYMENT_TARGET = 4.0; }; @@ -7992,22 +8433,14 @@ isa = XCBuildConfiguration; buildSettings = { APPLICATION_EXTENSION_API_ONLY = YES; - BUILD_LIBRARY_FOR_DISTRIBUTION = YES; - CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; - CLANG_WARN_DOCUMENTATION_COMMENTS = YES; - CODE_SIGN_IDENTITY = "Apple Development"; - GCC_C_LANGUAGE_STANDARD = gnu11; - GCC_INLINES_ARE_PRIVATE_EXTERN = YES; + BITCODE_GENERATION_MODE = bitcode; + CODE_SIGN_IDENTITY = ""; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; MACOSX_DEPLOYMENT_TARGET = 10.11; OTHER_CFLAGS = ""; PRODUCT_NAME = "Universal Framework"; SDKROOT = appletvos; - STRIP_STYLE = debugging; SUPPORTED_PLATFORMS = "appletvsimulator appletvos"; - TARGETED_DEVICE_FAMILY = 3; TVOS_DEPLOYMENT_TARGET = 10.0; WATCHOS_DEPLOYMENT_TARGET = 4.0; }; @@ -8018,20 +8451,12 @@ buildSettings = { APPLICATION_EXTENSION_API_ONLY = YES; BITCODE_GENERATION_MODE = bitcode; - BUILD_LIBRARY_FOR_DISTRIBUTION = YES; - CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; - CLANG_WARN_DOCUMENTATION_COMMENTS = YES; - CLANG_WARN_SUSPICIOUS_IMPLICIT_CONVERSION = NO; - CODE_SIGN_IDENTITY = "Apple Development"; - DEBUG_INFORMATION_FORMAT = dwarf; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; - GCC_C_LANGUAGE_STANDARD = gnu11; GCC_PREPROCESSOR_DEFINITIONS = ( "DEBUG=1", "FABRIC_SUPPORT=1", @@ -8042,13 +8467,12 @@ IPHONEOS_DEPLOYMENT_TARGET = 9.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; MACOSX_DEPLOYMENT_TARGET = 10.11; - MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; OTHER_CFLAGS = ""; PRODUCT_BUNDLE_IDENTIFIER = "com.pubnub.pubnub-objc"; PRODUCT_NAME = PubNub; + SEPARATE_STRIP = YES; SKIP_INSTALL = YES; - SUPPORTED_PLATFORMS = "iphonesimulator iphoneos"; - SUPPORTS_MACCATALYST = NO; + SUPPORTED_PLATFORMS = "iphonesimulator iphoneos macosx"; TVOS_DEPLOYMENT_TARGET = 10.0; WATCHOS_DEPLOYMENT_TARGET = 4.0; }; @@ -8059,21 +8483,13 @@ buildSettings = { APPLICATION_EXTENSION_API_ONLY = YES; BITCODE_GENERATION_MODE = bitcode; - BUILD_LIBRARY_FOR_DISTRIBUTION = YES; - CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; - CLANG_WARN_DOCUMENTATION_COMMENTS = YES; - CLANG_WARN_SUSPICIOUS_IMPLICIT_CONVERSION = NO; - CODE_SIGN_IDENTITY = "Apple Development"; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = ""; COPY_PHASE_STRIP = YES; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; - GCC_C_LANGUAGE_STANDARD = gnu11; GCC_PREPROCESSOR_DEFINITIONS = "FABRIC_SUPPORT=1"; INFOPLIST_FILE = "PubNub/PubNub-Fabric-Info.plist"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; @@ -8083,9 +8499,9 @@ OTHER_CFLAGS = ""; PRODUCT_BUNDLE_IDENTIFIER = "com.pubnub.pubnub-objc"; PRODUCT_NAME = PubNub; + SEPARATE_STRIP = YES; SKIP_INSTALL = YES; - SUPPORTED_PLATFORMS = "iphonesimulator iphoneos"; - SUPPORTS_MACCATALYST = NO; + SUPPORTED_PLATFORMS = "iphonesimulator iphoneos macosx"; TVOS_DEPLOYMENT_TARGET = 10.0; WATCHOS_DEPLOYMENT_TARGET = 4.0; }; @@ -8096,13 +8512,6 @@ buildSettings = { APPLICATION_EXTENSION_API_ONLY = YES; BITCODE_GENERATION_MODE = bitcode; - BUILD_LIBRARY_FOR_DISTRIBUTION = YES; - CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; - GCC_C_LANGUAGE_STANDARD = gnu11; - GCC_INLINES_ARE_PRIVATE_EXTERN = YES; GCC_PREPROCESSOR_DEFINITIONS = ( "DEBUG=1", "FABRIC_SUPPORT=1", @@ -8110,11 +8519,10 @@ ); IPHONEOS_DEPLOYMENT_TARGET = 9.0; MACOSX_DEPLOYMENT_TARGET = 10.11; - MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; OTHER_CFLAGS = ""; PRODUCT_NAME = "Universal Framework"; - STRIP_STYLE = debugging; - SUPPORTED_PLATFORMS = "iphonesimulator iphoneos"; + SEPARATE_STRIP = YES; + SUPPORTED_PLATFORMS = "iphonesimulator iphoneos macosx"; TVOS_DEPLOYMENT_TARGET = 10.0; WATCHOS_DEPLOYMENT_TARGET = 4.0; }; @@ -8125,20 +8533,13 @@ buildSettings = { APPLICATION_EXTENSION_API_ONLY = YES; BITCODE_GENERATION_MODE = bitcode; - BUILD_LIBRARY_FOR_DISTRIBUTION = YES; - CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; - GCC_C_LANGUAGE_STANDARD = gnu11; - GCC_INLINES_ARE_PRIVATE_EXTERN = YES; GCC_PREPROCESSOR_DEFINITIONS = "FABRIC_SUPPORT=1"; IPHONEOS_DEPLOYMENT_TARGET = 9.0; MACOSX_DEPLOYMENT_TARGET = 10.11; OTHER_CFLAGS = ""; PRODUCT_NAME = "Universal Framework"; - STRIP_STYLE = debugging; - SUPPORTED_PLATFORMS = "iphonesimulator iphoneos"; + SEPARATE_STRIP = YES; + SUPPORTED_PLATFORMS = "iphonesimulator iphoneos macosx"; TVOS_DEPLOYMENT_TARGET = 10.0; WATCHOS_DEPLOYMENT_TARGET = 4.0; }; @@ -8148,7 +8549,6 @@ isa = XCBuildConfiguration; buildSettings = { ALWAYS_SEARCH_USER_PATHS = NO; - BITCODE_GENERATION_MODE = bitcode; CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES; CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; CLANG_CXX_LIBRARY = "libc++"; @@ -8174,10 +8574,10 @@ CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; CLANG_WARN_UNREACHABLE_CODE = YES; CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; COPY_PHASE_STRIP = NO; CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = dwarf; - DEFINES_MODULE = YES; ENABLE_STRICT_OBJC_MSGSEND = YES; ENABLE_TESTABILITY = YES; GCC_C_LANGUAGE_STANDARD = gnu99; @@ -8195,8 +8595,7 @@ GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; IPHONEOS_DEPLOYMENT_TARGET = 9.0; - MACOSX_DEPLOYMENT_TARGET = 10.11; - MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; + MTL_ENABLE_DEBUG_INFO = YES; ONLY_ACTIVE_ARCH = YES; SDKROOT = iphoneos; TARGETED_DEVICE_FAMILY = "1,2"; @@ -8209,7 +8608,6 @@ isa = XCBuildConfiguration; buildSettings = { ALWAYS_SEARCH_USER_PATHS = NO; - BITCODE_GENERATION_MODE = bitcode; CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES; CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; CLANG_CXX_LIBRARY = "libc++"; @@ -8235,10 +8633,10 @@ CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; CLANG_WARN_UNREACHABLE_CODE = YES; CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; COPY_PHASE_STRIP = NO; CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; - DEFINES_MODULE = YES; ENABLE_NS_ASSERTIONS = NO; ENABLE_STRICT_OBJC_MSGSEND = YES; GCC_C_LANGUAGE_STANDARD = gnu99; @@ -8250,7 +8648,6 @@ GCC_WARN_UNUSED_FUNCTION = YES; GCC_WARN_UNUSED_VARIABLE = YES; IPHONEOS_DEPLOYMENT_TARGET = 9.0; - MACOSX_DEPLOYMENT_TARGET = 10.11; MTL_ENABLE_DEBUG_INFO = NO; SDKROOT = iphoneos; TARGETED_DEVICE_FAMILY = "1,2"; @@ -8264,25 +8661,17 @@ isa = XCBuildConfiguration; buildSettings = { APPLICATION_EXTENSION_API_ONLY = YES; - BUILD_LIBRARY_FOR_DISTRIBUTION = YES; - CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; - CLANG_WARN_DOCUMENTATION_COMMENTS = YES; - CODE_SIGN_IDENTITY = "Apple Development"; + BITCODE_GENERATION_MODE = bitcode; COMBINE_HIDPI_IMAGES = YES; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; - GCC_C_LANGUAGE_STANDARD = gnu11; INFOPLIST_FILE = PubNub/Info.plist; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; IPHONEOS_DEPLOYMENT_TARGET = 9.0; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; MACOSX_DEPLOYMENT_TARGET = 10.11; - MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; OTHER_CFLAGS = ""; OTHER_LDFLAGS = ( "$(inherited)", @@ -8303,19 +8692,12 @@ isa = XCBuildConfiguration; buildSettings = { APPLICATION_EXTENSION_API_ONLY = YES; - BUILD_LIBRARY_FOR_DISTRIBUTION = YES; - CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; - CLANG_WARN_DOCUMENTATION_COMMENTS = YES; - CODE_SIGN_IDENTITY = "Apple Development"; + BITCODE_GENERATION_MODE = bitcode; COMBINE_HIDPI_IMAGES = YES; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; - GCC_C_LANGUAGE_STANDARD = gnu11; INFOPLIST_FILE = PubNub/Info.plist; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; IPHONEOS_DEPLOYMENT_TARGET = 9.0; @@ -8342,21 +8724,11 @@ buildSettings = { APPLICATION_EXTENSION_API_ONLY = YES; BITCODE_GENERATION_MODE = bitcode; - BUILD_LIBRARY_FOR_DISTRIBUTION = YES; - CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; - CLANG_WARN_DOCUMENTATION_COMMENTS = YES; - GCC_C_LANGUAGE_STANDARD = gnu11; - GCC_INLINES_ARE_PRIVATE_EXTERN = YES; IPHONEOS_DEPLOYMENT_TARGET = 9.0; MACOSX_DEPLOYMENT_TARGET = 10.11; - MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; OTHER_CFLAGS = ""; PRODUCT_NAME = "Universal Framework"; - STRIP_STYLE = debugging; - SUPPORTED_PLATFORMS = "iphonesimulator iphoneos"; + SUPPORTED_PLATFORMS = "iphonesimulator iphoneos macosx"; TVOS_DEPLOYMENT_TARGET = 10.0; WATCHOS_DEPLOYMENT_TARGET = 4.0; }; @@ -8367,71 +8739,32 @@ buildSettings = { APPLICATION_EXTENSION_API_ONLY = YES; BITCODE_GENERATION_MODE = bitcode; - BUILD_LIBRARY_FOR_DISTRIBUTION = YES; - CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; - CLANG_WARN_DOCUMENTATION_COMMENTS = YES; - GCC_C_LANGUAGE_STANDARD = gnu11; - GCC_INLINES_ARE_PRIVATE_EXTERN = YES; IPHONEOS_DEPLOYMENT_TARGET = 9.0; MACOSX_DEPLOYMENT_TARGET = 10.11; OTHER_CFLAGS = ""; PRODUCT_NAME = "Universal Framework"; - STRIP_STYLE = debugging; - SUPPORTED_PLATFORMS = "iphonesimulator iphoneos"; + SUPPORTED_PLATFORMS = "iphonesimulator iphoneos macosx"; TVOS_DEPLOYMENT_TARGET = 10.0; WATCHOS_DEPLOYMENT_TARGET = 4.0; }; name = Release; }; - A57A2FF7238A04F500DE8C68 /* Debug */ = { + A57A3053238D5FDD00DE8C68 /* Debug */ = { isa = XCBuildConfiguration; buildSettings = { - APPLICATION_EXTENSION_API_ONLY = YES; - BITCODE_GENERATION_MODE = bitcode; - BUILD_LIBRARY_FOR_DISTRIBUTION = YES; - CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; - CLANG_WARN_DOCUMENTATION_COMMENTS = YES; - GCC_C_LANGUAGE_STANDARD = gnu11; - GCC_INLINES_ARE_PRIVATE_EXTERN = YES; - IPHONEOS_DEPLOYMENT_TARGET = 9.0; - MACOSX_DEPLOYMENT_TARGET = 10.11; - MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; - OTHER_CFLAGS = ""; - PRODUCT_NAME = "$(TARGET_NAME)"; - STRIP_STYLE = debugging; - SUPPORTED_PLATFORMS = "iphonesimulator iphoneos"; - TVOS_DEPLOYMENT_TARGET = 10.0; - WATCHOS_DEPLOYMENT_TARGET = 4.0; + COPY_PHASE_STRIP = NO; + GCC_DYNAMIC_NO_PIC = NO; + GCC_OPTIMIZATION_LEVEL = 0; + PRODUCT_NAME = "Universal Framework"; }; name = Debug; }; - A57A2FF8238A04F500DE8C68 /* Release */ = { + A57A3054238D5FDD00DE8C68 /* Release */ = { isa = XCBuildConfiguration; buildSettings = { - APPLICATION_EXTENSION_API_ONLY = YES; - BITCODE_GENERATION_MODE = bitcode; - BUILD_LIBRARY_FOR_DISTRIBUTION = YES; - CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; - CLANG_WARN_DOCUMENTATION_COMMENTS = YES; - GCC_C_LANGUAGE_STANDARD = gnu11; - GCC_INLINES_ARE_PRIVATE_EXTERN = YES; - IPHONEOS_DEPLOYMENT_TARGET = 9.0; - MACOSX_DEPLOYMENT_TARGET = 10.11; - OTHER_CFLAGS = ""; - PRODUCT_NAME = "$(TARGET_NAME)"; - STRIP_STYLE = debugging; - SUPPORTED_PLATFORMS = "iphonesimulator iphoneos"; - TVOS_DEPLOYMENT_TARGET = 10.0; - WATCHOS_DEPLOYMENT_TARGET = 4.0; + COPY_PHASE_STRIP = YES; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + PRODUCT_NAME = "Universal Framework"; }; name = Release; }; @@ -8555,11 +8888,11 @@ defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; }; - A57A2FF6238A04F500DE8C68 /* Build configuration list for PBXAggregateTarget "XCFramework (Catalyst)" */ = { + A57A3056238D61E600DE8C68 /* Build configuration list for PBXAggregateTarget "XCFramework (Catalyst)" */ = { isa = XCConfigurationList; buildConfigurations = ( - A57A2FF7238A04F500DE8C68 /* Debug */, - A57A2FF8238A04F500DE8C68 /* Release */, + A57A3053238D5FDD00DE8C68 /* Debug */, + A57A3054238D5FDD00DE8C68 /* Release */, ); defaultConfigurationIsVisible = 0; defaultConfigurationName = Release; diff --git a/Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/Framework (Fabric).xcscheme b/Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/Framework (Fabric).xcscheme deleted file mode 100644 index b6db0bc00..000000000 --- a/Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/Framework (Fabric).xcscheme +++ /dev/null @@ -1,76 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/Framework (OSX).xcscheme b/Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/Framework (OSX).xcscheme index 4345b69c3..3dcac4fd0 100644 --- a/Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/Framework (OSX).xcscheme +++ b/Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/Framework (OSX).xcscheme @@ -1,6 +1,6 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/Static PubNub (iOS).xcscheme b/Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/Static PubNub (iOS).xcscheme deleted file mode 100644 index 349a113ac..000000000 --- a/Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/Static PubNub (iOS).xcscheme +++ /dev/null @@ -1,76 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/XCFramework (Catalyst).xcscheme b/Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/XCFramework (Catalyst).xcscheme deleted file mode 100644 index 33b8e67ce..000000000 --- a/Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/XCFramework (Catalyst).xcscheme +++ /dev/null @@ -1,67 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/XCFramework (Fabric).xcscheme b/Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/XCFramework (Fabric).xcscheme deleted file mode 100644 index 565ddc451..000000000 --- a/Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/XCFramework (Fabric).xcscheme +++ /dev/null @@ -1,76 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/XCFramework (iOS).xcscheme b/Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/XCFramework (iOS).xcscheme deleted file mode 100644 index 386c1c71d..000000000 --- a/Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/XCFramework (iOS).xcscheme +++ /dev/null @@ -1,76 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/XCFramework (tvOS).xcscheme b/Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/XCFramework (tvOS).xcscheme deleted file mode 100644 index 77681b04e..000000000 --- a/Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/XCFramework (tvOS).xcscheme +++ /dev/null @@ -1,76 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/XCFramework (watchOS).xcscheme b/Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/XCFramework (watchOS).xcscheme deleted file mode 100644 index 9b6c2b457..000000000 --- a/Framework/PubNub Framework.xcodeproj/xcshareddata/xcschemes/XCFramework (watchOS).xcscheme +++ /dev/null @@ -1,76 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/Framework/PubNub/Info.plist b/Framework/PubNub/Info.plist index b1681caf9..22414105a 100644 --- a/Framework/PubNub/Info.plist +++ b/Framework/PubNub/Info.plist @@ -7,7 +7,7 @@ CFBundleExecutable PubNub CFBundleGetInfoString - 4.11.1 + 4.12.0 CFBundleIdentifier com.pubnub.pubnub-objc CFBundleInfoDictionaryVersion @@ -17,11 +17,11 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 4.11.1 + 4.12.0 CFBundleSignature ???? CFBundleVersion - 4.11.1 + 4.12.0 NSHumanReadableCopyright © 2010 - 2019 PubNub, Inc. NSPrincipalClass diff --git a/Framework/PubNub/PubNub-Fabric-Info.plist b/Framework/PubNub/PubNub-Fabric-Info.plist index b1681caf9..22414105a 100644 --- a/Framework/PubNub/PubNub-Fabric-Info.plist +++ b/Framework/PubNub/PubNub-Fabric-Info.plist @@ -7,7 +7,7 @@ CFBundleExecutable PubNub CFBundleGetInfoString - 4.11.1 + 4.12.0 CFBundleIdentifier com.pubnub.pubnub-objc CFBundleInfoDictionaryVersion @@ -17,11 +17,11 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 4.11.1 + 4.12.0 CFBundleSignature ???? CFBundleVersion - 4.11.1 + 4.12.0 NSHumanReadableCopyright © 2010 - 2019 PubNub, Inc. NSPrincipalClass diff --git a/Framework/PubNub/PubNub-iOS-Info.plist b/Framework/PubNub/PubNub-iOS-Info.plist index b1681caf9..22414105a 100644 --- a/Framework/PubNub/PubNub-iOS-Info.plist +++ b/Framework/PubNub/PubNub-iOS-Info.plist @@ -7,7 +7,7 @@ CFBundleExecutable PubNub CFBundleGetInfoString - 4.11.1 + 4.12.0 CFBundleIdentifier com.pubnub.pubnub-objc CFBundleInfoDictionaryVersion @@ -17,11 +17,11 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 4.11.1 + 4.12.0 CFBundleSignature ???? CFBundleVersion - 4.11.1 + 4.12.0 NSHumanReadableCopyright © 2010 - 2019 PubNub, Inc. NSPrincipalClass diff --git a/Framework/PubNub/PubNub-tvOS-Info.plist b/Framework/PubNub/PubNub-tvOS-Info.plist index b1681caf9..22414105a 100644 --- a/Framework/PubNub/PubNub-tvOS-Info.plist +++ b/Framework/PubNub/PubNub-tvOS-Info.plist @@ -7,7 +7,7 @@ CFBundleExecutable PubNub CFBundleGetInfoString - 4.11.1 + 4.12.0 CFBundleIdentifier com.pubnub.pubnub-objc CFBundleInfoDictionaryVersion @@ -17,11 +17,11 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 4.11.1 + 4.12.0 CFBundleSignature ???? CFBundleVersion - 4.11.1 + 4.12.0 NSHumanReadableCopyright © 2010 - 2019 PubNub, Inc. NSPrincipalClass diff --git a/Framework/PubNub/PubNub-watchOS-Info.plist b/Framework/PubNub/PubNub-watchOS-Info.plist index b1681caf9..22414105a 100644 --- a/Framework/PubNub/PubNub-watchOS-Info.plist +++ b/Framework/PubNub/PubNub-watchOS-Info.plist @@ -7,7 +7,7 @@ CFBundleExecutable PubNub CFBundleGetInfoString - 4.11.1 + 4.12.0 CFBundleIdentifier com.pubnub.pubnub-objc CFBundleInfoDictionaryVersion @@ -17,11 +17,11 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 4.11.1 + 4.12.0 CFBundleSignature ???? CFBundleVersion - 4.11.1 + 4.12.0 NSHumanReadableCopyright © 2010 - 2019 PubNub, Inc. NSPrincipalClass diff --git a/PubNub.podspec b/PubNub.podspec index cf433cb5d..a8368718e 100644 --- a/PubNub.podspec +++ b/PubNub.podspec @@ -9,7 +9,7 @@ Pod::Spec.new do |spec| spec.name = 'PubNub' - spec.version = '4.11.1' + spec.version = '4.12.0' spec.summary = 'The PubNub Real-Time Network. Build real-time apps quickly and scale them globally.' spec.homepage = 'https://github.com/pubnub/objective-c' @@ -32,10 +32,10 @@ Pod::Spec.new do |spec| core.source_files = 'PubNub/{Core,Data,Misc,Network}/**/*', 'PubNub/PubNub.h' core.private_header_files = [ 'PubNub/**/*Private.h', - 'PubNub/Data/{PNEnvelopeInformation,PNKeychain}.h', + 'PubNub/Data/{PNEnvelopeInformation}.h', 'PubNub/Data/Managers/**/*.h', 'PubNub/Misc/{PNConstants,PNPrivateStructures}.h', - 'PubNub/Misc/Helpers/{PNArray,PNChannel,PNData,PNDictionary,PNGZIP,PNHelpers,PNJSON,PNLockSupport,PNNumber,PNString,PNURLRequest}.h', + 'PubNub/Misc/Helpers/{PNArray,PNChannel,PNData,PNDate,PNDictionary,PNGZIP,PNHelpers,PNJSON,PNLockSupport,PNNumber,PNString,PNURLRequest}.h', 'PubNub/Misc/Logger/PNLogMacro.h', 'PubNub/Misc/Logger/Data/*.h', 'PubNub/Misc/Protocols/PNParser.h', diff --git a/PubNub/Core/PubNub+APNS.h b/PubNub/Core/PubNub+APNS.h index 5dbbdd429..d22165b53 100644 --- a/PubNub/Core/PubNub+APNS.h +++ b/PubNub/Core/PubNub+APNS.h @@ -1,6 +1,11 @@ #import +#import "PNRemoveAllPushNotificationsRequest.h" +#import "PNRemovePushNotificationsRequest.h" #import "PNAPNSModificationAPICallBuilder.h" +#import "PNAuditPushNotificationsRequest.h" +#import "PNAddPushNotificationsRequest.h" #import "PNAPNSAuditAPICallBuilder.h" +#import "PNNotificationsPayload.h" #import "PNAPNSAPICallBuilder.h" #import "PubNub+Core.h" @@ -22,8 +27,9 @@ NS_ASSUME_NONNULL_BEGIN * device inactive. * * @author Serhii Mamontov - * @since 4.0 - * @copyright © 2010-2018 PubNub, Inc. + * @version 4.12.0 + * @since 4.0.0 + * @copyright © 2010-2019 PubNub, Inc. */ @interface PubNub (APNS) @@ -51,7 +57,7 @@ NS_ASSUME_NONNULL_BEGIN * andCompletion:^(PNAcknowledgmentStatus *status) { * * if (!status.isError) { - * // Handle successful push notification enabling on passed channels. + * // Push notifications successful enabled on passed channels. * } else { * // Handle modification error. Check 'category' property to find out possible issue because * // of which request did fail. @@ -73,6 +79,85 @@ NS_ASSUME_NONNULL_BEGIN andCompletion:(nullable PNPushNotificationsStateModificationCompletionBlock)block NS_SWIFT_NAME(addPushNotificationsOnChannels(_:withDevicePushToken:andCompletion:)); +/** + * @brief Enable push notifications (sent using legacy APNs, FCM or MPNS) on provided set of + * \c channels. + * + * @code + * [self.client addPushNotificationsOnChannels:@[@"wwdc",@"google.io"] + * withDevicePushToken:self.devicePushToken + * pushType:PNAPNSPush + * andCompletion:^(PNAcknowledgmentStatus *status) { + * + * if (!status.isError) { + * // Push notifications successful enabled on passed channels. + * } else { + * // Handle modification error. Check 'category' property to find out possible issue because + * // of which request did fail. + * // + * // Request can be resent using: [status retry]; + * } + * }]; + * @endcode + * + * @param channels List of channel names for which push notifications should be enabled. + * @param pushToken Device token / identifier which depending from passed \c pushType should be + * \a NSData (for \b PNAPNS2Push and \b PNAPNSPush) or \a NSString for other. + * @param pushType One of \b PNPushType fields which specify service to manage notifications for + * device specified with \c pushToken. + * @param block \c Add \c notifications \c for \c channels request completion block. + * + * @since 4.12.0 + */ +- (void)addPushNotificationsOnChannels:(NSArray *)channels + withDevicePushToken:(id)pushToken + pushType:(PNPushType)pushType + andCompletion:(nullable PNPushNotificationsStateModificationCompletionBlock)block + NS_SWIFT_NAME(addPushNotificationsOnChannels(_:withDevicePushToken:pushType:andCompletion:)); + +/** + * @brief Enable push notifications (sent using APNs over HTTP/2) on provided set of \c channels. + * + * @code + * [self.client addPushNotificationsOnChannels:@[@"wwdc",@"google.io"] + * withDevicePushToken:self.devicePushToken + * pushType:PNAPNS2Push + * environment:PNAPNSProduction + * topic:@"com.my-application.bundle" + * andCompletion:^(PNAcknowledgmentStatus *status) { + * + * if (!status.isError) { + * // Push notifications successful enabled on passed channels. + * } else { + * // Handle modification error. Check 'category' property to find out possible issue because + * // of which request did fail. + * // + * // Request can be resent using: [status retry]; + * } + * }]; + * @endcode + * + * @param channels List of channel names for which push notifications should be enabled. + * @param pushToken Device token / identifier which depending from passed \c pushType should be + * \a NSData (for \b PNAPNS2Push and \b PNAPNSPush) or \a NSString for other. + * @param pushType One of \b PNPushType fields which specify service to manage notifications for + * device specified with \c pushToken. + * @param environment One of \b PNAPNSEnvironment fields which specify environment within which + * device should manage list of channels with enabled notifications (works only if \c pushType + * set to \b PNAPNS2Push). + * @param topic Notifications topic name (usually it is application's bundle identifier). + * @param block \c Add \c notifications \c for \c channels request completion block. + * + * @since 4.12.0 + */ +- (void)addPushNotificationsOnChannels:(NSArray *)channels + withDevicePushToken:(id)pushToken + pushType:(PNPushType)pushType + environment:(PNAPNSEnvironment)environment + topic:(NSString *)topic + andCompletion:(nullable PNPushNotificationsStateModificationCompletionBlock)block + NS_SWIFT_NAME(addPushNotificationsOnChannels(_:withDevicePushToken:pushType:environment:topic:andCompletion:)); + /** * @brief Disable push notifications on provided set of \c channels. * @@ -82,7 +167,7 @@ NS_ASSUME_NONNULL_BEGIN * andCompletion:^(PNAcknowledgmentStatus *status) { * * if (!status.isError) { - * // Handle successful push notification enabling on passed channels. + * // Push notification successfully disabled on passed channels. * } else { * // Handle modification error. Check 'category' property to find out possible issue because * // of which request did fail. @@ -104,6 +189,85 @@ NS_ASSUME_NONNULL_BEGIN andCompletion:(nullable PNPushNotificationsStateModificationCompletionBlock)block NS_SWIFT_NAME(removePushNotificationsFromChannels(_:withDevicePushToken:andCompletion:)); +/** + * @brief Disable push notifications (sent using legacy APNs, FCM or MPNS) on provided set of + * \c channels. + * + * @code + * [self.client removePushNotificationsFromChannels:@[@"wwdc",@"google.io"] + * withDevicePushToken:self.devicePushToken + * pushType:PNAPNSPush + * andCompletion:^(PNAcknowledgmentStatus *status) { + * + * if (!status.isError) { + * // Push notification successfully disabled on passed channels. + * } else { + * // Handle modification error. Check 'category' property to find out possible issue because + * // of which request did fail. + * // + * // Request can be resent using: [status retry]; + * } + * }]; + * @endcode + * + * @param channels List of channel names for which push notifications should be disabled. + * @param pushToken Device token / identifier which depending from passed \c pushType should be + * \a NSData (for \b PNAPNS2Push and \b PNAPNSPush) or \a NSString for other. + * @param pushType One of \b PNPushType fields which specify service to manage notifications for + * device specified with \c pushToken. + * @param block \c Remove \c notifications \c from \c channels request completion block. + * + * @since 4.12.0 + */ +- (void)removePushNotificationsFromChannels:(NSArray *)channels + withDevicePushToken:(id)pushToken + pushType:(PNPushType)pushType + andCompletion:(nullable PNPushNotificationsStateModificationCompletionBlock)block + NS_SWIFT_NAME(removePushNotificationsFromChannels(_:withDevicePushToken:pushType:andCompletion:)); + +/** + * @brief Disable push notifications (sent using APNs over HTTP/2) on provided set of \c channels. + * + * @code + * [self.client removePushNotificationsFromChannels:@[@"wwdc",@"google.io"] + * withDevicePushToken:self.devicePushToken + * pushType:PNAPNS2Push + * environment:PNAPNSDevelopment + * topic:@"com.my-application.bundle" + * andCompletion:^(PNAcknowledgmentStatus *status) { + * + * if (!status.isError) { + * // Push notification successfully disabled on passed channels. + * } else { + * // Handle modification error. Check 'category' property to find out possible issue because + * // of which request did fail. + * // + * // Request can be resent using: [status retry]; + * } + * }]; + * @endcode + * + * @param channels List of channel names for which push notifications should be disabled. + * @param pushToken Device token / identifier which depending from passed \c pushType should be + * \a NSData (for \b PNAPNS2Push and \b PNAPNSPush) or \a NSString for other. + * @param pushType One of \b PNPushType fields which specify service to manage notifications for + * device specified with \c pushToken. + * @param environment One of \b PNAPNSEnvironment fields which specify environment within which + * device should manage list of channels with enabled notifications (works only if \c pushType + * set to \b PNAPNS2Push). + * @param topic Notifications topic name (usually it is application's bundle identifier). + * @param block \c Remove \c notifications \c from \c channels request completion block. + * + * @since 4.12.0 + */ +- (void)removePushNotificationsFromChannels:(NSArray *)channels + withDevicePushToken:(id)pushToken + pushType:(PNPushType)pushType + environment:(PNAPNSEnvironment)environment + topic:(NSString *)topic + andCompletion:(nullable PNPushNotificationsStateModificationCompletionBlock)block + NS_SWIFT_NAME(removePushNotificationsFromChannels(_:withDevicePushToken:pushType:environment:topic:andCompletion:)); + /** * @brief Disable push notifications from all channels which is registered with specified * \c pushToken. @@ -113,8 +277,8 @@ NS_ASSUME_NONNULL_BEGIN * andCompletion:^(PNAcknowledgmentStatus *status) { * * if (!status.isError) { - * // Handle successful push notification disabling for all channels associated with - * // specified device push token. + * // Push notification successfully disabled for all channels associated with specified + * // device push token. * } else { * // Handle modification error. Check 'category' property to find out possible issue because * // of which request did fail. @@ -134,6 +298,82 @@ NS_ASSUME_NONNULL_BEGIN andCompletion:(nullable PNPushNotificationsStateModificationCompletionBlock)block NS_SWIFT_NAME(removeAllPushNotificationsFromDeviceWithPushToken(_:andCompletion:)); +/** + * @brief Disable push notifications (sent using legacy APNs, FCM or MPNS) from all channels which + * is registered with specified \c pushToken. + * + * @code + * [self.client removeAllPushNotificationsFromDeviceWithPushToken:self.devicePushToken + * pushType:PNAPNSPush + * andCompletion:^(PNAcknowledgmentStatus *status) { + * + * if (!status.isError) { + * // Push notification successfully disabled for all channels associated with specified + * // device push token. + * } else { + * // Handle modification error. Check 'category' property to find out possible issue because + * // of which request did fail. + * // + * // Request can be resent using: [status retry]; + * } + * }]; + * @endcode + * + * @param pushToken Device token / identifier which depending from passed \c pushType should be + * \a NSData (for \b PNAPNS2Push and \b PNAPNSPush) or \a NSString for other. + * @param pushType One of \b PNPushType fields which specify service to manage notifications for + * device specified with \c pushToken. + * @param block \c Remove \c all \c notifications request completion block. + * + * @since 4.12.0 + */ +- (void)removeAllPushNotificationsFromDeviceWithPushToken:(id)pushToken + pushType:(PNPushType)pushType + andCompletion:(nullable PNPushNotificationsStateModificationCompletionBlock)block + NS_SWIFT_NAME(removeAllPushNotificationsFromDeviceWithPushToken(_:pushType:andCompletion:)); + +/** + * @brief Disable push notifications (sent using APNs over HTTP/2) from all channels + * which is registered with specified \c pushToken. + * + * @code + * [self.client removeAllPushNotificationsFromDeviceWithPushToken:self.devicePushToken + * pushType:PNAPNS2Push + * environment:PNAPNSDevelopment + * topic:@"com.my-application.bundle" + * andCompletion:^(PNAcknowledgmentStatus *status) { + * + * if (!status.isError) { + * // Push notification successfully disabled for all channels associated with specified + * // device push token. + * } else { + * // Handle modification error. Check 'category' property to find out possible issue because + * // of which request did fail. + * // + * // Request can be resent using: [status retry]; + * } + * }]; + * @endcode + * + * @param pushToken Device token / identifier which depending from passed \c pushType should be + * \a NSData (for \b PNAPNS2Push and \b PNAPNSPush) or \a NSString for other. + * @param pushType One of \b PNPushType fields which specify service to manage notifications for + * device specified with \c pushToken. + * @param environment One of \b PNAPNSEnvironment fields which specify environment within which + * device should manage list of channels with enabled notifications (works only if \c pushType + * set to \b PNAPNS2Push). + * @param topic Notifications topic name (usually it is application's bundle identifier). + * @param block \c Remove \c all \c notifications request completion block. + * + * @since 4.12.0 + */ +- (void)removeAllPushNotificationsFromDeviceWithPushToken:(id)pushToken + pushType:(PNPushType)pushType + environment:(PNAPNSEnvironment)environment + topic:(NSString *)topic + andCompletion:(nullable PNPushNotificationsStateModificationCompletionBlock)block + NS_SWIFT_NAME(removeAllPushNotificationsFromDeviceWithPushToken(_:pushType:environment:topic:andCompletion:)); + #pragma mark - Push notifications state audit @@ -165,6 +405,86 @@ NS_ASSUME_NONNULL_BEGIN andCompletion:(PNPushNotificationsStateAuditCompletionBlock)block NS_SWIFT_NAME(pushNotificationEnabledChannelsForDeviceWithPushToken(_:andCompletion:)); +/** + * @brief Request for all channels on which push notification (sent using legacy APNs, FCM or MPNS) + * has been enabled using specified \c pushToken. + * + * @code + * [self.client pushNotificationEnabledChannelsForDeviceWithPushToken:self.devicePushToken + * pushType:PNAPNSPush + * andCompletion:^(PNAPNSEnabledChannelsResult *result, PNErrorStatus *status) { + * + * if (!status.isError) { + * // Handle downloaded list of channels using: result.data.channels + * } else { + * // Handle audition error. Check 'category' property to find out possible issue because of + * // which request did fail. + * // + * // Request can be resent using: [status retry]; + * } + * }]; + * @endcode + * + * @param pushToken Device token / identifier which depending from passed \c pushType should be + * \a NSData (for \b PNAPNS2Push and \b PNAPNSPush) or \a NSString for other. + * @param pushType One of \b PNPushType fields which specify service to manage notifications for + * device specified with \c pushToken. + * @param block \c Audit \c notifications \c enabled \c channels request completion block. + * + * @since 4.12.0 + */ +- (void)pushNotificationEnabledChannelsForDeviceWithPushToken:(id)pushToken + pushType:(PNPushType)pushType + andCompletion:(PNPushNotificationsStateAuditCompletionBlock)block + NS_SWIFT_NAME(pushNotificationEnabledChannelsForDeviceWithPushToken(_:pushType:andCompletion:)); + +/** + * @brief Request for all channels on which push notification (sent using APNs over HTTP/2) has been + * enabled using specified \c pushToken. + * + * @code + * PNAuditPushNotificationsRequest *request = nil; + * request = [PNAuditPushNotificationsRequest requestWithDevicePushToken:self.devicePushToken + * pushType:PNAPNS2Push]; + * request.topic = @"com.my-application.bundle"; + * request.environment = PNAPNSProduction; + * + * [self.client pushNotificationEnabledChannelsForDeviceWithPushToken:self.devicePushToken + * pushType:PNAPNS2Push + * environment:PNAPNSDevelopment + * topic:@"com.my-application.bundle" + * andCompletion:^(PNAPNSEnabledChannelsResult *result, PNErrorStatus *status) { + * + * if (!status.isError) { + * // Handle downloaded list of channels using: result.data.channels + * } else { + * // Handle audition error. Check 'category' property to find out possible issue because of + * // which request did fail. + * // + * // Request can be resent using: [status retry]; + * } + * }]; + * @endcode + * + * @param pushToken Device token / identifier which depending from passed \c pushType should be + * \a NSData (for \b PNAPNS2Push and \b PNAPNSPush) or \a NSString for other. + * @param pushType One of \b PNPushType fields which specify service to manage notifications for + * device specified with \c pushToken. + * @param environment One of \b PNAPNSEnvironment fields which specify environment within which + * device should manage list of channels with enabled notifications (works only if \c pushType + * set to \b PNAPNS2Push). + * @param topic Notifications topic name (usually it is application's bundle identifier). + * @param block \c Audit \c notifications \c enabled \c channels request completion block. + * + * @since 4.12.0 + */ +- (void)pushNotificationEnabledChannelsForDeviceWithPushToken:(id)pushToken + pushType:(PNPushType)pushType + environment:(PNAPNSEnvironment)environment + topic:(NSString *)topic + andCompletion:(PNPushNotificationsStateAuditCompletionBlock)block + NS_SWIFT_NAME(pushNotificationEnabledChannelsForDeviceWithPushToken(_:pushType:environment:topic:andCompletion:)); + #pragma mark - diff --git a/PubNub/Core/PubNub+APNS.m b/PubNub/Core/PubNub+APNS.m index 901a7a53d..11e6c2fd3 100644 --- a/PubNub/Core/PubNub+APNS.m +++ b/PubNub/Core/PubNub+APNS.m @@ -1,20 +1,23 @@ /** * @author Serhii Mamontov - * @since 4.0 - * @copyright © 2010-2018 PubNub, Inc. + * @version 4.12.0 + * @since 4.0.0 + * @copyright © 2010-2019 PubNub, Inc. */ #import "PubNub+APNS.h" #import "PNAPICallBuilder+Private.h" +#import "PNAcknowledgmentStatus.h" #import "PNRequestParameters.h" #import "PubNub+CorePrivate.h" #import "PNStatus+Private.h" +#import "PNErrorStatus.h" #import "PNKeychain.h" #import "PNHelpers.h" NS_ASSUME_NONNULL_BEGIN -#pragma mark - Protected interface declaration +#pragma mark Private interface declaration @interface PubNub (APNSProtected) @@ -22,50 +25,145 @@ @interface PubNub (APNSProtected) #pragma mark - Push notifications state manipulation /** - * @brief Final designated method which allow to modify push notifications state on set of channels - * for device specified by \c pushToken. + * @brief Enable push notifications (sent using legacy APNs or APNs over HTTP/2) on provided set of + * \c channels. * - * @param shouldEnabled Whether push notification should be enabled or disabled on \c channels. - * @param channels List of channels for which notification state should be changed. - * @param gateway Name / type of service for which channels modification should be done - * ('apns' or 'gcm'). - * @param token Device push token for which on specified \c channels push notifications will be - * enabled or disabled. - * @param queryParameters List arbitrary query parameters which should be sent along with original - * API call. - * @param block Push notifications state modification on channels completion block. + * @code + * PNAddPushNotificationsRequest *request = nil; + * request = [PNAddPushNotificationsRequest requestWithDevicePushToken:self.devicePushToken + * pushType:PNAPNSPush]; + * request.channels = @[@"wwdc",@"google.io"]; * - * @since 4.8.2 + * [self.client addPushNotificationsWithRequest:request + * completion:^(PNAcknowledgmentStatus *status) { + * + * if (!status.isError) { + * // Push notifications successful enabled on passed channels. + * } else { + * // Handle modification error. Check 'category' property to find out possible issue because + * // of which request did fail. + * // + * // Request can be resent using: [status retry]; + * } + * }]; + * @endcode + * + * @param request \c Add \c notifications \c for \c channels request with information required to + * enable notifications on \c channels. + * @param block \c Add \c notifications \c for \c channels request completion block. + * + * @since 4.12.0 */ -- (void)enablePushNotification:(BOOL)shouldEnabled - onChannels:(nullable NSArray *)channels - withGateway:(NSString *)gateway - deviceToken:(id)token - queryParameters:(nullable NSDictionary *)queryParameters - andCompletion:(nullable PNPushNotificationsStateModificationCompletionBlock)block; +- (void)addPushNotificationsWithRequest:(PNAddPushNotificationsRequest *)request + completion:(nullable PNPushNotificationsStateModificationCompletionBlock)block; + +/** + * @brief Disable push notifications (sent using legacy APNs or APNs over HTTP/2) on provided set of + * \c channels. + * + * @code + * PNRemovePushNotificationsRequest *request = nil; + * request = [PNRemovePushNotificationsRequest requestWithDevicePushToken:self.devicePushToken + * pushType:PNAPNSPush]; + * request.channels = @[@"wwdc",@"google.io"]; + * + * [self.client removePushNotificationsWithRequest:request + * completion:^(PNAcknowledgmentStatus *status) { + * + * if (!status.isError) { + * // Push notification successfully disabled on passed channels. + * } else { + * // Handle modification error. Check 'category' property to find out possible issue because + * // of which request did fail. + * // + * // Request can be resent using: [status retry]; + * } + * }]; + * @endcode + * + * @param request \c Remove \c notifications \c from \c channels request with information required + * to disable notifications for \c channels. + * @param block \c Remove \c notifications \c from \c channels request completion block. + * + * @since 4.12.0 + */ +- (void)removePushNotificationsWithRequest:(PNRemovePushNotificationsRequest *)request + completion:(nullable PNPushNotificationsStateModificationCompletionBlock)block; + +/** + * @brief Disable push notifications (sent using legacy APNs or APNs over HTTP/2) from all channels + * which is registered with specified \c pushToken. + * + * @code + * PNRemoveAllPushNotificationsRequest *request = nil; + * request = [PNRemoveAllPushNotificationsRequest requestWithDevicePushToken:self.devicePushToken + * pushType:PNAPNS2Push]; + * request.topic = @"com.my-application.bundle"; + * request.environment = PNAPNSProduction; + * + * [self.client removeAllPushNotificationsWithRequest:request + * completion:^(PNAcknowledgmentStatus *status) { + * + * if (!status.isError) { + * // Handle successful push notification disabling for all channels associated with + * // specified device push token. + * } else { + * // Handle modification error. Check 'category' property to find out possible issue because + * // of which request did fail. + * // + * // Request can be resent using: [status retry]; + * } + * }]; + * @endcode + * + * @param request \c Remove \c all \c notifications request with information required to disable + * notifications for \c device. + * @param block \c Remove \c all \c notifications request completion block. + * + * @since 4.12.0 + */ +- (void)removeAllPushNotificationsWithRequest:(PNRemoveAllPushNotificationsRequest *)request + completion:(nullable PNPushNotificationsStateModificationCompletionBlock)block; #pragma mark - Push notifications state audit /** - * @brief Request for all channels on which push notification has been enabled using specified - * \c pushToken. + * @brief Request for all channels on which push notification (sent using legacy APNs or APNs over + * HTTP/2) has been enabled using specified \c pushToken. + * + * @code + * PNAuditPushNotificationsRequest *request = nil; + * request = [PNAuditPushNotificationsRequest requestWithDevicePushToken:self.devicePushToken + * pushType:PNAPNS2Push]; + * request.topic = @"com.my-application.bundle"; + * request.environment = PNAPNSProduction; + * + * [self.client pushNotificationEnabledChannelsWithRequest:request + * andCompletion:^(PNAPNSEnabledChannelsResult *result, PNErrorStatus *status) { * - * @param gateway Name / type of service for which channels audit should be done ('apns' or 'gcm'). - * @param token Device push token against which search should be performed. - * @param queryParameters List arbitrary query parameters which should be sent along with original - * API call. - * \b Required: optional - * @param block Push notifications status fetch completion block. + * if (!status.isError) { + * // Handle downloaded list of channels using: result.data.channels + * } else { + * // Handle audition error. Check 'category' property to find out possible issue because of + * // which request did fail. + * // + * // Request can be resent using: [status retry]; + * } + * }]; + * @endcode * - * @since 4.8.2 + * @param request \c Audit \c notifications \c enabled \c channels request with information required + * to retrieve channels with enabled notifications. + * @param block \c Audit \c notifications \c enabled \c channels request completion block. + * + * @since 4.12.0 */ -- (void)pushNotificationEnabledChannelsForGateway:(NSString *)gateway - withDeviceToken:(id)token - queryParameters:(nullable NSDictionary *)queryParameters - andCompletion:(PNPushNotificationsStateAuditCompletionBlock)block; +- (void)pushNotificationEnabledChannelsWithRequest:(PNAuditPushNotificationsRequest *)request + completion:(PNPushNotificationsStateAuditCompletionBlock)block; + -#pragma mark - +#pragma mark - @end @@ -82,30 +180,58 @@ @implementation PubNub (APNS) - (PNAPNSAPICallBuilder * (^)(void))push { - PNAPNSAPICallBuilder *builder = nil; + PNAPNSAPICallBuilder *builder = nil; builder = [PNAPNSAPICallBuilder builderWithExecutionBlock:^(NSArray *flags, NSDictionary *parameters) { - - NSData *apnsToken = parameters[NSStringFromSelector(@selector(apnsToken))]; - NSString *fcmToken = parameters[NSStringFromSelector(@selector(fcmToken))]; + + NSArray *channels = parameters[NSStringFromSelector(@selector(channels))]; + NSNumber *environmentValue = parameters[NSStringFromSelector(@selector(environment))]; + NSNumber *pushTypeValue = parameters[NSStringFromSelector(@selector(pushType))]; + PNAPNSEnvironment environment = environmentValue.unsignedIntegerValue; + NSString *topic = parameters[NSStringFromSelector(@selector(topic))]; + id token = parameters[NSStringFromSelector(@selector(token))]; + PNPushType pushType = pushTypeValue.unsignedIntegerValue; NSDictionary *queryParam = parameters[@"queryParam"]; id block = parameters[@"block"]; if ([flags containsObject:NSStringFromSelector(@selector(audit))]) { - [self pushNotificationEnabledChannelsForGateway:(apnsToken ? @"apns" : @"gcm") - withDeviceToken:(apnsToken ?: fcmToken) - queryParameters:queryParam - andCompletion:block]; - } else { - NSArray *channels = parameters[NSStringFromSelector(@selector(channels))]; - BOOL enabling = [flags containsObject:NSStringFromSelector(@selector(enable))]; + PNAuditPushNotificationsRequest *request = nil; + request = [PNAuditPushNotificationsRequest requestWithDevicePushToken:token + pushType:pushType]; + request.arbitraryQueryParameters = queryParam; + request.environment = environment; + request.topic = topic; - [self enablePushNotification:enabling - onChannels:(channels.count ? channels : nil) - withGateway:(apnsToken ? @"apns" : @"gcm") - deviceToken:(apnsToken ?: fcmToken) - queryParameters:queryParam - andCompletion:block]; + [self pushNotificationEnabledChannelsWithRequest:request completion:block]; + } else if ([flags containsObject:NSStringFromSelector(@selector(enable))]) { + PNAddPushNotificationsRequest *request = nil; + request = [PNAddPushNotificationsRequest requestWithDevicePushToken:token + pushType:pushType]; + request.arbitraryQueryParameters = queryParam; + request.environment = environment; + request.channels = channels; + request.topic = topic; + + [self addPushNotificationsWithRequest:request completion:block]; + } else if ([flags containsObject:NSStringFromSelector(@selector(disable))]) { + PNRemovePushNotificationsRequest *request = nil; + request = [PNRemovePushNotificationsRequest requestWithDevicePushToken:token + pushType:pushType]; + request.arbitraryQueryParameters = queryParam; + request.environment = environment; + request.channels = channels; + request.topic = topic; + + [self removePushNotificationsWithRequest:request completion:block]; + } else if ([flags containsObject:NSStringFromSelector(@selector(disableAll))]) { + PNRemoveAllPushNotificationsRequest *request = nil; + request = [PNRemoveAllPushNotificationsRequest requestWithDevicePushToken:token + pushType:pushType]; + request.arbitraryQueryParameters = queryParam; + request.environment = environment; + request.topic = topic; + + [self removeAllPushNotificationsWithRequest:request completion:block]; } }]; @@ -121,98 +247,193 @@ - (void)addPushNotificationsOnChannels:(NSArray *)channels withDevicePushToken:(NSData *)pushToken andCompletion:(PNPushNotificationsStateModificationCompletionBlock)block { - [self enablePushNotification:YES - onChannels:channels - withGateway:@"apns" - deviceToken:pushToken - queryParameters:nil - andCompletion:block]; + [self addPushNotificationsOnChannels:channels + withDevicePushToken:pushToken + pushType:PNAPNSPush + andCompletion:block]; +} + +- (void)addPushNotificationsOnChannels:(NSArray *)channels + withDevicePushToken:(id)pushToken + pushType:(PNPushType)pushType + andCompletion:(PNPushNotificationsStateModificationCompletionBlock)block { + + [self addPushNotificationsOnChannels:channels + withDevicePushToken:pushToken + pushType:pushType + environment:PNAPNSDevelopment + topic:NSBundle.mainBundle.bundleIdentifier + andCompletion:block]; +} + +- (void)addPushNotificationsOnChannels:(NSArray *)channels + withDevicePushToken:(id)pushToken + pushType:(PNPushType)pushType + environment:(PNAPNSEnvironment)environment + topic:(NSString *)topic + andCompletion:(PNPushNotificationsStateModificationCompletionBlock)block { + + PNAddPushNotificationsRequest *request = nil; + request = [PNAddPushNotificationsRequest requestWithDevicePushToken:pushToken + pushType:pushType]; + request.channels = channels; + + if (pushType == PNAPNS2Push) { + request.environment = environment; + request.topic = topic; + } + + [self addPushNotificationsWithRequest:request completion:block]; +} + +- (void)addPushNotificationsWithRequest:(PNAddPushNotificationsRequest *)request + completion:(PNPushNotificationsStateModificationCompletionBlock)block { + + PNLogAPICall(self.logger, @" Enable push notifications for device '%@'%@: %@.", + request.pushToken, + request.pushType == PNAPNS2Push ? [NSString stringWithFormat:@" ('%@' topic in %@ environment)", + request.topic, + request.environment == PNAPNSDevelopment ? @"development" : @"production"] + : @"", + [PNChannel namesForRequest:request.channels]); + + __weak __typeof(self) weakSelf = self; + + [self performRequest:request withCompletion:^(PNAcknowledgmentStatus *status) { + if (status.isError) { + status.retryBlock = ^{ + [weakSelf addPushNotificationsWithRequest:request completion:block]; + }; + } + + block(status); + }]; } - (void)removePushNotificationsFromChannels:(NSArray *)channels withDevicePushToken:(NSData *)pushToken andCompletion:(PNPushNotificationsStateModificationCompletionBlock)block { - [self enablePushNotification:NO - onChannels:channels - withGateway:@"apns" - deviceToken:pushToken - queryParameters:nil - andCompletion:block]; + [self removePushNotificationsFromChannels:channels + withDevicePushToken:pushToken + pushType:PNAPNSPush + andCompletion:block]; } -- (void)removeAllPushNotificationsFromDeviceWithPushToken:(NSData *)pushToken +- (void)removePushNotificationsFromChannels:(NSArray *)channels + withDevicePushToken:(id)pushToken + pushType:(PNPushType)pushType andCompletion:(PNPushNotificationsStateModificationCompletionBlock)block { - [self enablePushNotification:NO - onChannels:nil - withGateway:@"apns" - deviceToken:pushToken - queryParameters:nil - andCompletion:block]; + [self removePushNotificationsFromChannels:channels + withDevicePushToken:pushToken + pushType:pushType + environment:PNAPNSDevelopment + topic:NSBundle.mainBundle.bundleIdentifier + andCompletion:block]; } -- (void)enablePushNotification:(BOOL)shouldEnabled - onChannels:(NSArray *)channels - withGateway:(NSString *)gateway - deviceToken:(id)token - queryParameters:(NSDictionary *)queryParameters - andCompletion:(PNPushNotificationsStateModificationCompletionBlock)block{ - - PNOperationType operationType = PNRemoveAllPushNotificationsOperation; - PNRequestParameters *parameters = [PNRequestParameters new]; - BOOL removeAllChannels = !shouldEnabled && !channels.count; - NSString *deviceToken = token; - gateway = gateway ?: @"apns"; - - [parameters addQueryParameters:@{@"type": gateway.lowercaseString}]; - [parameters addQueryParameters:queryParameters]; +- (void)removePushNotificationsFromChannels:(NSArray *)channels + withDevicePushToken:(id)pushToken + pushType:(PNPushType)pushType + environment:(PNAPNSEnvironment)environment + topic:(NSString *)topic + andCompletion:(PNPushNotificationsStateModificationCompletionBlock)block { + + PNRemovePushNotificationsRequest *request = nil; + request = [PNRemovePushNotificationsRequest requestWithDevicePushToken:pushToken + pushType:pushType]; + request.channels = channels; - if ([gateway.lowercaseString isEqualToString:@"apns"] && ((NSData *)token).length) { - deviceToken = [PNData HEXFromDevicePushToken:token]; + if (pushType == PNAPNS2Push) { + request.environment = environment; + request.topic = topic; } - if (deviceToken.length) { - [parameters addPathComponent:deviceToken.lowercaseString forPlaceholder:@"{token}"]; - } + [self removePushNotificationsWithRequest:request completion:block]; +} - if (!removeAllChannels) { - operationType = (shouldEnabled ? PNAddPushNotificationsOnChannelsOperation - : PNRemovePushNotificationsFromChannelsOperation); - - if (channels.count) { - [parameters addQueryParameter:[PNChannel namesForRequest:channels] - forFieldName:(shouldEnabled ? @"add" : @"remove")]; - } else if (operationType == PNAddPushNotificationsOnChannelsOperation) { - [parameters removePathComponentForPlaceholder:@"{token}"]; +- (void)removePushNotificationsWithRequest:(PNRemovePushNotificationsRequest *)request + completion:(PNPushNotificationsStateModificationCompletionBlock)block { + + PNLogAPICall(self.logger, @" Disable push notifications for device '%@'%@: %@.", + request.pushToken, + request.pushType == PNAPNS2Push ? [NSString stringWithFormat:@" ('%@' topic in %@ environment)", + request.topic, + request.environment == PNAPNSDevelopment ? @"development" : @"production"] + : @"", + [PNChannel namesForRequest:request.channels]); + + __weak __typeof(self) weakSelf = self; + + [self performRequest:request withCompletion:^(PNAcknowledgmentStatus *status) { + if (status.isError) { + status.retryBlock = ^{ + [weakSelf removePushNotificationsWithRequest:request completion:block]; + }; } - PNLogAPICall(self.logger, @" %@ push notifications for device '%@': %@.", - (shouldEnabled ? @"Enable" : @"Disable"), - deviceToken.lowercaseString, - [PNChannel namesForRequest:channels]); - } else { - PNLogAPICall(self.logger, @" Disable push notifications for device '%@'.", - deviceToken.lowercaseString); + block(status); + }]; +} + +- (void)removeAllPushNotificationsFromDeviceWithPushToken:(NSData *)pushToken + andCompletion:(PNPushNotificationsStateModificationCompletionBlock)block { + + [self removeAllPushNotificationsFromDeviceWithPushToken:pushToken + pushType:PNAPNSPush + andCompletion:block]; +} + +- (void)removeAllPushNotificationsFromDeviceWithPushToken:(id)pushToken + pushType:(PNPushType)pushType + andCompletion:(PNPushNotificationsStateModificationCompletionBlock)block { + + [self removeAllPushNotificationsFromDeviceWithPushToken:pushToken + pushType:pushType + environment:PNAPNSDevelopment + topic:NSBundle.mainBundle.bundleIdentifier + andCompletion:block]; +} + +- (void)removeAllPushNotificationsFromDeviceWithPushToken:(id)pushToken + pushType:(PNPushType)pushType + environment:(PNAPNSEnvironment)environment + topic:(NSString *)topic + andCompletion:(PNPushNotificationsStateModificationCompletionBlock)block { + + PNRemoveAllPushNotificationsRequest *request = nil; + request = [PNRemoveAllPushNotificationsRequest requestWithDevicePushToken:pushToken + pushType:pushType]; + + if (pushType == PNAPNS2Push) { + request.environment = environment; + request.topic = topic; } + + [self removeAllPushNotificationsWithRequest:request completion:block]; +} +- (void)removeAllPushNotificationsWithRequest:(PNRemoveAllPushNotificationsRequest *)request + completion:(PNPushNotificationsStateModificationCompletionBlock)block { + + PNLogAPICall(self.logger, @" Disable push notifications for device '%@'%@.", + request.pushToken, + request.pushType == PNAPNS2Push ? [NSString stringWithFormat:@" ('%@' topic in %@ environment)", + request.topic, + request.environment == PNAPNSDevelopment ? @"development" : @"production"] + : @""); + __weak __typeof(self) weakSelf = self; - [self processOperation:operationType - withParameters:parameters - completionBlock:^(PNStatus *status) { - + + [self performRequest:request withCompletion:^(PNAcknowledgmentStatus *status) { if (status.isError) { status.retryBlock = ^{ - [weakSelf enablePushNotification:shouldEnabled - onChannels:channels - withGateway:gateway - deviceToken:token - queryParameters:queryParameters - andCompletion:block]; + [weakSelf removeAllPushNotificationsWithRequest:request completion:block]; }; } - - [weakSelf callBlock:block status:YES withResult:nil andStatus:status]; + + block(status); }]; } @@ -222,50 +443,62 @@ - (void)enablePushNotification:(BOOL)shouldEnabled - (void)pushNotificationEnabledChannelsForDeviceWithPushToken:(NSData *)pushToken andCompletion:(PNPushNotificationsStateAuditCompletionBlock)block { - [self pushNotificationEnabledChannelsForGateway:@"apns" - withDeviceToken:pushToken - queryParameters:nil - andCompletion:block]; + [self pushNotificationEnabledChannelsForDeviceWithPushToken:pushToken + pushType:PNAPNSPush + andCompletion:block]; } -- (void)pushNotificationEnabledChannelsForGateway:(NSString *)gateway - withDeviceToken:(id)token - queryParameters:(NSDictionary *)queryParameters - andCompletion:(PNPushNotificationsStateAuditCompletionBlock)block { +- (void)pushNotificationEnabledChannelsForDeviceWithPushToken:(id)pushToken + pushType:(PNPushType)pushType + andCompletion:(PNPushNotificationsStateAuditCompletionBlock)block { + + [self pushNotificationEnabledChannelsForDeviceWithPushToken:pushToken + pushType:pushType + environment:PNAPNSDevelopment + topic:NSBundle.mainBundle.bundleIdentifier + andCompletion:block]; +} - PNRequestParameters *parameters = [PNRequestParameters new]; - NSString *deviceToken = token; - gateway = gateway ?: @"apns"; +- (void)pushNotificationEnabledChannelsForDeviceWithPushToken:(id)pushToken + pushType:(PNPushType)pushType + environment:(PNAPNSEnvironment)environment + topic:(NSString *)topic + andCompletion:(PNPushNotificationsStateAuditCompletionBlock)block { - [parameters addQueryParameters:@{@"type": gateway.lowercaseString}]; - [parameters addQueryParameters:queryParameters]; + PNAuditPushNotificationsRequest *request = nil; + request = [PNAuditPushNotificationsRequest requestWithDevicePushToken:pushToken + pushType:pushType]; - if ([gateway.lowercaseString isEqualToString:@"apns"] && ((NSData *)token).length) { - deviceToken = [PNData HEXFromDevicePushToken:token]; + if (pushType == PNAPNS2Push) { + request.environment = environment; + request.topic = topic; } - if (deviceToken.length) { - [parameters addPathComponent:deviceToken.lowercaseString forPlaceholder:@"{token}"]; - } - - PNLogAPICall(self.logger, @" Push notification enabled channels for device '%@'.", - deviceToken.lowercaseString); + [self pushNotificationEnabledChannelsWithRequest:request completion:block]; +} +- (void)pushNotificationEnabledChannelsWithRequest:(PNAuditPushNotificationsRequest *)request + completion:(PNPushNotificationsStateAuditCompletionBlock)block { + + PNLogAPICall(self.logger, @" Push notification enabled channels for device '%@'%@.", + request.pushToken, + request.pushType == PNAPNS2Push ? [NSString stringWithFormat:@" ('%@' topic in %@ environment)", + request.topic, + request.environment == PNAPNSDevelopment ? @"development" : @"production"] + : @""); + __weak __typeof(self) weakSelf = self; - [self processOperation:PNPushNotificationEnabledChannelsOperation - withParameters:parameters - completionBlock:^(PNResult *result, PNStatus *status) { - + + [self performRequest:request + withCompletion:^(PNAPNSEnabledChannelsResult *result, PNErrorStatus *status) { + if (status.isError) { status.retryBlock = ^{ - [weakSelf pushNotificationEnabledChannelsForGateway:gateway - withDeviceToken:token - queryParameters:queryParameters - andCompletion:block]; + [weakSelf pushNotificationEnabledChannelsWithRequest:request completion:block]; }; } - [weakSelf callBlock:block status:NO withResult:result andStatus:status]; + block(result, status); }]; } diff --git a/PubNub/Core/PubNub+Core.h b/PubNub/Core/PubNub+Core.h index 3a1c22705..a6ab29ced 100644 --- a/PubNub/Core/PubNub+Core.h +++ b/PubNub/Core/PubNub+Core.h @@ -18,7 +18,8 @@ NS_ASSUME_NONNULL_BEGIN * communication with \b PubNub service and share user-specified configuration. * * @author Serhii Mamontov - * @since 4.0 + * @version 4.12.0 + * @since 4.0.0 * @copyright © 2010-2019 PubNub, Inc. */ @interface PubNub : NSObject diff --git a/PubNub/Core/PubNub+Core.m b/PubNub/Core/PubNub+Core.m index cd83d6696..22d5ebd68 100644 --- a/PubNub/Core/PubNub+Core.m +++ b/PubNub/Core/PubNub+Core.m @@ -1,5 +1,7 @@ /** * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.0.0 * @copyright © 2010-2019 PubNub, Inc. */ #import "PubNub+CorePrivate.h" @@ -514,8 +516,8 @@ - (void)performRequest:(PNRequest *)request withCompletion:(id)block { [(PNStatus *)errorStatus updateCategory:PNBadRequestCategory]; } - if ([request.httpMethod isEqualToString:@"GET"]) { - requestCompletionBlock = ^(PNResult *result, PNStatus *status) { + if ([request.httpMethod isEqualToString:@"GET"] && request.returnsResponse) { + requestCompletionBlock = ^(PNResult *result, PNStatus *status) { [strongSelf callBlock:block status:NO withResult:result andStatus:status]; }; } else { @@ -525,7 +527,7 @@ - (void)performRequest:(PNRequest *)request withCompletion:(id)block { } if (errorStatus) { - if ([request.httpMethod isEqualToString:@"GET"]) { + if ([request.httpMethod isEqualToString:@"GET"] && request.returnsResponse) { [strongSelf callBlock:block status:NO withResult:nil andStatus:errorStatus]; } else { [strongSelf callBlock:block status:YES withResult:nil andStatus:errorStatus]; diff --git a/PubNub/Core/PubNub+History.m b/PubNub/Core/PubNub+History.m index fb40f2c14..2bfed808b 100644 --- a/PubNub/Core/PubNub+History.m +++ b/PubNub/Core/PubNub+History.m @@ -486,7 +486,8 @@ - (void)historyForChannels:(BOOL)multipleChannels } PNLogAPICall(self.logger, @" %@ for '%@' channel%@%@ with %@ limit%@.", - (shouldReverseOrder ? @"Reversed history" : @"History"), (channel?: @""), + (shouldReverseOrder && shouldReverseOrder.boolValue ? @"Reversed history" : @"History"), + (channel?: @""), (startDate ? [NSString stringWithFormat:@" from %@", startDate] : @""), (endDate ? [NSString stringWithFormat:@" to %@", endDate] : @""), @(limitValue), (shouldIncludeTimeToken.boolValue ? @" (including: message time tokens" : @"")); @@ -669,14 +670,20 @@ - (void)handleHistoryResult:(PNHistoryResult *)result withStatus:(PNErrorStatus *)status completion:(PNHistoryCompletionBlock)block { - if (result && result.serviceData[@"decryptError"]) { + if (result && (result.serviceData[@"decryptError"] || result.serviceData[@"apiError"])) { + PNStatusCategory category = result.serviceData[@"decryptError"] ? PNDecryptionErrorCategory + : PNAccessDeniedCategory; status = [PNErrorStatus statusForOperation:PNHistoryOperation - category:PNDecryptionErrorCategory + category:category withProcessingError:nil]; NSMutableDictionary *updatedData = [result.serviceData mutableCopy]; - [updatedData removeObjectsForKeys:@[@"decryptError", @"envelope"]]; - status.associatedObject = [PNHistoryData dataWithServiceResponse:updatedData]; + [updatedData removeObjectsForKeys:@[@"decryptError", @"apiError", @"envelope"]]; + + if (category == PNDecryptionErrorCategory) { + status.associatedObject = [PNHistoryData dataWithServiceResponse:updatedData]; + } + [status updateData:updatedData]; } diff --git a/PubNub/Data/Builders/API Call/APNS/PNAPNSAPICallBuilder.h b/PubNub/Data/Builders/API Call/APNS/PNAPNSAPICallBuilder.h index 325069493..df43dfec6 100644 --- a/PubNub/Data/Builders/API Call/APNS/PNAPNSAPICallBuilder.h +++ b/PubNub/Data/Builders/API Call/APNS/PNAPNSAPICallBuilder.h @@ -13,8 +13,9 @@ NS_ASSUME_NONNULL_BEGIN * @brief APNS API call builder. * * @author Serhii Mamontov + * @version 4.12.0 * @since 4.5.4 - * @copyright © 2010-2018 PubNub, Inc. + * @copyright © 2010-2019 PubNub, Inc. */ @interface PNAPNSAPICallBuilder : PNAPICallBuilder @@ -39,6 +40,15 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, readonly, strong) PNAPNSModificationAPICallBuilder * (^disable)(void); +/** + * @brief Push notifications state manipulation API access builder block. + * + * @return API call configuration builder. + * + * @since 4.12.0 + */ +@property (nonatomic, readonly, strong) PNAPNSModificationAPICallBuilder * (^disableAll)(void); + #pragma mark - APNS state audition diff --git a/PubNub/Data/Builders/API Call/APNS/PNAPNSAPICallBuilder.m b/PubNub/Data/Builders/API Call/APNS/PNAPNSAPICallBuilder.m index 9afe6e5e1..68871d3de 100644 --- a/PubNub/Data/Builders/API Call/APNS/PNAPNSAPICallBuilder.m +++ b/PubNub/Data/Builders/API Call/APNS/PNAPNSAPICallBuilder.m @@ -1,7 +1,8 @@ /** * @author Serhii Mamontov + * @version 4.12.0 * @since 4.5.4 - * @copyright © 2010-2018 PubNub, Inc. + * @copyright © 2010-2019 PubNub, Inc. */ #import "PNAPNSAPICallBuilder.h" #import "PNAPNSModificationAPICallBuilder.h" @@ -18,7 +19,6 @@ @implementation PNAPNSAPICallBuilder #pragma mark - Initialization + (void)initialize { - if (self == [PNAPNSAPICallBuilder class]) { [self copyMethodsFromClasses:@[[PNAPNSModificationAPICallBuilder class], [PNAPNSAuditAPICallBuilder class]]]; @@ -29,7 +29,6 @@ + (void)initialize { #pragma mark - APNS state manipulation - (PNAPNSModificationAPICallBuilder * (^)(void))enable { - return ^PNAPNSModificationAPICallBuilder * { object_setClass(self, [PNAPNSModificationAPICallBuilder class]); @@ -39,7 +38,15 @@ + (void)initialize { } - (PNAPNSModificationAPICallBuilder * (^)(void))disable { - + return ^PNAPNSModificationAPICallBuilder * { + object_setClass(self, [PNAPNSModificationAPICallBuilder class]); + + [self setFlag:NSStringFromSelector(_cmd)]; + return (PNAPNSModificationAPICallBuilder *)self; + }; +} + +- (PNAPNSModificationAPICallBuilder * (^)(void))disableAll { return ^PNAPNSModificationAPICallBuilder * { object_setClass(self, [PNAPNSModificationAPICallBuilder class]); @@ -52,7 +59,6 @@ + (void)initialize { #pragma mark - APNS state audition - (PNAPNSAuditAPICallBuilder * (^)(void))audit { - return ^PNAPNSAuditAPICallBuilder * { object_setClass(self, [PNAPNSAuditAPICallBuilder class]); diff --git a/PubNub/Data/Builders/API Call/APNS/PNAPNSAuditAPICallBuilder.h b/PubNub/Data/Builders/API Call/APNS/PNAPNSAuditAPICallBuilder.h index a749793c6..2c61e6a27 100644 --- a/PubNub/Data/Builders/API Call/APNS/PNAPNSAuditAPICallBuilder.h +++ b/PubNub/Data/Builders/API Call/APNS/PNAPNSAuditAPICallBuilder.h @@ -7,8 +7,9 @@ NS_ASSUME_NONNULL_BEGIN * @brief APNS state audit API call builder. * * @author Serhii Mamontov + * @version 4.12.0 * @since 4.5.4 - * @copyright © 2010-2018 PubNub, Inc. + * @copyright © 2010-2019 PubNub, Inc. */ @interface PNAPNSAuditAPICallBuilder : PNAPNSAPICallBuilder @@ -20,13 +21,15 @@ NS_ASSUME_NONNULL_BEGIN * * @note This method will forward call to 'apnsToken' block. * - * @param token Device push token against which search on \b PubNub service should be performed. + * @param token Device token / identifier against which search on \b PubNub service should be + * performed. Depending from passed \c pushType should be \a NSData (for \b PNAPNS2Push and + * \b PNAPNSPush) or \a NSString for other. * * @return API call configuration builder. * - * @since 4.5.4 + * @since 4.12.0 */ -@property (nonatomic, readonly, strong) PNAPNSAuditAPICallBuilder * (^token)(NSData *token); +@property (nonatomic, readonly, strong) PNAPNSAuditAPICallBuilder * (^token)(id token); /** * @brief Device APNS push token addition block. @@ -38,7 +41,9 @@ NS_ASSUME_NONNULL_BEGIN * * @since 4.8.9 */ -@property (nonatomic, readonly, strong) PNAPNSAuditAPICallBuilder * (^apnsToken)(NSData *token); +@property (nonatomic, readonly, strong) PNAPNSAuditAPICallBuilder * (^apnsToken)(NSData *token) + DEPRECATED_MSG_ATTRIBUTE("This method will be deprecated after 4.12.0. Instead please use " + "'token' along with 'pushType' set to 'PNAPNSPush'."); /** * @brief Device FCM push token addition block. @@ -50,7 +55,50 @@ NS_ASSUME_NONNULL_BEGIN * * @since 4.8.9 */ -@property (nonatomic, readonly, strong) PNAPNSAuditAPICallBuilder * (^fcmToken)(NSString *token); +@property (nonatomic, readonly, strong) PNAPNSAuditAPICallBuilder * (^fcmToken)(NSString *token) + DEPRECATED_MSG_ATTRIBUTE("This method will be deprecated after 4.12.0. Instead please use " + "'token' along with 'pushType' set to 'PNFCMPush'."); + +/** + * @brief Environment in which channel notifications managed. + * + * @note This field works only if request initialized with \c pushType set to \b PNAPNS2Push + * (by default set to \b PNAPNSDevelopment). + * + * @param environment One of \b PNAPNSEnvironment fields which specify environment within which + * device should manage list of channels with enabled notifications. + * + * @return API call configuration builder. + * + * @since 4.12.0 + */ +@property (nonatomic, readonly, strong) PNAPNSAuditAPICallBuilder * (^environment)(PNAPNSEnvironment environment); + +/** + * @brief Push notifications service. + * + * @param pushType One of \b PNPushType fields which specify spervide to manage notifications for + * device specified with \c pushToken. + * + * @return API call configuration builder. + * + * @since 4.12.0 + */ +@property (nonatomic, readonly, strong) PNAPNSAuditAPICallBuilder * (^pushType)(PNPushType pushType); + +/** + * @brief Notifications topic name. + * + * @note This field works only if request initialized with \c pushType set to \b PNAPNS2Push + * (by default set to \b NSBundle.mainBundle.bundleIdentifier). + * + * @param environment Notifications topic name (usually it is application's bundle identifier) + * + * @return API call configuration builder. + * + * @since 4.12.0 + */ + @property (nonatomic, readonly, strong) PNAPNSAuditAPICallBuilder *(^topic)(NSString *topic); #pragma mark - Execution diff --git a/PubNub/Data/Builders/API Call/APNS/PNAPNSAuditAPICallBuilder.m b/PubNub/Data/Builders/API Call/APNS/PNAPNSAuditAPICallBuilder.m index ee96f3ef2..a2954def4 100644 --- a/PubNub/Data/Builders/API Call/APNS/PNAPNSAuditAPICallBuilder.m +++ b/PubNub/Data/Builders/API Call/APNS/PNAPNSAuditAPICallBuilder.m @@ -1,7 +1,8 @@ /** * @author Serhii Mamontov + * @version 4.12.0 * @since 4.5.4 - * @copyright © 2010-2018 PubNub, Inc. + * @copyright © 2010-2019 PubNub, Inc. */ #import "PNAPNSAuditAPICallBuilder.h" #import "PNAPICallBuilder+Private.h" @@ -19,32 +20,53 @@ @implementation PNAPNSAuditAPICallBuilder #pragma mark - Configuration -- (PNAPNSAuditAPICallBuilder * (^)(NSData *token))token { - - return self.apnsToken; -} - -- (PNAPNSAuditAPICallBuilder * (^)(NSData *token))apnsToken { - - return ^PNAPNSAuditAPICallBuilder * (NSData *token) { +- (PNAPNSAuditAPICallBuilder * (^)(id token))token { + return ^PNAPNSAuditAPICallBuilder * (id token) { [self setValue:token forParameter:NSStringFromSelector(_cmd)]; return self; }; } +- (PNAPNSAuditAPICallBuilder * (^)(NSData *token))apnsToken { + return self.pushType(PNAPNSPush).token; +} + - (PNAPNSAuditAPICallBuilder * (^)(NSString *token))fcmToken { - + return self.pushType(PNFCMPush).token; +} + +- (PNAPNSAuditAPICallBuilder * (^)(NSString *token))mpnsToken { return ^PNAPNSAuditAPICallBuilder * (NSString *token) { [self setValue:token forParameter:NSStringFromSelector(_cmd)]; return self; }; } +- (PNAPNSAuditAPICallBuilder * (^)(PNAPNSEnvironment environment))environment { + return ^PNAPNSAuditAPICallBuilder * (PNAPNSEnvironment environment) { + [self setValue:@(environment) forParameter:NSStringFromSelector(_cmd)]; + return self; + }; +} + +- (PNAPNSAuditAPICallBuilder * (^)(PNPushType pushType))pushType { + return ^PNAPNSAuditAPICallBuilder * (PNPushType pushType) { + [self setValue:@(pushType) forParameter:NSStringFromSelector(_cmd)]; + return self; + }; +} + +- (PNAPNSAuditAPICallBuilder * (^)(NSString *topic))topic { + return ^PNAPNSAuditAPICallBuilder * (NSString *topic) { + [self setValue:topic forParameter:NSStringFromSelector(_cmd)]; + return self; + }; +} + #pragma mark - Execution - (void(^)(PNPushNotificationsStateAuditCompletionBlock block))performWithCompletion { - return ^(PNPushNotificationsStateAuditCompletionBlock block) { [super performWithBlock:block]; }; diff --git a/PubNub/Data/Builders/API Call/APNS/PNAPNSModificationAPICallBuilder.h b/PubNub/Data/Builders/API Call/APNS/PNAPNSModificationAPICallBuilder.h index 6dd1c5313..2f36dec7f 100644 --- a/PubNub/Data/Builders/API Call/APNS/PNAPNSModificationAPICallBuilder.h +++ b/PubNub/Data/Builders/API Call/APNS/PNAPNSModificationAPICallBuilder.h @@ -7,8 +7,9 @@ NS_ASSUME_NONNULL_BEGIN * @brief APNS state modification API call builder. * * @author Serhii Mamontov + * @version 4.12.0 * @since 4.5.4 - * @copyright © 2010-2018 PubNub, Inc. + * @copyright © 2010-2019 PubNub, Inc. */ @interface PNAPNSModificationAPICallBuilder : PNAPNSAPICallBuilder @@ -16,18 +17,17 @@ NS_ASSUME_NONNULL_BEGIN #pragma mark - Configuration /** - * @brief Device push token addition block. + * @brief Device token / identifier addition block. * - * @note This method will forward call to 'apnsToken' block. - * - * @param token Device push token which should be used to change notifications state on specified - * set of channels. + * @param token Device token / identifier which should be used to change notifications state on + * specified set of channels. Depending from passed \c pushType should be \a NSData (for + * \b PNAPNS2Push and \b PNAPNSPush) or \a NSString for other. * * @return API call configuration builder. * - * @since 4.5.4 + * @since 4.12.0 */ -@property (nonatomic, readonly, strong) PNAPNSModificationAPICallBuilder * (^token)(NSData *token); +@property (nonatomic, readonly, strong) PNAPNSModificationAPICallBuilder * (^token)(id token); /** * @brief Device APNS push token addition block. @@ -39,7 +39,9 @@ NS_ASSUME_NONNULL_BEGIN * * @since 4.8.9 */ -@property (nonatomic, readonly, strong) PNAPNSModificationAPICallBuilder * (^apnsToken)(NSData *token); +@property (nonatomic, readonly, strong) PNAPNSModificationAPICallBuilder * (^apnsToken)(NSData *token) + DEPRECATED_MSG_ATTRIBUTE("This method will be deprecated after 4.12.0. Instead please use " + "'token' along with 'pushType' set to 'PNAPNSPush'."); /** * @brief Device FCM push token addition block. @@ -51,7 +53,9 @@ NS_ASSUME_NONNULL_BEGIN * * @since 4.8.9 */ -@property (nonatomic, readonly, strong) PNAPNSModificationAPICallBuilder * (^fcmToken)(NSString *token); +@property (nonatomic, readonly, strong) PNAPNSModificationAPICallBuilder * (^fcmToken)(NSString *token) + DEPRECATED_MSG_ATTRIBUTE("This method will be deprecated after 4.12.0. Instead please use " + "'token' along with 'pushType' set to 'PNFCMPush'."); /** * @brief List of target channels addition block. @@ -67,6 +71,47 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, readonly, strong) PNAPNSModificationAPICallBuilder *(^channels)(NSArray * _Nullable channels); +/** + * @brief Environment in which channel notifications managed. + * + * @note This field works only if request initialized with \c pushType set to \b PNAPNS2Push + * (by default set to \b PNAPNSDevelopment). + * + * @param environment One of \b PNAPNSEnvironment fields which specify environment within which + * device should manage list of channels with enabled notifications. + * + * @return API call configuration builder. + * + * @since 4.12.0 + */ +@property (nonatomic, readonly, strong) PNAPNSModificationAPICallBuilder * (^environment)(PNAPNSEnvironment environment); + +/** + * @brief Push notifications service. + * + * @param pushType One of \b PNPushType fields which specify service to manage notifications for + * device specified with \c pushToken (will be set to \b PNAPNSPush by default). + * + * @return API call configuration builder. + * + * @since 4.12.0 + */ +@property (nonatomic, readonly, strong) PNAPNSModificationAPICallBuilder * (^pushType)(PNPushType pushType); + +/** + * @brief Notifications topic name. + * + * @note This field works only if request initialized with \c pushType set to \b PNAPNS2Push + * (by default set to \b NSBundle.mainBundle.bundleIdentifier). + * + * @param environment Notifications topic name (usually it is application's bundle identifier) + * + * @return API call configuration builder. + * + * @since 4.12.0 + */ + @property (nonatomic, readonly, strong) PNAPNSModificationAPICallBuilder *(^topic)(NSString *topic); + #pragma mark - Execution diff --git a/PubNub/Data/Builders/API Call/APNS/PNAPNSModificationAPICallBuilder.m b/PubNub/Data/Builders/API Call/APNS/PNAPNSModificationAPICallBuilder.m index ad3105b1c..7e10d332a 100644 --- a/PubNub/Data/Builders/API Call/APNS/PNAPNSModificationAPICallBuilder.m +++ b/PubNub/Data/Builders/API Call/APNS/PNAPNSModificationAPICallBuilder.m @@ -1,7 +1,8 @@ /** * @author Serhii Mamontov + * @version 4.12.0 * @since 4.5.4 - * @copyright © 2010-2018 PubNub, Inc. + * @copyright © 2010-2019 PubNub, Inc. */ #import "PNAPNSModificationAPICallBuilder.h" #import "PNAPICallBuilder+Private.h" @@ -19,40 +20,53 @@ @implementation PNAPNSModificationAPICallBuilder #pragma mark - Configuration -- (PNAPNSModificationAPICallBuilder * (^)(NSData *token))token { - - return self.apnsToken; -} - -- (PNAPNSModificationAPICallBuilder * (^)(NSData *token))apnsToken { - - return ^PNAPNSModificationAPICallBuilder * (NSData *token) { +- (PNAPNSModificationAPICallBuilder * (^)(id token))token { + return ^PNAPNSModificationAPICallBuilder * (id token) { [self setValue:token forParameter:NSStringFromSelector(_cmd)]; return self; }; } +- (PNAPNSModificationAPICallBuilder * (^)(NSData *token))apnsToken { + return self.pushType(PNAPNSPush).token; +} + - (PNAPNSModificationAPICallBuilder * (^)(NSString *token))fcmToken { - - return ^PNAPNSModificationAPICallBuilder * (NSString *token) { - [self setValue:token forParameter:NSStringFromSelector(_cmd)]; - return self; - }; + return self.pushType(PNFCMPush).token; } - (PNAPNSModificationAPICallBuilder * (^)(NSArray *channels))channels { - return ^PNAPNSModificationAPICallBuilder * (NSArray *channels) { [self setValue:channels forParameter:NSStringFromSelector(_cmd)]; return self; }; } +- (PNAPNSModificationAPICallBuilder * (^)(PNAPNSEnvironment environment))environment { + return ^PNAPNSModificationAPICallBuilder * (PNAPNSEnvironment environment) { + [self setValue:@(environment) forParameter:NSStringFromSelector(_cmd)]; + return self; + }; +} + +- (PNAPNSModificationAPICallBuilder * (^)(PNPushType pushType))pushType { + return ^PNAPNSModificationAPICallBuilder * (PNPushType pushType) { + [self setValue:@(pushType) forParameter:NSStringFromSelector(_cmd)]; + return self; + }; +} + +- (PNAPNSModificationAPICallBuilder * (^)(NSString *topic))topic { + return ^PNAPNSModificationAPICallBuilder * (NSString *topic) { + [self setValue:topic forParameter:NSStringFromSelector(_cmd)]; + return self; + }; +} + #pragma mark - Execution - (void(^)(PNPushNotificationsStateModificationCompletionBlock block))performWithCompletion { - return ^(PNPushNotificationsStateModificationCompletionBlock block) { [super performWithBlock:block]; }; diff --git a/PubNub/Data/Managers/PNPublishSequence.m b/PubNub/Data/Managers/PNPublishSequence.m index d2b0a06e7..99c11ca2e 100644 --- a/PubNub/Data/Managers/PNPublishSequence.m +++ b/PubNub/Data/Managers/PNPublishSequence.m @@ -22,11 +22,7 @@ #pragma mark Static -/** - * @brief Key under which in Keychain stored information about previously used sequence number for - * message publish. - */ -static NSString * const kPNPublishSequenceDataKey = @"pn_publishSequence"; +NSString * const kPNPublishSequenceDataKey = @"pn_publishSequence"; /** * @brief Maximum age of \c publish key inactivity after which it will be removed and count for it diff --git a/PubNub/Data/Managers/PNTelemetry.h b/PubNub/Data/Managers/PNTelemetry.h index 612735583..e0d114a96 100644 --- a/PubNub/Data/Managers/PNTelemetry.h +++ b/PubNub/Data/Managers/PNTelemetry.h @@ -10,10 +10,9 @@ NS_ASSUME_NONNULL_BEGIN * * @discussion Track various client parameters which can be used for service performance analysis. * - * @since 4.6.2 - * * @author Serhii Mamontov - * @version 4.8.4 + * @version 4.12.0 + * @since 4.6.2 * @copyright © 2010-2019 PubNub, Inc. */ @interface PNTelemetry : NSObject diff --git a/PubNub/Data/Managers/PNTelemetry.m b/PubNub/Data/Managers/PNTelemetry.m index f5ac2db31..cc14a684b 100644 --- a/PubNub/Data/Managers/PNTelemetry.m +++ b/PubNub/Data/Managers/PNTelemetry.m @@ -1,5 +1,7 @@ /** * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.6.2 * @copyright © 2010-2019 PubNub, Inc. */ #import "PNTelemetry.h" @@ -242,6 +244,10 @@ - (NSString *)endpointNameForOperation:(PNOperationType)operationType { case PNAddPushNotificationsOnChannelsOperation: case PNRemovePushNotificationsFromChannelsOperation: case PNRemoveAllPushNotificationsOperation: + case PNPushNotificationEnabledChannelsV2Operation: + case PNAddPushNotificationsOnChannelsV2Operation: + case PNRemovePushNotificationsFromChannelsV2Operation: + case PNRemoveAllPushNotificationsV2Operation: operation = @"push"; break; case PNCreateUserOperation: diff --git a/PubNub/Data/PNConfiguration.m b/PubNub/Data/PNConfiguration.m index 245fc2731..a535ae5d2 100644 --- a/PubNub/Data/PNConfiguration.m +++ b/PubNub/Data/PNConfiguration.m @@ -3,6 +3,9 @@ * @copyright © 2010-2019 PubNub, Inc. */ #import +#import +#import "PNPrivateStructures.h" +#import "PNKeychain+Private.h" #if TARGET_OS_IOS #import #elif TARGET_OS_OSX @@ -14,16 +17,11 @@ #endif // TARGET_OS_OSX #import "PNConfiguration.h" #import "PNConstants.h" -#import "PNKeychain.h" #pragma mark Static -/** - * @brief Key under which device ID will be stored persistently. - */ -static NSString * const kPNConfigurationDeviceIDKey = @"PNConfigurationDeviceID"; - +NSString * const kPNConfigurationDeviceIDKey = @"PNConfigurationDeviceID"; NSString * const kPNConfigurationUUIDKey = @"PNConfigurationUUID"; @@ -139,6 +137,10 @@ + (instancetype)configurationWithPublishKey:(NSString *)publishKey - (instancetype)initWithPublishKey:(NSString *)publishKey subscribeKey:(NSString *)subscribeKey { if ((self = [super init])) { + [PNKeychain updateEntries:@[kPNConfigurationUUIDKey, kPNConfigurationDeviceIDKey, kPNPublishSequenceDataKey] + accessibilityTo:kSecAttrAccessibleAfterFirstUnlock]; + + _deviceID = [[self uniqueDeviceIdentifier] copy]; if (NSClassFromString(@"XCTestExpectation")) { diff --git a/PubNub/Data/PNKeychain+Private.h b/PubNub/Data/PNKeychain+Private.h new file mode 100644 index 000000000..b1acd0c9e --- /dev/null +++ b/PubNub/Data/PNKeychain+Private.h @@ -0,0 +1,32 @@ +#import "PNKeychain.h" + + +NS_ASSUME_NONNULL_BEGIN + +#pragma mark Private interface declaration + +/** + * @brief Keychain private extension which provides maintenance methods. + * + * @author Serhii Mamontov + * @copyright © 2010-2019 PubNub, Inc. + */ +@interface PNKeychain (Private) + + +#pragma mark - Misc + +/** + * @brief Update accessibility for entries specified by list of keys. + * + * @param entryNames List of entry names for which current accessibility should be changed. + * @param accessibility Target entries accessibility mode. + */ ++ (void)updateEntries:(NSArray *)entryNames accessibilityTo:(CFStringRef)accessibility; + +#pragma mark - + + +@end + +NS_ASSUME_NONNULL_END diff --git a/PubNub/Data/PNKeychain.m b/PubNub/Data/PNKeychain.m index 232abf40d..4e78198d6 100644 --- a/PubNub/Data/PNKeychain.m +++ b/PubNub/Data/PNKeychain.m @@ -2,7 +2,7 @@ * @author Serhii Mamontov * @copyright © 2010-2019 PubNub, Inc. */ -#import "PNKeychain.h" +#import "PNKeychain+Private.h" #import #import "PNHelpers.h" @@ -423,6 +423,42 @@ + (id)unpackedData:(NSData *)data { #pragma mark - Misc ++ (void)updateEntries:(NSArray *)entryNames accessibilityTo:(CFStringRef)accessibility { + for (NSString *entryKey in entryNames) { + NSMutableDictionary *query = [self baseInformationForItemWithKey:entryKey]; + query[(__bridge id)kSecReturnAttributes] = (__bridge id)(kCFBooleanTrue); + query[(__bridge id)kSecReturnData] = (__bridge id)kCFBooleanTrue; + [query removeObjectForKey:(__bridge id)(kSecAttrAccessible)]; + CFDictionaryRef searchedItem = NULL; + id data = nil; + + OSStatus searchStatus = SecItemCopyMatching((__bridge CFDictionaryRef)query, + (CFTypeRef *)&searchedItem); + + if (searchedItem && searchStatus == errSecSuccess) { + NSDictionary *entryAttributes = (__bridge NSDictionary *)searchedItem; + NSString *itemAccessibility = entryAttributes[(__bridge id)(kSecAttrAccessible)]; + + if (![itemAccessibility isEqualToString:(__bridge id)accessibility]) { + if (CFDictionaryContainsKey(searchedItem, kSecValueData)) { + NSData *packedData = ((__bridge NSDictionary *)searchedItem)[(__bridge id)kSecValueData]; + data = [self unpackedData:packedData]; + } + + SecItemDelete((__bridge CFDictionaryRef)query); + } + + if (data) { + [self storeValue:data forKey:entryKey withCompletionBlock:nil]; + } + } + + if (searchedItem) { + CFRelease(searchedItem); + } + } +} + + (NSString *)fileBasedStoragePath { static NSString *_fileBasedStoragePath; @@ -476,7 +512,7 @@ + (NSMutableDictionary *)baseInformationForItemWithKey:(NSString *)key { query[(__bridge id)(kSecClass)] = (__bridge id)(kSecClassGenericPassword); query[(__bridge id)(kSecAttrSynchronizable)] = (__bridge id)(kCFBooleanFalse); - query[(__bridge id)(kSecAttrAccessible)] = (__bridge id)(kSecAttrAccessibleAlways); + query[(__bridge id)(kSecAttrAccessible)] = (__bridge id)(kSecAttrAccessibleAfterFirstUnlock); query[(__bridge id)(kSecAttrService)] = bundleIdentifier; query[(__bridge id)(kSecAttrAccount)] = key; diff --git a/PubNub/Data/Service Objects/PNStatus.m b/PubNub/Data/Service Objects/PNStatus.m index 799ef59ba..997a01f1f 100644 --- a/PubNub/Data/Service Objects/PNStatus.m +++ b/PubNub/Data/Service Objects/PNStatus.m @@ -103,6 +103,8 @@ - (void)setCategory:(PNStatusCategory)category { _category == PNDisconnectedCategory || _category == PNUnexpectedDisconnectCategory) { self.error = NO; + } else if (_category == PNBadRequestCategory) { + self.statusCode = 400; } } diff --git a/PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationConfiguration+Private.h b/PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationConfiguration+Private.h new file mode 100644 index 000000000..160dce8b0 --- /dev/null +++ b/PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationConfiguration+Private.h @@ -0,0 +1,24 @@ +#import "PNAPNSNotificationConfiguration.h" + + +NS_ASSUME_NONNULL_BEGIN + +#pragma mark Private interface declaration + +@interface PNAPNSNotificationConfiguration (Private) + + +#pragma mark - Misc + +/** + * @brief Translate user-provided information into payload which can be consumed by \b PubNub mobile + * notification service and delivered to target devices. + */ +- (NSDictionary *)dictionaryRepresentation; + +#pragma mark - + + +@end + +NS_ASSUME_NONNULL_END diff --git a/PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationConfiguration.h b/PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationConfiguration.h new file mode 100644 index 000000000..965cfac82 --- /dev/null +++ b/PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationConfiguration.h @@ -0,0 +1,65 @@ +#import +#import "PNAPNSNotificationTarget.h" + + +NS_ASSUME_NONNULL_BEGIN + +#pragma mark Interface declaration + +/** + * @brief APNS over HTTP/2 delivery configuration. + * + * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.12.0 + * @copyright © 2010-2019 PubNub, Inc. + */ +@interface PNAPNSNotificationConfiguration : NSObject + + +#pragma mark - Initialization & Configuration + +/** + * @brief Create and configure default APNS over HTTP/2 notification configuration. + * + * @discussion Default configuration will be created for single target in \b PNAPNSDevelopment + * environment and \b NSBundle.mainBundle.bundleIdentifier as topic name. + * + * @return Configured and ready to use APNS over HTTP/2 notification configuration. + */ ++ (instancetype)defaultConfiguration; + +/** + * @brief Create and configure APNS over HTTP/2 notification configuration. + * + * @param targets List of topics which should receive this notification. + * Default target with \b NSBundle.mainBundle.bundleIdentifier topic and \b PNAPNSDevelopment + * environment will be used if list is empty. + * + * @return Configured and ready to use APNS over HTTP/2 notification configuration. + */ ++ (instancetype)configurationWithTargets:(NSArray *)targets; + +/** + * @brief Create and configure APNS over HTTP/2 notification configuration. + * + * @param collapseId Notification group / collapse identifier. + * Value will be used in APNs POST request as \a apns-collapse-id header value. + * @param date Date till which APNS will try to deliver notification to target device. + * Value will be used in APNs POST request as \a apns-expiration header value. + * @param targets List of topics which should receive this notification. + * Default target with \b NSBundle.mainBundle.bundleIdentifier topic and \b PNAPNSDevelopment + * environment will be used if list is empty. + * + * @return Configured and ready to use APNS over HTTP/2 notification configuration. + */ ++ (instancetype)configurationWithCollapseID:(nullable NSString *)collapseId + expirationDate:(nullable NSDate *)date + targets:(NSArray *)targets; + +#pragma mark - + + +@end + +NS_ASSUME_NONNULL_END diff --git a/PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationConfiguration.m b/PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationConfiguration.m new file mode 100644 index 000000000..cae5e62c3 --- /dev/null +++ b/PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationConfiguration.m @@ -0,0 +1,134 @@ +/** + * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.12.0 + * @copyright © 2010-2019 PubNub, Inc. + */ +#import "PNAPNSNotificationConfiguration+Private.h" +#import "PNAPNSNotificationTarget+Private.h" +#import "PNHelpers.h" + + +NS_ASSUME_NONNULL_BEGIN + +#pragma mark Protected interface declaration + +@interface PNAPNSNotificationConfiguration () + + +#pragma mark - Information + +/** + * @brief List of topics which should receive this notification. + */ +@property (nonatomic, nullable, strong) NSArray *targets; + +/** + * @brief Notification group / collapse identifier. + * + * @note Value will be used in APNs POST request as \a apns-collapse-id header value. + */ +@property (nonatomic, nullable, copy) NSString *collapseId; + +/** + * @brief Date till which APNS will try to deliver notification to target device. + * + * @note Value will be used in APNs POST request as \a apns-expiration header value. + */ +@property (nonatomic, nullable, strong) NSDate *date; + + +#pragma mark - Initialization & Configuration + +/** + * @brief Create and configure APNS over HTTP/2 notification configuration. + * + * @param collapseId Notification group / collapse identifier. + * Value will be used in APNs POST request as \a apns-collapse-id header value. + * @param date Date till which APNS will try to deliver notification to target device. + * Value will be used in APNs POST request as \a apns-expiration header value. + * @param targets List of topics which should receive this notification. + * + * @return Configured and ready to use APNS over HTTP/2 notification configuration. + */ +- (instancetype)initWithCollapseID:(nullable NSString *)collapseId + expirationDate:(nullable NSDate *)date + targets:(NSArray *)targets; + +#pragma mark - + + +@end + +NS_ASSUME_NONNULL_END + + +#pragma mark - Interface implementation + +@implementation PNAPNSNotificationConfiguration + + +#pragma mark - Initialization & Configuration + ++ (instancetype)defaultConfiguration { + return [self configurationWithTargets:@[[PNAPNSNotificationTarget defaultTarget]]]; +} + ++ (instancetype)configurationWithTargets:(NSArray *)targets { + return [self configurationWithCollapseID:nil expirationDate:nil targets:targets]; +} + ++ (instancetype)configurationWithCollapseID:(NSString *)collapseId + expirationDate:(NSDate *)date + targets:(NSArray *)targets { + + return [[self alloc] initWithCollapseID:collapseId expirationDate:date targets:targets]; +} + +- (instancetype)initWithCollapseID:(NSString *)collapseId + expirationDate:(NSDate *)date + targets:(NSArray *)targets { + + if ((self = [super init])) { + _targets = targets.count ? targets : @[[PNAPNSNotificationTarget defaultTarget]]; + _collapseId = [collapseId copy]; + _date = date; + } + + return self; +} + + +#pragma mark - Misc + +- (NSDictionary *)dictionaryRepresentation { + NSArray *configurationTargets = self.targets; + NSMutableArray *targets = [NSMutableArray new]; + NSMutableDictionary *dictionary = [@{ + @"auth_method": @"token", + @"targets": targets, + @"version": @"v2" + } mutableCopy]; + + if (self.collapseId.length) { + dictionary[@"collapse_id"] = self.collapseId; + } + + if (self.date) { + dictionary[@"expiration"] = [PNDate RFC3339StringFromDate:self.date]; + } + + [configurationTargets enumerateObjectsUsingBlock:^(PNAPNSNotificationTarget *target, + __unused NSUInteger idx, + __unused BOOL *stop) { + + [targets addObject:[target dictionaryRepresentation]]; + }]; + + return dictionary; +} + +#pragma mark - + + +@end diff --git a/PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationPayload+Private.h b/PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationPayload+Private.h new file mode 100644 index 000000000..2cd828996 --- /dev/null +++ b/PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationPayload+Private.h @@ -0,0 +1,24 @@ +#import "PNAPNSNotificationPayload.h" + + +NS_ASSUME_NONNULL_BEGIN + +#pragma mark Private interface declaration + +@interface PNAPNSNotificationPayload (Private) + + +#pragma mark - Information + +/** + * @brief APNS or APNS over HTTP/2 push type. + */ +@property (nonatomic, assign) PNPushType apnsPushType; + + +#pragma mark - + + +@end + +NS_ASSUME_NONNULL_END diff --git a/PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationPayload.h b/PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationPayload.h new file mode 100644 index 000000000..c9ddfbb97 --- /dev/null +++ b/PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationPayload.h @@ -0,0 +1,49 @@ +#import +#import "PNAPNSNotificationConfiguration.h" +#import "PNBaseNotificationPayload.h" + + +NS_ASSUME_NONNULL_BEGIN + +#pragma mark Interface declaration + +/** + * @brief APNS notification payload builder. + * + * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.12.0 + * @copyright © 2010-2019 PubNub, Inc. + */ +@interface PNAPNSNotificationPayload : PNBaseNotificationPayload + + +#pragma mark - Information + +/** + * @brief List of APNS over HTTP/2 delivery configurations. + * + * @note If list is empty when payload for \b PNAPNS2Push has been requested, it will create default + * configuration for In case if payload will be requested for \b PNAPNSDevelopment environment and + * \b NSBundle.mainBundle.bundleIdentifier as topic name. + */ +@property (nonatomic, strong) NSArray *configurations; + +/** + * @brief Object with parameters which specify user-visible key-value pairs. + */ +@property (nonatomic, readonly, strong) NSMutableDictionary *notification; + +/** + * @brief Whether operation system should handle notification layout by default or not. + * + * @note \c alert, \c sound and \c badge will be removed from resulting payload if set to \c YES. + */ +@property (nonatomic, assign, getter=isSilent) BOOL silent; + +#pragma mark - + + +@end + +NS_ASSUME_NONNULL_END diff --git a/PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationPayload.m b/PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationPayload.m new file mode 100644 index 000000000..cd660fe01 --- /dev/null +++ b/PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationPayload.m @@ -0,0 +1,115 @@ +/** + * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.12.0 + * @copyright © 2010-2019 PubNub, Inc. +*/ +#import "PNAPNSNotificationConfiguration+Private.h" +#import "PNBaseNotificationPayload+Private.h" +#import "PNAPNSNotificationPayload+Private.h" + + +NS_ASSUME_NONNULL_BEGIN + +#pragma mark Protected interface declaration + +@interface PNAPNSNotificationPayload () + +/** + * @brief APNS or APNS over HTTP/2 push type. + */ +@property (nonatomic, assign) PNPushType apnsPushType; + +#pragma mark - + + +@end + +NS_ASSUME_NONNULL_END + + +#pragma mark - Interface implementation + +@implementation PNAPNSNotificationPayload + + +#pragma mark - Information + +- (NSMutableDictionary *)notification { + return self.payload[@"aps"]; +} + +- (void)setTitle:(NSString *)title { + self.payload[@"aps"][@"alert"][@"title"] = [title copy]; +} + +- (void)setSubtitle:(NSString *)subtitle { + self.payload[@"aps"][@"alert"][@"subtitle"] = [subtitle copy]; +} + +- (void)setBody:(NSString *)body { + self.payload[@"aps"][@"alert"][@"body"] = [body copy]; +} + +- (void)setBadge:(NSNumber *)badge { + self.payload[@"aps"][@"badge"] = [badge copy]; +} + +- (void)setSound:(NSString *)sound { + self.payload[@"aps"][@"sound"] = [sound copy]; +} + + +#pragma mark - Initialization & Configuration + +- (void)setDefaultPayloadStructure { + self.payload[@"aps"] = [NSMutableDictionary new]; + self.payload[@"aps"][@"alert"] = [NSMutableDictionary new]; +} + + +#pragma mark - Misc + +- (NSDictionary *)dictionaryRepresentation { + NSMutableDictionary *payload = [self.payload mutableCopy]; + NSMutableDictionary *aps = payload[@"aps"]; + NSMutableDictionary *alert = aps[@"alert"]; + + if (self.isSilent) { + payload[@"aps"][@"content-available"] = @1; + } + + if (self.apnsPushType == PNAPNS2Push) { + NSArray *configurations = self.configurations; + NSMutableArray *serializedConfigurations = [NSMutableArray new]; + + if (!configurations.count) { + configurations = @[[PNAPNSNotificationConfiguration defaultConfiguration]]; + } + + [configurations enumerateObjectsUsingBlock:^(PNAPNSNotificationConfiguration *configuration, + __unused NSUInteger idx, + __unused BOOL *stop) { + + [serializedConfigurations addObject:[configuration dictionaryRepresentation]]; + }]; + + payload[@"pn_push"] = serializedConfigurations; + } + + if (!alert.count) { + [aps removeObjectForKey:@"alert"]; + } + + if (self.isSilent) { + [alert removeAllObjects]; + [aps removeObjectsForKeys:@[@"alert", @"badge", @"sound"]]; + } + + return self.isSilent || alert.count ? payload : nil; +} + +#pragma mark - + + +@end diff --git a/PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationTarget+Private.h b/PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationTarget+Private.h new file mode 100644 index 000000000..a24cf66d9 --- /dev/null +++ b/PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationTarget+Private.h @@ -0,0 +1,24 @@ +#import "PNAPNSNotificationTarget.h" + + +NS_ASSUME_NONNULL_BEGIN + +#pragma mark Private interface declaration + +@interface PNAPNSNotificationTarget (Private) + + +#pragma mark - Misc + +/** + * @brief Translate user-provided information into payload which can be consumed by \b PubNub mobile + * notification service and delivered to target devices. + */ +- (NSDictionary *)dictionaryRepresentation; + +#pragma mark - + + +@end + +NS_ASSUME_NONNULL_END diff --git a/PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationTarget.h b/PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationTarget.h new file mode 100644 index 000000000..6d6aa3ec4 --- /dev/null +++ b/PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationTarget.h @@ -0,0 +1,60 @@ +#import +#import "PNStructures.h" + + +NS_ASSUME_NONNULL_BEGIN + +#pragma mark Interface declaration + +/** + * @brief APNS notification target . + * + * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.12.0 + * @copyright © 2010-2019 PubNub, Inc. +*/ +@interface PNAPNSNotificationTarget : NSObject + + +#pragma mark - Initialization & Configuration + +/** + * @brief Create and configure default notification configuration. + * + * @discussion Default configuration will be created for single target in \b PNAPNSDevelopment + * environment and \b NSBundle.mainBundle.bundleIdentifier as topic name. + * + * @return Configured and ready to use notification target. + */ ++ (instancetype)defaultTarget; + +/** + * @brief Create and configure notification target for \b PNAPNSDevelopment environment. + * + * @param topic Notifications topic name (usually it is application's bundle identifier). + * Value will be used in APNs POST request as \a apns-topic header value. + * + * @return Configured and ready to use notification target. + */ ++ (instancetype)targetForTopic:(NSString *)topic; + +/** + * @brief Create and configure notification target. + * + * @param topic Notifications topic name (usually it is application's bundle identifier). + * Value will be used in APNs POST request as \a apns-topic header value. + * @param environment One of \b PNAPNSEnvironment fields which specify environment within which + * registered devices to which notifications should be delivered. + * @param excludedDevices List of devices (their push tokens) to which this notification shouldn't + * be delivered. + * + * @return Configured and ready to use notification target. + */ ++ (instancetype)targetForTopic:(NSString *)topic + inEnvironment:(PNAPNSEnvironment)environment + withExcludedDevices:(nullable NSArray *)excludedDevices; + +@end + +NS_ASSUME_NONNULL_END diff --git a/PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationTarget.m b/PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationTarget.m new file mode 100644 index 000000000..69af52a1b --- /dev/null +++ b/PubNub/Misc/Helpers/Notifications Payload/APNS/PNAPNSNotificationTarget.m @@ -0,0 +1,131 @@ +/** + * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.12.0 + * @copyright © 2010-2019 PubNub, Inc. + */ +#import "PNAPNSNotificationTarget+Private.h" +#import "PNHelpers.h" + + +NS_ASSUME_NONNULL_BEGIN + +#pragma mark Protected interface declaration + +@interface PNAPNSNotificationTarget () + + +#pragma mark - Information + +/** + * @brief Notifications topic name (usually it is application's bundle identifier). + * + * @note Value will be used in APNs POST request as \a apns-topic header value. + */ +@property (nonatomic, copy) NSString *topic; + +/** + * @brief One of \b PNAPNSEnvironment fields which specify environment within which registered + * devices to which notifications should be delivered + */ +@property (nonatomic, assign) PNAPNSEnvironment environment; + +/** + * @brief List of devices (their push tokens) to which this notification shouldn't be delivered. + */ +@property (nonatomic, nullable, strong) NSArray *excludedDevices; + + +#pragma mark - Initialization & Configuration + +/** + * @brief Initialize and configure notification target. + * + * @param topic Notifications topic name (usually it is application's bundle identifier). + * Value will be used in APNs POST request as \a apns-topic header value. + * @param environment One of \b PNAPNSEnvironment fields which specify environment within which + * registered devices to which notifications should be delivered + * @param excludedDevices List of devices (their push tokens) to which this notification shouldn't + * be delivered. + * + * @return Initialized and ready to use notification target. + */ +- (instancetype)initForTopic:(nullable NSString *)topic + inEnvironment:(PNAPNSEnvironment)environment + withExcludedDevices:(nullable NSArray *)excludedDevices; + + +#pragma mark - + + +@end + +NS_ASSUME_NONNULL_END + + +#pragma mark - Interface implementation + +@implementation PNAPNSNotificationTarget + + +#pragma mark - Initialization & Configuration + ++ (instancetype)defaultTarget { + return [self targetForTopic:NSBundle.mainBundle.bundleIdentifier]; +} + ++ (instancetype)targetForTopic:(NSString *)topic { + return [self targetForTopic:topic inEnvironment:PNAPNSDevelopment withExcludedDevices:nil]; +} + ++ (instancetype)targetForTopic:(NSString *)topic + inEnvironment:(PNAPNSEnvironment)environment + withExcludedDevices:(NSArray *)excludedDevices { + + return [[self alloc] initForTopic:topic + inEnvironment:environment + withExcludedDevices:excludedDevices]; +} + +- (instancetype)initForTopic:(NSString *)topic + inEnvironment:(PNAPNSEnvironment)environment + withExcludedDevices:(NSArray *)excludedDevices { + + if ((self = [super init])) { + _topic = [(topic ?: NSBundle.mainBundle.bundleIdentifier) copy]; + _environment = environment; + _excludedDevices = excludedDevices; + } + + return self; +} + + +#pragma mark - Misc + +- (NSDictionary *)dictionaryRepresentation { + NSMutableDictionary *dictionary = [NSMutableDictionary new]; + dictionary[@"environment"] = (self.environment == PNAPNSDevelopment ? @"development" + : @"production"); + dictionary[@"topic"] = self.topic; + + if (self.excludedDevices.count) { + NSMutableArray *excludedDevices = [NSMutableArray new]; + + [self.excludedDevices enumerateObjectsUsingBlock:^(NSData *token, + __unused NSUInteger idx, + __unused BOOL *stop) { + + [excludedDevices addObject:[PNData HEXFromDevicePushToken:token]]; + }]; + + dictionary[@"excluded_devices"] = excludedDevices; + } + + return dictionary; +} + +#pragma mark - + + +@end diff --git a/PubNub/Misc/Helpers/Notifications Payload/PNBaseNotificationPayload+Private.h b/PubNub/Misc/Helpers/Notifications Payload/PNBaseNotificationPayload+Private.h new file mode 100644 index 000000000..4218693a2 --- /dev/null +++ b/PubNub/Misc/Helpers/Notifications Payload/PNBaseNotificationPayload+Private.h @@ -0,0 +1,76 @@ +#import "PNBaseNotificationPayload.h" + + +NS_ASSUME_NONNULL_BEGIN + +#pragma mark Private interface declaration + +@interface PNBaseNotificationPayload (Private) + + +#pragma mark - Information + +/** + * @brief Additional information which may explain reason why this notification has been delivered. + */ +@property (nonatomic, nullable, copy) NSString *subtitle; + +/** + * @brief Number which should be shown in space designated by platform (for example atop of + * application icon). + */ +@property (nonatomic, nullable, strong) NSNumber *badge; + +/** + * @brief Path to file with sound or name of system sound which should be played upon notification + * receive. + */ +@property (nonatomic, nullable, copy) NSString *sound; + +/** + * @brief Short text which should be shown at the top of notification instead of application name. + */ +@property (nonatomic, nullable, copy) NSString *title; + +/** + * @brief Message which should be shown in notification body (under title line). + */ +@property (nonatomic, nullable, copy) NSString *body; + + +#pragma mark - Initialization & Configuration + +/** + * @brief Create and configure platform specific notification payload builder. + * + * @param payloadStorage Mutable dictionary which can be used to store user-provided information. + * @param title Short text which should be shown at the top of notification instead of application + * name. + * @param body Message which should be shown in notification body (under title line). + * + * @return Configured and ready to use platform specific notification payload builder. + */ ++ (instancetype)payloadWithStorage:(NSMutableDictionary *)payloadStorage + notificationTitle:(nullable NSString *)title + body:(nullable NSString *)body; + +/** + * @brief Complete payload structure setup specific for target platform. + */ +- (void)setDefaultPayloadStructure; + + +#pragma mark - Misc + +/** + * @brief Translate user-provided information into payload which can be consumed by \b PubNub mobile + * notification service and delivered to target devices. + */ +- (nullable NSDictionary *)dictionaryRepresentation; + +#pragma mark - + + +@end + +NS_ASSUME_NONNULL_END diff --git a/PubNub/Misc/Helpers/Notifications Payload/PNBaseNotificationPayload.h b/PubNub/Misc/Helpers/Notifications Payload/PNBaseNotificationPayload.h new file mode 100644 index 000000000..e4dee29a6 --- /dev/null +++ b/PubNub/Misc/Helpers/Notifications Payload/PNBaseNotificationPayload.h @@ -0,0 +1,34 @@ +#import + + +NS_ASSUME_NONNULL_BEGIN + +#pragma mark Interface declaration + +/** + * @brief Base platform specific notification payload builder. + * + * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.12.0 + * @copyright © 2010-2019 PubNub, Inc. +*/ +@interface PNBaseNotificationPayload : NSObject + + +#pragma mark - Information + +/** + * @brief Platform specific notification payload. + * + * @discussion In addition to data required to make notification visual presentation it can be used + * to pass additional information which should be sent to remote device. + */ +@property (nonatomic, readonly, strong) NSMutableDictionary *payload; + +#pragma mark - + + +@end + +NS_ASSUME_NONNULL_END diff --git a/PubNub/Misc/Helpers/Notifications Payload/PNBaseNotificationPayload.m b/PubNub/Misc/Helpers/Notifications Payload/PNBaseNotificationPayload.m new file mode 100644 index 000000000..6eab46763 --- /dev/null +++ b/PubNub/Misc/Helpers/Notifications Payload/PNBaseNotificationPayload.m @@ -0,0 +1,108 @@ +/** + * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.12.0 + * @copyright © 2010-2019 PubNub, Inc. +*/ +#import "PNBaseNotificationPayload+Private.h" + + +NS_ASSUME_NONNULL_BEGIN + +#pragma mark Protected interface declaration + +@interface PNBaseNotificationPayload () + + +#pragma mark - Information + +/** + * @brief Platform specific notification payload. + */ +@property (nonatomic, strong) NSMutableDictionary *payload; + +/** + * @brief Additional information which may explain reason why this notification has been delivered. + */ +@property (nonatomic, nullable, copy) NSString *subtitle; + +/** + * @brief Number which should be shown in space designated by platform (for example atop of + * application icon). + */ +@property (nonatomic, nullable, strong) NSNumber *badge; + +/** + * @brief Path to file with sound or name of system sound which should be played upon notification + * receive. + */ +@property (nonatomic, nullable, copy) NSString *sound; + +/** + * @brief Short text which should be shown at the top of notification instead of application name. + */ +@property (nonatomic, nullable, copy) NSString *title; + +/** + * @brief Message which should be shown in notification body (under title line). + */ +@property (nonatomic, nullable, copy) NSString *body; + + +#pragma mark - Initialization & Configuration + +/** + * @brief Initialize and configure platform specific notification payload builder. + * + * @param payloadStorage Mutable dictionary which can be used to store user-provided information. + * @param title Short text which should be shown at the top of notification instead of application + * name. + * @param body Message which should be shown in notification body (under title line). + * + * @return Initialized and ready to use platform specific notification payload builder. + */ +- (instancetype)initWithStorage:(NSMutableDictionary *)payloadStorage + notificationTitle:(nullable NSString *)title + body:(nullable NSString *)body; + +#pragma mark - + + +@end + +NS_ASSUME_NONNULL_END + + +#pragma mark - Interface implementation + +@implementation PNBaseNotificationPayload + + +#pragma mark - Initialization & Configuration + ++ (instancetype)payloadWithStorage:(NSMutableDictionary *)payloadStorage + notificationTitle:(NSString *)title + body:(NSString *)body { + + return [[self alloc] initWithStorage:payloadStorage notificationTitle:title body:body]; +} + +- (instancetype)initWithStorage:(NSMutableDictionary *)payloadStorage + notificationTitle:(NSString *)title + body:(NSString *)body { + + if ((self = [super init])) { + _payload = payloadStorage; + + [self setDefaultPayloadStructure]; + self.title = title; + self.body = body; + } + + return self; +} + +#pragma mark - + + +@end diff --git a/PubNub/Misc/Helpers/Notifications Payload/PNFCMNotificationPayload.h b/PubNub/Misc/Helpers/Notifications Payload/PNFCMNotificationPayload.h new file mode 100644 index 000000000..388ef992a --- /dev/null +++ b/PubNub/Misc/Helpers/Notifications Payload/PNFCMNotificationPayload.h @@ -0,0 +1,64 @@ +#import +#import "PNBaseNotificationPayload.h" + + +NS_ASSUME_NONNULL_BEGIN + +#pragma mark Interface declaration + +/** + * @brief FCM notification payload builder. + * + * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.12.0 + * @copyright © 2010-2019 PubNub, Inc. + */ +@interface PNFCMNotificationPayload : PNBaseNotificationPayload + + +#pragma mark - Information + +/** + * @brief Object with parameters which specify user-visible key-value pairs. + */ +@property (nonatomic, readonly, strong) NSMutableDictionary *notification; + +/** + * @brief Custom key-value object with additional information which will be passed to device along + * with displayable notification information. + * + * @note All object and scalar type value should be converted to strings before passing to this + * object. + * @note \c notification object will be added to this object in case if \c isSilent set to \c YES. + * + * @warning Keys shouldn't match: \c from, \c message_type or start with \c google or \c gcm. + * Also as key can't be used any word defined in this table: https://firebase.google.com/docs/cloud-messaging/http-server-ref#notification-payload-support + */ +@property (nonatomic, readonly, strong) NSMutableDictionary *data; + +/** + * @brief Whether operation system should handle notification layout by default or not. + * + * @note \c notification key with it's content will be moved from root level under \c data key. + */ +@property (nonatomic, assign, getter=isSilent) BOOL silent; + +/** + * @brief Icon which should be shown on the left from notification title instead of application + * icon. + */ +@property (nonatomic, nullable, copy) NSString *icon; + +/** + * @brief Unique notification identifier which can be used to publish update notifications (they + * will previous notification with same \c tag). + */ +@property (nonatomic, nullable, copy) NSString *tag; + +#pragma mark - + + +@end + +NS_ASSUME_NONNULL_END diff --git a/PubNub/Misc/Helpers/Notifications Payload/PNFCMNotificationPayload.m b/PubNub/Misc/Helpers/Notifications Payload/PNFCMNotificationPayload.m new file mode 100644 index 000000000..7ade00fc5 --- /dev/null +++ b/PubNub/Misc/Helpers/Notifications Payload/PNFCMNotificationPayload.m @@ -0,0 +1,93 @@ +/** + * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.12.0 + * @copyright © 2010-2019 PubNub, Inc. +*/ +#import "PNBaseNotificationPayload+Private.h" +#import "PNFCMNotificationPayload.h" + + +#pragma mark Interface implementation + +@implementation PNFCMNotificationPayload + + +#pragma mark - Information + +- (NSMutableDictionary *)notification { + return self.payload[@"notification"]; +} + +- (void)setTitle:(NSString *)title { + self.payload[@"notification"][@"title"] = [title copy]; +} + +- (void)setBody:(NSString *)body { + self.payload[@"notification"][@"body"] = [body copy]; +} + +- (void)setSound:(NSString *)sound { + self.payload[@"notification"][@"sound"] = [sound copy]; +} + +- (void)setIcon:(NSString *)icon { + self.payload[@"notification"][@"icon"] = [icon copy]; +} + +- (void)setTag:(NSString *)tag { + self.payload[@"notification"][@"tag"] = [tag copy]; +} + +- (NSMutableDictionary *)data { + return self.payload[@"data"]; +} + + +#pragma mark - Initialization & Configuration + +- (void)setDefaultPayloadStructure { + self.payload[@"notification"] = [NSMutableDictionary new]; + self.payload[@"data"] = [NSMutableDictionary new]; +} + + +#pragma mark - Misc + +- (NSDictionary *)dictionaryRepresentation { + NSMutableDictionary *data = [self.payload[@"data"] mutableCopy]; + NSMutableDictionary *payload = [NSMutableDictionary new]; + NSDictionary *notification = nil; + + /** + * Check whether additional data has been passed outside of 'data' object and put it into it + * if required. + */ + if (self.payload.count > 2) { + NSMutableDictionary *additionalData = [self.payload mutableCopy]; + [additionalData removeObjectsForKeys:@[@"data", @"notification"]]; + + [data addEntriesFromDictionary:additionalData]; + } + + if (self.isSilent) { + [data addEntriesFromDictionary:@{ @"notification": self.payload[@"notification"] }]; + } else { + notification = self.payload[@"notification"]; + } + + if (data.count) { + payload[@"data"] = data; + } + + if (notification.count) { + payload[@"notification"] = notification; + } + + return payload.count ? payload : nil;; +} + +#pragma mark - + + +@end diff --git a/PubNub/Misc/Helpers/Notifications Payload/PNMPNSNotificationPayload.h b/PubNub/Misc/Helpers/Notifications Payload/PNMPNSNotificationPayload.h new file mode 100644 index 000000000..9119e947d --- /dev/null +++ b/PubNub/Misc/Helpers/Notifications Payload/PNMPNSNotificationPayload.h @@ -0,0 +1,64 @@ +#import +#import "PNBaseNotificationPayload.h" + + +NS_ASSUME_NONNULL_BEGIN + +#pragma mark Interface declaration + +/** + * @brief MPNS notification payload builder. + * + * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.12.0 + * @copyright © 2010-2019 PubNub, Inc. + */ +@interface PNMPNSNotificationPayload : PNBaseNotificationPayload + + +#pragma mark - Information + +/** + * @brief Message which should be shown in notification body (text for back tile). + * + * @note 40 characters long to fit into tile. + * + * @note This value initially set from builder's \c body value. + */ +@property (nonatomic, nullable, copy) NSString *backContent; + +/** + * @brief Additional information which may explain reason why this notification has been delivered. + * + * @note Maximum 15 characters long. + * + * @note This value initially set from builder's \c subtitle value. + */ +@property (nonatomic, nullable, copy) NSString *backTitle; + +/** + * @brief Value between 1-99 which will be shown on the tile. + * + * @note This value initially set from builder's \c badge value. + */ +@property (nonatomic, nullable, strong) NSNumber *count; + +/** + * @brief Title of the tile. + * + * @note This value initially set from builder's \c title value. + */ +@property (nonatomic, nullable, copy) NSString *title; + +/** + * @brief Type of notification which should be presented to the user. + */ +@property (nonatomic, nullable, copy) NSString *type; + +#pragma mark - + + +@end + +NS_ASSUME_NONNULL_END diff --git a/PubNub/Misc/Helpers/Notifications Payload/PNMPNSNotificationPayload.m b/PubNub/Misc/Helpers/Notifications Payload/PNMPNSNotificationPayload.m new file mode 100644 index 000000000..0068ba9e4 --- /dev/null +++ b/PubNub/Misc/Helpers/Notifications Payload/PNMPNSNotificationPayload.m @@ -0,0 +1,72 @@ +/** + * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.12.0 + * @copyright © 2010-2019 PubNub, Inc. +*/ +#import "PNBaseNotificationPayload+Private.h" +#import "PNMPNSNotificationPayload.h" + + +#pragma mark Interface implementation + +@implementation PNMPNSNotificationPayload + + +#pragma mark - Information + +- (void)setBackContent:(NSString *)backContent { + _backContent = [backContent copy]; + self.payload[@"back_content"] = _backContent; +} + +- (void)setBackTitle:(NSString *)backTitle { + _backTitle = [backTitle copy]; + self.payload[@"back_title"] = _backTitle; +} + +- (void)setCount:(NSNumber *)count { + _count = count; + self.payload[@"count"] = _count; +} + +- (void)setTitle:(NSString *)title { + _title = [title copy]; + self.payload[@"title"] = _title; +} + +- (void)setType:(NSString *)type { + _type = [type copy]; + self.payload[@"type"] = _type; +} + +- (void)setSubtitle:(NSString *)subtitle { + self.backTitle = subtitle; +} + +- (void)setBody:(NSString *)body { + self.backContent = body; +} + +- (void)setBadge:(NSNumber *)badge { + self.count = badge; +} + + +#pragma mark - Initialization & Configuration + +- (void)setDefaultPayloadStructure { + // No payload structure required for MPNS because all data is set in object root. +} + + +#pragma mark - Misc + +- (NSDictionary *)dictionaryRepresentation { + return self.payload.count ? [self.payload copy] : nil; +} + +#pragma mark - + + +@end diff --git a/PubNub/Misc/Helpers/Notifications Payload/PNNotificationsPayload.h b/PubNub/Misc/Helpers/Notifications Payload/PNNotificationsPayload.h new file mode 100644 index 000000000..514104503 --- /dev/null +++ b/PubNub/Misc/Helpers/Notifications Payload/PNNotificationsPayload.h @@ -0,0 +1,123 @@ +#import +#import "PNAPNSNotificationPayload.h" +#import "PNMPNSNotificationPayload.h" +#import "PNFCMNotificationPayload.h" + + +NS_ASSUME_NONNULL_BEGIN + +#pragma mark Interface declaration + +/** + * @brief Notifications payload builder. + * + * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.12.0 + * @copyright © 2010-2019 PubNub, Inc. + */ +@interface PNNotificationsPayload : NSObject + + +#pragma mark - Information + +/** + * @brief Access to APNS specific notification builder. + * + * @discussion Allows to set specific general keys and provides access to mutable payload which + * allow to make advanced configuration. + */ +@property (nonatomic, readonly, strong) PNAPNSNotificationPayload *apns; + +/** + * @brief Access to MPNS specific notification builder. + * + * @discussion Allows to set specific general keys and provides access to mutable payload which + * allow to make advanced configuration. + */ +@property (nonatomic, readonly, strong) PNMPNSNotificationPayload *mpns; + +/** + * @brief Access to FCM specific notification builder. + * + * @discussion Allows to set specific general keys and provides access to mutable payload which + * allow to make advanced configuration. + */ +@property (nonatomic, readonly, strong) PNFCMNotificationPayload *fcm; + +/** + * @brief Additional information which may explain reason why this notification has been delivered. + * + * @note May not be supported by some platforms or has different layout in UI. + */ +@property (nonatomic, nullable, copy) NSString *subtitle; + +/** + * @brief Number which should be shown in space designated by platform (for example atop of + * application icon). + */ +@property (nonatomic, nullable, strong) NSNumber *badge; + +/** + * @brief Path to file with sound or name of system sound which should be played upon notification + * receive. + */ +@property (nonatomic, nullable, copy) NSString *sound; + +/** + * @brief Whether \b PubNub service should provide debug information about devices which received + * created notifications payload. + * + * @note Make sure to subscribe from https://www.pubnub.com/docs/console using same + * \c publish / \c subscribe keys on channel to which message has been sent. Full channel name + * consist from target channel name and suffix: \c -pndebug. + * Each time, when message will be sent, \b PubNub should provide debug information into debug + * channel. + */ +@property (nonatomic, assign) BOOL debugging; + + +#pragma mark - Initialization & Configuration + +/** + * @brief Create and configure notifications payload builder. + * + * @param title Short text which should be shown at the top of notification instead of application + * name. + * @param body Message which should be shown in notification body (under title line). + * + * @return Configured and ready to use notifications payload builder. + */ ++ (instancetype)payloadsWithNotificationTitle:(nullable NSString *)title + body:(nullable NSString *)body; + +/** + * @brief Forbids payload builder initialization. + * + * @throws Interface not available exception and requirement to use provided constructor method. + * + * @return Initialized builder. + */ +- (instancetype)init NS_UNAVAILABLE; + + +#pragma mark - Misc + +/** + * @brief Build notifications platform for requested platforms (\c pushTypes). + * + * @param pushTypes Bitfield with fields from \b PNPushType which specify platforms for which + * payload should be added to final dictionary. + * + * @return Dictionary with keys (platform names) and values (notification payload) which will be + * consumed by \b PubNub service and used to trigger remote notifications for devices on specified + * platforms. + */ +- (NSDictionary *)dictionaryRepresentationFor:(PNPushType)pushTypes; + +#pragma mark - + + +@end + +NS_ASSUME_NONNULL_END diff --git a/PubNub/Misc/Helpers/Notifications Payload/PNNotificationsPayload.m b/PubNub/Misc/Helpers/Notifications Payload/PNNotificationsPayload.m new file mode 100644 index 000000000..a4caa13af --- /dev/null +++ b/PubNub/Misc/Helpers/Notifications Payload/PNNotificationsPayload.m @@ -0,0 +1,183 @@ +/** + * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.12.0 + * @copyright © 2010-2019 PubNub, Inc. +*/ +#import "PNAPNSNotificationPayload+Private.h" +#import "PNBaseNotificationPayload+Private.h" +#import "PNNotificationsPayload.h" + + +NS_ASSUME_NONNULL_BEGIN + +#pragma mark Protected interface declaration + +@interface PNNotificationsPayload () + + +#pragma mark - Information + +/** + * @brief Access to APNS specific notification builder. + * + * @discussion Allows to set specific general keys and provides access to mutable payload which + * allow to make advanced configuration. + */ +@property (nonatomic, strong) PNAPNSNotificationPayload *apns; + +/** + * @brief Access to MPNS specific notification builder. + * + * @discussion Allows to set specific general keys and provides access to mutable payload which + * allow to make advanced configuration. + */ +@property (nonatomic, strong) PNMPNSNotificationPayload *mpns; + +/** + * @brief Access to FCM specific notification builder. + * + * @discussion Allows to set specific general keys and provides access to mutable payload which + * allow to make advanced configuration. + */ +@property (nonatomic, strong) PNFCMNotificationPayload *fcm; + +/** + * @brief Mutable dictionary which allow to access raw content (w/o helper builders usage) to make + * direct modifications (if required). + * + * @note Platform specific payloads stored under: \c apns, \c fcm and \c mpns keys. Values for those + * keys also mutable dictionaries which allow to make direct changes to payload before it will be + * used. + */ +@property (nonatomic, strong) NSMutableDictionary *payload; + + +#pragma mark - Initialization & Configuration + +/** + * @brief Initialize and configure notifications payload builder. + * + * @param title Short text which should be shown at the top of notification instead of application + * name. + * @param body Message which should be shown in notification body (under title line). + * + * @return Initialized and ready to use notifications payload builder. + */ +- (instancetype)initWithNotificationTitle:(nullable NSString *)title body:(NSString *)body; + +@end + +NS_ASSUME_NONNULL_END + + +#pragma mark - Interface implementation + +@implementation PNNotificationsPayload + + +#pragma mark - Information + +- (void)setSubtitle:(NSString *)subtitle { + self.apns.subtitle = subtitle; + self.mpns.subtitle = subtitle; + self.fcm.subtitle = subtitle; +} + +- (void)setBadge:(NSNumber *)badge { + self.apns.badge = badge; + self.mpns.badge = badge; + self.fcm.badge = badge; +} + +- (void)setSound:(NSString *)sound { + self.apns.sound = sound; + self.mpns.sound = sound; + self.fcm.sound = sound; +} + + +#pragma mark - Initialization & Configuration + ++ (instancetype)payloadsWithNotificationTitle:(NSString *)title body:(NSString *)body { + return [[self alloc] initWithNotificationTitle:title body:body]; +} + +- (instancetype)initWithNotificationTitle:(NSString *)title body:(NSString *)body { + if ((self = [super init])) { + _payload = [@{ + @"apns": [NSMutableDictionary new], + @"fcm": [NSMutableDictionary new], + @"mpns": [NSMutableDictionary new] + } mutableCopy]; + + _apns = [PNAPNSNotificationPayload payloadWithStorage:_payload[@"apns"] + notificationTitle:title + body:body]; + + _mpns = [PNMPNSNotificationPayload payloadWithStorage:_payload[@"mpns"] + notificationTitle:title + body:body]; + + _fcm = [PNFCMNotificationPayload payloadWithStorage:_payload[@"fcm"] + notificationTitle:title + body:body]; + } + + return self; +} + +- (instancetype)init { + NSDictionary *errorInformation = @{ + NSLocalizedRecoverySuggestionErrorKey: @"Use provided builder constructor" + }; + + @throw [NSException exceptionWithName:@"PNInterfaceNotAvailable" + reason:@"+new or -init methods unavailable." + userInfo:errorInformation]; + + return nil; +} + + +#pragma mark - Misc + +- (NSDictionary *)dictionaryRepresentationFor:(PNPushType)pushTypes { + NSMutableDictionary *payload = [NSMutableDictionary new]; + + if ((pushTypes & PNAPNSPush) == PNAPNSPush || (pushTypes & PNAPNS2Push) == PNAPNS2Push) { + self.apns.apnsPushType = (pushTypes & PNAPNSPush) == PNAPNSPush ? PNAPNSPush : PNAPNS2Push; + NSDictionary *apnsPayload = [self.apns dictionaryRepresentation]; + + if (apnsPayload.count) { + payload[@"pn_apns"] = apnsPayload; + } + } + + if ((pushTypes & PNMPNSPush) == PNMPNSPush) { + NSDictionary *mpnsPayload = [self.mpns dictionaryRepresentation]; + + if (mpnsPayload.count) { + payload[@"pn_mpns"] = mpnsPayload; + } + } + + if ((pushTypes & PNFCMPush) == PNFCMPush) { + NSDictionary *fcmPayload = [self.fcm dictionaryRepresentation]; + + if (fcmPayload.count) { + payload[@"pn_gcm"] = fcmPayload; + } + } + + if (payload.count && self.debugging) { + payload[@"pn_debug"] = @YES; + } + + return payload; +} + +#pragma mark - + + +@end diff --git a/PubNub/Misc/Helpers/PNData.h b/PubNub/Misc/Helpers/PNData.h index ffe895572..5f53be07d 100644 --- a/PubNub/Misc/Helpers/PNData.h +++ b/PubNub/Misc/Helpers/PNData.h @@ -14,7 +14,7 @@ NS_ASSUME_NONNULL_BEGIN ///------------------------------------------------ -/// @name Convertion +/// @name Conversion ///------------------------------------------------ /** diff --git a/PubNub/Misc/Helpers/PNData.m b/PubNub/Misc/Helpers/PNData.m index b968b64cf..85f34ce12 100644 --- a/PubNub/Misc/Helpers/PNData.m +++ b/PubNub/Misc/Helpers/PNData.m @@ -11,7 +11,7 @@ @implementation PNData -#pragma mark - Convertion +#pragma mark - Conversion + (NSString *)HEXFrom:(NSData *)data { diff --git a/PubNub/Misc/Helpers/PNDate.h b/PubNub/Misc/Helpers/PNDate.h new file mode 100644 index 000000000..0633be29a --- /dev/null +++ b/PubNub/Misc/Helpers/PNDate.h @@ -0,0 +1,35 @@ +#import + + +NS_ASSUME_NONNULL_BEGIN + +#pragma mark Interface declaration + +/** + * @brief Useful NSDate additions collection. + * + * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.0.0 + * @copyright © 2010-2019 PubNub, Inc. + */ +@interface PNDate : NSObject + + +#pragma mark - Conversion + +/** + * @brief Convert \a NSDate instance to string formatted according to \c RFC3339. + * + * @param date \a NSDate instance which should be converted to \a NSString. + * + * @return RFC3339 formatted date string. + */ ++ (NSString *)RFC3339StringFromDate:(NSDate *)date; + +#pragma mark - + + +@end + +NS_ASSUME_NONNULL_END diff --git a/PubNub/Misc/Helpers/PNDate.m b/PubNub/Misc/Helpers/PNDate.m new file mode 100644 index 000000000..2c7f2061b --- /dev/null +++ b/PubNub/Misc/Helpers/PNDate.m @@ -0,0 +1,64 @@ +/** + * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.0.0 + * @copyright © 2010-2019 PubNub, Inc. + */ +#import "PNDate.h" + + +NS_ASSUME_NONNULL_BEGIN + +#pragma mark Protected interface declaration + +@interface PNDate () + + +#pragma mark - Information + +/** + * @brief Shared date formatter configured according to RFC3339 requirements. + */ +@property (class, nonatomic, readonly, strong) NSDateFormatter *rfc3339Formatter; + + +#pragma mark - + + +@end + +NS_ASSUME_NONNULL_END + + +#pragma mark - Interface implementation + +@implementation PNDate + + +#pragma mark - Information + ++ (NSDateFormatter *)rfc3339Formatter { + static NSDateFormatter *_sharedRFC3339Formatter; + static dispatch_once_t onceToken; + + dispatch_once(&onceToken, ^{ + _sharedRFC3339Formatter = [NSDateFormatter new]; + _sharedRFC3339Formatter.locale = [NSLocale localeWithLocaleIdentifier:@"en_US_POSIX"]; + _sharedRFC3339Formatter.timeZone = [NSTimeZone timeZoneForSecondsFromGMT:0]; + _sharedRFC3339Formatter.dateFormat = @"yyyy'-'MM'-'dd'T'HH':'mm':'ss'Z'"; + }); + + return _sharedRFC3339Formatter; +} + + +#pragma mark - Conversion + ++ (NSString *)RFC3339StringFromDate:(NSDate *)date { + return [[self rfc3339Formatter] stringFromDate:date]; +} + +#pragma mark - + + +@end diff --git a/PubNub/Misc/Helpers/PNHelpers.h b/PubNub/Misc/Helpers/PNHelpers.h index 081b49d4b..3c53d9f15 100644 --- a/PubNub/Misc/Helpers/PNHelpers.h +++ b/PubNub/Misc/Helpers/PNHelpers.h @@ -15,6 +15,7 @@ #import "PNNumber.h" #import "PNArray.h" #import "PNData.h" +#import "PNDate.h" #import "PNJSON.h" #import "PNGZIP.h" diff --git a/PubNub/Misc/PNConstants.h b/PubNub/Misc/PNConstants.h index dedb09620..d19a6f0cd 100644 --- a/PubNub/Misc/PNConstants.h +++ b/PubNub/Misc/PNConstants.h @@ -15,10 +15,10 @@ #pragma mark General information constants // Stores client library version number -static NSString * const kPNLibraryVersion = @"4.11.1"; +static NSString * const kPNLibraryVersion = @"4.12.0"; // Stores information about SDK codebase -static NSString * const kPNCommit = @"9baf80c2195046f41566e046bc2d44585eb62ef7"; +static NSString * const kPNCommit = @"527edf0d149ce120e63d76e3d52be0e64e63a8d6"; /** @brief Stores reference on unique identifier which is used to identify \b PubNub client among other diff --git a/PubNub/Misc/PNPrivateStructures.h b/PubNub/Misc/PNPrivateStructures.h index 6647d0900..8b3b4397d 100644 --- a/PubNub/Misc/PNPrivateStructures.h +++ b/PubNub/Misc/PNPrivateStructures.h @@ -1,9 +1,10 @@ /** - @brief Set of types and structures which is used as part of private API in \b PubNub client. - - @author Sergey Mamontov - @since 4.0 - @copyright © 2010-2018 PubNub, Inc. + * @brief Set of types and structures which is used as part of private API in \b PubNub client. + * + * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.0.0 + * @copyright © 2010-2019 PubNub, Inc. */ #import "PNStructures.h" @@ -12,7 +13,18 @@ #define PNPrivateStructures_h /** - * @brief Stores reference on key under which unique user identifier will be stored persistently. + * @brief Key under which device ID will be stored persistently. + */ +extern NSString * const kPNConfigurationDeviceIDKey; + +/** + * @brief Key under which in Keychain stored information about previously used sequence number for + * message publish. + */ +extern NSString * const kPNPublishSequenceDataKey; + +/** + * @brief Key under which unique user identifier will be stored persistently. */ extern NSString * const kPNConfigurationUUIDKey; @@ -48,7 +60,7 @@ typedef NS_OPTIONS(NSUInteger, PNMessageType) { @since 4.0 */ -static NSString * const PNOperationTypeStrings[45] = { +static NSString * const PNOperationTypeStrings[49] = { [PNSubscribeOperation] = @"Subscribe", [PNUnsubscribeOperation] = @"Unsubscribe", [PNPublishOperation] = @"Publish", @@ -79,6 +91,10 @@ static NSString * const PNOperationTypeStrings[45] = { [PNAddPushNotificationsOnChannelsOperation] = @"Enable Push Notifications On Channels", [PNRemovePushNotificationsFromChannelsOperation] = @"Remove Push Notifications From Channels", [PNRemoveAllPushNotificationsOperation] = @"Remove All Push Notifications", + [PNPushNotificationEnabledChannelsV2Operation] = @"Get Push Notification Enabled Channels (v2)", + [PNAddPushNotificationsOnChannelsV2Operation] = @"Enable Push Notifications On Channels (v2)", + [PNRemovePushNotificationsFromChannelsV2Operation] = @"Remove Push Notifications From Channels (v2)", + [PNRemoveAllPushNotificationsV2Operation] = @"Remove All Push Notifications (v2)", [PNCreateUserOperation] = @"Create User", [PNUpdateUserOperation] = @"Update User", [PNDeleteUserOperation] = @"Delete User", @@ -96,7 +112,7 @@ static NSString * const PNOperationTypeStrings[45] = { [PNTimeOperation] = @"Time", }; -static NSString * const PNOperationResultClasses[45] = { +static NSString * const PNOperationResultClasses[49] = { [PNHistoryOperation] = @"PNHistoryResult", [PNHistoryForChannelsOperation] = @"PNHistoryResult", [PNHistoryWithActionsOperation] = @"PNHistoryResult", @@ -111,6 +127,7 @@ static NSString * const PNOperationResultClasses[45] = { [PNChannelGroupsOperation] = @"PNChannelGroupsResult", [PNChannelsForGroupOperation] = @"PNChannelGroupChannelsResult", [PNPushNotificationEnabledChannelsOperation] = @"PNAPNSEnabledChannelsResult", + [PNPushNotificationEnabledChannelsV2Operation] = @"PNAPNSEnabledChannelsResult", [PNFetchMessagesActionsOperation] = @"PNFetchMessageActionsResult", [PNFetchUserOperation] = @"PNFetchUserResult", [PNFetchUsersOperation] = @"PNFetchUsersResult", @@ -121,7 +138,7 @@ static NSString * const PNOperationResultClasses[45] = { [PNTimeOperation] = @"PNTimeResult", }; -static NSString * const PNOperationStatusClasses[45] = { +static NSString * const PNOperationStatusClasses[49] = { [PNSubscribeOperation] = @"PNSubscribeStatus", [PNUnsubscribeOperation] = @"PNAcknowledgmentStatus", [PNPublishOperation] = @"PNPublishStatus", @@ -152,6 +169,10 @@ static NSString * const PNOperationStatusClasses[45] = { [PNAddPushNotificationsOnChannelsOperation] = @"PNAcknowledgmentStatus", [PNRemovePushNotificationsFromChannelsOperation] = @"PNAcknowledgmentStatus", [PNRemoveAllPushNotificationsOperation] = @"PNAcknowledgmentStatus", + [PNPushNotificationEnabledChannelsV2Operation] = @"PNErrorStatus", + [PNAddPushNotificationsOnChannelsV2Operation] = @"PNAcknowledgmentStatus", + [PNRemovePushNotificationsFromChannelsV2Operation] = @"PNAcknowledgmentStatus", + [PNRemoveAllPushNotificationsV2Operation] = @"PNAcknowledgmentStatus", [PNCreateUserOperation] = @"PNCreateUserStatus", [PNUpdateUserOperation] = @"PNUpdateUserStatus", [PNDeleteUserOperation] = @"PNAcknowledgmentStatus", diff --git a/PubNub/Misc/PNStructures.h b/PubNub/Misc/PNStructures.h index 13482d5ce..a7e96a2d4 100644 --- a/PubNub/Misc/PNStructures.h +++ b/PubNub/Misc/PNStructures.h @@ -2,6 +2,8 @@ * @brief Set of types and structures which is used as part of API calls in \b PubNub client. * * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.0.0 * @copyright © 2010-2019 PubNub, Inc. */ #import @@ -437,6 +439,56 @@ typedef void(^PNTimeCompletionBlock)(PNTimeResult * _Nullable result, NS_ASSUME_NONNULL_END + +#pragma mark - Push Notifications options and enums + +/** + * @brief Enum which specify possible push notification delivery services. + * + * @since 4.12.0 + */ +typedef NS_OPTIONS(NSUInteger, PNPushType) { + /** + * @brief Apple Push Notification Service used to deliver notifications to specified device. + */ + PNAPNSPush = 1 << 0, + /** + * @brief Apple Push Notification Service used over HTTP/2 to deliver notifications to specified + * device. + */ + PNAPNS2Push = 1 << 1, + /** + * @brief Firebase Cloud Messaging (Google Cloud Messaging) used to deliver notifications to + * specified device. + */ + PNFCMPush = 1 << 2, + /** + * @brief Microsoft Push Notification Service used to deliver notifications to specified device. + */ + PNMPNSPush = 1 << 3 +}; + +/** + * @brief Options with possible APNS environments. + * + * @note Available only for APNS2. + * + * @since 4.12.0 + */ +typedef NS_ENUM(NSUInteger, PNAPNSEnvironment) { + /** + * @brief Environment which allow to use APNS sandbox gateway for remote notifications. + */ + PNAPNSDevelopment, + /** + * @brief Environment which allow to use APNS gateway for remote notifications. + */ + PNAPNSProduction +}; + + +#pragma mark - Objects API options and enums + /** * @brief Options with possible additional \c space / \c membership fields which can be included to * response. @@ -686,6 +738,10 @@ typedef NS_ENUM(NSInteger, PNOperationType){ PNAddPushNotificationsOnChannelsOperation, PNRemovePushNotificationsFromChannelsOperation, PNRemoveAllPushNotificationsOperation, + PNPushNotificationEnabledChannelsV2Operation, + PNAddPushNotificationsOnChannelsV2Operation, + PNRemovePushNotificationsFromChannelsV2Operation, + PNRemoveAllPushNotificationsV2Operation, PNCreateUserOperation, PNUpdateUserOperation, PNDeleteUserOperation, diff --git a/PubNub/Network/PNNetwork.h b/PubNub/Network/PNNetwork.h index d267ca269..757593492 100644 --- a/PubNub/Network/PNNetwork.h +++ b/PubNub/Network/PNNetwork.h @@ -16,8 +16,9 @@ NS_ASSUME_NONNULL_BEGIN * to send network request to \b PubNub service. * * @author Serhii Mamontov - * @since 4.0 - * @copyright © 2010-2018 PubNub, Inc. + * @version 4.12.0 + * @since 4.0.0 + * @copyright © 2010-2019 PubNub, Inc. */ @interface PNNetwork : NSObject diff --git a/PubNub/Network/PNNetwork.m b/PubNub/Network/PNNetwork.m index 0b3499526..71367f359 100644 --- a/PubNub/Network/PNNetwork.m +++ b/PubNub/Network/PNNetwork.m @@ -1,7 +1,8 @@ /** * @author Serhii Mamontov - * @since 4.0 - * @copyright © 2010-2018 PubNub, Inc. + * @version 4.12.0 + * @since 4.0.0 + * @copyright © 2010-2019 PubNub, Inc. */ #import "PNNetwork.h" #import "NSURLSessionConfiguration+PNConfigurationPrivate.h" @@ -786,10 +787,11 @@ - (BOOL)operationExpectResult:(PNOperationType)operation { @(PNGetStateOperation), @(PNStateForChannelOperation), @(PNStateForChannelGroupOperation), @(PNChannelGroupsOperation), @(PNChannelsForGroupOperation), @(PNPushNotificationEnabledChannelsOperation), - @(PNTimeOperation), @(PNFetchMessagesActionsOperation), - @(PNFetchMembershipsOperation), @(PNFetchSpaceOperation), - @(PNFetchSpacesOperation), @(PNFetchUserOperation), - @(PNFetchUsersOperation), @(PNFetchMembersOperation) + @(PNPushNotificationEnabledChannelsV2Operation), @(PNTimeOperation), + @(PNFetchMessagesActionsOperation), @(PNFetchMembershipsOperation), + @(PNFetchSpaceOperation), @(PNFetchSpacesOperation), + @(PNFetchUserOperation), @(PNFetchUsersOperation), + @(PNFetchMembersOperation) ]; }); diff --git a/PubNub/Network/PNURLBuilder.h b/PubNub/Network/PNURLBuilder.h index b42588780..3458a3f0d 100644 --- a/PubNub/Network/PNURLBuilder.h +++ b/PubNub/Network/PNURLBuilder.h @@ -16,7 +16,8 @@ NS_ASSUME_NONNULL_BEGIN * be used with request to \b PubNub network. * * @author Serhii Mamontov - * @since 4.0 + * @version 4.12.0 + * @since 4.0.0 * @copyright © 2010-2019 PubNub, Inc. */ @interface PNURLBuilder : NSObject diff --git a/PubNub/Network/PNURLBuilder.m b/PubNub/Network/PNURLBuilder.m index 44d5b8444..a5fbaa917 100644 --- a/PubNub/Network/PNURLBuilder.m +++ b/PubNub/Network/PNURLBuilder.m @@ -1,5 +1,7 @@ /** * @author Sergey Mamontov + * @version 4.12.0 + * @since 4.0.0 * @copyright © 2010-2019 PubNub, Inc. */ #import "PNURLBuilder.h" @@ -12,7 +14,7 @@ /** * @brief API endpoints description basing on operation type. */ -static NSString * const PNOperationRequestTemplate[45] = { +static NSString * const PNOperationRequestTemplate[49] = { [PNSubscribeOperation] = @"/v2/subscribe/{sub-key}/{channels}/0", [PNUnsubscribeOperation] = @"/v2/presence/sub_key/{sub-key}/channel/{channels}/leave", [PNPublishOperation] = @"/publish/{pub-key}/{sub-key}/0/{channel}/0/{message}", @@ -43,6 +45,10 @@ [PNAddPushNotificationsOnChannelsOperation] = @"/v1/push/sub-key/{sub-key}/devices/{token}", [PNRemovePushNotificationsFromChannelsOperation] = @"/v1/push/sub-key/{sub-key}/devices/{token}", [PNRemoveAllPushNotificationsOperation] = @"/v1/push/sub-key/{sub-key}/devices/{token}/remove", + [PNPushNotificationEnabledChannelsV2Operation] = @"/v2/push/sub-key/{sub-key}/devices-apns2/{token}", + [PNAddPushNotificationsOnChannelsV2Operation] = @"/v2/push/sub-key/{sub-key}/devices-apns2/{token}", + [PNRemovePushNotificationsFromChannelsV2Operation] = @"/v2/push/sub-key/{sub-key}/devices-apns2/{token}", + [PNRemoveAllPushNotificationsV2Operation] = @"/v2/push/sub-key/{sub-key}/devices-apns2/{token}/remove", [PNCreateUserOperation] = @"/v1/objects/{sub-key}/users", [PNUpdateUserOperation] = @"/v1/objects/{sub-key}/users/{user-id}", [PNDeleteUserOperation] = @"/v1/objects/{sub-key}/users/{user-id}", diff --git a/PubNub/Network/Parsers/PNHistoryParser.m b/PubNub/Network/Parsers/PNHistoryParser.m index 08156dc78..330e3403c 100644 --- a/PubNub/Network/Parsers/PNHistoryParser.m +++ b/PubNub/Network/Parsers/PNHistoryParser.m @@ -91,15 +91,21 @@ + (BOOL)requireAdditionalData { @"end": (NSArray *)response[2], @"messages": [NSMutableArray new] } mutableCopy]; - NSMutableDictionary *processedMessages = [self processedMessagesFrom:messages - withData:additionalData]; + + if ([messages isKindOfClass:[NSArray class]]) { + NSMutableDictionary *processedMessages = [self processedMessagesFrom:messages + withData:additionalData]; - if (processedMessages[@"messages"]) { - data[@"messages"] = processedMessages[@"messages"]; - } + if (processedMessages[@"messages"]) { + data[@"messages"] = processedMessages[@"messages"]; + } - if (processedMessages[@"decryptError"]) { - data[@"decryptError"] = @YES; + if (processedMessages[@"decryptError"]) { + data[@"decryptError"] = @YES; + } + } else if ([messages isKindOfClass:[NSString class]]) { + data = [@{ @"status": @(403), @"information": messages, @"error": @YES } mutableCopy]; + data[@"apiError"] = @YES; } processedResponse = data; diff --git a/PubNub/Network/Parsers/PNPushNotificationsAuditParser.h b/PubNub/Network/Parsers/PNPushNotificationsAuditParser.h index 2f56c6d7c..abe4977ea 100644 --- a/PubNub/Network/Parsers/PNPushNotificationsAuditParser.h +++ b/PubNub/Network/Parsers/PNPushNotificationsAuditParser.h @@ -3,23 +3,25 @@ /** - @brief Class suitable to handle and process \b PubNub service response on push notification enabled - channgels list audit request. - @discussion Handle and pre-process provided server data to fetch operation result from it. - @discussion Expected input: - - @code -{ - "channels": [ - NSString, - ... - ] -} - @endcode - - @author Sergey Mamontov - @since 4.0 - @copyright © 2010-2018 PubNub, Inc. + * @brief Class suitable to handle and process \b PubNub service response on push notification + * enabled channgels list audit request. + * + * @discussion Handle and pre-process provided server data to fetch operation result from it. + * @discussion Expected input: + * + * @code + * { + * "channels": [ + * NSString, + * ... + * ] + * } + * @endcode + * + * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.0.0 + * @copyright © 2010-2019 PubNub, Inc. */ @interface PNPushNotificationsAuditParser : NSObject diff --git a/PubNub/Network/Parsers/PNPushNotificationsAuditParser.m b/PubNub/Network/Parsers/PNPushNotificationsAuditParser.m index 2d24195d5..6e2af2ebd 100644 --- a/PubNub/Network/Parsers/PNPushNotificationsAuditParser.m +++ b/PubNub/Network/Parsers/PNPushNotificationsAuditParser.m @@ -1,7 +1,8 @@ /** - @author Sergey Mamontov - @since 4.0 - @copyright © 2010-2018 PubNub, Inc. + * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.0.0 + * @copyright © 2010-2019 PubNub, Inc. */ #import "PNPushNotificationsAuditParser.h" #import "PNDictionary.h" @@ -16,7 +17,8 @@ @implementation PNPushNotificationsAuditParser + (NSArray *)operations { - return @[@(PNPushNotificationEnabledChannelsOperation)]; + return @[@(PNPushNotificationEnabledChannelsOperation), + @(PNPushNotificationEnabledChannelsV2Operation)]; } + (BOOL)requireAdditionalData { diff --git a/PubNub/Network/Parsers/PNPushNotificationsStateModificationParser.h b/PubNub/Network/Parsers/PNPushNotificationsStateModificationParser.h index 2cd1dcef5..7b333d3ec 100644 --- a/PubNub/Network/Parsers/PNPushNotificationsStateModificationParser.h +++ b/PubNub/Network/Parsers/PNPushNotificationsStateModificationParser.h @@ -3,21 +3,23 @@ /** - @brief Class suitable to handle and process \b PubNub service response on push notifications state - manipulation request. - @discussion Handle and pre-process provided server data to fetch operation status from it. - @discussion Expected input: - - @code -{ - "status": @BOOL, - "information": NSString -} - @endcode - - @author Sergey Mamontov - @since 4.0 - @copyright © 2010-2018 PubNub, Inc. + * @brief Class suitable to handle and process \b PubNub service response on push notifications + * state manipulation request. + * + * @discussion Handle and pre-process provided server data to fetch operation status from it. + * @discussion Expected input: + * + * @code + * { + * "status": @BOOL, + * "information": NSString + * } + * @endcode + * + * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.0.0 + * @copyright © 2010-2019 PubNub, Inc. */ @interface PNPushNotificationsStateModificationParser : NSObject diff --git a/PubNub/Network/Parsers/PNPushNotificationsStateModificationParser.m b/PubNub/Network/Parsers/PNPushNotificationsStateModificationParser.m index a13fa31da..1bf9f227e 100644 --- a/PubNub/Network/Parsers/PNPushNotificationsStateModificationParser.m +++ b/PubNub/Network/Parsers/PNPushNotificationsStateModificationParser.m @@ -1,7 +1,8 @@ /** - @author Sergey Mamontov - @since 4.0 - @copyright © 2010-2018 PubNub, Inc. + * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.0.0 + * @copyright © 2010-2019 PubNub, Inc. */ #import "PNPushNotificationsStateModificationParser.h" @@ -17,7 +18,10 @@ @implementation PNPushNotificationsStateModificationParser return @[@(PNAddPushNotificationsOnChannelsOperation), @(PNRemovePushNotificationsFromChannelsOperation), - @(PNRemoveAllPushNotificationsOperation)]; + @(PNRemoveAllPushNotificationsOperation), + @(PNAddPushNotificationsOnChannelsV2Operation), + @(PNRemovePushNotificationsFromChannelsV2Operation), + @(PNRemoveAllPushNotificationsV2Operation)]; } + (BOOL)requireAdditionalData { diff --git a/PubNub/Network/Requests/Actions/Message/PNRemoveMessageActionRequest.h b/PubNub/Network/Requests/Actions/Message/PNRemoveMessageActionRequest.h index 0091aa14c..8ff4dce5e 100644 --- a/PubNub/Network/Requests/Actions/Message/PNRemoveMessageActionRequest.h +++ b/PubNub/Network/Requests/Actions/Message/PNRemoveMessageActionRequest.h @@ -10,7 +10,7 @@ NS_ASSUME_NONNULL_BEGIN * @brief \c Remove \c message \c action request. * * @author Serhii Mamontov - * @version 4.11.0 + * @version 4.12.0 * @since 4.11.0 * @copyright © 2010-2019 PubNub, Inc. */ diff --git a/PubNub/Network/Requests/Actions/Message/PNRemoveMessageActionRequest.m b/PubNub/Network/Requests/Actions/Message/PNRemoveMessageActionRequest.m index a8cddf106..c29901634 100644 --- a/PubNub/Network/Requests/Actions/Message/PNRemoveMessageActionRequest.m +++ b/PubNub/Network/Requests/Actions/Message/PNRemoveMessageActionRequest.m @@ -1,6 +1,6 @@ /** * @author Serhii Mamontov - * @version 4.11.0 + * @version 4.12.0 * @since 4.11.0 * @copyright © 2010-2019 PubNub, Inc. */ @@ -24,9 +24,6 @@ - (NSString *)httpMethod { return @"DELETE"; } - -#pragma mark - Information - - (PNRequestParameters *)requestParameters { PNRequestParameters *parameters = [super requestParameters]; diff --git a/PubNub/Network/Requests/Objects/PNBaseObjectsRequest+Private.h b/PubNub/Network/Requests/Objects/PNBaseObjectsRequest+Private.h index d5f235ce2..64a88efc2 100644 --- a/PubNub/Network/Requests/Objects/PNBaseObjectsRequest+Private.h +++ b/PubNub/Network/Requests/Objects/PNBaseObjectsRequest+Private.h @@ -1,4 +1,6 @@ #import "PNBaseObjectsRequest.h" +#import "PNRequestParameters.h" + NS_ASSUME_NONNULL_BEGIN @@ -9,7 +11,7 @@ NS_ASSUME_NONNULL_BEGIN * initialization. * * @author Serhii Mamontov - * @version 4.10.0 + * @version 4.12.0 * @since 4.10.0 * @copyright © 2010-2019 PubNub, Inc. */ @@ -46,6 +48,19 @@ NS_ASSUME_NONNULL_BEGIN */ - (instancetype)initWithObject:(NSString *)objectType identifier:(NSString *)identifier; + +#pragma mark - Misc + +/** + * @brief Add another data field to 'include' query fields set. + * + * @param fields List of names of data fields which should be added to 'include' list. + * @param requestParameters Request's parameters object which is used to build actual network + * request. + */ +- (void)addIncludedFields:(NSArray *)fields + toRequest:(PNRequestParameters *)requestParameters; + #pragma mark - diff --git a/PubNub/Network/Requests/Objects/PNBaseObjectsRequest.h b/PubNub/Network/Requests/Objects/PNBaseObjectsRequest.h index 36841c794..a1e642fc2 100644 --- a/PubNub/Network/Requests/Objects/PNBaseObjectsRequest.h +++ b/PubNub/Network/Requests/Objects/PNBaseObjectsRequest.h @@ -10,7 +10,7 @@ NS_ASSUME_NONNULL_BEGIN * @brief Base class for all Object API endpoints which has shared query options. * * @author Serhii Mamontov - * @version 4.10.0 + * @version 4.12.0 * @since 4.10.0 * @copyright © 2010-2019 PubNub, Inc. */ diff --git a/PubNub/Network/Requests/Objects/PNBaseObjectsRequest.m b/PubNub/Network/Requests/Objects/PNBaseObjectsRequest.m index fb64c73df..4c5391285 100644 --- a/PubNub/Network/Requests/Objects/PNBaseObjectsRequest.m +++ b/PubNub/Network/Requests/Objects/PNBaseObjectsRequest.m @@ -1,6 +1,6 @@ /** * @author Serhii Mamontov - * @version 4.10.0 + * @version 4.12.0 * @since 4.10.0 * @copyright © 2010-2019 PubNub, Inc. */ @@ -146,11 +146,25 @@ - (instancetype)initWithObject:(NSString *)objectType identifier:(NSString *)ide [fields addObject:@"user.custom"]; } } - - + return fields; } + +#pragma mark - Misc + +- (void)addIncludedFields:(NSArray *)fields + toRequest:(PNRequestParameters *)requestParameters { + + NSString *include = [requestParameters query][@"include"]; + NSMutableArray *includeFields = [[include componentsSeparatedByString:@","] ?: @[] mutableCopy]; + [includeFields addObjectsFromArray:fields]; + + [requestParameters removeQueryParameterWithFieldName:@"include"]; + [requestParameters addQueryParameter:[includeFields componentsJoinedByString:@","] + forFieldName:@"include"]; +} + #pragma mark - diff --git a/PubNub/Network/Requests/PNRequest+Private.h b/PubNub/Network/Requests/PNRequest+Private.h index 6776eae8c..ea083e936 100644 --- a/PubNub/Network/Requests/PNRequest+Private.h +++ b/PubNub/Network/Requests/PNRequest+Private.h @@ -50,24 +50,21 @@ NS_ASSUME_NONNULL_BEGIN */ @property (nonatomic, readonly, strong) NSString *httpMethod; - -#pragma mark - Misc - /** - * @brief Add another data field to 'include' query fields set. + * @brief Whether request is expected to return service response (with data) or not. * - * @param fields List of names of data fields which should be added to 'include' list. - * @param requestParameters Request's parameters object which is used to build actual network - * request. + * @since 4.12.0 */ -- (void)addIncludedFields:(NSArray *)fields - toRequest:(PNRequestParameters *)requestParameters; +@property (nonatomic, readonly, assign) BOOL returnsResponse; + + +#pragma mark - Misc /** * @brief Create error which will provide information about missing required request parameter. * * @param parameter Name of missed of empty parameter. - * @param objectType Name of object type (so far known: \c Space and \c User). + * @param objectType Name of object type. * * @return Error with information about missing parameter. */ @@ -78,7 +75,7 @@ NS_ASSUME_NONNULL_BEGIN * too long. * * @param parameter Name of parameter who's length exceed maximum value. - * @param objectType Name of object type (so far known: \c Space and \c User). + * @param objectType Name of object type. * @param actualLength Actual value length. * @param maximumLength Maximum allowed value length. * diff --git a/PubNub/Network/Requests/PNRequest.h b/PubNub/Network/Requests/PNRequest.h index 167165fd6..4bfba93c9 100644 --- a/PubNub/Network/Requests/PNRequest.h +++ b/PubNub/Network/Requests/PNRequest.h @@ -12,7 +12,7 @@ NS_ASSUME_NONNULL_BEGIN * real network request. * * @author Serhii Mamontov - * @version 4.10.0 + * @version 4.12.0 * @since 4.10.0 * @copyright © 2010-2019 PubNub, Inc. */ diff --git a/PubNub/Network/Requests/PNRequest.m b/PubNub/Network/Requests/PNRequest.m index 1c21308e9..92bb7962d 100644 --- a/PubNub/Network/Requests/PNRequest.m +++ b/PubNub/Network/Requests/PNRequest.m @@ -1,6 +1,6 @@ /** * @author Serhii Mamontov - * @version 4.10.0 + * @version 4.12.0 * @since 4.10.0 * @copyright © 2010-2019 PubNub, Inc. */ @@ -16,6 +16,13 @@ @interface PNRequest () #pragma mark - Information +/** + * @brief Object with information which should be used for request URI composition. + * + * @since 4.12.0 + */ +@property (nonatomic, strong) PNRequestParameters *requestParameters; + /** * @brief Error which represent any request parameters error. */ @@ -40,6 +47,10 @@ - (NSString *)httpMethod { return @"GET"; } +- (BOOL)returnsResponse { + return [self.httpMethod.uppercaseString isEqualToString:@"GET"] ? YES : NO; +} + - (void)setParametersError:(NSError *)parametersError { if (!_parametersError) { _parametersError = parametersError; @@ -47,24 +58,16 @@ - (void)setParametersError:(NSError *)parametersError { } - (PNRequestParameters *)requestParameters { - return [PNRequestParameters new]; + if (!_requestParameters) { + _requestParameters = [PNRequestParameters new]; + } + + return _requestParameters; } #pragma mark - Misc -- (void)addIncludedFields:(NSArray *)fields - toRequest:(PNRequestParameters *)requestParameters { - - NSString *include = [requestParameters query][@"include"]; - NSMutableArray *includeFields = [[include componentsSeparatedByString:@","] ?: @[] mutableCopy]; - [includeFields addObjectsFromArray:fields]; - - [requestParameters removeQueryParameterWithFieldName:@"include"]; - [requestParameters addQueryParameter:[includeFields componentsJoinedByString:@","] - forFieldName:@"include"]; -} - - (NSError *)missingParameterError:(NSString *)parameter forObjectRequest:(NSString *)objectType { NSString *reason = [NSString stringWithFormat:@"%@'s '%@' parameter is missing or empty.", objectType.capitalizedString, parameter]; diff --git a/PubNub/Network/Requests/Push Notifications/PNAddPushNotificationsRequest.h b/PubNub/Network/Requests/Push Notifications/PNAddPushNotificationsRequest.h new file mode 100644 index 000000000..5eec38c75 --- /dev/null +++ b/PubNub/Network/Requests/Push Notifications/PNAddPushNotificationsRequest.h @@ -0,0 +1,32 @@ +#import "PNBasePushNotificationsRequest.h" +#import "PNStructures.h" + + +NS_ASSUME_NONNULL_BEGIN + +#pragma mark Interface declaration + +/** + * @brief \c Add \c notifications \c for \c channels request. + * + * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.12.0 + * @copyright © 2010-2019 PubNub, Inc. + */ +@interface PNAddPushNotificationsRequest : PNBasePushNotificationsRequest + + +#pragma mark - Information + +/** + * @brief List of channel names for which push notifications should be enabled. + */ +@property (nonatomic, copy) NSArray *channels; + +#pragma mark - + + +@end + +NS_ASSUME_NONNULL_END diff --git a/PubNub/Network/Requests/Push Notifications/PNAddPushNotificationsRequest.m b/PubNub/Network/Requests/Push Notifications/PNAddPushNotificationsRequest.m new file mode 100644 index 000000000..3ea81019c --- /dev/null +++ b/PubNub/Network/Requests/Push Notifications/PNAddPushNotificationsRequest.m @@ -0,0 +1,49 @@ +/** + * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.12.0 + * @copyright © 2010-2019 PubNub, Inc. + */ +#import "PNAddPushNotificationsRequest.h" +#import "PNRequest+Private.h" +#import "PNHelpers.h" + + +#pragma nark Interface implementation + +@implementation PNAddPushNotificationsRequest + + +#pragma mark - Information + +- (PNOperationType)operation { + return self.pushType == PNAPNS2Push ? PNAddPushNotificationsOnChannelsV2Operation + : PNAddPushNotificationsOnChannelsOperation; +} + +- (BOOL)returnsResponse { + return NO; +} + +- (PNRequestParameters *)requestParameters { + PNRequestParameters *parameters = [super requestParameters]; + + if (self.channels.count == 0) { + self.parametersError = [self missingParameterError:@"channels" forObjectRequest:@"Request"]; + } + + if (self.parametersError) { + [parameters removePathComponentForPlaceholder:@"{token}"]; + + return parameters; + } + + [parameters addQueryParameter:[PNChannel namesForRequest:self.channels] forFieldName:@"add"]; + + return parameters; +} + +#pragma mark - + + +@end diff --git a/PubNub/Network/Requests/Push Notifications/PNAuditPushNotificationsRequest.h b/PubNub/Network/Requests/Push Notifications/PNAuditPushNotificationsRequest.h new file mode 100644 index 000000000..422f7a188 --- /dev/null +++ b/PubNub/Network/Requests/Push Notifications/PNAuditPushNotificationsRequest.h @@ -0,0 +1,25 @@ +#import "PNBasePushNotificationsRequest.h" +#import "PNStructures.h" + + +NS_ASSUME_NONNULL_BEGIN + +#pragma mark Interface declaration + +/** + * @brief \c Audit \c notifications \c enabled \c channels request. + * + * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.12.0 + * @copyright © 2010-2019 PubNub, Inc. + */ +@interface PNAuditPushNotificationsRequest : PNBasePushNotificationsRequest + + +#pragma mark - + + +@end + +NS_ASSUME_NONNULL_END diff --git a/PubNub/Network/Requests/Push Notifications/PNAuditPushNotificationsRequest.m b/PubNub/Network/Requests/Push Notifications/PNAuditPushNotificationsRequest.m new file mode 100644 index 000000000..02aaccff1 --- /dev/null +++ b/PubNub/Network/Requests/Push Notifications/PNAuditPushNotificationsRequest.m @@ -0,0 +1,30 @@ +/** + * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.12.0 + * @copyright © 2010-2019 PubNub, Inc. + */ +#import "PNAuditPushNotificationsRequest.h" +#import "PNRequest+Private.h" + + +#pragma nark Interface implementation + +@implementation PNAuditPushNotificationsRequest + + +#pragma mark - Information + +- (PNOperationType)operation { + return self.pushType == PNAPNS2Push ? PNPushNotificationEnabledChannelsV2Operation + : PNPushNotificationEnabledChannelsOperation; +} + +- (BOOL)returnsResponse { + return YES; +} + +#pragma mark - + + +@end diff --git a/PubNub/Network/Requests/Push Notifications/PNBasePushNotificationsRequest.h b/PubNub/Network/Requests/Push Notifications/PNBasePushNotificationsRequest.h new file mode 100644 index 000000000..1135334bb --- /dev/null +++ b/PubNub/Network/Requests/Push Notifications/PNBasePushNotificationsRequest.h @@ -0,0 +1,85 @@ +#import "PNStructures.h" +#import "PNRequest.h" + + +NS_ASSUME_NONNULL_BEGIN + +#pragma mark Interface declaration + +/** + * @brief Base class for all 'Push Notifications' API endpoints which has shared query options. + * + * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.12.0 + * @copyright © 2010-2019 PubNub, Inc. + */ +@interface PNBasePushNotificationsRequest : PNRequest + + +#pragma mark - Information + +/** + * @brief One of \b PNPushType fields which specify service to manage notifications for device + * specified with \c pushToken. + */ +@property (nonatomic, readonly, assign) PNPushType pushType; + +/** + * @brief One of \b PNAPNSEnvironment fields which specify environment within which device should + * manage list of channels with enabled notifications. + * + * @note This field works only if request initialized with \c pushType set to \b PNAPNS2Push + * (by default set to \b PNAPNSDevelopment). + */ +@property (nonatomic, assign) PNAPNSEnvironment environment; + +/** + * @brief Notifications topic name (usually it is application's bundle identifier). + * + * @note This field works only if request initialized with \c pushType set to \b PNAPNS2Push + * (by default set to \b NSBundle.mainBundle.bundleIdentifier). + */ +@property (nonatomic, nullable, copy) NSString *topic; + +/** + * @brief OS/library-provided device push token. + */ +@property (nonatomic, readonly, copy) id pushToken; + +/** + * @brief Arbitrary percent encoded query parameters which should be sent along with original API + * call. + */ +@property (nonatomic, nullable, strong) NSDictionary *arbitraryQueryParameters; + + +#pragma mark - Initialization & Configuration + +/** + * @brief Create and configure \c push \c notifications API access request. + * + * @param pushToken Device token / identifier which depending from passed \c pushType should be + * \a NSData (for \b PNAPNS2Push and \b PNAPNSPush) or \a NSString for other. + * @param pushType One of \b PNPushType fields which specify service to manage notifications for + * device specified with \c pushToken. + * + * @return Configured and ready to use \c push \c notifications API access request. + */ ++ (instancetype)requestWithDevicePushToken:(id)pushToken pushType:(PNPushType)pushType; + +/** + * @brief Forbids request initialization. + * + * @throws Interface not available exception and requirement to use provided constructor method. + * + * @return Initialized request. + */ +- (instancetype)init NS_UNAVAILABLE; + +#pragma mark - + + +@end + +NS_ASSUME_NONNULL_END diff --git a/PubNub/Network/Requests/Push Notifications/PNBasePushNotificationsRequest.m b/PubNub/Network/Requests/Push Notifications/PNBasePushNotificationsRequest.m new file mode 100644 index 000000000..55242f88e --- /dev/null +++ b/PubNub/Network/Requests/Push Notifications/PNBasePushNotificationsRequest.m @@ -0,0 +1,161 @@ +/** + * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.12.0 + * @copyright © 2010-2019 PubNub, Inc. + */ +#import "PNBasePushNotificationsRequest.h" +#import "PNRequest+Private.h" +#import "PNErrorCodes.h" +#import "PNHelpers.h" + + +NS_ASSUME_NONNULL_BEGIN + +#pragma mark Protected interface declaration + +@interface PNBasePushNotificationsRequest () + + +#pragma mark - Information + +/** + * @brief OS/library-provided device push token. + */ +@property (nonatomic, copy) id pushToken; + +/** + * @brief One of \b PNPushType fields which specify spervide to manage notifications for device + * specified with \c pushToken. + */ +@property (nonatomic, assign) PNPushType pushType; + + +#pragma mark - Initialization & Configuration + +/** + * @brief Initialize \c push \c notifications API access request. + * + * @param pushToken Depending from passed \c pushType should be \a NSData (for \b PNAPNS2Push and + * \b PNAPNSPush) or \a NSString for other. + * @param pushType One of \b PNPushType fields which specify spervide to manage notifications for + * device specified with \c pushToken. + * + * @return Initialized and ready to use \c push \c notifications API access request. + */ +- (instancetype)initWithDevicePushToken:(id)pushToken pushType:(PNPushType)pushType; + +#pragma mark - + + +@end + +NS_ASSUME_NONNULL_END + + +#pragma mark - Interface implementation + +@implementation PNBasePushNotificationsRequest + + +#pragma mark - Information + +- (PNRequestParameters *)requestParameters { + PNRequestParameters *parameters = [super requestParameters]; + + if (self.parametersError) { + return parameters; + } + + NSString *token = self.pushToken; + NSString *tokenType = @"apns"; + + if (self.pushType == PNAPNSPush || self.pushType == PNAPNS2Push) { + token = [PNData HEXFromDevicePushToken:self.pushToken]; + } + + if (self.pushType == PNFCMPush) { + tokenType = @"gcm"; + } else if (self.pushType == PNMPNSPush) { + tokenType = @"mpns"; + } + + if (self.pushType == PNAPNS2Push) { + NSString *environment = self.environment == PNAPNSDevelopment ? @"development" : @"production"; + NSString *topic = self.topic ?: NSBundle.mainBundle.bundleIdentifier; + + [parameters addQueryParameter:environment forFieldName:@"environment"]; + [parameters addQueryParameter:topic forFieldName:@"topic"]; + } + + [parameters addPathComponent:token.lowercaseString forPlaceholder:@"{token}"]; + [parameters addQueryParameter:tokenType forFieldName:@"type"]; + + return parameters; +} + + +#pragma mark - Initialization & Configuration + ++ (instancetype)requestWithDevicePushToken:(id)pushToken pushType:(PNPushType)pushType { + return [[self alloc] initWithDevicePushToken:pushToken pushType:pushType]; +} + +- (instancetype)initWithDevicePushToken:(id)pushToken pushType:(PNPushType)pushType { + if ((self = [super init])) { + _pushToken = [pushToken copy]; + _pushType = pushType; + + NSDictionary *errorInformation = nil; + + if (!pushToken || + ([pushToken isKindOfClass:[NSData class]] && !((NSData *)pushToken).length) || + ([pushToken isKindOfClass:[NSString class]] && !((NSString *)pushToken).length)) { + + errorInformation = @{ + NSLocalizedDescriptionKey: @"Push Notifications API access request configuration error", + NSLocalizedFailureReasonErrorKey: @"Device token / identifier is missing or empty" + }; + } else if ((pushType == PNAPNSPush || pushType == PNAPNS2Push) && + ![pushToken isKindOfClass:[NSData class]]) { + NSString *serviceName = pushType == PNAPNSPush ? @"APNS" : @"APNS over HTTP/2"; + + errorInformation = @{ + NSLocalizedDescriptionKey: @"Push Notifications API access request configuration error", + NSLocalizedFailureReasonErrorKey: [NSString stringWithFormat:@"%@ expects device " + "token / identifier to be instance of NSData, " + "but got: %@", + serviceName, + NSStringFromClass([pushToken class])] + }; + } else if (pushType != PNAPNSPush && pushType != PNAPNS2Push && + ![pushToken isKindOfClass:[NSString class]]) { + errorInformation = @{ + NSLocalizedDescriptionKey: @"Push Notifications API access request configuration error", + NSLocalizedFailureReasonErrorKey: [NSString stringWithFormat:@"FCM / GCM / MPNS expects " + "device token / identifier to be instance of " + "NSString, but got: %@", + NSStringFromClass([pushToken class])] + }; + } + + if (errorInformation) { + self.parametersError = [NSError errorWithDomain:kPNAPIErrorDomain + code:kPNAPIUnacceptableParameters + userInfo:errorInformation]; + } + } + + return self; +} + +- (instancetype)init { + [self throwUnavailableInitInterface]; + + return nil; +} + +#pragma mark - + + +@end diff --git a/PubNub/Network/Requests/Push Notifications/PNRemoveAllPushNotificationsRequest.h b/PubNub/Network/Requests/Push Notifications/PNRemoveAllPushNotificationsRequest.h new file mode 100644 index 000000000..9ac5611c0 --- /dev/null +++ b/PubNub/Network/Requests/Push Notifications/PNRemoveAllPushNotificationsRequest.h @@ -0,0 +1,25 @@ +#import "PNBasePushNotificationsRequest.h" +#import "PNStructures.h" + + +NS_ASSUME_NONNULL_BEGIN + +#pragma mark Interface declaration + +/** + * @brief \c Remove \c all \c notifications request. + * + * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.12.0 + * @copyright © 2010-2019 PubNub, Inc. + */ +@interface PNRemoveAllPushNotificationsRequest : PNBasePushNotificationsRequest + + +#pragma mark - + + +@end + +NS_ASSUME_NONNULL_END diff --git a/PubNub/Network/Requests/Push Notifications/PNRemoveAllPushNotificationsRequest.m b/PubNub/Network/Requests/Push Notifications/PNRemoveAllPushNotificationsRequest.m new file mode 100644 index 000000000..33820f2cd --- /dev/null +++ b/PubNub/Network/Requests/Push Notifications/PNRemoveAllPushNotificationsRequest.m @@ -0,0 +1,30 @@ +/** + * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.12.0 + * @copyright © 2010-2019 PubNub, Inc. + */ +#import "PNRemoveAllPushNotificationsRequest.h" +#import "PNRequest+Private.h" + + +#pragma nark Interface implementation + +@implementation PNRemoveAllPushNotificationsRequest + + +#pragma mark - Information + +- (PNOperationType)operation { + return self.pushType == PNAPNS2Push ? PNRemoveAllPushNotificationsV2Operation + : PNRemoveAllPushNotificationsOperation; +} + +- (BOOL)returnsResponse { + return NO; +} + +#pragma mark - + + +@end diff --git a/PubNub/Network/Requests/Push Notifications/PNRemovePushNotificationsRequest.h b/PubNub/Network/Requests/Push Notifications/PNRemovePushNotificationsRequest.h new file mode 100644 index 000000000..b67cdf0ee --- /dev/null +++ b/PubNub/Network/Requests/Push Notifications/PNRemovePushNotificationsRequest.h @@ -0,0 +1,32 @@ +#import "PNBasePushNotificationsRequest.h" +#import "PNStructures.h" + + +NS_ASSUME_NONNULL_BEGIN + +#pragma mark Interface declaration + +/** + * @brief \c Remove \c notifications \c from \c channels request. + * + * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.12.0 + * @copyright © 2010-2019 PubNub, Inc. + */ +@interface PNRemovePushNotificationsRequest : PNBasePushNotificationsRequest + + +#pragma mark - Information + +/** + * @brief List of channel names for which push notifications should be disabled. + */ +@property (nonatomic, copy) NSArray *channels; + +#pragma mark - + + +@end + +NS_ASSUME_NONNULL_END diff --git a/PubNub/Network/Requests/Push Notifications/PNRemovePushNotificationsRequest.m b/PubNub/Network/Requests/Push Notifications/PNRemovePushNotificationsRequest.m new file mode 100644 index 000000000..e8257a8e9 --- /dev/null +++ b/PubNub/Network/Requests/Push Notifications/PNRemovePushNotificationsRequest.m @@ -0,0 +1,49 @@ +/** + * @author Serhii Mamontov + * @version 4.12.0 + * @since 4.12.0 + * @copyright © 2010-2019 PubNub, Inc. + */ +#import "PNRemovePushNotificationsRequest.h" +#import "PNRequest+Private.h" +#import "PNHelpers.h" + + +#pragma nark Interface implementation + +@implementation PNRemovePushNotificationsRequest + + +#pragma mark - Information + +- (PNOperationType)operation { + return self.pushType == PNAPNS2Push ? PNRemovePushNotificationsFromChannelsV2Operation + : PNRemovePushNotificationsFromChannelsOperation; +} + +- (BOOL)returnsResponse { + return NO; +} + +- (PNRequestParameters *)requestParameters { + PNRequestParameters *parameters = [super requestParameters]; + + if (self.channels.count == 0) { + self.parametersError = [self missingParameterError:@"channels" forObjectRequest:@"Request"]; + } + + if (self.parametersError) { + [parameters removePathComponentForPlaceholder:@"{token}"]; + + return parameters; + } + + [parameters addQueryParameter:[PNChannel namesForRequest:self.channels] forFieldName:@"remove"]; + + return parameters; +} + +#pragma mark - + + +@end diff --git a/README.md b/README.md index 215fc1d79..28a264103 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# PubNub 4.11.1 for iOS 9+ +# PubNub 4.12.0 for iOS 9+ [![Twitter](https://img.shields.io/badge/twitter-%40PubNub-blue.svg?style=flat)](https://twitter.com/PubNub) [![Twitter Releases](https://img.shields.io/badge/twitter-%40PubNubRelease-blue.svg?style=flat)](https://twitter.com/PubNubRelease) [![License](https://img.shields.io/github/license/pubnub/objective-c.svg?style=flat)](https://img.shields.io/github/license/pubnub/objective-c.svg) diff --git a/Tests/PubNub Tests.xcodeproj/project.pbxproj b/Tests/PubNub Tests.xcodeproj/project.pbxproj index 207214b31..43dc45b32 100644 --- a/Tests/PubNub Tests.xcodeproj/project.pbxproj +++ b/Tests/PubNub Tests.xcodeproj/project.pbxproj @@ -255,6 +255,10 @@ 96E383931BAAC12F00560991 /* PNConfigurationChiperKeyTests.bundle in Resources */ = {isa = PBXBuildFile; fileRef = 9652F3E61BA6E90B001E940A /* PNConfigurationChiperKeyTests.bundle */; }; 96F0239E1B580D0000C4A581 /* NSArray+PNTest.m in Sources */ = {isa = PBXBuildFile; fileRef = 96F0239D1B580D0000C4A581 /* NSArray+PNTest.m */; }; 9722C2761B68A24C00A7CB44 /* PNPublishTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9722C2751B68A24C00A7CB44 /* PNPublishTests.swift */; }; + A5105B60238F08FB00CB693D /* PNNotificationPayloadBuilderTest.m in Sources */ = {isa = PBXBuildFile; fileRef = A5105B5F238F08FB00CB693D /* PNNotificationPayloadBuilderTest.m */; }; + A5105B61238F08FB00CB693D /* PNNotificationPayloadBuilderTest.m in Sources */ = {isa = PBXBuildFile; fileRef = A5105B5F238F08FB00CB693D /* PNNotificationPayloadBuilderTest.m */; }; + A5105B62238F08FB00CB693D /* PNNotificationPayloadBuilderTest.m in Sources */ = {isa = PBXBuildFile; fileRef = A5105B5F238F08FB00CB693D /* PNNotificationPayloadBuilderTest.m */; }; + A5105B63238F08FB00CB693D /* PNNotificationPayloadBuilderTest.m in Sources */ = {isa = PBXBuildFile; fileRef = A5105B5F238F08FB00CB693D /* PNNotificationPayloadBuilderTest.m */; }; A525EA502301E69300ABFDC2 /* PNSpaceObjectsTest.m in Sources */ = {isa = PBXBuildFile; fileRef = A525EA4F2301E69300ABFDC2 /* PNSpaceObjectsTest.m */; }; A525EA512301E69300ABFDC2 /* PNSpaceObjectsTest.m in Sources */ = {isa = PBXBuildFile; fileRef = A525EA4F2301E69300ABFDC2 /* PNSpaceObjectsTest.m */; }; A525EA522301E69300ABFDC2 /* PNSpaceObjectsTest.m in Sources */ = {isa = PBXBuildFile; fileRef = A525EA4F2301E69300ABFDC2 /* PNSpaceObjectsTest.m */; }; @@ -420,6 +424,7 @@ 96F0239C1B580D0000C4A581 /* NSArray+PNTest.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = "NSArray+PNTest.h"; path = "iOS Tests/Helpers/NSArray+PNTest.h"; sourceTree = ""; }; 96F0239D1B580D0000C4A581 /* NSArray+PNTest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = "NSArray+PNTest.m"; path = "iOS Tests/Helpers/NSArray+PNTest.m"; sourceTree = ""; }; 9722C2751B68A24C00A7CB44 /* PNPublishTests.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = PNPublishTests.swift; sourceTree = ""; }; + A5105B5F238F08FB00CB693D /* PNNotificationPayloadBuilderTest.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = PNNotificationPayloadBuilderTest.m; sourceTree = ""; }; A525EA4F2301E69300ABFDC2 /* PNSpaceObjectsTest.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = PNSpaceObjectsTest.m; sourceTree = ""; }; A525EA532302A77A00ABFDC2 /* PNMembershipObjectsTest.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = PNMembershipObjectsTest.m; sourceTree = ""; }; A525EA572302A79000ABFDC2 /* PNMemberObjectsTest.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = PNMemberObjectsTest.m; sourceTree = ""; }; @@ -710,6 +715,7 @@ 79A3E4552215A42C00F2ADB9 /* Unit */ = { isa = PBXGroup; children = ( + A5105B5E238F08AB00CB693D /* Helpers */, 79A3E4562215A42C00F2ADB9 /* Core */, ); name = Unit; @@ -816,6 +822,14 @@ name = Categories; sourceTree = ""; }; + A5105B5E238F08AB00CB693D /* Helpers */ = { + isa = PBXGroup; + children = ( + A5105B5F238F08FB00CB693D /* PNNotificationPayloadBuilderTest.m */, + ); + path = Helpers; + sourceTree = ""; + }; A525EA5F2303EF2400ABFDC2 /* Objects */ = { isa = PBXGroup; children = ( @@ -1449,6 +1463,7 @@ 79A3E4542215806D00F2ADB9 /* PNTestCase.m in Sources */, 517A9EF31BE318B400FAA43A /* NSDictionary+PNTest.m in Sources */, 517A9EDC1BE3185800FAA43A /* PNChannelGroupSubscribeTests.m in Sources */, + A5105B63238F08FB00CB693D /* PNNotificationPayloadBuilderTest.m in Sources */, 79A3E44B2215783200F2ADB9 /* NSInvocation+PNTest.m in Sources */, A589756722FE711C0093BD9A /* PNSpaceObjectsAPICallBuilderTest.m in Sources */, A5F62C3623017E88001CC2A5 /* PNMembershipsObjectsAPICallBuilderTest.m in Sources */, @@ -1521,6 +1536,7 @@ 79878FC122D924F100F0096D /* PNSignalAPIBuilderTest.m in Sources */, 967707F71B8F4A80002B8E84 /* PNPresenceEventTests.m in Sources */, 799CE2F31C45B8FD00AAEBDC /* PNBasicPresenceTestCase.m in Sources */, + A5105B60238F08FB00CB693D /* PNNotificationPayloadBuilderTest.m in Sources */, 79EF04AA1B4EAAB7007478CB /* PNClientStateChannelTests.m in Sources */, 79A238E91D2EB6BA00D080CD /* NSURLSessionConfigurationCategoryTest.m in Sources */, 79EF04BB1B4EAAE4007478CB /* PNBasicClientTestCase.m in Sources */, @@ -1591,6 +1607,7 @@ 797BDCD91C1F5091006EF006 /* PNDeviceIndependentMatcher.m in Sources */, 797BDCDA1C1F5091006EF006 /* PNChannelGroupUnsubscribeTests.m in Sources */, 797BDCDB1C1F5091006EF006 /* PNPresenceEventTests.m in Sources */, + A5105B61238F08FB00CB693D /* PNNotificationPayloadBuilderTest.m in Sources */, 797BDCDC1C1F5091006EF006 /* PNClientStateChannelTests.m in Sources */, 797BDCDD1C1F5091006EF006 /* PNBasicClientTestCase.m in Sources */, 797BDCDE1C1F5091006EF006 /* NSString+PNTest.m in Sources */, @@ -1631,6 +1648,7 @@ 79A3E4532215806D00F2ADB9 /* PNTestCase.m in Sources */, 797BDD111C1F5176006EF006 /* PNSubscribeTests.m in Sources */, 797BDD121C1F5176006EF006 /* PNBasicSubscribeTestCase.m in Sources */, + A5105B62238F08FB00CB693D /* PNNotificationPayloadBuilderTest.m in Sources */, 79A3E44A2215783200F2ADB9 /* NSInvocation+PNTest.m in Sources */, A589756622FE711C0093BD9A /* PNSpaceObjectsAPICallBuilderTest.m in Sources */, A5F62C3523017E88001CC2A5 /* PNMembershipsObjectsAPICallBuilderTest.m in Sources */, diff --git a/Tests/iOS Tests/Tests/Integration/Actions/Messages/PNMessageActionsIntegrationTest.m b/Tests/iOS Tests/Tests/Integration/Actions/Messages/PNMessageActionsIntegrationTest.m index 9b8f677a1..418e6e5c3 100644 --- a/Tests/iOS Tests/Tests/Integration/Actions/Messages/PNMessageActionsIntegrationTest.m +++ b/Tests/iOS Tests/Tests/Integration/Actions/Messages/PNMessageActionsIntegrationTest.m @@ -285,6 +285,7 @@ - (void)testFetchActions_ShouldFetchActions_WhenCalled { NSNumber *firstPublishedActionTimetoken = actionTimetokens[0]; NSNumber *lastPublishedActionTimetoken = actionTimetokens[actionTimetokens.count - 1]; + [self waitTask:@"actionsStore" completionFor:2.f]; [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { self.client1.fetchMessageActions() .channel(expectedChannel) @@ -324,6 +325,7 @@ - (void)testFetchActions_ShouldFetchNextActionsPage_WhenCalledWithLimitAndStart NSNumber *middlePublishedActionTimetoken = actionTimetokens[halfSize]; NSNumber *middleMinusOnePublishedActionTimetoken = actionTimetokens[halfSize - 1]; + [self waitTask:@"actionsStore" completionFor:2.f]; [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { self.client1.fetchMessageActions() .channel(expectedChannel) diff --git a/Tests/iOS Tests/Tests/Integration/Push Notifications/PNAPNSIntegrationTest.m b/Tests/iOS Tests/Tests/Integration/Push Notifications/PNAPNSIntegrationTest.m index 92b0b2c45..302f48199 100644 --- a/Tests/iOS Tests/Tests/Integration/Push Notifications/PNAPNSIntegrationTest.m +++ b/Tests/iOS Tests/Tests/Integration/Push Notifications/PNAPNSIntegrationTest.m @@ -17,6 +17,14 @@ @interface PNAPNSIntegrationTest : PNTestCase @property (nonatomic, strong) PubNub *client; + +#pragma mark - Misc + +/** + * @brief Generate random string which can be used as device push token. + */ +- (NSString *)randomTokenString; + #pragma mark - @@ -44,8 +52,51 @@ - (void)setUp { #pragma mark - Tests :: enable -- (void)testEnable_ShouldFallbackToAPNSToken_WhenCalledWithTokenParameter { - NSString *pushKey = @"6652cff7f17536c86bc353527017741ec07a91699661abaf68c5977a83013092"; +- (void)testEnable_ShouldFallbackToTokenAndPushType_WhenCalledWithAPNSTokenParameter { + NSString *pushKey = [self randomTokenString]; + NSData *pushToken = [pushKey dataFromHexString:pushKey]; + + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { +#pragma clang diagnostic push +#pragma clang diagnostic ignored "-Wdeprecated-declarations" + self.client.push() + .enable() + .channels(@[@"channel1"]) + .apnsToken(pushToken) + .performWithCompletion(^(PNAcknowledgmentStatus *status) { + NSString *url = status.clientRequest.URL.absoluteString; + + XCTAssertFalse(status.isError); + XCTAssertNotEqual([url rangeOfString:@"type=apns"].location, NSNotFound); + handler(); + }); +#pragma clang diagnostic pop + }]; +} + +- (void)testEnable_ShouldFallbackToTokenAndPushType_WhenCalledWithFCMTokenParameter { + NSString *pushKey = [self randomTokenString]; + + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { +#pragma clang diagnostic push +#pragma clang diagnostic ignored "-Wdeprecated-declarations" + self.client.push() + .enable() + .channels(@[@"channel1"]) + .fcmToken(pushKey) + .performWithCompletion(^(PNAcknowledgmentStatus *status) { + NSString *url = status.clientRequest.URL.absoluteString; + + XCTAssertFalse(status.isError); + XCTAssertNotEqual([url rangeOfString:@"type=gcm"].location, NSNotFound); + handler(); + }); +#pragma clang diagnostic pop + }]; +} + +- (void)testEnable_ShouldCallWithAPNSToken_WhenCalledExplicitlyWithAPNSPushTypeParameter { + NSString *pushKey = [self randomTokenString]; NSData *pushToken = [pushKey dataFromHexString:pushKey]; [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { @@ -53,6 +104,7 @@ - (void)testEnable_ShouldFallbackToAPNSToken_WhenCalledWithTokenParameter { .enable() .channels(@[@"channel1"]) .token(pushToken) + .pushType(PNAPNSPush) .performWithCompletion(^(PNAcknowledgmentStatus *status) { NSString *url = status.clientRequest.URL.absoluteString; @@ -63,33 +115,36 @@ - (void)testEnable_ShouldFallbackToAPNSToken_WhenCalledWithTokenParameter { }]; } -- (void)testEnable_ShouldCallWithAPNSToken_WhenCalledExplicitlyWithAPNSTokenParameter { - NSString *pushKey = @"6652cff7f17536c86bc353527017741ec07a91699661abaf68c5977a83013092"; +- (void)testEnable_ShouldCallWithAPNS2Token_WhenCalledExplicitlyWithAPNS2PushTypeParameter { + NSString *pushKey = [self randomTokenString]; NSData *pushToken = [pushKey dataFromHexString:pushKey]; [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { self.client.push() .enable() .channels(@[@"channel1"]) - .apnsToken(pushToken) + .token(pushToken) + .pushType(PNAPNS2Push) .performWithCompletion(^(PNAcknowledgmentStatus *status) { NSString *url = status.clientRequest.URL.absoluteString; XCTAssertFalse(status.isError); XCTAssertNotEqual([url rangeOfString:@"type=apns"].location, NSNotFound); + XCTAssertNotEqual([url rangeOfString:@"devices-apns2"].location, NSNotFound); handler(); }); }]; } -- (void)testEnable_ShouldCallWithFCMToken_WhenCalledExplicitlyWithFCMTokenParameter { - NSString *pushKey = @"6652cff7f17536c86bc353527017741ec07a91699661abaf68c5977a83013093"; +- (void)testEnable_ShouldCallWithFCMToken_WhenCalledExplicitlyWithFCMPushTypeParameter { + NSString *pushKey = [self randomTokenString]; [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { self.client.push() .enable() .channels(@[@"channel1"]) - .fcmToken(pushKey) + .token(pushKey) + .pushType(PNFCMPush) .performWithCompletion(^(PNAcknowledgmentStatus *status) { NSString *url = status.clientRequest.URL.absoluteString; @@ -100,103 +155,483 @@ - (void)testEnable_ShouldCallWithFCMToken_WhenCalledExplicitlyWithFCMTokenParame }]; } +- (void)testEnable_ShouldCallWithMPNSToken_WhenCalledExplicitlyWithMPNSPushTypeParameter { + NSString *pushKey = [self randomTokenString]; + + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .enable() + .channels(@[@"channel1"]) + .token(pushKey) + .pushType(PNMPNSPush) + .performWithCompletion(^(PNAcknowledgmentStatus *status) { + NSString *url = status.clientRequest.URL.absoluteString; + + XCTAssertFalse(status.isError); + XCTAssertNotEqual([url rangeOfString:@"type=mpns"].location, NSNotFound); + handler(); + }); + }]; +} -#pragma mark - Tests :: disable +- (void)testEnable_ShouldFailCallAPNS_WhenCalledWithEmptyToken { + NSData *pushToken = nil; + + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .enable() + .channels(@[@"channel1"]) + .token(pushToken) + .pushType(PNAPNSPush) + .performWithCompletion(^(PNAcknowledgmentStatus *status) { + XCTAssertTrue(status.isError); + handler(); + }); + }]; +} -- (void)testDisable_ShouldFallbackToAPNSToken_WhenCalledWithTokenParameter { - NSString *pushKey = @"6652cff7f17536c86bc353527017741ec07a91699661abaf68c5977a83013092"; - NSData *pushToken = [pushKey dataFromHexString:pushKey]; +- (void)testEnable_ShouldFailCallAPNS_WhenCalledWithNonNSDataToken { + NSData *pushToken = (id)@""; [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { self.client.push() .enable() .channels(@[@"channel1"]) .token(pushToken) + .pushType(PNAPNSPush) .performWithCompletion(^(PNAcknowledgmentStatus *status) { - self.client.push() - .disable() - .token(pushToken) - .performWithCompletion(^(PNAcknowledgmentStatus *status) { - NSString *url = status.clientRequest.URL.absoluteString; - - XCTAssertFalse(status.isError); - XCTAssertNotEqual([url rangeOfString:@"type=apns"].location, NSNotFound); - handler(); - }); + XCTAssertTrue(status.isError); + handler(); + }); + }]; +} + +- (void)testEnable_ShouldFailCallFCM_WhenCalledWithEmptyToken { + NSString *pushToken = nil; + + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .enable() + .channels(@[@"channel1"]) + .token(pushToken) + .pushType(PNFCMPush) + .performWithCompletion(^(PNAcknowledgmentStatus *status) { + XCTAssertTrue(status.isError); + handler(); + }); + }]; +} + +- (void)testEnable_ShouldFailCallFCM_WhenCalledWithNonNSStringToken { + NSString *pushToken = (id)@2010; + + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .enable() + .channels(@[@"channel1"]) + .token(pushToken) + .pushType(PNFCMPush) + .performWithCompletion(^(PNAcknowledgmentStatus *status) { + XCTAssertTrue(status.isError); + handler(); }); }]; } -- (void)testDisable_ShouldCallWithAPNSToken_WhenCalledExplicitlyWithAPNSTokenParameter { - NSString *pushKey = @"6652cff7f17536c86bc353527017741ec07a91699661abaf68c5977a83013092"; +- (void)testEnable_ShouldFailCallMPNS_WhenCalledWithEmptyToken { + NSString *pushToken = nil; + + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .enable() + .channels(@[@"PNMPNSPush"]) + .token(pushToken) + .pushType(PNFCMPush) + .performWithCompletion(^(PNAcknowledgmentStatus *status) { + XCTAssertTrue(status.isError); + handler(); + }); + }]; +} + +- (void)testEnable_ShouldFailCallMPNS_WhenCalledWithNonNSStringToken { + NSString *pushToken = (id)@2010; + + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .enable() + .channels(@[@"channel1"]) + .token(pushToken) + .pushType(PNMPNSPush) + .performWithCompletion(^(PNAcknowledgmentStatus *status) { + XCTAssertTrue(status.isError); + handler(); + }); + }]; +} + + +#pragma mark - Tests :: disable + +- (void)testDisable_ShouldFallbackToTokenAndPushType_WhenCalledWithAPNSTokenParameter { + NSString *pushKey = [self randomTokenString]; NSData *pushToken = [pushKey dataFromHexString:pushKey]; +#pragma clang diagnostic push +#pragma clang diagnostic ignored "-Wdeprecated-declarations" [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { self.client.push() .enable() .channels(@[@"channel1"]) .apnsToken(pushToken) .performWithCompletion(^(PNAcknowledgmentStatus *status) { - self.client.push() - .disable() - .apnsToken(pushToken) - .performWithCompletion(^(PNAcknowledgmentStatus *status) { - self.client.push() - .audit() - .token(pushToken) - .performWithCompletion(^(PNAPNSEnabledChannelsResult *result, PNErrorStatus *status) { - NSString *url = result.clientRequest.URL.absoluteString; - - XCTAssertNil(status); - XCTAssertNotEqual([url rangeOfString:@"type=apns"].location, NSNotFound); - XCTAssertEqual(result.data.channels.count, 0); - handler(); - }); - }); + handler(); }); }]; + + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .disable() + .channels(@[@"channel1"]) + .apnsToken(pushToken) + .performWithCompletion(^(PNAcknowledgmentStatus *status) { + NSString *url = status.clientRequest.URL.absoluteString; + + XCTAssertFalse(status.isError); + XCTAssertNotEqual([url rangeOfString:@"type=apns"].location, NSNotFound); + handler(); + }); + }]; +#pragma clang diagnostic pop } -- (void)testDisable_ShouldCallWithFCMToken_WhenCalledExplicitlyWithFCMTokenParameter { - NSString *pushKey = @"6652cff7f17536c86bc353527017741ec07a91699661abaf68c5977a83013093"; +- (void)testDisable_ShouldFallbackToTokenAndPushType_WhenCalledWithFCMTokenParameter { + NSString *pushKey = [self randomTokenString]; +#pragma clang diagnostic push +#pragma clang diagnostic ignored "-Wdeprecated-declarations" [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { self.client.push() .enable() .channels(@[@"channel1"]) .fcmToken(pushKey) .performWithCompletion(^(PNAcknowledgmentStatus *status) { - self.client.push() - .disable() - .fcmToken(pushKey) - .performWithCompletion(^(PNAcknowledgmentStatus *status) { - self.client.push() - .audit() - .fcmToken(pushKey) - .performWithCompletion(^(PNAPNSEnabledChannelsResult *result, PNErrorStatus *status) { - NSString *url = result.clientRequest.URL.absoluteString; - - XCTAssertNil(status); - XCTAssertNotEqual([url rangeOfString:@"type=gcm"].location, NSNotFound); - XCTAssertEqual(result.data.channels.count, 0); - handler(); - }); - }); + handler(); }); }]; + + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .disable() + .channels(@[@"channel1"]) + .fcmToken(pushKey) + .performWithCompletion(^(PNAcknowledgmentStatus *status) { + NSString *url = status.clientRequest.URL.absoluteString; + + XCTAssertFalse(status.isError); + XCTAssertNotEqual([url rangeOfString:@"type=gcm"].location, NSNotFound); + handler(); + }); + }]; +#pragma clang diagnostic pop } +- (void)testDisable_ShouldCallWithAPNSToken_WhenCalledExplicitlyWithAPNSPushTypeParameter { + NSString *pushKey = [self randomTokenString]; + NSData *pushToken = [pushKey dataFromHexString:pushKey]; + + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .enable() + .channels(@[@"channel1"]) + .token(pushToken) + .pushType(PNAPNSPush) + .performWithCompletion(^(PNAcknowledgmentStatus *status) { + handler(); + }); + }]; -#pragma mark - Tests :: audit + [self waitTask:@"pushNotificationEnable" completionFor:0.5f]; + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .disableAll() + .token(pushToken) + .pushType(PNAPNSPush) + .performWithCompletion(^(PNAcknowledgmentStatus *status) { + handler(); + }); + }]; + + [self waitTask:@"pushNotificationDisable" completionFor:0.5f]; + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .audit() + .token(pushToken) + .pushType(PNAPNSPush) + .performWithCompletion(^(PNAPNSEnabledChannelsResult *result, PNErrorStatus *status) { + NSString *url = result.clientRequest.URL.absoluteString; + + XCTAssertNil(status); + XCTAssertNotEqual([url rangeOfString:@"type=apns"].location, NSNotFound); + XCTAssertEqual(result.data.channels.count, 0); + handler(); + }); + }]; +} -- (void)testAudit_ShouldFallbackToAPNSToken_WhenCalledWithTokenParameter { - NSString *pushKey = @"6652cff7f17536c86bc353527017741ec07a91699661abaf68c5977a83013092"; +- (void)testDisable_ShouldCallWithAPNS2Token_WhenCalledExplicitlyWithAPNS2PushTypeParameter { + NSString *pushKey = [self randomTokenString]; NSData *pushToken = [pushKey dataFromHexString:pushKey]; + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .enable() + .channels(@[@"channel1"]) + .token(pushToken) + .pushType(PNAPNS2Push) + .performWithCompletion(^(PNAcknowledgmentStatus *status) { + handler(); + }); + }]; + + [self waitTask:@"pushNotificationEnable" completionFor:0.5f]; + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .disableAll() + .token(pushToken) + .pushType(PNAPNS2Push) + .performWithCompletion(^(PNAcknowledgmentStatus *status) { + handler(); + }); + }]; + + [self waitTask:@"pushNotificationDisable" completionFor:0.5f]; [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { self.client.push() .audit() .token(pushToken) + .pushType(PNAPNS2Push) + .performWithCompletion(^(PNAPNSEnabledChannelsResult *result, PNErrorStatus *status) { + NSString *url = result.clientRequest.URL.absoluteString; + + XCTAssertNil(status); + XCTAssertNotEqual([url rangeOfString:@"type=apns"].location, NSNotFound); + XCTAssertNotEqual([url rangeOfString:@"devices-apns2"].location, NSNotFound); + XCTAssertEqual(result.data.channels.count, 0); + handler(); + }); + }]; +} + +- (void)testDisable_ShouldCallWithFCMToken_WhenCalledExplicitlyWithFCMPushTypeParameter { + NSString *pushKey = [self randomTokenString]; + + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .enable() + .channels(@[@"channel1"]) + .token(pushKey) + .pushType(PNFCMPush) + .performWithCompletion(^(PNAcknowledgmentStatus *status) { + handler(); + }); + }]; + + [self waitTask:@"pushNotificationEnable" completionFor:0.5f]; + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .disableAll() + .token(pushKey) + .pushType(PNFCMPush) + .performWithCompletion(^(PNAcknowledgmentStatus *status) { + handler(); + }); + }]; + + [self waitTask:@"pushNotificationDisable" completionFor:0.5f]; + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .audit() + .token(pushKey) + .pushType(PNFCMPush) + .performWithCompletion(^(PNAPNSEnabledChannelsResult *result, PNErrorStatus *status) { + NSString *url = result.clientRequest.URL.absoluteString; + + XCTAssertNil(status); + XCTAssertNotEqual([url rangeOfString:@"type=gcm"].location, NSNotFound); + XCTAssertEqual(result.data.channels.count, 0); + handler(); + }); + }]; +} + +- (void)testDisable_ShouldCallWithMPNSToken_WhenCalledExplicitlyWithMPNSPushTypeParameter { + NSString *pushKey = [self randomTokenString]; + + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .enable() + .channels(@[@"channel1"]) + .token(pushKey) + .pushType(PNMPNSPush) + .performWithCompletion(^(PNAcknowledgmentStatus *status) { + handler(); + }); + }]; + + [self waitTask:@"pushNotificationEnable" completionFor:0.5f]; + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .disableAll() + .token(pushKey) + .pushType(PNMPNSPush) + .performWithCompletion(^(PNAcknowledgmentStatus *status) { + handler(); + }); + }]; + + [self waitTask:@"pushNotificationDisable" completionFor:0.5f]; + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .audit() + .token(pushKey) + .pushType(PNMPNSPush) + .performWithCompletion(^(PNAPNSEnabledChannelsResult *result, PNErrorStatus *status) { + NSString *url = result.clientRequest.URL.absoluteString; + + XCTAssertNil(status); + XCTAssertNotEqual([url rangeOfString:@"type=mpns"].location, NSNotFound); + XCTAssertEqual(result.data.channels.count, 0); + handler(); + }); + }]; +} + +- (void)testDisable_ShouldFailCall_WhenCalledWithEmptyChannelsList { + NSString *pushKey = [self randomTokenString]; + NSData *pushToken = [pushKey dataFromHexString:pushKey]; + + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .disable() + .token(pushToken) + .pushType(PNAPNSPush) + .performWithCompletion(^(PNAcknowledgmentStatus *status) { + XCTAssertTrue(status.isError); + handler(); + }); + }]; +} + +- (void)testDisable_ShouldFailCallAPNS_WhenCalledWithEmptyToken { + NSData *pushToken = nil; + + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .disable() + .channels(@[@"channel1"]) + .token(pushToken) + .pushType(PNAPNSPush) + .performWithCompletion(^(PNAcknowledgmentStatus *status) { + XCTAssertTrue(status.isError); + handler(); + }); + }]; +} + +- (void)testDisable_ShouldFailCallAPNS_WhenCalledWithNonNSDataToken { + NSData *pushToken = (id)@""; + + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .disable() + .channels(@[@"channel1"]) + .token(pushToken) + .pushType(PNAPNSPush) + .performWithCompletion(^(PNAcknowledgmentStatus *status) { + XCTAssertTrue(status.isError); + handler(); + }); + }]; +} + +- (void)testDisable_ShouldFailCallFCM_WhenCalledWithEmptyToken { + NSString *pushToken = nil; + + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .disable() + .channels(@[@"channel1"]) + .token(pushToken) + .pushType(PNFCMPush) + .performWithCompletion(^(PNAcknowledgmentStatus *status) { + XCTAssertTrue(status.isError); + handler(); + }); + }]; +} + +- (void)testDisable_ShouldFailCallFCM_WhenCalledWithNonNSStringToken { + NSString *pushToken = (id)@2010; + + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .disable() + .channels(@[@"channel1"]) + .token(pushToken) + .pushType(PNFCMPush) + .performWithCompletion(^(PNAcknowledgmentStatus *status) { + XCTAssertTrue(status.isError); + handler(); + }); + }]; +} + +- (void)testDisable_ShouldFailCallMPNS_WhenCalledWithEmptyToken { + NSString *pushToken = nil; + + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .disable() + .channels(@[@"PNMPNSPush"]) + .token(pushToken) + .pushType(PNFCMPush) + .performWithCompletion(^(PNAcknowledgmentStatus *status) { + XCTAssertTrue(status.isError); + handler(); + }); + }]; +} + +- (void)testDisable_ShouldFailCallMPNS_WhenCalledWithNonNSStringToken { + NSString *pushToken = (id)@2010; + + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .disable() + .channels(@[@"channel1"]) + .token(pushToken) + .pushType(PNMPNSPush) + .performWithCompletion(^(PNAcknowledgmentStatus *status) { + XCTAssertTrue(status.isError); + handler(); + }); + }]; +} + + +#pragma mark - Tests :: audit + +- (void)testAudit_ShouldFallbackToTokenAndPushType_WhenCalledWithAPNSTokenParameter { + NSString *pushKey = [self randomTokenString]; + NSData *pushToken = [pushKey dataFromHexString:pushKey]; + + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { +#pragma clang diagnostic push +#pragma clang diagnostic ignored "-Wdeprecated-declarations" + self.client.push() + .audit() + .apnsToken(pushToken) .performWithCompletion(^(PNAPNSEnabledChannelsResult *result, PNErrorStatus *status) { NSString *url = result.clientRequest.URL.absoluteString; @@ -204,52 +639,232 @@ - (void)testAudit_ShouldFallbackToAPNSToken_WhenCalledWithTokenParameter { XCTAssertNotEqual([url rangeOfString:@"type=apns"].location, NSNotFound); handler(); }); +#pragma clang diagnostic pop + }]; +} + +- (void)testAudit_ShouldFallbackToTokenAndPushType_WhenCalledWithFCMTokenParameter { + NSString *pushKey = [self randomTokenString]; + + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { +#pragma clang diagnostic push +#pragma clang diagnostic ignored "-Wdeprecated-declarations" + self.client.push() + .audit() + .fcmToken(pushKey) + .performWithCompletion(^(PNAPNSEnabledChannelsResult *result, PNErrorStatus *status) { + NSString *url = result.clientRequest.URL.absoluteString; + + XCTAssertNil(status); + XCTAssertNotEqual([url rangeOfString:@"type=gcm"].location, NSNotFound); + handler(); + }); +#pragma clang diagnostic pop }]; } -- (void)testAudit_ShouldCallWithAPNSToken_WhenCalledExplicitlyWithAPNSTokenParameter { - NSString *pushKey = @"6652cff7f17536c86bc353527017741ec07a91699661abaf68c5977a83013092"; +- (void)testAudit_ShouldCallWithAPNSToken_WhenCalledExplicitlyWithAPNSPushTypeParameter { + NSString *pushKey = [self randomTokenString]; NSData *pushToken = [pushKey dataFromHexString:pushKey]; [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { self.client.push() .audit() - .apnsToken(pushToken) + .token(pushToken) + .pushType(PNAPNSPush) + .performWithCompletion(^(PNAPNSEnabledChannelsResult *result, PNErrorStatus *status) { + NSString *url = result.clientRequest.URL.absoluteString; + + XCTAssertNil(status); + XCTAssertNotEqual([url rangeOfString:@"type=apns"].location, NSNotFound); + handler(); + }); + }]; +} + +- (void)testAudit_ShouldCallWithAPNS2Token_WhenCalledExplicitlyWithAPNS2PushTypeParameter { + NSString *pushKey = [self randomTokenString]; + NSData *pushToken = [pushKey dataFromHexString:pushKey]; + + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .audit() + .token(pushToken) + .pushType(PNAPNS2Push) .performWithCompletion(^(PNAPNSEnabledChannelsResult *result, PNErrorStatus *status) { NSString *url = result.clientRequest.URL.absoluteString; XCTAssertNil(status); XCTAssertNotEqual([url rangeOfString:@"type=apns"].location, NSNotFound); + XCTAssertNotEqual([url rangeOfString:@"devices-apns2"].location, NSNotFound); handler(); }); }]; } -- (void)testAudit_ShouldCallWithFCMToken_WhenCalledExplicitlyWithFCMTokenParameter { - NSString *pushKey = @"6652cff7f17536c86bc353527017741ec07a91699661abaf68c5977a83013093"; +- (void)testAudit_ShouldCallWithFCMToken_WhenCalledExplicitlyWithFCMPushTypeParameter { + NSString *pushKey = [self randomTokenString]; NSString *channel = NSUUID.UUID.UUIDString; [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { self.client.push() .enable() .channels(@[channel]) - .fcmToken(pushKey) + .token(pushKey) + .pushType(PNFCMPush) .performWithCompletion(^(PNAcknowledgmentStatus *status) { - self.client.push() - .audit() - .fcmToken(pushKey) - .performWithCompletion(^(PNAPNSEnabledChannelsResult *result, PNErrorStatus *status) { - NSString *url = result.clientRequest.URL.absoluteString; - - XCTAssertNil(status); - XCTAssertNotEqual([url rangeOfString:@"type=gcm"].location, NSNotFound); - XCTAssertTrue([result.data.channels containsObject:channel]); - handler(); - }); + handler(); + }); + }]; + + [self waitTask:@"pushNotificationEnable" completionFor:0.5f]; + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .audit() + .token(pushKey) + .pushType(PNFCMPush) + .performWithCompletion(^(PNAPNSEnabledChannelsResult *result, PNErrorStatus *status) { + NSString *url = result.clientRequest.URL.absoluteString; + + XCTAssertNil(status); + XCTAssertNotEqual([url rangeOfString:@"type=gcm"].location, NSNotFound); + XCTAssertTrue([result.data.channels containsObject:channel]); + handler(); + }); + }]; +} + +- (void)testAudit_ShouldCallWithMPNSToken_WhenCalledExplicitlyWithMPNSPushTypeParameter { + NSString *pushKey = [self randomTokenString]; + NSString *channel = NSUUID.UUID.UUIDString; + + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .enable() + .channels(@[channel]) + .token(pushKey) + .pushType(PNMPNSPush) + .performWithCompletion(^(PNAcknowledgmentStatus *status) { + handler(); + }); + }]; + + [self waitTask:@"pushNotificationEnable" completionFor:0.5f]; + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .audit() + .token(pushKey) + .pushType(PNMPNSPush) + .performWithCompletion(^(PNAPNSEnabledChannelsResult *result, PNErrorStatus *status) { + NSString *url = result.clientRequest.URL.absoluteString; + + XCTAssertNil(status); + XCTAssertNotEqual([url rangeOfString:@"type=mpns"].location, NSNotFound); + XCTAssertTrue([result.data.channels containsObject:channel]); + handler(); + }); + }]; +} + +- (void)testAudit_ShouldFailCallAPNS_WhenCalledWithEmptyToken { + NSData *pushToken = nil; + + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .audit() + .token(pushToken) + .pushType(PNAPNSPush) + .performWithCompletion(^(PNAPNSEnabledChannelsResult *result, PNErrorStatus *status) { + XCTAssertTrue(status.isError); + handler(); }); }]; } +- (void)testAudit_ShouldFailCallAPNS_WhenCalledWithNonNSDataToken { + NSData *pushToken = (id)@""; + + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .audit() + .token(pushToken) + .pushType(PNAPNSPush) + .performWithCompletion(^(PNAPNSEnabledChannelsResult *result, PNErrorStatus *status) { + XCTAssertTrue(status.isError); + handler(); + }); + }]; +} + +- (void)testAudit_ShouldFailCallFCM_WhenCalledWithEmptyToken { + NSString *pushToken = nil; + + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .audit() + .token(pushToken) + .pushType(PNFCMPush) + .performWithCompletion(^(PNAPNSEnabledChannelsResult *result, PNErrorStatus *status) { + XCTAssertTrue(status.isError); + handler(); + }); + }]; +} + +- (void)testAudit_ShouldFailCallFCM_WhenCalledWithNonNSStringToken { + NSString *pushToken = (id)@2010; + + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .audit() + .token(pushToken) + .pushType(PNFCMPush) + .performWithCompletion(^(PNAPNSEnabledChannelsResult *result, PNErrorStatus *status) { + XCTAssertTrue(status.isError); + handler(); + }); + }]; +} + +- (void)testAudit_ShouldFailCallMPNS_WhenCalledWithEmptyToken { + NSString *pushToken = nil; + + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .audit() + .token(pushToken) + .pushType(PNFCMPush) + .performWithCompletion(^(PNAPNSEnabledChannelsResult *result, PNErrorStatus *status) { + XCTAssertTrue(status.isError); + handler(); + }); + }]; +} + +- (void)testAudit_ShouldFailCallMPNS_WhenCalledWithNonNSStringToken { + NSString *pushToken = (id)@2010; + + [self waitToCompleteIn:self.testCompletionDelay codeBlock:^(dispatch_block_t handler) { + self.client.push() + .audit() + .token(pushToken) + .pushType(PNMPNSPush) + .performWithCompletion(^(PNAPNSEnabledChannelsResult *result, PNErrorStatus *status) { + XCTAssertTrue(status.isError); + handler(); + }); + }]; +} + + +#pragma mark - Misc + +- (NSString *)randomTokenString { + NSString *uuidString = [@[[NSUUID UUID].UUIDString, [NSUUID UUID].UUIDString] componentsJoinedByString:@""]; + + return [[uuidString componentsSeparatedByString:@"-"] componentsJoinedByString:@""].lowercaseString; +} + #pragma mark - diff --git a/Tests/iOS Tests/Tests/PNAPNSTests.m b/Tests/iOS Tests/Tests/PNAPNSTests.m index 4a7e1c9d6..32869ef5f 100644 --- a/Tests/iOS Tests/Tests/PNAPNSTests.m +++ b/Tests/iOS Tests/Tests/PNAPNSTests.m @@ -172,10 +172,10 @@ - (void)testRemovePushNotificationFromNilChannel { PNStrongify(self); XCTAssertNotNil(status); - XCTAssertFalse(status.isError); - XCTAssertEqual(status.operation, PNRemoveAllPushNotificationsOperation, @"Wrong operation."); + XCTAssertTrue(status.isError); + XCTAssertEqual(status.operation, PNRemovePushNotificationsFromChannelsOperation, @"Wrong operation."); - XCTAssertEqual(status.statusCode, 200, @"Response status code is not 200"); + XCTAssertEqual(status.statusCode, 400, @"Response status code is not 400"); [self.testExpectation fulfill]; }]; @@ -201,7 +201,7 @@ - (void)testRemovePushNotificationFromNilChannelWithNilDevicePushToken { XCTAssertNotNil(status); XCTAssertTrue(status.isError); - XCTAssertEqual(status.operation, PNRemoveAllPushNotificationsOperation, @"Wrong operation."); + XCTAssertEqual(status.operation, PNRemovePushNotificationsFromChannelsOperation, @"Wrong operation."); XCTAssertEqual(status.statusCode, 400, @"Response status code is not 400"); diff --git a/Tests/iOS Tests/Tests/Unit/Helpers/PNNotificationPayloadBuilderTest.m b/Tests/iOS Tests/Tests/Unit/Helpers/PNNotificationPayloadBuilderTest.m new file mode 100644 index 000000000..2173df67c --- /dev/null +++ b/Tests/iOS Tests/Tests/Unit/Helpers/PNNotificationPayloadBuilderTest.m @@ -0,0 +1,828 @@ +/** +* @author Serhii Mamontov +* @copyright © 2010-2019 PubNub, Inc. +*/ +#import +#import +#import +#import +#import +#import +#import + + +NS_ASSUME_NONNULL_BEGIN + +#pragma mark Test interface declaration + +@interface PNNotificationPayloadBuilderTest : XCTestCase + + +# pragma mark - Information + +/** + * @brief Object to store keys created by platform-specific builder. + */ +@property (nonatomic, strong) NSMutableDictionary *platformPayloadStorage; + +#pragma mark - + + +@end + +NS_ASSUME_NONNULL_END + + +#pragma mark - Interface implementation + +@implementation PNNotificationPayloadBuilderTest + + +#pragma mark - Setup / Tear down + +- (void)setUp { + [super setUp]; + + + self.platformPayloadStorage = [NSMutableDictionary new]; +} + + +#pragma mark - Tests :: Notifications builder + +- (void)testNotificationBuilderConstructor_ShouldPreparePlatformSpecificBuilders_WhenCalled { + NSString *expectedTitle = [NSUUID UUID].UUIDString; + NSString *expectedBody = [NSUUID UUID].UUIDString; + + + PNNotificationsPayload *builder = [PNNotificationsPayload payloadsWithNotificationTitle:expectedTitle + body:expectedBody]; + + XCTAssertNotNil(builder.apns); + XCTAssertNotNil(builder.mpns); + XCTAssertNotNil(builder.fcm); +} + +- (void)testNotificationBuilderConstructor_ShouldPassTitleAndBodyToBuilders_WhenValuesPassed { + NSString *expectedTitle = [NSUUID UUID].UUIDString; + NSString *expectedBody = [NSUUID UUID].UUIDString; + + + PNNotificationsPayload *builder = [PNNotificationsPayload payloadsWithNotificationTitle:expectedTitle + body:expectedBody]; + + XCTAssertEqualObjects([[builder.apns dictionaryRepresentation] valueForKeyPath:@"aps.alert.title"], expectedTitle); + XCTAssertEqualObjects([[builder.apns dictionaryRepresentation] valueForKeyPath:@"aps.alert.body"], expectedBody); + XCTAssertEqualObjects([[builder.mpns dictionaryRepresentation] valueForKeyPath:@"title"], expectedTitle); + XCTAssertEqualObjects([[builder.mpns dictionaryRepresentation] valueForKeyPath:@"back_content"], expectedBody); + XCTAssertEqualObjects([[builder.fcm dictionaryRepresentation] valueForKeyPath:@"notification.title"], expectedTitle); + XCTAssertEqualObjects([[builder.fcm dictionaryRepresentation] valueForKeyPath:@"notification.body"], expectedBody); +} + +- (void)testNotificationSubtitle_ShouldPassToBuilders_WhenValueIsSet { + NSString *expectedSubtitle = [NSUUID UUID].UUIDString; + + + PNNotificationsPayload *builder = [PNNotificationsPayload payloadsWithNotificationTitle:[NSUUID UUID].UUIDString + body:[NSUUID UUID].UUIDString]; + builder.subtitle = expectedSubtitle; + + XCTAssertEqualObjects([[builder.apns dictionaryRepresentation] valueForKeyPath:@"aps.alert.subtitle"], expectedSubtitle); + XCTAssertEqualObjects([[builder.mpns dictionaryRepresentation] valueForKeyPath:@"back_title"], expectedSubtitle); + XCTAssertEqual(builder.fcm.notification.count, 2); +} + +- (void)testNotificationBadge_ShouldPassToBuilders_WhenValueIsSet { + NSNumber *expectedBadge = @11; + + + PNNotificationsPayload *builder = [PNNotificationsPayload payloadsWithNotificationTitle:[NSUUID UUID].UUIDString + body:[NSUUID UUID].UUIDString]; + builder.badge = expectedBadge; + + XCTAssertEqualObjects([[builder.apns dictionaryRepresentation] valueForKeyPath:@"aps.badge"], expectedBadge); + XCTAssertEqualObjects([[builder.mpns dictionaryRepresentation] valueForKeyPath:@"count"], expectedBadge); + XCTAssertEqual(builder.fcm.notification.count, 2); +} + +- (void)testNotificationSound_ShouldPassToBuilders_WhenValueIsSet { + NSString *expectedSound = [NSUUID UUID].UUIDString; + + + PNNotificationsPayload *builder = [PNNotificationsPayload payloadsWithNotificationTitle:[NSUUID UUID].UUIDString + body:[NSUUID UUID].UUIDString]; + builder.sound = expectedSound; + + XCTAssertEqualObjects([[builder.apns dictionaryRepresentation] valueForKeyPath:@"aps.sound"], expectedSound); + XCTAssertEqual(builder.mpns.payload.count, 2); + XCTAssertEqualObjects([[builder.fcm dictionaryRepresentation] valueForKeyPath:@"notification.sound"], expectedSound); +} + +- (void)testNotificationDebugging_ShouldSetDebugFlag_WhenDebuggingSetToYES { + PNNotificationsPayload *builder = [PNNotificationsPayload payloadsWithNotificationTitle:[NSUUID UUID].UUIDString + body:[NSUUID UUID].UUIDString]; + builder.debugging = YES; + + XCTAssertEqualObjects([builder dictionaryRepresentationFor:PNAPNSPush][@"pn_debug"], @YES); +} + +- (void)testNotificationDictionaryRepresentation_ShouldProvidePayloadForAPNSAndFCM_WhenCalledWithAPNSAndFCMPushTypes { + NSString *expectedTitle = [NSUUID UUID].UUIDString; + NSString *expectedBody = [NSUUID UUID].UUIDString; + NSDictionary *expectedPayload = @{ + @"pn_apns": @{ + @"aps": @{ + @"alert": @{ + @"title": expectedTitle, + @"body": expectedBody + } + } + }, + @"pn_gcm": @{ + @"notification": @{ + @"title": expectedTitle, + @"body": expectedBody + } + } + }; + + PNNotificationsPayload *builder = [PNNotificationsPayload payloadsWithNotificationTitle:expectedTitle + body:expectedBody]; + + XCTAssertEqualObjects([builder dictionaryRepresentationFor:PNAPNSPush|PNFCMPush], expectedPayload); +} + +- (void)testNotificationDictionaryRepresentation_ShouldProvidePayloadForAPNS2AndFCM_WhenCalledWithAPNSAndFCMPushTypes { + NSString *expectedTitle = [NSUUID UUID].UUIDString; + NSString *expectedBody = [NSUUID UUID].UUIDString; + NSDictionary *expectedPayload = @{ + @"pn_apns": @{ + @"aps": @{ + @"alert": @{ + @"title": expectedTitle, + @"body": expectedBody + } + }, + @"pn_push": @[ + @{ + @"auth_method": @"token", + @"targets": @[ + @{ + @"environment": @"development", + @"topic": NSBundle.mainBundle.bundleIdentifier + } + ], + @"version": @"v2" + } + ] + }, + @"pn_gcm": @{ + @"notification": @{ + @"title": expectedTitle, + @"body": expectedBody + } + } + }; + + PNNotificationsPayload *builder = [PNNotificationsPayload payloadsWithNotificationTitle:expectedTitle + body:expectedBody]; + + XCTAssertEqualObjects([builder dictionaryRepresentationFor:PNAPNS2Push|PNFCMPush], expectedPayload); +} + + +#pragma mark - Tests :: APNS builder + +- (void)testAPNSConstructor_ShouldSetDefaultStructure_WhenCalledOnlyWithStorage { + PNAPNSNotificationPayload *builder = [PNAPNSNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:nil + body:nil]; + + XCTAssertNotNil(builder); + XCTAssertTrue([self.platformPayloadStorage[@"aps"] isKindOfClass:[NSMutableDictionary class]]); + XCTAssertTrue([self.platformPayloadStorage[@"aps"][@"alert"] isKindOfClass:[NSMutableDictionary class]]); + XCTAssertEqual(((NSDictionary *)self.platformPayloadStorage[@"aps"]).count, 1); + XCTAssertEqual(((NSDictionary *)self.platformPayloadStorage[@"aps"][@"alert"]).count, 0); +} + +- (void)testAPNSConstructor_ShouldSetNotificationTitleBody_WhenCalledWithAllFieldsSet { + NSString *expectedTitle = [NSUUID UUID].UUIDString; + NSString *expectedBody = [NSUUID UUID].UUIDString; + + + [PNAPNSNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:expectedTitle + body:expectedBody]; + + XCTAssertEqualObjects(self.platformPayloadStorage[@"aps"][@"alert"][@"title"], expectedTitle); + XCTAssertEqualObjects(self.platformPayloadStorage[@"aps"][@"alert"][@"body"], expectedBody); +} + +- (void)testAPNSSubtitle_ShouldSet_WhenSubtitlePassedToBuilder { + NSString *expectedSubtitle = [NSUUID UUID].UUIDString; + + + PNAPNSNotificationPayload *builder = [PNAPNSNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:nil + body:nil]; + builder.subtitle = expectedSubtitle; + + XCTAssertEqualObjects(self.platformPayloadStorage[@"aps"][@"alert"][@"subtitle"], expectedSubtitle); +} + +- (void)testAPNSSubtitle_ShouldNotSet_WhenNilPassedToBuilder { + PNAPNSNotificationPayload *builder = [PNAPNSNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:nil + body:nil]; + builder.subtitle = nil; + + XCTAssertNil(self.platformPayloadStorage[@"aps"][@"alert"][@"subtitle"]); +} + +- (void)testAPNSBody_ShouldSet_WhenBodyPassedToBuilder { + NSString *expectedBody = [NSUUID UUID].UUIDString; + + + PNAPNSNotificationPayload *builder = [PNAPNSNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:nil + body:nil]; + builder.body = expectedBody; + + XCTAssertEqualObjects(self.platformPayloadStorage[@"aps"][@"alert"][@"body"], expectedBody); +} + +- (void)testAPNSBody_ShouldNotSet_WhenNilPassedToBuilder { + PNAPNSNotificationPayload *builder = [PNAPNSNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:nil + body:nil]; + builder.body = nil; + + XCTAssertNil(self.platformPayloadStorage[@"aps"][@"alert"][@"body"]); +} + +- (void)testAPNSBadge_ShouldSet_WhenBadgePassedToBuilder { + NSNumber *expectedBadge = @26; + + + PNAPNSNotificationPayload *builder = [PNAPNSNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:nil + body:nil]; + builder.badge = expectedBadge; + + XCTAssertEqualObjects(self.platformPayloadStorage[@"aps"][@"badge"], expectedBadge); +} + +- (void)testAPNSBadge_ShouldNotSet_WhenNilPassedToBuilder { + PNAPNSNotificationPayload *builder = [PNAPNSNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:nil + body:nil]; + builder.badge = nil; + + XCTAssertNil(self.platformPayloadStorage[@"aps"][@"badge"]); +} + +- (void)testAPNSSound_ShouldSet_WhenSoundPassedToBuilder { + NSString *expectedSound = [NSUUID UUID].UUIDString; + + + PNAPNSNotificationPayload *builder = [PNAPNSNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:nil + body:nil]; + builder.sound = expectedSound; + + XCTAssertEqualObjects(self.platformPayloadStorage[@"aps"][@"sound"], expectedSound); +} + +- (void)testAPNSSound_ShouldNotSet_WhenNilPassedToBuilder { + PNAPNSNotificationPayload *builder = [PNAPNSNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:nil + body:nil]; + builder.sound = nil; + + XCTAssertNil(self.platformPayloadStorage[@"aps"][@"sound"]); +} + +- (void)testAPNSDictionaryRepresentation_ShouldBeNil_WhenNoInformationPassed { + PNAPNSNotificationPayload *builder = [PNAPNSNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:nil + body:nil]; + + XCTAssertNil([builder dictionaryRepresentation]); +} + +- (void)testAPNSDictionaryRepresentation_ShouldSetContentAvailable_WhenSilentSetToYES { + PNAPNSNotificationPayload *builder = [PNAPNSNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:[NSUUID UUID].UUIDString + body:[NSUUID UUID].UUIDString]; + builder.sound = [NSUUID UUID].UUIDString; + builder.badge = @20; + builder.silent = YES; + + XCTAssertEqualObjects([builder dictionaryRepresentation][@"aps"][@"content-available"], @1); + XCTAssertNil([builder dictionaryRepresentation][@"aps"][@"badge"]); + XCTAssertNil([builder dictionaryRepresentation][@"aps"][@"sound"]); + XCTAssertNil([builder dictionaryRepresentation][@"aps"][@"alert"]); +} + +- (void)testAPNSDictionaryRepresentation_ShouldBeValid_WhenAllInformationPassed { + NSString *expectedSubtitle = [NSUUID UUID].UUIDString; + NSString *expectedTitle = [NSUUID UUID].UUIDString; + NSString *expectedSound = [NSUUID UUID].UUIDString; + NSString *expectedBody = [NSUUID UUID].UUIDString; + NSNumber *expectedBadge = @26; + NSDictionary *expectedPayload = @{ + @"aps": @{ + @"alert": @{ + @"title": expectedTitle, + @"subtitle": expectedSubtitle, + @"body": expectedBody + }, + @"badge": expectedBadge, + @"sound": expectedSound + } + }; + + + PNAPNSNotificationPayload *builder = [PNAPNSNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:expectedTitle + body:expectedBody]; + builder.subtitle = expectedSubtitle; + builder.badge = expectedBadge; + builder.sound = expectedSound; + + XCTAssertEqualObjects([builder dictionaryRepresentation], expectedPayload); +} + + +#pragma mark - Tests :: APNS over HTTP/2 builder + +- (void)testAPNS2DictionaryRepresentation_ShouldSetDefaultConfiguration_WhenCalledForAPNS2PushTypeWithOutConfiguration { + NSString *expectedSubtitle = [NSUUID UUID].UUIDString; + NSString *expectedTitle = [NSUUID UUID].UUIDString; + NSString *expectedSound = [NSUUID UUID].UUIDString; + NSString *expectedBody = [NSUUID UUID].UUIDString; + NSNumber *expectedBadge = @26; + NSDictionary *expectedPayload = @{ + @"aps": @{ + @"alert": @{ + @"title": expectedTitle, + @"subtitle": expectedSubtitle, + @"body": expectedBody + }, + @"badge": expectedBadge, + @"sound": expectedSound + }, + @"pn_push": @[ + @{ + @"auth_method": @"token", + @"targets": @[ + @{ + @"environment": @"development", + @"topic": NSBundle.mainBundle.bundleIdentifier + } + ], + @"version": @"v2" + } + ] + }; + + + PNAPNSNotificationPayload *builder = [PNAPNSNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:expectedTitle + body:expectedBody]; + builder.subtitle = expectedSubtitle; + builder.badge = expectedBadge; + builder.sound = expectedSound; + builder.apnsPushType = PNAPNS2Push; + + XCTAssertEqualObjects([builder dictionaryRepresentation], expectedPayload); +} + + +#pragma mark - Tests :: APNS over HTTP/2 builder :: Configuration + +- (void)testAPNSConfigurationConstructor_ShouldCreateWithDefaultTarget_WhenCalledDefault { + NSDictionary *expectedConfiguration = @{ + @"auth_method": @"token", + @"targets": @[ + @{ + @"environment": @"development", + @"topic": NSBundle.mainBundle.bundleIdentifier + } + ], + @"version": @"v2" + }; + + + PNAPNSNotificationConfiguration *configuration = [PNAPNSNotificationConfiguration defaultConfiguration]; + + XCTAssertEqualObjects([configuration dictionaryRepresentation], expectedConfiguration); +} + +- (void)testAPNSConfigurationConstructor_ShouldCreateWithDefaultTarget_WhenCalledWithEmptyTargetsList { + NSDictionary *expectedConfiguration = @{ + @"auth_method": @"token", + @"targets": @[ + @{ + @"environment": @"development", + @"topic": NSBundle.mainBundle.bundleIdentifier + } + ], + @"version": @"v2" + }; + + + PNAPNSNotificationConfiguration *configuration = [PNAPNSNotificationConfiguration configurationWithCollapseID:nil + expirationDate:nil + targets:@[]]; + + XCTAssertEqualObjects([configuration dictionaryRepresentation], expectedConfiguration); +} + +- (void)testAPNSConfigurationConstructor_ShouldCreateForTarget_WhenCalledWithSpecificTarget { + NSString *expectedTopic = [NSUUID UUID].UUIDString; + PNAPNSNotificationTarget *target = [PNAPNSNotificationTarget targetForTopic:expectedTopic]; + NSDictionary *expectedConfiguration = @{ + @"auth_method": @"token", + @"targets": @[ + @{ + @"environment": @"development", + @"topic": expectedTopic + } + ], + @"version": @"v2" + }; + + + PNAPNSNotificationConfiguration *configuration = [PNAPNSNotificationConfiguration configurationWithTargets:@[target]]; + + XCTAssertEqualObjects([configuration dictionaryRepresentation], expectedConfiguration); +} + +- (void)testAPNSConfigurationConstructor_ShouldCreateSpecific_WhenCalledCollapseIDExpirationAndTargets { + PNAPNSNotificationTarget *target = [PNAPNSNotificationTarget defaultTarget]; + NSDate *expectedExpirationDate = [NSDate dateWithTimeIntervalSince1970:1574892507]; + NSString *expectedCollapseID = [NSUUID UUID].UUIDString; + NSDictionary *expectedConfiguration = @{ + @"auth_method": @"token", + @"collapse_id": expectedCollapseID, + @"expiration": @"2019-11-27T22:08:27Z", + @"targets": @[ + @{ + @"environment": @"development", + @"topic": NSBundle.mainBundle.bundleIdentifier + } + ], + @"version": @"v2" + }; + + PNAPNSNotificationConfiguration *configuration = [PNAPNSNotificationConfiguration configurationWithCollapseID:expectedCollapseID + expirationDate:expectedExpirationDate + targets:@[target]]; + + XCTAssertEqualObjects([configuration dictionaryRepresentation], expectedConfiguration); +} + + +#pragma mark - Tests :: APNS over HTTP/2 builder :: Target + +- (void)testAPNSTarget_ShouldCreateForDevelopmentEnvironmentAndBundleIdentifier_WhenCalledDefault { + NSDictionary *expectedTarget = @{ + @"environment": @"development", + @"topic": NSBundle.mainBundle.bundleIdentifier + }; + + + PNAPNSNotificationTarget *target = [PNAPNSNotificationTarget defaultTarget]; + + XCTAssertEqualObjects([target dictionaryRepresentation], expectedTarget); +} + +- (void)testAPNSTarget_ShouldCreateForDevelopmentEnvironment_WhenCalledWithTopic { + NSString *expectedTopic = [NSUUID UUID].UUIDString; + NSDictionary *expectedTarget = @{ @"environment": @"development", @"topic": expectedTopic }; + + + PNAPNSNotificationTarget *target = [PNAPNSNotificationTarget targetForTopic:expectedTopic]; + + XCTAssertEqualObjects([target dictionaryRepresentation], expectedTarget); +} + +- (void)testAPNSTarget_ShouldCreateSpecific_WhenCalledWithTopicAndEnvironment { + NSData *excludedDevice = [@"000000000000000000000000000000" dataUsingEncoding:NSUTF8StringEncoding]; + NSString *expectedTopic = [NSUUID UUID].UUIDString; + NSDictionary *expectedTarget = @{ + @"environment": @"production", + @"topic": expectedTopic, + @"excluded_devices": @[[PNData HEXFromDevicePushToken:excludedDevice]] + }; + + + PNAPNSNotificationTarget *target = [PNAPNSNotificationTarget targetForTopic:expectedTopic + inEnvironment:PNAPNSProduction + withExcludedDevices:@[excludedDevice]]; + + XCTAssertEqualObjects([target dictionaryRepresentation], expectedTarget); +} + + +#pragma mark - Tests :: MPNS builder + +- (void)testMPNSConstructor_ShouldSetNotificationTitleBody_WhenCalledWithAllFieldsSet { + NSString *expectedTitle = [NSUUID UUID].UUIDString; + NSString *expectedBody = [NSUUID UUID].UUIDString; + + + [PNMPNSNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:expectedTitle + body:expectedBody]; + + XCTAssertEqualObjects(self.platformPayloadStorage[@"title"], expectedTitle); + XCTAssertEqualObjects(self.platformPayloadStorage[@"back_content"], expectedBody); +} + +- (void)testMPNSBackTitle_ShouldSet_WhenSubtitlePassedToBuilder { + NSString *expectedSubtitle = [NSUUID UUID].UUIDString; + + + PNMPNSNotificationPayload *builder = [PNMPNSNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:nil + body:nil]; + builder.subtitle = expectedSubtitle; + + XCTAssertEqualObjects(self.platformPayloadStorage[@"back_title"], expectedSubtitle); +} + +- (void)testMPNSBackTitle_ShouldSet_WhenBackTitlePassedToBuilder { + NSString *expectedSubtitle = [NSUUID UUID].UUIDString; + + + PNMPNSNotificationPayload *builder = [PNMPNSNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:nil + body:nil]; + builder.backTitle = expectedSubtitle; + + XCTAssertEqualObjects(self.platformPayloadStorage[@"back_title"], expectedSubtitle); +} + +- (void)testMPNSBackContent_ShouldSet_WhenBodyPassedToBuilder { + NSString *expectedBody = [NSUUID UUID].UUIDString; + + + PNMPNSNotificationPayload *builder = [PNMPNSNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:nil + body:nil]; + builder.body = expectedBody; + + XCTAssertEqualObjects(self.platformPayloadStorage[@"back_content"], expectedBody); +} + +- (void)testMPNSBackContent_ShouldSet_WhenBackContentPassedToBuilder { + NSString *expectedBody = [NSUUID UUID].UUIDString; + + + PNMPNSNotificationPayload *builder = [PNMPNSNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:nil + body:nil]; + builder.backContent = expectedBody; + + XCTAssertEqualObjects(self.platformPayloadStorage[@"back_content"], expectedBody); +} + +- (void)testMPNSCount_ShouldSet_WhenBadgePassedToBuilder { + NSNumber *expectedBadge = @26; + + + PNMPNSNotificationPayload *builder = [PNMPNSNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:nil + body:nil]; + builder.badge = expectedBadge; + + XCTAssertEqualObjects(self.platformPayloadStorage[@"count"], expectedBadge); +} + +- (void)testMPNSCount_ShouldSet_WhenCountPassedToBuilder { + NSNumber *expectedBadge = @26; + + + PNMPNSNotificationPayload *builder = [PNMPNSNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:nil + body:nil]; + builder.count = expectedBadge; + + XCTAssertEqualObjects(self.platformPayloadStorage[@"count"], expectedBadge); +} + +- (void)testMPNSDictionaryRepresentation_ShouldBeNil_WhenNoInformationPassed { + PNMPNSNotificationPayload *builder = [PNMPNSNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:nil + body:nil]; + + XCTAssertNil([builder dictionaryRepresentation]); +} + +- (void)testMPNSDictionaryRepresentation_ShouldBeValid_WhenAllInformationPassed { + NSString *expectedSubtitle = [NSUUID UUID].UUIDString; + NSString *expectedTitle = [NSUUID UUID].UUIDString; + NSString *expectedBody = [NSUUID UUID].UUIDString; + NSNumber *expectedCount = @26; + NSDictionary *expectedPayload = @{ + @"type": @"flip", + @"title": expectedTitle, + @"back_title": expectedSubtitle, + @"back_content": expectedBody, + @"count": expectedCount + }; + + + PNMPNSNotificationPayload *builder = [PNMPNSNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:expectedTitle + body:expectedBody]; + builder.type = @"flip"; + builder.subtitle = expectedSubtitle; + builder.count = expectedCount; + + XCTAssertEqualObjects([builder dictionaryRepresentation], expectedPayload); +} + + +#pragma mark - Tests :: FCM builder + +- (void)testFCMConstructor_ShouldSetDefaultStructure_WhenCalledOnlyWithStorage { + PNFCMNotificationPayload *builder = [PNFCMNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:nil + body:nil]; + + XCTAssertNotNil(builder); + XCTAssertTrue([self.platformPayloadStorage[@"notification"] isKindOfClass:[NSMutableDictionary class]]); + XCTAssertTrue([self.platformPayloadStorage[@"data"] isKindOfClass:[NSMutableDictionary class]]); +} + +- (void)testFCMSConstructor_ShouldSetNotificationTitleBody_WhenCalledWithAllFieldsSet { + NSString *expectedTitle = [NSUUID UUID].UUIDString; + NSString *expectedBody = [NSUUID UUID].UUIDString; + + + [PNFCMNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:expectedTitle + body:expectedBody]; + + XCTAssertEqualObjects(self.platformPayloadStorage[@"notification"][@"title"], expectedTitle); + XCTAssertEqualObjects(self.platformPayloadStorage[@"notification"][@"body"], expectedBody); +} + +- (void)testFCMSubtitle_ShouldNotSet_WhenPassedToBuilderBecauseNotSupported { + PNFCMNotificationPayload *builder = [PNFCMNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:nil + body:nil]; + builder.subtitle = [NSUUID UUID].UUIDString; + + XCTAssertEqual(builder.notification.count, 0); +} + +- (void)testFCMBody_ShouldSet_WhenBodyPassedToBuilder { + NSString *expectedBody = [NSUUID UUID].UUIDString; + + + PNFCMNotificationPayload *builder = [PNFCMNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:nil + body:nil]; + builder.body = expectedBody; + + XCTAssertEqualObjects(self.platformPayloadStorage[@"notification"][@"body"], expectedBody); +} + +- (void)testFCMBody_ShouldNotSet_WhenNilPassedToBuilder { + PNFCMNotificationPayload *builder = [PNFCMNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:nil + body:nil]; + builder.body = nil; + + XCTAssertNil(self.platformPayloadStorage[@"notification"][@"body"]); +} + +- (void)testFCMSBadge_ShouldNotSet_WhenPassedToBuilderBecauseNotSupported { + PNFCMNotificationPayload *builder = [PNFCMNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:nil + body:nil]; + builder.badge = @30; + + XCTAssertEqual(builder.notification.count, 0); +} + +- (void)testFCMSSound_ShouldSet_WhenSoundPassedToBuilder { + NSString *expectedSound = [NSUUID UUID].UUIDString; + + + PNFCMNotificationPayload *builder = [PNFCMNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:nil + body:nil]; + builder.sound = expectedSound; + + XCTAssertEqualObjects(self.platformPayloadStorage[@"notification"][@"sound"], expectedSound); +} + +- (void)testFCMSSound_ShouldNotSet_WhenNilPassedToBuilder { + PNFCMNotificationPayload *builder = [PNFCMNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:nil + body:nil]; + builder.sound = nil; + + XCTAssertNil(self.platformPayloadStorage[@"notification"][@"sound"]); +} + +- (void)testFCMSIcon_ShouldSet_WhenSoundPassedToBuilder { + NSString *expectedIcon = [NSUUID UUID].UUIDString; + + + PNFCMNotificationPayload *builder = [PNFCMNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:nil + body:nil]; + builder.icon = expectedIcon; + + XCTAssertEqualObjects(self.platformPayloadStorage[@"notification"][@"icon"], expectedIcon); +} + +- (void)testFCMSIcon_ShouldNotSet_WhenNilPassedToBuilder { + PNFCMNotificationPayload *builder = [PNFCMNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:nil + body:nil]; + builder.icon = nil; + + XCTAssertNil(self.platformPayloadStorage[@"notification"][@"icon"]); +} + +- (void)testFCMSTag_ShouldSet_WhenSoundPassedToBuilder { + NSString *expectedTag = [NSUUID UUID].UUIDString; + + + PNFCMNotificationPayload *builder = [PNFCMNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:nil + body:nil]; + builder.tag = expectedTag; + + XCTAssertEqualObjects(self.platformPayloadStorage[@"notification"][@"tag"], expectedTag); +} + +- (void)testFCMSTag_ShouldNotSet_WhenNilPassedToBuilder { + PNFCMNotificationPayload *builder = [PNFCMNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:nil + body:nil]; + builder.tag = nil; + + XCTAssertNil(self.platformPayloadStorage[@"notification"][@"tag"]); +} + +- (void)testFCMDictionaryRepresentation_ShouldBeNil_WhenNoInformationPassed { + PNFCMNotificationPayload *builder = [PNFCMNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:nil + body:nil]; + + XCTAssertNil([builder dictionaryRepresentation]); +} + +- (void)testFCMDictionaryRepresentation_ShouldMoveNotificationToData_WhenSilentSetToYES { + NSString *expectedSound = [NSUUID UUID].UUIDString; + NSString *expectedTitle = [NSUUID UUID].UUIDString; + NSString *expectedBody = [NSUUID UUID].UUIDString; + NSDictionary *expectedNotification = @{ + @"title": expectedTitle, + @"body": expectedBody, + @"sound": expectedSound + }; + + PNFCMNotificationPayload *builder = [PNFCMNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:expectedTitle + body:expectedBody]; + builder.sound = expectedSound; + builder.silent = YES; + + XCTAssertNil([builder dictionaryRepresentation][@"notification"]); + XCTAssertEqualObjects([builder dictionaryRepresentation][@"data"][@"notification"], expectedNotification); +} + +- (void)testFCMDictionaryRepresentation_ShouldBeValid_WhenAllInformationPassed { + NSString *expectedSound = [NSUUID UUID].UUIDString; + NSString *expectedTitle = [NSUUID UUID].UUIDString; + NSString *expectedBody = [NSUUID UUID].UUIDString; + NSDictionary *expectedPayload = @{ + @"notification": @{ + @"title": expectedTitle, + @"body": expectedBody, + @"sound": expectedSound + } + }; + + + PNFCMNotificationPayload *builder = [PNFCMNotificationPayload payloadWithStorage:self.platformPayloadStorage + notificationTitle:expectedTitle + body:expectedBody]; + builder.sound = expectedSound; + + XCTAssertEqualObjects([builder dictionaryRepresentation], expectedPayload); +} + +#pragma mark - + + +@end diff --git a/VERSION b/VERSION index d782fca8f..815588ef1 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -4.11.1 +4.12.0