./.codecov.yml .clang-format .gitmodules .releaserc/commit.hbs .releaserc/footer.hbs .releaserc/header.hbs .releaserc/template.hbs .ruby-version Cartfile Cartfile.resolved Carthage/Checkouts/Bolts-ObjC Carthage/Checkouts/OCMock Carthage/Checkouts/facebook-ios-sdk Gemfile Gemfile.lock LICENSE PATENTS Parse.podspec Parse.xcworkspace/contents.xcworkspacedata Parse.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist Parse.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings Parse/Configurations/Parse-iOS-Dynamic.xcconfig Parse/Configurations/Parse-iOS.xcconfig Parse/Configurations/Parse-macOS.xcconfig Parse/Configurations/Parse-tvOS-Dynamic.xcconfig Parse/Configurations/Parse-tvOS.xcconfig Parse/Configurations/Parse-watchOS-Dynamic.xcconfig Parse/Configurations/Parse-watchOS.xcconfig Parse/Configurations/ParseUnitTests-iOS.xcconfig Parse/Configurations/ParseUnitTests-macOS.xcconfig Parse/Configurations/Shared Parse/Parse.xcodeproj/project.pbxproj Parse/Parse.xcodeproj/project.xcworkspace/contents.xcworkspacedata Parse/Parse.xcodeproj/xcshareddata/xcschemes/Parse-iOS-Dynamic.xcscheme Parse/Parse.xcodeproj/xcshareddata/xcschemes/Parse-iOS.xcscheme Parse/Parse.xcodeproj/xcshareddata/xcschemes/Parse-macOS.xcscheme Parse/Parse.xcodeproj/xcshareddata/xcschemes/Parse-tvOS-Dynamic.xcscheme Parse/Parse.xcodeproj/xcshareddata/xcschemes/Parse-tvOS.xcscheme Parse/Parse.xcodeproj/xcshareddata/xcschemes/Parse-watchOS-Dynamic.xcscheme Parse/Parse.xcodeproj/xcshareddata/xcschemes/Parse-watchOS.xcscheme Parse/Parse/Internal/ACL/DefaultACLController/PFDefaultACLController.h Parse/Parse/Internal/ACL/DefaultACLController/PFDefaultACLController.m Parse/Parse/Internal/ACL/PFACLPrivate.h Parse/Parse/Internal/ACL/State/PFACLState.h Parse/Parse/Internal/ACL/State/PFACLState.m Parse/Parse/Internal/ACL/State/PFACLState_Private.h Parse/Parse/Internal/ACL/State/PFMutableACLState.h Parse/Parse/Internal/ACL/State/PFMutableACLState.m Parse/Parse/Internal/Analytics/Controller/PFAnalyticsController.h Parse/Parse/Internal/Analytics/Controller/PFAnalyticsController.m Parse/Parse/Internal/Analytics/PFAnalytics_Private.h Parse/Parse/Internal/Analytics/Utilities/PFAnalyticsUtilities.h Parse/Parse/Internal/Analytics/Utilities/PFAnalyticsUtilities.m Parse/Parse/Internal/BFTask+Private.h Parse/Parse/Internal/BFTask+Private.m Parse/Parse/Internal/CloudCode/PFCloudCodeController.h Parse/Parse/Internal/CloudCode/PFCloudCodeController.m Parse/Parse/Internal/Commands/CommandRunner/PFCommandRunning.h Parse/Parse/Internal/Commands/CommandRunner/PFCommandRunning.m Parse/Parse/Internal/Commands/CommandRunner/PFCommandRunningConstants.h Parse/Parse/Internal/Commands/CommandRunner/PFCommandRunningConstants.m Parse/Parse/Internal/Commands/CommandRunner/URLRequestConstructor/PFCommandURLRequestConstructor.h Parse/Parse/Internal/Commands/CommandRunner/URLRequestConstructor/PFCommandURLRequestConstructor.m Parse/Parse/Internal/Commands/CommandRunner/URLSession/PFURLSessionCommandRunner.h Parse/Parse/Internal/Commands/CommandRunner/URLSession/PFURLSessionCommandRunner.m Parse/Parse/Internal/Commands/CommandRunner/URLSession/PFURLSessionCommandRunner_Private.h Parse/Parse/Internal/Commands/CommandRunner/URLSession/Session/PFURLSession.h Parse/Parse/Internal/Commands/CommandRunner/URLSession/Session/PFURLSession.m Parse/Parse/Internal/Commands/CommandRunner/URLSession/Session/PFURLSession_Private.h Parse/Parse/Internal/Commands/CommandRunner/URLSession/Session/TaskDelegate/PFURLSessionDataTaskDelegate.h Parse/Parse/Internal/Commands/CommandRunner/URLSession/Session/TaskDelegate/PFURLSessionDataTaskDelegate.m Parse/Parse/Internal/Commands/CommandRunner/URLSession/Session/TaskDelegate/PFURLSessionDataTaskDelegate_Private.h Parse/Parse/Internal/Commands/CommandRunner/URLSession/Session/TaskDelegate/PFURLSessionFileDownloadTaskDelegate.h Parse/Parse/Internal/Commands/CommandRunner/URLSession/Session/TaskDelegate/PFURLSessionFileDownloadTaskDelegate.m Parse/Parse/Internal/Commands/CommandRunner/URLSession/Session/TaskDelegate/PFURLSessionJSONDataTaskDelegate.h Parse/Parse/Internal/Commands/CommandRunner/URLSession/Session/TaskDelegate/PFURLSessionJSONDataTaskDelegate.m Parse/Parse/Internal/Commands/CommandRunner/URLSession/Session/TaskDelegate/PFURLSessionUploadTaskDelegate.h Parse/Parse/Internal/Commands/CommandRunner/URLSession/Session/TaskDelegate/PFURLSessionUploadTaskDelegate.m Parse/Parse/Internal/Commands/PFRESTAnalyticsCommand.h Parse/Parse/Internal/Commands/PFRESTAnalyticsCommand.m Parse/Parse/Internal/Commands/PFRESTCloudCommand.h Parse/Parse/Internal/Commands/PFRESTCloudCommand.m Parse/Parse/Internal/Commands/PFRESTCommand.h Parse/Parse/Internal/Commands/PFRESTCommand.m Parse/Parse/Internal/Commands/PFRESTCommand_Private.h Parse/Parse/Internal/Commands/PFRESTConfigCommand.h Parse/Parse/Internal/Commands/PFRESTConfigCommand.m Parse/Parse/Internal/Commands/PFRESTFileCommand.h Parse/Parse/Internal/Commands/PFRESTFileCommand.m Parse/Parse/Internal/Commands/PFRESTObjectBatchCommand.h Parse/Parse/Internal/Commands/PFRESTObjectBatchCommand.m Parse/Parse/Internal/Commands/PFRESTObjectCommand.h Parse/Parse/Internal/Commands/PFRESTObjectCommand.m Parse/Parse/Internal/Commands/PFRESTPushCommand.h Parse/Parse/Internal/Commands/PFRESTPushCommand.m Parse/Parse/Internal/Commands/PFRESTQueryCommand.h Parse/Parse/Internal/Commands/PFRESTQueryCommand.m Parse/Parse/Internal/Commands/PFRESTSessionCommand.h Parse/Parse/Internal/Commands/PFRESTSessionCommand.m Parse/Parse/Internal/Commands/PFRESTUserCommand.h Parse/Parse/Internal/Commands/PFRESTUserCommand.m Parse/Parse/Internal/Config/Controller/PFConfigController.h Parse/Parse/Internal/Config/Controller/PFConfigController.m Parse/Parse/Internal/Config/Controller/PFCurrentConfigController.h Parse/Parse/Internal/Config/Controller/PFCurrentConfigController.m Parse/Parse/Internal/Config/PFConfig_Private.h Parse/Parse/Internal/FieldOperation/PFFieldOperation.h Parse/Parse/Internal/FieldOperation/PFFieldOperation.m Parse/Parse/Internal/FieldOperation/PFFieldOperationDecoder.h Parse/Parse/Internal/FieldOperation/PFFieldOperationDecoder.m Parse/Parse/Internal/File/Controller/PFFileController.h Parse/Parse/Internal/File/Controller/PFFileController.m Parse/Parse/Internal/File/Controller/PFFileStagingController.h Parse/Parse/Internal/File/Controller/PFFileStagingController.m Parse/Parse/Internal/File/Controller/PFFileUploadResult.m Parse/Parse/Internal/File/FileDataStream/PFFileDataStream.h Parse/Parse/Internal/File/FileDataStream/PFFileDataStream.m Parse/Parse/Internal/File/PFFileObject_Private.h Parse/Parse/Internal/File/State/PFFileState.h Parse/Parse/Internal/File/State/PFFileState.m Parse/Parse/Internal/File/State/PFFileState_Private.h Parse/Parse/Internal/File/State/PFMutableFileState.h Parse/Parse/Internal/File/State/PFMutableFileState.m Parse/Parse/Internal/HTTPRequest/PFHTTPRequest.h Parse/Parse/Internal/HTTPRequest/PFHTTPURLRequestConstructor.h Parse/Parse/Internal/HTTPRequest/PFHTTPURLRequestConstructor.m Parse/Parse/Internal/HTTPRequest/PFURLConstructor.h Parse/Parse/Internal/HTTPRequest/PFURLConstructor.m Parse/Parse/Internal/Installation/Constants/PFInstallationConstants.h Parse/Parse/Internal/Installation/Constants/PFInstallationConstants.m Parse/Parse/Internal/Installation/Controller/PFInstallationController.h Parse/Parse/Internal/Installation/Controller/PFInstallationController.m Parse/Parse/Internal/Installation/CurrentInstallationController/PFCurrentInstallationController.h Parse/Parse/Internal/Installation/CurrentInstallationController/PFCurrentInstallationController.m Parse/Parse/Internal/Installation/InstallationIdentifierStore/PFInstallationIdentifierStore.h Parse/Parse/Internal/Installation/InstallationIdentifierStore/PFInstallationIdentifierStore.m Parse/Parse/Internal/Installation/InstallationIdentifierStore/PFInstallationIdentifierStore_Private.h Parse/Parse/Internal/Installation/PFInstallationPrivate.h Parse/Parse/Internal/KeyValueCache/PFKeyValueCache.h Parse/Parse/Internal/KeyValueCache/PFKeyValueCache.m Parse/Parse/Internal/KeyValueCache/PFKeyValueCache_Private.h Parse/Parse/Internal/LocalDataStore/OfflineQueryLogic/PFOfflineQueryLogic.h Parse/Parse/Internal/LocalDataStore/OfflineQueryLogic/PFOfflineQueryLogic.m Parse/Parse/Internal/LocalDataStore/OfflineStore/PFOfflineStore.h Parse/Parse/Internal/LocalDataStore/OfflineStore/PFOfflineStore.m Parse/Parse/Internal/LocalDataStore/Pin/PFPin.h Parse/Parse/Internal/LocalDataStore/Pin/PFPin.m Parse/Parse/Internal/LocalDataStore/SQLite/PFSQLiteDatabase.h Parse/Parse/Internal/LocalDataStore/SQLite/PFSQLiteDatabase.m Parse/Parse/Internal/LocalDataStore/SQLite/PFSQLiteDatabaseController.h Parse/Parse/Internal/LocalDataStore/SQLite/PFSQLiteDatabaseController.m Parse/Parse/Internal/LocalDataStore/SQLite/PFSQLiteDatabaseResult.h Parse/Parse/Internal/LocalDataStore/SQLite/PFSQLiteDatabaseResult.m Parse/Parse/Internal/LocalDataStore/SQLite/PFSQLiteDatabase_Private.h Parse/Parse/Internal/LocalDataStore/SQLite/PFSQLiteStatement.h Parse/Parse/Internal/LocalDataStore/SQLite/PFSQLiteStatement.m Parse/Parse/Internal/MultiProcessLock/PFMultiProcessFileLock.h Parse/Parse/Internal/MultiProcessLock/PFMultiProcessFileLock.m Parse/Parse/Internal/MultiProcessLock/PFMultiProcessFileLockController.h Parse/Parse/Internal/MultiProcessLock/PFMultiProcessFileLockController.m Parse/Parse/Internal/Object/BatchController/PFObjectBatchController.h Parse/Parse/Internal/Object/BatchController/PFObjectBatchController.m Parse/Parse/Internal/Object/Coder/File/PFObjectFileCoder.h Parse/Parse/Internal/Object/Coder/File/PFObjectFileCoder.m Parse/Parse/Internal/Object/Coder/File/PFObjectFileCodingLogic.h Parse/Parse/Internal/Object/Coder/File/PFObjectFileCodingLogic.m Parse/Parse/Internal/Object/Constants/PFObjectConstants.h Parse/Parse/Internal/Object/Constants/PFObjectConstants.m Parse/Parse/Internal/Object/Controller/OfflineController/PFOfflineObjectController.h Parse/Parse/Internal/Object/Controller/OfflineController/PFOfflineObjectController.m Parse/Parse/Internal/Object/Controller/PFObjectController.h Parse/Parse/Internal/Object/Controller/PFObjectController.m Parse/Parse/Internal/Object/Controller/PFObjectController_Private.h Parse/Parse/Internal/Object/Controller/PFObjectControlling.h Parse/Parse/Internal/Object/CurrentController/PFCurrentObjectControlling.h Parse/Parse/Internal/Object/EstimatedData/PFObjectEstimatedData.h Parse/Parse/Internal/Object/EstimatedData/PFObjectEstimatedData.m Parse/Parse/Internal/Object/FilePersistence/PFObjectFilePersistenceController.h Parse/Parse/Internal/Object/FilePersistence/PFObjectFilePersistenceController.m Parse/Parse/Internal/Object/LocalIdStore/PFObjectLocalIdStore.h Parse/Parse/Internal/Object/LocalIdStore/PFObjectLocalIdStore.m Parse/Parse/Internal/Object/OperationSet/PFOperationSet.h Parse/Parse/Internal/Object/OperationSet/PFOperationSet.m Parse/Parse/Internal/Object/PFObjectPrivate.h Parse/Parse/Internal/Object/PinningStore/PFPinningObjectStore.h Parse/Parse/Internal/Object/PinningStore/PFPinningObjectStore.m Parse/Parse/Internal/Object/State/PFMutableObjectState.h Parse/Parse/Internal/Object/State/PFMutableObjectState.m Parse/Parse/Internal/Object/State/PFObjectState.h Parse/Parse/Internal/Object/State/PFObjectState.m Parse/Parse/Internal/Object/State/PFObjectState_Private.h Parse/Parse/Internal/Object/Subclassing/PFObjectSubclassInfo.h Parse/Parse/Internal/Object/Subclassing/PFObjectSubclassInfo.m Parse/Parse/Internal/Object/Subclassing/PFObjectSubclassingController.h Parse/Parse/Internal/Object/Subclassing/PFObjectSubclassingController.m Parse/Parse/Internal/Object/Utilities/PFObjectUtilities.h Parse/Parse/Internal/Object/Utilities/PFObjectUtilities.m Parse/Parse/Internal/PFAlertView.h Parse/Parse/Internal/PFAlertView.m Parse/Parse/Internal/PFApplication.h Parse/Parse/Internal/PFApplication.m Parse/Parse/Internal/PFAssert.h Parse/Parse/Internal/PFAsyncTaskQueue.h Parse/Parse/Internal/PFAsyncTaskQueue.m Parse/Parse/Internal/PFBase64Encoder.h Parse/Parse/Internal/PFBase64Encoder.m Parse/Parse/Internal/PFBaseState.h Parse/Parse/Internal/PFBaseState.m Parse/Parse/Internal/PFCategoryLoader.h Parse/Parse/Internal/PFCategoryLoader.m Parse/Parse/Internal/PFCommandCache.h Parse/Parse/Internal/PFCommandCache.m Parse/Parse/Internal/PFCommandCache_Private.h Parse/Parse/Internal/PFCommandResult.h Parse/Parse/Internal/PFCommandResult.m Parse/Parse/Internal/PFCoreDataProvider.h Parse/Parse/Internal/PFCoreManager.h Parse/Parse/Internal/PFCoreManager.m Parse/Parse/Internal/PFDataProvider.h Parse/Parse/Internal/PFDateFormatter.h Parse/Parse/Internal/PFDateFormatter.m Parse/Parse/Internal/PFDevice.h Parse/Parse/Internal/PFDevice.m Parse/Parse/Internal/PFErrorUtilities.h Parse/Parse/Internal/PFErrorUtilities.m Parse/Parse/Internal/PFEventuallyPin.h Parse/Parse/Internal/PFEventuallyPin.m Parse/Parse/Internal/PFEventuallyQueue.h Parse/Parse/Internal/PFEventuallyQueue.m Parse/Parse/Internal/PFEventuallyQueue_Private.h Parse/Parse/Internal/PFFileManager.h Parse/Parse/Internal/PFFileManager.m Parse/Parse/Internal/PFGeoPointPrivate.h Parse/Parse/Internal/PFHash.h Parse/Parse/Internal/PFHash.m Parse/Parse/Internal/PFInternalUtils.h Parse/Parse/Internal/PFInternalUtils.m Parse/Parse/Internal/PFJSONSerialization.h Parse/Parse/Internal/PFJSONSerialization.m Parse/Parse/Internal/PFKeychainStore.h Parse/Parse/Internal/PFKeychainStore.m Parse/Parse/Internal/PFLocationManager.h Parse/Parse/Internal/PFLocationManager.m Parse/Parse/Internal/PFLogging.h Parse/Parse/Internal/PFMacros.h Parse/Parse/Internal/PFMemoryEventuallyQueue.h Parse/Parse/Internal/PFMemoryEventuallyQueue.m Parse/Parse/Internal/PFMulticastDelegate.h Parse/Parse/Internal/PFMulticastDelegate.m Parse/Parse/Internal/PFNetworkCommand.h Parse/Parse/Internal/PFPinningEventuallyQueue.h Parse/Parse/Internal/PFPinningEventuallyQueue.m Parse/Parse/Internal/PFPolygonPrivate.h Parse/Parse/Internal/PFReachability.h Parse/Parse/Internal/PFReachability.m Parse/Parse/Internal/PFSystemLogger.h Parse/Parse/Internal/PFSystemLogger.m Parse/Parse/Internal/PFTaskQueue.h Parse/Parse/Internal/PFTaskQueue.m Parse/Parse/Internal/PFWeakValue.h Parse/Parse/Internal/PFWeakValue.m Parse/Parse/Internal/ParseClientConfiguration_Private.h Parse/Parse/Internal/ParseInternal.h Parse/Parse/Internal/ParseManager.h Parse/Parse/Internal/ParseManager.m Parse/Parse/Internal/ParseManagerPrivate.h Parse/Parse/Internal/ParseModule.h Parse/Parse/Internal/ParseModule.m Parse/Parse/Internal/Parse_Private.h Parse/Parse/Internal/Persistence/Group/PFFilePersistenceGroup.h Parse/Parse/Internal/Persistence/Group/PFFilePersistenceGroup.m Parse/Parse/Internal/Persistence/Group/PFPersistenceGroup.h Parse/Parse/Internal/Persistence/Group/PFUserDefaultsPersistenceGroup.h Parse/Parse/Internal/Persistence/Group/PFUserDefaultsPersistenceGroup.m Parse/Parse/Internal/Persistence/PFPersistenceController.h Parse/Parse/Internal/Persistence/PFPersistenceController.m Parse/Parse/Internal/Product/PFProduct+Private.h Parse/Parse/Internal/Product/ProductsRequestHandler/PFProductsRequestHandler.h Parse/Parse/Internal/Product/ProductsRequestHandler/PFProductsRequestHandler.m Parse/Parse/Internal/PropertyInfo/PFPropertyInfo.h Parse/Parse/Internal/PropertyInfo/PFPropertyInfo.m Parse/Parse/Internal/PropertyInfo/PFPropertyInfo_Private.h Parse/Parse/Internal/PropertyInfo/PFPropertyInfo_Runtime.h Parse/Parse/Internal/PropertyInfo/PFPropertyInfo_Runtime.m Parse/Parse/Internal/Purchase/Controller/PFPurchaseController.h Parse/Parse/Internal/Purchase/Controller/PFPurchaseController.m Parse/Parse/Internal/Purchase/PaymentTransactionObserver/PFPaymentTransactionObserver.h Parse/Parse/Internal/Purchase/PaymentTransactionObserver/PFPaymentTransactionObserver.m Parse/Parse/Internal/Purchase/PaymentTransactionObserver/PFPaymentTransactionObserver_Private.h Parse/Parse/Internal/Push/ChannelsController/PFPushChannelsController.h Parse/Parse/Internal/Push/ChannelsController/PFPushChannelsController.m Parse/Parse/Internal/Push/Controller/PFPushController.h Parse/Parse/Internal/Push/Controller/PFPushController.m Parse/Parse/Internal/Push/Manager/PFPushManager.h Parse/Parse/Internal/Push/Manager/PFPushManager.m Parse/Parse/Internal/Push/PFPushPrivate.h Parse/Parse/Internal/Push/State/PFMutablePushState.h Parse/Parse/Internal/Push/State/PFMutablePushState.m Parse/Parse/Internal/Push/State/PFPushState.h Parse/Parse/Internal/Push/State/PFPushState.m Parse/Parse/Internal/Push/State/PFPushState_Private.h Parse/Parse/Internal/Push/Utilites/PFPushUtilities.h Parse/Parse/Internal/Push/Utilites/PFPushUtilities.m Parse/Parse/Internal/Query/Controller/PFCachedQueryController.h Parse/Parse/Internal/Query/Controller/PFCachedQueryController.m Parse/Parse/Internal/Query/Controller/PFOfflineQueryController.h Parse/Parse/Internal/Query/Controller/PFOfflineQueryController.m Parse/Parse/Internal/Query/Controller/PFQueryController.h Parse/Parse/Internal/Query/Controller/PFQueryController.m Parse/Parse/Internal/Query/PFQueryConstants.h Parse/Parse/Internal/Query/PFQueryConstants.m Parse/Parse/Internal/Query/PFQueryPrivate.h Parse/Parse/Internal/Query/State/PFMutableQueryState.h Parse/Parse/Internal/Query/State/PFMutableQueryState.m Parse/Parse/Internal/Query/State/PFQueryState.h Parse/Parse/Internal/Query/State/PFQueryState.m Parse/Parse/Internal/Query/State/PFQueryState_Private.h Parse/Parse/Internal/Query/Utilities/PFQueryUtilities.h Parse/Parse/Internal/Query/Utilities/PFQueryUtilities.m Parse/Parse/Internal/Relation/PFRelationPrivate.h Parse/Parse/Internal/Relation/State/PFMutableRelationState.h Parse/Parse/Internal/Relation/State/PFMutableRelationState.m Parse/Parse/Internal/Relation/State/PFRelationState.h Parse/Parse/Internal/Relation/State/PFRelationState.m Parse/Parse/Internal/Relation/State/PFRelationState_Private.h Parse/Parse/Internal/Session/Controller/PFSessionController.h Parse/Parse/Internal/Session/Controller/PFSessionController.m Parse/Parse/Internal/Session/PFSession_Private.h Parse/Parse/Internal/Session/Utilities/PFSessionUtilities.h Parse/Parse/Internal/Session/Utilities/PFSessionUtilities.m Parse/Parse/Internal/ThreadSafety/PFThreadsafety.h Parse/Parse/Internal/ThreadSafety/PFThreadsafety.m Parse/Parse/Internal/User/AuthenticationProviders/Controller/PFUserAuthenticationController.h Parse/Parse/Internal/User/AuthenticationProviders/Controller/PFUserAuthenticationController.m Parse/Parse/Internal/User/AuthenticationProviders/Providers/Anonymous/PFAnonymousAuthenticationProvider.h Parse/Parse/Internal/User/AuthenticationProviders/Providers/Anonymous/PFAnonymousAuthenticationProvider.m Parse/Parse/Internal/User/AuthenticationProviders/Providers/Anonymous/PFAnonymousUtils_Private.h Parse/Parse/Internal/User/Coder/File/PFUserFileCodingLogic.h Parse/Parse/Internal/User/Coder/File/PFUserFileCodingLogic.m Parse/Parse/Internal/User/Constants/PFUserConstants.h Parse/Parse/Internal/User/Constants/PFUserConstants.m Parse/Parse/Internal/User/Controller/PFUserController.h Parse/Parse/Internal/User/Controller/PFUserController.m Parse/Parse/Internal/User/CurrentUserController/PFCurrentUserController.h Parse/Parse/Internal/User/CurrentUserController/PFCurrentUserController.m Parse/Parse/Internal/User/PFUserPrivate.h Parse/Parse/Internal/User/State/PFMutableUserState.h Parse/Parse/Internal/User/State/PFMutableUserState.m Parse/Parse/Internal/User/State/PFUserState.h Parse/Parse/Internal/User/State/PFUserState.m Parse/Parse/Internal/User/State/PFUserState_Private.h Parse/Parse/PFACL.h Parse/Parse/PFACL.m Parse/Parse/PFAnalytics.h Parse/Parse/PFAnalytics.m Parse/Parse/PFAnonymousUtils+Deprecated.h Parse/Parse/PFAnonymousUtils.h Parse/Parse/PFAnonymousUtils.m Parse/Parse/PFCloud+Deprecated.h Parse/Parse/PFCloud+Synchronous.h Parse/Parse/PFCloud.h Parse/Parse/PFCloud.m Parse/Parse/PFConfig+Synchronous.h Parse/Parse/PFConfig.h Parse/Parse/PFConfig.m Parse/Parse/PFConstants.h Parse/Parse/PFConstants.m Parse/Parse/PFDecoder.h Parse/Parse/PFDecoder.m Parse/Parse/PFEncoder.h Parse/Parse/PFEncoder.m Parse/Parse/PFFileObject+Deprecated.h Parse/Parse/PFFileObject+Synchronous.h Parse/Parse/PFFileObject.h Parse/Parse/PFFileObject.m Parse/Parse/PFFileUploadController.h Parse/Parse/PFFileUploadResult.h Parse/Parse/PFGeoPoint.h Parse/Parse/PFGeoPoint.m Parse/Parse/PFInstallation.h Parse/Parse/PFInstallation.m Parse/Parse/PFNetworkActivityIndicatorManager.h Parse/Parse/PFNetworkActivityIndicatorManager.m Parse/Parse/PFObject+Deprecated.h Parse/Parse/PFObject+Subclass.h Parse/Parse/PFObject+Synchronous.h Parse/Parse/PFObject.h Parse/Parse/PFObject.m Parse/Parse/PFPolygon.h Parse/Parse/PFPolygon.m Parse/Parse/PFProduct.h Parse/Parse/PFProduct.m Parse/Parse/PFPurchase.h Parse/Parse/PFPurchase.m Parse/Parse/PFPush+Deprecated.h Parse/Parse/PFPush+Synchronous.h Parse/Parse/PFPush.h Parse/Parse/PFPush.m Parse/Parse/PFQuery+Deprecated.h Parse/Parse/PFQuery+Synchronous.h Parse/Parse/PFQuery.h Parse/Parse/PFQuery.m Parse/Parse/PFRelation.h Parse/Parse/PFRelation.m Parse/Parse/PFRole.h Parse/Parse/PFRole.m Parse/Parse/PFSession.h Parse/Parse/PFSession.m Parse/Parse/PFSubclassing.h Parse/Parse/PFUser+Deprecated.h Parse/Parse/PFUser+Synchronous.h Parse/Parse/PFUser.h Parse/Parse/PFUser.m Parse/Parse/PFUserAuthenticationDelegate.h Parse/Parse/Parse.h Parse/Parse/Parse.m Parse/Parse/ParseClientConfiguration.h Parse/Parse/ParseClientConfiguration.m Parse/Parse/Resources/Parse-OSX.Info.plist Parse/Parse/Resources/Parse-iOS.Info.plist Parse/Parse/Resources/Parse-tvOS.Info.plist Parse/Parse/Resources/Parse-watchOS.Info.plist Parse/Parse/Resources/en.lproj/Parse.strings Parse/ParseUnitTests-iOS-host/AppDelegate.h Parse/ParseUnitTests-iOS-host/AppDelegate.m Parse/ParseUnitTests-iOS-host/Assets.xcassets/AppIcon.appiconset/Contents.json Parse/ParseUnitTests-iOS-host/Info.plist Parse/ParseUnitTests-iOS-host/Main.storyboard Parse/ParseUnitTests-iOS-host/ViewController.h Parse/ParseUnitTests-iOS-host/ViewController.m Parse/ParseUnitTests-iOS-host/main.m Parse/Tests/Other/Cache/TestCache.h Parse/Tests/Other/Cache/TestCache.m Parse/Tests/Other/ExtensionDataSharing/PFExtensionDataSharingTestHelper.h Parse/Tests/Other/ExtensionDataSharing/PFExtensionDataSharingTestHelper.m Parse/Tests/Other/FileManager/TestFileManager.h Parse/Tests/Other/FileManager/TestFileManager.m Parse/Tests/Other/LocationManager/CLLocationManager+TestAdditions.h Parse/Tests/Other/LocationManager/CLLocationManager+TestAdditions.m Parse/Tests/Other/NetworkMocking/PFMockURLProtocol.h Parse/Tests/Other/NetworkMocking/PFMockURLProtocol.m Parse/Tests/Other/NetworkMocking/PFMockURLResponse.h Parse/Tests/Other/NetworkMocking/PFMockURLResponse.m Parse/Tests/Other/OCMock/OCMock+Parse.h Parse/Tests/Other/OCMock/OCMock+Parse.m Parse/Tests/Other/StoreKitMocking/PFTestSKPaymentQueue.h Parse/Tests/Other/StoreKitMocking/PFTestSKPaymentQueue.m Parse/Tests/Other/StoreKitMocking/PFTestSKPaymentTransaction.h Parse/Tests/Other/StoreKitMocking/PFTestSKPaymentTransaction.m Parse/Tests/Other/StoreKitMocking/PFTestSKProduct.h Parse/Tests/Other/StoreKitMocking/PFTestSKProduct.m Parse/Tests/Other/StoreKitMocking/PFTestSKProductsRequest.h Parse/Tests/Other/StoreKitMocking/PFTestSKProductsRequest.m Parse/Tests/Other/StoreKitMocking/PFTestSKProductsResponse.h Parse/Tests/Other/StoreKitMocking/PFTestSKProductsResponse.m Parse/Tests/Other/Swift/SwiftSubclass.swift Parse/Tests/Other/Swizzling/PFTestSwizzledMethod.h Parse/Tests/Other/Swizzling/PFTestSwizzledMethod.m Parse/Tests/Other/Swizzling/PFTestSwizzlingUtilities.h Parse/Tests/Other/Swizzling/PFTestSwizzlingUtilities.m Parse/Tests/Other/TestCases/TestCase/PFTestCase.h Parse/Tests/Other/TestCases/TestCase/PFTestCase.m Parse/Tests/Other/TestCases/UnitTestCase/PFUnitTestCase.h Parse/Tests/Other/TestCases/UnitTestCase/PFUnitTestCase.m Parse/Tests/Resources/ParseUnitTests-OSX-Info.plist Parse/Tests/Resources/ParseUnitTests-iOS-Info.plist Parse/Tests/Unit/ACLDefaultTests.m Parse/Tests/Unit/ACLStateTests.m Parse/Tests/Unit/ACLTests.m Parse/Tests/Unit/AlertViewTests.m Parse/Tests/Unit/AnalyticsCommandTests.m Parse/Tests/Unit/AnalyticsControllerTests.m Parse/Tests/Unit/AnalyticsUnitTests.m Parse/Tests/Unit/AnalyticsUtilitiesTests.m Parse/Tests/Unit/AnonymousAuthenticationProviderTests.m Parse/Tests/Unit/AnonymousUtilsTests.m Parse/Tests/Unit/BaseStateTests.m Parse/Tests/Unit/CloudCodeControllerTests.m Parse/Tests/Unit/CloudCommandTests.m Parse/Tests/Unit/CloudUnitTests.m Parse/Tests/Unit/CommandResultTests.m Parse/Tests/Unit/CommandURLRequestConstructorTests.m Parse/Tests/Unit/CommandUnitTests.m Parse/Tests/Unit/ConfigCommandTests.m Parse/Tests/Unit/ConfigControllerTests.m Parse/Tests/Unit/ConfigUnitTests.m Parse/Tests/Unit/CurrentConfigControllerTests.m Parse/Tests/Unit/DateFormatterTests.m Parse/Tests/Unit/DecoderTests.m Parse/Tests/Unit/DefaultACLControllerTests.m Parse/Tests/Unit/DeviceTests.m Parse/Tests/Unit/ExtensionDataSharingMobileTests.m Parse/Tests/Unit/ExtensionDataSharingTests.m Parse/Tests/Unit/FieldOperationDecoderTests.m Parse/Tests/Unit/FieldOperationTests.m Parse/Tests/Unit/FileCommandTests.m Parse/Tests/Unit/FileControllerTests.m Parse/Tests/Unit/FileDataStreamTests.m Parse/Tests/Unit/FileStateTests.m Parse/Tests/Unit/FileUnitTests.m Parse/Tests/Unit/GeoPointLocationTests.m Parse/Tests/Unit/GeoPointUnitTests.m Parse/Tests/Unit/HashTests.m Parse/Tests/Unit/IncrementUnitTests.m Parse/Tests/Unit/InstallationIdentifierUnitTests.m Parse/Tests/Unit/InstallationUnitTests.m Parse/Tests/Unit/KeyValueCacheTests.m Parse/Tests/Unit/KeychainStoreTests.m Parse/Tests/Unit/LocationManagerMobileTests.m Parse/Tests/Unit/LocationManagerTests.m Parse/Tests/Unit/ObjectBatchCommandTests.m Parse/Tests/Unit/ObjectBatchControllerTests.m Parse/Tests/Unit/ObjectCommandTests.m Parse/Tests/Unit/ObjectEstimatedDataTests.m Parse/Tests/Unit/ObjectFileCoderTests.m Parse/Tests/Unit/ObjectFileCodingLogicTests.m Parse/Tests/Unit/ObjectFilePersistenceControllerTests.m Parse/Tests/Unit/ObjectLocalIdStoreTests.m Parse/Tests/Unit/ObjectOfflineTests.m Parse/Tests/Unit/ObjectPinTests.m Parse/Tests/Unit/ObjectStateTests.m Parse/Tests/Unit/ObjectSubclassPropertiesTests.m Parse/Tests/Unit/ObjectSubclassTests.m Parse/Tests/Unit/ObjectSubclassingControllerTests.m Parse/Tests/Unit/ObjectUnitTests.m Parse/Tests/Unit/ObjectUtilitiesTests.m Parse/Tests/Unit/OfflineQueryControllerTests.m Parse/Tests/Unit/OfflineQueryLogicUnitTests.m Parse/Tests/Unit/OperationSetUnitTests.m Parse/Tests/Unit/ParseClientConfigurationTests.m Parse/Tests/Unit/ParseModuleUnitTests.m Parse/Tests/Unit/ParseSetupUnitTests.m Parse/Tests/Unit/PinUnitTests.m Parse/Tests/Unit/PinningObjectStoreTests.m Parse/Tests/Unit/PolygonUnitTests.m Parse/Tests/Unit/ProductTests.m Parse/Tests/Unit/PropertyInfoTests.m Parse/Tests/Unit/PurchaseControllerTests.m Parse/Tests/Unit/PurchaseUnitTests.m Parse/Tests/Unit/PushChannelsControllerTests.m Parse/Tests/Unit/PushCommandTests.m Parse/Tests/Unit/PushControllerTests.m Parse/Tests/Unit/PushManagerTests.m Parse/Tests/Unit/PushMobileTests.m Parse/Tests/Unit/PushStateTests.m Parse/Tests/Unit/PushUnitTests.m Parse/Tests/Unit/QueryCachedControllerTests.m Parse/Tests/Unit/QueryControllerUnitTests.m Parse/Tests/Unit/QueryPredicateUnitTests.m Parse/Tests/Unit/QueryStateUnitTests.m Parse/Tests/Unit/QueryUnitTests.m Parse/Tests/Unit/QueryUtilitiesTests.m Parse/Tests/Unit/RelationStateTests.m Parse/Tests/Unit/RelationUnitTests.m Parse/Tests/Unit/RoleUnitTests.m Parse/Tests/Unit/SQLiteDatabaseTest.m Parse/Tests/Unit/SessionControllerTests.m Parse/Tests/Unit/SessionUnitTests.m Parse/Tests/Unit/SessionUtilitiesTests.m Parse/Tests/Unit/URLConstructorTests.m Parse/Tests/Unit/URLSessionCommandRunnerTests.m Parse/Tests/Unit/URLSessionDataTaskDelegateTests.m Parse/Tests/Unit/URLSessionTests.m Parse/Tests/Unit/URLSessionUploadTaskDelegateTests.m Parse/Tests/Unit/UserCommandTests.m Parse/Tests/Unit/UserControllerTests.m Parse/Tests/Unit/UserFileCodingLogicTests.m Parse/Tests/Unit/UserUnitTests.m Parse/Tests/testServer.config ParseFacebookUtils/Configurations/ParseFacebookTestApplicationV4.xcconfig ParseFacebookUtils/Configurations/ParseFacebookUtilsV4-UnitTests.xcconfig ParseFacebookUtils/Configurations/ParseFacebookUtilsV4-iOS-Dynamic.xcconfig ParseFacebookUtils/Configurations/ParseFacebookUtilsV4-iOS.xcconfig ParseFacebookUtils/Configurations/ParseFacebookUtilsV4-tvOS-Dynamic.xcconfig ParseFacebookUtils/Configurations/ParseFacebookUtilsV4-tvOS.xcconfig ParseFacebookUtils/Configurations/Shared ParseFacebookUtils/ParseFacebookUtils.xcodeproj/project.pbxproj ParseFacebookUtils/ParseFacebookUtils.xcodeproj/project.xcworkspace/contents.xcworkspacedata ParseFacebookUtils/ParseFacebookUtils.xcodeproj/xcshareddata/xcschemes/ParseFacebookUtilsV4-iOS-Dynamic.xcscheme ParseFacebookUtils/ParseFacebookUtils.xcodeproj/xcshareddata/xcschemes/ParseFacebookUtilsV4-iOS.xcscheme ParseFacebookUtils/ParseFacebookUtils.xcodeproj/xcshareddata/xcschemes/ParseFacebookUtilsV4-tvOS-Dynamic.xcscheme ParseFacebookUtils/ParseFacebookUtils.xcodeproj/xcshareddata/xcschemes/ParseFacebookUtilsV4-tvOS.xcscheme ParseFacebookUtils/ParseFacebookUtils/Internal/AuthenticationProvider/PFFacebookAuthenticationProvider.h ParseFacebookUtils/ParseFacebookUtils/Internal/AuthenticationProvider/PFFacebookAuthenticationProvider.m ParseFacebookUtils/ParseFacebookUtils/Internal/AuthenticationProvider/iOS/PFFacebookMobileAuthenticationProvider.h ParseFacebookUtils/ParseFacebookUtils/Internal/AuthenticationProvider/iOS/PFFacebookMobileAuthenticationProvider.m ParseFacebookUtils/ParseFacebookUtils/Internal/AuthenticationProvider/iOS/PFFacebookMobileAuthenticationProvider_Private.h ParseFacebookUtils/ParseFacebookUtils/Internal/AuthenticationProvider/tvOS/PFFacebookDeviceAuthenticationProvider.h ParseFacebookUtils/ParseFacebookUtils/Internal/AuthenticationProvider/tvOS/PFFacebookDeviceAuthenticationProvider.m ParseFacebookUtils/ParseFacebookUtils/Internal/PFFacebookPrivateUtilities.h ParseFacebookUtils/ParseFacebookUtils/Internal/PFFacebookPrivateUtilities.m ParseFacebookUtils/ParseFacebookUtils/Internal/PFFacebookUtils_Private.h ParseFacebookUtils/ParseFacebookUtils/PFFacebookUtils.h ParseFacebookUtils/ParseFacebookUtils/PFFacebookUtils.m ParseFacebookUtils/ParseFacebookUtils/ParseFacebookUtilsV4.h ParseFacebookUtils/Resources/Info-iOS.plist ParseFacebookUtils/Resources/Info-tvOS.plist ParseFacebookUtils/Resources/Localizable.strings ParseFacebookUtils/Tests/Other/TestCase/PFFacebookTestCase.h ParseFacebookUtils/Tests/Other/TestCase/PFFacebookTestCase.m ParseFacebookUtils/Tests/Resources/Info.plist ParseFacebookUtils/Tests/TestApplication/Classes/main.m ParseFacebookUtils/Tests/TestApplication/Resources/Info.plist ParseFacebookUtils/Tests/Unit/FacebookAuthenticationProviderTests.m ParseFacebookUtils/Tests/Unit/FacebookUtilsTests.m ParseStarterProject/OSX/ParseOSXStarterProject-Swift/ParseOSXStarterProject-Swift.xcodeproj/project.pbxproj ParseStarterProject/OSX/ParseOSXStarterProject-Swift/ParseOSXStarterProject-Swift.xcodeproj/project.xcworkspace/contents.xcworkspacedata ParseStarterProject/OSX/ParseOSXStarterProject-Swift/ParseOSXStarterProject/AppDelegate.swift ParseStarterProject/OSX/ParseOSXStarterProject-Swift/Resources/Base.lproj/MainMenu.xib ParseStarterProject/OSX/ParseOSXStarterProject-Swift/Resources/Images.xcassets/AppIcon.appiconset/Contents.json ParseStarterProject/OSX/ParseOSXStarterProject-Swift/Resources/Info.plist ParseStarterProject/OSX/ParseOSXStarterProject/ParseOSXStarterProject.xcodeproj/project.pbxproj ParseStarterProject/OSX/ParseOSXStarterProject/ParseOSXStarterProject.xcodeproj/project.xcworkspace/contents.xcworkspacedata ParseStarterProject/OSX/ParseOSXStarterProject/ParseOSXStarterProject/AppDelegate.h ParseStarterProject/OSX/ParseOSXStarterProject/ParseOSXStarterProject/AppDelegate.m ParseStarterProject/OSX/ParseOSXStarterProject/ParseOSXStarterProject/main.m ParseStarterProject/OSX/ParseOSXStarterProject/Resources/Base.lproj/MainMenu.xib ParseStarterProject/OSX/ParseOSXStarterProject/Resources/Info.plist ParseStarterProject/OSX/ParseOSXStarterProject/Resources/en.lproj/Credits.rtf ParseStarterProject/OSX/ParseOSXStarterProject/Resources/en.lproj/InfoPlist.strings ParseStarterProject/iOS/ParseStarterProject-Swift/ParseStarterProject-Swift.xcodeproj/project.pbxproj ParseStarterProject/iOS/ParseStarterProject-Swift/ParseStarterProject-Swift.xcodeproj/project.xcworkspace/contents.xcworkspacedata ParseStarterProject/iOS/ParseStarterProject-Swift/ParseStarterProject/AppDelegate.swift ParseStarterProject/iOS/ParseStarterProject-Swift/ParseStarterProject/ViewController.swift ParseStarterProject/iOS/ParseStarterProject-Swift/Resources/Base.lproj/Main.storyboard ParseStarterProject/iOS/ParseStarterProject-Swift/Resources/Images.xcassets/AppIcon.appiconset/Contents.json ParseStarterProject/iOS/ParseStarterProject-Swift/Resources/Images.xcassets/Contents.json ParseStarterProject/iOS/ParseStarterProject-Swift/Resources/Info.plist ParseStarterProject/iOS/ParseStarterProject-Swift/Resources/Launch.storyboard ParseStarterProject/iOS/ParseStarterProject/ParseStarterProject.xcodeproj/project.pbxproj ParseStarterProject/iOS/ParseStarterProject/ParseStarterProject.xcodeproj/project.xcworkspace/contents.xcworkspacedata ParseStarterProject/iOS/ParseStarterProject/ParseStarterProject/ParseStarterProjectAppDelegate.h ParseStarterProject/iOS/ParseStarterProject/ParseStarterProject/ParseStarterProjectAppDelegate.m ParseStarterProject/iOS/ParseStarterProject/ParseStarterProject/ParseStarterProjectViewController.h ParseStarterProject/iOS/ParseStarterProject/ParseStarterProject/ParseStarterProjectViewController.m ParseStarterProject/iOS/ParseStarterProject/ParseStarterProject/main.m ParseStarterProject/iOS/ParseStarterProject/Resources/Base.lproj/MainWindow.xib ParseStarterProject/iOS/ParseStarterProject/Resources/Base.lproj/ParseStarterProjectViewController.xib ParseStarterProject/iOS/ParseStarterProject/Resources/Info.plist ParseStarterProject/iOS/ParseStarterProject/Resources/en.lproj/InfoPlist.strings ParseStarterProject/tvOS/ParseStarterProject-Swift/ParseStarter-Swift.xcodeproj/project.pbxproj ParseStarterProject/tvOS/ParseStarterProject-Swift/ParseStarter-Swift.xcodeproj/project.xcworkspace/contents.xcworkspacedata ParseStarterProject/tvOS/ParseStarterProject-Swift/ParseStarter/AppDelegate.swift ParseStarterProject/tvOS/ParseStarterProject-Swift/ParseStarter/Base.lproj/Main.storyboard ParseStarterProject/tvOS/ParseStarterProject-Swift/ParseStarter/Info.plist ParseStarterProject/tvOS/ParseStarterProject-Swift/ParseStarter/ViewController.swift ParseStarterProject/watchOS/ParseStarterProject-Swift/ParseStarter Extension/ExtensionDelegate.swift ParseStarterProject/watchOS/ParseStarterProject-Swift/ParseStarter Extension/Info.plist ParseStarterProject/watchOS/ParseStarterProject-Swift/ParseStarter Extension/InterfaceController.swift ParseStarterProject/watchOS/ParseStarterProject-Swift/ParseStarter-Swift.xcodeproj/project.pbxproj ParseStarterProject/watchOS/ParseStarterProject-Swift/ParseStarter-Swift.xcodeproj/project.xcworkspace/contents.xcworkspacedata ParseStarterProject/watchOS/ParseStarterProject-Swift/ParseStarter/Assets.xcassets/AppIcon.appiconset/Contents.json ParseStarterProject/watchOS/ParseStarterProject-Swift/ParseStarter/Base.lproj/Interface.storyboard ParseStarterProject/watchOS/ParseStarterProject-Swift/ParseStarter/Info.plist ParseStarterProject/watchOS/ParseStarterProject-Swift/ParseStarterProject/AppDelegate.swift ParseStarterProject/watchOS/ParseStarterProject-Swift/ParseStarterProject/ViewController.swift ParseStarterProject/watchOS/ParseStarterProject-Swift/Resources/Base.lproj/Main.storyboard ParseStarterProject/watchOS/ParseStarterProject-Swift/Resources/Images.xcassets/AppIcon.appiconset/Contents.json ParseStarterProject/watchOS/ParseStarterProject-Swift/Resources/Images.xcassets/LaunchImage.launchimage/Contents.json ParseStarterProject/watchOS/ParseStarterProject-Swift/Resources/Info.plist ParseTwitterUtils/Configurations/ParseTwitterTestApplication.xcconfig ParseTwitterUtils/Configurations/ParseTwitterUtils-Tests.xcconfig ParseTwitterUtils/Configurations/ParseTwitterUtils-iOS-Dynamic.xcconfig ParseTwitterUtils/Configurations/ParseTwitterUtils-iOS.xcconfig ParseTwitterUtils/Configurations/Shared ParseTwitterUtils/ParseTwitterTestApplication.entitlements ParseTwitterUtils/ParseTwitterUtils.xcodeproj/project.pbxproj ParseTwitterUtils/ParseTwitterUtils.xcodeproj/project.xcworkspace/contents.xcworkspacedata ParseTwitterUtils/ParseTwitterUtils.xcodeproj/xcshareddata/xcschemes/ParseTwitterUtils-iOS-Dynamic.xcscheme ParseTwitterUtils/ParseTwitterUtils.xcodeproj/xcshareddata/xcschemes/ParseTwitterUtils-iOS.xcscheme ParseTwitterUtils/ParseTwitterUtils/Internal/Dialog/PFOAuth1FlowDialog.h ParseTwitterUtils/ParseTwitterUtils/Internal/Dialog/PFOAuth1FlowDialog.m ParseTwitterUtils/ParseTwitterUtils/Internal/OAuthCore/PF_OAuthCore.h ParseTwitterUtils/ParseTwitterUtils/Internal/OAuthCore/PF_OAuthCore.m ParseTwitterUtils/ParseTwitterUtils/Internal/PFTwitterAlertView.h ParseTwitterUtils/ParseTwitterUtils/Internal/PFTwitterAlertView.m ParseTwitterUtils/ParseTwitterUtils/Internal/PFTwitterAuthenticationProvider.h ParseTwitterUtils/ParseTwitterUtils/Internal/PFTwitterAuthenticationProvider.m ParseTwitterUtils/ParseTwitterUtils/Internal/PFTwitterLocalization.h ParseTwitterUtils/ParseTwitterUtils/Internal/PFTwitterPrivateUtilities.h ParseTwitterUtils/ParseTwitterUtils/Internal/PFTwitterPrivateUtilities.m ParseTwitterUtils/ParseTwitterUtils/Internal/PFTwitterUtils_Private.h ParseTwitterUtils/ParseTwitterUtils/Internal/PF_Twitter_Private.h ParseTwitterUtils/ParseTwitterUtils/PFTwitterUtils.h ParseTwitterUtils/ParseTwitterUtils/PFTwitterUtils.m ParseTwitterUtils/ParseTwitterUtils/PF_Twitter.h ParseTwitterUtils/ParseTwitterUtils/PF_Twitter.m ParseTwitterUtils/ParseTwitterUtils/ParseTwitterUtils.h ParseTwitterUtils/Resources/Info.plist ParseTwitterUtils/Resources/en.lproj/ParseTwitterUtils.strings ParseTwitterUtils/Tests/Other/PFTwitterTestMacros.h ParseTwitterUtils/Tests/Other/TestCase/PFTwitterTestCase.h ParseTwitterUtils/Tests/Other/TestCase/PFTwitterTestCase.m ParseTwitterUtils/Tests/Resources/Info.plist ParseTwitterUtils/Tests/TestApplication/Classes/main.m ParseTwitterUtils/Tests/TestApplication/Resources/Info.plist ParseTwitterUtils/Tests/Unit/OAuth1FlowDialogTests.m ParseTwitterUtils/Tests/Unit/OAuthCoreTests.m ParseTwitterUtils/Tests/Unit/TwitterAuthenticationProviderTests.m ParseTwitterUtils/Tests/Unit/TwitterTests.m ParseTwitterUtils/Tests/Unit/TwitterUtilsTests.m ParseUI/Classes/Cells/PFCollectionViewCell.h ParseUI/Classes/Cells/PFCollectionViewCell.m ParseUI/Classes/Cells/PFPurchaseTableViewCell.h ParseUI/Classes/Cells/PFPurchaseTableViewCell.m ParseUI/Classes/Cells/PFTableViewCell.h ParseUI/Classes/Cells/PFTableViewCell.m ParseUI/Classes/Internal/Cells/PFActivityIndicatorCollectionReusableView.h ParseUI/Classes/Internal/Cells/PFActivityIndicatorCollectionReusableView.m ParseUI/Classes/Internal/Cells/PFActivityIndicatorTableViewCell.h ParseUI/Classes/Internal/Cells/PFActivityIndicatorTableViewCell.m ParseUI/Classes/Internal/Extensions/PFColor.h ParseUI/Classes/Internal/Extensions/PFColor.m ParseUI/Classes/Internal/Extensions/PFImage.h ParseUI/Classes/Internal/Extensions/PFImage.m ParseUI/Classes/Internal/Extensions/PFRect.h ParseUI/Classes/Internal/Extensions/PFRect.m ParseUI/Classes/Internal/Extensions/PFUIAlertView.h ParseUI/Classes/Internal/Extensions/PFUIAlertView.m ParseUI/Classes/Internal/PFImageCache.h ParseUI/Classes/Internal/PFImageCache.m ParseUI/Classes/Internal/PFLocalization.h ParseUI/Classes/Internal/PFLocalization.m ParseUI/Classes/Internal/Views/Buttons/PFActionButton.h ParseUI/Classes/Internal/Views/Buttons/PFActionButton.m ParseUI/Classes/Internal/Views/Buttons/PFDismissButton.h ParseUI/Classes/Internal/Views/Buttons/PFDismissButton.m ParseUI/Classes/Internal/Views/Buttons/PFPrimaryButton.h ParseUI/Classes/Internal/Views/Buttons/PFPrimaryButton.m ParseUI/Classes/Internal/Views/Buttons/PFTextButton.h ParseUI/Classes/Internal/Views/Buttons/PFTextButton.m ParseUI/Classes/Internal/Views/PFLoadingView.h ParseUI/Classes/Internal/Views/PFLoadingView.m ParseUI/Classes/LogInViewController/PFLogInView.h ParseUI/Classes/LogInViewController/PFLogInView.m ParseUI/Classes/LogInViewController/PFLogInViewController.h ParseUI/Classes/LogInViewController/PFLogInViewController.m ParseUI/Classes/LogInViewController/PFLogInView_Private.h ParseUI/Classes/ProductTableViewController/PFProductTableViewController.h ParseUI/Classes/ProductTableViewController/PFProductTableViewController.m ParseUI/Classes/QueryCollectionViewController/PFQueryCollectionViewController.h ParseUI/Classes/QueryCollectionViewController/PFQueryCollectionViewController.m ParseUI/Classes/QueryTableViewController/PFQueryTableViewController.h ParseUI/Classes/QueryTableViewController/PFQueryTableViewController.m ParseUI/Classes/SignUpViewController/PFSignUpView.h ParseUI/Classes/SignUpViewController/PFSignUpView.m ParseUI/Classes/SignUpViewController/PFSignUpViewController.h ParseUI/Classes/SignUpViewController/PFSignUpViewController.m ParseUI/Classes/Views/PFImageView.h ParseUI/Classes/Views/PFImageView.m ParseUI/Classes/Views/PFTextField.h ParseUI/Classes/Views/PFTextField.m ParseUI/Configurations/ParseUI-iOS-Dynamic.xcconfig ParseUI/Configurations/ParseUI-iOS.xcconfig ParseUI/Configurations/Shared ParseUI/Generated/PFResources.h ParseUI/Generated/PFResources.m ParseUI/Other/ParseUI.h ParseUI/Other/ParseUIConstants.h ParseUI/ParseUI.xcodeproj/project.pbxproj ParseUI/ParseUI.xcodeproj/project.xcworkspace/contents.xcworkspacedata ParseUI/ParseUI.xcodeproj/xcshareddata/xcschemes/ParseUI-Dynamic.xcscheme ParseUI/ParseUI.xcodeproj/xcshareddata/xcschemes/ParseUI.xcscheme ParseUI/ParseUI.xcodeproj/xcshareddata/xcschemes/ParseUIDemo-Swift.xcscheme ParseUI/ParseUI.xcodeproj/xcshareddata/xcschemes/ParseUIDemo.xcscheme ParseUI/ParseUIDemo/Classes/AppDelegate.h ParseUI/ParseUIDemo/Classes/AppDelegate.m ParseUI/ParseUIDemo/Classes/CustomViewControllers/LogInViewController/CustomLogInViewController.h ParseUI/ParseUIDemo/Classes/CustomViewControllers/LogInViewController/CustomLogInViewController.m ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryCollectionViewController/DeletionCollectionViewController.h ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryCollectionViewController/DeletionCollectionViewController.m ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryCollectionViewController/PaginatedCollectionViewController.h ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryCollectionViewController/PaginatedCollectionViewController.m ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryCollectionViewController/SectionedCollectionViewController.h ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryCollectionViewController/SectionedCollectionViewController.m ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryCollectionViewController/SimpleCollectionViewController.h ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryCollectionViewController/SimpleCollectionViewController.m ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryCollectionViewController/StoryboardCollectionViewController.h ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryCollectionViewController/StoryboardCollectionViewController.m ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryCollectionViewController/SubtitleImageCollectionViewController.h ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryCollectionViewController/SubtitleImageCollectionViewController.m ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryTableViewController/CustomProductTableViewController.h ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryTableViewController/CustomProductTableViewController.m ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryTableViewController/DeletionTableViewController.h ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryTableViewController/DeletionTableViewController.m ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryTableViewController/PaginatedTableViewController.h ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryTableViewController/PaginatedTableViewController.m ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryTableViewController/SectionedTableViewController.h ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryTableViewController/SectionedTableViewController.m ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryTableViewController/SimpleTableViewController.h ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryTableViewController/SimpleTableViewController.m ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryTableViewController/StoryboardTableViewController.h ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryTableViewController/StoryboardTableViewController.m ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryTableViewController/SubtitleImageTableViewController.h ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryTableViewController/SubtitleImageTableViewController.m ParseUI/ParseUIDemo/Classes/CustomViewControllers/SignUpViewController/CustomSignUpViewController.h ParseUI/ParseUIDemo/Classes/CustomViewControllers/SignUpViewController/CustomSignUpViewController.m ParseUI/ParseUIDemo/Classes/PFUIDemoViewController.h ParseUI/ParseUIDemo/Classes/PFUIDemoViewController.m ParseUI/ParseUIDemo/Images.xcassets/LaunchImage.launchimage/Contents.json ParseUI/ParseUIDemo/Other/Info.plist ParseUI/ParseUIDemo/Other/main.m ParseUI/ParseUIDemo/ParseUIDemo.entitlements ParseUI/ParseUIDemo/Resources/SimpleQueryCollectionStoryboard.storyboard ParseUI/ParseUIDemo/Resources/SimpleQueryTableStoryboard.storyboard ParseUI/ParseUIDemo/Swift/AppDelegate.swift ParseUI/ParseUIDemo/Swift/CustomViewControllers/LogInViewController/CustomLogInViewController.swift ParseUI/ParseUIDemo/Swift/CustomViewControllers/ProductTableViewController/CustomProductTableViewController.swift ParseUI/ParseUIDemo/Swift/CustomViewControllers/QueryCollectionViewController/DeletionCollectionViewController.swift ParseUI/ParseUIDemo/Swift/CustomViewControllers/QueryCollectionViewController/PaginatedCollectionViewController.swift ParseUI/ParseUIDemo/Swift/CustomViewControllers/QueryCollectionViewController/SectionedCollectionViewController.swift ParseUI/ParseUIDemo/Swift/CustomViewControllers/QueryCollectionViewController/SimpleCollectionViewController.swift ParseUI/ParseUIDemo/Swift/CustomViewControllers/QueryCollectionViewController/StoryboardCollectionViewController.swift ParseUI/ParseUIDemo/Swift/CustomViewControllers/QueryCollectionViewController/SubtitleImageCollectionViewController.swift ParseUI/ParseUIDemo/Swift/CustomViewControllers/QueryTableViewController/DeletionTableViewController.swift ParseUI/ParseUIDemo/Swift/CustomViewControllers/QueryTableViewController/PaginatedTableViewController.swift ParseUI/ParseUIDemo/Swift/CustomViewControllers/QueryTableViewController/SectionedTableViewController.swift ParseUI/ParseUIDemo/Swift/CustomViewControllers/QueryTableViewController/SimpleTableViewController.swift ParseUI/ParseUIDemo/Swift/CustomViewControllers/QueryTableViewController/StoryboardTableViewController.swift ParseUI/ParseUIDemo/Swift/CustomViewControllers/QueryTableViewController/SubtitleImageTableViewController.swift ParseUI/ParseUIDemo/Swift/CustomViewControllers/SignUpViewController/CustomSignUpViewController.swift ParseUI/ParseUIDemo/Swift/Resources/SimpleQueryCollectionStoryboard-Swift.storyboard ParseUI/ParseUIDemo/Swift/Resources/SimpleQueryTableStoryboard-Swift.storyboard ParseUI/ParseUIDemo/Swift/UIDemoViewController.swift ParseUI/Resources/Info.plist ParseUI/Resources/Localization/de.lproj/ParseUI.strings ParseUI/Resources/Localization/en.lproj/ParseUI.strings ParseUI/Resources/Localization/fr.lproj/ParseUI.strings ParseUI/Resources/Localization/he.lproj/ParseUI.strings ParseUI/Resources/Localization/pt-BR.lproj/ParseUI.strings ParseUI/Resources/Localization/sv.lproj/ParseUI.strings ParseUI/Scripts/convert_images.rb ParseUI/Sign In With Apple/PFAppleAuthenticationProvider.h ParseUI/Sign In With Apple/PFAppleAuthenticationProvider.m ParseUI/Sign In With Apple/PFAppleUtils.h ParseUI/Sign In With Apple/PFAppleUtils.m ParseUI/SignInWithAppleTests/Info.plist ParseUI/SignInWithAppleTests/SignInWithAppleTests.m Rakefile Scripts/build_third_party.rb Scripts/jazzy.sh Vendor/xctoolchain package-lock.json package.json release.config.js <<<<<< network # path=Parse#Internal#Commands#CommandRunner#URLSession#Session#TaskDelegate#PFURLSessionUploadTaskDelegate.m.gcov.reduced -: 0:Source:Parse/Internal/Commands/CommandRunner/URLSession/Session/TaskDelegate/PFURLSessionUploadTaskDelegate.m <<<<<< EOF # path=./OCMock.framework.coverage.txt /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/NSInvocation+OCMAdditions.m: 1| |/* 2| | * Copyright (c) 2006-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import 18| |#import "NSInvocation+OCMAdditions.h" 19| |#import "OCMArg.h" 20| |#import "OCMFunctionsPrivate.h" 21| |#import "NSMethodSignature+OCMAdditions.h" 22| | 23| |#if (TARGET_OS_OSX && (!defined(__MAC_10_10) || __MAC_OS_X_VERSION_MIN_REQUIRED < __MAC_10_10)) || \ 24| | (TARGET_OS_IPHONE && (!defined(__IPHONE_8_0) || __IPHONE_OS_VERSION_MIN_REQUIRED < __IPHONE_8_0)) 25| |static BOOL OCMObjectIsClass(id object) { 26| | return class_isMetaClass(object_getClass(object)); 27| |} 28| |#define object_isClass OCMObjectIsClass 29| |#endif 30| | 31| |static NSString *const OCMArgAnyPointerDescription = @"<[OCMArg anyPointer]>"; 32| | 33| | 34| |@implementation NSInvocation(OCMAdditions) 35| | 36| |+ (NSInvocation *)invocationForBlock:(id)block withArguments:(NSArray *)arguments 37| 0|{ 38| 0| NSMethodSignature *sig = [NSMethodSignature signatureForBlock:block]; 39| 0| NSInvocation *inv = [self invocationWithMethodSignature:sig]; 40| | 41| 0| NSUInteger numArgsRequired = sig.numberOfArguments - 1; 42| 0| if((arguments != nil) && ([arguments count] != numArgsRequired)) 43| 0| [NSException raise:NSInvalidArgumentException format:@"Specified too few arguments for block; expected %lu arguments.", (unsigned long) numArgsRequired]; 44| | 45| 0| for(NSUInteger i = 0, j = 1; i < numArgsRequired; ++i, ++j) 46| 0| { 47| 0| id arg = [arguments objectAtIndex:i]; 48| 0| [inv setArgumentWithObject:arg atIndex:j]; 49| 0| } 50| | 51| 0| return inv; 52| | 53| 0|} 54| | 55| | 56| |static NSString *const OCMRetainedObjectArgumentsKey = @"OCMRetainedObjectArgumentsKey"; 57| | 58| |- (void)retainObjectArgumentsExcludingObject:(id)objectToExclude 59| 0|{ 60| 0| if(objc_getAssociatedObject(self, OCMRetainedObjectArgumentsKey) != nil) 61| 0| { 62| | // looks like we've retained the arguments already; do nothing else 63| 0| return; 64| 0| } 65| | 66| 0| NSMutableArray *retainedArguments = [[NSMutableArray alloc] init]; 67| | 68| 0| id target = [self target]; 69| 0| if((target != nil) && (target != objectToExclude) && !object_isClass(target)) 70| 0| { 71| | // Bad things will happen if the target is a block since it's not being 72| | // copied. There isn't a very good way to tell if an invocation's target 73| | // is a block though (the argument type at index 0 is always "@" even if 74| | // the target is a Class or block), and in practice it's OK since you 75| | // can't mock a block. 76| 0| [retainedArguments addObject:target]; 77| 0| } 78| | 79| 0| NSUInteger numberOfArguments = [[self methodSignature] numberOfArguments]; 80| 0| for(NSUInteger index = 2; index < numberOfArguments; index++) 81| 0| { 82| 0| const char *argumentType = [[self methodSignature] getArgumentTypeAtIndex:index]; 83| 0| if(OCMIsObjectType(argumentType)) 84| 0| { 85| 0| id argument; 86| 0| [self getArgument:&argument atIndex:index]; 87| 0| if((argument != nil) && (argument != objectToExclude)) 88| 0| { 89| 0| if(OCMIsBlockType(argumentType) && OCMIsBlock(argument)) 90| 0| { 91| | // The argument's type is block and the passed argument is a block. In this 92| | // case we can't retain the argument because it might be stack block, which 93| | // must be copied. Further, non-escaping blocks have a lifetime that is stack- 94| | // based and they treat copy/release as a no-op. Keeping a reference to these 95| | // would result in a dangling pointer, which is why they are ignored here. 96| | // Note: even when the argument's type is block the argument could be 97| | // something else, e.g. an instance of OCMConstraint. Such cases are handled 98| | // like regular objects in the last else branch below. 99| 0| if(OCMIsNonEscapingBlock(argument) == NO) 100| 0| { 101| 0| id blockArgument = [argument copy]; 102| 0| [retainedArguments addObject:blockArgument]; 103| 0| [blockArgument release]; 104| 0| } 105| 0| } 106| 0| else if(OCMIsClassType(argumentType) && object_isClass(argument)) 107| 0| { 108| | // The argument's type is class and the passed argument is a class. In this 109| | // case do not retain the argument. Note: Even though the type is class the 110| | // argument could be a non-class, e.g. an instance of OCMArg. 111| 0| } 112| 0| else 113| 0| { 114| 0| [retainedArguments addObject:argument]; 115| 0| } 116| 0| } 117| 0| } 118| 0| } 119| | 120| 0| objc_setAssociatedObject(self, OCMRetainedObjectArgumentsKey, retainedArguments, OBJC_ASSOCIATION_RETAIN); 121| 0| [retainedArguments release]; 122| 0|} 123| | 124| | 125| |- (void)setArgumentWithObject:(id)arg atIndex:(NSInteger)idx 126| 0|{ 127| 0| const char *typeEncoding = [[self methodSignature] getArgumentTypeAtIndex:idx]; 128| 0| if((arg == nil) || ([arg respondsToSelector:@selector(isKindOfClass:)] && [arg isKindOfClass:[NSNull class]])) 129| 0| { 130| 0| if(typeEncoding[0] == '^') 131| 0| { 132| 0| void *nullPtr = NULL; 133| 0| [self setArgument:&nullPtr atIndex:idx]; 134| 0| } 135| 0| else if(typeEncoding[0] == '@') 136| 0| { 137| 0| id nilObj = nil; 138| 0| [self setArgument:&nilObj atIndex:idx]; 139| 0| } 140| 0| else if(OCMNumberTypeForObjCType(typeEncoding)) 141| 0| { 142| 0| NSUInteger argSize; 143| 0| NSGetSizeAndAlignment(typeEncoding, NULL, &argSize); 144| 0| void *argBuffer = calloc(1, argSize); 145| 0| [self setArgument:argBuffer atIndex:idx]; 146| 0| free(argBuffer); 147| 0| } 148| 0| else 149| 0| { 150| 0| [NSException raise:NSInvalidArgumentException format:@"Unable to create default value for type '%s'.", typeEncoding]; 151| 0| } 152| 0| } 153| 0| else if(OCMIsObjectType(typeEncoding)) 154| 0| { 155| 0| [self setArgument:&arg atIndex:idx]; 156| 0| } 157| 0| else 158| 0| { 159| 0| if(![arg isKindOfClass:[NSValue class]]) 160| 0| [NSException raise:NSInvalidArgumentException format:@"Argument '%@' should be boxed in NSValue.", arg]; 161| | 162| 0| char const *valEncoding = [arg objCType]; 163| | 164| | /// @note Here we allow any data pointer to be passed as a void pointer and 165| | /// any numerical types to be passed as arguments to the block. 166| 0| BOOL takesVoidPtr = !strcmp(typeEncoding, "^v") && valEncoding[0] == '^'; 167| 0| BOOL takesNumber = OCMNumberTypeForObjCType(typeEncoding) && OCMNumberTypeForObjCType(valEncoding); 168| | 169| 0| if(!takesVoidPtr && !takesNumber && !OCMEqualTypesAllowingOpaqueStructs(typeEncoding, valEncoding)) 170| 0| [NSException raise:NSInvalidArgumentException format:@"Argument type mismatch; type of argument required is '%s' but type of value provided is '%s'", typeEncoding, valEncoding]; 171| | 172| 0| NSUInteger argSize; 173| 0| NSGetSizeAndAlignment(typeEncoding, &argSize, NULL); 174| 0| void *argBuffer = malloc(argSize); 175| 0| [arg getValue:argBuffer]; 176| 0| [self setArgument:argBuffer atIndex:idx]; 177| 0| free(argBuffer); 178| 0| } 179| | 180| 0|} 181| | 182| | 183| |- (id)getArgumentAtIndexAsObject:(NSInteger)argIndex 184| 0|{ 185| 0| const char *argType = OCMTypeWithoutQualifiers([[self methodSignature] getArgumentTypeAtIndex:(NSUInteger)argIndex]); 186| | 187| 0| if((strlen(argType) > 1) && (strchr("{^", argType[0]) == NULL) && (strcmp("@?", argType) != 0)) 188| 0| [NSException raise:NSInvalidArgumentException format:@"Cannot handle argument type '%s'.", argType]; 189| | 190| 0| if(OCMIsObjectType(argType)) 191| 0| { 192| 0| id value; 193| 0| [self getArgument:&value atIndex:argIndex]; 194| 0| return value; 195| 0| } 196| | 197| 0| switch(argType[0]) 198| 0| { 199| 0| case ':': 200| 0| { 201| 0| SEL s = (SEL)0; 202| 0| [self getArgument:&s atIndex:argIndex]; 203| 0| return [NSValue valueWithBytes:&s objCType:":"]; 204| 0| } 205| 0| case 'i': 206| 0| { 207| 0| int value; 208| 0| [self getArgument:&value atIndex:argIndex]; 209| 0| return @(value); 210| 0| } 211| 0| case 's': 212| 0| { 213| 0| short value; 214| 0| [self getArgument:&value atIndex:argIndex]; 215| 0| return @(value); 216| 0| } 217| 0| case 'l': 218| 0| { 219| 0| long value; 220| 0| [self getArgument:&value atIndex:argIndex]; 221| 0| return @(value); 222| 0| } 223| 0| case 'q': 224| 0| { 225| 0| long long value; 226| 0| [self getArgument:&value atIndex:argIndex]; 227| 0| return @(value); 228| 0| } 229| 0| case 'c': 230| 0| { 231| 0| char value; 232| 0| [self getArgument:&value atIndex:argIndex]; 233| 0| return @(value); 234| 0| } 235| 0| case 'C': 236| 0| { 237| 0| unsigned char value; 238| 0| [self getArgument:&value atIndex:argIndex]; 239| 0| return @(value); 240| 0| } 241| 0| case 'I': 242| 0| { 243| 0| unsigned int value; 244| 0| [self getArgument:&value atIndex:argIndex]; 245| 0| return @(value); 246| 0| } 247| 0| case 'S': 248| 0| { 249| 0| unsigned short value; 250| 0| [self getArgument:&value atIndex:argIndex]; 251| 0| return @(value); 252| 0| } 253| 0| case 'L': 254| 0| { 255| 0| unsigned long value; 256| 0| [self getArgument:&value atIndex:argIndex]; 257| 0| return @(value); 258| 0| } 259| 0| case 'Q': 260| 0| { 261| 0| unsigned long long value; 262| 0| [self getArgument:&value atIndex:argIndex]; 263| 0| return @(value); 264| 0| } 265| 0| case 'f': 266| 0| { 267| 0| float value; 268| 0| [self getArgument:&value atIndex:argIndex]; 269| 0| return @(value); 270| 0| } 271| 0| case 'd': 272| 0| { 273| 0| double value; 274| 0| [self getArgument:&value atIndex:argIndex]; 275| 0| return @(value); 276| 0| } 277| 0| case 'D': 278| 0| { 279| 0| long double value; 280| 0| [self getArgument:&value atIndex:argIndex]; 281| 0| return [NSValue valueWithBytes:&value objCType:@encode(__typeof__(value))]; 282| 0| } 283| 0| case 'B': 284| 0| { 285| 0| bool value; 286| 0| [self getArgument:&value atIndex:argIndex]; 287| 0| return @(value); 288| 0| } 289| 0| case '^': 290| 0| case '*': 291| 0| { 292| 0| void *value = NULL; 293| 0| [self getArgument:&value atIndex:argIndex]; 294| 0| return [NSValue valueWithPointer:value]; 295| 0| } 296| 0| case '{': // structure 297| 0| { 298| 0| NSUInteger argSize; 299| 0| NSGetSizeAndAlignment([[self methodSignature] getArgumentTypeAtIndex:(NSUInteger)argIndex], &argSize, NULL); 300| 0| if(argSize == 0) // TODO: Can this happen? Is frameLength a good choice in that case? 301| 0| argSize = [[self methodSignature] frameLength]; 302| 0| NSMutableData *argumentData = [[[NSMutableData alloc] initWithLength:argSize] autorelease]; 303| 0| [self getArgument:[argumentData mutableBytes] atIndex:argIndex]; 304| 0| return [NSValue valueWithBytes:[argumentData bytes] objCType:argType]; 305| 0| } 306| | 307| 0| } 308| 0| [NSException raise:NSInvalidArgumentException format:@"Argument type '%s' not supported", argType]; 309| 0| return nil; 310| 0|} 311| | 312| | 313| |- (NSString *)invocationDescription 314| 0|{ 315| 0| NSMethodSignature *methodSignature = [self methodSignature]; 316| 0| NSUInteger numberOfArgs = [methodSignature numberOfArguments]; 317| | 318| 0| if (numberOfArgs == 2) 319| 0| return NSStringFromSelector([self selector]); 320| | 321| 0| NSArray *selectorParts = [NSStringFromSelector([self selector]) componentsSeparatedByString:@":"]; 322| 0| NSMutableString *description = [[NSMutableString alloc] init]; 323| 0| NSUInteger i; 324| 0| for(i = 2; i < numberOfArgs; i++) 325| 0| { 326| 0| [description appendFormat:@"%@%@:", (i > 2 ? @" " : @""), [selectorParts objectAtIndex:(i - 2)]]; 327| 0| [description appendString:[self argumentDescriptionAtIndex:(NSInteger)i]]; 328| 0| } 329| | 330| 0| return [description autorelease]; 331| 0|} 332| | 333| |- (NSString *)argumentDescriptionAtIndex:(NSInteger)argIndex 334| 0|{ 335| 0| const char *argType = OCMTypeWithoutQualifiers([[self methodSignature] getArgumentTypeAtIndex:(NSUInteger)argIndex]); 336| | 337| 0| switch(*argType) 338| 0| { 339| 0| case '@': return [self objectDescriptionAtIndex:argIndex]; 340| 0| case 'B': return [self boolDescriptionAtIndex:argIndex]; 341| 0| case 'c': return [self charDescriptionAtIndex:argIndex]; 342| 0| case 'C': return [self unsignedCharDescriptionAtIndex:argIndex]; 343| 0| case 'i': return [self intDescriptionAtIndex:argIndex]; 344| 0| case 'I': return [self unsignedIntDescriptionAtIndex:argIndex]; 345| 0| case 's': return [self shortDescriptionAtIndex:argIndex]; 346| 0| case 'S': return [self unsignedShortDescriptionAtIndex:argIndex]; 347| 0| case 'l': return [self longDescriptionAtIndex:argIndex]; 348| 0| case 'L': return [self unsignedLongDescriptionAtIndex:argIndex]; 349| 0| case 'q': return [self longLongDescriptionAtIndex:argIndex]; 350| 0| case 'Q': return [self unsignedLongLongDescriptionAtIndex:argIndex]; 351| 0| case 'd': return [self doubleDescriptionAtIndex:argIndex]; 352| 0| case 'f': return [self floatDescriptionAtIndex:argIndex]; 353| 0| case 'D': return [self longDoubleDescriptionAtIndex:argIndex]; 354| 0| case '{': return [self structDescriptionAtIndex:argIndex]; 355| 0| case '^': return [self pointerDescriptionAtIndex:argIndex]; 356| 0| case '*': return [self cStringDescriptionAtIndex:argIndex]; 357| 0| case ':': return [self selectorDescriptionAtIndex:argIndex]; 358| 0| default: return [@""]; // avoid confusion with trigraphs... 359| 0| } 360| | 361| 0|} 362| | 363| |- (NSString *)objectDescriptionAtIndex:(NSInteger)anInt 364| 0|{ 365| 0| id object; 366| | 367| 0| [self getArgument:&object atIndex:anInt]; 368| 0| if (object == nil) 369| 0| return @"nil"; 370| 0| else if(![object isProxy] && [object isKindOfClass:[NSString class]]) 371| 0| return [NSString stringWithFormat:@"@\"%@\"", [object description]]; 372| 0| else 373| | // The description cannot be nil, if it is then replace it 374| 0| return [object description] ?: @""; 375| 0|} 376| | 377| |- (NSString *)boolDescriptionAtIndex:(NSInteger)anInt 378| 0|{ 379| 0| bool value; 380| 0| [self getArgument:&value atIndex:anInt]; 381| 0| return value? @"YES" : @"NO"; 382| 0|} 383| | 384| |- (NSString *)charDescriptionAtIndex:(NSInteger)anInt 385| 0|{ 386| 0| unsigned char buffer[128]; 387| 0| memset(buffer, 0x0, 128); 388| | 389| 0| [self getArgument:&buffer atIndex:anInt]; 390| | 391| | // If there's only one character in the buffer, and it's 0 or 1, then we have a BOOL 392| 0| if (buffer[1] == '\0' && (buffer[0] == 0 || buffer[0] == 1)) 393| 0| return (buffer[0] == 1 ? @"YES" : @"NO"); 394| 0| else 395| 0| return [NSString stringWithFormat:@"'%c'", *buffer]; 396| 0|} 397| | 398| |- (NSString *)unsignedCharDescriptionAtIndex:(NSInteger)anInt 399| 0|{ 400| 0| unsigned char buffer[128]; 401| 0| memset(buffer, 0x0, 128); 402| | 403| 0| [self getArgument:&buffer atIndex:anInt]; 404| 0| return [NSString stringWithFormat:@"'%c'", *buffer]; 405| 0|} 406| | 407| |- (NSString *)intDescriptionAtIndex:(NSInteger)anInt 408| 0|{ 409| 0| int intValue; 410| | 411| 0| [self getArgument:&intValue atIndex:anInt]; 412| 0| return [NSString stringWithFormat:@"%d", intValue]; 413| 0|} 414| | 415| |- (NSString *)unsignedIntDescriptionAtIndex:(NSInteger)anInt 416| 0|{ 417| 0| unsigned int intValue; 418| | 419| 0| [self getArgument:&intValue atIndex:anInt]; 420| 0| return [NSString stringWithFormat:@"%d", intValue]; 421| 0|} 422| | 423| |- (NSString *)shortDescriptionAtIndex:(NSInteger)anInt 424| 0|{ 425| 0| short shortValue; 426| | 427| 0| [self getArgument:&shortValue atIndex:anInt]; 428| 0| return [NSString stringWithFormat:@"%hi", shortValue]; 429| 0|} 430| | 431| |- (NSString *)unsignedShortDescriptionAtIndex:(NSInteger)anInt 432| 0|{ 433| 0| unsigned short shortValue; 434| | 435| 0| [self getArgument:&shortValue atIndex:anInt]; 436| 0| return [NSString stringWithFormat:@"%hu", shortValue]; 437| 0|} 438| | 439| |- (NSString *)longDescriptionAtIndex:(NSInteger)anInt 440| 0|{ 441| 0| long longValue; 442| | 443| 0| [self getArgument:&longValue atIndex:anInt]; 444| 0| return [NSString stringWithFormat:@"%ld", longValue]; 445| 0|} 446| | 447| |- (NSString *)unsignedLongDescriptionAtIndex:(NSInteger)anInt 448| 0|{ 449| 0| unsigned long longValue; 450| | 451| 0| [self getArgument:&longValue atIndex:anInt]; 452| 0| return [NSString stringWithFormat:@"%lu", longValue]; 453| 0|} 454| | 455| |- (NSString *)longLongDescriptionAtIndex:(NSInteger)anInt 456| 0|{ 457| 0| long long longLongValue; 458| | 459| 0| [self getArgument:&longLongValue atIndex:anInt]; 460| 0| return [NSString stringWithFormat:@"%qi", longLongValue]; 461| 0|} 462| | 463| |- (NSString *)unsignedLongLongDescriptionAtIndex:(NSInteger)anInt 464| 0|{ 465| 0| unsigned long long longLongValue; 466| | 467| 0| [self getArgument:&longLongValue atIndex:anInt]; 468| 0| return [NSString stringWithFormat:@"%qu", longLongValue]; 469| 0|} 470| | 471| |- (NSString *)doubleDescriptionAtIndex:(NSInteger)anInt 472| 0|{ 473| 0| double doubleValue; 474| | 475| 0| [self getArgument:&doubleValue atIndex:anInt]; 476| 0| return [NSString stringWithFormat:@"%f", doubleValue]; 477| 0|} 478| | 479| |- (NSString *)floatDescriptionAtIndex:(NSInteger)anInt 480| 0|{ 481| 0| float floatValue; 482| | 483| 0| [self getArgument:&floatValue atIndex:anInt]; 484| 0| return [NSString stringWithFormat:@"%f", floatValue]; 485| 0|} 486| | 487| |- (NSString *)longDoubleDescriptionAtIndex:(NSInteger)anInt 488| 0|{ 489| 0| long double longDoubleValue; 490| | 491| 0| [self getArgument:&longDoubleValue atIndex:anInt]; 492| 0| return [NSString stringWithFormat:@"%Lf", longDoubleValue]; 493| 0|} 494| | 495| |- (NSString *)structDescriptionAtIndex:(NSInteger)anInt 496| 0|{ 497| 0| return [NSString stringWithFormat:@"(%@)", [[self getArgumentAtIndexAsObject:anInt] description]]; 498| 0|} 499| | 500| |- (NSString *)pointerDescriptionAtIndex:(NSInteger)anInt 501| 0|{ 502| 0| void *buffer; 503| | 504| 0| [self getArgument:&buffer atIndex:anInt]; 505| | 506| 0| if(buffer == [OCMArg anyPointer]) 507| 0| return OCMArgAnyPointerDescription; 508| 0| else 509| 0| return [NSString stringWithFormat:@"%p", buffer]; 510| 0|} 511| | 512| |- (NSString *)cStringDescriptionAtIndex:(NSInteger)anInt 513| 0|{ 514| 0| char *cStringPtr; 515| | 516| 0| [self getArgument:&cStringPtr atIndex:anInt]; 517| | 518| 0| if(cStringPtr == [OCMArg anyPointer]) 519| 0| { 520| 0| return OCMArgAnyPointerDescription; 521| 0| } 522| 0| else 523| 0| { 524| 0| char buffer[104]; 525| 0| strlcpy(buffer, cStringPtr, sizeof(buffer)); 526| 0| strlcpy(buffer + 100, "...", (sizeof(buffer) - 100)); 527| 0| return [NSString stringWithFormat:@"\"%s\"", buffer]; 528| 0| } 529| 0|} 530| | 531| |- (NSString *)selectorDescriptionAtIndex:(NSInteger)anInt 532| 0|{ 533| 0| SEL selectorValue; 534| | 535| 0| [self getArgument:&selectorValue atIndex:anInt]; 536| 0| return [NSString stringWithFormat:@"@selector(%@)", NSStringFromSelector(selectorValue)]; 537| 0|} 538| | 539| | 540| |- (BOOL)isMethodFamily:(NSString *)family 541| 0|{ 542| | // Definitions here: https://clang.llvm.org/docs/AutomaticReferenceCounting.html#method-families 543| | 544| 0| NSMethodSignature *signature = [self methodSignature]; 545| 0| if(OCMIsObjectType(signature.methodReturnType) == NO) 546| 0| { 547| 0| return NO; 548| 0| } 549| | 550| 0| NSString *selString = NSStringFromSelector([self selector]); 551| 0| NSRange underscoreRange = [selString rangeOfString:@"^_*" options:NSRegularExpressionSearch]; 552| 0| selString = [selString substringFromIndex:NSMaxRange(underscoreRange)]; 553| | 554| 0| if([selString hasPrefix:family] == NO) 555| 0| { 556| 0| return NO; 557| 0| } 558| 0| NSUInteger familyLength = [family length]; 559| 0| if(([selString length] > familyLength) && 560| 0| ([[NSCharacterSet lowercaseLetterCharacterSet] characterIsMember:[selString characterAtIndex:familyLength]])) 561| 0| { 562| 0| return NO; 563| 0| } 564| 0| return YES; 565| 0|} 566| | 567| | 568| |- (BOOL)methodIsInInitFamily 569| 0|{ 570| 0| return [self isMethodFamily:@"init"]; 571| 0|} 572| | 573| |- (BOOL)methodIsInCreateFamily 574| 0|{ 575| 0| return [self isMethodFamily:@"alloc"] 576| 0| || [self isMethodFamily:@"copy"] 577| 0| || [self isMethodFamily:@"mutableCopy"] 578| 0| || [self isMethodFamily:@"new"]; 579| 0|} 580| | 581| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/NSMethodSignature+OCMAdditions.m: 1| |/* 2| | * Copyright (c) 2009-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import 18| |#import "NSMethodSignature+OCMAdditions.h" 19| |#import "OCMFunctionsPrivate.h" 20| | 21| | 22| |@implementation NSMethodSignature(OCMAdditions) 23| | 24| |#pragma mark Signatures for dynamic properties 25| | 26| |+ (NSMethodSignature *)signatureForDynamicPropertyAccessedWithSelector:(SEL)selector inClass:(Class)aClass 27| 0|{ 28| 0| BOOL isGetter = YES; 29| 0| objc_property_t property = [self propertyMatchingSelector:selector inClass:aClass isGetter:&isGetter]; 30| 0| if(property == NULL) 31| 0| return nil; 32| | 33| 0| const char *propertyAttributesString = property_getAttributes(property); 34| 0| NSArray *propertyAttributes = [[NSString stringWithCString:propertyAttributesString 35| 0| encoding:NSASCIIStringEncoding] componentsSeparatedByString:@","]; 36| 0| NSString *typeStr = nil; 37| 0| BOOL isDynamic = NO; 38| 0| for(NSString *attribute in propertyAttributes) 39| 0| { 40| 0| if([attribute isEqualToString:@"D"]) 41| 0| isDynamic = YES; 42| 0| else if([attribute hasPrefix:@"T"]) 43| 0| typeStr = [attribute substringFromIndex:1]; 44| 0| } 45| | 46| 0| if(!isDynamic) 47| 0| return nil; 48| | 49| 0| NSRange r = [typeStr rangeOfString:@"\""]; // incomplete workaround to deal with structs 50| 0| if(r.location != NSNotFound) 51| 0| typeStr = [typeStr substringToIndex:r.location]; 52| | 53| 0| NSString *sigStringFormat = isGetter ? @"%@@:" : @"v@:%@"; 54| 0| const char *sigCString = [[NSString stringWithFormat:sigStringFormat, typeStr] cStringUsingEncoding:NSASCIIStringEncoding]; 55| 0| return [NSMethodSignature signatureWithObjCTypes:sigCString]; 56| 0|} 57| | 58| | 59| |+ (objc_property_t)propertyMatchingSelector:(SEL)selector inClass:(Class)aClass isGetter:(BOOL *)isGetterPtr 60| 0|{ 61| 0| NSString *propertyName = NSStringFromSelector(selector); 62| | 63| | // first try selector as is aassuming it's a getter 64| 0| objc_property_t property = class_getProperty(aClass, [propertyName cStringUsingEncoding:NSASCIIStringEncoding]); 65| 0| if(property != NULL) 66| 0| { 67| 0| *isGetterPtr = YES; 68| 0| return property; 69| 0| } 70| | 71| | // try setter next if selector starts with "set" 72| 0| if([propertyName hasPrefix:@"set"]) 73| 0| { 74| 0| propertyName = [propertyName substringFromIndex:@"set".length]; 75| 0| propertyName = [propertyName stringByReplacingCharactersInRange:NSMakeRange(0, 1) withString:[[propertyName substringToIndex:1] lowercaseString]]; 76| 0| if([propertyName hasSuffix:@":"]) 77| 0| propertyName = [propertyName substringToIndex:[propertyName length] - 1]; 78| | 79| 0| property = class_getProperty(aClass, [propertyName cStringUsingEncoding:NSASCIIStringEncoding]); 80| 0| if(property != NULL) 81| 0| { 82| 0| *isGetterPtr = NO; 83| 0| return property; 84| 0| } 85| 0| } 86| | 87| | // search through properties with custom getter/setter that corresponds to selector 88| 0| unsigned int propertiesCount = 0; 89| 0| objc_property_t *allProperties = class_copyPropertyList(aClass, &propertiesCount); 90| 0| for(unsigned int i = 0 ; i < propertiesCount; i++) 91| 0| { 92| 0| NSArray *propertyAttributes = [[NSString stringWithCString:property_getAttributes(allProperties[i]) 93| 0| encoding:NSASCIIStringEncoding] componentsSeparatedByString:@","]; 94| 0| for(NSString *attribute in propertyAttributes) 95| 0| { 96| 0| if(([attribute hasPrefix:@"G"] || [attribute hasPrefix:@"S"]) && 97| 0| [[attribute substringFromIndex:1] isEqualToString:propertyName]) 98| 0| { 99| 0| *isGetterPtr = ![attribute hasPrefix:@"S"]; 100| 0| property = allProperties[i]; 101| 0| i = propertiesCount; 102| 0| break; 103| 0| } 104| 0| } 105| 0| } 106| 0| free(allProperties); 107| | 108| 0| return property; 109| 0|} 110| | 111| | 112| |#pragma mark Signatures for blocks 113| | 114| |+ (NSMethodSignature *)signatureForBlock:(id)block 115| 0|{ 116| | /* For a more complete implementation of parsing the block data structure see: 117| | * 118| | * https://github.com/ebf/CTObjectiveCRuntimeAdditions/tree/master/CTObjectiveCRuntimeAdditions/CTObjectiveCRuntimeAdditions 119| | */ 120| | 121| 0| struct OCMBlockDef *blockRef = (__bridge struct OCMBlockDef *) block; 122| | 123| 0| if(!(blockRef->flags & OCMBlockDescriptionFlagsHasSignature)) 124| 0| return nil; 125| | 126| 0| void *signatureLocation = blockRef->descriptor; 127| 0| signatureLocation += sizeof(unsigned long int); 128| 0| signatureLocation += sizeof(unsigned long int); 129| 0| if(blockRef->flags & OCMBlockDescriptionFlagsHasCopyDispose) 130| 0| { 131| 0| signatureLocation += sizeof(void (*)(void *dst, void *src)); 132| 0| signatureLocation += sizeof(void (*)(void *src)); 133| 0| } 134| | 135| 0| const char *signature = (*(const char **) signatureLocation); 136| 0| return [NSMethodSignature signatureWithObjCTypes:signature]; 137| 0|} 138| | 139| | 140| |#pragma mark Extended attributes 141| | 142| |- (BOOL)usesSpecialStructureReturn 143| 0|{ 144| 0| const char *types = OCMTypeWithoutQualifiers([self methodReturnType]); 145| | 146| 0| if((types == NULL) || (types[0] != '{')) 147| 0| return NO; 148| | 149| | /* In some cases structures are returned by ref. The rules are complex and depend on the 150| | architecture, see: 151| | 152| | http://sealiesoftware.com/blog/archive/2008/10/30/objc_explain_objc_msgSend_stret.html 153| | http://developer.apple.com/library/mac/#documentation/DeveloperTools/Conceptual/LowLevelABI/000-Introduction/introduction.html 154| | https://github.com/atgreen/libffi/blob/master/src/x86/ffi64.c 155| | http://www.uclibc.org/docs/psABI-x86_64.pdf 156| | http://infocenter.arm.com/help/topic/com.arm.doc.ihi0042e/IHI0042E_aapcs.pdf 157| | 158| | NSMethodSignature knows the details but has no API to return it, though it is in 159| | the debugDescription. Horribly kludgy. 160| | */ 161| 0| NSRange range = [[self debugDescription] rangeOfString:@"is special struct return? YES"]; 162| 0| return range.length > 0; 163| 0|} 164| | 165| | 166| |- (NSString *)fullTypeString 167| 0|{ 168| 0| NSMutableString *typeString = [NSMutableString string]; 169| 0| [typeString appendFormat:@"%s", [self methodReturnType]]; 170| 0| for (NSUInteger i=0; i<[self numberOfArguments]; i++) 171| 0| [typeString appendFormat:@"%s", [self getArgumentTypeAtIndex:i]]; 172| 0| return typeString; 173| 0|} 174| | 175| | 176| |- (const char *)fullObjCTypes 177| 0|{ 178| 0| return [[self fullTypeString] UTF8String]; 179| 0|} 180| | 181| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/NSNotificationCenter+OCMAdditions.m: 1| |/* 2| | * Copyright (c) 2009-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import "NSNotificationCenter+OCMAdditions.h" 18| |#import "OCObserverMockObject.h" 19| | 20| | 21| |@implementation NSNotificationCenter(OCMAdditions) 22| | 23| |#pragma clang diagnostic push 24| |#pragma clang diagnostic ignored "-Wdeprecated-declarations" 25| | 26| |- (void)addMockObserver:(OCObserverMockObject *)notificationObserver name:(NSString *)notificationName object:(id)notificationSender 27| 0|{ 28| 0| [notificationObserver autoRemoveFromCenter:self]; 29| 0| [self addObserver:notificationObserver selector:@selector(handleNotification:) name:notificationName object:notificationSender]; 30| 0|} 31| | 32| |#pragma clang diagnostic pop 33| | 34| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/NSObject+OCMAdditions.m: 1| |/* 2| | * Copyright (c) 2009-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import 18| |#import "NSObject+OCMAdditions.h" 19| |#import "NSMethodSignature+OCMAdditions.h" 20| | 21| | 22| |@implementation NSObject(OCMAdditions) 23| | 24| |+ (IMP)instanceMethodForwarderForSelector:(SEL)aSelector 25| 0|{ 26| | // use sel_registerName() and not @selector to avoid warning 27| 0| SEL selectorWithNoImplementation = sel_registerName("methodWhichMustNotExist::::"); 28| | 29| 0|#ifndef __arm64__ 30| 0| static NSMutableDictionary *_OCMReturnTypeCache; 31| | 32| 0| if(_OCMReturnTypeCache == nil) 33| 0| _OCMReturnTypeCache = [[NSMutableDictionary alloc] init]; 34| | 35| 0| BOOL needsStructureReturn; 36| 0| void *rawCacheKey[2] = { (void *)self, aSelector }; 37| 0| NSData *cacheKey = [NSData dataWithBytes:rawCacheKey length:sizeof(rawCacheKey)]; 38| 0| NSNumber *cachedValue = [_OCMReturnTypeCache objectForKey:cacheKey]; 39| | 40| 0| if(cachedValue == nil) 41| 0| { 42| 0| NSMethodSignature *sig = [self instanceMethodSignatureForSelector:aSelector]; 43| 0| needsStructureReturn = [sig usesSpecialStructureReturn]; 44| 0| [_OCMReturnTypeCache setObject:@(needsStructureReturn) forKey:cacheKey]; 45| 0| } 46| 0| else 47| 0| { 48| 0| needsStructureReturn = [cachedValue boolValue]; 49| 0| } 50| | 51| 0| if(needsStructureReturn) 52| 0| return class_getMethodImplementation_stret([NSObject class], selectorWithNoImplementation); 53| 0|#endif 54| | 55| 0| return class_getMethodImplementation([NSObject class], selectorWithNoImplementation); 56| 0|} 57| | 58| | 59| |+ (void)enumerateMethodsInClass:(Class)aClass usingBlock:(void (^)(Class cls, SEL sel))aBlock 60| 0|{ 61| 0| for(Class cls = aClass; cls != nil; cls = class_getSuperclass(cls)) 62| 0| { 63| 0| Method *methodList = class_copyMethodList(cls, NULL); 64| 0| if(methodList == NULL) 65| 0| continue; 66| | 67| 0| for(Method *mPtr = methodList; *mPtr != NULL; mPtr++) 68| 0| { 69| 0| SEL sel = method_getName(*mPtr); 70| 0| aBlock(cls, sel); 71| 0| } 72| 0| free(methodList); 73| 0| } 74| 0|} 75| | 76| | 77| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/NSValue+OCMAdditions.m: 1| |/* 2| | * Copyright (c) 2014-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import "NSValue+OCMAdditions.h" 18| |#import "OCMFunctionsPrivate.h" 19| | 20| | 21| |@implementation NSValue(OCMAdditions) 22| | 23| |static NSNumber *OCMNumberForValue(NSValue *value) 24| 0|{ 25| 0|#define CREATE_NUM(_type) ({ _type _v; [value getValue:&_v]; @(_v); }) 26| 0| switch([value objCType][0]) 27| 0| { 28| 0| case 'c': return CREATE_NUM(char); 29| 0| case 'C': return CREATE_NUM(unsigned char); 30| 0| case 'B': return CREATE_NUM(bool); 31| 0| case 's': return CREATE_NUM(short); 32| 0| case 'S': return CREATE_NUM(unsigned short); 33| 0| case 'i': return CREATE_NUM(int); 34| 0| case 'I': return CREATE_NUM(unsigned int); 35| 0| case 'l': return CREATE_NUM(long); 36| 0| case 'L': return CREATE_NUM(unsigned long); 37| 0| case 'q': return CREATE_NUM(long long); 38| 0| case 'Q': return CREATE_NUM(unsigned long long); 39| 0| case 'f': return CREATE_NUM(float); 40| 0| case 'd': return CREATE_NUM(double); 41| 0| default: return nil; 42| 0| } 43| 0|} 44| | 45| | 46| |- (BOOL)getBytes:(void *)outputBuf objCType:(const char *)targetType 47| 0|{ 48| | /* 49| | * See if they are similar number types, and if we can convert losslessly between them. 50| | * For the most part, we set things up to use CFNumberGetValue, which returns false if 51| | * conversion will be lossy. 52| | */ 53| 0| CFNumberType inputType = OCMNumberTypeForObjCType([self objCType]); 54| 0| CFNumberType outputType = OCMNumberTypeForObjCType(targetType); 55| | 56| 0| if(inputType == 0 || outputType == 0) // one or both are non-number types 57| 0| return NO; 58| | 59| 0| NSNumber *inputNumber = [self isKindOfClass:[NSNumber class]] ? (NSNumber *)self : OCMNumberForValue(self); 60| | 61| | /* 62| | * Due to some legacy, back-compatible requirements in CFNumber.c, CFNumberGetValue can return true for 63| | * some conversions which should not be allowed (by reading source, conversions from integer types to 64| | * 8-bit or 16-bit integer types). So, check ourselves. 65| | */ 66| 0| long long min; 67| 0| long long max; 68| 0| long long val = [inputNumber longLongValue]; 69| 0| switch(targetType[0]) 70| 0| { 71| 0| case 'B': 72| 0| case 'c': min = CHAR_MIN; max = CHAR_MAX; break; 73| 0| case 'C': min = 0; max = UCHAR_MAX; break; 74| 0| case 's': min = SHRT_MIN; max = SHRT_MAX; break; 75| 0| case 'S': min = 0; max = USHRT_MAX; break; 76| 0| default: min = LLONG_MIN; max = LLONG_MAX; break; 77| 0| } 78| 0| if(val < min || val > max) 79| 0| return NO; 80| | 81| | /* Get the number, and return NO if the value was out of range or conversion was lossy */ 82| 0| return CFNumberGetValue((CFNumberRef)inputNumber, outputType, outputBuf); 83| 0|} 84| | 85| | 86| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/OCClassMockObject.m: 1| |/* 2| | * Copyright (c) 2005-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import 18| |#import "OCClassMockObject.h" 19| |#import "OCMInvocationStub.h" 20| |#import "OCMFunctionsPrivate.h" 21| |#import "NSMethodSignature+OCMAdditions.h" 22| |#import "NSObject+OCMAdditions.h" 23| | 24| |@interface NSObject(OCMClassMockingSupport) 25| |+ (BOOL)supportsMocking:(NSString **)reason; 26| |@end 27| | 28| | 29| |@implementation OCClassMockObject 30| | 31| |#pragma mark Initialisers, description, accessors, etc. 32| | 33| |- (id)initWithClass:(Class)aClass 34| 0|{ 35| 0| [self assertClassIsSupported:aClass]; 36| 0| [super init]; 37| 0| mockedClass = aClass; 38| 0| [self prepareClassForClassMethodMocking]; 39| 0| return self; 40| 0|} 41| | 42| |- (void)dealloc 43| 0|{ 44| 0| [self stopMocking]; 45| 0| [super dealloc]; 46| 0|} 47| | 48| |- (NSString *)description 49| 0|{ 50| 0| return [NSString stringWithFormat:@"OCClassMockObject(%@)", NSStringFromClass(mockedClass)]; 51| 0|} 52| | 53| |- (Class)mockedClass 54| 0|{ 55| 0| return mockedClass; 56| 0|} 57| | 58| |- (void)assertClassIsSupported:(Class)aClass 59| 0|{ 60| 0| if(aClass == Nil) 61| 0| [NSException raise:NSInvalidArgumentException format:@"Class cannot be Nil."]; 62| | 63| 0| if([aClass respondsToSelector:@selector(supportsMocking:)]) 64| 0| { 65| 0| NSString *reason = nil; 66| 0| if(![aClass supportsMocking:&reason]) 67| 0| [NSException raise:NSInvalidArgumentException format:@"Class %@ does not support mocking: %@", aClass, reason]; 68| 0| } 69| 0|} 70| | 71| |#pragma mark Extending/overriding superclass behaviour 72| | 73| |- (void)stopMocking 74| 0|{ 75| 0| if(originalMetaClass != nil) 76| 0| { 77| 0| [self stopMockingClassMethods]; 78| 0| } 79| 0| if(classCreatedForNewMetaClass != nil) 80| 0| { 81| 0| OCMDisposeSubclass(classCreatedForNewMetaClass); 82| 0| classCreatedForNewMetaClass = nil; 83| 0| } 84| 0| [super stopMocking]; 85| 0|} 86| | 87| | 88| |- (void)stopMockingClassMethods 89| 0|{ 90| 0| OCMSetAssociatedMockForClass(nil, mockedClass); 91| 0| object_setClass(mockedClass, originalMetaClass); 92| 0| originalMetaClass = nil; 93| | /* created meta class will be disposed later because partial mocks create another subclass depending on it */ 94| 0|} 95| | 96| | 97| |- (void)addStub:(OCMInvocationStub *)aStub 98| 0|{ 99| 0| [super addStub:aStub]; 100| 0| if([aStub recordedAsClassMethod]) 101| 0| [self setupForwarderForClassMethodSelector:[[aStub recordedInvocation] selector]]; 102| 0|} 103| | 104| | 105| |#pragma mark Class method mocking 106| | 107| |- (void)prepareClassForClassMethodMocking 108| 0|{ 109| | /* the runtime and OCMock depend on string and array; we don't intercept methods on them to avoid endless loops */ 110| 0| if([[mockedClass class] isSubclassOfClass:[NSString class]] || [[mockedClass class] isSubclassOfClass:[NSArray class]]) 111| 0| return; 112| | 113| | /* trying to replace class methods on NSManagedObject and subclasses of it doesn't work; see #339 */ 114| 0| if([mockedClass isSubclassOfClass:objc_getClass("NSManagedObject")]) 115| 0| return; 116| | 117| | /* if there is another mock for this exact class, stop it */ 118| 0| id otherMock = OCMGetAssociatedMockForClass(mockedClass, NO); 119| 0| if(otherMock != nil) 120| 0| [otherMock stopMockingClassMethods]; 121| | 122| 0| OCMSetAssociatedMockForClass(self, mockedClass); 123| | 124| | /* dynamically create a subclass and use its meta class as the meta class for the mocked class */ 125| 0| classCreatedForNewMetaClass = OCMCreateSubclass(mockedClass, mockedClass); 126| 0| originalMetaClass = object_getClass(mockedClass); 127| 0| id newMetaClass = object_getClass(classCreatedForNewMetaClass); 128| | 129| | /* create a dummy initialize method */ 130| 0| Method myDummyInitializeMethod = class_getInstanceMethod([self mockObjectClass], @selector(initializeForClassObject)); 131| 0| const char *initializeTypes = method_getTypeEncoding(myDummyInitializeMethod); 132| 0| IMP myDummyInitializeIMP = method_getImplementation(myDummyInitializeMethod); 133| 0| class_addMethod(newMetaClass, @selector(initialize), myDummyInitializeIMP, initializeTypes); 134| | 135| 0| object_setClass(mockedClass, newMetaClass); // only after dummy initialize is installed (iOS9) 136| | 137| | /* point forwardInvocation: of the object to the implementation in the mock */ 138| 0| Method myForwardMethod = class_getInstanceMethod([self mockObjectClass], @selector(forwardInvocationForClassObject:)); 139| 0| IMP myForwardIMP = method_getImplementation(myForwardMethod); 140| 0| class_addMethod(newMetaClass, @selector(forwardInvocation:), myForwardIMP, method_getTypeEncoding(myForwardMethod)); 141| | 142| | /* adding forwarder for most class methods (instance methods on meta class) to allow for verify after run */ 143| 0| NSArray *methodBlackList = @[@"class", @"forwardingTargetForSelector:", @"methodSignatureForSelector:", @"forwardInvocation:", @"isBlock", 144| 0| @"instanceMethodForwarderForSelector:", @"instanceMethodSignatureForSelector:", @"resolveClassMethod:"]; 145| 0| [NSObject enumerateMethodsInClass:originalMetaClass usingBlock:^(Class cls, SEL sel) { 146| 0| if((cls == object_getClass([NSObject class])) || (cls == [NSObject class]) || (cls == object_getClass(cls))) 147| 0| return; 148| 0| if(OCMIsApplePrivateMethod(cls, sel)) 149| 0| return; 150| 0| if([methodBlackList containsObject:NSStringFromSelector(sel)]) 151| 0| return; 152| 0| @try 153| 0| { 154| 0| [self setupForwarderForClassMethodSelector:sel]; 155| 0| } 156| 0| @catch(NSException *e) 157| 0| { 158| | // ignore for now 159| 0| } 160| 0| }]; 161| 0|} 162| | 163| | 164| |- (void)setupForwarderForClassMethodSelector:(SEL)selector 165| 0|{ 166| 0| SEL aliasSelector = OCMAliasForOriginalSelector(selector); 167| 0| if(class_getClassMethod(mockedClass, aliasSelector) != NULL) 168| 0| return; 169| | 170| 0| Method originalMethod = class_getClassMethod(mockedClass, selector); 171| 0| IMP originalIMP = method_getImplementation(originalMethod); 172| 0| const char *types = method_getTypeEncoding(originalMethod); 173| | 174| 0| Class metaClass = object_getClass(mockedClass); 175| 0| IMP forwarderIMP = [originalMetaClass instanceMethodForwarderForSelector:selector]; 176| 0| class_addMethod(metaClass, aliasSelector, originalIMP, types); 177| 0| class_replaceMethod(metaClass, selector, forwarderIMP, types); 178| 0|} 179| | 180| | 181| |- (void)forwardInvocationForClassObject:(NSInvocation *)anInvocation 182| 0|{ 183| | // in here "self" is a reference to the real class, not the mock 184| 0| OCClassMockObject *mock = OCMGetAssociatedMockForClass((Class) self, YES); 185| 0| if(mock == nil) 186| 0| { 187| 0| [NSException raise:NSInternalInconsistencyException format:@"No mock for class %@", NSStringFromClass((Class)self)]; 188| 0| } 189| 0| if([mock handleInvocation:anInvocation] == NO) 190| 0| { 191| 0| [anInvocation setSelector:OCMAliasForOriginalSelector([anInvocation selector])]; 192| 0| [anInvocation invoke]; 193| 0| } 194| 0|} 195| | 196| |- (void)initializeForClassObject 197| 0|{ 198| | // we really just want to have an implementation so that the superclass's is not called 199| 0|} 200| | 201| | 202| |#pragma mark Proxy API 203| | 204| |- (NSMethodSignature *)methodSignatureForSelector:(SEL)aSelector 205| 0|{ 206| 0| NSMethodSignature *signature = [mockedClass instanceMethodSignatureForSelector:aSelector]; 207| 0| if(signature == nil) 208| 0| { 209| 0| signature = [NSMethodSignature signatureForDynamicPropertyAccessedWithSelector:aSelector inClass:mockedClass]; 210| 0| } 211| 0| return signature; 212| 0|} 213| | 214| |- (Class)mockObjectClass 215| 0|{ 216| 0| return [super class]; 217| 0|} 218| | 219| |- (Class)class 220| 0|{ 221| 0| return mockedClass; 222| 0|} 223| | 224| |- (BOOL)respondsToSelector:(SEL)selector 225| 0|{ 226| 0| return [mockedClass instancesRespondToSelector:selector]; 227| 0|} 228| | 229| |- (BOOL)isKindOfClass:(Class)aClass 230| 0|{ 231| 0| return [mockedClass isSubclassOfClass:aClass]; 232| 0|} 233| | 234| |- (BOOL)conformsToProtocol:(Protocol *)aProtocol 235| 0|{ 236| 0| Class clazz = mockedClass; 237| 0| while (clazz != nil) { 238| 0| if (class_conformsToProtocol(clazz, aProtocol)) { 239| 0| return YES; 240| 0| } 241| 0| clazz = class_getSuperclass(clazz); 242| 0| } 243| 0| return NO; 244| 0|} 245| | 246| |@end 247| | 248| | 249| |#pragma mark - 250| | 251| |/* 252| | taken from: 253| | `class-dump -f isNS /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.0.sdk/System/Library/Frameworks/CoreFoundation.framework` 254| | 255| | @ interface NSObject (__NSIsKinds) 256| | - (_Bool)isNSValue__; 257| | - (_Bool)isNSTimeZone__; 258| | - (_Bool)isNSString__; 259| | - (_Bool)isNSSet__; 260| | - (_Bool)isNSOrderedSet__; 261| | - (_Bool)isNSNumber__; 262| | - (_Bool)isNSDictionary__; 263| | - (_Bool)isNSDate__; 264| | - (_Bool)isNSData__; 265| | - (_Bool)isNSArray__; 266| | */ 267| | 268| |@implementation OCClassMockObject(NSIsKindsImplementation) 269| | 270| |- (BOOL)isNSValue__ 271| 0|{ 272| 0| return [mockedClass isSubclassOfClass:[NSValue class]]; 273| 0|} 274| | 275| |- (BOOL)isNSTimeZone__ 276| 0|{ 277| 0| return [mockedClass isSubclassOfClass:[NSTimeZone class]]; 278| 0|} 279| | 280| |- (BOOL)isNSSet__ 281| 0|{ 282| 0| return [mockedClass isSubclassOfClass:[NSSet class]]; 283| 0|} 284| | 285| |- (BOOL)isNSOrderedSet__ 286| 0|{ 287| 0| return [mockedClass isSubclassOfClass:[NSOrderedSet class]]; 288| 0|} 289| | 290| |- (BOOL)isNSNumber__ 291| 0|{ 292| 0| return [mockedClass isSubclassOfClass:[NSNumber class]]; 293| 0|} 294| | 295| |- (BOOL)isNSDate__ 296| 0|{ 297| 0| return [mockedClass isSubclassOfClass:[NSDate class]]; 298| 0|} 299| | 300| |- (BOOL)isNSString__ 301| 0|{ 302| 0| return [mockedClass isSubclassOfClass:[NSString class]]; 303| 0|} 304| | 305| |- (BOOL)isNSDictionary__ 306| 0|{ 307| 0| return [mockedClass isSubclassOfClass:[NSDictionary class]]; 308| 0|} 309| | 310| |- (BOOL)isNSData__ 311| 0|{ 312| 0| return [mockedClass isSubclassOfClass:[NSData class]]; 313| 0|} 314| | 315| |- (BOOL)isNSArray__ 316| 0|{ 317| 0| return [mockedClass isSubclassOfClass:[NSArray class]]; 318| 0|} 319| | 320| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/OCMArg.m: 1| |/* 2| | * Copyright (c) 2009-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import 18| |#import "OCMArg.h" 19| |#import "OCMBlockArgCaller.h" 20| |#import "OCMConstraint.h" 21| |#import "OCMPassByRefSetter.h" 22| | 23| | 24| |@implementation OCMArg 25| | 26| |+ (id)any 27| 0|{ 28| 0| return [OCMAnyConstraint constraint]; 29| 0|} 30| | 31| |+ (void *)anyPointer 32| 0|{ 33| 0| return (void *)0x01234567; 34| 0|} 35| | 36| |+ (id __autoreleasing *)anyObjectRef 37| 0|{ 38| 0| return (id *)0x01234567; 39| 0|} 40| | 41| |+ (SEL)anySelector 42| 0|{ 43| 0| return NSSelectorFromString(@"aSelectorThatMatchesAnySelector"); 44| 0|} 45| | 46| |+ (id)isNil 47| 0|{ 48| 0| return [OCMIsNilConstraint constraint]; 49| 0|} 50| | 51| |+ (id)isNotNil 52| 0|{ 53| 0| return [OCMIsNotNilConstraint constraint]; 54| 0|} 55| | 56| |+ (id)isEqual:(id)value 57| 0|{ 58| 0| return value; 59| 0|} 60| | 61| |+ (id)isNotEqual:(id)value 62| 0|{ 63| 0| OCMIsNotEqualConstraint *constraint = [OCMIsNotEqualConstraint constraint]; 64| 0| constraint->testValue = value; 65| 0| return constraint; 66| 0|} 67| | 68| |+ (id)isKindOfClass:(Class)cls 69| 0|{ 70| 0| return [[[OCMBlockConstraint alloc] initWithConstraintBlock:^BOOL(id obj) { 71| 0| return [obj isKindOfClass:cls]; 72| 0| }] autorelease]; 73| 0|} 74| | 75| |+ (id)checkWithSelector:(SEL)selector onObject:(id)anObject 76| 0|{ 77| 0| return [OCMConstraint constraintWithSelector:selector onObject:anObject]; 78| 0|} 79| | 80| |+ (id)checkWithBlock:(BOOL (^)(id))block 81| 0|{ 82| 0| return [[[OCMBlockConstraint alloc] initWithConstraintBlock:block] autorelease]; 83| 0|} 84| | 85| |+ (id *)setTo:(id)value 86| 0|{ 87| 0| return (id *)[[[OCMPassByRefSetter alloc] initWithValue:value] autorelease]; 88| 0|} 89| | 90| |+ (void *)setToValue:(NSValue *)value 91| 0|{ 92| 0| return (id *)[[[OCMPassByRefSetter alloc] initWithValue:value] autorelease]; 93| 0|} 94| | 95| |+ (id)invokeBlock 96| 0|{ 97| 0| return [[[OCMBlockArgCaller alloc] init] autorelease]; 98| 0|} 99| | 100| |+ (id)invokeBlockWithArgs:(id)first,... NS_REQUIRES_NIL_TERMINATION 101| 0|{ 102| | 103| 0| NSMutableArray *params = [NSMutableArray array]; 104| 0| va_list args; 105| 0| if(first) 106| 0| { 107| 0| [params addObject:first]; 108| 0| va_start(args, first); 109| 0| id obj; 110| 0| while((obj = va_arg(args, id))) 111| 0| { 112| 0| [params addObject:obj]; 113| 0| } 114| 0| va_end(args); 115| 0| } 116| 0| return [[[OCMBlockArgCaller alloc] initWithBlockArguments:params] autorelease]; 117| | 118| 0|} 119| | 120| |+ (id)defaultValue 121| 0|{ 122| 0| return [NSNull null]; 123| 0|} 124| | 125| | 126| |+ (id)resolveSpecialValues:(NSValue *)value 127| 0|{ 128| 0| const char *type = [value objCType]; 129| 0| if(type[0] == '^') 130| 0| { 131| 0| void *pointer = [value pointerValue]; 132| 0| if(pointer == (void *)0x01234567) 133| 0| return [OCMArg any]; 134| 0| if((pointer != NULL) && (object_getClass((id)pointer) == [OCMPassByRefSetter class])) 135| 0| return (id)pointer; 136| 0| } 137| 0| else if(type[0] == ':') 138| 0| { 139| 0| SEL selector; 140| 0| [value getValue:&selector]; 141| 0| if(selector == NSSelectorFromString(@"aSelectorThatMatchesAnySelector")) 142| 0| return [OCMArg any]; 143| 0| } 144| 0| return value; 145| 0|} 146| | 147| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/OCMArgAction.m: 1| |/* 2| | * Copyright (c) 2015-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import "OCMArgAction.h" 18| | 19| | 20| |@implementation OCMArgAction 21| | 22| |- (void)handleArgument:(id)argument 23| 0|{ 24| | 25| 0|} 26| | 27| | 28| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/OCMBlockArgCaller.m: 1| |/* 2| | * Copyright (c) 2015-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import "OCMBlockArgCaller.h" 18| |#import "NSInvocation+OCMAdditions.h" 19| | 20| | 21| |@implementation OCMBlockArgCaller 22| | 23| |- (instancetype)initWithBlockArguments:(NSArray *)someArgs 24| 0|{ 25| 0| self = [super init]; 26| 0| if(self) 27| 0| { 28| 0| arguments = [someArgs copy]; 29| 0| } 30| 0| return self; 31| 0|} 32| | 33| |- (void)dealloc 34| 0|{ 35| 0| [arguments release]; 36| 0| [super dealloc]; 37| 0|} 38| | 39| |- (id)copyWithZone:(NSZone *)zone 40| 0|{ 41| 0| return [self retain]; 42| 0|} 43| | 44| |- (void)handleArgument:(id)aBlock 45| 0|{ 46| 0| if(aBlock) 47| 0| { 48| 0| NSInvocation *inv = [NSInvocation invocationForBlock:aBlock withArguments:arguments]; 49| 0| [inv invokeWithTarget:aBlock]; 50| 0| } 51| 0|} 52| | 53| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/OCMBlockCaller.m: 1| |/* 2| | * Copyright (c) 2010-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import "OCMBlockCaller.h" 18| | 19| | 20| |@implementation OCMBlockCaller 21| | 22| |-(id)initWithCallBlock:(void (^)(NSInvocation *))theBlock 23| 0|{ 24| 0| if ((self = [super init])) 25| 0| { 26| 0| block = [theBlock copy]; 27| 0| } 28| | 29| 0| return self; 30| 0|} 31| | 32| |-(void)dealloc 33| 0|{ 34| 0| [block release]; 35| 0| [super dealloc]; 36| 0|} 37| | 38| |- (void)handleInvocation:(NSInvocation *)anInvocation 39| 0|{ 40| 0| if (block != nil) 41| 0| { 42| 0| block(anInvocation); 43| 0| } 44| 0|} 45| | 46| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/OCMBoxedReturnValueProvider.m: 1| |/* 2| | * Copyright (c) 2009-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import "OCMBoxedReturnValueProvider.h" 18| |#import "OCMFunctionsPrivate.h" 19| |#import "NSValue+OCMAdditions.h" 20| | 21| | 22| |@implementation OCMBoxedReturnValueProvider 23| | 24| |- (void)handleInvocation:(NSInvocation *)anInvocation 25| 0|{ 26| 0| NSUInteger valueSize = 0; 27| 0| NSValue *returnValueAsNSValue = (NSValue *)returnValue; 28| 0| NSGetSizeAndAlignment([returnValueAsNSValue objCType], &valueSize, NULL); 29| 0| char valueBuffer[valueSize]; 30| 0| [returnValueAsNSValue getValue:valueBuffer]; 31| | 32| 0| const char *returnType = [[anInvocation methodSignature] methodReturnType]; 33| | 34| 0| if([self isMethodReturnType:returnType compatibleWithValueType:[returnValueAsNSValue objCType] 35| 0| value:valueBuffer valueSize:valueSize]) 36| 0| { 37| 0| [anInvocation setReturnValue:valueBuffer]; 38| 0| } 39| 0| else if([returnValueAsNSValue getBytes:valueBuffer objCType:returnType]) 40| 0| { 41| 0| [anInvocation setReturnValue:valueBuffer]; 42| 0| } 43| 0| else 44| 0| { 45| 0| [NSException raise:NSInvalidArgumentException 46| 0| format:@"Return value cannot be used for method; method signature declares '%s' but value is '%s'.", returnType, [returnValueAsNSValue objCType]]; 47| 0| } 48| 0|} 49| | 50| |- (BOOL)isMethodReturnType:(const char *)returnType compatibleWithValueType:(const char *)valueType value:(const void *)value valueSize:(size_t)valueSize 51| 0|{ 52| | /* Same types are obviously compatible */ 53| 0| if(strcmp(returnType, valueType) == 0) 54| 0| return YES; 55| | 56| | /* Special treatment for nil and Nil */ 57| 0| if(strcmp(returnType, @encode(id)) == 0 || strcmp(returnType, @encode(Class)) == 0) 58| 0| return OCMIsNilValue(valueType, value, valueSize); 59| | 60| 0| return OCMEqualTypesAllowingOpaqueStructs(returnType, valueType); 61| 0|} 62| | 63| | 64| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/OCMConstraint.m: 1| |#import 2| |/* 3| | * Copyright (c) 2007-2020 Erik Doernenburg and contributors 4| | * 5| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 6| | * not use these files except in compliance with the License. You may obtain 7| | * a copy of the License at 8| | * 9| | * http://www.apache.org/licenses/LICENSE-2.0 10| | * 11| | * Unless required by applicable law or agreed to in writing, software 12| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 13| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 14| | * License for the specific language governing permissions and limitations 15| | * under the License. 16| | */ 17| | 18| |#import "OCMConstraint.h" 19| | 20| | 21| |@implementation OCMConstraint 22| | 23| |+ (instancetype)constraint 24| 0|{ 25| 0| return [[[self alloc] init] autorelease]; 26| 0|} 27| | 28| |- (BOOL)evaluate:(id)value 29| 0|{ 30| 0| return NO; 31| 0|} 32| | 33| |- (id)copyWithZone:(struct _NSZone *)zone __unused 34| 0|{ 35| 0| return [self retain]; 36| 0|} 37| | 38| |+ (instancetype)constraintWithSelector:(SEL)aSelector onObject:(id)anObject 39| 0|{ 40| 0| OCMInvocationConstraint *constraint = [OCMInvocationConstraint constraint]; 41| 0| NSMethodSignature *signature = [anObject methodSignatureForSelector:aSelector]; 42| 0| if(signature == nil) 43| 0| [NSException raise:NSInvalidArgumentException format:@"Unkown selector %@ used in constraint.", NSStringFromSelector(aSelector)]; 44| 0| NSInvocation *invocation = [NSInvocation invocationWithMethodSignature:signature]; 45| 0| [invocation setTarget:anObject]; 46| 0| [invocation setSelector:aSelector]; 47| 0| constraint->invocation = invocation; 48| 0| return constraint; 49| 0|} 50| | 51| |+ (instancetype)constraintWithSelector:(SEL)aSelector onObject:(id)anObject withValue:(id)aValue 52| 0|{ 53| 0| OCMInvocationConstraint *constraint = (OCMInvocationConstraint *)[self constraintWithSelector:aSelector onObject:anObject]; 54| 0| if([[constraint->invocation methodSignature] numberOfArguments] < 4) 55| 0| [NSException raise:NSInvalidArgumentException format:@"Constraint with value requires selector with two arguments."]; 56| 0| [constraint->invocation setArgument:&aValue atIndex:3]; 57| 0| return constraint; 58| 0|} 59| | 60| | 61| |@end 62| | 63| | 64| | 65| |#pragma mark - 66| | 67| |@implementation OCMAnyConstraint 68| | 69| |- (BOOL)evaluate:(id)value 70| 0|{ 71| 0| return YES; 72| 0|} 73| | 74| |@end 75| | 76| | 77| | 78| |#pragma mark - 79| | 80| |@implementation OCMIsNilConstraint 81| | 82| |- (BOOL)evaluate:(id)value 83| 0|{ 84| 0| return value == nil; 85| 0|} 86| | 87| |@end 88| | 89| | 90| | 91| |#pragma mark - 92| | 93| |@implementation OCMIsNotNilConstraint 94| | 95| |- (BOOL)evaluate:(id)value 96| 0|{ 97| 0| return value != nil; 98| 0|} 99| | 100| |@end 101| | 102| | 103| | 104| |#pragma mark - 105| | 106| |@implementation OCMIsNotEqualConstraint 107| | 108| |- (BOOL)evaluate:(id)value 109| 0|{ 110| 0| return ![value isEqual:testValue]; 111| 0|} 112| | 113| |@end 114| | 115| | 116| | 117| |#pragma mark - 118| | 119| |@implementation OCMInvocationConstraint 120| | 121| |- (BOOL)evaluate:(id)value 122| 0|{ 123| 0| [invocation setArgument:&value atIndex:2]; // should test if constraint takes arg 124| 0| [invocation invoke]; 125| 0| BOOL returnValue; 126| 0| [invocation getReturnValue:&returnValue]; 127| 0| return returnValue; 128| 0|} 129| | 130| |@end 131| | 132| |#pragma mark - 133| | 134| |@implementation OCMBlockConstraint 135| | 136| |- (instancetype)initWithConstraintBlock:(BOOL (^)(id))aBlock 137| 0|{ 138| 0| if ((self = [super init])) 139| 0| { 140| 0| block = [aBlock copy]; 141| 0| } 142| | 143| 0| return self; 144| 0|} 145| | 146| 0|- (void)dealloc { 147| 0| [block release]; 148| 0| [super dealloc]; 149| 0|} 150| | 151| |- (BOOL)evaluate:(id)value 152| 0|{ 153| 0| return block ? block(value) : NO; 154| 0|} 155| | 156| | 157| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/OCMExceptionReturnValueProvider.m: 1| |/* 2| | * Copyright (c) 2009-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import "OCMExceptionReturnValueProvider.h" 18| | 19| | 20| |@implementation OCMExceptionReturnValueProvider 21| | 22| |NSString *OCMStubbedException = @"OCMStubbedException"; 23| | 24| | 25| |- (void)handleInvocation:(NSInvocation *)anInvocation 26| 0|{ 27| 0| [[NSException exceptionWithName:OCMStubbedException reason:@"Exception stubbed in test." userInfo:@{ @"exception": returnValue }] raise]; 28| 0|} 29| | 30| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/OCMExpectationRecorder.m: 1| |/* 2| | * Copyright (c) 2004-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import "OCMExpectationRecorder.h" 18| |#import "OCMockObject.h" 19| |#import "OCMInvocationExpectation.h" 20| | 21| | 22| |@implementation OCMExpectationRecorder 23| | 24| |#pragma mark Initialisers, description, accessors, etc. 25| | 26| |- (id)init 27| 0|{ 28| 0| self = [super init]; 29| 0| [invocationMatcher release]; 30| 0| invocationMatcher = [[OCMInvocationExpectation alloc] init]; 31| 0| return self; 32| 0|} 33| | 34| |- (OCMInvocationExpectation *)expectation 35| 0|{ 36| 0| return (OCMInvocationExpectation *)invocationMatcher; 37| 0|} 38| | 39| | 40| |#pragma mark Modifying the expectation 41| | 42| |- (id)never 43| 0|{ 44| 0| [[self expectation] setMatchAndReject:YES]; 45| 0| return self; 46| 0|} 47| | 48| | 49| |#pragma mark Finishing recording 50| | 51| |- (void)forwardInvocation:(NSInvocation *)anInvocation 52| 0|{ 53| 0| [super forwardInvocation:anInvocation]; 54| 0| [mockObject addExpectation:[self expectation]]; 55| 0|} 56| | 57| | 58| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/OCMFunctions.m: 1| |/* 2| | * Copyright (c) 2014-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import 18| |#if !TARGET_OS_WATCH 19| |#import 20| |#endif 21| |#import "OCMFunctionsPrivate.h" 22| |#import "OCClassMockObject.h" 23| |#import "OCPartialMockObject.h" 24| |#import "OCMLocation.h" 25| | 26| | 27| |#pragma mark Known private API 28| | 29| |@interface NSException(OCMKnownExceptionMethods) 30| |+ (NSException *)failureInFile:(NSString *)file atLine:(int)line withDescription:(NSString *)formatString, ...; 31| |@end 32| | 33| |@interface NSObject(OCMKnownTestCaseMethods) 34| |- (void)recordFailureWithDescription:(NSString *)description inFile:(NSString *)file atLine:(NSUInteger)line expected:(BOOL)expected; 35| |- (void)failWithException:(NSException *)exception; 36| |@end 37| | 38| | 39| |#pragma mark Functions related to ObjC type system 40| | 41| |const char *OCMTypeWithoutQualifiers(const char *objCType) 42| 0|{ 43| 0| while(strchr("rnNoORV", objCType[0]) != NULL) 44| 0| objCType += 1; 45| 0| return objCType; 46| 0|} 47| | 48| | 49| |static BOOL OCMIsUnqualifiedClassType(const char *unqualifiedObjCType) 50| 0|{ 51| 0| return (strcmp(unqualifiedObjCType, @encode(Class)) == 0); 52| 0|} 53| | 54| | 55| |static BOOL OCMIsUnqualifiedBlockType(const char *unqualifiedObjCType) 56| 0|{ 57| 0| char blockType[] = @encode(void(^)(void)); 58| 0| if(strcmp(unqualifiedObjCType, blockType) == 0) 59| 0| return YES; 60| | 61| | // sometimes block argument/return types are tacked onto the type, in angle brackets 62| 0| if(strncmp(unqualifiedObjCType, blockType, sizeof(blockType) - 1) == 0 && unqualifiedObjCType[sizeof(blockType) - 1] == '<') 63| 0| return YES; 64| | 65| 0| return NO; 66| 0|} 67| | 68| |BOOL OCMIsClassType(const char *objCType) 69| 0|{ 70| 0| return OCMIsUnqualifiedClassType(OCMTypeWithoutQualifiers(objCType)); 71| 0|} 72| | 73| |BOOL OCMIsBlockType(const char *objCType) 74| 0|{ 75| 0| return OCMIsUnqualifiedBlockType(OCMTypeWithoutQualifiers(objCType)); 76| 0|} 77| | 78| | 79| |BOOL OCMIsObjectType(const char *objCType) 80| 0|{ 81| 0| const char *unqualifiedObjCType = OCMTypeWithoutQualifiers(objCType); 82| | 83| 0| char objectType[] = @encode(id); 84| 0| if(strcmp(unqualifiedObjCType, objectType) == 0 || OCMIsUnqualifiedClassType(unqualifiedObjCType)) 85| 0| return YES; 86| | 87| | // sometimes the name of an object's class is tacked onto the type, in double quotes 88| 0| if(strncmp(unqualifiedObjCType, objectType, sizeof(objectType) - 1) == 0 && unqualifiedObjCType[sizeof(objectType) - 1] == '"') 89| 0| return YES; 90| | 91| | // if the returnType is a typedef to an object, it has the form ^{OriginClass=#} 92| 0| NSString *regexString = @"^\\^\\{(.*)=#.*\\}"; 93| 0| NSRegularExpression *regex = [NSRegularExpression regularExpressionWithPattern:regexString options:0 error:NULL]; 94| 0| NSString *type = [NSString stringWithCString:unqualifiedObjCType encoding:NSASCIIStringEncoding]; 95| 0| if([regex numberOfMatchesInString:type options:0 range:NSMakeRange(0, type.length)] > 0) 96| 0| return YES; 97| | 98| | // if the return type is a block we treat it like an object 99| 0| return OCMIsUnqualifiedBlockType(unqualifiedObjCType); 100| 0|} 101| | 102| | 103| |CFNumberType OCMNumberTypeForObjCType(const char *objcType) 104| 0|{ 105| 0| switch (objcType[0]) 106| 0| { 107| 0| case 'c': return kCFNumberCharType; 108| 0| case 'C': return kCFNumberCharType; 109| 0| case 'B': return kCFNumberCharType; 110| 0| case 's': return kCFNumberShortType; 111| 0| case 'S': return kCFNumberShortType; 112| 0| case 'i': return kCFNumberIntType; 113| 0| case 'I': return kCFNumberIntType; 114| 0| case 'l': return kCFNumberLongType; 115| 0| case 'L': return kCFNumberLongType; 116| 0| case 'q': return kCFNumberLongLongType; 117| 0| case 'Q': return kCFNumberLongLongType; 118| 0| case 'f': return kCFNumberFloatType; 119| 0| case 'd': return kCFNumberDoubleType; 120| 0| default: return 0; 121| 0| } 122| 0|} 123| | 124| | 125| |static BOOL ParseStructType(const char *type, const char **typeEnd, const char **typeNameEnd, const char **typeEqualSign) 126| 0|{ 127| 0| if (type[0] != '{' && type[0] != '(') 128| 0| return NO; 129| | 130| 0| *typeNameEnd = NULL; 131| 0| *typeEqualSign = NULL; 132| | 133| 0| const char endChar = type[0] == '{' ? '}' : ')'; 134| 0| for (const char* ptr = type + 1; *ptr; ++ptr) { 135| 0| switch (*ptr) { 136| 0| case '(': 137| 0| case '{': 138| 0| { 139| 0| const char *subTypeEnd; 140| 0| const char *subTypeNameEnd; 141| 0| const char *subTypeEqualSign; 142| 0| if (!ParseStructType(ptr, &subTypeEnd, &subTypeNameEnd, &subTypeEqualSign)) 143| 0| return NO; 144| 0| ptr = subTypeEnd; 145| 0| break; 146| 0| } 147| 0| case '=': 148| 0| { 149| 0| if (!*typeEqualSign) { 150| 0| *typeNameEnd = ptr; 151| 0| *typeEqualSign = ptr; 152| 0| } 153| 0| break; 154| 0| } 155| 0| case ')': 156| 0| case '}': 157| 0| { 158| 0| if (*ptr == endChar) { 159| 0| *typeEnd = ptr; 160| 0| if (!*typeNameEnd) 161| 0| *typeNameEnd = ptr; 162| 0| return YES; 163| 0| } 164| 0| break; 165| 0| } 166| 0| default: 167| 0| break; 168| 0| } 169| 0| } 170| | 171| 0| return NO; 172| 0|} 173| | 174| | 175| |/* 176| | * Sometimes an external type is an opaque struct (which will have an @encode of "{structName}" 177| | * or "{structName=}") but the actual method return type, or property type, will know the contents 178| | * of the struct (so will have an objcType of say "{structName=iiSS}". This function will determine 179| | * those are equal provided they have the same structure name, otherwise everything else will be 180| | * compared textually. This can happen particularly for pointers to such structures, which still 181| | * encode what is being pointed to. 182| | * 183| | * In addition, this funtion will consider structures with unknown names, encoded as "{?=}, equal to 184| | * structures with any name. This means that "{?=dd}" and "{foo=dd}", and even "{?=}" and "{foo=dd}", 185| | * are considered equal. 186| | * 187| | * For some types some runtime functions throw exceptions, which is why we wrap this in an 188| | * exception handler just below. 189| | */ 190| |static BOOL OCMEqualTypesAllowingOpaqueStructsInternal(const char *type1, const char *type2) 191| 0|{ 192| 0| type1 = OCMTypeWithoutQualifiers(type1); 193| 0| type2 = OCMTypeWithoutQualifiers(type2); 194| | 195| 0| switch (type1[0]) 196| 0| { 197| 0| case '{': 198| 0| case '(': 199| 0| { 200| 0| if (type2[0] != type1[0]) 201| 0| return NO; 202| | 203| 0| const char *type1End; 204| 0| const char *type1NameEnd; 205| 0| const char *type1EqualSign; 206| 0| if (!ParseStructType(type1, &type1End, &type1NameEnd, &type1EqualSign)) 207| 0| return NO; 208| | 209| 0| const char *type2End; 210| 0| const char *type2NameEnd; 211| 0| const char *type2EqualSign; 212| 0| if (!ParseStructType(type2, &type2End, &type2NameEnd, &type2EqualSign)) 213| 0| return NO; 214| | 215| | /* Opaque types either don't have an equals sign (just the name and the end brace), or 216| | * empty content after the equals sign. 217| | * We want that to compare the same as a type of the same name but with the content. 218| | */ 219| 0| BOOL type1Opaque = (type1EqualSign == NULL || type1EqualSign + 1 == type1End); 220| 0| BOOL type2Opaque = (type2EqualSign == NULL || type2EqualSign + 2 == type2End); 221| 0| intptr_t type1NameLen = type1NameEnd - type1; 222| 0| intptr_t type2NameLen = type2NameEnd - type2; 223| | 224| | /* If the names are not equal and neither of the names is a question mark, return NO */ 225| 0| if ((type1NameLen != type2NameLen || strncmp(type1, type2, type1NameLen)) && 226| 0| !((type1NameLen == 2) && (type1[1] == '?')) && !((type2NameLen == 2) && (type2[1] == '?')) && 227| 0| !(type1NameLen == 1 || type2NameLen == 1)) 228| 0| return NO; 229| | 230| | /* If the same name, and at least one is opaque, that is close enough. */ 231| 0| if (type1Opaque || type2Opaque) 232| 0| return YES; 233| | 234| | /* Otherwise, compare all the elements. Use NSGetSizeAndAlignment to walk through the struct elements. */ 235| 0| type1 = type1EqualSign + 1; 236| 0| type2 = type2EqualSign + 1; 237| 0| while (type1 != type1End && *type1) 238| 0| { 239| 0| if (!OCMEqualTypesAllowingOpaqueStructs(type1, type2)) 240| 0| return NO; 241| | 242| 0| if (*type1 != '{' && *type1 != '(') { 243| 0| type1 = NSGetSizeAndAlignment(type1, NULL, NULL); 244| 0| type2 = NSGetSizeAndAlignment(type2, NULL, NULL); 245| 0| } else { 246| 0| const char *subType1End; 247| 0| const char *subType1NameEnd; 248| 0| const char *subType1EqualSign; 249| 0| if (!ParseStructType(type1, &subType1End, &subType1NameEnd, &subType1EqualSign)) 250| 0| return NO; 251| | 252| 0| const char *subType2End; 253| 0| const char *subType2NameEnd; 254| 0| const char *subType2EqualSign; 255| 0| if (!ParseStructType(type2, &subType2End, &subType2NameEnd, &subType2EqualSign)) 256| 0| return NO; 257| | 258| 0| type1 = subType1End + 1; 259| 0| type2 = subType2End + 1; 260| 0| } 261| 0| } 262| 0| return YES; 263| 0| } 264| 0| case '^': 265| | /* for a pointer, make sure the other is a pointer, then recursively compare the rest */ 266| 0| if (type2[0] != type1[0]) 267| 0| return NO; 268| 0| return OCMEqualTypesAllowingOpaqueStructs(type1 + 1, type2 + 1); 269| | 270| 0| case '?': 271| 0| return type2[0] == '?'; 272| | 273| 0| case '\0': 274| 0| return type2[0] == '\0'; 275| | 276| 0| default: 277| 0| { 278| | // Move the type pointers past the current types, then compare that region 279| 0| const char *afterType1 = NSGetSizeAndAlignment(type1, NULL, NULL); 280| 0| const char *afterType2 = NSGetSizeAndAlignment(type2, NULL, NULL); 281| 0| intptr_t type1Len = afterType1 - type1; 282| 0| intptr_t type2Len = afterType2 - type2; 283| | 284| 0| return (type1Len == type2Len && (strncmp(type1, type2, type1Len) == 0)); 285| 0| } 286| 0| } 287| 0|} 288| | 289| |BOOL OCMEqualTypesAllowingOpaqueStructs(const char *type1, const char *type2) 290| 0|{ 291| 0| @try 292| 0| { 293| 0| return OCMEqualTypesAllowingOpaqueStructsInternal(type1, type2); 294| 0| } 295| 0| @catch (NSException *e) 296| 0| { 297| | /* Probably a bitfield or something that NSGetSizeAndAlignment chokes on, oh well */ 298| 0| return NO; 299| 0| } 300| 0|} 301| | 302| |BOOL OCMIsNilValue(const char *objectCType, const void *value, size_t valueSize) 303| 0|{ 304| | // First, check value itself 305| 0| for(size_t i = 0; i < valueSize; i++) 306| 0| if(((const char *)value)[i] != 0) 307| 0| return NO; 308| | 309| | // Depending on the compilation settings of the file where the return value gets recorded, 310| | // nil and Nil get potentially different encodings. Check all known encodings. 311| 0| if((strcmp(objectCType, @encode(void *)) == 0) || // Standard Objective-C 312| 0| (strcmp(objectCType, @encode(int)) == 0) || // 32 bit C++ (before nullptr) 313| 0| (strcmp(objectCType, @encode(long long)) == 0) || // 64 bit C++ (before nullptr) 314| 0| (strcmp(objectCType, @encode(char *)) == 0)) // C++ with nullptr 315| 0| return YES; 316| | 317| 0| return NO; 318| 0|} 319| | 320| | 321| |BOOL OCMIsAppleBaseClass(Class cls) 322| 0|{ 323| 0| return (cls == [NSObject class]) || (cls == [NSProxy class]); 324| 0|} 325| | 326| |BOOL OCMIsApplePrivateMethod(Class cls, SEL sel) 327| 0|{ 328| 0| NSString *className = NSStringFromClass(cls); 329| 0| NSString *selName = NSStringFromSelector(sel); 330| 0| return ([className hasPrefix:@"NS"] || [className hasPrefix:@"UI"]) && 331| 0| ([selName hasPrefix:@"_"] || [selName hasSuffix:@"_"]); 332| 0|} 333| | 334| |BOOL OCMIsBlock(id potentialBlock) 335| 0|{ 336| 0| static Class blockClass; 337| 0| static dispatch_once_t onceToken; 338| 0| dispatch_once(&onceToken, ^ 339| 0| { 340| 0| blockClass = [^{} class]; 341| 0| Class nsObjectClass = [NSObject class]; 342| 0| while([blockClass superclass] != nsObjectClass) 343| 0| { 344| 0| blockClass = [blockClass superclass]; 345| 0| NSCAssert(blockClass != nil, @"Blocks are expected to inherit from NSObject."); 346| 0| } 347| 0| }); 348| 0| return [potentialBlock isKindOfClass:blockClass]; 349| 0|} 350| | 351| |BOOL OCMIsNonEscapingBlock(id block) 352| 0|{ 353| 0| struct OCMBlockDef *blockRef = (__bridge struct OCMBlockDef *)block; 354| 0| return OCMIsBlock(block) && (blockRef->flags & OCMBlockIsNoEscape) != 0; 355| 0|} 356| | 357| | 358| |#pragma mark Creating and disposing classes 359| | 360| |static NSString *const OCMSubclassPrefix = @"OCMock_"; 361| | 362| |Class OCMCreateSubclass(Class class, void *ref) 363| 0|{ 364| 0| const char *className = [[NSString stringWithFormat:@"%@%@-%p-%u", OCMSubclassPrefix, NSStringFromClass(class), ref, arc4random()] UTF8String]; 365| 0| Class subclass = objc_allocateClassPair(class, className, 0); 366| 0| objc_registerClassPair(subclass); 367| 0| return subclass; 368| 0|} 369| | 370| |void OCMDisposeSubclass(Class cls) 371| 0|{ 372| 0| if(!OCMIsMockSubclass(cls)) 373| 0| { 374| 0| [NSException raise:NSInvalidArgumentException format:@"Not a mock subclass; found %@\nThe subclass dynamically created by OCMock has been replaced by another class. This can happen when KVO or CoreData create their own dynamic subclass after OCMock created its subclass.\nYou will need to reorder initialization and/or teardown so that classes are created and disposed of in the right order.", NSStringFromClass(cls)]; 375| 0| } 376| 0| objc_disposeClassPair(cls); 377| 0|} 378| | 379| |BOOL OCMIsMockSubclass(Class cls) 380| 0|{ 381| 0| return [NSStringFromClass(cls) hasPrefix:OCMSubclassPrefix]; 382| 0|} 383| | 384| |BOOL OCMIsSubclassOfMockClass(Class cls) 385| 0|{ 386| 0| for(; cls != nil; cls = class_getSuperclass(cls)) 387| 0| { 388| 0| if(OCMIsMockSubclass(cls)) 389| 0| return YES; 390| 0| } 391| 0| return NO; 392| 0|} 393| | 394| | 395| |#pragma mark Alias for renaming real methods 396| | 397| |static NSString *const OCMRealMethodAliasPrefix = @"ocmock_replaced_"; 398| |static const char *const OCMRealMethodAliasPrefixCString = "ocmock_replaced_"; 399| | 400| |BOOL OCMIsAliasSelector(SEL selector) 401| 0|{ 402| 0| return [NSStringFromSelector(selector) hasPrefix:OCMRealMethodAliasPrefix]; 403| 0|} 404| | 405| |SEL OCMAliasForOriginalSelector(SEL selector) 406| 0|{ 407| 0| char aliasName[2048]; 408| 0| const char *originalName = sel_getName(selector); 409| 0| strlcpy(aliasName, OCMRealMethodAliasPrefixCString, sizeof(aliasName)); 410| 0| strlcat(aliasName, originalName, sizeof(aliasName)); 411| 0| return sel_registerName(aliasName); 412| 0|} 413| | 414| |SEL OCMOriginalSelectorForAlias(SEL selector) 415| 0|{ 416| 0| if(!OCMIsAliasSelector(selector)) 417| 0| [NSException raise:NSInvalidArgumentException format:@"Not an alias selector; found %@", NSStringFromSelector(selector)]; 418| 0| NSString *string = NSStringFromSelector(selector); 419| 0| return NSSelectorFromString([string substringFromIndex:[OCMRealMethodAliasPrefix length]]); 420| 0|} 421| | 422| | 423| |#pragma mark Wrappers around associative references 424| | 425| |static NSString *const OCMClassMethodMockObjectKey = @"OCMClassMethodMockObjectKey"; 426| | 427| |void OCMSetAssociatedMockForClass(OCClassMockObject *mock, Class aClass) 428| 0|{ 429| 0| if((mock != nil) && (objc_getAssociatedObject(aClass, OCMClassMethodMockObjectKey) != nil)) 430| 0| [NSException raise:NSInternalInconsistencyException format:@"Another mock is already associated with class %@", NSStringFromClass(aClass)]; 431| 0| objc_setAssociatedObject(aClass, OCMClassMethodMockObjectKey, mock, OBJC_ASSOCIATION_ASSIGN); 432| 0|} 433| | 434| |OCClassMockObject *OCMGetAssociatedMockForClass(Class aClass, BOOL includeSuperclasses) 435| 0|{ 436| 0| OCClassMockObject *mock = nil; 437| 0| do 438| 0| { 439| 0| mock = objc_getAssociatedObject(aClass, OCMClassMethodMockObjectKey); 440| 0| aClass = class_getSuperclass(aClass); 441| 0| } 442| 0| while((mock == nil) && (aClass != nil) && includeSuperclasses); 443| 0| return mock; 444| 0|} 445| | 446| |static NSString *const OCMPartialMockObjectKey = @"OCMPartialMockObjectKey"; 447| | 448| |void OCMSetAssociatedMockForObject(OCClassMockObject *mock, id anObject) 449| 0|{ 450| 0| if((mock != nil) && (objc_getAssociatedObject(anObject, OCMPartialMockObjectKey) != nil)) 451| 0| [NSException raise:NSInternalInconsistencyException format:@"Another mock is already associated with object %@", anObject]; 452| 0| objc_setAssociatedObject(anObject, OCMPartialMockObjectKey, mock, OBJC_ASSOCIATION_ASSIGN); 453| 0|} 454| | 455| |OCPartialMockObject *OCMGetAssociatedMockForObject(id anObject) 456| 0|{ 457| 0| return objc_getAssociatedObject(anObject, OCMPartialMockObjectKey); 458| 0|} 459| | 460| | 461| |#pragma mark Functions related to IDE error reporting 462| | 463| |void OCMReportFailure(OCMLocation *loc, NSString *description) 464| 0|{ 465| 0| id testCase = [loc testCase]; 466| 0|#ifdef __IPHONE_14_0 // this is actually a test for Xcode 12; see issue #472 467| 0|#if !TARGET_OS_WATCH 468| 0| if((testCase != nil) && [testCase respondsToSelector:@selector(recordIssue:)]) 469| 0| { 470| 0| XCTSourceCodeLocation *xctloc = [[[XCTSourceCodeLocation alloc] initWithFilePath:[loc file] lineNumber:[loc line]] autorelease]; 471| 0| XCTSourceCodeContext *xctctx = [[[XCTSourceCodeContext alloc] initWithLocation:xctloc] autorelease]; 472| 0| XCTIssue *issue = [[[XCTIssue alloc] initWithType:XCTIssueTypeAssertionFailure compactDescription:description 473| 0| detailedDescription:nil sourceCodeContext:xctctx associatedError:nil attachments:[NSArray array]] autorelease]; 474| 0| [testCase recordIssue:issue]; 475| 0| } 476| 0| else 477| 0|#endif 478| 0|#endif 479| 0| if((testCase != nil) && [testCase respondsToSelector:@selector(recordFailureWithDescription:inFile:atLine:expected:)]) 480| 0| { 481| 0| [testCase recordFailureWithDescription:description inFile:[loc file] atLine:[loc line] expected:NO]; 482| 0| } 483| 0| else if((testCase != nil) && [testCase respondsToSelector:@selector(failWithException:)]) 484| 0| { 485| 0| NSException *exception = nil; 486| 0| if([NSException instancesRespondToSelector:@selector(failureInFile:atLine:withDescription:)]) 487| 0| { 488| 0| exception = [NSException failureInFile:[loc file] atLine:(int)[loc line] withDescription:description]; 489| 0| } 490| 0| else 491| 0| { 492| 0| NSString *reason = [NSString stringWithFormat:@"%@:%lu %@", [loc file], (unsigned long)[loc line], description]; 493| 0| exception = [NSException exceptionWithName:@"OCMockTestFailure" reason:reason userInfo:nil]; 494| 0| } 495| 0| [testCase failWithException:exception]; 496| 0| } 497| 0| else if(loc != nil) 498| 0| { 499| 0| NSLog(@"%@:%lu %@", [loc file], (unsigned long)[loc line], description); 500| 0| NSString *reason = [NSString stringWithFormat:@"%@:%lu %@", [loc file], (unsigned long)[loc line], description]; 501| 0| [[NSException exceptionWithName:@"OCMockTestFailure" reason:reason userInfo:nil] raise]; 502| | 503| 0| } 504| 0| else 505| 0| { 506| 0| NSLog(@"%@", description); 507| 0| [[NSException exceptionWithName:@"OCMockTestFailure" reason:description userInfo:nil] raise]; 508| 0| } 509| | 510| 0|} /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/OCMIndirectReturnValueProvider.m: 1| |/* 2| | * Copyright (c) 2009-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import "OCMIndirectReturnValueProvider.h" 18| | 19| | 20| |@implementation OCMIndirectReturnValueProvider 21| | 22| |- (id)initWithProvider:(id)aProvider andSelector:(SEL)aSelector 23| 0|{ 24| 0| if ((self = [super init])) 25| 0| { 26| 0| provider = [aProvider retain]; 27| 0| selector = aSelector; 28| 0| } 29| | 30| 0| return self; 31| 0|} 32| | 33| |- (void)dealloc 34| 0|{ 35| 0| [provider release]; 36| 0| [super dealloc]; 37| 0|} 38| | 39| |- (void)handleInvocation:(NSInvocation *)anInvocation 40| 0|{ 41| 0| id originalTarget = [anInvocation target]; 42| 0| SEL originalSelector = [anInvocation selector]; 43| | 44| 0| [anInvocation setTarget:provider]; 45| 0| [anInvocation setSelector:selector]; 46| 0| [anInvocation invoke]; 47| | 48| 0| [anInvocation setTarget:originalTarget]; 49| 0| [anInvocation setSelector:originalSelector]; 50| 0|} 51| | 52| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/OCMInvocationExpectation.m: 1| |/* 2| | * Copyright (c) 2014-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import "OCMInvocationExpectation.h" 18| |#import "NSInvocation+OCMAdditions.h" 19| | 20| | 21| |@implementation OCMInvocationExpectation 22| | 23| |- (void)setMatchAndReject:(BOOL)flag 24| 0|{ 25| 0| matchAndReject = flag; 26| 0| if(matchAndReject) 27| 0| isSatisfied = YES; 28| 0|} 29| | 30| |- (BOOL)isMatchAndReject 31| 0|{ 32| 0| return matchAndReject; 33| 0|} 34| | 35| |- (BOOL)isSatisfied 36| 0|{ 37| 0| return isSatisfied; 38| 0|} 39| | 40| |- (void)addInvocationAction:(id)anAction 41| 0|{ 42| 0| if(matchAndReject) 43| 0| { 44| 0| [NSException raise:NSInternalInconsistencyException format:@"%@: cannot add action to a reject stub; got %@", 45| 0| [self description], anAction]; 46| 0| } 47| 0| [super addInvocationAction:anAction]; 48| 0|} 49| | 50| |- (void)handleInvocation:(NSInvocation *)anInvocation 51| 0|{ 52| 0| if(matchAndReject) 53| 0| { 54| 0| isSatisfied = NO; 55| 0| [NSException raise:NSInternalInconsistencyException format:@"%@: explicitly disallowed method invoked: %@", 56| 0| [self description], [anInvocation invocationDescription]]; 57| 0| } 58| 0| else 59| 0| { 60| 0| [super handleInvocation:anInvocation]; 61| 0| isSatisfied = YES; 62| 0| } 63| 0|} 64| | 65| | 66| | 67| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/OCMInvocationMatcher.m: 1| |/* 2| | * Copyright (c) 2014-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import 18| |#import "OCMInvocationMatcher.h" 19| |#import "OCMArg.h" 20| |#import "OCMConstraint.h" 21| |#import "OCMPassByRefSetter.h" 22| |#import "OCMFunctionsPrivate.h" 23| |#import "NSInvocation+OCMAdditions.h" 24| | 25| | 26| |@interface NSObject(HCMatcherDummy) 27| |- (BOOL)matches:(id)item; 28| |@end 29| | 30| | 31| |@implementation OCMInvocationMatcher 32| | 33| |- (void)dealloc 34| 0|{ 35| 0| [recordedInvocation release]; 36| 0| [super dealloc]; 37| 0|} 38| | 39| |- (void)setInvocation:(NSInvocation *)anInvocation 40| 0|{ 41| 0| [recordedInvocation release]; 42| | // Don't do a regular -retainArguments on the invocation that we use for matching. NSInvocation 43| | // effectively does an strcpy on char* arguments which messes up matching them literally and blows 44| | // up with anyPointer (in strlen since it's not actually a C string). Also on the off-chance that 45| | // anInvocation contains self as an argument, -retainArguments would create a retain cycle. 46| 0| [anInvocation retainObjectArgumentsExcludingObject:self]; 47| 0| recordedInvocation = [anInvocation retain]; 48| 0|} 49| | 50| |- (void)setRecordedAsClassMethod:(BOOL)flag 51| 0|{ 52| 0| recordedAsClassMethod = flag; 53| 0|} 54| | 55| |- (BOOL)recordedAsClassMethod 56| 0|{ 57| 0| return recordedAsClassMethod; 58| 0|} 59| | 60| |- (void)setIgnoreNonObjectArgs:(BOOL)flag 61| 0|{ 62| 0| ignoreNonObjectArgs = flag; 63| 0|} 64| | 65| |- (NSString *)description 66| 0|{ 67| 0| return [recordedInvocation invocationDescription]; 68| 0|} 69| | 70| |- (NSInvocation *)recordedInvocation 71| 0|{ 72| 0| return recordedInvocation; 73| 0|} 74| | 75| |- (BOOL)matchesSelector:(SEL)sel 76| 0|{ 77| 0| if(sel == [recordedInvocation selector]) 78| 0| return YES; 79| 0| if(OCMIsAliasSelector(sel) && 80| 0| OCMOriginalSelectorForAlias(sel) == [recordedInvocation selector]) 81| 0| return YES; 82| | 83| 0| return NO; 84| 0|} 85| | 86| |- (BOOL)matchesInvocation:(NSInvocation *)anInvocation 87| 0|{ 88| 0| id target = [anInvocation target]; 89| 0| BOOL isClassMethodInvocation = (target != nil) && (target == [target class]); 90| 0| if(isClassMethodInvocation != recordedAsClassMethod) 91| 0| return NO; 92| | 93| 0| if(![self matchesSelector:[anInvocation selector]]) 94| 0| return NO; 95| | 96| 0| NSMethodSignature *signature = [recordedInvocation methodSignature]; 97| 0| NSUInteger n = [signature numberOfArguments]; 98| 0| for(NSUInteger i = 2; i < n; i++) 99| 0| { 100| 0| if(ignoreNonObjectArgs && !OCMIsObjectType([signature getArgumentTypeAtIndex:i])) 101| 0| { 102| 0| continue; 103| 0| } 104| | 105| 0| id recordedArg = [recordedInvocation getArgumentAtIndexAsObject:i]; 106| 0| id passedArg = [anInvocation getArgumentAtIndexAsObject:i]; 107| | 108| 0| if([recordedArg isProxy]) 109| 0| { 110| 0| if(![recordedArg isEqual:passedArg]) 111| 0| return NO; 112| 0| continue; 113| 0| } 114| | 115| 0| if([recordedArg isKindOfClass:[NSValue class]]) 116| 0| recordedArg = [OCMArg resolveSpecialValues:recordedArg]; 117| | 118| 0| if([recordedArg isKindOfClass:[OCMConstraint class]]) 119| 0| { 120| 0| if([recordedArg evaluate:passedArg] == NO) 121| 0| return NO; 122| 0| } 123| 0| else if([recordedArg isKindOfClass:[OCMArgAction class]]) 124| 0| { 125| | // ignore, will be dealt with in handleInvocation: where applicable 126| 0| } 127| 0| else if([recordedArg conformsToProtocol:objc_getProtocol("HCMatcher")]) 128| 0| { 129| 0| if([recordedArg matches:passedArg] == NO) 130| 0| return NO; 131| 0| } 132| 0| else 133| 0| { 134| 0| if(([recordedArg class] == [NSNumber class]) && 135| 0| ([(NSNumber*)recordedArg compare:(NSNumber*)passedArg] != NSOrderedSame)) 136| 0| return NO; 137| 0| if(([recordedArg isEqual:passedArg] == NO) && 138| 0| !((recordedArg == nil) && (passedArg == nil))) 139| 0| return NO; 140| 0| } 141| 0| } 142| 0| return YES; 143| 0|} 144| | 145| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/OCMInvocationStub.m: 1| |/* 2| | * Copyright (c) 2014-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import "OCMInvocationStub.h" 18| |#import "OCMArg.h" 19| |#import "OCMArgAction.h" 20| |#import "NSInvocation+OCMAdditions.h" 21| | 22| 0|#define UNSET_RETURN_VALUE_MARKER ((id)0x01234567) 23| | 24| | 25| |@implementation OCMInvocationStub 26| | 27| |- (id)init 28| 0|{ 29| 0| self = [super init]; 30| 0| invocationActions = [[NSMutableArray alloc] init]; 31| 0| return self; 32| 0|} 33| | 34| |- (void)dealloc 35| 0|{ 36| 0| [invocationActions release]; 37| 0| [super dealloc]; 38| 0|} 39| | 40| | 41| |- (void)addInvocationAction:(id)anAction 42| 0|{ 43| 0| [invocationActions addObject:anAction]; 44| 0|} 45| | 46| |- (NSArray *)invocationActions 47| 0|{ 48| 0| return invocationActions; 49| 0|} 50| | 51| | 52| |- (void)handleInvocation:(NSInvocation *)anInvocation 53| 0|{ 54| 0| [self invokeArgActionsForInvocation:anInvocation]; 55| 0| id target = [anInvocation target]; 56| | 57| 0| BOOL isInInitFamily = [anInvocation methodIsInInitFamily]; 58| 0| BOOL isInCreateFamily = isInInitFamily ? NO : [anInvocation methodIsInCreateFamily]; 59| 0| if(isInInitFamily || isInCreateFamily) 60| 0| { 61| 0| id returnVal = UNSET_RETURN_VALUE_MARKER; 62| 0| [anInvocation setReturnValue:&returnVal]; 63| | 64| 0| [self invokeActionsForInvocation:anInvocation]; 65| | 66| 0| [anInvocation getReturnValue:&returnVal]; 67| 0| if(returnVal == UNSET_RETURN_VALUE_MARKER) 68| 0| [NSException raise:NSInvalidArgumentException format:@"%@ was stubbed but no return value set. A return value is required for all alloc/copy/new/mutablecopy/init methods. If you intended to return nil, make this explicit with .andReturn(nil)", NSStringFromSelector([anInvocation selector])]; 69| | 70| 0| if(isInCreateFamily) 71| 0| { 72| | // methods that "create" an object return it with an extra retain count 73| 0| [returnVal retain]; 74| 0| } 75| 0| if(isInInitFamily) 76| 0| { 77| | // init family methods "consume" self and retain their return value. Do the retain 78| | // first in case the return value and self are the same. 79| 0| [returnVal retain]; 80| 0| [target release]; 81| 0| } 82| 0| } 83| 0| else 84| 0| { 85| 0| [self invokeActionsForInvocation:anInvocation]; 86| 0| } 87| 0|} 88| | 89| |- (void)invokeArgActionsForInvocation:(NSInvocation *)anInvocation 90| 0|{ 91| 0| NSMethodSignature *signature = [recordedInvocation methodSignature]; 92| 0| NSUInteger n = [signature numberOfArguments]; 93| 0| for(NSUInteger i = 2; i < n; i++) 94| 0| { 95| 0| id recordedArg = [recordedInvocation getArgumentAtIndexAsObject:i]; 96| 0| id passedArg = [anInvocation getArgumentAtIndexAsObject:i]; 97| | 98| 0| if([recordedArg isProxy]) 99| 0| continue; 100| | 101| 0| if([recordedArg isKindOfClass:[NSValue class]]) 102| 0| recordedArg = [OCMArg resolveSpecialValues:recordedArg]; 103| | 104| 0| if([recordedArg isKindOfClass:[OCMArgAction class]]) 105| 0| [recordedArg handleArgument:passedArg]; 106| 0| } 107| 0|} 108| | 109| |- (void)invokeActionsForInvocation:(NSInvocation *)anInvocation 110| 0|{ 111| 0| [invocationActions makeObjectsPerformSelector:@selector(handleInvocation:) withObject:anInvocation]; 112| 0|} 113| | 114| | 115| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/OCMLocation.m: 1| |/* 2| | * Copyright (c) 2014-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import "OCMLocation.h" 18| | 19| | 20| |@implementation OCMLocation 21| | 22| |+ (instancetype)locationWithTestCase:(id)aTestCase file:(NSString *)aFile line:(NSUInteger)aLine 23| 0|{ 24| 0| return [[[OCMLocation alloc] initWithTestCase:aTestCase file:aFile line:aLine] autorelease]; 25| 0|} 26| | 27| |- (instancetype)initWithTestCase:(id)aTestCase file:(NSString *)aFile line:(NSUInteger)aLine 28| 0|{ 29| 0| if ((self = [super init])) 30| 0| { 31| 0| testCase = aTestCase; 32| 0| file = [aFile retain]; 33| 0| line = aLine; 34| 0| } 35| | 36| 0| return self; 37| 0|} 38| | 39| |- (void)dealloc 40| 0|{ 41| 0| [file release]; 42| 0| [super dealloc]; 43| 0|} 44| | 45| |- (id)testCase 46| 0|{ 47| 0| return testCase; 48| 0|} 49| | 50| |- (NSString *)file 51| 0|{ 52| 0| return file; 53| 0|} 54| | 55| |- (NSUInteger)line 56| 0|{ 57| 0| return line; 58| 0|} 59| | 60| |@end 61| | 62| | 63| |OCMLocation *OCMMakeLocation(id testCase, const char *fileCString, int line) 64| 0|{ 65| 0| return [OCMLocation locationWithTestCase:testCase file:[NSString stringWithUTF8String:fileCString] line:line]; 66| 0|} 67| | /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/OCMMacroState.m: 1| |/* 2| | * Copyright (c) 2014-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import "OCMMacroState.h" 18| |#import "OCMExpectationRecorder.h" 19| |#import "OCMVerifier.h" 20| | 21| | 22| |@implementation OCMMacroState 23| | 24| |static NSString *const OCMGlobalStateKey = @"OCMGlobalStateKey"; 25| | 26| |#pragma mark Methods to begin/end macros 27| | 28| |+ (void)beginStubMacro 29| 0|{ 30| 0| OCMStubRecorder *recorder = [[[OCMStubRecorder alloc] init] autorelease]; 31| 0| OCMMacroState *macroState = [[OCMMacroState alloc] initWithRecorder:recorder]; 32| 0| [NSThread currentThread].threadDictionary[OCMGlobalStateKey] = macroState; 33| 0| [macroState release]; 34| 0|} 35| | 36| |+ (OCMStubRecorder *)endStubMacro 37| 0|{ 38| 0| NSMutableDictionary *threadDictionary = [NSThread currentThread].threadDictionary; 39| 0| OCMMacroState *globalState = threadDictionary[OCMGlobalStateKey]; 40| 0| OCMStubRecorder *recorder = [[(OCMStubRecorder *)[globalState recorder] retain] autorelease]; 41| 0| BOOL didThrow = [globalState invocationDidThrow]; 42| 0| [threadDictionary removeObjectForKey:OCMGlobalStateKey]; 43| 0| if(didThrow == NO && [recorder didRecordInvocation] == NO) 44| 0| { 45| 0| [NSException raise:NSInternalInconsistencyException 46| 0| format:@"Did not record an invocation in OCMStub/OCMExpect/OCMReject.\n" 47| 0| @"Possible causes are:\n" 48| 0| @"- The receiver is not a mock object.\n" 49| 0| @"- The selector conflicts with a selector implemented by OCMStubRecorder/OCMExpectationRecorder."]; 50| 0| } 51| 0| return recorder; 52| 0|} 53| | 54| | 55| |+ (void)beginExpectMacro 56| 0|{ 57| 0| OCMExpectationRecorder *recorder = [[[OCMExpectationRecorder alloc] init] autorelease]; 58| 0| OCMMacroState *macroState = [[OCMMacroState alloc] initWithRecorder:recorder]; 59| 0| [NSThread currentThread].threadDictionary[OCMGlobalStateKey] = macroState; 60| 0| [macroState release]; 61| 0|} 62| | 63| |+ (OCMStubRecorder *)endExpectMacro 64| 0|{ 65| 0| return [self endStubMacro]; 66| 0|} 67| | 68| | 69| |+ (void)beginRejectMacro 70| 0|{ 71| 0| OCMExpectationRecorder *recorder = [[[OCMExpectationRecorder alloc] init] autorelease]; 72| 0| OCMMacroState *macroState = [[OCMMacroState alloc] initWithRecorder:recorder]; 73| 0| [NSThread currentThread].threadDictionary[OCMGlobalStateKey] = macroState; 74| 0| [macroState release]; 75| 0|} 76| | 77| |+ (OCMStubRecorder *)endRejectMacro 78| 0|{ 79| 0| OCMMacroState *globalState = [NSThread currentThread].threadDictionary[OCMGlobalStateKey]; 80| | // Calling never after the invocation to avoid running afoul of ARC's expectations on 81| | // return values from init methods. 82| 0| [(OCMExpectationRecorder *)[globalState recorder] never]; 83| 0| return [self endStubMacro]; 84| 0|} 85| | 86| | 87| |+ (void)beginVerifyMacroAtLocation:(OCMLocation *)aLocation 88| 0|{ 89| 0| return [self beginVerifyMacroAtLocation:aLocation withQuantifier:nil]; 90| 0|} 91| | 92| |+ (void)beginVerifyMacroAtLocation:(OCMLocation *)aLocation withQuantifier:(OCMQuantifier *)quantifier 93| 0|{ 94| 0| OCMVerifier *recorder = [[[OCMVerifier alloc] init] autorelease]; 95| 0| [recorder setLocation:aLocation]; 96| 0| [recorder setQuantifier:quantifier]; 97| 0| OCMMacroState *macroState = [[OCMMacroState alloc] initWithRecorder:recorder]; 98| 0| [NSThread currentThread].threadDictionary[OCMGlobalStateKey] = macroState; 99| 0| [macroState release]; 100| 0|} 101| | 102| |+ (void)endVerifyMacro 103| 0|{ 104| 0| NSMutableDictionary *threadDictionary = [NSThread currentThread].threadDictionary; 105| 0| OCMMacroState *globalState = threadDictionary[OCMGlobalStateKey]; 106| 0| OCMVerifier *verifier = [[(OCMVerifier *)[globalState recorder] retain] autorelease]; 107| 0| BOOL didThrow = [globalState invocationDidThrow]; 108| 0| [threadDictionary removeObjectForKey:OCMGlobalStateKey]; 109| 0| if(didThrow == NO && [verifier didRecordInvocation] == NO) 110| 0| { 111| 0| [NSException raise:NSInternalInconsistencyException 112| 0| format:@"Did not record an invocation in OCMVerify.\n" 113| 0| @"Possible causes are:\n" 114| 0| @"- The receiver is not a mock object.\n" 115| 0| @"- The selector conflicts with a selector implemented by OCMVerifier."]; 116| 0| } 117| 0|} 118| | 119| | 120| |#pragma mark Accessing global state 121| | 122| |+ (OCMMacroState *)globalState 123| 0|{ 124| 0| return [NSThread currentThread].threadDictionary[OCMGlobalStateKey]; 125| 0|} 126| | 127| | 128| |#pragma mark Init, dealloc, accessors 129| | 130| |- (id)initWithRecorder:(OCMRecorder *)aRecorder 131| 0|{ 132| 0| if((self = [super init])) 133| 0| { 134| 0| recorder = [aRecorder retain]; 135| 0| } 136| | 137| 0| return self; 138| 0|} 139| | 140| |- (void)dealloc 141| 0|{ 142| 0| [recorder release]; 143| 0| if([NSThread currentThread].threadDictionary[OCMGlobalStateKey] == self) 144| 0| [NSException raise:NSInternalInconsistencyException format:@"Unexpected dealloc while set as the global state"]; 145| 0| [super dealloc]; 146| 0|} 147| | 148| |- (void)setRecorder:(OCMRecorder *)aRecorder 149| 0|{ 150| 0| [recorder autorelease]; 151| 0| recorder = [aRecorder retain]; 152| 0|} 153| | 154| |- (OCMRecorder *)recorder 155| 0|{ 156| 0| return recorder; 157| 0|} 158| | 159| |- (void)setInvocationDidThrow:(BOOL)flag 160| 0|{ 161| 0| invocationDidThrow = flag; 162| 0|} 163| | 164| |- (BOOL)invocationDidThrow 165| 0|{ 166| 0| return invocationDidThrow; 167| 0|} 168| | 169| | 170| |#pragma mark Changing the recorder 171| | 172| |- (void)switchToClassMethod 173| 0|{ 174| 0| [recorder classMethod]; 175| 0|} 176| | 177| | 178| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/OCMNonRetainingObjectReturnValueProvider.m: 1| |/* 2| | * Copyright (c) 2019-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import "OCMNonRetainingObjectReturnValueProvider.h" 18| |#import "OCMFunctions.h" 19| |#import "NSInvocation+OCMAdditions.h" 20| | 21| | 22| |@implementation OCMNonRetainingObjectReturnValueProvider 23| | 24| |- (instancetype)initWithValue:(id)aValue 25| 0|{ 26| 0| if ((self = [super init])) 27| 0| returnValue = aValue; 28| 0| return self; 29| 0|} 30| | 31| |- (void)handleInvocation:(NSInvocation *)anInvocation 32| 0|{ 33| 0| if(!OCMIsObjectType([[anInvocation methodSignature] methodReturnType])) 34| 0| { 35| 0| @throw [NSException exceptionWithName:NSInvalidArgumentException reason:@"Expected invocation with object return type. Did you mean to use andReturnValue: instead?" userInfo:nil]; 36| 0| } 37| 0| [anInvocation setReturnValue:&returnValue]; 38| 0|} 39| |@end 40| | /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/OCMNotificationPoster.m: 1| |/* 2| | * Copyright (c) 2009-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import "OCMNotificationPoster.h" 18| | 19| | 20| |@implementation OCMNotificationPoster 21| | 22| |- (id)initWithNotification:(id)aNotification 23| 0|{ 24| 0| if ((self = [super init])) 25| 0| { 26| 0| notification = [aNotification retain]; 27| 0| } 28| | 29| 0| return self; 30| 0|} 31| | 32| |- (void)dealloc 33| 0|{ 34| 0| [notification release]; 35| 0| [super dealloc]; 36| 0|} 37| | 38| |- (void)handleInvocation:(NSInvocation *)anInvocation 39| 0|{ 40| 0| [[NSNotificationCenter defaultCenter] postNotification:notification]; 41| 0|} 42| | 43| | 44| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/OCMObjectReturnValueProvider.m: 1| |/* 2| | * Copyright (c) 2009-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import "OCMObjectReturnValueProvider.h" 18| | 19| | 20| |@implementation OCMObjectReturnValueProvider 21| | 22| |- (instancetype)initWithValue:(id)aValue 23| 0|{ 24| 0| if((self = [super initWithValue:aValue])) 25| 0| [returnValue retain]; 26| 0| return self; 27| 0|} 28| | 29| |- (void)dealloc 30| 0|{ 31| 0| [returnValue release]; 32| 0| [super dealloc]; 33| 0|} 34| | 35| | 36| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/OCMObserverRecorder.m: 1| |/* 2| | * Copyright (c) 2009-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import 18| |#import "OCMObserverRecorder.h" 19| |#import "OCMConstraint.h" 20| | 21| | 22| |@interface NSObject(HCMatcherDummy) 23| |- (BOOL)matches:(id)item; 24| |@end 25| | 26| |#pragma mark - 27| | 28| | 29| |@implementation OCMObserverRecorder 30| | 31| |#pragma mark Initialisers, description, accessors, etc. 32| | 33| |- (void)dealloc 34| 0|{ 35| 0| [recordedNotification release]; 36| 0| [super dealloc]; 37| 0|} 38| | 39| |- (BOOL)didRecordInvocation 40| 0|{ 41| 0| return YES; // Needed for macro use, and recorder can only end up in macro state if it was used. 42| 0|} 43| | 44| | 45| |#pragma mark Recording 46| | 47| |- (NSNotification *)notificationWithName:(NSString *)name object:(id)sender 48| 0|{ 49| 0| recordedNotification = [[NSNotification notificationWithName:name object:sender] retain]; 50| 0| return nil; 51| 0|} 52| | 53| |- (NSNotification *)notificationWithName:(NSString *)name object:(id)sender userInfo:(NSDictionary *)userInfo 54| 0|{ 55| 0| recordedNotification = [[NSNotification notificationWithName:name object:sender userInfo:userInfo] retain]; 56| 0| return nil; 57| 0|} 58| | 59| | 60| |#pragma mark Verification 61| | 62| |- (BOOL)matchesNotification:(NSNotification *)aNotification 63| 0|{ 64| 0| return [self argument:[recordedNotification name] matchesArgument:[aNotification name]] && 65| 0| [self argument:[recordedNotification object] matchesArgument:[aNotification object]] && 66| 0| [self argument:[recordedNotification userInfo] matchesArgument:[aNotification userInfo]]; 67| 0|} 68| | 69| |- (BOOL)argument:(id)expectedArg matchesArgument:(id)observedArg 70| 0|{ 71| 0| if([expectedArg isKindOfClass:[OCMConstraint class]]) 72| 0| { 73| 0| return [expectedArg evaluate:observedArg]; 74| 0| } 75| 0| else if([expectedArg conformsToProtocol:objc_getProtocol("HCMatcher")]) 76| 0| { 77| 0| return [expectedArg matches:observedArg]; 78| 0| } 79| 0| else if (expectedArg == observedArg) 80| 0| { 81| 0| return YES; 82| 0| } 83| 0| else if (expectedArg == nil || observedArg == nil) 84| 0| { 85| 0| return NO; 86| 0| } 87| 0| else 88| 0| { 89| 0| return [expectedArg isEqual:observedArg]; 90| 0| } 91| 0|} 92| | 93| | 94| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/OCMPassByRefSetter.m: 1| |/* 2| | * Copyright (c) 2009-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import "OCMPassByRefSetter.h" 18| | 19| | 20| |@implementation OCMPassByRefSetter 21| | 22| |- (id)initWithValue:(id)aValue 23| 0|{ 24| 0| if ((self = [super init])) 25| 0| { 26| 0| value = [aValue retain]; 27| 0| } 28| | 29| 0| return self; 30| 0|} 31| | 32| |- (void)dealloc 33| 0|{ 34| 0| [value release]; 35| 0| [super dealloc]; 36| 0|} 37| | 38| |- (void)handleArgument:(id)arg 39| 0|{ 40| 0| void *pointerValue = [arg pointerValue]; 41| 0| if(pointerValue != NULL) 42| 0| { 43| 0| if([value isKindOfClass:[NSValue class]]) 44| 0| [(NSValue *)value getValue:pointerValue]; 45| 0| else 46| 0| *(id *)pointerValue = value; 47| 0| } 48| 0|} 49| | 50| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/OCMQuantifier.m: 1| |/* 2| | * Copyright (c) 2016-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import "OCMQuantifier.h" 18| |#import "OCMMacroState.h" 19| |#import "OCMVerifier.h" 20| | 21| | 22| |@interface OCMExactCountQuantifier : OCMQuantifier 23| | 24| |@end 25| | 26| |@interface OCMAtLeastQuantifier : OCMQuantifier 27| | 28| |@end 29| | 30| |@interface OCMAtMostQuantifier : OCMQuantifier 31| | 32| |@end 33| | 34| | 35| | 36| |@implementation OCMQuantifier 37| | 38| |+ (instancetype)exactly:(NSUInteger)count 39| 0|{ 40| 0| return [[[OCMExactCountQuantifier alloc] initWithCount:count] autorelease]; 41| 0|} 42| | 43| |+ (instancetype)never 44| 0|{ 45| 0| return [self exactly:0]; 46| 0|} 47| | 48| |+ (instancetype)atLeast:(NSUInteger)count 49| 0|{ 50| 0| return [[[OCMAtLeastQuantifier alloc] initWithCount:count] autorelease]; 51| 0|} 52| | 53| |+ (instancetype)atMost:(NSUInteger)count 54| 0|{ 55| 0| return [[[OCMAtMostQuantifier alloc] initWithCount:count] autorelease]; 56| 0|} 57| | 58| | 59| |- (instancetype)initWithCount:(NSUInteger)count 60| 0|{ 61| 0| if((self = [super init]) != nil) 62| 0| { 63| 0| expectedCount = count; 64| 0| [(OCMVerifier *)[[OCMMacroState globalState] recorder] setQuantifier:self]; 65| 0| } 66| 0| return self; 67| 0|} 68| | 69| | 70| |- (BOOL)isValidCount:(NSUInteger)count 71| 0|{ 72| 0| return NO; 73| 0|} 74| | 75| |- (NSString *)description 76| 0|{ 77| 0| switch(expectedCount) 78| 0| { 79| 0| case 0: return @"never"; 80| 0| case 1: return @"once"; 81| 0| default: return [NSString stringWithFormat:@"%lu times", (unsigned long)expectedCount]; 82| 0| } 83| 0|} 84| | 85| |@end 86| | 87| | 88| |@implementation OCMExactCountQuantifier 89| | 90| |- (BOOL)isValidCount:(NSUInteger)count 91| 0|{ 92| 0| return count == expectedCount; 93| 0|} 94| | 95| |@end 96| | 97| | 98| |@implementation OCMAtLeastQuantifier 99| | 100| |- (instancetype)initWithCount:(NSUInteger)count 101| 0|{ 102| 0| if(count == 0) 103| 0| @throw [NSException exceptionWithName:NSInvalidArgumentException reason:@"Count for an at-least quantifier cannot be zero." userInfo:nil]; 104| 0| return [super initWithCount:count]; 105| 0|} 106| | 107| |- (BOOL)isValidCount:(NSUInteger)count 108| 0|{ 109| 0| return count >= expectedCount; 110| 0|} 111| | 112| |- (NSString *)description 113| 0|{ 114| 0| return [@"at least " stringByAppendingString:[super description]]; 115| 0|} 116| | 117| |@end 118| | 119| | 120| |@implementation OCMAtMostQuantifier 121| | 122| |- (instancetype)initWithCount:(NSUInteger)count 123| 0|{ 124| 0| if(count == 0) 125| 0| @throw [NSException exceptionWithName:NSInvalidArgumentException reason:@"Count for an at-most quantifier cannot be zero. Use never or exactly-zero quantifier instead." userInfo:nil]; 126| 0| return [super initWithCount:count]; 127| 0|} 128| | 129| |- (BOOL)isValidCount:(NSUInteger)count 130| 0|{ 131| 0| return count <= expectedCount; 132| 0|} 133| | 134| |- (NSString *)description 135| 0|{ 136| 0| return [@"at most " stringByAppendingString:[super description]]; 137| 0|} 138| | 139| |@end 140| | /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/OCMRealObjectForwarder.m: 1| |/* 2| | * Copyright (c) 2010-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import 18| |#import "OCMRealObjectForwarder.h" 19| |#import "OCPartialMockObject.h" 20| |#import "OCMFunctionsPrivate.h" 21| |#import "NSInvocation+OCMAdditions.h" 22| | 23| | 24| |@implementation OCMRealObjectForwarder 25| | 26| |- (void)handleInvocation:(NSInvocation *)anInvocation 27| 0|{ 28| 0| id invocationTarget = [anInvocation target]; 29| | 30| 0| BOOL isInInitFamily = [anInvocation methodIsInInitFamily]; 31| 0| BOOL isInCreateFamily = isInInitFamily ? NO : [anInvocation methodIsInCreateFamily]; 32| | 33| 0| [anInvocation setSelector:OCMAliasForOriginalSelector([anInvocation selector])]; 34| 0| if([invocationTarget isProxy]) 35| 0| { 36| 0| if(!class_getInstanceMethod([invocationTarget mockObjectClass], @selector(realObject))) 37| 0| [NSException raise:NSInternalInconsistencyException format:@"Method andForwardToRealObject can only be used with partial mocks and class methods."]; 38| | 39| 0| NSObject *realObject = [(OCPartialMockObject *) invocationTarget realObject]; 40| 0| [anInvocation setTarget:realObject]; 41| 0| if(isInInitFamily) 42| 0| { 43| | // The init method of the real object will "consume" self, but because the method was 44| | // invoked on the mock and not the real object a corresponding retain is missing; so 45| | // we do this here. 46| 0| [realObject retain]; 47| 0| } 48| 0| } 49| | 50| 0| [anInvocation invoke]; 51| | 52| 0| if(isInInitFamily || isInCreateFamily) 53| 0| { 54| | // After invoking the method on the real object the return value's retain count is correct, 55| | // but because we have a chain of handlers for an invocation and we handle the retain count 56| | // adjustments at the end in the stub, we undo the additional retains here. 57| 0| id returnVal; 58| 0| [anInvocation getReturnValue:&returnVal]; 59| 0| [returnVal autorelease]; 60| 0| } 61| 0|} 62| | 63| | 64| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/OCMRecorder.m: 1| |#import 2| |/* 3| | * Copyright (c) 2014-2020 Erik Doernenburg and contributors 4| | * 5| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 6| | * not use these files except in compliance with the License. You may obtain 7| | * a copy of the License at 8| | * 9| | * http://www.apache.org/licenses/LICENSE-2.0 10| | * 11| | * Unless required by applicable law or agreed to in writing, software 12| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 13| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 14| | * License for the specific language governing permissions and limitations 15| | * under the License. 16| | */ 17| | 18| |#import 19| |#import "OCMRecorder.h" 20| |#import "OCClassMockObject.h" 21| |#import "OCMInvocationMatcher.h" 22| |#import "NSInvocation+OCMAdditions.h" 23| | 24| | 25| |@implementation OCMRecorder 26| | 27| |- (instancetype)init 28| 0|{ 29| | // no super, we're inheriting from NSProxy 30| 0| didRecordInvocation = NO; 31| 0| shouldReturnMockFromInit = NO; 32| 0| return self; 33| 0|} 34| | 35| |- (instancetype)initWithMockObject:(OCMockObject *)aMockObject 36| 0|{ 37| 0| [self init]; 38| 0| [self setMockObject:aMockObject]; 39| 0| return self; 40| 0|} 41| | 42| |- (void)setMockObject:(OCMockObject *)aMockObject 43| 0|{ 44| 0| mockObject = aMockObject; 45| 0|} 46| | 47| |- (void)setShouldReturnMockFromInit:(BOOL)flag 48| 0|{ 49| 0| shouldReturnMockFromInit = flag; 50| 0|} 51| | 52| |- (void)dealloc 53| 0|{ 54| 0| [invocationMatcher release]; 55| 0| [super dealloc]; 56| 0|} 57| | 58| |- (NSString *)description 59| 0|{ 60| 0| return [invocationMatcher description]; 61| 0|} 62| | 63| |- (OCMInvocationMatcher *)invocationMatcher 64| 0|{ 65| 0| return invocationMatcher; 66| 0|} 67| | 68| |- (BOOL)didRecordInvocation 69| 0|{ 70| 0| return didRecordInvocation; 71| 0|} 72| | 73| | 74| |#pragma mark Modifying the matcher 75| | 76| |- (id)classMethod 77| 0|{ 78| | // should we handle the case where this is called with a mock that isn't a class mock? 79| 0| [invocationMatcher setRecordedAsClassMethod:YES]; 80| 0| return self; 81| 0|} 82| | 83| |- (id)ignoringNonObjectArgs 84| 0|{ 85| 0| [invocationMatcher setIgnoreNonObjectArgs:YES]; 86| 0| return self; 87| 0|} 88| | 89| | 90| |#pragma mark Recording the actual invocation 91| | 92| |- (NSMethodSignature *)methodSignatureForSelector:(SEL)aSelector 93| 0|{ 94| 0| if([invocationMatcher recordedAsClassMethod]) 95| 0| return [[(OCClassMockObject *)mockObject mockedClass] methodSignatureForSelector:aSelector]; 96| | 97| 0| NSMethodSignature *signature = [mockObject methodSignatureForSelector:aSelector]; 98| 0| if(signature == nil) 99| 0| { 100| | // if we're a working with a class mock and there is a class method, auto-switch 101| 0| if(([object_getClass(mockObject) isSubclassOfClass:[OCClassMockObject class]]) && 102| 0| ([[(OCClassMockObject *)mockObject mockedClass] respondsToSelector:aSelector])) 103| 0| { 104| 0| [self classMethod]; 105| 0| signature = [self methodSignatureForSelector:aSelector]; 106| 0| } 107| 0| } 108| 0| return signature; 109| 0|} 110| | 111| |- (void)forwardInvocation:(NSInvocation *)anInvocation 112| 0|{ 113| 0| [anInvocation setTarget:nil]; 114| 0| didRecordInvocation = YES; 115| 0| [invocationMatcher setInvocation:anInvocation]; 116| | 117| | // Code with ARC may retain the receiver of an init method before invoking it. In that case it 118| | // relies on the init method returning an object it can release. So, we must set the correct 119| | // return value here. Normally, the correct return value is the recorder but sometimes it's the 120| | // mock. The decision is easier to make in the mock, which is why the mock sets a flag in the 121| | // recorder and we simply use the flag here. 122| 0| if([anInvocation methodIsInInitFamily]) 123| 0| { 124| 0| id returnValue = shouldReturnMockFromInit ? (id)mockObject : (id)self; 125| 0| [anInvocation setReturnValue:&returnValue]; 126| 0| } 127| 0|} 128| | 129| |- (void)doesNotRecognizeSelector:(SEL)aSelector __used 130| 0|{ 131| 0| [NSException raise:NSInvalidArgumentException format:@"%@: cannot stub/expect/verify method '%@' because no such method exists in the mocked class.", mockObject, NSStringFromSelector(aSelector)]; 132| 0|} 133| | 134| | 135| |@end 136| | 137| | 138| |@implementation OCMRecorder (Properties) 139| | 140| |@dynamic _ignoringNonObjectArgs; 141| | 142| |- (OCMRecorder *(^)(void))_ignoringNonObjectArgs 143| 0|{ 144| 0| id (^theBlock)(void) = ^ (void) 145| 0| { 146| 0| return [self ignoringNonObjectArgs]; 147| 0| }; 148| 0| return [[theBlock copy] autorelease]; 149| 0|} 150| | 151| | 152| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/OCMStubRecorder.m: 1| |/* 2| | * Copyright (c) 2004-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import "OCMStubRecorder.h" 18| |#import "OCClassMockObject.h" 19| |#import "OCMInvocationStub.h" 20| |#import "OCMBlockCaller.h" 21| |#import "OCMBoxedReturnValueProvider.h" 22| |#import "OCMExceptionReturnValueProvider.h" 23| |#import "OCMIndirectReturnValueProvider.h" 24| |#import "OCMNotificationPoster.h" 25| |#import "OCMRealObjectForwarder.h" 26| | 27| |#if !TARGET_OS_WATCH 28| |#import 29| |#endif 30| | 31| |@implementation OCMStubRecorder 32| | 33| |#pragma mark Initialisers, description, accessors, etc. 34| | 35| |- (id)init 36| 0|{ 37| 0| if(invocationMatcher != nil) 38| 0| [NSException raise:NSInternalInconsistencyException format:@"** Method init invoked twice on stub recorder. Are you trying to mock the init method? This is currently not supported."]; 39| | 40| 0| self = [super init]; 41| 0| invocationMatcher = [[OCMInvocationStub alloc] init]; 42| 0| return self; 43| 0|} 44| | 45| |- (OCMInvocationStub *)stub 46| 0|{ 47| 0| return (OCMInvocationStub *)invocationMatcher; 48| 0|} 49| | 50| | 51| |#pragma mark Recording invocation actions 52| | 53| |- (id)andReturn:(id)anObject 54| 0|{ 55| 0| id action; 56| 0| if(anObject == mockObject) 57| 0| { 58| 0| action = [[[OCMNonRetainingObjectReturnValueProvider alloc] initWithValue:anObject] autorelease]; 59| 0| } 60| 0| else 61| 0| { 62| 0| action = [[[OCMObjectReturnValueProvider alloc] initWithValue:anObject] autorelease]; 63| 0| } 64| 0| [[self stub] addInvocationAction:action]; 65| 0| return self; 66| 0|} 67| | 68| |- (id)andReturnValue:(NSValue *)aValue 69| 0|{ 70| 0| [[self stub] addInvocationAction:[[[OCMBoxedReturnValueProvider alloc] initWithValue:aValue] autorelease]]; 71| 0| return self; 72| 0|} 73| | 74| |- (id)andThrow:(NSException *)anException 75| 0|{ 76| 0| [[self stub] addInvocationAction:[[[OCMExceptionReturnValueProvider alloc] initWithValue:anException] autorelease]]; 77| 0| return self; 78| 0|} 79| | 80| |- (id)andPost:(NSNotification *)aNotification 81| 0|{ 82| 0| [[self stub] addInvocationAction:[[[OCMNotificationPoster alloc] initWithNotification:aNotification] autorelease]]; 83| 0| return self; 84| 0|} 85| | 86| |- (id)andCall:(SEL)selector onObject:(id)anObject 87| 0|{ 88| 0| [[self stub] addInvocationAction:[[[OCMIndirectReturnValueProvider alloc] initWithProvider:anObject andSelector:selector] autorelease]]; 89| 0| return self; 90| 0|} 91| | 92| |- (id)andDo:(void (^)(NSInvocation *))aBlock 93| 0|{ 94| 0| [[self stub] addInvocationAction:[[[OCMBlockCaller alloc] initWithCallBlock:aBlock] autorelease]]; 95| 0| return self; 96| 0|} 97| | 98| |- (id)andForwardToRealObject 99| 0|{ 100| 0| [[self stub] addInvocationAction:[[[OCMRealObjectForwarder alloc] init] autorelease]]; 101| 0| return self; 102| 0|} 103| | 104| |#if !TARGET_OS_WATCH 105| |- (id)andFulfill:(XCTestExpectation *)expectation 106| 0|{ 107| 0| return [self andDo:^(NSInvocation *invocation) 108| 0| { 109| 0| [expectation fulfill]; 110| 0| }]; 111| 0|} 112| |#endif 113| | 114| |#pragma mark Finishing recording 115| | 116| |- (void)forwardInvocation:(NSInvocation *)anInvocation 117| 0|{ 118| 0| [super forwardInvocation:anInvocation]; 119| 0| [mockObject addStub:[self stub]]; 120| 0|} 121| | 122| | 123| |@end 124| | 125| | 126| |@implementation OCMStubRecorder (Properties) 127| | 128| |@dynamic _andReturn; 129| | 130| |- (OCMStubRecorder *(^)(NSValue *))_andReturn 131| 0|{ 132| 0| id (^theBlock)(id) = ^ (NSValue *aValue) 133| 0| { 134| 0| if(OCMIsObjectType([aValue objCType])) 135| 0| { 136| 0| id objValue = nil; 137| 0| [aValue getValue:&objValue]; // TODO: deprecated but replacement available in 10.13 only 138| 0| return [self andReturn:objValue]; 139| 0| } 140| 0| else 141| 0| { 142| 0| return [self andReturnValue:aValue]; 143| 0| } 144| 0| }; 145| 0| return (id)[[theBlock copy] autorelease]; 146| 0|} 147| | 148| | 149| |@dynamic _andThrow; 150| | 151| |- (OCMStubRecorder *(^)(NSException *))_andThrow 152| 0|{ 153| 0| id (^theBlock)(id) = ^ (NSException * anException) 154| 0| { 155| 0| return [self andThrow:anException]; 156| 0| }; 157| 0| return (id)[[theBlock copy] autorelease]; 158| 0|} 159| | 160| | 161| |@dynamic _andPost; 162| | 163| |- (OCMStubRecorder *(^)(NSNotification *))_andPost 164| 0|{ 165| 0| id (^theBlock)(id) = ^ (NSNotification * aNotification) 166| 0| { 167| 0| return [self andPost:aNotification]; 168| 0| }; 169| 0| return (id)[[theBlock copy] autorelease]; 170| 0|} 171| | 172| | 173| |@dynamic _andCall; 174| | 175| |- (OCMStubRecorder *(^)(id, SEL))_andCall 176| 0|{ 177| 0| id (^theBlock)(id, SEL) = ^ (id anObject, SEL aSelector) 178| 0| { 179| 0| return [self andCall:aSelector onObject:anObject]; 180| 0| }; 181| 0| return (id)[[theBlock copy] autorelease]; 182| 0|} 183| | 184| | 185| |@dynamic _andDo; 186| | 187| |- (OCMStubRecorder *(^)(void (^)(NSInvocation *)))_andDo 188| 0|{ 189| 0| id (^theBlock)(void (^)(NSInvocation *)) = ^ (void (^ blockToCall)(NSInvocation *)) 190| 0| { 191| 0| return [self andDo:blockToCall]; 192| 0| }; 193| 0| return (id)[[theBlock copy] autorelease]; 194| 0|} 195| | 196| | 197| |@dynamic _andForwardToRealObject; 198| | 199| |- (OCMStubRecorder *(^)(void))_andForwardToRealObject 200| 0|{ 201| 0| id (^theBlock)(void) = ^ (void) 202| 0| { 203| 0| return [self andForwardToRealObject]; 204| 0| }; 205| 0| return (id)[[theBlock copy] autorelease]; 206| 0|} 207| | 208| |#if !TARGET_OS_WATCH 209| | 210| |@dynamic _andFulfill; 211| | 212| |- (OCMStubRecorder * (^)(XCTestExpectation *))_andFulfill 213| 0|{ 214| 0| id (^theBlock)(XCTestExpectation *) = ^ (XCTestExpectation *expectation) 215| 0| { 216| 0| return [self andFulfill:expectation]; 217| 0| }; 218| 0| return (id)[[theBlock copy] autorelease]; 219| 0|} 220| |#endif 221| | 222| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/OCMVerifier.m: 1| |/* 2| | * Copyright (c) 2014-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import "OCMVerifier.h" 18| |#import "OCMockObject.h" 19| |#import "OCMInvocationMatcher.h" 20| |#import "OCMLocation.h" 21| |#import "OCMQuantifier.h" 22| | 23| | 24| |@implementation OCMVerifier 25| | 26| |- (id)init 27| 0|{ 28| 0| if(invocationMatcher != nil) 29| 0| [NSException raise:NSInternalInconsistencyException format:@"** Method init invoked twice on verifier. Are you trying to verify the init method? This is currently not supported."]; 30| 0| if ((self = [super init])) 31| 0| { 32| 0| invocationMatcher = [[OCMInvocationMatcher alloc] init]; 33| 0| } 34| | 35| 0| return self; 36| 0|} 37| | 38| |- (id)withQuantifier:(OCMQuantifier *)quantifier 39| 0|{ 40| 0| [self setQuantifier:quantifier]; 41| 0| return self; 42| 0|} 43| | 44| |- (void)forwardInvocation:(NSInvocation *)anInvocation 45| 0|{ 46| 0| [super forwardInvocation:anInvocation]; 47| 0| [mockObject verifyInvocation:invocationMatcher withQuantifier:self.quantifier atLocation:self.location]; 48| 0|} 49| | 50| |- (void)dealloc 51| 0|{ 52| 0| [_location release]; 53| 0| [_quantifier release]; 54| 0| [super dealloc]; 55| 0|} 56| | 57| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/OCMockObject.m: 1| |/* 2| | * Copyright (c) 2004-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import "OCMockObject.h" 18| |#import "OCClassMockObject.h" 19| |#import "OCProtocolMockObject.h" 20| |#import "OCPartialMockObject.h" 21| |#import "OCObserverMockObject.h" 22| |#import "OCMExceptionReturnValueProvider.h" 23| |#import "OCMExpectationRecorder.h" 24| |#import "OCMInvocationExpectation.h" 25| |#import "OCMLocation.h" 26| |#import "OCMMacroState.h" 27| |#import "OCMQuantifier.h" 28| |#import "OCMVerifier.h" 29| |#import "OCMFunctionsPrivate.h" 30| |#import "NSInvocation+OCMAdditions.h" 31| | 32| | 33| |@implementation OCMockObject 34| | 35| |#pragma mark Class initialisation 36| | 37| |+ (void)initialize 38| 0|{ 39| 0| if([[NSInvocation class] instanceMethodSignatureForSelector:@selector(getArgumentAtIndexAsObject:)] == NULL) 40| 0| [NSException raise:NSInternalInconsistencyException format:@"** Expected method not present; the method getArgumentAtIndexAsObject: is not implemented by NSInvocation. If you see this exception it is likely that you are using the static library version of OCMock and your project is not configured correctly to load categories from static libraries. Did you forget to add the -ObjC linker flag?"]; 41| 0|} 42| | 43| | 44| |#pragma mark Factory methods 45| | 46| |+ (id)mockForClass:(Class)aClass 47| 0|{ 48| 0| return [[[OCClassMockObject alloc] initWithClass:aClass] autorelease]; 49| 0|} 50| | 51| |+ (id)mockForProtocol:(Protocol *)aProtocol 52| 0|{ 53| 0| return [[[OCProtocolMockObject alloc] initWithProtocol:aProtocol] autorelease]; 54| 0|} 55| | 56| |+ (id)partialMockForObject:(NSObject *)anObject 57| 0|{ 58| 0| return [[[OCPartialMockObject alloc] initWithObject:anObject] autorelease]; 59| 0|} 60| | 61| | 62| |+ (id)niceMockForClass:(Class)aClass 63| 0|{ 64| 0| return [self _makeNice:[self mockForClass:aClass]]; 65| 0|} 66| | 67| |+ (id)niceMockForProtocol:(Protocol *)aProtocol 68| 0|{ 69| 0| return [self _makeNice:[self mockForProtocol:aProtocol]]; 70| 0|} 71| | 72| | 73| |+ (id)_makeNice:(OCMockObject *)mock 74| 0|{ 75| 0| mock->isNice = YES; 76| 0| return mock; 77| 0|} 78| | 79| | 80| |+ (id)observerMock 81| 0|{ 82| 0| return [[[OCObserverMockObject alloc] init] autorelease]; 83| 0|} 84| | 85| | 86| |#pragma mark Initialisers, description, accessors, etc. 87| | 88| |- (instancetype)init 89| 0|{ 90| | // check if we are called from inside a macro 91| 0| OCMRecorder *recorder = [[OCMMacroState globalState] recorder]; 92| 0| if(recorder != nil) 93| 0| { 94| 0| [recorder setMockObject:self]; 95| 0| return (id)[recorder init]; 96| 0| } 97| | 98| | // skip initialisation when init is called again, which can happen when stubbing alloc/init 99| 0| if(stubs != nil) 100| 0| { 101| 0| return self; 102| 0| } 103| | 104| 0| if([self class] == [OCMockObject class]) 105| 0| { 106| 0| [NSException raise:NSInternalInconsistencyException format:@"*** Cannot create instances of OCMockObject. Please use one of the subclasses."]; 107| 0| } 108| | 109| | // no [super init], we're inheriting from NSProxy 110| 0| expectationOrderMatters = NO; 111| 0| stubs = [[NSMutableArray alloc] init]; 112| 0| expectations = [[NSMutableArray alloc] init]; 113| 0| exceptions = [[NSMutableArray alloc] init]; 114| 0| invocations = [[NSMutableArray alloc] init]; 115| 0| return self; 116| 0|} 117| | 118| |- (void)dealloc 119| 0|{ 120| 0| [stubs release]; 121| 0| [expectations release]; 122| 0| [exceptions release]; 123| 0| [invocations release]; 124| 0| [super dealloc]; 125| 0|} 126| | 127| |- (NSString *)description 128| 0|{ 129| 0| return @"OCMockObject"; 130| 0|} 131| | 132| |- (void)addStub:(OCMInvocationStub *)aStub 133| 0|{ 134| 0| [self assertInvocationsArrayIsPresent]; 135| 0| @synchronized(stubs) 136| 0| { 137| 0| [stubs addObject:aStub]; 138| 0| } 139| 0|} 140| | 141| |- (OCMInvocationStub *)stubForInvocation:(NSInvocation *)anInvocation 142| 0|{ 143| 0| @synchronized(stubs) 144| 0| { 145| 0| for(OCMInvocationStub *stub in stubs) 146| 0| if([stub matchesInvocation:anInvocation]) 147| 0| return stub; 148| 0| return nil; 149| 0| } 150| 0|} 151| | 152| |- (void)addExpectation:(OCMInvocationExpectation *)anExpectation 153| 0|{ 154| 0| @synchronized(expectations) 155| 0| { 156| 0| [expectations addObject:anExpectation]; 157| 0| } 158| 0|} 159| | 160| |- (void)assertInvocationsArrayIsPresent 161| 0|{ 162| 0| if(invocations == nil) 163| 0| { 164| 0| [NSException raise:NSInternalInconsistencyException format:@"** Cannot use mock object %@ at %p. This error usually occurs when a mock object is used after stopMocking has been called on it. In most cases it is not necessary to call stopMocking. If you know you have to, please make sure that the mock object is not used afterwards.", [self description], (void *)self]; 165| 0| } 166| 0|} 167| | 168| |- (void)addInvocation:(NSInvocation *)anInvocation 169| 0|{ 170| 0| @synchronized(invocations) 171| 0| { 172| | // We can't do a normal retain arguments on anInvocation because its target/arguments/return 173| | // value could be self. That would produce a retain cycle self->invocations->anInvocation->self. 174| | // However we need to retain everything on anInvocation that isn't self because we expect them to 175| | // stick around after this method returns. Use our special method to retain just what's needed. 176| | // This still doesn't completely prevent retain cycles since any of the arguments could have a 177| | // strong reference to self. Those will have to be broken with manual calls to -stopMocking. 178| 0| [anInvocation retainObjectArgumentsExcludingObject:self]; 179| 0| [invocations addObject:anInvocation]; 180| 0| } 181| 0|} 182| | 183| | 184| |#pragma mark Public API 185| | 186| |- (void)setExpectationOrderMatters:(BOOL)flag 187| 0|{ 188| 0| expectationOrderMatters = flag; 189| 0|} 190| | 191| |- (void)stopMocking 192| 0|{ 193| | // invocations can contain objects that clients expect to be deallocated by now, 194| | // and they can also have a strong reference to self, creating a retain cycle. Get 195| | // rid of all of the invocations to hopefully let their objects deallocate, and to 196| | // break any retain cycles involving self. 197| 0| @synchronized(invocations) 198| 0| { 199| 0| [invocations removeAllObjects]; 200| 0| [invocations autorelease]; 201| 0| invocations = nil; 202| 0| } 203| 0|} 204| | 205| | 206| |- (id)stub 207| 0|{ 208| 0| return [[[OCMStubRecorder alloc] initWithMockObject:self] autorelease]; 209| 0|} 210| | 211| |- (id)expect 212| 0|{ 213| 0| return [[[OCMExpectationRecorder alloc] initWithMockObject:self] autorelease]; 214| 0|} 215| | 216| |- (id)reject 217| 0|{ 218| 0| return [[self expect] never]; 219| 0|} 220| | 221| | 222| |- (id)verify 223| 0|{ 224| 0| return [self verifyAtLocation:nil]; 225| 0|} 226| | 227| |- (id)verifyAtLocation:(OCMLocation *)location 228| 0|{ 229| 0| NSMutableArray *unsatisfiedExpectations = [NSMutableArray array]; 230| 0| @synchronized(expectations) 231| 0| { 232| 0| for(OCMInvocationExpectation *e in expectations) 233| 0| { 234| 0| if(![e isSatisfied]) 235| 0| [unsatisfiedExpectations addObject:e]; 236| 0| } 237| 0| } 238| | 239| 0| if([unsatisfiedExpectations count] == 1) 240| 0| { 241| 0| NSString *description = [NSString stringWithFormat:@"%@: expected method was not invoked: %@", 242| 0| [self description], [[unsatisfiedExpectations objectAtIndex:0] description]]; 243| 0| OCMReportFailure(location, description); 244| 0| } 245| 0| else if([unsatisfiedExpectations count] > 0) 246| 0| { 247| 0| NSString *description = [NSString stringWithFormat:@"%@: %@ expected methods were not invoked: %@", 248| 0| [self description], @([unsatisfiedExpectations count]), [self _stubDescriptions:YES]]; 249| 0| OCMReportFailure(location, description); 250| 0| } 251| | 252| 0| OCMInvocationExpectation *firstException = nil; 253| 0| @synchronized(exceptions) 254| 0| { 255| 0| firstException = [exceptions.firstObject retain]; 256| 0| } 257| 0| if(firstException) 258| 0| { 259| 0| NSString *description = [NSString stringWithFormat:@"%@: %@ (This is a strict mock failure that was ignored when it actually occurred.)", 260| 0| [self description], [firstException description]]; 261| 0| OCMReportFailure(location, description); 262| 0| } 263| 0| [firstException release]; 264| | 265| 0| return [[[OCMVerifier alloc] initWithMockObject:self] autorelease]; 266| 0|} 267| | 268| | 269| |- (void)verifyWithDelay:(NSTimeInterval)delay 270| 0|{ 271| 0| [self verifyWithDelay:delay atLocation:nil]; 272| 0|} 273| | 274| |- (void)verifyWithDelay:(NSTimeInterval)delay atLocation:(OCMLocation *)location 275| 0|{ 276| 0| NSTimeInterval step = 0.01; 277| 0| while(delay > 0) 278| 0| { 279| 0| @synchronized(expectations) 280| 0| { 281| 0| BOOL allExpectationsAreMatchAndReject = YES; 282| 0| for(OCMInvocationExpectation *expectation in expectations) 283| 0| { 284| 0| if(![expectation isMatchAndReject]) 285| 0| { 286| 0| allExpectationsAreMatchAndReject = NO; 287| 0| break; 288| 0| } 289| 0| } 290| 0| if(allExpectationsAreMatchAndReject) 291| 0| break; 292| 0| } 293| 0| [[NSRunLoop currentRunLoop] runUntilDate:[NSDate dateWithTimeIntervalSinceNow:MIN(step, delay)]]; 294| 0| delay -= step; 295| 0| step *= 2; 296| 0| } 297| 0| [self verifyAtLocation:location]; 298| 0|} 299| | 300| | 301| |#pragma mark Verify after running 302| | 303| |- (void)verifyInvocation:(OCMInvocationMatcher *)matcher 304| 0|{ 305| 0| [self verifyInvocation:matcher atLocation:nil]; 306| 0|} 307| | 308| |- (void)verifyInvocation:(OCMInvocationMatcher *)matcher atLocation:(OCMLocation *)location 309| 0|{ 310| 0| [self verifyInvocation:matcher withQuantifier:nil atLocation:location]; 311| 0|} 312| | 313| |- (void)verifyInvocation:(OCMInvocationMatcher *)matcher withQuantifier:(OCMQuantifier *)quantifier atLocation:(OCMLocation *)location 314| 0|{ 315| 0| NSUInteger count = 0; 316| 0| [self assertInvocationsArrayIsPresent]; 317| 0| @synchronized(invocations) 318| 0| { 319| 0| for(NSInvocation *invocation in invocations) 320| 0| { 321| 0| if([matcher matchesInvocation:invocation]) 322| 0| count += 1; 323| 0| } 324| 0| } 325| 0| if(quantifier == nil) 326| 0| quantifier = [OCMQuantifier atLeast:1]; 327| 0| if(![quantifier isValidCount:count]) 328| 0| { 329| 0| NSString *description = [self descriptionForVerificationFailureWithMatcher:matcher quantifier:quantifier invocationCount:count]; 330| 0| OCMReportFailure(location, description); 331| 0| } 332| 0|} 333| | 334| |- (NSString *)descriptionForVerificationFailureWithMatcher:(OCMInvocationMatcher *)matcher quantifier:(OCMQuantifier *)quantifier invocationCount:(NSUInteger)count 335| 0|{ 336| 0| NSString *actualDescription = nil; 337| 0| switch(count) 338| 0| { 339| 0| case 0: actualDescription = @"not invoked"; break; 340| 0| case 1: actualDescription = @"invoked once"; break; 341| 0| default: actualDescription = [NSString stringWithFormat:@"invoked %lu times", (unsigned long)count]; break; 342| 0| } 343| | 344| 0| return [NSString stringWithFormat:@"%@: Method `%@` was %@; but was expected %@.", 345| 0| [self description], [matcher description], actualDescription, [quantifier description]]; 346| 0|} 347| | 348| | 349| |#pragma mark Handling invocations 350| | 351| |- (id)forwardingTargetForSelector:(SEL)aSelector 352| 0|{ 353| 0| if([OCMMacroState globalState] != nil) 354| 0| { 355| 0| OCMRecorder *recorder = [[OCMMacroState globalState] recorder]; 356| 0| [recorder setMockObject:self]; 357| | // In order for ARC to work correctly, the recorder has to set up return values for 358| | // methods in the init family of methods. If the mock forwards a method to the recorder 359| | // that it will record, i.e. a method that the recorder does not implement, then the 360| | // recorder must set the mock as the return value. Otherwise it must use itself. 361| 0| [recorder setShouldReturnMockFromInit:(class_getInstanceMethod(object_getClass(recorder), aSelector) == NO)]; 362| 0| return recorder; 363| 0| } 364| 0| return nil; 365| 0|} 366| | 367| | 368| |- (BOOL)handleSelector:(SEL)sel 369| 0|{ 370| 0| @synchronized(stubs) 371| 0| { 372| 0| for(OCMInvocationStub *recorder in stubs) 373| 0| if([recorder matchesSelector:sel]) 374| 0| return YES; 375| 0| } 376| 0| return NO; 377| 0|} 378| | 379| |- (void)forwardInvocation:(NSInvocation *)anInvocation 380| 0|{ 381| 0| @try 382| 0| { 383| 0| if([self handleInvocation:anInvocation] == NO) 384| 0| [self handleUnRecordedInvocation:anInvocation]; 385| 0| } 386| 0| @catch(NSException *e) 387| 0| { 388| 0| if([[e name] isEqualToString:OCMStubbedException]) 389| 0| { 390| 0| e = [[e userInfo] objectForKey:@"exception"]; 391| 0| } 392| 0| else 393| 0| { 394| | // add non-stubbed method to list of exceptions to be re-raised in verify 395| 0| @synchronized(exceptions) 396| 0| { 397| 0| [exceptions addObject:e]; 398| 0| } 399| 0| } 400| 0| [e raise]; 401| 0| } 402| 0|} 403| | 404| |- (BOOL)handleInvocation:(NSInvocation *)anInvocation 405| 0|{ 406| 0| [self assertInvocationsArrayIsPresent]; 407| 0| [self addInvocation:anInvocation]; 408| | 409| 0| OCMInvocationStub *stub = [self stubForInvocation:anInvocation]; 410| 0| if(stub == nil) 411| 0| return NO; 412| | 413| | // Retain the stub in case it ends up being removed because we still need it at the end for handleInvocation: 414| 0| [stub retain]; 415| | 416| 0| BOOL removeStub = NO; 417| 0| @synchronized(expectations) 418| 0| { 419| 0| if([expectations containsObject:stub]) 420| 0| { 421| 0| OCMInvocationExpectation *expectation = [self _nextExpectedInvocation]; 422| 0| if(expectationOrderMatters && (expectation != stub)) 423| 0| { 424| 0| [NSException raise:NSInternalInconsistencyException format:@"%@: unexpected method invoked: %@\n\texpected:\t%@", 425| 0| [self description], [stub description], [[expectations objectAtIndex:0] description]]; 426| 0| } 427| | 428| | // We can't check isSatisfied yet, since the stub won't be satisfied until we call 429| | // handleInvocation: since we'll still have the current expectation in the expectations array, which 430| | // will cause an exception if expectationOrderMatters is YES and we're not ready for any future 431| | // expected methods to be called yet 432| 0| if(![(OCMInvocationExpectation *)stub isMatchAndReject]) 433| 0| { 434| 0| [expectations removeObject:stub]; 435| 0| removeStub = YES; 436| 0| } 437| 0| } 438| 0| } 439| 0| if(removeStub) 440| 0| { 441| 0| @synchronized(stubs) 442| 0| { 443| 0| [stubs removeObject:stub]; 444| 0| } 445| 0| } 446| | 447| 0| @try 448| 0| { 449| 0| [stub handleInvocation:anInvocation]; 450| 0| } 451| 0| @finally 452| 0| { 453| 0| [stub release]; 454| 0| } 455| | 456| 0| return YES; 457| 0|} 458| | 459| |// Must be synchronized on expectations when calling this method. 460| |- (OCMInvocationExpectation *)_nextExpectedInvocation 461| 0|{ 462| 0| for(OCMInvocationExpectation *expectation in expectations) 463| 0| if(![expectation isMatchAndReject]) 464| 0| return expectation; 465| 0| return nil; 466| 0|} 467| | 468| |- (void)handleUnRecordedInvocation:(NSInvocation *)anInvocation 469| 0|{ 470| 0| if(isNice == NO) 471| 0| { 472| 0| [NSException raise:NSInternalInconsistencyException format:@"%@: unexpected method invoked: %@ %@", 473| 0| [self description], [anInvocation invocationDescription], [self _stubDescriptions:NO]]; 474| 0| } 475| 0|} 476| | 477| |- (void)doesNotRecognizeSelector:(SEL)aSelector __unused 478| 0|{ 479| 0| if([OCMMacroState globalState] != nil) 480| 0| { 481| | // we can't do anything clever with the macro state because we must raise an exception here 482| 0| [NSException raise:NSInvalidArgumentException format:@"%@: Cannot stub/expect/verify method '%@' because no such method exists in the mocked class.", 483| 0| [self description], NSStringFromSelector(aSelector)]; 484| 0| } 485| 0| else 486| 0| { 487| 0| [NSException raise:NSInvalidArgumentException format:@"-[%@ %@]: unrecognized selector sent to instance %p", 488| 0| [self description], NSStringFromSelector(aSelector), (void *)self]; 489| 0| } 490| 0|} 491| | 492| | 493| |#pragma mark Helper methods 494| | 495| |- (NSString *)_stubDescriptions:(BOOL)onlyExpectations 496| 0|{ 497| 0| NSMutableString *outputString = [NSMutableString string]; 498| 0| NSArray *stubsCopy = nil; 499| 0| @synchronized(stubs) 500| 0| { 501| 0| stubsCopy = [stubs copy]; 502| 0| } 503| 0| for(OCMStubRecorder *stub in stubsCopy) 504| 0| { 505| 0| BOOL expectationsContainStub = NO; 506| 0| @synchronized(expectations) 507| 0| { 508| 0| expectationsContainStub = [expectations containsObject:stub]; 509| 0| } 510| | 511| 0| NSString *prefix = @""; 512| | 513| 0| if(onlyExpectations) 514| 0| { 515| 0| if(expectationsContainStub == NO) 516| 0| continue; 517| 0| } 518| 0| else 519| 0| { 520| 0| if(expectationsContainStub) 521| 0| prefix = @"expected:\t"; 522| 0| else 523| 0| prefix = @"stubbed:\t"; 524| 0| } 525| 0| [outputString appendFormat:@"\n\t%@%@", prefix, [stub description]]; 526| 0| } 527| 0| [stubsCopy release]; 528| 0| return outputString; 529| 0|} 530| | 531| | 532| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/OCObserverMockObject.m: 1| |/* 2| | * Copyright (c) 2009-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import "OCObserverMockObject.h" 18| |#import "OCMLocation.h" 19| |#import "OCMMacroState.h" 20| |#import "OCMObserverRecorder.h" 21| |#import "OCMFunctionsPrivate.h" 22| | 23| |#pragma clang diagnostic push 24| |#pragma clang diagnostic ignored "-Wdeprecated-implementations" 25| |@implementation OCObserverMockObject 26| |#pragma clang diagnostic pop 27| | 28| |#pragma mark Initialisers, description, accessors, etc. 29| | 30| |- (id)init 31| 0|{ 32| 0| if ((self = [super init])) 33| 0| { 34| 0| recorders = [[NSMutableArray alloc] init]; 35| 0| centers = [[NSMutableArray alloc] init]; 36| 0| } 37| | 38| 0| return self; 39| 0|} 40| | 41| |- (id)retain 42| 0|{ 43| 0| return [super retain]; 44| 0|} 45| | 46| |- (void)dealloc 47| 0|{ 48| 0| for(NSNotificationCenter *c in centers) 49| 0| [c removeObserver:self]; 50| 0| [centers release]; 51| 0| [recorders release]; 52| 0| [super dealloc]; 53| 0|} 54| | 55| |- (NSString *)description 56| 0|{ 57| 0| return @"OCObserverMockObject"; 58| 0|} 59| | 60| |- (void)setExpectationOrderMatters:(BOOL)flag 61| 0|{ 62| 0| expectationOrderMatters = flag; 63| 0|} 64| | 65| |- (void)autoRemoveFromCenter:(NSNotificationCenter *)aCenter 66| 0|{ 67| 0| @synchronized(centers) 68| 0| { 69| 0| [centers addObject:aCenter]; 70| 0| } 71| 0|} 72| | 73| | 74| |#pragma mark Public API 75| | 76| |- (id)expect 77| 0|{ 78| 0| OCMObserverRecorder *recorder = [[[OCMObserverRecorder alloc] init] autorelease]; 79| 0| @synchronized(recorders) 80| 0| { 81| 0| [recorders addObject:recorder]; 82| 0| } 83| 0| return recorder; 84| 0|} 85| | 86| |- (void)verify 87| 0|{ 88| 0| [self verifyAtLocation:nil]; 89| 0|} 90| | 91| |- (void)verifyAtLocation:(OCMLocation *)location 92| 0|{ 93| 0| @synchronized(recorders) 94| 0| { 95| 0| if([recorders count] == 1) 96| 0| { 97| 0| NSString *description = [NSString stringWithFormat:@"%@: expected notification was not observed: %@", 98| 0| [self description], [[recorders lastObject] description]]; 99| 0| OCMReportFailure(location, description); 100| 0| } 101| 0| else if([recorders count] > 0) 102| 0| { 103| 0| NSString *description = [NSString stringWithFormat:@"%@ : %@ expected notifications were not observed.", 104| 0| [self description], @([recorders count])]; 105| 0| OCMReportFailure(location, description); 106| 0| } 107| 0| } 108| 0|} 109| | 110| | 111| |#pragma mark Receiving recording requests via macro 112| | 113| |// This is a bit of a hack. The methods simply assume that when they are called from within a macro that it's 114| |// the OCMExpect macro. That creates a recorder for mock objects, which we cannot use here. So, we overwrite 115| |// it with a newly allocated recorder. 116| | 117| |- (NSNotification *)notificationWithName:(NSString *)name object:(id)sender 118| 0|{ 119| 0| if([OCMMacroState globalState] != nil) 120| 0| { 121| 0| id recorder = [self expect]; 122| 0| [[OCMMacroState globalState] setRecorder:recorder]; 123| 0| return [recorder notificationWithName:name object:sender]; 124| 0| } 125| 0| return nil; 126| 0|} 127| | 128| |- (NSNotification *)notificationWithName:(NSString *)name object:(id)sender userInfo:(NSDictionary *)userInfo 129| 0|{ 130| 0| if([OCMMacroState globalState] != nil) 131| 0| { 132| 0| id recorder = [self expect]; 133| 0| [[OCMMacroState globalState] setRecorder:recorder]; 134| 0| return [recorder notificationWithName:name object:sender userInfo:userInfo]; 135| 0| } 136| 0| return nil; 137| 0|} 138| | 139| | 140| |#pragma mark Receiving notifications 141| | 142| |- (void)handleNotification:(NSNotification *)aNotification 143| 0|{ 144| 0| @synchronized(recorders) 145| 0| { 146| 0| NSUInteger i, limit; 147| | 148| 0| limit = expectationOrderMatters ? 1 : [recorders count]; 149| 0| for(i = 0; i < limit; i++) 150| 0| { 151| 0| if([[recorders objectAtIndex:i] matchesNotification:aNotification]) 152| 0| { 153| 0| [recorders removeObjectAtIndex:i]; 154| 0| return; 155| 0| } 156| 0| } 157| 0| } 158| 0| [NSException raise:NSInternalInconsistencyException format:@"%@: unexpected notification observed: %@", [self description], 159| 0| [aNotification description]]; 160| 0|} 161| | 162| | 163| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/OCPartialMockObject.m: 1| |/* 2| | * Copyright (c) 2009-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import 18| |#import "OCPartialMockObject.h" 19| |#import "NSObject+OCMAdditions.h" 20| |#import "OCMFunctionsPrivate.h" 21| |#import "OCMInvocationStub.h" 22| |#import "NSInvocation+OCMAdditions.h" 23| |#import "NSMethodSignature+OCMAdditions.h" 24| | 25| | 26| |@implementation OCPartialMockObject 27| | 28| |#pragma mark Initialisers, description, accessors, etc. 29| | 30| |- (id)initWithObject:(NSObject *)anObject 31| 0|{ 32| 0| if(anObject == nil) 33| 0| [NSException raise:NSInvalidArgumentException format:@"Object cannot be nil."]; 34| 0| Class const class = [self classToSubclassForObject:anObject]; 35| 0| [super initWithClass:class]; 36| 0| realObject = [anObject retain]; 37| 0| [self prepareObjectForInstanceMethodMocking]; 38| 0| return self; 39| 0|} 40| | 41| |- (NSString *)description 42| 0|{ 43| 0| return [NSString stringWithFormat:@"OCPartialMockObject(%@)", NSStringFromClass(mockedClass)]; 44| 0|} 45| | 46| |- (NSObject *)realObject 47| 0|{ 48| 0| return realObject; 49| 0|} 50| | 51| |#pragma mark Helper methods 52| | 53| |- (void)assertClassIsSupported:(Class)class 54| 0|{ 55| 0| [super assertClassIsSupported:class]; 56| 0| NSString *classname = NSStringFromClass(class); 57| 0| NSString *reason = nil; 58| 0| if([classname hasPrefix:@"__NSTagged"] || [classname hasPrefix:@"NSTagged"]) 59| 0| reason = [NSString stringWithFormat:@"OCMock does not support partially mocking tagged classes; got %@", classname]; 60| 0| else if([classname hasPrefix:@"__NSCF"]) 61| 0| reason = [NSString stringWithFormat:@"OCMock does not support partially mocking toll-free bridged classes; got %@", classname]; 62| | 63| 0| if(reason != nil) 64| 0| [[NSException exceptionWithName:NSInvalidArgumentException reason:reason userInfo:nil] raise]; 65| 0|} 66| | 67| |- (Class)classToSubclassForObject:(id)object 68| 0|{ 69| 0| if([object observationInfo] != NULL) 70| 0| { 71| | // Special treatment for objects that are observed with KVO. The KVO implementation sets 72| | // a subclass for such objects and it overrides the -class method to return the original 73| | // class. If we base our subclass on the KVO subclass, as returned by object_getClass(), 74| | // crashes will occur. So, we take the real class instead. Unfortunately, this removes 75| | // any observers set up before. 76| 0| NSLog(@"Warning: Creating a partial mock for %@. This object has observers, which will now stop receiving KVO notifications. If you want to receive KVO notifications, create the partial mock first, and then register the observer.", object); 77| 0| return [object class]; 78| 0| } 79| | 80| 0| return object_getClass(object); 81| 0|} 82| | 83| |#pragma mark Extending/overriding superclass behaviour 84| | 85| |- (void)stopMocking 86| 0|{ 87| 0| if(realObject != nil) 88| 0| { 89| 0| Class partialMockClass = object_getClass(realObject); 90| 0| OCMSetAssociatedMockForObject(nil, realObject); 91| 0| object_setClass(realObject, [self mockedClass]); 92| 0| [realObject release]; 93| 0| realObject = nil; 94| 0| OCMDisposeSubclass(partialMockClass); 95| 0| } 96| 0| [super stopMocking]; 97| 0|} 98| | 99| |- (void)addStub:(OCMInvocationStub *)aStub 100| 0|{ 101| 0| [super addStub:aStub]; 102| 0| if(![aStub recordedAsClassMethod]) 103| 0| [self setupForwarderForSelector:[[aStub recordedInvocation] selector]]; 104| 0|} 105| | 106| |- (void)addInvocation:(NSInvocation *)anInvocation 107| 0|{ 108| | // If the mock invokes a method on the real object we end up here a second time, but because 109| | // the mock has added the invocation already we do not want to add it again. 110| 0| if((invocationFromMock == nil) || ([anInvocation selector] != [invocationFromMock selector])) 111| 0| [super addInvocation:anInvocation]; 112| 0|} 113| | 114| |- (void)handleUnRecordedInvocation:(NSInvocation *)anInvocation 115| 0|{ 116| | // In the case of an init that is called on a mock we must return the mock instance and 117| | // not the realObject if the underlying init returns the realObject because at the call site 118| | // ARC will have retained the target and the release/retain count must balance. If we return 119| | // the realObject, then realObject will be over released and the mock will leak. Equally if 120| | // we are called on the realObject we need to make sure not to return the mock. 121| 0| id targetReceivingInit = nil; 122| 0| if([anInvocation methodIsInInitFamily]) 123| 0| { 124| 0| targetReceivingInit = [anInvocation target]; 125| 0| [realObject retain]; 126| 0| } 127| | 128| 0| invocationFromMock = anInvocation; 129| 0| [anInvocation invokeWithTarget:realObject]; 130| 0| invocationFromMock = nil; 131| | 132| 0| if(targetReceivingInit) 133| 0| { 134| 0| id returnVal; 135| 0| [anInvocation getReturnValue:&returnVal]; 136| 0| if(returnVal == realObject) 137| 0| { 138| 0| [anInvocation setReturnValue:&self]; 139| 0| [realObject release]; 140| 0| [self retain]; 141| 0| } 142| 0| [targetReceivingInit release]; 143| 0| } 144| 0|} 145| | 146| | 147| |#pragma mark Subclass management 148| | 149| |- (void)prepareObjectForInstanceMethodMocking 150| 0|{ 151| 0| OCMSetAssociatedMockForObject(self, realObject); 152| | 153| | /* dynamically create a subclass and set it as the class of the object */ 154| 0| Class subclass = OCMCreateSubclass(mockedClass, realObject); 155| 0| object_setClass(realObject, subclass); 156| | 157| | /* point forwardInvocation: of the object to the implementation in the mock */ 158| 0| Method myForwardMethod = class_getInstanceMethod([self mockObjectClass], @selector(forwardInvocationForRealObject:)); 159| 0| IMP myForwardIMP = method_getImplementation(myForwardMethod); 160| 0| class_addMethod(subclass, @selector(forwardInvocation:), myForwardIMP, method_getTypeEncoding(myForwardMethod)); 161| | 162| | /* do the same for forwardingTargetForSelector, remember existing imp with alias selector */ 163| 0| Method myForwardingTargetMethod = class_getInstanceMethod([self mockObjectClass], @selector(forwardingTargetForSelectorForRealObject:)); 164| 0| IMP myForwardingTargetIMP = method_getImplementation(myForwardingTargetMethod); 165| 0| IMP originalForwardingTargetIMP = [mockedClass instanceMethodForSelector:@selector(forwardingTargetForSelector:)]; 166| 0| class_addMethod(subclass, @selector(forwardingTargetForSelector:), myForwardingTargetIMP, method_getTypeEncoding(myForwardingTargetMethod)); 167| 0| class_addMethod(subclass, @selector(ocmock_replaced_forwardingTargetForSelector:), originalForwardingTargetIMP, method_getTypeEncoding(myForwardingTargetMethod)); 168| | 169| | /* We also override the -class method to return the original class */ 170| 0| Method myObjectClassMethod = class_getInstanceMethod([self mockObjectClass], @selector(classForRealObject)); 171| 0| const char *objectClassTypes = method_getTypeEncoding(myObjectClassMethod); 172| 0| IMP myObjectClassImp = method_getImplementation(myObjectClassMethod); 173| 0| class_addMethod(subclass, @selector(class), myObjectClassImp, objectClassTypes); 174| | 175| | /* Adding forwarder for most instance methods to allow for verify after run */ 176| 0| NSArray *methodBlackList = @[@"class", @"forwardingTargetForSelector:", @"methodSignatureForSelector:", @"forwardInvocation:", 177| 0| @"allowsWeakReference", @"retainWeakReference", @"isBlock", @"retainCount", @"retain", @"release", @"autorelease"]; 178| 0| [NSObject enumerateMethodsInClass:mockedClass usingBlock:^(Class cls, SEL sel) { 179| 0| if(OCMIsAppleBaseClass(cls) || OCMIsApplePrivateMethod(cls, sel)) 180| 0| return; 181| 0| if([methodBlackList containsObject:NSStringFromSelector(sel)]) 182| 0| return; 183| 0| @try 184| 0| { 185| 0| [self setupForwarderForSelector:sel]; 186| 0| } 187| 0| @catch(NSException *e) 188| 0| { 189| | // ignore for now 190| 0| } 191| 0| }]; 192| 0|} 193| | 194| |- (void)setupForwarderForSelector:(SEL)sel 195| 0|{ 196| 0| SEL aliasSelector = OCMAliasForOriginalSelector(sel); 197| 0| if(class_getInstanceMethod(object_getClass(realObject), aliasSelector) != NULL) 198| 0| return; 199| | 200| 0| Method originalMethod = class_getInstanceMethod(mockedClass, sel); 201| | /* Might be NULL if the selector is forwarded to another class */ 202| 0| IMP originalIMP = (originalMethod != NULL) ? method_getImplementation(originalMethod) : NULL; 203| 0| const char *types = (originalMethod != NULL) ? method_getTypeEncoding(originalMethod) : NULL; 204| | // TODO: check the fallback implementation is actually sufficient 205| 0| if(types == NULL) 206| 0| types = ([[mockedClass instanceMethodSignatureForSelector:sel] fullObjCTypes]); 207| | 208| 0| Class subclass = object_getClass([self realObject]); 209| 0| IMP forwarderIMP = [mockedClass instanceMethodForwarderForSelector:sel]; 210| 0| class_replaceMethod(subclass, sel, forwarderIMP, types); 211| 0| class_addMethod(subclass, aliasSelector, originalIMP, types); 212| 0|} 213| | 214| | 215| |// Implementation of the -class method; return the Class that was reported with [realObject class] prior to mocking 216| |- (Class)classForRealObject 217| 0|{ 218| | // in here "self" is a reference to the real object, not the mock 219| 0| OCPartialMockObject *mock = OCMGetAssociatedMockForObject(self); 220| 0| if(mock == nil) 221| 0| [NSException raise:NSInternalInconsistencyException format:@"No partial mock for object %p", self]; 222| 0| return [mock mockedClass]; 223| 0|} 224| | 225| | 226| |- (id)forwardingTargetForSelectorForRealObject:(SEL)sel 227| 0|{ 228| | // in here "self" is a reference to the real object, not the mock 229| 0| OCPartialMockObject *mock = OCMGetAssociatedMockForObject(self); 230| 0| if(mock == nil) 231| 0| [NSException raise:NSInternalInconsistencyException format:@"No partial mock for object %p", self]; 232| 0| if([mock handleSelector:sel]) 233| 0| return self; 234| | 235| 0| return [self ocmock_replaced_forwardingTargetForSelector:sel]; 236| 0|} 237| | 238| |// Make the compiler happy in -forwardingTargetForSelectorForRealObject: because it can't find the message… 239| |- (id)ocmock_replaced_forwardingTargetForSelector:(SEL)sel 240| 0|{ 241| 0| return nil; 242| 0|} 243| | 244| | 245| |- (void)forwardInvocationForRealObject:(NSInvocation *)anInvocation 246| 0|{ 247| | // in here "self" is a reference to the real object, not the mock 248| 0| OCPartialMockObject *mock = OCMGetAssociatedMockForObject(self); 249| 0| if(mock == nil) 250| 0| [NSException raise:NSInternalInconsistencyException format:@"No partial mock for object %p", self]; 251| | 252| 0| if([mock handleInvocation:anInvocation] == NO) 253| 0| { 254| 0| [anInvocation setSelector:OCMAliasForOriginalSelector([anInvocation selector])]; 255| 0| [anInvocation invoke]; 256| 0| } 257| 0|} 258| | 259| | 260| |#pragma mark Verification handling 261| | 262| |- (NSString *)descriptionForVerificationFailureWithMatcher:(OCMInvocationMatcher *)matcher quantifier:(OCMQuantifier *)quantifier invocationCount:(NSUInteger)count 263| 0|{ 264| 0| SEL matcherSel = [[matcher recordedInvocation] selector]; 265| 0| __block BOOL stubbingMightHelp = NO; 266| 0| [NSObject enumerateMethodsInClass:mockedClass usingBlock:^(Class cls, SEL sel) { 267| 0| if(sel == matcherSel) 268| 0| stubbingMightHelp = OCMIsAppleBaseClass(cls) || OCMIsApplePrivateMethod(cls, sel); 269| 0| }]; 270| | 271| 0| NSString *description = [super descriptionForVerificationFailureWithMatcher:matcher quantifier:quantifier invocationCount:count]; 272| 0| if(stubbingMightHelp) 273| 0| { 274| 0| description = [description stringByAppendingFormat:@" Adding a stub for the method may resolve the issue, e.g. `OCMStub([mockObject %@]).andForwardToRealObject()`", [matcher description]]; 275| 0| } 276| 0| return description; 277| 0|} 278| | 279| | 280| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/OCMock/Source/OCMock/OCProtocolMockObject.m: 1| |/* 2| | * Copyright (c) 2005-2020 Erik Doernenburg and contributors 3| | * 4| | * Licensed under the Apache License, Version 2.0 (the "License"); you may 5| | * not use these files except in compliance with the License. You may obtain 6| | * a copy of the License at 7| | * 8| | * http://www.apache.org/licenses/LICENSE-2.0 9| | * 10| | * Unless required by applicable law or agreed to in writing, software 11| | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT 12| | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the 13| | * License for the specific language governing permissions and limitations 14| | * under the License. 15| | */ 16| | 17| |#import 18| |#import "OCProtocolMockObject.h" 19| | 20| | 21| |@implementation OCProtocolMockObject 22| | 23| |#pragma mark Initialisers, description, accessors, etc. 24| | 25| |- (id)initWithProtocol:(Protocol *)aProtocol 26| 0|{ 27| 0| if(aProtocol == nil) 28| 0| [NSException raise:NSInvalidArgumentException format:@"Protocol cannot be nil."]; 29| | 30| 0| [super init]; 31| 0| mockedProtocol = aProtocol; 32| 0| return self; 33| 0|} 34| | 35| |- (NSString *)description 36| 0|{ 37| 0| const char* name = protocol_getName(mockedProtocol); 38| 0| return [NSString stringWithFormat:@"OCProtocolMockObject(%s)", name]; 39| 0|} 40| | 41| |#pragma mark Proxy API 42| | 43| |- (NSMethodSignature *)methodSignatureForSelector:(SEL)aSelector 44| 0|{ 45| 0| struct { BOOL isRequired; BOOL isInstance; } opts[4] = { {YES, YES}, {NO, YES}, {YES, NO}, {NO, NO} }; 46| 0| for(int i = 0; i < 4; i++) 47| 0| { 48| 0| struct objc_method_description methodDescription = protocol_getMethodDescription(mockedProtocol, aSelector, opts[i].isRequired, opts[i].isInstance); 49| 0| if(methodDescription.name != NULL) 50| 0| return [NSMethodSignature signatureWithObjCTypes:methodDescription.types]; 51| 0| } 52| 0| return nil; 53| 0|} 54| | 55| |- (BOOL)conformsToProtocol:(Protocol *)aProtocol 56| 0|{ 57| 0| return protocol_conformsToProtocol(mockedProtocol, aProtocol); 58| 0|} 59| | 60| |- (BOOL)respondsToSelector:(SEL)selector 61| 0|{ 62| 0| return ([self methodSignatureForSelector:selector] != nil); 63| 0|} 64| | 65| |@end <<<<<< EOF # path=OCMock#OCMQuantifier.m.gcov.reduced -: 0:Source:OCMock/OCMQuantifier.m <<<<<< EOF # path=Parse#Internal#ThreadSafety#PFThreadsafety.m.gcov.reduced -: 0:Source:Parse/Internal/ThreadSafety/PFThreadsafety.m <<<<<< EOF # path=Parse#PFEncoder.m.gcov.reduced -: 0:Source:Parse/PFEncoder.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#FBSDKAppEventsConfigurationManager.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsConfigurationManager.m <<<<<< EOF # path=#Applications#Xcode_13.1.app#Contents#Developer#Platforms#iPhoneSimulator.platform#Developer#SDKs#iPhoneSimulator15.0.sdk#usr#include#dispatch#once.h.gcov.reduced -: 0:Source:/Applications/Xcode_13.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator15.0.sdk/usr/include/dispatch/once.h 18:80: 18:82: 18:83: 1:84: 1:85: 17:86: 18:88: 18:89: <<<<<< EOF # path=FBSDKCoreKit#Internal#TokenCaching#FBSDKKeychainStore.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/TokenCaching/FBSDKKeychainStore.m <<<<<< EOF # path=#Applications#Xcode_13.1.app#Contents#Developer#Platforms#iPhoneSimulator.platform#Developer#SDKs#iPhoneSimulator15.0.sdk#usr#include#c++#v1#functional.gcov.reduced -: 0:Source:/Applications/Xcode_13.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator15.0.sdk/usr/include/c++/v1/functional #####:691: #####:692: <<<<<< EOF # path=FBSDKCoreKit#AppLink#FBSDKAppLinkTarget.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppLink/FBSDKAppLinkTarget.m <<<<<< EOF # path=Parse#Internal#Relation#State#PFRelationState.m.gcov.reduced -: 0:Source:Parse/Internal/Relation/State/PFRelationState.m <<<<<< EOF # path=Parse#Internal#File#Controller#PFFileStagingController.h.gcov.reduced -: 0:Source:Parse/Internal/File/Controller/PFFileStagingController.h <<<<<< EOF # path=FBSDKCoreKit#Internal#Network#FBSDKGraphRequestConnectionFactory.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/Network/FBSDKGraphRequestConnectionFactory.m <<<<<< EOF # path=FBSDKCoreKit#Internal#ServerConfiguration#FBSDKServerConfiguration.h.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/ServerConfiguration/FBSDKServerConfiguration.h <<<<<< EOF # path=Parse#Internal#Query#Utilities#PFQueryUtilities.m.gcov.reduced -: 0:Source:Parse/Internal/Query/Utilities/PFQueryUtilities.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#FBSDKTimeSpentRecordingFactory.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/FBSDKTimeSpentRecordingFactory.m <<<<<< EOF # path=Parse#PFGeoPoint.m.gcov.reduced -: 0:Source:Parse/PFGeoPoint.m <<<<<< EOF # path=Parse#Internal#Installation#Controller#PFInstallationController.m.gcov.reduced -: 0:Source:Parse/Internal/Installation/Controller/PFInstallationController.m <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#Internal#LocalDataStore#OfflineQueryLogic#PFOfflineQueryLogic.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/Internal/LocalDataStore/OfflineQueryLogic/PFOfflineQueryLogic.m #####:826: <<<<<< EOF # path=FBSDKCoreKit#FBSDKRandom.m.gcov.reduced -: 0:Source:FBSDKCoreKit/FBSDKRandom.m <<<<<< EOF # path=Parse#Internal#Push#Manager#PFPushManager.m.gcov.reduced -: 0:Source:Parse/Internal/Push/Manager/PFPushManager.m <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#Internal#Object#OperationSet#PFOperationSet.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/Internal/Object/OperationSet/PFOperationSet.m #####:79: <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#PFAnonymousUtils.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/PFAnonymousUtils.m #####:57: <<<<<< EOF # path=OCMock#OCMMacroState.m.gcov.reduced -: 0:Source:OCMock/OCMMacroState.m <<<<<< EOF # path=FBSDKCoreKit#Internal#ServerConfiguration#FBSDKErrorRecoveryConfiguration.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/ServerConfiguration/FBSDKErrorRecoveryConfiguration.m <<<<<< EOF # path=OCMock#OCMExpectationRecorder.m.gcov.reduced -: 0:Source:OCMock/OCMExpectationRecorder.m <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Carthage#Checkouts#facebook-ios-sdk#FBSDKCoreKit#FBSDKCoreKit#Internal#Network#FBSDKGraphRequestPiggybackManager.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKGraphRequestPiggybackManager.m #####:98: <<<<<< EOF # path=FBSDKCoreKit#Internal#FBSDKBackgroundEventLogger.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/FBSDKBackgroundEventLogger.m <<<<<< EOF # path=OCMock#NSObject+OCMAdditions.m.gcov.reduced -: 0:Source:OCMock/NSObject+OCMAdditions.m <<<<<< EOF # path=Parse#Internal#User#State#PFUserState_Private.h.gcov.reduced -: 0:Source:Parse/Internal/User/State/PFUserState_Private.h <<<<<< EOF # path=Parse#Internal#Product#ProductsRequestHandler#PFProductsRequestHandler.h.gcov.reduced -: 0:Source:Parse/Internal/Product/ProductsRequestHandler/PFProductsRequestHandler.h <<<<<< EOF # path=Parse#Internal#Commands#CommandRunner#URLSession#Session#TaskDelegate#PFURLSessionDataTaskDelegate_Private.h.gcov.reduced -: 0:Source:Parse/Internal/Commands/CommandRunner/URLSession/Session/TaskDelegate/PFURLSessionDataTaskDelegate_Private.h <<<<<< EOF # path=Parse#Internal#Query#State#PFQueryState_Private.h.gcov.reduced -: 0:Source:Parse/Internal/Query/State/PFQueryState_Private.h <<<<<< EOF # path=Parse#Internal#Commands#PFRESTPushCommand.m.gcov.reduced -: 0:Source:Parse/Internal/Commands/PFRESTPushCommand.m <<<<<< EOF # path=Parse#Internal#PropertyInfo#PFPropertyInfo.m.gcov.reduced -: 0:Source:Parse/Internal/PropertyInfo/PFPropertyInfo.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#ML#FBSDKModelUtility.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/ML/FBSDKModelUtility.m <<<<<< EOF # path=Parse#Internal#File#Controller#PFFileController.h.gcov.reduced -: 0:Source:Parse/Internal/File/Controller/PFFileController.h <<<<<< EOF # path=Tests#Other#TestCase#PFFacebookTestCase.m.gcov.reduced -: 0:Source:Tests/Other/TestCase/PFFacebookTestCase.m <<<<<< EOF # path=Parse#Internal#Push#State#PFPushState.m.gcov.reduced -: 0:Source:Parse/Internal/Push/State/PFPushState.m <<<<<< EOF # path=FBSDKCoreKit#FBSDKLocation.h.gcov.reduced -: 0:Source:FBSDKCoreKit/FBSDKLocation.h <<<<<< EOF # path=Parse#Internal#Commands#PFRESTAnalyticsCommand.m.gcov.reduced -: 0:Source:Parse/Internal/Commands/PFRESTAnalyticsCommand.m <<<<<< EOF # path=Parse#Internal#Object#Controller#PFObjectController.h.gcov.reduced -: 0:Source:Parse/Internal/Object/Controller/PFObjectController.h <<<<<< EOF # path=Parse#Internal#Object#Subclassing#PFObjectSubclassInfo.m.gcov.reduced -: 0:Source:Parse/Internal/Object/Subclassing/PFObjectSubclassInfo.m <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Carthage#Checkouts#facebook-ios-sdk#FBSDKCoreKit#FBSDKCoreKit#FBSDKBridgeAPI.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKBridgeAPI.m #####:295: <<<<<< EOF # path=FBSDKCoreKit#Internal#Network#FBSDKGraphRequestMetadata.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/Network/FBSDKGraphRequestMetadata.m <<<<<< EOF # path=FBSDKCoreKit#FBSDKAuthenticationToken.m.gcov.reduced -: 0:Source:FBSDKCoreKit/FBSDKAuthenticationToken.m <<<<<< EOF # path=Parse#Internal#File#FileDataStream#PFFileDataStream.m.gcov.reduced -: 0:Source:Parse/Internal/File/FileDataStream/PFFileDataStream.m <<<<<< EOF # path=#Applications#Xcode_13.1.app#Contents#Developer#Platforms#iPhoneSimulator.platform#Developer#SDKs#iPhoneSimulator15.0.sdk#usr#include#c++#v1#limits.gcov.reduced -: 0:Source:/Applications/Xcode_13.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator15.0.sdk/usr/include/c++/v1/limits #####:214: #####:451: <<<<<< EOF # path=Bolts#Common#BFTask.m.gcov.reduced -: 0:Source:Bolts/Common/BFTask.m <<<<<< EOF # path=FBSDKCoreKit#FBSDKAuthenticationTokenClaims.m.gcov.reduced -: 0:Source:FBSDKCoreKit/FBSDKAuthenticationTokenClaims.m <<<<<< EOF # path=FBSDKLoginKit#Internal#FBSDKLoginCompletion.m.gcov.reduced -: 0:Source:FBSDKLoginKit/Internal/FBSDKLoginCompletion.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#SKAdNetwork#FBSDKSKAdNetworkConversionConfiguration.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/SKAdNetwork/FBSDKSKAdNetworkConversionConfiguration.m <<<<<< EOF # path=Bolts#Common#BFExecutor.m.gcov.reduced -: 0:Source:Bolts/Common/BFExecutor.m <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Carthage#Checkouts#facebook-ios-sdk#FBSDKLoginKit#FBSDKLoginKit#Internal#FBSDKLoginCompletion.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKLoginCompletion.m #####:236: <<<<<< EOF # path=#Applications#Xcode_13.1.app#Contents#Developer#Platforms#iPhoneSimulator.platform#Developer#SDKs#iPhoneSimulator15.0.sdk#usr#include#c++#v1#memory.gcov.reduced -: 0:Source:/Applications/Xcode_13.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator15.0.sdk/usr/include/c++/v1/memory #####:749: #####:750: #####:752: 2:836: 2:856: #####:860: #####:863: #####:864: #####:865: #####:870: #####:875: #####:879: #####:881: #####:909: #####:910: #####:915: #####:916: #####:917: #####:920: #####:921: #####:922: #####:1061: #####:1062: #####:1063: #####:1064: #####:1065: #####:1066: #####:1067: #####:1092: #####:1093: #####:1094: #####:1095: #####:1096: #####:1097: 1:1250: 1:1252: 4:1259: 4:1260: 4:1261: 4:1262: 3:1274: #####:1276: 3:1291: 1:1293: #####:1300: #####:1301: #####:1302: 1:1312: #####:1314: 2:1340: 8:1344: 8:1345: 3:1359: 3:1360: #####:1364: #####:1365: 1:1369: 1:1370: #####:1374: #####:1375: #####:1572: #####:1573: #####:1576: #####:1643: #####:1657: #####:1658: #####:1661: #####:1662: #####:1665: #####:1666: #####:1678: #####:1679: #####:1680: #####:1681: #####:1685: #####:1686: #####:1687: #####:1688: #####:1689: #####:1690: 2:1774: #####:1814: #####:1815: #####:1818: 2:1866: #####:1876: #####:1877: #####:1885: #####:1886: #####:1890: #####:1891: #####:1899: #####:1900: #####:1901: #####:1902: #####:1910: #####:1911: #####:1912: #####:1913: #####:1914: #####:1915: 1:1918: 1:1919: 1:1920: 1:1921: #####:1922: 1:1923: #####:2436: #####:2437: #####:2439: #####:2447: #####:2448: #####:2450: #####:2491: #####:2492: #####:2500: #####:2501: #####:2502: #####:2504: #####:2505: #####:2506: #####:2507: #####:2509: #####:2510: #####:2525: #####:2526: #####:2527: #####:2539: #####:2540: #####:2541: #####:2547: #####:2548: #####:2549: #####:2550: #####:2569: #####:2570: #####:2585: #####:2586: #####:2587: #####:2594: #####:2595: #####:2596: #####:2597: #####:2598: #####:2602: #####:2603: #####:2608: #####:2609: #####:2610: #####:2611: #####:2863: #####:2954: #####:2982: #####:2983: #####:2984: #####:2985: #####:2986: #####:3013: #####:3015: #####:3016: #####:3023: #####:3024: #####:3026: #####:3029: #####:3030: #####:3031: #####:3033: #####:3124: #####:3125: #####:3126: #####:3127: #####:3128: #####:3129: #####:3130: #####:3147: #####:3148: #####:3149: #####:3150: #####:3151: #####:3152: #####:3153: #####:3235: #####:3236: #####:3237: #####:3238: #####:3239: #####:3267: #####:3268: #####:3269: #####:3270: #####:3322: #####:3323: #####:3324: #####:3325: #####:3326: #####:3357: #####:3358: #####:3359: #####:3360: <<<<<< EOF # path=Parse#Internal#Analytics#Controller#PFAnalyticsController.h.gcov.reduced -: 0:Source:Parse/Internal/Analytics/Controller/PFAnalyticsController.h <<<<<< EOF # path=Parse#Internal#FieldOperation#PFFieldOperation.m.gcov.reduced -: 0:Source:Parse/Internal/FieldOperation/PFFieldOperation.m <<<<<< EOF # path=OCMock#OCMFunctions.m.gcov.reduced -: 0:Source:OCMock/OCMFunctions.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#Integrity#FBSDKRestrictiveDataFilterManager.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/Integrity/FBSDKRestrictiveDataFilterManager.m <<<<<< EOF # path=Parse#Internal#ParseModule.m.gcov.reduced -: 0:Source:Parse/Internal/ParseModule.m <<<<<< EOF # path=Parse#Internal#Object#LocalIdStore#PFObjectLocalIdStore.h.gcov.reduced -: 0:Source:Parse/Internal/Object/LocalIdStore/PFObjectLocalIdStore.h <<<<<< EOF # path=FBSDKCoreKit#GraphAPI#FBSDKGraphErrorRecoveryProcessor.m.gcov.reduced -: 0:Source:FBSDKCoreKit/GraphAPI/FBSDKGraphErrorRecoveryProcessor.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#AAM#FBSDKMetadataIndexer.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/AAM/FBSDKMetadataIndexer.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#AEM#FBSDKAEMReporter.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMReporter.m <<<<<< EOF # path=OCMock#OCMBlockArgCaller.m.gcov.reduced -: 0:Source:OCMock/OCMBlockArgCaller.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#SKAdNetwork#FBSDKSKAdNetworkRule.h.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/SKAdNetwork/FBSDKSKAdNetworkRule.h <<<<<< EOF # path=Parse#Internal#User#Coder#File#PFUserFileCodingLogic.m.gcov.reduced -: 0:Source:Parse/Internal/User/Coder/File/PFUserFileCodingLogic.m <<<<<< EOF # path=Parse#Internal#PFFileManager.m.gcov.reduced -: 0:Source:Parse/Internal/PFFileManager.m <<<<<< EOF # path=Parse#PFPush.m.gcov.reduced -: 0:Source:Parse/PFPush.m <<<<<< EOF # path=Parse#PFInstallation.m.gcov.reduced -: 0:Source:Parse/PFInstallation.m <<<<<< EOF # path=Parse#Internal#PFCoreManager.h.gcov.reduced -: 0:Source:Parse/Internal/PFCoreManager.h <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#Internal#Commands#CommandRunner#URLSession#Session#PFURLSession.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/Internal/Commands/CommandRunner/URLSession/Session/PFURLSession.m #####:101: <<<<<< EOF # path=Parse#Internal#PFEventuallyQueue.h.gcov.reduced -: 0:Source:Parse/Internal/PFEventuallyQueue.h <<<<<< EOF # path=FBSDKCoreKit#FBSDKBridgeAPI.h.gcov.reduced -: 0:Source:FBSDKCoreKit/FBSDKBridgeAPI.h <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#AEM#FBSDKAEMAdvertiserSingleEntryRule.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMAdvertiserSingleEntryRule.m <<<<<< EOF # path=Parse#Internal#Push#Controller#PFPushController.m.gcov.reduced -: 0:Source:Parse/Internal/Push/Controller/PFPushController.m <<<<<< EOF # path=#Applications#Xcode_13.1.app#Contents#Developer#Platforms#iPhoneSimulator.platform#Developer#SDKs#iPhoneSimulator15.0.sdk#usr#include#c++#v1#__string.gcov.reduced -: 0:Source:/Applications/Xcode_13.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator15.0.sdk/usr/include/c++/v1/__string #####:372: #####:412: #####:413: #####:414: #####:415: #####:417: #####:430: #####:1157: #####:1158: #####:1160: <<<<<< EOF # path=FBSDKCoreKit#FBSDKUserAgeRange.h.gcov.reduced -: 0:Source:FBSDKCoreKit/FBSDKUserAgeRange.h <<<<<< EOF # path=Parse#Internal#Push#Utilites#PFPushUtilities.m.gcov.reduced -: 0:Source:Parse/Internal/Push/Utilites/PFPushUtilities.m <<<<<< EOF # path=Parse#Internal#LocalDataStore#SQLite#PFSQLiteDatabase.m.gcov.reduced -: 0:Source:Parse/Internal/LocalDataStore/SQLite/PFSQLiteDatabase.m <<<<<< EOF # path=Parse#ParseClientConfiguration.h.gcov.reduced -: 0:Source:Parse/ParseClientConfiguration.h <<<<<< EOF # path=Parse#PFACL.m.gcov.reduced -: 0:Source:Parse/PFACL.m <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#Internal#PFAlertView.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/Internal/PFAlertView.m #####:30: <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#Internal#ParseManager.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/Internal/ParseManager.m #####:145: <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Carthage#Checkouts#facebook-ios-sdk#Sources#FBSDKCoreKit_Basics#FBSDKURLSession.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKURLSession.m 2:33: 2:36: 2:37: 2:38: 2:39: 2:40: 2:41: 1:43: 1:46: 2:47: 1:48: 1:49: 1:50: 1:51: #####:52: #####:53: #####:54: 1:55: 1:57: 1:59: 2:60: 1:61: 1:62: 1:63: 1:64: 1:65: 4:67: 4:69: 4:70: 4:71: 2:73: 2:75: <<<<<< EOF # path=Parse#Internal#Commands#PFRESTCommand.m.gcov.reduced -: 0:Source:Parse/Internal/Commands/PFRESTCommand.m <<<<<< EOF # path=FBSDKCoreKit#FBSDKURL.h.gcov.reduced -: 0:Source:FBSDKCoreKit/FBSDKURL.h <<<<<< EOF # path=Parse#Internal#Commands#PFRESTUserCommand.m.gcov.reduced -: 0:Source:Parse/Internal/Commands/PFRESTUserCommand.m <<<<<< EOF # path=FBSDKCoreKit#FBSDKProfile.m.gcov.reduced -: 0:Source:FBSDKCoreKit/FBSDKProfile.m <<<<<< EOF # path=Parse#Internal#Object#EstimatedData#PFObjectEstimatedData.m.gcov.reduced -: 0:Source:Parse/Internal/Object/EstimatedData/PFObjectEstimatedData.m <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#Internal#Installation#CurrentInstallationController#PFCurrentInstallationController.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/Internal/Installation/CurrentInstallationController/PFCurrentInstallationController.m #####:104: <<<<<< EOF # path=Parse#Internal#PFReachability.m.gcov.reduced -: 0:Source:Parse/Internal/PFReachability.m <<<<<< EOF # path=OCMock#OCMExceptionReturnValueProvider.m.gcov.reduced -: 0:Source:OCMock/OCMExceptionReturnValueProvider.m <<<<<< EOF # path=Parse#Internal#Push#ChannelsController#PFPushChannelsController.m.gcov.reduced -: 0:Source:Parse/Internal/Push/ChannelsController/PFPushChannelsController.m <<<<<< EOF # path=Parse#Internal#ACL#State#PFACLState.h.gcov.reduced -: 0:Source:Parse/Internal/ACL/State/PFACLState.h <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#Internal#Object#Subclassing#PFObjectSubclassInfo.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/Internal/Object/Subclassing/PFObjectSubclassInfo.m #####:102: <<<<<< EOF # path=Parse#Internal#PFCommandResult.h.gcov.reduced -: 0:Source:Parse/Internal/PFCommandResult.h <<<<<< EOF # path=FBSDKCoreKit#Internal#Network#FBSDKGraphRequestPiggybackManager.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/Network/FBSDKGraphRequestPiggybackManager.m <<<<<< EOF # path=Parse#Internal#Persistence#PFPersistenceController.m.gcov.reduced -: 0:Source:Parse/Internal/Persistence/PFPersistenceController.m <<<<<< EOF # path=Parse#Internal#Commands#PFRESTFileCommand.m.gcov.reduced -: 0:Source:Parse/Internal/Commands/PFRESTFileCommand.m <<<<<< EOF # path=#Applications#Xcode_13.1.app#Contents#Developer#Platforms#iPhoneSimulator.platform#Developer#SDKs#iPhoneSimulator15.0.sdk#usr#include#c++#v1#__memory#allocator_traits.h.gcov.reduced -: 0:Source:/Applications/Xcode_13.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator15.0.sdk/usr/include/c++/v1/__memory/allocator_traits.h #####:259: #####:260: #####:279: #####:280: #####:281: #####:286: #####:288: #####:290: #####:305: #####:307: #####:309: #####:313: #####:317: #####:319: #####:324: #####:326: #####:345: #####:346: <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#FBSDKAppEventsStateManager.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsStateManager.m <<<<<< EOF # path=Bolts#Common#BFCancellationToken.m.gcov.reduced -: 0:Source:Bolts/Common/BFCancellationToken.m <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#Internal#Commands#PFRESTCommand.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/Internal/Commands/PFRESTCommand.m #####:192: <<<<<< EOF # path=Parse#Internal#Object#Subclassing#PFObjectSubclassingController.m.gcov.reduced -: 0:Source:Parse/Internal/Object/Subclassing/PFObjectSubclassingController.m <<<<<< EOF # path=Parse#Internal#Config#Controller#PFCurrentConfigController.h.gcov.reduced -: 0:Source:Parse/Internal/Config/Controller/PFCurrentConfigController.h <<<<<< EOF # path=OCMock#OCMockObject.m.gcov.reduced -: 0:Source:OCMock/OCMockObject.m <<<<<< EOF # path=Parse#Internal#Object#PinningStore#PFPinningObjectStore.m.gcov.reduced -: 0:Source:Parse/Internal/Object/PinningStore/PFPinningObjectStore.m <<<<<< EOF # path=#Applications#Xcode_13.1.app#Contents#Developer#Platforms#iPhoneSimulator.platform#Developer#SDKs#iPhoneSimulator15.0.sdk#System#Library#Frameworks#Foundation.framework#Headers#NSObject.h.gcov.reduced -: 0:Source:/Applications/Xcode_13.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator15.0.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSObject.h #####:109: #####:110: <<<<<< EOF # path=OCMock#OCMNotificationPoster.m.gcov.reduced -: 0:Source:OCMock/OCMNotificationPoster.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#FBSDKAppEventsAtePublisher.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsAtePublisher.m <<<<<< EOF # path=Parse#Internal#ParseManager.h.gcov.reduced -: 0:Source:Parse/Internal/ParseManager.h <<<<<< EOF # path=Parse#Internal#Query#State#PFQueryState.h.gcov.reduced -: 0:Source:Parse/Internal/Query/State/PFQueryState.h <<<<<< EOF # path=#Applications#Xcode_13.1.app#Contents#Developer#Platforms#iPhoneSimulator.platform#Developer#SDKs#iPhoneSimulator15.0.sdk#usr#include#c++#v1#type_traits.gcov.reduced -: 0:Source:/Applications/Xcode_13.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator15.0.sdk/usr/include/c++/v1/type_traits #####:2567: #####:2568: #####:2570: 12:2576: 12:2577: 12:2578: #####:3948: #####:3950: #####:3951: #####:3952: #####:3953: #####:3954: <<<<<< EOF # path=ParseFacebookUtils#Internal#AuthenticationProvider#iOS#PFFacebookMobileAuthenticationProvider_Private.h.gcov.reduced -: 0:Source:ParseFacebookUtils/Internal/AuthenticationProvider/iOS/PFFacebookMobileAuthenticationProvider_Private.h <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#Internal#Push#Manager#PFPushManager.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/Internal/Push/Manager/PFPushManager.m #####:54: <<<<<< EOF # path=FBSDKCoreKit#Internal#FBSDKInternalUtility.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/FBSDKInternalUtility.m <<<<<< EOF # path=Parse#Parse.m.gcov.reduced -: 0:Source:Parse/Parse.m <<<<<< EOF # path=Parse#Internal#User#CurrentUserController#PFCurrentUserController.m.gcov.reduced -: 0:Source:Parse/Internal/User/CurrentUserController/PFCurrentUserController.m <<<<<< EOF # path=FBSDKCoreKit#GraphAPI#FBSDKGraphRequestConnection.h.gcov.reduced -: 0:Source:FBSDKCoreKit/GraphAPI/FBSDKGraphRequestConnection.h <<<<<< EOF # path=Parse#Internal#Session#Controller#PFSessionController.h.gcov.reduced -: 0:Source:Parse/Internal/Session/Controller/PFSessionController.h <<<<<< EOF # path=Parse#Internal#LocalDataStore#OfflineStore#PFOfflineStore.m.gcov.reduced -: 0:Source:Parse/Internal/LocalDataStore/OfflineStore/PFOfflineStore.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#FBSDKProductRequestFactory.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/FBSDKProductRequestFactory.m <<<<<< EOF # path=Parse#Internal#FieldOperation#PFFieldOperationDecoder.m.gcov.reduced -: 0:Source:Parse/Internal/FieldOperation/PFFieldOperationDecoder.m <<<<<< EOF # path=#Applications#Xcode_13.1.app#Contents#Developer#Platforms#iPhoneSimulator.platform#Developer#SDKs#iPhoneSimulator15.0.sdk#usr#include#c++#v1#__hash_table.gcov.reduced -: 0:Source:/Applications/Xcode_13.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator15.0.sdk/usr/include/c++/v1/__hash_table #####:72: #####:73: #####:74: #####:78: #####:79: #####:80: #####:84: #####:85: 2:88: #####:106: #####:107: #####:108: #####:113: #####:114: #####:115: #####:116: #####:121: #####:122: #####:123: #####:172: #####:173: #####:193: #####:194: #####:371: #####:372: #####:373: #####:450: #####:453: #####:457: #####:460: #####:461: #####:473: #####:474: #####:475: #####:478: #####:479: #####:491: #####:492: #####:493: 2:782: 2:784: #####:787: #####:789: #####:792: #####:794: #####:795: #####:796: #####:797: #####:800: #####:802: #####:805: #####:807: #####:810: #####:811: #####:812: #####:813: #####:839: #####:841: #####:842: #####:843: #####:846: #####:847: #####:848: #####:849: #####:850: #####:851: #####:852: #####:966: #####:969: #####:972: #####:974: #####:977: #####:982: #####:984: 1:987: #####:989: #####:990: 1:999: #####:1153: #####:1154: #####:1193: #####:1194: #####:1195: #####:1367: #####:1372: #####:1373: #####:1375: #####:1379: #####:1380: #####:1381: #####:1382: #####:1383: 2:1396: 1:1403: 1:1404: 2:1405: 2:1406: #####:1440: #####:1441: #####:1442: #####:1444: #####:1445: #####:1446: #####:1447: #####:1448: #####:1449: #####:1450: 2:1510: 2:1511: 1:1519: 2:1523: 1:1557: 1:1559: 1:1560: 1:1561: #####:1563: #####:1579: #####:1580: #####:1581: #####:1582: 1:1584: #####:1601: #####:1607: #####:1608: #####:1609: #####:1610: #####:1611: #####:1612: #####:1613: #####:1614: #####:1615: #####:1616: #####:1617: #####:1618: #####:1620: #####:1621: #####:1622: #####:1623: #####:1624: #####:1628: #####:1681: #####:1687: #####:1688: #####:1690: #####:1799: #####:1800: #####:1804: #####:1811: #####:1812: #####:1816: #####:1822: #####:1823: #####:1824: #####:1826: #####:1827: #####:1828: #####:1829: #####:1830: #####:1831: #####:1832: #####:1833: #####:2069: #####:2070: #####:2072: #####:2073: #####:2074: #####:2077: #####:2079: #####:2080: #####:2081: #####:2083: #####:2084: #####:2085: #####:2087: #####:2088: #####:2089: #####:2090: #####:2091: #####:2093: #####:2094: #####:2096: #####:2097: #####:2098: #####:2099: #####:2100: #####:2102: #####:2103: #####:2105: #####:2106: #####:2107: #####:2109: #####:2110: #####:2111: #####:2112: #####:2113: #####:2116: #####:2117: #####:2119: #####:2121: #####:2122: #####:2123: #####:2128: #####:2130: #####:2306: #####:2308: #####:2309: #####:2310: #####:2311: #####:2312: #####:2313: #####:2314: #####:2315: #####:2316: #####:2318: #####:2321: #####:2322: #####:2324: #####:2325: #####:2326: #####:2327: #####:2331: #####:2332: #####:2336: #####:2337: #####:2338: #####:2339: #####:2340: #####:2342: #####:2343: #####:2344: #####:2345: #####:2346: #####:2348: #####:2349: #####:2350: #####:2351: #####:2352: #####:2354: #####:2355: #####:2356: #####:2359: #####:2361: #####:2362: #####:2363: #####:2364: #####:2367: #####:2368: #####:2369: #####:2370: #####:2371: #####:2373: #####:2374: #####:2375: #####:2379: #####:2380: #####:2381: #####:2382: #####:2418: #####:2419: #####:2420: #####:2421: #####:2422: #####:2424: #####:2425: #####:2426: #####:2428: #####:2429: #####:2430: #####:2431: #####:2433: #####:2434: #####:2438: #####:2440: #####:2441: #####:2443: #####:2444: #####:2445: #####:2466: #####:2468: #####:2471: #####:2472: #####:2473: #####:2474: #####:2476: #####:2477: #####:2478: #####:2479: #####:2480: <<<<<< EOF # path=Parse#Internal#ACL#DefaultACLController#PFDefaultACLController.h.gcov.reduced -: 0:Source:Parse/Internal/ACL/DefaultACLController/PFDefaultACLController.h <<<<<< EOF # path=FBSDKLoginKit#FBSDKLoginConfiguration.m.gcov.reduced -: 0:Source:FBSDKLoginKit/FBSDKLoginConfiguration.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#AEM#FBSDKAEMEvent.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMEvent.m <<<<<< EOF # path=FBSDKCoreKit#Internal#Instrument#FBSDKInstrumentManager.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/Instrument/FBSDKInstrumentManager.m <<<<<< EOF # path=Parse#Internal#PFSystemLogger.h.gcov.reduced -: 0:Source:Parse/Internal/PFSystemLogger.h <<<<<< EOF # path=FBSDKCoreKit#FBSDKAccessToken.h.gcov.reduced -: 0:Source:FBSDKCoreKit/FBSDKAccessToken.h <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#SuggestedEvents#FBSDKFeatureExtractor.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/SuggestedEvents/FBSDKFeatureExtractor.m <<<<<< EOF # path=Parse#Internal#Persistence#Group#PFFilePersistenceGroup.m.gcov.reduced -: 0:Source:Parse/Internal/Persistence/Group/PFFilePersistenceGroup.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#AEM#FBSDKAEMConfiguration.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMConfiguration.m <<<<<< EOF # path=OCMock#NSValue+OCMAdditions.m.gcov.reduced -: 0:Source:OCMock/NSValue+OCMAdditions.m <<<<<< EOF # path=FBSDKLoginKit#FBSDKLoginManager.m.gcov.reduced -: 0:Source:FBSDKLoginKit/FBSDKLoginManager.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#Codeless#FBSDKEventBindingManager.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/Codeless/FBSDKEventBindingManager.m <<<<<< EOF # path=Parse#Internal#Commands#CommandRunner#URLSession#PFURLSessionCommandRunner.m.gcov.reduced -: 0:Source:Parse/Internal/Commands/CommandRunner/URLSession/PFURLSessionCommandRunner.m <<<<<< EOF # path=ParseFacebookUtils#Internal#AuthenticationProvider#iOS#PFFacebookMobileAuthenticationProvider.m.gcov.reduced -: 0:Source:ParseFacebookUtils/Internal/AuthenticationProvider/iOS/PFFacebookMobileAuthenticationProvider.m <<<<<< EOF # path=FBSDKCoreKit#Internal#UI#FBSDKCloseIcon.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/UI/FBSDKCloseIcon.m <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#Internal#Config#Controller#PFConfigController.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/Internal/Config/Controller/PFConfigController.m #####:78: <<<<<< EOF # path=Parse#Internal#PFAlertView.m.gcov.reduced -: 0:Source:Parse/Internal/PFAlertView.m <<<<<< EOF # path=#Applications#Xcode_13.1.app#Contents#Developer#Platforms#iPhoneSimulator.platform#Developer#SDKs#iPhoneSimulator15.0.sdk#usr#include#c++#v1#math.h.gcov.reduced -: 0:Source:/Applications/Xcode_13.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator15.0.sdk/usr/include/c++/v1/math.h #####:830: #####:1213: <<<<<< EOF # path=FBSDKCoreKit#Internal#WebDialog#FBSDKWebDialogView.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/WebDialog/FBSDKWebDialogView.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#SuggestedEvents#FBSDKSuggestedEventsIndexer.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/SuggestedEvents/FBSDKSuggestedEventsIndexer.m <<<<<< EOF # path=Parse#Internal#PFMulticastDelegate.m.gcov.reduced -: 0:Source:Parse/Internal/PFMulticastDelegate.m <<<<<< EOF # path=Parse#Internal#Analytics#Utilities#PFAnalyticsUtilities.m.gcov.reduced -: 0:Source:Parse/Internal/Analytics/Utilities/PFAnalyticsUtilities.m <<<<<< EOF # path=Parse#Internal#PFBase64Encoder.m.gcov.reduced -: 0:Source:Parse/Internal/PFBase64Encoder.m <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Carthage#Checkouts#facebook-ios-sdk#FBSDKCoreKit#FBSDKCoreKit#AppEvents#Internal#ML#FBSDKModelManager.mm.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/ML/FBSDKModelManager.mm 1:53: <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#Internal#User#CurrentUserController#PFCurrentUserController.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/Internal/User/CurrentUserController/PFCurrentUserController.m #####:100: <<<<<< EOF # path=OCMock#OCMObjectReturnValueProvider.m.gcov.reduced -: 0:Source:OCMock/OCMObjectReturnValueProvider.m <<<<<< EOF # path=Parse#PFFileObject.m.gcov.reduced -: 0:Source:Parse/PFFileObject.m <<<<<< EOF # path=FBSDKCoreKit#Internal#Network#FBSDKGraphRequestPiggybackManagerProvider.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/Network/FBSDKGraphRequestPiggybackManagerProvider.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#Codeless#FBSDKCodelessPathComponent.h.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/Codeless/FBSDKCodelessPathComponent.h <<<<<< EOF # path=Parse#Internal#PFCommandCache.h.gcov.reduced -: 0:Source:Parse/Internal/PFCommandCache.h <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Carthage#Checkouts#facebook-ios-sdk#Sources#FBSDKCoreKit_Basics#FBSDKUserDataStore.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKUserDataStore.m #####:51: #####:53: #####:54: #####:55: #####:56: #####:57: #####:59: #####:71: #####:72: #####:73: #####:74: #####:75: #####:76: #####:77: #####:78: #####:79: #####:80: #####:81: #####:82: #####:83: #####:84: #####:85: #####:86: #####:87: #####:88: #####:89: #####:90: #####:91: #####:92: #####:93: #####:94: #####:95: #####:96: #####:97: #####:98: #####:99: #####:100: #####:101: #####:102: #####:103: #####:104: #####:106: #####:107: #####:108: #####:110: #####:111: #####:113: #####:116: #####:117: #####:118: #####:120: #####:123: #####:124: #####:125: #####:126: #####:127: #####:129: #####:131: #####:132: #####:134: #####:137: #####:138: #####:139: #####:140: #####:141: #####:143: #####:145: #####:146: #####:148: #####:150: #####:151: #####:152: #####:153: #####:155: #####:157: #####:158: #####:160: #####:162: #####:165: #####:167: #####:168: #####:169: #####:170: #####:171: #####:172: #####:173: #####:174: #####:175: #####:176: #####:177: #####:178: #####:179: #####:181: #####:183: #####:194: #####:196: #####:198: #####:199: #####:200: #####:201: #####:202: #####:203: #####:207: #####:209: #####:210: #####:211: #####:212: #####:215: #####:216: #####:217: #####:218: #####:219: #####:220: #####:222: #####:224: #####:225: #####:228: #####:229: #####:232: #####:234: #####:236: #####:239: #####:240: #####:242: #####:243: #####:245: #####:248: #####:249: #####:250: #####:251: #####:252: #####:253: #####:254: #####:255: #####:256: #####:260: #####:262: #####:265: #####:266: #####:267: #####:268: #####:269: #####:270: #####:271: #####:272: #####:273: #####:275: #####:277: #####:278: #####:279: <<<<<< EOF # path=OCMock#OCMVerifier.h.gcov.reduced -: 0:Source:OCMock/OCMVerifier.h <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#Internal#PFPinningEventuallyQueue.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/Internal/PFPinningEventuallyQueue.m #####:273: <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#Codeless#FBSDKCodelessParameterComponent.h.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/Codeless/FBSDKCodelessParameterComponent.h <<<<<< EOF # path=Parse#Internal#User#State#PFUserState.h.gcov.reduced -: 0:Source:Parse/Internal/User/State/PFUserState.h <<<<<< EOF # path=Parse#Internal#PropertyInfo#PFPropertyInfo_Runtime.m.gcov.reduced -: 0:Source:Parse/Internal/PropertyInfo/PFPropertyInfo_Runtime.m <<<<<< EOF # path=Parse#Internal#CloudCode#PFCloudCodeController.h.gcov.reduced -: 0:Source:Parse/Internal/CloudCode/PFCloudCodeController.h <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#PFFileObject.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/PFFileObject.m #####:263: <<<<<< EOF # path=Parse#Internal#PFApplication.m.gcov.reduced -: 0:Source:Parse/Internal/PFApplication.m <<<<<< EOF # path=OCMock#OCProtocolMockObject.m.gcov.reduced -: 0:Source:OCMock/OCProtocolMockObject.m <<<<<< EOF # path=Parse#Internal#Commands#PFRESTSessionCommand.m.gcov.reduced -: 0:Source:Parse/Internal/Commands/PFRESTSessionCommand.m <<<<<< EOF # path=FBSDKCoreKit#FBSDKImpressionTrackingButton.m.gcov.reduced -: 0:Source:FBSDKCoreKit/FBSDKImpressionTrackingButton.m <<<<<< EOF # path=Parse#Internal#Object#OperationSet#PFOperationSet.h.gcov.reduced -: 0:Source:Parse/Internal/Object/OperationSet/PFOperationSet.h <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#FBSDKAppEventsState.h.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsState.h <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#FBSDKAppEventsConfiguration.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsConfiguration.m <<<<<< EOF # path=Parse#Internal#Query#Controller#PFQueryController.m.gcov.reduced -: 0:Source:Parse/Internal/Query/Controller/PFQueryController.m <<<<<< EOF # path=Parse#Internal#PropertyInfo#PFPropertyInfo_Private.h.gcov.reduced -: 0:Source:Parse/Internal/PropertyInfo/PFPropertyInfo_Private.h <<<<<< EOF # path=FBSDKCoreKit#Internal#WebDialog#FBSDKWebViewFactory.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/WebDialog/FBSDKWebViewFactory.m <<<<<< EOF # path=FBSDKCoreKit#FBSDKMeasurementEvent.m.gcov.reduced -: 0:Source:FBSDKCoreKit/FBSDKMeasurementEvent.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#Integrity#FBSDKIntegrityManager.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/Integrity/FBSDKIntegrityManager.m <<<<<< EOF # path=OCMock#OCMNonRetainingObjectReturnValueProvider.m.gcov.reduced -: 0:Source:OCMock/OCMNonRetainingObjectReturnValueProvider.m <<<<<< EOF # path=Parse#Internal#LocalDataStore#Pin#PFPin.m.gcov.reduced -: 0:Source:Parse/Internal/LocalDataStore/Pin/PFPin.m <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#Internal#PFEventuallyQueue.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/Internal/PFEventuallyQueue.m #####:237: <<<<<< EOF # path=OCMock#NSInvocation+OCMAdditions.m.gcov.reduced -: 0:Source:OCMock/NSInvocation+OCMAdditions.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#Codeless#FBSDKEventBinding.h.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/Codeless/FBSDKEventBinding.h <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Carthage#Checkouts#facebook-ios-sdk#Sources#FBSDKCoreKit_Basics#FBSDKTypeUtility.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKTypeUtility.m 13:25: 13:27: 13:28: 11:30: 11:32: 11:33: #####:36: 11:37: 14:39: 14:41: 10:42: 10:43: 14:44: #####:46: #####:48: #####:49: #####:50: #####:51: #####:52: #####:53: #####:54: #####:55: #####:57: #####:59: #####:61: #####:62: #####:64: #####:66: #####:68: 131:70: 131:72: 131:73: 92:75: 92:77: 92:79: 52:80: 40:82: 92:84: 85:86: 85:88: 69:89: 69:90: 85:91: 7:93: 7:95: 7:96: 7:97: 7:98: 7:99: 3:101: 3:103: 3:104: #####:106: #####:108: #####:109: #####:110: #####:111: #####:113: #####:115: 2:117: 2:119: 2:120: #####:122: #####:124: #####:125: 9:127: 9:129: 8:130: 1:131: #####:132: 1:133: #####:134: 1:136: 9:138: #####:140: #####:142: #####:143: #####:144: #####:145: #####:147: #####:149: #####:151: #####:153: #####:154: #####:158: #####:159: #####:160: #####:161: #####:162: #####:164: #####:166: #####:168: #####:169: #####:170: #####:171: #####:173: #####:175: 1:177: 1:179: 1:180: 1:182: 1:184: 1:187: #####:188: #####:189: 1:190: 1:191: 1:192: 1:194: 1:196: #####:197: 1:200: 1:202: #####:203: #####:204: 1:205: 1:206: 1:207: 149:211: 149:213: 149:214: <<<<<< EOF # path=Parse#Internal#LocalDataStore#SQLite#PFSQLiteDatabaseResult.m.gcov.reduced -: 0:Source:Parse/Internal/LocalDataStore/SQLite/PFSQLiteDatabaseResult.m <<<<<< EOF # path=Parse#Internal#Persistence#Group#PFUserDefaultsPersistenceGroup.h.gcov.reduced -: 0:Source:Parse/Internal/Persistence/Group/PFUserDefaultsPersistenceGroup.h <<<<<< EOF # path=Parse#Internal#Object#State#PFObjectState.m.gcov.reduced -: 0:Source:Parse/Internal/Object/State/PFObjectState.m <<<<<< EOF # path=OCMock#OCMBlockCaller.m.gcov.reduced -: 0:Source:OCMock/OCMBlockCaller.m <<<<<< EOF # path=FBSDKLoginKit#Internal#FBSDKLoginUtility.m.gcov.reduced -: 0:Source:FBSDKLoginKit/Internal/FBSDKLoginUtility.m <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#Internal#LocalDataStore#SQLite#PFSQLiteDatabaseResult.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/Internal/LocalDataStore/SQLite/PFSQLiteDatabaseResult.m #####:96: <<<<<< EOF # path=Parse#Internal#Installation#CurrentInstallationController#PFCurrentInstallationController.m.gcov.reduced -: 0:Source:Parse/Internal/Installation/CurrentInstallationController/PFCurrentInstallationController.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#ML#FBSDKModelRuntime.hpp.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/ML/FBSDKModelRuntime.hpp <<<<<< EOF # path=FBSDKCoreKit#Internal#FBSDKLogger.h.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/FBSDKLogger.h <<<<<< EOF # path=FBSDKCoreKit#AppLink#FBSDKAppLinkUtility.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppLink/FBSDKAppLinkUtility.m <<<<<< EOF # path=FBSDKCoreKit#Internal#FBSDKContainerViewController.h.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/FBSDKContainerViewController.h <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#SKAdNetwork#FBSDKSKAdNetworkEvent.h.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/SKAdNetwork/FBSDKSKAdNetworkEvent.h <<<<<< EOF # path=FBSDKCoreKit#AppLink#FBSDKAppLink.h.gcov.reduced -: 0:Source:FBSDKCoreKit/AppLink/FBSDKAppLink.h <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Carthage#Checkouts#facebook-ios-sdk#FBSDKCoreKit#FBSDKCoreKit#AppEvents#FBSDKAppEvents.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/FBSDKAppEvents.m #####:1187: <<<<<< EOF # path=Parse#Internal#Commands#CommandRunner#URLSession#Session#PFURLSession.m.gcov.reduced -: 0:Source:Parse/Internal/Commands/CommandRunner/URLSession/Session/PFURLSession.m <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Carthage#Checkouts#facebook-ios-sdk#Sources#FBSDKCoreKit_Basics#FBSDKURLSessionTask.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKURLSessionTask.m 1:25: 1:27: 1:28: 1:29: 1:30: 1:31: 1:33: 1:37: 1:38: 1:39: 1:40: 1:41: 1:42: #####:44: #####:46: 1:51: 1:53: 1:54: #####:56: #####:58: #####:59: #####:60: <<<<<< EOF # path=#Applications#Xcode_13.1.app#Contents#Developer#Platforms#iPhoneSimulator.platform#Developer#SDKs#iPhoneSimulator15.0.sdk#usr#include#c++#v1#unordered_map.gcov.reduced -: 0:Source:/Applications/Xcode_13.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator15.0.sdk/usr/include/c++/v1/unordered_map 1:457: 1:459: #####:470: #####:471: 1:538: 1:540: #####:548: #####:549: #####:551: #####:552: #####:716: #####:717: #####:721: #####:726: #####:727: #####:731: #####:877: #####:885: #####:887: #####:890: #####:900: #####:901: #####:903: #####:904: 3:978: 2:980: 2:984: 2:1042: 2:1044: #####:1078: #####:1087: #####:1089: #####:1354: #####:1410: #####:1605: #####:1607: #####:1608: #####:1612: #####:1613: #####:1614: #####:1704: #####:1706: #####:1707: #####:1708: #####:1727: #####:1729: #####:1730: #####:1731: #####:1732: #####:1795: #####:1796: #####:1797: #####:1798: #####:1799: #####:1800: <<<<<< EOF # path=FBSDKCoreKit#Internal#UI#FBSDKViewImpressionTracker.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/UI/FBSDKViewImpressionTracker.m <<<<<< EOF # path=Parse#Internal#Commands#PFRESTCommand_Private.h.gcov.reduced -: 0:Source:Parse/Internal/Commands/PFRESTCommand_Private.h <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Carthage#Checkouts#facebook-ios-sdk#Sources#FBSDKCoreKit_Basics#FBSDKLibAnalyzer.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKLibAnalyzer.m #####:29: #####:31: #####:32: #####:34: #####:37: #####:38: #####:39: #####:40: #####:41: #####:42: #####:43: #####:44: #####:45: #####:46: #####:47: #####:48: #####:50: #####:53: #####:54: #####:56: #####:57: #####:58: #####:60: #####:61: #####:62: #####:64: #####:65: #####:66: #####:67: #####:69: #####:70: #####:72: #####:73: #####:74: #####:75: #####:76: #####:79: #####:80: #####:82: #####:83: #####:84: #####:86: #####:87: #####:89: #####:90: #####:94: #####:97: #####:99: #####:100: #####:102: #####:103: #####:104: #####:105: #####:106: #####:107: #####:108: #####:109: #####:111: #####:112: #####:113: #####:114: #####:115: #####:117: #####:118: #####:120: #####:123: #####:124: #####:125: #####:126: #####:127: #####:128: #####:129: #####:130: #####:131: #####:132: #####:134: #####:135: #####:136: #####:138: #####:139: #####:140: #####:141: #####:143: #####:146: #####:147: #####:149: #####:151: #####:152: #####:154: #####:155: #####:157: #####:158: #####:159: #####:160: #####:161: #####:162: #####:164: #####:165: #####:166: #####:167: #####:168: #####:169: #####:170: #####:171: #####:172: #####:174: #####:176: #####:177: #####:178: #####:179: #####:180: #####:182: #####:183: #####:184: #####:185: #####:187: #####:190: #####:191: #####:192: #####:194: #####:195: #####:197: #####:198: #####:199: #####:201: #####:204: #####:205: #####:207: #####:208: #####:210: #####:211: #####:214: #####:215: #####:218: #####:219: #####:222: #####:223: #####:225: #####:226: #####:227: #####:228: #####:229: <<<<<< EOF # path=FBSDKLoginKit#Internal#FBSDKPermission.h.gcov.reduced -: 0:Source:FBSDKLoginKit/Internal/FBSDKPermission.h <<<<<< EOF # path=Parse#Internal#User#Controller#PFUserController.m.gcov.reduced -: 0:Source:Parse/Internal/User/Controller/PFUserController.m <<<<<< EOF # path=FBSDKCoreKit#Internal#FBSDKFeatureManager.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/FBSDKFeatureManager.m <<<<<< EOF # path=FBSDKLoginKit#FBSDKLoginManagerLoginResult.m.gcov.reduced -: 0:Source:FBSDKLoginKit/FBSDKLoginManagerLoginResult.m <<<<<< EOF # path=Parse#Internal#PFBaseState.h.gcov.reduced -: 0:Source:Parse/Internal/PFBaseState.h <<<<<< EOF # path=Parse#Internal#User#AuthenticationProviders#Providers#Anonymous#PFAnonymousAuthenticationProvider.m.gcov.reduced -: 0:Source:Parse/Internal/User/AuthenticationProviders/Providers/Anonymous/PFAnonymousAuthenticationProvider.m <<<<<< EOF # path=FBSDKCoreKit#Internal#FBSDKAuthenticationStatusUtility.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/FBSDKAuthenticationStatusUtility.m <<<<<< EOF # path=#Applications#Xcode_13.1.app#Contents#Developer#Platforms#iPhoneSimulator.platform#Developer#SDKs#iPhoneSimulator15.0.sdk#usr#include#c++#v1#stdexcept.gcov.reduced -: 0:Source:/Applications/Xcode_13.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator15.0.sdk/usr/include/c++/v1/stdexcept #####:153: #####:165: #####:253: #####:254: #####:256: #####:261: #####:264: #####:265: #####:267: #####:272: <<<<<< EOF # path=Parse#Internal#Installation#InstallationIdentifierStore#PFInstallationIdentifierStore.h.gcov.reduced -: 0:Source:Parse/Internal/Installation/InstallationIdentifierStore/PFInstallationIdentifierStore.h <<<<<< EOF # path=FBSDKCoreKit#GraphAPI#FBSDKGraphRequestDataAttachment.m.gcov.reduced -: 0:Source:FBSDKCoreKit/GraphAPI/FBSDKGraphRequestDataAttachment.m <<<<<< EOF # path=FBSDKCoreKit#FBSDKApplicationDelegate.m.gcov.reduced -: 0:Source:FBSDKCoreKit/FBSDKApplicationDelegate.m <<<<<< EOF # path=FBSDKCoreKit#Internal#Network#FBSDKGraphRequestBody.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/Network/FBSDKGraphRequestBody.m <<<<<< EOF # path=Parse#Internal#LocalDataStore#SQLite#PFSQLiteStatement.m.gcov.reduced -: 0:Source:Parse/Internal/LocalDataStore/SQLite/PFSQLiteStatement.m <<<<<< EOF # path=FBSDKLoginKit#Internal#FBSDKMonotonicTime.m.gcov.reduced -: 0:Source:FBSDKLoginKit/Internal/FBSDKMonotonicTime.m <<<<<< EOF # path=Parse#PFAnonymousUtils.m.gcov.reduced -: 0:Source:Parse/PFAnonymousUtils.m <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#Internal#Commands#PFRESTQueryCommand.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/Internal/Commands/PFRESTQueryCommand.m #####:147: <<<<<< EOF # path=Parse#Internal#Query#Controller#PFOfflineQueryController.m.gcov.reduced -: 0:Source:Parse/Internal/Query/Controller/PFOfflineQueryController.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#FBSDKAppEventsStateFactory.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsStateFactory.m <<<<<< EOF # path=OCMock#OCMInvocationExpectation.m.gcov.reduced -: 0:Source:OCMock/OCMInvocationExpectation.m <<<<<< EOF # path=Tests#TestApplication#Classes#main.m.gcov.reduced -: 0:Source:Tests/TestApplication/Classes/main.m <<<<<< EOF # path=Parse#Internal#Object#Controller#OfflineController#PFOfflineObjectController.m.gcov.reduced -: 0:Source:Parse/Internal/Object/Controller/OfflineController/PFOfflineObjectController.m <<<<<< EOF # path=FBSDKLoginKit#Internal#FBSDKLoginManager+Internal.h.gcov.reduced -: 0:Source:FBSDKLoginKit/Internal/FBSDKLoginManager+Internal.h <<<<<< EOF # path=Parse#Internal#Commands#CommandRunner#URLSession#Session#TaskDelegate#PFURLSessionDataTaskDelegate.h.gcov.reduced -: 0:Source:Parse/Internal/Commands/CommandRunner/URLSession/Session/TaskDelegate/PFURLSessionDataTaskDelegate.h <<<<<< EOF # path=OCMock#OCMPassByRefSetter.m.gcov.reduced -: 0:Source:OCMock/OCMPassByRefSetter.m <<<<<< EOF # path=Parse#Internal#Commands#CommandRunner#URLSession#Session#TaskDelegate#PFURLSessionFileDownloadTaskDelegate.h.gcov.reduced -: 0:Source:Parse/Internal/Commands/CommandRunner/URLSession/Session/TaskDelegate/PFURLSessionFileDownloadTaskDelegate.h <<<<<< EOF # path=Parse#Internal#PFWeakValue.h.gcov.reduced -: 0:Source:Parse/Internal/PFWeakValue.h <<<<<< EOF # path=Bolts#Common#BFTaskCompletionSource.m.gcov.reduced -: 0:Source:Bolts/Common/BFTaskCompletionSource.m <<<<<< EOF # path=Parse#Internal#MultiProcessLock#PFMultiProcessFileLock.h.gcov.reduced -: 0:Source:Parse/Internal/MultiProcessLock/PFMultiProcessFileLock.h <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#AEM#FBSDKAEMAdvertiserMultiEntryRule.h.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMAdvertiserMultiEntryRule.h <<<<<< EOF # path=Parse#Internal#Object#Utilities#PFObjectUtilities.m.gcov.reduced -: 0:Source:Parse/Internal/Object/Utilities/PFObjectUtilities.m <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#Internal#PFLocationManager.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/Internal/PFLocationManager.m #####:38: <<<<<< EOF # path=OCMock#OCMIndirectReturnValueProvider.m.gcov.reduced -: 0:Source:OCMock/OCMIndirectReturnValueProvider.m <<<<<< EOF # path=Parse#PFSession.m.gcov.reduced -: 0:Source:Parse/PFSession.m <<<<<< EOF # path=Parse#Internal#PFJSONSerialization.m.gcov.reduced -: 0:Source:Parse/Internal/PFJSONSerialization.m <<<<<< EOF # path=Parse#Internal#User#AuthenticationProviders#Controller#PFUserAuthenticationController.h.gcov.reduced -: 0:Source:Parse/Internal/User/AuthenticationProviders/Controller/PFUserAuthenticationController.h <<<<<< EOF # path=Parse#PFObject.m.gcov.reduced -: 0:Source:Parse/PFObject.m <<<<<< EOF # path=Parse#Internal#Object#BatchController#PFObjectBatchController.m.gcov.reduced -: 0:Source:Parse/Internal/Object/BatchController/PFObjectBatchController.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#AEM#FBSDKAEMRule.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMRule.m <<<<<< EOF # path=Parse#Internal#Commands#PFRESTConfigCommand.m.gcov.reduced -: 0:Source:Parse/Internal/Commands/PFRESTConfigCommand.m <<<<<< EOF # path=FBSDKCoreKit#Internal#Instrument#ErrorReport#FBSDKErrorReport.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/Instrument/ErrorReport/FBSDKErrorReport.m <<<<<< EOF # path=#Applications#Xcode_13.1.app#Contents#Developer#Platforms#iPhoneSimulator.platform#Developer#SDKs#iPhoneSimulator15.0.sdk#System#Library#Frameworks#Foundation.framework#Headers#NSRange.h.gcov.reduced -: 0:Source:/Applications/Xcode_13.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator15.0.sdk/System/Library/Frameworks/Foundation.framework/Headers/NSRange.h 102:19: 102:21: 102:22: 102:23: <<<<<< EOF # path=FBSDKCoreKit#GraphAPI#FBSDKGraphRequest.m.gcov.reduced -: 0:Source:FBSDKCoreKit/GraphAPI/FBSDKGraphRequest.m <<<<<< EOF # path=FBSDKLoginKit#Internal#FBSDKAuthenticationTokenHeader.m.gcov.reduced -: 0:Source:FBSDKLoginKit/Internal/FBSDKAuthenticationTokenHeader.m <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#Internal#Object#State#PFObjectState.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/Internal/Object/State/PFObjectState.m #####:121: <<<<<< EOF # path=FBSDKCoreKit#Internal#Instrument#CrashReport#FBSDKCrashObserver.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/Instrument/CrashReport/FBSDKCrashObserver.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#AEM#FBSDKAEMInvocation.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMInvocation.m <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#Internal#LocalDataStore#OfflineStore#PFOfflineStore.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/Internal/LocalDataStore/OfflineStore/PFOfflineStore.m #####:122: <<<<<< EOF # path=Parse#Internal#Object#FilePersistence#PFObjectFilePersistenceController.m.gcov.reduced -: 0:Source:Parse/Internal/Object/FilePersistence/PFObjectFilePersistenceController.m <<<<<< EOF # path=ParseFacebookUtils#PFFacebookUtils.m.gcov.reduced -: 0:Source:ParseFacebookUtils/PFFacebookUtils.m <<<<<< EOF # path=Parse#Internal#PFTaskQueue.m.gcov.reduced -: 0:Source:Parse/Internal/PFTaskQueue.m <<<<<< EOF # path=Parse#Internal#PFAsyncTaskQueue.m.gcov.reduced -: 0:Source:Parse/Internal/PFAsyncTaskQueue.m <<<<<< EOF # path=Parse#Internal#File#State#PFFileState.h.gcov.reduced -: 0:Source:Parse/Internal/File/State/PFFileState.h <<<<<< EOF # path=Parse#PFNetworkActivityIndicatorManager.m.gcov.reduced -: 0:Source:Parse/PFNetworkActivityIndicatorManager.m <<<<<< EOF # path=FBSDKCoreKit#FBSDKBridgeAPIResponse.h.gcov.reduced -: 0:Source:FBSDKCoreKit/FBSDKBridgeAPIResponse.h <<<<<< EOF # path=FBSDKCoreKit#Internal#FBSDKMath.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/FBSDKMath.m <<<<<< EOF # path=Parse#Internal#Commands#CommandRunner#URLRequestConstructor#PFCommandURLRequestConstructor.h.gcov.reduced -: 0:Source:Parse/Internal/Commands/CommandRunner/URLRequestConstructor/PFCommandURLRequestConstructor.h <<<<<< EOF # path=Parse#Internal#Config#Controller#PFConfigController.m.gcov.reduced -: 0:Source:Parse/Internal/Config/Controller/PFConfigController.m <<<<<< EOF # path=./FBSDKCoreKit_Basics.framework.coverage.txt /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKBase64.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKBase64.h" 20| | 21| |@implementation FBSDKBase64 22| | 23| |static FBSDKBase64 *_decoder; 24| |static FBSDKBase64 *_encoder; 25| | 26| |#pragma mark - Class Methods 27| | 28| |+ (void)initialize 29| 0|{ 30| 0| if (self == [FBSDKBase64 class]) { 31| 0| _decoder = [FBSDKBase64 new]; 32| 0| _encoder = [FBSDKBase64 new]; 33| 0| } 34| 0|} 35| | 36| |+ (NSData *)decodeAsData:(NSString *)string 37| 0|{ 38| 0| return [_decoder decodeAsData:string]; 39| 0|} 40| | 41| |+ (NSString *)decodeAsString:(NSString *)string 42| 0|{ 43| 0| return [_decoder decodeAsString:string]; 44| 0|} 45| | 46| |+ (NSString *)encodeData:(NSData *)data 47| 0|{ 48| 0| return [_encoder encodeData:data]; 49| 0|} 50| | 51| |+ (NSString *)encodeString:(NSString *)string 52| 0|{ 53| 0| return [_encoder encodeString:string]; 54| 0|} 55| | 56| |+ (NSString *)base64FromBase64Url:(NSString *)base64Url 57| 0|{ 58| 0| NSString *base64 = [base64Url stringByReplacingOccurrencesOfString:@"-" withString:@"+"]; 59| 0| base64 = [base64 stringByReplacingOccurrencesOfString:@"_" withString:@"/"]; 60| | 61| 0| return base64; 62| 0|} 63| | 64| |#pragma mark - Object Lifecycle 65| | 66| |#pragma mark - Implementation Methods 67| | 68| |- (NSData *)decodeAsData:(NSString *)string 69| 0|{ 70| 0| if (!string) { 71| 0| return nil; 72| 0| } 73| | // This padding will be appended before stripping unknown characters, so if there are unknown characters of count % 4 74| | // it will not be able to decode. Since we assume valid base64 data, we will take this as is. 75| 0| int needPadding = string.length % 4; 76| 0| if (needPadding > 0) { 77| 0| needPadding = 4 - needPadding; 78| 0| string = [string stringByPaddingToLength:string.length + needPadding withString:@"=" startingAtIndex:0]; 79| 0| } 80| | 81| 0| return [[NSData alloc] initWithBase64EncodedString:string options:NSDataBase64DecodingIgnoreUnknownCharacters]; 82| 0|} 83| | 84| |- (NSString *)decodeAsString:(NSString *)string 85| 0|{ 86| 0| NSData *data = [self decodeAsData:string]; 87| 0| if (!data) { 88| 0| return nil; 89| 0| } 90| 0| return [[NSString alloc] initWithData:data encoding:NSUTF8StringEncoding]; 91| 0|} 92| | 93| |- (NSString *)encodeData:(NSData *)data 94| 0|{ 95| 0| if (!data) { 96| 0| return nil; 97| 0| } 98| | 99| 0| return [data base64EncodedStringWithOptions:0]; 100| 0|} 101| | 102| |- (NSString *)encodeString:(NSString *)string 103| 0|{ 104| 0| return [self encodeData:[string dataUsingEncoding:NSUTF8StringEncoding]]; 105| 0|} 106| | 107| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKBasicUtility.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKBasicUtility.h" 20| | 21| |#import 22| |#import 23| | 24| |#import "FBSDKTypeUtility.h" 25| | 26| 0|#define kChunkSize 1024 27| | 28| |static NSString *const FBSDK_BASICUTILITY_ANONYMOUSIDFILENAME = @"com-facebook-sdk-PersistedAnonymousID.json"; 29| |static NSString *const FBSDK_BASICUTILITY_ANONYMOUSID_KEY = @"anon_id"; 30| | 31| |void fb_dispatch_on_main_thread(dispatch_block_t block) 32| 0|{ 33| 0| if (block != nil) { 34| 0| if ([NSThread isMainThread]) { 35| 0| block(); 36| 0| } else { 37| 0| dispatch_async(dispatch_get_main_queue(), block); 38| 0| } 39| 0| } 40| 0|} 41| | 42| |void fb_dispatch_on_default_thread(dispatch_block_t block) 43| 0|{ 44| 0| if (block != nil) { 45| 0| dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_DEFAULT, 0), block); 46| 0| } 47| 0|} 48| | 49| |@protocol BASIC_FBSDKError 50| | 51| |+ (NSError *)invalidArgumentErrorWithName:(NSString *)name value:(id)value message:(NSString *)message; 52| | 53| |@end 54| | 55| |@implementation FBSDKBasicUtility 56| | 57| |+ (NSString *)JSONStringForObject:(id)object 58| | error:(NSError *__autoreleasing *)errorRef 59| | invalidObjectHandler:(FBSDKInvalidObjectHandler)invalidObjectHandler 60| 0|{ 61| 0| if (invalidObjectHandler || ![FBSDKTypeUtility isValidJSONObject:object]) { 62| 0| object = [self _convertObjectToJSONObject:object invalidObjectHandler:invalidObjectHandler stop:NULL]; 63| 0| if (![FBSDKTypeUtility isValidJSONObject:object]) { 64| 0| if (errorRef != NULL) { 65| 0| Class FBSDKErrorClass = NSClassFromString(@"FBSDKError"); 66| 0| if ([FBSDKErrorClass respondsToSelector:@selector(invalidArgumentErrorWithName:value:message:)]) { 67| 0| *errorRef = [FBSDKErrorClass invalidArgumentErrorWithName:@"object" 68| 0| value:object 69| 0| message:@"Invalid object for JSON serialization."]; 70| 0| } 71| 0| } 72| 0| return nil; 73| 0| } 74| 0| } 75| 0| NSData *data = [FBSDKTypeUtility dataWithJSONObject:object options:0 error:errorRef]; 76| 0| if (!data) { 77| 0| return nil; 78| 0| } 79| 0| return [[NSString alloc] initWithData:data encoding:NSUTF8StringEncoding]; 80| 0|} 81| | 82| |+ (BOOL) dictionary:(NSMutableDictionary *)dictionary 83| | setJSONStringForObject:(id)object 84| | forKey:(id)key 85| | error:(NSError *__autoreleasing *)errorRef 86| 0|{ 87| 0| if (!object || !key) { 88| 0| return YES; 89| 0| } 90| 0| NSString *JSONString = [self JSONStringForObject:object error:errorRef invalidObjectHandler:NULL]; 91| 0| if (!JSONString) { 92| 0| return NO; 93| 0| } 94| 0| [FBSDKTypeUtility dictionary:dictionary setObject:JSONString forKey:key]; 95| 0| return YES; 96| 0|} 97| | 98| |+ (id)_convertObjectToJSONObject:(id)object 99| | invalidObjectHandler:(FBSDKInvalidObjectHandler)invalidObjectHandler 100| | stop:(BOOL *)stopRef 101| 0|{ 102| 0| __block BOOL stop = NO; 103| 0| if ([object isKindOfClass:[NSString class]] || [object isKindOfClass:[NSNumber class]]) { 104| | // good to go, keep the object 105| 0| } else if ([object isKindOfClass:[NSURL class]]) { 106| 0| object = ((NSURL *)object).absoluteString; 107| 0| } else if ([object isKindOfClass:[NSDictionary class]]) { 108| 0| NSMutableDictionary *dictionary = [NSMutableDictionary new]; 109| 0| [FBSDKTypeUtility dictionary:(NSDictionary *) object enumerateKeysAndObjectsUsingBlock:^(id key, id obj, BOOL *dictionaryStop) { 110| 0| [FBSDKTypeUtility dictionary:dictionary 111| 0| setObject:[self _convertObjectToJSONObject:obj invalidObjectHandler:invalidObjectHandler stop:&stop] 112| 0| forKey:[FBSDKTypeUtility coercedToStringValue:key]]; 113| 0| if (stop) { 114| 0| *dictionaryStop = YES; 115| 0| } 116| 0| }]; 117| 0| object = dictionary; 118| 0| } else if ([object isKindOfClass:[NSArray class]]) { 119| 0| NSMutableArray *array = [NSMutableArray new]; 120| 0| for (id obj in (NSArray *)object) { 121| 0| id convertedObj = [self _convertObjectToJSONObject:obj invalidObjectHandler:invalidObjectHandler stop:&stop]; 122| 0| [FBSDKTypeUtility array:array addObject:convertedObj]; 123| 0| if (stop) { 124| 0| break; 125| 0| } 126| 0| } 127| 0| object = array; 128| 0| } else { 129| 0| object = invalidObjectHandler(object, stopRef); 130| 0| } 131| 0| if (stopRef != NULL) { 132| 0| *stopRef = stop; 133| 0| } 134| 0| return object; 135| 0|} 136| | 137| |+ (id)objectForJSONString:(NSString *)string error:(NSError *__autoreleasing *)errorRef 138| 0|{ 139| 0| NSData *data = [[FBSDKTypeUtility stringValueOrNil:string] dataUsingEncoding:NSUTF8StringEncoding]; 140| 0| if (!data) { 141| 0| if (errorRef != NULL) { 142| 0| *errorRef = nil; 143| 0| } 144| 0| return nil; 145| 0| } 146| 0| return [FBSDKTypeUtility JSONObjectWithData:data options:NSJSONReadingAllowFragments error:errorRef]; 147| 0|} 148| | 149| |+ (nullable NSString *)queryStringWithDictionary:(NSDictionary *)dictionary 150| | error:(NSError *__autoreleasing *)errorRef 151| | invalidObjectHandler:(FBSDKInvalidObjectHandler)invalidObjectHandler 152| 0|{ 153| 0| NSMutableString *queryString = [NSMutableString new]; 154| 0| __block BOOL hasParameters = NO; 155| 0| if (dictionary) { 156| 0| NSMutableArray *keys = [dictionary.allKeys mutableCopy]; 157| | // remove non-string keys, as they are not valid 158| 0| [keys filterUsingPredicate:[NSPredicate predicateWithBlock:^BOOL (id evaluatedObject, NSDictionary *bindings) { 159| 0| return [evaluatedObject isKindOfClass:[NSString class]]; 160| 0| }]]; 161| | // sort the keys so that the query string order is deterministic 162| 0| [keys sortUsingSelector:@selector(compare:)]; 163| 0| BOOL stop = NO; 164| 0| for (NSString *key in keys) { 165| 0| id value = [self convertRequestValue:dictionary[key]]; 166| 0| if ([value isKindOfClass:[NSString class]]) { 167| 0| value = [self URLEncode:value]; 168| 0| } 169| 0| if (invalidObjectHandler && ![value isKindOfClass:[NSString class]]) { 170| 0| value = invalidObjectHandler(value, &stop); 171| 0| if (stop) { 172| 0| break; 173| 0| } 174| 0| } 175| 0| if (value) { 176| 0| if (hasParameters) { 177| 0| [queryString appendString:@"&"]; 178| 0| } 179| 0| [queryString appendFormat:@"%@=%@", key, value]; 180| 0| hasParameters = YES; 181| 0| } 182| 0| } 183| 0| } 184| 0| if (errorRef != NULL) { 185| 0| *errorRef = nil; 186| 0| } 187| 0| return (queryString.length ? [queryString copy] : nil); 188| 0|} 189| | 190| |+ (id)convertRequestValue:(id)value 191| 0|{ 192| 0| if ([value isKindOfClass:[NSNumber class]]) { 193| 0| value = ((NSNumber *)value).stringValue; 194| 0| } else if ([value isKindOfClass:[NSURL class]]) { 195| 0| value = ((NSURL *)value).absoluteString; 196| 0| } 197| 0| return value; 198| 0|} 199| | 200| |#pragma clang diagnostic push 201| |#pragma clang diagnostic ignored "-Wdeprecated-declarations" 202| |+ (NSString *)URLEncode:(NSString *)value 203| 0|{ 204| 0| return (__bridge_transfer NSString *)CFURLCreateStringByAddingPercentEscapes( 205| 0| NULL, 206| 0| (CFStringRef)value, 207| 0| NULL, // characters to leave unescaped 208| 0| CFSTR(":!*();@/&?+$,='"), 209| 0| kCFStringEncodingUTF8 210| 0| ); 211| 0|} 212| | 213| |#pragma clang diagnostic pop 214| | 215| |+ (NSDictionary *)dictionaryWithQueryString:(NSString *)queryString 216| 0|{ 217| 0| NSMutableDictionary *result = [NSMutableDictionary new]; 218| 0| NSArray *parts = [queryString componentsSeparatedByString:@"&"]; 219| | 220| 0| for (NSString *part in parts) { 221| 0| if (part.length == 0) { 222| 0| continue; 223| 0| } 224| | 225| 0| NSRange index = [part rangeOfString:@"="]; 226| 0| NSString *key; 227| 0| NSString *value; 228| | 229| 0| if (index.location == NSNotFound) { 230| 0| key = part; 231| 0| value = @""; 232| 0| } else { 233| 0| key = [part substringToIndex:index.location]; 234| 0| value = [part substringFromIndex:index.location + index.length]; 235| 0| } 236| | 237| 0| key = [self URLDecode:key]; 238| 0| value = [self URLDecode:value]; 239| 0| if (key && value) { 240| 0| [FBSDKTypeUtility dictionary:result setObject:value forKey:key]; 241| 0| } 242| 0| } 243| 0| return result; 244| 0|} 245| | 246| |+ (NSString *)URLDecode:(NSString *)value 247| 0|{ 248| 0| value = [value stringByReplacingOccurrencesOfString:@"+" withString:@" "]; 249| 0| #pragma clang diagnostic push 250| 0| #pragma clang diagnostic ignored "-Wdeprecated-declarations" 251| 0| value = [value stringByReplacingPercentEscapesUsingEncoding:NSUTF8StringEncoding]; 252| 0| #pragma clang diagnostic pop 253| 0| return value; 254| 0|} 255| | 256| |+ (NSData *)gzip:(NSData *)data 257| 0|{ 258| 0| const void *bytes = data.bytes; 259| 0| const NSUInteger length = data.length; 260| | 261| 0| if (!bytes || !length) { 262| 0| return nil; 263| 0| } 264| | 265| 0|#if defined(__LP64__) && __LP64__ 266| 0| if (length > UINT_MAX) { 267| 0| return nil; 268| 0| } 269| 0|#endif 270| | 271| | // initialze stream 272| 0| z_stream stream; 273| 0| bzero(&stream, sizeof(z_stream)); 274| | 275| 0| if (deflateInit2(&stream, -1, Z_DEFLATED, 31, 8, Z_DEFAULT_STRATEGY) != Z_OK) { 276| 0| return nil; 277| 0| } 278| 0| stream.avail_in = (uint)length; 279| 0| stream.next_in = (Bytef *)bytes; 280| | 281| 0| int retCode; 282| 0| NSMutableData *result = [NSMutableData dataWithCapacity:(length / 4)]; 283| 0| unsigned char output[kChunkSize]; 284| 0| do { 285| 0| stream.avail_out = kChunkSize; 286| 0| stream.next_out = output; 287| 0| retCode = deflate(&stream, Z_FINISH); 288| 0| if (retCode != Z_OK && retCode != Z_STREAM_END) { 289| 0| deflateEnd(&stream); 290| 0| return nil; 291| 0| } 292| 0| unsigned size = kChunkSize - stream.avail_out; 293| 0| if (size > 0) { 294| 0| [result appendBytes:output length:size]; 295| 0| } 296| 0| } while (retCode == Z_OK); 297| | 298| 0| deflateEnd(&stream); 299| | 300| 0| return result; 301| 0|} 302| | 303| |+ (NSString *)anonymousID 304| 0|{ 305| | // Grab previously written anonymous ID and, if none have been generated, create and 306| | // persist a new one which will remain associated with this app. 307| 0| NSString *result = [[self class] retrievePersistedAnonymousID]; 308| 0| if (!result) { 309| | // Generate a new anonymous ID. Create as a UUID, but then prepend the fairly 310| | // arbitrary 'XZ' to the front so it's easily distinguishable from IDFA's which 311| | // will only contain hex. 312| 0| result = [NSString stringWithFormat:@"XZ%@", [NSUUID UUID].UUIDString]; 313| | 314| 0| [self persistAnonymousID:result]; 315| 0| } 316| 0| return result; 317| 0|} 318| | 319| |+ (NSString *)retrievePersistedAnonymousID 320| 0|{ 321| 0| NSString *file = [[self class] persistenceFilePath:FBSDK_BASICUTILITY_ANONYMOUSIDFILENAME]; 322| 0| NSString *content = [[NSString alloc] initWithContentsOfFile:file 323| 0| encoding:NSASCIIStringEncoding 324| 0| error:nil]; 325| 0| NSDictionary *results = [FBSDKBasicUtility objectForJSONString:content error:NULL]; 326| 0| return results[FBSDK_BASICUTILITY_ANONYMOUSID_KEY]; 327| 0|} 328| | 329| |+ (NSString *)persistenceFilePath:(NSString *)filename 330| 0|{ 331| 0| NSSearchPathDirectory directory = NSLibraryDirectory; 332| 0| NSArray *paths = NSSearchPathForDirectoriesInDomains(directory, NSUserDomainMask, YES); 333| 0| NSString *docDirectory = [FBSDKTypeUtility array:paths objectAtIndex:0]; 334| 0| return [docDirectory stringByAppendingPathComponent:filename]; 335| 0|} 336| | 337| |+ (void)persistAnonymousID:(NSString *)anonymousID 338| 0|{ 339| 0| NSDictionary *data = @{ FBSDK_BASICUTILITY_ANONYMOUSID_KEY : anonymousID }; 340| 0| NSString *content = [self JSONStringForObject:data error:NULL invalidObjectHandler:NULL]; 341| | 342| 0| [content writeToFile:[[self class] persistenceFilePath:FBSDK_BASICUTILITY_ANONYMOUSIDFILENAME] 343| 0| atomically:YES 344| 0| encoding:NSASCIIStringEncoding 345| 0| error:nil]; 346| 0|} 347| | 348| |+ (NSString *)SHA256Hash:(NSObject *)input 349| 0|{ 350| 0| NSData *data = nil; 351| | 352| 0| if ([input isKindOfClass:[NSData class]]) { 353| 0| data = (NSData *)input; 354| 0| } else if ([input isKindOfClass:[NSString class]]) { 355| 0| data = [(NSString *)input dataUsingEncoding:NSUTF8StringEncoding]; 356| 0| } 357| | 358| 0| if (!data) { 359| 0| return nil; 360| 0| } 361| | 362| 0| uint8_t digest[CC_SHA256_DIGEST_LENGTH]; 363| 0| CC_SHA256(data.bytes, (CC_LONG)data.length, digest); 364| 0| NSMutableString *hashed = [NSMutableString stringWithCapacity:CC_SHA256_DIGEST_LENGTH * 2]; 365| 0| for (int i = 0; i < CC_SHA256_DIGEST_LENGTH; i++) { 366| 0| [hashed appendFormat:@"%02x", digest[i]]; 367| 0| } 368| | 369| 0| return [hashed copy]; 370| 0|} 371| | 372| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKCrashHandler.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKCrashHandler.h" 20| | 21| |#import 22| | 23| |#import 24| | 25| |#import "FBSDKCrashObserving.h" 26| |#import "FBSDKFileDataExtracting.h" 27| |#import "FBSDKFileManaging.h" 28| |#import "FBSDKLibAnalyzer.h" 29| |#import "FBSDKTypeUtility.h" 30| |#import "NSBundle+InfoDictionaryProviding.h" 31| | 32| |#define FBSDK_MAX_CRASH_LOGS 5 33| 0|#define FBSDK_CRASH_PATH_NAME @"instrument" 34| |#ifndef FBSDK_VERSION_STRING 35| 0| #define FBSDK_VERSION_STRING @"11.0.1" 36| |#endif 37| | 38| |static NSUncaughtExceptionHandler *previousExceptionHandler = NULL; 39| |static NSString *mappingTableIdentifier = NULL; 40| |static NSString *directoryPath; 41| | 42| |NSString *const kFBSDKAppVersion = @"app_version"; 43| |NSString *const kFBSDKCallstack = @"callstack"; 44| |NSString *const kFBSDKCrashReason = @"reason"; 45| |NSString *const kFBSDKCrashTimestamp = @"timestamp"; 46| |NSString *const kFBSDKDeviceModel = @"device_model"; 47| |NSString *const kFBSDKDeviceOSVersion = @"device_os_version"; 48| | 49| |NSString *const kFBSDKMapingTable = @"mapping_table"; 50| |NSString *const kFBSDKMappingTableIdentifier = @"mapping_table_identifier"; 51| | 52| |@interface FBSDKCrashHandler () 53| | 54| |@property (nonatomic) BOOL isTurnedOn; 55| |@property (nonatomic) id fileManager; 56| |@property (nonatomic, strong) Class dataExtractor; 57| |@property (nonatomic) id bundle; 58| |@property (nonatomic) NSHashTable> *observers; 59| |@property (nonatomic) NSArray *> *processedCrashLogs; 60| | 61| |@end 62| | 63| |@implementation FBSDKCrashHandler 64| | 65| |- (instancetype)init 66| 0|{ 67| 0| return [self initWithFileManager:NSFileManager.defaultManager 68| 0| bundle:NSBundle.mainBundle 69| 0| fileDataExtractor:NSData.class 70| 0| ]; 71| 0|} 72| | 73| |- (instancetype)initWithFileManager:(id)fileManager 74| | bundle:(id)bundle 75| | fileDataExtractor:(nonnull Class)dataExtractor 76| 0|{ 77| 0| if ((self = [super init])) { 78| 0| _observers = [NSHashTable new]; 79| 0| _isTurnedOn = YES; 80| 0| _fileManager = fileManager; 81| 0| _bundle = bundle; 82| 0| _dataExtractor = dataExtractor; 83| | 84| 0| NSString *dirPath = [NSTemporaryDirectory() stringByAppendingPathComponent:FBSDK_CRASH_PATH_NAME]; 85| 0| if (![_fileManager fileExistsAtPath:dirPath]) { 86| 0| [_fileManager createDirectoryAtPath:dirPath withIntermediateDirectories:NO attributes:NULL error:NULL]; 87| 0| } 88| 0| directoryPath = dirPath; 89| 0| NSString *identifier = [[NSUUID UUID] UUIDString]; 90| 0| mappingTableIdentifier = [identifier stringByReplacingOccurrencesOfString:@"-" withString:@""]; 91| 0| } 92| 0| return self; 93| 0|} 94| | 95| |+ (instancetype)shared 96| 0|{ 97| 0| static dispatch_once_t nonce; 98| 0| static id instance; 99| 0| dispatch_once(&nonce, ^{ 100| 0| instance = [self new]; 101| 0| }); 102| 0| return instance; 103| 0|} 104| | 105| |#pragma mark - Public API 106| | 107| |+ (NSString *)getFBSDKVersion 108| 0|{ 109| 0| return FBSDK_VERSION_STRING; 110| 0|} 111| | 112| |+ (void)disable 113| 0|{ 114| 0| [FBSDKCrashHandler.shared disable]; 115| 0|} 116| | 117| |- (void)disable 118| 0|{ 119| 0| self.isTurnedOn = NO; 120| 0| [FBSDKCrashHandler.shared _uninstallExceptionsHandler]; 121| 0| self.observers = nil; 122| 0|} 123| | 124| |+ (void)addObserver:(id)observer 125| 0|{ 126| 0| [FBSDKCrashHandler.shared addObserver:observer]; 127| 0|} 128| | 129| |- (void)addObserver:(id)observer 130| 0|{ 131| 0| if (!self.isTurnedOn || ![self _isSafeToGenerateMapping]) { 132| 0| return; 133| 0| } 134| 0| static dispatch_once_t onceToken; 135| 0| dispatch_once(&onceToken, ^{ 136| 0| [FBSDKCrashHandler.shared _installExceptionsHandler]; 137| 0| _processedCrashLogs = [self _getProcessedCrashLogs]; 138| 0| }); 139| 0| @synchronized(_observers) { 140| 0| if (![self.observers containsObject:observer]) { 141| 0| [self.observers addObject:observer]; 142| 0| dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_BACKGROUND, 0), ^(void) { 143| 0| [self _generateMethodMapping:observer]; 144| 0| }); 145| 0| [self _sendCrashLogs]; 146| 0| } 147| 0| } 148| 0|} 149| | 150| |+ (void)removeObserver:(id)observer 151| 0|{ 152| 0| [FBSDKCrashHandler.shared removeObserver:observer]; 153| 0|} 154| | 155| |- (void)removeObserver:(id)observer 156| 0|{ 157| 0| @synchronized(_observers) { 158| 0| if ([self.observers containsObject:observer]) { 159| 0| [self.observers removeObject:observer]; 160| 0| if (self.observers.count == 0) { 161| 0| [FBSDKCrashHandler.shared _uninstallExceptionsHandler]; 162| 0| } 163| 0| } 164| 0| } 165| 0|} 166| | 167| |+ (void)clearCrashReportFiles 168| 0|{ 169| 0| [FBSDKCrashHandler.shared clearCrashReportFiles]; 170| 0|} 171| | 172| |- (void)clearCrashReportFiles 173| 0|{ 174| 0| NSArray *files = [self.fileManager contentsOfDirectoryAtPath:directoryPath error:nil]; 175| | 176| 0| for (NSUInteger i = 0; i < files.count; i++) { 177| | // remove all crash related files except for the current mapping table 178| 0| if ([[FBSDKTypeUtility array:files objectAtIndex:i] hasPrefix:@"crash_"] && ![[FBSDKTypeUtility array:files objectAtIndex:i] containsString:mappingTableIdentifier]) { 179| 0| [self.fileManager removeItemAtPath:[directoryPath stringByAppendingPathComponent:[FBSDKTypeUtility array:files objectAtIndex:i]] error:nil]; 180| 0| } 181| 0| } 182| 0|} 183| | 184| |# pragma mark - Handler 185| | 186| |+ (void)_installExceptionsHandler 187| 0|{ 188| 0| [FBSDKCrashHandler.shared _installExceptionsHandler]; 189| 0|} 190| | 191| |- (void)_installExceptionsHandler 192| 0|{ 193| 0| NSUncaughtExceptionHandler *currentHandler = NSGetUncaughtExceptionHandler(); 194| | 195| 0| if (currentHandler != FBSDKExceptionHandler) { 196| 0| previousExceptionHandler = currentHandler; 197| 0| NSSetUncaughtExceptionHandler(&FBSDKExceptionHandler); 198| 0| } 199| 0|} 200| | 201| |+ (void)_uninstallExceptionsHandler 202| 0|{ 203| 0| [FBSDKCrashHandler.shared _uninstallExceptionsHandler]; 204| 0|} 205| | 206| |- (void)_uninstallExceptionsHandler 207| 0|{ 208| 0| NSSetUncaughtExceptionHandler(previousExceptionHandler); 209| 0| previousExceptionHandler = nil; 210| 0|} 211| | 212| |static void FBSDKExceptionHandler(NSException *exception) 213| 0|{ 214| 0| [FBSDKCrashHandler.shared _saveException:exception]; 215| 0| if (previousExceptionHandler) { 216| 0| previousExceptionHandler(exception); 217| 0| } 218| 0|} 219| | 220| |#pragma mark - Storage & Process 221| | 222| |+ (void)_saveException:(NSException *)exception 223| 0|{ 224| 0| [FBSDKCrashHandler.shared _saveException:exception]; 225| 0|} 226| | 227| |- (void)_saveException:(NSException *)exception 228| 0|{ 229| 0| if (exception.callStackSymbols && exception.name) { 230| 0| NSArray *stackSymbols = [NSArray arrayWithArray:exception.callStackSymbols]; 231| 0| [self _saveCrashLog:@{ 232| 0| kFBSDKCallstack : stackSymbols, 233| 0| kFBSDKCrashReason : exception.name, 234| 0| }]; 235| 0| } 236| 0|} 237| | 238| |+ (NSArray *> *)_getProcessedCrashLogs 239| 0|{ 240| 0| return [FBSDKCrashHandler.shared _getProcessedCrashLogs]; 241| 0|} 242| | 243| |- (NSArray *> *)_getProcessedCrashLogs 244| 0|{ 245| 0| NSArray *> *crashLogs = [self _loadCrashLogs]; 246| 0| if (0 == crashLogs.count) { 247| 0| [self clearCrashReportFiles]; 248| 0| return nil; 249| 0| } 250| 0| NSMutableArray *> *processedCrashLogs = [NSMutableArray array]; 251| | 252| 0| for (NSDictionary *crashLog in crashLogs) { 253| 0| NSArray *callstack = crashLog[kFBSDKCallstack]; 254| 0| NSData *data = [self _loadLibData:crashLog]; 255| 0| if (!data) { 256| 0| continue; 257| 0| } 258| 0| NSDictionary *methodMapping = [FBSDKTypeUtility JSONObjectWithData:data 259| 0| options:kNilOptions 260| 0| error:nil]; 261| 0| NSArray *symbolicatedCallstack = [FBSDKLibAnalyzer symbolicateCallstack:callstack methodMapping:methodMapping]; 262| 0| NSMutableDictionary *symbolicatedCrashLog = [NSMutableDictionary dictionaryWithDictionary:crashLog]; 263| 0| if (symbolicatedCallstack) { 264| 0| [FBSDKTypeUtility dictionary:symbolicatedCrashLog setObject:symbolicatedCallstack forKey:kFBSDKCallstack]; 265| 0| [symbolicatedCrashLog removeObjectForKey:kFBSDKMappingTableIdentifier]; 266| 0| [FBSDKTypeUtility array:processedCrashLogs addObject:symbolicatedCrashLog]; 267| 0| } 268| 0| } 269| 0| return processedCrashLogs; 270| 0|} 271| | 272| |+ (NSArray *> *)_loadCrashLogs 273| 0|{ 274| 0| return [FBSDKCrashHandler.shared _loadCrashLogs]; 275| 0|} 276| | 277| |- (NSArray *> *)_loadCrashLogs 278| 0|{ 279| 0| NSArray *files = [self.fileManager contentsOfDirectoryAtPath:directoryPath error:NULL]; 280| 0| NSArray *fileNames = [[self _getCrashLogFileNames:files] sortedArrayUsingComparator:^NSComparisonResult (id _Nonnull obj1, id _Nonnull obj2) { 281| 0| return [obj2 compare:obj1]; 282| 0| }]; 283| 0| NSMutableArray *> *crashLogArray = [NSMutableArray array]; 284| | 285| 0| for (NSUInteger i = 0; i < MIN(fileNames.count, FBSDK_MAX_CRASH_LOGS); i++) { 286| 0| NSData *data = [self _loadCrashLog:[FBSDKTypeUtility array:fileNames objectAtIndex:i]]; 287| 0| if (!data) { 288| 0| continue; 289| 0| } 290| 0| NSDictionary *crashLog = [FBSDKTypeUtility JSONObjectWithData:data 291| 0| options:kNilOptions 292| 0| error:nil]; 293| 0| if (crashLog) { 294| 0| [FBSDKTypeUtility array:crashLogArray addObject:crashLog]; 295| 0| } 296| 0| } 297| 0| return [crashLogArray copy]; 298| 0|} 299| | 300| |+ (nullable NSData *)_loadCrashLog:(NSString *)fileName 301| 0|{ 302| 0| return [FBSDKCrashHandler.shared _loadCrashLog:fileName]; 303| 0|} 304| | 305| |- (nullable NSData *)_loadCrashLog:(NSString *)fileName 306| 0|{ 307| 0| return [self.dataExtractor dataWithContentsOfFile:[directoryPath stringByAppendingPathComponent:fileName] options:NSDataReadingMappedIfSafe error:nil]; 308| 0|} 309| | 310| |+ (NSArray *)_getCrashLogFileNames:(NSArray *)files 311| 0|{ 312| 0| return [FBSDKCrashHandler.shared _getCrashLogFileNames:files]; 313| 0|} 314| | 315| |- (NSArray *)_getCrashLogFileNames:(NSArray *)files 316| 0|{ 317| 0| NSMutableArray *fileNames = [NSMutableArray array]; 318| | 319| 0| for (NSString *fileName in files) { 320| 0| if ([fileName hasPrefix:@"crash_log_"] && [fileName hasSuffix:@".json"]) { 321| 0| [FBSDKTypeUtility array:fileNames addObject:fileName]; 322| 0| } 323| 0| } 324| | 325| 0| return fileNames; 326| 0|} 327| | 328| |+ (void)_saveCrashLog:(NSDictionary *)crashLog 329| 0|{ 330| 0| [FBSDKCrashHandler.shared _saveCrashLog:crashLog]; 331| 0|} 332| | 333| |- (void)_saveCrashLog:(NSDictionary *)crashLog 334| 0|{ 335| 0| NSMutableDictionary *completeCrashLog = [NSMutableDictionary dictionaryWithDictionary:crashLog]; 336| 0| NSString *currentTimestamp = [NSString stringWithFormat:@"%.0lf", [[NSDate date] timeIntervalSince1970]]; 337| | 338| 0| [FBSDKTypeUtility dictionary:completeCrashLog setObject:currentTimestamp forKey:kFBSDKCrashTimestamp]; 339| 0| [FBSDKTypeUtility dictionary:completeCrashLog setObject:mappingTableIdentifier forKey:kFBSDKMappingTableIdentifier]; 340| | 341| 0| NSString *version = [self.bundle objectForInfoDictionaryKey:@"CFBundleShortVersionString"]; 342| 0| NSString *build = [self.bundle objectForInfoDictionaryKey:@"CFBundleVersion"]; 343| 0| [FBSDKTypeUtility dictionary:completeCrashLog setObject:[NSString stringWithFormat:@"%@(%@)", version, build] forKey:kFBSDKAppVersion]; 344| | 345| 0| struct utsname systemInfo; 346| 0| uname(&systemInfo); 347| 0| [FBSDKTypeUtility dictionary:completeCrashLog setObject:@(systemInfo.machine) forKey:kFBSDKDeviceModel]; 348| | 349| 0| [FBSDKTypeUtility dictionary:completeCrashLog setObject:[UIDevice currentDevice].systemVersion forKey:kFBSDKDeviceOSVersion]; 350| | 351| 0| NSData *data = [FBSDKTypeUtility dataWithJSONObject:completeCrashLog options:0 error:nil]; 352| | 353| 0| [data writeToFile:[self _getPathToCrashFile:currentTimestamp] 354| 0| atomically:YES]; 355| 0|} 356| | 357| |+ (void)_sendCrashLogs 358| 0|{ 359| 0| [FBSDKCrashHandler.shared _sendCrashLogs]; 360| 0|} 361| | 362| |- (void)_sendCrashLogs 363| 0|{ 364| 0| for (id observer in _observers) { 365| 0| if (observer) { 366| 0| NSArray *> *filteredCrashLogs = [self _filterCrashLogs:observer.prefixes processedCrashLogs:_processedCrashLogs]; 367| 0| [observer didReceiveCrashLogs:filteredCrashLogs]; 368| 0| } 369| 0| } 370| 0|} 371| | 372| |+ (NSArray *> *)_filterCrashLogs:(NSArray *)prefixList 373| | processedCrashLogs:(NSArray *> *)processedCrashLogs 374| 0|{ 375| 0| return [FBSDKCrashHandler.shared _filterCrashLogs:prefixList processedCrashLogs:processedCrashLogs]; 376| 0|} 377| | 378| |- (NSArray *> *)_filterCrashLogs:(NSArray *)prefixList 379| | processedCrashLogs:(NSArray *> *)processedCrashLogs 380| 0|{ 381| 0| NSMutableArray *> *crashLogs = [NSMutableArray array]; 382| 0| for (NSDictionary *crashLog in processedCrashLogs) { 383| 0| NSArray *callstack = crashLog[kFBSDKCallstack]; 384| 0| if ([self _callstack:callstack containsPrefix:prefixList]) { 385| 0| [FBSDKTypeUtility array:crashLogs addObject:crashLog]; 386| 0| } 387| 0| } 388| 0| return crashLogs; 389| 0|} 390| | 391| |+ (BOOL)_callstack:(NSArray *)callstack 392| | containsPrefix:(NSArray *)prefixList 393| 0|{ 394| 0| return [FBSDKCrashHandler.shared _callstack:callstack containsPrefix:prefixList]; 395| 0|} 396| | 397| |- (BOOL)_callstack:(NSArray *)callstack 398| | containsPrefix:(NSArray *)prefixList 399| 0|{ 400| 0| NSString *callStackString = [callstack componentsJoinedByString:@""]; 401| 0| for (NSString *prefix in prefixList) { 402| 0| if ([callStackString containsString:prefix]) { 403| 0| return YES; 404| 0| } 405| 0| } 406| 0| return NO; 407| 0|} 408| | 409| |#pragma mark - Method Mapping 410| | 411| |+ (void)_generateMethodMapping:(id)observer 412| 0|{ 413| 0| [FBSDKCrashHandler.shared _generateMethodMapping:observer]; 414| 0|} 415| | 416| |- (void)_generateMethodMapping:(id)observer 417| 0|{ 418| 0| if (observer.prefixes.count == 0) { 419| 0| return; 420| 0| } 421| 0| [[NSUserDefaults standardUserDefaults] setObject:mappingTableIdentifier forKey:kFBSDKMappingTableIdentifier]; 422| 0| NSDictionary *methodMapping = [FBSDKLibAnalyzer getMethodsTable:observer.prefixes 423| 0| frameworks:observer.frameworks]; 424| 0| if (methodMapping.count > 0) { 425| 0| NSData *data = [FBSDKTypeUtility dataWithJSONObject:methodMapping options:0 error:nil]; 426| 0| [data writeToFile:[self _getPathToLibDataFile:mappingTableIdentifier] 427| 0| atomically:YES]; 428| 0| } 429| 0|} 430| | 431| |+ (nullable NSData *)_loadLibData:(NSDictionary *)crashLog 432| 0|{ 433| 0| return [FBSDKCrashHandler.shared _loadLibData:crashLog]; 434| 0|} 435| | 436| |- (nullable NSData *)_loadLibData:(NSDictionary *)crashLog 437| 0|{ 438| 0| NSString *identifier = [FBSDKTypeUtility dictionary:crashLog objectForKey:kFBSDKMappingTableIdentifier ofType:NSObject.class]; 439| 0| return [self.dataExtractor dataWithContentsOfFile:[self _getPathToLibDataFile:identifier] options:NSDataReadingMappedIfSafe error:nil]; 440| 0|} 441| | 442| |+ (NSString *)_getPathToCrashFile:(NSString *)timestamp 443| 0|{ 444| 0| return [FBSDKCrashHandler.shared _getPathToCrashFile:timestamp]; 445| 0|} 446| | 447| |- (NSString *)_getPathToCrashFile:(NSString *)timestamp 448| 0|{ 449| 0| return [directoryPath stringByAppendingPathComponent: 450| 0| [NSString stringWithFormat:@"crash_log_%@.json", timestamp]]; 451| 0|} 452| | 453| |+ (NSString *)_getPathToLibDataFile:(NSString *)identifier 454| 0|{ 455| 0| return [FBSDKCrashHandler.shared _getPathToLibDataFile:identifier]; 456| 0|} 457| | 458| |- (NSString *)_getPathToLibDataFile:(NSString *)identifier 459| 0|{ 460| 0| return [directoryPath stringByAppendingPathComponent: 461| 0| [NSString stringWithFormat:@"crash_lib_data_%@.json", identifier]]; 462| 0|} 463| | 464| |+ (BOOL)_isSafeToGenerateMapping 465| 0|{ 466| 0| return [FBSDKCrashHandler.shared _isSafeToGenerateMapping]; 467| 0|} 468| | 469| |- (BOOL)_isSafeToGenerateMapping 470| 0|{ 471| 0|#if TARGET_OS_SIMULATOR 472| 0| return YES; 473| |#else 474| | NSString *identifier = [[NSUserDefaults standardUserDefaults] objectForKey:kFBSDKMappingTableIdentifier]; 475| | // first app start 476| | if (!identifier) { 477| | return YES; 478| | } 479| | 480| | return [self.fileManager fileExistsAtPath:[self _getPathToLibDataFile:identifier]]; 481| |#endif 482| 0|} 483| | 484| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKJSONValue.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKJSONValue.h" 20| | 21| |#import 22| | 23| |#import "FBSDKBasicUtility.h" 24| |#import "FBSDKSafeCast.h" 25| |#import "FBSDKTypeUtility.h" 26| | 27| |@interface FBSDKJSONField () 28| |- (instancetype)initWithPotentialJSONField:(id)obj; 29| |@end 30| | 31| |static NSArray *createArray(id obj) 32| 0|{ 33| 0| NSArray *const original = FBSDK_CAST_TO_CLASS_OR_NIL(obj, NSArray); 34| 0| if (!original) { 35| 0| return @[]; 36| 0| } 37| | 38| 0| NSMutableArray *const fields = 39| 0| [[NSMutableArray alloc] initWithCapacity:original.count]; 40| | 41| 0| for (id field in original) { 42| 0| FBSDKJSONField *const f = [[FBSDKJSONField alloc] initWithPotentialJSONField:field]; 43| 0| if (f) { 44| 0| [fields addObject:f]; 45| 0| } 46| 0| } 47| | 48| 0| return fields; 49| 0|} 50| | 51| |static NSDictionary *createDictionary(id obj) 52| 0|{ 53| 0| NSDictionary *const original = FBSDK_CAST_TO_CLASS_OR_NIL(obj, NSDictionary); 54| 0| if (!original) { 55| 0| return @{}; 56| 0| } 57| | 58| 0| NSMutableDictionary *const fields = 59| 0| [[NSMutableDictionary alloc] initWithCapacity:original.count]; 60| | 61| 0| for (id key in original) { 62| | // This is just a sanity check. Apple should only give us string keys 63| | // anyway. 64| 0| if (![key respondsToSelector:@selector(isKindOfClass:)] || ![key isKindOfClass:NSString.class]) { 65| 0| continue; 66| 0| } 67| 0| NSString *const stringKey = (NSString *)key; 68| | 69| 0| FBSDKJSONField *const typedField = [[FBSDKJSONField alloc] initWithPotentialJSONField:original[key]]; 70| 0| if (typedField) { 71| 0| fields[stringKey] = typedField; 72| 0| } 73| 0| } 74| | 75| 0| return fields; 76| 0|} 77| | 78| |@implementation FBSDKJSONValue 79| | 80| |- (instancetype)initWithPotentialJSONObject:(id)obj 81| 0|{ 82| | // If this isn't a real JSON object, dump it. 83| 0| if (![FBSDKTypeUtility isValidJSONObject:obj]) { 84| 0| return nil; 85| 0| } 86| 0| _rawObject = obj; 87| | 88| 0| return self; 89| 0|} 90| | 91| |- (void)matchArray:(void (^)(NSArray *))arrayMatcher 92| | dictionary:(void (^)(NSDictionary *))dictMatcher 93| 0|{ 94| 0| if (arrayMatcher && [_rawObject isKindOfClass:[NSArray class]]) { 95| 0| arrayMatcher(createArray(_rawObject)); 96| 0| } else if (dictMatcher && [_rawObject isKindOfClass:[NSDictionary class]]) { 97| 0| dictMatcher(createDictionary(_rawObject)); 98| 0| } 99| 0|} 100| | 101| |- (NSDictionary *_Nullable)matchDictionaryOrNil 102| 0|{ 103| 0| __block NSDictionary *result = nil; 104| 0| [self matchArray:nil dictionary:^(NSDictionary *_Nonnull value) { 105| 0| result = value; 106| 0| }]; 107| 0| return result; 108| 0|} 109| | 110| |- (NSDictionary *_Nullable)unsafe_matchDictionaryOrNil 111| 0|{ 112| 0| return [_rawObject isKindOfClass:NSDictionary.class] ? _rawObject : nil; 113| 0|} 114| | 115| |- (NSArray *_Nullable)matchArrayOrNil 116| 0|{ 117| 0| __block NSArray *result = nil; 118| 0| [self matchArray:^(NSArray *_Nonnull value) { 119| 0| result = value; 120| 0| } dictionary:nil]; 121| 0| return result; 122| 0|} 123| | 124| |- (NSArray *_Nullable)unsafe_matchArrayOrNil 125| 0|{ 126| 0| __block BOOL isArray = NO; 127| 0| [self matchArray:^(NSArray *_Nonnull _) { 128| 0| isArray = YES; 129| 0| } dictionary:nil]; 130| | 131| 0| return [_rawObject isKindOfClass:NSArray.class] ? _rawObject : nil; 132| 0|} 133| | 134| |@end 135| | 136| |@implementation FBSDKJSONField 137| | 138| |- (instancetype)initWithPotentialJSONField:(id)obj 139| 0|{ 140| | // If this is nil, don't wrap it. 141| 0| if (obj == nil) { 142| 0| return nil; 143| 0| } 144| | 145| | // Per Apple's Docs, these are the only types FBSDKTypeUtility can return. 146| 0| if ( 147| 0| ![obj isKindOfClass:NSString.class] 148| 0| && ![obj isKindOfClass:NSNumber.class] 149| 0| && ![obj isKindOfClass:NSNull.class] 150| 0| && ![obj isKindOfClass:NSDictionary.class] 151| 0| && ![obj isKindOfClass:NSArray.class]) { 152| 0| return nil; 153| 0| } 154| | 155| 0| if (self = [super init]) { 156| 0| _rawObject = obj; 157| 0| } 158| | 159| 0| return self; 160| 0|} 161| | 162| |- (void)matchArray:(void (^)(NSArray *))arrayMatcher 163| | dictionary:(void (^)(NSDictionary *_Nonnull))dictionaryMatcher 164| | string:(void (^)(NSString *_Nonnull))stringMatcher 165| | number:(void (^)(NSNumber *_Nonnull))numberMatcher 166| | null:(void (^)(void))nullMatcher 167| 0|{ 168| 0| if (nullMatcher && [_rawObject isKindOfClass:NSNull.class]) { 169| 0| nullMatcher(); 170| 0| } else if (numberMatcher && [_rawObject isKindOfClass:NSNumber.class]) { 171| 0| numberMatcher(_rawObject); 172| 0| } else if (stringMatcher && [_rawObject isKindOfClass:NSString.class]) { 173| 0| stringMatcher(_rawObject); 174| 0| } else if (arrayMatcher && [_rawObject isKindOfClass:NSArray.class]) { 175| 0| arrayMatcher(createArray(_rawObject)); 176| 0| } else if (dictionaryMatcher && [_rawObject isKindOfClass:NSDictionary.class]) { 177| 0| dictionaryMatcher(createDictionary(_rawObject)); 178| 0| } 179| 0|} 180| | 181| |- (NSArray *_Nullable)arrayOrNil 182| 0|{ 183| 0| __block NSArray *result = nil; 184| 0| [self matchArray:^(NSArray *_Nonnull a) { 185| 0| result = [a copy]; 186| 0| } dictionary:nil string:nil number:nil null:nil]; 187| 0| return result; 188| 0|} 189| | 190| |- (NSDictionary *_Nullable)dictionaryOrNil 191| 0|{ 192| 0| __block NSDictionary *result = nil; 193| 0| [self matchArray:nil dictionary:^(NSDictionary *_Nonnull d) { 194| 0| result = [d copy]; 195| 0| } string:nil number:nil null:nil]; 196| 0| return result; 197| 0|} 198| | 199| |- (NSString *_Nullable)stringOrNil 200| 0|{ 201| 0| __block NSString *result = nil; 202| 0| [self matchArray:nil dictionary:nil string:^(NSString *_Nonnull s) { 203| 0| result = [s copy]; 204| 0| } number:nil null:nil]; 205| 0| return result; 206| 0|} 207| | 208| |- (NSNumber *_Nullable)numberOrNil 209| 0|{ 210| 0| __block NSNumber *result = nil; 211| 0| [self matchArray:nil dictionary:nil string:nil number:^(NSNumber *_Nonnull n) { 212| 0| result = n; 213| 0| } null:nil]; 214| 0| return result; 215| 0|} 216| | 217| |- (NSNull *_Nullable)nullOrNil 218| 0|{ 219| 0| __block NSNull *result = nil; 220| 0| [self matchArray:nil dictionary:nil string:nil number:nil null:^{ 221| 0| result = [NSNull null]; 222| 0| }]; 223| 0| return result; 224| 0|} 225| | 226| |@end 227| | 228| |FBSDKJSONValue *_Nullable FBSDKCreateJSONFromString(NSString *_Nullable string, NSError *__autoreleasing *errorRef) 229| 0|{ 230| 0| return 231| 0| [[FBSDKJSONValue alloc] initWithPotentialJSONObject:[FBSDKBasicUtility objectForJSONString:string error:errorRef]]; 232| 0|} /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKLibAnalyzer.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKLibAnalyzer.h" 20| | 21| |#import 22| | 23| |#import "FBSDKTypeUtility.h" 24| | 25| |@implementation FBSDKLibAnalyzer 26| | 27| |static NSMutableDictionary *_methodMapping; 28| | 29| |+ (void)initialize 30| 0|{ 31| 0| _methodMapping = [NSMutableDictionary dictionary]; 32| 0|} 33| | 34| |+ (NSDictionary *)getMethodsTable:(NSArray *)prefixes 35| | frameworks:(NSArray *)frameworks 36| 0|{ 37| 0| NSArray *allClasses = [self _getClassNames:prefixes frameworks:frameworks]; 38| 0| for (NSString *className in allClasses) { 39| 0| Class class = NSClassFromString(className); 40| 0| if (class) { 41| 0| [self _addClass:class isClassMethod:NO]; 42| 0| [self _addClass:object_getClass(class) isClassMethod:YES]; 43| 0| } 44| 0| } 45| 0| @synchronized(_methodMapping) { 46| 0| return [_methodMapping copy]; 47| 0| } 48| 0|} 49| | 50| |+ (nullable NSArray *)symbolicateCallstack:(NSArray *)callstack 51| | methodMapping:(NSDictionary *)methodMapping 52| 0|{ 53| 0| if (!callstack || !methodMapping) { 54| 0| return nil; 55| 0| } 56| 0| NSArray *sortedAllAddress = [methodMapping.allKeys sortedArrayUsingComparator:^NSComparisonResult (id _Nonnull obj1, id _Nonnull obj2) { 57| 0| return [obj1 compare:obj2]; 58| 0| }]; 59| | 60| 0| BOOL containsFBSDKFunction = NO; 61| 0| NSInteger nonSDKMethodCount = 0; 62| 0| NSMutableArray *symbolicatedCallstack = [NSMutableArray array]; 63| | 64| 0| for (NSUInteger i = 0; i < callstack.count; i++) { 65| 0| NSString *rawAddress = [self _getAddress:[FBSDKTypeUtility array:callstack objectAtIndex:i]]; 66| 0| if (rawAddress.length < 10) { 67| 0| continue; 68| 0| } 69| 0| NSString *addressString = [NSString stringWithFormat:@"0x%@", [rawAddress substringWithRange:NSMakeRange(rawAddress.length - 10, 10)]]; 70| 0| NSString *methodAddress = [self _searchMethod:addressString sortedAllAddress:sortedAllAddress]; 71| | 72| 0| if (methodAddress) { 73| 0| containsFBSDKFunction = YES; 74| 0| nonSDKMethodCount == 0 ?: [FBSDKTypeUtility array:symbolicatedCallstack addObject:[NSString stringWithFormat:@"(%ld DEV METHODS)", (long)nonSDKMethodCount]]; 75| 0| nonSDKMethodCount = 0; 76| 0| NSString *methodName = [FBSDKTypeUtility dictionary:methodMapping objectForKey:methodAddress ofType:NSObject.class]; 77| | 78| | // filter out cxx_destruct 79| 0| if ([methodName containsString:@".cxx_destruct"]) { 80| 0| return nil; 81| 0| } 82| 0| [FBSDKTypeUtility array:symbolicatedCallstack addObject:[NSString stringWithFormat:@"%@%@", methodName, [self _getOffset:addressString secondString:methodAddress]]]; 83| 0| } else { 84| 0| nonSDKMethodCount++; 85| 0| } 86| 0| } 87| 0| nonSDKMethodCount == 0 ?: [FBSDKTypeUtility array:symbolicatedCallstack addObject:[NSString stringWithFormat:@"(%ld DEV METHODS)", (long)nonSDKMethodCount]]; 88| | 89| 0| return containsFBSDKFunction ? symbolicatedCallstack : nil; 90| 0|} 91| | 92| |#pragma mark - Private Methods 93| | 94| |+ (NSArray *)_getClassNames:(NSArray *)prefixes 95| | frameworks:(NSArray *)frameworks 96| 0|{ 97| 0| NSMutableArray *classNames = [NSMutableArray new]; 98| | // from main bundle 99| 0| [classNames addObjectsFromArray:[self _getClassesFrom:[[NSBundle mainBundle] executablePath] 100| 0| prefixes:prefixes]]; 101| | // from dynamic libraries 102| 0| if (frameworks.count > 0) { 103| 0| unsigned int count = 0; 104| 0| const char **images = objc_copyImageNames(&count); 105| 0| for (int i = 0; i < count; i++) { 106| 0| NSString *image = [NSString stringWithUTF8String:images[i]]; 107| 0| for (NSString *framework in frameworks) { 108| 0| if ([image containsString:framework]) { 109| 0| [classNames addObjectsFromArray:[self _getClassesFrom:image 110| 0| prefixes:nil]]; 111| 0| } 112| 0| } 113| 0| } 114| 0| free(images); 115| 0| } 116| | 117| 0| return [classNames copy]; 118| 0|} 119| | 120| |+ (NSArray *)_getClassesFrom:(NSString *)image 121| | prefixes:(NSArray *)prefixes 122| 0|{ 123| 0| NSMutableArray *classNames = [NSMutableArray array]; 124| 0| unsigned int count = 0; 125| 0| const char **classes = objc_copyClassNamesForImage([image UTF8String], &count); 126| 0| for (unsigned int i = 0; i < count; i++) { 127| 0| NSString *className = [NSString stringWithUTF8String:classes[i]]; 128| 0| if (prefixes.count > 0) { 129| 0| for (NSString *prefix in prefixes) { 130| 0| if ([className hasPrefix:prefix]) { 131| 0| [FBSDKTypeUtility array:classNames addObject:className]; 132| 0| break; 133| 0| } 134| 0| } 135| 0| } else { 136| 0| [FBSDKTypeUtility array:classNames addObject:className]; 137| 0| } 138| 0| } 139| 0| free(classes); 140| 0| return [classNames copy]; 141| 0|} 142| | 143| |+ (void)_addClass:(Class)class 144| | isClassMethod:(BOOL)isClassMethod 145| 0|{ 146| 0| unsigned int methodsCount = 0; 147| 0| Method *methods = class_copyMethodList(class, &methodsCount); 148| | 149| 0| NSString *methodType = isClassMethod ? @"+" : @"-"; 150| | 151| 0| for (unsigned int i = 0; i < methodsCount; i++) { 152| 0| Method method = methods[i]; 153| | 154| 0| if (method) { 155| 0| SEL selector = method_getName(method); 156| | 157| 0| IMP methodImplementation = class_getMethodImplementation(class, selector); 158| 0| NSString *methodAddress = [NSString stringWithFormat:@"0x%010lx", (unsigned long)methodImplementation]; 159| 0| NSString *methodName = [NSString stringWithFormat:@"%@[%@ %@]", 160| 0| methodType, 161| 0| NSStringFromClass(class), 162| 0| NSStringFromSelector(selector)]; 163| | 164| 0| if (methodAddress && methodName) { 165| 0| @synchronized(_methodMapping) { 166| 0| [FBSDKTypeUtility dictionary:_methodMapping setObject:methodName forKey:methodAddress]; 167| 0| } 168| 0| } 169| 0| } 170| 0| } 171| 0| free(methods); 172| 0|} 173| | 174| |+ (nullable NSString *)_getAddress:(nullable NSString *)callstackEntry 175| 0|{ 176| 0| if ([callstackEntry isKindOfClass:[NSString class]]) { 177| 0| NSArray *components = [callstackEntry componentsSeparatedByString:@" "]; 178| 0| for (NSString *component in components) { 179| 0| if ([component containsString:@"0x"]) { 180| 0| return component; 181| 0| } 182| 0| } 183| 0| } 184| 0| return nil; 185| 0|} 186| | 187| |+ (NSString *)_getOffset:(NSString *)firstString 188| | secondString:(NSString *)secondString 189| 0|{ 190| 0| unsigned long long first = 0, second = 0; 191| 0| NSScanner *scanner = [NSScanner scannerWithString:firstString]; 192| 0| [scanner scanHexLongLong:&first]; 193| | 194| 0| scanner = [NSScanner scannerWithString:secondString]; 195| 0| [scanner scanHexLongLong:&second]; 196| | 197| 0| unsigned long long difference = first - second; 198| 0| return [NSString stringWithFormat:@"+%llu", difference]; 199| 0|} 200| | 201| |+ (nullable NSString *)_searchMethod:(NSString *)address 202| | sortedAllAddress:(NSArray *)sortedAllAddress 203| 0|{ 204| 0| if (0 == sortedAllAddress.count) { 205| 0| return nil; 206| 0| } 207| 0| NSString *lowestAddress = [FBSDKTypeUtility array:sortedAllAddress objectAtIndex:0]; 208| 0| NSString *highestAddress = [FBSDKTypeUtility array:sortedAllAddress objectAtIndex:sortedAllAddress.count - 1]; 209| | 210| 0| if ([address compare:lowestAddress] == NSOrderedAscending || [address compare:highestAddress] == NSOrderedDescending) { 211| 0| return nil; 212| 0| } 213| | 214| 0| if ([address compare:lowestAddress] == NSOrderedSame) { 215| 0| return lowestAddress; 216| 0| } 217| | 218| 0| if ([address compare:highestAddress] == NSOrderedSame) { 219| 0| return highestAddress; 220| 0| } 221| | 222| 0| NSUInteger index = [sortedAllAddress indexOfObject:address 223| 0| inSortedRange:NSMakeRange(0, sortedAllAddress.count - 1) 224| 0| options:NSBinarySearchingInsertionIndex 225| 0| usingComparator:^NSComparisonResult (id _Nonnull obj1, id _Nonnull obj2) { 226| 0| return [obj1 compare:obj2]; 227| 0| }]; 228| 0| return [FBSDKTypeUtility array:sortedAllAddress objectAtIndex:index - 1]; 229| 0|} 230| | 231| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKSafeCast.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKSafeCast.h" 20| | 21| |id _FBSDKCastToClassOrNilUnsafeInternal(id object, Class klass) 22| 0|{ 23| 0| return [(NSObject *)object isKindOfClass:klass] ? object : nil; 24| 0|} 25| | 26| |id _FBSDKCastToProtocolOrNilUnsafeInternal(id object, Protocol *protocol) 27| 0|{ 28| 0| return [(NSObject *)object conformsToProtocol:protocol] ? object : nil; 29| 0|} /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKTypeUtility.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKTypeUtility.h" 20| | 21| |@implementation FBSDKTypeUtility 22| | 23| |#pragma mark - Class Methods 24| | 25| |+ (NSArray *)arrayValue:(id)object 26| 0|{ 27| 0| return (NSArray *)[self _objectValue:object ofClass:[NSArray class]]; 28| 0|} 29| | 30| |+ (nullable id)array:(NSArray *)array objectAtIndex:(NSUInteger)index 31| 0|{ 32| 0| if ([self arrayValue:array] && index < array.count) { 33| 0| return [array objectAtIndex:index]; 34| 0| } 35| | 36| 0| return nil; 37| 0|} 38| | 39| |+ (void)array:(NSMutableArray *)array addObject:(id)object 40| 0|{ 41| 0| if (object && [array isKindOfClass:NSMutableArray.class]) { 42| 0| [array addObject:object]; 43| 0| } 44| 0|} 45| | 46| |+ (void)array:(NSMutableArray *)array addObject:(nullable id)object atIndex:(NSUInteger)index 47| 0|{ 48| 0| if (object && [array isKindOfClass:NSMutableArray.class]) { 49| 0| if (index < array.count) { 50| 0| [array insertObject:object atIndex:index]; 51| 0| } else if (index == array.count) { 52| 0| [array addObject:object]; 53| 0| } 54| 0| } 55| 0|} 56| | 57| |+ (BOOL)boolValue:(id)object 58| 0|{ 59| 0| if ([object isKindOfClass:[NSNumber class]]) { 60| | // @0 or @NO returns NO, otherwise YES 61| 0| return ((NSNumber *)object).boolValue; 62| 0| } else if ([object isKindOfClass:[NSString class]]) { 63| | // Returns YES on encountering one of "Y", "y", "T", "t", or a digit 1-9, otherwise NO 64| 0| return ((NSString *)object).boolValue; 65| 0| } else { 66| 0| return ([self objectValue:object] != nil); 67| 0| } 68| 0|} 69| | 70| |+ (NSDictionary *)dictionaryValue:(id)object 71| 0|{ 72| 0| return (NSDictionary *)[self _objectValue:object ofClass:[NSDictionary class]]; 73| 0|} 74| | 75| |+ (id)dictionary:(NSDictionary *)dictionary objectForKey:(NSString *)key ofType:(Class)type 76| 0|{ 77| 0| id potentialValue = [[self dictionaryValue:dictionary] objectForKey:key]; 78| | 79| 0| if ([potentialValue isKindOfClass:type]) { 80| 0| return potentialValue; 81| 0| } else { 82| 0| return nil; 83| 0| } 84| 0|} 85| | 86| |+ (void)dictionary:(NSMutableDictionary *)dictionary setObject:(id)object forKey:(id)key 87| 0|{ 88| 0| if (object && key) { 89| 0| dictionary[key] = object; 90| 0| } 91| 0|} 92| | 93| |+ (void)dictionary:(NSDictionary *)dictionary enumerateKeysAndObjectsUsingBlock:(void(NS_NOESCAPE ^)(id key, id obj, BOOL *stop))block 94| 0|{ 95| 0| NSDictionary *validDictionary = [self dictionaryValue:dictionary]; 96| 0| if (validDictionary) { 97| 0| [validDictionary enumerateKeysAndObjectsUsingBlock:block]; 98| 0| } 99| 0|} 100| | 101| |+ (NSNumber *)numberValue:(id)object 102| 0|{ 103| 0| return [self _objectValue:object ofClass:NSNumber.class]; 104| 0|} 105| | 106| |+ (NSInteger)integerValue:(id)object 107| 0|{ 108| 0| if ([object isKindOfClass:[NSNumber class]]) { 109| 0| return ((NSNumber *)object).integerValue; 110| 0| } else if ([object isKindOfClass:[NSString class]]) { 111| 0| return ((NSString *)object).integerValue; 112| 0| } else { 113| 0| return 0; 114| 0| } 115| 0|} 116| | 117| |+ (NSString *)stringValueOrNil:(id)object 118| 0|{ 119| 0| return [self _objectValue:object ofClass:NSString.class]; 120| 0|} 121| | 122| |+ (id)objectValue:(id)object 123| 0|{ 124| 0| return ([object isKindOfClass:[NSNull class]] ? nil : object); 125| 0|} 126| | 127| |+ (NSString *)coercedToStringValue:(id)object 128| 0|{ 129| 0| if ([object isKindOfClass:[NSString class]]) { 130| 0| return (NSString *)object; 131| 0| } else if ([object isKindOfClass:[NSNumber class]]) { 132| 0| return ((NSNumber *)object).stringValue; 133| 0| } else if ([object isKindOfClass:[NSURL class]]) { 134| 0| return ((NSURL *)object).absoluteString; 135| 0| } else { 136| 0| return nil; 137| 0| } 138| 0|} 139| | 140| |+ (NSTimeInterval)timeIntervalValue:(id)object 141| 0|{ 142| 0| if ([object isKindOfClass:[NSNumber class]]) { 143| 0| return ((NSNumber *)object).doubleValue; 144| 0| } else if ([object isKindOfClass:[NSString class]]) { 145| 0| return ((NSString *)object).doubleValue; 146| 0| } else { 147| 0| return 0; 148| 0| } 149| 0|} 150| | 151| |+ (NSUInteger)unsignedIntegerValue:(id)object 152| 0|{ 153| 0| if ([object isKindOfClass:[NSNumber class]]) { 154| 0| return ((NSNumber *)object).unsignedIntegerValue; 155| 0| } else { 156| | // there is no direct support for strings containing unsigned values > NSIntegerMax - not worth writing ourselves 157| | // right now, so just cap unsigned values at NSIntegerMax until we have a need for larger 158| 0| NSInteger integerValue = [self integerValue:object]; 159| 0| if (integerValue < 0) { 160| 0| integerValue = 0; 161| 0| } 162| 0| return (NSUInteger)integerValue; 163| 0| } 164| 0|} 165| | 166| |+ (NSURL *)URLValue:(id)object 167| 0|{ 168| 0| if ([object isKindOfClass:[NSURL class]]) { 169| 0| return (NSURL *)object; 170| 0| } else if ([object isKindOfClass:[NSString class]]) { 171| 0| return [NSURL URLWithString:(NSString *)object]; 172| 0| } else { 173| 0| return nil; 174| 0| } 175| 0|} 176| | 177| |+ (BOOL)isValidJSONObject:(id)obj 178| 0|{ 179| 0| return [NSJSONSerialization isValidJSONObject:obj]; 180| 0|} 181| | 182| |+ (NSData *)dataWithJSONObject:(id)obj options:(NSJSONWritingOptions)opt error:(NSError *__autoreleasing _Nullable *)error 183| 0|{ 184| 0| NSData *data; 185| | 186| 0| @try { 187| 0| data = [NSJSONSerialization dataWithJSONObject:obj options:opt error:error]; 188| 0| } @catch (NSException *exception) { 189| 0| NSLog(@"FBSDKJSONSerialization - dataWithJSONObject:options:error failed: %@", exception.reason); 190| 0| } 191| 0| return data; 192| 0|} 193| | 194| |+ (id)JSONObjectWithData:(NSData *)data options:(NSJSONReadingOptions)opt error:(NSError *__autoreleasing _Nullable *)error 195| 0|{ 196| 0| if (![data isKindOfClass:NSData.class]) { 197| 0| return nil; 198| 0| } 199| | 200| 0| id object; 201| 0| @try { 202| 0| object = [NSJSONSerialization JSONObjectWithData:data options:opt error:error]; 203| 0| } @catch (NSException *exception) { 204| 0| NSLog(@"FBSDKJSONSerialization - JSONObjectWithData:options:error failed: %@", exception.reason); 205| 0| } 206| 0| return object; 207| 0|} 208| | 209| |#pragma mark - Helper Methods 210| | 211| |+ (id)_objectValue:(id)object ofClass:(Class)expectedClass 212| 0|{ 213| 0| return ([object isKindOfClass:expectedClass] ? object : nil); 214| 0|} 215| | 216| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKURLSession.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKURLSession.h" 20| | 21| |#import 22| | 23| |#import "FBSDKBasicUtility.h" 24| |#import "FBSDKURLSessionTask.h" 25| | 26| |// At some point this default conformance declaration needs to be moved out of 27| |// this class and treated like the dependency it is. 28| |@interface NSURLSession (SessionProviding) 29| |@end 30| | 31| |@implementation FBSDKURLSession 32| | 33| |- (instancetype)initWithDelegate:(id)delegate 34| | delegateQueue:(NSOperationQueue *)queue 35| 0|{ 36| 0| if ((self = [super init])) { 37| 0| self.delegate = delegate; 38| 0| self.delegateQueue = queue; 39| 0| } 40| 0| return self; 41| 0|} 42| | 43| |- (void)executeURLRequest:(NSURLRequest *)request 44| | completionHandler:(FBSDKURLSessionTaskBlock)handler 45| 0|{ 46| 0| if (!self.valid) { 47| 0| [self updateSessionWithBlock:^{ 48| 0| FBSDKURLSessionTask *task = [[FBSDKURLSessionTask alloc] initWithRequest:request fromSession:self.session completionHandler:handler]; 49| 0| [task start]; 50| 0| }]; 51| 0| } else { 52| 0| FBSDKURLSessionTask *task = [[FBSDKURLSessionTask alloc] initWithRequest:request fromSession:self.session completionHandler:handler]; 53| 0| [task start]; 54| 0| } 55| 0|} 56| | 57| |- (void)updateSessionWithBlock:(dispatch_block_t)block 58| 0|{ 59| 0| if (!self.valid) { 60| 0| self.session = [NSURLSession sessionWithConfiguration:[NSURLSessionConfiguration defaultSessionConfiguration] 61| 0| delegate:_delegate 62| 0| delegateQueue:_delegateQueue]; 63| 0| } 64| 0| block(); 65| 0|} 66| | 67| |- (void)invalidateAndCancel 68| 0|{ 69| 0| [self.session invalidateAndCancel]; 70| 0| self.session = nil; 71| 0|} 72| | 73| |- (BOOL)valid 74| 0|{ 75| 0| return self.session != nil; 76| 0|} 77| | 78| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKURLSessionTask.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKURLSessionTask.h" 20| | 21| |#import "FBSDKSessionProviding.h" 22| | 23| |@implementation FBSDKURLSessionTask 24| | 25| |- (instancetype)init 26| 0|{ 27| 0| if ((self = [super init])) { 28| 0| _requestStartDate = [NSDate date]; 29| 0| } 30| 0| return self; 31| 0|} 32| | 33| |- (instancetype)initWithRequest:(NSURLRequest *)request 34| | fromSession:(id)session 35| | completionHandler:(FBSDKURLSessionTaskBlock)handler 36| 0|{ 37| 0| if ((self = [self init])) { 38| 0| self.requestStartTime = (uint64_t)([self.requestStartDate timeIntervalSince1970] * 1000); 39| 0| self.task = [session dataTaskWithRequest:request completionHandler:handler]; 40| 0| } 41| 0| return self; 42| 0|} 43| | 44| |- (NSURLSessionTaskState)state 45| 0|{ 46| 0| return self.task.state; 47| 0|} 48| | 49| |#pragma mark - Task State 50| | 51| |- (void)start 52| 0|{ 53| 0| [self.task resume]; 54| 0|} 55| | 56| |- (void)cancel 57| 0|{ 58| 0| [self.task cancel]; 59| 0| self.handler = nil; 60| 0|} 61| | 62| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKUserDataStore.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKUserDataStore.h" 20| | 21| |#import "FBSDKBasicUtility.h" 22| |#import "FBSDKTypeUtility.h" 23| | 24| |static NSString *const FBSDKUserDataKey = @"com.facebook.appevents.UserDataStore.userData"; 25| |static NSString *const FBSDKInternalUserDataKey = @"com.facebook.appevents.UserDataStore.internalUserData"; 26| | 27| |static NSMutableDictionary *hashedUserData; 28| |static NSMutableDictionary *internalHashedUserData; 29| |static NSMutableSet *enabledRules; 30| | 31| |static dispatch_queue_t serialQueue; 32| | 33| |// 34| |// Public event user data types 35| |// 36| | 37| |FBSDKAppEventUserDataType FBSDKAppEventEmail = @"em"; 38| |FBSDKAppEventUserDataType FBSDKAppEventFirstName = @"fn"; 39| |FBSDKAppEventUserDataType FBSDKAppEventLastName = @"ln"; 40| |FBSDKAppEventUserDataType FBSDKAppEventPhone = @"ph"; 41| |FBSDKAppEventUserDataType FBSDKAppEventDateOfBirth = @"dob"; 42| |FBSDKAppEventUserDataType FBSDKAppEventGender = @"ge"; 43| |FBSDKAppEventUserDataType FBSDKAppEventCity = @"ct"; 44| |FBSDKAppEventUserDataType FBSDKAppEventState = @"st"; 45| |FBSDKAppEventUserDataType FBSDKAppEventZip = @"zp"; 46| |FBSDKAppEventUserDataType FBSDKAppEventCountry = @"country"; 47| |FBSDKAppEventUserDataType FBSDKAppEventExternalId = @"external_id"; 48| | 49| |@implementation FBSDKUserDataStore 50| | 51| |+ (void)initialize 52| 0|{ 53| 0| serialQueue = dispatch_queue_create("com.facebook.appevents.UserDataStore", DISPATCH_QUEUE_SERIAL); 54| 0| hashedUserData = [FBSDKUserDataStore initializeUserData:FBSDKUserDataKey]; 55| 0| internalHashedUserData = [FBSDKUserDataStore initializeUserData:FBSDKInternalUserDataKey]; 56| 0| enabledRules = [NSMutableSet new]; 57| 0|} 58| | 59| |+ (void)setUserEmail:(nullable NSString *)email 60| | firstName:(nullable NSString *)firstName 61| | lastName:(nullable NSString *)lastName 62| | phone:(nullable NSString *)phone 63| | dateOfBirth:(nullable NSString *)dateOfBirth 64| | gender:(nullable NSString *)gender 65| | city:(nullable NSString *)city 66| | state:(nullable NSString *)state 67| | zip:(nullable NSString *)zip 68| | country:(nullable NSString *)country 69| | externalId:(nullable NSString *)externalId 70| 0|{ 71| 0| NSMutableDictionary *ud = [NSMutableDictionary new]; 72| 0| if (email) { 73| 0| [FBSDKTypeUtility dictionary:ud setObject:[FBSDKUserDataStore encryptData:email type:FBSDKAppEventEmail] forKey:FBSDKAppEventEmail]; 74| 0| } 75| 0| if (firstName) { 76| 0| [FBSDKTypeUtility dictionary:ud setObject:[FBSDKUserDataStore encryptData:firstName type:FBSDKAppEventFirstName] forKey:FBSDKAppEventFirstName]; 77| 0| } 78| 0| if (lastName) { 79| 0| [FBSDKTypeUtility dictionary:ud setObject:[FBSDKUserDataStore encryptData:lastName type:FBSDKAppEventLastName] forKey:FBSDKAppEventLastName]; 80| 0| } 81| 0| if (phone) { 82| 0| [FBSDKTypeUtility dictionary:ud setObject:[FBSDKUserDataStore encryptData:phone type:FBSDKAppEventPhone] forKey:FBSDKAppEventPhone]; 83| 0| } 84| 0| if (dateOfBirth) { 85| 0| [FBSDKTypeUtility dictionary:ud setObject:[FBSDKUserDataStore encryptData:dateOfBirth type:FBSDKAppEventDateOfBirth] forKey:FBSDKAppEventDateOfBirth]; 86| 0| } 87| 0| if (gender) { 88| 0| [FBSDKTypeUtility dictionary:ud setObject:[FBSDKUserDataStore encryptData:gender type:FBSDKAppEventGender] forKey:FBSDKAppEventGender]; 89| 0| } 90| 0| if (city) { 91| 0| [FBSDKTypeUtility dictionary:ud setObject:[FBSDKUserDataStore encryptData:city type:FBSDKAppEventCity] forKey:FBSDKAppEventCity]; 92| 0| } 93| 0| if (state) { 94| 0| [FBSDKTypeUtility dictionary:ud setObject:[FBSDKUserDataStore encryptData:state type:FBSDKAppEventState] forKey:FBSDKAppEventState]; 95| 0| } 96| 0| if (zip) { 97| 0| [FBSDKTypeUtility dictionary:ud setObject:[FBSDKUserDataStore encryptData:zip type:FBSDKAppEventZip] forKey:FBSDKAppEventZip]; 98| 0| } 99| 0| if (country) { 100| 0| [FBSDKTypeUtility dictionary:ud setObject:[FBSDKUserDataStore encryptData:country type:FBSDKAppEventCountry] forKey:FBSDKAppEventCountry]; 101| 0| } 102| 0| if (externalId) { 103| 0| [FBSDKTypeUtility dictionary:ud setObject:[FBSDKUserDataStore encryptData:externalId type:FBSDKAppEventExternalId] forKey:FBSDKAppEventExternalId]; 104| 0| } 105| | 106| 0| dispatch_async(serialQueue, ^{ 107| 0| hashedUserData = [ud mutableCopy]; 108| 0| [[NSUserDefaults standardUserDefaults] setObject:[FBSDKUserDataStore stringByHashedData:hashedUserData] 109| 0| forKey:FBSDKUserDataKey]; 110| 0| }); 111| 0|} 112| | 113| |+ (void)setUserData:(nullable NSString *)data 114| | forType:(FBSDKAppEventUserDataType)type 115| 0|{ 116| 0| [FBSDKUserDataStore setHashData:[FBSDKUserDataStore encryptData:data type:type] 117| 0| forType:type]; 118| 0|} 119| | 120| |+ (void)setHashData:(nullable NSString *)hashData 121| | forType:(FBSDKAppEventUserDataType)type 122| 0|{ 123| 0| dispatch_async(serialQueue, ^{ 124| 0| if (!hashData) { 125| 0| [hashedUserData removeObjectForKey:type]; 126| 0| } else { 127| 0| [FBSDKTypeUtility dictionary:hashedUserData setObject:hashData forKey:type]; 128| 0| } 129| 0| [[NSUserDefaults standardUserDefaults] setObject:[FBSDKUserDataStore stringByHashedData:hashedUserData] 130| 0| forKey:FBSDKUserDataKey]; 131| 0| }); 132| 0|} 133| | 134| |+ (void)setInternalHashData:(nullable NSString *)hashData 135| | forType:(FBSDKAppEventUserDataType)type 136| 0|{ 137| 0| dispatch_async(serialQueue, ^{ 138| 0| if (!hashData) { 139| 0| [internalHashedUserData removeObjectForKey:type]; 140| 0| } else { 141| 0| internalHashedUserData[type] = hashData; 142| 0| } 143| 0| [[NSUserDefaults standardUserDefaults] setObject:[FBSDKUserDataStore stringByHashedData:internalHashedUserData] 144| 0| forKey:FBSDKInternalUserDataKey]; 145| 0| }); 146| 0|} 147| | 148| |+ (void)setEnabledRules:(NSArray *)rules 149| 0|{ 150| 0| if (rules.count > 0) { 151| 0| [enabledRules addObjectsFromArray:rules]; 152| 0| } 153| 0|} 154| | 155| |+ (void)clearUserDataForType:(FBSDKAppEventUserDataType)type 156| 0|{ 157| 0| [FBSDKUserDataStore setUserData:nil forType:type]; 158| 0|} 159| | 160| |+ (NSString *)getUserData 161| 0|{ 162| 0| return [FBSDKUserDataStore getHashedData]; 163| 0|} 164| | 165| |+ (NSString *)getHashedData 166| 0|{ 167| 0| __block NSString *hashedUserDataString; 168| 0| dispatch_sync(serialQueue, ^{ 169| 0| NSMutableDictionary *hashedUD = [NSMutableDictionary new]; 170| 0| [hashedUD addEntriesFromDictionary:hashedUserData]; 171| 0| for (NSString *key in enabledRules) { 172| 0| if (internalHashedUserData[key]) { 173| 0| hashedUD[key] = internalHashedUserData[key]; 174| 0| } 175| 0| } 176| 0| hashedUserDataString = [FBSDKUserDataStore stringByHashedData:hashedUD]; 177| 0| }); 178| 0| return hashedUserDataString; 179| 0|} 180| | 181| |+ (void)clearUserData 182| 0|{ 183| 0| [FBSDKUserDataStore setUserEmail:nil 184| 0| firstName:nil 185| 0| lastName:nil 186| 0| phone:nil 187| 0| dateOfBirth:nil 188| 0| gender:nil 189| 0| city:nil 190| 0| state:nil 191| 0| zip:nil 192| 0| country:nil 193| 0| externalId:nil]; 194| 0|} 195| | 196| |+ (NSString *)getInternalHashedDataForType:(FBSDKAppEventUserDataType)type 197| 0|{ 198| 0| __block NSString *hashedData; 199| 0| dispatch_sync(serialQueue, ^{ 200| 0| hashedData = [FBSDKTypeUtility dictionary:internalHashedUserData objectForKey:type ofType:NSObject.class]; 201| 0| }); 202| 0| return hashedData; 203| 0|} 204| | 205| |#pragma mark - Helper Methods 206| | 207| |+ (NSMutableDictionary *)initializeUserData:(NSString *)userDataKey 208| 0|{ 209| 0| NSString *userData = [[NSUserDefaults standardUserDefaults] stringForKey:userDataKey]; 210| 0| NSMutableDictionary *hashedUD = nil; 211| 0| if (userData) { 212| 0| hashedUD = (NSMutableDictionary *)[FBSDKTypeUtility JSONObjectWithData:[userData dataUsingEncoding:NSUTF8StringEncoding] 213| 0| options: NSJSONReadingMutableContainers 214| 0| error: nil]; 215| 0| } 216| 0| if (!hashedUD) { 217| 0| hashedUD = [NSMutableDictionary new]; 218| 0| } 219| 0| return hashedUD; 220| 0|} 221| | 222| |+ (NSString *)stringByHashedData:(id)hashedData 223| 0|{ 224| 0| NSError *error; 225| 0| NSData *jsonData = [FBSDKTypeUtility dataWithJSONObject:hashedData 226| 0| options:0 227| 0| error:&error]; 228| 0| if (jsonData) { 229| 0| return [[NSString alloc] initWithData:jsonData 230| 0| encoding:NSUTF8StringEncoding]; 231| 0| } else { 232| 0| return @""; 233| 0| } 234| 0|} 235| | 236| |+ (NSString *)encryptData:(NSString *)data 237| | type:(FBSDKAppEventUserDataType)type 238| 0|{ 239| 0| if (data.length == 0 || [FBSDKUserDataStore maybeSHA256Hashed:data]) { 240| 0| return data; 241| 0| } 242| 0| return [FBSDKBasicUtility SHA256Hash:[FBSDKUserDataStore normalizeData:data type:type]]; 243| 0|} 244| | 245| |+ (NSString *)normalizeData:(NSString *)data 246| | type:(FBSDKAppEventUserDataType)type 247| 0|{ 248| 0| NSString *normalizedData = @""; 249| 0| NSSet *set = [NSSet setWithArray: 250| 0| @[FBSDKAppEventEmail, FBSDKAppEventFirstName, FBSDKAppEventLastName, FBSDKAppEventCity, FBSDKAppEventState, FBSDKAppEventCountry]]; 251| 0| if ([set containsObject:type]) { 252| 0| normalizedData = [data stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceCharacterSet]]; 253| 0| normalizedData = normalizedData.lowercaseString; 254| 0| } else if ([type isEqualToString:FBSDKAppEventPhone]) { 255| 0| NSError *error = nil; 256| 0| NSRegularExpression *regex = [NSRegularExpression regularExpressionWithPattern:@"[^0-9]" 257| 0| options:NSRegularExpressionCaseInsensitive 258| 0| error:&error 259| 0| ]; 260| 0| normalizedData = [regex stringByReplacingMatchesInString:data 261| 0| options:0 262| 0| range:NSMakeRange(0, data.length) 263| 0| withTemplate:@"" 264| 0| ]; 265| 0| } else if ([type isEqualToString:FBSDKAppEventGender]) { 266| 0| NSString *temp = [data stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceCharacterSet]]; 267| 0| temp = temp.lowercaseString; 268| 0| normalizedData = temp.length > 0 ? [temp substringToIndex:1] : @""; 269| 0| } else if ([type isEqualToString:FBSDKAppEventExternalId]) { 270| 0| normalizedData = data; 271| 0| } 272| 0| return normalizedData; 273| 0|} 274| | 275| |+ (BOOL)maybeSHA256Hashed:(NSString *)data 276| 0|{ 277| 0| NSRange range = [data rangeOfString:@"[A-Fa-f0-9]{64}" options:NSRegularExpressionSearch]; 278| 0| return (data.length == 64) && (range.location != NSNotFound); 279| 0|} 280| | 281| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/include/FBSDKSafeCast.h: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import 20| | 21| |#ifndef FBSDK_CAST_TO_CLASS_OR_NIL_FUNC 22| | #define FBSDK_CAST_TO_CLASS_OR_NIL_FUNC 23| | #ifdef __cplusplus 24| |extern "C" { 25| | #endif 26| |/** Use the type-safe FBSDK_CAST_TO_CLASS_OR_NIL instead. */ 27| |id _FBSDKCastToClassOrNilUnsafeInternal(id object, Class klass); 28| | #ifdef __cplusplus 29| |} 30| | #endif 31| |#endif 32| | 33| |#ifndef FBSDK_CAST_TO_CLASS_OR_NIL 34| 0| #define FBSDK_CAST_TO_CLASS_OR_NIL(obj_, class_) ((class_ *)_FBSDKCastToClassOrNilUnsafeInternal(obj_, [class_ class])) 35| |#endif 36| | 37| |#ifndef FBSDK_CAST_TO_PROTOCOL_OR_NIL_FUNC 38| | #define FBSDK_CAST_TO_PROTOCOL_OR_NIL_FUNC 39| | #ifdef __cplusplus 40| |extern "C" { 41| | #endif 42| |/** Use the type-safe FBSDK_CAST_TO_PROTOCOL_OR_NIL instead. */ 43| |id _FBSDKCastToProtocolOrNilUnsafeInternal(id object, Protocol *protocol); 44| | #ifdef __cplusplus 45| |} 46| | #endif 47| |#endif 48| | 49| |#ifndef FBSDK_CAST_TO_PROTOCOL_OR_NIL 50| | #define FBSDK_CAST_TO_PROTOCOL_OR_NIL(obj_, protocol_) ((id)_FBSDKCastToProtocolOrNilUnsafeInternal(obj_, @protocol(protocol_))) 51| |#endif <<<<<< EOF # path=Bolts#Common#BFCancellationTokenSource.h.gcov.reduced -: 0:Source:Bolts/Common/BFCancellationTokenSource.h <<<<<< EOF # path=Parse#Internal#Commands#PFRESTObjectCommand.m.gcov.reduced -: 0:Source:Parse/Internal/Commands/PFRESTObjectCommand.m <<<<<< EOF # path=Parse#Internal#Purchase#Controller#PFPurchaseController.m.gcov.reduced -: 0:Source:Parse/Internal/Purchase/Controller/PFPurchaseController.m <<<<<< EOF # path=FBSDKCoreKit#Internal#FBSDKDynamicFrameworkLoader.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/FBSDKDynamicFrameworkLoader.m <<<<<< EOF # path=FBSDKCoreKit#Internal#ServerConfiguration#FBSDKDialogConfiguration.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/ServerConfiguration/FBSDKDialogConfiguration.m <<<<<< EOF # path=Parse#Internal#LocalDataStore#SQLite#PFSQLiteDatabaseController.h.gcov.reduced -: 0:Source:Parse/Internal/LocalDataStore/SQLite/PFSQLiteDatabaseController.h <<<<<< EOF # path=Parse#PFPolygon.h.gcov.reduced -: 0:Source:Parse/PFPolygon.h <<<<<< EOF # path=Parse#Internal#Commands#PFRESTObjectBatchCommand.m.gcov.reduced -: 0:Source:Parse/Internal/Commands/PFRESTObjectBatchCommand.m <<<<<< EOF # path=Parse#Internal#Commands#PFRESTCloudCommand.m.gcov.reduced -: 0:Source:Parse/Internal/Commands/PFRESTCloudCommand.m <<<<<< EOF # path=#Applications#Xcode_13.1.app#Contents#Developer#Platforms#iPhoneSimulator.platform#Developer#SDKs#iPhoneSimulator15.0.sdk#usr#include#dispatch#queue.h.gcov.reduced -: 0:Source:/Applications/Xcode_13.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator15.0.sdk/usr/include/dispatch/queue.h #####:584: #####:585: #####:586: <<<<<< EOF # path=Parse#Internal#Commands#PFRESTCommand.h.gcov.reduced -: 0:Source:Parse/Internal/Commands/PFRESTCommand.h <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#SKAdNetwork#FBSDKSKAdNetworkReporter.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/SKAdNetwork/FBSDKSKAdNetworkReporter.m <<<<<< EOF # path=#Applications#Xcode_13.1.app#Contents#Developer#Platforms#iPhoneSimulator.platform#Developer#SDKs#iPhoneSimulator15.0.sdk#usr#include#c++#v1#__bits.gcov.reduced -: 0:Source:/Applications/Xcode_13.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator15.0.sdk/usr/include/c++/v1/__bits #####:41: <<<<<< EOF # path=FBSDKCoreKit#FBSDKURL.m.gcov.reduced -: 0:Source:FBSDKCoreKit/FBSDKURL.m <<<<<< EOF # path=Parse#Internal#Commands#PFRESTUserCommand.h.gcov.reduced -: 0:Source:Parse/Internal/Commands/PFRESTUserCommand.h <<<<<< EOF # path=Parse#Internal#Relation#State#PFMutableRelationState.m.gcov.reduced -: 0:Source:Parse/Internal/Relation/State/PFMutableRelationState.m <<<<<< EOF # path=#Applications#Xcode_13.1.app#Contents#Developer#Platforms#iPhoneSimulator.platform#Developer#SDKs#iPhoneSimulator15.0.sdk#usr#include#c++#v1#new.gcov.reduced -: 0:Source:/Applications/Xcode_13.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator15.0.sdk/usr/include/c++/v1/new #####:233: #####:235: #####:243: #####:245: #####:249: #####:252: #####:261: #####:266: #####:269: #####:276: #####:279: <<<<<< EOF # path=FBSDKCoreKit#FBSDKProfile.h.gcov.reduced -: 0:Source:FBSDKCoreKit/FBSDKProfile.h <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#Internal#PFCoreManager.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/Internal/PFCoreManager.m #####:98: <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#ML#FBSDKModelParser.mm.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/ML/FBSDKModelParser.mm <<<<<< EOF # path=FBSDKCoreKit#Internal#Cryptography#FBSDKCrypto.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/Cryptography/FBSDKCrypto.m <<<<<< EOF # path=Parse#Internal#HTTPRequest#PFURLConstructor.m.gcov.reduced -: 0:Source:Parse/Internal/HTTPRequest/PFURLConstructor.m <<<<<< EOF # path=Parse#Internal#Push#ChannelsController#PFPushChannelsController.h.gcov.reduced -: 0:Source:Parse/Internal/Push/ChannelsController/PFPushChannelsController.h <<<<<< EOF # path=Parse#Internal#ACL#State#PFACLState.m.gcov.reduced -: 0:Source:Parse/Internal/ACL/State/PFACLState.m <<<<<< EOF # path=Parse#Internal#PFCommandResult.m.gcov.reduced -: 0:Source:Parse/Internal/PFCommandResult.m <<<<<< EOF # path=#Applications#Xcode_13.1.app#Contents#Developer#Platforms#iPhoneSimulator.platform#Developer#SDKs#iPhoneSimulator15.0.sdk#usr#include#c++#v1#__memory#base.h.gcov.reduced -: 0:Source:/Applications/Xcode_13.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator15.0.sdk/usr/include/c++/v1/__memory/base.h #####:33: #####:34: #####:35: <<<<<< EOF # path=Parse#Internal#Persistence#PFPersistenceController.h.gcov.reduced -: 0:Source:Parse/Internal/Persistence/PFPersistenceController.h <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#Internal#KeyValueCache#PFKeyValueCache.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/Internal/KeyValueCache/PFKeyValueCache.m #####:151: <<<<<< EOF # path=OCMock#OCMRealObjectForwarder.m.gcov.reduced -: 0:Source:OCMock/OCMRealObjectForwarder.m <<<<<< EOF # path=Parse#Internal#ACL#State#PFMutableACLState.m.gcov.reduced -: 0:Source:Parse/Internal/ACL/State/PFMutableACLState.m <<<<<< EOF # path=Parse#Internal#Object#PinningStore#PFPinningObjectStore.h.gcov.reduced -: 0:Source:Parse/Internal/Object/PinningStore/PFPinningObjectStore.h <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#FBSDKPaymentObserver.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/FBSDKPaymentObserver.m <<<<<< EOF # path=Parse#Internal#Config#Controller#PFCurrentConfigController.m.gcov.reduced -: 0:Source:Parse/Internal/Config/Controller/PFCurrentConfigController.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#FBSDKAppEventsAtePublisher.h.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsAtePublisher.h <<<<<< EOF # path=Parse#Internal#Query#State#PFQueryState.m.gcov.reduced -: 0:Source:Parse/Internal/Query/State/PFQueryState.m <<<<<< EOF # path=Parse#Internal#ParseManager.m.gcov.reduced -: 0:Source:Parse/Internal/ParseManager.m <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Carthage#Checkouts#facebook-ios-sdk#Sources#FBSDKCoreKit_Basics#FBSDKBasicUtility.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKBasicUtility.m #####:31: #####:32: #####:33: #####:34: #####:35: #####:36: #####:37: #####:39: #####:40: #####:42: #####:43: #####:44: #####:45: #####:46: #####:47: 1:57: 1:61: #####:62: #####:63: #####:64: #####:65: #####:66: #####:67: #####:68: #####:70: #####:71: #####:72: #####:74: 1:75: 1:76: #####:77: 1:79: 1:80: #####:82: #####:87: #####:88: #####:90: #####:91: #####:92: #####:94: #####:95: #####:96: #####:98: #####:102: #####:103: #####:105: #####:106: #####:107: #####:108: #####:109: #####:110: #####:111: #####:112: #####:113: #####:114: #####:115: #####:116: #####:117: #####:118: #####:119: #####:120: #####:121: #####:122: #####:123: #####:124: #####:126: #####:127: #####:128: #####:129: #####:131: #####:132: #####:133: #####:134: #####:135: 2:137: 2:139: 2:140: 1:141: #####:142: #####:143: 1:144: 1:146: 2:147: 1:149: 1:153: 1:154: 1:155: 1:156: 6:158: 5:159: 5:160: 1:162: 1:163: 5:164: 5:165: 5:166: 5:167: 5:168: 5:169: #####:170: #####:171: #####:172: #####:174: 5:175: 5:176: 4:177: 4:178: 5:179: 5:180: 5:181: 5:182: 1:183: 1:184: #####:185: #####:186: 1:187: 1:188: 10:190: 10:192: #####:193: 10:194: #####:195: #####:196: 10:197: 10:198: 5:202: 5:204: 5:206: 5:211: 1:215: 1:217: 1:218: 1:220: #####:221: #####:222: #####:225: #####:226: #####:227: #####:229: #####:230: #####:231: #####:232: #####:233: #####:234: #####:237: #####:238: #####:239: #####:240: #####:241: 1:242: 1:243: 1:244: #####:246: #####:248: #####:251: #####:253: #####:254: #####:256: #####:258: #####:259: #####:261: #####:262: #####:266: #####:267: #####:273: #####:275: #####:276: #####:278: #####:279: #####:282: #####:284: #####:285: #####:286: #####:287: #####:288: #####:289: #####:290: #####:292: #####:293: #####:294: #####:295: #####:296: #####:298: #####:300: #####:301: 1:303: 1:307: 1:308: 1:312: 1:314: 1:315: 1:316: 1:317: 1:319: 1:321: 1:322: 1:325: 1:326: 1:327: 5:329: 5:331: 5:332: 5:333: 5:334: 5:335: 1:337: 1:339: 1:340: 1:342: 1:346: #####:348: #####:350: #####:352: #####:353: #####:354: #####:355: #####:356: #####:358: #####:359: #####:363: #####:364: #####:365: #####:366: #####:367: #####:369: #####:370: <<<<<< EOF # path=Parse#Internal#Commands#CommandRunner#URLSession#Session#TaskDelegate#PFURLSessionJSONDataTaskDelegate.m.gcov.reduced -: 0:Source:Parse/Internal/Commands/CommandRunner/URLSession/Session/TaskDelegate/PFURLSessionJSONDataTaskDelegate.m <<<<<< EOF # path=Parse#Internal#Query#State#PFMutableQueryState.m.gcov.reduced -: 0:Source:Parse/Internal/Query/State/PFMutableQueryState.m <<<<<< EOF # path=OCMock#NSMethodSignature+OCMAdditions.m.gcov.reduced -: 0:Source:OCMock/NSMethodSignature+OCMAdditions.m <<<<<< EOF # path=FBSDKCoreKit#FBSDKUtility.m.gcov.reduced -: 0:Source:FBSDKCoreKit/FBSDKUtility.m <<<<<< EOF # path=Parse#Internal#User#CurrentUserController#PFCurrentUserController.h.gcov.reduced -: 0:Source:Parse/Internal/User/CurrentUserController/PFCurrentUserController.h <<<<<< EOF # path=FBSDKCoreKit#GraphAPI#FBSDKGraphRequestConnection.m.gcov.reduced -: 0:Source:FBSDKCoreKit/GraphAPI/FBSDKGraphRequestConnection.m <<<<<< EOF # path=Parse#Internal#Session#Controller#PFSessionController.m.gcov.reduced -: 0:Source:Parse/Internal/Session/Controller/PFSessionController.m <<<<<< EOF # path=FBSDKLoginKit#Internal#FBSDKAuthenticationTokenFactory.m.gcov.reduced -: 0:Source:FBSDKLoginKit/Internal/FBSDKAuthenticationTokenFactory.m <<<<<< EOF # path=#Applications#Xcode_13.1.app#Contents#Developer#Platforms#iPhoneSimulator.platform#Developer#SDKs#iPhoneSimulator15.0.sdk#usr#include#c++#v1#__memory#pointer_traits.h.gcov.reduced -: 0:Source:/Applications/Xcode_13.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator15.0.sdk/usr/include/c++/v1/__memory/pointer_traits.h #####:151: #####:153: <<<<<< EOF # path=FBSDKCoreKit#Internal#UI#FBSDKUIUtility.h.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/UI/FBSDKUIUtility.h <<<<<< EOF # path=Parse#Internal#LocalDataStore#OfflineStore#PFOfflineStore.h.gcov.reduced -: 0:Source:Parse/Internal/LocalDataStore/OfflineStore/PFOfflineStore.h <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#FBSDKAppEventsNumberParser.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsNumberParser.m <<<<<< EOF # path=Parse#Internal#BFTask+Private.m.gcov.reduced -: 0:Source:Parse/Internal/BFTask+Private.m <<<<<< EOF # path=Parse#Internal#ACL#DefaultACLController#PFDefaultACLController.m.gcov.reduced -: 0:Source:Parse/Internal/ACL/DefaultACLController/PFDefaultACLController.m <<<<<< EOF # path=FBSDKLoginKit#FBSDKLoginConfiguration.h.gcov.reduced -: 0:Source:FBSDKLoginKit/FBSDKLoginConfiguration.h <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#AEM#FBSDKAEMEvent.h.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMEvent.h <<<<<< EOF # path=OCMock#OCMLocation.m.gcov.reduced -: 0:Source:OCMock/OCMLocation.m <<<<<< EOF # path=FBSDKCoreKit#FBSDKSettings.m.gcov.reduced -: 0:Source:FBSDKCoreKit/FBSDKSettings.m <<<<<< EOF # path=Parse#Internal#PFSystemLogger.m.gcov.reduced -: 0:Source:Parse/Internal/PFSystemLogger.m <<<<<< EOF # path=FBSDKCoreKit#FBSDKAccessToken.m.gcov.reduced -: 0:Source:FBSDKCoreKit/FBSDKAccessToken.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#AEM#FBSDKAEMConfiguration.h.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMConfiguration.h <<<<<< EOF # path=Parse#Internal#Persistence#Group#PFFilePersistenceGroup.h.gcov.reduced -: 0:Source:Parse/Internal/Persistence/Group/PFFilePersistenceGroup.h <<<<<< EOF # path=#Applications#Xcode_13.1.app#Contents#Developer#Platforms#iPhoneSimulator.platform#Developer#SDKs#iPhoneSimulator15.0.sdk#usr#include#c++#v1#algorithm.gcov.reduced -: 0:Source:/Applications/Xcode_13.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator15.0.sdk/usr/include/c++/v1/algorithm #####:725: #####:1646: #####:1647: #####:1648: #####:1731: #####:1732: #####:1733: #####:1734: #####:1735: #####:1736: #####:1742: #####:1743: #####:1748: #####:1749: #####:2585: #####:2586: #####:2587: #####:2594: #####:2595: #####:2596: #####:2658: #####:2659: #####:2660: #####:2667: #####:2668: #####:2669: <<<<<< EOF # path=FBSDKCoreKit#Internal#TokenCaching#FBSDKTokenCache.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/TokenCaching/FBSDKTokenCache.m <<<<<< EOF # path=ParseFacebookUtils#Internal#AuthenticationProvider#iOS#PFFacebookMobileAuthenticationProvider.h.gcov.reduced -: 0:Source:ParseFacebookUtils/Internal/AuthenticationProvider/iOS/PFFacebookMobileAuthenticationProvider.h <<<<<< EOF # path=FBSDKLoginKit#FBSDKLoginManager.h.gcov.reduced -: 0:Source:FBSDKLoginKit/FBSDKLoginManager.h <<<<<< EOF # path=#Applications#Xcode_13.1.app#Contents#Developer#Platforms#iPhoneSimulator.platform#Developer#SDKs#iPhoneSimulator15.0.sdk#usr#include#c++#v1#iterator.gcov.reduced -: 0:Source:/Applications/Xcode_13.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator15.0.sdk/usr/include/c++/v1/iterator #####:655: #####:657: #####:658: #####:659: #####:663: #####:664: #####:668: #####:669: #####:670: #####:686: #####:687: #####:688: #####:694: #####:695: #####:696: #####:1474: #####:1475: #####:1480: #####:1490: #####:1491: #####:1496: #####:1497: #####:1537: #####:1546: #####:1631: #####:1632: #####:1633: #####:1683: #####:1684: #####:1685: <<<<<< EOF # path=Parse#Internal#PFLocationManager.m.gcov.reduced -: 0:Source:Parse/Internal/PFLocationManager.m <<<<<< EOF # path=Parse#Internal#Commands#PFRESTQueryCommand.m.gcov.reduced -: 0:Source:Parse/Internal/Commands/PFRESTQueryCommand.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#ML#FBSDKTensor.hpp.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/ML/FBSDKTensor.hpp <<<<<< EOF # path=FBSDKCoreKit#Internal#Network#FBSDKURLSessionProxyFactory.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/Network/FBSDKURLSessionProxyFactory.m <<<<<< EOF # path=FBSDKCoreKit#Internal#UI#FBSDKLogo.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/UI/FBSDKLogo.m <<<<<< EOF # path=OCMock#OCMArgAction.m.gcov.reduced -: 0:Source:OCMock/OCMArgAction.m <<<<<< EOF # path=FBSDKCoreKit#Internal#WebDialog#FBSDKWebDialogView.h.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/WebDialog/FBSDKWebDialogView.h <<<<<< EOF # path=OCMock#OCPartialMockObject.m.gcov.reduced -: 0:Source:OCMock/OCPartialMockObject.m <<<<<< EOF # path=Parse#Internal#PFPinningEventuallyQueue.m.gcov.reduced -: 0:Source:Parse/Internal/PFPinningEventuallyQueue.m <<<<<< EOF # path=FBSDKCoreKit#Internal#FBSDKUnarchiverProvider.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/FBSDKUnarchiverProvider.m <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#PFRelation.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/PFRelation.m #####:109: <<<<<< EOF # path=Parse#Internal#Purchase#PaymentTransactionObserver#PFPaymentTransactionObserver.m.gcov.reduced -: 0:Source:Parse/Internal/Purchase/PaymentTransactionObserver/PFPaymentTransactionObserver.m <<<<<< EOF # path=Parse#Internal#KeyValueCache#PFKeyValueCache.m.gcov.reduced -: 0:Source:Parse/Internal/KeyValueCache/PFKeyValueCache.m <<<<<< EOF # path=FBSDKCoreKit#Internal#TokenCaching#FBSDKKeychainStore.h.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/TokenCaching/FBSDKKeychainStore.h <<<<<< EOF # path=FBSDKCoreKit#AppLink#FBSDKAppLinkTarget.h.gcov.reduced -: 0:Source:FBSDKCoreKit/AppLink/FBSDKAppLinkTarget.h <<<<<< EOF # path=OCMock#OCMInvocationStub.m.gcov.reduced -: 0:Source:OCMock/OCMInvocationStub.m <<<<<< EOF # path=Parse#Internal#File#Controller#PFFileStagingController.m.gcov.reduced -: 0:Source:Parse/Internal/File/Controller/PFFileStagingController.m <<<<<< EOF # path=FBSDKCoreKit#Internal#ServerConfiguration#FBSDKServerConfiguration.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/ServerConfiguration/FBSDKServerConfiguration.m <<<<<< EOF # path=Parse#Internal#Relation#State#PFRelationState.h.gcov.reduced -: 0:Source:Parse/Internal/Relation/State/PFRelationState.h <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#PFObject.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/PFObject.m #####:234: <<<<<< EOF # path=Parse#Internal#HTTPRequest#PFHTTPURLRequestConstructor.m.gcov.reduced -: 0:Source:Parse/Internal/HTTPRequest/PFHTTPURLRequestConstructor.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#ViewHierarchy#FBSDKViewHierarchy.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/ViewHierarchy/FBSDKViewHierarchy.m <<<<<< EOF # path=Parse#PFGeoPoint.h.gcov.reduced -: 0:Source:Parse/PFGeoPoint.h <<<<<< EOF # path=Parse#Internal#Installation#Controller#PFInstallationController.h.gcov.reduced -: 0:Source:Parse/Internal/Installation/Controller/PFInstallationController.h <<<<<< EOF # path=OCMock#OCMInvocationMatcher.m.gcov.reduced -: 0:Source:OCMock/OCMInvocationMatcher.m <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#Internal#Query#Controller#PFQueryController.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/Internal/Query/Controller/PFQueryController.m #####:57: <<<<<< EOF # path=Parse#Internal#Push#Manager#PFPushManager.h.gcov.reduced -: 0:Source:Parse/Internal/Push/Manager/PFPushManager.h <<<<<< EOF # path=Parse#Internal#Relation#State#PFRelationState_Private.h.gcov.reduced -: 0:Source:Parse/Internal/Relation/State/PFRelationState_Private.h <<<<<< EOF # path=FBSDKCoreKit#Internal#ServerConfiguration#FBSDKErrorRecoveryConfiguration.h.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/ServerConfiguration/FBSDKErrorRecoveryConfiguration.h <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#Internal#PFEventuallyPin.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/Internal/PFEventuallyPin.m #####:167: <<<<<< EOF # path=FBSDKCoreKit#AppEvents#FBSDKAppEvents.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/FBSDKAppEvents.m <<<<<< EOF # path=Parse#Internal#PropertyInfo#PFPropertyInfo.h.gcov.reduced -: 0:Source:Parse/Internal/PropertyInfo/PFPropertyInfo.h <<<<<< EOF # path=Parse#Internal#Product#ProductsRequestHandler#PFProductsRequestHandler.m.gcov.reduced -: 0:Source:Parse/Internal/Product/ProductsRequestHandler/PFProductsRequestHandler.m <<<<<< EOF # path=Parse#Internal#PFKeychainStore.m.gcov.reduced -: 0:Source:Parse/Internal/PFKeychainStore.m <<<<<< EOF # path=Parse#Internal#Push#State#PFPushState.h.gcov.reduced -: 0:Source:Parse/Internal/Push/State/PFPushState.h <<<<<< EOF # path=FBSDKCoreKit#FBSDKLocation.m.gcov.reduced -: 0:Source:FBSDKCoreKit/FBSDKLocation.m <<<<<< EOF # path=Parse#Internal#File#Controller#PFFileController.m.gcov.reduced -: 0:Source:Parse/Internal/File/Controller/PFFileController.m <<<<<< EOF # path=Parse#Internal#Object#Controller#PFObjectController.m.gcov.reduced -: 0:Source:Parse/Internal/Object/Controller/PFObjectController.m <<<<<< EOF # path=FBSDKCoreKit#Internal#UI#FBSDKIcon.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/UI/FBSDKIcon.m <<<<<< EOF # path=Parse#Internal#Query#Controller#PFCachedQueryController.m.gcov.reduced -: 0:Source:Parse/Internal/Query/Controller/PFCachedQueryController.m <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Carthage#Checkouts#facebook-ios-sdk#Sources#FBSDKCoreKit_Basics#FBSDKSafeCast.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKSafeCast.m 4:21: 4:22: 4:23: 4:24: #####:26: #####:27: #####:28: #####:29: <<<<<< EOF # path=OCMock#OCMBoxedReturnValueProvider.m.gcov.reduced -: 0:Source:OCMock/OCMBoxedReturnValueProvider.m <<<<<< EOF # path=Parse#Internal#Object#Subclassing#PFObjectSubclassInfo.h.gcov.reduced -: 0:Source:Parse/Internal/Object/Subclassing/PFObjectSubclassInfo.h <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#FBSDKPaymentProductRequestor.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/FBSDKPaymentProductRequestor.m <<<<<< EOF # path=FBSDKCoreKit#FBSDKAuthenticationToken.h.gcov.reduced -: 0:Source:FBSDKCoreKit/FBSDKAuthenticationToken.h <<<<<< EOF # path=FBSDKCoreKit#Internal#Network#FBSDKGraphRequestMetadata.h.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/Network/FBSDKGraphRequestMetadata.h <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#Internal#Object#FilePersistence#PFObjectFilePersistenceController.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/Internal/Object/FilePersistence/PFObjectFilePersistenceController.m #####:46: <<<<<< EOF # path=FBSDKCoreKit#FBSDKAuthenticationTokenClaims.h.gcov.reduced -: 0:Source:FBSDKCoreKit/FBSDKAuthenticationTokenClaims.h <<<<<< EOF # path=FBSDKLoginKit#Internal#FBSDKLoginCompletion.h.gcov.reduced -: 0:Source:FBSDKLoginKit/Internal/FBSDKLoginCompletion.h <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#SKAdNetwork#FBSDKSKAdNetworkConversionConfiguration.h.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/SKAdNetwork/FBSDKSKAdNetworkConversionConfiguration.h <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#PFACL.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/PFACL.m #####:263: <<<<<< EOF # path=FBSDKCoreKit#Internal#ServerConfiguration#FBSDKErrorConfiguration.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/ServerConfiguration/FBSDKErrorConfiguration.m <<<<<< EOF # path=FBSDKCoreKit#Internal#ServerConfiguration#FBSDKGateKeeperManager.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/ServerConfiguration/FBSDKGateKeeperManager.m <<<<<< EOF # path=Parse#Internal#Analytics#Controller#PFAnalyticsController.m.gcov.reduced -: 0:Source:Parse/Internal/Analytics/Controller/PFAnalyticsController.m <<<<<< EOF # path=FBSDKLoginKit#Internal#FBSDKProfileFactory.m.gcov.reduced -: 0:Source:FBSDKLoginKit/Internal/FBSDKProfileFactory.m <<<<<< EOF # path=Parse#Internal#Object#State#PFMutableObjectState.m.gcov.reduced -: 0:Source:Parse/Internal/Object/State/PFMutableObjectState.m <<<<<< EOF # path=OCMock#NSNotificationCenter+OCMAdditions.m.gcov.reduced -: 0:Source:OCMock/NSNotificationCenter+OCMAdditions.m <<<<<< EOF # path=Parse#Internal#FieldOperation#PFFieldOperation.h.gcov.reduced -: 0:Source:Parse/Internal/FieldOperation/PFFieldOperation.h <<<<<< EOF # path=Parse#Internal#Object#LocalIdStore#PFObjectLocalIdStore.m.gcov.reduced -: 0:Source:Parse/Internal/Object/LocalIdStore/PFObjectLocalIdStore.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#FBSDKPaymentProductRequestorFactory.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/FBSDKPaymentProductRequestorFactory.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#Codeless#FBSDKCodelessIndexer.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/Codeless/FBSDKCodelessIndexer.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#SKAdNetwork#FBSDKSKAdNetworkRule.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/SKAdNetwork/FBSDKSKAdNetworkRule.m <<<<<< EOF # path=Parse#Internal#PFCoreManager.m.gcov.reduced -: 0:Source:Parse/Internal/PFCoreManager.m <<<<<< EOF # path=Parse#Internal#PFEventuallyQueue.m.gcov.reduced -: 0:Source:Parse/Internal/PFEventuallyQueue.m <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#Internal#PFDateFormatter.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/Internal/PFDateFormatter.m #####:73: <<<<<< EOF # path=Parse#Internal#PFHash.m.gcov.reduced -: 0:Source:Parse/Internal/PFHash.m <<<<<< EOF # path=Parse#Internal#Push#Controller#PFPushController.h.gcov.reduced -: 0:Source:Parse/Internal/Push/Controller/PFPushController.h <<<<<< EOF # path=#Applications#Xcode_13.1.app#Contents#Developer#Platforms#iPhoneSimulator.platform#Developer#SDKs#iPhoneSimulator15.0.sdk#usr#include#c++#v1#vector.gcov.reduced -: 0:Source:/Applications/Xcode_13.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator15.0.sdk/usr/include/c++/v1/vector #####:305: #####:349: #####:350: #####:352: #####:353: #####:355: #####:356: #####:358: #####:359: #####:362: #####:366: #####:371: #####:373: #####:374: #####:380: #####:381: #####:382: #####:385: #####:389: #####:390: #####:405: #####:406: #####:409: #####:411: #####:412: #####:413: #####:424: #####:425: #####:426: #####:427: #####:428: #####:429: #####:430: #####:434: #####:436: #####:437: #####:438: #####:439: #####:440: #####:454: #####:455: #####:456: #####:457: #####:461: #####:462: #####:463: #####:465: #####:466: #####:467: #####:468: #####:497: #####:498: #####:502: #####:515: #####:519: #####:551: #####:552: #####:553: #####:557: #####:566: #####:657: #####:658: #####:660: #####:661: #####:699: #####:700: #####:771: #####:772: #####:773: #####:774: #####:775: #####:776: #####:777: #####:831: #####:832: #####:833: #####:834: #####:835: #####:836: #####:837: #####:868: #####:869: #####:872: #####:873: #####:874: #####:875: #####:878: #####:879: #####:880: #####:881: #####:891: #####:892: #####:893: #####:894: #####:895: #####:898: #####:899: #####:903: #####:904: #####:905: #####:911: #####:924: #####:925: #####:926: #####:927: #####:928: #####:929: #####:950: #####:951: #####:953: #####:954: #####:955: #####:956: #####:957: #####:958: #####:959: #####:960: #####:961: #####:989: #####:990: #####:991: #####:992: #####:993: #####:994: #####:995: #####:996: #####:1000: #####:1001: #####:1002: #####:1004: #####:1005: #####:1006: #####:1007: #####:1008: #####:1012: #####:1013: #####:1014: #####:1015: #####:1022: #####:1023: #####:1024: #####:1025: #####:1026: #####:1027: #####:1028: #####:1029: #####:1030: #####:1031: #####:1040: #####:1041: #####:1042: #####:1043: #####:1044: #####:1045: #####:1046: #####:1047: #####:1058: #####:1059: #####:1060: #####:1061: #####:1062: #####:1063: #####:1064: #####:1065: #####:1074: #####:1075: #####:1076: #####:1077: #####:1078: #####:1119: #####:1120: #####:1124: #####:1126: #####:1127: #####:1128: #####:1129: #####:1148: #####:1149: #####:1153: #####:1155: #####:1156: #####:1157: #####:1158: #####:1249: #####:1250: #####:1251: #####:1255: #####:1256: #####:1258: #####:1259: #####:1260: #####:1261: #####:1327: #####:1328: #####:1332: #####:1334: #####:1335: #####:1336: #####:1337: #####:1357: #####:1359: #####:1360: #####:1362: #####:1381: #####:1383: #####:1384: #####:1385: #####:1386: #####:1387: #####:1388: #####:1389: #####:1393: #####:1400: #####:1401: #####:1402: #####:1404: #####:1405: #####:1406: #####:1407: #####:1438: #####:1439: #####:1440: #####:1441: #####:1443: #####:1444: #####:1445: #####:1447: #####:1448: #####:1449: #####:1450: #####:1451: #####:1452: #####:1453: #####:1455: #####:1456: #####:1459: #####:1460: #####:1461: #####:1463: #####:1464: #####:1503: #####:1504: #####:1508: #####:1523: #####:1524: #####:1525: #####:1539: #####:1540: #####:1541: #####:1547: #####:1548: #####:1550: #####:1556: #####:1557: #####:1559: #####:1618: #####:1622: #####:1623: #####:1624: #####:1626: #####:1627: #####:1628: #####:1629: #####:1634: #####:1635: #####:1636: #####:1638: #####:1639: #####:1641: #####:1642: #####:2122: #####:2123: #####:2127: #####:2133: #####:2149: <<<<<< EOF # path=FBSDKCoreKit#FBSDKBridgeAPI.m.gcov.reduced -: 0:Source:FBSDKCoreKit/FBSDKBridgeAPI.m <<<<<< EOF # path=FBSDKLoginKit#Internal#FBSDKNonceUtility.m.gcov.reduced -: 0:Source:FBSDKLoginKit/Internal/FBSDKNonceUtility.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#AEM#FBSDKAEMAdvertiserSingleEntryRule.h.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMAdvertiserSingleEntryRule.h <<<<<< EOF # path=FBSDKCoreKit#FBSDKUserAgeRange.m.gcov.reduced -: 0:Source:FBSDKCoreKit/FBSDKUserAgeRange.m <<<<<< EOF # path=Parse#ParseClientConfiguration.m.gcov.reduced -: 0:Source:Parse/ParseClientConfiguration.m <<<<<< EOF # path=Parse#Internal#Session#Utilities#PFSessionUtilities.m.gcov.reduced -: 0:Source:Parse/Internal/Session/Utilities/PFSessionUtilities.m <<<<<< EOF # path=FBSDKCoreKit#Internal#FBSDKLoggerFactory.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/FBSDKLoggerFactory.m <<<<<< EOF # path=Parse#Internal#PFInternalUtils.m.gcov.reduced -: 0:Source:Parse/Internal/PFInternalUtils.m <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#Internal#Object#Subclassing#PFObjectSubclassingController.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/Internal/Object/Subclassing/PFObjectSubclassingController.m #####:115: <<<<<< EOF # path=FBSDKCoreKit#Internal#Network#FBSDKGraphRequestBody.h.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/Network/FBSDKGraphRequestBody.h <<<<<< EOF # path=Parse#Internal#Installation#InstallationIdentifierStore#PFInstallationIdentifierStore.m.gcov.reduced -: 0:Source:Parse/Internal/Installation/InstallationIdentifierStore/PFInstallationIdentifierStore.m <<<<<< EOF # path=FBSDKCoreKit#GraphAPI#FBSDKGraphRequestDataAttachment.h.gcov.reduced -: 0:Source:FBSDKCoreKit/GraphAPI/FBSDKGraphRequestDataAttachment.h <<<<<< EOF # path=Parse#Internal#LocalDataStore#SQLite#PFSQLiteStatement.h.gcov.reduced -: 0:Source:Parse/Internal/LocalDataStore/SQLite/PFSQLiteStatement.h <<<<<< EOF # path=Parse#Internal#PFDateFormatter.m.gcov.reduced -: 0:Source:Parse/Internal/PFDateFormatter.m <<<<<< EOF # path=#Applications#Xcode_13.1.app#Contents#Developer#Platforms#iPhoneSimulator.platform#Developer#SDKs#iPhoneSimulator15.0.sdk#usr#include#c++#v1#__split_buffer.gcov.reduced -: 0:Source:/Applications/Xcode_13.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator15.0.sdk/usr/include/c++/v1/__split_buffer #####:56: #####:58: #####:59: #####:85: #####:86: #####:89: #####:136: #####:137: #####:296: #####:297: #####:298: #####:299: #####:300: #####:311: #####:312: #####:313: #####:314: #####:315: #####:316: #####:317: #####:342: #####:343: #####:344: #####:345: #####:346: #####:347: <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#FBSDKTimeSpentData.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/FBSDKTimeSpentData.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#FBSDKAppEventsDeviceInfo.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsDeviceInfo.m <<<<<< EOF # path=Parse#Internal#Query#Controller#PFOfflineQueryController.h.gcov.reduced -: 0:Source:Parse/Internal/Query/Controller/PFOfflineQueryController.h <<<<<< EOF # path=FBSDKCoreKit#Internal#Network#FBSDKGraphRequestFactory.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/Network/FBSDKGraphRequestFactory.m <<<<<< EOF # path=Parse#PFConfig.m.gcov.reduced -: 0:Source:Parse/PFConfig.m <<<<<< EOF # path=#Applications#Xcode_13.1.app#Contents#Developer#Platforms#iPhoneSimulator.platform#Developer#SDKs#iPhoneSimulator15.0.sdk#usr#include#c++#v1#string.gcov.reduced -: 0:Source:/Applications/Xcode_13.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator15.0.sdk/usr/include/c++/v1/string #####:839: #####:841: #####:845: #####:969: #####:970: #####:1268: #####:1275: #####:1461: #####:1462: #####:1478: #####:1479: #####:1510: #####:1514: #####:1523: #####:1524: #####:1543: #####:1544: #####:1549: #####:1550: #####:1555: #####:1556: #####:1559: #####:1560: #####:1561: #####:1562: #####:1563: #####:1564: #####:1817: #####:1823: #####:1824: #####:1828: #####:1829: #####:4045: #####:4047: #####:4048: #####:4049: #####:4050: #####:4051: #####:4052: #####:4053: #####:4054: #####:4055: #####:4056: #####:4057: #####:4058: #####:4059: #####:4271: #####:4272: #####:4273: #####:4274: #####:4275: #####:4276: #####:4277: #####:4278: #####:4279: #####:4418: #####:4419: <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#FBSDKAtePublisherFactory.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/FBSDKAtePublisherFactory.m <<<<<< EOF # path=Parse#Internal#Commands#CommandRunner#URLSession#Session#TaskDelegate#PFURLSessionDataTaskDelegate.m.gcov.reduced -: 0:Source:Parse/Internal/Commands/CommandRunner/URLSession/Session/TaskDelegate/PFURLSessionDataTaskDelegate.m <<<<<< EOF # path=FBSDKCoreKit#Internal#ServerConfiguration#FBSDKErrorConfigurationProvider.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/ServerConfiguration/FBSDKErrorConfigurationProvider.m <<<<<< EOF # path=Bolts#Common#BFTaskCompletionSource.h.gcov.reduced -: 0:Source:Bolts/Common/BFTaskCompletionSource.h <<<<<< EOF # path=FBSDKLoginKit#Internal#FBSDKLoginManagerLoginResult+Internal.h.gcov.reduced -: 0:Source:FBSDKLoginKit/Internal/FBSDKLoginManagerLoginResult+Internal.h <<<<<< EOF # path=Parse#Internal#Commands#CommandRunner#URLSession#Session#TaskDelegate#PFURLSessionFileDownloadTaskDelegate.m.gcov.reduced -: 0:Source:Parse/Internal/Commands/CommandRunner/URLSession/Session/TaskDelegate/PFURLSessionFileDownloadTaskDelegate.m <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#Internal#File#Controller#PFFileController.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/Internal/File/Controller/PFFileController.m #####:72: <<<<<< EOF # path=Parse#Internal#PFWeakValue.m.gcov.reduced -: 0:Source:Parse/Internal/PFWeakValue.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#AEM#FBSDKAEMAdvertiserMultiEntryRule.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMAdvertiserMultiEntryRule.m <<<<<< EOF # path=Parse#Internal#Object#Coder#File#PFObjectFileCodingLogic.m.gcov.reduced -: 0:Source:Parse/Internal/Object/Coder/File/PFObjectFileCodingLogic.m <<<<<< EOF # path=Parse#Internal#MultiProcessLock#PFMultiProcessFileLock.m.gcov.reduced -: 0:Source:Parse/Internal/MultiProcessLock/PFMultiProcessFileLock.m <<<<<< EOF # path=FBSDKCoreKit#Internal#FBSDKObjectDecoder.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/FBSDKObjectDecoder.m <<<<<< EOF # path=OCMock#OCClassMockObject.m.gcov.reduced -: 0:Source:OCMock/OCClassMockObject.m <<<<<< EOF # path=Parse#Internal#PFDevice.m.gcov.reduced -: 0:Source:Parse/Internal/PFDevice.m <<<<<< EOF # path=Parse#Internal#Object#BatchController#PFObjectBatchController.h.gcov.reduced -: 0:Source:Parse/Internal/Object/BatchController/PFObjectBatchController.h <<<<<< EOF # path=./ParseFacebookUtilsV4-UnitTests.xctest.coverage.txt /Users/runner/Library/Developer/Xcode/DerivedData/Parse-dscfcsmewbetpzfilnzorrkjyefy/Build/Products/Debug-iphonesimulator/FBSDKCoreKit.framework/Headers/FBSDKCoreKitVersions.h: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| 0|#define FBSDK_VERSION_STRING @"11.0.1" 20| |#define FBSDK_TARGET_PLATFORM_VERSION @"v11.0" /Users/runner/Library/Developer/Xcode/DerivedData/Parse-dscfcsmewbetpzfilnzorrkjyefy/Build/Products/Debug-iphonesimulator/FBSDKCoreKit_Basics.framework/Headers/FBSDKSafeCast.h: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import 20| | 21| |#ifndef FBSDK_CAST_TO_CLASS_OR_NIL_FUNC 22| | #define FBSDK_CAST_TO_CLASS_OR_NIL_FUNC 23| | #ifdef __cplusplus 24| |extern "C" { 25| | #endif 26| |/** Use the type-safe FBSDK_CAST_TO_CLASS_OR_NIL instead. */ 27| |id _FBSDKCastToClassOrNilUnsafeInternal(id object, Class klass); 28| | #ifdef __cplusplus 29| |} 30| | #endif 31| |#endif 32| | 33| |#ifndef FBSDK_CAST_TO_CLASS_OR_NIL 34| 0| #define FBSDK_CAST_TO_CLASS_OR_NIL(obj_, class_) ((class_ *)_FBSDKCastToClassOrNilUnsafeInternal(obj_, [class_ class])) 35| |#endif 36| | 37| |#ifndef FBSDK_CAST_TO_PROTOCOL_OR_NIL_FUNC 38| | #define FBSDK_CAST_TO_PROTOCOL_OR_NIL_FUNC 39| | #ifdef __cplusplus 40| |extern "C" { 41| | #endif 42| |/** Use the type-safe FBSDK_CAST_TO_PROTOCOL_OR_NIL instead. */ 43| |id _FBSDKCastToProtocolOrNilUnsafeInternal(id object, Protocol *protocol); 44| | #ifdef __cplusplus 45| |} 46| | #endif 47| |#endif 48| | 49| |#ifndef FBSDK_CAST_TO_PROTOCOL_OR_NIL 50| 0| #define FBSDK_CAST_TO_PROTOCOL_OR_NIL(obj_, protocol_) ((id)_FBSDKCastToProtocolOrNilUnsafeInternal(obj_, @protocol(protocol_))) 51| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/Bolts-ObjC/Bolts/Common/BFCancellationToken.m: 1| |/* 2| | * Copyright (c) 2014, Facebook, Inc. 3| | * All rights reserved. 4| | * 5| | * This source code is licensed under the BSD-style license found in the 6| | * LICENSE file in the root directory of this source tree. An additional grant 7| | * of patent rights can be found in the PATENTS file in the same directory. 8| | * 9| | */ 10| | 11| |#import "BFCancellationToken.h" 12| |#import "BFCancellationTokenRegistration.h" 13| | 14| |NS_ASSUME_NONNULL_BEGIN 15| | 16| |@interface BFCancellationToken () 17| | 18| |@property (nullable, nonatomic, strong) NSMutableArray *registrations; 19| |@property (nonatomic, strong) NSObject *lock; 20| |@property (nonatomic) BOOL disposed; 21| | 22| |@end 23| | 24| |@interface BFCancellationTokenRegistration (BFCancellationToken) 25| | 26| |+ (instancetype)registrationWithToken:(BFCancellationToken *)token delegate:(BFCancellationBlock)delegate; 27| | 28| |- (void)notifyDelegate; 29| | 30| |@end 31| | 32| |@implementation BFCancellationToken 33| | 34| |@synthesize cancellationRequested = _cancellationRequested; 35| | 36| |#pragma mark - Initializer 37| | 38| 0|- (instancetype)init { 39| 0| self = [super init]; 40| 0| if (!self) return self; 41| | 42| 0| _registrations = [NSMutableArray array]; 43| 0| _lock = [NSObject new]; 44| | 45| 0| return self; 46| 0|} 47| | 48| |#pragma mark - Custom Setters/Getters 49| | 50| 0|- (BOOL)isCancellationRequested { 51| 0| @synchronized(self.lock) { 52| 0| [self throwIfDisposed]; 53| 0| return _cancellationRequested; 54| 0| } 55| 0|} 56| | 57| 0|- (void)cancel { 58| 0| NSArray *registrations; 59| 0| @synchronized(self.lock) { 60| 0| [self throwIfDisposed]; 61| 0| if (_cancellationRequested) { 62| 0| return; 63| 0| } 64| 0| [NSObject cancelPreviousPerformRequestsWithTarget:self selector:@selector(cancelPrivate) object:nil]; 65| 0| _cancellationRequested = YES; 66| 0| registrations = [self.registrations copy]; 67| 0| } 68| | 69| 0| [self notifyCancellation:registrations]; 70| 0|} 71| | 72| 0|- (void)notifyCancellation:(NSArray *)registrations { 73| 0| for (BFCancellationTokenRegistration *registration in registrations) { 74| 0| [registration notifyDelegate]; 75| 0| } 76| 0|} 77| | 78| 0|- (BFCancellationTokenRegistration *)registerCancellationObserverWithBlock:(BFCancellationBlock)block { 79| 0| @synchronized(self.lock) { 80| 0| BFCancellationTokenRegistration *registration = [BFCancellationTokenRegistration registrationWithToken:self delegate:[block copy]]; 81| 0| [self.registrations addObject:registration]; 82| | 83| 0| return registration; 84| 0| } 85| 0|} 86| | 87| 0|- (void)unregisterRegistration:(BFCancellationTokenRegistration *)registration { 88| 0| @synchronized(self.lock) { 89| 0| [self throwIfDisposed]; 90| 0| [self.registrations removeObject:registration]; 91| 0| } 92| 0|} 93| | 94| |// Delay on a non-public method to prevent interference with a user calling performSelector or 95| |// cancelPreviousPerformRequestsWithTarget on the public method 96| 0|- (void)cancelPrivate { 97| 0| [self cancel]; 98| 0|} 99| | 100| 0|- (void)cancelAfterDelay:(int)millis { 101| 0| [self throwIfDisposed]; 102| 0| if (millis < -1) { 103| 0| [NSException raise:NSInvalidArgumentException format:@"Delay must be >= -1"]; 104| 0| } 105| | 106| 0| if (millis == 0) { 107| 0| [self cancel]; 108| 0| return; 109| 0| } 110| | 111| 0| @synchronized(self.lock) { 112| 0| [self throwIfDisposed]; 113| 0| [NSObject cancelPreviousPerformRequestsWithTarget:self selector:@selector(cancelPrivate) object:nil]; 114| 0| if (self.cancellationRequested) { 115| 0| return; 116| 0| } 117| | 118| 0| if (millis != -1) { 119| 0| double delay = (double)millis / 1000; 120| 0| [self performSelector:@selector(cancelPrivate) withObject:nil afterDelay:delay]; 121| 0| } 122| 0| } 123| 0|} 124| | 125| 0|- (void)dispose { 126| 0| @synchronized(self.lock) { 127| 0| if (self.disposed) { 128| 0| return; 129| 0| } 130| 0| [self.registrations makeObjectsPerformSelector:@selector(dispose)]; 131| 0| self.registrations = nil; 132| 0| self.disposed = YES; 133| 0| } 134| 0|} 135| | 136| 0|- (void)throwIfDisposed { 137| 0| if (self.disposed) { 138| 0| [NSException raise:NSInternalInconsistencyException format:@"Object already disposed"]; 139| 0| } 140| 0|} 141| | 142| |@end 143| | 144| |NS_ASSUME_NONNULL_END /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/Bolts-ObjC/Bolts/Common/BFCancellationTokenRegistration.m: 1| |/* 2| | * Copyright (c) 2014, Facebook, Inc. 3| | * All rights reserved. 4| | * 5| | * This source code is licensed under the BSD-style license found in the 6| | * LICENSE file in the root directory of this source tree. An additional grant 7| | * of patent rights can be found in the PATENTS file in the same directory. 8| | * 9| | */ 10| | 11| |#import "BFCancellationTokenRegistration.h" 12| | 13| |#import "BFCancellationToken.h" 14| | 15| |NS_ASSUME_NONNULL_BEGIN 16| | 17| |@interface BFCancellationTokenRegistration () 18| | 19| |@property (nonatomic, weak) BFCancellationToken *token; 20| |@property (nullable, nonatomic, strong) BFCancellationBlock cancellationObserverBlock; 21| |@property (nonatomic, strong) NSObject *lock; 22| |@property (nonatomic) BOOL disposed; 23| | 24| |@end 25| | 26| |@interface BFCancellationToken (BFCancellationTokenRegistration) 27| | 28| |- (void)unregisterRegistration:(BFCancellationTokenRegistration *)registration; 29| | 30| |@end 31| | 32| |@implementation BFCancellationTokenRegistration 33| | 34| 0|+ (instancetype)registrationWithToken:(BFCancellationToken *)token delegate:(BFCancellationBlock)delegate { 35| 0| BFCancellationTokenRegistration *registration = [BFCancellationTokenRegistration new]; 36| 0| registration.token = token; 37| 0| registration.cancellationObserverBlock = delegate; 38| 0| return registration; 39| 0|} 40| | 41| 0|- (instancetype)init { 42| 0| self = [super init]; 43| 0| if (!self) return self; 44| | 45| 0| _lock = [NSObject new]; 46| | 47| 0| return self; 48| 0|} 49| | 50| 0|- (void)dispose { 51| 0| @synchronized(self.lock) { 52| 0| if (self.disposed) { 53| 0| return; 54| 0| } 55| 0| self.disposed = YES; 56| 0| } 57| | 58| 0| BFCancellationToken *token = self.token; 59| 0| if (token != nil) { 60| 0| [token unregisterRegistration:self]; 61| 0| self.token = nil; 62| 0| } 63| 0| self.cancellationObserverBlock = nil; 64| 0|} 65| | 66| 0|- (void)notifyDelegate { 67| 0| @synchronized(self.lock) { 68| 0| [self throwIfDisposed]; 69| 0| self.cancellationObserverBlock(); 70| 0| } 71| 0|} 72| | 73| 0|- (void)throwIfDisposed { 74| 0| NSAssert(!self.disposed, @"Object already disposed"); 75| 0|} 76| | 77| |@end 78| | 79| |NS_ASSUME_NONNULL_END /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/Bolts-ObjC/Bolts/Common/BFCancellationTokenSource.m: 1| |/* 2| | * Copyright (c) 2014, Facebook, Inc. 3| | * All rights reserved. 4| | * 5| | * This source code is licensed under the BSD-style license found in the 6| | * LICENSE file in the root directory of this source tree. An additional grant 7| | * of patent rights can be found in the PATENTS file in the same directory. 8| | * 9| | */ 10| | 11| |#import "BFCancellationTokenSource.h" 12| | 13| |#import "BFCancellationToken.h" 14| | 15| |NS_ASSUME_NONNULL_BEGIN 16| | 17| |@interface BFCancellationToken (BFCancellationTokenSource) 18| | 19| |- (void)cancel; 20| |- (void)cancelAfterDelay:(int)millis; 21| | 22| |- (void)dispose; 23| |- (void)throwIfDisposed; 24| | 25| |@end 26| | 27| |@implementation BFCancellationTokenSource 28| | 29| |#pragma mark - Initializer 30| | 31| 0|- (instancetype)init { 32| 0| self = [super init]; 33| 0| if (!self) return self; 34| | 35| 0| _token = [BFCancellationToken new]; 36| | 37| 0| return self; 38| 0|} 39| | 40| 0|+ (instancetype)cancellationTokenSource { 41| 0| return [BFCancellationTokenSource new]; 42| 0|} 43| | 44| |#pragma mark - Custom Setters/Getters 45| | 46| 0|- (BOOL)isCancellationRequested { 47| 0| return _token.isCancellationRequested; 48| 0|} 49| | 50| 0|- (void)cancel { 51| 0| [_token cancel]; 52| 0|} 53| | 54| 0|- (void)cancelAfterDelay:(int)millis { 55| 0| [_token cancelAfterDelay:millis]; 56| 0|} 57| | 58| 0|- (void)dispose { 59| 0| [_token dispose]; 60| 0|} 61| | 62| |@end 63| | 64| |NS_ASSUME_NONNULL_END /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/Bolts-ObjC/Bolts/Common/BFExecutor.m: 1| |/* 2| | * Copyright (c) 2014, Facebook, Inc. 3| | * All rights reserved. 4| | * 5| | * This source code is licensed under the BSD-style license found in the 6| | * LICENSE file in the root directory of this source tree. An additional grant 7| | * of patent rights can be found in the PATENTS file in the same directory. 8| | * 9| | */ 10| | 11| |#import "BFExecutor.h" 12| | 13| |#import 14| | 15| |NS_ASSUME_NONNULL_BEGIN 16| | 17| |/*! 18| | Get the remaining stack-size of the current thread. 19| | 20| | @param totalSize The total stack size of the current thread. 21| | 22| | @return The remaining size, in bytes, available to the current thread. 23| | 24| | @note This function cannot be inlined, as otherwise the internal implementation could fail to report the proper 25| | remaining stack space. 26| | */ 27| 0|__attribute__((noinline)) static size_t remaining_stack_size(size_t *restrict totalSize) { 28| 0| pthread_t currentThread = pthread_self(); 29| | 30| | // NOTE: We must store stack pointers as uint8_t so that the pointer math is well-defined 31| 0| uint8_t *endStack = pthread_get_stackaddr_np(currentThread); 32| 0| *totalSize = pthread_get_stacksize_np(currentThread); 33| | 34| | // NOTE: If the function is inlined, this value could be incorrect 35| 0| uint8_t *frameAddr = __builtin_frame_address(0); 36| | 37| 0| return (*totalSize) - (size_t)(endStack - frameAddr); 38| 0|} 39| | 40| |@interface BFExecutor () 41| | 42| |@property (nonatomic, copy) void(^block)(void(^block)(void)); 43| | 44| |@end 45| | 46| |@implementation BFExecutor 47| | 48| |#pragma mark - Executor methods 49| | 50| 0|+ (instancetype)defaultExecutor { 51| 0| static BFExecutor *defaultExecutor = NULL; 52| 0| static dispatch_once_t onceToken; 53| 0| dispatch_once(&onceToken, ^{ 54| 0| defaultExecutor = [self executorWithBlock:^void(void(^block)(void)) { 55| | // We prefer to run everything possible immediately, so that there is callstack information 56| | // when debugging. However, we don't want the stack to get too deep, so if the remaining stack space 57| | // is less than 10% of the total space, we dispatch to another GCD queue. 58| 0| size_t totalStackSize = 0; 59| 0| size_t remainingStackSize = remaining_stack_size(&totalStackSize); 60| | 61| 0| if (remainingStackSize < (totalStackSize / 10)) { 62| 0| dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_DEFAULT, 0), block); 63| 0| } else { 64| 0| @autoreleasepool { 65| 0| block(); 66| 0| } 67| 0| } 68| 0| }]; 69| 0| }); 70| 0| return defaultExecutor; 71| 0|} 72| | 73| 0|+ (instancetype)immediateExecutor { 74| 0| static BFExecutor *immediateExecutor = NULL; 75| 0| static dispatch_once_t onceToken; 76| 0| dispatch_once(&onceToken, ^{ 77| 0| immediateExecutor = [self executorWithBlock:^void(void(^block)(void)) { 78| 0| block(); 79| 0| }]; 80| 0| }); 81| 0| return immediateExecutor; 82| 0|} 83| | 84| 0|+ (instancetype)mainThreadExecutor { 85| 0| static BFExecutor *mainThreadExecutor = NULL; 86| 0| static dispatch_once_t onceToken; 87| 0| dispatch_once(&onceToken, ^{ 88| 0| mainThreadExecutor = [self executorWithBlock:^void(void(^block)(void)) { 89| 0| if (![NSThread isMainThread]) { 90| 0| dispatch_async(dispatch_get_main_queue(), block); 91| 0| } else { 92| 0| @autoreleasepool { 93| 0| block(); 94| 0| } 95| 0| } 96| 0| }]; 97| 0| }); 98| 0| return mainThreadExecutor; 99| 0|} 100| | 101| 0|+ (instancetype)executorWithBlock:(void(^)(void(^block)(void)))block { 102| 0| return [[self alloc] initWithBlock:block]; 103| 0|} 104| | 105| 0|+ (instancetype)executorWithDispatchQueue:(dispatch_queue_t)queue { 106| 0| return [self executorWithBlock:^void(void(^block)(void)) { 107| 0| dispatch_async(queue, block); 108| 0| }]; 109| 0|} 110| | 111| 0|+ (instancetype)executorWithOperationQueue:(NSOperationQueue *)queue { 112| 0| return [self executorWithBlock:^void(void(^block)(void)) { 113| 0| [queue addOperation:[NSBlockOperation blockOperationWithBlock:block]]; 114| 0| }]; 115| 0|} 116| | 117| |#pragma mark - Initializer 118| | 119| 0|- (instancetype)initWithBlock:(void(^)(void(^block)(void)))block { 120| 0| self = [super init]; 121| 0| if (!self) return self; 122| | 123| 0| _block = block; 124| | 125| 0| return self; 126| 0|} 127| | 128| |#pragma mark - Execution 129| | 130| 0|- (void)execute:(void(^)(void))block { 131| 0| self.block(block); 132| 0|} 133| | 134| |@end 135| | 136| |NS_ASSUME_NONNULL_END /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/Bolts-ObjC/Bolts/Common/BFTask.m: 1| |/* 2| | * Copyright (c) 2014, Facebook, Inc. 3| | * All rights reserved. 4| | * 5| | * This source code is licensed under the BSD-style license found in the 6| | * LICENSE file in the root directory of this source tree. An additional grant 7| | * of patent rights can be found in the PATENTS file in the same directory. 8| | * 9| | */ 10| | 11| |#import "BFTask.h" 12| | 13| |#import 14| | 15| |#import "Bolts.h" 16| | 17| |NS_ASSUME_NONNULL_BEGIN 18| | 19| 0|__attribute__ ((noinline)) void warnBlockingOperationOnMainThread() { 20| 0| NSLog(@"Warning: A long-running operation is being executed on the main thread. \n" 21| 0| " Break on warnBlockingOperationOnMainThread() to debug."); 22| 0|} 23| | 24| |NSString *const BFTaskErrorDomain = @"bolts"; 25| |NSInteger const kBFMultipleErrorsError = 80175001; 26| | 27| |NSString *const BFTaskMultipleErrorsUserInfoKey = @"errors"; 28| | 29| |@interface BFTask () { 30| | id _result; 31| | NSError *_error; 32| |} 33| | 34| |@property (nonatomic, assign, readwrite, getter=isCancelled) BOOL cancelled; 35| |@property (nonatomic, assign, readwrite, getter=isFaulted) BOOL faulted; 36| |@property (nonatomic, assign, readwrite, getter=isCompleted) BOOL completed; 37| | 38| |@property (nonatomic, strong) NSObject *lock; 39| |@property (nonatomic, strong) NSCondition *condition; 40| |@property (nonatomic, strong) NSMutableArray *callbacks; 41| | 42| |@end 43| | 44| |@implementation BFTask 45| | 46| |#pragma mark - Initializer 47| | 48| 0|- (instancetype)init { 49| 0| self = [super init]; 50| 0| if (!self) return self; 51| | 52| 0| _lock = [[NSObject alloc] init]; 53| 0| _condition = [[NSCondition alloc] init]; 54| 0| _callbacks = [NSMutableArray array]; 55| | 56| 0| return self; 57| 0|} 58| | 59| 0|- (instancetype)initWithResult:(nullable id)result { 60| 0| self = [super init]; 61| 0| if (!self) return self; 62| | 63| 0| [self trySetResult:result]; 64| | 65| 0| return self; 66| 0|} 67| | 68| 0|- (instancetype)initWithError:(NSError *)error { 69| 0| self = [super init]; 70| 0| if (!self) return self; 71| | 72| 0| [self trySetError:error]; 73| | 74| 0| return self; 75| 0|} 76| | 77| 0|- (instancetype)initCancelled { 78| 0| self = [super init]; 79| 0| if (!self) return self; 80| | 81| 0| [self trySetCancelled]; 82| | 83| 0| return self; 84| 0|} 85| | 86| |#pragma mark - Task Class methods 87| | 88| 0|+ (instancetype)taskWithResult:(nullable id)result { 89| 0| return [[self alloc] initWithResult:result]; 90| 0|} 91| | 92| 0|+ (instancetype)taskWithError:(NSError *)error { 93| 0| return [[self alloc] initWithError:error]; 94| 0|} 95| | 96| 0|+ (instancetype)cancelledTask { 97| 0| return [[self alloc] initCancelled]; 98| 0|} 99| | 100| 0|+ (instancetype)taskForCompletionOfAllTasks:(nullable NSArray *)tasks { 101| 0| __block int32_t total = (int32_t)tasks.count; 102| 0| if (total == 0) { 103| 0| return [self taskWithResult:nil]; 104| 0| } 105| | 106| 0| __block int32_t cancelled = 0; 107| 0| NSObject *lock = [[NSObject alloc] init]; 108| 0| NSMutableArray *errors = [NSMutableArray array]; 109| | 110| 0| BFTaskCompletionSource *tcs = [BFTaskCompletionSource taskCompletionSource]; 111| 0| for (BFTask *task in tasks) { 112| 0| [task continueWithBlock:^id(BFTask *t) { 113| 0| if (t.error) { 114| 0| @synchronized (lock) { 115| 0| [errors addObject:t.error]; 116| 0| } 117| 0| } else if (t.cancelled) { 118| 0| OSAtomicIncrement32Barrier(&cancelled); 119| 0| } 120| | 121| 0| if (OSAtomicDecrement32Barrier(&total) == 0) { 122| 0| if (errors.count > 0) { 123| 0| if (errors.count == 1) { 124| 0| tcs.error = [errors firstObject]; 125| 0| } else { 126| 0| NSError *error = [NSError errorWithDomain:BFTaskErrorDomain 127| 0| code:kBFMultipleErrorsError 128| 0| userInfo:@{ BFTaskMultipleErrorsUserInfoKey: errors }]; 129| 0| tcs.error = error; 130| 0| } 131| 0| } else if (cancelled > 0) { 132| 0| [tcs cancel]; 133| 0| } else { 134| 0| tcs.result = nil; 135| 0| } 136| 0| } 137| 0| return nil; 138| 0| }]; 139| 0| } 140| 0| return tcs.task; 141| 0|} 142| | 143| 0|+ (instancetype)taskForCompletionOfAllTasksWithResults:(nullable NSArray *)tasks { 144| 0| return [[self taskForCompletionOfAllTasks:tasks] continueWithSuccessBlock:^id(BFTask * __unused task) { 145| 0| return [tasks valueForKey:@"result"]; 146| 0| }]; 147| 0|} 148| | 149| |+ (instancetype)taskForCompletionOfAnyTask:(nullable NSArray *)tasks 150| 0|{ 151| 0| __block int32_t total = (int32_t)tasks.count; 152| 0| if (total == 0) { 153| 0| return [self taskWithResult:nil]; 154| 0| } 155| | 156| 0| __block int completed = 0; 157| 0| __block int32_t cancelled = 0; 158| | 159| 0| NSObject *lock = [NSObject new]; 160| 0| NSMutableArray *errors = [NSMutableArray new]; 161| | 162| 0| BFTaskCompletionSource *source = [BFTaskCompletionSource taskCompletionSource]; 163| 0| for (BFTask *task in tasks) { 164| 0| [task continueWithBlock:^id(BFTask *t) { 165| 0| if (t.error != nil) { 166| 0| @synchronized(lock) { 167| 0| [errors addObject:t.error]; 168| 0| } 169| 0| } else if (t.cancelled) { 170| 0| OSAtomicIncrement32Barrier(&cancelled); 171| 0| } else { 172| 0| if(OSAtomicCompareAndSwap32Barrier(0, 1, &completed)) { 173| 0| [source setResult:t.result]; 174| 0| } 175| 0| } 176| | 177| 0| if (OSAtomicDecrement32Barrier(&total) == 0 && 178| 0| OSAtomicCompareAndSwap32Barrier(0, 1, &completed)) { 179| 0| if (cancelled > 0) { 180| 0| [source cancel]; 181| 0| } else if (errors.count > 0) { 182| 0| if (errors.count == 1) { 183| 0| source.error = errors.firstObject; 184| 0| } else { 185| 0| NSError *error = [NSError errorWithDomain:BFTaskErrorDomain 186| 0| code:kBFMultipleErrorsError 187| 0| userInfo:@{ @"errors": errors }]; 188| 0| source.error = error; 189| 0| } 190| 0| } 191| 0| } 192| | // Abort execution of per tasks continuations 193| 0| return nil; 194| 0| }]; 195| 0| } 196| 0| return source.task; 197| 0|} 198| | 199| | 200| 0|+ (BFTask *)taskWithDelay:(int)millis { 201| 0| BFTaskCompletionSource *tcs = [BFTaskCompletionSource taskCompletionSource]; 202| 0| dispatch_time_t popTime = dispatch_time(DISPATCH_TIME_NOW, millis * NSEC_PER_MSEC); 203| 0| dispatch_after(popTime, dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_DEFAULT, 0), ^(void){ 204| 0| tcs.result = nil; 205| 0| }); 206| 0| return tcs.task; 207| 0|} 208| | 209| 0|+ (BFTask *)taskWithDelay:(int)millis cancellationToken:(nullable BFCancellationToken *)token { 210| 0| if (token.cancellationRequested) { 211| 0| return [BFTask cancelledTask]; 212| 0| } 213| | 214| 0| BFTaskCompletionSource *tcs = [BFTaskCompletionSource taskCompletionSource]; 215| 0| dispatch_time_t popTime = dispatch_time(DISPATCH_TIME_NOW, millis * NSEC_PER_MSEC); 216| 0| dispatch_after(popTime, dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_DEFAULT, 0), ^(void){ 217| 0| if (token.cancellationRequested) { 218| 0| [tcs cancel]; 219| 0| return; 220| 0| } 221| 0| tcs.result = nil; 222| 0| }); 223| 0| return tcs.task; 224| 0|} 225| | 226| 0|+ (instancetype)taskFromExecutor:(BFExecutor *)executor withBlock:(nullable id (^)(void))block { 227| 0| return [[self taskWithResult:nil] continueWithExecutor:executor withBlock:^id(BFTask *task) { 228| 0| return block(); 229| 0| }]; 230| 0|} 231| | 232| |#pragma mark - Custom Setters/Getters 233| | 234| 0|- (nullable id)result { 235| 0| @synchronized(self.lock) { 236| 0| return _result; 237| 0| } 238| 0|} 239| | 240| 0|- (BOOL)trySetResult:(nullable id)result { 241| 0| @synchronized(self.lock) { 242| 0| if (self.completed) { 243| 0| return NO; 244| 0| } 245| 0| self.completed = YES; 246| 0| _result = result; 247| 0| [self runContinuations]; 248| 0| return YES; 249| 0| } 250| 0|} 251| | 252| 0|- (nullable NSError *)error { 253| 0| @synchronized(self.lock) { 254| 0| return _error; 255| 0| } 256| 0|} 257| | 258| 0|- (BOOL)trySetError:(NSError *)error { 259| 0| @synchronized(self.lock) { 260| 0| if (self.completed) { 261| 0| return NO; 262| 0| } 263| 0| self.completed = YES; 264| 0| self.faulted = YES; 265| 0| _error = error; 266| 0| [self runContinuations]; 267| 0| return YES; 268| 0| } 269| 0|} 270| | 271| 0|- (BOOL)isCancelled { 272| 0| @synchronized(self.lock) { 273| 0| return _cancelled; 274| 0| } 275| 0|} 276| | 277| 0|- (BOOL)isFaulted { 278| 0| @synchronized(self.lock) { 279| 0| return _faulted; 280| 0| } 281| 0|} 282| | 283| 0|- (BOOL)trySetCancelled { 284| 0| @synchronized(self.lock) { 285| 0| if (self.completed) { 286| 0| return NO; 287| 0| } 288| 0| self.completed = YES; 289| 0| self.cancelled = YES; 290| 0| [self runContinuations]; 291| 0| return YES; 292| 0| } 293| 0|} 294| | 295| 0|- (BOOL)isCompleted { 296| 0| @synchronized(self.lock) { 297| 0| return _completed; 298| 0| } 299| 0|} 300| | 301| 0|- (void)runContinuations { 302| 0| @synchronized(self.lock) { 303| 0| [self.condition lock]; 304| 0| [self.condition broadcast]; 305| 0| [self.condition unlock]; 306| 0| for (void (^callback)(void) in self.callbacks) { 307| 0| callback(); 308| 0| } 309| 0| [self.callbacks removeAllObjects]; 310| 0| } 311| 0|} 312| | 313| |#pragma mark - Chaining methods 314| | 315| 0|- (BFTask *)continueWithExecutor:(BFExecutor *)executor withBlock:(BFContinuationBlock)block { 316| 0| return [self continueWithExecutor:executor block:block cancellationToken:nil]; 317| 0|} 318| | 319| |- (BFTask *)continueWithExecutor:(BFExecutor *)executor 320| | block:(BFContinuationBlock)block 321| 0| cancellationToken:(nullable BFCancellationToken *)cancellationToken { 322| 0| BFTaskCompletionSource *tcs = [BFTaskCompletionSource taskCompletionSource]; 323| | 324| | // Capture all of the state that needs to used when the continuation is complete. 325| 0| dispatch_block_t executionBlock = ^{ 326| 0| if (cancellationToken.cancellationRequested) { 327| 0| [tcs cancel]; 328| 0| return; 329| 0| } 330| | 331| 0| id result = block(self); 332| 0| if ([result isKindOfClass:[BFTask class]]) { 333| | 334| 0| id (^setupWithTask) (BFTask *) = ^id(BFTask *task) { 335| 0| if (cancellationToken.cancellationRequested || task.cancelled) { 336| 0| [tcs cancel]; 337| 0| } else if (task.error) { 338| 0| tcs.error = task.error; 339| 0| } else { 340| 0| tcs.result = task.result; 341| 0| } 342| 0| return nil; 343| 0| }; 344| | 345| 0| BFTask *resultTask = (BFTask *)result; 346| | 347| 0| if (resultTask.completed) { 348| 0| setupWithTask(resultTask); 349| 0| } else { 350| 0| [resultTask continueWithBlock:setupWithTask]; 351| 0| } 352| | 353| 0| } else { 354| 0| tcs.result = result; 355| 0| } 356| 0| }; 357| | 358| 0| BOOL completed; 359| 0| @synchronized(self.lock) { 360| 0| completed = self.completed; 361| 0| if (!completed) { 362| 0| [self.callbacks addObject:[^{ 363| 0| [executor execute:executionBlock]; 364| 0| } copy]]; 365| 0| } 366| 0| } 367| 0| if (completed) { 368| 0| [executor execute:executionBlock]; 369| 0| } 370| | 371| 0| return tcs.task; 372| 0|} 373| | 374| 0|- (BFTask *)continueWithBlock:(BFContinuationBlock)block { 375| 0| return [self continueWithExecutor:[BFExecutor defaultExecutor] block:block cancellationToken:nil]; 376| 0|} 377| | 378| 0|- (BFTask *)continueWithBlock:(BFContinuationBlock)block cancellationToken:(nullable BFCancellationToken *)cancellationToken { 379| 0| return [self continueWithExecutor:[BFExecutor defaultExecutor] block:block cancellationToken:cancellationToken]; 380| 0|} 381| | 382| |- (BFTask *)continueWithExecutor:(BFExecutor *)executor 383| 0| withSuccessBlock:(BFContinuationBlock)block { 384| 0| return [self continueWithExecutor:executor successBlock:block cancellationToken:nil]; 385| 0|} 386| | 387| |- (BFTask *)continueWithExecutor:(BFExecutor *)executor 388| | successBlock:(BFContinuationBlock)block 389| 0| cancellationToken:(nullable BFCancellationToken *)cancellationToken { 390| 0| if (cancellationToken.cancellationRequested) { 391| 0| return [BFTask cancelledTask]; 392| 0| } 393| | 394| 0| return [self continueWithExecutor:executor block:^id(BFTask *task) { 395| 0| if (task.faulted || task.cancelled) { 396| 0| return task; 397| 0| } else { 398| 0| return block(task); 399| 0| } 400| 0| } cancellationToken:cancellationToken]; 401| 0|} 402| | 403| 0|- (BFTask *)continueWithSuccessBlock:(BFContinuationBlock)block { 404| 0| return [self continueWithExecutor:[BFExecutor defaultExecutor] successBlock:block cancellationToken:nil]; 405| 0|} 406| | 407| 0|- (BFTask *)continueWithSuccessBlock:(BFContinuationBlock)block cancellationToken:(nullable BFCancellationToken *)cancellationToken { 408| 0| return [self continueWithExecutor:[BFExecutor defaultExecutor] successBlock:block cancellationToken:cancellationToken]; 409| 0|} 410| | 411| |#pragma mark - Syncing Task (Avoid it) 412| | 413| 0|- (void)warnOperationOnMainThread { 414| 0| warnBlockingOperationOnMainThread(); 415| 0|} 416| | 417| 0|- (void)waitUntilFinished { 418| 0| if ([NSThread isMainThread]) { 419| 0| [self warnOperationOnMainThread]; 420| 0| } 421| | 422| 0| @synchronized(self.lock) { 423| 0| if (self.completed) { 424| 0| return; 425| 0| } 426| 0| [self.condition lock]; 427| 0| } 428| | // TODO: (nlutsenko) Restructure this to use Bolts-Swift thread access synchronization architecture 429| | // In the meantime, it's absolutely safe to get `_completed` aka an ivar, as long as it's a `BOOL` aka less than word size. 430| 0| while (!_completed) { 431| 0| [self.condition wait]; 432| 0| } 433| 0| [self.condition unlock]; 434| 0|} 435| | 436| |#pragma mark - NSObject 437| | 438| 0|- (NSString *)description { 439| | // Acquire the data from the locked properties 440| 0| BOOL completed; 441| 0| BOOL cancelled; 442| 0| BOOL faulted; 443| 0| NSString *resultDescription = nil; 444| | 445| 0| @synchronized(self.lock) { 446| 0| completed = self.completed; 447| 0| cancelled = self.cancelled; 448| 0| faulted = self.faulted; 449| 0| resultDescription = completed ? [NSString stringWithFormat:@" result = %@", self.result] : @""; 450| 0| } 451| | 452| | // Description string includes status information and, if available, the 453| | // result since in some ways this is what a promise actually "is". 454| 0| return [NSString stringWithFormat:@"<%@: %p; completed = %@; cancelled = %@; faulted = %@;%@>", 455| 0| NSStringFromClass([self class]), 456| 0| self, 457| 0| completed ? @"YES" : @"NO", 458| 0| cancelled ? @"YES" : @"NO", 459| 0| faulted ? @"YES" : @"NO", 460| 0| resultDescription]; 461| 0|} 462| | 463| |@end 464| | 465| |NS_ASSUME_NONNULL_END /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/Bolts-ObjC/Bolts/Common/BFTaskCompletionSource.m: 1| |/* 2| | * Copyright (c) 2014, Facebook, Inc. 3| | * All rights reserved. 4| | * 5| | * This source code is licensed under the BSD-style license found in the 6| | * LICENSE file in the root directory of this source tree. An additional grant 7| | * of patent rights can be found in the PATENTS file in the same directory. 8| | * 9| | */ 10| | 11| |#import "BFTaskCompletionSource.h" 12| | 13| |#import "BFTask.h" 14| | 15| |NS_ASSUME_NONNULL_BEGIN 16| | 17| |@interface BFTask (BFTaskCompletionSource) 18| | 19| |- (BOOL)trySetResult:(nullable id)result; 20| |- (BOOL)trySetError:(NSError *)error; 21| |- (BOOL)trySetCancelled; 22| | 23| |@end 24| | 25| |@implementation BFTaskCompletionSource 26| | 27| |#pragma mark - Initializer 28| | 29| 0|+ (instancetype)taskCompletionSource { 30| 0| return [[self alloc] init]; 31| 0|} 32| | 33| 0|- (instancetype)init { 34| 0| self = [super init]; 35| 0| if (!self) return self; 36| | 37| 0| _task = [[BFTask alloc] init]; 38| | 39| 0| return self; 40| 0|} 41| | 42| |#pragma mark - Custom Setters/Getters 43| | 44| 0|- (void)setResult:(nullable id)result { 45| 0| if (![self.task trySetResult:result]) { 46| 0| [NSException raise:NSInternalInconsistencyException 47| 0| format:@"Cannot set the result on a completed task."]; 48| 0| } 49| 0|} 50| | 51| 0|- (void)setError:(NSError *)error { 52| 0| if (![self.task trySetError:error]) { 53| 0| [NSException raise:NSInternalInconsistencyException 54| 0| format:@"Cannot set the error on a completed task."]; 55| 0| } 56| 0|} 57| | 58| 0|- (void)cancel { 59| 0| if (![self.task trySetCancelled]) { 60| 0| [NSException raise:NSInternalInconsistencyException 61| 0| format:@"Cannot cancel a completed task."]; 62| 0| } 63| 0|} 64| | 65| 0|- (BOOL)trySetResult:(nullable id)result { 66| 0| return [self.task trySetResult:result]; 67| 0|} 68| | 69| 0|- (BOOL)trySetError:(NSError *)error { 70| 0| return [self.task trySetError:error]; 71| 0|} 72| | 73| 0|- (BOOL)trySetCancelled { 74| 0| return [self.task trySetCancelled]; 75| 0|} 76| | 77| |@end 78| | 79| |NS_ASSUME_NONNULL_END /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/FBSDKAppEvents.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKAppEvents.h" 20| |#import "FBSDKAppEvents+EventLogging.h" 21| |#import "FBSDKAppEvents+Internal.h" 22| | 23| |#import 24| |#import 25| | 26| |#import 27| | 28| |#import "FBSDKAEMReporter.h" 29| |#import "FBSDKAccessToken.h" 30| |#import "FBSDKAppEventsConfiguration.h" 31| |#import "FBSDKAppEventsConfigurationProviding.h" 32| |#import "FBSDKAppEventsDeviceInfo.h" 33| |#import "FBSDKAppEventsParameterProcessing.h" 34| |#import "FBSDKAppEventsState.h" 35| |#import "FBSDKAppEventsStatePersisting.h" 36| |#import "FBSDKAppEventsStateProviding.h" 37| |#import "FBSDKAppEventsUtility.h" 38| |#import "FBSDKAtePublisherCreating.h" 39| |#import "FBSDKAtePublishing.h" 40| |#import "FBSDKCodelessIndexer.h" 41| |#import "FBSDKConstants.h" 42| |#import "FBSDKCoreKitBasicsImport.h" 43| |#import "FBSDKDataPersisting.h" 44| |#import "FBSDKDynamicFrameworkLoader.h" 45| |#import "FBSDKError.h" 46| |#import "FBSDKEventsProcessing.h" 47| |#import "FBSDKFeatureChecking.h" 48| |#import "FBSDKGateKeeperManaging.h" 49| |#import "FBSDKGraphRequestProtocol.h" 50| |#import "FBSDKGraphRequestProviding.h" 51| |#import "FBSDKInternalUtility.h" 52| |#import "FBSDKLogger.h" 53| |#import "FBSDKLogging.h" 54| |#import "FBSDKMetadataIndexing.h" 55| |#import "FBSDKPaymentObserving.h" 56| |#import "FBSDKSKAdNetworkReporter.h" 57| |#import "FBSDKServerConfiguration.h" 58| |#import "FBSDKServerConfigurationProviding.h" 59| |#import "FBSDKSettingsProtocol.h" 60| |#import "FBSDKSwizzling.h" 61| |#import "FBSDKTimeSpentRecordingCreating.h" 62| |#import "FBSDKUtility.h" 63| | 64| |#if !TARGET_OS_TV 65| | 66| | #import "FBSDKEventBindingManager.h" 67| | #import "FBSDKEventProcessing.h" 68| | #import "FBSDKHybridAppEventsScriptMessageHandler.h" 69| | #import "FBSDKIntegrityParametersProcessorProvider.h" 70| | 71| |#endif 72| | 73| |// 74| |// Public event names 75| |// 76| | 77| |// General purpose 78| |FBSDKAppEventName FBSDKAppEventNameCompletedRegistration = @"fb_mobile_complete_registration"; 79| |FBSDKAppEventName FBSDKAppEventNameViewedContent = @"fb_mobile_content_view"; 80| |FBSDKAppEventName FBSDKAppEventNameSearched = @"fb_mobile_search"; 81| |FBSDKAppEventName FBSDKAppEventNameRated = @"fb_mobile_rate"; 82| |FBSDKAppEventName FBSDKAppEventNameCompletedTutorial = @"fb_mobile_tutorial_completion"; 83| |FBSDKAppEventName FBSDKAppEventNameContact = @"Contact"; 84| |FBSDKAppEventName FBSDKAppEventNameCustomizeProduct = @"CustomizeProduct"; 85| |FBSDKAppEventName FBSDKAppEventNameDonate = @"Donate"; 86| |FBSDKAppEventName FBSDKAppEventNameFindLocation = @"FindLocation"; 87| |FBSDKAppEventName FBSDKAppEventNameSchedule = @"Schedule"; 88| |FBSDKAppEventName FBSDKAppEventNameStartTrial = @"StartTrial"; 89| |FBSDKAppEventName FBSDKAppEventNameSubmitApplication = @"SubmitApplication"; 90| |FBSDKAppEventName FBSDKAppEventNameSubscribe = @"Subscribe"; 91| |FBSDKAppEventName FBSDKAppEventNameSubscriptionHeartbeat = @"SubscriptionHeartbeat"; 92| |FBSDKAppEventName FBSDKAppEventNameAdImpression = @"AdImpression"; 93| |FBSDKAppEventName FBSDKAppEventNameAdClick = @"AdClick"; 94| | 95| |// Ecommerce related 96| |FBSDKAppEventName FBSDKAppEventNameAddedToCart = @"fb_mobile_add_to_cart"; 97| |FBSDKAppEventName FBSDKAppEventNameAddedToWishlist = @"fb_mobile_add_to_wishlist"; 98| |FBSDKAppEventName FBSDKAppEventNameInitiatedCheckout = @"fb_mobile_initiated_checkout"; 99| |FBSDKAppEventName FBSDKAppEventNameAddedPaymentInfo = @"fb_mobile_add_payment_info"; 100| |FBSDKAppEventName FBSDKAppEventNameProductCatalogUpdate = @"fb_mobile_catalog_update"; 101| |FBSDKAppEventName FBSDKAppEventNamePurchased = @"fb_mobile_purchase"; 102| | 103| |// Gaming related 104| |FBSDKAppEventName FBSDKAppEventNameAchievedLevel = @"fb_mobile_level_achieved"; 105| |FBSDKAppEventName FBSDKAppEventNameUnlockedAchievement = @"fb_mobile_achievement_unlocked"; 106| |FBSDKAppEventName FBSDKAppEventNameSpentCredits = @"fb_mobile_spent_credits"; 107| | 108| |// 109| |// Public event parameter names 110| |// 111| | 112| |FBSDKAppEventParameterName FBSDKAppEventParameterNameCurrency = @"fb_currency"; 113| |FBSDKAppEventParameterName FBSDKAppEventParameterNameRegistrationMethod = @"fb_registration_method"; 114| |FBSDKAppEventParameterName FBSDKAppEventParameterNameContentType = @"fb_content_type"; 115| |FBSDKAppEventParameterName FBSDKAppEventParameterNameContent = @"fb_content"; 116| |FBSDKAppEventParameterName FBSDKAppEventParameterNameContentID = @"fb_content_id"; 117| |FBSDKAppEventParameterName FBSDKAppEventParameterNameSearchString = @"fb_search_string"; 118| |FBSDKAppEventParameterName FBSDKAppEventParameterNameSuccess = @"fb_success"; 119| |FBSDKAppEventParameterName FBSDKAppEventParameterNameMaxRatingValue = @"fb_max_rating_value"; 120| |FBSDKAppEventParameterName FBSDKAppEventParameterNamePaymentInfoAvailable = @"fb_payment_info_available"; 121| |FBSDKAppEventParameterName FBSDKAppEventParameterNameNumItems = @"fb_num_items"; 122| |FBSDKAppEventParameterName FBSDKAppEventParameterNameLevel = @"fb_level"; 123| |FBSDKAppEventParameterName FBSDKAppEventParameterNameDescription = @"fb_description"; 124| |FBSDKAppEventParameterName FBSDKAppEventParameterNameAdType = @"ad_type"; 125| |FBSDKAppEventParameterName FBSDKAppEventParameterNameOrderID = @"fb_order_id"; 126| | 127| |// 128| |// Public event parameter names for DPA Catalog 129| |// 130| | 131| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductCustomLabel0 = @"fb_product_custom_label_0"; 132| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductCustomLabel1 = @"fb_product_custom_label_1"; 133| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductCustomLabel2 = @"fb_product_custom_label_2"; 134| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductCustomLabel3 = @"fb_product_custom_label_3"; 135| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductCustomLabel4 = @"fb_product_custom_label_4"; 136| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductCategory = @"fb_product_category"; 137| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductAppLinkIOSUrl = @"fb_product_applink_ios_url"; 138| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductAppLinkIOSAppStoreID = @"fb_product_applink_ios_app_store_id"; 139| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductAppLinkIOSAppName = @"fb_product_applink_ios_app_name"; 140| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductAppLinkIPhoneUrl = @"fb_product_applink_iphone_url"; 141| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductAppLinkIPhoneAppStoreID = @"fb_product_applink_iphone_app_store_id"; 142| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductAppLinkIPhoneAppName = @"fb_product_applink_iphone_app_name"; 143| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductAppLinkIPadUrl = @"fb_product_applink_ipad_url"; 144| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductAppLinkIPadAppStoreID = @"fb_product_applink_ipad_app_store_id"; 145| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductAppLinkIPadAppName = @"fb_product_applink_ipad_app_name"; 146| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductAppLinkAndroidUrl = @"fb_product_applink_android_url"; 147| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductAppLinkAndroidPackage = @"fb_product_applink_android_package"; 148| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductAppLinkAndroidAppName = @"fb_product_applink_android_app_name"; 149| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductAppLinkWindowsPhoneUrl = @"fb_product_applink_windows_phone_url"; 150| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductAppLinkWindowsPhoneAppID = @"fb_product_applink_windows_phone_app_id"; 151| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductAppLinkWindowsPhoneAppName = @"fb_product_applink_windows_phone_app_name"; 152| | 153| |// 154| |// Public event parameter values 155| |// 156| | 157| |FBSDKAppEventParameterValue FBSDKAppEventParameterValueNo = @"0"; 158| |FBSDKAppEventParameterValue FBSDKAppEventParameterValueYes = @"1"; 159| | 160| |// 161| |// Event names internal to this file 162| |// 163| |FBSDKAppEventName FBSDKAppEventNameShareSheetLaunch = @"fb_share_sheet_launch"; 164| |FBSDKAppEventName FBSDKAppEventNameShareSheetDismiss = @"fb_share_sheet_dismiss"; 165| |FBSDKAppEventName FBSDKAppEventNameShareTrayDidLaunch = @"fb_share_tray_did_launch"; 166| |FBSDKAppEventName FBSDKAppEventNameShareTrayDidSelectActivity = @"fb_share_tray_did_select_activity"; 167| |FBSDKAppEventName FBSDKAppEventNamePermissionsUILaunch = @"fb_permissions_ui_launch"; 168| |FBSDKAppEventName FBSDKAppEventNamePermissionsUIDismiss = @"fb_permissions_ui_dismiss"; 169| |FBSDKAppEventName FBSDKAppEventNameFBDialogsPresentShareDialog = @"fb_dialogs_present_share"; 170| |FBSDKAppEventName FBSDKAppEventNameFBDialogsPresentShareDialogPhoto = @"fb_dialogs_present_share_photo"; 171| |FBSDKAppEventName FBSDKAppEventNameFBDialogsPresentShareDialogOG = @"fb_dialogs_present_share_og"; 172| |FBSDKAppEventName FBSDKAppEventNameFBDialogsPresentLikeDialogOG = @"fb_dialogs_present_like_og"; 173| |FBSDKAppEventName FBSDKAppEventNameFBDialogsPresentMessageDialog = @"fb_dialogs_present_message"; 174| |FBSDKAppEventName FBSDKAppEventNameFBDialogsPresentMessageDialogPhoto = @"fb_dialogs_present_message_photo"; 175| | 176| |FBSDKAppEventName FBSDKAppEventNameFBSDKLikeButtonImpression = @"fb_like_button_impression"; 177| |FBSDKAppEventName FBSDKAppEventNameFBSDKLiveStreamingButtonImpression = @"fb_live_streaming_button_impression"; 178| | 179| |FBSDKAppEventName FBSDKAppEventNameFBSDKLikeButtonDidTap = @"fb_like_button_did_tap"; 180| |FBSDKAppEventName FBSDKAppEventNameFBSDKLiveStreamingButtonDidTap = @"fb_live_streaming_button_did_tap"; 181| | 182| |FBSDKAppEventName FBSDKAppEventNameFBSDKEventAppInviteShareDialogResult = @"fb_app_invite_dialog_share_result"; 183| | 184| |FBSDKAppEventName FBSDKAppEventNameFBSDKEventAppInviteShareDialogShow = @"fb_app_invite_share_show"; 185| | 186| |FBSDKAppEventName FBSDKAppEventNameFBSDKLiveStreamingStart = @"fb_sdk_live_streaming_start"; 187| |FBSDKAppEventName FBSDKAppEventNameFBSDKLiveStreamingStop = @"fb_sdk_live_streaming_stop"; 188| |FBSDKAppEventName FBSDKAppEventNameFBSDKLiveStreamingPause = @"fb_sdk_live_streaming_pause"; 189| |FBSDKAppEventName FBSDKAppEventNameFBSDKLiveStreamingResume = @"fb_sdk_live_streaming_resume"; 190| |FBSDKAppEventName FBSDKAppEventNameFBSDKLiveStreamingError = @"fb_sdk_live_streaming_error"; 191| |FBSDKAppEventName FBSDKAppEventNameFBSDKLiveStreamingUpdateStatus = @"fb_sdk_live_streaming_update_status"; 192| |FBSDKAppEventName FBSDKAppEventNameFBSDKLiveStreamingVideoID = @"fb_sdk_live_streaming_video_id"; 193| |FBSDKAppEventName FBSDKAppEventNameFBSDKLiveStreamingMic = @"fb_sdk_live_streaming_mic"; 194| |FBSDKAppEventName FBSDKAppEventNameFBSDKLiveStreamingCamera = @"fb_sdk_live_streaming_camera"; 195| | 196| |// Event Parameters internal to this file 197| |NSString *const FBSDKAppEventParameterShareTrayActivityName = @"fb_share_tray_activity"; 198| |NSString *const FBSDKAppEventParameterShareTrayResult = @"fb_share_tray_result"; 199| |NSString *const FBSDKAppEventParameterLogTime = @"_logTime"; 200| |NSString *const FBSDKAppEventParameterEventName = @"_eventName"; 201| |NSString *const FBSDKAppEventParameterImplicitlyLogged = @"_implicitlyLogged"; 202| |NSString *const FBSDKAppEventParameterInBackground = @"_inBackground"; 203| | 204| |NSString *const FBSDKAppEventParameterLiveStreamingPrevStatus = @"live_streaming_prev_status"; 205| |NSString *const FBSDKAppEventParameterLiveStreamingStatus = @"live_streaming_status"; 206| |NSString *const FBSDKAppEventParameterLiveStreamingError = @"live_streaming_error"; 207| |NSString *const FBSDKAppEventParameterLiveStreamingVideoID = @"live_streaming_video_id"; 208| |NSString *const FBSDKAppEventParameterLiveStreamingMicEnabled = @"live_streaming_mic_enabled"; 209| |NSString *const FBSDKAppEventParameterLiveStreamingCameraEnabled = @"live_streaming_camera_enabled"; 210| | 211| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductItemID = @"fb_product_item_id"; 212| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductAvailability = @"fb_product_availability"; 213| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductCondition = @"fb_product_condition"; 214| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductDescription = @"fb_product_description"; 215| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductImageLink = @"fb_product_image_link"; 216| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductLink = @"fb_product_link"; 217| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductTitle = @"fb_product_title"; 218| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductGTIN = @"fb_product_gtin"; 219| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductMPN = @"fb_product_mpn"; 220| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductBrand = @"fb_product_brand"; 221| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductPriceAmount = @"fb_product_price_amount"; 222| |FBSDKAppEventParameterProduct FBSDKAppEventParameterProductPriceCurrency = @"fb_product_price_currency"; 223| | 224| |// Event parameter values internal to this file 225| | 226| |NSString *const FBSDKGateKeeperAppEventsKillSwitch = @"app_events_killswitch"; 227| | 228| |#if __IPHONE_OS_VERSION_MAX_ALLOWED >= __IPHONE_10_0 229| | 230| |NSNotificationName const FBSDKAppEventsLoggingResultNotification = @"com.facebook.sdk:FBSDKAppEventsLoggingResultNotification"; 231| | 232| |#else 233| | 234| |NSString *const FBSDKAppEventsLoggingResultNotification = @"com.facebook.sdk:FBSDKAppEventsLoggingResultNotification"; 235| | 236| |#endif 237| | 238| |NSString *const FBSDKAppEventsOverrideAppIDBundleKey = @"FacebookLoggingOverrideAppID"; 239| | 240| |// 241| |// Push Notifications 242| |// 243| |// Activities Endpoint Parameter 244| |static NSString *const FBSDKActivitesParameterPushDeviceToken = @"device_token"; 245| |// Event Names 246| |static FBSDKAppEventName FBSDKAppEventNamePushTokenObtained = @"fb_mobile_obtain_push_token"; 247| |static FBSDKAppEventName FBSDKAppEventNamePushOpened = @"fb_mobile_push_opened"; 248| |// Event Parameter 249| |static NSString *const FBSDKAppEventParameterPushCampaign = @"fb_push_campaign"; 250| |static NSString *const FBSDKAppEventParameterPushAction = @"fb_push_action"; 251| |// Payload Keys 252| |static NSString *const FBSDKAppEventsPushPayloadKey = @"fb_push_payload"; 253| |static NSString *const FBSDKAppEventsPushPayloadCampaignKey = @"campaign"; 254| | 255| |// 256| |// Augmentation of web browser constants 257| |// 258| |NSString *const FBSDKAppEventsWKWebViewMessagesPixelIDKey = @"pixelID"; 259| |NSString *const FBSDKAppEventsWKWebViewMessagesHandlerKey = @"fbmqHandler"; 260| |NSString *const FBSDKAppEventsWKWebViewMessagesEventKey = @"event"; 261| |NSString *const FBSDKAppEventsWKWebViewMessagesParamsKey = @"params"; 262| |NSString *const FBSDKAPPEventsWKWebViewMessagesProtocolKey = @"fbmq-0.1"; 263| | 264| 0|#define NUM_LOG_EVENTS_TO_TRY_TO_FLUSH_AFTER 100 265| 0|#define FLUSH_PERIOD_IN_SECONDS 15 266| 0|#define USER_ID_USER_DEFAULTS_KEY @"com.facebook.sdk.appevents.userid" 267| | 268| 0|#define FBUnityUtilityClassName "FBUnityUtility" 269| 0|#define FBUnityUtilityUpdateBindingsSelector @"triggerUpdateBindings:" 270| | 271| |static NSString *g_overrideAppID = nil; 272| |static BOOL g_explicitEventsLoggedYet; 273| |static Class g_gateKeeperManager; 274| |static Class g_appEventsConfigurationProvider; 275| |static Class g_serverConfigurationProvider; 276| |static id g_graphRequestProvider; 277| |static id g_featureChecker; 278| |static Class g_logger; 279| |static id g_settings; 280| |static id g_paymentObserver; 281| |static id g_appEventsStateStore; 282| |static id g_eventDeactivationParameterProcessor; 283| |static id g_restrictiveDataFilterParameterProcessor; 284| | 285| |#if !TARGET_OS_TV 286| |static id g_onDeviceMLModelManager = nil; 287| |static id g_metadataIndexer = nil; 288| |#endif 289| | 290| |@interface FBSDKAppEvents () 291| | 292| |@property (nullable, nonatomic) id store; 293| |@property (nonatomic, assign) FBSDKAppEventsFlushBehavior flushBehavior; 294| |@property (nonatomic) UIApplicationState applicationState; 295| |@property (nonatomic, copy) NSString *pushNotificationsDeviceTokenString; 296| |@property (nonatomic, strong) dispatch_source_t flushTimer; 297| |@property (nonatomic, copy) NSString *userID; 298| |@property (nonatomic, strong) id atePublisher; 299| |@property (nullable, nonatomic) Class swizzler; 300| |@property (nullable, nonatomic) id timeSpentRecorder; 301| |@property (nonatomic, strong) id appEventsStateProvider; 302| |@property (nonatomic) BOOL isConfigured; 303| | 304| |@property (nonatomic, assign) BOOL disableTimer; // for testing only. 305| | 306| |@end 307| | 308| |@implementation FBSDKAppEvents 309| |{ 310| | FBSDKServerConfiguration *_serverConfiguration; 311| | FBSDKAppEventsState *_appEventsState; 312| |#if !TARGET_OS_TV 313| | FBSDKEventBindingManager *_eventBindingManager; 314| |#endif 315| | BOOL _isUnityInit; 316| |} 317| | 318| |#pragma mark - Object Lifecycle 319| | 320| |+ (void)initialize 321| 0|{ 322| 0| if (self == [FBSDKAppEvents class]) { 323| 0| g_overrideAppID = [[[NSBundle mainBundle] objectForInfoDictionaryKey:FBSDKAppEventsOverrideAppIDBundleKey] copy]; 324| 0| dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_BACKGROUND, 0), ^(void) { 325| 0| [FBSDKBasicUtility anonymousID]; 326| 0| }); 327| 0| } 328| 0|} 329| | 330| |- (instancetype)init 331| 0|{ 332| 0| return [self initWithFlushBehavior:FBSDKAppEventsFlushBehaviorAuto 333| 0| flushPeriodInSeconds:FLUSH_PERIOD_IN_SECONDS]; 334| 0|} 335| | 336| |- (instancetype)initWithFlushBehavior:(FBSDKAppEventsFlushBehavior)flushBehavior 337| | flushPeriodInSeconds:(int)flushPeriodInSeconds 338| 0|{ 339| 0| self = [super init]; 340| 0| if (self) { 341| 0| _flushBehavior = flushBehavior; 342| | 343| 0| __weak FBSDKAppEvents *weakSelf = self; 344| 0| self.flushTimer = [FBSDKUtility startGCDTimerWithInterval:flushPeriodInSeconds 345| 0| block:^{ 346| 0| [weakSelf flushTimerFired:nil]; 347| 0| }]; 348| | 349| 0| self.applicationState = UIApplicationStateInactive; 350| 0| } 351| | 352| 0| return self; 353| 0|} 354| | 355| |- (void)startObservingApplicationLifecycleNotifications 356| 0|{ 357| 0| [[NSNotificationCenter defaultCenter] 358| 0| addObserver:self 359| 0| selector:@selector(applicationMovingFromActiveStateOrTerminating) 360| 0| name:UIApplicationWillResignActiveNotification 361| 0| object:NULL]; 362| | 363| 0| [[NSNotificationCenter defaultCenter] 364| 0| addObserver:self 365| 0| selector:@selector(applicationMovingFromActiveStateOrTerminating) 366| 0| name:UIApplicationWillTerminateNotification 367| 0| object:NULL]; 368| | 369| 0| [[NSNotificationCenter defaultCenter] 370| 0| addObserver:self 371| 0| selector:@selector(applicationDidBecomeActive) 372| 0| name:UIApplicationDidBecomeActiveNotification 373| 0| object:NULL]; 374| 0|} 375| | 376| |- (void)dealloc 377| 0|{ 378| 0| [[NSNotificationCenter defaultCenter] removeObserver:self]; 379| 0| [FBSDKUtility stopGCDTimer:self.flushTimer]; 380| 0|} 381| | 382| |#pragma mark - Public Methods 383| | 384| |+ (void)logEvent:(FBSDKAppEventName)eventName 385| 0|{ 386| 0| [self.singleton logEvent:eventName]; 387| 0|} 388| | 389| |- (void)logEvent:(FBSDKAppEventName)eventName 390| 0|{ 391| 0| [self logEvent:eventName 392| 0| parameters:@{}]; 393| 0|} 394| | 395| |+ (void)logEvent:(FBSDKAppEventName)eventName 396| | valueToSum:(double)valueToSum 397| 0|{ 398| 0| [self.singleton logEvent:eventName 399| 0| valueToSum:valueToSum]; 400| 0|} 401| | 402| |- (void)logEvent:(FBSDKAppEventName)eventName 403| | valueToSum:(double)valueToSum 404| 0|{ 405| 0| [self logEvent:eventName 406| 0| valueToSum:valueToSum 407| 0| parameters:@{}]; 408| 0|} 409| | 410| |+ (void)logEvent:(FBSDKAppEventName)eventName 411| | parameters:(NSDictionary *)parameters 412| 0|{ 413| 0| [self.singleton logEvent:eventName 414| 0| parameters:parameters]; 415| 0|} 416| | 417| |- (void)logEvent:(NSString *)eventName 418| | parameters:(NSDictionary *)parameters 419| 0|{ 420| 0| [FBSDKAppEvents logEvent:eventName 421| 0| valueToSum:nil 422| 0| parameters:parameters 423| 0| accessToken:nil]; 424| 0|} 425| | 426| |+ (void)logEvent:(FBSDKAppEventName)eventName 427| | valueToSum:(double)valueToSum 428| | parameters:(NSDictionary *)parameters 429| 0|{ 430| 0| [self.singleton logEvent:eventName 431| 0| valueToSum:valueToSum 432| 0| parameters:parameters]; 433| 0|} 434| | 435| |- (void)logEvent:(FBSDKAppEventName)eventName 436| | valueToSum:(double)valueToSum 437| | parameters:(NSDictionary *)parameters 438| 0|{ 439| 0| [FBSDKAppEvents logEvent:eventName 440| 0| valueToSum:@(valueToSum) 441| 0| parameters:parameters 442| 0| accessToken:nil]; 443| 0|} 444| | 445| |+ (void)logEvent:(FBSDKAppEventName)eventName 446| | valueToSum:(NSNumber *)valueToSum 447| | parameters:(NSDictionary *)parameters 448| | accessToken:(FBSDKAccessToken *)accessToken 449| 0|{ 450| 0| [self.singleton logEvent:eventName 451| 0| valueToSum:valueToSum 452| 0| parameters:parameters 453| 0| accessToken:accessToken]; 454| 0|} 455| | 456| |- (void)logEvent:(FBSDKAppEventName)eventName 457| | valueToSum:(NSNumber *)valueToSum 458| | parameters:(NSDictionary *)parameters 459| | accessToken:(FBSDKAccessToken *)accessToken 460| 0|{ 461| 0| [self instanceLogEvent:eventName 462| 0| valueToSum:valueToSum 463| 0| parameters:parameters 464| 0| isImplicitlyLogged:[parameters[FBSDKAppEventParameterImplicitlyLogged] boolValue] 465| 0| accessToken:accessToken]; 466| 0|} 467| | 468| |+ (void)logPurchase:(double)purchaseAmount 469| | currency:(NSString *)currency 470| 0|{ 471| 0| [FBSDKAppEvents logPurchase:purchaseAmount 472| 0| currency:currency 473| 0| parameters:@{}]; 474| 0|} 475| | 476| |+ (void)logPurchase:(double)purchaseAmount 477| | currency:(NSString *)currency 478| | parameters:(NSDictionary *)parameters 479| 0|{ 480| 0| [FBSDKAppEvents logPurchase:purchaseAmount 481| 0| currency:currency 482| 0| parameters:parameters 483| 0| accessToken:nil]; 484| 0|} 485| | 486| |+ (void)logPurchase:(double)purchaseAmount 487| | currency:(NSString *)currency 488| | parameters:(NSDictionary *)parameters 489| | accessToken:(FBSDKAccessToken *)accessToken 490| 0|{ 491| 0| [self.singleton validateConfiguration]; 492| | 493| | // A purchase event is just a regular logged event with a given event name 494| | // and treating the currency value as going into the parameters dictionary. 495| 0| NSDictionary *newParameters; 496| 0| if (!parameters) { 497| 0| newParameters = @{ FBSDKAppEventParameterNameCurrency : currency }; 498| 0| } else { 499| 0| newParameters = [NSMutableDictionary dictionaryWithDictionary:parameters]; 500| 0| [newParameters setValue:currency forKey:FBSDKAppEventParameterNameCurrency]; 501| 0| } 502| | 503| 0| [FBSDKAppEvents logEvent:FBSDKAppEventNamePurchased 504| 0| valueToSum:@(purchaseAmount) 505| 0| parameters:newParameters 506| 0| accessToken:accessToken]; 507| | 508| | // Unless the behavior is set to only allow explicit flushing, we go ahead and flush, since purchase events 509| | // are relatively rare and relatively high value and worth getting across on wire right away. 510| 0| if ([FBSDKAppEvents flushBehavior] != FBSDKAppEventsFlushBehaviorExplicitOnly) { 511| 0| [[FBSDKAppEvents singleton] flushForReason:FBSDKAppEventsFlushReasonEagerlyFlushingEvent]; 512| 0| } 513| 0|} 514| | 515| |/* 516| | * Push Notifications Logging 517| | */ 518| | 519| |+ (void)logPushNotificationOpen:(NSDictionary *)payload 520| 0|{ 521| 0| [self logPushNotificationOpen:payload action:@""]; 522| 0|} 523| | 524| |+ (void)logPushNotificationOpen:(NSDictionary *)payload action:(NSString *)action 525| 0|{ 526| 0| [self.singleton validateConfiguration]; 527| | 528| 0| NSDictionary *facebookPayload = payload[FBSDKAppEventsPushPayloadKey]; 529| 0| if (!facebookPayload) { 530| 0| return; 531| 0| } 532| 0| NSString *campaign = facebookPayload[FBSDKAppEventsPushPayloadCampaignKey]; 533| 0| if (campaign.length == 0) { 534| 0| [g_logger singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors 535| 0| logEntry:@"Malformed payload specified for logging a push notification open."]; 536| 0| return; 537| 0| } 538| | 539| 0| NSMutableDictionary *parameters = [NSMutableDictionary dictionaryWithObject:campaign forKey:FBSDKAppEventParameterPushCampaign]; 540| 0| if (action && action.length > 0) { 541| 0| [FBSDKTypeUtility dictionary:parameters setObject:action forKey:FBSDKAppEventParameterPushAction]; 542| 0| } 543| 0| [self logEvent:FBSDKAppEventNamePushOpened parameters:parameters]; 544| 0|} 545| | 546| |/* 547| | * Uploads product catalog product item as an app event 548| | */ 549| |+ (void)logProductItem:(NSString *)itemID 550| | availability:(FBSDKProductAvailability)availability 551| | condition:(FBSDKProductCondition)condition 552| | description:(NSString *)description 553| | imageLink:(NSString *)imageLink 554| | link:(NSString *)link 555| | title:(NSString *)title 556| | priceAmount:(double)priceAmount 557| | currency:(NSString *)currency 558| | gtin:(NSString *)gtin 559| | mpn:(NSString *)mpn 560| | brand:(NSString *)brand 561| | parameters:(NSDictionary *)parameters 562| 0|{ 563| 0| [self.singleton validateConfiguration]; 564| | 565| 0| if (itemID == nil) { 566| 0| [g_logger singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors 567| 0| logEntry:@"itemID cannot be null"]; 568| 0| return; 569| 0| } else if (description == nil) { 570| 0| [g_logger singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors 571| 0| logEntry:@"description cannot be null"]; 572| 0| return; 573| 0| } else if (imageLink == nil) { 574| 0| [g_logger singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors 575| 0| logEntry:@"imageLink cannot be null"]; 576| 0| return; 577| 0| } else if (link == nil) { 578| 0| [g_logger singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors 579| 0| logEntry:@"link cannot be null"]; 580| 0| return; 581| 0| } else if (title == nil) { 582| 0| [g_logger singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors 583| 0| logEntry:@"title cannot be null"]; 584| 0| return; 585| 0| } else if (currency == nil) { 586| 0| [g_logger singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors 587| 0| logEntry:@"currency cannot be null"]; 588| 0| return; 589| 0| } else if (gtin == nil && mpn == nil && brand == nil) { 590| 0| [g_logger singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors 591| 0| logEntry:@"Either gtin, mpn or brand is required"]; 592| 0| return; 593| 0| } 594| | 595| 0| NSMutableDictionary *dict = [NSMutableDictionary dictionary]; 596| 0| if (nil != parameters) { 597| 0| [dict setValuesForKeysWithDictionary:parameters]; 598| 0| } 599| | 600| 0| [FBSDKTypeUtility dictionary:dict setObject:itemID forKey:FBSDKAppEventParameterProductItemID]; 601| | 602| 0| NSString *avail = nil; 603| 0| switch (availability) { 604| 0| case FBSDKProductAvailabilityInStock: 605| 0| avail = @"IN_STOCK"; break; 606| 0| case FBSDKProductAvailabilityOutOfStock: 607| 0| avail = @"OUT_OF_STOCK"; break; 608| 0| case FBSDKProductAvailabilityPreOrder: 609| 0| avail = @"PREORDER"; break; 610| 0| case FBSDKProductAvailabilityAvailableForOrder: 611| 0| avail = @"AVALIABLE_FOR_ORDER"; break; 612| 0| case FBSDKProductAvailabilityDiscontinued: 613| 0| avail = @"DISCONTINUED"; break; 614| 0| } 615| 0| if (avail) { 616| 0| [FBSDKTypeUtility dictionary:dict setObject:avail forKey:FBSDKAppEventParameterProductAvailability]; 617| 0| } 618| | 619| 0| NSString *cond = nil; 620| 0| switch (condition) { 621| 0| case FBSDKProductConditionNew: 622| 0| cond = @"NEW"; break; 623| 0| case FBSDKProductConditionRefurbished: 624| 0| cond = @"REFURBISHED"; break; 625| 0| case FBSDKProductConditionUsed: 626| 0| cond = @"USED"; break; 627| 0| } 628| 0| if (cond) { 629| 0| [FBSDKTypeUtility dictionary:dict setObject:cond forKey:FBSDKAppEventParameterProductCondition]; 630| 0| } 631| | 632| 0| [FBSDKTypeUtility dictionary:dict setObject:description forKey:FBSDKAppEventParameterProductDescription]; 633| 0| [FBSDKTypeUtility dictionary:dict setObject:imageLink forKey:FBSDKAppEventParameterProductImageLink]; 634| 0| [FBSDKTypeUtility dictionary:dict setObject:link forKey:FBSDKAppEventParameterProductLink]; 635| 0| [FBSDKTypeUtility dictionary:dict setObject:title forKey:FBSDKAppEventParameterProductTitle]; 636| 0| [FBSDKTypeUtility dictionary:dict setObject:[NSString stringWithFormat:@"%.3lf", priceAmount] forKey:FBSDKAppEventParameterProductPriceAmount]; 637| 0| [FBSDKTypeUtility dictionary:dict setObject:currency forKey:FBSDKAppEventParameterProductPriceCurrency]; 638| 0| if (gtin) { 639| 0| [FBSDKTypeUtility dictionary:dict setObject:gtin forKey:FBSDKAppEventParameterProductGTIN]; 640| 0| } 641| 0| if (mpn) { 642| 0| [FBSDKTypeUtility dictionary:dict setObject:mpn forKey:FBSDKAppEventParameterProductMPN]; 643| 0| } 644| 0| if (brand) { 645| 0| [FBSDKTypeUtility dictionary:dict setObject:brand forKey:FBSDKAppEventParameterProductBrand]; 646| 0| } 647| | 648| 0| [FBSDKAppEvents logEvent:FBSDKAppEventNameProductCatalogUpdate 649| 0| parameters:dict]; 650| 0|} 651| | 652| |+ (void)activateApp 653| 0|{ 654| 0| [self.singleton activateApp]; 655| 0|} 656| | 657| |- (void)activateApp 658| 0|{ 659| 0| [self validateConfiguration]; 660| | 661| 0| [FBSDKAppEventsUtility ensureOnMainThread:NSStringFromSelector(_cmd) className:NSStringFromClass(self.class)]; 662| | 663| | // Fetch app settings and register for transaction notifications only if app supports implicit purchase 664| | // events 665| 0| [self publishInstall]; 666| 0| [self fetchServerConfiguration:NULL]; 667| | 668| | // Restore time spent data, indicating that we're being called from "activateApp", which will, 669| | // when appropriate, result in logging an "activated app" and "deactivated app" (for the 670| | // previous session) App Event. 671| 0| [self.timeSpentRecorder restore:YES]; 672| 0|} 673| | 674| |+ (void)setPushNotificationsDeviceToken:(NSData *)deviceToken 675| 0|{ 676| 0| [self.singleton validateConfiguration]; 677| | 678| 0| NSString *deviceTokenString = [FBSDKInternalUtility hexadecimalStringFromData:deviceToken]; 679| 0| [FBSDKAppEvents setPushNotificationsDeviceTokenString:deviceTokenString]; 680| 0|} 681| | 682| |+ (void)setPushNotificationsDeviceTokenString:(NSString *)deviceTokenString 683| 0|{ 684| 0| [self.singleton validateConfiguration]; 685| | 686| 0| if (deviceTokenString == nil) { 687| 0| [FBSDKAppEvents singleton].pushNotificationsDeviceTokenString = nil; 688| 0| return; 689| 0| } 690| | 691| 0| if (![deviceTokenString isEqualToString:([FBSDKAppEvents singleton].pushNotificationsDeviceTokenString)]) { 692| 0| [FBSDKAppEvents singleton].pushNotificationsDeviceTokenString = deviceTokenString; 693| | 694| 0| [FBSDKAppEvents logEvent:FBSDKAppEventNamePushTokenObtained]; 695| | 696| | // Unless the behavior is set to only allow explicit flushing, we go ahead and flush the event 697| 0| if ([FBSDKAppEvents flushBehavior] != FBSDKAppEventsFlushBehaviorExplicitOnly) { 698| 0| [[FBSDKAppEvents singleton] flushForReason:FBSDKAppEventsFlushReasonEagerlyFlushingEvent]; 699| 0| } 700| 0| } 701| 0|} 702| | 703| |+ (FBSDKAppEventsFlushBehavior)flushBehavior 704| 0|{ 705| 0| return [FBSDKAppEvents singleton].flushBehavior; 706| 0|} 707| | 708| |+ (void)setFlushBehavior:(FBSDKAppEventsFlushBehavior)flushBehavior 709| 0|{ 710| 0| [self.singleton validateConfiguration]; 711| | 712| 0| self.singleton.flushBehavior = flushBehavior; 713| 0|} 714| | 715| |+ (NSString *)loggingOverrideAppID 716| 0|{ 717| 0| return g_overrideAppID; 718| 0|} 719| | 720| |+ (void)setLoggingOverrideAppID:(NSString *)appID 721| 0|{ 722| 0| [self.singleton validateConfiguration]; 723| | 724| 0| if (![g_overrideAppID isEqualToString:appID]) { 725| 0| FBSDKConditionalLog( 726| 0| !g_explicitEventsLoggedYet, 727| 0| FBSDKLoggingBehaviorDeveloperErrors, 728| 0| @"[FBSDKAppEvents setLoggingOverrideAppID:] should only be called prior to any events being logged." 729| 0| ); 730| 0| g_overrideAppID = appID; 731| 0| } 732| 0|} 733| | 734| |+ (void)flush 735| 0|{ 736| 0| [self.singleton validateConfiguration]; 737| 0| [self.singleton flushForReason:FBSDKAppEventsFlushReasonExplicit]; 738| 0|} 739| | 740| |+ (void)setUserID:(NSString *)userID 741| 0|{ 742| 0| self.singleton.userID = userID; 743| 0|} 744| | 745| |- (void)setUserID:(NSString *)userID 746| 0|{ 747| 0| [self validateConfiguration]; 748| 0| _userID = [userID copy]; 749| 0| [self.store setObject:userID forKey:USER_ID_USER_DEFAULTS_KEY]; 750| 0|} 751| | 752| |+ (void)clearUserID 753| 0|{ 754| 0| [self.singleton clearUserID]; 755| 0|} 756| | 757| |- (void)clearUserID 758| 0|{ 759| 0| [self validateConfiguration]; 760| | 761| 0| self.userID = nil; 762| 0|} 763| | 764| |+ (NSString *)userID 765| 0|{ 766| 0| [self.singleton validateConfiguration]; 767| | 768| 0| return self.singleton.userID; 769| 0|} 770| | 771| |+ (void)setUserEmail:(nullable NSString *)email 772| | firstName:(nullable NSString *)firstName 773| | lastName:(nullable NSString *)lastName 774| | phone:(nullable NSString *)phone 775| | dateOfBirth:(nullable NSString *)dateOfBirth 776| | gender:(nullable NSString *)gender 777| | city:(nullable NSString *)city 778| | state:(nullable NSString *)state 779| | zip:(nullable NSString *)zip 780| | country:(nullable NSString *)country 781| 0|{ 782| 0| [FBSDKUserDataStore setUserEmail:email 783| 0| firstName:firstName 784| 0| lastName:lastName 785| 0| phone:phone 786| 0| dateOfBirth:dateOfBirth 787| 0| gender:gender 788| 0| city:city 789| 0| state:state 790| 0| zip:zip 791| 0| country:country 792| 0| externalId:nil]; 793| 0|} 794| | 795| |+ (NSString *)getUserData 796| 0|{ 797| 0| return [FBSDKUserDataStore getUserData]; 798| 0|} 799| | 800| |+ (void)clearUserData 801| 0|{ 802| 0| [FBSDKUserDataStore clearUserData]; 803| 0|} 804| | 805| |+ (void)setUserData:(nullable NSString *)data 806| | forType:(FBSDKAppEventUserDataType)type 807| 0|{ 808| 0| [FBSDKUserDataStore setUserData:data forType:type]; 809| 0|} 810| | 811| |+ (void)clearUserDataForType:(FBSDKAppEventUserDataType)type 812| 0|{ 813| 0| [FBSDKUserDataStore clearUserDataForType:type]; 814| 0|} 815| | 816| |+ (NSString *)anonymousID 817| 0|{ 818| 0| return [FBSDKBasicUtility anonymousID]; 819| 0|} 820| | 821| |#if !TARGET_OS_TV 822| |+ (void)augmentHybridWKWebView:(WKWebView *)webView 823| 0|{ 824| 0| [self.singleton validateConfiguration]; 825| | 826| 0| if ([webView isKindOfClass:WKWebView.class]) { 827| 0| if (WKUserScript.class != nil) { 828| 0| WKUserContentController *controller = webView.configuration.userContentController; 829| 0| FBSDKHybridAppEventsScriptMessageHandler *scriptHandler = [FBSDKHybridAppEventsScriptMessageHandler new]; 830| 0| [controller addScriptMessageHandler:scriptHandler name:FBSDKAppEventsWKWebViewMessagesHandlerKey]; 831| | 832| 0| NSString *js = [NSString stringWithFormat:@"window.fbmq_%@={'sendEvent': function(pixel_id,event_name,custom_data){var msg={\"%@\":pixel_id, \"%@\":event_name,\"%@\":custom_data};window.webkit.messageHandlers[\"%@\"].postMessage(msg);}, 'getProtocol':function(){return \"%@\";}}", 833| 0| [[self singleton] appID], 834| 0| FBSDKAppEventsWKWebViewMessagesPixelIDKey, 835| 0| FBSDKAppEventsWKWebViewMessagesEventKey, 836| 0| FBSDKAppEventsWKWebViewMessagesParamsKey, 837| 0| FBSDKAppEventsWKWebViewMessagesHandlerKey, 838| 0| FBSDKAPPEventsWKWebViewMessagesProtocolKey 839| 0| ]; 840| | 841| 0| [controller addUserScript:[[WKUserScript.class alloc] initWithSource:js injectionTime:WKUserScriptInjectionTimeAtDocumentStart forMainFrameOnly:NO]]; 842| 0| } 843| 0| } else { 844| 0| [FBSDKAppEventsUtility logAndNotify:@"You must call augmentHybridWKWebView with WebKit linked to your project and a WKWebView instance"]; 845| 0| } 846| 0|} 847| | 848| |#endif 849| | 850| |+ (void)setIsUnityInit:(BOOL)isUnityInit 851| 0|{ 852| 0| [FBSDKAppEvents singleton]->_isUnityInit = isUnityInit; 853| 0|} 854| | 855| |#pragma clang diagnostic push 856| |#pragma clang diagnostic ignored "-Warc-performSelector-leaks" 857| |+ (void)sendEventBindingsToUnity 858| 0|{ 859| 0| [self.singleton validateConfiguration]; 860| | 861| | // Send event bindings to Unity only Unity is initialized 862| 0| if ([FBSDKAppEvents singleton]->_isUnityInit 863| 0| && [FBSDKAppEvents singleton]->_serverConfiguration 864| 0| && [FBSDKTypeUtility isValidJSONObject:[FBSDKAppEvents singleton]->_serverConfiguration.eventBindings] 865| 0| ) { 866| 0| NSData *jsonData = [FBSDKTypeUtility dataWithJSONObject:[FBSDKAppEvents singleton]->_serverConfiguration.eventBindings ?: @"" 867| 0| options:0 868| 0| error:nil]; 869| 0| NSString *jsonString = [[NSString alloc] initWithData:jsonData encoding:NSUTF8StringEncoding]; 870| 0| Class classFBUnityUtility = objc_lookUpClass(FBUnityUtilityClassName); 871| 0| SEL updateBindingSelector = NSSelectorFromString(FBUnityUtilityUpdateBindingsSelector); 872| 0| if ([classFBUnityUtility respondsToSelector:updateBindingSelector]) { 873| 0| [classFBUnityUtility performSelector:updateBindingSelector withObject:jsonString]; 874| 0| } 875| 0| } 876| 0|} 877| | 878| |#pragma clang diagnostic pop 879| | 880| |#pragma mark - Internal Methods 881| | 882| |- (void) configureWithGateKeeperManager:(Class)gateKeeperManager 883| | appEventsConfigurationProvider:(Class)appEventsConfigurationProvider 884| | serverConfigurationProvider:(Class)serverConfigurationProvider 885| | graphRequestProvider:(id)provider 886| | featureChecker:(id)featureChecker 887| | store:(id)store 888| | logger:(Class)logger 889| | settings:(id)settings 890| | paymentObserver:(id)paymentObserver 891| | timeSpentRecorderFactory:(id)timeSpentRecorderFactory 892| | appEventsStateStore:(id)appEventsStateStore 893| | eventDeactivationParameterProcessor:(id)eventDeactivationParameterProcessor 894| | restrictiveDataFilterParameterProcessor:(id)restrictiveDataFilterParameterProcessor 895| | atePublisherFactory:(id)atePublisherFactory 896| | appEventsStateProvider:(id)appEventsStateProvider 897| | swizzler:(Class)swizzler 898| 0|{ 899| 0| [FBSDKAppEvents setAppEventsConfigurationProvider:appEventsConfigurationProvider]; 900| 0| [FBSDKAppEvents setServerConfigurationProvider:serverConfigurationProvider]; 901| 0| g_gateKeeperManager = gateKeeperManager; 902| 0| g_logger = logger; 903| 0| [FBSDKAppEvents setRequestProvider:provider]; 904| 0| [FBSDKAppEvents setFeatureChecker:featureChecker]; 905| 0| g_settings = settings; 906| 0| g_paymentObserver = paymentObserver; 907| 0| g_appEventsStateStore = appEventsStateStore; 908| 0| g_eventDeactivationParameterProcessor = eventDeactivationParameterProcessor; 909| 0| g_restrictiveDataFilterParameterProcessor = restrictiveDataFilterParameterProcessor; 910| 0| self.swizzler = swizzler; 911| 0| self.store = store; 912| 0| self.atePublisher = [atePublisherFactory createPublisherWithAppID:self.appID]; 913| 0| self.timeSpentRecorder = [timeSpentRecorderFactory createTimeSpentRecorder]; 914| 0| self.appEventsStateProvider = appEventsStateProvider; 915| | 916| 0| self.isConfigured = YES; 917| | 918| 0| self.userID = [store stringForKey:USER_ID_USER_DEFAULTS_KEY]; 919| 0|} 920| | 921| |+ (void)setFeatureChecker:(id)checker 922| 0|{ 923| 0| if (g_featureChecker != checker) { 924| 0| g_featureChecker = checker; 925| 0| } 926| 0|} 927| | 928| |+ (void)setRequestProvider:(id)provider 929| 0|{ 930| 0| if (g_graphRequestProvider != provider) { 931| 0| g_graphRequestProvider = provider; 932| 0| } 933| 0|} 934| | 935| |+ (void)setAppEventsConfigurationProvider:(Class)provider 936| 0|{ 937| 0| if (g_appEventsConfigurationProvider != provider) { 938| 0| g_appEventsConfigurationProvider = provider; 939| 0| } 940| 0|} 941| | 942| |+ (void)setServerConfigurationProvider:(Class)provider 943| 0|{ 944| 0| if (g_serverConfigurationProvider != provider) { 945| 0| g_serverConfigurationProvider = provider; 946| 0| } 947| 0|} 948| | 949| |#if !TARGET_OS_TV 950| | 951| |+ (void)configureNonTVComponentsWithOnDeviceMLModelManager:(id)modelManager 952| | metadataIndexer:(id)metadataIndexer 953| 0|{ 954| 0| g_onDeviceMLModelManager = modelManager; 955| 0| g_metadataIndexer = metadataIndexer; 956| 0|} 957| | 958| |#endif 959| | 960| |+ (void)logInternalEvent:(FBSDKAppEventName)eventName 961| | isImplicitlyLogged:(BOOL)isImplicitlyLogged 962| 0|{ 963| 0| [self.singleton logInternalEvent:eventName 964| 0| isImplicitlyLogged:isImplicitlyLogged]; 965| 0|} 966| | 967| |- (void)logInternalEvent:(FBSDKAppEventName)eventName 968| | isImplicitlyLogged:(BOOL)isImplicitlyLogged 969| 0|{ 970| 0| [self logInternalEvent:eventName 971| 0| parameters:@{} 972| 0| isImplicitlyLogged:isImplicitlyLogged]; 973| 0|} 974| | 975| |+ (void)logInternalEvent:(FBSDKAppEventName)eventName 976| | valueToSum:(double)valueToSum 977| | isImplicitlyLogged:(BOOL)isImplicitlyLogged 978| 0|{ 979| 0| [self.singleton logInternalEvent:eventName 980| 0| valueToSum:valueToSum 981| 0| isImplicitlyLogged:isImplicitlyLogged]; 982| 0|} 983| | 984| |- (void)logInternalEvent:(FBSDKAppEventName)eventName 985| | valueToSum:(double)valueToSum 986| | isImplicitlyLogged:(BOOL)isImplicitlyLogged 987| 0|{ 988| 0| [self logInternalEvent:eventName 989| 0| valueToSum:valueToSum 990| 0| parameters:@{} 991| 0| isImplicitlyLogged:isImplicitlyLogged]; 992| 0|} 993| | 994| |+ (void)logInternalEvent:(FBSDKAppEventName)eventName 995| | parameters:(NSDictionary *)parameters 996| | isImplicitlyLogged:(BOOL)isImplicitlyLogged 997| 0|{ 998| 0| [self.singleton logInternalEvent:eventName 999| 0| parameters:parameters 1000| 0| isImplicitlyLogged:isImplicitlyLogged]; 1001| 0|} 1002| | 1003| |- (void)logInternalEvent:(FBSDKAppEventName)eventName 1004| | parameters:(NSDictionary *)parameters 1005| | isImplicitlyLogged:(BOOL)isImplicitlyLogged 1006| 0|{ 1007| 0| [self logInternalEvent:eventName 1008| 0| valueToSum:nil 1009| 0| parameters:parameters 1010| 0| isImplicitlyLogged:isImplicitlyLogged 1011| 0| accessToken:nil]; 1012| 0|} 1013| | 1014| |+ (void)logInternalEvent:(FBSDKAppEventName)eventName 1015| | parameters:(NSDictionary *)parameters 1016| | isImplicitlyLogged:(BOOL)isImplicitlyLogged 1017| | accessToken:(FBSDKAccessToken *)accessToken 1018| 0|{ 1019| 0| [self.singleton logInternalEvent:eventName 1020| 0| parameters:parameters 1021| 0| isImplicitlyLogged:isImplicitlyLogged 1022| 0| accessToken:accessToken]; 1023| 0|} 1024| | 1025| |- (void)logInternalEvent:(FBSDKAppEventName)eventName 1026| | parameters:(NSDictionary *)parameters 1027| | isImplicitlyLogged:(BOOL)isImplicitlyLogged 1028| | accessToken:(FBSDKAccessToken *)accessToken 1029| 0|{ 1030| 0| [self logInternalEvent:eventName 1031| 0| valueToSum:nil 1032| 0| parameters:parameters 1033| 0| isImplicitlyLogged:isImplicitlyLogged 1034| 0| accessToken:accessToken]; 1035| 0|} 1036| | 1037| |+ (void)logInternalEvent:(FBSDKAppEventName)eventName 1038| | valueToSum:(double)valueToSum 1039| | parameters:(NSDictionary *)parameters 1040| | isImplicitlyLogged:(BOOL)isImplicitlyLogged 1041| 0|{ 1042| 0| [self.singleton logInternalEvent:eventName 1043| 0| valueToSum:valueToSum 1044| 0| parameters:parameters 1045| 0| isImplicitlyLogged:isImplicitlyLogged]; 1046| 0|} 1047| | 1048| |- (void)logInternalEvent:(FBSDKAppEventName)eventName 1049| | valueToSum:(double)valueToSum 1050| | parameters:(NSDictionary *)parameters 1051| | isImplicitlyLogged:(BOOL)isImplicitlyLogged 1052| 0|{ 1053| 0| [self logInternalEvent:eventName 1054| 0| valueToSum:@(valueToSum) 1055| 0| parameters:parameters 1056| 0| isImplicitlyLogged:isImplicitlyLogged 1057| 0| accessToken:nil]; 1058| 0|} 1059| | 1060| |+ (void)logInternalEvent:(NSString *)eventName 1061| | valueToSum:(NSNumber *)valueToSum 1062| | parameters:(NSDictionary *)parameters 1063| | isImplicitlyLogged:(BOOL)isImplicitlyLogged 1064| | accessToken:(FBSDKAccessToken *)accessToken 1065| 0|{ 1066| 0| [self.singleton logInternalEvent:eventName 1067| 0| valueToSum:valueToSum 1068| 0| parameters:parameters 1069| 0| isImplicitlyLogged:isImplicitlyLogged 1070| 0| accessToken:accessToken]; 1071| 0|} 1072| | 1073| |- (void)logInternalEvent:(NSString *)eventName 1074| | valueToSum:(NSNumber *)valueToSum 1075| | parameters:(NSDictionary *)parameters 1076| | isImplicitlyLogged:(BOOL)isImplicitlyLogged 1077| | accessToken:(FBSDKAccessToken *)accessToken 1078| 0|{ 1079| 0| if ([g_settings isAutoLogAppEventsEnabled]) { 1080| 0| [self instanceLogEvent:eventName 1081| 0| valueToSum:valueToSum 1082| 0| parameters:parameters 1083| 0| isImplicitlyLogged:isImplicitlyLogged 1084| 0| accessToken:accessToken]; 1085| 0| } 1086| 0|} 1087| | 1088| |+ (void)logImplicitEvent:(NSString *)eventName 1089| | valueToSum:(NSNumber *)valueToSum 1090| | parameters:(NSDictionary *)parameters 1091| | accessToken:(FBSDKAccessToken *)accessToken 1092| 0|{ 1093| 0| [self.singleton instanceLogEvent:eventName 1094| 0| valueToSum:valueToSum 1095| 0| parameters:parameters 1096| 0| isImplicitlyLogged:YES 1097| 0| accessToken:accessToken]; 1098| 0|} 1099| | 1100| |- (void)logImplicitEvent:(NSString *)eventName 1101| | valueToSum:(NSNumber *)valueToSum 1102| | parameters:(NSDictionary *)parameters 1103| | accessToken:(FBSDKAccessToken *)accessToken 1104| 0|{ 1105| 0| [self instanceLogEvent:eventName 1106| 0| valueToSum:valueToSum 1107| 0| parameters:parameters 1108| 0| isImplicitlyLogged:YES 1109| 0| accessToken:accessToken]; 1110| 0|} 1111| | 1112| |+ (FBSDKAppEvents *)singleton 1113| 0|{ 1114| 0| static dispatch_once_t onceToken; 1115| 0| static FBSDKAppEvents *shared = nil; 1116| 0| dispatch_once(&onceToken, ^{ 1117| 0| shared = [self new]; 1118| 0| }); 1119| 0| return shared; 1120| 0|} 1121| | 1122| |- (void)flushForReason:(FBSDKAppEventsFlushReason)flushReason 1123| 0|{ 1124| | // Always flush asynchronously, even on main thread, for two reasons: 1125| | // - most consistent code path for all threads. 1126| | // - allow locks being held by caller to be released prior to actual flushing work being done. 1127| 0| @synchronized(self) { 1128| 0| if (!_appEventsState) { 1129| 0| return; 1130| 0| } 1131| 0| FBSDKAppEventsState *copy = [_appEventsState copy]; 1132| 0| _appEventsState = [self.appEventsStateProvider createStateWithToken:copy.tokenString 1133| 0| appID:copy.appID]; 1134| 0| dispatch_async(dispatch_get_main_queue(), ^{ 1135| 0| [self flushOnMainQueue:copy forReason:flushReason]; 1136| 0| }); 1137| 0| } 1138| 0|} 1139| | 1140| |#pragma mark - Source Application Tracking 1141| | 1142| |- (void)setSourceApplication:(NSString *)sourceApplication openURL:(NSURL *)url 1143| 0|{ 1144| 0| [self.timeSpentRecorder setSourceApplication:sourceApplication openURL:url]; 1145| 0|} 1146| | 1147| |- (void)setSourceApplication:(NSString *)sourceApplication isFromAppLink:(BOOL)isFromAppLink 1148| 0|{ 1149| 0| [self.timeSpentRecorder setSourceApplication:sourceApplication isFromAppLink:isFromAppLink]; 1150| 0|} 1151| | 1152| |- (void)registerAutoResetSourceApplication 1153| 0|{ 1154| 0| [self.timeSpentRecorder registerAutoResetSourceApplication]; 1155| 0|} 1156| | 1157| |#pragma mark - Private Methods 1158| |- (NSString *)appID 1159| 0|{ 1160| 0| return [FBSDKAppEvents loggingOverrideAppID] ?: [g_settings appID]; 1161| 0|} 1162| | 1163| |- (void)publishInstall 1164| 0|{ 1165| 0| NSString *appID = [self appID]; 1166| 0| if (appID.length == 0) { 1167| 0| [g_logger singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors logEntry:@"Missing [FBSDKAppEvents appID] for [FBSDKAppEvents publishInstall:]"]; 1168| 0| return; 1169| 0| } 1170| 0| NSString *lastAttributionPingString = [NSString stringWithFormat:@"com.facebook.sdk:lastAttributionPing%@", appID]; 1171| 0| if ([self.store objectForKey:lastAttributionPingString]) { 1172| 0| return; 1173| 0| } 1174| 0| [self fetchServerConfiguration:^{ 1175| 0| if ([FBSDKAppEventsUtility shouldDropAppEvent]) { 1176| 0| return; 1177| 0| } 1178| 0| NSMutableDictionary *params = [FBSDKAppEventsUtility activityParametersDictionaryForEvent:@"MOBILE_APP_INSTALL" 1179| 0| shouldAccessAdvertisingID:self->_serverConfiguration.isAdvertisingIDEnabled]; 1180| 0| [self appendInstallTimestamp:params]; 1181| 0| NSString *path = [NSString stringWithFormat:@"%@/activities", appID]; 1182| 0| id request = [g_graphRequestProvider createGraphRequestWithGraphPath:path 1183| 0| parameters:params 1184| 0| tokenString:nil 1185| 0| HTTPMethod:FBSDKHTTPMethodPOST 1186| 0| flags:FBSDKGraphRequestFlagDoNotInvalidateTokenOnError | FBSDKGraphRequestFlagDisableErrorRecovery]; 1187| 0| __block id weakStore = self.store; 1188| 0| [request startWithCompletion:^(id connection, id result, NSError *error) { 1189| 0| if (!error) { 1190| 0| [weakStore setObject:[NSDate date] forKey:lastAttributionPingString]; 1191| 0| NSString *lastInstallResponseKey = [NSString stringWithFormat:@"com.facebook.sdk:lastInstallResponse%@", appID]; 1192| 0| [weakStore setObject:result forKey:lastInstallResponseKey]; 1193| 0| } 1194| 0| }]; 1195| 0| }]; 1196| 0|} 1197| | 1198| |- (void)publishATE 1199| 0|{ 1200| 0| if (self.appID.length == 0) { 1201| 0| return; 1202| 0| } 1203| | 1204| 0|#if FBSDKTEST 1205| 0| [self.atePublisher publishATE]; 1206| |#else 1207| | __weak FBSDKAppEvents *weakSelf = self; 1208| | fb_dispatch_on_default_thread(^(void) { 1209| | [weakSelf.atePublisher publishATE]; 1210| | }); 1211| |#endif 1212| 0|} 1213| | 1214| |- (void)appendInstallTimestamp:(NSMutableDictionary *)parameters 1215| 0|{ 1216| 0| if (@available(iOS 14.0, *)) { 1217| 0| if ([g_settings isSetATETimeExceedsInstallTime]) { 1218| 0| NSDate *setAteTimestamp = g_settings.advertiserTrackingEnabledTimestamp; 1219| 0| [FBSDKTypeUtility dictionary:parameters setObject:@([FBSDKAppEventsUtility convertToUnixTime:setAteTimestamp]) forKey:@"install_timestamp"]; 1220| 0| } else { 1221| 0| NSDate *installTimestamp = g_settings.installTimestamp; 1222| 0| [FBSDKTypeUtility dictionary:parameters setObject:@([FBSDKAppEventsUtility convertToUnixTime:installTimestamp]) forKey:@"install_timestamp"]; 1223| 0| } 1224| 0| } 1225| 0|} 1226| | 1227| |#if !TARGET_OS_TV 1228| |- (void)enableCodelessEvents 1229| 0|{ 1230| 0| if (_serverConfiguration.isCodelessEventsEnabled) { 1231| 0| [FBSDKCodelessIndexer enable]; 1232| | 1233| 0| if (!_eventBindingManager) { 1234| 0| _eventBindingManager = [FBSDKEventBindingManager new]; 1235| 0| } 1236| | 1237| 0| if ([FBSDKInternalUtility isUnity]) { 1238| 0| [FBSDKAppEvents sendEventBindingsToUnity]; 1239| 0| } else { 1240| 0| FBSDKEventBindingManager *manager = [[FBSDKEventBindingManager alloc] initWithSwizzler:self.swizzler 1241| 0| eventLogger:self]; 1242| 0| [_eventBindingManager updateBindings:[manager parseArray:_serverConfiguration.eventBindings]]; 1243| 0| } 1244| 0| } 1245| 0|} 1246| | 1247| |#endif 1248| | 1249| |// app events can use a server configuration up to 24 hours old to minimize network traffic. 1250| |- (void)fetchServerConfiguration:(FBSDKCodeBlock)callback 1251| 0|{ 1252| 0| [g_appEventsConfigurationProvider loadAppEventsConfigurationWithBlock:^{ 1253| 0| [g_serverConfigurationProvider loadServerConfigurationWithCompletionBlock:^(FBSDKServerConfiguration *serverConfiguration, NSError *error) { 1254| 0| self->_serverConfiguration = serverConfiguration; 1255| | 1256| 0| if ([g_settings isAutoLogAppEventsEnabled] && self->_serverConfiguration.implicitPurchaseLoggingEnabled) { 1257| 0| [g_paymentObserver startObservingTransactions]; 1258| 0| } else { 1259| 0| [g_paymentObserver stopObservingTransactions]; 1260| 0| } 1261| 0| [g_featureChecker checkFeature:FBSDKFeatureRestrictiveDataFiltering completionBlock:^(BOOL enabled) { 1262| 0| if (enabled) { 1263| 0| [g_restrictiveDataFilterParameterProcessor enable]; 1264| 0| } 1265| 0| }]; 1266| 0| [g_featureChecker checkFeature:FBSDKFeatureEventDeactivation completionBlock:^(BOOL enabled) { 1267| 0| if (enabled) { 1268| 0| [g_eventDeactivationParameterProcessor enable]; 1269| 0| } 1270| 0| }]; 1271| 0| if (@available(iOS 14.0, *)) { 1272| 0| __weak FBSDKAppEvents *weakSelf = self; 1273| 0| [g_featureChecker checkFeature:FBSDKFeatureATELogging completionBlock:^(BOOL enabled) { 1274| 0| if (enabled) { 1275| 0| [weakSelf publishATE]; 1276| 0| } 1277| 0| }]; 1278| 0| } 1279| 0| #if !TARGET_OS_TV 1280| 0| [g_featureChecker checkFeature:FBSDKFeatureCodelessEvents completionBlock:^(BOOL enabled) { 1281| 0| if (enabled) { 1282| 0| [self enableCodelessEvents]; 1283| 0| } 1284| 0| }]; 1285| 0| [g_featureChecker checkFeature:FBSDKFeatureAAM completionBlock:^(BOOL enabled) { 1286| 0| if (enabled) { 1287| 0| [g_metadataIndexer enable]; 1288| 0| } 1289| 0| }]; 1290| 0| [g_featureChecker checkFeature:FBSDKFeaturePrivacyProtection completionBlock:^(BOOL enabled) { 1291| 0| if (enabled) { 1292| 0| [g_onDeviceMLModelManager enable]; 1293| 0| } 1294| 0| }]; 1295| 0| if (@available(iOS 11.3, *)) { 1296| 0| if ([g_settings isSKAdNetworkReportEnabled]) { 1297| 0| [g_featureChecker checkFeature:FBSDKFeatureSKAdNetwork completionBlock:^(BOOL SKAdNetworkEnabled) { 1298| 0| if (SKAdNetworkEnabled) { 1299| 0| [SKAdNetwork registerAppForAdNetworkAttribution]; 1300| 0| [g_featureChecker checkFeature:FBSDKFeatureSKAdNetworkConversionValue completionBlock:^(BOOL SKAdNetworkConversionValueEnabled) { 1301| 0| if (SKAdNetworkConversionValueEnabled) { 1302| 0| [FBSDKSKAdNetworkReporter enable]; 1303| 0| } 1304| 0| }]; 1305| 0| } 1306| 0| }]; 1307| 0| } 1308| 0| } 1309| 0| if (@available(iOS 14.0, *)) { 1310| 0| [g_featureChecker checkFeature:FBSDKFeatureAEM completionBlock:^(BOOL AEMEnabled) { 1311| 0| if (AEMEnabled) { 1312| 0| [FBSDKAEMReporter enable]; 1313| 0| } 1314| 0| }]; 1315| 0| } 1316| 0| #endif 1317| 0| if (callback) { 1318| 0| callback(); 1319| 0| } 1320| 0| }]; 1321| 0| }]; 1322| 0|} 1323| | 1324| |#pragma clang diagnostic push 1325| |#pragma clang diagnostic ignored "-Wdeprecated-declarations" 1326| |- (void)instanceLogEvent:(FBSDKAppEventName)eventName 1327| | valueToSum:(NSNumber *)valueToSum 1328| | parameters:(NSDictionary *)parameters 1329| | isImplicitlyLogged:(BOOL)isImplicitlyLogged 1330| | accessToken:(FBSDKAccessToken *)accessToken 1331| 0|{ 1332| 0| [self validateConfiguration]; 1333| | 1334| | // Kill events if kill-switch is enabled 1335| 0| if (!g_gateKeeperManager) { 1336| 0| [g_logger singleShotLogEntry:FBSDKLoggingBehaviorAppEvents 1337| 0| logEntry:@"FBSDKAppEvents: Cannot log app events before the SDK is initialized."]; 1338| 0| return; 1339| 0| } else if ([g_gateKeeperManager boolForKey:FBSDKGateKeeperAppEventsKillSwitch 1340| 0| defaultValue:NO]) { 1341| 0| NSString *message = [NSString stringWithFormat:@"FBSDKAppEvents: KillSwitch is enabled and fail to log app event: %@", eventName]; 1342| 0| [g_logger singleShotLogEntry:FBSDKLoggingBehaviorAppEvents 1343| 0| logEntry:message]; 1344| 0| return; 1345| 0| } 1346| 0|#if !TARGET_OS_TV 1347| | // Update conversion value for SKAdNetwork if needed 1348| 0| [FBSDKSKAdNetworkReporter recordAndUpdateEvent:eventName currency:[FBSDKTypeUtility dictionary:parameters objectForKey:FBSDKAppEventParameterNameCurrency ofType:NSString.class] value:valueToSum]; 1349| | // Update conversion value for AEM if needed 1350| 0| [FBSDKAEMReporter recordAndUpdateEvent:eventName 1351| 0| currency:[FBSDKTypeUtility dictionary:parameters objectForKey:FBSDKAppEventParameterNameCurrency ofType:NSString.class] 1352| 0| value:valueToSum 1353| 0| parameters:parameters]; 1354| 0|#endif 1355| | 1356| 0| if ([FBSDKAppEventsUtility shouldDropAppEvent]) { 1357| 0| return; 1358| 0| } 1359| | 1360| 0| if (isImplicitlyLogged && _serverConfiguration && !_serverConfiguration.isImplicitLoggingSupported) { 1361| 0| return; 1362| 0| } 1363| | 1364| 0| if (!isImplicitlyLogged && !g_explicitEventsLoggedYet) { 1365| 0| g_explicitEventsLoggedYet = YES; 1366| 0| } 1367| 0| __block BOOL failed = ![FBSDKAppEventsUtility validateIdentifier:eventName]; 1368| | 1369| | // Make sure parameter dictionary is well formed. Log and exit if not. 1370| 0| [FBSDKTypeUtility dictionary:parameters enumerateKeysAndObjectsUsingBlock:^(id key, id obj, BOOL *stop) { 1371| 0| if (![key isKindOfClass:[NSString class]]) { 1372| 0| [FBSDKAppEventsUtility logAndNotify:[NSString stringWithFormat:@"The keys in the parameters must be NSStrings, '%@' is not.", key]]; 1373| 0| failed = YES; 1374| 0| } 1375| 0| if (![FBSDKAppEventsUtility validateIdentifier:key]) { 1376| 0| failed = YES; 1377| 0| } 1378| 0| if (![obj isKindOfClass:[NSString class]] && ![obj isKindOfClass:[NSNumber class]]) { 1379| 0| [FBSDKAppEventsUtility logAndNotify:[NSString stringWithFormat:@"The values in the parameters dictionary must be NSStrings or NSNumbers, '%@' is not.", obj]]; 1380| 0| failed = YES; 1381| 0| } 1382| 0| }]; 1383| | 1384| 0| if (failed) { 1385| 0| return; 1386| 0| } 1387| | // Filter out deactivated params 1388| 0| parameters = [g_eventDeactivationParameterProcessor processParameters:parameters eventName:eventName]; 1389| | 1390| 0|#if !TARGET_OS_TV 1391| | // Filter out restrictive data with on-device ML 1392| 0| if (g_onDeviceMLModelManager.integrityParametersProcessor) { 1393| 0| parameters = [g_onDeviceMLModelManager.integrityParametersProcessor processParameters:parameters eventName:eventName]; 1394| 0| } 1395| 0|#endif 1396| | // Filter out restrictive keys 1397| 0| parameters = [g_restrictiveDataFilterParameterProcessor processParameters:parameters 1398| 0| eventName:eventName]; 1399| | 1400| 0| NSMutableDictionary *eventDictionary = [NSMutableDictionary dictionaryWithDictionary:parameters]; 1401| 0| [FBSDKTypeUtility dictionary:eventDictionary setObject:eventName forKey:FBSDKAppEventParameterEventName]; 1402| 0| if (!eventDictionary[FBSDKAppEventParameterLogTime]) { 1403| 0| [FBSDKTypeUtility dictionary:eventDictionary setObject:@([FBSDKAppEventsUtility unixTimeNow]) forKey:FBSDKAppEventParameterLogTime]; 1404| 0| } 1405| 0| [FBSDKTypeUtility dictionary:eventDictionary setObject:valueToSum forKey:@"_valueToSum"]; 1406| 0| if (isImplicitlyLogged) { 1407| 0| [FBSDKTypeUtility dictionary:eventDictionary setObject:@"1" forKey:FBSDKAppEventParameterImplicitlyLogged]; 1408| 0| } 1409| | 1410| 0| NSString *currentViewControllerName; 1411| 0| UIApplicationState applicationState; 1412| 0| if ([NSThread isMainThread]) { 1413| | // We only collect the view controller when on the main thread, as the behavior off 1414| | // the main thread is unpredictable. Besides, UI state for off-main-thread computations 1415| | // isn't really relevant anyhow. 1416| 0| UIViewController *vc = [UIApplication sharedApplication].keyWindow.rootViewController; 1417| 0| vc = vc.presentedViewController ?: vc; 1418| 0| if (vc) { 1419| 0| currentViewControllerName = [[vc class] description]; 1420| 0| } else { 1421| 0| currentViewControllerName = @"no_ui"; 1422| 0| } 1423| 0| applicationState = [UIApplication sharedApplication].applicationState; 1424| 0| } else { 1425| 0| currentViewControllerName = @"off_thread"; 1426| 0| applicationState = self.applicationState; 1427| 0| } 1428| 0| [FBSDKTypeUtility dictionary:eventDictionary setObject:currentViewControllerName forKey:@"_ui"]; 1429| | 1430| 0| if (applicationState == UIApplicationStateBackground) { 1431| 0| [FBSDKTypeUtility dictionary:eventDictionary setObject:@"1" forKey:FBSDKAppEventParameterInBackground]; 1432| 0| } 1433| | 1434| 0| NSString *tokenString = [FBSDKAppEventsUtility tokenStringToUseFor:accessToken]; 1435| 0| NSString *appID = [self appID]; 1436| | 1437| 0| @synchronized(self) { 1438| 0| if (!_appEventsState) { 1439| 0| _appEventsState = [self.appEventsStateProvider createStateWithToken:tokenString appID:appID]; 1440| 0| } else if (![_appEventsState isCompatibleWithTokenString:tokenString appID:appID]) { 1441| 0| if (self.flushBehavior == FBSDKAppEventsFlushBehaviorExplicitOnly) { 1442| 0| [g_appEventsStateStore persistAppEventsData:_appEventsState]; 1443| 0| } else { 1444| 0| [self flushForReason:FBSDKAppEventsFlushReasonSessionChange]; 1445| 0| } 1446| 0| _appEventsState = [self.appEventsStateProvider createStateWithToken:tokenString appID:appID]; 1447| 0| } 1448| | 1449| 0| [_appEventsState addEvent:eventDictionary isImplicit:isImplicitlyLogged]; 1450| 0| if (!isImplicitlyLogged) { 1451| 0| NSString *message = [NSString stringWithFormat:@"FBSDKAppEvents: Recording event @ %f: %@", 1452| 0| [FBSDKAppEventsUtility unixTimeNow], 1453| 0| eventDictionary]; 1454| 0| [g_logger singleShotLogEntry:FBSDKLoggingBehaviorAppEvents 1455| 0| logEntry:message]; 1456| 0| } 1457| | 1458| 0| [self checkPersistedEvents]; 1459| | 1460| 0| if (_appEventsState.events.count > NUM_LOG_EVENTS_TO_TRY_TO_FLUSH_AFTER 1461| 0| && self.flushBehavior != FBSDKAppEventsFlushBehaviorExplicitOnly) { 1462| 0| [self flushForReason:FBSDKAppEventsFlushReasonEventThreshold]; 1463| 0| } 1464| 0| } 1465| 0|} 1466| | 1467| |#pragma clang diagnostic pop 1468| | 1469| |// this fetches persisted event states. 1470| |// for those matching the currently tracked events, add it. 1471| |// otherwise, either flush (if not explicitonly behavior) or persist them back. 1472| |- (void)checkPersistedEvents 1473| 0|{ 1474| 0| NSArray *existingEventsStates = [g_appEventsStateStore retrievePersistedAppEventsStates]; 1475| 0| if (existingEventsStates.count == 0) { 1476| 0| return; 1477| 0| } 1478| 0| FBSDKAppEventsState *matchingEventsPreviouslySaved = nil; 1479| | // reduce lock time by creating a new FBSDKAppEventsState to collect matching persisted events. 1480| 0| @synchronized(self) { 1481| 0| if (_appEventsState) { 1482| 0| matchingEventsPreviouslySaved = [self.appEventsStateProvider createStateWithToken:_appEventsState.tokenString 1483| 0| appID:_appEventsState.appID]; 1484| 0| } 1485| 0| } 1486| 0| for (FBSDKAppEventsState *saved in existingEventsStates) { 1487| 0| if ([saved isCompatibleWithAppEventsState:matchingEventsPreviouslySaved]) { 1488| 0| [matchingEventsPreviouslySaved addEventsFromAppEventState:saved]; 1489| 0| } else { 1490| 0| if (self.flushBehavior == FBSDKAppEventsFlushBehaviorExplicitOnly) { 1491| 0| [g_appEventsStateStore persistAppEventsData:saved]; 1492| 0| } else { 1493| 0| dispatch_async(dispatch_get_main_queue(), ^{ 1494| 0| [self flushOnMainQueue:saved forReason:FBSDKAppEventsFlushReasonPersistedEvents]; 1495| 0| }); 1496| 0| } 1497| 0| } 1498| 0| } 1499| 0| if (matchingEventsPreviouslySaved.events.count > 0) { 1500| 0| @synchronized(self) { 1501| 0| if ([_appEventsState isCompatibleWithAppEventsState:matchingEventsPreviouslySaved]) { 1502| 0| [_appEventsState addEventsFromAppEventState:matchingEventsPreviouslySaved]; 1503| 0| } 1504| 0| } 1505| 0| } 1506| 0|} 1507| | 1508| |- (void)flushOnMainQueue:(FBSDKAppEventsState *)appEventsState 1509| | forReason:(FBSDKAppEventsFlushReason)reason 1510| 0|{ 1511| 0| if (appEventsState.events.count == 0) { 1512| 0| return; 1513| 0| } 1514| | 1515| 0| if (appEventsState.appID.length == 0) { 1516| 0| [g_logger singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors logEntry:@"Missing [FBSDKAppEvents appEventsState.appID] for [FBSDKAppEvents flushOnMainQueue:]"]; 1517| 0| return; 1518| 0| } 1519| | 1520| 0| [FBSDKAppEventsUtility ensureOnMainThread:NSStringFromSelector(_cmd) className:NSStringFromClass([self class])]; 1521| | 1522| 0| [self fetchServerConfiguration:^(void) { 1523| 0| if ([FBSDKAppEventsUtility shouldDropAppEvent]) { 1524| 0| return; 1525| 0| } 1526| 0| NSString *receipt_data = appEventsState.extractReceiptData; 1527| 0| const BOOL shouldIncludeImplicitEvents = (self->_serverConfiguration.implicitLoggingEnabled && g_settings.isAutoLogAppEventsEnabled); 1528| 0| NSString *encodedEvents = [appEventsState JSONStringForEventsIncludingImplicitEvents:shouldIncludeImplicitEvents]; 1529| 0| if (!encodedEvents || appEventsState.events.count == 0) { 1530| 0| [g_logger singleShotLogEntry:FBSDKLoggingBehaviorAppEvents 1531| 0| logEntry:@"FBSDKAppEvents: Flushing skipped - no events after removing implicitly logged ones.\n"]; 1532| 0| return; 1533| 0| } 1534| 0| NSMutableDictionary *postParameters = [FBSDKAppEventsUtility 1535| 0| activityParametersDictionaryForEvent:@"CUSTOM_APP_EVENTS" 1536| 0| shouldAccessAdvertisingID:self->_serverConfiguration.advertisingIDEnabled]; 1537| 0| NSInteger length = receipt_data.length; 1538| 0| if (length > 0) { 1539| 0| [FBSDKTypeUtility dictionary:postParameters setObject:receipt_data forKey:@"receipt_data"]; 1540| 0| } 1541| | 1542| 0| [FBSDKTypeUtility dictionary:postParameters setObject:encodedEvents forKey:@"custom_events"]; 1543| 0| if (appEventsState.numSkipped > 0) { 1544| 0| [FBSDKTypeUtility dictionary:postParameters setObject:[NSString stringWithFormat:@"%lu", (unsigned long)appEventsState.numSkipped] forKey:@"num_skipped_events"]; 1545| 0| } 1546| 0| if (self.pushNotificationsDeviceTokenString) { 1547| 0| [FBSDKTypeUtility dictionary:postParameters setObject:self.pushNotificationsDeviceTokenString forKey:FBSDKActivitesParameterPushDeviceToken]; 1548| 0| } 1549| | 1550| 0| NSString *loggingEntry = nil; 1551| 0| if ([g_settings.loggingBehaviors containsObject:FBSDKLoggingBehaviorAppEvents]) { 1552| 0| NSData *prettyJSONData = [FBSDKTypeUtility dataWithJSONObject:appEventsState.events 1553| 0| options:NSJSONWritingPrettyPrinted 1554| 0| error:NULL]; 1555| 0| NSString *prettyPrintedJsonEvents = [[NSString alloc] initWithData:prettyJSONData 1556| 0| encoding:NSUTF8StringEncoding]; 1557| | // Remove this param -- just an encoding of the events which we pretty print later. 1558| 0| NSMutableDictionary *paramsForPrinting = [postParameters mutableCopy]; 1559| 0| [paramsForPrinting removeObjectForKey:@"custom_events_file"]; 1560| | 1561| 0| loggingEntry = [NSString stringWithFormat:@"FBSDKAppEvents: Flushed @ %f, %lu events due to '%@' - %@\nEvents: %@", 1562| 0| [FBSDKAppEventsUtility unixTimeNow], 1563| 0| (unsigned long)appEventsState.events.count, 1564| 0| [FBSDKAppEventsUtility flushReasonToString:reason], 1565| 0| paramsForPrinting, 1566| 0| prettyPrintedJsonEvents]; 1567| 0| } 1568| 0| id request = [g_graphRequestProvider createGraphRequestWithGraphPath:[NSString stringWithFormat:@"%@/activities", appEventsState.appID] 1569| 0| parameters:postParameters 1570| 0| tokenString:appEventsState.tokenString 1571| 0| HTTPMethod:FBSDKHTTPMethodPOST 1572| 0| flags:FBSDKGraphRequestFlagDoNotInvalidateTokenOnError | FBSDKGraphRequestFlagDisableErrorRecovery]; 1573| 0| [request startWithCompletion:^(id connection, id result, NSError *error) { 1574| 0| [self handleActivitiesPostCompletion:error 1575| 0| loggingEntry:loggingEntry 1576| 0| appEventsState:(FBSDKAppEventsState *)appEventsState]; 1577| 0| }]; 1578| 0| }]; 1579| 0|} 1580| | 1581| |- (void)handleActivitiesPostCompletion:(NSError *)error 1582| | loggingEntry:(NSString *)loggingEntry 1583| | appEventsState:(FBSDKAppEventsState *)appEventsState 1584| 0|{ 1585| 0| typedef NS_ENUM(NSUInteger, FBSDKAppEventsFlushResult) { 1586| 0| FlushResultSuccess, 1587| 0| FlushResultServerError, 1588| 0| FlushResultNoConnectivity, 1589| 0| }; 1590| | 1591| 0| [FBSDKAppEventsUtility ensureOnMainThread:NSStringFromSelector(_cmd) className:NSStringFromClass([self class])]; 1592| | 1593| 0| FBSDKAppEventsFlushResult flushResult = FlushResultSuccess; 1594| 0| if (error) { 1595| 0| NSInteger errorCode = [error.userInfo[FBSDKGraphRequestErrorHTTPStatusCodeKey] integerValue]; 1596| | 1597| | // We interpret a 400 coming back from FBRequestConnection as a server error due to improper data being 1598| | // sent down. Otherwise we assume no connectivity, or another condition where we could treat it as no connectivity. 1599| | // Adding 404 as having wrong/missing appID results in 404 and that is not a connectivity issue 1600| 0| flushResult = (errorCode == 400 || errorCode == 404) ? FlushResultServerError : FlushResultNoConnectivity; 1601| 0| } 1602| | 1603| 0| if (flushResult == FlushResultServerError) { 1604| | // Only log events that developer can do something with (i.e., if parameters are incorrect). 1605| | // as opposed to cases where the token is bad. 1606| 0| if ([error.userInfo[FBSDKGraphRequestErrorKey] unsignedIntegerValue] == FBSDKGraphRequestErrorOther) { 1607| 0| NSString *message = [NSString stringWithFormat:@"Failed to send AppEvents: %@", error]; 1608| 0| [FBSDKAppEventsUtility logAndNotify:message allowLogAsDeveloperError:!appEventsState.areAllEventsImplicit]; 1609| 0| } 1610| 0| } else if (flushResult == FlushResultNoConnectivity) { 1611| 0| @synchronized(self) { 1612| 0| if ([appEventsState isCompatibleWithAppEventsState:_appEventsState]) { 1613| 0| [_appEventsState addEventsFromAppEventState:appEventsState]; 1614| 0| } else { 1615| | // flush failed due to connectivity. Persist to be tried again later. 1616| 0| [g_appEventsStateStore persistAppEventsData:appEventsState]; 1617| 0| } 1618| 0| } 1619| 0| } 1620| | 1621| 0| NSString *resultString = @""; 1622| 0| switch (flushResult) { 1623| 0| case FlushResultSuccess: 1624| 0| resultString = @"Success"; 1625| 0| break; 1626| | 1627| 0| case FlushResultNoConnectivity: 1628| 0| resultString = @"No Connectivity"; 1629| 0| break; 1630| | 1631| 0| case FlushResultServerError: 1632| 0| resultString = [NSString stringWithFormat:@"Server Error - %@", error.description]; 1633| 0| break; 1634| 0| } 1635| | 1636| 0| NSString *message = [NSString stringWithFormat:@"%@\nFlush Result : %@", loggingEntry, resultString]; 1637| 0| [g_logger singleShotLogEntry:FBSDKLoggingBehaviorAppEvents 1638| 0| logEntry:message]; 1639| 0|} 1640| | 1641| |- (void)flushTimerFired:(id)arg 1642| 0|{ 1643| 0| [FBSDKAppEventsUtility ensureOnMainThread:NSStringFromSelector(_cmd) className:NSStringFromClass([self class])]; 1644| 0| if (self.flushBehavior != FBSDKAppEventsFlushBehaviorExplicitOnly && !self.disableTimer) { 1645| 0| [self flushForReason:FBSDKAppEventsFlushReasonTimer]; 1646| 0| } 1647| 0|} 1648| | 1649| |- (void)applicationDidBecomeActive 1650| 0|{ 1651| 0| [FBSDKAppEventsUtility ensureOnMainThread:NSStringFromSelector(_cmd) className:NSStringFromClass([self class])]; 1652| | 1653| | // This must happen here to avoid a race condition with the shared `Settings` object. 1654| 0| [self fetchServerConfiguration:nil]; 1655| | 1656| 0| [self checkPersistedEvents]; 1657| | 1658| | // Restore time spent data, indicating that we're not being called from "activateApp". 1659| 0| [self.timeSpentRecorder restore:NO]; 1660| 0|} 1661| | 1662| |- (void)applicationMovingFromActiveStateOrTerminating 1663| 0|{ 1664| | // When moving from active state, we don't have time to wait for the result of a flush, so 1665| | // just persist events to storage, and we'll process them at the next activation. 1666| 0| FBSDKAppEventsState *copy = nil; 1667| 0| @synchronized(self) { 1668| 0| copy = [_appEventsState copy]; 1669| 0| _appEventsState = nil; 1670| 0| } 1671| 0| if (copy) { 1672| 0| [g_appEventsStateStore persistAppEventsData:copy]; 1673| 0| } 1674| 0| [self.timeSpentRecorder suspend]; 1675| 0|} 1676| | 1677| |#pragma mark - Configuration Validation 1678| | 1679| |- (void)validateConfiguration 1680| 0|{ 1681| 0|#if DEBUG 1682| 0| if (!self.isConfigured) { 1683| 0| static NSString *const reason = @"As of v9.0, you must initialize the SDK prior to calling any methods or setting any properties. " 1684| 0| "You can do this by calling `FBSDKApplicationDelegate`'s `application:didFinishLaunchingWithOptions:` method. " 1685| 0| "Learn more: https://developers.facebook.com/docs/ios/getting-started"; 1686| 0| @throw [NSException exceptionWithName:@"InvalidOperationException" reason:reason userInfo:nil]; 1687| 0| } 1688| 0|#endif 1689| 0|} 1690| | 1691| |#pragma mark - Custom Audience 1692| | 1693| |+ (id)requestForCustomAudienceThirdPartyIDWithAccessToken:(FBSDKAccessToken *)accessToken 1694| 0|{ 1695| 0| [self.singleton validateConfiguration]; 1696| | 1697| 0| accessToken = accessToken ?: [FBSDKAccessToken currentAccessToken]; 1698| | // Rules for how we use the attribution ID / advertiser ID for an 'custom_audience_third_party_id' Graph API request 1699| | // 1) if the OS tells us that the user has Limited Ad Tracking, then just don't send, and return a nil in the token. 1700| | // 2) if the app has set 'limitEventAndDataUsage', this effectively implies that app-initiated ad targeting shouldn't happen, 1701| | // so use that data here to return nil as well. 1702| | // 3) if we have a user session token, then no need to send attribution ID / advertiser ID back as the udid parameter 1703| | // 4) otherwise, send back the udid parameter. 1704| 0| if (g_settings.advertisingTrackingStatus == FBSDKAdvertisingTrackingDisallowed || g_settings.shouldLimitEventAndDataUsage) { 1705| 0| return nil; 1706| 0| } 1707| | 1708| 0| NSString *tokenString = [FBSDKAppEventsUtility tokenStringToUseFor:accessToken]; 1709| 0| NSString *udid = nil; 1710| 0| if (!accessToken) { 1711| | // We don't have a logged in user, so we need some form of udid representation. Prefer advertiser ID if 1712| | // available. Note that this function only makes sense to be called in the context of advertising. 1713| 0| udid = [FBSDKAppEventsUtility.shared advertiserID]; 1714| 0| if (!udid) { 1715| | // No udid, and no user token. No point in making the request. 1716| 0| return nil; 1717| 0| } 1718| 0| } 1719| | 1720| 0| NSDictionary *parameters = @{}; 1721| 0| if (udid) { 1722| 0| parameters = @{ @"udid" : udid }; 1723| 0| } 1724| | 1725| 0| NSString *graphPath = [NSString stringWithFormat:@"%@/custom_audience_third_party_id", [[self singleton] appID]]; 1726| | 1727| 0| id request = [g_graphRequestProvider createGraphRequestWithGraphPath:graphPath 1728| 0| parameters:parameters 1729| 0| tokenString:tokenString 1730| 0| HTTPMethod:FBSDKHTTPMethodGET 1731| 0| flags:FBSDKGraphRequestFlagDoNotInvalidateTokenOnError | FBSDKGraphRequestFlagDisableErrorRecovery]; 1732| 0| return request; 1733| 0|} 1734| | 1735| |#pragma mark - Testability 1736| | 1737| |#if DEBUG 1738| | 1739| |+ (void)reset 1740| 0|{ 1741| 0| self.singleton.isConfigured = NO; 1742| 0| [self resetApplicationState]; 1743| 0| g_gateKeeperManager = nil; 1744| 0| g_graphRequestProvider = nil; 1745| 0|} 1746| | 1747| |+ (void)resetApplicationState 1748| 0|{ 1749| 0| self.singleton.applicationState = UIApplicationStateInactive; 1750| 0|} 1751| | 1752| |+ (id)featureChecker 1753| 0|{ 1754| 0| return g_featureChecker; 1755| 0|} 1756| | 1757| |+ (id)requestProvider 1758| 0|{ 1759| 0| return g_graphRequestProvider; 1760| 0|} 1761| | 1762| |+ (Class)serverConfigurationProvider 1763| 0|{ 1764| 0| return g_serverConfigurationProvider; 1765| 0|} 1766| | 1767| |+ (Class)appEventsConfigurationProvider 1768| 0|{ 1769| 0| return g_appEventsConfigurationProvider; 1770| 0|} 1771| | 1772| |+ (Class)gateKeeperManager 1773| 0|{ 1774| 0| return g_gateKeeperManager; 1775| 0|} 1776| | 1777| |+ (Class)logger 1778| 0|{ 1779| 0| return g_logger; 1780| 0|} 1781| | 1782| |+ (id)settings 1783| 0|{ 1784| 0| return g_settings; 1785| 0|} 1786| | 1787| |+ (void)setSettings:(id)settings 1788| 0|{ 1789| 0| g_settings = settings; 1790| 0|} 1791| | 1792| |+ (id)paymentObserver 1793| 0|{ 1794| 0| return g_paymentObserver; 1795| 0|} 1796| | 1797| |+ (void)setPaymentObserver:(id)paymentObserver 1798| 0|{ 1799| 0| g_paymentObserver = paymentObserver; 1800| 0|} 1801| | 1802| |+ (id)appEventsStateStore 1803| 0|{ 1804| 0| return g_appEventsStateStore; 1805| 0|} 1806| | 1807| |- (void)setFlushBehavior:(FBSDKAppEventsFlushBehavior)flushBehavior 1808| 0|{ 1809| 0| _flushBehavior = flushBehavior; 1810| 0|} 1811| | 1812| | #if !TARGET_OS_TV 1813| | 1814| |+ (id)onDeviceMLModelManager 1815| 0|{ 1816| 0| return g_onDeviceMLModelManager; 1817| 0|} 1818| | 1819| |+ (id)metadataIndexer 1820| 0|{ 1821| 0| return g_metadataIndexer; 1822| 0|} 1823| | 1824| |+ (id)eventDeactivationParameterProcessor 1825| 0|{ 1826| 0| return g_eventDeactivationParameterProcessor; 1827| 0|} 1828| | 1829| |+ (id)restrictiveDataFilterParameterProcessor 1830| 0|{ 1831| 0| return g_restrictiveDataFilterParameterProcessor; 1832| 0|} 1833| | 1834| | #endif 1835| | 1836| |#endif 1837| | 1838| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AAM/FBSDKMetadataIndexer.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKMetadataIndexer.h" 24| | 25| | #import 26| | 27| | #import 28| | #import 29| | #import 30| | 31| | #import "FBSDKAppEventsUtility.h" 32| | #import "FBSDKCoreKitBasicsImport.h" 33| | #import "FBSDKServerConfigurationManager.h" 34| | #import "FBSDKSwizzler.h" 35| | #import "FBSDKUtility.h" 36| | #import "FBSDKViewHierarchy.h" 37| | 38| |@interface FBSDKUserDataStore (Internal) 39| | 40| |+ (void)setInternalHashData:(nullable NSString *)hashData 41| | forType:(FBSDKAppEventUserDataType)type; 42| |+ (void)setEnabledRules:(NSArray *)rules; 43| | 44| |+ (nullable NSString *)getInternalHashedDataForType:(FBSDKAppEventUserDataType)type; 45| | 46| |@end 47| | 48| |static const int FBSDKMetadataIndexerMaxTextLength = 100; 49| |static const int FBSDKMetadataIndexerMaxIndicatorLength = 100; 50| |static const int FBSDKMetadataIndexerMaxValue = 5; 51| | 52| |static NSString *const FIELD_K = @"k"; 53| |static NSString *const FIELD_V = @"v"; 54| |static NSString *const FIELD_K_DELIMITER = @","; 55| | 56| |@interface FBSDKMetadataIndexer () 57| | 58| |@property (nonatomic, readonly, strong) NSMutableDictionary *> *rules; 59| |@property (nonatomic, readonly, strong) NSMutableDictionary *> *store; 60| |@property (nonatomic, readonly, strong) dispatch_queue_t serialQueue; 61| | 62| |@end 63| | 64| |@implementation FBSDKMetadataIndexer 65| | 66| |+ (instancetype)shared 67| 0|{ 68| 0| static dispatch_once_t nonce; 69| 0| static FBSDKMetadataIndexer *instance; 70| 0| dispatch_once(&nonce, ^{ 71| 0| instance = [self new]; 72| 0| }); 73| 0| return instance; 74| 0|} 75| | 76| |- (instancetype)init 77| 0|{ 78| 0| _rules = [NSMutableDictionary new]; 79| 0| _serialQueue = dispatch_queue_create("com.facebook.appevents.MetadataIndexer", DISPATCH_QUEUE_SERIAL); 80| 0| return self; 81| 0|} 82| | 83| |- (void)enable 84| 0|{ 85| 0| @try { 86| 0| if ([FBSDKAppEventsUtility shouldDropAppEvent]) { 87| 0| return; 88| 0| } 89| | 90| 0| static dispatch_once_t onceToken; 91| 0| dispatch_once(&onceToken, ^{ 92| 0| NSDictionary *AAMRules = [FBSDKServerConfigurationManager cachedServerConfiguration].AAMRules; 93| 0| if (AAMRules) { 94| 0| [self setupWithRules:AAMRules]; 95| 0| } 96| 0| }); 97| 0| } @catch (NSException *exception) { 98| 0| NSLog(@"Fail to enable Automatic Advanced Matching, exception reason: %@", exception.reason); 99| 0| } 100| 0|} 101| | 102| |- (void)setupWithRules:(NSDictionary *_Nullable)rules 103| 0|{ 104| 0| if (0 == rules.count) { 105| 0| return; 106| 0| } 107| 0| static dispatch_once_t onceToken; 108| 0| dispatch_once(&onceToken, ^{ 109| 0| [self constructRules:rules]; 110| 0| [self initStore]; 111| | 112| 0| BOOL isEnabled = NO; 113| 0| for (NSString *key in _rules) { 114| 0| if (_rules[key]) { 115| 0| isEnabled = YES; 116| 0| break; 117| 0| } 118| 0| } 119| | 120| 0| if (isEnabled) { 121| 0| [FBSDKUserDataStore setEnabledRules:_rules.allKeys]; 122| 0| [self setupMetadataIndexing]; 123| 0| } 124| 0| }); 125| 0|} 126| | 127| |- (void)initStore 128| 0|{ 129| 0| _store = [NSMutableDictionary new]; 130| 0| for (NSString *key in _rules) { 131| 0| NSString *data = [FBSDKUserDataStore getInternalHashedDataForType:key]; 132| 0| if (data.length > 0) { 133| 0| [FBSDKTypeUtility dictionary:_store setObject:[NSMutableArray arrayWithArray:[data componentsSeparatedByString:FIELD_K_DELIMITER]] forKey:key]; 134| 0| } 135| 0| } 136| | 137| 0| for (NSString *key in _rules) { 138| 0| if (!_store[key]) { 139| 0| [FBSDKTypeUtility dictionary:_store setObject:[NSMutableArray new] forKey:key]; 140| 0| } 141| 0| } 142| 0|} 143| | 144| |- (void)constructRules:(NSDictionary *_Nullable)rules 145| 0|{ 146| 0| for (NSString *key in rules) { 147| 0| NSDictionary *value = [FBSDKTypeUtility dictionaryValue:rules[key]]; 148| 0| if (value[FIELD_K].length > 0 && value[FIELD_V]) { 149| 0| [FBSDKTypeUtility dictionary:_rules setObject:value forKey:key]; 150| 0| } 151| 0| } 152| 0|} 153| | 154| |- (void)setupMetadataIndexing 155| 0|{ 156| 0| void (^block)(UIView *) = ^(UIView *view) { 157| | // Indexing when the view is removed from window and conforms to UITextInput, and skip UIFieldEditor, which is an internval view of UITextField 158| 0| if (![view window] && ![NSStringFromClass([view class]) isEqualToString:@"UIFieldEditor"] && [view conformsToProtocol:@protocol(UITextInput)]) { 159| 0| NSString *text = [FBSDKViewHierarchy getText:view]; 160| 0| NSString *placeholder = [FBSDKViewHierarchy getHint:view]; 161| 0| BOOL secureTextEntry = [self checkSecureTextEntry:view]; 162| 0| NSArray *labels = [self getLabelsOfView:view]; 163| 0| UIKeyboardType keyboardType = [self getKeyboardType:view]; 164| 0| dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_DEFAULT, 0), ^(void) { 165| 0| [self getMetadataWithText:text 166| 0| placeholder:placeholder 167| 0| labels:labels 168| 0| secureTextEntry:secureTextEntry 169| 0| inputType:keyboardType]; 170| 0| }); 171| 0| } 172| 0| }; 173| | 174| 0| [FBSDKSwizzler swizzleSelector:@selector(didMoveToWindow) onClass:[UIView class] withBlock:block named:@"metadataIndexingUIView"]; 175| | 176| | // iOS 12: UITextField implements didMoveToWindow without calling parent implementation 177| 0| if (@available(iOS 12, *)) { 178| 0| [FBSDKSwizzler swizzleSelector:@selector(didMoveToWindow) onClass:[UITextField class] withBlock:block named:@"metadataIndexingUITextField"]; 179| 0| } else { 180| 0| [FBSDKSwizzler swizzleSelector:@selector(didMoveToWindow) onClass:[UIControl class] withBlock:block named:@"metadataIndexingUIControl"]; 181| 0| } 182| 0|} 183| | 184| |- (NSArray *)getSiblingViewsOfView:(UIView *)view 185| 0|{ 186| 0| NSObject *parent = [FBSDKViewHierarchy getParent:view]; 187| 0| if (parent) { 188| 0| NSArray *views = [FBSDKViewHierarchy getChildren:parent]; 189| 0| if (views) { 190| 0| NSMutableArray *siblings = [NSMutableArray arrayWithArray:views]; 191| 0| [siblings removeObject:view]; 192| 0| return [siblings copy]; 193| 0| } 194| 0| } 195| 0| return nil; 196| 0|} 197| | 198| |- (NSArray *)getLabelsOfView:(UIView *)view 199| 0|{ 200| 0| NSMutableArray *labels = [NSMutableArray new]; 201| | 202| 0| NSString *placeholder = [self normalizeField:[FBSDKViewHierarchy getHint:view]]; 203| 0| if (placeholder.length > 0) { 204| 0| [FBSDKTypeUtility array:labels addObject:placeholder]; 205| 0| } 206| | 207| 0| NSArray *siblingViews = [self getSiblingViewsOfView:view]; 208| 0| for (id sibling in siblingViews) { 209| 0| if ([sibling isKindOfClass:[UILabel class]]) { 210| 0| NSString *text = [self normalizeField:[FBSDKViewHierarchy getText:sibling]]; 211| 0| if (text.length > 0) { 212| 0| [FBSDKTypeUtility array:labels addObject:text]; 213| 0| } 214| 0| } 215| 0| } 216| 0| return [labels copy]; 217| 0|} 218| | 219| |- (BOOL)checkSecureTextEntry:(UIView *)view 220| 0|{ 221| 0| if ([view isKindOfClass:[UITextField class]]) { 222| 0| return ((UITextField *)view).secureTextEntry; 223| 0| } 224| 0| if ([view isKindOfClass:[UITextView class]]) { 225| 0| return ((UITextView *)view).secureTextEntry; 226| 0| } 227| | 228| 0| return NO; 229| 0|} 230| | 231| |- (UIKeyboardType)getKeyboardType:(UIView *)view 232| 0|{ 233| 0| if ([view isKindOfClass:[UITextField class]]) { 234| 0| return ((UITextField *)view).keyboardType; 235| 0| } 236| 0| if ([view isKindOfClass:[UITextView class]]) { 237| 0| return ((UITextView *)view).keyboardType; 238| 0| } 239| | 240| 0| return UIKeyboardTypeDefault; 241| 0|} 242| | 243| |- (void)getMetadataWithText:(NSString *)text 244| | placeholder:(NSString *)placeholder 245| | labels:(NSArray *)labels 246| | secureTextEntry:(BOOL)secureTextEntry 247| | inputType:(UIKeyboardType)inputType 248| 0|{ 249| 0| text = [self normalizeValue:text]; 250| 0| placeholder = [self normalizeField:placeholder]; 251| 0| if (secureTextEntry || [placeholder containsString:@"password"] 252| 0| || text.length == 0 253| 0| || text.length > FBSDKMetadataIndexerMaxTextLength 254| 0| || placeholder.length >= FBSDKMetadataIndexerMaxIndicatorLength) { 255| 0| return; 256| 0| } 257| | 258| 0| for (NSString *key in _rules) { 259| 0| NSDictionary *rule = _rules[key]; 260| 0| BOOL isRuleKMatched = [self checkMetadataHint:placeholder matchRuleK:rule[FIELD_K]] 261| 0| || [self checkMetadataLabels:labels matchRuleK:rule[FIELD_K]]; 262| 0| if (!isRuleKMatched) { 263| 0| continue; 264| 0| } 265| | 266| 0| NSString *preProcessedText = text; 267| 0| if ([key isEqualToString:@"r2"]) { 268| 0| preProcessedText = [[text componentsSeparatedByCharactersInSet:[NSCharacterSet characterSetWithCharactersInString:@"+- ()."]] componentsJoinedByString:@""]; 269| 0| } 270| 0| BOOL isRuleVMatched = [rule[FIELD_V] isEqualToString:@""] || [self checkMetadataText:preProcessedText matchRuleV:rule[FIELD_V]]; 271| 0| if (isRuleVMatched) { 272| 0| NSString *prunedText = [self pruneValue:preProcessedText forKey:key]; 273| 0| [self checkAndAppendData:prunedText forKey:key]; 274| 0| continue; 275| 0| } 276| 0| } 277| 0|} 278| | 279| | #pragma mark - Helper Methods 280| | 281| |- (void)checkAndAppendData:(NSString *)data 282| | forKey:(NSString *)key 283| 0|{ 284| 0| NSString *hashData = [FBSDKUtility SHA256Hash:data]; 285| 0| __weak typeof(_store) weakStore = _store; 286| 0| dispatch_block_t checkAndAppendDataBlock = ^{ 287| 0| if (hashData.length == 0 || [weakStore[key] containsObject:hashData]) { 288| 0| return; 289| 0| } 290| | 291| 0| while (weakStore[key].count >= FBSDKMetadataIndexerMaxValue) { 292| 0| [weakStore[key] removeObjectAtIndex:0]; 293| 0| } 294| 0| [FBSDKTypeUtility array:weakStore[key] addObject:hashData]; 295| 0| [FBSDKUserDataStore setInternalHashData:[weakStore[key] componentsJoinedByString:FIELD_K_DELIMITER] 296| 0| forType:key]; 297| 0| }; 298| 0|#ifdef FBSDKTEST 299| 0| checkAndAppendDataBlock(); 300| |#else 301| | dispatch_async(_serialQueue, checkAndAppendDataBlock); 302| |#endif 303| 0|} 304| | 305| |- (BOOL)checkMetadataLabels:(NSArray *)labels 306| | matchRuleK:(NSString *)ruleK 307| 0|{ 308| 0| for (NSString *label in labels) { 309| 0| if ([self checkMetadataHint:label matchRuleK:ruleK]) { 310| 0| return YES; 311| 0| } 312| 0| } 313| 0| return NO; 314| 0|} 315| | 316| |- (BOOL)checkMetadataHint:(NSString *)hint 317| | matchRuleK:(NSString *)ruleK 318| 0|{ 319| 0| if (hint.length > 0 && ruleK) { 320| 0| NSArray *items = [ruleK componentsSeparatedByString:FIELD_K_DELIMITER]; 321| 0| for (NSString *item in items) { 322| 0| if ([hint containsString:item]) { 323| 0| return YES; 324| 0| } 325| 0| } 326| 0| } 327| 0| return NO; 328| 0|} 329| | 330| |- (BOOL)checkMetadataText:(NSString *)text 331| | matchRuleV:(NSString *)ruleV 332| 0|{ 333| 0| if (text.length > 0 && ruleV) { 334| 0| NSRegularExpression *regex = [[NSRegularExpression alloc] initWithPattern:ruleV 335| 0| options:NSRegularExpressionCaseInsensitive 336| 0| error:nil]; 337| 0| return [regex numberOfMatchesInString:text options:0 range:NSMakeRange(0, text.length)] == 1; 338| 0| } 339| 0| return NO; 340| 0|} 341| | 342| |- (NSString *)normalizeField:(NSString *)field 343| 0|{ 344| 0| if (field.length == 0) { 345| 0| return @""; 346| 0| } 347| 0| NSRegularExpression *regex = [NSRegularExpression regularExpressionWithPattern:@"[_-]|\\s" 348| 0| options:NSRegularExpressionCaseInsensitive 349| 0| error:nil]; 350| 0| return [regex stringByReplacingMatchesInString:field 351| 0| options:0 352| 0| range:NSMakeRange(0, field.length) 353| 0| withTemplate:@""].lowercaseString; 354| 0|} 355| | 356| |- (NSString *)normalizeValue:(NSString *)value 357| 0|{ 358| 0| if (value.length == 0) { 359| 0| return @""; 360| 0| } 361| 0| return [value stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceCharacterSet]].lowercaseString; 362| 0|} 363| | 364| |- (NSString *)pruneValue:(NSString *)value forKey:(NSString *)key 365| 0|{ 366| 0| if (value.length == 0) { 367| 0| return @""; 368| 0| } 369| 0| if ([key isEqualToString:@"r3"]) { 370| 0| if ([value hasPrefix:@"m"] || [value hasPrefix:@"b"] || [value hasPrefix:@"ge"]) { 371| 0| value = @"m"; 372| 0| } else { 373| 0| value = @"f"; 374| 0| } 375| 0| } else if ([key isEqualToString:@"r4"] || [key isEqualToString:@"r5"]) { 376| 0| value = [[value componentsSeparatedByCharactersInSet:[[NSCharacterSet letterCharacterSet] invertedSet]] componentsJoinedByString:@""]; 377| 0| } else if ([key isEqualToString:@"r6"]) { 378| 0| value = [FBSDKTypeUtility array:[value componentsSeparatedByString:@"-"] objectAtIndex:0]; 379| 0| } 380| 0| return value; 381| 0|} 382| | 383| |@end 384| | 385| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMAdvertiserMultiEntryRule.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKAEMAdvertiserMultiEntryRule.h" 24| | 25| | #import "FBSDKAEMAdvertiserSingleEntryRule.h" 26| | 27| |static NSString *const OPERATOR_KEY = @"operator"; 28| |static NSString *const RULES_KEY = @"rules"; 29| | 30| |@implementation FBSDKAEMAdvertiserMultiEntryRule 31| | 32| |- (instancetype)initWithOperator:(FBSDKAEMAdvertiserRuleOperator)op 33| | rules:(NSArray> *)rules 34| 0|{ 35| 0| if (self = [super init]) { 36| 0| _operator = op; 37| 0| _rules = rules; 38| 0| } 39| 0| return self; 40| 0|} 41| | 42| | #pragma mark - FBSDKAEMAdvertiserRuleMatching 43| | 44| |- (BOOL)isMatchedEventParameters:(nullable NSDictionary *)eventParams 45| 0|{ 46| 0| @try { 47| 0| BOOL isMatched = _operator == FBSDKAEMAdvertiserRuleOperatorOr ? NO : YES; 48| 0| for (id rule in _rules) { 49| 0| BOOL doesSubruleMatch = [rule isMatchedEventParameters:eventParams]; 50| 0| if (_operator == FBSDKAEMAdvertiserRuleOperatorAnd) { 51| 0| isMatched = isMatched & doesSubruleMatch; 52| 0| } 53| 0| if (_operator == FBSDKAEMAdvertiserRuleOperatorOr) { 54| 0| isMatched = isMatched | doesSubruleMatch; 55| 0| } 56| 0| if (_operator == FBSDKAEMAdvertiserRuleOperatorNot) { 57| 0| isMatched = isMatched & !doesSubruleMatch; 58| 0| } 59| 0| } 60| 0| return isMatched; 61| 0| } @catch (NSException *exception) { 62| 0| #if DEBUG 63| 0| #if FBSDKTEST 64| 0| @throw exception; 65| 0| #endif 66| 0| #endif 67| 0| return NO; 68| 0| } 69| 0|} 70| | 71| | #pragma mark - NSCoding 72| | 73| |+ (BOOL)supportsSecureCoding 74| 0|{ 75| 0| return YES; 76| 0|} 77| | 78| |- (instancetype)initWithCoder:(NSCoder *)decoder 79| 0|{ 80| 0| FBSDKAEMAdvertiserRuleOperator op = [decoder decodeIntegerForKey:OPERATOR_KEY]; 81| 0| NSSet *classes = [NSSet setWithArray:@[NSArray.class, FBSDKAEMAdvertiserMultiEntryRule.class, FBSDKAEMAdvertiserSingleEntryRule.class]]; 82| 0| NSArray> *rules = [decoder decodeObjectOfClasses:classes forKey:RULES_KEY]; 83| 0| return [self initWithOperator:op rules:rules]; 84| 0|} 85| | 86| |- (void)encodeWithCoder:(NSCoder *)encoder 87| 0|{ 88| 0| [encoder encodeInteger:_operator forKey:OPERATOR_KEY]; 89| 0| [encoder encodeObject:_rules forKey:RULES_KEY]; 90| 0|} 91| | 92| | #pragma mark - NSCopying 93| | 94| |- (instancetype)copyWithZone:(NSZone *)zone 95| 0|{ 96| 0| return self; 97| 0|} 98| | 99| |@end 100| | 101| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMAdvertiserRuleFactory.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKAEMAdvertiserRuleFactory.h" 24| | 25| | #import "FBSDKAEMAdvertiserMultiEntryRule.h" 26| | #import "FBSDKAEMAdvertiserSingleEntryRule.h" 27| | #import "FBSDKCoreKitBasicsImport.h" 28| | #import "FBSDKLogger.h" 29| | 30| |@implementation FBSDKAEMAdvertiserRuleFactory 31| | 32| |- (nullable id)createRuleWithJson:(nullable NSString *)json 33| 0|{ 34| 0| @try { 35| 0| json = [FBSDKTypeUtility stringValueOrNil:json]; 36| 0| if (!json) { 37| 0| return nil; 38| 0| } 39| 0| NSDictionary *rule = [FBSDKBasicUtility objectForJSONString:json error:nil]; 40| 0| return [self createRuleWithDict:rule]; 41| 0| } @catch (NSException *exception) { 42| 0| [FBSDKLogger singleShotLogEntry:FBSDKLoggingBehaviorAppEvents logEntry:@"Fail to parse Advertiser Rules with JSON"]; 43| 0| } 44| 0| return nil; 45| 0|} 46| | 47| |- (nullable id)createRuleWithDict:(NSDictionary *)dict 48| 0|{ 49| 0| @try { 50| 0| dict = [FBSDKTypeUtility dictionaryValue:dict]; 51| 0| if (!dict) { 52| 0| return nil; 53| 0| } 54| 0| FBSDKAEMAdvertiserRuleOperator op = [self getOperator:dict]; 55| 0| if ([self isOperatorForMultiEntryRule:op]) { 56| 0| return [self createMultiEntryRuleWithDict:dict]; 57| 0| } else { 58| 0| return [self createSingleEntryRuleWithDict:dict]; 59| 0| } 60| 0| } @catch (NSException *exception) { 61| 0| [FBSDKLogger singleShotLogEntry:FBSDKLoggingBehaviorAppEvents logEntry:@"Fail to parse Advertiser Rules with Dict"]; 62| 0| } 63| 0| return nil; 64| 0|} 65| | 66| |- (nullable FBSDKAEMAdvertiserMultiEntryRule *)createMultiEntryRuleWithDict:(NSDictionary *)dict 67| 0|{ 68| 0| dict = [FBSDKTypeUtility dictionaryValue:dict]; 69| 0| if (!dict) { 70| 0| return nil; 71| 0| } 72| 0| NSString *opString = [self primaryKeyForRule:dict]; 73| 0| FBSDKAEMAdvertiserRuleOperator operator = [self getOperator:dict]; 74| 0| if (![self isOperatorForMultiEntryRule:operator]) { 75| 0| return nil; 76| 0| } 77| 0| NSArray *subrules = [FBSDKTypeUtility dictionary:dict objectForKey:opString ofType:NSArray.class]; 78| 0| NSMutableArray> *rules = [NSMutableArray new]; 79| 0| for (NSDictionary *subrule in subrules) { 80| 0| id entryRule = [self createRuleWithDict:subrule]; 81| 0| if (!entryRule) { 82| 0| return nil; 83| 0| } 84| 0| [FBSDKTypeUtility array:rules addObject:entryRule]; 85| 0| } 86| 0| if (!rules.count) { 87| 0| return nil; 88| 0| } 89| 0| return [[FBSDKAEMAdvertiserMultiEntryRule alloc] initWithOperator:operator rules:rules]; 90| 0|} 91| | 92| |- (nullable FBSDKAEMAdvertiserSingleEntryRule *)createSingleEntryRuleWithDict:(NSDictionary *)dict 93| 0|{ 94| 0| dict = [FBSDKTypeUtility dictionaryValue:dict]; 95| 0| if (!dict) { 96| 0| return nil; 97| 0| } 98| 0| NSString *paramKey = [self primaryKeyForRule:dict]; 99| 0| NSDictionary *rawRule = [FBSDKTypeUtility dictionary:dict objectForKey:paramKey ofType:NSDictionary.class]; 100| 0| NSString *encodedOperator = [self primaryKeyForRule:rawRule]; 101| 0| FBSDKAEMAdvertiserRuleOperator operator = [self getOperator:rawRule]; 102| 0| NSString *linguisticCondition = nil; 103| 0| NSNumber *numericalCondition = nil; 104| 0| NSArray *arrayCondition = nil; 105| 0| switch (operator) { 106| 0| case Unknown: 107| 0| default: 108| 0| return nil; 109| 0| case FBSDKAEMAdvertiserRuleOperatorContains: 110| 0| case FBSDKAEMAdvertiserRuleOperatorNotContains: 111| 0| case FBSDKAEMAdvertiserRuleOperatorStartsWith: 112| 0| case FBSDKAEMAdvertiserRuleOperatorI_Contains: 113| 0| case FBSDKAEMAdvertiserRuleOperatorI_NotContains: 114| 0| case FBSDKAEMAdvertiserRuleOperatorI_StartsWith: 115| 0| case FBSDKAEMAdvertiserRuleOperatorRegexMatch: 116| 0| case FBSDKAEMAdvertiserRuleOperatorEqual: 117| 0| case FBSDKAEMAdvertiserRuleOperatorNotEqual: 118| 0| linguisticCondition = [FBSDKTypeUtility dictionary:rawRule objectForKey:encodedOperator ofType:NSString.class]; break; 119| 0| case FBSDKAEMAdvertiserRuleOperatorLessThan: 120| 0| case FBSDKAEMAdvertiserRuleOperatorLessThanOrEqual: 121| 0| case FBSDKAEMAdvertiserRuleOperatorGreaterThan: 122| 0| case FBSDKAEMAdvertiserRuleOperatorGreaterThanOrEqual: 123| 0| numericalCondition = [FBSDKTypeUtility dictionary:rawRule objectForKey:encodedOperator ofType:NSNumber.class]; break; 124| 0| case FBSDKAEMAdvertiserRuleOperatorI_IsAny: 125| 0| case FBSDKAEMAdvertiserRuleOperatorI_IsNotAny: 126| 0| case FBSDKAEMAdvertiserRuleOperatorIsAny: 127| 0| case FBSDKAEMAdvertiserRuleOperatorIsNotAny: 128| 0| arrayCondition = [FBSDKTypeUtility dictionary:rawRule objectForKey:encodedOperator ofType:NSArray.class]; break; 129| 0| } 130| 0| if (linguisticCondition || numericalCondition != nil || arrayCondition.count > 0) { 131| 0| return [[FBSDKAEMAdvertiserSingleEntryRule alloc] initWithOperator:operator paramKey:paramKey linguisticCondition:linguisticCondition numericalCondition:numericalCondition arrayCondition:arrayCondition]; 132| 0| } 133| 0| return nil; 134| 0|} 135| | 136| |- (nullable NSString *)primaryKeyForRule:(NSDictionary *)rule 137| 0|{ 138| 0| NSArray *keys = [rule allKeys]; 139| 0| NSString *key = keys.firstObject; 140| 0| return [FBSDKTypeUtility stringValueOrNil:key]; 141| 0|} 142| | 143| |- (FBSDKAEMAdvertiserRuleOperator)getOperator:(NSDictionary *)rule 144| 0|{ 145| 0| NSString *key = [self primaryKeyForRule:rule]; 146| 0| if (!key) { 147| 0| return Unknown; 148| 0| } 149| 0| NSArray *operatorKeys = @[ 150| 0| @"unknown", 151| 0| @"and", 152| 0| @"or", 153| 0| @"not", 154| 0| @"contains", 155| 0| @"not_contains", 156| 0| @"starts_with", 157| 0| @"i_contains", 158| 0| @"i_not_contains", 159| 0| @"i_starts_with", 160| 0| @"regex_match", 161| 0| @"eq", 162| 0| @"neq", 163| 0| @"lt", 164| 0| @"lte", 165| 0| @"gt", 166| 0| @"gte", 167| 0| @"i_is_any", 168| 0| @"i_is_not_any", 169| 0| @"is_any", 170| 0| @"is_not_any" 171| 0| ]; 172| 0| NSInteger index = [operatorKeys indexOfObject:key.lowercaseString]; 173| 0| return index == NSNotFound ? Unknown : index; 174| 0|} 175| | 176| |- (BOOL)isOperatorForMultiEntryRule:(FBSDKAEMAdvertiserRuleOperator)operator 177| 0|{ 178| 0| return operator == FBSDKAEMAdvertiserRuleOperatorAnd 179| 0| || operator == FBSDKAEMAdvertiserRuleOperatorOr 180| 0| || operator == FBSDKAEMAdvertiserRuleOperatorNot; 181| 0|} 182| | 183| |@end 184| | 185| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMAdvertiserSingleEntryRule.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKAEMAdvertiserSingleEntryRule.h" 24| | 25| | #import "FBSDKCoreKitBasicsImport.h" 26| | 27| |static NSString *const OPERATOR_KEY = @"operator"; 28| |static NSString *const PARAMKEY_KEY = @"param_key"; 29| |static NSString *const STRING_VALUE_KEY = @"string_value"; 30| |static NSString *const NUMBER_VALUE_KEY = @"number_value"; 31| |static NSString *const ARRAY_VALUE_KEY = @"array_value"; 32| |static NSString *const PARAM_DELIMETER = @"."; 33| |static NSString *const ASTERISK_DELIMETER = @"[*]"; 34| | 35| |@implementation FBSDKAEMAdvertiserSingleEntryRule 36| | 37| |- (instancetype)initWithOperator:(FBSDKAEMAdvertiserRuleOperator)op 38| | paramKey:(NSString *)paramKey 39| | linguisticCondition:(nullable NSString *)linguisticCondition 40| | numericalCondition:(nullable NSNumber *)numericalCondition 41| | arrayCondition:(nullable NSArray *)arrayCondition 42| 0|{ 43| 0| if ((self = [super init])) { 44| 0| _operator = op; 45| 0| _paramKey = paramKey; 46| 0| _linguisticCondition = linguisticCondition; 47| 0| _numericalCondition = numericalCondition; 48| 0| _arrayCondition = arrayCondition; 49| 0| } 50| 0| return self; 51| 0|} 52| | 53| | #pragma mark - FBSDKAEMAdvertiserRuleMatching 54| | 55| |- (BOOL)isMatchedEventParameters:(nullable NSDictionary *)eventParams 56| 0|{ 57| 0| @try { 58| 0| NSArray *paramPath = [_paramKey componentsSeparatedByString:PARAM_DELIMETER]; 59| 0| return [self isMatchedEventParameters:eventParams paramPath:paramPath]; 60| 0| } @catch (NSException *exception) { 61| 0| #if DEBUG 62| 0| #if FBSDKTEST 63| 0| @throw exception; 64| 0| #endif 65| 0| #endif 66| 0| return NO; 67| 0| } 68| 0|} 69| | 70| |- (BOOL)isMatchedEventParameters:(nullable NSDictionary *)eventParams 71| | paramPath:(NSArray *)paramPath 72| 0|{ 73| 0| eventParams = [FBSDKTypeUtility dictionaryValue:eventParams]; 74| 0| if (!eventParams || !paramPath.count) { 75| 0| return NO; 76| 0| } 77| 0| NSString *param = [FBSDKTypeUtility stringValueOrNil:paramPath.firstObject]; 78| 0| if ([param hasSuffix:ASTERISK_DELIMETER]) { 79| 0| return [self isMatchedWithAsteriskParam:param eventParameters:eventParams paramPath:paramPath]; 80| 0| } 81| | // if data does not contain the key, we should return false directly. 82| 0| if (!param || ![[eventParams allKeys] containsObject:param]) { 83| 0| return NO; 84| 0| } 85| | // Apply operator rule if the last param is reached 86| 0| if (paramPath.count == 1) { 87| 0| NSString *stringValue = nil; 88| 0| NSNumber *numericalValue = nil; 89| 0| switch (_operator) { 90| 0| case FBSDKAEMAdvertiserRuleOperatorContains: 91| 0| case FBSDKAEMAdvertiserRuleOperatorNotContains: 92| 0| case FBSDKAEMAdvertiserRuleOperatorStartsWith: 93| 0| case FBSDKAEMAdvertiserRuleOperatorI_Contains: 94| 0| case FBSDKAEMAdvertiserRuleOperatorI_NotContains: 95| 0| case FBSDKAEMAdvertiserRuleOperatorI_StartsWith: 96| 0| case FBSDKAEMAdvertiserRuleOperatorRegexMatch: 97| 0| case FBSDKAEMAdvertiserRuleOperatorEqual: 98| 0| case FBSDKAEMAdvertiserRuleOperatorNotEqual: 99| 0| case FBSDKAEMAdvertiserRuleOperatorI_IsAny: 100| 0| case FBSDKAEMAdvertiserRuleOperatorI_IsNotAny: 101| 0| case FBSDKAEMAdvertiserRuleOperatorIsAny: 102| 0| case FBSDKAEMAdvertiserRuleOperatorIsNotAny: 103| 0| stringValue = [FBSDKTypeUtility dictionary:eventParams objectForKey:param ofType:NSString.class]; break; 104| 0| case FBSDKAEMAdvertiserRuleOperatorLessThan: 105| 0| case FBSDKAEMAdvertiserRuleOperatorLessThanOrEqual: 106| 0| case FBSDKAEMAdvertiserRuleOperatorGreaterThan: 107| 0| case FBSDKAEMAdvertiserRuleOperatorGreaterThanOrEqual: 108| 0| numericalValue = [FBSDKTypeUtility dictionary:eventParams objectForKey:param ofType:NSNumber.class]; break; 109| 0| default: break; 110| 0| } 111| 0| return [self isMatchedWithStringValue:stringValue numericalValue:numericalValue]; 112| 0| } 113| 0| NSDictionary *subParams = [FBSDKTypeUtility dictionary:eventParams objectForKey:param ofType:NSDictionary.class]; 114| 0| NSRange range = NSMakeRange(1, paramPath.count - 1); 115| 0| NSArray *subParamPath = [paramPath subarrayWithRange:range]; 116| 0| return [self isMatchedEventParameters:subParams paramPath:subParamPath]; 117| 0|} 118| | 119| |- (BOOL)isMatchedWithAsteriskParam:(NSString *)param 120| | eventParameters:(NSDictionary *)eventParams 121| | paramPath:(NSArray *)paramPath 122| 0|{ 123| 0| param = [param substringToIndex:param.length - ASTERISK_DELIMETER.length]; 124| 0| NSArray *items = [FBSDKTypeUtility dictionary:eventParams objectForKey:param ofType:NSArray.class]; 125| 0| if (!items.count || paramPath.count < 2) { 126| 0| return NO; 127| 0| } 128| 0| BOOL isMatched = NO; 129| 0| NSRange range = NSMakeRange(1, paramPath.count - 1); 130| 0| NSArray *subParamPath = [paramPath subarrayWithRange:range]; 131| 0| for (NSDictionary *item in items) { 132| 0| isMatched |= [self isMatchedEventParameters:item paramPath:subParamPath]; 133| 0| if (isMatched) { 134| 0| break; 135| 0| } 136| 0| } 137| 0| return isMatched; 138| 0|} 139| | 140| |- (BOOL)isMatchedWithStringValue:(nullable NSString *)stringValue 141| | numericalValue:(nullable NSNumber *)numericalValue 142| 0|{ 143| 0| BOOL isMatched = NO; 144| 0| switch (_operator) { 145| 0| case FBSDKAEMAdvertiserRuleOperatorContains: 146| 0| isMatched = stringValue && [stringValue containsString:_linguisticCondition]; break; 147| 0| case FBSDKAEMAdvertiserRuleOperatorNotContains: 148| 0| isMatched = !(stringValue && [stringValue containsString:_linguisticCondition]); break; 149| 0| case FBSDKAEMAdvertiserRuleOperatorStartsWith: 150| 0| isMatched = stringValue && [stringValue hasPrefix:_linguisticCondition]; break; 151| 0| case FBSDKAEMAdvertiserRuleOperatorI_Contains: 152| 0| isMatched = stringValue && [stringValue.lowercaseString containsString:_linguisticCondition.lowercaseString]; break; 153| 0| case FBSDKAEMAdvertiserRuleOperatorI_NotContains: 154| 0| isMatched = !(stringValue && [stringValue.lowercaseString containsString:_linguisticCondition.lowercaseString]); break; 155| 0| case FBSDKAEMAdvertiserRuleOperatorI_StartsWith: 156| 0| isMatched = stringValue && [stringValue.lowercaseString hasPrefix:_linguisticCondition.lowercaseString]; break; 157| 0| case FBSDKAEMAdvertiserRuleOperatorRegexMatch: 158| 0| isMatched = stringValue && [self isRegexMatch:stringValue]; break; 159| 0| case FBSDKAEMAdvertiserRuleOperatorEqual: 160| 0| isMatched = stringValue && [stringValue isEqualToString:_linguisticCondition]; break; 161| 0| case FBSDKAEMAdvertiserRuleOperatorNotEqual: 162| 0| isMatched = !(stringValue && [stringValue isEqualToString:_linguisticCondition]); break; 163| 0| case FBSDKAEMAdvertiserRuleOperatorI_IsAny: 164| 0| isMatched = stringValue && [self isAnyOf:_arrayCondition stringValue:stringValue ignoreCase:YES]; break; 165| 0| case FBSDKAEMAdvertiserRuleOperatorI_IsNotAny: 166| 0| isMatched = !(stringValue && [self isAnyOf:_arrayCondition stringValue:stringValue ignoreCase:YES]); break; 167| 0| case FBSDKAEMAdvertiserRuleOperatorIsAny: 168| 0| isMatched = stringValue && [self isAnyOf:_arrayCondition stringValue:stringValue ignoreCase:NO]; break; 169| 0| case FBSDKAEMAdvertiserRuleOperatorIsNotAny: 170| 0| isMatched = !(stringValue && [self isAnyOf:_arrayCondition stringValue:stringValue ignoreCase:NO]); break; 171| 0| case FBSDKAEMAdvertiserRuleOperatorLessThan: 172| 0| isMatched = (numericalValue != nil) && ([numericalValue compare:_numericalCondition] == NSOrderedAscending); break; 173| 0| case FBSDKAEMAdvertiserRuleOperatorLessThanOrEqual: 174| 0| isMatched = (numericalValue != nil) && ([numericalValue compare:_numericalCondition] != NSOrderedDescending); break; 175| 0| case FBSDKAEMAdvertiserRuleOperatorGreaterThan: 176| 0| isMatched = (numericalValue != nil) && ([numericalValue compare:_numericalCondition] == NSOrderedDescending); break; 177| 0| case FBSDKAEMAdvertiserRuleOperatorGreaterThanOrEqual: 178| 0| isMatched = (numericalValue != nil) && ([numericalValue compare:_numericalCondition] != NSOrderedAscending); break; 179| 0| default: break; 180| 0| } 181| 0| return isMatched; 182| 0|} 183| | 184| |- (BOOL)isRegexMatch:(NSString *)stringValue 185| 0|{ 186| 0| if (!_linguisticCondition.length) { 187| 0| return NO; 188| 0| } 189| 0| NSError *error = nil; 190| 0| NSRegularExpression *regex = [NSRegularExpression regularExpressionWithPattern:_linguisticCondition options:0 error:&error]; 191| 0| if (!regex || error) { 192| 0| return NO; 193| 0| } 194| 0| NSRange searchedRange = NSMakeRange(0, stringValue.length); 195| 0| NSArray *matches = [regex matchesInString:stringValue options:0 range:searchedRange]; 196| 0| return matches.count > 0; 197| 0|} 198| | 199| |- (BOOL)isAnyOf:(NSArray *)arrayCondition 200| | stringValue:(NSString *)stringValue 201| | ignoreCase:(BOOL)ignoreCase 202| 0|{ 203| 0| NSMutableSet *set = [NSMutableSet new]; 204| 0| for (NSString *item in arrayCondition) { 205| 0| if (ignoreCase) { 206| 0| [set addObject:item.lowercaseString]; 207| 0| } else { 208| 0| [set addObject:item]; 209| 0| } 210| 0| } 211| 0| if (ignoreCase) { 212| 0| stringValue = stringValue.lowercaseString; 213| 0| } 214| 0| return [set containsObject:stringValue]; 215| 0|} 216| | 217| | #pragma mark - NSCoding 218| | 219| |+ (BOOL)supportsSecureCoding 220| 0|{ 221| 0| return YES; 222| 0|} 223| | 224| |- (instancetype)initWithCoder:(NSCoder *)decoder 225| 0|{ 226| 0| FBSDKAEMAdvertiserRuleOperator op = [decoder decodeIntegerForKey:OPERATOR_KEY]; 227| 0| NSString *paramKey = [decoder decodeObjectOfClass:NSString.class forKey:PARAMKEY_KEY]; 228| 0| NSString *linguisticCondition = [decoder decodeObjectOfClass:NSString.class forKey:STRING_VALUE_KEY]; 229| 0| NSNumber *numericalCondition = [decoder decodeObjectOfClass:NSNumber.class forKey:NUMBER_VALUE_KEY]; 230| 0| NSArray *arrayCondition = [decoder decodeObjectOfClass:NSArray.class forKey:ARRAY_VALUE_KEY]; 231| 0| return [self initWithOperator:op 232| 0| paramKey:paramKey 233| 0| linguisticCondition:linguisticCondition 234| 0| numericalCondition:numericalCondition 235| 0| arrayCondition:arrayCondition]; 236| 0|} 237| | 238| |- (void)encodeWithCoder:(NSCoder *)encoder 239| 0|{ 240| 0| [encoder encodeInteger:_operator forKey:OPERATOR_KEY]; 241| 0| [encoder encodeObject:_paramKey forKey:PARAMKEY_KEY]; 242| 0| [encoder encodeObject:_linguisticCondition forKey:STRING_VALUE_KEY]; 243| 0| [encoder encodeObject:_numericalCondition forKey:NUMBER_VALUE_KEY]; 244| 0| [encoder encodeObject:_arrayCondition forKey:ARRAY_VALUE_KEY]; 245| 0|} 246| | 247| | #pragma mark - NSCopying 248| | 249| |- (instancetype)copyWithZone:(NSZone *)zone 250| 0|{ 251| 0| return self; 252| 0|} 253| | 254| | #if DEBUG 255| | #if FBSDKTEST 256| | 257| |- (void)setOperator:(FBSDKAEMAdvertiserRuleOperator)operator 258| 0|{ 259| 0| _operator = operator; 260| 0|} 261| | 262| | #endif 263| | #endif 264| | 265| |@end 266| | 267| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMConfiguration.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKAEMConfiguration.h" 24| | 25| | #import "FBSDKAEMAdvertiserMultiEntryRule.h" 26| | #import "FBSDKAEMAdvertiserSingleEntryRule.h" 27| | #import "FBSDKCoreKitBasicsImport.h" 28| | 29| |static NSString *const DEFAULT_CURRENCY_KEY = @"default_currency"; 30| |static NSString *const CUTOFF_TIME_KEY = @"cutoff_time"; 31| |static NSString *const CONVERSION_RULES_KEY = @"conversion_value_rules"; 32| |static NSString *const VALID_FROM_KEY = @"valid_from"; 33| |static NSString *const CONFIG_MODE_KEY = @"config_mode"; 34| |static NSString *const CONFIG_BUSINESS_ID_KEY = @"advertiser_id"; 35| |static NSString *const BUSINESS_ID_KEY = @"business_id"; 36| |static NSString *const PARAM_RULE_KEY = @"param_rule"; 37| | 38| |static id _ruleProvider; 39| | 40| |@implementation FBSDKAEMConfiguration 41| | 42| |+ (void)configureWithRuleProvider:(id)ruleProvider 43| 0|{ 44| 0| if (self == [FBSDKAEMConfiguration class]) { 45| 0| _ruleProvider = ruleProvider; 46| 0| } 47| 0|} 48| | 49| |+ (id)ruleProvider 50| 0|{ 51| 0| return _ruleProvider; 52| 0|} 53| | 54| |- (nullable instancetype)initWithJSON:(nullable NSDictionary *)dict 55| 0|{ 56| 0| if ((self = [super init])) { 57| 0| @try { 58| 0| dict = [FBSDKTypeUtility dictionaryValue:dict]; 59| 0| if (!dict) { 60| 0| return nil; 61| 0| } 62| 0| NSString *defaultCurrency = [FBSDKTypeUtility dictionary:dict objectForKey:DEFAULT_CURRENCY_KEY ofType:NSString.class]; 63| 0| NSNumber *cutoffTime = [FBSDKTypeUtility dictionary:dict objectForKey:CUTOFF_TIME_KEY ofType:NSNumber.class]; 64| 0| NSNumber *validFrom = [FBSDKTypeUtility dictionary:dict objectForKey:VALID_FROM_KEY ofType:NSNumber.class]; 65| 0| NSString *configMode = [FBSDKTypeUtility dictionary:dict objectForKey:CONFIG_MODE_KEY ofType:NSString.class]; 66| 0| NSString *businessID = [FBSDKTypeUtility dictionary:dict objectForKey:CONFIG_BUSINESS_ID_KEY ofType:NSString.class]; 67| 0| NSString *paramRuleJson = [FBSDKTypeUtility dictionary:dict objectForKey:PARAM_RULE_KEY ofType:NSString.class]; 68| 0| id matchingRule = [FBSDKAEMConfiguration.ruleProvider createRuleWithJson:paramRuleJson]; 69| 0| NSArray *rules = [FBSDKAEMConfiguration parseRules:[FBSDKTypeUtility dictionary:dict objectForKey:CONVERSION_RULES_KEY ofType:NSArray.class]]; 70| 0| if (!defaultCurrency || cutoffTime == nil || validFrom == nil || !configMode || 0 == rules.count) { 71| 0| return nil; 72| 0| } 73| | // Advertiser Config must have param rule 74| 0| if (businessID && !matchingRule) { 75| 0| return nil; 76| 0| } 77| 0| _defaultCurrency = defaultCurrency; 78| 0| _cutoffTime = cutoffTime.integerValue; 79| 0| _validFrom = validFrom.integerValue; 80| 0| _configMode = configMode; 81| 0| _businessID = businessID; 82| 0| _matchingRule = matchingRule; 83| 0| _conversionValueRules = rules; 84| 0| _eventSet = [FBSDKAEMConfiguration getEventSetFromRules:_conversionValueRules]; 85| 0| _currencySet = [FBSDKAEMConfiguration getCurrencySetFromRules:_conversionValueRules]; 86| 0| } @catch (NSException *exception) { 87| 0| return nil; 88| 0| } 89| 0| } 90| 0| return self; 91| 0|} 92| | 93| |- (instancetype)initWithDefaultCurrency:(NSString *)defaultCurrency 94| | cutoffTime:(NSInteger)cutoffTime 95| | validFrom:(NSInteger)validFrom 96| | configMode:(NSString *)configMode 97| | businessID:(nullable NSString *)businessID 98| | matchingRule:(id)matchingRule 99| | conversionValueRules:(NSArray *)conversionValueRules 100| 0|{ 101| 0| if ((self = [super init])) { 102| 0| _defaultCurrency = defaultCurrency; 103| 0| _cutoffTime = cutoffTime; 104| 0| _validFrom = validFrom; 105| 0| _configMode = configMode; 106| 0| _businessID = businessID; 107| 0| _matchingRule = matchingRule; 108| 0| _conversionValueRules = conversionValueRules; 109| 0| _eventSet = [FBSDKAEMConfiguration getEventSetFromRules:_conversionValueRules]; 110| 0| _currencySet = [FBSDKAEMConfiguration getCurrencySetFromRules:_conversionValueRules]; 111| 0| } 112| 0| return self; 113| 0|} 114| | 115| |+ (nullable NSArray *)parseRules:(nullable NSArray *> *)rules 116| 0|{ 117| 0| if (0 == rules.count) { 118| 0| return nil; 119| 0| } 120| 0| NSMutableArray *parsedRules = [NSMutableArray new]; 121| 0| for (NSDictionary *ruleEntry in rules) { 122| 0| FBSDKAEMRule *rule = [[FBSDKAEMRule alloc] initWithJSON:ruleEntry]; 123| 0| if (!rule) { 124| 0| return nil; 125| 0| } 126| 0| [FBSDKTypeUtility array:parsedRules addObject:rule]; 127| 0| } 128| | // Sort the rules in descending priority order 129| 0| [parsedRules sortUsingComparator:^NSComparisonResult (FBSDKAEMRule *obj1, FBSDKAEMRule *obj2) { 130| 0| if (obj1.priority < obj2.priority) { 131| 0| return NSOrderedDescending; 132| 0| } 133| 0| if (obj1.priority > obj2.priority) { 134| 0| return NSOrderedAscending; 135| 0| } 136| 0| return NSOrderedSame; 137| 0| }]; 138| 0| return [parsedRules copy]; 139| 0|} 140| | 141| |+ (NSSet *)getEventSetFromRules:(NSArray *)rules 142| 0|{ 143| 0| NSMutableSet *eventSet = [NSMutableSet new]; 144| 0| for (FBSDKAEMRule *rule in rules) { 145| 0| if (!rule) { 146| 0| continue; 147| 0| } 148| 0| for (FBSDKAEMEvent *event in rule.events) { 149| 0| if (event.eventName) { 150| 0| [eventSet addObject:event.eventName]; 151| 0| } 152| 0| } 153| 0| } 154| 0| return [eventSet copy]; 155| 0|} 156| | 157| |+ (NSSet *)getCurrencySetFromRules:(NSArray *)rules 158| 0|{ 159| 0| NSMutableSet *currencySet = [NSMutableSet new]; 160| 0| for (FBSDKAEMRule *rule in rules) { 161| 0| if (!rule) { 162| 0| continue; 163| 0| } 164| 0| for (FBSDKAEMEvent *event in rule.events) { 165| 0| for (NSString *currency in event.values) { 166| 0| [currencySet addObject:[currency uppercaseString]]; 167| 0| } 168| 0| } 169| 0| } 170| 0| return [currencySet copy]; 171| 0|} 172| | 173| |- (BOOL)isSameValidFrom:(NSInteger)validFrom 174| | businessID:(nullable NSString *)businessID 175| 0|{ 176| 0| return (_validFrom == validFrom) && [self isSameBusinessID:businessID]; 177| 0|} 178| | 179| |- (BOOL)isSameBusinessID:(nullable NSString *)businessID 180| 0|{ 181| 0| return (_businessID && [_businessID isEqualToString:businessID]) 182| 0| || (!_businessID && !businessID); 183| 0|} 184| | 185| | #pragma mark - NSCoding 186| | 187| |+ (BOOL)supportsSecureCoding 188| 0|{ 189| 0| return YES; 190| 0|} 191| | 192| |- (instancetype)initWithCoder:(NSCoder *)decoder 193| 0|{ 194| 0| NSString *defaultCurrency = [decoder decodeObjectOfClass:NSString.class forKey:DEFAULT_CURRENCY_KEY]; 195| 0| NSInteger cutoffTime = [decoder decodeIntegerForKey:CUTOFF_TIME_KEY]; 196| 0| NSInteger validFrom = [decoder decodeIntegerForKey:VALID_FROM_KEY]; 197| 0| NSString *configMode = [decoder decodeObjectOfClass:NSString.class forKey:CONFIG_MODE_KEY]; 198| 0| NSString *businessID = [decoder decodeObjectOfClass:NSString.class forKey:BUSINESS_ID_KEY]; 199| 0| NSSet *matchingRuleClasses = [NSSet setWithArray:@[NSArray.class, FBSDKAEMAdvertiserMultiEntryRule.class, FBSDKAEMAdvertiserSingleEntryRule.class]]; 200| 0| id matchingRule = [decoder decodeObjectOfClasses:matchingRuleClasses forKey:PARAM_RULE_KEY]; 201| 0| NSArray *rules = [decoder decodeObjectOfClasses:[NSSet setWithArray:@[NSArray.class, FBSDKAEMRule.class, FBSDKAEMEvent.class]] forKey:CONVERSION_RULES_KEY]; 202| 0| return [self initWithDefaultCurrency:defaultCurrency 203| 0| cutoffTime:cutoffTime 204| 0| validFrom:validFrom 205| 0| configMode:configMode 206| 0| businessID:businessID 207| 0| matchingRule:matchingRule 208| 0| conversionValueRules:rules]; 209| 0|} 210| | 211| |- (void)encodeWithCoder:(NSCoder *)encoder 212| 0|{ 213| 0| [encoder encodeObject:_defaultCurrency forKey:DEFAULT_CURRENCY_KEY]; 214| 0| [encoder encodeInteger:_cutoffTime forKey:CUTOFF_TIME_KEY]; 215| 0| [encoder encodeInteger:_validFrom forKey:VALID_FROM_KEY]; 216| 0| [encoder encodeObject:_configMode forKey:CONFIG_MODE_KEY]; 217| 0| [encoder encodeObject:_businessID forKey:BUSINESS_ID_KEY]; 218| 0| [encoder encodeObject:_matchingRule forKey:PARAM_RULE_KEY]; 219| 0| [encoder encodeObject:_conversionValueRules forKey:CONVERSION_RULES_KEY]; 220| 0|} 221| | 222| | #pragma mark - NSCopying 223| | 224| |- (instancetype)copyWithZone:(NSZone *)zone 225| 0|{ 226| 0| return self; 227| 0|} 228| | 229| |@end 230| | 231| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMEvent.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKAEMEvent.h" 24| | 25| | #import "FBSDKCoreKitBasicsImport.h" 26| | 27| |static NSString *const EVENT_NAME_KEY = @"event_name"; 28| |static NSString *const VALUES_KEY = @"values"; 29| |static NSString *const CURRENCY_KEY = @"currency"; 30| |static NSString *const AMOUNT_KEY = @"amount"; 31| | 32| |@implementation FBSDKAEMEvent 33| | 34| |- (nullable instancetype)initWithJSON:(nullable NSDictionary *)dict 35| 0|{ 36| 0| if ((self = [super init])) { 37| 0| dict = [FBSDKTypeUtility dictionaryValue:dict]; 38| 0| if (!dict) { 39| 0| return nil; 40| 0| } 41| 0| _eventName = [FBSDKTypeUtility dictionary:dict objectForKey:EVENT_NAME_KEY ofType:NSString.class]; 42| | // Event name is a required field 43| 0| if (!_eventName) { 44| 0| return nil; 45| 0| } 46| | // Values is an optional field 47| 0| NSArray *> *valueEntries = [FBSDKTypeUtility dictionary:dict objectForKey:VALUES_KEY ofType:NSArray.class]; 48| 0| if (valueEntries.count > 0) { 49| 0| NSMutableDictionary *valueDict = [NSMutableDictionary new]; 50| 0| for (NSDictionary *valueEntry in valueEntries) { 51| 0| NSDictionary *value = [FBSDKTypeUtility dictionaryValue:valueEntry]; 52| 0| NSString *currency = [FBSDKTypeUtility dictionary:value objectForKey:CURRENCY_KEY ofType:NSString.class]; 53| 0| NSNumber *amount = [FBSDKTypeUtility dictionary:value objectForKey:AMOUNT_KEY ofType:NSNumber.class]; 54| 0| if (!currency || amount == nil) { 55| 0| return nil; 56| 0| } 57| 0| [FBSDKTypeUtility dictionary:valueDict setObject:amount forKey:[currency uppercaseString]]; 58| 0| } 59| 0| _values = [valueDict copy]; 60| 0| } 61| 0| } 62| 0| return self; 63| 0|} 64| | 65| |- (instancetype)initWithEventName:(NSString *)eventName 66| | values:(NSDictionary *)values 67| 0|{ 68| 0| if ((self = [super init])) { 69| 0| _eventName = eventName; 70| 0| _values = values; 71| 0| } 72| 0| return self; 73| 0|} 74| | 75| | #pragma mark - NSCoding 76| | 77| |+ (BOOL)supportsSecureCoding 78| 0|{ 79| 0| return YES; 80| 0|} 81| | 82| |- (instancetype)initWithCoder:(NSCoder *)decoder 83| 0|{ 84| 0| NSString *eventName = [decoder decodeObjectOfClass:NSString.class forKey:EVENT_NAME_KEY]; 85| 0| NSDictionary *values = [decoder decodeObjectOfClass:NSDictionary.class forKey:VALUES_KEY]; 86| 0| return [self initWithEventName:eventName values:values]; 87| 0|} 88| | 89| |- (void)encodeWithCoder:(NSCoder *)encoder 90| 0|{ 91| 0| [encoder encodeObject:_eventName forKey:EVENT_NAME_KEY]; 92| 0| if (_values) { 93| 0| [encoder encodeObject:_values forKey:VALUES_KEY]; 94| 0| } 95| 0|} 96| | 97| | #pragma mark - NSCopying 98| | 99| |- (instancetype)copyWithZone:(NSZone *)zone 100| 0|{ 101| 0| return self; 102| 0|} 103| | 104| |@end 105| | 106| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMInvocation.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKAEMInvocation.h" 24| | 25| | #import 26| | 27| | #import "FBSDKCoreKitBasicsImport.h" 28| | 29| 0| #define SEC_IN_DAY 86400 30| | 31| |static NSString *const CAMPAIGN_ID_KEY = @"campaign_ids"; 32| |static NSString *const ACS_TOKEN_KEY = @"acs_token"; 33| |static NSString *const ACS_SHARED_SECRET_KEY = @"shared_secret"; 34| |static NSString *const ACS_CONFIG_ID_KEY = @"acs_config_id"; 35| |static NSString *const BUSINESS_ID_KEY = @"advertiser_id"; 36| |static NSString *const TIMESTAMP_KEY = @"timestamp"; 37| |static NSString *const CONFIG_MODE_KEY = @"config_mode"; 38| |static NSString *const CONFIG_ID_KEY = @"config_id"; 39| |static NSString *const RECORDED_EVENTS_KEY = @"recorded_events"; 40| |static NSString *const RECORDED_VALUES_KEY = @"recorded_values"; 41| |static NSString *const CONVERSION_VALUE_KEY = @"conversion_value"; 42| |static NSString *const PRIORITY_KEY = @"priority"; 43| |static NSString *const CONVERSION_TIMESTAMP_KEY = @"conversion_timestamp"; 44| |static NSString *const IS_AGGREGATED_KEY = @"is_aggregated"; 45| | 46| |typedef NSString *const FBSDKAEMInvocationConfigMode; 47| | 48| |FBSDKAEMInvocationConfigMode FBSDKAEMInvocationConfigDefaultMode = @"DEFAULT"; 49| |FBSDKAEMInvocationConfigMode FBSDKAEMInvocationConfigBrandMode = @"BRAND"; 50| | 51| |@implementation FBSDKAEMInvocation 52| | 53| |+ (nullable instancetype)invocationWithAppLinkData:(nullable NSDictionary *)applinkData 54| 0|{ 55| 0| @try { 56| 0| applinkData = [FBSDKTypeUtility dictionaryValue:applinkData]; 57| 0| if (!applinkData) { 58| 0| return nil; 59| 0| } 60| | 61| 0| NSString *campaignID = [FBSDKTypeUtility dictionary:applinkData objectForKey:CAMPAIGN_ID_KEY ofType:NSString.class]; 62| 0| NSString *ACSToken = [FBSDKTypeUtility dictionary:applinkData objectForKey:ACS_TOKEN_KEY ofType:NSString.class]; 63| 0| NSString *ACSSharedSecret = [FBSDKTypeUtility dictionary:applinkData objectForKey:ACS_SHARED_SECRET_KEY ofType:NSString.class]; 64| 0| NSString *ACSConfigID = [FBSDKTypeUtility dictionary:applinkData objectForKey:CONFIG_ID_KEY ofType:NSString.class]; 65| 0| NSString *businessID = [FBSDKTypeUtility dictionary:applinkData objectForKey:BUSINESS_ID_KEY ofType:NSString.class]; 66| 0| if (campaignID == nil || ACSToken == nil) { 67| 0| return nil; 68| 0| } 69| 0| return [[FBSDKAEMInvocation alloc] initWithCampaignID:campaignID 70| 0| ACSToken:ACSToken 71| 0| ACSSharedSecret:ACSSharedSecret 72| 0| ACSConfigID:ACSConfigID 73| 0| businessID:businessID]; 74| 0| } @catch (NSException *exception) { 75| 0| return nil; 76| 0| } 77| 0|} 78| | 79| |- (nullable instancetype)initWithCampaignID:(NSString *)campaignID 80| | ACSToken:(NSString *)ACSToken 81| | ACSSharedSecret:(nullable NSString *)ACSSharedSecret 82| | ACSConfigID:(nullable NSString *)ACSConfigID 83| | businessID:(nullable NSString *)businessID 84| 0|{ 85| 0| return [self initWithCampaignID:campaignID 86| 0| ACSToken:ACSToken 87| 0| ACSSharedSecret:ACSSharedSecret 88| 0| ACSConfigID:ACSConfigID 89| 0| businessID:businessID 90| 0| timestamp:nil 91| 0| configMode:nil 92| 0| configID:-1 93| 0| recordedEvents:nil 94| 0| recordedValues:nil 95| 0| conversionValue:-1 96| 0| priority:-1 97| 0| conversionTimestamp:nil 98| 0| isAggregated:YES]; 99| 0|} 100| | 101| |- (nullable instancetype)initWithCampaignID:(NSString *)campaignID 102| | ACSToken:(NSString *)ACSToken 103| | ACSSharedSecret:(nullable NSString *)ACSSharedSecret 104| | ACSConfigID:(nullable NSString *)ACSConfigID 105| | businessID:(nullable NSString *)businessID 106| | timestamp:(nullable NSDate *)timestamp 107| | configMode:(nullable NSString *)configMode 108| | configID:(NSInteger)configID 109| | recordedEvents:(nullable NSMutableSet *)recordedEvents 110| | recordedValues:(nullable NSMutableDictionary *)recordedValues 111| | conversionValue:(NSInteger)conversionValue 112| | priority:(NSInteger)priority 113| | conversionTimestamp:(nullable NSDate *)conversionTimestamp 114| | isAggregated:(BOOL)isAggregated 115| 0|{ 116| 0| if ((self = [super init])) { 117| 0| _campaignID = campaignID; 118| 0| _ACSToken = ACSToken; 119| 0| _ACSSharedSecret = ACSSharedSecret; 120| 0| _ACSConfigID = ACSConfigID; 121| 0| _businessID = businessID; 122| 0| if ([timestamp isKindOfClass:NSDate.class]) { 123| 0| _timestamp = timestamp; 124| 0| } else { 125| 0| _timestamp = [NSDate date]; 126| 0| } 127| 0| _configMode = configMode; 128| 0| _configID = configID; 129| 0| if ([recordedEvents isKindOfClass:NSMutableSet.class]) { 130| 0| _recordedEvents = recordedEvents; 131| 0| } else { 132| 0| _recordedEvents = [NSMutableSet new]; 133| 0| } 134| 0| if ([recordedValues isKindOfClass:NSMutableDictionary.class]) { 135| 0| _recordedValues = recordedValues; 136| 0| } else { 137| 0| _recordedValues = [NSMutableDictionary new]; 138| 0| } 139| 0| _conversionValue = conversionValue; 140| 0| _priority = priority; 141| 0| _conversionTimestamp = conversionTimestamp; 142| 0| _isAggregated = isAggregated; 143| 0| } 144| 0| return self; 145| 0|} 146| | 147| |- (BOOL)attributeEvent:(NSString *)event 148| | currency:(nullable NSString *)currency 149| | value:(nullable NSNumber *)value 150| | parameters:(nullable NSDictionary *)parameters 151| | configs:(nullable NSDictionary *> *)configs 152| 0|{ 153| 0| FBSDKAEMConfiguration *config = [self _findConfig:configs]; 154| 0| if ([self _isOutOfWindowWithConfig:config] || ![config.eventSet containsObject:event]) { 155| 0| return NO; 156| 0| } 157| | // Check advertiser rule matching 158| 0| if (config.matchingRule && ![config.matchingRule isMatchedEventParameters:parameters]) { 159| 0| return NO; 160| 0| } 161| 0| BOOL isAttributed = NO; 162| 0| if (![_recordedEvents containsObject:event]) { 163| 0| [_recordedEvents addObject:event]; 164| 0| isAttributed = YES; 165| 0| } 166| | // Change currency to default currency if currency is not found in currencySet 167| 0| NSString *valueCurrency = [currency uppercaseString]; 168| 0| if (![config.currencySet containsObject:valueCurrency]) { 169| 0| valueCurrency = config.defaultCurrency; 170| 0| } 171| 0| if (value != nil) { 172| 0| NSMutableDictionary *mapping = [[FBSDKTypeUtility dictionary:_recordedValues objectForKey:event ofType:NSDictionary.class] mutableCopy] ?: [NSMutableDictionary new]; 173| 0| NSNumber *valueInMapping = [FBSDKTypeUtility dictionary:mapping objectForKey:valueCurrency ofType:NSNumber.class] ?: [NSNumber numberWithDouble:0]; 174| | // Overwrite values when the incoming event's value is greater than the cached one 175| 0| if (value.doubleValue > valueInMapping.doubleValue) { 176| 0| [FBSDKTypeUtility dictionary:mapping setObject:[NSNumber numberWithDouble:value.doubleValue] forKey:valueCurrency]; 177| 0| [FBSDKTypeUtility dictionary:_recordedValues setObject:mapping forKey:event]; 178| 0| isAttributed = YES; 179| 0| } 180| 0| } 181| 0| return isAttributed; 182| 0|} 183| | 184| |- (BOOL)updateConversionValueWithConfigs:(nullable NSDictionary *> *)configs 185| 0|{ 186| 0| FBSDKAEMConfiguration *config = [self _findConfig:configs]; 187| 0| if (!config) { 188| 0| return NO; 189| 0| } 190| | // Update conversion value if a rule is matched 191| 0| for (FBSDKAEMRule *rule in config.conversionValueRules) { 192| 0| if (rule.priority <= _priority) { 193| 0| break; 194| 0| } 195| 0| if ([rule isMatchedWithRecordedEvents:_recordedEvents recordedValues:_recordedValues]) { 196| 0| _conversionValue = rule.conversionValue; 197| 0| _priority = rule.priority; 198| 0| _conversionTimestamp = [NSDate date]; 199| 0| _isAggregated = NO; 200| 0| return YES; 201| 0| } 202| 0| } 203| 0| return NO; 204| 0|} 205| | 206| |- (BOOL)isOutOfWindowWithConfigs:(nullable NSDictionary *> *)configs 207| 0|{ 208| 0| FBSDKAEMConfiguration *config = [self _findConfig:configs]; 209| 0| return [self _isOutOfWindowWithConfig:config]; 210| 0|} 211| | 212| |- (nullable NSString *)getHMAC:(NSInteger)delay 213| 0|{ 214| 0| if (!_ACSSharedSecret || !_ACSConfigID) { 215| 0| return nil; 216| 0| } 217| 0| @try { 218| 0| NSData *secretData = [self decodeBase64UrlSafeString:_ACSSharedSecret]; 219| 0| if (!secretData) { 220| 0| return nil; 221| 0| } 222| 0| NSMutableData *hmac = [NSMutableData dataWithLength:CC_SHA512_DIGEST_LENGTH]; 223| 0| NSString *text = [NSString stringWithFormat:@"%@|%@|%@|%@", _campaignID, @(_conversionValue), @(delay), @"server"]; 224| 0| NSData *clearTextData = [text dataUsingEncoding:NSUTF8StringEncoding]; 225| 0| CCHmac(kCCHmacAlgSHA512, [secretData bytes], [secretData length], [clearTextData bytes], [clearTextData length], hmac.mutableBytes); 226| 0| NSString *base64UrlSafeString = [hmac base64EncodedStringWithOptions:0]; 227| 0| base64UrlSafeString = [base64UrlSafeString stringByReplacingOccurrencesOfString:@"/" 228| 0| withString:@"_"]; 229| 0| base64UrlSafeString = [base64UrlSafeString stringByReplacingOccurrencesOfString:@"+" 230| 0| withString:@"-"]; 231| 0| base64UrlSafeString = [base64UrlSafeString stringByReplacingOccurrencesOfString:@"=" 232| 0| withString:@""]; 233| 0| return base64UrlSafeString; 234| 0| } @catch (NSException *exception) { 235| 0| return nil; 236| 0| } 237| 0|} 238| | 239| |- (nullable NSData *)decodeBase64UrlSafeString:(NSString *)base64UrlSafeString 240| 0|{ 241| 0| if (!base64UrlSafeString.length) { 242| 0| return nil; 243| 0| } 244| 0| NSString *base64String = [base64UrlSafeString stringByReplacingOccurrencesOfString:@"-" withString:@"+"]; 245| 0| base64String = [base64String stringByReplacingOccurrencesOfString:@"_" withString:@"/"]; 246| 0| base64String = [base64String stringByReplacingOccurrencesOfString:@"-" withString:@"+"]; 247| 0| NSString *padding = [@"" stringByPaddingToLength:(4 - base64String.length % 4) withString:@"=" startingAtIndex:0]; 248| 0| base64String = [base64String stringByAppendingString:padding]; 249| 0| NSData *decodedData = [[NSData alloc] initWithBase64EncodedString:base64String options:0]; 250| 0| return decodedData; 251| 0|} 252| | 253| |- (BOOL)_isOutOfWindowWithConfig:(nullable FBSDKAEMConfiguration *)config 254| 0|{ 255| 0| if (!config) { 256| 0| return true; 257| 0| } 258| 0| BOOL isCutoff = [[NSDate date] timeIntervalSinceDate:_timestamp] > config.cutoffTime * SEC_IN_DAY; 259| 0| BOOL isOverLastConversionWindow = _conversionTimestamp && [[NSDate date] timeIntervalSinceDate:_conversionTimestamp] > SEC_IN_DAY; 260| 0| return isCutoff || isOverLastConversionWindow; 261| 0|} 262| | 263| |- (nullable FBSDKAEMConfiguration *)_findConfig:(nullable NSDictionary *> *)configs 264| 0|{ 265| 0| NSString *configMode = _businessID ? FBSDKAEMInvocationConfigBrandMode : FBSDKAEMInvocationConfigDefaultMode; 266| 0| NSArray *configList = [FBSDKTypeUtility dictionary:configs objectForKey:configMode ofType:NSArray.class]; 267| 0| if (0 == configList.count) { 268| 0| return nil; 269| 0| } 270| 0| if (_configID > 0) { 271| 0| for (FBSDKAEMConfiguration *config in configList) { 272| 0| if ([config isSameValidFrom:_configID businessID:_businessID]) { 273| 0| return config; 274| 0| } 275| 0| } 276| 0| return nil; 277| 0| } else { 278| 0| FBSDKAEMConfiguration *config = nil; 279| 0| for (FBSDKAEMConfiguration *c in [configList reverseObjectEnumerator]) { 280| 0| if (c.validFrom <= _timestamp.timeIntervalSince1970 && [c isSameBusinessID:_businessID]) { 281| 0| config = c; 282| 0| break; 283| 0| } 284| 0| } 285| 0| if (!config) { 286| 0| return nil; 287| 0| } 288| 0| [self _setConfig:config]; 289| 0| return config; 290| 0| } 291| 0|} 292| | 293| |- (void)_setConfig:(FBSDKAEMConfiguration *)config 294| 0|{ 295| 0| _configID = config.validFrom; 296| 0| _configMode = config.configMode; 297| 0|} 298| | 299| | #pragma mark - NSCoding 300| | 301| |+ (BOOL)supportsSecureCoding 302| 0|{ 303| 0| return YES; 304| 0|} 305| | 306| |- (instancetype)initWithCoder:(NSCoder *)decoder 307| 0|{ 308| 0| NSString *campaignID = [decoder decodeObjectOfClass:NSString.class forKey:CAMPAIGN_ID_KEY]; 309| 0| NSString *ACSToken = [decoder decodeObjectOfClass:NSString.class forKey:ACS_TOKEN_KEY]; 310| 0| NSString *ACSSharedSecret = [decoder decodeObjectOfClass:NSString.class forKey:ACS_SHARED_SECRET_KEY]; 311| 0| NSString *ACSConfigID = [decoder decodeObjectOfClass:NSString.class forKey:ACS_CONFIG_ID_KEY]; 312| 0| NSString *businessID = [decoder decodeObjectOfClass:NSString.class forKey:BUSINESS_ID_KEY]; 313| 0| NSDate *timestamp = [decoder decodeObjectOfClass:NSDate.class forKey:TIMESTAMP_KEY]; 314| 0| NSString *configMode = [decoder decodeObjectOfClass:NSString.class forKey:CONFIG_MODE_KEY]; 315| 0| NSInteger configID = [decoder decodeIntegerForKey:CONFIG_ID_KEY]; 316| 0| NSMutableSet *recordedEvents = [decoder decodeObjectOfClass:NSMutableSet.class forKey:RECORDED_EVENTS_KEY]; 317| 0| NSMutableDictionary *recordedValues = [decoder decodeObjectOfClass:NSMutableDictionary.class forKey:RECORDED_VALUES_KEY]; 318| 0| NSInteger conversionValue = [decoder decodeIntegerForKey:CONVERSION_VALUE_KEY]; 319| 0| NSInteger priority = [decoder decodeIntegerForKey:PRIORITY_KEY]; 320| 0| NSDate *conversionTimestamp = [decoder decodeObjectOfClass:NSDate.class forKey:CONVERSION_TIMESTAMP_KEY]; 321| 0| BOOL isAggregated = [decoder decodeBoolForKey:IS_AGGREGATED_KEY]; 322| 0| return [self initWithCampaignID:campaignID 323| 0| ACSToken:ACSToken 324| 0| ACSSharedSecret:ACSSharedSecret 325| 0| ACSConfigID:ACSConfigID 326| 0| businessID:businessID 327| 0| timestamp:timestamp 328| 0| configMode:configMode 329| 0| configID:configID 330| 0| recordedEvents:recordedEvents 331| 0| recordedValues:recordedValues 332| 0| conversionValue:conversionValue 333| 0| priority:priority 334| 0| conversionTimestamp:conversionTimestamp 335| 0| isAggregated:isAggregated]; 336| 0|} 337| | 338| |- (void)encodeWithCoder:(NSCoder *)encoder 339| 0|{ 340| 0| [encoder encodeObject:_campaignID forKey:CAMPAIGN_ID_KEY]; 341| 0| [encoder encodeObject:_ACSToken forKey:ACS_TOKEN_KEY]; 342| 0| [encoder encodeObject:_ACSSharedSecret forKey:ACS_SHARED_SECRET_KEY]; 343| 0| [encoder encodeObject:_ACSConfigID forKey:ACS_CONFIG_ID_KEY]; 344| 0| [encoder encodeObject:_businessID forKey:BUSINESS_ID_KEY]; 345| 0| [encoder encodeObject:_timestamp forKey:TIMESTAMP_KEY]; 346| 0| [encoder encodeObject:_configMode forKey:CONFIG_MODE_KEY]; 347| 0| [encoder encodeInteger:_configID forKey:CONFIG_ID_KEY]; 348| 0| [encoder encodeObject:_recordedEvents forKey:RECORDED_EVENTS_KEY]; 349| 0| [encoder encodeObject:_recordedValues forKey:RECORDED_VALUES_KEY]; 350| 0| [encoder encodeInteger:_conversionValue forKey:CONVERSION_VALUE_KEY]; 351| 0| [encoder encodeInteger:_priority forKey:PRIORITY_KEY]; 352| 0| [encoder encodeObject:_conversionTimestamp forKey:CONVERSION_TIMESTAMP_KEY]; 353| 0| [encoder encodeBool:_isAggregated forKey:IS_AGGREGATED_KEY]; 354| 0|} 355| | 356| | #pragma mark - NSCopying 357| | 358| |- (instancetype)copyWithZone:(NSZone *)zone 359| 0|{ 360| 0| return self; 361| 0|} 362| | 363| | #if DEBUG 364| | #if FBSDKTEST 365| | 366| |- (void)setRecordedEvents:(NSMutableSet *)recordedEvents 367| 0|{ 368| 0| _recordedEvents = recordedEvents; 369| 0|} 370| | 371| |- (void)setRecordedValues:(NSMutableDictionary *)recordedValues 372| 0|{ 373| 0| _recordedValues = recordedValues; 374| 0|} 375| | 376| |- (void)setPriority:(NSInteger)priority 377| 0|{ 378| 0| _priority = priority; 379| 0|} 380| | 381| |- (void)setConfigID:(NSInteger)configID 382| 0|{ 383| 0| _configID = configID; 384| 0|} 385| | 386| |- (void)setBusinessID:(NSString *_Nullable)businessID 387| 0|{ 388| 0| _businessID = businessID; 389| 0|} 390| | 391| |- (void)setConversionTimestamp:(NSDate *_Nonnull)conversionTimestamp 392| 0|{ 393| 0| _conversionTimestamp = conversionTimestamp; 394| 0|} 395| | 396| |- (void)setConversionValue:(NSInteger)conversionValue 397| 0|{ 398| 0| _conversionValue = conversionValue; 399| 0|} 400| | 401| |- (void)setCampaignID:(NSString *_Nonnull)campaignID 402| 0|{ 403| 0| _campaignID = campaignID; 404| 0|} 405| | 406| |- (void)setACSSharedSecret:(NSString *_Nullable)ACSSharedSecret 407| 0|{ 408| 0| _ACSSharedSecret = ACSSharedSecret; 409| 0|} 410| | 411| |- (void)setACSConfigID:(NSString *_Nullable)ACSConfigID 412| 0|{ 413| 0| _ACSConfigID = ACSConfigID; 414| 0|} 415| | 416| |- (void)reset 417| 0|{ 418| 0| _timestamp = [NSDate date]; 419| 0| _configMode = @"DEFAULT"; 420| 0| _configID = -1; 421| 0| _businessID = nil; 422| 0| _recordedEvents = [NSMutableSet new]; 423| 0| _recordedValues = [NSMutableDictionary new]; 424| 0| _conversionValue = -1; 425| 0| _priority = -1; 426| 0| _conversionTimestamp = [NSDate date]; 427| 0| _isAggregated = YES; 428| 0|} 429| | 430| | #endif 431| | #endif 432| | 433| |@end 434| | 435| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMReporter.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKAEMReporter.h" 24| | 25| | #include 26| | 27| | #import "FBSDKAEMAdvertiserRuleFactory.h" 28| | #import "FBSDKAEMConfiguration.h" 29| | #import "FBSDKAEMInvocation.h" 30| | #import "FBSDKCoreKitBasicsImport.h" 31| | #import "FBSDKGraphRequestProtocol.h" 32| | #import "FBSDKGraphRequestProviding.h" 33| | #import "FBSDKLogger.h" 34| | #import "FBSDKSettings.h" 35| | 36| 0| #define FBSDK_AEM_CONFIG_TIME_OUT 86400 37| | 38| |typedef void (^FBSDKAEMReporterBlock)(NSError *); 39| | 40| |static NSString *const BUSINESS_ID_KEY = @"advertiser_id"; 41| |static NSString *const BUSINESS_IDS_KEY = @"advertiser_ids"; 42| |static NSString *const AL_APPLINK_DATA_KEY = @"al_applink_data"; 43| |static NSString *const CAMPAIGN_ID_KEY = @"campaign_id"; 44| |static NSString *const CONVERSION_DATA_KEY = @"conversion_data"; 45| |static NSString *const CONSUMPTION_HOUR_KEY = @"consumption_hour"; 46| |static NSString *const TOKEN_KEY = @"token"; 47| |static NSString *const HMAC_KEY = @"hmac"; 48| |static NSString *const CONFIG_ID_KEY = @"config_id"; 49| |static NSString *const DELAY_FLOW_KEY = @"delay_flow"; 50| | 51| |static NSString *const FBSDKAEMConfigurationKey = @"com.facebook.sdk:FBSDKAEMConfiguration"; 52| |static NSString *const FBSDKAEMReporterKey = @"com.facebook.sdk:FBSDKAEMReporter"; 53| |static NSString *const FBSDKAEMReporterFileName = @"FBSDKAEMReportData.report"; 54| |static NSString *const FBSDKAEMConfigFileName = @"FBSDKAEMReportData.config"; 55| | 56| |static BOOL g_isAEMReportEnabled = NO; 57| |static BOOL g_isLoadingConfiguration = NO; 58| |static dispatch_queue_t g_serialQueue; 59| |static NSString *g_reportFile; 60| |static NSString *g_configFile; 61| |static NSMutableDictionary *> *g_configs; 62| |static NSMutableArray *g_invocations; 63| |static NSDate *g_configRefreshTimestamp; 64| |static NSMutableArray *g_completionBlocks; 65| |static id _requestProvider; 66| | 67| |@implementation FBSDKAEMReporter 68| | 69| |static char *const dispatchQueueLabel = "com.facebook.appevents.AEM.FBSDKAEMReporter"; 70| | 71| |+ (void)configureWithRequestProvider:(id)requestProvider 72| 0|{ 73| 0| if (self == [FBSDKAEMReporter class]) { 74| 0| _requestProvider = requestProvider; 75| 0| } 76| 0|} 77| | 78| |+ (id)requestProvider 79| 0|{ 80| 0| return _requestProvider; 81| 0|} 82| | 83| |+ (void)enable 84| 0|{ 85| 0| if (@available(iOS 14.0, *)) { 86| 0| static dispatch_once_t onceToken; 87| 0| dispatch_once(&onceToken, ^{ 88| 0| [FBSDKAEMConfiguration configureWithRuleProvider:[FBSDKAEMAdvertiserRuleFactory new]]; 89| 0| g_reportFile = [FBSDKBasicUtility persistenceFilePath:FBSDKAEMReporterFileName]; 90| 0| g_configFile = [FBSDKBasicUtility persistenceFilePath:FBSDKAEMConfigFileName]; 91| 0| g_completionBlocks = [NSMutableArray new]; 92| 0| if (!g_serialQueue) { 93| 0| g_serialQueue = dispatch_queue_create(dispatchQueueLabel, DISPATCH_QUEUE_SERIAL); 94| 0| } 95| 0| [self dispatchOnQueue:g_serialQueue block:^() { 96| 0| g_configs = [self _loadConfigs]; 97| 0| g_invocations = [self _loadReportData]; 98| 0| }]; 99| 0| [self _loadConfigurationWithBlock:^(NSError *error) { 100| 0| if (error) { 101| 0| return; 102| 0| } 103| 0| [self _sendAggregationRequest]; 104| 0| [self _clearCache]; 105| 0| }]; 106| 0| g_isAEMReportEnabled = YES; 107| 0| }); 108| 0| } 109| 0|} 110| | 111| |+ (void)handleURL:(NSURL *)url 112| 0|{ 113| 0| if (!g_isAEMReportEnabled) { 114| 0| return; 115| 0| } 116| | 117| 0| FBSDKAEMInvocation *invocation = [self parseURL:url]; 118| 0| if (!invocation) { 119| 0| return; 120| 0| } 121| | 122| 0| [self _appendAndSaveInvocation:invocation]; 123| 0|} 124| | 125| |+ (nullable FBSDKAEMInvocation *)parseURL:(NSURL *)url 126| 0|{ 127| 0| if (!url) { 128| 0| return nil; 129| 0| } 130| | 131| 0| NSDictionary *params = [FBSDKBasicUtility dictionaryWithQueryString:url.query]; 132| 0| NSString *applinkDataString = params[AL_APPLINK_DATA_KEY]; 133| 0| if (!applinkDataString) { 134| 0| return nil; 135| 0| } 136| | 137| 0| NSDictionary *applinkData = [FBSDKTypeUtility dictionaryValue:[FBSDKBasicUtility objectForJSONString:applinkDataString error:NULL]]; 138| 0| if (!applinkData) { 139| 0| return nil; 140| 0| } 141| | 142| 0| return [FBSDKAEMInvocation invocationWithAppLinkData:applinkData]; 143| 0|} 144| | 145| |+ (void)recordAndUpdateEvent:(NSString *)event 146| | currency:(nullable NSString *)currency 147| | value:(nullable NSNumber *)value 148| | parameters:(nullable NSDictionary *)parameters 149| 0|{ 150| 0| if (@available(iOS 14.0, *)) { 151| 0| if (!g_isAEMReportEnabled || 0 == event.length) { 152| 0| return; 153| 0| } 154| 0| [self _loadConfigurationWithBlock:^(NSError *error) { 155| 0| if (0 == g_configs.count || 0 == g_invocations.count) { 156| 0| return; 157| 0| } 158| | 159| 0| FBSDKAEMInvocation *attributedInvocation = [self _attributedInvocation:g_invocations Event:event currency:currency value:value parameters:parameters configs:g_configs]; 160| 0| if (attributedInvocation) { 161| 0| if ([attributedInvocation updateConversionValueWithConfigs:g_configs]) { 162| 0| [self _sendAggregationRequest]; 163| 0| } 164| 0| [self _saveReportData]; 165| 0| } 166| 0| }]; 167| 0| } 168| 0|} 169| | 170| |+ (nullable FBSDKAEMInvocation *)_attributedInvocation:(NSArray *)invocations 171| | Event:(NSString *)event 172| | currency:(nullable NSString *)currency 173| | value:(nullable NSNumber *)value 174| | parameters:(nullable NSDictionary *)parameters 175| | configs:(NSDictionary *> *)configs 176| 0|{ 177| 0| BOOL isGeneralInvocationVisited = NO; 178| 0| FBSDKAEMInvocation *attributedInvocation = nil; 179| 0| for (FBSDKAEMInvocation *invocation in [invocations reverseObjectEnumerator]) { 180| 0| if (!invocation.businessID && isGeneralInvocationVisited) { 181| 0| continue; 182| 0| } 183| | 184| 0| if ([invocation attributeEvent:event currency:currency value:value parameters:parameters configs:configs]) { 185| 0| attributedInvocation = invocation; 186| 0| break; 187| 0| } 188| 0| if (!invocation.businessID) { 189| 0| isGeneralInvocationVisited = YES; 190| 0| } 191| 0| } 192| 0| return attributedInvocation; 193| 0|} 194| | 195| |+ (void)_appendAndSaveInvocation:(FBSDKAEMInvocation *)invocation 196| 0|{ 197| 0| [self dispatchOnQueue:g_serialQueue block:^() { 198| 0| [FBSDKTypeUtility array:g_invocations addObject:invocation]; 199| 0| [self _saveReportData]; 200| 0| }]; 201| 0|} 202| | 203| |+ (void)_loadConfigurationWithBlock:(FBSDKAEMReporterBlock)block 204| 0|{ 205| 0| [self dispatchOnQueue:g_serialQueue block:^() { 206| 0| [FBSDKTypeUtility array:g_completionBlocks addObject:block]; 207| | // Executes blocks if there is cache 208| 0| if (![self _shouldRefresh]) { 209| 0| for (FBSDKAEMReporterBlock executionBlock in g_completionBlocks) { 210| 0| executionBlock(nil); 211| 0| } 212| 0| [g_completionBlocks removeAllObjects]; 213| 0| return; 214| 0| } 215| 0| if (g_isLoadingConfiguration) { 216| 0| return; 217| 0| } 218| 0| g_isLoadingConfiguration = YES; 219| 0| id request = [self.requestProvider createGraphRequestWithGraphPath:[NSString stringWithFormat:@"%@/aem_conversion_configs", [FBSDKSettings appID]] 220| 0| parameters:[self _requestParameters] 221| 0| tokenString:nil 222| 0| HTTPMethod:FBSDKHTTPMethodGET 223| 0| flags:FBSDKGraphRequestFlagSkipClientToken | FBSDKGraphRequestFlagDisableErrorRecovery]; 224| 0| [request startWithCompletion:^(id connection, id result, NSError *error) { 225| 0| [self dispatchOnQueue:g_serialQueue block:^() { 226| 0| if (error) { 227| 0| for (FBSDKAEMReporterBlock executionBlock in g_completionBlocks) { 228| 0| executionBlock(error); 229| 0| } 230| 0| [g_completionBlocks removeAllObjects]; 231| 0| g_isLoadingConfiguration = NO; 232| 0| return; 233| 0| } 234| 0| NSDictionary *json = [FBSDKTypeUtility dictionaryValue:result]; 235| 0| if (json) { 236| 0| g_configRefreshTimestamp = [NSDate date]; 237| 0| [self _addConfigs:[FBSDKTypeUtility dictionary:json objectForKey:@"data" ofType:NSArray.class]]; 238| 0| for (FBSDKAEMReporterBlock executionBlock in g_completionBlocks) { 239| 0| executionBlock(nil); 240| 0| } 241| 0| [g_completionBlocks removeAllObjects]; 242| 0| } else { 243| 0| [FBSDKLogger singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors logEntry:@"Received invalid AEM config"]; 244| 0| } 245| 0| g_isLoadingConfiguration = NO; 246| 0| }]; 247| 0| }]; 248| 0| }]; 249| 0|} 250| | 251| |+ (NSDictionary *)_requestParameters 252| 0|{ 253| 0| NSMutableDictionary *params = [NSMutableDictionary new]; 254| | // append business ids to the request params 255| 0| NSMutableArray *businessIDs = [NSMutableArray new]; 256| 0| for (FBSDKAEMInvocation *invocation in g_invocations) { 257| 0| [FBSDKTypeUtility array:businessIDs addObject:invocation.businessID]; 258| 0| } 259| 0| NSString *businessIDsString = [FBSDKBasicUtility JSONStringForObject:businessIDs error:nil invalidObjectHandler:nil]; 260| 0| [FBSDKTypeUtility dictionary:params setObject:businessIDsString forKey:BUSINESS_IDS_KEY]; 261| 0| return [params copy]; 262| 0|} 263| | 264| |+ (BOOL)_isConfigRefreshTimestampValid 265| 0|{ 266| 0| return g_configRefreshTimestamp && [[NSDate date] timeIntervalSinceDate:g_configRefreshTimestamp] < FBSDK_AEM_CONFIG_TIME_OUT; 267| 0|} 268| | 269| |+ (BOOL)_shouldRefresh 270| 0|{ 271| | // Refresh if there exists invocation which has business ID 272| 0| for (FBSDKAEMInvocation *invocation in g_invocations) { 273| 0| if (invocation.businessID) { 274| 0| return YES; 275| 0| } 276| 0| } 277| | // Refresh if timestamp is expired or cached config is empty 278| 0| return (![self _isConfigRefreshTimestampValid]) || (0 == g_configs.count); 279| 0|} 280| | 281| | #pragma mark - Background methods 282| | 283| |+ (NSMutableDictionary *> *)_loadConfigs 284| 0|{ 285| 0| if (@available(iOS 11.0, *)) { 286| 0| NSData *cachedConfig = [NSData dataWithContentsOfFile:g_configFile options:NSDataReadingMappedIfSafe error:nil]; 287| 0| if ([cachedConfig isKindOfClass:NSData.class]) { 288| 0| NSSet *classes = [NSSet setWithArray:@[ 289| 0| NSMutableDictionary.class, 290| 0| NSMutableArray.class, 291| 0| FBSDKAEMConfiguration.class, 292| 0| FBSDKAEMRule.class, 293| 0| FBSDKAEMEvent.class]]; 294| 0| NSDictionary *> *cache = [FBSDKTypeUtility dictionaryValue:[NSKeyedUnarchiver unarchivedObjectOfClasses:classes fromData:cachedConfig error:nil]]; 295| 0| if (cache) { 296| 0| return [cache mutableCopy]; 297| 0| } 298| 0| } 299| 0| } 300| 0| return [NSMutableDictionary new]; 301| 0|} 302| | 303| |+ (void)_saveConfigs 304| 0|{ 305| 0| if (!g_configs) { 306| 0| return; 307| 0| } 308| 0| if (@available(iOS 11.0, *)) { 309| 0| NSData *cache = [NSKeyedArchiver archivedDataWithRootObject:g_configs requiringSecureCoding:NO error:nil]; 310| 0| if (cache && g_configFile) { 311| 0| [cache writeToFile:g_configFile atomically:YES]; 312| 0| } 313| 0| } 314| 0|} 315| | 316| |+ (void)_addConfigs:(nullable NSArray *)configs 317| 0|{ 318| 0| if (0 == configs.count) { 319| 0| return; 320| 0| } 321| 0| for (NSDictionary *config in configs) { 322| 0| [self _addConfig:[[FBSDKAEMConfiguration alloc] initWithJSON:config]]; 323| 0| } 324| 0| [self _saveConfigs]; 325| 0|} 326| | 327| |+ (void)_addConfig:(nullable FBSDKAEMConfiguration *)config 328| 0|{ 329| 0| if (!config.configMode) { 330| 0| return; 331| 0| } 332| 0| NSMutableArray *configs = [FBSDKTypeUtility dictionary:g_configs objectForKey:config.configMode ofType:NSMutableArray.class]; 333| | // Remove the config in the array that has the same "validFrom" and "businessID" as the added config 334| 0| NSMutableArray *res = [NSMutableArray new]; 335| 0| for (FBSDKAEMConfiguration *c in configs) { 336| 0| if ([config isSameValidFrom:c.validFrom businessID:c.businessID]) { 337| 0| continue; 338| 0| } 339| 0| [FBSDKTypeUtility array:res addObject:c]; 340| 0| } 341| 0| [FBSDKTypeUtility array:res addObject:config]; 342| 0| [FBSDKTypeUtility dictionary:g_configs setObject:res forKey:config.configMode]; 343| | // Sort the configs via "validFrom" 344| 0| [res sortUsingComparator:^NSComparisonResult (FBSDKAEMConfiguration *obj1, FBSDKAEMConfiguration *obj2) { 345| 0| if (obj1.validFrom > obj2.validFrom) { 346| 0| return NSOrderedDescending; 347| 0| } 348| 0| if (obj1.validFrom < obj2.validFrom) { 349| 0| return NSOrderedAscending; 350| 0| } 351| 0| return NSOrderedSame; 352| 0| }]; 353| 0|} 354| | 355| |+ (NSMutableArray *)_loadReportData 356| 0|{ 357| 0| if (@available(iOS 11.0, *)) { 358| 0| NSData *cachedReportData = [NSData dataWithContentsOfFile:g_reportFile options:NSDataReadingMappedIfSafe error:nil]; 359| 0| if ([cachedReportData isKindOfClass:NSData.class]) { 360| 0| NSArray *cache = [FBSDKTypeUtility arrayValue:[NSKeyedUnarchiver unarchivedObjectOfClasses:[NSSet setWithArray:@[NSArray.class, FBSDKAEMInvocation.class]] fromData:cachedReportData error:nil]]; 361| 0| if (cache) { 362| 0| return [cache mutableCopy]; 363| 0| } 364| 0| } 365| 0| } 366| 0| return [NSMutableArray new]; 367| 0|} 368| | 369| |+ (void)_saveReportData 370| 0|{ 371| 0| if (@available(iOS 11.0, *)) { 372| 0| NSData *cache = [NSKeyedArchiver archivedDataWithRootObject:g_invocations requiringSecureCoding:NO error:nil]; 373| 0| if (cache && g_reportFile) { 374| 0| [cache writeToFile:g_reportFile atomically:YES]; 375| 0| } 376| 0| } 377| 0|} 378| | 379| |+ (void)_sendAggregationRequest 380| 0|{ 381| 0| NSMutableArray *params = [NSMutableArray new]; 382| 0| NSMutableArray *aggregatedInvocations = [NSMutableArray new]; 383| 0| for (FBSDKAEMInvocation *invocation in g_invocations) { 384| 0| if (!invocation.isAggregated) { 385| 0| [FBSDKTypeUtility array:params addObject:[self _aggregationRequestParameters:invocation]]; 386| 0| [FBSDKTypeUtility array:aggregatedInvocations addObject:invocation]; 387| 0| } 388| 0| } 389| 0| if (0 == params.count) { 390| 0| return; 391| 0| } 392| 0| @try { 393| 0| NSData *jsonData = [FBSDKTypeUtility dataWithJSONObject:params options:0 error:nil]; 394| 0| if (jsonData) { 395| 0| NSString *reports = [[NSString alloc] initWithData:jsonData encoding:NSUTF8StringEncoding]; 396| 0| id request = [self.requestProvider createGraphRequestWithGraphPath:[NSString stringWithFormat:@"%@/aem_conversions", FBSDKSettings.appID] 397| 0| parameters:@{@"aem_conversions" : reports} 398| 0| tokenString:nil 399| 0| HTTPMethod:FBSDKHTTPMethodPOST 400| 0| flags:FBSDKGraphRequestFlagSkipClientToken | FBSDKGraphRequestFlagDisableErrorRecovery]; 401| 0| [request startWithCompletion:^(id connection, id result, NSError *error) { 402| 0| if (error) { 403| 0| return; 404| 0| } 405| | 406| 0| [self dispatchOnQueue:g_serialQueue block:^() { 407| 0| for (FBSDKAEMInvocation *invocation in aggregatedInvocations) { 408| 0| invocation.isAggregated = YES; 409| 0| } 410| 0| [self _saveReportData]; 411| 0| }]; 412| 0| }]; 413| 0| } 414| 0| } @catch (NSException *exception) { 415| 0| [FBSDKLogger singleShotLogEntry:FBSDKLoggingBehaviorAppEvents logEntry:@"Fail to send AEM reports"]; 416| 0| } 417| 0|} 418| | 419| |+ (NSDictionary *)_aggregationRequestParameters:(FBSDKAEMInvocation *)invocation 420| 0|{ 421| 0| NSInteger delay = 24 + arc4random_uniform(24); 422| 0| NSMutableDictionary *conversionParams = [NSMutableDictionary new]; 423| 0| [FBSDKTypeUtility dictionary:conversionParams setObject:invocation.campaignID forKey:CAMPAIGN_ID_KEY]; 424| 0| [FBSDKTypeUtility dictionary:conversionParams setObject:@(invocation.conversionValue) forKey:CONVERSION_DATA_KEY]; 425| 0| [FBSDKTypeUtility dictionary:conversionParams setObject:@(delay) forKey:CONSUMPTION_HOUR_KEY]; 426| 0| [FBSDKTypeUtility dictionary:conversionParams setObject:invocation.ACSToken forKey:TOKEN_KEY]; 427| 0| [FBSDKTypeUtility dictionary:conversionParams setObject:@"server" forKey:DELAY_FLOW_KEY]; 428| 0| [FBSDKTypeUtility dictionary:conversionParams setObject:invocation.ACSConfigID forKey:CONFIG_ID_KEY]; 429| 0| [FBSDKTypeUtility dictionary:conversionParams setObject:[invocation getHMAC:delay] forKey:HMAC_KEY]; 430| 0| [FBSDKTypeUtility dictionary:conversionParams setObject:invocation.businessID forKey:BUSINESS_ID_KEY]; 431| | 432| 0| return [conversionParams copy]; 433| 0|} 434| | 435| |+ (void)dispatchOnQueue:(dispatch_queue_t)queue block:(dispatch_block_t)block 436| 0|{ 437| 0| if (block != nil) { 438| 0| if (strcmp(dispatch_queue_get_label(queue), dispatchQueueLabel) == 0) { 439| 0| dispatch_async(queue, block); 440| 0| } else { 441| 0| block(); 442| 0| } 443| 0| } 444| 0|} 445| | 446| |+ (void)_clearCache 447| 0|{ 448| | // step 1: clear aggregated invocations that are outside attribution window 449| 0| [self _clearInvocations]; 450| | // step 2: clear old configs that are not used anymore and keep the most recent config 451| 0| [self _clearConfigs]; 452| 0|} 453| | 454| |+ (void)_clearConfigs 455| 0|{ 456| 0| BOOL shouldSaveCache = NO; 457| 0| if (g_configs.count > 0) { 458| 0| NSMutableDictionary *> *configs = [NSMutableDictionary new]; 459| 0| for (NSString *key in g_configs) { 460| 0| NSMutableArray *oldConfigurations = [FBSDKTypeUtility dictionary:g_configs objectForKey:key ofType:NSMutableArray.class]; 461| 0| NSMutableArray *newConfigurations = [NSMutableArray new]; 462| | 463| | // Removes the last of the old configurations and stores it so it can be 464| | // added to the array-to-save 465| 0| FBSDKAEMConfiguration *lastConfiguration = oldConfigurations.lastObject; 466| 0| [oldConfigurations removeLastObject]; 467| | 468| 0| for (FBSDKAEMConfiguration *oldConfiguration in oldConfigurations) { 469| 0| if (![self _isUsingConfig:oldConfiguration forInvocations:g_invocations]) { 470| 0| shouldSaveCache = YES; 471| 0| continue; 472| 0| } 473| 0| [FBSDKTypeUtility array:newConfigurations addObject:oldConfiguration]; 474| 0| } 475| | 476| 0| [FBSDKTypeUtility array:newConfigurations addObject:lastConfiguration]; 477| 0| [FBSDKTypeUtility dictionary:configs setObject:newConfigurations forKey:key]; 478| 0| } 479| 0| g_configs = configs; 480| 0| } 481| 0| if (shouldSaveCache) { 482| 0| [self _saveConfigs]; 483| 0| } 484| 0|} 485| | 486| |+ (void)_clearInvocations 487| 0|{ 488| 0| BOOL isInvocationCacheUpdated = NO; 489| 0| if (g_invocations.count > 0) { 490| 0| NSMutableArray *res = [NSMutableArray new]; 491| 0| for (FBSDKAEMInvocation *invocation in g_invocations) { 492| 0| if ([invocation isOutOfWindowWithConfigs:g_configs] && invocation.isAggregated) { 493| 0| isInvocationCacheUpdated = YES; 494| 0| continue; 495| 0| } 496| 0| [FBSDKTypeUtility array:res addObject:invocation]; 497| 0| } 498| 0| g_invocations = res; 499| 0| } 500| 0| if (isInvocationCacheUpdated) { 501| 0| [self _saveReportData]; 502| 0| } 503| 0|} 504| | 505| |+ (BOOL)_isUsingConfig:(FBSDKAEMConfiguration *)config 506| | forInvocations:(NSArray *)invocations 507| 0|{ 508| 0| for (FBSDKAEMInvocation *invocation in invocations) { 509| 0| if ([config isSameValidFrom:invocation.configID businessID:invocation.businessID]) { 510| 0| return YES; 511| 0| } 512| 0| } 513| 0| return NO; 514| 0|} 515| | 516| | #pragma mark - Testability 517| | 518| | #if DEBUG 519| | #if FBSDKTEST 520| | 521| |+ (NSMutableDictionary *> *)configs 522| 0|{ 523| 0| return g_configs; 524| 0|} 525| | 526| |+ (void)setConfigs:(NSMutableDictionary *> *)configs 527| 0|{ 528| 0| g_configs = configs; 529| 0|} 530| | 531| |+ (void)setInvocations:(NSMutableArray *)invocations 532| 0|{ 533| 0| g_invocations = invocations; 534| 0|} 535| | 536| |+ (NSMutableArray *)invocations 537| 0|{ 538| 0| return g_invocations; 539| 0|} 540| | 541| |+ (void)setIsEnabled:(BOOL)enabled 542| 0|{ 543| 0| g_isAEMReportEnabled = enabled; 544| 0|} 545| | 546| |+ (BOOL)isEnabled 547| 0|{ 548| 0| return g_isAEMReportEnabled; 549| 0|} 550| | 551| |+ (void)setCompletionBlocks:(NSMutableArray *)completionBlocks 552| 0|{ 553| 0| g_completionBlocks = completionBlocks; 554| 0|} 555| | 556| |+ (void)setQueue:(nullable dispatch_queue_t)queue 557| 0|{ 558| 0| g_serialQueue = queue; 559| 0|} 560| | 561| |+ (void)setTimestamp:(NSDate *)timestamp 562| 0|{ 563| 0| g_configRefreshTimestamp = timestamp; 564| 0|} 565| | 566| |+ (void)setIsLoadingConfiguration:(BOOL)loading 567| 0|{ 568| 0| g_isLoadingConfiguration = loading; 569| 0|} 570| | 571| |+ (NSString *)reportFilePath 572| 0|{ 573| 0| return g_reportFile; 574| 0|} 575| | 576| |+ (void)setReportFilePath:(NSString *)path 577| 0|{ 578| 0| g_reportFile = path; 579| 0|} 580| | 581| | #endif 582| | #endif 583| | 584| |@end 585| | 586| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMRule.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKAEMRule.h" 24| | 25| | #import "FBSDKCoreKitBasicsImport.h" 26| | 27| |static NSString *const CONVERSION_VALUE_KEY = @"conversion_value"; 28| |static NSString *const PRIORITY_KEY = @"priority"; 29| |static NSString *const EVENTS_KEY = @"events"; 30| | 31| |@implementation FBSDKAEMRule 32| | 33| |- (nullable instancetype)initWithJSON:(nullable NSDictionary *)dict 34| 0|{ 35| 0| if ((self = [super init])) { 36| 0| dict = [FBSDKTypeUtility dictionaryValue:dict]; 37| 0| if (!dict) { 38| 0| return nil; 39| 0| } 40| 0| NSNumber *conversionValue = [FBSDKTypeUtility dictionary:dict objectForKey:CONVERSION_VALUE_KEY ofType:NSNumber.class]; 41| 0| NSNumber *priority = [FBSDKTypeUtility dictionary:dict objectForKey:PRIORITY_KEY ofType:NSNumber.class]; 42| 0| NSArray *events = [FBSDKAEMRule parseEvents:[FBSDKTypeUtility dictionary:dict objectForKey:EVENTS_KEY ofType:NSArray.class]]; 43| 0| if (conversionValue == nil || priority == nil || 0 == events.count) { 44| 0| return nil; 45| 0| } 46| 0| _conversionValue = conversionValue.integerValue; 47| 0| _priority = priority.integerValue; 48| 0| _events = events; 49| 0| } 50| 0| return self; 51| 0|} 52| | 53| |- (instancetype)initWithConversionValue:(NSInteger)conversionValue 54| | priority:(NSInteger)priority 55| | events:(NSArray *)events 56| 0|{ 57| 0| if ((self = [super init])) { 58| 0| _conversionValue = conversionValue; 59| 0| _priority = priority; 60| 0| _events = events; 61| 0| } 62| 0| return self; 63| 0|} 64| | 65| |- (BOOL)isMatchedWithRecordedEvents:(nullable NSSet *)recordedEvents 66| | recordedValues:(nullable NSDictionary *)recordedValues 67| 0|{ 68| 0| for (FBSDKAEMEvent *event in self.events) { 69| | // Check if event name matches 70| 0| if (![recordedEvents containsObject:event.eventName]) { 71| 0| return NO; 72| 0| } 73| | // Check if event value matches when values is not nil 74| 0| if (event.values) { 75| 0| NSDictionary *recordedEventValues = [FBSDKTypeUtility dictionary:recordedValues objectForKey:event.eventName ofType:NSDictionary.class]; 76| 0| if (![self _isMatchedWithValues:event.values recordedEventValues:recordedEventValues]) { 77| 0| return NO; 78| 0| } 79| 0| } 80| 0| } 81| 0| return YES; 82| 0|} 83| | 84| |- (BOOL)_isMatchedWithValues:(NSDictionary *)values 85| | recordedEventValues:(nullable NSDictionary *)recordedEventValues 86| 0|{ 87| 0| for (NSString *currency in values) { 88| 0| NSNumber *valueInMapping = [FBSDKTypeUtility dictionary:values objectForKey:currency ofType:NSNumber.class]; 89| 0| NSNumber *value = [FBSDKTypeUtility dictionary:recordedEventValues objectForKey:currency ofType:NSNumber.class]; 90| 0| if (value.doubleValue >= valueInMapping.doubleValue) { 91| 0| return YES; 92| 0| } 93| 0| } 94| 0| return NO; 95| 0|} 96| | 97| |+ (nullable NSArray *)parseEvents:(nullable NSArray *> *)events 98| 0|{ 99| 0| if (0 == events.count) { 100| 0| return nil; 101| 0| } 102| 0| NSMutableArray *parsedEvents = [NSMutableArray new]; 103| 0| for (NSDictionary *eventEntry in events) { 104| 0| FBSDKAEMEvent *event = [[FBSDKAEMEvent alloc] initWithJSON:eventEntry]; 105| 0| if (!event) { 106| 0| return nil; 107| 0| } 108| 0| [FBSDKTypeUtility array:parsedEvents addObject:event]; 109| 0| } 110| 0| return [parsedEvents copy]; 111| 0|} 112| | 113| | #pragma mark - NSCoding 114| | 115| |+ (BOOL)supportsSecureCoding 116| 0|{ 117| 0| return YES; 118| 0|} 119| | 120| |- (instancetype)initWithCoder:(NSCoder *)decoder 121| 0|{ 122| 0| NSInteger conversionValue = [decoder decodeIntegerForKey:CONVERSION_VALUE_KEY]; 123| 0| NSInteger priority = [decoder decodeIntegerForKey:PRIORITY_KEY]; 124| 0| NSArray *events = [decoder decodeObjectOfClasses:[NSSet setWithArray:@[NSArray.class, FBSDKAEMEvent.class]] forKey:EVENTS_KEY]; 125| 0| return [self initWithConversionValue:conversionValue priority:priority events:events]; 126| 0|} 127| | 128| |- (void)encodeWithCoder:(NSCoder *)encoder 129| 0|{ 130| 0| [encoder encodeInteger:_conversionValue forKey:CONVERSION_VALUE_KEY]; 131| 0| [encoder encodeInteger:_priority forKey:PRIORITY_KEY]; 132| 0| [encoder encodeObject:_events forKey:EVENTS_KEY]; 133| 0|} 134| | 135| | #pragma mark - NSCopying 136| | 137| |- (instancetype)copyWithZone:(NSZone *)zone 138| 0|{ 139| 0| return self; 140| 0|} 141| | 142| |@end 143| | 144| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/Codeless/FBSDKCodelessIndexer.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKCodelessIndexer.h" 24| | 25| | #import 26| | 27| | #import 28| | #import 29| | #import 30| | 31| | #import "FBSDKAdvertiserIDProviding.h" 32| | #import "FBSDKAppEventsUtility.h" 33| | #import "FBSDKCoreKitBasicsImport.h" 34| | #import "FBSDKDataPersisting.h" 35| | #import "FBSDKGraphRequestConnecting.h" 36| | #import "FBSDKGraphRequestConnectionProviding.h" 37| | #import "FBSDKGraphRequestHTTPMethod.h" 38| | #import "FBSDKGraphRequestProtocol.h" 39| | #import "FBSDKGraphRequestProviding.h" 40| | #import "FBSDKInternalUtility.h" 41| | #import "FBSDKObjectDecoding.h" 42| | #import "FBSDKServerConfiguration.h" 43| | #import "FBSDKServerConfigurationManager.h" 44| | #import "FBSDKServerConfigurationProviding.h" 45| | #import "FBSDKSettings+Internal.h" 46| | #import "FBSDKSettingsProtocol.h" 47| | #import "FBSDKSwizzling.h" 48| | #import "FBSDKUnarchiverProvider.h" 49| | #import "FBSDKUtility.h" 50| | #import "FBSDKViewHierarchy.h" 51| | #import "FBSDKViewHierarchyMacros.h" 52| | 53| |@interface FBSDKCodelessIndexer () 54| | 55| |@property (class, nullable, nonatomic, readonly) id requestProvider; 56| |@property (class, nullable, nonatomic, readonly) Class serverConfigurationProvider; 57| |@property (class, nullable, nonatomic, readonly) id store; 58| |@property (class, nullable, nonatomic, readonly, copy) id connectionProvider; 59| |@property (class, nullable, nonatomic, readonly, copy) Class swizzler; 60| |@property (class, nullable, nonatomic, readonly) id settings; 61| |@property (class, nullable, nonatomic, readonly) id advertiserIDProvider; 62| | 63| |@end 64| | 65| |@implementation FBSDKCodelessIndexer 66| | 67| |static BOOL _isCodelessIndexing; 68| |static BOOL _isCheckingSession; 69| |static BOOL _isCodelessIndexingEnabled; 70| |static BOOL _isGestureSet; 71| | 72| |static NSMutableDictionary *_codelessSetting; 73| |static const NSTimeInterval kTimeout = 4.0; 74| | 75| |static NSString *_deviceSessionID; 76| |static NSTimer *_appIndexingTimer; 77| |static NSString *_lastTreeHash; 78| |static id _requestProvider; 79| |static Class _serverConfigurationProvider; 80| |static id _store; 81| |static id _connectionProvider; 82| |static Class _swizzler; 83| |static id _settings; 84| |static id _advertiserIDProvider; 85| |static id _settings; 86| | 87| |+ (void)configureWithRequestProvider:(id)requestProvider 88| | serverConfigurationProvider:(Class)serverConfigurationProvider 89| | store:(id)store 90| | connectionProvider:(id)connectionProvider 91| | swizzler:(Class)swizzler 92| | settings:(id)settings 93| | advertiserIDProvider:(id)advertiserIDProvider 94| 0|{ 95| 0| if (self == [FBSDKCodelessIndexer class]) { 96| 0| _requestProvider = requestProvider; 97| 0| _serverConfigurationProvider = serverConfigurationProvider; 98| 0| _store = store; 99| 0| _connectionProvider = connectionProvider; 100| 0| _swizzler = swizzler; 101| 0| _settings = settings; 102| 0| _advertiserIDProvider = advertiserIDProvider; 103| 0| } 104| 0|} 105| | 106| |+ (id)requestProvider 107| 0|{ 108| 0| return _requestProvider; 109| 0|} 110| | 111| |+ (Class)serverConfigurationProvider 112| 0|{ 113| 0| return _serverConfigurationProvider; 114| 0|} 115| | 116| |+ (id)store 117| 0|{ 118| 0| return _store; 119| 0|} 120| | 121| |+ (id)connectionProvider 122| 0|{ 123| 0| return _connectionProvider; 124| 0|} 125| | 126| |+ (Class)swizzler 127| 0|{ 128| 0| return _swizzler; 129| 0|} 130| | 131| |+ (id)settings 132| 0|{ 133| 0| return _settings; 134| 0|} 135| | 136| |+ (id)advertiserIDProvider 137| 0|{ 138| 0| return _advertiserIDProvider; 139| 0|} 140| | 141| |+ (void)enable 142| 0|{ 143| 0| if (_isGestureSet) { 144| 0| return; 145| 0| } 146| | 147| 0| static dispatch_once_t onceToken; 148| 0| dispatch_once(&onceToken, ^{ 149| 0| #if TARGET_OS_SIMULATOR 150| 0| [self setupGesture]; 151| | #else 152| | [self loadCodelessSettingWithCompletionBlock:^(BOOL isCodelessSetupEnabled, NSError *error) { 153| | if (isCodelessSetupEnabled) { 154| | [self setupGesture]; 155| | } 156| | }]; 157| | #endif 158| 0| }); 159| 0|} 160| | 161| | #pragma clang diagnostic push 162| | #pragma clang diagnostic ignored "-Wdeprecated-declarations" 163| |// DO NOT call this function, it is only called once in the enable function 164| |+ (void)loadCodelessSettingWithCompletionBlock:(FBSDKCodelessSettingLoadBlock)completionBlock 165| 0|{ 166| 0| NSString *appID = [self.settings appID]; 167| 0| if (appID == nil) { 168| 0| return; 169| 0| } 170| | 171| 0| [self.serverConfigurationProvider loadServerConfigurationWithCompletionBlock:^(FBSDKServerConfiguration *serverConfiguration, NSError *serverConfigurationLoadingError) { 172| 0| if (!serverConfiguration.isCodelessEventsEnabled) { 173| 0| return; 174| 0| } 175| | 176| | // load the defaults 177| 0| NSString *defaultKey = [NSString stringWithFormat:CODELESS_SETTING_KEY, appID]; 178| 0| NSData *data = [self.store objectForKey:defaultKey]; 179| 0| if ([data isKindOfClass:[NSData class]]) { 180| 0| NSMutableDictionary *codelessSetting = nil; 181| 0| id unarchiver = [FBSDKUnarchiverProvider createInsecureUnarchiverFor:data]; 182| 0| @try { 183| 0| codelessSetting = [unarchiver decodeObjectOfClass:NSDictionary.class forKey:NSKeyedArchiveRootObjectKey]; 184| 0| } @catch (NSException *ex) { 185| | // ignore decoding exceptions 186| 0| } 187| 0| if (codelessSetting) { 188| 0| _codelessSetting = codelessSetting; 189| 0| } 190| 0| } 191| | 192| 0| if ( 193| 0| _codelessSetting 194| 0| && [self _codelessSetupTimestampIsValid:[FBSDKTypeUtility dictionary:_codelessSetting objectForKey:CODELESS_SETTING_TIMESTAMP_KEY ofType:NSObject.class]] 195| 0| ) { 196| 0| completionBlock([FBSDKTypeUtility boolValue:[FBSDKTypeUtility dictionary:_codelessSetting objectForKey:CODELESS_SETUP_ENABLED_KEY ofType:NSObject.class]], nil); 197| 0| } else { 198| 0| _codelessSetting = [NSMutableDictionary new]; 199| 0| id request = [self requestToLoadCodelessSetup:appID]; 200| 0| if (request == nil) { 201| 0| return; 202| 0| } 203| 0| id requestConnection = [self.connectionProvider createGraphRequestConnection]; 204| 0| requestConnection.timeout = kTimeout; 205| 0| [requestConnection addRequest:request completion:^(id connection, id result, NSError *codelessLoadingError) { 206| 0| if (codelessLoadingError) { 207| 0| return; 208| 0| } 209| | 210| 0| NSDictionary *resultDictionary = [FBSDKTypeUtility dictionaryValue:result]; 211| 0| if (resultDictionary) { 212| 0| BOOL isCodelessSetupEnabled = [FBSDKTypeUtility boolValue:resultDictionary[CODELESS_SETUP_ENABLED_FIELD]]; 213| 0| [FBSDKTypeUtility dictionary:_codelessSetting setObject:@(isCodelessSetupEnabled) forKey:CODELESS_SETUP_ENABLED_KEY]; 214| 0| [FBSDKTypeUtility dictionary:_codelessSetting setObject:[NSDate date] forKey:CODELESS_SETTING_TIMESTAMP_KEY]; 215| | // update the cached copy in user defaults 216| 0| [self.store setObject:[NSKeyedArchiver archivedDataWithRootObject:_codelessSetting] forKey:defaultKey]; 217| 0| completionBlock(isCodelessSetupEnabled, codelessLoadingError); 218| 0| } 219| 0| }]; 220| 0| [requestConnection start]; 221| 0| } 222| 0| }]; 223| 0|} 224| | 225| | #pragma clang diagnostic pop 226| | 227| |+ (id)requestToLoadCodelessSetup:(NSString *)appID 228| 0|{ 229| 0| NSString *advertiserID = self.advertiserIDProvider.advertiserID; 230| 0| if (!advertiserID) { 231| 0| return nil; 232| 0| } 233| | 234| 0| NSDictionary *parameters = @{ 235| 0| @"fields" : CODELESS_SETUP_ENABLED_FIELD, 236| 0| @"advertiser_id" : advertiserID 237| 0| }; 238| 0| id request = [self.requestProvider createGraphRequestWithGraphPath:appID 239| 0| parameters:parameters 240| 0| tokenString:nil 241| 0| HTTPMethod:nil 242| 0| flags:FBSDKGraphRequestFlagSkipClientToken | FBSDKGraphRequestFlagDisableErrorRecovery]; 243| 0| return request; 244| 0|} 245| | 246| |+ (BOOL)_codelessSetupTimestampIsValid:(NSDate *)timestamp 247| 0|{ 248| 0| return (timestamp != nil && [[NSDate date] timeIntervalSinceDate:timestamp] < CODELESS_SETTING_CACHE_TIMEOUT); 249| 0|} 250| | 251| |+ (void)setupGesture 252| 0|{ 253| 0| _isGestureSet = YES; 254| 0| [UIApplication sharedApplication].applicationSupportsShakeToEdit = YES; 255| 0| Class class = [UIApplication class]; 256| | 257| 0| [self.swizzler swizzleSelector:@selector(motionBegan:withEvent:) 258| 0| onClass:class 259| 0| withBlock:^{ 260| 0| if ([FBSDKServerConfigurationManager cachedServerConfiguration].isCodelessEventsEnabled) { 261| 0| [self checkCodelessIndexingSession]; 262| 0| } 263| 0| } 264| 0| named:@"motionBegan"]; 265| 0|} 266| | 267| |+ (void)checkCodelessIndexingSession 268| 0|{ 269| 0| if (_isCheckingSession) { 270| 0| return; 271| 0| } 272| | 273| 0| _isCheckingSession = YES; 274| 0| NSDictionary *parameters = @{ 275| 0| CODELESS_INDEXING_SESSION_ID_KEY : [self currentSessionDeviceID], 276| 0| CODELESS_INDEXING_EXT_INFO_KEY : [self extInfo] 277| 0| }; 278| 0| id request = [_requestProvider createGraphRequestWithGraphPath:[NSString stringWithFormat:@"%@/%@", 279| 0| [self.settings appID], 280| 0| CODELESS_INDEXING_SESSION_ENDPOINT] 281| 0| parameters:parameters 282| 0| HTTPMethod:FBSDKHTTPMethodPOST]; 283| 0| [request startWithCompletion:^(id connection, id result, NSError *error) { 284| 0| _isCheckingSession = NO; 285| 0| if ([result isKindOfClass:[NSDictionary class]]) { 286| 0| _isCodelessIndexingEnabled = [((NSDictionary *)result)[CODELESS_INDEXING_STATUS_KEY] boolValue]; 287| 0| if (_isCodelessIndexingEnabled) { 288| 0| _lastTreeHash = nil; 289| 0| if (!_appIndexingTimer) { 290| 0| _appIndexingTimer = [NSTimer timerWithTimeInterval:CODELESS_INDEXING_UPLOAD_INTERVAL_IN_SECONDS 291| 0| target:self 292| 0| selector:@selector(startIndexing) 293| 0| userInfo:nil 294| 0| repeats:YES]; 295| 0| [[NSRunLoop mainRunLoop] addTimer:_appIndexingTimer forMode:NSDefaultRunLoopMode]; 296| 0| } 297| 0| } else { 298| 0| _deviceSessionID = nil; 299| 0| } 300| 0| } 301| 0| }]; 302| 0|} 303| | 304| |+ (NSString *)currentSessionDeviceID 305| 0|{ 306| 0| if (!_deviceSessionID) { 307| 0| _deviceSessionID = [NSUUID UUID].UUIDString; 308| 0| } 309| 0| return _deviceSessionID; 310| 0|} 311| | 312| |+ (NSString *)extInfo 313| 0|{ 314| 0| struct utsname systemInfo; 315| 0| uname(&systemInfo); 316| 0| NSString *machine = @(systemInfo.machine); 317| 0| NSString *advertiserID = [FBSDKAppEventsUtility.shared advertiserID] ?: @""; 318| 0| machine = machine ?: @""; 319| 0| NSString *debugStatus = [FBSDKAppEventsUtility isDebugBuild] ? @"1" : @"0"; 320| 0|#if TARGET_OS_SIMULATOR 321| 0| NSString *isSimulator = @"1"; 322| |#else 323| | NSString *isSimulator = @"0"; 324| |#endif 325| 0| NSLocale *locale = [NSLocale currentLocale]; 326| 0| NSString *languageCode = [locale objectForKey:NSLocaleLanguageCode]; 327| 0| NSString *countryCode = [locale objectForKey:NSLocaleCountryCode]; 328| 0| NSString *localeString = locale.localeIdentifier; 329| 0| if (languageCode && countryCode) { 330| 0| localeString = [NSString stringWithFormat:@"%@_%@", languageCode, countryCode]; 331| 0| } 332| | 333| 0| NSString *extinfo = [FBSDKBasicUtility JSONStringForObject:@[machine, 334| 0| advertiserID, 335| 0| debugStatus, 336| 0| isSimulator, 337| 0| localeString] 338| 0| error:NULL 339| 0| invalidObjectHandler:NULL]; 340| | 341| 0| return extinfo ?: @""; 342| 0|} 343| | 344| |+ (void)startIndexing 345| 0|{ 346| 0| if (!_isCodelessIndexingEnabled) { 347| 0| return; 348| 0| } 349| | 350| 0| if (UIApplicationStateActive != [UIApplication sharedApplication].applicationState) { 351| 0| return; 352| 0| } 353| | 354| | // If userAgentSuffix begins with Unity, trigger unity code to upload view hierarchy 355| 0| NSString *userAgentSuffix = [FBSDKSettings userAgentSuffix]; 356| 0| if (userAgentSuffix != nil && [userAgentSuffix hasPrefix:@"Unity"]) { 357| 0| Class FBUnityUtility = objc_lookUpClass("FBUnityUtility"); 358| 0| SEL selector = NSSelectorFromString(@"triggerUploadViewHierarchy"); 359| 0| if (FBUnityUtility && selector && [FBUnityUtility respondsToSelector:selector]) { 360| 0| #pragma clang diagnostic push 361| 0| #pragma clang diagnostic ignored "-Warc-performSelector-leaks" 362| 0| [FBUnityUtility performSelector:selector]; 363| 0| #pragma clang diagnostic pop 364| 0| } 365| 0| } else { 366| 0| [self uploadIndexing]; 367| 0| } 368| 0|} 369| | 370| |+ (void)uploadIndexing 371| 0|{ 372| 0| if (_isCodelessIndexing) { 373| 0| return; 374| 0| } 375| | 376| 0| NSString *tree = [FBSDKCodelessIndexer currentViewTree]; 377| | 378| 0| [self uploadIndexing:tree]; 379| 0|} 380| | 381| |+ (void)uploadIndexing:(NSString *)tree 382| 0|{ 383| 0| if (_isCodelessIndexing) { 384| 0| return; 385| 0| } 386| | 387| 0| if (!tree) { 388| 0| return; 389| 0| } 390| | 391| 0| NSString *currentTreeHash = [FBSDKUtility SHA256Hash:tree]; 392| 0| if (_lastTreeHash && [_lastTreeHash isEqualToString:currentTreeHash]) { 393| 0| return; 394| 0| } 395| | 396| 0| _lastTreeHash = currentTreeHash; 397| | 398| 0| NSBundle *mainBundle = [NSBundle mainBundle]; 399| 0| NSString *version = [mainBundle objectForInfoDictionaryKey:@"CFBundleShortVersionString"]; 400| 0| id request = [_requestProvider createGraphRequestWithGraphPath:[NSString stringWithFormat:@"%@/%@", 401| 0| [self.settings appID], 402| 0| CODELESS_INDEXING_ENDPOINT] 403| 0| parameters:@{ 404| 0| CODELESS_INDEXING_TREE_KEY : tree, 405| 0| CODELESS_INDEXING_APP_VERSION_KEY : version ?: @"", 406| 0| CODELESS_INDEXING_PLATFORM_KEY : @"iOS", 407| 0| CODELESS_INDEXING_SESSION_ID_KEY : [self currentSessionDeviceID] 408| 0| } 409| 0| HTTPMethod:FBSDKHTTPMethodPOST]; 410| 0| _isCodelessIndexing = YES; 411| 0| [request startWithCompletion:^(id connection, id result, NSError *error) { 412| 0| _isCodelessIndexing = NO; 413| 0| if ([result isKindOfClass:[NSDictionary class]]) { 414| 0| _isCodelessIndexingEnabled = [result[CODELESS_INDEXING_STATUS_KEY] boolValue]; 415| 0| if (!_isCodelessIndexingEnabled) { 416| 0| _deviceSessionID = nil; 417| 0| } 418| 0| } 419| 0| }]; 420| 0|} 421| | 422| |+ (NSString *)currentViewTree 423| 0|{ 424| 0| NSMutableArray *trees = [NSMutableArray array]; 425| | 426| 0| NSArray *windows = [UIApplication sharedApplication].windows; 427| 0| for (UIWindow *window in windows) { 428| 0| NSDictionary *tree = [FBSDKViewHierarchy recursiveCaptureTreeWithCurrentNode:window 429| 0| targetNode:nil 430| 0| objAddressSet:nil 431| 0| hash:YES]; 432| 0| if (tree) { 433| 0| if (window.isKeyWindow) { 434| 0| [trees insertObject:tree atIndex:0]; 435| 0| } else { 436| 0| [FBSDKTypeUtility array:trees addObject:tree]; 437| 0| } 438| 0| } 439| 0| } 440| | 441| 0| if (0 == trees.count) { 442| 0| return nil; 443| 0| } 444| | 445| 0| NSArray *viewTrees = [trees reverseObjectEnumerator].allObjects; 446| | 447| 0| NSData *data = UIImageJPEGRepresentation([FBSDKCodelessIndexer screenshot], 0.5); 448| 0| NSString *screenshot = [data base64EncodedStringWithOptions:0]; 449| | 450| 0| NSMutableDictionary *treeInfo = [NSMutableDictionary dictionary]; 451| | 452| 0| [FBSDKTypeUtility dictionary:treeInfo setObject:viewTrees forKey:@"view"]; 453| 0| [FBSDKTypeUtility dictionary:treeInfo setObject:screenshot ?: @"" forKey:@"screenshot"]; 454| | 455| 0| NSString *tree = nil; 456| 0| data = [FBSDKTypeUtility dataWithJSONObject:treeInfo options:0 error:nil]; 457| 0| if (data) { 458| 0| tree = [[NSString alloc] initWithData:data encoding:NSUTF8StringEncoding]; 459| 0| } 460| | 461| 0| return tree; 462| 0|} 463| | 464| |+ (UIImage *)screenshot 465| 0|{ 466| 0| UIWindow *window = [FBSDKInternalUtility.sharedUtility findWindow]; 467| 0| if (!window) { 468| 0| return nil; 469| 0| } 470| | 471| 0| UIGraphicsBeginImageContext(window.bounds.size); 472| 0| [window drawViewHierarchyInRect:window.bounds afterScreenUpdates:YES]; 473| 0| UIImage *image = UIGraphicsGetImageFromCurrentImageContext(); 474| 0| UIGraphicsEndImageContext(); 475| | 476| 0| return image; 477| 0|} 478| | 479| |+ (NSDictionary *)dimensionOf:(NSObject *)obj 480| 0|{ 481| 0| UIView *view = nil; 482| | 483| 0| if ([obj isKindOfClass:[UIView class]]) { 484| 0| view = (UIView *)obj; 485| 0| } else if ([obj isKindOfClass:[UIViewController class]]) { 486| 0| view = ((UIViewController *)obj).view; 487| 0| } 488| | 489| 0| CGRect frame = view.frame; 490| 0| CGPoint offset = CGPointZero; 491| | 492| 0| if ([view isKindOfClass:[UIScrollView class]]) { 493| 0| offset = ((UIScrollView *)view).contentOffset; 494| 0| } 495| | 496| 0| return @{ 497| 0| CODELESS_VIEW_TREE_TOP_KEY : @((int)frame.origin.y), 498| 0| CODELESS_VIEW_TREE_LEFT_KEY : @((int)frame.origin.x), 499| 0| CODELESS_VIEW_TREE_WIDTH_KEY : @((int)frame.size.width), 500| 0| CODELESS_VIEW_TREE_HEIGHT_KEY : @((int)frame.size.height), 501| 0| CODELESS_VIEW_TREE_OFFSET_X_KEY : @((int)offset.x), 502| 0| CODELESS_VIEW_TREE_OFFSET_Y_KEY : @((int)offset.y), 503| 0| CODELESS_VIEW_TREE_VISIBILITY_KEY : view.isHidden ? @4 : @0 504| 0| }; 505| 0|} 506| | 507| | #if DEBUG 508| | #if FBSDKTEST 509| | 510| |+ (void)reset 511| 0|{ 512| 0| _isCheckingSession = NO; 513| 0| _isCodelessIndexing = NO; 514| 0| _isCodelessIndexingEnabled = NO; 515| 0| _isGestureSet = NO; 516| 0| _codelessSetting = nil; 517| 0| _requestProvider = nil; 518| 0| _serverConfigurationProvider = nil; 519| 0| _store = nil; 520| 0| _connectionProvider = nil; 521| 0| _swizzler = nil; 522| 0| _settings = nil; 523| 0| _advertiserIDProvider = nil; 524| 0| _deviceSessionID = nil; 525| 0| _lastTreeHash = nil; 526| 0|} 527| | 528| |+ (void)resetIsCodelessIndexing 529| 0|{ 530| 0| _isCodelessIndexing = NO; 531| 0|} 532| | 533| |+ (BOOL)isCheckingSession 534| 0|{ 535| 0| return _isCheckingSession; 536| 0|} 537| | 538| |+ (NSTimer *)appIndexingTimer 539| 0|{ 540| 0| return _appIndexingTimer; 541| 0|} 542| | 543| | #endif 544| | #endif 545| | 546| |@end 547| | 548| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/Codeless/FBSDKCodelessParameterComponent.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKCodelessParameterComponent.h" 24| | 25| | #import "FBSDKCodelessPathComponent.h" 26| | #import "FBSDKCoreKitBasicsImport.h" 27| | #import "FBSDKViewHierarchyMacros.h" 28| | 29| |@implementation FBSDKCodelessParameterComponent 30| | 31| |- (instancetype)initWithJSON:(NSDictionary *)dict 32| 0|{ 33| 0| if (self = [super init]) { 34| 0| _name = [dict[CODELESS_MAPPING_PARAMETER_NAME_KEY] copy]; 35| 0| _value = [dict[CODELESS_MAPPING_PARAMETER_VALUE_KEY] copy]; 36| 0| _pathType = [dict[CODELESS_MAPPING_PATH_TYPE_KEY] copy]; 37| | 38| 0| NSArray *ary = dict[CODELESS_MAPPING_PATH_KEY]; 39| 0| NSMutableArray *mut = [NSMutableArray array]; 40| 0| for (NSDictionary *info in ary) { 41| 0| FBSDKCodelessPathComponent *component = [[FBSDKCodelessPathComponent alloc] initWithJSON:info]; 42| 0| [FBSDKTypeUtility array:mut addObject:component]; 43| 0| } 44| 0| _path = [mut copy]; 45| 0| } 46| | 47| 0| return self; 48| 0|} 49| | 50| |- (BOOL)isEqualToParameter:(FBSDKCodelessParameterComponent *)parameter 51| 0|{ 52| 0| if (_path.count != parameter.path.count) { 53| 0| return NO; 54| 0| } 55| | 56| 0| NSString *current = [NSString stringWithFormat:@"%@|%@|%@", 57| 0| _name ?: @"", 58| 0| _value ?: @"", 59| 0| _pathType ?: @""]; 60| 0| NSString *compared = [NSString stringWithFormat:@"%@|%@|%@", 61| 0| parameter.name ?: @"", 62| 0| parameter.value ?: @"", 63| 0| parameter.pathType ?: @""]; 64| | 65| 0| if (![current isEqualToString:compared]) { 66| 0| return NO; 67| 0| } 68| | 69| 0| for (int i = 0; i < _path.count; i++) { 70| 0| if (![[FBSDKTypeUtility array:_path objectAtIndex:i] isEqualToPath:[FBSDKTypeUtility array:parameter.path objectAtIndex:i]]) { 71| 0| return NO; 72| 0| } 73| 0| } 74| | 75| 0| return YES; 76| 0|} 77| | 78| |@end 79| | 80| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/Codeless/FBSDKCodelessPathComponent.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKCodelessPathComponent.h" 24| | 25| | #import "FBSDKViewHierarchyMacros.h" 26| | 27| |@implementation FBSDKCodelessPathComponent 28| | 29| |- (instancetype)initWithJSON:(NSDictionary *)dict 30| 0|{ 31| 0| if (self = [super init]) { 32| 0| _className = [dict[CODELESS_MAPPING_CLASS_NAME_KEY] copy]; 33| 0| _text = [dict[CODELESS_MAPPING_TEXT_KEY] copy]; 34| 0| _hint = [dict[CODELESS_MAPPING_HINT_KEY] copy]; 35| 0| _desc = [dict[CODELESS_MAPPING_DESC_KEY] copy]; 36| | 37| 0| if (dict[CODELESS_MAPPING_INDEX_KEY]) { 38| 0| _index = [dict[CODELESS_MAPPING_INDEX_KEY] intValue]; 39| 0| } else { 40| 0| _index = -1; 41| 0| } 42| | 43| 0| if (dict[CODELESS_MAPPING_SECTION_KEY]) { 44| 0| _section = [dict[CODELESS_MAPPING_SECTION_KEY] intValue]; 45| 0| } else { 46| 0| _section = -1; 47| 0| } 48| | 49| 0| if (dict[CODELESS_MAPPING_ROW_KEY]) { 50| 0| _row = [dict[CODELESS_MAPPING_ROW_KEY] intValue]; 51| 0| } else { 52| 0| _row = -1; 53| 0| } 54| | 55| 0| _tag = [dict[CODELESS_MAPPING_TAG_KEY] intValue]; 56| 0| _matchBitmask = [dict[CODELESS_MAPPING_MATCH_BITMASK_KEY] intValue]; 57| 0| } 58| | 59| 0| return self; 60| 0|} 61| | 62| |- (BOOL)isEqualToPath:(FBSDKCodelessPathComponent *)path 63| 0|{ 64| 0| NSString *current = [NSString stringWithFormat:@"%@|%@|%@|%@|%d|%d|%d|%d|%d", 65| 0| _className ?: @"", 66| 0| _text ?: @"", 67| 0| _hint ?: @"", 68| 0| _desc ?: @"", 69| 0| _index, _section, _row, _tag, _matchBitmask]; 70| 0| NSString *compared = [NSString stringWithFormat:@"%@|%@|%@|%@|%d|%d|%d|%d|%d", 71| 0| path.className ?: @"", 72| 0| path.text ?: @"", 73| 0| path.hint ?: @"", 74| 0| path.desc ?: @"", 75| 0| path.index, path.section, path.row, path.tag, path.matchBitmask]; 76| 0| return [current isEqualToString:compared]; 77| 0|} 78| | 79| |@end 80| | 81| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/Codeless/FBSDKEventBinding.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKEventBinding.h" 24| | 25| | #import "FBSDKCodelessPathComponent.h" 26| | #import "FBSDKCoreKitBasicsImport.h" 27| | #import "FBSDKEventLogging.h" 28| | #import "FBSDKInternalUtility.h" 29| | #import "FBSDKSwizzler.h" 30| | #import "FBSDKUtility.h" 31| | #import "FBSDKViewHierarchy.h" 32| | #import "FBSDKViewHierarchyMacros.h" 33| | 34| | #define CODELESS_PATH_TYPE_ABSOLUTE @"absolute" 35| 0| #define CODELESS_PATH_TYPE_RELATIVE @"relative" 36| 0| #define CODELESS_CODELESS_EVENT_KEY @"_is_fb_codeless" 37| 0| #define PARAMETER_NAME_PRICE @"_valueToSum" 38| | 39| |@interface FBSDKEventBinding () 40| | 41| |@property (nonnull, nonatomic) id eventLogger; 42| | 43| |@end 44| | 45| |@implementation FBSDKEventBinding 46| | 47| |static id _numberParser; 48| | 49| |+ (id)numberParser 50| 0|{ 51| 0| return _numberParser; 52| 0|} 53| | 54| |+ (void)setNumberParser:(id)numberParser 55| 0|{ 56| 0| _numberParser = numberParser; 57| 0|} 58| | 59| |+ (void)initialize 60| 0|{ 61| 0| _numberParser = [[FBSDKAppEventsNumberParser alloc] initWithLocale:NSLocale.currentLocale]; 62| 0|} 63| | 64| |- (FBSDKEventBinding *)initWithJSON:(NSDictionary *)dict 65| | eventLogger:(id)eventLogger 66| 0|{ 67| 0| if ((self = [super init])) { 68| 0| _eventLogger = eventLogger; 69| | 70| 0| _eventName = [dict[CODELESS_MAPPING_EVENT_NAME_KEY] copy]; 71| 0| _eventType = [dict[CODELESS_MAPPING_EVENT_TYPE_KEY] copy]; 72| 0| _appVersion = [dict[CODELESS_MAPPING_APP_VERSION_KEY] copy]; 73| 0| _pathType = [dict[CODELESS_MAPPING_PATH_TYPE_KEY] copy]; 74| | 75| 0| NSArray *pathComponents = dict[CODELESS_MAPPING_PATH_KEY]; 76| 0| NSMutableArray *mut = [NSMutableArray array]; 77| 0| for (NSDictionary *info in pathComponents) { 78| 0| FBSDKCodelessPathComponent *component = [[FBSDKCodelessPathComponent alloc] initWithJSON:info]; 79| 0| [FBSDKTypeUtility array:mut addObject:component]; 80| 0| } 81| 0| _path = [mut copy]; 82| | 83| 0| NSArray *parameters = dict[CODELESS_MAPPING_PARAMETERS_KEY]; 84| 0| mut = [NSMutableArray array]; 85| 0| for (NSDictionary *info in parameters) { 86| 0| FBSDKCodelessParameterComponent *component = [[FBSDKCodelessParameterComponent alloc] initWithJSON:info]; 87| 0| [FBSDKTypeUtility array:mut addObject:component]; 88| 0| } 89| 0| _parameters = [mut copy]; 90| 0| } 91| 0| return self; 92| 0|} 93| | 94| |- (void)trackEvent:(id)sender 95| 0|{ 96| 0| UIView *sourceView = [sender isKindOfClass:[UIView class]] ? (UIView *)sender : nil; 97| 0| NSMutableDictionary *params = [NSMutableDictionary dictionary]; 98| 0| [FBSDKTypeUtility dictionary:params setObject:@"1" forKey:CODELESS_CODELESS_EVENT_KEY]; 99| 0| for (FBSDKCodelessParameterComponent *component in self.parameters) { 100| 0| NSString *text = component.value; 101| 0| if (!text || text.length == 0) { 102| 0| text = [FBSDKEventBinding findParameterOfPath:component.path 103| 0| pathType:component.pathType 104| 0| sourceView:sourceView]; 105| 0| } 106| 0| if (text.length > 0) { 107| 0| if ([component.name isEqualToString:PARAMETER_NAME_PRICE]) { 108| 0| NSNumber *value = [self.class.numberParser parseNumberFrom:text]; 109| 0| [FBSDKTypeUtility dictionary:params setObject:value forKey:component.name]; 110| 0| } else { 111| 0| [FBSDKTypeUtility dictionary:params setObject:text forKey:component.name]; 112| 0| } 113| 0| } 114| 0| } 115| | 116| 0| [self.eventLogger logEvent:_eventName parameters:[params copy]]; 117| 0|} 118| | 119| |+ (BOOL)matchAnyView:(NSArray *)views 120| | pathComponent:(FBSDKCodelessPathComponent *)component 121| 0|{ 122| 0| for (NSObject *view in views) { 123| 0| if ([self match:view pathComponent:component]) { 124| 0| return YES; 125| 0| } 126| 0| } 127| 0| return NO; 128| 0|} 129| | 130| |+ (BOOL) match:(NSObject *)view 131| | pathComponent:(FBSDKCodelessPathComponent *)component 132| 0|{ 133| 0| NSString *className = NSStringFromClass([view class]); 134| 0| if (![className isEqualToString:component.className]) { 135| 0| return NO; 136| 0| } 137| | 138| 0| if (component.index >= 0) { 139| 0| NSObject *parent = [FBSDKViewHierarchy getParent:view]; 140| 0| if (parent) { 141| 0| NSArray *children = [FBSDKViewHierarchy getChildren:[FBSDKViewHierarchy getParent:view]]; 142| 0| NSUInteger index = [children indexOfObject:view]; 143| 0| if (index == NSNotFound || index != component.index) { 144| 0| return NO; 145| 0| } 146| 0| } else { 147| 0| if (0 != component.index) { 148| 0| return NO; 149| 0| } 150| 0| } 151| 0| } 152| | 153| 0| if ((component.matchBitmask & FBSDKCodelessMatchBitmaskFieldText) > 0) { 154| 0| NSString *text = [FBSDKViewHierarchy getText:view]; 155| 0| BOOL match = ((text.length == 0 && component.text.length == 0) 156| 0| || [text isEqualToString:component.text]); 157| 0| if (!match) { 158| 0| return NO; 159| 0| } 160| 0| } 161| | 162| 0| if ((component.matchBitmask & FBSDKCodelessMatchBitmaskFieldTag) > 0 163| 0| && [view isKindOfClass:[UIView class]] 164| 0| && component.tag != ((UIView *)view).tag) { 165| 0| return NO; 166| 0| } 167| | 168| 0| if ((component.matchBitmask & FBSDKCodelessMatchBitmaskFieldHint) > 0) { 169| 0| NSString *hint = [FBSDKViewHierarchy getHint:view]; 170| 0| BOOL match = ((hint.length == 0 && component.hint.length == 0) 171| 0| || [hint isEqualToString:component.hint]); 172| 0| if (!match) { 173| 0| return NO; 174| 0| } 175| 0| } 176| | 177| 0| return YES; 178| 0|} 179| | 180| |+ (BOOL)isViewMatchPath:(UIView *)view path:(NSArray *)path 181| 0|{ 182| 0| NSArray *viewPath = [FBSDKViewHierarchy getPath:view]; 183| 0| BOOL isMatch = [self isPath:path matchViewPath:viewPath]; 184| | 185| 0| return isMatch; 186| 0|} 187| | 188| |+ (BOOL)isPath:(NSArray *)path matchViewPath:(NSArray *)viewPath 189| 0|{ 190| 0| if ((path.count == 0) || (viewPath.count == 0)) { 191| 0| return NO; 192| 0| } 193| | 194| 0| for (NSInteger i = 0; i < MIN(path.count, viewPath.count); i++) { 195| 0| NSInteger idxPath = path.count - i - 1; 196| 0| NSInteger idxViewPath = viewPath.count - i - 1; 197| | 198| 0| FBSDKCodelessPathComponent *pathComponent = [FBSDKTypeUtility array:path objectAtIndex:idxPath]; 199| 0| FBSDKCodelessPathComponent *viewPathComponent = [FBSDKTypeUtility array:viewPath objectAtIndex:idxViewPath]; 200| | 201| 0| if (![pathComponent.className isEqualToString:viewPathComponent.className]) { 202| 0| return NO; 203| 0| } 204| | 205| 0| if (pathComponent.index >= 0 206| 0| && pathComponent.index != viewPathComponent.index) { 207| 0| return NO; 208| 0| } 209| | 210| 0| if ((pathComponent.matchBitmask & FBSDKCodelessMatchBitmaskFieldText) > 0) { 211| 0| NSString *text = viewPathComponent.text; 212| 0| BOOL match = ((text.length == 0 && pathComponent.text.length == 0) 213| 0| || [text isEqualToString:pathComponent.text] 214| 0| || [[FBSDKUtility SHA256Hash:text] isEqualToString:pathComponent.text]); 215| 0| if (!match) { 216| 0| return NO; 217| 0| } 218| 0| } 219| | 220| 0| if ((pathComponent.matchBitmask & FBSDKCodelessMatchBitmaskFieldTag) > 0 221| 0| && pathComponent.tag != viewPathComponent.tag) { 222| 0| return NO; 223| 0| } 224| | 225| 0| if ((pathComponent.matchBitmask & FBSDKCodelessMatchBitmaskFieldHint) > 0) { 226| 0| NSString *hint = viewPathComponent.hint; 227| 0| BOOL match = ((hint.length == 0 && pathComponent.hint.length == 0) 228| 0| || [hint isEqualToString:pathComponent.hint] 229| 0| || [[FBSDKUtility SHA256Hash:hint] isEqualToString:pathComponent.hint]); 230| 0| if (!match) { 231| 0| return NO; 232| 0| } 233| 0| } 234| 0| } 235| | 236| 0| return YES; 237| 0|} 238| | 239| |+ (NSObject *)findViewByPath:(NSArray *)path parent:(NSObject *)parent level:(int)level 240| 0|{ 241| 0| if (level >= path.count) { 242| 0| return nil; 243| 0| } 244| | 245| 0| FBSDKCodelessPathComponent *pathComponent = [FBSDKTypeUtility array:path objectAtIndex:level]; 246| | 247| | // If found parent, skip to next level 248| 0| if ([pathComponent.className isEqualToString:CODELESS_MAPPING_PARENT_CLASS_NAME]) { 249| 0| NSObject *nextParent = [FBSDKViewHierarchy getParent:parent]; 250| | 251| 0| return [FBSDKEventBinding findViewByPath:path parent:nextParent level:level + 1]; 252| 0| } else if ([pathComponent.className isEqualToString:CODELESS_MAPPING_CURRENT_CLASS_NAME]) { 253| 0| return parent; 254| 0| } 255| | 256| 0| NSArray *children; 257| 0| if (parent) { 258| 0| children = [FBSDKViewHierarchy getChildren:parent]; 259| 0| } else { 260| 0| UIWindow *window = [FBSDKInternalUtility.sharedUtility findWindow]; 261| 0| if (window) { 262| 0| children = @[window]; 263| 0| } else { 264| 0| return nil; 265| 0| } 266| 0| } 267| | 268| 0| if (path.count - 1 == level) { 269| 0| int index = pathComponent.index; 270| 0| if (index >= 0) { 271| 0| NSObject *child = index < children.count ? [FBSDKTypeUtility array:children objectAtIndex:index] : nil; 272| 0| if ([self match:child pathComponent:pathComponent]) { 273| 0| return child; 274| 0| } 275| 0| } else { 276| 0| for (NSObject *child in children) { 277| 0| if ([self match:child pathComponent:pathComponent]) { 278| 0| return child; 279| 0| } 280| 0| } 281| 0| } 282| 0| } else { 283| 0| for (NSObject *child in children) { 284| 0| NSObject *result = [self findViewByPath:path parent:child level:level + 1]; 285| 0| if (result) { 286| 0| return result; 287| 0| } 288| 0| } 289| 0| } 290| | 291| 0| return nil; 292| 0|} 293| | 294| |- (BOOL)isEqualToBinding:(FBSDKEventBinding *)binding 295| 0|{ 296| 0| if (_path.count != binding.path.count 297| 0| || _parameters.count != binding.parameters.count) { 298| 0| return NO; 299| 0| } 300| | 301| 0| NSString *current = [NSString stringWithFormat:@"%@|%@|%@|%@", 302| 0| _eventName ?: @"", 303| 0| _eventType ?: @"", 304| 0| _appVersion ?: @"", 305| 0| _pathType ?: @""]; 306| 0| NSString *compared = [NSString stringWithFormat:@"%@|%@|%@|%@", 307| 0| binding.eventName ?: @"", 308| 0| binding.eventType ?: @"", 309| 0| binding.appVersion ?: @"", 310| 0| binding.pathType ?: @""]; 311| 0| if (![current isEqualToString:compared]) { 312| 0| return NO; 313| 0| } 314| | 315| 0| for (int i = 0; i < _path.count; i++) { 316| 0| if (![[FBSDKTypeUtility array:_path objectAtIndex:i] isEqualToPath:[FBSDKTypeUtility array:binding.path objectAtIndex:i]]) { 317| 0| return NO; 318| 0| } 319| 0| } 320| | 321| 0| for (int i = 0; i < _parameters.count; i++) { 322| 0| if (![[FBSDKTypeUtility array:_parameters objectAtIndex:i] isEqualToParameter:[FBSDKTypeUtility array:binding.parameters objectAtIndex:i]]) { 323| 0| return NO; 324| 0| } 325| 0| } 326| | 327| 0| return YES; 328| 0|} 329| | 330| |// MARK: - find event parameters via relative path 331| |+ (NSString *)findParameterOfPath:(NSArray *)path 332| | pathType:(NSString *)pathType 333| | sourceView:(UIView *)sourceView 334| 0|{ 335| 0| if (0 == path.count) { 336| 0| return nil; 337| 0| } 338| | 339| 0| UIView *rootView = sourceView; 340| 0| if (![pathType isEqualToString:CODELESS_PATH_TYPE_RELATIVE]) { 341| 0| rootView = nil; 342| 0| } 343| | 344| 0| NSObject *foundObj = [self findViewByPath:path parent:rootView level:0]; 345| | 346| 0| return [FBSDKViewHierarchy getText:foundObj]; 347| 0|} 348| | 349| |@end 350| | 351| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/Codeless/FBSDKEventBindingManager.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKEventBindingManager.h" 24| | 25| | #import 26| | 27| | #import 28| | 29| | #import "FBSDKCodelessPathComponent.h" 30| | #import "FBSDKCoreKitBasicsImport.h" 31| | #import "FBSDKEventBinding.h" 32| | #import "FBSDKEventLogging.h" 33| | #import "FBSDKSwizzling.h" 34| | #import "FBSDKViewHierarchy.h" 35| | #import "FBSDKViewHierarchyMacros.h" 36| | 37| | #define ReactNativeTargetKey @"target" 38| 0| #define ReactNativeTouchEndEventName @"touchEnd" 39| | 40| 0| #define ReactNativeClassRCTTextView "RCTTextView" 41| 0| #define ReactNativeClassRCTImageView "RCTImageView" 42| | #define ReactNativeClassRCTTouchEvent "RCTTouchEvent" 43| 0| #define ReactNativeClassRCTTouchHandler "RCTTouchHandler" 44| | 45| |@interface FBSDKEventBindingManager () 46| | 47| |@property (nonnull, nonatomic) id eventLogger; 48| |@property (nonnull, nonatomic) Class swizzler; 49| |@property (nonatomic) BOOL isStarted; 50| |@property (nullable, nonatomic) NSMutableDictionary *reactBindings; 51| |@property (nonnull, nonatomic) NSSet *validClasses; 52| |@property (nonatomic) BOOL hasReactNative; 53| |@property (nullable, nonatomic) NSArray *eventBindings; 54| | 55| |@end 56| | 57| |@implementation FBSDKEventBindingManager 58| | 59| |- (instancetype)initWithSwizzler:(Class)swizzling 60| | eventLogger:(id)eventLogger; 61| 0|{ 62| 0| if ((self = [super init])) { 63| 0| _swizzler = swizzling; 64| 0| _eventLogger = eventLogger; 65| 0| _hasReactNative = NO; 66| 0| _isStarted = NO; 67| 0| _reactBindings = [NSMutableDictionary dictionary]; 68| | 69| 0| NSMutableSet *classes = [NSMutableSet set]; 70| 0| [classes addObject:[UIControl class]]; 71| 0| [classes addObject:[UITableView class]]; 72| 0| [classes addObject:[UICollectionView class]]; 73| | // ReactNative 74| 0| Class classRCTRootView = objc_lookUpClass(ReactNativeClassRCTRootView); 75| 0| if (classRCTRootView != nil) { 76| 0| _hasReactNative = YES; 77| 0| Class classRCTView = objc_lookUpClass(ReactNativeClassRCTView); 78| 0| Class classRCTTextView = objc_lookUpClass(ReactNativeClassRCTTextView); 79| 0| Class classRCTImageView = objc_lookUpClass(ReactNativeClassRCTImageView); 80| 0| if (classRCTView) { 81| 0| [classes addObject:classRCTView]; 82| 0| } 83| 0| if (classRCTTextView) { 84| 0| [classes addObject:classRCTTextView]; 85| 0| } 86| 0| if (classRCTImageView) { 87| 0| [classes addObject:classRCTImageView]; 88| 0| } 89| 0| } 90| 0| _validClasses = [NSSet setWithSet:classes]; 91| 0| } 92| 0| return self; 93| 0|} 94| | 95| |- (instancetype)initWithJSON:(NSDictionary *)dict 96| | swizzler:(Class)swizzler 97| | eventLogger:(id)eventLogger 98| 0|{ 99| 0| if ((self = [self initWithSwizzler:swizzler eventLogger:eventLogger])) { 100| 0| NSArray *eventBindingsDict = [FBSDKTypeUtility arrayValue:dict[@"event_bindings"]]; 101| 0| NSMutableArray *bindings = [NSMutableArray array]; 102| 0| for (NSDictionary *d in eventBindingsDict) { 103| 0| FBSDKEventBinding *e = [[FBSDKEventBinding alloc] initWithJSON:d eventLogger:eventLogger]; 104| 0| [FBSDKTypeUtility array:bindings addObject:e]; 105| 0| } 106| 0| _eventBindings = [bindings copy]; 107| 0| } 108| 0| return self; 109| 0|} 110| | 111| |- (NSArray *)parseArray:(NSArray *)array 112| 0|{ 113| 0| NSMutableArray *result = [NSMutableArray array]; 114| | 115| 0| for (NSDictionary *json in array) { 116| 0| FBSDKEventBinding *binding = [[FBSDKEventBinding alloc] initWithJSON:json 117| 0| eventLogger:self.eventLogger]; 118| 0| [FBSDKTypeUtility array:result addObject:binding]; 119| 0| } 120| | 121| 0| return [result copy]; 122| 0|} 123| | 124| | #pragma clang diagnostic push 125| | #pragma clang diagnostic ignored "-Wundeclared-selector" 126| |- (void)start 127| 0|{ 128| 0| if (self.isStarted) { 129| 0| return; 130| 0| } 131| | 132| 0| if (0 == self.eventBindings.count) { 133| 0| return; 134| 0| } 135| | 136| 0| self.isStarted = YES; 137| | 138| 0| void (^blockToWindow)(id view) = ^(id view) { 139| 0| [self matchView:view delegate:nil]; 140| 0| }; 141| | 142| 0| [self.swizzler swizzleSelector:@selector(didMoveToWindow) 143| 0| onClass:[UIControl class] 144| 0| withBlock:blockToWindow 145| 0| named:@"map_control"]; 146| | 147| | // ReactNative 148| 0| if (self.hasReactNative) { // If app is built via ReactNative 149| 0| Class classRCTView = objc_lookUpClass(ReactNativeClassRCTView); 150| 0| Class classRCTTextView = objc_lookUpClass(ReactNativeClassRCTTextView); 151| 0| Class classRCTImageView = objc_lookUpClass(ReactNativeClassRCTImageView); 152| 0| Class classRCTTouchHandler = objc_lookUpClass(ReactNativeClassRCTTouchHandler); 153| | 154| | // All react-native views would be added tp RCTRootView, so no need to check didMoveToWindow 155| 0| [self.swizzler swizzleSelector:@selector(didMoveToWindow) 156| 0| onClass:classRCTView 157| 0| withBlock:blockToWindow 158| 0| named:@"match_react_native"]; 159| 0| [self.swizzler swizzleSelector:@selector(didMoveToWindow) 160| 0| onClass:classRCTTextView 161| 0| withBlock:blockToWindow 162| 0| named:@"match_react_native"]; 163| 0| [self.swizzler swizzleSelector:@selector(didMoveToWindow) 164| 0| onClass:classRCTImageView 165| 0| withBlock:blockToWindow 166| 0| named:@"match_react_native"]; 167| | 168| | // RCTTouchHandler handles with touch events, like touchEnd and uses RCTEventDispather to dispatch events, so we can check _updateAndDispatchTouches to fire events 169| 0| [self.swizzler swizzleSelector:@selector(_updateAndDispatchTouches:eventName:) 170| 0| onClass:classRCTTouchHandler 171| 0| withBlock:^(id touchHandler, SEL command, id touches, id eventName) { 172| 0| [self handleReactNativeTouchesWithHandler:touchHandler command:command touches:touches eventName:eventName]; 173| 0| } 174| 0| named:@"dispatch_rn_event"]; 175| 0| } 176| | 177| | // UITableView 178| 0| void (^tableViewBlock)(UITableView *tableView, 179| 0| SEL cmd, 180| 0| id delegate) = 181| 0| ^(UITableView *tableView, SEL cmd, id delegate) { 182| 0| if (!delegate) { 183| 0| return; 184| 0| } 185| | 186| 0| [self matchView:tableView delegate:delegate]; 187| 0| }; 188| 0| [self.swizzler swizzleSelector:@selector(setDelegate:) 189| 0| onClass:[UITableView class] 190| 0| withBlock:tableViewBlock 191| 0| named:@"match_table_view"]; 192| | // UICollectionView 193| 0| void (^collectionViewBlock)(UICollectionView *collectionView, 194| 0| SEL cmd, 195| 0| id delegate) = 196| 0| ^(UICollectionView *collectionView, SEL cmd, id delegate) { 197| 0| if (nil == delegate) { 198| 0| return; 199| 0| } 200| | 201| 0| [self matchView:collectionView delegate:delegate]; 202| 0| }; 203| 0| [self.swizzler swizzleSelector:@selector(setDelegate:) 204| 0| onClass:[UICollectionView class] 205| 0| withBlock:collectionViewBlock 206| 0| named:@"handle_collection_view"]; 207| 0|} 208| | 209| |- (void)rematchBindings 210| 0|{ 211| 0| if (0 == self.eventBindings.count) { 212| 0| return; 213| 0| } 214| | 215| 0| NSArray *windows = [UIApplication sharedApplication].windows; 216| 0| for (UIWindow *window in windows) { 217| 0| [self matchSubviewsIn:window]; 218| 0| } 219| 0|} 220| | 221| |- (void)matchSubviewsIn:(UIView *)view 222| 0|{ 223| 0| if (!view) { 224| 0| return; 225| 0| } 226| | 227| 0| for (UIView *subview in view.subviews) { 228| 0| BOOL isValidClass = NO; 229| 0| for (Class cls in self.validClasses) { 230| 0| if ([subview isKindOfClass:cls]) { 231| 0| isValidClass = YES; 232| 0| break; 233| 0| } 234| 0| } 235| | 236| 0| if (isValidClass) { 237| 0| if ([subview isKindOfClass:[UITableView class]]) { 238| 0| UITableView *tableView = (UITableView *)subview; 239| 0| if (tableView.delegate) { 240| 0| [self matchView:subview delegate:tableView.delegate]; 241| 0| } 242| 0| } else if ([subview isKindOfClass:[UICollectionView class]]) { 243| 0| UICollectionView *collectionView = (UICollectionView *)subview; 244| 0| if (collectionView.delegate) { 245| 0| [self matchView:subview delegate:collectionView.delegate]; 246| 0| } 247| 0| } else { 248| 0| [self matchView:subview delegate:nil]; 249| 0| } 250| 0| } 251| | 252| 0| if (![subview isKindOfClass:[UIControl class]]) { 253| 0| [self matchSubviewsIn:subview]; 254| 0| } 255| 0| } 256| 0|} 257| | 258| |// check if the view is matched to any event 259| |- (void)matchView:(UIView *)view delegate:(id)delegate 260| 0|{ 261| 0| if (0 == self.eventBindings.count) { 262| 0| return; 263| 0| } 264| | 265| 0| __weak Class weakSwizzler = self.swizzler; 266| 0| __block BOOL hasReactNative = self.hasReactNative; 267| 0| fb_dispatch_on_main_thread(^{ 268| 0| if (![view window]) { 269| 0| return; 270| 0| } 271| | 272| 0| NSArray *path = [FBSDKViewHierarchy getPath:view]; 273| | 274| 0| void (^matchBlock)(void) = ^void () { 275| 0| if ([view isKindOfClass:[UIControl class]]) { 276| 0| UIControl *control = (UIControl *)view; 277| 0| for (FBSDKEventBinding *binding in self->_eventBindings) { 278| 0| if ([FBSDKEventBinding isPath:binding.path matchViewPath:path]) { 279| 0| fb_dispatch_on_main_thread(^{ 280| 0| [control addTarget:binding 281| 0| action:@selector(trackEvent:) 282| 0| forControlEvents:UIControlEventTouchUpInside]; 283| 0| }); 284| 0| break; 285| 0| } 286| 0| } 287| 0| } else if (hasReactNative 288| 0| && [view respondsToSelector:@selector(reactTag)]) { 289| 0| for (FBSDKEventBinding *binding in self->_eventBindings) { 290| 0| if ([FBSDKEventBinding isPath:binding.path matchViewPath:path]) { 291| 0| fb_dispatch_on_main_thread(^{ 292| 0| if (view) { 293| 0| NSNumber *reactTag = [FBSDKViewHierarchy getViewReactTag:view]; 294| 0| if (reactTag != nil) { 295| 0| [FBSDKTypeUtility dictionary:self->_reactBindings setObject:binding forKey:reactTag]; 296| 0| } 297| 0| } 298| 0| }); 299| 0| break; 300| 0| } 301| 0| } 302| 0| } else if ([view isKindOfClass:[UITableView class]] 303| 0| && [delegate conformsToProtocol:@protocol(UITableViewDelegate)]) { 304| 0| void (^tableViewBlock)(void) = ^void () { 305| 0| NSMutableSet *matchedBindings = [NSMutableSet set]; 306| 0| for (FBSDKEventBinding *binding in self->_eventBindings) { 307| 0| if (binding.path.count > 1) { 308| 0| NSArray *shortPath = [binding.path 309| 0| subarrayWithRange:NSMakeRange(0, binding.path.count - 1)]; 310| 0| if ([FBSDKEventBinding isPath:shortPath matchViewPath:path]) { 311| 0| [matchedBindings addObject:binding]; 312| 0| } 313| 0| } 314| 0| } 315| | 316| 0| if (matchedBindings.count > 0) { 317| 0| NSArray *bindings = matchedBindings.allObjects; 318| 0| void (^block)(id, SEL, id, id) = ^(id target, SEL command, UITableView *tableView, NSIndexPath *indexPath) { 319| 0| [self handleDidSelectRowWithBindings:bindings target:target command:command tableView:tableView indexPath:indexPath]; 320| 0| }; 321| 0| [weakSwizzler swizzleSelector:@selector(tableView:didSelectRowAtIndexPath:) 322| 0| onClass:[delegate class] 323| 0| withBlock:block 324| 0| named:@"handle_table_view"]; 325| 0| } 326| 0| }; 327| 0| #if FBSDKTEST 328| 0| tableViewBlock(); 329| | #else 330| | fb_dispatch_on_default_thread(tableViewBlock); 331| | #endif 332| 0| } else if ([view isKindOfClass:[UICollectionView class]] 333| 0| && [delegate conformsToProtocol:@protocol(UICollectionViewDelegate)]) { 334| 0| void (^collectionViewBlock)(void) = ^void () { 335| 0| NSMutableSet *matchedBindings = [NSMutableSet set]; 336| 0| for (FBSDKEventBinding *binding in self->_eventBindings) { 337| 0| if (binding.path.count > 1) { 338| 0| NSArray *shortPath = [binding.path 339| 0| subarrayWithRange:NSMakeRange(0, binding.path.count - 1)]; 340| 0| if ([FBSDKEventBinding isPath:shortPath matchViewPath:path]) { 341| 0| [matchedBindings addObject:binding]; 342| 0| } 343| 0| } 344| 0| } 345| | 346| 0| if (matchedBindings.count > 0) { 347| 0| NSArray *bindings = matchedBindings.allObjects; 348| 0| void (^block)(id, SEL, id, id) = ^(id target, SEL command, UICollectionView *collectionView, NSIndexPath *indexPath) { 349| 0| [self handleDidSelectItemWithBindings:bindings target:target command:command collectionView:collectionView indexPath:indexPath]; 350| 0| }; 351| 0| [weakSwizzler swizzleSelector:@selector(collectionView:didSelectItemAtIndexPath:) 352| 0| onClass:[delegate class] 353| 0| withBlock:block 354| 0| named:@"handle_collection_view"]; 355| 0| } 356| 0| }; 357| 0| #if FBSDKTEST 358| 0| collectionViewBlock(); 359| | #else 360| | fb_dispatch_on_default_thread(collectionViewBlock); 361| | #endif 362| 0| } 363| 0| }; 364| | 365| 0| #if FBSDKTEST 366| 0| matchBlock(); 367| | #else 368| | fb_dispatch_on_default_thread(matchBlock); 369| | #endif 370| 0| }); 371| 0|} 372| | 373| | #pragma clang diagnostic pop 374| |- (void)updateBindings:(NSArray *)bindings 375| 0|{ 376| 0| if (self.eventBindings.count > 0 && self.eventBindings.count == bindings.count) { 377| | // Check whether event bindings are the same 378| 0| BOOL isSame = YES; 379| 0| for (int i = 0; i < self.eventBindings.count; i++) { 380| 0| if (![[FBSDKTypeUtility array:self.eventBindings objectAtIndex:i] isEqualToBinding:[FBSDKTypeUtility array:bindings objectAtIndex:i]]) { 381| 0| isSame = NO; 382| 0| break; 383| 0| } 384| 0| } 385| | 386| 0| if (isSame) { 387| 0| return; 388| 0| } 389| 0| } 390| | 391| 0| self.eventBindings = bindings; 392| 0| [self.reactBindings removeAllObjects]; 393| 0| if (!self.isStarted) { 394| 0| [self start]; 395| 0| } 396| | 397| 0| fb_dispatch_on_main_thread(^{ 398| 0| [self rematchBindings]; 399| 0| }); 400| 0|} 401| | 402| |// MARK: Method Replacements 403| | 404| |- (void)handleReactNativeTouchesWithHandler:(id)handler 405| | command:(SEL)command 406| | touches:(id)touches 407| | eventName:(id)eventName 408| 0|{ 409| 0| if ([touches isKindOfClass:[NSSet class]] && [eventName isKindOfClass:[NSString class]]) { 410| 0| @try { 411| 0| NSString *reactEventName = (NSString *)eventName; 412| 0| NSSet *reactTouches = (NSSet *)touches; 413| 0| if ([reactEventName isEqualToString:ReactNativeTouchEndEventName]) { 414| 0| for (UITouch *touch in reactTouches) { 415| 0| UIView *targetView = ((UITouch *)touch).view.superview; 416| 0| NSNumber *reactTag = nil; 417| | // Find the closest React-managed touchable view like RCTTouchHandler 418| 0| while (targetView) { 419| 0| reactTag = [FBSDKViewHierarchy getViewReactTag:targetView]; 420| 0| if (reactTag != nil && targetView.userInteractionEnabled) { 421| 0| break; 422| 0| } 423| 0| targetView = targetView.superview; 424| 0| } 425| 0| FBSDKEventBinding *eventBinding = self->_reactBindings[reactTag]; 426| 0| if (reactTag != nil && eventBinding != nil) { 427| 0| [eventBinding trackEvent:nil]; 428| 0| } 429| 0| } 430| 0| } 431| 0| } @catch (NSException *exception) { 432| | // Catch exception here to prevent LytroKit from crashing app 433| 0| } 434| 0| } 435| 0|}; 436| | 437| |- (void)handleDidSelectRowWithBindings:(NSArray *)bindings 438| | target:(nullable id)target 439| | command:(nullable SEL)command 440| | tableView:(UITableView *)tableView 441| | indexPath:(NSIndexPath *)indexPath 442| 0|{ 443| 0| fb_dispatch_on_main_thread(^{ 444| 0| for (FBSDKEventBinding *binding in bindings) { 445| 0| FBSDKCodelessPathComponent *component = binding.path.lastObject; 446| 0| if ((component.section == -1 || component.section == indexPath.section) 447| 0| && (component.row == -1 || component.row == indexPath.row)) { 448| 0| UITableViewCell *cell = [tableView cellForRowAtIndexPath:indexPath]; 449| 0| if (cell) { 450| 0| [binding trackEvent:cell]; 451| 0| } 452| 0| } 453| 0| } 454| 0| }); 455| 0|} 456| | 457| |- (void)handleDidSelectItemWithBindings:(NSArray *)bindings 458| | target:(nullable id)target 459| | command:(nullable SEL)command 460| | collectionView:(UICollectionView *)collectionView 461| | indexPath:(NSIndexPath *)indexPath 462| 0|{ 463| 0| fb_dispatch_on_main_thread(^{ 464| 0| for (FBSDKEventBinding *binding in bindings) { 465| 0| FBSDKCodelessPathComponent *component = binding.path.lastObject; 466| 0| if ((component.section == -1 || component.section == indexPath.section) 467| 0| && (component.row == -1 || component.row == indexPath.row)) { 468| 0| UICollectionViewCell *cell = [collectionView cellForItemAtIndexPath:indexPath]; 469| 0| if (cell) { 470| 0| [binding trackEvent:cell]; 471| 0| } 472| 0| } 473| 0| } 474| 0| }); 475| 0|} 476| | 477| |- (NSSet *)validClasses 478| 0|{ 479| 0| return _validClasses; 480| 0|} 481| | 482| | #if DEBUG 483| | #if FBSDKTEST 484| | 485| |- (void)setReactBindings:(NSMutableDictionary *)bindings 486| 0|{ 487| 0| _reactBindings = bindings; 488| 0|} 489| | 490| | #endif 491| | #endif 492| | 493| |@end 494| | 495| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/EventDeactivation/FBSDKEventDeactivationManager.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKEventDeactivationManager.h" 20| | 21| |#import "FBSDKCoreKitBasicsImport.h" 22| |#import "FBSDKServerConfigurationManager.h" 23| | 24| |static NSString *const DEPRECATED_PARAM_KEY = @"deprecated_param"; 25| |static NSString *const DEPRECATED_EVENT_KEY = @"is_deprecated_event"; 26| | 27| |@interface FBSDKDeactivatedEvent : NSObject 28| | 29| |@property (nonatomic, readonly, copy) NSString *eventName; 30| |@property (nullable, nonatomic, readonly, copy) NSSet *deactivatedParams; 31| | 32| |- (instancetype)initWithEventName:(NSString *)eventName 33| | deactivatedParams:(NSSet *)deactivatedParams; 34| | 35| |@end 36| | 37| |@implementation FBSDKDeactivatedEvent 38| | 39| |- (instancetype)initWithEventName:(NSString *)eventName 40| | deactivatedParams:(NSSet *)deactivatedParams 41| 0|{ 42| 0| self = [super init]; 43| 0| if (self) { 44| 0| _eventName = eventName; 45| 0| _deactivatedParams = deactivatedParams; 46| 0| } 47| | 48| 0| return self; 49| 0|} 50| | 51| |@end 52| | 53| |@interface FBSDKEventDeactivationManager () 54| | 55| |@property BOOL isEventDeactivationEnabled; 56| |@property (nonatomic, strong) NSMutableSet *deactivatedEvents; 57| |@property (nonatomic, strong) NSMutableArray *eventsWithDeactivatedParams; 58| |@property (nonatomic) Class serverConfigurationProvider; 59| | 60| |@end 61| | 62| |@implementation FBSDKEventDeactivationManager 63| |+ (instancetype)shared 64| 0|{ 65| 0| static FBSDKEventDeactivationManager *instance; 66| 0| static dispatch_once_t nonce; 67| 0| dispatch_once(&nonce, ^{ 68| 0| instance = [[self alloc] initWithServerConfigurationProvider:FBSDKServerConfigurationManager.class]; 69| 0| }); 70| 0| return instance; 71| 0|} 72| | 73| |- (instancetype)initWithServerConfigurationProvider:(Class)serverConfigurationProvider 74| 0|{ 75| 0| self.isEventDeactivationEnabled = NO; 76| 0| self.serverConfigurationProvider = serverConfigurationProvider; 77| 0| return self; 78| 0|} 79| | 80| |- (void)enable 81| 0|{ 82| 0| @try { 83| 0| static dispatch_once_t onceToken; 84| 0| dispatch_once(&onceToken, ^{ 85| 0| NSDictionary *restrictiveParams = [self.serverConfigurationProvider cachedServerConfiguration].restrictiveParams; 86| 0| if (restrictiveParams) { 87| 0| [self _updateDeactivatedEvents:restrictiveParams]; 88| 0| self.isEventDeactivationEnabled = YES; 89| 0| } 90| 0| }); 91| 0| } @catch (NSException *exception) {} 92| 0|} 93| | 94| |- (void)processEvents:(NSMutableArray *> *)events 95| 0|{ 96| 0| @try { 97| 0| if (!self.isEventDeactivationEnabled) { 98| 0| return; 99| 0| } 100| 0| NSArray *> *eventArray = [events copy]; 101| 0| for (NSDictionary *> *event in eventArray) { 102| 0| if ([self.deactivatedEvents containsObject:event[@"event"][@"_eventName"]]) { 103| 0| [events removeObject:event]; 104| 0| } 105| 0| } 106| 0| } @catch (NSException *exception) {} 107| 0|} 108| | 109| |- (nullable NSDictionary *)processParameters:(nullable NSDictionary *)parameters 110| | eventName:(NSString *)eventName 111| 0|{ 112| 0| @try { 113| 0| if (!self.isEventDeactivationEnabled || parameters.count == 0 || self.eventsWithDeactivatedParams.count == 0) { 114| 0| return parameters; 115| 0| } 116| 0| NSMutableDictionary *params = [NSMutableDictionary dictionaryWithDictionary:parameters]; 117| 0| for (NSString *key in [parameters keyEnumerator]) { 118| 0| for (FBSDKDeactivatedEvent *event in self.eventsWithDeactivatedParams) { 119| 0| if ([event.eventName isEqualToString:eventName] && [event.deactivatedParams containsObject:key]) { 120| 0| [params removeObjectForKey:key]; 121| 0| } 122| 0| } 123| 0| } 124| 0| return [params copy]; 125| 0| } @catch (NSException *exception) { 126| 0| return parameters; 127| 0| } 128| 0|} 129| | 130| |#pragma mark - Private Method 131| | 132| |- (void)_updateDeactivatedEvents:(nullable NSDictionary *)events 133| 0|{ 134| 0| events = [FBSDKTypeUtility dictionaryValue:events]; 135| 0| if (events.count == 0) { 136| 0| return; 137| 0| } 138| 0| [self.deactivatedEvents removeAllObjects]; 139| 0| [self.eventsWithDeactivatedParams removeAllObjects]; 140| 0| NSMutableArray *deactivatedParamsArray = [NSMutableArray array]; 141| 0| NSMutableSet *deactivatedEventSet = [NSMutableSet set]; 142| 0| for (NSString *eventName in events.allKeys) { 143| 0| NSDictionary *eventInfo = [FBSDKTypeUtility dictionary:events objectForKey:eventName ofType:NSDictionary.class]; 144| 0| if (!eventInfo) { 145| 0| continue; 146| 0| } 147| 0| if (eventInfo[DEPRECATED_EVENT_KEY]) { 148| 0| [deactivatedEventSet addObject:eventName]; 149| 0| } 150| 0| if (eventInfo[DEPRECATED_PARAM_KEY]) { 151| 0| FBSDKDeactivatedEvent *eventWithDeactivatedParams = [[FBSDKDeactivatedEvent alloc] initWithEventName:eventName 152| 0| deactivatedParams:[NSSet setWithArray:eventInfo[DEPRECATED_PARAM_KEY]]]; 153| 0| [FBSDKTypeUtility array:deactivatedParamsArray addObject:eventWithDeactivatedParams]; 154| 0| } 155| 0| } 156| 0| self.deactivatedEvents = deactivatedEventSet; 157| 0| self.eventsWithDeactivatedParams = deactivatedParamsArray; 158| 0|} 159| | 160| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsAtePublisher.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKAppEventsAtePublisher.h" 20| | 21| |#if FBSDK_SWIFT_PACKAGE 22| | #import "FBSDKGraphRequestFlags.h" 23| | #import "FBSDKGraphRequestHTTPMethod.h" 24| |#else 25| | #import 26| | #import 27| |#endif 28| | 29| |#import "FBSDKAppEventsDeviceInfo.h" 30| |#import "FBSDKCoreKitBasicsImport.h" 31| |#import "FBSDKDataPersisting.h" 32| |#import "FBSDKGraphRequestConnecting.h" 33| |#import "FBSDKGraphRequestProtocol.h" 34| |#import "FBSDKGraphRequestProviding.h" 35| |#import "FBSDKInternalUtility.h" 36| |#import "FBSDKLogger.h" 37| |#import "FBSDKSettingsProtocol.h" 38| | 39| |@interface FBSDKAppEventsAtePublisher () 40| | 41| |@property (nullable, nonatomic) id graphRequestFactory; 42| |@property (nullable, nonatomic) id settings; 43| |@property (nullable, nonatomic) id store; 44| |@property (nonatomic) BOOL isProcessing; 45| | 46| |@end 47| | 48| |@implementation FBSDKAppEventsAtePublisher 49| | 50| |- (nullable instancetype)initWithAppIdentifier:(NSString *)appIdentifier 51| | graphRequestFactory:(id)graphRequestFactory 52| | settings:(id)settings 53| | store:(id)store 54| 0|{ 55| 0| if ((self = [self init])) { 56| 0| NSString *identifier = [FBSDKTypeUtility coercedToStringValue:appIdentifier]; 57| 0| if (identifier.length == 0) { 58| 0| [FBSDKLogger singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors logEntry:@"Missing [FBSDKAppEvents appID] for [FBSDKAppEvents publishATE:]"]; 59| 0| return nil; 60| 0| } 61| 0| _appIdentifier = identifier; 62| 0| _graphRequestFactory = graphRequestFactory; 63| 0| _settings = settings; 64| 0| _store = store; 65| 0| } 66| 0| return self; 67| 0|} 68| | 69| |- (void)publishATE 70| 0|{ 71| 0| if (self.isProcessing) { 72| 0| return; 73| 0| } 74| 0| self.isProcessing = YES; 75| 0| NSString *lastATEPingString = [NSString stringWithFormat:@"com.facebook.sdk:lastATEPing%@", self.appIdentifier]; 76| 0| id lastPublishDate = [self.store objectForKey:lastATEPingString]; 77| 0| if ([lastPublishDate isKindOfClass:[NSDate class]] && [(NSDate *)lastPublishDate timeIntervalSinceNow] * -1 < 24 * 60 * 60) { 78| 0| self.isProcessing = NO; 79| 0| return; 80| 0| } 81| | 82| 0| NSMutableDictionary *parameters = [NSMutableDictionary dictionary]; 83| 0| [FBSDKTypeUtility dictionary:parameters setObject:@"CUSTOM_APP_EVENTS" forKey:@"event"]; 84| | 85| 0| NSOperatingSystemVersion operatingSystemVersion = [FBSDKInternalUtility operatingSystemVersion]; 86| 0| NSString *osVersion = [NSString stringWithFormat:@"%ti.%ti.%ti", 87| 0| operatingSystemVersion.majorVersion, 88| 0| operatingSystemVersion.minorVersion, 89| 0| operatingSystemVersion.patchVersion]; 90| | 91| 0| NSArray *event = @[ 92| 0| @{ 93| 0| @"_eventName" : @"fb_mobile_ate_status", 94| 0| @"ate_status" : @(self.settings.advertisingTrackingStatus).stringValue, 95| 0| @"os_version" : osVersion, 96| 0| } 97| 0| ]; 98| 0| [FBSDKTypeUtility dictionary:parameters setObject:[FBSDKBasicUtility JSONStringForObject:event error:NULL invalidObjectHandler:NULL] forKey:@"custom_events"]; 99| | 100| 0| [FBSDKAppEventsDeviceInfo extendDictionaryWithDeviceInfo:parameters]; 101| | 102| 0| NSString *path = [NSString stringWithFormat:@"%@/activities", self.appIdentifier]; 103| 0| id request = [self.graphRequestFactory createGraphRequestWithGraphPath:path 104| 0| parameters:parameters 105| 0| tokenString:nil 106| 0| HTTPMethod:FBSDKHTTPMethodPOST 107| 0| flags:FBSDKGraphRequestFlagDoNotInvalidateTokenOnError | FBSDKGraphRequestFlagDisableErrorRecovery]; 108| 0| __block id weakStore = self.store; 109| 0| [request startWithCompletion:^(id connection, id result, NSError *error) { 110| 0| if (!error) { 111| 0| [weakStore setObject:[NSDate date] forKey:lastATEPingString]; 112| 0| } 113| 0| self.isProcessing = NO; 114| 0| }]; 115| | 116| 0|#if FBSDKTEST 117| 0| self.isProcessing = NO; 118| 0|#endif 119| 0|} 120| | 121| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsConfiguration.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKAppEventsConfiguration.h" 20| | 21| |#import "FBSDKCoreKitBasicsImport.h" 22| | 23| 0|#define FBSDK_APP_EVENTS_CONFIGURATION_DEFAULT_ATE_STATUS_KEY @"default_ate_status" 24| 0|#define FBSDK_APP_EVENTS_CONFIGURATION_ADVERTISER_ID_TRACKING_ENABLED_KEY @"advertiser_id_collection_enabled" 25| 0|#define FBSDK_APP_EVENTS_CONFIGURATION_EVENT_COLLECTION_ENABLED_KEY @"event_collection_enabled" 26| | 27| |@implementation FBSDKAppEventsConfiguration 28| | 29| |- (instancetype)initWithJSON:(nullable NSDictionary *)dict 30| 0|{ 31| 0| if ((self = [super init])) { 32| 0| @try { 33| 0| dict = [FBSDKTypeUtility dictionaryValue:dict]; 34| 0| if (!dict) { 35| 0| return FBSDKAppEventsConfiguration.defaultConfiguration; 36| 0| } 37| 0| NSDictionary *configs = [FBSDKTypeUtility dictionary:dict objectForKey:@"app_events_config" ofType:NSDictionary.class]; 38| 0| if (!configs) { 39| 0| return FBSDKAppEventsConfiguration.defaultConfiguration; 40| 0| } 41| 0| NSNumber *defaultATEStatus = [FBSDKTypeUtility numberValue:configs[FBSDK_APP_EVENTS_CONFIGURATION_DEFAULT_ATE_STATUS_KEY]] ?: @(FBSDKAdvertisingTrackingUnspecified); 42| 0| NSNumber *advertiserIDCollectionEnabled = [FBSDKTypeUtility numberValue:configs[FBSDK_APP_EVENTS_CONFIGURATION_ADVERTISER_ID_TRACKING_ENABLED_KEY]] ?: @(YES); 43| 0| NSNumber *eventCollectionEnabled = [FBSDKTypeUtility numberValue:configs[FBSDK_APP_EVENTS_CONFIGURATION_EVENT_COLLECTION_ENABLED_KEY]] ?: @(NO); 44| 0| _defaultATEStatus = [defaultATEStatus integerValue]; 45| 0| _advertiserIDCollectionEnabled = [advertiserIDCollectionEnabled boolValue]; 46| 0| _eventCollectionEnabled = [eventCollectionEnabled boolValue]; 47| 0| } @catch (NSException *exception) { 48| 0| return FBSDKAppEventsConfiguration.defaultConfiguration; 49| 0| } 50| 0| } 51| 0| return self; 52| 0|} 53| | 54| |- (instancetype)initWithDefaultATEStatus:(FBSDKAdvertisingTrackingStatus)defaultATEStatus 55| | advertiserIDCollectionEnabled:(BOOL)advertiserIDCollectionEnabled 56| | eventCollectionEnabled:(BOOL)eventCollectionEnabled 57| 0|{ 58| 0| if ((self = [super init])) { 59| 0| _defaultATEStatus = defaultATEStatus; 60| 0| _advertiserIDCollectionEnabled = advertiserIDCollectionEnabled; 61| 0| _eventCollectionEnabled = eventCollectionEnabled; 62| 0| } 63| 0| return self; 64| 0|} 65| | 66| |+ (instancetype)defaultConfiguration 67| 0|{ 68| 0| FBSDKAppEventsConfiguration *config = [[FBSDKAppEventsConfiguration alloc] initWithDefaultATEStatus:FBSDKAdvertisingTrackingUnspecified 69| 0| advertiserIDCollectionEnabled:YES 70| 0| eventCollectionEnabled:NO]; 71| 0| return config; 72| 0|} 73| | 74| |#pragma mark - NSCoding 75| | 76| |+ (BOOL)supportsSecureCoding 77| 0|{ 78| 0| return YES; 79| 0|} 80| | 81| |- (instancetype)initWithCoder:(NSCoder *)decoder 82| 0|{ 83| 0| FBSDKAdvertisingTrackingStatus defaultATEStatus = [decoder decodeIntegerForKey:FBSDK_APP_EVENTS_CONFIGURATION_DEFAULT_ATE_STATUS_KEY]; 84| 0| BOOL advertisingIDCollectionEnabled = [decoder decodeBoolForKey:FBSDK_APP_EVENTS_CONFIGURATION_ADVERTISER_ID_TRACKING_ENABLED_KEY]; 85| 0| BOOL eventCollectionEnabled = [decoder decodeBoolForKey:FBSDK_APP_EVENTS_CONFIGURATION_EVENT_COLLECTION_ENABLED_KEY]; 86| 0| return [[FBSDKAppEventsConfiguration alloc] initWithDefaultATEStatus:defaultATEStatus 87| 0| advertiserIDCollectionEnabled:advertisingIDCollectionEnabled 88| 0| eventCollectionEnabled:eventCollectionEnabled]; 89| 0|} 90| | 91| |- (void)encodeWithCoder:(NSCoder *)encoder 92| 0|{ 93| 0| [encoder encodeInteger:_defaultATEStatus forKey:FBSDK_APP_EVENTS_CONFIGURATION_DEFAULT_ATE_STATUS_KEY]; 94| 0| [encoder encodeBool:_advertiserIDCollectionEnabled forKey:FBSDK_APP_EVENTS_CONFIGURATION_ADVERTISER_ID_TRACKING_ENABLED_KEY]; 95| 0| [encoder encodeBool:_eventCollectionEnabled forKey:FBSDK_APP_EVENTS_CONFIGURATION_EVENT_COLLECTION_ENABLED_KEY]; 96| 0|} 97| | 98| |#pragma mark - NSCopying 99| | 100| |- (instancetype)copyWithZone:(NSZone *)zone 101| 0|{ 102| 0| return self; 103| 0|} 104| | 105| |#pragma mark - Testability 106| | 107| |#if DEBUG 108| | #if FBSDKTEST 109| | 110| |- (void)setDefaultATEStatus:(FBSDKAdvertisingTrackingStatus)status 111| 0|{ 112| 0| _defaultATEStatus = status; 113| 0|} 114| | 115| | #endif 116| |#endif 117| | 118| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsConfigurationManager.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKAppEventsConfigurationManager.h" 20| | 21| |#import "FBSDKCoreKitBasicsImport.h" 22| |#import "FBSDKDataPersisting.h" 23| |#import "FBSDKGraphRequestConnecting.h" 24| |#import "FBSDKGraphRequestConnectionProviding.h" 25| |#import "FBSDKGraphRequestProviding.h" 26| |#import "FBSDKSettingsProtocol.h" 27| | 28| |static NSString *const FBSDKAppEventsConfigurationKey = @"com.facebook.sdk:FBSDKAppEventsConfiguration"; 29| |static NSString *const FBSDKAppEventsConfigurationTimestampKey = @"com.facebook.sdk:FBSDKAppEventsConfigurationTimestamp"; 30| |static const NSTimeInterval kTimeout = 4.0; 31| | 32| |@interface FBSDKAppEventsConfigurationManager () 33| | 34| |@property (nullable, nonatomic) id store; 35| |@property (nullable, nonatomic) id settings; 36| |@property (nullable, nonatomic) id requestFactory; 37| |@property (nullable, nonatomic) id connectionFactory; 38| |@property (nonnull, nonatomic) FBSDKAppEventsConfiguration *configuration; 39| |@property (nonatomic) BOOL isLoadingConfiguration; 40| |@property (nonatomic) BOOL hasRequeryFinishedForAppStart; 41| |@property (nullable, nonatomic) NSDate *timestamp; 42| |@property (nullable, nonatomic) NSMutableArray *completionBlocks; 43| | 44| |@end 45| | 46| |@implementation FBSDKAppEventsConfigurationManager 47| | 48| |static dispatch_once_t sharedConfigurationManagerNonce; 49| | 50| |// Transitional singleton introduced as a way to change the usage semantics 51| |// from a type-based interface to an instance-based interface. 52| |// The goal of the refactor is to move callsites from: 53| |// ClassWithoutUnderlyingInstance -> ClassRelyingOnUnderlyingInstance -> Instance 54| |+ (FBSDKAppEventsConfigurationManager *)shared 55| 0|{ 56| 0| static id instance; 57| 0| dispatch_once(&sharedConfigurationManagerNonce, ^{ 58| 0| instance = [self new]; 59| 0| }); 60| 0| return instance; 61| 0|} 62| | 63| |+ (void) configureWithStore:(id)store 64| | settings:(id)settings 65| | graphRequestFactory:(id)graphRequestFactory 66| | graphRequestConnectionFactory:(id)graphRequestConnectionFactory 67| 0|{ 68| 0| [self.shared configureWithStore:store 69| 0| settings:settings 70| 0| graphRequestFactory:graphRequestFactory 71| 0| graphRequestConnectionFactory:graphRequestConnectionFactory]; 72| 0|} 73| | 74| |#pragma clang diagnostic push 75| |#pragma clang diagnostic ignored "-Wdeprecated-declarations" 76| |- (void) configureWithStore:(id)store 77| | settings:(id)settings 78| | graphRequestFactory:(id)graphRequestFactory 79| | graphRequestConnectionFactory:(id)graphRequestConnectionFactory 80| 0|{ 81| 0| self.store = store; 82| 0| self.settings = settings; 83| 0| self.requestFactory = graphRequestFactory; 84| 0| self.connectionFactory = graphRequestConnectionFactory; 85| 0| id data = [self.store objectForKey:FBSDKAppEventsConfigurationKey]; 86| 0| if ([data isKindOfClass:NSData.class]) { 87| 0| if (@available(iOS 11.0, tvOS 11.0, *)) { 88| 0| self.configuration = [NSKeyedUnarchiver unarchivedObjectOfClass:FBSDKAppEventsConfiguration.class fromData:data error:nil]; 89| 0| } else { 90| 0| self.configuration = [NSKeyedUnarchiver unarchiveObjectWithData:data]; 91| 0| } 92| 0| } 93| 0| if (!self.configuration) { 94| 0| self.configuration = [FBSDKAppEventsConfiguration defaultConfiguration]; 95| 0| } 96| 0| self.completionBlocks = [NSMutableArray new]; 97| 0| self.timestamp = [self.store objectForKey:FBSDKAppEventsConfigurationTimestampKey]; 98| 0|} 99| | 100| |#pragma clang diagnostic pop 101| | 102| |+ (FBSDKAppEventsConfiguration *)cachedAppEventsConfiguration 103| 0|{ 104| 0| return self.shared.cachedAppEventsConfiguration; 105| 0|} 106| | 107| |- (FBSDKAppEventsConfiguration *)cachedAppEventsConfiguration 108| 0|{ 109| 0| return self.configuration; 110| 0|} 111| | 112| |+ (void)loadAppEventsConfigurationWithBlock:(FBSDKAppEventsConfigurationManagerBlock)block 113| 0|{ 114| 0| [self.shared loadAppEventsConfigurationWithBlock:block]; 115| 0|} 116| | 117| |- (void)loadAppEventsConfigurationWithBlock:(FBSDKAppEventsConfigurationManagerBlock)block 118| 0|{ 119| 0| NSString *appID = self.settings.appID; 120| 0| @synchronized(self) { 121| 0| [FBSDKTypeUtility array:self.completionBlocks addObject:block]; 122| 0| if (!appID || (self.hasRequeryFinishedForAppStart && [self _isTimestampValid])) { 123| 0| for (FBSDKAppEventsConfigurationManagerBlock completionBlock in self.completionBlocks) { 124| 0| completionBlock(); 125| 0| } 126| 0| [self.completionBlocks removeAllObjects]; 127| 0| return; 128| 0| } 129| 0| if (self.isLoadingConfiguration) { 130| 0| return; 131| 0| } 132| 0| self.isLoadingConfiguration = true; 133| 0| id request = [self.requestFactory createGraphRequestWithGraphPath:appID 134| 0| parameters:@{ 135| 0| @"fields" : [NSString stringWithFormat:@"app_events_config.os_version(%@)", [UIDevice currentDevice].systemVersion] 136| 0| }]; 137| 0| id requestConnection = [self.connectionFactory createGraphRequestConnection]; 138| 0| requestConnection.timeout = kTimeout; 139| 0| [requestConnection addRequest:request completion:^(id connection, id result, NSError *error) { 140| 0| [self _processResponse:result error:error]; 141| 0| }]; 142| 0| [requestConnection start]; 143| 0| } 144| 0|} 145| | 146| |#pragma clang diagnostic push 147| |#pragma clang diagnostic ignored "-Wdeprecated-declarations" 148| |+ (void)_processResponse:(id)response 149| | error:(NSError *)error 150| 0|{ 151| 0| [self.shared _processResponse:response error:error]; 152| 0|} 153| | 154| |- (void)_processResponse:(id)response 155| | error:(NSError *)error 156| 0|{ 157| 0| NSDate *date = [NSDate date]; 158| 0| @synchronized(self) { 159| 0| self.isLoadingConfiguration = NO; 160| 0| self.hasRequeryFinishedForAppStart = YES; 161| 0| if (error) { 162| 0| return; 163| 0| } 164| 0| self.configuration = [[FBSDKAppEventsConfiguration alloc] initWithJSON:response]; 165| 0| self.timestamp = date; 166| 0| for (FBSDKAppEventsConfigurationManagerBlock completionBlock in self.completionBlocks) { 167| 0| completionBlock(); 168| 0| } 169| 0| [self.completionBlocks removeAllObjects]; 170| 0| } 171| 0| NSData *data = [NSKeyedArchiver archivedDataWithRootObject:self.configuration]; 172| 0| [self.store setObject:data forKey:FBSDKAppEventsConfigurationKey]; 173| 0| [self.store setObject:date forKey:FBSDKAppEventsConfigurationTimestampKey]; 174| 0|} 175| | 176| |#pragma clang diagnostic pop 177| | 178| |- (BOOL)_isTimestampValid 179| 0|{ 180| 0| return self.timestamp && [[NSDate date] timeIntervalSinceDate:self.timestamp] < 3600; 181| 0|} 182| | 183| |#if DEBUG 184| | #if FBSDKTEST 185| | 186| |+ (void)reset 187| 0|{ 188| 0| [self.shared reset]; 189| 0|} 190| | 191| |- (void)reset 192| 0|{ 193| | // Reset the nonce so that a new instance will be created. 194| 0| if (sharedConfigurationManagerNonce) { 195| 0| sharedConfigurationManagerNonce = 0; 196| 0| } 197| 0|} 198| | 199| | #endif 200| |#endif 201| | 202| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsDeviceInfo.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKAppEventsDeviceInfo.h" 20| | 21| |#import 22| |#import 23| | 24| |#if !TARGET_OS_TV 25| | #import 26| | #import 27| |#endif 28| | 29| |#import 30| |#import 31| | 32| |#import "FBSDKAppEventsUtility.h" 33| |#import "FBSDKCoreKitBasicsImport.h" 34| |#import "FBSDKDynamicFrameworkLoader.h" 35| |#import "FBSDKInternalUtility.h" 36| |#import "FBSDKSettings+Internal.h" 37| | 38| 0|#define FB_ARRAY_COUNT(x) sizeof(x) / sizeof(x[0]) 39| | 40| |static const u_int FB_GROUP1_RECHECK_DURATION = 30 * 60; // seconds 41| | 42| |// Apple reports storage in binary gigabytes (1024^3) in their About menus, etc. 43| |static const u_int FB_GIGABYTE = 1024 * 1024 * 1024; // bytes 44| | 45| |@implementation FBSDKAppEventsDeviceInfo 46| |{ 47| | // Ephemeral data, may change during the lifetime of an app. We collect them in different 48| | // 'group' frequencies - group1 may gets collected once every 30 minutes. 49| | 50| | // group1 51| | NSString *_carrierName; 52| | NSString *_timeZoneAbbrev; 53| | unsigned long long _remainingDiskSpaceGB; 54| | NSString *_timeZoneName; 55| | 56| | // Persistent data, but we maintain it to make rebuilding the device info as fast as possible. 57| | NSString *_bundleIdentifier; 58| | NSString *_longVersion; 59| | NSString *_shortVersion; 60| | NSString *_sysVersion; 61| | NSString *_machine; 62| | NSString *_language; 63| | unsigned long long _totalDiskSpaceGB; 64| | unsigned long long _coreCount; 65| | CGFloat _width; 66| | CGFloat _height; 67| | CGFloat _density; 68| | 69| | // Other state 70| | long _lastGroup1CheckTime; 71| | BOOL _isEncodingDirty; 72| | NSString *_encodedDeviceInfo; 73| |} 74| | 75| |#pragma mark - Public Methods 76| | 77| |+ (void)extendDictionaryWithDeviceInfo:(NSMutableDictionary *)dictionary 78| 0|{ 79| 0| [FBSDKTypeUtility dictionary:dictionary setObject:[[self sharedDeviceInfo] encodedDeviceInfo] forKey:@"extinfo"]; 80| 0|} 81| | 82| |#pragma mark - Internal Methods 83| | 84| |+ (void)initialize 85| 0|{ 86| 0| if (self == [FBSDKAppEventsDeviceInfo class]) { 87| 0| [[self sharedDeviceInfo] _collectPersistentData]; 88| 0| } 89| 0|} 90| | 91| |+ (instancetype)sharedDeviceInfo 92| 0|{ 93| 0| static FBSDKAppEventsDeviceInfo *_sharedDeviceInfo = nil; 94| 0| if (_sharedDeviceInfo == nil) { 95| 0| _sharedDeviceInfo = [FBSDKAppEventsDeviceInfo new]; 96| 0| } 97| 0| return _sharedDeviceInfo; 98| 0|} 99| | 100| |- (instancetype)init 101| 0|{ 102| 0| if ((self = [super init])) { 103| 0| _isEncodingDirty = YES; 104| 0| } 105| 0| return self; 106| 0|} 107| | 108| |- (NSString *)encodedDeviceInfo 109| 0|{ 110| 0| @synchronized(self) { 111| 0| BOOL isGroup1Expired = [self _isGroup1Expired]; 112| 0| BOOL isEncodingExpired = isGroup1Expired; // Can || other groups in if we add them 113| | 114| | // As long as group1 hasn't expired, we can just return the last generated value 115| 0| if (_encodedDeviceInfo && !isEncodingExpired) { 116| 0| return _encodedDeviceInfo; 117| 0| } 118| | 119| 0| if (isGroup1Expired) { 120| 0| [self _collectGroup1Data]; 121| 0| } 122| | 123| 0| if (_isEncodingDirty) { 124| 0| self.encodedDeviceInfo = [self _generateEncoding]; 125| 0| _isEncodingDirty = NO; 126| 0| } 127| | 128| 0| return _encodedDeviceInfo; 129| 0| } 130| 0|} 131| | 132| |- (void)setEncodedDeviceInfo:(NSString *)encodedDeviceInfo 133| 0|{ 134| 0| @synchronized(self) { 135| 0| if (![_encodedDeviceInfo isEqualToString:encodedDeviceInfo]) { 136| 0| _encodedDeviceInfo = [encodedDeviceInfo copy]; 137| 0| } 138| 0| } 139| 0|} 140| | 141| |// This data need only be collected once. 142| |- (void)_collectPersistentData 143| 0|{ 144| | // Bundle stuff 145| 0| NSBundle *mainBundle = [NSBundle mainBundle]; 146| 0| _bundleIdentifier = mainBundle.bundleIdentifier; 147| 0| _longVersion = [mainBundle objectForInfoDictionaryKey:@"CFBundleVersion"]; 148| 0| _shortVersion = [mainBundle objectForInfoDictionaryKey:@"CFBundleShortVersionString"]; 149| | 150| | // Locale stuff 151| 0| _language = [NSLocale currentLocale].localeIdentifier; 152| | 153| | // Device stuff 154| 0| UIDevice *device = [UIDevice currentDevice]; 155| 0| _sysVersion = device.systemVersion; 156| 0| _coreCount = [FBSDKAppEventsDeviceInfo _coreCount]; 157| | 158| 0| UIScreen *sc = [UIScreen mainScreen]; 159| 0| CGRect sr = sc.bounds; 160| 0| _width = sr.size.width; 161| 0| _height = sr.size.height; 162| 0| _density = sc.scale; 163| | 164| 0| struct utsname systemInfo; 165| 0| uname(&systemInfo); 166| 0| _machine = @(systemInfo.machine); 167| | 168| | // Disk space stuff 169| 0| float totalDiskSpace = [FBSDKAppEventsDeviceInfo _getTotalDiskSpace].floatValue; 170| 0| _totalDiskSpaceGB = (unsigned long long)round(totalDiskSpace / FB_GIGABYTE); 171| 0|} 172| | 173| |- (BOOL)_isGroup1Expired 174| 0|{ 175| 0| return ([self unixTimeNow] - _lastGroup1CheckTime) > FB_GROUP1_RECHECK_DURATION; 176| 0|} 177| | 178| |// This data is collected only once every GROUP1_RECHECK_DURATION. 179| |- (void)_collectGroup1Data 180| 0|{ 181| 0| const BOOL shouldUseCachedValues = [FBSDKSettings shouldUseCachedValuesForExpensiveMetadata]; 182| | 183| 0| if (!_carrierName || !shouldUseCachedValues) { 184| 0| NSString *newCarrierName = [FBSDKAppEventsDeviceInfo _getCarrier]; 185| 0| if (!_carrierName || ![newCarrierName isEqualToString:_carrierName]) { 186| 0| _carrierName = newCarrierName; 187| 0| _isEncodingDirty = YES; 188| 0| } 189| 0| } 190| | 191| 0| if (!_timeZoneName || !_timeZoneAbbrev || !shouldUseCachedValues) { 192| 0| NSTimeZone *timeZone = [NSTimeZone systemTimeZone]; 193| 0| NSString *timeZoneName = timeZone.name; 194| 0| if (!_timeZoneName || ![timeZoneName isEqualToString:_timeZoneName]) { 195| 0| _timeZoneName = timeZoneName; 196| 0| _timeZoneAbbrev = timeZone.abbreviation; 197| 0| _isEncodingDirty = YES; 198| 0| } 199| 0| } 200| | 201| | // Remaining disk space 202| 0| float remainingDiskSpace = [FBSDKAppEventsDeviceInfo _getRemainingDiskSpace].floatValue; 203| 0| unsigned long long newRemainingDiskSpaceGB = (unsigned long long)round(remainingDiskSpace / FB_GIGABYTE); 204| 0| if (_remainingDiskSpaceGB != newRemainingDiskSpaceGB) { 205| 0| _remainingDiskSpaceGB = newRemainingDiskSpaceGB; 206| 0| _isEncodingDirty = YES; 207| 0| } 208| | 209| 0| _lastGroup1CheckTime = [self unixTimeNow]; 210| 0|} 211| | 212| |- (NSString *)_generateEncoding 213| 0|{ 214| | // Keep a bit of precision on density as it's the most likely to become non-integer. 215| 0| NSString *densityString = _density ? [NSString stringWithFormat:@"%.02f", _density] : @""; 216| | 217| 0| NSArray *arr = @[ 218| 0| @"i2", // version - starts with 'i' for iOS, we'll use 'a' for Android 219| 0| _bundleIdentifier ?: @"", 220| 0| _longVersion ?: @"", 221| 0| _shortVersion ?: @"", 222| 0| _sysVersion ?: @"", 223| 0| _machine ?: @"", 224| 0| _language ?: @"", 225| 0| _timeZoneAbbrev ?: @"", 226| 0| _carrierName ?: @"", 227| 0| _width ? @((unsigned long)_width) : @"", 228| 0| _height ? @((unsigned long)_height) : @"", 229| 0| densityString, 230| 0| @(_coreCount) ?: @"", 231| 0| @(_totalDiskSpaceGB) ?: @"", 232| 0| @(_remainingDiskSpaceGB) ?: @"", 233| 0| _timeZoneName ?: @"" 234| 0| ]; 235| | 236| 0| return [FBSDKBasicUtility JSONStringForObject:arr error:NULL invalidObjectHandler:NULL]; 237| 0|} 238| | 239| |#pragma mark - Helper Methods 240| | 241| |- (NSTimeInterval)unixTimeNow 242| 0|{ 243| 0| return round([NSDate date].timeIntervalSince1970); 244| 0|} 245| | 246| |+ (NSNumber *)_getTotalDiskSpace 247| 0|{ 248| 0| NSDictionary *attrs = [[NSFileManager new] attributesOfFileSystemForPath:NSHomeDirectory() 249| 0| error:nil]; 250| 0| return attrs[NSFileSystemSize]; 251| 0|} 252| | 253| |+ (NSNumber *)_getRemainingDiskSpace 254| 0|{ 255| 0| NSDictionary *attrs = [[NSFileManager new] attributesOfFileSystemForPath:NSHomeDirectory() 256| 0| error:nil]; 257| 0| return attrs[NSFileSystemFreeSize]; 258| 0|} 259| | 260| |+ (uint)_coreCount 261| 0|{ 262| 0| return [FBSDKAppEventsDeviceInfo _readSysCtlUInt:CTL_HW type:HW_AVAILCPU]; 263| 0|} 264| | 265| |+ (uint)_readSysCtlUInt:(int)ctl type:(int)type 266| 0|{ 267| 0| int mib[2] = {ctl, type}; 268| 0| uint value; 269| 0| size_t size = sizeof value; 270| 0| if (0 != sysctl(mib, FB_ARRAY_COUNT(mib), &value, &size, NULL, 0)) { 271| 0| return 0; 272| 0| } 273| 0| return value; 274| 0|} 275| | 276| |#pragma clang diagnostic push 277| |#pragma clang diagnostic ignored "-Wdeprecated-declarations" 278| |+ (NSString *)_getCarrier 279| 0|{ 280| 0|#if TARGET_OS_TV || TARGET_OS_SIMULATOR 281| 0| return @"NoCarrier"; 282| |#else 283| | // Dynamically load class for this so calling app doesn't need to link framework in. 284| | CTTelephonyNetworkInfo *networkInfo = [[fbsdkdfl_CTTelephonyNetworkInfoClass() alloc] init]; 285| | CTCarrier *carrier = networkInfo.subscriberCellularProvider; 286| | return carrier.carrierName ?: @"NoCarrier"; 287| |#endif 288| 0|} 289| | 290| |#pragma clang diagnostic pop 291| | 292| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsNumberParser.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKAppEventsNumberParser.h" 20| | 21| |@implementation FBSDKAppEventsNumberParser 22| |{ 23| | NSLocale *_locale; 24| |} 25| | 26| |- (instancetype)initWithLocale:(NSLocale *)locale 27| 0|{ 28| 0| if ((self = [self init])) { 29| 0| _locale = locale; 30| 0| } 31| 0| return self; 32| 0|} 33| | 34| |- (NSNumber *)parseNumberFrom:(NSString *)string 35| 0|{ 36| 0| NSNumber *value = @0; 37| | 38| 0| NSString *ds = [_locale objectForKey:NSLocaleDecimalSeparator] ?: @"."; 39| 0| NSString *gs = [_locale objectForKey:NSLocaleGroupingSeparator] ?: @","; 40| 0| NSString *separators = [ds stringByAppendingString:gs]; 41| | 42| 0| NSString *regex = [NSString stringWithFormat:@"[+-]?([0-9]+[%1$@]?)?[%1$@]?([0-9]+[%1$@]?)+", separators]; 43| 0| NSRegularExpression *re = [NSRegularExpression regularExpressionWithPattern:regex 44| 0| options:0 45| 0| error:nil]; 46| 0| NSTextCheckingResult *match = [re firstMatchInString:string 47| 0| options:0 48| 0| range:NSMakeRange(0, string.length)]; 49| 0| if (match) { 50| 0| NSString *validText = [string substringWithRange:match.range]; 51| 0| NSNumberFormatter *formatter = [NSNumberFormatter new]; 52| 0| formatter.locale = _locale; 53| 0| formatter.numberStyle = NSNumberFormatterDecimalStyle; 54| | 55| 0| value = [formatter numberFromString:validText]; 56| 0| if (nil == value) { 57| 0| value = @(validText.floatValue); 58| 0| } 59| 0| } 60| | 61| 0| return value; 62| 0|} 63| | 64| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsState.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKAppEventsState.h" 20| | 21| |#import "FBSDKCoreKitBasicsImport.h" 22| | 23| 0|#define FBSDK_APPEVENTSTATE_ISIMPLICIT_KEY @"isImplicit" 24| | 25| 0|#define FBSDK_APPEVENTSSTATE_MAX_EVENTS 1000 26| | 27| 0|#define FBSDK_APPEVENTSSTATE_APPID_KEY @"appID" 28| 0|#define FBSDK_APPEVENTSSTATE_EVENTS_KEY @"events" 29| 0|#define FBSDK_APPEVENTSSTATE_NUMSKIPPED_KEY @"numSkipped" 30| 0|#define FBSDK_APPEVENTSSTATE_TOKENSTRING_KEY @"tokenString" 31| 0|#define FBSDK_APPEVENTSTATE_RECEIPTDATA_KEY @"receipt_data" 32| 0|#define FBSDK_APPEVENTSTATE_RECEIPTID_KEY @"receipt_id" 33| | 34| |static NSArray> *_eventProcessors; 35| | 36| |@implementation FBSDKAppEventsState 37| |{ 38| | NSMutableArray *_mutableEvents; 39| |} 40| | 41| |+ (void)configureWithEventProcessors:(nonnull NSArray> *)eventProcessors 42| 0|{ 43| 0| _eventProcessors = eventProcessors; 44| 0|} 45| | 46| |- (instancetype)initWithToken:(NSString *)tokenString appID:(NSString *)appID 47| 0|{ 48| 0| if ((self = [super init])) { 49| 0| _tokenString = [tokenString copy]; 50| 0| _appID = [appID copy]; 51| 0| _mutableEvents = [NSMutableArray array]; 52| 0| } 53| 0| return self; 54| 0|} 55| | 56| |- (instancetype)copyWithZone:(NSZone *)zone 57| 0|{ 58| 0| FBSDKAppEventsState *copy = [[FBSDKAppEventsState allocWithZone:zone] initWithToken:_tokenString appID:_appID]; 59| 0| if (copy) { 60| 0| [copy->_mutableEvents addObjectsFromArray:_mutableEvents]; 61| 0| copy->_numSkipped = _numSkipped; 62| 0| } 63| 0| return copy; 64| 0|} 65| | 66| |#pragma mark - NSCoding 67| | 68| |+ (BOOL)supportsSecureCoding 69| 0|{ 70| 0| return YES; 71| 0|} 72| | 73| |- (id)initWithCoder:(NSCoder *)decoder 74| 0|{ 75| 0| NSString *appID = [decoder decodeObjectOfClass:[NSString class] forKey:FBSDK_APPEVENTSSTATE_APPID_KEY]; 76| 0| NSString *tokenString = [decoder decodeObjectOfClass:[NSString class] forKey:FBSDK_APPEVENTSSTATE_TOKENSTRING_KEY]; 77| 0| NSArray *events = [FBSDKTypeUtility arrayValue:[decoder decodeObjectOfClasses: 78| 0| [NSSet setWithArray:@[NSArray.class, NSDictionary.class]] 79| 0| forKey:FBSDK_APPEVENTSSTATE_EVENTS_KEY]]; 80| 0| NSUInteger numSkipped = [[decoder decodeObjectOfClass:[NSNumber class] forKey:FBSDK_APPEVENTSSTATE_NUMSKIPPED_KEY] unsignedIntegerValue]; 81| | 82| 0| if ((self = [self initWithToken:tokenString appID:appID])) { 83| 0| _mutableEvents = [NSMutableArray arrayWithArray:events]; 84| 0| _numSkipped = numSkipped; 85| 0| } 86| 0| return self; 87| 0|} 88| | 89| |- (void)encodeWithCoder:(NSCoder *)encoder 90| 0|{ 91| 0| [encoder encodeObject:_appID forKey:FBSDK_APPEVENTSSTATE_APPID_KEY]; 92| 0| [encoder encodeObject:_tokenString forKey:FBSDK_APPEVENTSSTATE_TOKENSTRING_KEY]; 93| 0| [encoder encodeObject:@(_numSkipped) forKey:FBSDK_APPEVENTSSTATE_NUMSKIPPED_KEY]; 94| 0| [encoder encodeObject:_mutableEvents forKey:FBSDK_APPEVENTSSTATE_EVENTS_KEY]; 95| 0|} 96| | 97| |#pragma mark - Implementation 98| | 99| |- (NSArray *)events 100| 0|{ 101| 0| return [_mutableEvents copy]; 102| 0|} 103| | 104| |- (void)addEventsFromAppEventState:(FBSDKAppEventsState *)appEventsState 105| 0|{ 106| 0| NSArray *toAdd = appEventsState->_mutableEvents; 107| 0| NSInteger excess = _mutableEvents.count + toAdd.count - FBSDK_APPEVENTSSTATE_MAX_EVENTS; 108| 0| if (excess > 0) { 109| 0| NSInteger range = FBSDK_APPEVENTSSTATE_MAX_EVENTS - _mutableEvents.count; 110| 0| toAdd = [toAdd subarrayWithRange:NSMakeRange(0, range)]; 111| 0| _numSkipped += excess; 112| 0| } 113| | 114| 0| [_mutableEvents addObjectsFromArray:toAdd]; 115| 0|} 116| | 117| |- (void)addEvent:(NSDictionary *)eventDictionary 118| | isImplicit:(BOOL)isImplicit 119| 0|{ 120| 0| if (_mutableEvents.count >= FBSDK_APPEVENTSSTATE_MAX_EVENTS) { 121| 0| _numSkipped++; 122| 0| } else { 123| 0| [FBSDKTypeUtility array:_mutableEvents addObject:@{ 124| 0| @"event" : [eventDictionary mutableCopy], 125| 0| FBSDK_APPEVENTSTATE_ISIMPLICIT_KEY : @(isImplicit) 126| 0| }]; 127| 0| } 128| 0|} 129| | 130| |- (NSString *)extractReceiptData 131| 0|{ 132| 0| NSMutableString *receipts_string = [NSMutableString string]; 133| 0| NSInteger transactionId = 1; 134| 0| for (NSMutableDictionary *events in _mutableEvents) { 135| 0| NSMutableDictionary *event = events[@"event"]; 136| | 137| 0| NSString *receipt = event[@"receipt_data"]; 138| | // Add receipt id as the identifier for receipt data in event parameter. 139| | // Receipt data will be sent as post parameter rather than the event parameter 140| 0| if (receipt) { 141| 0| NSString *idKey = [NSString stringWithFormat:@"receipt_%ld", (long)transactionId]; 142| 0| [FBSDKTypeUtility dictionary:event setObject:idKey forKey:FBSDK_APPEVENTSTATE_RECEIPTID_KEY]; 143| 0| NSString *receiptWithId = [NSString stringWithFormat:@"%@::%@;;;", idKey, receipt]; 144| 0| [receipts_string appendString:receiptWithId]; 145| 0| transactionId++; 146| 0| } 147| 0| } 148| 0| return receipts_string; 149| 0|} 150| | 151| |- (BOOL)areAllEventsImplicit 152| 0|{ 153| 0| for (NSDictionary *event in _mutableEvents) { 154| 0| if (![[event valueForKey:FBSDK_APPEVENTSTATE_ISIMPLICIT_KEY] boolValue]) { 155| 0| return NO; 156| 0| } 157| 0| } 158| 0| return YES; 159| 0|} 160| | 161| |- (BOOL)isCompatibleWithAppEventsState:(FBSDKAppEventsState *)appEventsState 162| 0|{ 163| 0| return ([self isCompatibleWithTokenString:appEventsState.tokenString appID:appEventsState.appID]); 164| 0|} 165| | 166| |- (BOOL)isCompatibleWithTokenString:(NSString *)tokenString appID:(NSString *)appID 167| 0|{ 168| | // token strings can be nil (e.g., no user token) but appIDs should not. 169| 0| BOOL tokenCompatible = ([self.tokenString isEqualToString:tokenString] 170| 0| || (self.tokenString == nil && tokenString == nil)); 171| 0| return (tokenCompatible 172| 0| && [self.appID isEqualToString:appID]); 173| 0|} 174| | 175| |- (NSString *)JSONStringForEventsIncludingImplicitEvents:(BOOL)includeImplicitEvents 176| 0|{ 177| 0| if (_eventProcessors != nil) { 178| 0| for (id processor in _eventProcessors) { 179| 0| [processor processEvents:_mutableEvents]; 180| 0| } 181| 0| } 182| 0| NSMutableArray *events = [[NSMutableArray alloc] initWithCapacity:_mutableEvents.count]; 183| 0| for (NSDictionary *eventAndImplicitFlag in _mutableEvents) { 184| 0| const BOOL isImplicitEvent = [eventAndImplicitFlag[FBSDK_APPEVENTSTATE_ISIMPLICIT_KEY] boolValue]; 185| 0| if (!includeImplicitEvents && isImplicitEvent) { 186| 0| continue; 187| 0| } 188| 0| NSMutableDictionary *event = eventAndImplicitFlag[@"event"]; 189| 0| NSAssert(event != nil, @"event cannot be nil"); 190| 0| [event removeObjectForKey:FBSDK_APPEVENTSTATE_RECEIPTDATA_KEY]; 191| | 192| 0| [FBSDKTypeUtility array:events addObject:event]; 193| 0| } 194| | 195| 0| return [FBSDKBasicUtility JSONStringForObject:events error:NULL invalidObjectHandler:NULL]; 196| 0|} 197| | 198| |#ifdef DEBUG 199| | #ifdef FBSDKTEST 200| |+ (NSArray> *)eventProcessors 201| 0|{ 202| 0| return _eventProcessors; 203| 0|} 204| | 205| | #endif 206| |#endif 207| | 208| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsStateFactory.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKAppEventsStateFactory.h" 20| | 21| |#import 22| | 23| |#import "FBSDKAppEventsState.h" 24| | 25| |@implementation FBSDKAppEventsStateFactory 26| | 27| |- (FBSDKAppEventsState *)createStateWithToken:(NSString *)tokenString appID:(NSString *)appID 28| 0|{ 29| 0| return [[FBSDKAppEventsState alloc] initWithToken:tokenString appID:appID]; 30| 0|} 31| | 32| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsStateManager.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKAppEventsStateManager.h" 20| | 21| |#import 22| | 23| |#import "FBSDKAppEventsState.h" 24| |#import "FBSDKAppEventsUtility.h" 25| |#import "FBSDKCoreKitBasicsImport.h" 26| |#import "FBSDKLogger.h" 27| |#import "FBSDKSettings.h" 28| |#import "FBSDKUnarchiverProvider.h" 29| | 30| |@interface FBSDKAppEventsStateManager (Internal) 31| |// A quick optimization to allow returning empty array if we know there are no persisted events. 32| |@property (nonatomic, readwrite, assign) BOOL canSkipDiskCheck; 33| |@end 34| | 35| |@implementation FBSDKAppEventsStateManager 36| |{ 37| | BOOL _canSkipDiskCheck; 38| |} 39| | 40| |- (instancetype)init 41| 0|{ 42| 0| self.canSkipDiskCheck = NO; 43| 0| return self; 44| 0|} 45| | 46| |- (void)setCanSkipDiskCheck:(BOOL)canSkipDiskCheck 47| 0|{ 48| 0| _canSkipDiskCheck = canSkipDiskCheck; 49| 0|} 50| | 51| |- (BOOL)canSkipDiskCheck 52| 0|{ 53| 0| return _canSkipDiskCheck; 54| 0|} 55| | 56| |+ (FBSDKAppEventsStateManager *)shared 57| 0|{ 58| 0| static dispatch_once_t nonce; 59| 0| static FBSDKAppEventsStateManager *instance = nil; 60| | 61| 0| dispatch_once(&nonce, ^{ 62| 0| instance = [FBSDKAppEventsStateManager new]; 63| 0| }); 64| 0| return instance; 65| 0|} 66| | 67| |- (void)clearPersistedAppEventsStates 68| 0|{ 69| 0| [FBSDKLogger singleShotLogEntry:FBSDKLoggingBehaviorAppEvents 70| 0| logEntry:@"FBSDKAppEvents Persist: Clearing"]; 71| 0| [[NSFileManager defaultManager] removeItemAtPath:[self filePath] 72| 0| error:NULL]; 73| 0| self.canSkipDiskCheck = YES; 74| 0|} 75| | 76| |#pragma clang diagnostic push 77| |#pragma clang diagnostic ignored "-Wdeprecated-declarations" 78| |- (void)persistAppEventsData:(FBSDKAppEventsState *)appEventsState 79| 0|{ 80| 0| NSString *msg = [NSString stringWithFormat:@"FBSDKAppEvents Persist: Writing %lu events", (unsigned long)appEventsState.events.count]; 81| 0| [FBSDKLogger singleShotLogEntry:FBSDKLoggingBehaviorAppEvents 82| 0| logEntry:msg]; 83| | 84| 0| if (!appEventsState.events.count) { 85| 0| return; 86| 0| } 87| 0| NSMutableArray *existingEvents = [NSMutableArray arrayWithArray:[self retrievePersistedAppEventsStates]]; 88| 0| [FBSDKTypeUtility array:existingEvents addObject:appEventsState]; 89| | 90| 0| [NSKeyedArchiver archiveRootObject:existingEvents toFile:[self filePath]]; 91| 0| self.canSkipDiskCheck = NO; 92| 0|} 93| | 94| |- (NSArray *)retrievePersistedAppEventsStates 95| 0|{ 96| 0| NSMutableArray *eventsStates = [NSMutableArray array]; 97| 0| if (!self.canSkipDiskCheck) { 98| 0| NSData *data = [[NSData alloc] initWithContentsOfFile:[self filePath] options:NSDataReadingMappedIfSafe error:NULL]; 99| 0| id unarchiver = [FBSDKUnarchiverProvider createSecureUnarchiverFor:data]; 100| 0| @try { 101| 0| NSArray *retrievedEvents = [unarchiver decodeObjectOfClasses: 102| 0| [NSSet setWithObjects:NSArray.class, FBSDKAppEventsState.class, NSDictionary.class, nil] 103| 0| forKey:NSKeyedArchiveRootObjectKey]; 104| 0| [eventsStates addObjectsFromArray:[FBSDKTypeUtility arrayValue:retrievedEvents]]; 105| 0| } @catch (NSException *ex) { 106| | // ignore decoding exceptions from previous versions of the archive, etc 107| 0| } 108| | 109| 0| NSString *msg = [NSString stringWithFormat:@"FBSDKAppEvents Persist: Read %lu event states. First state has %lu events", 110| 0| (unsigned long)eventsStates.count, 111| 0| (unsigned long)(eventsStates.count > 0 ? ((FBSDKAppEventsState *)[FBSDKTypeUtility array:eventsStates objectAtIndex:0]).events.count : 0)]; 112| 0| [FBSDKLogger singleShotLogEntry:FBSDKLoggingBehaviorAppEvents 113| 0| logEntry:msg]; 114| 0| [self clearPersistedAppEventsStates]; 115| 0| } 116| 0| return eventsStates; 117| 0|} 118| | 119| |#pragma clang diagnostic pop 120| | 121| |#pragma mark - Private Helpers 122| | 123| |- (NSString *)filePath 124| 0|{ 125| 0| return [FBSDKBasicUtility persistenceFilePath:@"com-facebook-sdk-AppEventsPersistedEvents.json"]; 126| 0|} 127| | 128| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsUtility.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKAppEventsUtility.h" 20| | 21| |#import 22| | 23| |#import 24| | 25| |#import "FBSDKAccessToken.h" 26| |#import "FBSDKAppEvents.h" 27| |#import "FBSDKAppEventsConfiguration.h" 28| |#import "FBSDKAppEventsConfigurationManager.h" 29| |#import "FBSDKAppEventsDeviceInfo.h" 30| |#import "FBSDKConstants.h" 31| |#import "FBSDKCoreKitBasicsImport.h" 32| |#import "FBSDKDynamicFrameworkLoader.h" 33| |#import "FBSDKError.h" 34| |#import "FBSDKInternalUtility.h" 35| |#import "FBSDKLogger.h" 36| |#import "FBSDKSettings.h" 37| |#import "FBSDKSettings+Internal.h" 38| | 39| 0|#define FBSDK_APPEVENTSUTILITY_ANONYMOUSIDFILENAME @"com-facebook-sdk-PersistedAnonymousID.json" 40| 0|#define FBSDK_APPEVENTSUTILITY_ANONYMOUSID_KEY @"anon_id" 41| 0|#define FBSDK_APPEVENTSUTILITY_MAX_IDENTIFIER_LENGTH 40 42| | 43| |static NSArray *standardEvents; 44| |static ASIdentifierManager *_cachedAdvertiserIdentifierManager; 45| | 46| |@implementation FBSDKAppEventsUtility 47| | 48| |+ (void)initialize 49| 0|{ 50| 0| standardEvents = @[ 51| 0| FBSDKAppEventNameCompletedRegistration, 52| 0| FBSDKAppEventNameViewedContent, 53| 0| FBSDKAppEventNameSearched, 54| 0| FBSDKAppEventNameRated, 55| 0| FBSDKAppEventNameCompletedTutorial, 56| 0| FBSDKAppEventNameAddedToCart, 57| 0| FBSDKAppEventNameAddedToWishlist, 58| 0| FBSDKAppEventNameInitiatedCheckout, 59| 0| FBSDKAppEventNameAddedPaymentInfo, 60| 0| FBSDKAppEventNamePurchased, 61| 0| FBSDKAppEventNameAchievedLevel, 62| 0| FBSDKAppEventNameUnlockedAchievement, 63| 0| FBSDKAppEventNameSpentCredits, 64| 0| FBSDKAppEventNameContact, 65| 0| FBSDKAppEventNameCustomizeProduct, 66| 0| FBSDKAppEventNameDonate, 67| 0| FBSDKAppEventNameFindLocation, 68| 0| FBSDKAppEventNameSchedule, 69| 0| FBSDKAppEventNameStartTrial, 70| 0| FBSDKAppEventNameSubmitApplication, 71| 0| FBSDKAppEventNameSubscribe, 72| 0| FBSDKAppEventNameAdImpression, 73| 0| FBSDKAppEventNameAdClick 74| 0| ]; 75| 0|} 76| | 77| |// Transitional singleton introduced as a way to change the usage semantics 78| |// from a type-based interface to an instance-based interface. 79| |// The goal is to move from: 80| |// ClassWithoutUnderlyingInstance -> ClassRelyingOnUnderlyingInstance -> Instance 81| |+ (instancetype)shared 82| 0|{ 83| 0| static dispatch_once_t nonce; 84| 0| static id instance; 85| 0| dispatch_once(&nonce, ^{ 86| 0| instance = [self new]; 87| 0| }); 88| 0| return instance; 89| 0|} 90| | 91| |+ (NSMutableDictionary *)activityParametersDictionaryForEvent:(NSString *)eventCategory 92| | shouldAccessAdvertisingID:(BOOL)shouldAccessAdvertisingID 93| 0|{ 94| 0| NSMutableDictionary *parameters = [NSMutableDictionary dictionary]; 95| 0| [FBSDKTypeUtility dictionary:parameters setObject:eventCategory forKey:@"event"]; 96| | 97| 0| if (shouldAccessAdvertisingID) { 98| 0| NSString *advertiserID = [self.shared advertiserID]; 99| 0| [FBSDKTypeUtility dictionary:parameters setObject:advertiserID forKey:@"advertiser_id"]; 100| 0| } 101| | 102| 0| [FBSDKTypeUtility dictionary:parameters setObject:[FBSDKBasicUtility anonymousID] forKey:FBSDK_APPEVENTSUTILITY_ANONYMOUSID_KEY]; 103| | 104| 0| FBSDKAdvertisingTrackingStatus advertisingTrackingStatus = [FBSDKSettings advertisingTrackingStatus]; 105| 0| if (advertisingTrackingStatus != FBSDKAdvertisingTrackingUnspecified) { 106| 0| [FBSDKTypeUtility dictionary:parameters setObject:@([FBSDKSettings isAdvertiserTrackingEnabled]).stringValue forKey:@"advertiser_tracking_enabled"]; 107| 0| } 108| | 109| 0| NSString *userData = [FBSDKAppEvents getUserData]; 110| 0| if (userData) { 111| 0| [FBSDKTypeUtility dictionary:parameters setObject:userData forKey:@"ud"]; 112| 0| } 113| | 114| 0| [FBSDKTypeUtility dictionary:parameters setObject:@(!FBSDKSettings.limitEventAndDataUsage).stringValue forKey:@"application_tracking_enabled"]; 115| 0| [FBSDKTypeUtility dictionary:parameters setObject:@(FBSDKSettings.advertiserIDCollectionEnabled).stringValue forKey:@"advertiser_id_collection_enabled"]; 116| | 117| 0| NSString *userID = [FBSDKAppEvents userID]; 118| 0| if (userID) { 119| 0| [FBSDKTypeUtility dictionary:parameters setObject:userID forKey:@"app_user_id"]; 120| 0| } 121| | 122| 0| NSDictionary *dataProcessingOptions = [FBSDKSettings dataProcessingOptions]; 123| 0| if (dataProcessingOptions) { 124| 0| NSArray *options = (NSArray *)dataProcessingOptions[DATA_PROCESSING_OPTIONS]; 125| 0| if (options && [options isKindOfClass:NSArray.class]) { 126| 0| NSString *optionsString = [FBSDKBasicUtility JSONStringForObject:options error:nil invalidObjectHandler:nil]; 127| 0| [FBSDKTypeUtility dictionary:parameters 128| 0| setObject:optionsString 129| 0| forKey:DATA_PROCESSING_OPTIONS]; 130| 0| } 131| 0| [FBSDKTypeUtility dictionary:parameters 132| 0| setObject:dataProcessingOptions[DATA_PROCESSING_OPTIONS_COUNTRY] 133| 0| forKey:DATA_PROCESSING_OPTIONS_COUNTRY]; 134| 0| [FBSDKTypeUtility dictionary:parameters 135| 0| setObject:dataProcessingOptions[DATA_PROCESSING_OPTIONS_STATE] 136| 0| forKey:DATA_PROCESSING_OPTIONS_STATE]; 137| 0| } 138| | 139| 0| [FBSDKAppEventsDeviceInfo extendDictionaryWithDeviceInfo:parameters]; 140| | 141| 0| static dispatch_once_t fetchBundleOnce; 142| 0| static NSMutableArray *urlSchemes; 143| | 144| 0| dispatch_once(&fetchBundleOnce, ^{ 145| 0| NSBundle *mainBundle = [NSBundle mainBundle]; 146| 0| urlSchemes = [NSMutableArray new]; 147| 0| for (NSDictionary *fields in [mainBundle objectForInfoDictionaryKey:@"CFBundleURLTypes"]) { 148| 0| NSArray *schemesForType = fields[@"CFBundleURLSchemes"]; 149| 0| if (schemesForType) { 150| 0| [urlSchemes addObjectsFromArray:schemesForType]; 151| 0| } 152| 0| } 153| 0| }); 154| | 155| 0| if (urlSchemes.count > 0) { 156| 0| [FBSDKTypeUtility dictionary:parameters setObject:[FBSDKBasicUtility JSONStringForObject:urlSchemes error:NULL invalidObjectHandler:NULL] forKey:@"url_schemes"]; 157| 0| } 158| | 159| 0| return parameters; 160| 0|} 161| | 162| |- (NSString *)advertiserID 163| 0|{ 164| 0| BOOL shouldUseCachedManagerIfAvailable = [FBSDKSettings shouldUseCachedValuesForExpensiveMetadata]; 165| 0| id dynamicFrameworkResolver = FBSDKDynamicFrameworkLoader.shared; 166| 0| return [self _advertiserIDFromDynamicFrameworkResolver:dynamicFrameworkResolver 167| 0| shouldUseCachedManager:shouldUseCachedManagerIfAvailable]; 168| 0|} 169| | 170| |- (NSString *)_advertiserIDFromDynamicFrameworkResolver:(id)dynamicFrameworkResolver 171| | shouldUseCachedManager:(BOOL)shouldUseCachedManager 172| 0|{ 173| 0| if (!FBSDKSettings.isAdvertiserIDCollectionEnabled) { 174| 0| return nil; 175| 0| } 176| | 177| 0| if (@available(iOS 14.0, *)) { 178| 0| if (![FBSDKAppEventsConfigurationManager cachedAppEventsConfiguration].advertiserIDCollectionEnabled) { 179| 0| return nil; 180| 0| } 181| 0| } 182| | 183| 0| ASIdentifierManager *manager = [self _asIdentifierManagerWithShouldUseCachedManager:shouldUseCachedManager 184| 0| dynamicFrameworkResolver:dynamicFrameworkResolver]; 185| 0| return manager.advertisingIdentifier.UUIDString; 186| 0|} 187| | 188| |- (ASIdentifierManager *)_asIdentifierManagerWithShouldUseCachedManager:(BOOL)shouldUseCachedManager 189| | dynamicFrameworkResolver:(id)dynamicFrameworkResolver 190| 0|{ 191| 0| if (shouldUseCachedManager && _cachedAdvertiserIdentifierManager) { 192| 0| return _cachedAdvertiserIdentifierManager; 193| 0| } 194| | 195| 0| Class ASIdentifierManagerClass = [dynamicFrameworkResolver asIdentifierManagerClass]; 196| 0| ASIdentifierManager *manager = [ASIdentifierManagerClass sharedManager]; 197| 0| if (shouldUseCachedManager) { 198| 0| _cachedAdvertiserIdentifierManager = manager; 199| 0| } else { 200| 0| _cachedAdvertiserIdentifierManager = nil; 201| 0| } 202| 0| return manager; 203| 0|} 204| | 205| |+ (BOOL)isStandardEvent:(nullable NSString *)event 206| 0|{ 207| 0| if (!event) { 208| 0| return NO; 209| 0| } 210| 0| return [standardEvents containsObject:event]; 211| 0|} 212| | 213| |#pragma mark - Internal, for testing 214| | 215| |+ (void)clearLibraryFiles 216| 0|{ 217| 0| [[NSFileManager defaultManager] removeItemAtPath:[[self class] persistenceFilePath:FBSDK_APPEVENTSUTILITY_ANONYMOUSIDFILENAME] 218| 0| error:NULL]; 219| 0| [[NSFileManager defaultManager] removeItemAtPath:[[self class] persistenceFilePath:@"com-facebook-sdk-AppEventsTimeSpent.json"] 220| 0| error:NULL]; 221| 0|} 222| | 223| |+ (void)ensureOnMainThread:(NSString *)methodName className:(NSString *)className 224| 0|{ 225| 0| FBSDKConditionalLog( 226| 0| [NSThread isMainThread], 227| 0| FBSDKLoggingBehaviorDeveloperErrors, 228| 0| @"*** <%@, %@> is not called on the main thread. This can lead to errors.", 229| 0| methodName, 230| 0| className 231| 0| ); 232| 0|} 233| | 234| |+ (NSString *)flushReasonToString:(FBSDKAppEventsFlushReason)flushReason 235| 0|{ 236| 0| NSString *result = @"Unknown"; 237| 0| switch (flushReason) { 238| 0| case FBSDKAppEventsFlushReasonExplicit: 239| 0| result = @"Explicit"; 240| 0| break; 241| 0| case FBSDKAppEventsFlushReasonTimer: 242| 0| result = @"Timer"; 243| 0| break; 244| 0| case FBSDKAppEventsFlushReasonSessionChange: 245| 0| result = @"SessionChange"; 246| 0| break; 247| 0| case FBSDKAppEventsFlushReasonPersistedEvents: 248| 0| result = @"PersistedEvents"; 249| 0| break; 250| 0| case FBSDKAppEventsFlushReasonEventThreshold: 251| 0| result = @"EventCountThreshold"; 252| 0| break; 253| 0| case FBSDKAppEventsFlushReasonEagerlyFlushingEvent: 254| 0| result = @"EagerlyFlushingEvent"; 255| 0| break; 256| 0| } 257| 0| return result; 258| 0|} 259| | 260| |+ (void)logAndNotify:(NSString *)msg 261| 0|{ 262| 0| [[self class] logAndNotify:msg allowLogAsDeveloperError:YES]; 263| 0|} 264| | 265| |+ (void)logAndNotify:(NSString *)msg allowLogAsDeveloperError:(BOOL)allowLogAsDeveloperError 266| 0|{ 267| 0| NSString *behaviorToLog = FBSDKLoggingBehaviorAppEvents; 268| 0| if (allowLogAsDeveloperError) { 269| 0| if ([FBSDKSettings.loggingBehaviors containsObject:FBSDKLoggingBehaviorDeveloperErrors]) { 270| | // Rather than log twice, prefer 'DeveloperErrors' if it's set over AppEvents. 271| 0| behaviorToLog = FBSDKLoggingBehaviorDeveloperErrors; 272| 0| } 273| 0| } 274| | 275| 0| [FBSDKLogger singleShotLogEntry:behaviorToLog logEntry:msg]; 276| 0| NSError *error = [FBSDKError errorWithCode:FBSDKErrorAppEventsFlush message:msg]; 277| 0| [[NSNotificationCenter defaultCenter] postNotificationName:FBSDKAppEventsLoggingResultNotification object:error]; 278| 0|} 279| | 280| |+ (BOOL) matchString:(NSString *)string 281| | firstCharacterSet:(NSCharacterSet *)firstCharacterSet 282| | restOfStringCharacterSet:(NSCharacterSet *)restOfStringCharacterSet 283| 0|{ 284| 0| if (string.length == 0) { 285| 0| return NO; 286| 0| } 287| 0| for (NSUInteger i = 0; i < string.length; i++) { 288| 0| const unichar c = [string characterAtIndex:i]; 289| 0| if (i == 0) { 290| 0| if (![firstCharacterSet characterIsMember:c]) { 291| 0| return NO; 292| 0| } 293| 0| } else { 294| 0| if (![restOfStringCharacterSet characterIsMember:c]) { 295| 0| return NO; 296| 0| } 297| 0| } 298| 0| } 299| 0| return YES; 300| 0|} 301| | 302| |+ (BOOL)regexValidateIdentifier:(NSString *)identifier 303| 0|{ 304| 0| static NSCharacterSet *firstCharacterSet; 305| 0| static NSCharacterSet *restOfStringCharacterSet; 306| 0| static dispatch_once_t onceToken; 307| 0| static NSMutableSet *cachedIdentifiers; 308| 0| dispatch_once(&onceToken, ^{ 309| 0| NSMutableCharacterSet *mutableSet = [NSMutableCharacterSet alphanumericCharacterSet]; 310| 0| [mutableSet addCharactersInString:@"_"]; 311| 0| firstCharacterSet = [mutableSet copy]; 312| | 313| 0| [mutableSet addCharactersInString:@"- "]; 314| 0| restOfStringCharacterSet = [mutableSet copy]; 315| 0| cachedIdentifiers = [NSMutableSet new]; 316| 0| }); 317| | 318| 0| @synchronized(self) { 319| 0| if (![cachedIdentifiers containsObject:identifier]) { 320| 0| if ([self matchString:identifier 321| 0| firstCharacterSet:firstCharacterSet 322| 0| restOfStringCharacterSet:restOfStringCharacterSet]) { 323| 0| [cachedIdentifiers addObject:identifier]; 324| 0| } else { 325| 0| return NO; 326| 0| } 327| 0| } 328| 0| } 329| 0| return YES; 330| 0|} 331| | 332| |+ (BOOL)validateIdentifier:(NSString *)identifier 333| 0|{ 334| 0| if (identifier == nil || identifier.length == 0 || identifier.length > FBSDK_APPEVENTSUTILITY_MAX_IDENTIFIER_LENGTH || ![[self class] regexValidateIdentifier:identifier]) { 335| 0| [[self class] logAndNotify:[NSString stringWithFormat:@"Invalid identifier: '%@'. Must be between 1 and %d characters, and must be contain only alphanumerics, _, - or spaces, starting with alphanumeric or _.", 336| 0| identifier, FBSDK_APPEVENTSUTILITY_MAX_IDENTIFIER_LENGTH]]; 337| 0| return NO; 338| 0| } 339| | 340| 0| return YES; 341| 0|} 342| | 343| |// Given a candidate token (which may be nil), find the real token to string to use. 344| |// Precedence: 1) provided token, 2) current token, 3) app | client token, 4) fully anonymous session. 345| |+ (NSString *)tokenStringToUseFor:(FBSDKAccessToken *)token 346| 0|{ 347| 0| if (!token) { 348| 0| token = [FBSDKAccessToken currentAccessToken]; 349| 0| } 350| | 351| 0| NSString *loggingOverrideAppID = [FBSDKAppEvents loggingOverrideAppID]; 352| | 353| 0| NSString *appID = loggingOverrideAppID ?: token.appID ?: [FBSDKSettings appID]; 354| 0| NSString *tokenString = token.tokenString; 355| 0| NSString *clientTokenString = [FBSDKSettings clientToken]; 356| | 357| 0| if (![appID isEqualToString:token.appID]) { 358| | // If there's a logging override app id present 359| | // then we don't want to use the client token since the client token 360| | // is intended to match up with the primary app id 361| | // and AppEvents doesn't require a client token. 362| 0| if (clientTokenString && loggingOverrideAppID) { 363| 0| tokenString = nil; 364| 0| } else if (clientTokenString && appID && ([appID isEqualToString:token.appID] || token == nil)) { 365| 0| tokenString = [NSString stringWithFormat:@"%@|%@", appID, clientTokenString]; 366| 0| } else if (appID) { 367| 0| tokenString = nil; 368| 0| } 369| 0| } 370| 0| return tokenString; 371| 0|} 372| | 373| |+ (NSTimeInterval)unixTimeNow 374| 0|{ 375| 0| return round([NSDate date].timeIntervalSince1970); 376| 0|} 377| | 378| |+ (NSTimeInterval)convertToUnixTime:(NSDate *)date 379| 0|{ 380| 0| return round([date timeIntervalSince1970]); 381| 0|} 382| | 383| |+ (BOOL)isDebugBuild 384| 0|{ 385| 0|#if TARGET_OS_SIMULATOR 386| 0| return YES; 387| |#else 388| | BOOL isDevelopment = NO; 389| | 390| | // There is no provisioning profile in AppStore Apps. 391| | @try { 392| | NSData *data = [NSData dataWithContentsOfFile:[NSBundle.mainBundle pathForResource:@"embedded" ofType:@"mobileprovision"]]; 393| | if (data) { 394| | const char *bytes = [data bytes]; 395| | NSMutableString *profile = [[NSMutableString alloc] initWithCapacity:data.length]; 396| | for (NSUInteger i = 0; i < data.length; i++) { 397| | [profile appendFormat:@"%c", bytes[i]]; 398| | } 399| | // Look for debug value, if detected we're in a development build. 400| | NSString *cleared = [[profile componentsSeparatedByCharactersInSet:NSCharacterSet.whitespaceAndNewlineCharacterSet] componentsJoinedByString:@""]; 401| | isDevelopment = ([cleared rangeOfString:@"get-task-allow"].length > 0); 402| | } 403| | 404| | return isDevelopment; 405| | } @catch (NSException *exception) {} 406| | 407| | return NO; 408| |#endif 409| 0|} 410| | 411| |+ (BOOL)shouldDropAppEvent 412| 0|{ 413| 0| if (@available(iOS 14.0, *)) { 414| 0| if ([FBSDKSettings advertisingTrackingStatus] == FBSDKAdvertisingTrackingDisallowed && ![FBSDKAppEventsConfigurationManager cachedAppEventsConfiguration].eventCollectionEnabled) { 415| 0| return YES; 416| 0| } 417| 0| } 418| 0| return NO; 419| 0|} 420| | 421| |+ (BOOL)isSensitiveUserData:(NSString *)text 422| 0|{ 423| 0| if (0 == text.length) { 424| 0| return NO; 425| 0| } 426| | 427| 0| return [self isEmailAddress:text] || [self isCreditCardNumber:text]; 428| 0|} 429| | 430| |+ (BOOL)isCreditCardNumber:(NSString *)text 431| 0|{ 432| 0| text = [[text componentsSeparatedByCharactersInSet:[NSCharacterSet.decimalDigitCharacterSet invertedSet]] componentsJoinedByString:@""]; 433| | 434| 0| if (text.doubleValue == 0) { 435| 0| return NO; 436| 0| } 437| | 438| 0| if (text.length < 9 || text.length > 21) { 439| 0| return NO; 440| 0| } 441| | 442| 0| const char *chars = [text cStringUsingEncoding:NSUTF8StringEncoding]; 443| 0| if (NULL == chars) { 444| 0| return NO; 445| 0| } 446| | 447| 0| BOOL isOdd = YES; 448| 0| int oddSum = 0; 449| 0| int evenSum = 0; 450| | 451| 0| for (int i = (int)text.length - 1; i >= 0; i--) { 452| 0| int digit = chars[i] - '0'; 453| | 454| 0| if (isOdd) { 455| 0| oddSum += digit; 456| 0| } else { 457| 0| evenSum += digit / 5 + (2 * digit) % 10; 458| 0| } 459| | 460| 0| isOdd = !isOdd; 461| 0| } 462| | 463| 0| return ((oddSum + evenSum) % 10 == 0); 464| 0|} 465| | 466| |+ (BOOL)isEmailAddress:(NSString *)text 467| 0|{ 468| 0| NSString *pattern = @"[A-Z0-9a-z._%+-]+@[A-Za-z0-9.-]+\\.[A-Za-z]{2,4}"; 469| 0| NSRegularExpression *regex = [[NSRegularExpression alloc] initWithPattern:pattern options:NSRegularExpressionCaseInsensitive error:nil]; 470| 0| NSUInteger matches = [regex numberOfMatchesInString:text options:0 range:NSMakeRange(0, [text length])]; 471| 0| return matches > 0; 472| 0|} 473| | 474| |#if DEBUG 475| | #if FBSDKTEST 476| | 477| |+ (ASIdentifierManager *)cachedAdvertiserIdentifierManager 478| 0|{ 479| 0| return _cachedAdvertiserIdentifierManager; 480| 0|} 481| | 482| |+ (void)setCachedAdvertiserIdentifierManager:(ASIdentifierManager *)manager 483| 0|{ 484| 0| _cachedAdvertiserIdentifierManager = manager; 485| 0|} 486| | 487| | #endif 488| |#endif 489| | 490| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAtePublisherFactory.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKAtePublisherFactory.h" 20| | 21| |#import "FBSDKAppEventsAtePublisher.h" 22| |#import "FBSDKDataPersisting.h" 23| | 24| |NS_ASSUME_NONNULL_BEGIN 25| | 26| |@interface FBSDKAtePublisherFactory () 27| | 28| |@property (nonnull, nonatomic, readonly) id graphRequestFactory; 29| |@property (nonnull, nonatomic, readonly) id settings; 30| |@property (nonnull, nonatomic, readonly) id store; 31| | 32| |@end 33| | 34| |@implementation FBSDKAtePublisherFactory 35| | 36| |- (instancetype)initWithStore:(id)store 37| | graphRequestFactory:(id)graphRequestFactory 38| | settings:(id)settings 39| 0|{ 40| 0| if ((self = [super init])) { 41| 0| _store = store; 42| 0| _graphRequestFactory = graphRequestFactory; 43| 0| _settings = settings; 44| 0| } 45| 0| return self; 46| 0|} 47| | 48| |- (id)createPublisherWithAppID:(NSString *)appID 49| 0|{ 50| 0| return [[FBSDKAppEventsAtePublisher alloc] initWithAppIdentifier:appID 51| 0| graphRequestFactory:self.graphRequestFactory 52| 0| settings:self.settings 53| 0| store:self.store]; 54| 0|} 55| | 56| |@end 57| | 58| |NS_ASSUME_NONNULL_END /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKHybridAppEventsScriptMessageHandler.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKHybridAppEventsScriptMessageHandler.h" 24| | 25| | #import "FBSDKAppEvents+EventLogging.h" 26| | #import "FBSDKAppEvents+Internal.h" 27| | #import "FBSDKCoreKitBasicsImport.h" 28| | #import "FBSDKEventLogging.h" 29| | 30| |NSString *const FBSDKAppEventsWKWebViewMessagesPixelReferralParamKey = @"_fb_pixel_referral_id"; 31| | 32| |@protocol FBSDKEventLogging; 33| |@class WKUserContentController; 34| | 35| |@interface FBSDKHybridAppEventsScriptMessageHandler () 36| | 37| |@property (nonatomic) id eventLogger; 38| | 39| |@end 40| | 41| |@implementation FBSDKHybridAppEventsScriptMessageHandler 42| | 43| |- (instancetype)init 44| 0|{ 45| 0| return [self initWithEventLogger:FBSDKAppEvents.singleton]; 46| 0|} 47| | 48| |- (instancetype)initWithEventLogger:(id)eventLogger 49| 0|{ 50| 0| if ((self = [super init])) { 51| 0| _eventLogger = eventLogger; 52| 0| } 53| 0| return self; 54| 0|} 55| | 56| |- (void)userContentController:(WKUserContentController *)userContentController didReceiveScriptMessage:(WKScriptMessage *)message 57| 0|{ 58| 0| if ([message.name isEqualToString:FBSDKAppEventsWKWebViewMessagesHandlerKey]) { 59| 0| NSDictionary *body = [FBSDKTypeUtility dictionaryValue:message.body]; 60| 0| if (!body) { 61| 0| return; 62| 0| } 63| 0| NSString *event = body[FBSDKAppEventsWKWebViewMessagesEventKey]; 64| 0| if ([event isKindOfClass:NSString.class] && (event.length > 0)) { 65| 0| NSString *stringedParams = [FBSDKTypeUtility stringValueOrNil:body[FBSDKAppEventsWKWebViewMessagesParamsKey]]; 66| 0| NSMutableDictionary *params = nil; 67| 0| NSError *jsonParseError = nil; 68| 0| if (stringedParams) { 69| 0| params = [FBSDKTypeUtility JSONObjectWithData:[stringedParams dataUsingEncoding:NSUTF8StringEncoding] 70| 0| options:NSJSONReadingMutableContainers 71| 0| error:&jsonParseError 72| 0| ]; 73| 0| } 74| 0| NSString *pixelID = body[FBSDKAppEventsWKWebViewMessagesPixelIDKey]; 75| 0| if (pixelID == nil) { 76| 0| [FBSDKAppEventsUtility logAndNotify:@"Can't bridge an event without a referral Pixel ID. Check your webview Pixel configuration."]; 77| 0| return; 78| 0| } 79| 0| if (jsonParseError != nil || ![params isKindOfClass:[NSDictionary class]] || params == nil) { 80| 0| [FBSDKAppEventsUtility logAndNotify:@"Could not find parameters for your Pixel request. Check your webview Pixel configuration."]; 81| 0| params = [[NSMutableDictionary alloc] initWithObjectsAndKeys:pixelID, FBSDKAppEventsWKWebViewMessagesPixelReferralParamKey, nil]; 82| 0| } else { 83| 0| [FBSDKTypeUtility dictionary:params setObject:pixelID forKey:FBSDKAppEventsWKWebViewMessagesPixelReferralParamKey]; 84| 0| } 85| 0| [self.eventLogger logInternalEvent:event 86| 0| parameters:params 87| 0| isImplicitlyLogged:NO]; 88| 0| } 89| 0| } 90| 0|} 91| | 92| |@end 93| | 94| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKPaymentObserver.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKPaymentObserver.h" 20| | 21| |#import 22| | 23| |#import "FBSDKCoreKit+Internal.h" 24| |#import "FBSDKPaymentProductRequestor.h" 25| |#import "FBSDKPaymentProductRequestorCreating.h" 26| |#import "FBSDKPaymentProductRequestorFactory.h" 27| | 28| |@interface FBSDKPaymentObserver () 29| | 30| |@property (nonatomic, readonly) SKPaymentQueue *paymentQueue; 31| |@property (nonatomic, readonly) id requestorFactory; 32| |@property (nonatomic) BOOL isObservingTransactions; 33| | 34| |@end 35| | 36| |@implementation FBSDKPaymentObserver 37| | 38| |- (instancetype)initWithPaymentQueue:(SKPaymentQueue *)paymentQueue 39| | paymentProductRequestorFactory:(id)paymentProductRequestorFactory 40| 0|{ 41| 0| if ((self = [super init])) { 42| 0| _paymentQueue = paymentQueue; 43| 0| _requestorFactory = paymentProductRequestorFactory; 44| 0| } 45| | 46| 0| return self; 47| 0|} 48| | 49| |#pragma mark - Internal Methods 50| | 51| |+ (FBSDKPaymentObserver *)shared 52| 0|{ 53| 0| static FBSDKPaymentObserver *shared = nil; 54| 0| static dispatch_once_t nonce; 55| 0| dispatch_once(&nonce, ^{ 56| 0| shared = [[FBSDKPaymentObserver alloc] initWithPaymentQueue:SKPaymentQueue.defaultQueue 57| 0| paymentProductRequestorFactory:[FBSDKPaymentProductRequestorFactory new]]; 58| 0| }); 59| 0| return shared; 60| 0|} 61| | 62| |- (void)startObservingTransactions 63| 0|{ 64| 0| @synchronized(self) { 65| 0| if (!self.isObservingTransactions) { 66| 0| [self.paymentQueue addTransactionObserver:self]; 67| 0| self.isObservingTransactions = YES; 68| 0| } 69| 0| } 70| 0|} 71| | 72| |- (void)stopObservingTransactions 73| 0|{ 74| 0| @synchronized(self) { 75| 0| if (self.isObservingTransactions) { 76| 0| [self.paymentQueue removeTransactionObserver:self]; 77| 0| self.isObservingTransactions = NO; 78| 0| } 79| 0| } 80| 0|} 81| | 82| |- (void) paymentQueue:(SKPaymentQueue *)queue 83| | updatedTransactions:(NSArray *)transactions 84| 0|{ 85| 0| for (SKPaymentTransaction *transaction in transactions) { 86| 0| switch (transaction.transactionState) { 87| 0| case SKPaymentTransactionStatePurchasing: 88| 0| case SKPaymentTransactionStatePurchased: 89| 0| case SKPaymentTransactionStateFailed: 90| 0| case SKPaymentTransactionStateRestored: 91| 0| [self handleTransaction:transaction]; 92| 0| break; 93| 0| case SKPaymentTransactionStateDeferred: 94| 0| break; 95| 0| } 96| 0| } 97| 0|} 98| | 99| |- (void)handleTransaction:(SKPaymentTransaction *)transaction 100| 0|{ 101| 0| FBSDKPaymentProductRequestor *productRequestor = [self.requestorFactory createRequestorWithTransaction:transaction]; 102| 0| [productRequestor resolveProducts]; 103| 0|} 104| | 105| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKPaymentProductRequestor.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKPaymentProductRequestor.h" 20| | 21| |#import 22| | 23| |#import "FBSDKAppEventName.h" 24| |#import "FBSDKAppEventParameterName.h" 25| |#import "FBSDKAppEventsFlushReason.h" 26| |#import "FBSDKAppStoreReceiptProviding.h" 27| |#import "FBSDKCoreKitBasicsImport.h" 28| |#import "FBSDKDataPersisting.h" 29| |#import "FBSDKEventLogging.h" 30| |#import "FBSDKGateKeeperManaging.h" 31| |#import "FBSDKLoggingCreating.h" 32| |#import "FBSDKProductsRequestProtocols.h" 33| |#import "FBSDKSettingsProtocol.h" 34| | 35| |static NSString *const FBSDKPaymentObserverOriginalTransactionKey = @"com.facebook.appevents.PaymentObserver.originalTransaction"; 36| |static NSString *const FBSDKPaymentObserverDelimiter = @","; 37| | 38| |static NSString *const FBSDKAppEventParameterImplicitlyLoggedPurchase = @"_implicitlyLogged"; 39| |static NSString *const FBSDKAppEventNamePurchaseFailed = @"fb_mobile_purchase_failed"; 40| |static NSString *const FBSDKAppEventNamePurchaseRestored = @"fb_mobile_purchase_restored"; 41| |static NSString *const FBSDKAppEventParameterNameInAppPurchaseType = @"fb_iap_product_type"; 42| |static NSString *const FBSDKAppEventParameterNameProductTitle = @"fb_content_title"; 43| |static NSString *const FBSDKAppEventParameterNameOriginalTransactionID = @"fb_original_transaction_id"; 44| |static NSString *const FBSDKAppEventParameterNameTransactionID = @"fb_transaction_id"; 45| |static NSString *const FBSDKAppEventParameterNameTransactionDate = @"fb_transaction_date"; 46| |static NSString *const FBSDKAppEventParameterNameSubscriptionPeriod = @"fb_iap_subs_period"; 47| |static NSString *const FBSDKAppEventParameterNameIsStartTrial = @"fb_iap_is_start_trial"; 48| |static NSString *const FBSDKAppEventParameterNameHasFreeTrial = @"fb_iap_has_free_trial"; 49| |static NSString *const FBSDKAppEventParameterNameTrialPeriod = @"fb_iap_trial_period"; 50| |static NSString *const FBSDKAppEventParameterNameTrialPrice = @"fb_iap_trial_price"; 51| | 52| |static NSString *const FBSDKGateKeeperAppEventsIfAutoLogSubs = @"app_events_if_auto_log_subs"; 53| |static int const FBSDKMaxParameterValueLength = 100; 54| | 55| |@interface FBSDKPaymentProductRequestor () 56| | 57| |@property (class, nonatomic, readonly) NSMutableArray *pendingRequestors; 58| |@property (nonatomic, retain) SKPaymentTransaction *transaction; 59| |@property (nonatomic, readonly) id appStoreReceiptProvider; 60| |@property (nonatomic, retain) id productsRequest; 61| |@property (nonatomic, readonly) id productRequestFactory; 62| |@property (nonatomic, readonly) id settings; 63| |@property (nonatomic, readonly) id eventLogger; 64| |@property (nonatomic, readonly) Class gateKeeperManager; 65| |@property (nonatomic, readonly) id store; 66| |@property (nonatomic, readonly) id loggerFactory; 67| |@property (nonatomic) NSMutableSet *originalTransactionSet; 68| |@property (nonatomic) NSSet *eventsWithReceipt; 69| |@property (nonatomic, readonly) NSDateFormatter *formatter; 70| | 71| |@end 72| | 73| |@implementation FBSDKPaymentProductRequestor 74| | 75| |static NSMutableArray *_pendingRequestors; 76| | 77| |+ (void)initialize 78| 0|{ 79| 0| if ([self class] == [FBSDKPaymentProductRequestor class]) { 80| 0| _pendingRequestors = [NSMutableArray new]; 81| 0| } 82| 0|} 83| | 84| |- (instancetype)initWithTransaction:(SKPaymentTransaction *)transaction 85| | settings:(id)settings 86| | eventLogger:(id)eventLogger 87| | gateKeeperManager:(Class)gateKeeperManager 88| | store:(id)store 89| | loggerFactory:(id)loggerFactory 90| | productsRequestFactory:(id)productRequestFactory 91| | appStoreReceiptProvider:(id)receiptProvider 92| 0|{ 93| 0| if ((self = [super init])) { 94| 0| _settings = settings; 95| 0| _eventLogger = eventLogger; 96| 0| _gateKeeperManager = gateKeeperManager; 97| 0| _store = store; 98| 0| _loggerFactory = loggerFactory; 99| 0| _productRequestFactory = productRequestFactory; 100| 0| _appStoreReceiptProvider = receiptProvider; 101| 0| _transaction = transaction; 102| 0| _formatter = [NSDateFormatter new]; 103| 0| _formatter.dateFormat = @"yyyy-MM-dd HH:mm:ssZ"; 104| 0| NSString *data = [_store stringForKey:FBSDKPaymentObserverOriginalTransactionKey]; 105| 0| _eventsWithReceipt = [NSSet setWithArray:@[FBSDKAppEventNamePurchased, FBSDKAppEventNameSubscribe, 106| 0| FBSDKAppEventNameStartTrial]]; 107| 0| if (data) { 108| 0| _originalTransactionSet = [NSMutableSet setWithArray:[data componentsSeparatedByString:FBSDKPaymentObserverDelimiter]]; 109| 0| } else { 110| 0| _originalTransactionSet = [NSMutableSet new]; 111| 0| } 112| 0| } 113| 0| return self; 114| 0|} 115| | 116| |+ (NSMutableArray *)pendingRequestors 117| 0|{ 118| 0| return _pendingRequestors; 119| 0|} 120| | 121| |- (void)setProductsRequest:(id)productsRequest 122| 0|{ 123| 0| if (productsRequest != _productsRequest) { 124| 0| if (_productsRequest) { 125| 0| _productsRequest.delegate = nil; 126| 0| } 127| 0| _productsRequest = productsRequest; 128| 0| } 129| 0|} 130| | 131| |- (void)resolveProducts 132| 0|{ 133| 0| NSString *productId = self.transaction.payment.productIdentifier; 134| 0| NSSet *productIdentifiers = [NSSet setWithObjects:productId, nil]; 135| 0| self.productsRequest = [self.productRequestFactory createWithProductIdentifiers:productIdentifiers]; 136| 0| self.productsRequest.delegate = self; 137| 0| @synchronized(self.class.pendingRequestors) { 138| 0| [FBSDKTypeUtility array:self.class.pendingRequestors addObject:self]; 139| 0| } 140| 0| [self.productsRequest start]; 141| 0|} 142| | 143| |- (NSString *)getTruncatedString:(NSString *)inputString 144| 0|{ 145| 0| if (!inputString) { 146| 0| return @""; 147| 0| } 148| | 149| 0| return inputString.length <= FBSDKMaxParameterValueLength ? inputString : [inputString substringToIndex:FBSDKMaxParameterValueLength]; 150| 0|} 151| | 152| |- (void)logTransactionEvent:(SKProduct *)product 153| 0|{ 154| 0| if ([self isSubscription:product] 155| 0| && [self.gateKeeperManager boolForKey:FBSDKGateKeeperAppEventsIfAutoLogSubs 156| 0| defaultValue:NO]) { 157| 0| [self logImplicitSubscribeTransaction:self.transaction ofProduct:product]; 158| 0| } else { 159| 0| [self logImplicitPurchaseTransaction:self.transaction ofProduct:product]; 160| 0| } 161| 0|} 162| | 163| |- (BOOL)isSubscription:(SKProduct *)product 164| 0|{ 165| 0|#if !TARGET_OS_TV 166| 0|#if __IPHONE_OS_VERSION_MAX_ALLOWED > __IPHONE_11_1 167| 0| if (@available(iOS 11.2, *)) { 168| 0| return (product.subscriptionPeriod != nil) && ((unsigned long)product.subscriptionPeriod.numberOfUnits > 0); 169| 0| } 170| 0|#endif 171| 0|#endif 172| 0| return NO; 173| 0|} 174| | 175| |- (NSMutableDictionary *)getEventParametersOfProduct:(SKProduct *)product 176| | withTransaction:(SKPaymentTransaction *)transaction 177| 0|{ 178| 0| NSString *transactionID = nil; 179| 0| NSString *transactionDate = nil; 180| 0| switch (transaction.transactionState) { 181| 0| case SKPaymentTransactionStatePurchasing: 182| 0| break; 183| 0| case SKPaymentTransactionStatePurchased: 184| 0| transactionID = transaction.transactionIdentifier; 185| 0| transactionDate = [_formatter stringFromDate:transaction.transactionDate]; 186| 0| break; 187| 0| case SKPaymentTransactionStateFailed: 188| 0| break; 189| 0| case SKPaymentTransactionStateRestored: 190| 0| transactionDate = [_formatter stringFromDate:transaction.transactionDate]; 191| 0| break; 192| 0| default: break; 193| 0| } 194| 0| SKPayment *payment = transaction.payment; 195| 0| NSMutableDictionary *eventParameters = [NSMutableDictionary dictionaryWithDictionary:@{ 196| 0| FBSDKAppEventParameterNameContentID : payment.productIdentifier ?: @"", 197| 0| FBSDKAppEventParameterNameNumItems : @(payment.quantity), 198| 0| FBSDKAppEventParameterNameTransactionDate : transactionDate ?: @"", 199| 0| }]; 200| 0| if (product) { 201| 0| [eventParameters addEntriesFromDictionary:@{ 202| 0| FBSDKAppEventParameterNameCurrency : [product.priceLocale objectForKey:NSLocaleCurrencyCode], 203| 0| FBSDKAppEventParameterNameNumItems : @(payment.quantity), 204| 0| FBSDKAppEventParameterNameProductTitle : [self getTruncatedString:product.localizedTitle], 205| 0| FBSDKAppEventParameterNameDescription : [self getTruncatedString:product.localizedDescription], 206| 0| }]; 207| 0| if (transactionID) { 208| 0| [FBSDKTypeUtility dictionary:eventParameters setObject:transactionID forKey:FBSDKAppEventParameterNameTransactionID]; 209| 0| } 210| 0| } 211| | 212| 0|#if !TARGET_OS_TV 213| 0|#if __IPHONE_OS_VERSION_MAX_ALLOWED > __IPHONE_11_1 214| 0| if (@available(iOS 11.2, *)) { 215| 0| if ([self isSubscription:product]) { 216| | // subs inapp 217| 0| [FBSDKTypeUtility dictionary:eventParameters setObject:[self durationOfSubscriptionPeriod:product.subscriptionPeriod] forKey:FBSDKAppEventParameterNameSubscriptionPeriod]; 218| 0| [FBSDKTypeUtility dictionary:eventParameters setObject:@"subs" forKey:FBSDKAppEventParameterNameInAppPurchaseType]; 219| 0| [FBSDKTypeUtility dictionary:eventParameters setObject:[self isStartTrial:transaction ofProduct:product] ? @"1" : @"0" forKey:FBSDKAppEventParameterNameIsStartTrial]; 220| | // trial information for subs 221| 0| SKProductDiscount *discount = product.introductoryPrice; 222| 0| if (discount) { 223| 0| if (discount.paymentMode == SKProductDiscountPaymentModeFreeTrial) { 224| 0| [FBSDKTypeUtility dictionary:eventParameters setObject:@"1" forKey:FBSDKAppEventParameterNameHasFreeTrial]; 225| 0| } else { 226| 0| [FBSDKTypeUtility dictionary:eventParameters setObject:@"0" forKey:FBSDKAppEventParameterNameHasFreeTrial]; 227| 0| } 228| 0| [FBSDKTypeUtility dictionary:eventParameters setObject:[self durationOfSubscriptionPeriod:discount.subscriptionPeriod] forKey:FBSDKAppEventParameterNameTrialPeriod]; 229| 0| [FBSDKTypeUtility dictionary:eventParameters setObject:discount.price forKey:FBSDKAppEventParameterNameTrialPrice]; 230| 0| } 231| 0| } else { 232| 0| [FBSDKTypeUtility dictionary:eventParameters setObject:@"inapp" forKey:FBSDKAppEventParameterNameInAppPurchaseType]; 233| 0| } 234| 0| } 235| 0|#endif 236| 0|#endif 237| 0| return eventParameters; 238| 0|} 239| | 240| |- (void)appendOriginalTransactionID:(NSString *)transactionID 241| 0|{ 242| 0| if (!transactionID) { 243| 0| return; 244| 0| } 245| 0| [self.originalTransactionSet addObject:transactionID]; 246| 0| [self.store setObject:[[self.originalTransactionSet allObjects] componentsJoinedByString:FBSDKPaymentObserverDelimiter] 247| 0| forKey:FBSDKPaymentObserverOriginalTransactionKey]; 248| 0|} 249| | 250| |- (void)clearOriginalTransactionID:(NSString *)transactionID 251| 0|{ 252| 0| if (!transactionID) { 253| 0| return; 254| 0| } 255| 0| [self.originalTransactionSet removeObject:transactionID]; 256| 0| [self.store setObject:[[self.originalTransactionSet allObjects] componentsJoinedByString:FBSDKPaymentObserverDelimiter] 257| 0| forKey:FBSDKPaymentObserverOriginalTransactionKey]; 258| 0|} 259| | 260| |- (BOOL)isStartTrial:(SKPaymentTransaction *)transaction 261| | ofProduct:(SKProduct *)product 262| 0|{ 263| 0|#if !TARGET_OS_TV 264| 0|#if __IPHONE_OS_VERSION_MAX_ALLOWED > __IPHONE_11_1 265| 0|#if __IPHONE_OS_VERSION_MAX_ALLOWED > __IPHONE_11_4 266| 0|#if __IPHONE_OS_VERSION_MAX_ALLOWED > __IPHONE_12_1 267| | // promotional offer starting from iOS 12.2 268| 0| if (@available(iOS 12.2, *)) { 269| 0| SKPaymentDiscount *paymentDiscount = transaction.payment.paymentDiscount; 270| 0| if (paymentDiscount) { 271| 0| NSArray *discounts = product.discounts; 272| 0| for (SKProductDiscount *discount in discounts) { 273| 0| if (discount.paymentMode == SKProductDiscountPaymentModeFreeTrial 274| 0| && [paymentDiscount.identifier isEqualToString:discount.identifier]) { 275| 0| return YES; 276| 0| } 277| 0| } 278| 0| } 279| 0| } 280| 0|#endif 281| 0|#endif 282| | // introductory offer starting from iOS 11.2 283| 0| if (@available(iOS 11.2, *)) { 284| 0| if (product.introductoryPrice 285| 0| && product.introductoryPrice.paymentMode == SKProductDiscountPaymentModeFreeTrial) { 286| 0| NSString *originalTransactionID = transaction.originalTransaction.transactionIdentifier; 287| | // only consider the very first trial transaction as start trial 288| 0| if (!originalTransactionID) { 289| 0| return YES; 290| 0| } 291| 0| } 292| 0| } 293| 0|#endif 294| 0|#endif 295| 0| return NO; 296| 0|} 297| | 298| |- (NSString *)durationOfSubscriptionPeriod:(id)subcriptionPeriod 299| 0|{ 300| 0|#if !TARGET_OS_TV 301| 0|#if __IPHONE_OS_VERSION_MAX_ALLOWED > __IPHONE_11_1 302| 0| if (@available(iOS 11.2, *)) { 303| 0| if (subcriptionPeriod && [subcriptionPeriod isKindOfClass:[SKProductSubscriptionPeriod class]]) { 304| 0| SKProductSubscriptionPeriod *period = (SKProductSubscriptionPeriod *)subcriptionPeriod; 305| 0| NSString *unit = nil; 306| 0| switch (period.unit) { 307| 0| case SKProductPeriodUnitDay: unit = @"D"; break; 308| 0| case SKProductPeriodUnitWeek: unit = @"W"; break; 309| 0| case SKProductPeriodUnitMonth: unit = @"M"; break; 310| 0| case SKProductPeriodUnitYear: unit = @"Y"; break; 311| 0| } 312| 0| return [NSString stringWithFormat:@"P%lu%@", (unsigned long)period.numberOfUnits, unit]; 313| 0| } 314| 0| } 315| 0|#endif 316| 0|#endif 317| 0| return nil; 318| 0|} 319| | 320| |- (void)productsRequest:(SKProductsRequest *)request didReceiveResponse:(SKProductsResponse *)response 321| 0|{ 322| 0| NSArray *products = response.products; 323| 0| NSArray *invalidProductIdentifiers = response.invalidProductIdentifiers; 324| 0| if (products.count + invalidProductIdentifiers.count != 1) { 325| 0| id logger = [self.loggerFactory createLoggerWithLoggingBehavior:FBSDKLoggingBehaviorAppEvents]; 326| 0| [logger logEntry:@"FBSDKPaymentObserver: Expect to resolve one product per request"]; 327| 0| } 328| 0| SKProduct *product = nil; 329| 0| if (products.count) { 330| 0| product = [FBSDKTypeUtility array:products objectAtIndex:0]; 331| 0| } 332| 0| [self logTransactionEvent:product]; 333| 0|} 334| | 335| |- (void)requestDidFinish:(SKRequest *)request 336| 0|{ 337| 0| [self cleanUp]; 338| 0|} 339| | 340| |- (void)request:(SKRequest *)request didFailWithError:(NSError *)error 341| 0|{ 342| 0| [self logTransactionEvent:nil]; 343| 0| [self cleanUp]; 344| 0|} 345| | 346| |- (void)cleanUp 347| 0|{ 348| 0| @synchronized(self.class.pendingRequestors) { 349| 0| [self.class.pendingRequestors removeObject:self]; 350| 0| } 351| 0|} 352| | 353| |- (void)logImplicitSubscribeTransaction:(SKPaymentTransaction *)transaction 354| | ofProduct:(SKProduct *)product 355| 0|{ 356| 0| NSString *eventName = nil; 357| 0| NSString *originalTransactionID = transaction.originalTransaction.transactionIdentifier; 358| 0| switch (transaction.transactionState) { 359| 0| case SKPaymentTransactionStatePurchasing: 360| 0| eventName = @"SubscriptionInitiatedCheckout"; 361| 0| break; 362| 0| case SKPaymentTransactionStatePurchased: 363| 0| if ([self isStartTrial:transaction ofProduct:product]) { 364| 0| eventName = FBSDKAppEventNameStartTrial; 365| 0| [self clearOriginalTransactionID:originalTransactionID]; 366| 0| } else { 367| 0| if (originalTransactionID && [self.originalTransactionSet containsObject:originalTransactionID]) { 368| 0| return; 369| 0| } 370| 0| eventName = FBSDKAppEventNameSubscribe; 371| 0| [self appendOriginalTransactionID:(originalTransactionID ?: transaction.transactionIdentifier)]; 372| 0| } 373| 0| break; 374| 0| case SKPaymentTransactionStateFailed: 375| 0| eventName = @"SubscriptionFailed"; 376| 0| break; 377| 0| case SKPaymentTransactionStateRestored: 378| 0| eventName = @"SubscriptionRestore"; 379| 0| break; 380| 0| case SKPaymentTransactionStateDeferred: 381| 0| return; 382| 0| } 383| | 384| 0| double totalAmount = 0; 385| 0| if (product) { 386| 0| totalAmount = transaction.payment.quantity * product.price.doubleValue; 387| 0| } 388| | 389| 0| [self logImplicitTransactionEvent:eventName 390| 0| valueToSum:totalAmount 391| 0| parameters:[self getEventParametersOfProduct:product withTransaction:transaction]]; 392| 0|} 393| | 394| |- (void)logImplicitPurchaseTransaction:(SKPaymentTransaction *)transaction 395| | ofProduct:(SKProduct *)product 396| 0|{ 397| 0| NSString *eventName = nil; 398| 0| switch (transaction.transactionState) { 399| 0| case SKPaymentTransactionStatePurchasing: 400| 0| eventName = FBSDKAppEventNameInitiatedCheckout; 401| 0| break; 402| 0| case SKPaymentTransactionStatePurchased: 403| 0| eventName = FBSDKAppEventNamePurchased; 404| 0| break; 405| 0| case SKPaymentTransactionStateFailed: 406| 0| eventName = FBSDKAppEventNamePurchaseFailed; 407| 0| break; 408| 0| case SKPaymentTransactionStateRestored: 409| 0| eventName = FBSDKAppEventNamePurchaseRestored; 410| 0| break; 411| 0| case SKPaymentTransactionStateDeferred: 412| 0| return; 413| 0| } 414| | 415| 0| double totalAmount = 0; 416| 0| if (product) { 417| 0| totalAmount = transaction.payment.quantity * product.price.doubleValue; 418| 0| } 419| | 420| 0| [self logImplicitTransactionEvent:eventName 421| 0| valueToSum:totalAmount 422| 0| parameters:[self getEventParametersOfProduct:product withTransaction:transaction]]; 423| 0|} 424| | 425| |- (void)logImplicitTransactionEvent:(NSString *)eventName 426| | valueToSum:(double)valueToSum 427| | parameters:(NSDictionary *)parameters 428| 0|{ 429| 0| NSMutableDictionary *eventParameters = [NSMutableDictionary dictionaryWithDictionary:parameters]; 430| | 431| 0| if ([_eventsWithReceipt containsObject:eventName]) { 432| 0| NSData *receipt = [self fetchDeviceReceipt]; 433| 0| if (receipt) { 434| 0| NSString *base64encodedReceipt = [receipt base64EncodedStringWithOptions:0]; 435| 0| [FBSDKTypeUtility dictionary:eventParameters setObject:base64encodedReceipt forKey:@"receipt_data"]; 436| 0| } 437| 0| } 438| | 439| 0| [FBSDKTypeUtility dictionary:eventParameters setObject:@"1" forKey:FBSDKAppEventParameterImplicitlyLoggedPurchase]; 440| 0| [self.eventLogger logEvent:eventName 441| 0| valueToSum:valueToSum 442| 0| parameters:eventParameters]; 443| | 444| | // Unless the behavior is set to only allow explicit flushing, we go ahead and flush, since purchase events 445| | // are relatively rare and relatively high value and worth getting across on wire right away. 446| 0| if ([self.eventLogger flushBehavior] != FBSDKAppEventsFlushBehaviorExplicitOnly) { 447| 0| [self.eventLogger flushForReason:FBSDKAppEventsFlushReasonEagerlyFlushingEvent]; 448| 0| } 449| 0|} 450| | 451| |// Fetch the current receipt for this application. 452| |- (NSData *)fetchDeviceReceipt 453| 0|{ 454| 0| NSURL *receiptURL = self.appStoreReceiptProvider.appStoreReceiptURL; 455| 0| NSData *receipt = [NSData dataWithContentsOfURL:receiptURL]; 456| 0| return receipt; 457| 0|} 458| | 459| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKPaymentProductRequestorFactory.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKPaymentProductRequestorFactory.h" 20| | 21| |#import "FBSDKAppEvents+EventLogging.h" 22| |#import "FBSDKAppStoreReceiptProviding.h" 23| |#import "FBSDKGateKeeperManager.h" 24| |#import "FBSDKGateKeeperManaging.h" 25| |#import "FBSDKLoggerFactory.h" 26| |#import "FBSDKPaymentProductRequestor.h" 27| |#import "FBSDKProductRequestFactory.h" 28| |#import "FBSDKProductsRequestProtocols.h" 29| |#import "FBSDKSettings+Internal.h" 30| |#import "FBSDKSettings+SettingsProtocols.h" 31| |#import "NSUserDefaults+FBSDKDataPersisting.h" 32| | 33| |@interface FBSDKPaymentProductRequestorFactory () 34| | 35| |@property (nonatomic, readonly) id settings; 36| |@property (nonatomic, readonly) id eventLogger; 37| |@property (nullable, nonatomic) Class gateKeeperManager; 38| |@property (nullable, nonatomic) id store; 39| |@property (nullable, nonatomic) id loggerFactory; 40| |@property (nonatomic, readonly) id productsRequestFactory; 41| |@property (nonatomic, readonly) id appStoreReceiptProvider; 42| | 43| |@end 44| | 45| |@implementation FBSDKPaymentProductRequestorFactory 46| | 47| |- (instancetype)init 48| 0|{ 49| 0| return [self initWithSettings:FBSDKSettings.sharedSettings 50| 0| eventLogger:FBSDKAppEvents.singleton 51| 0| gateKeeperManager:FBSDKGateKeeperManager.class 52| 0| store:NSUserDefaults.standardUserDefaults 53| 0| loggerFactory:[FBSDKLoggerFactory new] 54| 0| productsRequestFactory:[FBSDKProductRequestFactory new] 55| 0| appStoreReceiptProvider:[NSBundle bundleForClass:self.class]]; 56| 0|} 57| | 58| |- (instancetype)initWithSettings:(id)settings 59| | eventLogger:(id)eventLogger 60| | gateKeeperManager:(Class)gateKeeperManager 61| | store:(id)store 62| | loggerFactory:(id)loggerFactory 63| | productsRequestFactory:(id)productsRequestFactory 64| | appStoreReceiptProvider:(id)receiptProvider 65| 0|{ 66| 0| if ((self = [super init])) { 67| 0| _settings = settings; 68| 0| _eventLogger = eventLogger; 69| 0| _gateKeeperManager = gateKeeperManager; 70| 0| _store = store; 71| 0| _loggerFactory = loggerFactory; 72| 0| _productsRequestFactory = productsRequestFactory; 73| 0| _appStoreReceiptProvider = receiptProvider; 74| 0| } 75| | 76| 0| return self; 77| 0|} 78| | 79| |- (nonnull FBSDKPaymentProductRequestor *)createRequestorWithTransaction:(SKPaymentTransaction *)transaction 80| 0|{ 81| 0| return [[FBSDKPaymentProductRequestor alloc] initWithTransaction:transaction 82| 0| settings:self.settings 83| 0| eventLogger:self.eventLogger 84| 0| gateKeeperManager:self.gateKeeperManager 85| 0| store:self.store 86| 0| loggerFactory:self.loggerFactory 87| 0| productsRequestFactory:self.productsRequestFactory 88| 0| appStoreReceiptProvider:self.appStoreReceiptProvider]; 89| 0|} 90| | 91| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKProductRequestFactory.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKProductRequestFactory.h" 20| | 21| |#import "SKProductsRequest+FBSDKProductsRequest.h" 22| | 23| |@implementation FBSDKProductRequestFactory 24| | 25| |- (nonnull id)createWithProductIdentifiers:(nonnull NSSet *)identifiers 26| 0|{ 27| 0| return [[SKProductsRequest alloc] initWithProductIdentifiers:identifiers]; 28| 0|} 29| | 30| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKTimeSpentData.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKTimeSpentData.h" 20| | 21| |#import "FBSDKAppEventParameterName.h" 22| |#import "FBSDKAppEventsFlushReason.h" 23| |#import "FBSDKCoreKitBasicsImport.h" 24| |#import "FBSDKEventLogging.h" 25| |#import "FBSDKInternalUtility.h" 26| |#import "FBSDKLogger.h" 27| |#import "FBSDKServerConfiguration.h" 28| |#import "FBSDKServerConfigurationProviding.h" 29| | 30| |// Filename and keys for session length 31| |NSString *const FBSDKTimeSpentFilename = @"com-facebook-sdk-AppEventsTimeSpent.json"; 32| |static NSString *const FBSDKTimeSpentPersistKeySessionSecondsSpent = @"secondsSpentInCurrentSession"; 33| |static NSString *const FBSDKTimeSpentPersistKeySessionNumInterruptions = @"numInterruptions"; 34| |static NSString *const FBSDKTimeSpentPersistKeyLastSuspendTime = @"lastSuspendTime"; 35| |static NSString *const FBSDKTimeSpentPersistKeySessionID = @"sessionID"; 36| | 37| |static NSString *const FBSDKAppEventNameActivatedApp = @"fb_mobile_activate_app"; 38| |static NSString *const FBSDKAppEventNameDeactivatedApp = @"fb_mobile_deactivate_app"; 39| |static NSString *const FBSDKAppEventParameterNameSessionInterruptions = @"fb_mobile_app_interruptions"; 40| |static NSString *const FBSDKAppEventParameterNameTimeBetweenSessions = @"fb_mobile_time_between_sessions"; 41| |static NSString *const FBSDKAppEventParameterNameSessionID = @"_session_id"; 42| | 43| |FBSDKAppEventParameterName FBSDKAppEventParameterLaunchSource = @"fb_mobile_launch_source"; 44| | 45| |static const int SECS_PER_MIN = 60; 46| |static const int SECS_PER_HOUR = 60 * SECS_PER_MIN; 47| |static const int SECS_PER_DAY = 24 * SECS_PER_HOUR; 48| | 49| |// Will be translated and displayed in App Insights. Need to maintain same number and value of quanta on the server. 50| |static const long INACTIVE_SECONDS_QUANTA[] = 51| |{ 52| | 5 * SECS_PER_MIN, 53| | 15 * SECS_PER_MIN, 54| | 30 * SECS_PER_MIN, 55| | 1 * SECS_PER_HOUR, 56| | 6 * SECS_PER_HOUR, 57| | 12 * SECS_PER_HOUR, 58| | 1 * SECS_PER_DAY, 59| | 2 * SECS_PER_DAY, 60| | 3 * SECS_PER_DAY, 61| | 7 * SECS_PER_DAY, 62| | 14 * SECS_PER_DAY, 63| | 21 * SECS_PER_DAY, 64| | 28 * SECS_PER_DAY, 65| | 60 * SECS_PER_DAY, 66| | 90 * SECS_PER_DAY, 67| | 120 * SECS_PER_DAY, 68| | 150 * SECS_PER_DAY, 69| | 180 * SECS_PER_DAY, 70| | 365 * SECS_PER_DAY, 71| | LONG_MAX, // keep as LONG_MAX to guarantee loop will terminate 72| |}; 73| | 74| |@interface FBSDKTimeSpentData () 75| | 76| |@property (nonatomic, weak) id eventLogger; 77| |@property (nonnull, nonatomic) Class serverConfigurationProvider; 78| |@property (nonatomic) NSString *sourceApplication; 79| |@property (nonatomic) BOOL isOpenedFromAppLink; 80| | 81| |@end 82| | 83| |/** 84| | * This class encapsulates the notion of an app 'session' - the length of time that the user has 85| | * spent in the app that can be considered a single usage of the app. Apps may be frequently interrupted 86| | * do to other device activity, like a text message, so this class allows those interruptions to be smoothed 87| | * out and the time actually spent in the app excluding this interruption time to be accumulated. Also, 88| | * once a certain amount of time has gone by where the app is not in the foreground, we consider the 89| | * session to be complete, and a new session beginning. When this occurs, we log a 'deactivate app' event 90| | * with the duration of the previous session as the 'value' of this event, along with the number of 91| | * interruptions from that previous session as an event parameter. 92| | */ 93| |@implementation FBSDKTimeSpentData 94| |{ 95| | BOOL _isCurrentlyLoaded; 96| | BOOL _shouldLogActivateEvent; 97| | BOOL _shouldLogDeactivateEvent; 98| | NSTimeInterval _secondsSpentInCurrentSession; 99| | NSTimeInterval _timeSinceLastSuspend; 100| | int _numInterruptionsInCurrentSession; 101| | NSTimeInterval _lastRestoreTime; 102| | NSTimeInterval _lastSuspendTime; 103| | NSString *_sessionID; 104| |} 105| | 106| |- (instancetype)initWithEventLogger:(id)eventLogger 107| | serverConfigurationProvider:(Class)serverConfigurationProvider 108| 0|{ 109| 0| if ((self = [super init])) { 110| 0| _eventLogger = eventLogger; 111| 0| _serverConfigurationProvider = serverConfigurationProvider; 112| 0| } 113| | 114| 0| return self; 115| 0|} 116| | 117| |- (void)ensureOnMainThread:(NSString *)methodName className:(NSString *)className 118| 0|{ 119| 0| if (!NSThread.isMainThread) { 120| 0| NSString *msg = [NSString stringWithFormat:@"*** <%@, %@> is not called on the main thread. This can lead to errors.", methodName, className]; 121| 0| [FBSDKLogger singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors logEntry:msg]; 122| 0| } 123| 0|} 124| | 125| |// Calculate and persist time spent data for this instance of the app activation. 126| |- (void)suspend 127| 0|{ 128| 0| [self ensureOnMainThread:NSStringFromSelector(_cmd) className:NSStringFromClass([self class])]; 129| 0| if (!_isCurrentlyLoaded) { 130| 0| FBSDKConditionalLog(YES, FBSDKLoggingBehaviorInformational, @"[FBSDKTimeSpentData suspend] invoked without corresponding restore"); 131| 0| return; 132| 0| } 133| | 134| 0| NSTimeInterval now = round([NSDate date].timeIntervalSince1970); 135| 0| NSTimeInterval timeSinceRestore = now - _lastRestoreTime; 136| | 137| | // Can happen if the clock on the device is changed 138| 0| if (timeSinceRestore < 0) { 139| 0| [FBSDKLogger singleShotLogEntry:FBSDKLoggingBehaviorAppEvents 140| 0| logEntry:@"Clock skew detected"]; 141| 0| timeSinceRestore = 0; 142| 0| } 143| | 144| 0| _secondsSpentInCurrentSession += timeSinceRestore; 145| | 146| 0| NSDictionary *timeSpentData = 147| 0| @{ 148| 0| FBSDKTimeSpentPersistKeySessionSecondsSpent : @(_secondsSpentInCurrentSession), 149| 0| FBSDKTimeSpentPersistKeySessionNumInterruptions : @(_numInterruptionsInCurrentSession), 150| 0| FBSDKTimeSpentPersistKeyLastSuspendTime : @(now), 151| 0| FBSDKTimeSpentPersistKeySessionID : _sessionID, 152| 0| }; 153| | 154| 0| NSString *content = [FBSDKBasicUtility JSONStringForObject:timeSpentData error:NULL invalidObjectHandler:NULL]; 155| | 156| 0| [content writeToFile:[FBSDKBasicUtility persistenceFilePath:FBSDKTimeSpentFilename] 157| 0| atomically:YES 158| 0| encoding:NSASCIIStringEncoding 159| 0| error:nil]; 160| | 161| 0| NSString *msg = [NSString stringWithFormat:@"FBSDKTimeSpentData Persist: %@", content]; 162| 0| [FBSDKLogger singleShotLogEntry:FBSDKLoggingBehaviorAppEvents 163| 0| logEntry:msg]; 164| | 165| 0| _isCurrentlyLoaded = NO; 166| 0|} 167| | 168| |// Called during activation - either through an explicit 'activateApp' call or implicitly when the app is foregrounded. 169| |// In both cases, we restore the persisted event data. In the case of the activateApp, we log an 'app activated' 170| |// event if there's been enough time between the last deactivation and now. 171| |- (void)restore:(BOOL)calledFromActivateApp 172| 0|{ 173| 0| [self ensureOnMainThread:NSStringFromSelector(_cmd) className:NSStringFromClass([self class])]; 174| | 175| | // It's possible to call this multiple times during the time the app is in the foreground. If this is the case, 176| | // just restore persisted data the first time. 177| 0| if (!_isCurrentlyLoaded) { 178| 0| NSTimeInterval now = round([NSDate date].timeIntervalSince1970); 179| 0| NSString *content = 180| 0| [[NSString alloc] initWithContentsOfFile:[FBSDKBasicUtility persistenceFilePath:FBSDKTimeSpentFilename] 181| 0| usedEncoding:nil 182| 0| error:nil]; 183| | 184| 0| if (!content) { 185| | // Nothing persisted, so this is the first launch. 186| 0| _sessionID = [NSUUID UUID].UUIDString; 187| 0| _secondsSpentInCurrentSession = 0; 188| 0| _numInterruptionsInCurrentSession = 0; 189| 0| _lastSuspendTime = 0; 190| | 191| | // We want to log the app activation event on the first launch, but not the deactivate event 192| 0| _shouldLogActivateEvent = YES; 193| 0| _shouldLogDeactivateEvent = NO; 194| 0| } else { 195| 0| NSDictionary *results = [FBSDKBasicUtility objectForJSONString:content error:NULL]; 196| | 197| 0| _lastSuspendTime = [results[FBSDKTimeSpentPersistKeyLastSuspendTime] longValue]; 198| | 199| 0| _timeSinceLastSuspend = now - _lastSuspendTime; 200| 0| _secondsSpentInCurrentSession = [results[FBSDKTimeSpentPersistKeySessionSecondsSpent] intValue]; 201| 0| _sessionID = results[FBSDKTimeSpentPersistKeySessionID] ?: [NSUUID UUID].UUIDString; 202| 0| _numInterruptionsInCurrentSession = [results[FBSDKTimeSpentPersistKeySessionNumInterruptions] intValue]; 203| 0| _shouldLogActivateEvent = (_timeSinceLastSuspend > [[self.serverConfigurationProvider cachedServerConfiguration] sessionTimoutInterval]); 204| | 205| | // Other than the first launch, we always log the last session's deactivate with this session's activate. 206| 0| _shouldLogDeactivateEvent = _shouldLogActivateEvent; 207| | 208| 0| if (!_shouldLogDeactivateEvent) { 209| | // If we're not logging, then the time we spent deactivated is considered another interruption. But cap it 210| | // so errant or test uses doesn't blow out the cardinality on the backend processing 211| 0| _numInterruptionsInCurrentSession = MIN(_numInterruptionsInCurrentSession + 1, 200); 212| 0| } 213| 0| } 214| | 215| 0| _lastRestoreTime = now; 216| 0| _isCurrentlyLoaded = YES; 217| | 218| 0| if (calledFromActivateApp) { 219| | // It's important to log deactivate first to reset sessionID 220| 0| if (_shouldLogDeactivateEvent) { 221| 0| [self.eventLogger logEvent:FBSDKAppEventNameDeactivatedApp 222| 0| valueToSum:_secondsSpentInCurrentSession 223| 0| parameters:[self appEventsParametersForDeactivate]]; 224| | 225| | // We've logged the session stats, now reset. 226| 0| _secondsSpentInCurrentSession = 0; 227| 0| _numInterruptionsInCurrentSession = 0; 228| 0| _sessionID = [NSUUID UUID].UUIDString; 229| 0| } 230| | 231| 0| if (_shouldLogActivateEvent) { 232| 0| [self.eventLogger logEvent:FBSDKAppEventNameActivatedApp 233| 0| parameters:[self appEventsParametersForActivate]]; 234| | // Unless the behavior is set to only allow explicit flushing, we go ahead and flush. App launch 235| | // events are critical to Analytics so we don't want to lose them. 236| 0| if (self.eventLogger.flushBehavior != FBSDKAppEventsFlushBehaviorExplicitOnly) { 237| 0| [self.eventLogger flushForReason:FBSDKAppEventsFlushReasonEagerlyFlushingEvent]; 238| 0| } 239| 0| } 240| 0| } 241| 0| } 242| 0|} 243| | 244| |- (NSDictionary *)appEventsParametersForActivate 245| 0|{ 246| 0| return @{ 247| 0| FBSDKAppEventParameterLaunchSource : [self getSourceApplication], 248| 0| FBSDKAppEventParameterNameSessionID : _sessionID, 249| 0| }; 250| 0|} 251| | 252| |- (NSDictionary *)appEventsParametersForDeactivate 253| 0|{ 254| 0| int quantaIndex = 0; 255| 0| while (_timeSinceLastSuspend > INACTIVE_SECONDS_QUANTA[quantaIndex]) { 256| 0| quantaIndex++; 257| 0| } 258| | 259| 0| NSMutableDictionary *params = [@{ FBSDKAppEventParameterNameSessionInterruptions : @(_numInterruptionsInCurrentSession), 260| 0| FBSDKAppEventParameterNameTimeBetweenSessions : [NSString stringWithFormat:@"session_quanta_%d", quantaIndex], 261| 0| FBSDKAppEventParameterLaunchSource : [self getSourceApplication], 262| 0| FBSDKAppEventParameterNameSessionID : _sessionID ?: @"", } mutableCopy]; 263| 0| if (_lastSuspendTime) { 264| 0| [FBSDKTypeUtility dictionary:params setObject:@(_lastSuspendTime) forKey:@"_logTime"]; 265| 0| } 266| 0| return [params copy]; 267| 0|} 268| | 269| |- (void)setSourceApplication:(nullable NSString *)sourceApplication openURL:(NSURL *)url 270| 0|{ 271| 0| [self setSourceApplication:sourceApplication 272| 0| isFromAppLink:[FBSDKInternalUtility parametersFromFBURL:url][@"al_applink_data"] != nil]; 273| 0|} 274| | 275| |- (void)setSourceApplication:(nullable NSString *)sourceApplication isFromAppLink:(BOOL)isFromAppLink 276| 0|{ 277| 0| self.isOpenedFromAppLink = isFromAppLink; 278| 0| self.sourceApplication = sourceApplication; 279| 0|} 280| | 281| |- (NSString *)getSourceApplication 282| 0|{ 283| 0| NSString *openType = @"Unclassified"; 284| 0| if (self.isOpenedFromAppLink) { 285| 0| openType = @"AppLink"; 286| 0| } 287| 0| return (self.sourceApplication 288| 0| ? [NSString stringWithFormat:@"%@(%@)", openType, self.sourceApplication] 289| 0| : openType); 290| 0|} 291| | 292| |- (void)resetSourceApplication 293| 0|{ 294| 0| self.sourceApplication = nil; 295| 0| self.isOpenedFromAppLink = NO; 296| 0|} 297| | 298| |- (void)registerAutoResetSourceApplication 299| 0|{ 300| 0| [[NSNotificationCenter defaultCenter] addObserver:self 301| 0| selector:@selector(resetSourceApplication) 302| 0| name:UIApplicationDidEnterBackgroundNotification 303| 0| object:nil]; 304| 0|} 305| | 306| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKTimeSpentRecordingFactory.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKTimeSpentRecordingFactory.h" 20| | 21| |#import "FBSDKEventLogging.h" 22| |#import "FBSDKServerConfigurationProviding.h" 23| |#import "FBSDKTimeSpentData.h" 24| |#import "FBSDKTimeSpentData+SourceApplicationTracking.h" 25| |#import "FBSDKTimeSpentData+TimeSpentRecording.h" 26| | 27| |NS_ASSUME_NONNULL_BEGIN 28| | 29| |@interface FBSDKTimeSpentRecordingFactory () 30| | 31| |@property (nonnull, nonatomic, readonly) Class serverConfigurationProvider; 32| |@property (nonnull, nonatomic, readonly) id eventLogger; 33| | 34| |@end 35| | 36| |@implementation FBSDKTimeSpentRecordingFactory 37| | 38| |- (instancetype)initWithEventLogger:(id)eventLogger 39| | serverConfigurationProvider:(Class)serverConfigurationProvider 40| 0|{ 41| 0| if ((self = [super init])) { 42| 0| _eventLogger = eventLogger; 43| 0| _serverConfigurationProvider = serverConfigurationProvider; 44| 0| } 45| 0| return self; 46| 0|} 47| | 48| |- (id)createTimeSpentRecorder 49| 0|{ 50| 0| return [[FBSDKTimeSpentData alloc] initWithEventLogger:self.eventLogger 51| 0| serverConfigurationProvider:self.serverConfigurationProvider]; 52| 0|} 53| | 54| |@end 55| | 56| |NS_ASSUME_NONNULL_END /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/Integrity/FBSDKIntegrityManager.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKIntegrityManager.h" 24| | 25| | #import "FBSDKCoreKitBasicsImport.h" 26| | #import "FBSDKGateKeeperManaging.h" 27| | #import "FBSDKIntegrityProcessing.h" 28| | 29| |@interface FBSDKIntegrityManager () 30| | 31| |@property (nonatomic) Class gateKeeperManager; 32| |@property (nonatomic, weak) id integrityProcessor; 33| |@property (nonatomic) BOOL isIntegrityEnabled; 34| |@property (nonatomic) BOOL isSampleEnabled; 35| | 36| |@end 37| | 38| |@implementation FBSDKIntegrityManager 39| | 40| |- (instancetype)initWithGateKeeperManager:(Class)gateKeeperManager 41| | integrityProcessor:(id)integrityProcessor 42| 0|{ 43| 0| if ((self = [super init])) { 44| 0| _gateKeeperManager = gateKeeperManager; 45| 0| _integrityProcessor = integrityProcessor; 46| 0| } 47| 0| return self; 48| 0|} 49| | 50| |- (void)enable 51| 0|{ 52| 0| self.isIntegrityEnabled = YES; 53| 0| self.isSampleEnabled = [self.gateKeeperManager boolForKey:@"FBSDKFeatureIntegritySample" defaultValue:false]; 54| 0|} 55| | 56| |// Unused parameter eventName is required for conformance to shared protocol for processing app events. 57| |- (nullable NSDictionary *)processParameters:(nullable NSDictionary *)parameters 58| | eventName:(NSString *)eventName 59| 0|{ 60| 0| if (!self.isIntegrityEnabled || parameters.count == 0) { 61| 0| return parameters; 62| 0| } 63| 0| NSMutableDictionary *params = [NSMutableDictionary dictionaryWithDictionary:parameters]; 64| 0| NSMutableDictionary *restrictiveParams = [NSMutableDictionary dictionary]; 65| | 66| 0| for (NSString *key in [parameters keyEnumerator]) { 67| 0| NSString *valueString = [FBSDKTypeUtility coercedToStringValue:parameters[key]]; 68| 0| BOOL shouldFilter = [self.integrityProcessor processIntegrity:key] || [self.integrityProcessor processIntegrity:valueString]; 69| 0| if (shouldFilter) { 70| 0| [FBSDKTypeUtility dictionary:restrictiveParams setObject:self.isSampleEnabled ? valueString : @"" forKey:key]; 71| 0| [params removeObjectForKey:key]; 72| 0| } 73| 0| } 74| 0| if ([restrictiveParams count] > 0) { 75| 0| NSString *restrictiveParamsJSONString = [FBSDKBasicUtility JSONStringForObject:restrictiveParams 76| 0| error:NULL 77| 0| invalidObjectHandler:NULL]; 78| 0| [FBSDKTypeUtility dictionary:params setObject:restrictiveParamsJSONString forKey:@"_onDeviceParams"]; 79| 0| } 80| 0| return [params copy]; 81| 0|} 82| | 83| |@end 84| | 85| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/Integrity/FBSDKRestrictiveDataFilterManager.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKRestrictiveDataFilterManager.h" 20| | 21| |#import "FBSDKCoreKitBasicsImport.h" 22| |#import "FBSDKServerConfigurationManager.h" 23| |#import "FBSDKServerConfigurationProviding.h" 24| | 25| |@interface FBSDKRestrictiveEventFilter : NSObject 26| | 27| |@property (nonatomic, readonly, copy) NSString *eventName; 28| |@property (nonatomic, readonly, copy) NSDictionary *restrictiveParams; 29| | 30| |- (instancetype)init NS_UNAVAILABLE; 31| |+ (instancetype)new NS_UNAVAILABLE; 32| | 33| |- (instancetype)initWithEventName:(NSString *)eventName 34| | restrictiveParams:(NSDictionary *)restrictiveParams; 35| | 36| |@end 37| | 38| |@implementation FBSDKRestrictiveEventFilter 39| | 40| |- (instancetype)initWithEventName:(NSString *)eventName 41| | restrictiveParams:(NSDictionary *)restrictiveParams 42| 0|{ 43| 0| self = [super init]; 44| 0| if (self) { 45| 0| _eventName = [eventName copy]; 46| 0| _restrictiveParams = [restrictiveParams copy]; 47| 0| } 48| | 49| 0| return self; 50| 0|} 51| | 52| |@end 53| | 54| |static FBSDKRestrictiveDataFilterManager *_instance; 55| | 56| |@interface FBSDKRestrictiveDataFilterManager () 57| | 58| |@property BOOL isRestrictiveEventFilterEnabled; 59| |@property (nonatomic) NSMutableArray *params; 60| |@property (nonatomic) NSMutableSet *restrictedEvents; 61| |@property (nonatomic) Class serverConfigurationProvider; 62| | 63| |@end 64| | 65| |@implementation FBSDKRestrictiveDataFilterManager 66| | 67| |- (instancetype)initWithServerConfigurationProvider:(Class)serverConfigurationProvider 68| 0|{ 69| 0| self.serverConfigurationProvider = serverConfigurationProvider; 70| 0| return self; 71| 0|} 72| | 73| |- (void)enable 74| 0|{ 75| 0| @synchronized(self) { 76| 0| @try { 77| 0| if (!self.isRestrictiveEventFilterEnabled) { 78| 0| NSDictionary *restrictiveParams = [self.serverConfigurationProvider cachedServerConfiguration].restrictiveParams; 79| 0| if (restrictiveParams) { 80| 0| [self updateFilters:restrictiveParams]; 81| 0| self.isRestrictiveEventFilterEnabled = YES; 82| 0| } 83| 0| } 84| 0| } @catch (NSException *exception) {} 85| 0| } 86| 0|} 87| | 88| |- (NSDictionary *)processParameters:(NSDictionary *)parameters 89| | eventName:(NSString *)eventName 90| 0|{ 91| 0| if (!self.isRestrictiveEventFilterEnabled) { 92| 0| return parameters; 93| 0| } 94| 0| if (parameters) { 95| 0| @try { 96| 0| NSMutableDictionary *params = [NSMutableDictionary dictionaryWithDictionary:parameters]; 97| 0| NSMutableDictionary *restrictedParams = [NSMutableDictionary dictionary]; 98| | 99| 0| for (NSString *key in [parameters keyEnumerator]) { 100| 0| NSString *type = [self getMatchedDataTypeWithEventName:eventName paramKey:key]; 101| 0| if (type) { 102| 0| [FBSDKTypeUtility dictionary:restrictedParams setObject:type forKey:key]; 103| 0| [params removeObjectForKey:key]; 104| 0| } 105| 0| } 106| | 107| 0| if ([[restrictedParams allKeys] count] > 0) { 108| 0| NSString *restrictedParamsJSONString = [FBSDKBasicUtility JSONStringForObject:restrictedParams 109| 0| error:NULL 110| 0| invalidObjectHandler:NULL]; 111| 0| [FBSDKTypeUtility dictionary:params setObject:restrictedParamsJSONString forKey:@"_restrictedParams"]; 112| 0| } 113| | 114| 0| return [params copy]; 115| 0| } @catch (NSException *exception) { 116| 0| return parameters; 117| 0| } 118| 0| } 119| | 120| 0| return nil; 121| 0|} 122| | 123| |- (void)processEvents:(NSMutableArray *> *)events 124| 0|{ 125| 0| @try { 126| 0| if (!self.isRestrictiveEventFilterEnabled) { 127| 0| return; 128| 0| } 129| | 130| 0| static NSString *const REPLACEMENT_STRING = @"_removed_"; 131| | 132| 0| for (NSDictionary *> *event in events) { 133| 0| if ([self isRestrictedEvent:event[@"event"][@"_eventName"]]) { 134| 0| [FBSDKTypeUtility dictionary:event[@"event"] setObject:REPLACEMENT_STRING forKey:@"_eventName"]; 135| 0| } 136| 0| } 137| 0| } @catch (NSException *exception) {} 138| 0|} 139| | 140| |#pragma mark - Private Methods 141| | 142| |- (BOOL)isRestrictedEvent:(NSString *)eventName 143| 0|{ 144| 0| @synchronized(self) { 145| 0| return [self.restrictedEvents containsObject:eventName]; 146| 0| } 147| 0|} 148| | 149| |- (nullable NSString *)getMatchedDataTypeWithEventName:(NSString *)eventName 150| | paramKey:(NSString *)paramKey 151| 0|{ 152| | // match by params in custom events with event name 153| 0| for (FBSDKRestrictiveEventFilter *filter in self.params) { 154| 0| if ([filter.eventName isEqualToString:eventName]) { 155| 0| NSString *type = [FBSDKTypeUtility coercedToStringValue:filter.restrictiveParams[paramKey]]; 156| 0| if (type) { 157| 0| return type; 158| 0| } 159| 0| } 160| 0| } 161| 0| return nil; 162| 0|} 163| | 164| |- (void)updateFilters:(nullable NSDictionary *)restrictiveParams 165| 0|{ 166| 0| static NSString *const RESTRICTIVE_PARAM_KEY = @"restrictive_param"; 167| 0| static NSString *const PROCESS_EVENT_NAME_KEY = @"process_event_name"; 168| | 169| 0| restrictiveParams = [FBSDKTypeUtility dictionaryValue:restrictiveParams]; 170| 0| if (restrictiveParams.count > 0) { 171| 0| @synchronized(self) { 172| 0| [self.params removeAllObjects]; 173| 0| [self.restrictedEvents removeAllObjects]; 174| 0| NSMutableArray *eventFilterArray = [NSMutableArray array]; 175| 0| NSMutableSet *restrictedEventSet = [NSMutableSet set]; 176| 0| for (NSString *eventName in restrictiveParams.allKeys) { 177| 0| NSDictionary *eventInfo = restrictiveParams[eventName]; 178| 0| if (!eventInfo) { 179| 0| continue; 180| 0| } 181| 0| if (eventInfo[RESTRICTIVE_PARAM_KEY]) { 182| 0| FBSDKRestrictiveEventFilter *restrictiveEventFilter = [[FBSDKRestrictiveEventFilter alloc] initWithEventName:eventName 183| 0| restrictiveParams:eventInfo[RESTRICTIVE_PARAM_KEY]]; 184| 0| [FBSDKTypeUtility array:eventFilterArray addObject:restrictiveEventFilter]; 185| 0| } 186| 0| if (restrictiveParams[eventName][PROCESS_EVENT_NAME_KEY]) { 187| 0| [restrictedEventSet addObject:eventName]; 188| 0| } 189| 0| } 190| 0| self.params = eventFilterArray; 191| 0| self.restrictedEvents = restrictedEventSet; 192| 0| } 193| 0| } 194| 0|} 195| | 196| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/ML/FBSDKMLMacros.h: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#ifndef FBSDKMLMacros_h 20| |#define FBSDKMLMacros_h 21| | 22| |// keys for ML 23| 0|#define MODEL_REQUEST_INTERVAL (60 * 60 * 24 * 3) 24| 0|#define MODEL_REQUEST_TIMESTAMP_KEY @"com.facebook.sdk:FBSDKModelRequestTimestamp" 25| | 26| 0|#define FBSDK_ML_MODEL_PATH @"models" 27| 0|#define MODEL_INFO_KEY @"com.facebook.sdk:FBSDKModelInfo" 28| 0|#define ASSET_URI_KEY @"asset_uri" 29| 0|#define RULES_URI_KEY @"rules_uri" 30| 0|#define THRESHOLDS_KEY @"thresholds" 31| 0|#define USE_CASE_KEY @"use_case" 32| 0|#define VERSION_ID_KEY @"version_id" 33| 0|#define MODEL_DATA_KEY @"data" 34| | 35| 0|#define MTMLKey @"MTML" 36| 0|#define MTMLTaskAppEventPredKey @"MTML_APP_EVENT_PRED" 37| 0|#define MTMLTaskIntegrityDetectKey @"MTML_INTEGRITY_DETECT" 38| | 39| |// keys for Suggested Event 40| |#define SUGGEST_EVENT_KEY @"SUGGEST_EVENT" 41| |#define DENSE_FEATURE_KEY @"DENSE_FEATURE" 42| 0|#define SUGGESTED_EVENT_OTHER @"other" 43| | 44| |#endif /* FBSDKMLMacros_h */ /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/ML/FBSDKModelManager.mm: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKModelManager.h" 24| | #import "FBSDKModelManager+IntegrityProcessing.h" 25| | 26| | #import "FBSDKAppEvents+Internal.h" 27| | #import "FBSDKAppEventsParameterProcessing.h" 28| | #import "FBSDKCoreKitBasicsImport.h" 29| | #import "FBSDKDataPersisting.h" 30| | #import "FBSDKFeatureChecking.h" 31| | #import "FBSDKFeatureExtractor.h" 32| | #import "FBSDKGateKeeperManager.h" 33| | #import "FBSDKGraphRequestProviding.h" 34| | #import "FBSDKIntegrityManager+AppEventsParametersProcessing.h" 35| | #import "FBSDKMLMacros.h" 36| | #import "FBSDKModelParser.h" 37| | #import "FBSDKModelRuntime.hpp" 38| | #import "FBSDKModelUtility.h" 39| | #import "FBSDKSettingsProtocol.h" 40| | #import "FBSDKSuggestedEventsIndexer.h" 41| | 42| |static NSString *const INTEGRITY_NONE = @"none"; 43| |static NSString *const INTEGRITY_ADDRESS = @"address"; 44| |static NSString *const INTEGRITY_HEALTH = @"health"; 45| | 46| |extern FBSDKAppEventName FBSDKAppEventNameCompletedRegistration; 47| |extern FBSDKAppEventName FBSDKAppEventNameAddedToCart; 48| |extern FBSDKAppEventName FBSDKAppEventNamePurchased; 49| |extern FBSDKAppEventName FBSDKAppEventNameInitiatedCheckout; 50| | 51| |static NSString *_directoryPath; 52| |static NSMutableDictionary *_modelInfo; 53| |static std::unordered_map _MTMLWeights; 54| | 55| |NS_ASSUME_NONNULL_BEGIN 56| | 57| |@interface FBSDKModelManager () 58| | 59| |@property (nonatomic) id integrityParametersProcessor; 60| |@property (nullable, nonatomic) id featureChecker; 61| |@property (nullable, nonatomic) id graphRequestFactory; 62| |@property (nullable, nonatomic) id fileManager; 63| |@property (nullable, nonatomic) id store; 64| |@property (nullable, nonatomic) id settings; 65| |@property (nullable, nonatomic) Class dataExtractor; 66| | 67| |@end 68| | 69| |@implementation FBSDKModelManager 70| | 71| |typedef void (^FBSDKDownloadCompletionBlock)(void); 72| | 73| |// Transitional singleton introduced as a way to change the usage semantics 74| |// from a type-based interface to an instance-based interface. 75| |+ (instancetype)shared 76| 0|{ 77| 0| static dispatch_once_t nonce; 78| 0| static id instance; 79| 0| dispatch_once(&nonce, ^{ 80| 0| instance = [self new]; 81| 0| }); 82| 0| return instance; 83| 0|} 84| | 85| | #pragma mark - Dependency Management 86| | 87| |- (void)configureWithFeatureChecker:(id)featureChecker 88| | graphRequestFactory:(id)graphRequestFactory 89| | fileManager:(id)fileManager 90| | store:(id)store 91| | settings:(id)settings 92| | dataExtractor:(Class)dataExtractor 93| 0|{ 94| 0| _featureChecker = featureChecker; 95| 0| _graphRequestFactory = graphRequestFactory; 96| 0| _fileManager = fileManager; 97| 0| _store = store; 98| 0| _settings = settings; 99| 0| _dataExtractor = dataExtractor; 100| 0|} 101| | 102| | #pragma mark - Public methods 103| | 104| |static dispatch_once_t enableNonce; 105| | 106| |- (void)enable 107| 0|{ 108| 0| @try { 109| 0| dispatch_once(&enableNonce, ^{ 110| 0| NSString *languageCode = [[NSLocale currentLocale] objectForKey:NSLocaleLanguageCode]; 111| | // If the languageCode could not be fetched successfully, it's regarded as "en" by default. 112| 0| if (languageCode && ![languageCode isEqualToString:@"en"]) { 113| 0| return; 114| 0| } 115| | 116| 0| _directoryPath = [NSTemporaryDirectory() stringByAppendingPathComponent:FBSDK_ML_MODEL_PATH]; 117| 0| if (![self.fileManager fileExistsAtPath:_directoryPath]) { 118| 0| [self.fileManager createDirectoryAtPath:_directoryPath withIntermediateDirectories:YES attributes:NULL error:NULL]; 119| 0| } 120| 0| _modelInfo = [self.store objectForKey:MODEL_INFO_KEY]; 121| 0| NSDate *timestamp = [self.store objectForKey:MODEL_REQUEST_TIMESTAMP_KEY]; 122| 0| if ([_modelInfo count] == 0 || ![self.featureChecker isEnabled:FBSDKFeatureModelRequest] || ![self.class isValidTimestamp:timestamp]) { 123| | // fetch api 124| 0| NSString *graphPath = [NSString stringWithFormat:@"%@/model_asset", self.settings.appID]; 125| 0| id request = [self.graphRequestFactory createGraphRequestWithGraphPath:graphPath]; 126| 0| __weak FBSDKModelManager *weakSelf = self; 127| 0| [request startWithCompletion:^(id connection, id result, NSError *error) { 128| 0| if (!error) { 129| 0| NSDictionary *resultDictionary = [FBSDKTypeUtility dictionaryValue:result]; 130| 0| NSArray *rawModels = resultDictionary[MODEL_DATA_KEY]; 131| 0| if ([rawModels isKindOfClass:NSArray.class]) { 132| 0| NSDictionary *modelInfo = [weakSelf.class convertToDictionary:rawModels]; 133| 0| if (modelInfo) { 134| 0| _modelInfo = [modelInfo mutableCopy]; 135| 0| [weakSelf.class processMTML]; 136| | // update cache for model info and timestamp 137| 0| [weakSelf.store setObject:_modelInfo forKey:MODEL_INFO_KEY]; 138| 0| [weakSelf.store setObject:[NSDate date] forKey:MODEL_REQUEST_TIMESTAMP_KEY]; 139| 0| } 140| 0| } 141| 0| } 142| 0| [self checkFeaturesAndExecuteForMTML]; 143| 0| }]; 144| 0| } else { 145| 0| [self checkFeaturesAndExecuteForMTML]; 146| 0| } 147| 0| }); 148| 0| } @catch (NSException *exception) { 149| 0| NSLog(@"Fail to enable model manager, exception reason: %@", exception.reason); 150| 0| } 151| 0|} 152| | 153| |- (nullable NSDictionary *)getRulesForKey:(NSString *)useCase 154| 0|{ 155| 0| @try { 156| 0| NSDictionary *model = [FBSDKTypeUtility dictionary:_modelInfo objectForKey:useCase ofType:NSObject.class]; 157| 0| if (model && model[VERSION_ID_KEY]) { 158| 0| NSString *filePath = [_directoryPath stringByAppendingPathComponent:[NSString stringWithFormat:@"%@_%@.rules", useCase, model[VERSION_ID_KEY]]]; 159| 0| if (filePath) { 160| 0| NSData *rulesData = [self.dataExtractor dataWithContentsOfFile:filePath options:NSDataReadingMappedIfSafe error:nil]; 161| 0| NSDictionary *rules = [FBSDKTypeUtility JSONObjectWithData:rulesData options:0 error:nil]; 162| 0| return rules; 163| 0| } 164| 0| } 165| 0| } @catch (NSException *exception) { 166| 0| NSLog(@"Fail to get rules for usecase %@ from ml model, exception reason: %@", useCase, exception.reason); 167| 0| } 168| 0| return nil; 169| 0|} 170| | 171| |- (nullable NSData *)getWeightsForKey:(NSString *)useCase 172| 0|{ 173| 0| if (!_modelInfo || !_directoryPath) { 174| 0| return nil; 175| 0| } 176| 0| if ([useCase hasPrefix:MTMLKey]) { 177| 0| useCase = MTMLKey; 178| 0| } 179| 0| NSDictionary *model = [FBSDKTypeUtility dictionary:_modelInfo objectForKey:useCase ofType:NSObject.class]; 180| 0| if (model && model[VERSION_ID_KEY]) { 181| 0| NSString *path = [_directoryPath stringByAppendingPathComponent:[NSString stringWithFormat:@"%@_%@.weights", useCase, model[VERSION_ID_KEY]]]; 182| 0| if (!path) { 183| 0| return nil; 184| 0| } 185| 0| return [NSData dataWithContentsOfFile:path 186| 0| options:NSDataReadingMappedIfSafe 187| 0| error:nil]; 188| 0| } 189| 0| return nil; 190| 0|} 191| | 192| |- (nullable NSArray *)getThresholdsForKey:(NSString *)useCase 193| 0|{ 194| 0| if (!_modelInfo) { 195| 0| return nil; 196| 0| } 197| 0| NSDictionary *modelInfo = _modelInfo[useCase]; 198| 0| if (!modelInfo) { 199| 0| return nil; 200| 0| } 201| 0| return modelInfo[THRESHOLDS_KEY]; 202| 0|} 203| | 204| | #pragma mark - Integrity Inferencer method 205| | 206| |// Used by the `integrityParametersProcessor` which holds a weak reference to this instance 207| |- (BOOL)processIntegrity:(nullable NSString *)param 208| 0|{ 209| 0| NSString *integrityType = INTEGRITY_NONE; 210| 0| @try { 211| 0| if (param.length == 0 || _MTMLWeights.size() == 0) { 212| 0| return false; 213| 0| } 214| 0| NSArray *integrityMapping = [self.class getIntegrityMapping]; 215| 0| NSString *text = [FBSDKModelUtility normalizedText:param]; 216| 0| const char *bytes = [text UTF8String]; 217| 0| if ((int)strlen(bytes) == 0) { 218| 0| return false; 219| 0| } 220| 0| NSArray *thresholds = [FBSDKModelManager.shared getThresholdsForKey:MTMLTaskIntegrityDetectKey]; 221| 0| if (thresholds.count != integrityMapping.count) { 222| 0| return false; 223| 0| } 224| 0| const fbsdk::MTensor &res = fbsdk::predictOnMTML("integrity_detect", bytes, _MTMLWeights, nullptr); 225| 0| const float *res_data = res.data(); 226| 0| for (int i = 0; i < thresholds.count; i++) { 227| 0| if ((float)res_data[i] >= (float)[[FBSDKTypeUtility array:thresholds objectAtIndex:i] floatValue]) { 228| 0| integrityType = [FBSDKTypeUtility array:integrityMapping objectAtIndex:i]; 229| 0| break; 230| 0| } 231| 0| } 232| 0| } @catch (NSException *exception) { 233| 0| NSLog(@"Fail to process parameter for integrity usecase, exception reason: %@", exception.reason); 234| 0| } 235| 0| return ![integrityType isEqualToString:INTEGRITY_NONE]; 236| 0|} 237| | 238| | #pragma mark - SuggestedEvents Inferencer method 239| | 240| |- (NSString *)processSuggestedEvents:(NSString *)textFeature denseData:(nullable float *)denseData 241| 0|{ 242| 0| @try { 243| 0| NSArray *eventMapping = [FBSDKModelManager getSuggestedEventsMapping]; 244| 0| if (textFeature.length == 0 || _MTMLWeights.size() == 0 || !denseData) { 245| 0| return SUGGESTED_EVENT_OTHER; 246| 0| } 247| 0| const char *bytes = [textFeature UTF8String]; 248| 0| if ((int)strlen(bytes) == 0) { 249| 0| return SUGGESTED_EVENT_OTHER; 250| 0| } 251| | 252| 0| NSArray *thresholds = [FBSDKModelManager.shared getThresholdsForKey:MTMLTaskAppEventPredKey]; 253| 0| if (thresholds.count != eventMapping.count) { 254| 0| return SUGGESTED_EVENT_OTHER; 255| 0| } 256| | 257| 0| const fbsdk::MTensor &res = fbsdk::predictOnMTML("app_event_pred", bytes, _MTMLWeights, denseData); 258| 0| const float *res_data = res.data(); 259| 0| for (int i = 0; i < thresholds.count; i++) { 260| 0| if ((float)res_data[i] >= (float)[[FBSDKTypeUtility array:thresholds objectAtIndex:i] floatValue]) { 261| 0| return [FBSDKTypeUtility array:eventMapping objectAtIndex:i]; 262| 0| } 263| 0| } 264| 0| } @catch (NSException *exception) { 265| 0| NSLog(@"Fail to process suggested events, exception reason: %@", exception.reason); 266| 0| } 267| 0| return SUGGESTED_EVENT_OTHER; 268| 0|} 269| | 270| | #pragma mark - Private methods 271| | 272| |+ (BOOL)isValidTimestamp:(NSDate *)timestamp 273| 0|{ 274| 0| if (!timestamp) { 275| 0| return NO; 276| 0| } 277| 0| return ([[NSDate date] timeIntervalSinceDate:timestamp] < MODEL_REQUEST_INTERVAL); 278| 0|} 279| | 280| |+ (void)processMTML 281| 0|{ 282| 0| NSString *mtmlAssetUri = nil; 283| 0| long mtmlVersionId = 0; 284| 0| for (NSString *useCase in _modelInfo) { 285| 0| if (![useCase isKindOfClass:NSString.class]) { 286| 0| continue; 287| 0| } 288| 0| NSDictionary *model = _modelInfo[useCase]; 289| 0| if ([useCase hasPrefix:MTMLKey]) { 290| 0| if (![model[ASSET_URI_KEY] isKindOfClass:NSString.class] 291| 0| || ![model[VERSION_ID_KEY] isKindOfClass:NSNumber.class]) { 292| 0| continue; 293| 0| } 294| 0| mtmlAssetUri = model[ASSET_URI_KEY]; 295| 0| long thisVersionId = [model[VERSION_ID_KEY] longValue]; 296| 0| mtmlVersionId = thisVersionId > mtmlVersionId ? thisVersionId : mtmlVersionId; 297| 0| } 298| 0| } 299| 0| if (mtmlAssetUri && mtmlVersionId > 0) { 300| 0| [FBSDKTypeUtility dictionary:_modelInfo setObject:@{ 301| 0| USE_CASE_KEY : MTMLKey, 302| 0| ASSET_URI_KEY : mtmlAssetUri, 303| 0| VERSION_ID_KEY : [NSNumber numberWithLong:mtmlVersionId], 304| 0| } forKey:MTMLKey]; 305| 0| } 306| 0|} 307| | 308| |- (void)checkFeaturesAndExecuteForMTML 309| 0|{ 310| 0| [self getModelAndRules:MTMLKey onSuccess:^() { 311| 0| NSData *data = [FBSDKModelManager.shared getWeightsForKey:MTMLKey]; 312| 0| _MTMLWeights = [FBSDKModelParser parseWeightsData:data]; 313| 0| if (![FBSDKModelParser validateWeights:_MTMLWeights forKey:MTMLKey]) { 314| 0| return; 315| 0| } 316| | 317| 0| if ([self.featureChecker isEnabled:FBSDKFeatureSuggestedEvents]) { 318| 0| [self getModelAndRules:MTMLTaskAppEventPredKey onSuccess:^() { 319| 0| [FBSDKFeatureExtractor loadRulesForKey:MTMLTaskAppEventPredKey]; 320| 0| [FBSDKSuggestedEventsIndexer.shared enable]; 321| 0| }]; 322| 0| } 323| | 324| 0| if ([self.featureChecker isEnabled:FBSDKFeatureIntelligentIntegrity]) { 325| 0| [self getModelAndRules:MTMLTaskIntegrityDetectKey onSuccess:^() { 326| 0| [self setIntegrityParametersProcessor:[[FBSDKIntegrityManager alloc] initWithGateKeeperManager:FBSDKGateKeeperManager.class 327| 0| integrityProcessor:self]]; 328| 0| [[self integrityParametersProcessor] enable]; 329| 0| }]; 330| 0| } 331| 0| }]; 332| 0|} 333| | 334| |- (void)getModelAndRules:(NSString *)useCaseKey 335| | onSuccess:(FBSDKDownloadCompletionBlock)handler 336| 0|{ 337| 0| dispatch_queue_t queue = dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_DEFAULT, 0); 338| 0| dispatch_group_t group = dispatch_group_create(); 339| | 340| 0| NSDictionary *model = [FBSDKTypeUtility dictionary:_modelInfo objectForKey:useCaseKey ofType:NSObject.class]; 341| 0| if (!model || !_directoryPath) { 342| 0| return; 343| 0| } 344| | 345| 0| NSFileManager *fileManager = [NSFileManager defaultManager]; 346| | // download model asset only if not exist before 347| 0| NSString *assetUrlString = [FBSDKTypeUtility dictionary:model objectForKey:ASSET_URI_KEY ofType:NSObject.class]; 348| 0| NSString *assetFilePath; 349| 0| if (assetUrlString.length > 0) { 350| 0| [self clearCacheForModel:model suffix:@".weights"]; 351| 0| NSString *fileName = useCaseKey; 352| 0| if ([useCaseKey hasPrefix:MTMLKey]) { 353| | // all mtml tasks share the same weights file 354| 0| fileName = MTMLKey; 355| 0| } 356| 0| assetFilePath = [_directoryPath stringByAppendingPathComponent:[NSString stringWithFormat:@"%@_%@.weights", fileName, model[VERSION_ID_KEY]]]; 357| 0| [self download:assetUrlString filePath:assetFilePath queue:queue group:group]; 358| 0| } 359| | 360| | // download rules 361| 0| NSString *rulesUrlString = [FBSDKTypeUtility dictionary:model objectForKey:RULES_URI_KEY ofType:NSObject.class]; 362| 0| NSString *rulesFilePath = nil; 363| | // rules are optional and rulesUrlString may be empty 364| 0| if (rulesUrlString.length > 0) { 365| 0| [self clearCacheForModel:model suffix:@".rules"]; 366| 0| rulesFilePath = [_directoryPath stringByAppendingPathComponent:[NSString stringWithFormat:@"%@_%@.rules", useCaseKey, model[VERSION_ID_KEY]]]; 367| 0| [self download:rulesUrlString filePath:rulesFilePath queue:queue group:group]; 368| 0| } 369| 0| dispatch_group_notify(group, 370| 0| dispatch_get_main_queue(), ^{ 371| 0| if (handler) { 372| 0| if ([fileManager fileExistsAtPath:assetFilePath] && (!rulesFilePath || [fileManager fileExistsAtPath:rulesFilePath])) { 373| 0| handler(); 374| 0| } 375| 0| } 376| 0| }); 377| 0|} 378| | 379| |- (void)clearCacheForModel:(NSDictionary *)model 380| | suffix:(NSString *)suffix 381| 0|{ 382| 0| NSFileManager *fileManager = [NSFileManager defaultManager]; 383| 0| NSString *useCase = model[USE_CASE_KEY]; 384| 0| NSString *version = model[VERSION_ID_KEY]; 385| 0| NSArray *files = [fileManager contentsOfDirectoryAtPath:_directoryPath error:nil]; 386| 0| NSString *prefixWithVersion = [NSString stringWithFormat:@"%@_%@", useCase, version]; 387| 0| for (NSString *file in files) { 388| 0| if ([file hasSuffix:suffix] && [file hasPrefix:useCase] && ![file hasPrefix:prefixWithVersion]) { 389| 0| [fileManager removeItemAtPath:[_directoryPath stringByAppendingPathComponent:file] error:nil]; 390| 0| } 391| 0| } 392| 0|} 393| | 394| |- (void)download:(NSString *)urlString 395| | filePath:(NSString *)filePath 396| | queue:(dispatch_queue_t)queue 397| | group:(dispatch_group_t)group 398| 0|{ 399| 0| if (!filePath || [[NSFileManager defaultManager] fileExistsAtPath:filePath]) { 400| 0| return; 401| 0| } 402| 0| dispatch_group_async(group, 403| 0| queue, ^{ 404| 0| NSURL *url = [NSURL URLWithString:urlString]; 405| 0| NSData *urlData = [NSData dataWithContentsOfURL:url]; 406| 0| if (urlData) { 407| 0| [urlData writeToFile:filePath atomically:YES]; 408| 0| } 409| 0| }); 410| 0|} 411| | 412| |+ (nullable NSMutableDictionary *)convertToDictionary:(NSArray *> *)models 413| 0|{ 414| 0| if ([models count] == 0) { 415| 0| return nil; 416| 0| } 417| 0| NSMutableDictionary *modelInfo = [NSMutableDictionary dictionary]; 418| 0| for (NSDictionary *model in models) { 419| 0| if ([model isKindOfClass:NSDictionary.class] 420| 0| && [model[USE_CASE_KEY] isKindOfClass:NSString.class] 421| 0| && [self isPlistFormatDictionary:model]) { 422| 0| [modelInfo addEntriesFromDictionary:@{model[USE_CASE_KEY] : model}]; 423| 0| } 424| 0| } 425| | 426| 0| if (modelInfo.allKeys.count > 0) { 427| 0| return modelInfo; 428| 0| } else { 429| 0| return nil; 430| 0| } 431| 0|} 432| | 433| |+ (BOOL)isPlistFormatDictionary:(NSDictionary *)dictionary 434| 0|{ 435| 0| __block BOOL isPlistFormat = YES; 436| 0| [dictionary enumerateKeysAndObjectsUsingBlock:^(id _Nonnull key, id _Nonnull obj, BOOL *_Nonnull stop) { 437| 0| if (![key isKindOfClass:NSString.class]) { 438| 0| isPlistFormat = NO; 439| 0| *stop = YES; 440| 0| } 441| 0| if (![obj isKindOfClass:NSArray.class] 442| 0| && ![obj isKindOfClass:NSDictionary.class] 443| 0| && ![obj isKindOfClass:NSData.class] 444| 0| && ![obj isKindOfClass:NSDate.class] 445| 0| && ![obj isKindOfClass:NSNumber.class] 446| 0| && ![obj isKindOfClass:NSString.class]) { 447| 0| isPlistFormat = NO; 448| 0| *stop = YES; 449| 0| } 450| 0| }]; 451| | 452| 0| return isPlistFormat; 453| 0|} 454| | 455| |+ (NSArray *)getIntegrityMapping 456| 0|{ 457| 0| return @[INTEGRITY_NONE, INTEGRITY_ADDRESS, INTEGRITY_HEALTH]; 458| 0|} 459| | 460| |+ (NSArray *)getSuggestedEventsMapping 461| 0|{ 462| 0| return 463| 0| @[SUGGESTED_EVENT_OTHER, 464| 0| FBSDKAppEventNameCompletedRegistration, 465| 0| FBSDKAppEventNameAddedToCart, 466| 0| FBSDKAppEventNamePurchased, 467| 0| FBSDKAppEventNameInitiatedCheckout]; 468| 0|} 469| | 470| | #if DEBUG && FBSDKTEST 471| | 472| |+ (void)reset 473| 0|{ 474| 0| if (enableNonce) { 475| 0| enableNonce = 0; 476| 0| } 477| 0| _directoryPath = nil; 478| 0| _modelInfo = nil; 479| | 480| 0| self.shared.featureChecker = nil; 481| 0| self.shared.graphRequestFactory = nil; 482| 0| self.shared.fileManager = nil; 483| 0| self.shared.store = nil; 484| 0| self.shared.settings = nil; 485| 0| self.shared.dataExtractor = nil; 486| 0|} 487| | 488| |+ (void)setModelInfo:(NSDictionary *)modelInfo 489| 0|{ 490| 0| _modelInfo = [NSMutableDictionary dictionaryWithDictionary:modelInfo]; 491| 0|} 492| | 493| |+ (void)setDirectoryPath:(NSString *)directoryPath 494| 0|{ 495| 0| _directoryPath = directoryPath; 496| 0|} 497| | 498| | #endif 499| | 500| |@end 501| | 502| |NS_ASSUME_NONNULL_END 503| | 504| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/ML/FBSDKModelParser.mm: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKModelParser.h" 24| | 25| | #import "FBSDKCoreKitBasicsImport.h" 26| | #import "FBSDKMLMacros.h" 27| | 28| |NS_ASSUME_NONNULL_BEGIN 29| | 30| |@implementation FBSDKModelParser 31| | 32| |+ (std::unordered_map)parseWeightsData:(NSData *)weightsData 33| 0|{ 34| 0| std::unordered_map weights; 35| 0| if (!weightsData) { 36| 0| return weights; 37| 0| } 38| | 39| 0| const void *data = weightsData.bytes; 40| 0| NSUInteger totalLength = weightsData.length; 41| | 42| 0| if (totalLength < 4) { 43| | // Make sure data length is valid 44| 0| return weights; 45| 0| } 46| 0| try { 47| 0| int length; 48| 0| memcpy(&length, data, 4); 49| 0| if (length + 4 > totalLength) { 50| | // Make sure data length is valid 51| 0| return weights; 52| 0| } 53| | 54| 0| char *json = (char *)data + 4; 55| 0| NSDictionary *info = [FBSDKTypeUtility JSONObjectWithData:[NSData dataWithBytes:json length:length] 56| 0| options:0 57| 0| error:nil]; 58| 0| NSArray *keys = [[info allKeys] sortedArrayUsingComparator:^NSComparisonResult (NSString *key1, NSString *key2) { 59| 0| return [key1 compare:key2]; 60| 0| }]; 61| | 62| 0| int totalFloats = 0; 63| 0| float *floats = (float *)(json + length); 64| 0| NSDictionary *keysMapping = [self getKeysMapping]; 65| 0| for (NSString *key in keys) { 66| 0| NSString *finalKey = key; 67| 0| NSString *mapping = [FBSDKTypeUtility dictionary:keysMapping objectForKey:key ofType:NSObject.class]; 68| 0| if (mapping) { 69| 0| finalKey = mapping; 70| 0| } 71| 0| std::string s_name([finalKey UTF8String]); 72| | 73| 0| std::vector v_shape; 74| 0| NSArray *shape = [FBSDKTypeUtility dictionary:info objectForKey:key ofType:NSObject.class]; 75| 0| int count = 1; 76| 0| for (NSNumber *_s in shape) { 77| 0| int i = [_s intValue]; 78| 0| v_shape.push_back(i); 79| 0| count *= i; 80| 0| } 81| | 82| 0| totalFloats += count; 83| | 84| 0| if ((4 + length + totalFloats * 4) > totalLength) { 85| | // Make sure data length is valid 86| 0| break; 87| 0| } 88| 0| fbsdk::MTensor tensor(v_shape); 89| 0| memcpy(tensor.mutable_data(), floats, sizeof(float) * count); 90| 0| floats += count; 91| | 92| 0| weights[s_name] = tensor; 93| 0| } 94| 0| } catch (const std::exception &e) {} 95| | 96| 0| return weights; 97| 0|} 98| | 99| |+ (bool)validateWeights:(std::unordered_map)weights forKey:(NSString *)key 100| 0|{ 101| 0| NSMutableDictionary *weightsInfoDict = [NSMutableDictionary new]; 102| 0| if ([key hasPrefix:MTMLKey]) { 103| 0| [weightsInfoDict addEntriesFromDictionary:[self getMTMLWeightsInfo]]; 104| 0| } 105| 0| return [self checkWeights:weights withExpectedInfo:weightsInfoDict]; 106| 0|} 107| | 108| | #pragma mark - private methods 109| | 110| |+ (NSDictionary *)getKeysMapping 111| 0|{ 112| 0| return @{ 113| 0| @"embedding.weight" : @"embed.weight", 114| 0| @"dense1.weight" : @"fc1.weight", 115| 0| @"dense2.weight" : @"fc2.weight", 116| 0| @"dense3.weight" : @"fc3.weight", 117| 0| @"dense1.bias" : @"fc1.bias", 118| 0| @"dense2.bias" : @"fc2.bias", 119| 0| @"dense3.bias" : @"fc3.bias" 120| 0| }; 121| 0|} 122| | 123| |+ (NSDictionary *)getMTMLWeightsInfo 124| 0|{ 125| 0| return @{ 126| 0| @"embed.weight" : @[@256, @32], 127| 0| @"convs.0.weight" : @[@32, @32, @3], 128| 0| @"convs.0.bias" : @[@32], 129| 0| @"convs.1.weight" : @[@64, @32, @3], 130| 0| @"convs.1.bias" : @[@64], 131| 0| @"convs.2.weight" : @[@64, @64, @3], 132| 0| @"convs.2.bias" : @[@64], 133| 0| @"fc1.weight" : @[@128, @190], 134| 0| @"fc1.bias" : @[@128], 135| 0| @"fc2.weight" : @[@64, @128], 136| 0| @"fc2.bias" : @[@64], 137| 0| @"integrity_detect.weight" : @[@3, @64], 138| 0| @"integrity_detect.bias" : @[@3], 139| 0| @"app_event_pred.weight" : @[@5, @64], 140| 0| @"app_event_pred.bias" : @[@5] 141| 0| }; 142| 0|} 143| | 144| |+ (bool)checkWeights:(std::unordered_map)weights 145| | withExpectedInfo:(NSDictionary *)weightsInfoDict 146| 0|{ 147| 0| if (weightsInfoDict.count != weights.size()) { 148| 0| return false; 149| 0| } 150| 0| try { 151| 0| for (NSString *key in weightsInfoDict) { 152| 0| if (weights.count(std::string([key UTF8String])) == 0) { 153| 0| return false; 154| 0| } 155| 0| fbsdk::MTensor tensor = weights[std::string([key UTF8String])]; 156| 0| const std::vector &actualSize = tensor.sizes(); 157| 0| NSArray *expectedSize = weightsInfoDict[key]; 158| 0| if (actualSize.size() != expectedSize.count) { 159| 0| return false; 160| 0| } 161| 0| for (int i = 0; i < expectedSize.count; i++) { 162| 0| if ((int)actualSize[i] != (int)[[FBSDKTypeUtility array:expectedSize objectAtIndex:i] intValue]) { 163| 0| return false; 164| 0| } 165| 0| } 166| 0| } 167| 0| } catch (const std::exception &e) { 168| 0| return false; 169| 0| } 170| 0| return true; 171| 0|} 172| | 173| |@end 174| | 175| |NS_ASSUME_NONNULL_END 176| | 177| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/ML/FBSDKModelRuntime.hpp: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #include 24| | 25| | #include 26| | #include 27| | #include 28| | 29| | #import 30| | 31| | #include "FBSDKTensor.hpp" 32| | 33| 0| #define SEQ_LEN 128 34| 0| #define DENSE_FEATURE_LEN 30 35| | 36| |namespace fbsdk { 37| | static void relu(MTensor &x) 38| 0| { 39| 0| float min = 0; 40| 0| float max = FLT_MAX; 41| 0| float *x_data = x.mutable_data(); 42| 0| vDSP_vclip(x_data, 1, &min, &max, x_data, 1, x.count()); 43| 0| } 44| | 45| | static void flatten(MTensor &x, int start_dim) 46| 0| { 47| 0| const std::vector &shape = x.sizes(); 48| 0| std::vector new_shape; 49| 0| for (int i = 0; i < start_dim; i++) { 50| 0| new_shape.push_back(shape[i]); 51| 0| } 52| 0| int count = 1; 53| 0| for (int i = start_dim; i < shape.size(); i++) { 54| 0| count *= shape[i]; 55| 0| } 56| 0| new_shape.push_back(count); 57| 0| x.Reshape(new_shape); 58| 0| } 59| | 60| | static MTensor concatenate(std::vector &tensors) 61| 0| { 62| 0| int n_examples = tensors[0]->size(0); 63| 0| int count = 0; 64| 0| for (int i = 0; i < tensors.size(); i++) { 65| 0| count += tensors[i]->size(1); 66| 0| } 67| 0| MTensor y({n_examples, count}); 68| 0| float *y_data = y.mutable_data(); 69| 0| for (int i = 0; i < tensors.size(); i++) { 70| 0| int this_count = (int)tensors[i]->size(1); 71| 0| const float *this_data = tensors[i]->data(); 72| 0| for (int n = 0; n < n_examples; n++) { 73| 0| memcpy(y_data + n * count, this_data + n * this_count, this_count * sizeof(float)); 74| 0| } 75| 0| y_data += this_count; 76| 0| } 77| 0| return y; 78| 0| } 79| | 80| | static void softmax(MTensor &x) 81| 0| { 82| 0| int n_examples = x.size(0); 83| 0| int n_channel = x.size(1); 84| 0| float *x_data = x.mutable_data(); 85| 0| float max; 86| 0| float sum; 87| 0| for (int n = 0; n < n_examples; n++) { 88| 0| vDSP_maxv(x_data, 1, &max, n_channel); 89| 0| max = -max; 90| 0| vDSP_vsadd(x_data, 1, &max, x_data, 1, n_channel); 91| 0| vvexpf(x_data, x_data, &n_channel); 92| 0| vDSP_sve(x_data, 1, &sum, n_channel); 93| 0| vDSP_vsdiv(x_data, 1, &sum, x_data, 1, n_channel); 94| 0| x_data += n_channel; 95| 0| } 96| 0| } 97| | 98| | static std::vector vectorize(const char *texts, const int seq_length) 99| 0| { 100| 0| int str_len = (int)strlen(texts); 101| 0| std::vector vec(seq_length, 0); 102| 0| for (int i = 0; i < seq_length; i++) { 103| 0| if (i < str_len) { 104| 0| vec[i] = static_cast(texts[i]); 105| 0| } 106| 0| } 107| 0| return vec; 108| 0| } 109| | 110| | static MTensor embedding(const char *texts, const int seq_length, const MTensor &w) 111| 0| { 112| | // TODO: T65152708 support batch prediction 113| 0| const std::vector &vec = vectorize(texts, seq_length); 114| 0| int n_examples = 1; 115| 0| int embedding_size = w.size(1); 116| 0| MTensor y({n_examples, seq_length, embedding_size}); 117| 0| const float *w_data = w.data(); 118| 0| float *y_data = y.mutable_data(); 119| 0| for (int i = 0; i < n_examples; i++) { 120| 0| for (int j = 0; j < seq_length; j++) { 121| 0| memcpy(y_data, w_data + vec[i * seq_length + j] * embedding_size, (size_t)(embedding_size * sizeof(float))); 122| 0| y_data += embedding_size; 123| 0| } 124| 0| } 125| 0| return y; 126| 0| } 127| | 128| | /* 129| | x shape: n_examples, in_vector_size 130| | w shape: in_vector_size, out_vector_size 131| | b shape: out_vector_size 132| | return shape: n_examples, out_vector_size 133| | */ 134| | static MTensor dense(const MTensor &x, const MTensor &w, const MTensor &b) 135| 0| { 136| 0| int n_examples = x.size(0); 137| 0| int in_vector_size = x.size(1); 138| 0| int out_vector_size = w.size(1); 139| 0| MTensor y({n_examples, out_vector_size}); 140| 0| float *y_data = y.mutable_data(); 141| 0| const float *b_data = b.data(); 142| 0| vDSP_mmul(x.data(), 1, w.data(), 1, y_data, 1, n_examples, out_vector_size, in_vector_size); 143| 0| for (int i = 0; i < out_vector_size; i++) { 144| 0| vDSP_vsadd(y_data + i, out_vector_size, b_data + i, y_data + i, out_vector_size, n_examples); 145| 0| } 146| 0| return y; 147| 0| } 148| | 149| | /* 150| | x shape: n_examples, seq_len, input_size 151| | w shape: kernel_size, input_size, output_size 152| | return shape: n_examples, seq_len - kernel_size + 1, output_size 153| | */ 154| | static MTensor conv1D(const MTensor &x, const MTensor &w) 155| 0| { 156| 0| int n_examples = x.size(0); 157| 0| int seq_len = x.size(1); 158| 0| int input_size = x.size(2); 159| 0| int kernel_size = w.size(0); 160| 0| int output_size = w.size(2); 161| 0| MTensor y({n_examples, seq_len - kernel_size + 1, output_size}); 162| 0| MTensor temp_x({kernel_size, input_size}); 163| 0| MTensor temp_w({kernel_size, input_size}); 164| 0| const float *x_data = x.data(); 165| 0| const float *w_data = w.data(); 166| 0| float *y_data = y.mutable_data(); 167| 0| float *temp_x_data = temp_x.mutable_data(); 168| 0| float *temp_w_data = temp_w.mutable_data(); 169| 0| float sum; 170| 0| for (int n = 0; n < n_examples; n++) { 171| 0| for (int o = 0; o < output_size; o++) { 172| 0| for (int i = 0; i < seq_len - kernel_size + 1; i++) { 173| 0| for (int m = 0; m < kernel_size; m++) { 174| 0| for (int k = 0; k < input_size; k++) { 175| 0| temp_x_data[m * input_size + k] = x_data[n * (seq_len * input_size) + (m + i) * input_size + k]; 176| 0| temp_w_data[m * input_size + k] = w_data[(m * input_size + k) * output_size + o]; 177| 0| } 178| 0| } 179| 0| vDSP_dotpr(temp_x_data, 1, temp_w_data, 1, &sum, (size_t)(kernel_size * input_size)); 180| 0| y_data[(n * (output_size * (seq_len - kernel_size + 1)) + i * output_size + o)] = sum; 181| 0| } 182| 0| } 183| 0| } 184| 0| return y; 185| 0| } 186| | 187| | /* 188| | input shape: n_examples, len, n_channel 189| | return shape: n_examples, len - pool_size + 1, n_channel 190| | */ 191| | static MTensor maxPool1D(const MTensor &x, const int pool_size) 192| 0| { 193| 0| int n_examples = x.size(0); 194| 0| int input_len = x.size(1); 195| 0| int n_channel = x.size(2); 196| 0| int output_len = input_len - pool_size + 1; 197| 0| MTensor y({n_examples, output_len, n_channel}); 198| 0| const float *x_data = x.data(); 199| 0| float *y_data = y.mutable_data(); 200| 0| for (int n = 0; n < n_examples; n++) { 201| 0| for (int c = 0; c < n_channel; c++) { 202| 0| for (int i = 0; i < output_len; i++) { 203| 0| float this_max = -FLT_MAX; 204| 0| for (int r = i; r < i + pool_size; r++) { 205| 0| this_max = fmax(this_max, x_data[n * (n_channel * input_len) + r * n_channel + c]); 206| 0| } 207| 0| y_data[n * (n_channel * output_len) + i * n_channel + c] = this_max; 208| 0| } 209| 0| } 210| 0| } 211| 0| return y; 212| 0| } 213| | 214| | /* 215| | input shape: m, n 216| | return shape: n, m 217| | */ 218| | static MTensor transpose2D(const MTensor &x) 219| 0| { 220| 0| int m = x.size(0); 221| 0| int n = x.size(1); 222| 0| MTensor y({n, m}); 223| 0| float *y_data = y.mutable_data(); 224| 0| const float *x_data = x.data(); 225| 0| for (int i = 0; i < m; i++) { 226| 0| for (int j = 0; j < n; j++) { 227| 0| y_data[j * m + i] = x_data[i * n + j]; 228| 0| } 229| 0| } 230| 0| return y; 231| 0| } 232| | 233| | /* 234| | input shape: m, n, p 235| | return shape: p, n, m 236| | */ 237| | static MTensor transpose3D(const MTensor &x) 238| 0| { 239| 0| int m = x.size(0); 240| 0| int n = x.size(1); 241| 0| int p = x.size(2); 242| 0| MTensor y({p, n, m}); 243| 0| float *y_data = y.mutable_data(); 244| 0| const float *x_data = x.data(); 245| 0| for (int i = 0; i < m; i++) { 246| 0| for (int j = 0; j < n; j++) { 247| 0| for (int k = 0; k < p; k++) { 248| 0| y_data[k * m * n + j * m + i] = x_data[i * n * p + j * p + k]; 249| 0| } 250| 0| } 251| 0| } 252| 0| return y; 253| 0| } 254| | 255| | static void addmv(MTensor &y, const MTensor &x) 256| 0| { 257| 0| int m = y.size(0); 258| 0| int n = y.size(1); 259| 0| int p = y.size(2); 260| 0| float *y_data = y.mutable_data(); 261| 0| const float *x_data = x.data(); 262| 0| for (int i = 0; i < p; i++) { 263| 0| vDSP_vsadd(y_data + i, p, x_data + i, y_data + i, p, m * n); 264| 0| } 265| 0| } 266| | 267| | static MTensor getDenseTensor(const float *df) 268| 0| { 269| 0| MTensor dense_tensor({1, DENSE_FEATURE_LEN}); 270| 0| if (df) { 271| 0| memcpy(dense_tensor.mutable_data(), df, DENSE_FEATURE_LEN * sizeof(float)); 272| 0| } else { 273| 0| memset(dense_tensor.mutable_data(), 0, DENSE_FEATURE_LEN * sizeof(float)); 274| 0| } 275| 0| return dense_tensor; 276| 0| } 277| | 278| | static MTensor predictOnMTML(const std::string task, const char *texts, const std::unordered_map &weights, const float *df) 279| 0| { 280| 0| MTensor dense_tensor = getDenseTensor(df); 281| 0| std::string final_layer_weight_key = task + ".weight"; 282| 0| std::string final_layer_bias_key = task + ".bias"; 283| | 284| 0| const MTensor &embed_t = weights.at("embed.weight"); 285| 0| const MTensor &conv0w_t = weights.at("convs.0.weight"); 286| 0| const MTensor &conv1w_t = weights.at("convs.1.weight"); 287| 0| const MTensor &conv2w_t = weights.at("convs.2.weight"); 288| 0| const MTensor &conv0b_t = weights.at("convs.0.bias"); 289| 0| const MTensor &conv1b_t = weights.at("convs.1.bias"); 290| 0| const MTensor &conv2b_t = weights.at("convs.2.bias"); 291| 0| const MTensor &fc1w_t = weights.at("fc1.weight"); // (128, 190) 292| 0| const MTensor &fc1b_t = weights.at("fc1.bias"); // 128 293| 0| const MTensor &fc2w_t = weights.at("fc2.weight"); // (64, 128) 294| 0| const MTensor &fc2b_t = weights.at("fc2.bias"); // 64 295| 0| const MTensor &final_layer_weight_t = weights.at(final_layer_weight_key); // (2, 64) or (5, 64) 296| 0| const MTensor &final_layer_bias_t = weights.at(final_layer_bias_key); // 2 or 5 297| | 298| 0| const MTensor &convs_0_weight = transpose3D(conv0w_t); 299| 0| const MTensor &convs_1_weight = transpose3D(conv1w_t); 300| 0| const MTensor &convs_2_weight = transpose3D(conv2w_t); 301| 0| const MTensor &fc1_weight = transpose2D(fc1w_t); 302| 0| const MTensor &fc2_weight = transpose2D(fc2w_t); 303| 0| const MTensor &final_layer_weight = transpose2D(final_layer_weight_t); 304| | 305| | // embedding 306| 0| const MTensor &embed_x = embedding(texts, SEQ_LEN, embed_t); 307| | 308| | // conv0 309| 0| MTensor c0 = conv1D(embed_x, convs_0_weight); // (1, 126, 32) 310| 0| addmv(c0, conv0b_t); 311| 0| relu(c0); 312| | 313| | // conv1 314| 0| MTensor c1 = conv1D(c0, convs_1_weight); // (1, 124, 64) 315| 0| addmv(c1, conv1b_t); 316| 0| relu(c1); 317| 0| c1 = maxPool1D(c1, 2); // (1, 123, 64) 318| | 319| | // conv2 320| 0| MTensor c2 = conv1D(c1, convs_2_weight); // (1, 121, 64) 321| 0| addmv(c2, conv2b_t); 322| 0| relu(c2); 323| | 324| | // max pooling 325| 0| MTensor ca = maxPool1D(c0, c0.size(1)); 326| 0| MTensor cb = maxPool1D(c1, c1.size(1)); 327| 0| MTensor cc = maxPool1D(c2, c2.size(1)); 328| | 329| | // concatenate 330| 0| flatten(ca, 1); 331| 0| flatten(cb, 1); 332| 0| flatten(cc, 1); 333| 0| std::vector concat_tensors { &ca, &cb, &cc, &dense_tensor }; 334| 0| const MTensor &concat = concatenate(concat_tensors); 335| | 336| | // dense + relu 337| 0| MTensor dense1_x = dense(concat, fc1_weight, fc1b_t); 338| 0| relu(dense1_x); 339| 0| MTensor dense2_x = dense(dense1_x, fc2_weight, fc2b_t); 340| 0| relu(dense2_x); 341| 0| MTensor final_layer_dense_x = dense(dense2_x, final_layer_weight, final_layer_bias_t); 342| 0| softmax(final_layer_dense_x); 343| 0| return final_layer_dense_x; 344| 0| } 345| |} 346| | 347| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/ML/FBSDKModelUtility.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKModelUtility.h" 24| | 25| | #import 26| | 27| |@implementation FBSDKModelUtility : NSObject 28| | 29| |+ (NSString *)normalizedText:(NSString *)text 30| 0|{ 31| 0| NSMutableArray *tokens = [[text componentsSeparatedByCharactersInSet:[NSCharacterSet whitespaceAndNewlineCharacterSet]] mutableCopy]; 32| 0| [tokens removeObject:@""]; 33| 0| return [tokens componentsJoinedByString:@" "]; 34| 0|} 35| | 36| |@end 37| | 38| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/ML/FBSDKTensor.hpp: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #include 24| | #include 25| | #include 26| | #include 27| | #include 28| | #include 29| | #include 30| | 31| | #include 32| | #include 33| | 34| | #import 35| | 36| |// minimal aten implementation 37| | #define MAT_ALWAYS_INLINE inline __attribute__((always_inline)) 38| |namespace fbsdk { 39| | static void *MAllocateMemory(size_t nbytes) 40| 0| { 41| 0| void *ptr = nullptr; 42| 0| assert(nbytes > 0); 43| | #ifdef __ANDROID__ 44| | ptr = memalign(64, nbytes); 45| | #else 46| 0| const int ret = posix_memalign(&ptr, 64, nbytes); 47| 0| (void)ret; 48| 0| assert(ret == 0); 49| 0| #endif 50| 0| return ptr; 51| 0| } ------------------ | Unexecuted instantiation: FBSDKModelManager.mm:_ZN5fbsdkL15MAllocateMemoryEm ------------------ | Unexecuted instantiation: FBSDKModelParser.mm:_ZN5fbsdkL15MAllocateMemoryEm ------------------ 52| | 53| | static void MFreeMemory(void *ptr) 54| 0| { 55| 0| if (ptr) { 56| 0| free(ptr); 57| 0| } 58| 0| } ------------------ | Unexecuted instantiation: FBSDKModelManager.mm:_ZN5fbsdkL11MFreeMemoryEPv ------------------ | Unexecuted instantiation: FBSDKModelParser.mm:_ZN5fbsdkL11MFreeMemoryEPv ------------------ 59| | 60| | class MTensor { 61| | public: 62| | MTensor() : 63| | storage_(nullptr), 64| | sizes_(), 65| | strides_(), 66| 0| capacity_(0) {}; 67| | explicit MTensor(const std::vector &sizes) 68| 0| { 69| 0| std::vector strides = std::vector(sizes.size()); 70| 0| strides[strides.size() - 1] = 1; 71| 0| for (int i = static_cast(strides.size()) - 2; i >= 0; --i) { 72| 0| strides[i] = strides[i + 1] * sizes[i + 1]; 73| 0| } 74| 0| strides_ = strides; 75| 0| sizes_ = sizes; 76| 0| capacity_ = 1; 77| 0| for (int size : sizes) { 78| 0| capacity_ *= size; 79| 0| } 80| 0| storage_ = std::shared_ptr(MAllocateMemory((size_t)capacity_ * sizeof(float)), MFreeMemory); 81| 0| } 82| | 83| | MAT_ALWAYS_INLINE int count() const 84| 0| { 85| 0| return capacity_; 86| 0| } 87| | 88| | MAT_ALWAYS_INLINE int size(int dim) const 89| 0| { 90| 0| return sizes_[dim]; 91| 0| } 92| | 93| | MAT_ALWAYS_INLINE const std::vector &sizes() const 94| 0| { 95| 0| return sizes_; 96| 0| } 97| | 98| | MAT_ALWAYS_INLINE const std::vector &strides() const 99| 0| { 100| 0| return strides_; 101| 0| } 102| | 103| | MAT_ALWAYS_INLINE const float *data() const 104| 0| { 105| 0| return (const float *)(storage_.get()); 106| 0| } 107| | 108| | MAT_ALWAYS_INLINE float *mutable_data() 109| 0| { 110| 0| return static_cast(storage_.get()); 111| 0| } 112| | 113| | MAT_ALWAYS_INLINE void Reshape(const std::vector &sizes) 114| 0| { 115| 0| int count = 1; 116| 0| for (int i = 0; i < sizes.size(); i++) { 117| 0| count *= sizes[i]; 118| 0| } 119| 0| if (count > capacity_) { 120| 0| capacity_ = count; 121| 0| storage_.reset(MAllocateMemory((size_t)capacity_ * sizeof(float)), MFreeMemory); 122| 0| } 123| 0| sizes_ = sizes; 124| 0| } 125| | 126| | private: 127| | int capacity_; 128| | std::vector sizes_; 129| | std::vector strides_; 130| | std::shared_ptr storage_; 131| | }; 132| |} 133| | 134| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/SKAdNetwork/FBSDKSKAdNetworkConversionConfiguration.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKSKAdNetworkConversionConfiguration.h" 24| | 25| | #import "FBSDKCoreKitBasicsImport.h" 26| | 27| |@implementation FBSDKSKAdNetworkConversionConfiguration 28| | 29| |- (nullable instancetype)initWithJSON:(nullable NSDictionary *)dict 30| 0|{ 31| 0| if ((self = [super init])) { 32| 0| @try { 33| 0| dict = [FBSDKTypeUtility dictionaryValue:dict]; 34| 0| if (!dict) { 35| 0| return nil; 36| 0| } 37| 0| NSArray *data = [FBSDKTypeUtility dictionary:dict objectForKey:@"data" ofType:NSArray.class]; 38| 0| NSDictionary *conversionRules = [FBSDKTypeUtility dictionaryValue:[FBSDKTypeUtility array:data objectAtIndex:0]]; 39| 0| if (!conversionRules) { 40| 0| return nil; 41| 0| } 42| 0| _timerBuckets = [FBSDKTypeUtility integerValue:conversionRules[@"timer_buckets"]]; 43| 0| _timerInterval = (NSTimeInterval)[FBSDKTypeUtility integerValue:conversionRules[@"timer_interval"]]; 44| 0| _cutoffTime = [FBSDKTypeUtility integerValue:conversionRules[@"cutoff_time"]]; 45| 0| _defaultCurrency = [[FBSDKTypeUtility coercedToStringValue:conversionRules[@"default_currency"]] uppercaseString]; 46| 0| _conversionValueRules = [FBSDKSKAdNetworkConversionConfiguration parseRules:conversionRules[@"conversion_value_rules"]]; 47| 0| if (!_conversionValueRules || !_defaultCurrency) { 48| 0| return nil; 49| 0| } 50| 0| _eventSet = [FBSDKSKAdNetworkConversionConfiguration getEventSetFromRules:_conversionValueRules]; 51| 0| _currencySet = [FBSDKSKAdNetworkConversionConfiguration getCurrencySetFromRules:_conversionValueRules]; 52| 0| } @catch (NSException *exception) { 53| 0| return nil; 54| 0| } 55| 0| } 56| 0| return self; 57| 0|} 58| | 59| |+ (NSSet *)getEventSetFromRules:(NSArray *)rules 60| 0|{ 61| 0| NSMutableSet *eventSet = [NSMutableSet new]; 62| 0| for (FBSDKSKAdNetworkRule *rule in rules) { 63| 0| if (!rule) { 64| 0| continue; 65| 0| } 66| 0| for (FBSDKSKAdNetworkEvent *event in rule.events) { 67| 0| if (event.eventName) { 68| 0| [eventSet addObject:event.eventName]; 69| 0| } 70| 0| } 71| 0| } 72| 0| return [eventSet copy]; 73| 0|} 74| | 75| |+ (NSSet *)getCurrencySetFromRules:(NSArray *)rules 76| 0|{ 77| 0| NSMutableSet *currencySet = [NSMutableSet new]; 78| 0| for (FBSDKSKAdNetworkRule *rule in rules) { 79| 0| if (!rule) { 80| 0| continue; 81| 0| } 82| 0| for (FBSDKSKAdNetworkEvent *event in rule.events) { 83| 0| for (NSString *currency in event.values) { 84| 0| [currencySet addObject:[currency uppercaseString]]; 85| 0| } 86| 0| } 87| 0| } 88| 0| return [currencySet copy]; 89| 0|} 90| | 91| |+ (nullable NSArray *)parseRules:(nullable NSArray *)rules 92| 0|{ 93| 0| rules = [FBSDKTypeUtility arrayValue:rules]; 94| 0| if (!rules) { 95| 0| return nil; 96| 0| } 97| 0| NSMutableArray *parsedRules = [NSMutableArray new]; 98| 0| for (id ruleEntry in rules) { 99| 0| FBSDKSKAdNetworkRule *rule = [[FBSDKSKAdNetworkRule alloc] initWithJSON:ruleEntry]; 100| 0| [FBSDKTypeUtility array:parsedRules addObject:rule]; 101| 0| } 102| 0| [parsedRules sortUsingComparator:^NSComparisonResult (FBSDKSKAdNetworkRule *obj1, FBSDKSKAdNetworkRule *obj2) { 103| 0| if (obj1.conversionValue < obj2.conversionValue) { 104| 0| return NSOrderedDescending; 105| 0| } 106| 0| if (obj1.conversionValue < obj2.conversionValue) { 107| 0| return NSOrderedAscending; 108| 0| } 109| 0| return NSOrderedSame; 110| 0| }]; 111| 0| return [parsedRules copy]; 112| 0|} 113| | 114| |@end 115| | 116| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/SKAdNetwork/FBSDKSKAdNetworkEvent.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKSKAdNetworkEvent.h" 24| | 25| | #import 26| | 27| | #import "FBSDKCoreKitBasicsImport.h" 28| | #import "FBSDKUtility.h" 29| | 30| |@implementation FBSDKSKAdNetworkEvent 31| | 32| |- (nullable instancetype)initWithJSON:(NSDictionary *)dict 33| 0|{ 34| 0| if ((self = [super init])) { 35| 0| dict = [FBSDKTypeUtility dictionaryValue:dict]; 36| 0| if (!dict) { 37| 0| return nil; 38| 0| } 39| 0| _eventName = [FBSDKTypeUtility dictionary:dict objectForKey:@"event_name" ofType:NSString.class]; 40| | // Event name is a required field 41| 0| if (!_eventName) { 42| 0| return nil; 43| 0| } 44| | // Values is an optional field 45| 0| NSArray *> *valueEntries = [FBSDKTypeUtility dictionary:dict objectForKey:@"values" ofType:NSArray.class]; 46| 0| if (valueEntries) { 47| 0| NSMutableDictionary *valueDict = [NSMutableDictionary new]; 48| 0| for (NSDictionary *valueEntry in valueEntries) { 49| 0| NSDictionary *value = [FBSDKTypeUtility dictionaryValue:valueEntry]; 50| 0| NSString *currency = [FBSDKTypeUtility dictionary:value objectForKey:@"currency" ofType:NSString.class]; 51| 0| NSNumber *amount = [FBSDKTypeUtility dictionary:value objectForKey:@"amount" ofType:NSNumber.class]; 52| 0| if (!currency || amount == nil) { 53| 0| return nil; 54| 0| } 55| 0| [FBSDKTypeUtility dictionary:valueDict setObject:amount forKey:[currency uppercaseString]]; 56| 0| } 57| 0| _values = [valueDict copy]; 58| 0| } 59| 0| } 60| 0| return self; 61| 0|} 62| | 63| |@end 64| | 65| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/SKAdNetwork/FBSDKSKAdNetworkReporter.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKSKAdNetworkReporter.h" 24| | 25| | #import 26| | 27| | #import 28| | 29| | #import "FBSDKAppEventsUtility.h" 30| | #import "FBSDKConversionValueUpdating.h" 31| | #import "FBSDKCoreKitBasicsImport.h" 32| | #import "FBSDKDataPersisting.h" 33| | #import "FBSDKGraphRequestProtocol.h" 34| | #import "FBSDKGraphRequestProviding.h" 35| | #import "FBSDKSKAdNetworkConversionConfiguration.h" 36| | #import "FBSDKSettings.h" 37| | 38| 0| #define FBSDK_SKADNETWORK_CONFIG_TIME_OUT 86400 39| | 40| |typedef void (*send_type)(Class, SEL, NSInteger); 41| | 42| |typedef void (^FBSDKSKAdNetworkReporterBlock)(void); 43| | 44| |static NSString *const FBSDKSKAdNetworkConversionConfigurationKey = @"com.facebook.sdk:FBSDKSKAdNetworkConversionConfiguration"; 45| |static NSString *const FBSDKSKAdNetworkReporterKey = @"com.facebook.sdk:FBSDKSKAdNetworkReporter"; 46| | 47| |static BOOL g_isSKAdNetworkReportEnabled = NO; 48| |static NSMutableArray *g_completionBlocks; 49| |static BOOL g_isRequestStarted = NO; 50| |static dispatch_queue_t serialQueue; 51| |static FBSDKSKAdNetworkConversionConfiguration *config; 52| |static NSDate *g_configRefreshTimestamp; 53| |static NSInteger g_conversionValue = 0; 54| |static NSDate *g_timestamp = nil; 55| |static NSMutableSet *g_recordedEvents; 56| |static NSMutableDictionary *g_recordedValues; 57| |static id _requestProvider; 58| |static id _store; 59| |static Class _conversionValueUpdatable; 60| | 61| |@implementation FBSDKSKAdNetworkReporter 62| | 63| |+ (void)configureWithRequestProvider:(id)requestProvider 64| | store:(id)store 65| | conversionValueUpdatable:(Class)conversionValueUpdatable 66| 0|{ 67| 0| if (self == [FBSDKSKAdNetworkReporter class]) { 68| 0| _requestProvider = requestProvider; 69| 0| _store = store; 70| 0| _conversionValueUpdatable = conversionValueUpdatable; 71| 0| } 72| 0|} 73| | 74| |+ (id)requestProvider 75| 0|{ 76| 0| return _requestProvider; 77| 0|} 78| | 79| |+ (id)store 80| 0|{ 81| 0| return _store; 82| 0|} 83| | 84| |+ (Class)conversionValueUpdatable 85| 0|{ 86| 0| return _conversionValueUpdatable; 87| 0|} 88| | 89| |+ (void)enable 90| 0|{ 91| 0| if (@available(iOS 14.0, *)) { 92| 0| static dispatch_once_t onceToken; 93| 0| dispatch_once(&onceToken, ^{ 94| 0| [SKAdNetwork registerAppForAdNetworkAttribution]; 95| 0| [self _loadReportData]; 96| 0| g_completionBlocks = [NSMutableArray new]; 97| 0| serialQueue = dispatch_queue_create("com.facebook.appevents.SKAdNetwork.FBSDKSKAdNetworkReporter", DISPATCH_QUEUE_SERIAL); 98| 0| [self _loadConfigurationWithBlock:^{ 99| 0| [self _checkAndUpdateConversionValue]; 100| 0| [self _checkAndRevokeTimer]; 101| 0| }]; 102| 0| g_isSKAdNetworkReportEnabled = YES; 103| 0| }); 104| 0| } 105| 0|} 106| | 107| |+ (void)checkAndRevokeTimer 108| 0|{ 109| 0| if (@available(iOS 14.0, *)) { 110| 0| if (!g_isSKAdNetworkReportEnabled) { 111| 0| return; 112| 0| } 113| 0| [self _loadConfigurationWithBlock:^() { 114| 0| [self _checkAndRevokeTimer]; 115| 0| }]; 116| 0| } 117| 0|} 118| | 119| |+ (void)recordAndUpdateEvent:(NSString *)event 120| | currency:(nullable NSString *)currency 121| | value:(nullable NSNumber *)value 122| 0|{ 123| 0| if (@available(iOS 14.0, *)) { 124| 0| if (!g_isSKAdNetworkReportEnabled) { 125| 0| return; 126| 0| } 127| 0| if (!event.length) { 128| 0| return; 129| 0| } 130| 0| [self _loadConfigurationWithBlock:^() { 131| 0| [self _recordAndUpdateEvent:event currency:currency value:value]; 132| 0| }]; 133| 0| } 134| 0|} 135| | 136| |+ (void)_loadConfigurationWithBlock:(FBSDKSKAdNetworkReporterBlock)block 137| 0|{ 138| 0| if (!serialQueue) { 139| 0| return; 140| 0| } 141| | // Executes block if there is cache 142| 0| if ([self _isConfigRefreshTimestampValid] && [self.store objectForKey:FBSDKSKAdNetworkConversionConfigurationKey]) { 143| 0| dispatch_async(serialQueue, ^() { 144| 0| [FBSDKTypeUtility array:g_completionBlocks addObject:block]; 145| 0| for (FBSDKSKAdNetworkReporterBlock executionBlock in g_completionBlocks) { 146| 0| executionBlock(); 147| 0| } 148| 0| [g_completionBlocks removeAllObjects]; 149| 0| }); 150| 0| return; 151| 0| } 152| 0| dispatch_async(serialQueue, ^{ 153| 0| [FBSDKTypeUtility array:g_completionBlocks addObject:block]; 154| 0| if (g_isRequestStarted) { 155| 0| return; 156| 0| } 157| 0| g_isRequestStarted = YES; 158| 0| id request = [self.requestProvider createGraphRequestWithGraphPath:[NSString stringWithFormat:@"%@/ios_skadnetwork_conversion_config", [FBSDKSettings appID]]]; 159| 0| [request startWithCompletion:^(id connection, id result, NSError *error) { 160| 0| dispatch_async(serialQueue, ^{ 161| 0| if (error) { 162| 0| g_isRequestStarted = NO; 163| 0| return; 164| 0| } 165| 0| NSDictionary *json = [FBSDKTypeUtility dictionaryValue:result]; 166| 0| if (json) { 167| 0| [self.store setObject:json forKey:FBSDKSKAdNetworkConversionConfigurationKey]; 168| 0| g_configRefreshTimestamp = [NSDate date]; 169| 0| config = [[FBSDKSKAdNetworkConversionConfiguration alloc] initWithJSON:json]; 170| 0| for (FBSDKSKAdNetworkReporterBlock executionBlock in g_completionBlocks) { 171| 0| executionBlock(); 172| 0| } 173| 0| [g_completionBlocks removeAllObjects]; 174| 0| g_isRequestStarted = NO; 175| 0| } 176| 0| }); 177| 0| }]; 178| 0| }); 179| 0|} 180| | 181| |+ (void)_checkAndRevokeTimer 182| 0|{ 183| 0| if (!config) { 184| 0| return; 185| 0| } 186| 0| if ([self _shouldCutoff]) { 187| 0| return; 188| 0| } 189| 0| if (g_conversionValue > config.timerBuckets) { 190| 0| return; 191| 0| } 192| 0| if (g_timestamp && [[NSDate date] timeIntervalSinceDate:g_timestamp] < config.timerInterval) { 193| 0| return; 194| 0| } 195| 0| [FBSDKSKAdNetworkReporter _updateConversionValue:g_conversionValue]; 196| 0|} 197| | 198| |+ (void)_recordAndUpdateEvent:(NSString *)event 199| | currency:(nullable NSString *)currency 200| | value:(nullable NSNumber *)value 201| 0|{ 202| 0| if (!config) { 203| 0| return; 204| 0| } 205| 0| if ([self _shouldCutoff]) { 206| 0| return; 207| 0| } 208| 0| if (![config.eventSet containsObject:event] && ![FBSDKAppEventsUtility isStandardEvent:event]) { 209| 0| return; 210| 0| } 211| 0| BOOL isCacheUpdated = false; 212| 0| if (![g_recordedEvents containsObject:event]) { 213| 0| [g_recordedEvents addObject:event]; 214| 0| isCacheUpdated = true; 215| 0| } 216| | // Change currency to default currency if currency is not found in currencySet 217| 0| NSString *valueCurrency = [currency uppercaseString]; 218| 0| if (![config.currencySet containsObject:valueCurrency]) { 219| 0| valueCurrency = config.defaultCurrency; 220| 0| } 221| 0| if (value != nil) { 222| 0| NSMutableDictionary *mapping = [[FBSDKTypeUtility dictionary:g_recordedValues objectForKey:event ofType:NSDictionary.class] mutableCopy] ?: [NSMutableDictionary new]; 223| 0| NSNumber *valueInMapping = [FBSDKTypeUtility dictionary:mapping objectForKey:valueCurrency ofType:NSNumber.class] ?: [NSNumber numberWithDouble:0]; 224| 0| [FBSDKTypeUtility dictionary:mapping setObject:[NSNumber numberWithDouble:(valueInMapping.doubleValue + value.doubleValue)] forKey:valueCurrency]; 225| 0| [FBSDKTypeUtility dictionary:g_recordedValues setObject:mapping forKey:event]; 226| 0| isCacheUpdated = true; 227| 0| } 228| 0| if (isCacheUpdated) { 229| 0| [self _checkAndUpdateConversionValue]; 230| 0| [self _saveReportData]; 231| 0| } 232| 0|} 233| | 234| |+ (void)_checkAndUpdateConversionValue 235| 0|{ 236| | // Update conversion value if a rule is matched 237| 0| for (FBSDKSKAdNetworkRule *rule in config.conversionValueRules) { 238| 0| if (rule.conversionValue < g_conversionValue) { 239| 0| break; 240| 0| } 241| 0| if ([rule isMatchedWithRecordedEvents:g_recordedEvents recordedValues:g_recordedValues]) { 242| 0| [self _updateConversionValue:rule.conversionValue]; 243| 0| break; 244| 0| } 245| 0| } 246| 0|} 247| | 248| |+ (void)_updateConversionValue:(NSInteger)value 249| 0|{ 250| 0| if (@available(iOS 14.0, *)) { 251| 0| if ([self _shouldCutoff]) { 252| 0| return; 253| 0| } 254| 0| [_conversionValueUpdatable updateConversionValue:value]; 255| 0| g_conversionValue = value + 1; 256| 0| g_timestamp = [NSDate date]; 257| 0| [self _saveReportData]; 258| 0| } 259| 0|} 260| | 261| |+ (BOOL)_shouldCutoff 262| 0|{ 263| 0| if (!config.cutoffTime) { 264| 0| return true; 265| 0| } 266| 0| NSDate *installTimestamp = [self.store objectForKey:@"com.facebook.sdk:FBSDKSettingsInstallTimestamp"]; 267| 0| return [installTimestamp isKindOfClass:NSDate.class] && [[NSDate date] timeIntervalSinceDate:installTimestamp] > config.cutoffTime * 86400; 268| 0|} 269| | 270| | #pragma clang diagnostic push 271| | #pragma clang diagnostic ignored "-Wdeprecated-declarations" 272| |+ (void)_loadReportData 273| 0|{ 274| 0| id cachedJSON = [self.store objectForKey:FBSDKSKAdNetworkConversionConfigurationKey]; 275| 0| config = [[FBSDKSKAdNetworkConversionConfiguration alloc] initWithJSON:cachedJSON]; 276| 0| NSData *cachedReportData = [self.store objectForKey:FBSDKSKAdNetworkReporterKey]; 277| 0| g_recordedEvents = [NSMutableSet new]; 278| 0| g_recordedValues = [NSMutableDictionary new]; 279| 0| if ([cachedReportData isKindOfClass:[NSData class]]) { 280| 0| NSDictionary *data; 281| 0| if (@available(iOS 11.0, *)) { 282| 0| data = [FBSDKTypeUtility dictionaryValue:[NSKeyedUnarchiver 283| 0| unarchivedObjectOfClasses:[NSSet setWithArray: 284| 0| @[NSString.class, 285| 0| NSNumber.class, 286| 0| NSArray.class, 287| 0| NSDictionary.class, 288| 0| NSSet.class]] 289| 0| fromData:cachedReportData 290| 0| error:nil]]; 291| 0| } else { 292| 0| data = [FBSDKTypeUtility dictionaryValue:[NSKeyedUnarchiver unarchiveObjectWithData:cachedReportData]]; 293| 0| } 294| 0| if (data) { 295| 0| g_conversionValue = [FBSDKTypeUtility integerValue:data[@"conversion_value"]]; 296| 0| g_timestamp = [FBSDKTypeUtility dictionary:data objectForKey:@"timestamp" ofType:NSDate.class]; 297| 0| g_recordedEvents = [[FBSDKTypeUtility dictionary:data objectForKey:@"recorded_events" ofType:NSSet.class] mutableCopy] ?: [NSMutableSet new]; 298| 0| g_recordedValues = [[FBSDKTypeUtility dictionary:data objectForKey:@"recorded_values" ofType:NSDictionary.class] mutableCopy] ?: [NSMutableDictionary new]; 299| 0| } 300| 0| } 301| 0|} 302| | 303| |+ (void)_saveReportData 304| 0|{ 305| 0| NSMutableDictionary *reportData = [NSMutableDictionary new]; 306| 0| [FBSDKTypeUtility dictionary:reportData setObject:@(g_conversionValue) forKey:@"conversion_value"]; 307| 0| [FBSDKTypeUtility dictionary:reportData setObject:g_timestamp forKey:@"timestamp"]; 308| 0| [FBSDKTypeUtility dictionary:reportData setObject:g_recordedEvents forKey:@"recorded_events"]; 309| 0| [FBSDKTypeUtility dictionary:reportData setObject:g_recordedValues forKey:@"recorded_values"]; 310| 0| NSData *cache = [NSKeyedArchiver archivedDataWithRootObject:reportData]; 311| 0| if (cache) { 312| 0| [self.store setObject:cache forKey:FBSDKSKAdNetworkReporterKey]; 313| 0| } 314| 0|} 315| | 316| | #pragma clang diagnostic pop 317| | 318| |+ (BOOL)_isConfigRefreshTimestampValid 319| 0|{ 320| 0| return g_configRefreshTimestamp && [[NSDate date] timeIntervalSinceDate:g_configRefreshTimestamp] < FBSDK_SKADNETWORK_CONFIG_TIME_OUT; 321| 0|} 322| | 323| | #pragma mark - Testability 324| | 325| | #if DEBUG 326| | #if FBSDKTEST 327| | 328| |+ (void)reset 329| 0|{ 330| 0| _store = nil; 331| 0| _requestProvider = nil; 332| 0| _conversionValueUpdatable = nil; 333| 0| [self setConfiguration:nil]; 334| 0| [self setSKAdNetworkReportEnabled:false]; 335| 0|} 336| | 337| |+ (void)setConfiguration:(FBSDKSKAdNetworkConversionConfiguration *)configuration 338| 0|{ 339| 0| config = configuration; 340| 0|} 341| | 342| |+ (void)setSKAdNetworkReportEnabled:(BOOL)enabled 343| 0|{ 344| 0| g_isSKAdNetworkReportEnabled = enabled; 345| 0|} 346| | 347| | #endif 348| | #endif 349| |@end 350| | 351| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/SKAdNetwork/FBSDKSKAdNetworkRule.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKSKAdNetworkRule.h" 24| | 25| | #import "FBSDKCoreKitBasicsImport.h" 26| | 27| |@implementation FBSDKSKAdNetworkRule 28| | 29| |- (nullable instancetype)initWithJSON:(NSDictionary *)dict 30| 0|{ 31| 0| if ((self = [super init])) { 32| 0| dict = [FBSDKTypeUtility dictionaryValue:dict]; 33| 0| if (!dict) { 34| 0| return nil; 35| 0| } 36| 0| NSNumber *value = [FBSDKTypeUtility dictionary:dict objectForKey:@"conversion_value" ofType:NSNumber.class]; 37| 0| NSArray *events = [FBSDKSKAdNetworkRule parseEvents:[FBSDKTypeUtility dictionary:dict objectForKey:@"events" ofType:NSArray.class]]; 38| 0| if (value == nil || !events) { 39| 0| return nil; 40| 0| } 41| 0| _conversionValue = value.integerValue; 42| 0| _events = events; 43| 0| } 44| 0| return self; 45| 0|} 46| | 47| |- (BOOL)isMatchedWithRecordedEvents:(NSSet *)recordedEvents 48| | recordedValues:(NSDictionary *)recordedValues 49| 0|{ 50| 0| for (FBSDKSKAdNetworkEvent *event in self.events) { 51| | // Check if event name matches 52| 0| if (![recordedEvents containsObject:event.eventName]) { 53| 0| return NO; 54| 0| } 55| | // Check if event value matches when values is not nil 56| 0| if (event.values) { 57| 0| NSDictionary *recordedEventValues = [FBSDKTypeUtility dictionary:recordedValues objectForKey:event.eventName ofType:NSDictionary.class]; 58| 0| if (!recordedEventValues) { 59| 0| return NO; 60| 0| } 61| 0| for (NSString *currency in event.values) { 62| 0| NSNumber *valueInMapping = [FBSDKTypeUtility dictionary:event.values objectForKey:currency ofType:NSNumber.class]; 63| 0| NSNumber *value = [FBSDKTypeUtility dictionary:recordedEventValues objectForKey:currency ofType:NSNumber.class]; 64| 0| if (value != nil && valueInMapping != nil && value.doubleValue > valueInMapping.doubleValue) { 65| 0| return YES; 66| 0| } 67| 0| } 68| 0| return NO; 69| 0| } 70| 0| } 71| 0| return YES; 72| 0|} 73| | 74| |+ (NSArray *)parseEvents:(nullable NSArray *> *)events 75| 0|{ 76| 0| if (!events) { 77| 0| return nil; 78| 0| } 79| 0| NSMutableArray *parsedEvents = [NSMutableArray new]; 80| 0| for (NSDictionary *eventEntry in events) { 81| 0| FBSDKSKAdNetworkEvent *event = [[FBSDKSKAdNetworkEvent alloc] initWithJSON:eventEntry]; 82| 0| if (!event) { 83| 0| return nil; 84| 0| } 85| 0| [FBSDKTypeUtility array:parsedEvents addObject:event]; 86| 0| } 87| 0| return [parsedEvents copy]; 88| 0|} 89| | 90| |@end 91| | 92| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/SuggestedEvents/FBSDKFeatureExtractor.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKFeatureExtractor.h" 24| | 25| | #import "FBSDKCoreKitBasicsImport.h" 26| | #import "FBSDKModelManager.h" 27| | #import "FBSDKRulesFromKeyProvider.h" 28| | #import "FBSDKViewHierarchy.h" 29| | #import "FBSDKViewHierarchyMacros.h" 30| | 31| 0| #define REGEX_CR_PASSWORD_FIELD @"password" 32| 0| #define REGEX_CR_HAS_CONFIRM_PASSWORD_FIELD @"(?i)(confirm.*password)|(password.*(confirmation|confirm)|confirmation)" 33| 0| #define REGEX_CR_HAS_LOG_IN_KEYWORDS @"(?i)(sign in)|login|signIn" 34| | #define REGEX_CR_HAS_SIGN_ON_KEYWORDS \ 35| 0| @"(?i)(sign.*(up|now)|registration|" \ 36| 0| @"register|(create|apply).*(profile|account)|open.*account|" \ 37| 0| @"account.*(open|creation|application)|enroll|join.*now)" 38| 0| #define REGEX_ADD_TO_CART_BUTTON_TEXT @"(?i)add to(\\s|\\Z)|update(\\s|\\Z)|cart" 39| 0| #define REGEX_ADD_TO_CART_PAGE_TITLE @"(?i)add to(\\s|\\Z)|update(\\s|\\Z)|cart|shop|buy" 40| | 41| |static NSDictionary *_languageInfo; 42| |static NSDictionary *_eventInfo; 43| |static NSDictionary *_textTypeInfo; 44| |static NSDictionary *_rules; 45| | 46| |void sum(float *val0, float *val1); 47| | 48| |@implementation FBSDKFeatureExtractor 49| | 50| |static id _keyProvider; 51| | 52| |+ (void)configureWithRulesFromKeyProvider:(id)keyProvider 53| 0|{ 54| 0| if (self == FBSDKFeatureExtractor.class) { 55| 0| _keyProvider = keyProvider; 56| 0| } 57| 0|} 58| | 59| |+ (void)initialize 60| 0|{ 61| 0| _languageInfo = @{ 62| 0| @"ENGLISH" : @"1", 63| 0| @"GERMAN" : @"2", 64| 0| @"SPANISH" : @"3", 65| 0| @"JAPANESE" : @"4" 66| 0| }; 67| 0| _eventInfo = @{ 68| 0| @"VIEW_CONTENT" : @"0", 69| 0| @"SEARCH" : @"1", 70| 0| @"ADD_TO_CART" : @"2", 71| 0| @"ADD_TO_WISHLIST" : @"3", 72| 0| @"INITIATE_CHECKOUT" : @"4", 73| 0| @"ADD_PAYMENT_INFO" : @"5", 74| 0| @"PURCHASE" : @"6", 75| 0| @"LEAD" : @"7", 76| 0| @"COMPLETE_REGISTRATION" : @"8" 77| 0| }; 78| 0| _textTypeInfo = @{ 79| 0| @"BUTTON_TEXT" : @"1", 80| 0| @"PAGE_TITLE" : @"2", 81| 0| @"RESOLVED_DOCUMENT_LINK" : @"3", 82| 0| @"BUTTON_ID" : @"4" 83| 0| }; 84| 0|} 85| | 86| |+ (void)loadRulesForKey:(NSString *)useCaseKey 87| 0|{ 88| 0| BOOL isValid = [useCaseKey isKindOfClass:NSString.class]; 89| 0| if (isValid) { 90| 0| _rules = [_keyProvider getRulesForKey:useCaseKey]; 91| 0| } 92| 0|} 93| | 94| |+ (NSString *)getTextFeature:(NSString *)text 95| | withScreenName:(NSString *)screenName 96| 0|{ 97| | // use "|" and "," to separate different text based on the rule of how text processed during training 98| 0| NSString *appName = [FBSDKTypeUtility dictionary:[[NSBundle mainBundle] infoDictionary] objectForKey:(NSString *)kCFBundleNameKey ofType:NSObject.class]; 99| 0| return [[NSString stringWithFormat:@"%@ | %@, %@", appName, screenName, text] lowercaseString]; 100| 0|} 101| | 102| |+ (nullable float *)getDenseFeatures:(NSDictionary *)viewHierarchy 103| 0|{ 104| 0| if (!_rules) { 105| 0| return nil; 106| 0| } 107| 0| viewHierarchy = [FBSDKTypeUtility dictionaryValue:viewHierarchy]; 108| | 109| 0| NSMutableArray *> *viewTree = [[FBSDKTypeUtility arrayValue:viewHierarchy[VIEW_HIERARCHY_VIEW_KEY]] mutableCopy]; 110| 0| NSString *screenName = viewHierarchy[VIEW_HIERARCHY_SCREEN_NAME_KEY]; 111| 0| NSMutableArray *> *siblings = [NSMutableArray array]; 112| | 113| 0| [self pruneTree:[[FBSDKTypeUtility array:viewTree objectAtIndex:0] mutableCopy] siblings:siblings]; 114| | 115| 0| float *result = [self parseFeatures:[FBSDKTypeUtility array:viewTree objectAtIndex:0]]; 116| | 117| 0| NSMutableDictionary *interactedNode; 118| 0| for (NSMutableDictionary *node in siblings) { 119| 0| if ([[FBSDKTypeUtility dictionary:node objectForKey:VIEW_HIERARCHY_IS_INTERACTED_KEY ofType:NSObject.class] boolValue]) { 120| 0| interactedNode = node; 121| 0| } 122| 0| } 123| | 124| 0| NSString *viewTreeString; 125| 0| if ([FBSDKTypeUtility isValidJSONObject:viewTree]) { 126| 0| viewTreeString = [[NSString alloc] initWithData:[FBSDKTypeUtility dataWithJSONObject:viewTree options:0 error:nil] encoding:NSUTF8StringEncoding]; 127| 0| } 128| | 129| 0| float *nonparseResult = [self nonparseFeatures:interactedNode siblings:siblings screenname:screenName viewTreeString:viewTreeString]; 130| 0| sum(result, nonparseResult); 131| 0| free(nonparseResult); 132| | 133| 0| return result; 134| 0|} 135| | 136| | #pragma mark - Helper functions 137| |+ (BOOL)pruneTree:(NSMutableDictionary *)node siblings:(NSMutableArray *)siblings 138| 0|{ 139| | // If it's interacted, don't prune away the children and just return. 140| 0| BOOL isInteracted = [[FBSDKTypeUtility dictionary:node 141| 0| objectForKey:VIEW_HIERARCHY_IS_INTERACTED_KEY 142| 0| ofType:NSNumber.class] boolValue]; 143| 0| if (isInteracted) { 144| 0| return true; 145| 0| } 146| | 147| 0| NSMutableArray *> *newChildren = [NSMutableArray array]; 148| | // If a child is interacted, we're at the right level and we want to grab everything 149| 0| BOOL isChildInteracted = NO; 150| 0| BOOL isDescendantInteracted = NO; 151| | 152| 0| NSMutableArray *> *childviews = [FBSDKTypeUtility dictionary:node objectForKey:VIEW_HIERARCHY_CHILD_VIEWS_KEY ofType:NSObject.class]; 153| 0| for (NSMutableDictionary *child in childviews) { 154| 0| if ([[FBSDKTypeUtility dictionary:child 155| 0| objectForKey:VIEW_HIERARCHY_IS_INTERACTED_KEY 156| 0| ofType:NSNumber.class] boolValue]) { 157| 0| isChildInteracted = YES; 158| 0| isDescendantInteracted = YES; 159| 0| } 160| 0| } 161| | 162| 0| if (isChildInteracted) { 163| 0| [siblings addObjectsFromArray:childviews]; 164| 0| } else { 165| 0| for (NSMutableDictionary *c in childviews) { 166| 0| NSMutableDictionary *child = [c mutableCopy]; 167| 0| if ([self pruneTree:child siblings:siblings]) { 168| 0| isDescendantInteracted = YES; 169| 0| [FBSDKTypeUtility array:newChildren addObject:child]; 170| 0| } 171| 0| } 172| 0| [FBSDKTypeUtility dictionary:node setObject:newChildren forKey:VIEW_HIERARCHY_CHILD_VIEWS_KEY]; 173| 0| } 174| | 175| 0| return isDescendantInteracted; 176| 0|} 177| | 178| |+ (float *)nonparseFeatures:(NSMutableDictionary *)node 179| | siblings:(NSMutableArray *)siblings 180| | screenname:(NSString *)screenname 181| | viewTreeString:(NSString *)viewTreeString 182| 0|{ 183| 0| float *densefeat = (float *)calloc(30, sizeof(float)); 184| | 185| 0| densefeat[3] = MAX((float)siblings.count - 1, 0); 186| | 187| 0| densefeat[9] = [siblings filteredArrayUsingPredicate:[NSPredicate predicateWithBlock:^BOOL (id _Nullable evaluatedObject, NSDictionary *_Nullable bindings) { 188| 0| return [self isButton:evaluatedObject]; 189| 0| }]].count; 190| 0| if ([self isButton:node]) { 191| 0| densefeat[9] -= 1; 192| 0| } 193| | 194| 0| densefeat[13] = -1; 195| 0| densefeat[14] = -1; 196| | 197| 0| NSString *pageTitle = screenname ?: @""; 198| 0| NSString *formFieldsJSON = viewTreeString; 199| 0| NSString *buttonID = @""; 200| 0| NSString *buttonText = @""; 201| | 202| 0| if ([self isButton:node]) { 203| 0| NSMutableString *buttonTextString = [NSMutableString string]; 204| 0| NSMutableString *buttonHintString = [NSMutableString string]; 205| 0| [self update:node text:buttonTextString hint:buttonHintString]; 206| 0| buttonText = (NSString *)buttonTextString; 207| 0| buttonID = (NSString *)buttonHintString; 208| 0| } 209| | 210| | // Regex features 211| 0| densefeat[15] = [self regexMatch:@"ENGLISH" event:@"COMPLETE_REGISTRATION" textType:@"BUTTON_TEXT" matchText:buttonText]; 212| 0| densefeat[16] = [self regexMatch:@"ENGLISH" event:@"COMPLETE_REGISTRATION" textType:@"PAGE_TITLE" matchText:pageTitle]; 213| 0| densefeat[17] = [self regexMatch:@"ENGLISH" event:@"COMPLETE_REGISTRATION" textType:@"BUTTON_ID" matchText:buttonID]; 214| | 215| 0| densefeat[18] = [formFieldsJSON containsString:REGEX_CR_PASSWORD_FIELD] ? 1.0 : 0.0; 216| | 217| 0| densefeat[19] = [self regextMatch:REGEX_CR_HAS_CONFIRM_PASSWORD_FIELD text:formFieldsJSON]; 218| 0| densefeat[20] = [self regextMatch:REGEX_CR_HAS_LOG_IN_KEYWORDS text:formFieldsJSON]; 219| 0| densefeat[21] = [self regextMatch:REGEX_CR_HAS_SIGN_ON_KEYWORDS text:formFieldsJSON]; 220| | 221| | // Purchase specific features 222| 0| densefeat[22] = [self regexMatch:@"ENGLISH" event:@"PURCHASE" textType:@"BUTTON_TEXT" matchText:buttonText]; 223| 0| densefeat[24] = [self regexMatch:@"ENGLISH" event:@"PURCHASE" textType:@"PAGE_TITLE" matchText:pageTitle]; 224| | 225| | // AddToCart specific features 226| 0| densefeat[25] = [self regextMatch:REGEX_ADD_TO_CART_BUTTON_TEXT text:buttonText]; 227| 0| densefeat[27] = [self regextMatch:REGEX_ADD_TO_CART_PAGE_TITLE text:pageTitle]; 228| | 229| | // Lead specific features 230| 0| densefeat[28] = [self regexMatch:@"ENGLISH" event:@"LEAD" textType:@"BUTTON_TEXT" matchText:buttonText]; 231| 0| densefeat[29] = [self regexMatch:@"ENGLISH" event:@"LEAD" textType:@"PAGE_TITLE" matchText:pageTitle]; 232| | 233| 0| return densefeat; 234| 0|} 235| | 236| |+ (float *)parseFeatures:(NSMutableDictionary *)node 237| 0|{ 238| 0| float *densefeat = (float *)calloc(30, sizeof(float)); 239| | 240| 0| NSString *validText = [FBSDKTypeUtility coercedToStringValue:node[VIEW_HIERARCHY_TEXT_KEY]]; 241| 0| NSString *validHint = [FBSDKTypeUtility coercedToStringValue:node[VIEW_HIERARCHY_HINT_KEY]]; 242| 0| NSString *validClassName = [FBSDKTypeUtility coercedToStringValue:node[VIEW_HIERARCHY_CLASS_NAME_KEY]]; 243| | 244| 0| NSString *text = [validText lowercaseString] ?: @""; 245| 0| NSString *hint = [validHint lowercaseString] ?: @""; 246| 0| NSString *className = [validClassName lowercaseString] ?: @""; 247| | 248| 0| if ([self foundIndicators:[@"$,amount,price,total" componentsSeparatedByString:@","] 249| 0| inValues:@[text, hint]]) { 250| 0| densefeat[0] += 1.0; 251| 0| } 252| | 253| 0| if ([self foundIndicators:[@"password,pwd" componentsSeparatedByString:@","] 254| 0| inValues:@[text, hint]]) { 255| 0| densefeat[1] += 1.0; 256| 0| } 257| | 258| 0| if ([self foundIndicators:[@"phone,tel" componentsSeparatedByString:@","] 259| 0| inValues:@[text, hint]]) { 260| 0| densefeat[2] += 1.0; 261| 0| } 262| | 263| 0| if ([self foundIndicators:@[@"search"] 264| 0| inValues:@[text, hint]]) { 265| 0| densefeat[4] += 1.0; 266| 0| } 267| | 268| | // Input field with general text 269| 0| if ([className containsString:@"text"] && [className containsString:@"edit"]) { 270| 0| densefeat[5] += 1.0; 271| 0| } 272| | 273| | // Input field with number or phone 274| 0| if (([className containsString:@"num"] || [className containsString:@"phone"]) && [className containsString:@"edit"]) { 275| 0| densefeat[6] += 1.0; 276| 0| } 277| | 278| 0| if ([hint containsString:@"email"] || [text containsString:@"@"]) { 279| 0| densefeat[7] += 1.0; 280| 0| } 281| | 282| | // Check Box 283| 0| if ([className containsString:@"checkbox"]) { 284| 0| densefeat[8] += 1.0; 285| 0| } 286| | 287| 0| if ([self foundIndicators:[@"complete,confirm,done,submit" componentsSeparatedByString:@","] 288| 0| inValues:@[text]]) { 289| 0| densefeat[10] += 1.0; 290| 0| } 291| | 292| 0| densefeat[11] = 0.0; 293| | 294| | // Radio Button 295| 0| if ([className containsString:@"radio"] && [className containsString:@"button"]) { 296| 0| densefeat[12] += 1.0; 297| 0| } 298| | 299| 0| NSMutableArray *> *childviews = node[VIEW_HIERARCHY_CHILD_VIEWS_KEY]; 300| | 301| 0| for (int i = 0; i < childviews.count; i++) { 302| 0| sum(densefeat, [self parseFeatures:[FBSDKTypeUtility array:childviews objectAtIndex:i]]); 303| 0| } 304| | 305| 0| return densefeat; 306| 0|} 307| | 308| |void sum(float *val0, float *val1) 309| 0|{ 310| 0| for (int i = 0; i < 30; i++) { 311| 0| val0[i] += val1[i]; 312| 0| } 313| 0|} 314| | 315| |+ (BOOL)isButton:(NSDictionary *)node 316| 0|{ 317| 0| int classtypebitmask = [[FBSDKTypeUtility dictionary:node 318| 0| objectForKey:VIEW_HIERARCHY_CLASS_TYPE_BITMASK_KEY 319| 0| ofType:NSString.class] intValue]; 320| 0| return (classtypebitmask & FBCodelessClassBitmaskUIButton) > 0; 321| 0|} 322| | 323| |+ (void)update:(NSDictionary *)node 324| | text:(NSMutableString *)buttonTextString 325| | hint:(NSMutableString *)buttonHintString 326| 0|{ 327| 0| NSString *text = [[FBSDKTypeUtility dictionary:node 328| 0| objectForKey:VIEW_HIERARCHY_TEXT_KEY 329| 0| ofType:NSString.class] lowercaseString]; 330| 0| NSString *hint = [[FBSDKTypeUtility dictionary:node 331| 0| objectForKey:VIEW_HIERARCHY_HINT_KEY 332| 0| ofType:NSString.class] lowercaseString]; 333| 0| if (text.length > 0) { 334| 0| [buttonTextString appendFormat:@"%@ ", text]; 335| 0| } 336| 0| if (hint.length > 0) { 337| 0| [buttonHintString appendFormat:@"%@ ", hint]; 338| 0| } 339| | 340| 0| NSMutableArray *> *childviews = node[VIEW_HIERARCHY_CHILD_VIEWS_KEY]; 341| 0| for (NSMutableDictionary *child in childviews) { 342| 0| [self update:child text:buttonTextString hint:buttonHintString]; 343| 0| } 344| 0|} 345| | 346| |+ (BOOL)foundIndicators:(NSArray *)indicators inValues:(NSArray *)values 347| 0|{ 348| 0| for (NSString *indicator in indicators) { 349| 0| for (NSString *value in values) { 350| 0| if ([value containsString:indicator]) { 351| 0| return YES; 352| 0| } 353| 0| } 354| 0| } 355| | 356| 0| return NO; 357| 0|} 358| | 359| |+ (float)regextMatch:(NSString *)pattern text:(NSString *)text 360| 0|{ 361| 0| NSString *validText = [FBSDKTypeUtility coercedToStringValue:text]; 362| 0| if (!validText) { 363| 0| return 0.0; 364| 0| } 365| | 366| 0| NSString *validPattern = [FBSDKTypeUtility coercedToStringValue:pattern]; 367| 0| if (!validPattern) { 368| 0| return 0.0; 369| 0| } 370| | 371| 0| NSRegularExpression *re = [NSRegularExpression regularExpressionWithPattern:pattern options:0 error:nil]; 372| 0| NSRange range = NSMakeRange(0, validText.length); 373| 0| NSArray *matched = [re matchesInString:validText options:0 range:range]; 374| 0| return matched.count > 0 ? 1.0 : 0.0; 375| 0|} 376| | 377| |+ (float)regexMatch:(NSString *)language 378| | event:(NSString *)event 379| | textType:(NSString *)textType 380| | matchText:(NSString *)matchText 381| 0|{ 382| 0| NSString *pattern = _rules[@"rulesForLanguage"][_languageInfo[language]] 383| 0| [@"rulesForEvent"][_eventInfo[event]] 384| 0| [@"positiveRules"][_textTypeInfo[textType]]; 385| 0| return [self regextMatch:pattern text:matchText]; 386| 0|} 387| | 388| | #if DEBUG 389| | #if FBSDKTEST 390| | 391| |+ (id)keyProvider 392| 0|{ 393| 0| return _keyProvider; 394| 0|} 395| | 396| |+ (void)reset 397| 0|{ 398| 0| _keyProvider = nil; 399| 0|} 400| | 401| | #endif 402| | #endif 403| | 404| |@end 405| | 406| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/SuggestedEvents/FBSDKSuggestedEventsIndexer.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKSuggestedEventsIndexer.h" 24| | 25| | #import 26| | 27| | #import 28| | #import 29| | #import 30| | 31| | #import "FBSDKAppEvents.h" 32| | #import "FBSDKAppEvents+EventLogging.h" 33| | #import "FBSDKAppEventsUtility.h" 34| | #import "FBSDKCoreKitBasicsImport.h" 35| | #import "FBSDKEventProcessing.h" 36| | #import "FBSDKFeatureExtracting.h" 37| | #import "FBSDKFeatureExtractor.h" 38| | #import "FBSDKGraphRequestFactory.h" 39| | #import "FBSDKInternalUtility.h" 40| | #import "FBSDKMLMacros.h" 41| | #import "FBSDKModelManager.h" 42| | #import "FBSDKModelUtility.h" 43| | #import "FBSDKServerConfigurationManager+ServerConfigurationProviding.h" 44| | #import "FBSDKSettings+Internal.h" 45| | #import "FBSDKSettings+SettingsProtocols.h" 46| | #import "FBSDKSwizzler+Swizzling.h" 47| | #import "FBSDKSwizzling.h" 48| | #import "FBSDKViewHierarchy.h" 49| | #import "FBSDKViewHierarchyMacros.h" 50| | 51| |NSString *const OptInEvents = @"production_events"; 52| |NSString *const UnconfirmedEvents = @"eligible_for_prediction_events"; 53| | 54| |@interface FBSDKSuggestedEventsIndexer () 55| | 56| |@property (nonatomic, readonly) id requestProvider; 57| |@property (nonatomic, readonly) Class serverConfigurationProvider; 58| |@property (nonatomic, readonly) Class swizzler; 59| |@property (nonatomic, readonly) id settings; 60| |@property (nonatomic, readonly) id eventLogger; 61| |@property (nonatomic, readonly) Class featureExtractor; 62| |@property (nonatomic, readonly) NSMutableSet *optInEvents; 63| |@property (nonatomic, readonly) NSMutableSet *unconfirmedEvents; 64| |@property (nonatomic, readonly, weak) id eventProcessor; 65| | 66| |@end 67| | 68| |@implementation FBSDKSuggestedEventsIndexer 69| | 70| |- (instancetype)init 71| 0|{ 72| 0| return [self initWithGraphRequestProvider:[FBSDKGraphRequestFactory new] 73| 0| serverConfigurationProvider:FBSDKServerConfigurationManager.class 74| 0| swizzler:FBSDKSwizzler.class 75| 0| settings:FBSDKSettings.sharedSettings 76| 0| eventLogger:FBSDKAppEvents.singleton 77| 0| featureExtractor:FBSDKFeatureExtractor.class 78| 0| eventProcessor:FBSDKModelManager.shared]; 79| 0|} 80| | 81| |- (instancetype)initWithGraphRequestProvider:(id)requestProvider 82| | serverConfigurationProvider:(Class)serverConfigurationProvider 83| | swizzler:(Class)swizzler 84| | settings:(id)settings 85| | eventLogger:(id)eventLogger 86| | featureExtractor:(Class)featureExtractor 87| | eventProcessor:(id)eventProcessor 88| 0|{ 89| 0| if ((self = [super init])) { 90| 0| _optInEvents = [NSMutableSet set]; 91| 0| _unconfirmedEvents = [NSMutableSet set]; 92| 0| _requestProvider = requestProvider; 93| 0| _serverConfigurationProvider = serverConfigurationProvider; 94| 0| _swizzler = swizzler; 95| 0| _settings = settings; 96| 0| _eventLogger = eventLogger; 97| 0| _featureExtractor = featureExtractor; 98| 0| _eventProcessor = eventProcessor; 99| 0| } 100| 0| return self; 101| 0|} 102| | 103| |// Transitional singleton introduced as a way to change the usage semantics 104| |// from a type-based interface to an instance-based interface. 105| |+ (instancetype)shared 106| 0|{ 107| 0| static dispatch_once_t nonce; 108| 0| static id instance; 109| 0| dispatch_once(&nonce, ^{ 110| 0| instance = [self new]; 111| 0| }); 112| 0| return instance; 113| 0|} 114| | 115| |- (void)enable 116| 0|{ 117| 0| __weak typeof(self) weakSelf = self; 118| 0| [self.serverConfigurationProvider loadServerConfigurationWithCompletionBlock:^(FBSDKServerConfiguration *serverConfiguration, NSError *error) { 119| 0| if (error) { 120| 0| return; 121| 0| } 122| | 123| 0| NSDictionary *suggestedEventsSetting = serverConfiguration.suggestedEventsSetting; 124| 0| if ([suggestedEventsSetting isKindOfClass:[NSNull class]] || !suggestedEventsSetting[OptInEvents] || !suggestedEventsSetting[UnconfirmedEvents]) { 125| 0| return; 126| 0| } 127| | 128| 0| [weakSelf.optInEvents addObjectsFromArray:suggestedEventsSetting[OptInEvents]]; 129| 0| [weakSelf.unconfirmedEvents addObjectsFromArray:suggestedEventsSetting[UnconfirmedEvents]]; 130| | 131| 0| [weakSelf setup]; 132| 0| }]; 133| 0|} 134| | 135| |static dispatch_once_t setupNonce; 136| |- (void)setup 137| 0|{ 138| | // won't do the model prediction when there is no opt-in event and unconfirmed event 139| 0| if (_optInEvents.count == 0 && _unconfirmedEvents.count == 0) { 140| 0| return; 141| 0| } 142| | 143| 0| dispatch_once(&setupNonce, ^{ 144| | // swizzle UIButton 145| 0| [self.swizzler swizzleSelector:@selector(didMoveToWindow) 146| 0| onClass:[UIControl class] 147| 0| withBlock:^(UIControl *control) { 148| 0| if (control.window && [control isKindOfClass:[UIButton class]]) { 149| 0| [((UIButton *)control) addTarget:self action:@selector(buttonClicked:) forControlEvents:UIControlEventTouchDown]; 150| 0| } 151| 0| } 152| 0| named:@"suggested_events"]; 153| | 154| | // UITableView 155| 0| void (^tableViewBlock)(UITableView *tableView, 156| 0| SEL cmd, 157| 0| id delegate) = 158| 0| ^(UITableView *tableView, SEL cmd, id delegate) { 159| 0| [self handleView:tableView withDelegate:delegate]; 160| 0| }; 161| 0| [self.swizzler swizzleSelector:@selector(setDelegate:) 162| 0| onClass:[UITableView class] 163| 0| withBlock:tableViewBlock 164| 0| named:@"suggested_events"]; 165| | 166| | // UICollectionView 167| 0| void (^collectionViewBlock)(UICollectionView *collectionView, 168| 0| SEL cmd, 169| 0| id delegate) = 170| 0| ^(UICollectionView *collectionView, SEL cmd, id delegate) { 171| 0| [self handleView:collectionView withDelegate:delegate]; 172| 0| }; 173| 0| [self.swizzler swizzleSelector:@selector(setDelegate:) 174| 0| onClass:[UICollectionView class] 175| 0| withBlock:collectionViewBlock 176| 0| named:@"suggested_events"]; 177| | 178| 0| fb_dispatch_on_main_thread(^{ 179| 0| [self rematchBindings]; 180| 0| }); 181| 0| }); 182| 0|} 183| | 184| |- (void)rematchBindings 185| 0|{ 186| 0| NSArray *windows = [UIApplication sharedApplication].windows; 187| 0| for (UIWindow *window in windows) { 188| 0| [self matchSubviewsIn:window]; 189| 0| } 190| 0|} 191| | 192| |- (void)matchSubviewsIn:(UIView *)view 193| 0|{ 194| 0| if (!view) { 195| 0| return; 196| 0| } 197| | 198| 0| for (UIView *subview in view.subviews) { 199| 0| if ([subview isKindOfClass:[UITableView class]]) { 200| 0| UITableView *tableView = (UITableView *)subview; 201| 0| [self handleView:tableView withDelegate:tableView.delegate]; 202| 0| } else if ([subview isKindOfClass:[UICollectionView class]]) { 203| 0| UICollectionView *collectionView = (UICollectionView *)subview; 204| 0| [self handleView:collectionView withDelegate:collectionView.delegate]; 205| 0| } else if ([subview isKindOfClass:[UIButton class]]) { 206| 0| [(UIButton *)subview addTarget:self action:@selector(buttonClicked:) forControlEvents:UIControlEventTouchDown]; 207| 0| } 208| | 209| 0| if (![subview isKindOfClass:[UIControl class]]) { 210| 0| [self matchSubviewsIn:subview]; 211| 0| } 212| 0| } 213| 0|} 214| | 215| |- (void)buttonClicked:(UIButton *)button 216| 0|{ 217| 0| [self predictEventWithUIResponder:button 218| 0| text:[FBSDKViewHierarchy getText:button]]; 219| 0|} 220| | 221| |- (void)handleView:(UIView *)view withDelegate:(id)delegate 222| 0|{ 223| 0| if (!delegate) { 224| 0| return; 225| 0| } 226| | 227| 0| if ([view isKindOfClass:[UITableView class]] 228| 0| && [delegate respondsToSelector:@selector(tableView:didSelectRowAtIndexPath:)]) { 229| 0| void (^block)(id, SEL, id, id) = ^(id target, SEL command, UITableView *tableView, NSIndexPath *indexPath) { 230| 0| UITableViewCell *cell = [tableView cellForRowAtIndexPath:indexPath]; 231| 0| [self predictEventWithUIResponder:cell 232| 0| text:[self getTextFromContentView:[cell contentView]]]; 233| 0| }; 234| 0| [self.swizzler swizzleSelector:@selector(tableView:didSelectRowAtIndexPath:) 235| 0| onClass:[delegate class] 236| 0| withBlock:block 237| 0| named:@"suggested_events"]; 238| 0| } else if ([view isKindOfClass:[UICollectionView class]] 239| 0| && [delegate respondsToSelector:@selector(collectionView:didSelectItemAtIndexPath:)]) { 240| 0| void (^block)(id, SEL, id, id) = ^(id target, SEL command, UICollectionView *collectionView, NSIndexPath *indexPath) { 241| 0| UICollectionViewCell *cell = [collectionView cellForItemAtIndexPath:indexPath]; 242| 0| [self predictEventWithUIResponder:cell 243| 0| text:[self getTextFromContentView:[cell contentView]]]; 244| 0| }; 245| 0| [self.swizzler swizzleSelector:@selector(collectionView:didSelectItemAtIndexPath:) 246| 0| onClass:[delegate class] 247| 0| withBlock:block 248| 0| named:@"suggested_events"]; 249| 0| } 250| 0|} 251| | 252| |- (void)predictEventWithUIResponder:(UIResponder *)uiResponder text:(NSString *)text 253| 0|{ 254| 0| if (text.length > 100 || text.length == 0 || [FBSDKAppEventsUtility isSensitiveUserData:text]) { 255| 0| return; 256| 0| } 257| | 258| 0| NSMutableArray *> *trees = [NSMutableArray array]; 259| | 260| 0| fb_dispatch_on_main_thread(^{ 261| 0| NSMutableSet *objAddressSet = [NSMutableSet set]; 262| 0| NSArray *windows = [UIApplication sharedApplication].windows; 263| 0| for (UIWindow *window in windows) { 264| 0| NSDictionary *tree = [FBSDKViewHierarchy recursiveCaptureTreeWithCurrentNode:window 265| 0| targetNode:uiResponder 266| 0| objAddressSet:objAddressSet 267| 0| hash:NO]; 268| 0| if (tree) { 269| 0| if (window.isKeyWindow) { 270| 0| [trees insertObject:tree atIndex:0]; 271| 0| } else { 272| 0| [FBSDKTypeUtility array:trees addObject:tree]; 273| 0| } 274| 0| } 275| 0| } 276| 0| NSMutableDictionary *viewTree = [NSMutableDictionary dictionary]; 277| | 278| 0| NSString *screenName = nil; 279| 0| UIViewController *topMostViewController = [FBSDKInternalUtility topMostViewController]; 280| 0| if (topMostViewController) { 281| 0| screenName = NSStringFromClass([topMostViewController class]); 282| 0| } 283| | 284| 0| [FBSDKTypeUtility dictionary:viewTree setObject:trees forKey:VIEW_HIERARCHY_VIEW_KEY]; 285| 0| [FBSDKTypeUtility dictionary:viewTree setObject:screenName ?: @"" forKey:VIEW_HIERARCHY_SCREEN_NAME_KEY]; 286| | 287| 0| __weak typeof(self) weakSelf = self; 288| 0| dispatch_block_t predictAndLogBlock = ^{ 289| 0| NSMutableDictionary *viewTreeCopy = [viewTree mutableCopy]; 290| 0| float *denseData = [weakSelf.featureExtractor getDenseFeatures:viewTree]; 291| 0| NSString *textFeature = [FBSDKModelUtility normalizedText:[FBSDKFeatureExtractor getTextFeature:text withScreenName:viewTreeCopy[@"screenname"]]]; 292| 0| NSString *event = [weakSelf.eventProcessor processSuggestedEvents:textFeature denseData:denseData]; 293| 0| if (!event || [event isEqualToString:SUGGESTED_EVENT_OTHER]) { 294| 0| return; 295| 0| } 296| 0| if ([weakSelf.optInEvents containsObject:event]) { 297| 0| [weakSelf.eventLogger logEvent:event 298| 0| parameters:@{@"_is_suggested_event" : @"1", 299| 0| @"_button_text" : text}]; 300| 0| } else if ([weakSelf.unconfirmedEvents containsObject:event] && denseData) { 301| | // Only send back not confirmed events to advertisers 302| 0| [weakSelf logSuggestedEvent:event text:text denseFeature:[self getDenseFeaure:denseData] ?: @""]; 303| 0| } 304| 0| free(denseData); 305| 0| }; 306| | 307| 0| #ifdef FBSDKTEST 308| 0| predictAndLogBlock(); 309| | #else 310| | fb_dispatch_on_default_thread(predictAndLogBlock); 311| | #endif 312| 0| }); 313| 0|} 314| | 315| | #pragma mark - Helper Methods 316| | 317| |- (NSString *)getDenseFeaure:(float *)denseData 318| 0|{ 319| | // Get dense feature string 320| 0| NSMutableArray *denseDataArray = [NSMutableArray array]; 321| 0| for (int i = 0; i < 30; i++) { 322| 0| [FBSDKTypeUtility array:denseDataArray addObject:[NSNumber numberWithFloat:denseData[i]]]; 323| 0| } 324| 0| return [denseDataArray componentsJoinedByString:@","]; 325| 0|} 326| | 327| |- (NSString *)getTextFromContentView:(UIView *)contentView 328| 0|{ 329| 0| NSMutableArray *textArray = [NSMutableArray array]; 330| 0| for (UIView *subView in [contentView subviews]) { 331| 0| NSString *label = [FBSDKViewHierarchy getText:subView]; 332| 0| if (label.length > 0) { 333| 0| [FBSDKTypeUtility array:textArray addObject:label]; 334| 0| } 335| 0| } 336| 0| return [textArray componentsJoinedByString:@" "]; 337| 0|} 338| | 339| |- (void)logSuggestedEvent:(NSString *)event 340| | text:(NSString *)text 341| | denseFeature:(NSString *)denseFeature 342| 0|{ 343| 0| if (!denseFeature) { 344| 0| return; 345| 0| } 346| 0| NSString *metadata = [FBSDKBasicUtility JSONStringForObject:@{@"button_text" : text, 347| 0| @"dense" : denseFeature, } 348| 0| error:nil 349| 0| invalidObjectHandler:nil]; 350| 0| if (!metadata) { 351| 0| return; 352| 0| } 353| | 354| 0| id request = [self.requestProvider createGraphRequestWithGraphPath:[NSString stringWithFormat:@"%@/suggested_events", [self.settings appID]] 355| 0| parameters:@{ 356| 0| @"event_name" : event, 357| 0| @"metadata" : metadata, 358| 0| } 359| 0| HTTPMethod:FBSDKHTTPMethodPOST]; 360| 0| [request startWithCompletion:^(id connection, id result, NSError *error) {}]; 361| 0| return; 362| 0|} 363| | 364| | #pragma mark - Testability 365| | 366| | #ifdef FBSDKTEST 367| | 368| |+ (void)reset 369| 0|{ 370| 0| if (setupNonce) { 371| 0| setupNonce = 0; 372| 0| } 373| 0|} 374| | 375| | #endif 376| | 377| |@end 378| | 379| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/ViewHierarchy/FBSDKViewHierarchy.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKViewHierarchy.h" 24| | 25| | #import 26| | 27| | #import 28| | 29| | #import "FBSDKAppEventsUtility.h" 30| | #import "FBSDKCodelessPathComponent.h" 31| | #import "FBSDKCoreKitBasicsImport.h" 32| | #import "FBSDKUtility.h" 33| | #import "FBSDKViewHierarchyMacros.h" 34| | 35| 0| #define MAX_VIEW_HIERARCHY_LEVEL 35 36| | 37| |NS_ASSUME_NONNULL_BEGIN 38| | 39| |_Nullable id getVariableFromInstance(NSObject *instance, NSString *variableName); 40| | 41| |@implementation FBSDKViewHierarchy 42| | 43| |+ (nullable NSArray *)getChildren:(NSObject *)obj 44| 0|{ 45| 0| if ([obj isKindOfClass:[UIControl class]]) { 46| 0| return nil; 47| 0| } 48| | 49| 0| NSMutableArray *children = [NSMutableArray array]; 50| | 51| | // children of window should be viewcontroller 52| 0| if ([obj isKindOfClass:[UIWindow class]]) { 53| 0| UIViewController *rootVC = ((UIWindow *)obj).rootViewController; 54| 0| NSArray *subviews = ((UIWindow *)obj).subviews; 55| 0| for (UIView *child in subviews) { 56| 0| if (child != rootVC.view) { 57| 0| UIViewController *vc = [FBSDKViewHierarchy getParentViewController:child]; 58| 0| if (vc != nil && vc.view == child) { 59| 0| [FBSDKTypeUtility array:children addObject:vc]; 60| 0| } else { 61| 0| [FBSDKTypeUtility array:children addObject:child]; 62| 0| } 63| 0| } else { 64| 0| if (rootVC) { 65| 0| [FBSDKTypeUtility array:children addObject:rootVC]; 66| 0| } 67| 0| } 68| 0| } 69| 0| } else if ([obj isKindOfClass:[UIView class]]) { 70| 0| NSArray *subviews = [((UIView *)obj).subviews copy]; 71| 0| for (UIView *child in subviews) { 72| 0| UIViewController *vc = [FBSDKViewHierarchy getParentViewController:child]; 73| 0| if (vc && vc.view == child) { 74| 0| [FBSDKTypeUtility array:children addObject:vc]; 75| 0| } else { 76| 0| [FBSDKTypeUtility array:children addObject:child]; 77| 0| } 78| 0| } 79| 0| } else if ([obj isKindOfClass:[UINavigationController class]]) { 80| 0| UIViewController *vc = ((UINavigationController *)obj).visibleViewController; 81| 0| UIViewController *tc = ((UINavigationController *)obj).topViewController; 82| 0| NSArray *nextChildren = [FBSDKViewHierarchy getChildren:((UIViewController *)obj).view]; 83| 0| for (NSObject *child in nextChildren) { 84| 0| if (tc && [self isView:child superViewOfView:tc.view]) { 85| 0| [FBSDKTypeUtility array:children addObject:tc]; 86| 0| } else if (vc && [self isView:child superViewOfView:vc.view]) { 87| 0| [FBSDKTypeUtility array:children addObject:vc]; 88| 0| } else { 89| 0| if (child != vc.view && child != tc.view) { 90| 0| [FBSDKTypeUtility array:children addObject:child]; 91| 0| } else { 92| 0| if (vc && child == vc.view) { 93| 0| [FBSDKTypeUtility array:children addObject:vc]; 94| 0| } else if (tc && child == tc.view) { 95| 0| [FBSDKTypeUtility array:children addObject:tc]; 96| 0| } 97| 0| } 98| 0| } 99| 0| } 100| | 101| 0| if (vc && ![children containsObject:vc]) { 102| 0| [FBSDKTypeUtility array:children addObject:vc]; 103| 0| } 104| 0| } else if ([obj isKindOfClass:[UITabBarController class]]) { 105| 0| UIViewController *vc = ((UITabBarController *)obj).selectedViewController; 106| 0| NSArray *nextChildren = [FBSDKViewHierarchy getChildren:((UIViewController *)obj).view]; 107| 0| for (NSObject *child in nextChildren) { 108| 0| if (vc && [self isView:child superViewOfView:vc.view]) { 109| 0| [FBSDKTypeUtility array:children addObject:vc]; 110| 0| } else { 111| 0| if (vc && child == vc.view) { 112| 0| [FBSDKTypeUtility array:children addObject:vc]; 113| 0| } else { 114| 0| [FBSDKTypeUtility array:children addObject:child]; 115| 0| } 116| 0| } 117| 0| } 118| | 119| 0| if (vc && ![children containsObject:vc]) { 120| 0| [FBSDKTypeUtility array:children addObject:vc]; 121| 0| } 122| 0| } else if ([obj isKindOfClass:[UIViewController class]]) { 123| 0| UIViewController *vc = (UIViewController *)obj; 124| 0| if (vc.isViewLoaded) { 125| 0| NSArray *nextChildren = [FBSDKViewHierarchy getChildren:vc.view]; 126| 0| if (nextChildren.count > 0) { 127| 0| [children addObjectsFromArray:nextChildren]; 128| 0| } 129| 0| } 130| 0| for (NSObject *child in vc.childViewControllers) { 131| 0| [FBSDKTypeUtility array:children addObject:child]; 132| 0| } 133| 0| UIViewController *presentedVC = vc.presentedViewController; 134| 0| if (presentedVC) { 135| 0| [FBSDKTypeUtility array:children addObject:presentedVC]; 136| 0| } 137| 0| } 138| 0| return children; 139| 0|} 140| | 141| |+ (nullable NSObject *)getParent:(nullable NSObject *)obj 142| 0|{ 143| 0| if ([obj isKindOfClass:[UIView class]]) { 144| 0| UIView *superview = ((UIView *)obj).superview; 145| 0| UIViewController *superviewViewController = [FBSDKViewHierarchy 146| 0| getParentViewController:superview]; 147| 0| if (superviewViewController && superviewViewController.view == superview) { 148| 0| return superviewViewController; 149| 0| } 150| 0| if (superview && superview != obj) { 151| 0| return superview; 152| 0| } 153| 0| } else if ([obj isKindOfClass:[UIViewController class]]) { 154| 0| UIViewController *vc = (UIViewController *)obj; 155| 0| UIViewController *parentVC = vc.parentViewController; 156| 0| UIViewController *presentingVC = vc.presentingViewController; 157| 0| UINavigationController *nav = vc.navigationController; 158| 0| UITabBarController *tab = vc.tabBarController; 159| | 160| 0| if (nav) { 161| 0| return nav; 162| 0| } 163| | 164| 0| if (tab) { 165| 0| return tab; 166| 0| } 167| | 168| 0| if (parentVC) { 169| 0| return parentVC; 170| 0| } 171| | 172| 0| if (presentingVC && presentingVC.presentedViewController == vc) { 173| 0| return presentingVC; 174| 0| } 175| | 176| | // Return parent of view of UIViewController 177| 0| NSObject *viewParent = [FBSDKViewHierarchy getParent:vc.view]; 178| 0| if (viewParent) { 179| 0| return viewParent; 180| 0| } 181| 0| } 182| 0| return nil; 183| 0|} 184| | 185| |+ (nullable NSArray *)getPath:(NSObject *)obj 186| 0|{ 187| 0| return [FBSDKViewHierarchy getPath:obj limit:MAX_VIEW_HIERARCHY_LEVEL]; 188| 0|} 189| | 190| |+ (nullable NSArray *)getPath:(NSObject *)obj limit:(int)limit 191| 0|{ 192| 0| if (!obj || limit <= 0) { 193| 0| return nil; 194| 0| } 195| | 196| 0| NSMutableArray *path; 197| | 198| 0| NSObject *parent = [FBSDKViewHierarchy getParent:obj]; 199| 0| if (parent) { 200| 0| NSArray *parentPath = [FBSDKViewHierarchy getPath:parent limit:limit - 1]; 201| 0| path = [NSMutableArray arrayWithArray:parentPath]; 202| 0| } else { 203| 0| path = [NSMutableArray array]; 204| 0| } 205| | 206| 0| NSDictionary *componentInfo = [FBSDKViewHierarchy getAttributesOf:obj parent:parent]; 207| | 208| 0| FBSDKCodelessPathComponent *pathComponent = [[FBSDKCodelessPathComponent alloc] 209| 0| initWithJSON:componentInfo]; 210| 0| [FBSDKTypeUtility array:path addObject:pathComponent]; 211| | 212| 0| return [NSArray arrayWithArray:path]; 213| 0|} 214| | 215| |+ (NSDictionary *)getAttributesOf:(NSObject *)obj parent:(NSObject *_Nullable)parent 216| 0|{ 217| 0| NSMutableDictionary *componentInfo = [NSMutableDictionary dictionary]; 218| 0| [FBSDKTypeUtility dictionary:componentInfo setObject:NSStringFromClass([obj class]) forKey:CODELESS_MAPPING_CLASS_NAME_KEY]; 219| | 220| 0| if (![FBSDKViewHierarchy isUserInputView:obj]) { 221| 0| NSString *text = [FBSDKViewHierarchy getText:obj]; 222| 0| if (text.length > 0) { 223| 0| [FBSDKTypeUtility dictionary:componentInfo setObject:text forKey:CODELESS_MAPPING_TEXT_KEY]; 224| 0| } 225| 0| } else { 226| 0| [FBSDKTypeUtility dictionary:componentInfo setObject:@"" forKey:CODELESS_MAPPING_TEXT_KEY]; 227| 0| componentInfo[CODELESS_MAPPING_IS_USER_INPUT_KEY] = @YES; 228| 0| } 229| | 230| 0| NSString *hint = [FBSDKViewHierarchy getHint:obj]; 231| 0| if (hint.length > 0) { 232| 0| [FBSDKTypeUtility dictionary:componentInfo setObject:hint forKey:CODELESS_MAPPING_HINT_KEY]; 233| 0| } 234| | 235| 0| NSIndexPath *indexPath = [FBSDKViewHierarchy getIndexPath:obj]; 236| 0| if (indexPath) { 237| 0| [FBSDKTypeUtility dictionary:componentInfo setObject:@(indexPath.section) forKey:CODELESS_MAPPING_SECTION_KEY]; 238| 0| [FBSDKTypeUtility dictionary:componentInfo setObject:@(indexPath.row) forKey:CODELESS_MAPPING_ROW_KEY]; 239| 0| } 240| | 241| 0| if (parent != nil) { 242| 0| NSArray *children = [FBSDKViewHierarchy getChildren:parent]; 243| 0| NSUInteger index = [children indexOfObject:obj]; 244| 0| if (index != NSNotFound) { 245| 0| [FBSDKTypeUtility dictionary:componentInfo setObject:@(index) forKey:CODELESS_MAPPING_INDEX_KEY]; 246| 0| } 247| 0| } else { 248| 0| [FBSDKTypeUtility dictionary:componentInfo setObject:@0 forKey:CODELESS_MAPPING_INDEX_KEY]; 249| 0| } 250| | 251| 0| [FBSDKTypeUtility dictionary:componentInfo setObject:@([FBSDKViewHierarchy getTag:obj]) forKey:CODELESS_VIEW_TREE_TAG_KEY]; 252| | 253| 0| return [componentInfo copy]; 254| 0|} 255| | 256| |+ (nullable NSMutableDictionary *)getDetailAttributesOf:(NSObject *)obj 257| 0|{ 258| 0| return [self getDetailAttributesOf:obj withHash:YES]; 259| 0|} 260| | 261| |+ (nullable NSMutableDictionary *)getDetailAttributesOf:(NSObject *)obj withHash:(BOOL)hash 262| 0|{ 263| 0| if (!obj) { 264| 0| return nil; 265| 0| } 266| | 267| 0| NSObject *parent = [FBSDKViewHierarchy getParent:obj]; 268| | 269| 0| NSDictionary *simpleAttributes = [FBSDKViewHierarchy getAttributesOf:obj parent:parent]; 270| | 271| 0| NSMutableDictionary *result = [NSMutableDictionary dictionaryWithDictionary:simpleAttributes]; 272| | 273| 0| NSString *className = NSStringFromClass([obj class]); 274| 0| [FBSDKTypeUtility dictionary:result setObject:className forKey:VIEW_HIERARCHY_CLASS_NAME_KEY]; 275| | 276| 0| NSUInteger classBitmask = [FBSDKViewHierarchy getClassBitmask:obj]; 277| 0| [FBSDKTypeUtility dictionary:result setObject:[NSString stringWithFormat:@"%lu", (unsigned long)classBitmask] forKey:VIEW_HIERARCHY_CLASS_TYPE_BITMASK_KEY]; 278| | 279| 0| if ([obj isKindOfClass:[UIControl class]]) { 280| | // Get actions of UIControl 281| 0| UIControl *control = (UIControl *)obj; 282| 0| NSMutableSet *actions = [NSMutableSet set]; 283| 0| NSSet *targets = control.allTargets; 284| 0| for (NSObject *target in targets) { 285| 0| NSArray *ary = [control actionsForTarget:target forControlEvent:0]; 286| 0| if (ary.count > 0) { 287| 0| [actions addObjectsFromArray:ary]; 288| 0| } 289| 0| } 290| 0| if (targets.count > 0) { 291| 0| [FBSDKTypeUtility dictionary:result setObject:actions.allObjects forKey:CODELESS_VIEW_TREE_ACTIONS_KEY]; 292| 0| } 293| 0| } 294| | 295| 0| [FBSDKTypeUtility dictionary:result setObject:[FBSDKViewHierarchy getDimensionOf:obj] forKey:CODELESS_VIEW_TREE_DIMENSION_KEY]; 296| | 297| 0| NSDictionary *textStyle = [FBSDKViewHierarchy getTextStyle:obj]; 298| 0| if (textStyle) { 299| 0| [FBSDKTypeUtility dictionary:result setObject:textStyle forKey:CODELESS_VIEW_TREE_TEXT_STYLE_KEY]; 300| 0| } 301| | 302| 0| if (hash) { 303| | // hash text and hint 304| 0| [FBSDKTypeUtility dictionary:result setObject:[FBSDKUtility SHA256Hash:result[VIEW_HIERARCHY_TEXT_KEY]] forKey:VIEW_HIERARCHY_TEXT_KEY]; 305| 0| [FBSDKTypeUtility dictionary:result setObject:[FBSDKUtility SHA256Hash:result[VIEW_HIERARCHY_HINT_KEY]] forKey:VIEW_HIERARCHY_HINT_KEY]; 306| 0| } 307| | 308| 0| return result; 309| 0|} 310| | 311| |+ (nullable NSIndexPath *)getIndexPath:(NSObject *)obj 312| 0|{ 313| 0| NSIndexPath *indexPath = nil; 314| | 315| 0| if ([obj isKindOfClass:[UITableViewCell class]]) { 316| 0| UITableView *tableView = [FBSDKViewHierarchy getParentTableView:(UIView *)obj]; 317| 0| indexPath = [tableView indexPathForCell:(UITableViewCell *)obj]; 318| 0| } else if ([obj isKindOfClass:[UICollectionViewCell class]]) { 319| 0| UICollectionView *collectionView = [FBSDKViewHierarchy getParentCollectionView:(UIView *)obj]; 320| 0| indexPath = [collectionView indexPathForCell:(UICollectionViewCell *)obj]; 321| 0| } 322| | 323| 0| return indexPath; 324| 0|} 325| | 326| |// This method only works for ObjC objects (whether statically typed or id) 327| |id getVariableFromInstance(NSObject *instance, NSString *variableName) 328| 0|{ 329| 0| if (instance == nil || variableName.length == 0) { 330| 0| return [NSNull null]; 331| 0| } 332| | 333| 0| Ivar ivar = class_getInstanceVariable([instance class], variableName.UTF8String); 334| 0| if (ivar != NULL) { 335| 0| const char *encoding = ivar_getTypeEncoding(ivar); 336| 0| if (encoding != NULL && encoding[0] == '@') { 337| 0| return object_getIvar(instance, ivar); 338| 0| } 339| 0| } 340| | 341| 0| return [NSNull null]; 342| 0|} 343| | 344| |+ (NSString *)getText:(nullable NSObject *)obj 345| 0|{ 346| 0| NSString *text = nil; 347| | 348| 0| if ([obj isKindOfClass:[UIButton class]]) { 349| 0| text = ((UIButton *)obj).currentTitle; 350| 0| } else if ([obj isKindOfClass:[UITextView class]] 351| 0| || [obj isKindOfClass:[UITextField class]] 352| 0| || [obj isKindOfClass:[UILabel class]]) { 353| 0| text = ((UILabel *)obj).text; 354| 0| } else if ([obj isKindOfClass:[UIPickerView class]]) { 355| 0| UIPickerView *picker = (UIPickerView *)obj; 356| 0| NSInteger sections = picker.numberOfComponents; 357| 0| NSMutableArray *titles = [NSMutableArray array]; 358| | 359| 0| for (NSInteger i = 0; i < sections; i++) { 360| 0| NSInteger numberOfRow = [picker numberOfRowsInComponent:i]; 361| 0| if (numberOfRow <= 0) { 362| 0| continue; 363| 0| } 364| 0| NSInteger row = [picker selectedRowInComponent:i]; 365| 0| NSString *title; 366| 0| if ([picker.delegate 367| 0| respondsToSelector:@selector(pickerView:titleForRow:forComponent:)]) { 368| 0| title = [picker.delegate pickerView:picker titleForRow:row forComponent:i]; 369| 0| } else if ([picker.delegate 370| 0| respondsToSelector:@selector(pickerView:attributedTitleForRow:forComponent:)]) { 371| 0| title = [picker.delegate 372| 0| pickerView:picker 373| 0| attributedTitleForRow:row forComponent:i].string; 374| 0| } 375| 0| [FBSDKTypeUtility array:titles addObject:title ?: @""]; 376| 0| } 377| | 378| 0| if (titles.count > 0) { 379| 0| text = [FBSDKBasicUtility JSONStringForObject:titles 380| 0| error:NULL 381| 0| invalidObjectHandler:NULL]; 382| 0| } 383| 0| } else if ([obj isKindOfClass:[UIDatePicker class]]) { 384| 0| UIDatePicker *picker = (UIDatePicker *)obj; 385| 0| NSDateFormatter *const formatter = [NSDateFormatter new]; 386| 0| formatter.dateFormat = @"yyyy-MM-dd HH:mm:ssZ"; 387| 0| text = [formatter stringFromDate:picker.date]; 388| 0| } else if ([obj isKindOfClass:objc_lookUpClass("RCTTextView")]) { 389| 0| NSTextStorage *const textStorage = FBSDK_CAST_TO_CLASS_OR_NIL(getVariableFromInstance(obj, @"_textStorage"), NSTextStorage); 390| 0| if (textStorage) { 391| 0| text = [textStorage string]; 392| 0| } 393| 0| } else if ([obj isKindOfClass:objc_lookUpClass("RCTBaseTextInputView")]) { 394| 0| NSAttributedString *const attributedText = FBSDK_CAST_TO_CLASS_OR_NIL(getVariableFromInstance(obj, @"attributedText"), NSAttributedString); 395| 0| if (attributedText) { 396| 0| text = [attributedText string]; 397| 0| } 398| 0| } 399| | 400| 0| return text ?: @""; 401| 0|} 402| | 403| |+ (nullable NSDictionary *)getTextStyle:(NSObject *)obj 404| 0|{ 405| 0| UIFont *font = nil; 406| 0| if ([obj isKindOfClass:[UIButton class]]) { 407| 0| font = ((UIButton *)obj).titleLabel.font; 408| 0| } else if ([obj isKindOfClass:[UILabel class]]) { 409| 0| font = ((UILabel *)obj).font; 410| 0| } else if ([obj isKindOfClass:[UITextField class]]) { 411| 0| font = ((UITextField *)obj).font; 412| 0| } else if ([obj isKindOfClass:[UITextView class]]) { 413| 0| font = ((UITextView *)obj).font; 414| 0| } 415| | 416| 0| if (font) { 417| 0| UIFontDescriptorSymbolicTraits traits = font.fontDescriptor.symbolicTraits; 418| 0| BOOL isBold = (traits & UIFontDescriptorTraitBold) != 0; 419| 0| BOOL isItalic = (traits & UIFontDescriptorTraitItalic) != 0; 420| 0| CGFloat fontSize = font.pointSize; 421| | 422| 0| return @{ 423| 0| CODELESS_VIEW_TREE_TEXT_IS_BOLD_KEY : @(isBold), 424| 0| CODELESS_VIEW_TREE_TEXT_IS_ITALIC_KEY : @(isItalic), 425| 0| CODELESS_VIEW_TREE_TEXT_SIZE_KEY : @(fontSize) 426| 0| }; 427| 0| } 428| | 429| 0| return nil; 430| 0|} 431| | 432| |+ (NSString *)getHint:(nullable NSObject *)obj 433| 0|{ 434| 0| NSString *hint = nil; 435| | 436| 0| if ([obj isKindOfClass:[UITextField class]]) { 437| 0| UITextField *textField = (UITextField *)obj; 438| 0| hint = textField.placeholder ?: @""; 439| 0| hint = [hint stringByAppendingString:[self recursiveGetLabelsFromView:textField]]; 440| 0| } else if ([obj isKindOfClass:[UINavigationController class]]) { 441| 0| UIViewController *top = ((UINavigationController *)obj).topViewController; 442| 0| if (top) { 443| 0| hint = NSStringFromClass([top class]); 444| 0| } 445| 0| } 446| | 447| 0| return hint ?: @""; 448| 0|} 449| | 450| |+ (NSUInteger)getClassBitmask:(NSObject *)obj 451| 0|{ 452| 0| NSUInteger bitmask = 0; 453| | 454| 0| if ([obj isKindOfClass:[UIView class]]) { 455| 0| if ([obj isKindOfClass:[UIControl class]]) { 456| 0| bitmask |= FBCodelessClassBitmaskUIControl; 457| 0| if ([obj isKindOfClass:[UIButton class]]) { 458| 0| bitmask |= FBCodelessClassBitmaskUIButton; 459| 0| } else if ([obj isKindOfClass:[UISwitch class]]) { 460| 0| bitmask |= FBCodelessClassBitmaskSwitch; 461| 0| } else if ([obj isKindOfClass:[UIDatePicker class]]) { 462| 0| bitmask |= FBCodelessClassBitmaskPicker; 463| 0| } 464| 0| } else if ([obj isKindOfClass:[UITableViewCell class]]) { 465| 0| bitmask |= FBCodelessClassBitmaskUITableViewCell; 466| 0| } else if ([obj isKindOfClass:[UICollectionViewCell class]]) { 467| 0| bitmask |= FBCodelessClassBitmaskUICollectionViewCell; 468| 0| } else if ([obj isKindOfClass:[UIPickerView class]]) { 469| 0| bitmask |= FBCodelessClassBitmaskPicker; 470| 0| } else if ([obj isKindOfClass:[UILabel class]]) { 471| 0| bitmask |= FBCodelessClassBitmaskLabel; 472| 0| } 473| | 474| 0| if ([FBSDKViewHierarchy isRCTButton:((UIView *)obj)]) { 475| 0| bitmask |= FBCodelessClassBitmaskReactNativeButton; 476| 0| } 477| | 478| | // Check selector of UITextInput protocol instead of checking conformsToProtocol 479| 0| if ([obj respondsToSelector:@selector(textInRange:)]) { 480| 0| bitmask |= FBCodelessClassBitmaskInput; 481| 0| } 482| 0| } else if ([obj isKindOfClass:[UIViewController class]]) { 483| 0| bitmask |= FBCodelessClassBitmaskUIViewController; 484| 0| } 485| | 486| 0| return bitmask; 487| 0|} 488| | 489| |+ (BOOL)isUserInputView:(NSObject *)obj 490| 0|{ 491| 0| if (obj && [obj conformsToProtocol:@protocol(UITextInput)]) { 492| 0| id input = (id)obj; 493| 0| if ([input respondsToSelector:@selector(isSecureTextEntry)] 494| 0| && input.secureTextEntry) { 495| 0| return YES; 496| 0| } else { 497| 0| if ([input respondsToSelector:@selector(keyboardType)]) { 498| 0| switch (input.keyboardType) { 499| 0| case UIKeyboardTypePhonePad: 500| 0| case UIKeyboardTypeEmailAddress: 501| 0| return YES; 502| 0| default: break; 503| 0| } 504| 0| } 505| 0| } 506| 0| } 507| | 508| 0| NSString *text = [FBSDKViewHierarchy getText:obj]; 509| 0| return text.length > 0 && [FBSDKAppEventsUtility isSensitiveUserData:text]; 510| 0|} 511| | 512| |+ (nullable NSDictionary *)recursiveCaptureTreeWithCurrentNode:(NSObject *)currentNode 513| | targetNode:(nullable NSObject *)targetNode 514| | objAddressSet:(nullable NSMutableSet *)objAddressSet 515| | hash:(BOOL)hash 516| 0|{ 517| 0| if (!currentNode) { 518| 0| return nil; 519| 0| } 520| | 521| 0| if (objAddressSet) { 522| 0| if ([objAddressSet containsObject:currentNode]) { 523| 0| return nil; 524| 0| } 525| 0| [objAddressSet addObject:currentNode]; 526| 0| } 527| | 528| 0| NSMutableDictionary *result = [FBSDKViewHierarchy getDetailAttributesOf:currentNode 529| 0| withHash:hash]; 530| | 531| 0| NSArray *children = [FBSDKViewHierarchy getChildren:currentNode]; 532| 0| NSMutableArray *> *childrenTrees = [NSMutableArray array]; 533| 0| for (NSObject *child in children) { 534| 0| NSDictionary *objTree = [self recursiveCaptureTreeWithCurrentNode:child 535| 0| targetNode:targetNode 536| 0| objAddressSet:objAddressSet 537| 0| hash:hash]; 538| 0| if (objTree != nil) { 539| 0| [FBSDKTypeUtility array:childrenTrees addObject:objTree]; 540| 0| } 541| 0| } 542| | 543| 0| if (childrenTrees.count > 0) { 544| 0| [FBSDKTypeUtility dictionary:result setObject:[childrenTrees copy] forKey:VIEW_HIERARCHY_CHILD_VIEWS_KEY]; 545| 0| } 546| 0| if (targetNode && currentNode == targetNode) { 547| 0| [FBSDKTypeUtility dictionary:result setObject:[NSNumber numberWithBool:YES] forKey:VIEW_HIERARCHY_IS_INTERACTED_KEY]; 548| 0| } 549| 0| return [result copy]; 550| 0|} 551| | 552| | #pragma clang diagnostic push 553| | #pragma clang diagnostic ignored "-Wundeclared-selector" 554| |+ (BOOL)isRCTButton:(UIView *)view 555| 0|{ 556| 0| if (view == nil) { 557| 0| return NO; 558| 0| } 559| | 560| 0| Class classRCTView = objc_lookUpClass(ReactNativeClassRCTView); 561| 0| if (classRCTView && [view isKindOfClass:classRCTView] 562| 0| && [view respondsToSelector:@selector(reactTagAtPoint:)] 563| 0| && [view respondsToSelector:@selector(reactTag)] 564| 0| && view.userInteractionEnabled) { 565| | // We check all its subviews locations and the view is clickable if there exists one that mathces reactTagAtPoint 566| 0| for (UIView *subview in view.subviews) { 567| 0| if (subview && ![subview isKindOfClass:classRCTView]) { 568| 0| NSNumber *reactTag = [view performSelector:@selector(reactTagAtPoint:) 569| 0| withObject:[NSValue valueWithCGPoint:subview.frame.origin]]; 570| 0| NSNumber *subviewReactTag = [FBSDKViewHierarchy getViewReactTag:subview]; 571| 0| if (reactTag != nil && subviewReactTag != nil && [reactTag isEqualToNumber:subviewReactTag]) { 572| 0| return YES; 573| 0| } 574| 0| } 575| 0| } 576| 0| } 577| | 578| 0| return NO; 579| 0|} 580| | 581| |+ (nullable NSNumber *)getViewReactTag:(UIView *)view 582| 0|{ 583| 0| if (view != nil && [view respondsToSelector:@selector(reactTag)]) { 584| 0| NSNumber *reactTag = [view performSelector:@selector(reactTag)]; 585| 0| if (reactTag != nil && [reactTag isKindOfClass:[NSNumber class]]) { 586| 0| return reactTag; 587| 0| } 588| 0| } 589| | 590| 0| return nil; 591| 0|} 592| | 593| | #pragma clang diagnostic pop 594| | 595| |+ (BOOL)isView:(NSObject *)obj1 superViewOfView:(UIView *)obj2 596| 0|{ 597| 0| if (![obj1 isKindOfClass:[UIView class]] 598| 0| || ![obj2 isKindOfClass:[UIView class]]) { 599| 0| return NO; 600| 0| } 601| 0| UIView *view1 = (UIView *)obj1; 602| 0| UIView *view2 = (UIView *)obj2; 603| 0| UIView *superview = view2; 604| 0| while (superview) { 605| 0| superview = superview.superview; 606| 0| if (superview == view1) { 607| 0| return YES; 608| 0| } 609| 0| } 610| | 611| 0| return NO; 612| 0|} 613| | 614| |+ (nullable UIViewController *)getParentViewController:(UIView *)view 615| 0|{ 616| 0| UIResponder *parentResponder = view; 617| | 618| 0| while (parentResponder) { 619| 0| parentResponder = parentResponder.nextResponder; 620| 0| if ([parentResponder isKindOfClass:[UIViewController class]]) { 621| 0| return (UIViewController *)parentResponder; 622| 0| } 623| 0| } 624| | 625| 0| return nil; 626| 0|} 627| | 628| |+ (nullable UITableView *)getParentTableView:(UIView *)cell 629| 0|{ 630| 0| UIView *superview = cell.superview; 631| 0| while (superview) { 632| 0| if ([superview isKindOfClass:[UITableView class]]) { 633| 0| return (UITableView *)superview; 634| 0| } 635| 0| superview = superview.superview; 636| 0| } 637| 0| return nil; 638| 0|} 639| | 640| |+ (nullable UICollectionView *)getParentCollectionView:(UIView *)cell 641| 0|{ 642| 0| UIView *superview = cell.superview; 643| 0| while (superview) { 644| 0| if ([superview isKindOfClass:[UICollectionView class]]) { 645| 0| return (UICollectionView *)superview; 646| 0| } 647| 0| superview = superview.superview; 648| 0| } 649| 0| return nil; 650| 0|} 651| | 652| |+ (NSInteger)getTag:(NSObject *)obj 653| 0|{ 654| 0| if ([obj isKindOfClass:[UIView class]]) { 655| 0| return ((UIView *)obj).tag; 656| 0| } else if ([obj isKindOfClass:[UIViewController class]]) { 657| 0| UIViewController *vc = (UIViewController *)obj; 658| 0| if (vc.isViewLoaded) { 659| 0| return ((UIViewController *)obj).view.tag; 660| 0| } 661| 0| } 662| | 663| 0| return 0; 664| 0|} 665| | 666| |+ (NSDictionary *)getDimensionOf:(NSObject *)obj 667| 0|{ 668| 0| UIView *view = nil; 669| | 670| 0| if ([obj isKindOfClass:[UIView class]]) { 671| 0| view = (UIView *)obj; 672| 0| } else if ([obj isKindOfClass:[UIViewController class]]) { 673| 0| view = ((UIViewController *)obj).view; 674| 0| } 675| | 676| 0| CGRect frame = view.frame; 677| 0| CGPoint offset = CGPointZero; 678| | 679| 0| if ([view isKindOfClass:[UIScrollView class]]) { 680| 0| offset = ((UIScrollView *)view).contentOffset; 681| 0| } 682| | 683| 0| return @{ 684| 0| CODELESS_VIEW_TREE_TOP_KEY : @((int)frame.origin.y), 685| 0| CODELESS_VIEW_TREE_LEFT_KEY : @((int)frame.origin.x), 686| 0| CODELESS_VIEW_TREE_WIDTH_KEY : @((int)frame.size.width), 687| 0| CODELESS_VIEW_TREE_HEIGHT_KEY : @((int)frame.size.height), 688| 0| CODELESS_VIEW_TREE_OFFSET_X_KEY : @((int)offset.x), 689| 0| CODELESS_VIEW_TREE_OFFSET_Y_KEY : @((int)offset.y), 690| 0| CODELESS_VIEW_TREE_VISIBILITY_KEY : view.isHidden ? @4 : @0 691| 0| }; 692| 0|} 693| | 694| |+ (NSString *)recursiveGetLabelsFromView:(UIView *)view 695| 0|{ 696| 0| NSString *str = @""; 697| 0| for (UIView *subview in view.subviews) { 698| 0| str = [str stringByAppendingString:[self recursiveGetLabelsFromView:subview]]; 699| 0| } 700| 0| if ([view isKindOfClass:[UILabel class]] && ((UILabel *)view).text.length > 0) { 701| 0| str = [str stringByAppendingFormat:@" %@", ((UILabel *)view).text]; 702| 0| } 703| 0| return str; 704| 0|} 705| | 706| |@end 707| | 708| |NS_ASSUME_NONNULL_END 709| | 710| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/ViewHierarchy/FBSDKViewHierarchyMacros.h: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| |#ifndef FBSDKViewHierarchyMacros_h 19| |#define FBSDKViewHierarchyMacros_h 20| | 21| |// keys for event binding path compoenent 22| |#define CODELESS_MAPPING_METHOD_KEY @"method" 23| 0|#define CODELESS_MAPPING_EVENT_NAME_KEY @"event_name" 24| 0|#define CODELESS_MAPPING_EVENT_TYPE_KEY @"event_type" 25| 0|#define CODELESS_MAPPING_APP_VERSION_KEY @"app_version" 26| 0|#define CODELESS_MAPPING_PATH_KEY @"path" 27| 0|#define CODELESS_MAPPING_PATH_TYPE_KEY @"path_type" 28| 0|#define CODELESS_MAPPING_CLASS_NAME_KEY @"class_name" 29| 0|#define CODELESS_MAPPING_MATCH_BITMASK_KEY @"match_bitmask" 30| |#define CODELESS_MAPPING_ID_KEY @"id" 31| 0|#define CODELESS_MAPPING_INDEX_KEY @"index" 32| 0|#define CODELESS_MAPPING_IS_USER_INPUT_KEY @"is_user_input" 33| 0|#define CODELESS_MAPPING_SECTION_KEY @"section" 34| 0|#define CODELESS_MAPPING_ROW_KEY @"row" 35| 0|#define CODELESS_MAPPING_TEXT_KEY @"text" 36| 0|#define CODELESS_MAPPING_TAG_KEY @"tag" 37| 0|#define CODELESS_MAPPING_DESC_KEY @"description" 38| 0|#define CODELESS_MAPPING_HINT_KEY @"hint" 39| 0|#define CODELESS_MAPPING_PARAMETERS_KEY @"parameters" 40| 0|#define CODELESS_MAPPING_PARAMETER_NAME_KEY @"name" 41| 0|#define CODELESS_MAPPING_PARAMETER_VALUE_KEY @"value" 42| | 43| 0|#define CODELESS_MAPPING_PARENT_CLASS_NAME @".." 44| 0|#define CODELESS_MAPPING_CURRENT_CLASS_NAME @"." 45| | 46| 0|#define ReactNativeClassRCTView "RCTView" 47| 0|#define ReactNativeClassRCTRootView "RCTRootView" 48| | 49| 0|#define CODELESS_INDEXING_UPLOAD_INTERVAL_IN_SECONDS 1 50| 0|#define CODELESS_INDEXING_STATUS_KEY @"is_app_indexing_enabled" 51| 0|#define CODELESS_INDEXING_SESSION_ID_KEY @"device_session_id" 52| 0|#define CODELESS_INDEXING_APP_VERSION_KEY @"app_version" 53| |#define CODELESS_INDEXING_SDK_VERSION_KEY @"sdk_version" 54| 0|#define CODELESS_INDEXING_PLATFORM_KEY @"platform" 55| 0|#define CODELESS_INDEXING_TREE_KEY @"tree" 56| |#define CODELESS_INDEXING_SCREENSHOT_KEY @"screenshot" 57| 0|#define CODELESS_INDEXING_EXT_INFO_KEY @"extinfo" 58| | 59| 0|#define CODELESS_INDEXING_ENDPOINT @"app_indexing" 60| 0|#define CODELESS_INDEXING_SESSION_ENDPOINT @"app_indexing_session" 61| | 62| 0|#define CODELESS_SETUP_ENABLED_FIELD @"auto_event_setup_enabled" 63| 0|#define CODELESS_SETUP_ENABLED_KEY @"codeless_setup_enabled" 64| 0|#define CODELESS_SETTING_KEY @"com.facebook.sdk:codelessSetting%@" 65| 0|#define CODELESS_SETTING_TIMESTAMP_KEY @"codeless_setting_timestamp" 66| 0|#define CODELESS_SETTING_CACHE_TIMEOUT (7 * 24 * 60 * 60) 67| | 68| |// keys for view tree 69| |#define CODELESS_VIEW_TREE_DESC_KEY @"description" 70| 0|#define CODELESS_VIEW_TREE_DIMENSION_KEY @"dimension" 71| 0|#define CODELESS_VIEW_TREE_TAG_KEY @"tag" 72| 0|#define CODELESS_VIEW_TREE_ACTIONS_KEY @"actions" 73| | 74| 0|#define CODELESS_VIEW_TREE_TOP_KEY @"top" 75| 0|#define CODELESS_VIEW_TREE_LEFT_KEY @"left" 76| 0|#define CODELESS_VIEW_TREE_WIDTH_KEY @"width" 77| 0|#define CODELESS_VIEW_TREE_HEIGHT_KEY @"height" 78| 0|#define CODELESS_VIEW_TREE_OFFSET_X_KEY @"scrollx" 79| 0|#define CODELESS_VIEW_TREE_OFFSET_Y_KEY @"scrolly" 80| 0|#define CODELESS_VIEW_TREE_VISIBILITY_KEY @"visibility" 81| | 82| 0|#define CODELESS_VIEW_TREE_TEXT_STYLE_KEY @"text_style" 83| 0|#define CODELESS_VIEW_TREE_TEXT_IS_BOLD_KEY @"is_bold" 84| 0|#define CODELESS_VIEW_TREE_TEXT_IS_ITALIC_KEY @"is_italic" 85| 0|#define CODELESS_VIEW_TREE_TEXT_SIZE_KEY @"font_size" 86| | 87| |// keys for view hierarchy 88| 0|#define VIEW_HIERARCHY_CHILD_VIEWS_KEY @"childviews" 89| 0|#define VIEW_HIERARCHY_CLASS_NAME_KEY @"classname" 90| 0|#define VIEW_HIERARCHY_CLASS_TYPE_BITMASK_KEY @"classtypebitmask" 91| 0|#define VIEW_HIERARCHY_HINT_KEY @"hint" 92| 0|#define VIEW_HIERARCHY_IS_INTERACTED_KEY @"is_interacted" 93| 0|#define VIEW_HIERARCHY_SCREEN_NAME_KEY @"screenname" 94| 0|#define VIEW_HIERARCHY_TEXT_KEY @"text" 95| 0|#define VIEW_HIERARCHY_VIEW_KEY @"view" 96| | 97| |#endif /* FBSDKCodelessMacros_h */ /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppLink/FBSDKAppLink.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKAppLink_Internal.h" 24| | 25| |NSString *const FBSDKAppLinkDataParameterName = @"al_applink_data"; 26| |NSString *const FBSDKAppLinkTargetKeyName = @"target_url"; 27| |NSString *const FBSDKAppLinkUserAgentKeyName = @"user_agent"; 28| |NSString *const FBSDKAppLinkExtrasKeyName = @"extras"; 29| |NSString *const FBSDKAppLinkRefererAppLink = @"referer_app_link"; 30| |NSString *const FBSDKAppLinkRefererAppName = @"app_name"; 31| |NSString *const FBSDKAppLinkRefererUrl = @"url"; 32| |NSString *const FBSDKAppLinkVersionKeyName = @"version"; 33| |NSString *const FBSDKAppLinkVersion = @"1.0"; 34| | 35| |@interface FBSDKAppLink () 36| | 37| |@property (nonatomic, strong) NSURL *sourceURL; 38| |@property (nonatomic, copy) NSArray *targets; 39| |@property (nonatomic, strong) NSURL *webURL; 40| | 41| |@property (nonatomic, getter = isBackToReferrer, assign) BOOL backToReferrer; 42| | 43| |@end 44| | 45| |@implementation FBSDKAppLink 46| | 47| |+ (instancetype)appLinkWithSourceURL:(NSURL *)sourceURL 48| | targets:(NSArray *)targets 49| | webURL:(NSURL *)webURL 50| | isBackToReferrer:(BOOL)isBackToReferrer 51| 0|{ 52| 0| FBSDKAppLink *link = [[self alloc] initWithIsBackToReferrer:isBackToReferrer]; 53| 0| link.sourceURL = sourceURL; 54| 0| link.targets = [targets copy]; 55| 0| link.webURL = webURL; 56| 0| return link; 57| 0|} 58| | 59| |+ (instancetype)appLinkWithSourceURL:(NSURL *)sourceURL 60| | targets:(NSArray *)targets 61| | webURL:(NSURL *)webURL 62| 0|{ 63| 0| return [self appLinkWithSourceURL:sourceURL 64| 0| targets:targets 65| 0| webURL:webURL 66| 0| isBackToReferrer:NO]; 67| 0|} 68| | 69| |- (FBSDKAppLink *)initWithIsBackToReferrer:(BOOL)backToReferrer 70| 0|{ 71| 0| if ((self = [super init])) { 72| 0| _backToReferrer = backToReferrer; 73| 0| } 74| 0| return self; 75| 0|} 76| | 77| |@end 78| | 79| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppLink/FBSDKAppLinkTarget.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKAppLinkTarget.h" 24| | 25| |@interface FBSDKAppLinkTarget () 26| | 27| |@property (nonatomic, strong) NSURL *URL; 28| |@property (nonatomic, copy) NSString *appStoreId; 29| |@property (nonatomic, copy) NSString *appName; 30| | 31| |@end 32| | 33| |@implementation FBSDKAppLinkTarget 34| | 35| |+ (instancetype)appLinkTargetWithURL:(NSURL *)url 36| | appStoreId:(NSString *)appStoreId 37| | appName:(NSString *)appName 38| 0|{ 39| 0| FBSDKAppLinkTarget *target = [self new]; 40| 0| target.URL = url; 41| 0| target.appStoreId = appStoreId; 42| 0| target.appName = appName; 43| 0| return target; 44| 0|} 45| | 46| |@end 47| | 48| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppLink/FBSDKAppLinkUtility.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKAppLinkUtility.h" 24| | 25| | #import "FBSDKAppEventsConfigurationManager.h" 26| | #import "FBSDKAppEventsUtility.h" 27| | #import "FBSDKCoreKit+Internal.h" 28| | #import "FBSDKCoreKitBasicsImport.h" 29| | #import "FBSDKGraphRequestProviding.h" 30| | #import "FBSDKSettings.h" 31| | #import "FBSDKURL.h" 32| | 33| |static NSString *const FBSDKLastDeferredAppLink = @"com.facebook.sdk:lastDeferredAppLink%@"; 34| |static NSString *const FBSDKDeferredAppLinkEvent = @"DEFERRED_APP_LINK"; 35| |static id _requestProvider; 36| |static id _infoDictionaryProvider; 37| |static BOOL _isConfigured; 38| | 39| |@implementation FBSDKAppLinkUtility 40| |{} 41| | 42| |+ (void)configureWithRequestProvider:(id)requestProvider 43| | infoDictionaryProvider:(id)infoDictionaryProvider 44| 0|{ 45| 0| if (self == [FBSDKAppLinkUtility class]) { 46| 0| _requestProvider = requestProvider; 47| 0| _infoDictionaryProvider = infoDictionaryProvider; 48| 0| _isConfigured = YES; 49| 0| } 50| 0|} 51| | 52| |+ (void)fetchDeferredAppLink:(FBSDKURLBlock)handler 53| 0|{ 54| 0| [self validateConfiguration]; 55| 0| NSAssert([NSThread isMainThread], @"FBSDKAppLink fetchDeferredAppLink: must be invoked from main thread."); 56| | 57| 0| [FBSDKAppEventsConfigurationManager loadAppEventsConfigurationWithBlock:^{ 58| 0| if ([FBSDKAppEventsUtility shouldDropAppEvent]) { 59| 0| if (handler) { 60| 0| NSError *error = [[NSError alloc] initWithDomain:@"AdvertiserTrackingEnabled must be enabled" code:-1 userInfo:nil]; 61| 0| handler(nil, error); 62| 0| } 63| 0| return; 64| 0| } 65| | 66| 0| NSString *appID = [FBSDKSettings appID]; 67| | 68| | // Deferred app links are only currently used for engagement ads, thus we consider the app to be an advertising one. 69| | // If this is considered for organic, non-ads scenarios, we'll need to retrieve the FBAppEventsUtility.shouldAccessAdvertisingID 70| | // before we make this call. 71| 0| NSMutableDictionary *deferredAppLinkParameters = 72| 0| [FBSDKAppEventsUtility activityParametersDictionaryForEvent:FBSDKDeferredAppLinkEvent 73| 0| shouldAccessAdvertisingID:YES]; 74| 0| id deferredAppLinkRequest = [_requestProvider createGraphRequestWithGraphPath:[NSString stringWithFormat:@"%@/activities", appID, nil] 75| 0| parameters:deferredAppLinkParameters 76| 0| tokenString:nil 77| 0| version:nil 78| 0| HTTPMethod:FBSDKHTTPMethodPOST]; 79| 0| [deferredAppLinkRequest startWithCompletion:^(id connection, 80| 0| id result, 81| 0| NSError *error) { 82| 0| NSURL *applinkURL = nil; 83| 0| if (!error) { 84| 0| NSString *appLinkString = result[@"applink_url"]; 85| 0| if (appLinkString) { 86| 0| applinkURL = [NSURL URLWithString:appLinkString]; 87| | 88| 0| NSString *createTimeUtc = result[@"click_time"]; 89| 0| if (createTimeUtc) { 90| | // append/translate the create_time_utc so it can be used by clients 91| 0| NSString *modifiedURLString = [applinkURL.absoluteString 92| 0| stringByAppendingFormat:@"%@fb_click_time_utc=%@", 93| 0| (applinkURL.query) ? @"&" : @"?", 94| 0| createTimeUtc]; 95| 0| applinkURL = [NSURL URLWithString:modifiedURLString]; 96| 0| } 97| 0| } 98| 0| } 99| | 100| 0| if (handler) { 101| 0| dispatch_async(dispatch_get_main_queue(), ^{ 102| 0| handler(applinkURL, error); 103| 0| }); 104| 0| } 105| 0| }]; 106| 0| }]; 107| 0|} 108| | 109| |+ (NSString *)appInvitePromotionCodeFromURL:(NSURL *)url 110| 0|{ 111| 0| [self validateConfiguration]; 112| 0| FBSDKURL *parsedUrl = [FBSDKURL URLWithURL:url]; 113| 0| NSDictionary *extras = parsedUrl.appLinkExtras; 114| 0| if (extras) { 115| 0| NSString *deeplinkContextString = extras[@"deeplink_context"]; 116| | 117| | // Parse deeplinkContext and extract promo code 118| 0| if (deeplinkContextString.length > 0) { 119| 0| NSError *error = nil; 120| 0| NSDictionary *deeplinkContextData = [FBSDKBasicUtility objectForJSONString:deeplinkContextString error:&error]; 121| 0| if (!error && [deeplinkContextData isKindOfClass:[NSDictionary class]]) { 122| 0| return deeplinkContextData[@"promo_code"]; 123| 0| } 124| 0| } 125| 0| } 126| | 127| 0| return nil; 128| 0|} 129| | 130| |+ (BOOL)isMatchURLScheme:(NSString *)scheme 131| 0|{ 132| 0| if (!scheme) { 133| 0| return NO; 134| 0| } 135| 0| [self validateConfiguration]; 136| 0| for (NSDictionary *urlType in [_infoDictionaryProvider objectForInfoDictionaryKey:@"CFBundleURLTypes"]) { 137| 0| for (NSString *urlScheme in urlType[@"CFBundleURLSchemes"]) { 138| 0| if ([urlScheme caseInsensitiveCompare:scheme] == NSOrderedSame) { 139| 0| return YES; 140| 0| } 141| 0| } 142| 0| } 143| 0| return NO; 144| 0|} 145| | 146| |// MARK: Configuration Validation 147| | 148| |+ (void)validateConfiguration 149| 0|{ 150| 0|#if DEBUG 151| 0| if (!_isConfigured) { 152| 0| static NSString *const reason = @"As of v9.0, you must initialize the SDK prior to calling any methods or setting any properties. " 153| 0| "You can do this by calling `FBSDKApplicationDelegate`'s `application:didFinishLaunchingWithOptions:` method." 154| 0| "Learn more: https://developers.facebook.com/docs/ios/getting-started"; 155| 0| @throw [NSException exceptionWithName:@"InvalidOperationException" reason:reason userInfo:nil]; 156| 0| } 157| 0|#endif 158| 0|} 159| | 160| | #if DEBUG 161| | #if FBSDKTEST 162| | 163| |+ (void)reset 164| 0|{ 165| 0| _isConfigured = NO; 166| 0|} 167| | 168| |+ (id)requestProvider 169| 0|{ 170| 0| return _requestProvider; 171| 0|} 172| | 173| |+ (id)infoDictionaryProvider 174| 0|{ 175| 0| return _infoDictionaryProvider; 176| 0|} 177| | 178| | #endif 179| | #endif 180| | 181| |@end 182| | 183| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppLink/Internal/FBSDKMeasurementEventListener.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKMeasurementEventListener.h" 24| | 25| | #import "FBSDKAppEvents+Internal.h" 26| | #import "FBSDKAppEvents+SourceApplicationTracking.h" 27| | #import "FBSDKCoreKitBasicsImport.h" 28| | #import "FBSDKMeasurementEvent.h" 29| | #import "FBSDKTimeSpentData.h" 30| | 31| |static NSString *const FBSDKMeasurementEventName = @"event_name"; 32| |static NSString *const FBSDKMeasurementEventArgs = @"event_args"; 33| |static NSString *const FBSDKMeasurementEventPrefix = @"bf_"; 34| | 35| |@implementation FBSDKMeasurementEventListener 36| | 37| |+ (instancetype)defaultListener 38| 0|{ 39| 0| static dispatch_once_t dispatchOnceLocker = 0; 40| 0| static FBSDKMeasurementEventListener *defaultListener = nil; 41| 0| dispatch_once(&dispatchOnceLocker, ^{ 42| 0| defaultListener = [self new]; 43| 0| NSNotificationCenter *center = [NSNotificationCenter defaultCenter]; 44| 0| [center addObserver:defaultListener 45| 0| selector:@selector(logFBAppEventForNotification:) 46| 0| name:FBSDKMeasurementEventNotification 47| 0| object:nil]; 48| 0| }); 49| 0| return defaultListener; 50| 0|} 51| | 52| |- (void)logFBAppEventForNotification:(NSNotification *)note 53| 0|{ 54| | // when catch al_nav_in event, we set source application for FBAppEvents. 55| 0| if ([note.userInfo[FBSDKMeasurementEventName] isEqualToString:@"al_nav_in"]) { 56| 0| NSString *sourceApplication = note.userInfo[FBSDKMeasurementEventArgs][@"sourceApplication"]; 57| 0| if (sourceApplication) { 58| 0| [FBSDKAppEvents.singleton setSourceApplication:sourceApplication isFromAppLink:YES]; 59| 0| } 60| 0| } 61| 0| NSDictionary *eventArgs = note.userInfo[FBSDKMeasurementEventArgs]; 62| 0| NSMutableDictionary *logData = [NSMutableDictionary new]; 63| 0| for (NSString *key in eventArgs.allKeys) { 64| 0| NSError *error = nil; 65| 0| NSRegularExpression *regex = [NSRegularExpression regularExpressionWithPattern:@"[^0-9a-zA-Z _-]" options:0 error:&error]; 66| 0| NSString *safeKey = [regex stringByReplacingMatchesInString:key 67| 0| options:0 68| 0| range:NSMakeRange(0, key.length) 69| 0| withTemplate:@"-"]; 70| 0| safeKey = [safeKey stringByTrimmingCharactersInSet:[NSCharacterSet characterSetWithCharactersInString:@" -"]]; 71| 0| [FBSDKTypeUtility dictionary:logData setObject:eventArgs[key] forKey:safeKey]; 72| 0| } 73| 0| [FBSDKAppEvents logInternalEvent:[FBSDKMeasurementEventPrefix stringByAppendingString:note.userInfo[FBSDKMeasurementEventName]] 74| 0| parameters:logData 75| 0| isImplicitlyLogged:YES]; 76| 0|} 77| | 78| |- (void)dealloc 79| 0|{ 80| 0| [[NSNotificationCenter defaultCenter] removeObserver:self]; 81| 0|} 82| | 83| |@end 84| | 85| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKAccessToken.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKAccessToken.h" 20| |#import "FBSDKAccessToken+Internal.h" 21| |#import "FBSDKAccessToken+TokenStringProviding.h" 22| | 23| |#import "FBSDKCoreKitBasicsImport.h" 24| |#import "FBSDKGraphRequestPiggybackManager.h" 25| |#import "FBSDKInternalUtility.h" 26| |#import "FBSDKMath.h" 27| | 28| |#if __IPHONE_OS_VERSION_MAX_ALLOWED >= __IPHONE_10_0 29| | 30| |NSNotificationName const FBSDKAccessTokenDidChangeNotification = @"com.facebook.sdk.FBSDKAccessTokenData.FBSDKAccessTokenDidChangeNotification"; 31| | 32| |#else 33| | 34| |NSString *const FBSDKAccessTokenDidChangeNotification = @"com.facebook.sdk.FBSDKAccessTokenData.FBSDKAccessTokenDidChangeNotification"; 35| | 36| |#endif 37| | 38| |NSString *const FBSDKAccessTokenDidChangeUserIDKey = @"FBSDKAccessTokenDidChangeUserIDKey"; 39| |NSString *const FBSDKAccessTokenChangeNewKey = @"FBSDKAccessToken"; 40| |NSString *const FBSDKAccessTokenChangeOldKey = @"FBSDKAccessTokenOld"; 41| |NSString *const FBSDKAccessTokenDidExpireKey = @"FBSDKAccessTokenDidExpireKey"; 42| | 43| |static FBSDKAccessToken *g_currentAccessToken; 44| |static id g_tokenCache; 45| |static id g_connectionFactory; 46| | 47| 0|#define FBSDK_ACCESSTOKEN_TOKENSTRING_KEY @"tokenString" 48| 0|#define FBSDK_ACCESSTOKEN_PERMISSIONS_KEY @"permissions" 49| 0|#define FBSDK_ACCESSTOKEN_DECLINEDPERMISSIONS_KEY @"declinedPermissions" 50| 0|#define FBSDK_ACCESSTOKEN_EXPIREDPERMISSIONS_KEY @"expiredPermissions" 51| 0|#define FBSDK_ACCESSTOKEN_APPID_KEY @"appID" 52| 0|#define FBSDK_ACCESSTOKEN_USERID_KEY @"userID" 53| 0|#define FBSDK_ACCESSTOKEN_REFRESHDATE_KEY @"refreshDate" 54| 0|#define FBSDK_ACCESSTOKEN_EXPIRATIONDATE_KEY @"expirationDate" 55| 0|#define FBSDK_ACCESSTOKEN_DATA_EXPIRATIONDATE_KEY @"dataAccessExpirationDate" 56| 0|#define FBSDK_ACCESSTOKEN_GRAPH_DOMAIN_KEY @"graphDomain" 57| | 58| |@implementation FBSDKAccessToken 59| | 60| |- (instancetype)initWithTokenString:(NSString *)tokenString 61| | permissions:(NSArray *)permissions 62| | declinedPermissions:(NSArray *)declinedPermissions 63| | expiredPermissions:(NSArray *)expiredPermissions 64| | appID:(NSString *)appID 65| | userID:(NSString *)userID 66| | expirationDate:(NSDate *)expirationDate 67| | refreshDate:(NSDate *)refreshDate 68| | dataAccessExpirationDate:(NSDate *)dataAccessExpirationDate 69| 0|{ 70| 0| if ((self = [super init])) { 71| 0| _tokenString = [tokenString copy]; 72| 0| _permissions = [NSSet setWithArray:permissions]; 73| 0| _declinedPermissions = [NSSet setWithArray:declinedPermissions]; 74| 0| _expiredPermissions = [NSSet setWithArray:expiredPermissions]; 75| 0| _appID = [appID copy]; 76| 0| _userID = [userID copy]; 77| 0| _expirationDate = [expirationDate copy] ?: [NSDate distantFuture]; 78| 0| _refreshDate = [refreshDate copy] ?: [NSDate date]; 79| 0| _dataAccessExpirationDate = [dataAccessExpirationDate copy] ?: [NSDate distantFuture]; 80| 0| } 81| 0| return self; 82| 0|} 83| | 84| |- (instancetype)initWithTokenString:(NSString *)tokenString 85| | permissions:(NSArray *)permissions 86| | declinedPermissions:(NSArray *)declinedPermissions 87| | expiredPermissions:(NSArray *)expiredPermissions 88| | appID:(NSString *)appID 89| | userID:(NSString *)userID 90| | expirationDate:(NSDate *)expirationDate 91| | refreshDate:(NSDate *)refreshDate 92| | dataAccessExpirationDate:(NSDate *)dataAccessExpirationDate 93| | graphDomain:(NSString *)graphDomain 94| 0|{ 95| 0| FBSDKAccessToken *accessToken = 96| 0| [self 97| 0| initWithTokenString:tokenString 98| 0| permissions:permissions 99| 0| declinedPermissions:declinedPermissions 100| 0| expiredPermissions:expiredPermissions 101| 0| appID:appID 102| 0| userID:userID 103| 0| expirationDate:expirationDate 104| 0| refreshDate:refreshDate 105| 0| dataAccessExpirationDate:dataAccessExpirationDate]; 106| | 107| 0| if (accessToken != nil) { 108| 0| accessToken->_graphDomain = [graphDomain copy]; 109| 0| } 110| | 111| 0| return accessToken; 112| 0|} 113| | 114| |- (BOOL)hasGranted:(NSString *)permission 115| 0|{ 116| 0| return [self.permissions containsObject:permission]; 117| 0|} 118| | 119| |- (BOOL)isDataAccessExpired 120| 0|{ 121| 0| return [self.dataAccessExpirationDate compare:NSDate.date] == NSOrderedAscending; 122| 0|} 123| | 124| |- (BOOL)isExpired 125| 0|{ 126| 0| return [self.expirationDate compare:NSDate.date] == NSOrderedAscending; 127| 0|} 128| | 129| |+ (id)tokenCache 130| 0|{ 131| 0| return g_tokenCache; 132| 0|} 133| | 134| |+ (void)setTokenCache:(id)cache 135| 0|{ 136| 0| if (g_tokenCache != cache) { 137| 0| g_tokenCache = cache; 138| 0| } 139| 0|} 140| | 141| |+ (void)resetTokenCache 142| 0|{ 143| 0| [FBSDKAccessToken setTokenCache:nil]; 144| 0|} 145| | 146| |+ (FBSDKAccessToken *)currentAccessToken 147| 0|{ 148| 0| return g_currentAccessToken; 149| 0|} 150| | 151| |+ (NSString *)tokenString 152| 0|{ 153| 0| return FBSDKAccessToken.currentAccessToken.tokenString; 154| 0|} 155| | 156| |+ (void)setCurrentAccessToken:(FBSDKAccessToken *)token 157| 0|{ 158| 0| [FBSDKAccessToken setCurrentAccessToken:token shouldDispatchNotif:YES]; 159| 0|} 160| | 161| |+ (void)setCurrentAccessToken:(nullable FBSDKAccessToken *)token 162| | shouldDispatchNotif:(BOOL)shouldDispatchNotif 163| 0|{ 164| 0| if (token != g_currentAccessToken) { 165| 0| NSMutableDictionary *userInfo = [NSMutableDictionary dictionary]; 166| 0| [FBSDKTypeUtility dictionary:userInfo setObject:token forKey:FBSDKAccessTokenChangeNewKey]; 167| 0| [FBSDKTypeUtility dictionary:userInfo setObject:g_currentAccessToken forKey:FBSDKAccessTokenChangeOldKey]; 168| | // We set this flag also when the current Access Token was not valid, since there might be legacy code relying on it 169| 0| if (![g_currentAccessToken.userID isEqualToString:token.userID] || !self.isCurrentAccessTokenActive) { 170| 0| userInfo[FBSDKAccessTokenDidChangeUserIDKey] = @YES; 171| 0| } 172| | 173| 0| g_currentAccessToken = token; 174| | 175| | // Only need to keep current session in web view for the case when token is current 176| | // When token is abandoned cookies must to be cleaned up immediately 177| 0| if (token == nil) { 178| 0| [FBSDKInternalUtility deleteFacebookCookies]; 179| 0| } 180| | 181| 0| self.tokenCache.accessToken = token; 182| 0| if (shouldDispatchNotif) { 183| 0| [[NSNotificationCenter defaultCenter] postNotificationName:FBSDKAccessTokenDidChangeNotification 184| 0| object:[self class] 185| 0| userInfo:userInfo]; 186| 0| } 187| 0| } 188| 0|} 189| | 190| |+ (BOOL)isCurrentAccessTokenActive 191| 0|{ 192| 0| FBSDKAccessToken *currentAccessToken = [self currentAccessToken]; 193| 0| return currentAccessToken != nil && !currentAccessToken.isExpired; 194| 0|} 195| | 196| |+ (void)refreshCurrentAccessToken:(FBSDKGraphRequestBlock)completionHandler 197| 0|{ 198| 0| FBSDKGraphRequestCompletion completion = ^void (id connection, id result, NSError *error) { 199| 0| if (completionHandler) { 200| 0| completionHandler(FBSDK_CAST_TO_CLASS_OR_NIL(connection, FBSDKGraphRequestConnection), result, error); 201| 0| } 202| 0| }; 203| 0| [self refreshCurrentAccessTokenWithCompletion:completion]; 204| 0|} 205| | 206| |+ (void)refreshCurrentAccessTokenWithCompletion:(nullable FBSDKGraphRequestCompletion)completion 207| 0|{ 208| 0| if ([FBSDKAccessToken currentAccessToken]) { 209| 0| id connection = [FBSDKAccessToken.connectionFactory createGraphRequestConnection]; 210| 0| [FBSDKGraphRequestPiggybackManager addRefreshPiggyback:connection permissionHandler:completion]; 211| 0| [connection start]; 212| 0| } else if (completion) { 213| 0| completion( 214| 0| nil, 215| 0| nil, 216| 0| [FBSDKError 217| 0| errorWithCode:FBSDKErrorAccessTokenRequired 218| 0| message:@"No current access token to refresh"] 219| 0| ); 220| 0| } 221| 0|} 222| | 223| |+ (id)connectionFactory 224| 0|{ 225| 0| return g_connectionFactory; 226| 0|} 227| | 228| |+ (void)setConnectionFactory:(nonnull id)connectionFactory 229| 0|{ 230| 0| if (g_connectionFactory != connectionFactory) { 231| 0| g_connectionFactory = connectionFactory; 232| 0| } 233| 0|} 234| | 235| |#pragma mark - Equality 236| | 237| |- (NSUInteger)hash 238| 0|{ 239| 0| #pragma clang diagnostic push 240| 0| #pragma clang diagnostic ignored "-Wdeprecated-declarations" 241| 0| NSUInteger subhashes[] = { 242| 0| self.tokenString.hash, 243| 0| self.permissions.hash, 244| 0| self.declinedPermissions.hash, 245| 0| self.expiredPermissions.hash, 246| 0| self.appID.hash, 247| 0| self.userID.hash, 248| 0| self.refreshDate.hash, 249| 0| self.expirationDate.hash, 250| 0| self.dataAccessExpirationDate.hash, 251| 0| self.graphDomain.hash 252| 0| }; 253| 0| #pragma clange diagnostic pop 254| | 255| 0| return [FBSDKMath hashWithIntegerArray:subhashes count:sizeof(subhashes) / sizeof(subhashes[0])]; 256| 0|} 257| | 258| |- (BOOL)isEqual:(id)object 259| 0|{ 260| 0| if (self == object) { 261| 0| return YES; 262| 0| } 263| 0| if (![object isKindOfClass:[FBSDKAccessToken class]]) { 264| 0| return NO; 265| 0| } 266| 0| return [self isEqualToAccessToken:(FBSDKAccessToken *)object]; 267| 0|} 268| | 269| |- (BOOL)isEqualToAccessToken:(FBSDKAccessToken *)token 270| 0|{ 271| 0| #pragma clang diagnostic push 272| 0| #pragma clang diagnostic ignored "-Wdeprecated-declarations" 273| 0| return (token 274| 0| && [FBSDKInternalUtility object:self.tokenString isEqualToObject:token.tokenString] 275| 0| && [FBSDKInternalUtility object:self.permissions isEqualToObject:token.permissions] 276| 0| && [FBSDKInternalUtility object:self.declinedPermissions isEqualToObject:token.declinedPermissions] 277| 0| && [FBSDKInternalUtility object:self.expiredPermissions isEqualToObject:token.expiredPermissions] 278| 0| && [FBSDKInternalUtility object:self.appID isEqualToObject:token.appID] 279| 0| && [FBSDKInternalUtility object:self.userID isEqualToObject:token.userID] 280| 0| && [FBSDKInternalUtility object:self.refreshDate isEqualToObject:token.refreshDate] 281| 0| && [FBSDKInternalUtility object:self.expirationDate isEqualToObject:token.expirationDate] 282| 0| && [FBSDKInternalUtility object:self.dataAccessExpirationDate isEqualToObject:token.dataAccessExpirationDate] 283| 0| && [FBSDKInternalUtility object:self.graphDomain isEqualToObject:token.graphDomain]); 284| 0| #pragma clange diagnostic pop 285| 0|} 286| | 287| |#pragma mark - NSCopying 288| | 289| |- (id)copyWithZone:(NSZone *)zone 290| 0|{ 291| | // we're immutable. 292| 0| return self; 293| 0|} 294| | 295| |#pragma mark NSCoding 296| | 297| |+ (BOOL)supportsSecureCoding 298| 0|{ 299| 0| return YES; 300| 0|} 301| | 302| |- (instancetype)initWithCoder:(NSCoder *)decoder 303| 0|{ 304| 0| NSString *appID = [decoder decodeObjectOfClass:[NSString class] forKey:FBSDK_ACCESSTOKEN_APPID_KEY]; 305| 0| NSSet *declinedPermissions = [decoder decodeObjectOfClass:[NSSet class] forKey:FBSDK_ACCESSTOKEN_DECLINEDPERMISSIONS_KEY]; 306| 0| NSSet *expiredPermissions = [decoder decodeObjectOfClass:[NSSet class] forKey:FBSDK_ACCESSTOKEN_EXPIREDPERMISSIONS_KEY]; 307| 0| NSSet *permissions = [decoder decodeObjectOfClass:[NSSet class] forKey:FBSDK_ACCESSTOKEN_PERMISSIONS_KEY]; 308| 0| NSString *tokenString = [decoder decodeObjectOfClass:[NSString class] forKey:FBSDK_ACCESSTOKEN_TOKENSTRING_KEY]; 309| 0| NSString *userID = [decoder decodeObjectOfClass:[NSString class] forKey:FBSDK_ACCESSTOKEN_USERID_KEY]; 310| 0| NSDate *refreshDate = [decoder decodeObjectOfClass:[NSDate class] forKey:FBSDK_ACCESSTOKEN_REFRESHDATE_KEY]; 311| 0| NSDate *expirationDate = [decoder decodeObjectOfClass:[NSDate class] forKey:FBSDK_ACCESSTOKEN_EXPIRATIONDATE_KEY]; 312| 0| NSDate *dataAccessExpirationDate = [decoder decodeObjectOfClass:[NSDate class] forKey:FBSDK_ACCESSTOKEN_DATA_EXPIRATIONDATE_KEY]; 313| 0| NSString *graphDomain = [decoder decodeObjectOfClass:[NSString class] forKey:FBSDK_ACCESSTOKEN_GRAPH_DOMAIN_KEY]; 314| | 315| 0| return 316| 0| [self 317| 0| initWithTokenString:tokenString 318| 0| permissions:permissions.allObjects 319| 0| declinedPermissions:declinedPermissions.allObjects 320| 0| expiredPermissions:expiredPermissions.allObjects 321| 0| appID:appID 322| 0| userID:userID 323| 0| expirationDate:expirationDate 324| 0| refreshDate:refreshDate 325| 0| dataAccessExpirationDate:dataAccessExpirationDate 326| 0| graphDomain:graphDomain]; 327| 0|} 328| | 329| |- (void)encodeWithCoder:(NSCoder *)encoder 330| 0|{ 331| 0| [encoder encodeObject:self.appID forKey:FBSDK_ACCESSTOKEN_APPID_KEY]; 332| 0| [encoder encodeObject:self.declinedPermissions forKey:FBSDK_ACCESSTOKEN_DECLINEDPERMISSIONS_KEY]; 333| 0| [encoder encodeObject:self.expiredPermissions forKey:FBSDK_ACCESSTOKEN_EXPIREDPERMISSIONS_KEY]; 334| 0| [encoder encodeObject:self.permissions forKey:FBSDK_ACCESSTOKEN_PERMISSIONS_KEY]; 335| 0| [encoder encodeObject:self.tokenString forKey:FBSDK_ACCESSTOKEN_TOKENSTRING_KEY]; 336| 0| [encoder encodeObject:self.userID forKey:FBSDK_ACCESSTOKEN_USERID_KEY]; 337| 0| [encoder encodeObject:self.expirationDate forKey:FBSDK_ACCESSTOKEN_EXPIRATIONDATE_KEY]; 338| 0| [encoder encodeObject:self.refreshDate forKey:FBSDK_ACCESSTOKEN_REFRESHDATE_KEY]; 339| 0| [encoder encodeObject:self.dataAccessExpirationDate forKey:FBSDK_ACCESSTOKEN_DATA_EXPIRATIONDATE_KEY]; 340| 0| #pragma clang diagnostic push 341| 0| #pragma clang diagnostic ignored "-Wdeprecated-declarations" 342| 0| [encoder encodeObject:self.graphDomain forKey:FBSDK_ACCESSTOKEN_GRAPH_DOMAIN_KEY]; 343| 0| #pragma clange diagnostic pop 344| 0|} 345| | 346| |#pragma mark - Testability 347| | 348| |#if DEBUG 349| | #if FBSDKTEST 350| | 351| |+ (void)resetCurrentAccessTokenCache 352| 0|{ 353| 0| g_currentAccessToken = nil; 354| 0|} 355| | 356| | #endif 357| |#endif 358| | 359| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKApplicationDelegate.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKApplicationDelegate.h" 20| |#import "FBSDKApplicationDelegate+Internal.h" 21| | 22| |#import 23| | 24| |#import "FBSDKAccessToken+Internal.h" 25| |#import "FBSDKAccessTokenExpirer.h" 26| |#import "FBSDKAppEvents+AppEventsConfiguring.h" 27| |#import "FBSDKAppEvents+ApplicationActivating.h" 28| |#import "FBSDKAppEvents+ApplicationLifecycleObserving.h" 29| |#import "FBSDKAppEvents+ApplicationStateSetting.h" 30| |#import "FBSDKAppEvents+EventLogging.h" 31| |#import "FBSDKAppEvents+Internal.h" 32| |#import "FBSDKAppEvents+SourceApplicationTracking.h" 33| |#import "FBSDKAppEventsConfigurationManager.h" 34| |#import "FBSDKAppEventsState.h" 35| |#import "FBSDKAppEventsStateFactory.h" 36| |#import "FBSDKAppEventsStateManager+AppEventsStatePersisting.h" 37| |#import "FBSDKAppEventsUtility+AdvertiserIDProviding.h" 38| |#import "FBSDKApplicationLifecycleObserving.h" 39| |#import "FBSDKAtePublisherFactory.h" 40| |#import "FBSDKAuthenticationStatusUtility.h" 41| |#import "FBSDKAuthenticationToken+AuthenticationTokenProtocols.h" 42| |#import "FBSDKAuthenticationToken+Internal.h" 43| |#import "FBSDKBridgeAPI+ApplicationObserving.h" 44| |#import "FBSDKButton+Subclass.h" 45| |#import "FBSDKCoreKitBasicsImport.h" 46| |#import "FBSDKCrashShield+Internal.h" 47| |#import "FBSDKDynamicFrameworkLoader.h" 48| |#import "FBSDKError.h" 49| |#import "FBSDKErrorReport+ErrorReporting.h" 50| |#import "FBSDKEventDeactivationManager+Protocols.h" 51| |#import "FBSDKFeatureManager+FeatureChecking.h" 52| |#import "FBSDKFeatureManager+FeatureDisabling.h" 53| |#import "FBSDKGateKeeperManager.h" 54| |#import "FBSDKGraphRequestFactory.h" 55| |#import "FBSDKGraphRequestPiggybackManager+Internal.h" 56| |#import "FBSDKInstrumentManager.h" 57| |#import "FBSDKInternalUtility.h" 58| |#import "FBSDKLogger+Logging.h" 59| |#import "FBSDKPaymentObserver.h" 60| |#import "FBSDKPaymentObserver+PaymentObserving.h" 61| |#import "FBSDKProfileProtocols.h" 62| |#import "FBSDKRestrictiveDataFilterManager+Protocols.h" 63| |#import "FBSDKServerConfiguration.h" 64| |#import "FBSDKServerConfigurationManager+ServerConfigurationProviding.h" 65| |#import "FBSDKSettings+Internal.h" 66| |#import "FBSDKSettings+SettingsLogging.h" 67| |#import "FBSDKSettings+SettingsProtocols.h" 68| |#import "FBSDKSettingsLogging.h" 69| |#import "FBSDKSwizzler+Swizzling.h" 70| |#import "FBSDKTimeSpentRecordingFactory.h" 71| |#import "FBSDKTokenCache.h" 72| |#import "GraphAPI/FBSDKGraphRequest.h" 73| |#import "NSNotificationCenter+Extensions.h" 74| |#import "NSUserDefaults+FBSDKDataPersisting.h" 75| | 76| |#if !TARGET_OS_TV 77| | #import "FBSDKAEMReporter+Internal.h" 78| | #import "FBSDKAppLinkUtility+Internal.h" 79| | #import "FBSDKBackgroundEventLogger.h" 80| | #import "FBSDKBackgroundEventLogging.h" 81| | #import "FBSDKCodelessIndexer+Internal.h" 82| | #import "FBSDKContainerViewController.h" 83| | #import "FBSDKFeatureExtractor.h" 84| | #import "FBSDKFeatureExtractor+Internal.h" 85| | #import "FBSDKMeasurementEventListener.h" 86| | #import "FBSDKMetadataIndexer+MetadataIndexing.h" 87| | #import "FBSDKModelManager.h" 88| | #import "FBSDKModelManager+RulesFromKeyProvider.h" 89| | #import "FBSDKProfile+Internal.h" 90| | #import "FBSDKSKAdNetworkReporter+Internal.h" 91| | #import "FBSDKURLOpener.h" 92| | #import "FBSDKWebDialogView.h" 93| | #import "FBSDKWebViewFactory.h" 94| | #import "SKAdNetwork+ConversionValueUpdating.h" 95| | #import "UIApplication+URLOpener.h" 96| |#endif 97| | 98| |static NSString *const FBSDKAppLinkInboundEvent = @"fb_al_inbound"; 99| |static NSString *const FBSDKKitsBitmaskKey = @"com.facebook.sdk.kits.bitmask"; 100| |static BOOL hasInitializeBeenCalled = NO; 101| |static UIApplicationState _applicationState; 102| | 103| |@interface FBSDKApplicationDelegate () 104| | 105| |@property (nonnull, nonatomic, readonly) id featureChecker; 106| |@property (nonnull, nonatomic, readonly) Class tokenWallet; 107| |@property (nonnull, nonatomic, readonly) id settings; 108| |@property (nonnull, nonatomic, readonly) id notificationObserver; 109| |@property (nonnull, nonatomic, readonly) NSHashTable> *applicationObservers; 110| |@property (nonnull, nonatomic, readonly) id appEvents; 111| |@property (nonnull, nonatomic, readonly) Class serverConfigurationProvider; 112| |@property (nonnull, nonatomic, readonly) id store; 113| |@property (nonnull, nonatomic, readonly) Class authenticationTokenWallet; 114| |@property (nonnull, nonatomic, readonly) FBSDKAccessTokenExpirer *accessTokenExpirer; 115| | 116| |#if !TARGET_OS_TV 117| |@property (nonnull, nonatomic, readonly) Class profileProvider; 118| |@property (nonnull, nonatomic, readonly) id backgroundEventLogger; 119| |#endif 120| | 121| |@property (nonatomic) BOOL isAppLaunched; 122| | 123| |@end 124| | 125| |@implementation FBSDKApplicationDelegate 126| | 127| |#pragma mark - Class Methods 128| | 129| |+ (void)initializeSDK:(NSDictionary *)launchOptions 130| 0|{ 131| 0| [self.sharedInstance initializeSDKWithLaunchOptions:launchOptions]; 132| 0|} 133| | 134| |+ (FBSDKApplicationDelegate *)sharedInstance 135| 0|{ 136| 0| static FBSDKApplicationDelegate *_sharedInstance; 137| 0| static dispatch_once_t onceToken; 138| 0| dispatch_once(&onceToken, ^{ 139| 0| _sharedInstance = [self new]; 140| 0| }); 141| 0| return _sharedInstance; 142| 0|} 143| | 144| |#pragma mark - Object Lifecycle 145| | 146| |- (instancetype)init 147| 0|{ 148| |#if TARGET_OS_TV 149| | return [self initWithNotificationCenter:NSNotificationCenter.defaultCenter 150| | tokenWallet:FBSDKAccessToken.class 151| | settings:FBSDKSettings.sharedSettings 152| | featureChecker:FBSDKFeatureManager.shared 153| | appEvents:FBSDKAppEvents.singleton 154| | serverConfigurationProvider:FBSDKServerConfigurationManager.class 155| | store:NSUserDefaults.standardUserDefaults 156| | authenticationTokenWallet:FBSDKAuthenticationToken.class]; 157| |#else 158| 0| FBSDKBackgroundEventLogger *backgroundEventLogger = [[FBSDKBackgroundEventLogger alloc] initWithInfoDictionaryProvider:NSBundle.mainBundle 159| 0| eventLogger:FBSDKAppEvents.singleton]; 160| 0| return [self initWithNotificationCenter:NSNotificationCenter.defaultCenter 161| 0| tokenWallet:FBSDKAccessToken.class 162| 0| settings:FBSDKSettings.sharedSettings 163| 0| featureChecker:FBSDKFeatureManager.shared 164| 0| appEvents:FBSDKAppEvents.singleton 165| 0| serverConfigurationProvider:FBSDKServerConfigurationManager.class 166| 0| store:NSUserDefaults.standardUserDefaults 167| 0| authenticationTokenWallet:FBSDKAuthenticationToken.class 168| 0| profileProvider:FBSDKProfile.class 169| 0| backgroundEventLogger:backgroundEventLogger]; 170| 0|#endif 171| 0|} 172| | 173| |#if TARGET_OS_TV 174| |- (instancetype)initWithNotificationCenter:(id)notificationCenter 175| | tokenWallet:(Class)tokenWallet 176| | settings:(id)settings 177| | featureChecker:(id)featureChecker 178| | appEvents:(id)appEvents 179| | serverConfigurationProvider:(Class)serverConfigurationProvider 180| | store:(id)store 181| | authenticationTokenWallet:(Class)authenticationTokenWallet 182| |{ 183| | if ((self = [super init]) != nil) { 184| | _applicationObservers = [NSHashTable new]; 185| | _notificationObserver = notificationCenter; 186| | _tokenWallet = tokenWallet; 187| | _settings = settings; 188| | _featureChecker = featureChecker; 189| | _appEvents = appEvents; 190| | _serverConfigurationProvider = serverConfigurationProvider; 191| | _store = store; 192| | _authenticationTokenWallet = authenticationTokenWallet; 193| | _accessTokenExpirer = [[FBSDKAccessTokenExpirer alloc] initWithNotificationCenter:notificationCenter]; 194| | } 195| | return self; 196| |} 197| | 198| |#else 199| |- (instancetype)initWithNotificationCenter:(id)notificationCenter 200| | tokenWallet:(Class)tokenWallet 201| | settings:(id)settings 202| | featureChecker:(id)featureChecker 203| | appEvents:(id)appEvents 204| | serverConfigurationProvider:(Class)serverConfigurationProvider 205| | store:(id)store 206| | authenticationTokenWallet:(Class)authenticationTokenWallet 207| | profileProvider:(Class)profileProvider 208| | backgroundEventLogger:(id)backgroundEventLogger 209| 0|{ 210| 0| if ((self = [super init]) != nil) { 211| 0| _applicationObservers = [NSHashTable new]; 212| 0| _notificationObserver = notificationCenter; 213| 0| _tokenWallet = tokenWallet; 214| 0| _settings = settings; 215| 0| _featureChecker = featureChecker; 216| 0| _appEvents = appEvents; 217| 0| _serverConfigurationProvider = serverConfigurationProvider; 218| 0| _store = store; 219| 0| _authenticationTokenWallet = authenticationTokenWallet; 220| 0| _profileProvider = profileProvider; 221| 0| _backgroundEventLogger = backgroundEventLogger; 222| 0| _accessTokenExpirer = [[FBSDKAccessTokenExpirer alloc] initWithNotificationCenter:notificationCenter]; 223| 0| } 224| 0| return self; 225| 0|} 226| | 227| |#endif 228| | 229| |- (void)initializeSDKWithLaunchOptions:(NSDictionary *)launchOptions 230| 0|{ 231| 0| if (hasInitializeBeenCalled) { 232| | // Do nothing if initialized already 233| 0| return; 234| 0| } else { 235| 0| hasInitializeBeenCalled = YES; 236| 0| } 237| | 238| | // 239| | // DO NOT MOVE THIS CALL 240| | // Dependencies MUST be configured before they are invoked 241| | // 242| 0| [self configureDependencies]; 243| | 244| 0| id const settingsLogger = self.settings; 245| 0| [settingsLogger logWarnings]; 246| 0| [settingsLogger logIfSDKSettingsChanged]; 247| 0| [settingsLogger recordInstall]; 248| | 249| 0| [self addObservers]; 250| | 251| 0| [self.appEvents startObservingApplicationLifecycleNotifications]; 252| | 253| 0| [self application:[UIApplication sharedApplication] didFinishLaunchingWithOptions:launchOptions]; 254| | 255| | // In case of sdk autoInit enabled sdk expects one appDidBecomeActive notification after app launch and has some logic to ignore it. 256| | // if sdk autoInit disabled app won't receive appDidBecomeActive on app launch and will ignore the first one it gets instead of handling it. 257| | // Send first applicationDidBecomeActive notification manually 258| 0| if ([UIApplication sharedApplication].applicationState == UIApplicationStateActive) { 259| 0| [self applicationDidBecomeActive:nil]; 260| 0| } 261| | 262| 0| [self.featureChecker checkFeature:FBSDKFeatureInstrument completionBlock:^(BOOL enabled) { 263| 0| if (enabled) { 264| 0| [FBSDKInstrumentManager.shared enable]; 265| 0| } 266| 0| }]; 267| | 268| 0|#if !TARGET_OS_TV 269| 0| [self.backgroundEventLogger logBackgroundRefresStatus:[UIApplication.sharedApplication backgroundRefreshStatus]]; 270| | // Register Listener for App Link measurement events 271| 0| [FBSDKMeasurementEventListener defaultListener]; 272| 0| [self _logIfAutoAppLinkEnabled]; 273| 0|#endif 274| | // Set the SourceApplication for time spent data. This is not going to update the value if the app has already launched. 275| 0| [self.appEvents setSourceApplication:launchOptions[UIApplicationLaunchOptionsSourceApplicationKey] 276| 0| openURL:launchOptions[UIApplicationLaunchOptionsURLKey]]; 277| | // Register on UIApplicationDidEnterBackgroundNotification events to reset source application data when app backgrounds. 278| 0| [self.appEvents registerAutoResetSourceApplication]; 279| | 280| 0| [FBSDKInternalUtility validateFacebookReservedURLSchemes]; 281| 0|} 282| | 283| |- (void)addObservers 284| 0|{ 285| 0| id const observer = self.notificationObserver; 286| 0| [observer addObserver:self 287| 0| selector:@selector(applicationDidEnterBackground:) 288| 0| name:UIApplicationDidEnterBackgroundNotification 289| 0| object:nil]; 290| 0| [observer addObserver:self 291| 0| selector:@selector(applicationDidBecomeActive:) 292| 0| name:UIApplicationDidBecomeActiveNotification 293| 0| object:nil]; 294| 0| [observer addObserver:self 295| 0| selector:@selector(applicationWillResignActive:) 296| 0| name:UIApplicationWillResignActiveNotification 297| 0| object:nil]; 298| 0|#if !TARGET_OS_TV 299| 0| [self addObserver:FBSDKBridgeAPI.sharedInstance]; 300| 0|#endif 301| 0|} 302| | 303| |- (void)dealloc 304| 0|{ 305| 0| [self.notificationObserver removeObserver:self]; 306| 0|} 307| | 308| |#pragma mark - UIApplicationDelegate 309| | 310| |#if __IPHONE_OS_VERSION_MAX_ALLOWED> __IPHONE_9_0 311| |- (BOOL)application:(UIApplication *)application 312| | openURL:(NSURL *)url 313| | options:(NSDictionary *)options 314| 0|{ 315| 0| return [self application:application 316| 0| openURL:url 317| 0| sourceApplication:options[UIApplicationOpenURLOptionsSourceApplicationKey] 318| 0| annotation:options[UIApplicationOpenURLOptionsAnnotationKey]]; 319| | 320| 0| return NO; 321| 0|} 322| | 323| |#endif 324| | 325| |- (BOOL)application:(UIApplication *)application 326| | openURL:(NSURL *)url 327| | sourceApplication:(NSString *)sourceApplication 328| | annotation:(id)annotation 329| 0|{ 330| 0| if (sourceApplication != nil && ![sourceApplication isKindOfClass:[NSString class]]) { 331| 0| @throw [NSException exceptionWithName:NSInvalidArgumentException 332| 0| reason:@"Expected 'sourceApplication' to be NSString. Please verify you are passing in 'sourceApplication' from your app delegate (not the UIApplication* parameter). If your app delegate implements iOS 9's application:openURL:options:, you should pass in options[UIApplicationOpenURLOptionsSourceApplicationKey]. " 333| 0| userInfo:nil]; 334| 0| } 335| 0| [self.appEvents setSourceApplication:sourceApplication openURL:url]; 336| | 337| 0|#if !TARGET_OS_TV 338| 0| [self.featureChecker checkFeature:FBSDKFeatureAEM completionBlock:^(BOOL enabled) { 339| 0| if (enabled) { 340| 0| [FBSDKAEMReporter enable]; 341| 0| [FBSDKAEMReporter handleURL:url]; 342| 0| } 343| 0| }]; 344| 0|#endif 345| | 346| 0| BOOL handled = NO; 347| 0| NSArray> *observers = [self.applicationObservers allObjects]; 348| 0| for (id observer in observers) { 349| 0| if ([observer respondsToSelector:@selector(application:openURL:sourceApplication:annotation:)]) { 350| 0| if ([observer application:application 351| 0| openURL:url 352| 0| sourceApplication:sourceApplication 353| 0| annotation:annotation]) { 354| 0| handled = YES; 355| 0| } 356| 0| } 357| 0| } 358| | 359| 0| if (handled) { 360| 0| return YES; 361| 0| } 362| | 363| 0| [self _logIfAppLinkEvent:url]; 364| | 365| 0| return NO; 366| 0|} 367| | 368| |- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions 369| 0|{ 370| 0| if (self.isAppLaunched) { 371| 0| return NO; 372| 0| } 373| | 374| 0| if (!hasInitializeBeenCalled) { 375| 0| [self initializeSDKWithLaunchOptions:launchOptions]; 376| 0| } 377| | 378| 0| self.isAppLaunched = YES; 379| | 380| | // Retrieve cached tokens 381| 0| FBSDKAccessToken *cachedToken = [[self.tokenWallet tokenCache] accessToken]; 382| 0| [self.tokenWallet setCurrentAccessToken:cachedToken]; 383| | 384| | // fetch app settings 385| 0| [self.serverConfigurationProvider loadServerConfigurationWithCompletionBlock:NULL]; 386| | 387| 0| if (self.settings.isAutoLogAppEventsEnabled) { 388| 0| [self _logSDKInitialize]; 389| 0| } 390| 0|#if !TARGET_OS_TV 391| 0| FBSDKProfile *cachedProfile = [self.profileProvider fetchCachedProfile]; 392| 0| [self.profileProvider setCurrentProfile:cachedProfile]; 393| | 394| 0| FBSDKAuthenticationToken *cachedAuthToken = [[self.authenticationTokenWallet tokenCache] authenticationToken]; 395| 0| [self.authenticationTokenWallet setCurrentAuthenticationToken:cachedAuthToken]; 396| 0| [FBSDKAuthenticationStatusUtility checkAuthenticationStatus]; 397| 0|#endif 398| 0| NSArray> *observers = [self.applicationObservers allObjects]; 399| 0| BOOL handled = NO; 400| 0| for (id observer in observers) { 401| 0| if ([observer respondsToSelector:@selector(application:didFinishLaunchingWithOptions:)]) { 402| 0| if ([observer application:application didFinishLaunchingWithOptions:launchOptions]) { 403| 0| handled = YES; 404| 0| } 405| 0| } 406| 0| } 407| | 408| 0| return handled; 409| 0|} 410| | 411| |- (void)applicationDidEnterBackground:(NSNotification *)notification 412| 0|{ 413| 0| [self setApplicationState:UIApplicationStateBackground]; 414| 0| NSArray> *observers = [self.applicationObservers allObjects]; 415| 0| for (id observer in observers) { 416| 0| if ([observer respondsToSelector:@selector(applicationDidEnterBackground:)]) { 417| 0| [observer applicationDidEnterBackground:notification.object]; 418| 0| } 419| 0| } 420| 0|} 421| | 422| |- (void)applicationDidBecomeActive:(NSNotification *)notification 423| 0|{ 424| 0| [self setApplicationState:UIApplicationStateActive]; 425| | // Auto log basic events in case autoLogAppEventsEnabled is set 426| 0| if (self.settings.isAutoLogAppEventsEnabled) { 427| 0| [self.appEvents activateApp]; 428| 0| } 429| 0|#if !TARGET_OS_TV 430| 0| [FBSDKSKAdNetworkReporter checkAndRevokeTimer]; 431| 0|#endif 432| | 433| 0| NSArray> *observers = [self.applicationObservers copy]; 434| 0| for (id observer in observers) { 435| 0| if ([observer respondsToSelector:@selector(applicationDidBecomeActive:)]) { 436| 0| [observer applicationDidBecomeActive:notification.object]; 437| 0| } 438| 0| } 439| 0|} 440| | 441| |- (void)applicationWillResignActive:(NSNotification *)notification 442| 0|{ 443| 0| [self setApplicationState:UIApplicationStateInactive]; 444| 0| NSArray> *const observers = [self.applicationObservers copy]; 445| 0| for (id observer in observers) { 446| 0| if ([observer respondsToSelector:@selector(applicationWillResignActive:)]) { 447| 0| [observer applicationWillResignActive:notification.object]; 448| 0| } 449| 0| } 450| 0|} 451| | 452| |#pragma mark - Internal Methods 453| | 454| |#pragma mark - FBSDKApplicationObserving 455| | 456| |- (void)addObserver:(id)observer 457| 0|{ 458| 0| if (![self.applicationObservers containsObject:observer]) { 459| 0| [self.applicationObservers addObject:observer]; 460| 0| } 461| 0|} 462| | 463| |- (void)removeObserver:(id)observer 464| 0|{ 465| 0| if ([self.applicationObservers containsObject:observer]) { 466| 0| [self.applicationObservers removeObject:observer]; 467| 0| } 468| 0|} 469| | 470| |+ (UIApplicationState)applicationState 471| 0|{ 472| 0| return _applicationState; 473| 0|} 474| | 475| |- (void)setApplicationState:(UIApplicationState)state 476| 0|{ 477| 0| _applicationState = state; 478| 0| [self.appEvents setApplicationState:state]; 479| 0|} 480| | 481| |#pragma mark - Helper Methods 482| | 483| |- (void)_logIfAppLinkEvent:(NSURL *)url 484| 0|{ 485| 0| if (!url) { 486| 0| return; 487| 0| } 488| 0| NSDictionary *params = [FBSDKBasicUtility dictionaryWithQueryString:url.query]; 489| 0| NSString *applinkDataString = params[@"al_applink_data"]; 490| 0| if (!applinkDataString) { 491| 0| return; 492| 0| } 493| | 494| 0| NSDictionary *applinkData = [FBSDKTypeUtility dictionaryValue:[FBSDKBasicUtility objectForJSONString:applinkDataString error:NULL]]; 495| 0| if (!applinkData) { 496| 0| return; 497| 0| } 498| | 499| 0| NSString *targetURLString = applinkData[@"target_url"]; 500| 0| NSURL *targetURL = [targetURLString isKindOfClass:[NSString class]] ? [NSURL URLWithString:targetURLString] : nil; 501| | 502| 0| NSMutableDictionary *logData = [NSMutableDictionary new]; 503| 0| [FBSDKTypeUtility dictionary:logData setObject:targetURL.absoluteString forKey:@"targetURL"]; 504| 0| [FBSDKTypeUtility dictionary:logData setObject:targetURL.host forKey:@"targetURLHost"]; 505| | 506| 0| NSDictionary *refererData = applinkData[@"referer_data"]; 507| 0| if (refererData) { 508| 0| [FBSDKTypeUtility dictionary:logData setObject:refererData[@"target_url"] forKey:@"referralTargetURL"]; 509| 0| [FBSDKTypeUtility dictionary:logData setObject:refererData[@"url"] forKey:@"referralURL"]; 510| 0| [FBSDKTypeUtility dictionary:logData setObject:refererData[@"app_name"] forKey:@"referralAppName"]; 511| 0| } 512| 0| [FBSDKTypeUtility dictionary:logData setObject:url.absoluteString forKey:@"inputURL"]; 513| 0| [FBSDKTypeUtility dictionary:logData setObject:url.scheme forKey:@"inputURLScheme"]; 514| | 515| 0| [self.appEvents logInternalEvent:FBSDKAppLinkInboundEvent 516| 0| parameters:logData 517| 0| isImplicitlyLogged:YES]; 518| 0|} 519| | 520| |- (void)_logSDKInitialize 521| 0|{ 522| 0| NSDictionary *metaInfo = [NSDictionary dictionaryWithObjects:@[@"login_lib_included", 523| 0| @"marketing_lib_included", 524| 0| @"messenger_lib_included", 525| 0| @"places_lib_included", 526| 0| @"share_lib_included", 527| 0| @"tv_lib_included"] 528| 0| forKeys:@[@"FBSDKLoginManager", 529| 0| @"FBSDKAutoLog", 530| 0| @"FBSDKMessengerButton", 531| 0| @"FBSDKPlacesManager", 532| 0| @"FBSDKShareDialog", 533| 0| @"FBSDKTVInterfaceFactory"]]; 534| | 535| 0| NSInteger bitmask = 0; 536| 0| NSInteger bit = 0; 537| 0| NSMutableDictionary *params = NSMutableDictionary.new; 538| 0| [FBSDKTypeUtility dictionary:params setObject:@1 forKey:@"core_lib_included"]; 539| 0| for (NSString *className in metaInfo.allKeys) { 540| 0| NSString *keyName = [FBSDKTypeUtility dictionary:metaInfo objectForKey:className ofType:NSObject.class]; 541| 0| if (objc_lookUpClass([className UTF8String])) { 542| 0| [FBSDKTypeUtility dictionary:params setObject:@1 forKey:keyName]; 543| 0| bitmask |= 1 << bit; 544| 0| } 545| 0| bit++; 546| 0| } 547| | 548| 0| NSInteger existingBitmask = [self.store integerForKey:FBSDKKitsBitmaskKey]; 549| 0| if (existingBitmask != bitmask) { 550| 0| [self.store setInteger:bitmask forKey:FBSDKKitsBitmaskKey]; 551| 0| [self.appEvents logInternalEvent:@"fb_sdk_initialize" 552| 0| parameters:params 553| 0| isImplicitlyLogged:NO]; 554| 0| } 555| 0|} 556| | 557| |- (void)_logIfAutoAppLinkEnabled 558| 0|{ 559| 0|#if !TARGET_OS_TV 560| 0| NSNumber *enabled = [[NSBundle mainBundle] objectForInfoDictionaryKey:@"FBSDKAutoAppLinkEnabled"]; 561| 0| if (enabled.boolValue) { 562| 0| NSMutableDictionary *params = [NSMutableDictionary new]; 563| 0| if (![FBSDKAppLinkUtility isMatchURLScheme:[NSString stringWithFormat:@"fb%@", self.settings.appID]]) { 564| 0| NSString *warning = @"You haven't set the Auto App Link URL scheme: fb"; 565| 0| [FBSDKTypeUtility dictionary:params setObject:warning forKey:@"SchemeWarning"]; 566| 0| NSLog(@"%@", warning); 567| 0| } 568| 0| [self.appEvents logInternalEvent:@"fb_auto_applink" parameters:params isImplicitlyLogged:YES]; 569| 0| } 570| 0|#endif 571| 0|} 572| | 573| |+ (BOOL)isSDKInitialized 574| 0|{ 575| 0| return hasInitializeBeenCalled; 576| 0|} 577| | 578| |- (void)configureDependencies 579| 0|{ 580| 0| id graphRequestProvider = [FBSDKGraphRequestFactory new]; 581| 0| id store = NSUserDefaults.standardUserDefaults; 582| 0| id connectionProvider = [FBSDKGraphRequestConnectionFactory new]; 583| 0| id sharedSettings = FBSDKSettings.sharedSettings; 584| | 585| 0| [FBSDKSettings configureWithStore:store 586| 0| appEventsConfigurationProvider:FBSDKAppEventsConfigurationManager.class 587| 0| infoDictionaryProvider:NSBundle.mainBundle 588| 0| eventLogger:FBSDKAppEvents.singleton]; 589| 0| [FBSDKGraphRequest setCurrentAccessTokenStringProvider:FBSDKAccessToken.class]; 590| 0| [FBSDKGraphRequestConnection setCanMakeRequests]; 591| 0| [FBSDKGateKeeperManager configureWithSettings:FBSDKSettings.class 592| 0| requestProvider:graphRequestProvider 593| 0| connectionProvider:connectionProvider 594| 0| store:store]; 595| 0| FBSDKTokenCache *tokenCache = [[FBSDKTokenCache alloc] initWithSettings:sharedSettings]; 596| 0| [FBSDKAccessToken setTokenCache:tokenCache]; 597| 0| [FBSDKAccessToken setConnectionFactory:connectionProvider]; 598| 0| [FBSDKAuthenticationToken setTokenCache:tokenCache]; 599| 0| FBSDKAtePublisherFactory *atePublisherFactory = [[FBSDKAtePublisherFactory alloc] initWithStore:store 600| 0| graphRequestFactory:graphRequestProvider 601| 0| settings:sharedSettings]; 602| 0| FBSDKTimeSpentRecordingFactory *timeSpentRecordingFactory 603| 0| = [[FBSDKTimeSpentRecordingFactory alloc] initWithEventLogger:self.appEvents 604| 0| serverConfigurationProvider:FBSDKServerConfigurationManager.class]; 605| 0| FBSDKEventDeactivationManager *eventDeactivationManager = [FBSDKEventDeactivationManager new]; 606| 0| FBSDKRestrictiveDataFilterManager *restrictiveDataFilterManager = [[FBSDKRestrictiveDataFilterManager alloc] initWithServerConfigurationProvider:FBSDKServerConfigurationManager.class]; 607| 0| [FBSDKAppEventsState configureWithEventProcessors:@[eventDeactivationManager, restrictiveDataFilterManager]]; 608| 0| [self.appEvents configureWithGateKeeperManager:FBSDKGateKeeperManager.class 609| 0| appEventsConfigurationProvider:FBSDKAppEventsConfigurationManager.class 610| 0| serverConfigurationProvider:FBSDKServerConfigurationManager.class 611| 0| graphRequestProvider:graphRequestProvider 612| 0| featureChecker:self.featureChecker 613| 0| store:store 614| 0| logger:FBSDKLogger.class 615| 0| settings:sharedSettings 616| 0| paymentObserver:FBSDKPaymentObserver.shared 617| 0| timeSpentRecorderFactory:timeSpentRecordingFactory 618| 0| appEventsStateStore:FBSDKAppEventsStateManager.shared 619| 0| eventDeactivationParameterProcessor:eventDeactivationManager 620| 0| restrictiveDataFilterParameterProcessor:restrictiveDataFilterManager 621| 0| atePublisherFactory:atePublisherFactory 622| 0| appEventsStateProvider:[FBSDKAppEventsStateFactory new] 623| 0| swizzler:FBSDKSwizzler.class]; 624| 0| [FBSDKInternalUtility configureWithInfoDictionaryProvider:NSBundle.mainBundle]; 625| 0| [FBSDKAppEventsConfigurationManager configureWithStore:store 626| 0| settings:sharedSettings 627| 0| graphRequestFactory:graphRequestProvider 628| 0| graphRequestConnectionFactory:connectionProvider]; 629| 0| [FBSDKGraphRequestPiggybackManager configureWithTokenWallet:FBSDKAccessToken.class 630| 0| settings:sharedSettings 631| 0| serverConfiguration:[FBSDKServerConfigurationManager class] 632| 0| requestProvider:graphRequestProvider]; 633| 0| [FBSDKButton setApplicationActivationNotifier:self]; 634| 0| [FBSDKError configureWithErrorReporter:FBSDKErrorReport.shared]; 635| 0|#if !TARGET_OS_TV 636| 0| [FBSDKModelManager.shared configureWithFeatureChecker:FBSDKFeatureManager.shared 637| 0| graphRequestFactory:graphRequestProvider 638| 0| fileManager:NSFileManager.defaultManager 639| 0| store:store 640| 0| settings:sharedSettings 641| 0| dataExtractor:NSData.class]; 642| 0| [FBSDKFeatureExtractor configureWithRulesFromKeyProvider:FBSDKModelManager.shared]; 643| 0| [FBSDKAppLinkUtility configureWithRequestProvider:graphRequestProvider 644| 0| infoDictionaryProvider:NSBundle.mainBundle]; 645| 0| [FBSDKCodelessIndexer configureWithRequestProvider:graphRequestProvider 646| 0| serverConfigurationProvider:FBSDKServerConfigurationManager.class 647| 0| store:store 648| 0| connectionProvider:connectionProvider 649| 0| swizzler:FBSDKSwizzler.class 650| 0| settings:sharedSettings 651| 0| advertiserIDProvider:FBSDKAppEventsUtility.shared]; 652| 0| [FBSDKCrashShield configureWithSettings:sharedSettings 653| 0| requestProvider:[FBSDKGraphRequestFactory new] 654| 0| featureChecking:FBSDKFeatureManager.shared]; 655| 0| if (@available(iOS 14.0, *)) { 656| 0| [FBSDKSKAdNetworkReporter configureWithRequestProvider:graphRequestProvider 657| 0| store:store 658| 0| conversionValueUpdatable:SKAdNetwork.class]; 659| 0| [FBSDKAEMReporter configureWithRequestProvider:graphRequestProvider]; 660| 0| } 661| 0| [FBSDKProfile configureWithStore:store 662| 0| accessTokenProvider:FBSDKAccessToken.class 663| 0| notificationCenter:NSNotificationCenter.defaultCenter]; 664| 0| [FBSDKWebDialogView configureWithWebViewProvider:[FBSDKWebViewFactory new] 665| 0| urlOpener:UIApplication.sharedApplication]; 666| 0| [FBSDKAppEvents configureNonTVComponentsWithOnDeviceMLModelManager:FBSDKModelManager.shared 667| 0| metadataIndexer:FBSDKMetadataIndexer.shared]; 668| 0|#endif 669| 0|} 670| | 671| |// MARK: - Testability 672| | 673| |#if DEBUG 674| | #if FBSDKTEST 675| | 676| |+ (void)resetHasInitializeBeenCalled 677| 0|{ 678| 0| hasInitializeBeenCalled = NO; 679| 0|} 680| | 681| |- (void)resetApplicationObserverCache 682| 0|{ 683| 0| _applicationObservers = [NSHashTable new]; 684| 0|} 685| | 686| | #endif 687| |#endif 688| | 689| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKAuthenticationToken.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKAuthenticationToken.h" 20| |#import "FBSDKAuthenticationToken+Internal.h" 21| | 22| |#import "FBSDKAuthenticationTokenClaims.h" 23| |#import "FBSDKCoreKitBasicsImport.h" 24| | 25| |static FBSDKAuthenticationToken *g_currentAuthenticationToken; 26| |static id g_tokenCache; 27| | 28| |NSString *const FBSDKAuthenticationTokenTokenStringCodingKey = @"FBSDKAuthenticationTokenTokenStringCodingKey"; 29| |NSString *const FBSDKAuthenticationTokenNonceCodingKey = @"FBSDKAuthenticationTokenNonceCodingKey"; 30| |NSString *const FBSDKAuthenticationTokenGraphDomainCodingKey = @"FBSDKAuthenticationTokenGraphDomainCodingKey"; 31| | 32| |@interface FBSDKAuthenticationTokenClaims (Internal) 33| | 34| |+ (nullable FBSDKAuthenticationTokenClaims *)claimsFromEncodedString:(NSString *)encodedClaims nonce:(NSString *)expectedNonce; 35| | 36| |@end 37| | 38| |@implementation FBSDKAuthenticationToken 39| |{ 40| | NSString *_jti; 41| |} 42| | 43| |- (instancetype)initWithTokenString:(NSString *)tokenString 44| | nonce:(NSString *)nonce 45| | graphDomain:(NSString *)graphDomain 46| 0|{ 47| 0| if ((self = [super init])) { 48| 0| _tokenString = tokenString; 49| 0| _nonce = nonce; 50| 0| _graphDomain = graphDomain; 51| 0| } 52| 0| return self; 53| 0|} 54| | 55| |- (instancetype)initWithTokenString:(NSString *)tokenString 56| | nonce:(NSString *)nonce 57| 0|{ 58| 0| return [self initWithTokenString:tokenString 59| 0| nonce:nonce 60| 0| graphDomain:@"facebook"]; 61| 0|} 62| | 63| |+ (nullable FBSDKAuthenticationToken *)currentAuthenticationToken 64| 0|{ 65| 0| return g_currentAuthenticationToken; 66| 0|} 67| | 68| |+ (void)setCurrentAuthenticationToken:(FBSDKAuthenticationToken *)token 69| 0|{ 70| 0| if (token != g_currentAuthenticationToken) { 71| 0| g_currentAuthenticationToken = token; 72| 0| self.tokenCache.authenticationToken = token; 73| 0| } 74| 0|} 75| | 76| |- (FBSDKAuthenticationTokenClaims *)claims 77| 0|{ 78| 0| NSArray *segments = [_tokenString componentsSeparatedByString:@"."]; 79| 0| if (segments.count != 3) { 80| 0| return nil; 81| 0| } 82| 0| NSString *encodedClaims = [FBSDKTypeUtility array:segments objectAtIndex:1]; 83| 0| return [FBSDKAuthenticationTokenClaims claimsFromEncodedString:encodedClaims nonce:_nonce]; 84| 0|} 85| | 86| |#pragma mark - Storage 87| | 88| |+ (id)tokenCache 89| 0|{ 90| 0| return g_tokenCache; 91| 0|} 92| | 93| |+ (void)setTokenCache:(id)cache 94| 0|{ 95| 0| if (g_tokenCache != cache) { 96| 0| g_tokenCache = cache; 97| 0| } 98| 0|} 99| | 100| |+ (void)resetTokenCache 101| 0|{ 102| 0| g_tokenCache = nil; 103| 0|} 104| | 105| |+ (BOOL)supportsSecureCoding 106| 0|{ 107| 0| return YES; 108| 0|} 109| | 110| |- (instancetype)initWithCoder:(NSCoder *)decoder 111| 0|{ 112| 0| NSString *tokenString = [decoder decodeObjectOfClass:NSString.class forKey:FBSDKAuthenticationTokenTokenStringCodingKey]; 113| 0| NSString *nonce = [decoder decodeObjectOfClass:NSString.class forKey:FBSDKAuthenticationTokenNonceCodingKey]; 114| 0| NSString *graphDomain = [decoder decodeObjectOfClass:NSString.class forKey:FBSDKAuthenticationTokenGraphDomainCodingKey]; 115| | 116| 0| return [self initWithTokenString:tokenString 117| 0| nonce:nonce 118| 0| graphDomain:graphDomain]; 119| 0|} 120| | 121| |- (void)encodeWithCoder:(NSCoder *)encoder 122| 0|{ 123| 0| [encoder encodeObject:self.tokenString forKey:FBSDKAuthenticationTokenTokenStringCodingKey]; 124| 0| [encoder encodeObject:self.nonce forKey:FBSDKAuthenticationTokenNonceCodingKey]; 125| 0| [encoder encodeObject:_graphDomain forKey:FBSDKAuthenticationTokenGraphDomainCodingKey]; 126| 0|} 127| | 128| |#pragma mark - NSCopying 129| | 130| |- (id)copyWithZone:(NSZone *)zone 131| 0|{ 132| | // we're immutable. 133| 0| return self; 134| 0|} 135| | 136| |#pragma mark - Test methods 137| | 138| |#if DEBUG 139| | #if FBSDKTEST 140| | 141| |+ (void)resetCurrentAuthenticationTokenCache 142| 0|{ 143| 0| g_currentAuthenticationToken = nil; 144| 0|} 145| | 146| | #endif 147| |#endif 148| | 149| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKAuthenticationTokenClaims.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKAuthenticationTokenClaims.h" 20| | 21| |#import "FBSDKCoreKitBasicsImport.h" 22| |#import "FBSDKSettings.h" 23| | 24| |static NSTimeInterval const MaxTimeSinceTokenIssued = 10 * 60; // 10 mins 25| | 26| |@implementation FBSDKAuthenticationTokenClaims 27| | 28| |- (instancetype)initWithJti:(NSString *)jti 29| | iss:(NSString *)iss 30| | aud:(NSString *)aud 31| | nonce:(NSString *)nonce 32| | exp:(NSTimeInterval)exp 33| | iat:(NSTimeInterval)iat 34| | sub:(NSString *)sub 35| | name:(nullable NSString *)name 36| | givenName:(nullable NSString *)givenName 37| | middleName:(nullable NSString *)middleName 38| | familyName:(nullable NSString *)familyName 39| | email:(nullable NSString *)email 40| | picture:(nullable NSString *)picture 41| | userFriends:(nullable NSArray *)userFriends 42| | userBirthday:(nullable NSString *)userBirthday 43| | userAgeRange:(nullable NSDictionary *)userAgeRange 44| | userHometown:(nullable NSDictionary *)userHometown 45| | userLocation:(nullable NSDictionary *)userLocation 46| | userGender:(nullable NSString *)userGender 47| | userLink:(nullable NSString *)userLink 48| 0|{ 49| 0| if (self = [super init]) { 50| 0| _jti = jti; 51| 0| _iss = iss; 52| 0| _aud = aud; 53| 0| _nonce = nonce; 54| 0| _exp = exp; 55| 0| _iat = iat; 56| 0| _sub = sub; 57| 0| _name = name; 58| 0| _givenName = givenName; 59| 0| _middleName = middleName; 60| 0| _familyName = familyName; 61| 0| _email = email; 62| 0| _picture = picture; 63| 0| _userFriends = userFriends; 64| 0| _userBirthday = userBirthday; 65| 0| _userAgeRange = userAgeRange; 66| 0| _userHometown = userHometown; 67| 0| _userLocation = userLocation; 68| 0| _userGender = userGender; 69| 0| _userLink = userLink; 70| 0| } 71| | 72| 0| return self; 73| 0|} 74| | 75| |+ (nullable FBSDKAuthenticationTokenClaims *)claimsFromEncodedString:(NSString *)encodedClaims nonce:(NSString *)expectedNonce 76| 0|{ 77| 0| NSError *error; 78| 0| NSData *claimsData = [FBSDKBase64 decodeAsData:[FBSDKBase64 base64FromBase64Url:encodedClaims]]; 79| | 80| 0| if (claimsData) { 81| 0| NSDictionary *claimsDict = [FBSDKTypeUtility JSONObjectWithData:claimsData options:0 error:&error]; 82| 0| if (!error) { 83| 0| NSTimeInterval currentTime = [[NSDate date] timeIntervalSince1970]; 84| | 85| | // verify claims 86| 0| NSString *jti = [FBSDKTypeUtility coercedToStringValue:claimsDict[@"jti"]]; 87| 0| BOOL hasJti = jti.length > 0; 88| | 89| 0| NSString *iss = [FBSDKTypeUtility coercedToStringValue:claimsDict[@"iss"]]; 90| 0| BOOL isFacebook = iss.length > 0 && [[[NSURL URLWithString:iss] host] isEqualToString:@"facebook.com"]; 91| | 92| 0| NSString *aud = [FBSDKTypeUtility coercedToStringValue:claimsDict[@"aud"]]; 93| 0| BOOL audMatched = [aud isEqualToString:[FBSDKSettings appID]]; 94| | 95| 0| NSNumber *expValue = [FBSDKTypeUtility numberValue:claimsDict[@"exp"]]; 96| 0| NSTimeInterval exp = [expValue doubleValue]; 97| 0| BOOL isExpired = expValue == nil || exp <= currentTime; 98| | 99| 0| NSNumber *iatValue = [FBSDKTypeUtility numberValue:claimsDict[@"iat"]]; 100| 0| NSTimeInterval iat = [iatValue doubleValue]; 101| 0| BOOL issuedRecently = iatValue != nil && iat >= currentTime - MaxTimeSinceTokenIssued; 102| | 103| 0| NSString *nonce = [FBSDKTypeUtility coercedToStringValue:claimsDict[@"nonce"]]; 104| 0| BOOL nonceMatched = nonce.length > 0 && [nonce isEqualToString:expectedNonce]; 105| | 106| 0| NSString *sub = [FBSDKTypeUtility coercedToStringValue:claimsDict[@"sub"]]; 107| 0| BOOL userIDValid = sub.length > 0; 108| | 109| 0| NSString *name = [FBSDKTypeUtility coercedToStringValue:claimsDict[@"name"]]; 110| 0| NSString *givenName = [FBSDKTypeUtility coercedToStringValue:claimsDict[@"given_name"]]; 111| 0| NSString *middleName = [FBSDKTypeUtility coercedToStringValue:claimsDict[@"middle_name"]]; 112| 0| NSString *familyName = [FBSDKTypeUtility coercedToStringValue:claimsDict[@"family_name"]]; 113| 0| NSString *email = [FBSDKTypeUtility coercedToStringValue:claimsDict[@"email"]]; 114| 0| NSString *picture = [FBSDKTypeUtility coercedToStringValue:claimsDict[@"picture"]]; 115| 0| NSString *userBirthday = [FBSDKTypeUtility coercedToStringValue:claimsDict[@"user_birthday"]]; 116| | 117| 0| NSMutableDictionary *userAgeRange; 118| 0| NSDictionary *rawUserAgeRange = [FBSDKTypeUtility dictionaryValue:claimsDict[@"user_age_range"]]; 119| 0| if (rawUserAgeRange.count > 0) { 120| 0| userAgeRange = NSMutableDictionary.new; 121| 0| for (NSString *key in rawUserAgeRange) { 122| 0| NSNumber *value = [FBSDKTypeUtility dictionary:rawUserAgeRange objectForKey:key ofType:NSNumber.class]; 123| 0| if (value == nil) { 124| 0| userAgeRange = nil; 125| 0| break; 126| 0| } 127| | 128| 0| [FBSDKTypeUtility dictionary:userAgeRange setObject:value forKey:key]; 129| 0| } 130| 0| } 131| | 132| 0| NSMutableDictionary *userHometown = [self extractLocationDictFromClaims:claimsDict key:@"user_hometown"]; 133| 0| NSMutableDictionary *userLocation = [self extractLocationDictFromClaims:claimsDict key:@"user_location"]; 134| | 135| 0| NSString *userGender = [FBSDKTypeUtility coercedToStringValue:claimsDict[@"user_gender"]]; 136| 0| NSString *userLink = [FBSDKTypeUtility coercedToStringValue:claimsDict[@"user_link"]]; 137| | 138| 0| NSArray *userFriends = [FBSDKTypeUtility arrayValue:claimsDict[@"user_friends"]]; 139| 0| for (NSString *friend in userFriends) { 140| 0| if (![FBSDKTypeUtility coercedToStringValue:friend]) { 141| 0| userFriends = nil; 142| 0| break; 143| 0| } 144| 0| } 145| | 146| 0| if (hasJti && isFacebook && audMatched && !isExpired && issuedRecently && nonceMatched && userIDValid) { 147| 0| return [[FBSDKAuthenticationTokenClaims alloc] initWithJti:jti 148| 0| iss:iss 149| 0| aud:aud 150| 0| nonce:nonce 151| 0| exp:exp 152| 0| iat:iat 153| 0| sub:sub 154| 0| name:name 155| 0| givenName:givenName 156| 0| middleName:middleName 157| 0| familyName:familyName 158| 0| email:email 159| 0| picture:picture 160| 0| userFriends:userFriends 161| 0| userBirthday:userBirthday 162| 0| userAgeRange:userAgeRange 163| 0| userHometown:userHometown 164| 0| userLocation:userLocation 165| 0| userGender:userGender 166| 0| userLink:userLink]; 167| 0| } 168| 0| } 169| 0| } 170| | 171| 0| return nil; 172| 0|} 173| | 174| |+ (nullable NSMutableDictionary *)extractLocationDictFromClaims:(NSDictionary *)claimsDict key:(NSString *)keyName 175| 0|{ 176| 0| NSDictionary *rawLocationData = [FBSDKTypeUtility dictionaryValue:claimsDict[keyName]]; 177| 0| NSMutableDictionary *location; 178| 0| if (rawLocationData.count > 0) { 179| 0| location = NSMutableDictionary.new; 180| 0| for (NSString *key in rawLocationData) { 181| 0| NSString *value = [FBSDKTypeUtility dictionary:rawLocationData 182| 0| objectForKey:key 183| 0| ofType:NSString.class]; 184| 0| if (value == nil) { 185| 0| return nil; 186| 0| } 187| | 188| 0| [FBSDKTypeUtility dictionary:location setObject:value forKey:key]; 189| 0| } 190| 0| } 191| 0| return location; 192| 0|} 193| | 194| |// MARK: Equality 195| | 196| |- (BOOL)isEqualToClaims:(FBSDKAuthenticationTokenClaims *)claims 197| 0|{ 198| 0| return [_jti isEqualToString:claims.jti] 199| 0| && [_iss isEqualToString:claims.iss] 200| 0| && [_aud isEqualToString:claims.aud] 201| 0| && [_nonce isEqualToString:claims.nonce] 202| 0| && _exp == claims.exp 203| 0| && _iat == claims.iat 204| 0| && [_sub isEqualToString:claims.sub] 205| 0| && [_name isEqualToString:claims.name] 206| 0| && [_givenName isEqualToString:claims.givenName] 207| 0| && [_middleName isEqualToString:claims.middleName] 208| 0| && [_familyName isEqualToString:claims.familyName] 209| 0| && [_email isEqualToString:claims.email] 210| 0| && [_picture isEqualToString:claims.picture] 211| 0| && [_userFriends isEqualToArray:claims.userFriends] 212| 0| && [_userBirthday isEqualToString:claims.userBirthday] 213| 0| && [_userAgeRange isEqualToDictionary:claims.userAgeRange] 214| 0| && [_userHometown isEqualToDictionary:claims.userHometown] 215| 0| && [_userLocation isEqualToDictionary:claims.userLocation] 216| 0| && [_userGender isEqualToString:claims.userGender] 217| 0| && [_userLink isEqualToString:claims.userLink]; 218| 0|} 219| | 220| |- (BOOL)isEqual:(id)object 221| 0|{ 222| 0| if (self == object) { 223| 0| return YES; 224| 0| } 225| | 226| 0| if (![object isKindOfClass:[FBSDKAuthenticationTokenClaims class]]) { 227| 0| return NO; 228| 0| } 229| | 230| 0| return [self isEqualToClaims:(FBSDKAuthenticationTokenClaims *)object]; 231| 0|} 232| | 233| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKBridgeAPI.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKBridgeAPI.h" 24| | 25| | #import "FBSDKApplicationLifecycleNotifications.h" 26| | #import "FBSDKBridgeAPIResponseCreating.h" 27| | #import "FBSDKBridgeAPIResponseFactory.h" 28| | #import "FBSDKContainerViewController.h" 29| | #import "FBSDKCoreKit+Internal.h" 30| | #import "FBSDKInternalUtility+AppURLSchemeProviding.h" 31| | #import "FBSDKOperatingSystemVersionComparing.h" 32| | #import "NSProcessInfo+Protocols.h" 33| | #import "UIApplication+URLOpener.h" 34| | 35| |/** 36| | Specifies state of FBSDKAuthenticationSession (SFAuthenticationSession (iOS 11) and ASWebAuthenticationSession (iOS 12+)) 37| | */ 38| |typedef NS_ENUM(NSUInteger, FBSDKAuthenticationSession) { 39| | /** There is no active authentication session*/ 40| | FBSDKAuthenticationSessionNone, 41| | /** The authentication session has started*/ 42| | FBSDKAuthenticationSessionStarted, 43| | /** System dialog ("app wants to use facebook.com to sign in") to access facebook.com was presented to the user*/ 44| | FBSDKAuthenticationSessionShowAlert, 45| | /** Web browser with log in to authentication was presented to the user*/ 46| | FBSDKAuthenticationSessionShowWebBrowser, 47| | /** Authentication session was canceled by system. It happens when app goes to background while alert requesting access to facebook.com is presented*/ 48| | FBSDKAuthenticationSessionCanceledBySystem, 49| |}; 50| | 51| |@protocol FBSDKAuthenticationSession 52| | 53| |- (instancetype)initWithURL:(NSURL *)URL callbackURLScheme:(nullable NSString *)callbackURLScheme completionHandler:(FBSDKAuthenticationCompletionHandler)completionHandler; 54| |- (BOOL)start; 55| |- (void)cancel; 56| |@optional 57| |- (void)setPresentationContextProvider:(id)presentationContextProvider; 58| | 59| |@end 60| | 61| | #if __IPHONE_OS_VERSION_MAX_ALLOWED >= 130000 62| | #import 63| |@interface FBSDKBridgeAPI () 64| | #else 65| |@interface FBSDKBridgeAPI () 66| | #endif 67| | 68| |@property (nonnull, nonatomic) FBSDKLogger *logger; 69| |@property (nonatomic, readonly) id urlOpener; 70| |@property (nonatomic, readonly) id bridgeAPIResponseFactory; 71| |@property (nonatomic, readonly) id frameworkLoader; 72| |@property (nonatomic, readonly) id appURLSchemeProvider; 73| | 74| |@end 75| | 76| |@implementation FBSDKBridgeAPI 77| |{ 78| | NSObject *_pendingRequest; 79| | FBSDKBridgeAPIResponseBlock _pendingRequestCompletionBlock; 80| | id _pendingURLOpen; 81| | id _authenticationSession NS_AVAILABLE_IOS(11_0); 82| | FBSDKAuthenticationCompletionHandler _authenticationSessionCompletionHandler NS_AVAILABLE_IOS(11_0); 83| | 84| | BOOL _expectingBackground; 85| | UIViewController *_safariViewController; 86| | BOOL _isDismissingSafariViewController; 87| | BOOL _isAppLaunched; 88| | FBSDKAuthenticationSession _authenticationSessionState; 89| | id _processInfo; 90| |} 91| | 92| |+ (FBSDKBridgeAPI *)sharedInstance 93| 0|{ 94| 0| static FBSDKBridgeAPI *_sharedInstance; 95| 0| static dispatch_once_t onceToken; 96| 0| dispatch_once(&onceToken, ^{ 97| 0| _sharedInstance = [[self alloc] initWithProcessInfo:NSProcessInfo.processInfo 98| 0| logger:[[FBSDKLogger alloc] initWithLoggingBehavior:FBSDKLoggingBehaviorDeveloperErrors] 99| 0| urlOpener:UIApplication.sharedApplication 100| 0| bridgeAPIResponseFactory:[FBSDKBridgeAPIResponseFactory new] 101| 0| frameworkLoader:FBSDKDynamicFrameworkLoader.shared 102| 0| appURLSchemeProvider:FBSDKInternalUtility.sharedUtility]; 103| 0| }); 104| 0| return _sharedInstance; 105| 0|} 106| | 107| |- (instancetype)initWithProcessInfo:(id)processInfo 108| | logger:(FBSDKLogger *)logger 109| | urlOpener:(id)urlOpener 110| | bridgeAPIResponseFactory:(id)bridgeAPIResponseFactory 111| | frameworkLoader:(id)frameworkLoader 112| | appURLSchemeProvider:(nonnull id)appURLSchemeProvider; 113| 0|{ 114| 0| if ((self = [super init])) { 115| 0| _processInfo = processInfo; 116| 0| _logger = logger; 117| 0| _urlOpener = urlOpener; 118| 0| _bridgeAPIResponseFactory = bridgeAPIResponseFactory; 119| 0| _frameworkLoader = frameworkLoader; 120| 0| _appURLSchemeProvider = appURLSchemeProvider; 121| 0| } 122| 0| return self; 123| 0|} 124| | 125| |- (void)applicationWillResignActive:(UIApplication *)application 126| 0|{ 127| 0| [self _updateAuthStateIfSystemAlertToUseWebAuthFlowPresented]; 128| 0|} 129| | 130| |- (void)applicationDidBecomeActive:(UIApplication *)application 131| 0|{ 132| 0| BOOL isRequestingWebAuthenticationSession = NO; 133| 0| if (@available(iOS 11.0, *)) { 134| 0| if (_authenticationSession && _authenticationSessionState == FBSDKAuthenticationSessionShowAlert) { 135| 0| _authenticationSessionState = FBSDKAuthenticationSessionShowWebBrowser; 136| 0| } else if (_authenticationSession && _authenticationSessionState == FBSDKAuthenticationSessionCanceledBySystem) { 137| 0| [_authenticationSession cancel]; 138| 0| _authenticationSession = nil; 139| 0| NSString *errorDomain; 140| 0| if (@available(iOS 12.0, *)) { 141| 0| errorDomain = @"com.apple.AuthenticationServices.WebAuthenticationSession"; 142| 0| } else { 143| 0| errorDomain = @"com.apple.SafariServices.Authentication"; 144| 0| } 145| 0| NSError *error = [FBSDKError errorWithDomain:errorDomain code:1 message:nil]; 146| 0| if (_authenticationSessionCompletionHandler) { 147| 0| _authenticationSessionCompletionHandler(nil, error); 148| 0| } 149| 0| isRequestingWebAuthenticationSession = [self _isRequestingWebAuthenticationSession]; 150| 0| } 151| 0| } 152| | // _expectingBackground can be YES if the caller started doing work (like login) 153| | // within the app delegate's lifecycle like openURL, in which case there 154| | // might have been a "didBecomeActive" event pending that we want to ignore. 155| 0| BOOL notExpectingBackground = !_expectingBackground && !_safariViewController && !_isDismissingSafariViewController && !isRequestingWebAuthenticationSession; 156| 0| if (notExpectingBackground) { 157| 0| _active = YES; 158| | 159| 0| [_pendingURLOpen applicationDidBecomeActive:application]; 160| 0| [self _cancelBridgeRequest]; 161| | 162| 0| [[NSNotificationCenter defaultCenter] postNotificationName:FBSDKApplicationDidBecomeActiveNotification object:self]; 163| 0| } 164| 0|} 165| | 166| |- (void)applicationDidEnterBackground:(UIApplication *)application 167| 0|{ 168| 0| _active = NO; 169| 0| _expectingBackground = NO; 170| 0| [self _updateAuthStateIfSystemCancelAuthSession]; 171| 0|} 172| | 173| |- (BOOL)application:(UIApplication *)application 174| | openURL:(NSURL *)url 175| | sourceApplication:(NSString *)sourceApplication 176| | annotation:(id)annotation 177| 0|{ 178| 0| id pendingURLOpen = _pendingURLOpen; 179| | 180| 0| if ([pendingURLOpen respondsToSelector:@selector(shouldStopPropagationOfURL:)] 181| 0| && [pendingURLOpen shouldStopPropagationOfURL:url]) { 182| 0| return YES; 183| 0| } 184| | 185| 0| BOOL canOpenURL = [pendingURLOpen canOpenURL:url 186| 0| forApplication:application 187| 0| sourceApplication:sourceApplication 188| 0| annotation:annotation]; 189| | 190| 0| void (^completePendingOpenURLBlock)(void) = ^{ 191| 0| self->_pendingURLOpen = nil; 192| 0| [pendingURLOpen application:application 193| 0| openURL:url 194| 0| sourceApplication:sourceApplication 195| 0| annotation:annotation]; 196| 0| self->_isDismissingSafariViewController = NO; 197| 0| }; 198| | // if they completed a SFVC flow, dismiss it. 199| 0| if (_safariViewController) { 200| 0| _isDismissingSafariViewController = YES; 201| 0| [_safariViewController.presentingViewController dismissViewControllerAnimated:YES 202| 0| completion:completePendingOpenURLBlock]; 203| 0| _safariViewController = nil; 204| 0| } else { 205| 0| if (@available(iOS 11.0, *)) { 206| 0| if (_authenticationSession != nil) { 207| 0| [_authenticationSession cancel]; 208| 0| _authenticationSession = nil; 209| | 210| | // This check is needed in case another sdk / message / ad etc... tries to open the app 211| | // during the login flow. 212| | // This dismisses the authentication browser without triggering any login callbacks. 213| | // Hence we need to explicitly call the authentication session's completion handler. 214| 0| if (!canOpenURL) { 215| 0| NSString *errorMessage = [[NSString alloc] 216| 0| initWithFormat:@"Login attempt cancelled by alternate call to openURL from: %@", 217| 0| url]; 218| 0| NSError *loginError = [[NSError alloc] 219| 0| initWithDomain:FBSDKErrorDomain 220| 0| code:FBSDKErrorBridgeAPIInterruption 221| 0| userInfo:@{FBSDKErrorLocalizedDescriptionKey : errorMessage}]; 222| 0| if (_authenticationSessionCompletionHandler) { 223| 0| _authenticationSessionCompletionHandler(url, loginError); 224| 0| _authenticationSessionCompletionHandler = nil; 225| 0| } 226| 0| } 227| 0| } 228| 0| } 229| 0| completePendingOpenURLBlock(); 230| 0| } 231| | 232| 0| if (canOpenURL) { 233| 0| return YES; 234| 0| } 235| | 236| 0| if ([self _handleBridgeAPIResponseURL:url sourceApplication:sourceApplication]) { 237| 0| return YES; 238| 0| } 239| | 240| 0| return NO; 241| 0|} 242| | 243| |- (BOOL) application:(UIApplication *)application 244| | didFinishLaunchingWithOptions:(NSDictionary *)launchOptions 245| 0|{ 246| 0| NSURL *launchedURL = launchOptions[UIApplicationLaunchOptionsURLKey]; 247| 0| NSString *sourceApplication = launchOptions[UIApplicationLaunchOptionsSourceApplicationKey]; 248| | 249| 0| if (launchedURL 250| 0| && sourceApplication) { 251| 0| Class loginManagerClass = NSClassFromString(@"FBSDKLoginManager"); 252| 0| if (loginManagerClass) { 253| 0| id annotation = launchOptions[UIApplicationLaunchOptionsAnnotationKey]; 254| 0| id loginManager = [loginManagerClass new]; 255| 0| return [loginManager application:application 256| 0| openURL:launchedURL 257| 0| sourceApplication:sourceApplication 258| 0| annotation:annotation]; 259| 0| } 260| 0| } 261| | 262| 0| return NO; 263| 0|} 264| | 265| |- (void)_updateAuthStateIfSystemAlertToUseWebAuthFlowPresented 266| 0|{ 267| 0| if (@available(iOS 11.0, *)) { 268| 0| if (_authenticationSession && _authenticationSessionState == FBSDKAuthenticationSessionStarted) { 269| 0| _authenticationSessionState = FBSDKAuthenticationSessionShowAlert; 270| 0| } 271| 0| } 272| 0|} 273| | 274| |- (void)_updateAuthStateIfSystemCancelAuthSession 275| 0|{ 276| 0| if (@available(iOS 11.0, *)) { 277| 0| if (_authenticationSession && _authenticationSessionState == FBSDKAuthenticationSessionShowAlert) { 278| 0| _authenticationSessionState = FBSDKAuthenticationSessionCanceledBySystem; 279| 0| } 280| 0| } 281| 0|} 282| | 283| |- (BOOL)_isRequestingWebAuthenticationSession 284| 0|{ 285| 0| return !(_authenticationSessionState == FBSDKAuthenticationSessionNone 286| 0| || _authenticationSessionState == FBSDKAuthenticationSessionCanceledBySystem); 287| 0|} 288| | 289| | #pragma clang diagnostic push 290| | #pragma clang diagnostic ignored "-Wdeprecated-declarations" 291| |- (void)openURL:(NSURL *)url sender:(id)sender handler:(FBSDKSuccessBlock)handler 292| 0|{ 293| 0| _expectingBackground = YES; 294| 0| _pendingURLOpen = sender; 295| 0| __block id weakProcessInfo = _processInfo; 296| 0| dispatch_block_t block = ^{ 297| | // Dispatch openURL calls to prevent hangs if we're inside the current app delegate's openURL flow already 298| 0| NSOperatingSystemVersion iOS10Version = { .majorVersion = 10, .minorVersion = 0, .patchVersion = 0 }; 299| 0| if ([weakProcessInfo isOperatingSystemAtLeastVersion:iOS10Version]) { 300| 0| if (@available(iOS 10.0, *)) { 301| 0| [self.urlOpener openURL:url options:@{} completionHandler:^(BOOL success) { 302| 0| handler(success, nil); 303| 0| }]; 304| 0| } 305| 0| } else if (handler) { 306| 0| BOOL opened = [self.urlOpener openURL:url]; 307| 0| handler(opened, nil); 308| 0| } 309| 0| }; 310| 0|#if FBSDKTEST 311| 0| block(); 312| |#else 313| | dispatch_async(dispatch_get_main_queue(), block); 314| |#endif 315| 0|} 316| | 317| | #pragma clang diagnostic pop 318| | 319| |- (void)openBridgeAPIRequest:(NSObject *)request 320| | useSafariViewController:(BOOL)useSafariViewController 321| | fromViewController:(UIViewController *)fromViewController 322| | completionBlock:(FBSDKBridgeAPIResponseBlock)completionBlock 323| 0|{ 324| 0| if (!request) { 325| 0| return; 326| 0| } 327| 0| NSError *error; 328| 0| NSURL *requestURL = [request requestURL:&error]; 329| 0| if (!requestURL) { 330| 0| FBSDKBridgeAPIResponse *response = [self.bridgeAPIResponseFactory createResponseWithRequest:request error:error]; 331| 0| completionBlock(response); 332| 0| return; 333| 0| } 334| 0| _pendingRequest = request; 335| 0| _pendingRequestCompletionBlock = [completionBlock copy]; 336| 0| FBSDKSuccessBlock handler = [self _bridgeAPIRequestCompletionBlockWithRequest:request 337| 0| completion:completionBlock]; 338| | 339| 0| if (useSafariViewController) { 340| 0| [self openURLWithSafariViewController:requestURL sender:nil fromViewController:fromViewController handler:handler]; 341| 0| } else { 342| 0| [self openURL:requestURL sender:nil handler:handler]; 343| 0| } 344| 0|} 345| | 346| |- (FBSDKSuccessBlock)_bridgeAPIRequestCompletionBlockWithRequest:(NSObject *)request 347| | completion:(FBSDKBridgeAPIResponseBlock)completionBlock 348| 0|{ 349| 0| return ^(BOOL openedURL, NSError *anError) { 350| 0| if (!openedURL) { 351| 0| self->_pendingRequest = nil; 352| 0| self->_pendingRequestCompletionBlock = nil; 353| 0| NSError *openedURLError; 354| 0| if ([request.scheme hasPrefix:@"http"]) { 355| 0| openedURLError = [FBSDKError errorWithCode:FBSDKErrorBrowserUnavailable 356| 0| message:@"the app switch failed because the browser is unavailable"]; 357| 0| } else { 358| 0| openedURLError = [FBSDKError errorWithCode:FBSDKErrorAppVersionUnsupported 359| 0| message:@"the app switch failed because the destination app is out of date"]; 360| 0| } 361| 0| FBSDKBridgeAPIResponse *response = [self.bridgeAPIResponseFactory createResponseWithRequest:request 362| 0| error:openedURLError]; 363| 0| completionBlock(response); 364| 0| return; 365| 0| } 366| 0| }; 367| 0|} 368| | 369| |- (void)openURLWithSafariViewController:(NSURL *)url 370| | sender:(id)sender 371| | fromViewController:(UIViewController *)fromViewController 372| | handler:(FBSDKSuccessBlock)handler 373| 0|{ 374| 0| if (![url.scheme hasPrefix:@"http"]) { 375| 0| [self openURL:url sender:sender handler:handler]; 376| 0| return; 377| 0| } 378| | 379| 0| _expectingBackground = NO; 380| 0| _pendingURLOpen = sender; 381| | 382| 0| if (@available(iOS 11.0, *)) { 383| 0| if ([sender isAuthenticationURL:url]) { 384| 0| [self setSessionCompletionHandlerFromHandler:handler]; 385| 0| [self openURLWithAuthenticationSession:url]; 386| 0| return; 387| 0| } 388| 0| } 389| | 390| | // trying to dynamically load SFSafariViewController class 391| | // so for the cases when it is available we can send users through Safari View Controller flow 392| | // in cases it is not available regular flow will be selected 393| 0| Class SFSafariViewControllerClass = self.frameworkLoader.safariViewControllerClass; 394| | 395| 0| if (SFSafariViewControllerClass) { 396| 0| UIViewController *parent = fromViewController ?: [FBSDKInternalUtility topMostViewController]; 397| 0| if (parent == nil) { 398| 0| [self.logger logEntry:@"There are no valid ViewController to present SafariViewController with"]; 399| 0| return; 400| 0| } 401| | 402| 0| NSURLComponents *components = [NSURLComponents componentsWithURL:url resolvingAgainstBaseURL:NO]; 403| 0| NSURLQueryItem *sfvcQueryItem = [[NSURLQueryItem alloc] initWithName:@"sfvc" value:@"1"]; 404| 0| components.queryItems = [components.queryItems arrayByAddingObject:sfvcQueryItem]; 405| 0| url = components.URL; 406| 0| FBSDKContainerViewController *container = [FBSDKContainerViewController new]; 407| 0| container.delegate = self; 408| 0| if (parent.transitionCoordinator != nil) { 409| | // Wait until the transition is finished before presenting SafariVC to avoid a blank screen. 410| 0| [parent.transitionCoordinator animateAlongsideTransition:NULL completion:^(id context) { 411| | // Note SFVC init must occur inside block to avoid blank screen. 412| 0| self->_safariViewController = [[SFSafariViewControllerClass alloc] initWithURL:url]; 413| | // Disable dismissing with edge pan gesture 414| 0| self->_safariViewController.modalPresentationStyle = UIModalPresentationOverFullScreen; 415| 0| [self->_safariViewController performSelector:@selector(setDelegate:) withObject:self]; 416| 0| [container displayChildController:self->_safariViewController]; 417| 0| [parent presentViewController:container animated:YES completion:nil]; 418| 0| }]; 419| 0| } else { 420| 0| _safariViewController = [[SFSafariViewControllerClass alloc] initWithURL:url]; 421| | // Disable dismissing with edge pan gesture 422| 0| _safariViewController.modalPresentationStyle = UIModalPresentationOverFullScreen; 423| 0| [_safariViewController performSelector:@selector(setDelegate:) withObject:self]; 424| 0| [container displayChildController:_safariViewController]; 425| 0| [parent presentViewController:container animated:YES completion:nil]; 426| 0| } 427| | 428| | // Assuming Safari View Controller always opens 429| 0| if (handler) { 430| 0| handler(YES, nil); 431| 0| } 432| 0| } else { 433| 0| [self openURL:url sender:sender handler:handler]; 434| 0| } 435| 0|} 436| | 437| |- (void)openURLWithAuthenticationSession:(NSURL *)url 438| 0|{ 439| 0| Class AuthenticationSessionClass = fbsdkdfl_ASWebAuthenticationSessionClass(); 440| | 441| 0| if (!AuthenticationSessionClass) { 442| 0| AuthenticationSessionClass = fbsdkdfl_SFAuthenticationSessionClass(); 443| 0| } 444| | 445| 0| if (AuthenticationSessionClass != nil) { 446| 0| if (_authenticationSession != nil) { 447| 0| [self.logger logEntry:@"There is already a request for authenticated session. Cancelling active SFAuthenticationSession before starting the new one."]; 448| 0| [_authenticationSession cancel]; 449| 0| } 450| 0| _authenticationSession = [[AuthenticationSessionClass alloc] initWithURL:url 451| 0| callbackURLScheme:self.appURLSchemeProvider.appURLScheme 452| 0| completionHandler:_authenticationSessionCompletionHandler]; 453| 0| if (@available(iOS 13.0, *)) { 454| 0| if ([_authenticationSession respondsToSelector:@selector(setPresentationContextProvider:)]) { 455| 0| [_authenticationSession setPresentationContextProvider:self]; 456| 0| } 457| 0| } 458| 0| _authenticationSessionState = FBSDKAuthenticationSessionStarted; 459| 0| [_authenticationSession start]; 460| 0| } 461| 0|} 462| | 463| |- (void)setSessionCompletionHandlerFromHandler:(FBSDKSuccessBlock)handler 464| 0|{ 465| 0| __weak FBSDKBridgeAPI *weakSelf = self; 466| 0| _authenticationSessionCompletionHandler = ^(NSURL *aURL, NSError *error) { 467| 0| FBSDKBridgeAPI *strongSelf = weakSelf; 468| 0| BOOL didSucceed = (error == nil && aURL != nil); 469| 0| handler(didSucceed, error); 470| 0| if (didSucceed) { 471| 0| [strongSelf application:[UIApplication sharedApplication] openURL:aURL sourceApplication:@"com.apple" annotation:nil]; 472| 0| } 473| 0| strongSelf->_authenticationSession = nil; 474| 0| strongSelf->_authenticationSessionCompletionHandler = nil; 475| 0| strongSelf->_authenticationSessionState = FBSDKAuthenticationSessionNone; 476| 0| }; 477| 0|} 478| | 479| |- (FBSDKAuthenticationCompletionHandler)sessionCompletionHandler 480| 0|{ 481| 0| return _authenticationSessionCompletionHandler; 482| 0|} 483| | 484| | #pragma mark -- SFSafariViewControllerDelegate 485| | 486| |// This means the user tapped "Done" which we should treat as a cancellation. 487| |- (void)safariViewControllerDidFinish:(UIViewController *)safariViewController 488| 0|{ 489| 0| if (_pendingURLOpen) { 490| 0| id pendingURLOpen = _pendingURLOpen; 491| | 492| 0| _pendingURLOpen = nil; 493| | 494| 0| [pendingURLOpen application:nil 495| 0| openURL:nil 496| 0| sourceApplication:nil 497| 0| annotation:nil]; 498| 0| } 499| 0| [self _cancelBridgeRequest]; 500| 0| _safariViewController = nil; 501| 0|} 502| | 503| | #pragma mark -- FBSDKContainerViewControllerDelegate 504| | 505| |- (void)viewControllerDidDisappear:(FBSDKContainerViewController *)viewController animated:(BOOL)animated 506| 0|{ 507| 0| if (_safariViewController) { 508| 0| [self.logger logEntry:@"**ERROR**:\n The SFSafariViewController's parent view controller was dismissed.\n" 509| 0| "This can happen if you are triggering login from a UIAlertController. Instead, make sure your top most view " 510| 0| "controller will not be prematurely dismissed."]; 511| 0| [self safariViewControllerDidFinish:_safariViewController]; 512| 0| } 513| 0|} 514| | 515| | #pragma mark - Helper Methods 516| | 517| |- (BOOL)_handleBridgeAPIResponseURL:(NSURL *)responseURL sourceApplication:(NSString *)sourceApplication 518| 0|{ 519| 0| NSObject *request = _pendingRequest; 520| 0| FBSDKBridgeAPIResponseBlock completionBlock = _pendingRequestCompletionBlock; 521| 0| _pendingRequest = nil; 522| 0| _pendingRequestCompletionBlock = NULL; 523| 0| if (![responseURL.scheme isEqualToString:[self.appURLSchemeProvider appURLScheme]]) { 524| 0| return NO; 525| 0| } 526| 0| if (![responseURL.host isEqualToString:@"bridge"]) { 527| 0| return NO; 528| 0| } 529| 0| if (!request) { 530| 0| return NO; 531| 0| } 532| 0| if (!completionBlock) { 533| 0| return YES; 534| 0| } 535| 0| NSError *error; 536| 0| FBSDKBridgeAPIResponse *response = [self.bridgeAPIResponseFactory createResponseWithRequest:request 537| 0| responseURL:responseURL 538| 0| sourceApplication:sourceApplication 539| 0| error:&error]; 540| 0| if (response) { 541| 0| completionBlock(response); 542| 0| return YES; 543| 0| } else if (error) { 544| 0| if (error.code == FBSDKErrorBridgeAPIResponse) { 545| 0| return NO; 546| 0| } else { 547| 0| completionBlock([self.bridgeAPIResponseFactory createResponseWithRequest:request error:error]); 548| 0| return YES; 549| 0| } 550| 0| } else { 551| | // This should not be reachable anymore. 552| 0| return NO; 553| 0| } 554| 0|} 555| | 556| |- (void)_cancelBridgeRequest 557| 0|{ 558| 0| if (_pendingRequest && _pendingRequestCompletionBlock) { 559| 0| _pendingRequestCompletionBlock([FBSDKBridgeAPIResponse bridgeAPIResponseCancelledWithRequest:_pendingRequest]); 560| 0| } 561| 0| _pendingRequest = nil; 562| 0| _pendingRequestCompletionBlock = NULL; 563| 0|} 564| | 565| | #pragma clang diagnostic push 566| | #pragma clang diagnostic ignored "-Wdeprecated-declarations" 567| | #pragma mark - ASWebAuthenticationPresentationContextProviding 568| | #if __IPHONE_OS_VERSION_MAX_ALLOWED >= 130000 569| |- (ASPresentationAnchor)presentationAnchorForWebAuthenticationSession:(ASWebAuthenticationSession *)session API_AVAILABLE(ios(13.0)) 570| 0|{ 571| | #else 572| |- (UIWindow *)presentationAnchorForWebAuthenticationSession:(id)session API_AVAILABLE(ios(11.0)) { 573| |#endif 574| 0| return UIApplication.sharedApplication.keyWindow; 575| 0|} 576| | #pragma clang diagnostic pop 577| | 578| | #pragma mark - Testability 579| | 580| | #if DEBUG 581| | #if FBSDKTEST 582| | 583| |- (id)authenticationSession 584| 0|{ 585| 0| return _authenticationSession; 586| 0|} 587| | 588| |- (void)setAuthenticationSession:(id)session 589| 0|{ 590| 0| _authenticationSession = session; 591| 0|} 592| | 593| |- (FBSDKAuthenticationSession)authenticationSessionState 594| 0|{ 595| 0| return _authenticationSessionState; 596| 0|} 597| | 598| |- (void)setAuthenticationSessionState:(FBSDKAuthenticationSession)state 599| 0|{ 600| 0| _authenticationSessionState = state; 601| 0|} 602| | 603| |- (FBSDKAuthenticationCompletionHandler)authenticationSessionCompletionHandler 604| 0|{ 605| 0| return _authenticationSessionCompletionHandler; 606| 0|} 607| | 608| |- (void)setAuthenticationSessionCompletionHandler:(FBSDKAuthenticationCompletionHandler)handler 609| 0|{ 610| 0| _authenticationSessionCompletionHandler = handler; 611| 0|} 612| | 613| |- (void)setActive:(BOOL)isActive 614| 0|{ 615| 0| _active = isActive; 616| 0|} 617| | 618| |- (BOOL)expectingBackground 619| 0|{ 620| 0| return _expectingBackground; 621| 0|} 622| | 623| |- (void)setExpectingBackground:(BOOL)isExpectingBackground 624| 0|{ 625| 0| _expectingBackground = isExpectingBackground; 626| 0|} 627| | 628| |- (id)pendingUrlOpen 629| 0|{ 630| 0| return _pendingURLOpen; 631| 0|} 632| | 633| |- (void)setPendingUrlOpen:(id)opening 634| 0|{ 635| 0| _pendingURLOpen = opening; 636| 0|} 637| | 638| |- (UIViewController *)safariViewController 639| 0|{ 640| 0| return _safariViewController; 641| 0|} 642| | 643| |- (void)setSafariViewController:(nullable UIViewController *)controller 644| 0|{ 645| 0| _safariViewController = controller; 646| 0|} 647| | 648| |- (BOOL)isDismissingSafariViewController 649| 0|{ 650| 0| return _isDismissingSafariViewController; 651| 0|} 652| | 653| |- (void)setIsDismissingSafariViewController:(BOOL)isDismissing 654| 0|{ 655| 0| _isDismissingSafariViewController = isDismissing; 656| 0|} 657| | 658| |- (NSObject *)pendingRequest 659| 0|{ 660| 0| return _pendingRequest; 661| 0|} 662| | 663| |- (void)setPendingRequest:(NSObject *)newValue 664| 0|{ 665| 0| _pendingRequest = newValue; 666| 0|} 667| | 668| |- (FBSDKBridgeAPIResponseBlock)pendingRequestCompletionBlock 669| 0|{ 670| 0| return _pendingRequestCompletionBlock; 671| 0|} 672| | 673| |- (void)setPendingRequestCompletionBlock:(FBSDKBridgeAPIResponseBlock)newValue 674| 0|{ 675| 0| _pendingRequestCompletionBlock = newValue; 676| 0|} 677| | 678| |- (id)processInfo 679| 0|{ 680| 0| return _processInfo; 681| 0|} 682| | 683| | #endif 684| | #endif 685| | 686| |@end 687| | 688| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKBridgeAPIResponse.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKBridgeAPIResponse.h" 24| | 25| | #import "FBSDKBridgeAPIRequest+Private.h" 26| | #import "FBSDKConstants.h" 27| | #import "FBSDKCoreKitBasicsImport.h" 28| | #import "FBSDKInternalUtility.h" 29| | #import "FBSDKOperatingSystemVersionComparing.h" 30| | #import "NSProcessInfo+Protocols.h" 31| | 32| |@interface FBSDKBridgeAPIResponse () 33| |- (instancetype)initWithRequest:(id)request 34| | responseParameters:(NSDictionary *)responseParameters 35| | cancelled:(BOOL)cancelled 36| | error:(NSError *)error 37| | NS_DESIGNATED_INITIALIZER; 38| |@end 39| | 40| |@implementation FBSDKBridgeAPIResponse 41| | 42| | #pragma mark - Class Methods 43| | 44| |+ (instancetype)bridgeAPIResponseWithRequest:(id)request error:(NSError *)error 45| 0|{ 46| 0| return [[self alloc] initWithRequest:request 47| 0| responseParameters:nil 48| 0| cancelled:NO 49| 0| error:error]; 50| 0|} 51| | 52| |+ (instancetype)bridgeAPIResponseWithRequest:(NSObject *)request 53| | responseURL:(NSURL *)responseURL 54| | sourceApplication:(NSString *)sourceApplication 55| | error:(NSError *__autoreleasing *)errorRef 56| 0|{ 57| 0| return [self bridgeAPIResponseWithRequest:request 58| 0| responseURL:responseURL 59| 0| sourceApplication:sourceApplication 60| 0| osVersionComparer:NSProcessInfo.processInfo 61| 0| error:errorRef]; 62| 0|} 63| | 64| |+ (instancetype)bridgeAPIResponseWithRequest:(NSObject *)request 65| | responseURL:(NSURL *)responseURL 66| | sourceApplication:(NSString *)sourceApplication 67| | osVersionComparer:(id)comparer 68| | error:(NSError *__autoreleasing *)errorRef 69| 0|{ 70| 0| FBSDKBridgeAPIProtocolType protocolType = request.protocolType; 71| 0| NSOperatingSystemVersion iOS13Version = { .majorVersion = 13, .minorVersion = 0, .patchVersion = 0 }; 72| 0| if ([comparer isOperatingSystemAtLeastVersion:iOS13Version]) { 73| | // SourceApplication is not available in iOS 13. 74| | // https://forums.developer.apple.com/thread/119118 75| 0| } else { 76| 0| switch (protocolType) { 77| 0| case FBSDKBridgeAPIProtocolTypeNative: { 78| 0| if (![FBSDKInternalUtility isFacebookBundleIdentifier:sourceApplication]) { 79| 0| if (errorRef != NULL) { 80| 0| *errorRef = [[NSError alloc] initWithDomain:FBSDKErrorDomain 81| 0| code:FBSDKErrorBridgeAPIResponse 82| 0| userInfo:nil]; 83| 0| } 84| 0| return nil; 85| 0| } 86| 0| break; 87| 0| } 88| 0| case FBSDKBridgeAPIProtocolTypeWeb: { 89| 0| if (![FBSDKInternalUtility isSafariBundleIdentifier:sourceApplication]) { 90| 0| if (errorRef != NULL) { 91| 0| *errorRef = [[NSError alloc] initWithDomain:FBSDKErrorDomain 92| 0| code:FBSDKErrorBridgeAPIResponse 93| 0| userInfo:nil]; 94| 0| } 95| 0| return nil; 96| 0| } 97| 0| break; 98| 0| } 99| 0| } 100| 0| } 101| 0| NSDictionary *const queryParameters = [FBSDKBasicUtility dictionaryWithQueryString:responseURL.query]; 102| 0| id protocol = request.protocol; 103| 0| BOOL cancelled; 104| 0| NSError *error; 105| 0| NSDictionary *responseParameters = [protocol responseParametersForActionID:request.actionID 106| 0| queryParameters:queryParameters 107| 0| cancelled:&cancelled 108| 0| error:&error]; 109| 0| if (errorRef != NULL) { 110| 0| *errorRef = error; 111| 0| } 112| 0| if (!responseParameters) { 113| 0| if (errorRef != NULL) { 114| 0| *errorRef = [[NSError alloc] initWithDomain:FBSDKErrorDomain code:FBSDKErrorBridgeAPIResponse userInfo:nil]; 115| 0| } 116| 0| return nil; 117| 0| } 118| 0| return [[self alloc] initWithRequest:request 119| 0| responseParameters:responseParameters 120| 0| cancelled:cancelled 121| 0| error:error]; 122| 0|} 123| | 124| |+ (instancetype)bridgeAPIResponseCancelledWithRequest:(NSObject *)request 125| 0|{ 126| 0| return [[self alloc] initWithRequest:request 127| 0| responseParameters:nil 128| 0| cancelled:YES 129| 0| error:nil]; 130| 0|} 131| | 132| | #pragma mark - Object Lifecycle 133| | 134| |- (instancetype)initWithRequest:(NSObject *)request 135| | responseParameters:(NSDictionary *)responseParameters 136| | cancelled:(BOOL)cancelled 137| | error:(NSError *)error 138| 0|{ 139| 0| if ((self = [super init])) { 140| 0| _request = [request copy]; 141| 0| _responseParameters = [responseParameters copy]; 142| 0| _cancelled = cancelled; 143| 0| _error = [error copy]; 144| 0| } 145| 0| return self; 146| 0|} 147| | 148| | #pragma mark - NSCopying 149| | 150| |- (id)copyWithZone:(NSZone *)zone 151| 0|{ 152| 0| return self; 153| 0|} 154| | 155| |@end 156| | 157| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKButton.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKButton.h" 20| |#import "FBSDKButton+Subclass.h" 21| | 22| |#import "FBSDKAccessToken.h" 23| |#import "FBSDKAccessToken+AccessTokenProtocols.h" 24| |#import "FBSDKAppEvents+Internal.h" 25| |#import "FBSDKApplicationLifecycleNotifications.h" 26| |#import "FBSDKGraphRequestFactory.h" 27| |#import "FBSDKLogo.h" 28| |#import "FBSDKUIUtility.h" 29| |#import "FBSDKViewImpressionTracker.h" 30| |#import "NSNotificationCenter+Extensions.h" 31| | 32| 0|#define HEIGHT_TO_FONT_SIZE 0.47 33| 0|#define HEIGHT_TO_MARGIN 0.27 34| 0|#define HEIGHT_TO_PADDING 0.23 35| 0|#define HEIGHT_TO_TEXT_PADDING_CORRECTION 0.08 36| | 37| |@interface FBSDKButton () 38| | 39| |@property (class, nonatomic) id applicationActivationNotifier; 40| | 41| |@end 42| | 43| |@implementation FBSDKButton 44| |{ 45| | BOOL _skipIntrinsicContentSizing; 46| | BOOL _isExplicitlyDisabled; 47| |} 48| | 49| |static id _applicationActivationNotifier; 50| | 51| |+ (id)applicationActivationNotifier 52| 0|{ 53| 0| return _applicationActivationNotifier; 54| 0|} 55| | 56| |+ (void)setApplicationActivationNotifier:(id)notifier 57| 0|{ 58| 0| _applicationActivationNotifier = notifier; 59| 0|} 60| | 61| |#pragma mark - Object Lifecycle 62| | 63| |- (instancetype)initWithFrame:(CGRect)frame 64| 0|{ 65| 0| if ((self = [super initWithFrame:frame])) { 66| 0| _skipIntrinsicContentSizing = YES; 67| 0| [self configureButton]; 68| 0| _skipIntrinsicContentSizing = NO; 69| 0| } 70| 0| return self; 71| 0|} 72| | 73| |- (void)awakeFromNib 74| 0|{ 75| 0| [super awakeFromNib]; 76| 0| _skipIntrinsicContentSizing = YES; 77| 0| [self configureButton]; 78| 0| _skipIntrinsicContentSizing = NO; 79| 0|} 80| | 81| |- (void)dealloc 82| 0|{ 83| 0| [[NSNotificationCenter defaultCenter] removeObserver:self]; 84| 0|} 85| | 86| |#pragma mark - Properties 87| | 88| |- (void)setEnabled:(BOOL)enabled 89| 0|{ 90| 0| _isExplicitlyDisabled = !enabled; 91| 0| [self checkImplicitlyDisabled]; 92| 0|} 93| | 94| |#pragma mark - Layout 95| | 96| |- (CGRect)imageRectForContentRect:(CGRect)contentRect 97| 0|{ 98| 0| if (self.hidden || CGRectIsEmpty(self.bounds)) { 99| 0| return CGRectZero; 100| 0| } 101| 0| CGRect imageRect = UIEdgeInsetsInsetRect(contentRect, self.imageEdgeInsets); 102| 0| CGFloat margin = [self _marginForHeight:[self _heightForContentRect:contentRect]]; 103| 0| imageRect = CGRectInset(imageRect, margin, margin); 104| 0| imageRect.size.width = CGRectGetHeight(imageRect); 105| 0| return imageRect; 106| 0|} 107| | 108| |- (CGSize)intrinsicContentSize 109| 0|{ 110| 0| if (_skipIntrinsicContentSizing) { 111| 0| return CGSizeZero; 112| 0| } 113| 0| _skipIntrinsicContentSizing = YES; 114| 0| CGSize size = [self sizeThatFits:CGSizeMake(CGFLOAT_MAX, CGFLOAT_MAX)]; 115| 0| _skipIntrinsicContentSizing = NO; 116| 0| return size; 117| 0|} 118| | 119| |- (CGSize)sizeThatFits:(CGSize)size 120| 0|{ 121| 0| if (self.hidden) { 122| 0| return CGSizeZero; 123| 0| } 124| 0| CGSize normalSize = [self sizeThatFits:size title:[self titleForState:UIControlStateNormal]]; 125| 0| CGSize selectedSize = [self sizeThatFits:size title:[self titleForState:UIControlStateSelected]]; 126| 0| return CGSizeMake(MAX(normalSize.width, selectedSize.width), MAX(normalSize.height, selectedSize.height)); 127| 0|} 128| | 129| |- (void)sizeToFit 130| 0|{ 131| 0| CGRect bounds = self.bounds; 132| 0| bounds.size = [self sizeThatFits:CGSizeMake(CGFLOAT_MAX, CGFLOAT_MAX)]; 133| 0| self.bounds = bounds; 134| 0|} 135| | 136| |- (CGRect)titleRectForContentRect:(CGRect)contentRect 137| 0|{ 138| 0| if (self.hidden || CGRectIsEmpty(self.bounds)) { 139| 0| return CGRectZero; 140| 0| } 141| 0| CGRect imageRect = [self imageRectForContentRect:contentRect]; 142| 0| CGFloat height = [self _heightForContentRect:contentRect]; 143| 0| CGFloat padding = [self _paddingForHeight:height]; 144| 0| CGFloat titleX = CGRectGetMaxX(imageRect) + padding; 145| 0| CGRect titleRect = CGRectMake(titleX, 0.0, CGRectGetWidth(contentRect) - titleX, CGRectGetHeight(contentRect)); 146| | 147| 0| UIEdgeInsets titleEdgeInsets = UIEdgeInsetsZero; 148| 0| if (!self.layer.needsLayout) { 149| 0| UILabel *titleLabel = self.titleLabel; 150| 0| if (titleLabel.textAlignment == NSTextAlignmentCenter) { 151| | // if the text is centered, we need to adjust the frame for the titleLabel based on the size of the text in order 152| | // to keep the text centered in the button without adding extra blank space to the right when unnecessary 153| | // 1. the text fits centered within the button without colliding with the image (imagePaddingWidth) 154| | // 2. the text would run into the image, so adjust the insets to effectively left align it (textPaddingWidth) 155| 0| CGSize titleSize = FBSDKTextSize( 156| 0| titleLabel.text, 157| 0| titleLabel.font, 158| 0| titleRect.size, 159| 0| titleLabel.lineBreakMode 160| 0| ); 161| 0| CGFloat titlePaddingWidth = (CGRectGetWidth(titleRect) - titleSize.width) / 2; 162| 0| CGFloat imagePaddingWidth = titleX / 2; 163| 0| CGFloat inset = MIN(titlePaddingWidth, imagePaddingWidth); 164| 0| titleEdgeInsets.left -= inset; 165| 0| titleEdgeInsets.right += inset; 166| 0| } 167| 0| } 168| 0| return UIEdgeInsetsInsetRect(titleRect, titleEdgeInsets); 169| 0|} 170| | 171| |#pragma mark - Subclass Methods 172| | 173| |- (void)logTapEventWithEventName:(NSString *)eventName parameters:(NSDictionary *)parameters 174| 0|{ 175| 0| [FBSDKAppEvents logInternalEvent:eventName 176| 0| parameters:parameters 177| 0| isImplicitlyLogged:YES 178| 0| accessToken:[FBSDKAccessToken currentAccessToken]]; 179| 0|} 180| | 181| |- (void)checkImplicitlyDisabled 182| 0|{ 183| 0| BOOL enabled = !_isExplicitlyDisabled && !self.implicitlyDisabled; 184| 0| BOOL currentEnabled = self.enabled; 185| 0| super.enabled = enabled; 186| 0| if (currentEnabled != enabled) { 187| 0| [self invalidateIntrinsicContentSize]; 188| 0| [self setNeedsLayout]; 189| 0| } 190| 0|} 191| | 192| |- (void)configureButton 193| 0|{ 194| 0| [self configureWithIcon:[self defaultIcon] 195| 0| title:nil 196| 0| backgroundColor:[self defaultBackgroundColor] 197| 0| highlightedColor:[self defaultHighlightedColor]]; 198| 0|} 199| | 200| |- (void)configureWithIcon:(FBSDKIcon *)icon 201| | title:(NSString *)title 202| | backgroundColor:(UIColor *)backgroundColor 203| | highlightedColor:(UIColor *)highlightedColor 204| 0|{ 205| 0| [self _configureWithIcon:icon 206| 0| title:title 207| 0| backgroundColor:backgroundColor 208| 0| highlightedColor:highlightedColor 209| 0| selectedTitle:nil 210| 0| selectedIcon:nil 211| 0| selectedColor:nil 212| 0| selectedHighlightedColor:nil]; 213| 0|} 214| | 215| |- (void) configureWithIcon:(FBSDKIcon *)icon 216| | title:(NSString *)title 217| | backgroundColor:(UIColor *)backgroundColor 218| | highlightedColor:(UIColor *)highlightedColor 219| | selectedTitle:(NSString *)selectedTitle 220| | selectedIcon:(FBSDKIcon *)selectedIcon 221| | selectedColor:(UIColor *)selectedColor 222| | selectedHighlightedColor:(UIColor *)selectedHighlightedColor 223| 0|{ 224| 0| [self _configureWithIcon:icon 225| 0| title:title 226| 0| backgroundColor:backgroundColor 227| 0| highlightedColor:highlightedColor 228| 0| selectedTitle:selectedTitle 229| 0| selectedIcon:selectedIcon 230| 0| selectedColor:selectedColor 231| 0| selectedHighlightedColor:selectedHighlightedColor]; 232| 0|} 233| | 234| |- (UIColor *)defaultBackgroundColor 235| 0|{ 236| 0| return [UIColor colorWithRed:24.0 / 255.0 green:119.0 / 255.0 blue:242.0 / 255.0 alpha:1.0]; 237| 0|} 238| | 239| |- (UIColor *)defaultDisabledColor 240| 0|{ 241| 0| return [UIColor colorWithRed:189.0 / 255.0 green:193.0 / 255.0 blue:201.0 / 255.0 alpha:1.0]; 242| 0|} 243| | 244| |- (UIFont *)defaultFont 245| 0|{ 246| 0| return [UIFont systemFontOfSize:14]; 247| 0|} 248| | 249| |- (UIColor *)defaultHighlightedColor 250| 0|{ 251| 0| return [UIColor colorWithRed:21.0 / 255.0 green:105.0 / 255.0 blue:214.0 / 255.0 alpha:1.0]; 252| 0|} 253| | 254| |- (FBSDKIcon *)defaultIcon 255| 0|{ 256| 0| return [FBSDKLogo new]; 257| 0|} 258| | 259| |- (UIColor *)defaultSelectedColor 260| 0|{ 261| 0| return [self defaultBackgroundColor]; 262| 0|} 263| | 264| |- (UIColor *)highlightedContentColor 265| 0|{ 266| 0| return [UIColor colorWithRed:218.0 / 255.0 green:221.0 / 255.0 blue:226.0 / 255.0 alpha:1.0]; 267| 0|} 268| | 269| |- (BOOL)isImplicitlyDisabled 270| 0|{ 271| 0| return NO; 272| 0|} 273| | 274| |- (CGSize)sizeThatFits:(CGSize)size title:(NSString *)title 275| 0|{ 276| 0| UIFont *font = self.titleLabel.font; 277| 0| CGFloat height = [self _heightForFont:font]; 278| | 279| 0| UIEdgeInsets contentEdgeInsets = self.contentEdgeInsets; 280| | 281| 0| CGSize constrainedContentSize = FBSDKEdgeInsetsInsetSize(size, contentEdgeInsets); 282| | 283| 0| CGSize titleSize = FBSDKTextSize(title, font, constrainedContentSize, self.titleLabel.lineBreakMode); 284| | 285| 0| CGFloat padding = [self _paddingForHeight:height]; 286| 0| CGFloat textPaddingCorrection = [self _textPaddingCorrectionForHeight:height]; 287| 0| CGSize contentSize = CGSizeMake(height + padding + titleSize.width - textPaddingCorrection, height); 288| 0| return FBSDKEdgeInsetsOutsetSize(contentSize, contentEdgeInsets); 289| 0|} 290| | 291| |#pragma mark - Helper Methods 292| | 293| |- (void)_applicationDidBecomeActiveNotification:(NSNotification *)notification 294| 0|{ 295| 0| [self checkImplicitlyDisabled]; 296| 0|} 297| | 298| |- (UIImage *)_backgroundImageWithColor:(UIColor *)color cornerRadius:(CGFloat)cornerRadius scale:(CGFloat)scale 299| 0|{ 300| 0| CGFloat size = 1.0 + 2 * cornerRadius; 301| 0| UIGraphicsBeginImageContextWithOptions(CGSizeMake(size, size), NO, scale); 302| 0| CGContextRef context = UIGraphicsGetCurrentContext(); 303| 0| CGContextSetFillColorWithColor(context, color.CGColor); 304| 0| CGMutablePathRef path = CGPathCreateMutable(); 305| 0| CGPathMoveToPoint(path, NULL, cornerRadius + 1.0, 0.0); 306| 0| CGPathAddArcToPoint(path, NULL, size, 0.0, size, cornerRadius, cornerRadius); 307| 0| CGPathAddLineToPoint(path, NULL, size, cornerRadius + 1.0); 308| 0| CGPathAddArcToPoint(path, NULL, size, size, cornerRadius + 1.0, size, cornerRadius); 309| 0| CGPathAddLineToPoint(path, NULL, cornerRadius, size); 310| 0| CGPathAddArcToPoint(path, NULL, 0.0, size, 0.0, cornerRadius + 1.0, cornerRadius); 311| 0| CGPathAddLineToPoint(path, NULL, 0.0, cornerRadius); 312| 0| CGPathAddArcToPoint(path, NULL, 0.0, 0.0, cornerRadius, 0.0, cornerRadius); 313| 0| CGPathCloseSubpath(path); 314| 0| CGContextAddPath(context, path); 315| 0| CGPathRelease(path); 316| 0| CGContextFillPath(context); 317| 0| UIImage *image = UIGraphicsGetImageFromCurrentImageContext(); 318| 0| UIGraphicsEndImageContext(); 319| |#if TARGET_OS_TV 320| | return [image resizableImageWithCapInsets:UIEdgeInsetsMake(cornerRadius, cornerRadius, cornerRadius, cornerRadius) 321| | resizingMode:UIImageResizingModeStretch]; 322| |#else 323| 0| return [image stretchableImageWithLeftCapWidth:cornerRadius topCapHeight:cornerRadius]; 324| 0|#endif 325| 0|} 326| | 327| |- (void)_configureWithIcon:(FBSDKIcon *)icon 328| | title:(NSString *)title 329| | backgroundColor:(UIColor *)backgroundColor 330| | highlightedColor:(UIColor *)highlightedColor 331| | selectedTitle:(NSString *)selectedTitle 332| | selectedIcon:(FBSDKIcon *)selectedIcon 333| | selectedColor:(UIColor *)selectedColor 334| | selectedHighlightedColor:(UIColor *)selectedHighlightedColor 335| 0|{ 336| 0| [self checkImplicitlyDisabled]; 337| | 338| 0| if (!icon) { 339| 0| icon = [self defaultIcon]; 340| 0| } 341| 0| if (!selectedIcon) { 342| 0| selectedIcon = [self defaultIcon]; 343| 0| } 344| 0| if (!backgroundColor) { 345| 0| backgroundColor = [self defaultBackgroundColor]; 346| 0| } 347| 0| if (!highlightedColor) { 348| 0| highlightedColor = [self defaultHighlightedColor]; 349| 0| } 350| 0| if (!selectedColor) { 351| 0| selectedColor = [self defaultSelectedColor]; 352| 0| } 353| 0| if (!selectedHighlightedColor) { 354| 0| selectedHighlightedColor = highlightedColor; 355| 0| } 356| | 357| 0| self.adjustsImageWhenDisabled = NO; 358| 0| self.adjustsImageWhenHighlighted = NO; 359| 0| self.contentHorizontalAlignment = UIControlContentHorizontalAlignmentFill; 360| 0| self.contentVerticalAlignment = UIControlContentVerticalAlignmentFill; 361| 0| self.tintColor = [UIColor whiteColor]; 362| | 363| 0| BOOL forceSizeToFit = CGRectIsEmpty(self.bounds); 364| | 365| 0| CGFloat scale = [UIScreen mainScreen].scale; 366| 0| UIImage *backgroundImage; 367| | 368| 0| backgroundImage = [self _backgroundImageWithColor:backgroundColor cornerRadius:3.0 scale:scale]; 369| 0| [self setBackgroundImage:backgroundImage forState:UIControlStateNormal]; 370| |#if TARGET_OS_TV 371| | [self setBackgroundImage:backgroundImage forState:UIControlStateFocused]; 372| |#endif 373| | 374| 0| backgroundImage = [self _backgroundImageWithColor:highlightedColor cornerRadius:3.0 scale:scale]; 375| 0| [self setBackgroundImage:backgroundImage forState:UIControlStateHighlighted]; 376| | 377| 0| backgroundImage = [self _backgroundImageWithColor:[self defaultDisabledColor] cornerRadius:3.0 scale:scale]; 378| 0| [self setBackgroundImage:backgroundImage forState:UIControlStateDisabled]; 379| | 380| 0| if (selectedColor) { 381| 0| backgroundImage = [self _backgroundImageWithColor:selectedColor cornerRadius:3.0 scale:scale]; 382| 0| [self setBackgroundImage:backgroundImage forState:UIControlStateSelected]; 383| 0| } 384| | 385| 0| if (selectedHighlightedColor) { 386| 0| backgroundImage = [self _backgroundImageWithColor:selectedHighlightedColor cornerRadius:3.0 scale:scale]; 387| 0| [self setBackgroundImage:backgroundImage forState:UIControlStateSelected | UIControlStateHighlighted]; 388| | #if TARGET_OS_TV 389| | [self setBackgroundImage:backgroundImage forState:UIControlStateSelected | UIControlStateFocused]; 390| | #endif 391| 0| } 392| | 393| 0| [self setTitleColor:[UIColor whiteColor] forState:UIControlStateNormal]; 394| 0| [self setTitleColor:[self highlightedContentColor] forState:UIControlStateHighlighted | UIControlStateSelected]; 395| | 396| 0| [self setTitle:title forState:UIControlStateNormal]; 397| |#if TARGET_OS_TV 398| | [self setTitle:title forState:UIControlStateFocused]; 399| |#endif 400| 0| if (selectedTitle) { 401| 0| [self setTitle:selectedTitle forState:UIControlStateSelected]; 402| 0| [self setTitle:selectedTitle forState:UIControlStateSelected | UIControlStateHighlighted]; 403| | #if TARGET_OS_TV 404| | [self setTitle:selectedTitle forState:UIControlStateSelected | UIControlStateFocused]; 405| | #endif 406| 0| } 407| | 408| 0| UILabel *titleLabel = self.titleLabel; 409| 0| titleLabel.lineBreakMode = NSLineBreakByClipping; 410| 0| UIFont *font = [self defaultFont]; 411| 0| titleLabel.font = font; 412| | 413| 0| CGSize imageSize = CGSizeMake(font.pointSize, font.pointSize); 414| 0| UIImage *image = [icon imageWithSize:imageSize]; 415| 0| image = [image resizableImageWithCapInsets:UIEdgeInsetsZero resizingMode:UIImageResizingModeStretch]; 416| 0| [self setImage:image forState:UIControlStateNormal]; 417| |#if TARGET_OS_TV 418| | [self setImage:image forState:UIControlStateFocused]; 419| |#endif 420| | 421| 0| if (selectedIcon) { 422| 0| UIImage *selectedImage = [selectedIcon imageWithSize:imageSize]; 423| 0| selectedImage = [selectedImage resizableImageWithCapInsets:UIEdgeInsetsZero 424| 0| resizingMode:UIImageResizingModeStretch]; 425| 0| [self setImage:selectedImage forState:UIControlStateSelected]; 426| 0| [self setImage:selectedImage forState:UIControlStateSelected | UIControlStateHighlighted]; 427| | #if TARGET_OS_TV 428| | [self setImage:selectedImage forState:UIControlStateSelected | UIControlStateFocused]; 429| | #endif 430| 0| } 431| | 432| 0| if (forceSizeToFit) { 433| 0| [self sizeToFit]; 434| 0| } 435| 0| [[NSNotificationCenter defaultCenter] addObserver:self 436| 0| selector:@selector(_applicationDidBecomeActiveNotification:) 437| 0| name:FBSDKApplicationDidBecomeActiveNotification 438| 0| object:self.class.applicationActivationNotifier]; 439| 0|} 440| | 441| |- (CGFloat)_fontSizeForHeight:(CGFloat)height 442| 0|{ 443| 0| return floorf(height * HEIGHT_TO_FONT_SIZE); 444| 0|} 445| | 446| |- (CGFloat)_heightForContentRect:(CGRect)contentRect 447| 0|{ 448| 0| UIEdgeInsets contentEdgeInsets = self.contentEdgeInsets; 449| 0| return contentEdgeInsets.top + CGRectGetHeight(contentRect) + contentEdgeInsets.bottom; 450| 0|} 451| | 452| |- (CGFloat)_heightForFont:(UIFont *)font 453| 0|{ 454| 0| return floorf(font.pointSize / (1 - 2 * HEIGHT_TO_MARGIN)); 455| 0|} 456| | 457| |- (CGFloat)_marginForHeight:(CGFloat)height 458| 0|{ 459| 0| return floorf(height * HEIGHT_TO_MARGIN); 460| 0|} 461| | 462| |- (CGFloat)_paddingForHeight:(CGFloat)height 463| 0|{ 464| 0| return roundf(height * HEIGHT_TO_PADDING) - [self _textPaddingCorrectionForHeight:height]; 465| 0|} 466| | 467| |- (CGFloat)_textPaddingCorrectionForHeight:(CGFloat)height 468| 0|{ 469| 0| return floorf(height * HEIGHT_TO_TEXT_PADDING_CORRECTION); 470| 0|} 471| | 472| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKCoreKitVersions.h: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| 0|#define FBSDK_VERSION_STRING @"11.0.1" 20| 0|#define FBSDK_TARGET_PLATFORM_VERSION @"v11.0" /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKImpressionTrackingButton.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKImpressionTrackingButton.h" 20| | 21| |#import "FBSDKAccessToken.h" 22| |#import "FBSDKAccessToken+AccessTokenProtocols.h" 23| |#import "FBSDKAppEvents.h" 24| |#import "FBSDKAppEvents+EventLogging.h" 25| |#import "FBSDKButtonImpressionTracking.h" 26| |#import "FBSDKGraphRequestFactory.h" 27| |#import "FBSDKViewImpressionTracker.h" 28| |#import "NSNotificationCenter+Extensions.h" 29| | 30| |@implementation FBSDKImpressionTrackingButton 31| | 32| |- (void)layoutSubviews 33| 0|{ 34| | // automatic impression tracking if the button conforms to FBSDKButtonImpressionTracking 35| 0| if ([self conformsToProtocol:@protocol(FBSDKButtonImpressionTracking)]) { 36| 0| NSString *eventName = ((id)self).impressionTrackingEventName; 37| 0| NSString *identifier = ((id)self).impressionTrackingIdentifier; 38| 0| NSDictionary *parameters = ((id)self).analyticsParameters; 39| 0| if (eventName && identifier) { 40| 0| FBSDKViewImpressionTracker *impressionTracker 41| 0| = [FBSDKViewImpressionTracker impressionTrackerWithEventName:eventName 42| 0| graphRequestProvider:[FBSDKGraphRequestFactory new] 43| 0| eventLogger:FBSDKAppEvents.singleton 44| 0| notificationObserver:NSNotificationCenter.defaultCenter 45| 0| tokenWallet:FBSDKAccessToken.class]; 46| 0| [impressionTracker logImpressionWithIdentifier:identifier parameters:parameters]; 47| 0| } 48| 0| } 49| 0| [super layoutSubviews]; 50| 0|} 51| | 52| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKLocation.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKLocation.h" 20| | 21| |#import "FBSDKCoreKitBasicsImport.h" 22| |#import "FBSDKMath.h" 23| | 24| |NSString *const FBSDKLocationIdCodingKey = @"FBSDKLocationIdCodingKey"; 25| |NSString *const FBSDKLocationNameCodingKey = @"FBSDKLocationNameCodingKey"; 26| | 27| |@implementation FBSDKLocation 28| | 29| |- (instancetype)initWithId:(NSString *)id 30| | name:(NSString *)name 31| 0|{ 32| 0| if (self = [super init]) { 33| 0| _id = id; 34| 0| _name = name; 35| 0| } 36| | 37| 0| return self; 38| 0|} 39| | 40| |+ (instancetype)locationFromDictionary:(NSDictionary *)dictionary 41| 0|{ 42| 0| if (![FBSDKTypeUtility dictionaryValue:dictionary]) { 43| 0| return nil; 44| 0| } 45| | 46| 0| NSString *id = [FBSDKTypeUtility stringValueOrNil:dictionary[@"id"]]; 47| 0| NSString *name = [FBSDKTypeUtility stringValueOrNil:dictionary[@"name"]]; 48| | 49| 0| if (id == nil || name == nil) { 50| 0| return nil; 51| 0| } 52| | 53| 0| return [[FBSDKLocation alloc] initWithId:id name:name]; 54| 0|} 55| | 56| |#pragma mark - Equality 57| | 58| |- (NSUInteger)hash 59| 0|{ 60| 0| NSUInteger subhashes[] = { 61| 0| _id.hash, 62| 0| _name.hash, 63| 0| }; 64| 0| return [FBSDKMath hashWithIntegerArray:subhashes count:sizeof(subhashes) / sizeof(subhashes[0])]; 65| 0|} 66| | 67| |- (BOOL)isEqual:(id)object 68| 0|{ 69| 0| if (self == object) { 70| 0| return YES; 71| 0| } 72| 0| if (![object isKindOfClass:[FBSDKLocation class]]) { 73| 0| return NO; 74| 0| } 75| 0| return [self isEqualToLocation:object]; 76| 0|} 77| | 78| |- (BOOL)isEqualToLocation:(FBSDKLocation *)location 79| 0|{ 80| 0| return [_id isEqualToString:location.id] && [_name isEqualToString:location.name]; 81| 0|} 82| | 83| |#pragma mark - NSCopying 84| | 85| |- (id)copyWithZone:(NSZone *)zone 86| 0|{ 87| | // we're immutable. 88| 0| return self; 89| 0|} 90| | 91| |#pragma mark NSCoding 92| |+ (BOOL)supportsSecureCoding 93| 0|{ 94| 0| return YES; 95| 0|} 96| | 97| |- (void)encodeWithCoder:(nonnull NSCoder *)coder 98| 0|{ 99| 0| [coder encodeObject:_id forKey:FBSDKLocationIdCodingKey]; 100| 0| [coder encodeObject:_name forKey:FBSDKLocationNameCodingKey]; 101| 0|} 102| | 103| |- (instancetype)initWithCoder:(nonnull NSCoder *)coder 104| 0|{ 105| 0| NSString *id = [coder decodeObjectOfClass:NSString.class forKey:FBSDKLocationIdCodingKey]; 106| 0| NSString *name = [coder decodeObjectOfClass:NSString.class forKey:FBSDKLocationNameCodingKey]; 107| | 108| 0| return [self initWithId:id name:name]; 109| 0|} 110| | 111| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKMeasurementEvent.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKLogger.h" 24| | #import "FBSDKMeasurementEvent_Internal.h" 25| | #import "FBSDKSettings.h" 26| | 27| | #if __IPHONE_OS_VERSION_MAX_ALLOWED >= __IPHONE_10_0 28| | 29| |NSNotificationName const FBSDKMeasurementEventNotification = @"com.facebook.facebook-objc-sdk.measurement_event"; 30| | 31| | #else 32| | 33| |NSString *const FBSDKMeasurementEventNotification = @"com.facebook.facebook-objc-sdk.measurement_event"; 34| | 35| | #endif 36| | 37| |NSString *const FBSDKMeasurementEventNotificationName = @"com.facebook.facebook-objc-sdk.measurement_event"; 38| | 39| |NSString *const FBSDKMeasurementEventNameKey = @"event_name"; 40| |NSString *const FBSDKMeasurementEventArgsKey = @"event_args"; 41| | 42| |/** app Link Event raised by this FBSDKURL */ 43| |NSString *const FBSDKAppLinkParseEventName = @"al_link_parse"; 44| |NSString *const FBSDKAppLinkNavigateInEventName = @"al_nav_in"; 45| | 46| |/** AppLink events raised in this class */ 47| |NSString *const FBSDKAppLinkNavigateOutEventName = @"al_nav_out"; 48| |NSString *const FBSDKAppLinkNavigateBackToReferrerEventName = @"al_ref_back_out"; 49| | 50| |@implementation FBSDKMeasurementEvent 51| | 52| |- (void)postNotificationForEventName:(NSString *)name 53| | args:(NSDictionary *)args 54| 0|{ 55| 0| if (!name) { 56| 0| [FBSDKLogger 57| 0| singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors 58| 0| logEntry:@"Warning: Missing event name when logging FBSDK measurement event.\nIgnoring this event in logging."]; 59| 0| return; 60| 0| } 61| 0| NSNotificationCenter *center = [NSNotificationCenter defaultCenter]; 62| 0| NSDictionary *userInfo = @{FBSDKMeasurementEventNameKey : name, 63| 0| FBSDKMeasurementEventArgsKey : args}; 64| | 65| 0| [center postNotificationName:FBSDKMeasurementEventNotification 66| 0| object:self 67| 0| userInfo:userInfo]; 68| 0|} 69| | 70| |+ (void)postNotificationForEventName:(NSString *)name 71| | args:(NSDictionary *)args 72| 0|{ 73| 0| [[self new] postNotificationForEventName:name args:args ?: @{}]; 74| 0|} 75| | 76| |@end 77| | 78| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKProfile.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKNotificationProtocols.h" 20| |#import "TargetConditionals.h" 21| | 22| |#if !TARGET_OS_TV 23| | 24| | #import "FBSDKProfile+Internal.h" 25| | 26| | #import "FBSDKCoreKitBasicsImport.h" 27| | #import "FBSDKLocation.h" 28| | #import "FBSDKUserAgeRange.h" 29| | 30| | #if __IPHONE_OS_VERSION_MAX_ALLOWED >= __IPHONE_10_0 31| | 32| |NSNotificationName const FBSDKProfileDidChangeNotification = @"com.facebook.sdk.FBSDKProfile.FBSDKProfileDidChangeNotification";; 33| | 34| | #else 35| | 36| |NSString *const FBSDKProfileDidChangeNotification = @"com.facebook.sdk.FBSDKProfile.FBSDKProfileDidChangeNotification";; 37| | 38| | #endif 39| | 40| |NSString *const FBSDKProfileChangeOldKey = @"FBSDKProfileOld"; 41| |NSString *const FBSDKProfileChangeNewKey = @"FBSDKProfileNew"; 42| |static NSString *const FBSDKProfileUserDefaultsKey = @"com.facebook.sdk.FBSDKProfile.currentProfile"; 43| |static FBSDKProfile *g_currentProfile; 44| |static NSDateFormatter *_dateFormatter; 45| | 46| 0| #define FBSDKPROFILE_USERID_KEY @"userID" 47| 0| #define FBSDKPROFILE_FIRSTNAME_KEY @"firstName" 48| 0| #define FBSDKPROFILE_MIDDLENAME_KEY @"middleName" 49| 0| #define FBSDKPROFILE_LASTNAME_KEY @"lastName" 50| 0| #define FBSDKPROFILE_NAME_KEY @"name" 51| 0| #define FBSDKPROFILE_LINKURL_KEY @"linkURL" 52| 0| #define FBSDKPROFILE_REFRESHDATE_KEY @"refreshDate" 53| 0| #define FBSDKPROFILE_IMAGEURL_KEY @"imageURL" 54| 0| #define FBSDKPROFILE_EMAIL_KEY @"email" 55| 0| #define FBSDKPROFILE_FRIENDIDS_KEY @"friendIDs" 56| 0| #define FBSDKPROFILE_IS_LIMITED_KEY @"isLimited" 57| 0| #define FBSDKPROFILE_BIRTHDAY_KEY @"birthday" 58| 0| #define FBSDKPROFILE_AGERANGE_KEY @"ageRange" 59| 0| #define FBSDKPROFILE_HOMETOWN_KEY @"hometown" 60| 0| #define FBSDKPROFILE_LOCATION_KEY @"location" 61| 0| #define FBSDKPROFILE_GENDER_KEY @"gender" 62| | 63| |// Once a day 64| 0| #define FBSDKPROFILE_STALE_IN_SECONDS (60 * 60 * 24) 65| | 66| |@interface FBSDKProfile () 67| | 68| |@property (nonatomic, assign) BOOL isLimited; 69| | 70| |@end 71| | 72| |@implementation FBSDKProfile 73| | 74| |static Class _accessTokenProvider = nil; 75| |static id _notificationCenter = nil; 76| | 77| |+ (Class)accessTokenProvider 78| 0|{ 79| 0| return _accessTokenProvider; 80| 0|} 81| | 82| |+ (id)notificationCenter 83| 0|{ 84| 0| return _notificationCenter; 85| 0|} 86| | 87| |- (instancetype)initWithUserID:(FBSDKUserIdentifier *)userID 88| | firstName:(NSString *)firstName 89| | middleName:(NSString *)middleName 90| | lastName:(NSString *)lastName 91| | name:(NSString *)name 92| | linkURL:(NSURL *)linkURL 93| | refreshDate:(NSDate *)refreshDate 94| 0|{ 95| 0| return [self initWithUserID:userID 96| 0| firstName:firstName 97| 0| middleName:middleName 98| 0| lastName:lastName 99| 0| name:name 100| 0| linkURL:linkURL 101| 0| refreshDate:refreshDate 102| 0| imageURL:nil 103| 0| email:nil 104| 0| friendIDs:nil 105| 0| birthday:nil 106| 0| ageRange:nil 107| 0| hometown:nil 108| 0| location:nil 109| 0| gender:nil]; 110| 0|} 111| | 112| |- (instancetype)initWithUserID:(FBSDKUserIdentifier *)userID 113| | firstName:(NSString *)firstName 114| | middleName:(NSString *)middleName 115| | lastName:(NSString *)lastName 116| | name:(NSString *)name 117| | linkURL:(NSURL *)linkURL 118| | refreshDate:(NSDate *)refreshDate 119| | imageURL:(NSURL *)imageURL 120| | email:(NSString *)email 121| 0|{ 122| 0| return [self initWithUserID:userID 123| 0| firstName:firstName 124| 0| middleName:middleName 125| 0| lastName:lastName 126| 0| name:name 127| 0| linkURL:linkURL 128| 0| refreshDate:refreshDate 129| 0| imageURL:imageURL 130| 0| email:email 131| 0| friendIDs:nil 132| 0| birthday:nil 133| 0| ageRange:nil 134| 0| hometown:nil 135| 0| location:nil 136| 0| gender:nil]; 137| 0|} 138| | 139| |- (instancetype)initWithUserID:(FBSDKUserIdentifier *)userID 140| | firstName:(NSString *)firstName 141| | middleName:(NSString *)middleName 142| | lastName:(NSString *)lastName 143| | name:(NSString *)name 144| | linkURL:(NSURL *)linkURL 145| | refreshDate:(NSDate *)refreshDate 146| | imageURL:(NSURL *)imageURL 147| | email:(NSString *)email 148| | friendIDs:(NSArray *)friendIDs 149| 0|{ 150| 0| return [self initWithUserID:userID 151| 0| firstName:firstName 152| 0| middleName:middleName 153| 0| lastName:lastName 154| 0| name:name 155| 0| linkURL:linkURL 156| 0| refreshDate:refreshDate 157| 0| imageURL:imageURL 158| 0| email:email 159| 0| friendIDs:friendIDs 160| 0| birthday:nil 161| 0| ageRange:nil 162| 0| hometown:nil 163| 0| location:nil 164| 0| gender:nil]; 165| 0|} 166| | 167| |- (instancetype)initWithUserID:(FBSDKUserIdentifier *)userID 168| | firstName:(NSString *)firstName 169| | middleName:(NSString *)middleName 170| | lastName:(NSString *)lastName 171| | name:(NSString *)name 172| | linkURL:(NSURL *)linkURL 173| | refreshDate:(NSDate *)refreshDate 174| | imageURL:(NSURL *)imageURL 175| | email:(NSString *)email 176| | friendIDs:(NSArray *)friendIDs 177| | birthday:(NSDate *)birthday 178| | ageRange:(FBSDKUserAgeRange *)ageRange 179| 0|{ 180| 0| return [self initWithUserID:userID 181| 0| firstName:firstName 182| 0| middleName:middleName 183| 0| lastName:lastName 184| 0| name:name 185| 0| linkURL:linkURL 186| 0| refreshDate:refreshDate 187| 0| imageURL:imageURL 188| 0| email:email 189| 0| friendIDs:friendIDs 190| 0| birthday:birthday 191| 0| ageRange:ageRange 192| 0| hometown:nil 193| 0| location:nil 194| 0| gender:nil]; 195| 0|} 196| | 197| |- (instancetype)initWithUserID:(FBSDKUserIdentifier *)userID 198| | firstName:(NSString *)firstName 199| | middleName:(NSString *)middleName 200| | lastName:(NSString *)lastName 201| | name:(NSString *)name 202| | linkURL:(NSURL *)linkURL 203| | refreshDate:(NSDate *)refreshDate 204| | imageURL:(NSURL *)imageURL 205| | email:(NSString *)email 206| | friendIDs:(NSArray *)friendIDs 207| | birthday:(NSDate *)birthday 208| | ageRange:(FBSDKUserAgeRange *)ageRange 209| | isLimited:(BOOL)isLimited 210| 0|{ 211| 0| return [self initWithUserID:userID 212| 0| firstName:firstName 213| 0| middleName:middleName 214| 0| lastName:lastName 215| 0| name:name 216| 0| linkURL:linkURL 217| 0| refreshDate:refreshDate 218| 0| imageURL:imageURL 219| 0| email:email 220| 0| friendIDs:friendIDs 221| 0| birthday:birthday 222| 0| ageRange:ageRange 223| 0| hometown:nil 224| 0| location:nil 225| 0| gender:nil 226| 0| isLimited:isLimited]; 227| 0|} 228| | 229| |- (instancetype)initWithUserID:(FBSDKUserIdentifier *)userID 230| | firstName:(NSString *)firstName 231| | middleName:(NSString *)middleName 232| | lastName:(NSString *)lastName 233| | name:(NSString *)name 234| | linkURL:(NSURL *)linkURL 235| | refreshDate:(NSDate *)refreshDate 236| | imageURL:(NSURL *)imageURL 237| | email:(NSString *)email 238| | friendIDs:(NSArray *)friendIDs 239| | birthday:(NSDate *)birthday 240| | ageRange:(FBSDKUserAgeRange *)ageRange 241| | hometown:(FBSDKLocation *)hometown 242| | location:(FBSDKLocation *)location 243| | gender:(NSString *)gender 244| | isLimited:(BOOL)isLimited 245| 0|{ 246| 0| self = [self initWithUserID:userID 247| 0| firstName:firstName 248| 0| middleName:middleName 249| 0| lastName:lastName 250| 0| name:name 251| 0| linkURL:linkURL 252| 0| refreshDate:refreshDate 253| 0| imageURL:imageURL 254| 0| email:email 255| 0| friendIDs:friendIDs 256| 0| birthday:birthday 257| 0| ageRange:ageRange 258| 0| hometown:hometown 259| 0| location:location 260| 0| gender:gender]; 261| 0| self.isLimited = isLimited; 262| | 263| 0| return self; 264| 0|} 265| | 266| |- (instancetype)initWithUserID:(FBSDKUserIdentifier *)userID 267| | firstName:(NSString *)firstName 268| | middleName:(NSString *)middleName 269| | lastName:(NSString *)lastName 270| | name:(NSString *)name 271| | linkURL:(NSURL *)linkURL 272| | refreshDate:(NSDate *)refreshDate 273| | imageURL:(NSURL *)imageURL 274| | email:(NSString *)email 275| | friendIDs:(NSArray *)friendIDs 276| | birthday:(NSDate *)birthday 277| | ageRange:(FBSDKUserAgeRange *)ageRange 278| | hometown:(FBSDKLocation *)hometown 279| | location:(FBSDKLocation *)location 280| | gender:(NSString *)gender 281| 0|{ 282| 0| if ((self = [super init])) { 283| 0| _userID = [userID copy]; 284| 0| _firstName = [firstName copy]; 285| 0| _middleName = [middleName copy]; 286| 0| _lastName = [lastName copy]; 287| 0| _name = [name copy]; 288| 0| _linkURL = [linkURL copy]; 289| 0| _refreshDate = [refreshDate copy] ?: [NSDate date]; 290| 0| _imageURL = [imageURL copy]; 291| 0| _email = [email copy]; 292| 0| _friendIDs = [friendIDs copy]; 293| 0| self.isLimited = NO; 294| 0| _birthday = [birthday copy]; 295| 0| _ageRange = [ageRange copy]; 296| 0| _hometown = [hometown copy]; 297| 0| _location = [location copy]; 298| 0| _gender = [gender copy]; 299| 0| } 300| 0| return self; 301| 0|} 302| | 303| |+ (nullable FBSDKProfile *)currentProfile 304| 0|{ 305| 0| return g_currentProfile; 306| 0|} 307| | 308| |+ (void)setCurrentProfile:(nullable FBSDKProfile *)profile 309| 0|{ 310| 0| [self setCurrentProfile:profile shouldPostNotification:YES]; 311| 0|} 312| | 313| |+ (void)setCurrentProfile:(nullable FBSDKProfile *)profile 314| | shouldPostNotification:(BOOL)shouldPostNotification 315| 0|{ 316| 0| if (profile != g_currentProfile && ![profile isEqualToProfile:g_currentProfile]) { 317| 0| [[self class] cacheProfile:profile]; 318| 0| NSMutableDictionary *userInfo = [NSMutableDictionary dictionary]; 319| | 320| 0| [FBSDKTypeUtility dictionary:userInfo setObject:profile forKey:FBSDKProfileChangeNewKey]; 321| 0| [FBSDKTypeUtility dictionary:userInfo setObject:g_currentProfile forKey:FBSDKProfileChangeOldKey]; 322| 0| g_currentProfile = profile; 323| | 324| 0| if (shouldPostNotification) { 325| 0| [_notificationCenter postNotificationName:FBSDKProfileDidChangeNotification 326| 0| object:[self class] 327| 0| userInfo:userInfo]; 328| 0| } 329| 0| } 330| 0|} 331| | 332| |- (NSURL *)imageURLForPictureMode:(FBSDKProfilePictureMode)mode size:(CGSize)size 333| 0|{ 334| 0| return [FBSDKProfile imageURLForProfileID:_userID PictureMode:mode size:size]; 335| 0|} 336| | 337| |+ (void)enableUpdatesOnAccessTokenChange:(BOOL)enable 338| 0|{ 339| 0| if (enable) { 340| 0| [_notificationCenter addObserver:self 341| 0| selector:@selector(observeChangeAccessTokenChange:) 342| 0| name:FBSDKAccessTokenDidChangeNotification 343| 0| object:nil]; 344| 0| } else { 345| 0| [_notificationCenter removeObserver:self]; 346| 0| } 347| 0|} 348| | 349| |+ (void)loadCurrentProfileWithCompletion:(FBSDKProfileBlock)completion 350| 0|{ 351| 0| [self loadProfileWithToken:[self.accessTokenProvider currentAccessToken] completion:completion]; 352| 0|} 353| | 354| | #pragma mark - NSCopying 355| | 356| |- (instancetype)copyWithZone:(NSZone *)zone 357| 0|{ 358| | // immutable 359| 0| return self; 360| 0|} 361| | 362| | #pragma mark - Equality 363| | 364| |- (NSUInteger)hash 365| 0|{ 366| 0| NSUInteger subhashes[] = { 367| 0| self.userID.hash, 368| 0| self.firstName.hash, 369| 0| self.middleName.hash, 370| 0| self.lastName.hash, 371| 0| self.name.hash, 372| 0| self.linkURL.hash, 373| 0| self.refreshDate.hash, 374| 0| self.imageURL.hash, 375| 0| self.email.hash, 376| 0| self.friendIDs.hash, 377| 0| self.birthday.hash, 378| 0| self.ageRange.hash, 379| 0| self.hometown.hash, 380| 0| self.location.hash, 381| 0| self.gender.hash, 382| 0| self.isLimited 383| 0| }; 384| 0| return [FBSDKMath hashWithIntegerArray:subhashes count:sizeof(subhashes) / sizeof(subhashes[0])]; 385| 0|} 386| | 387| |- (BOOL)isEqual:(id)object 388| 0|{ 389| 0| if (self == object) { 390| 0| return YES; 391| 0| } 392| 0| if (![object isKindOfClass:[FBSDKProfile class]]) { 393| 0| return NO; 394| 0| } 395| 0| return [self isEqualToProfile:object]; 396| 0|} 397| | 398| |- (BOOL)isEqualToProfile:(FBSDKProfile *)profile 399| 0|{ 400| 0| return ([_userID isEqualToString:profile.userID] 401| 0| && [_firstName isEqualToString:profile.firstName] 402| 0| && [_middleName isEqualToString:profile.middleName] 403| 0| && [_lastName isEqualToString:profile.lastName] 404| 0| && [_name isEqualToString:profile.name] 405| 0| && [_linkURL isEqual:profile.linkURL] 406| 0| && [_refreshDate isEqualToDate:profile.refreshDate] 407| 0| && [_imageURL isEqual:profile.imageURL] 408| 0| && [_email isEqualToString:profile.email] 409| 0| && [_friendIDs isEqualToArray:profile.friendIDs] 410| 0| && _isLimited == profile.isLimited 411| 0| && [_birthday isEqualToDate:profile.birthday] 412| 0| && [_ageRange isEqual:profile.ageRange] 413| 0| && [_hometown isEqual:profile.hometown] 414| 0| && [_location isEqual:profile.location] 415| 0| && [_gender isEqual:profile.gender]); 416| 0|} 417| | 418| | #pragma mark NSCoding 419| | 420| |+ (BOOL)supportsSecureCoding 421| 0|{ 422| 0| return YES; 423| 0|} 424| | 425| |- (instancetype)initWithCoder:(NSCoder *)decoder 426| 0|{ 427| 0| FBSDKUserIdentifier *userID = [decoder decodeObjectOfClass:[FBSDKUserIdentifier class] forKey:FBSDKPROFILE_USERID_KEY]; 428| 0| NSString *firstName = [decoder decodeObjectOfClass:[NSString class] forKey:FBSDKPROFILE_FIRSTNAME_KEY]; 429| 0| NSString *middleName = [decoder decodeObjectOfClass:[NSString class] forKey:FBSDKPROFILE_MIDDLENAME_KEY]; 430| 0| NSString *lastName = [decoder decodeObjectOfClass:[NSString class] forKey:FBSDKPROFILE_LASTNAME_KEY]; 431| 0| NSString *name = [decoder decodeObjectOfClass:[NSString class] forKey:FBSDKPROFILE_NAME_KEY]; 432| 0| NSURL *linkURL = [decoder decodeObjectOfClass:[NSURL class] forKey:FBSDKPROFILE_LINKURL_KEY]; 433| 0| NSDate *refreshDate = [decoder decodeObjectOfClass:[NSDate class] forKey:FBSDKPROFILE_REFRESHDATE_KEY]; 434| 0| NSURL *imageURL = [decoder decodeObjectOfClass:[NSURL class] forKey:FBSDKPROFILE_IMAGEURL_KEY]; 435| 0| NSString *email = [decoder decodeObjectOfClass:[NSString class] forKey:FBSDKPROFILE_EMAIL_KEY]; 436| 0| NSArray *friendIDs = [decoder decodeObjectOfClass:[NSArray class] forKey:FBSDKPROFILE_FRIENDIDS_KEY]; 437| 0| BOOL isLimited = [decoder decodeBoolForKey:FBSDKPROFILE_IS_LIMITED_KEY]; 438| 0| NSDate *birthday = [decoder decodeObjectOfClass:[NSDate class] forKey:FBSDKPROFILE_BIRTHDAY_KEY]; 439| 0| FBSDKUserAgeRange *ageRange = [decoder decodeObjectOfClass:[FBSDKUserAgeRange class] forKey:FBSDKPROFILE_AGERANGE_KEY]; 440| 0| FBSDKLocation *hometown = [decoder decodeObjectOfClass:[FBSDKLocation class] forKey:FBSDKPROFILE_HOMETOWN_KEY]; 441| 0| FBSDKLocation *location = [decoder decodeObjectOfClass:[FBSDKLocation class] forKey:FBSDKPROFILE_LOCATION_KEY]; 442| 0| NSString *gender = [decoder decodeObjectOfClass:[NSString class] forKey:FBSDKPROFILE_GENDER_KEY]; 443| 0| return [self initWithUserID:userID 444| 0| firstName:firstName 445| 0| middleName:middleName 446| 0| lastName:lastName 447| 0| name:name 448| 0| linkURL:linkURL 449| 0| refreshDate:refreshDate 450| 0| imageURL:imageURL 451| 0| email:email 452| 0| friendIDs:friendIDs 453| 0| birthday:birthday 454| 0| ageRange:ageRange 455| 0| hometown:hometown 456| 0| location:location 457| 0| gender:gender 458| 0| isLimited:isLimited]; 459| 0|} 460| | 461| |- (void)encodeWithCoder:(NSCoder *)encoder 462| 0|{ 463| 0| [encoder encodeObject:self.userID forKey:FBSDKPROFILE_USERID_KEY]; 464| 0| [encoder encodeObject:self.firstName forKey:FBSDKPROFILE_FIRSTNAME_KEY]; 465| 0| [encoder encodeObject:self.middleName forKey:FBSDKPROFILE_MIDDLENAME_KEY]; 466| 0| [encoder encodeObject:self.lastName forKey:FBSDKPROFILE_LASTNAME_KEY]; 467| 0| [encoder encodeObject:self.name forKey:FBSDKPROFILE_NAME_KEY]; 468| 0| [encoder encodeObject:self.linkURL forKey:FBSDKPROFILE_LINKURL_KEY]; 469| 0| [encoder encodeObject:self.refreshDate forKey:FBSDKPROFILE_REFRESHDATE_KEY]; 470| 0| [encoder encodeObject:self.imageURL forKey:FBSDKPROFILE_IMAGEURL_KEY]; 471| 0| [encoder encodeObject:self.email forKey:FBSDKPROFILE_EMAIL_KEY]; 472| 0| [encoder encodeObject:self.friendIDs forKey:FBSDKPROFILE_FRIENDIDS_KEY]; 473| 0| [encoder encodeBool:self.isLimited forKey:FBSDKPROFILE_IS_LIMITED_KEY]; 474| 0| [encoder encodeObject:self.birthday forKey:FBSDKPROFILE_BIRTHDAY_KEY]; 475| 0| [encoder encodeObject:self.ageRange forKey:FBSDKPROFILE_AGERANGE_KEY]; 476| 0| [encoder encodeObject:self.hometown forKey:FBSDKPROFILE_HOMETOWN_KEY]; 477| 0| [encoder encodeObject:self.location forKey:FBSDKPROFILE_LOCATION_KEY]; 478| 0| [encoder encodeObject:self.gender forKey:FBSDKPROFILE_GENDER_KEY]; 479| 0|} 480| | 481| |@end 482| | 483| |@implementation FBSDKProfile (Internal) 484| | 485| |static id _store; 486| | 487| |+ (void)configureWithStore:(id)store 488| | accessTokenProvider:(Class)accessTokenProvider 489| | notificationCenter:(id)notificationCenter 490| 0|{ 491| 0| if (self == [FBSDKProfile class]) { 492| 0| _store = store; 493| 0| _accessTokenProvider = accessTokenProvider; 494| 0| _notificationCenter = notificationCenter; 495| 0| } 496| 0|} 497| | 498| | #pragma clang diagnostic push 499| | #pragma clang diagnostic ignored "-Wdeprecated-declarations" 500| |+ (void)cacheProfile:(FBSDKProfile *)profile 501| 0|{ 502| 0| if (profile) { 503| 0| NSData *data = [NSKeyedArchiver archivedDataWithRootObject:profile]; 504| 0| [_store setObject:data forKey:FBSDKProfileUserDefaultsKey]; 505| 0| } else { 506| 0| [_store removeObjectForKey:FBSDKProfileUserDefaultsKey]; 507| 0| } 508| 0|} 509| | 510| |+ (FBSDKProfile *)fetchCachedProfile 511| 0|{ 512| 0| NSData *data = [_store objectForKey:FBSDKProfileUserDefaultsKey]; 513| 0| if (data != nil) { 514| 0| id unarchiver = [FBSDKUnarchiverProvider createSecureUnarchiverFor:data]; 515| | 516| 0| @try { 517| 0| return [unarchiver decodeObjectOfClass:[FBSDKProfile class] forKey:NSKeyedArchiveRootObjectKey]; 518| 0| } @catch (NSException *exception) { 519| | // Ignore decode error 520| 0| } 521| 0| } 522| 0| return nil; 523| 0|} 524| | 525| |+ (NSURL *)imageURLForProfileID:(FBSDKUserIdentifier *)profileId 526| | PictureMode:(FBSDKProfilePictureMode)mode 527| | size:(CGSize)size 528| 0|{ 529| 0| NSString *const accessTokenKey = @"access_token"; 530| 0| NSString *const pictureModeKey = @"type"; 531| 0| NSString *const widthKey = @"width"; 532| 0| NSString *const heightKey = @"height"; 533| | 534| 0| NSString *type; 535| 0| switch (mode) { 536| 0| case FBSDKProfilePictureModeNormal: type = @"normal"; break; 537| 0| case FBSDKProfilePictureModeSquare: type = @"square"; break; 538| 0| case FBSDKProfilePictureModeSmall: type = @"small"; break; 539| 0| case FBSDKProfilePictureModeAlbum: type = @"album"; break; 540| 0| case FBSDKProfilePictureModeLarge: type = @"large"; break; 541| 0| default: type = @"normal"; 542| 0| } 543| | 544| 0| NSMutableDictionary *queryParameters = [NSMutableDictionary dictionary]; 545| 0| [FBSDKTypeUtility dictionary:queryParameters setObject:type forKey:pictureModeKey]; 546| 0| [FBSDKTypeUtility dictionary:queryParameters setObject:@(roundf(size.width)) forKey:widthKey]; 547| 0| [FBSDKTypeUtility dictionary:queryParameters setObject:@(roundf(size.height)) forKey:heightKey]; 548| | 549| 0| if ([self.accessTokenProvider currentAccessToken]) { 550| 0| [FBSDKTypeUtility dictionary:queryParameters setObject:[[self.accessTokenProvider currentAccessToken] tokenString] 551| 0| forKey:accessTokenKey]; 552| 0| } else if (FBSDKSettings.clientToken) { 553| 0| [FBSDKTypeUtility dictionary:queryParameters setObject:FBSDKSettings.clientToken forKey:accessTokenKey]; 554| 0| } else { 555| 0| NSLog(@"As of Graph API v8.0, profile images may not be retrieved without an access token. This can be the current access token from logging in with Facebook or it can be set via the plist or in code. Providing neither will cause this call to return a silhouette image."); 556| 0| } 557| | 558| 0| NSString *path = [NSString stringWithFormat:@"%@/picture", profileId]; 559| | 560| 0| return [FBSDKInternalUtility facebookURLWithHostPrefix:@"graph" 561| 0| path:path 562| 0| queryParameters:queryParameters 563| 0| error:NULL]; 564| 0|} 565| | 566| |+ (NSString *)graphPathForToken:(FBSDKAccessToken *)token 567| 0|{ 568| 0| NSString *graphPath = @"me?fields=id,first_name,middle_name,last_name,name"; 569| 0| if ([token.permissions containsObject:@"user_link"]) { 570| 0| graphPath = [graphPath stringByAppendingString:@",link"]; 571| 0| } 572| | 573| 0| if ([token.permissions containsObject:@"email"]) { 574| 0| graphPath = [graphPath stringByAppendingString:@",email"]; 575| 0| } 576| | 577| 0| if ([token.permissions containsObject:@"user_friends"]) { 578| 0| graphPath = [graphPath stringByAppendingString:@",friends"]; 579| 0| } 580| | 581| 0| if ([token.permissions containsObject:@"user_birthday"]) { 582| 0| graphPath = [graphPath stringByAppendingString:@",birthday"]; 583| 0| } 584| | 585| 0| if ([token.permissions containsObject:@"user_age_range"]) { 586| 0| graphPath = [graphPath stringByAppendingString:@",age_range"]; 587| 0| } 588| | 589| 0| if ([token.permissions containsObject:@"user_hometown"]) { 590| 0| graphPath = [graphPath stringByAppendingString:@",hometown"]; 591| 0| } 592| | 593| 0| if ([token.permissions containsObject:@"user_location"]) { 594| 0| graphPath = [graphPath stringByAppendingString:@",location"]; 595| 0| } 596| | 597| 0| if ([token.permissions containsObject:@"user_gender"]) { 598| 0| graphPath = [graphPath stringByAppendingString:@",gender"]; 599| 0| } 600| | 601| 0| return graphPath; 602| 0|} 603| | 604| |+ (void)loadProfileWithToken:(FBSDKAccessToken *)token completion:(FBSDKProfileBlock)completion 605| 0|{ 606| 0| NSString *graphPath = [[self class] graphPathForToken:token]; 607| 0| id request = [[FBSDKGraphRequest alloc] initWithGraphPath:graphPath 608| 0| parameters:nil 609| 0| flags:FBSDKGraphRequestFlagDoNotInvalidateTokenOnError | FBSDKGraphRequestFlagDisableErrorRecovery]; 610| 0| [[self class] loadProfileWithToken:token completion:completion graphRequest:request]; 611| 0|} 612| | 613| |+ (void)loadProfileWithToken:(FBSDKAccessToken *)token 614| | completion:(FBSDKProfileBlock)completion 615| | graphRequest:(id)request 616| 0|{ 617| 0| FBSDKParseProfileBlock parseBlock = ^void (id result, FBSDKProfile **profileRef) { 618| 0| if (profileRef == NULL 619| 0| || result == nil 620| 0| || [FBSDKTypeUtility dictionaryValue:result] == nil) { 621| 0| return; 622| 0| } 623| | 624| 0| NSString *profileID = [FBSDKTypeUtility coercedToStringValue:result[@"id"]]; 625| 0| if (profileID == nil || profileID.length == 0) { 626| 0| return; 627| 0| } 628| | 629| 0| NSString *urlString = [FBSDKTypeUtility coercedToStringValue:result[@"link"]]; 630| 0| NSURL *linkUrl = [FBSDKTypeUtility URLValue:[NSURL URLWithString:urlString]]; 631| 0| NSArray *friendIDs = [self friendIDsFromGraphResult:[FBSDKTypeUtility dictionaryValue:result[@"friends"]]]; 632| 0| FBSDKUserAgeRange *ageRange = [FBSDKUserAgeRange ageRangeFromDictionary:[FBSDKTypeUtility dictionaryValue:result[@"age_range"]]]; 633| | 634| 0| [FBSDKProfile.dateFormatter setDateFormat:@"MM/dd/yyyy"]; 635| 0| NSDate *birthday = [FBSDKProfile.dateFormatter dateFromString:[FBSDKTypeUtility coercedToStringValue:result[@"birthday"]]]; 636| 0| FBSDKLocation *hometown = [FBSDKLocation locationFromDictionary:[FBSDKTypeUtility dictionaryValue:result[@"hometown"]]]; 637| 0| FBSDKLocation *location = [FBSDKLocation locationFromDictionary:[FBSDKTypeUtility dictionaryValue:result[@"location"]]]; 638| 0| NSString *gender = [FBSDKTypeUtility coercedToStringValue:result[@"gender"]]; 639| | 640| 0| FBSDKProfile *profile = [[FBSDKProfile alloc] initWithUserID:profileID 641| 0| firstName:[FBSDKTypeUtility coercedToStringValue:result[@"first_name"]] 642| 0| middleName:[FBSDKTypeUtility coercedToStringValue:result[@"middle_name"]] 643| 0| lastName:[FBSDKTypeUtility coercedToStringValue:result[@"last_name"]] 644| 0| name:[FBSDKTypeUtility coercedToStringValue:result[@"name"]] 645| 0| linkURL:linkUrl 646| 0| refreshDate:[NSDate date] 647| 0| imageURL:nil 648| 0| email:[FBSDKTypeUtility coercedToStringValue:result[@"email"]] 649| 0| friendIDs:friendIDs 650| 0| birthday:birthday 651| 0| ageRange:ageRange 652| 0| hometown:hometown 653| 0| location:location 654| 0| gender:gender]; 655| 0| *profileRef = [profile copy]; 656| 0| }; 657| 0| [[self class] loadProfileWithToken:token 658| 0| completion:completion 659| 0| graphRequest:request 660| 0| parseBlock:parseBlock]; 661| 0|} 662| | 663| |+ (void)loadProfileWithToken:(FBSDKAccessToken *)token 664| | completion:(FBSDKProfileBlock)completion 665| | graphRequest:(id)request 666| | parseBlock:(FBSDKParseProfileBlock)parseBlock; 667| 0|{ 668| 0| static id executingRequestConnection = nil; 669| | 670| 0| BOOL isStale = [[NSDate date] timeIntervalSinceDate:g_currentProfile.refreshDate] > FBSDKPROFILE_STALE_IN_SECONDS; 671| 0| if (token 672| 0| && (isStale || ![g_currentProfile.userID isEqualToString:token.userID] || g_currentProfile.isLimited)) { 673| 0| FBSDKProfile *expectedCurrentProfile = g_currentProfile; 674| | 675| 0| [executingRequestConnection cancel]; 676| 0| executingRequestConnection = [request startWithCompletion:^(id connection, id result, NSError *error) { 677| 0| if (expectedCurrentProfile != g_currentProfile) { 678| | // current profile has already changed since request was started. Let's not overwrite. 679| 0| if (completion != NULL) { 680| 0| completion(nil, nil); 681| 0| } 682| 0| return; 683| 0| } 684| 0| FBSDKProfile *profile = nil; 685| 0| if (!error) { 686| 0| parseBlock(result, &profile); 687| 0| } 688| 0| [[self class] setCurrentProfile:profile]; 689| 0| if (completion != NULL) { 690| 0| completion(profile, error); 691| 0| } 692| 0| }]; 693| 0| } else if (completion != NULL) { 694| 0| completion(g_currentProfile, nil); 695| 0| } 696| 0|} 697| | 698| |+ (void)observeChangeAccessTokenChange:(NSNotification *)notification 699| 0|{ 700| 0| FBSDKAccessToken *token = notification.userInfo[FBSDKAccessTokenChangeNewKey]; 701| 0| [self loadProfileWithToken:token completion:NULL]; 702| 0|} 703| | 704| |+ (NSArray *)friendIDsFromGraphResult:(NSDictionary *)result 705| 0|{ 706| 0| NSArray *rawFriends = [FBSDKTypeUtility arrayValue:result[@"data"]]; 707| 0| NSMutableArray *friendIDs = NSMutableArray.new; 708| | 709| 0| for (NSDictionary *rawFriend in rawFriends) { 710| 0| if ([FBSDKTypeUtility dictionaryValue:rawFriend]) { 711| 0| FBSDKUserIdentifier *friendID = [FBSDKTypeUtility coercedToStringValue:rawFriend[@"id"]]; 712| 0| [FBSDKTypeUtility array:friendIDs addObject:friendID]; 713| 0| } 714| 0| } 715| | 716| 0| if (friendIDs.count <= 0) { 717| 0| return nil; 718| 0| } 719| 0| return friendIDs; 720| 0|} 721| | 722| |+ (NSDateFormatter *)dateFormatter 723| 0|{ 724| 0| if (!_dateFormatter) { 725| 0| _dateFormatter = NSDateFormatter.new; 726| 0| } 727| 0| return _dateFormatter; 728| 0|} 729| | 730| | #pragma clang diagnostic pop 731| | 732| | #if DEBUG 733| | #if FBSDKTEST 734| | 735| |+ (void)resetCurrentProfileCache 736| 0|{ 737| 0| g_currentProfile = nil; 738| 0|} 739| | 740| |+ (id)store 741| 0|{ 742| 0| return _store; 743| 0|} 744| | 745| |+ (void)setAccessTokenProvider:(Class)accessTokenProvider 746| 0|{ 747| 0| _accessTokenProvider = accessTokenProvider; 748| 0|} 749| | 750| |+ (void)reset 751| 0|{ 752| 0| _store = nil; 753| 0| _accessTokenProvider = nil; 754| 0| _notificationCenter = nil; 755| 0|} 756| | 757| | #endif 758| | #endif 759| | 760| |@end 761| | 762| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKRandom.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKRandom.h" 20| | 21| |#import "FBSDKCrypto.h" 22| | 23| |NSString *fb_randomString(NSUInteger numberOfBytes) 24| 0|{ 25| 0| return [FBSDKCrypto randomString:numberOfBytes]; 26| 0|} /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKSettings.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKSettings+Internal.h" 20| | 21| |#import 22| | 23| |#import "FBSDKAppEventsConfigurationProtocol.h" 24| |#import "FBSDKAppEventsConfigurationProviding.h" 25| |#import "FBSDKCoreKitBasicsImport.h" 26| |#import "FBSDKCoreKitVersions.h" 27| |#import "FBSDKDataPersisting.h" 28| |#import "FBSDKEventLogging.h" 29| |#import "FBSDKInternalUtility.h" 30| | 31| |#define FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_IMPL(TYPE, PLIST_KEY, PROPERTY_NAME, SETTER, DEFAULT_VALUE, ENABLE_CACHE) \ 32| | + (TYPE *)PROPERTY_NAME \ 33| 0| { \ 34| 0| return self.sharedSettings.PROPERTY_NAME; \ 35| 0| } \ ------------------ | Unexecuted instantiation: FBSDKSettings.m:+[FBSDKSettings appID] ------------------ | Unexecuted instantiation: FBSDKSettings.m:+[FBSDKSettings appURLSchemeSuffix] ------------------ | Unexecuted instantiation: FBSDKSettings.m:+[FBSDKSettings clientToken] ------------------ | Unexecuted instantiation: FBSDKSettings.m:+[FBSDKSettings displayName] ------------------ | Unexecuted instantiation: FBSDKSettings.m:+[FBSDKSettings facebookDomainPart] ------------------ | Unexecuted instantiation: FBSDKSettings.m:+[FBSDKSettings _JPEGCompressionQualityNumber] ------------------ | Unexecuted instantiation: FBSDKSettings.m:+[FBSDKSettings _instrumentEnabled] ------------------ | Unexecuted instantiation: FBSDKSettings.m:+[FBSDKSettings _autoLogAppEventsEnabled] ------------------ | Unexecuted instantiation: FBSDKSettings.m:+[FBSDKSettings _advertiserIDCollectionEnabled] ------------------ | Unexecuted instantiation: FBSDKSettings.m:+[FBSDKSettings _SKAdNetworkReportEnabled] ------------------ | Unexecuted instantiation: FBSDKSettings.m:+[FBSDKSettings _codelessDebugLogEnabled] ------------------ 36| |\ 37| 0| + (void)SETTER:(TYPE *)value { \ 38| 0| [self.sharedSettings SETTER:value]; \ 39| 0| } \ ------------------ | Unexecuted instantiation: FBSDKSettings.m:+[FBSDKSettings setAppID:] ------------------ | Unexecuted instantiation: FBSDKSettings.m:+[FBSDKSettings setAppURLSchemeSuffix:] ------------------ | Unexecuted instantiation: FBSDKSettings.m:+[FBSDKSettings setClientToken:] ------------------ | Unexecuted instantiation: FBSDKSettings.m:+[FBSDKSettings setDisplayName:] ------------------ | Unexecuted instantiation: FBSDKSettings.m:+[FBSDKSettings setFacebookDomainPart:] ------------------ | Unexecuted instantiation: FBSDKSettings.m:+[FBSDKSettings _setJPEGCompressionQualityNumber:] ------------------ | Unexecuted instantiation: FBSDKSettings.m:+[FBSDKSettings _setInstrumentEnabled:] ------------------ | Unexecuted instantiation: FBSDKSettings.m:+[FBSDKSettings _setAutoLogAppEventsEnabled:] ------------------ | Unexecuted instantiation: FBSDKSettings.m:+[FBSDKSettings _setAdvertiserIDCollectionEnabled:] ------------------ | Unexecuted instantiation: FBSDKSettings.m:+[FBSDKSettings _setSKAdNetworkReportEnabled:] ------------------ | Unexecuted instantiation: FBSDKSettings.m:+[FBSDKSettings _setCodelessDebugLogEnabled:] ------------------ 40| | - (TYPE *)PROPERTY_NAME \ 41| 0| { \ 42| 0| if ((_ ## PROPERTY_NAME == nil) && ENABLE_CACHE) { \ 43| 0| _ ## PROPERTY_NAME = [[self.store objectForKey:@#PLIST_KEY] copy]; \ 44| 0| } \ 45| 0| if (_ ## PROPERTY_NAME == nil) { \ 46| 0| _ ## PROPERTY_NAME = [[self.infoDictionaryProvider objectForInfoDictionaryKey:@#PLIST_KEY] copy] ?: DEFAULT_VALUE; \ 47| 0| } \ 48| 0| return _ ## PROPERTY_NAME; \ 49| 0| } \ ------------------ | Unexecuted instantiation: FBSDKSettings.m:-[FBSDKSettings appID] ------------------ | Unexecuted instantiation: FBSDKSettings.m:-[FBSDKSettings appURLSchemeSuffix] ------------------ | Unexecuted instantiation: FBSDKSettings.m:-[FBSDKSettings clientToken] ------------------ | Unexecuted instantiation: FBSDKSettings.m:-[FBSDKSettings displayName] ------------------ | Unexecuted instantiation: FBSDKSettings.m:-[FBSDKSettings facebookDomainPart] ------------------ | Unexecuted instantiation: FBSDKSettings.m:-[FBSDKSettings _JPEGCompressionQualityNumber] ------------------ | Unexecuted instantiation: FBSDKSettings.m:-[FBSDKSettings _instrumentEnabled] ------------------ | Unexecuted instantiation: FBSDKSettings.m:-[FBSDKSettings _autoLogAppEventsEnabled] ------------------ | Unexecuted instantiation: FBSDKSettings.m:-[FBSDKSettings _advertiserIDCollectionEnabled] ------------------ | Unexecuted instantiation: FBSDKSettings.m:-[FBSDKSettings _SKAdNetworkReportEnabled] ------------------ | Unexecuted instantiation: FBSDKSettings.m:-[FBSDKSettings _codelessDebugLogEnabled] ------------------ 50| 0| - (void)SETTER:(TYPE *)value { \ 51| 0| [self validateConfiguration]; \ 52| 0| _ ## PROPERTY_NAME = [value copy]; \ 53| 0| if (ENABLE_CACHE) { \ 54| 0| if (value != nil) { \ 55| 0| [self.store setObject:value forKey:@#PLIST_KEY]; \ 56| 0| } else { \ 57| 0| [self.store removeObjectForKey:@#PLIST_KEY]; \ 58| 0| } \ 59| 0| } \ 60| 0| [self logIfSDKSettingsChanged]; \ 61| 0| } ------------------ | Unexecuted instantiation: FBSDKSettings.m:-[FBSDKSettings setAppID:] ------------------ | Unexecuted instantiation: FBSDKSettings.m:-[FBSDKSettings setAppURLSchemeSuffix:] ------------------ | Unexecuted instantiation: FBSDKSettings.m:-[FBSDKSettings setClientToken:] ------------------ | Unexecuted instantiation: FBSDKSettings.m:-[FBSDKSettings setDisplayName:] ------------------ | Unexecuted instantiation: FBSDKSettings.m:-[FBSDKSettings setFacebookDomainPart:] ------------------ | Unexecuted instantiation: FBSDKSettings.m:-[FBSDKSettings _setJPEGCompressionQualityNumber:] ------------------ | Unexecuted instantiation: FBSDKSettings.m:-[FBSDKSettings _setInstrumentEnabled:] ------------------ | Unexecuted instantiation: FBSDKSettings.m:-[FBSDKSettings _setAutoLogAppEventsEnabled:] ------------------ | Unexecuted instantiation: FBSDKSettings.m:-[FBSDKSettings _setAdvertiserIDCollectionEnabled:] ------------------ | Unexecuted instantiation: FBSDKSettings.m:-[FBSDKSettings _setSKAdNetworkReportEnabled:] ------------------ | Unexecuted instantiation: FBSDKSettings.m:-[FBSDKSettings _setCodelessDebugLogEnabled:] ------------------ 62| | 63| |#define FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_DECL(TYPE, PROPERTY_NAME, SETTER) \ 64| | @property (nullable, nonatomic, getter = PROPERTY_NAME, setter = SETTER:, copy) TYPE *PROPERTY_NAME; 65| | 66| |#define FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_IVAR_DECL(TYPE, PROPERTY_NAME) \ 67| | TYPE *_ ## PROPERTY_NAME; 68| | 69| |FBSDKLoggingBehavior FBSDKLoggingBehaviorAccessTokens = @"include_access_tokens"; 70| |FBSDKLoggingBehavior FBSDKLoggingBehaviorPerformanceCharacteristics = @"perf_characteristics"; 71| |FBSDKLoggingBehavior FBSDKLoggingBehaviorAppEvents = @"app_events"; 72| |FBSDKLoggingBehavior FBSDKLoggingBehaviorInformational = @"informational"; 73| |FBSDKLoggingBehavior FBSDKLoggingBehaviorCacheErrors = @"cache_errors"; 74| |FBSDKLoggingBehavior FBSDKLoggingBehaviorUIControlErrors = @"ui_control_errors"; 75| |FBSDKLoggingBehavior FBSDKLoggingBehaviorDeveloperErrors = @"developer_errors"; 76| |FBSDKLoggingBehavior FBSDKLoggingBehaviorGraphAPIDebugWarning = @"graph_api_debug_warning"; 77| |FBSDKLoggingBehavior FBSDKLoggingBehaviorGraphAPIDebugInfo = @"graph_api_debug_info"; 78| |FBSDKLoggingBehavior FBSDKLoggingBehaviorNetworkRequests = @"network_requests"; 79| | 80| |static NSMutableSet *g_loggingBehaviors; 81| |static NSString *const FBSDKSettingsLimitEventAndDataUsage = @"com.facebook.sdk:FBSDKSettingsLimitEventAndDataUsage"; 82| |static NSString *const FBSDKSettingsBitmask = @"com.facebook.sdk:FBSDKSettingsBitmask"; 83| |static NSString *const FBSDKSettingsDataProcessingOptions = @"com.facebook.sdk:FBSDKSettingsDataProcessingOptions"; 84| |static NSString *const FBSDKSettingsAdvertisingTrackingStatus = @"com.facebook.sdk:FBSDKSettingsAdvertisingTrackingStatus"; 85| |static NSString *const FBSDKSettingsInstallTimestamp = @"com.facebook.sdk:FBSDKSettingsInstallTimestamp"; 86| |static NSString *const FBSDKSettingsSetAdvertiserTrackingEnabledTimestamp = @"com.facebook.sdk:FBSDKSettingsSetAdvertiserTrackingEnabledTimestamp"; 87| |static NSString *const FBSDKSettingsUseCachedValuesForExpensiveMetadata = @"com.facebook.sdk:FBSDKSettingsUseCachedValuesForExpensiveMetadata"; 88| |static NSString *const FBSDKSettingsUseTokenOptimizations = @"com.facebook.sdk.FBSDKSettingsUseTokenOptimizations"; 89| |static BOOL g_disableErrorRecovery; 90| |static NSString *g_userAgentSuffix; 91| |static NSDictionary *g_dataProcessingOptions = nil; 92| | 93| |// 94| |// Warning messages for App Event Flags 95| |// 96| | 97| |static NSString *const autoLogAppEventsEnabledNotSetWarning = 98| |@": Please set a value for FacebookAutoLogAppEventsEnabled. Set the flag to TRUE if you want " 99| |"to collect app install, app launch and in-app purchase events automatically. To request user consent " 100| |"before collecting data, set the flag value to FALSE, then change to TRUE once user consent is received. " 101| |"Learn more: https://developers.facebook.com/docs/app-events/getting-started-app-events-ios#disable-auto-events."; 102| |static NSString *const advertiserIDCollectionEnabledNotSetWarning = 103| |@": You haven't set a value for FacebookAdvertiserIDCollectionEnabled. Set the flag to TRUE if " 104| |"you want to collect Advertiser ID for better advertising and analytics results."; 105| |static NSString *const advertiserIDCollectionEnabledFalseWarning = 106| |@": The value for FacebookAdvertiserIDCollectionEnabled is currently set to FALSE so you're sending app " 107| |"events without collecting Advertiser ID. This can affect the quality of your advertising and analytics results."; 108| | 109| |@interface FBSDKSettings () 110| | 111| |@property (nullable, nonatomic) id store; 112| |@property (nullable, nonatomic) Class appEventsConfigurationProvider; 113| |@property (nullable, nonatomic) id infoDictionaryProvider; 114| |@property (nullable, nonatomic) id eventLogger; 115| |@property (nullable, nonatomic) NSNumber *advertiserTrackingStatusBacking; 116| |@property (nonatomic) BOOL isConfigured; 117| |@property (nonatomic) NSString *graphAPIVersion; 118| | 119| |FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_DECL(NSString, appID, setAppID); 120| |FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_DECL(NSString, appURLSchemeSuffix, setAppURLSchemeSuffix); 121| |FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_DECL(NSString, clientToken, setClientToken); 122| |FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_DECL(NSString, displayName, setDisplayName); 123| |FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_DECL(NSString, facebookDomainPart, setFacebookDomainPart); 124| |FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_DECL(NSNumber, _JPEGCompressionQualityNumber, _setJPEGCompressionQualityNumber); 125| |FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_DECL(NSNumber, _instrumentEnabled, _setInstrumentEnabled); 126| |FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_DECL(NSNumber, _autoLogAppEventsEnabled, _setAutoLogAppEventsEnabled); 127| |FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_DECL(NSNumber, _advertiserIDCollectionEnabled, _setAdvertiserIDCollectionEnabled); 128| |FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_DECL(NSNumber, _SKAdNetworkReportEnabled, _setSKAdNetworkReportEnabled); 129| |FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_DECL(NSNumber, _codelessDebugLogEnabled, _setCodelessDebugLogEnabled); 130| | 131| |@end 132| | 133| |@implementation FBSDKSettings 134| |{ 135| | FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_IVAR_DECL(NSString, appID); 136| | FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_IVAR_DECL(NSString, appURLSchemeSuffix); 137| | FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_IVAR_DECL(NSString, clientToken); 138| | FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_IVAR_DECL(NSString, displayName); 139| | FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_IVAR_DECL(NSString, facebookDomainPart); 140| | FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_IVAR_DECL(NSNumber, _JPEGCompressionQualityNumber); 141| | FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_IVAR_DECL(NSNumber, _instrumentEnabled); 142| | FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_IVAR_DECL(NSNumber, _autoLogAppEventsEnabled); 143| | FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_IVAR_DECL(NSNumber, _advertiserIDCollectionEnabled); 144| | FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_IVAR_DECL(NSNumber, _SKAdNetworkReportEnabled); 145| | FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_IVAR_DECL(NSNumber, _codelessDebugLogEnabled); 146| |} 147| | 148| |static dispatch_once_t sharedSettingsNonce; 149| | 150| |// Transitional singleton introduced as a way to change the usage semantics 151| |// from a type-based interface to an instance-based interface. 152| |// Once that is complete then types that use `+[FBSDKSettings foo]` can take an 153| |// injectable instance of a `FBSDKSettings` until they no longer directly 154| |// reference a settings type of any kind and instead refer to an injectable 155| |// dependency for their actual use cases. 156| |// The move will be: 157| |// ClassWithoutUnderlyingInstance -> ClassRelyingOnUnderlyingInstance -> Instance 158| |+ (instancetype)sharedSettings 159| 0|{ 160| 0| static id instance; 161| 0| dispatch_once(&sharedSettingsNonce, ^{ 162| 0| instance = [self new]; 163| 0| }); 164| 0| return instance; 165| 0|} 166| | 167| |- (void) configureWithStore:(id)store 168| | appEventsConfigurationProvider:(Class)provider 169| | infoDictionaryProvider:(id)infoDictionaryProvider 170| | eventLogger:(id)eventLogger 171| 0|{ 172| 0| self.store = store; 173| 0| self.appEventsConfigurationProvider = provider; 174| 0| self.infoDictionaryProvider = infoDictionaryProvider; 175| 0| self.eventLogger = eventLogger; 176| | 177| 0| self.isConfigured = YES; 178| 0|} 179| | 180| |+ (void) configureWithStore:(id)store 181| | appEventsConfigurationProvider:(Class)provider 182| | infoDictionaryProvider:(id)infoDictionaryProvider 183| | eventLogger:(id)eventLogger 184| 0|{ 185| 0| [self.sharedSettings configureWithStore:store 186| 0| appEventsConfigurationProvider:provider 187| 0| infoDictionaryProvider:infoDictionaryProvider 188| 0| eventLogger:eventLogger]; 189| 0|} 190| | 191| |+ (id)store 192| 0|{ 193| 0| return self.sharedSettings.store; 194| 0|} 195| | 196| |+ (Class)appEventsConfigurationProvider 197| 0|{ 198| 0| return self.sharedSettings.appEventsConfigurationProvider; 199| 0|} 200| | 201| |+ (id)infoDictionaryProvider 202| 0|{ 203| 0| return self.sharedSettings.infoDictionaryProvider; 204| 0|} 205| | 206| |+ (id)eventLogger 207| 0|{ 208| 0| return self.sharedSettings.eventLogger; 209| 0|} 210| | 211| |#pragma mark - Plist Configuration Settings 212| | 213| |FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_IMPL(NSString, FacebookAppID, appID, setAppID, nil, NO); 214| |FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_IMPL(NSString, FacebookUrlSchemeSuffix, appURLSchemeSuffix, setAppURLSchemeSuffix, nil, NO); 215| |FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_IMPL(NSString, FacebookClientToken, clientToken, setClientToken, nil, NO); 216| |FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_IMPL(NSString, FacebookDisplayName, displayName, setDisplayName, nil, NO); 217| |FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_IMPL(NSString, FacebookDomainPart, facebookDomainPart, setFacebookDomainPart, nil, NO); 218| |FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_IMPL(NSNumber, FacebookJpegCompressionQuality, _JPEGCompressionQualityNumber, _setJPEGCompressionQualityNumber, @0.9, NO); 219| |FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_IMPL(NSNumber, FacebookInstrumentEnabled, _instrumentEnabled, _setInstrumentEnabled, @1, YES); 220| |FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_IMPL(NSNumber, FacebookAutoLogAppEventsEnabled, _autoLogAppEventsEnabled, _setAutoLogAppEventsEnabled, @1, YES); 221| |FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_IMPL(NSNumber, FacebookAdvertiserIDCollectionEnabled, _advertiserIDCollectionEnabled, _setAdvertiserIDCollectionEnabled, @1, YES); 222| |FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_IMPL(NSNumber, FacebookSKAdNetworkReportEnabled, _SKAdNetworkReportEnabled, _setSKAdNetworkReportEnabled, @1, YES); 223| |FBSDKSETTINGS_PLIST_CONFIGURATION_SETTING_IMPL( 224| | NSNumber, 225| | FacebookCodelessDebugLogEnabled, 226| | _codelessDebugLogEnabled, 227| | _setCodelessDebugLogEnabled, 228| | @0, 229| | YES 230| |); 231| | 232| |+ (BOOL)isGraphErrorRecoveryEnabled 233| 0|{ 234| 0| return !g_disableErrorRecovery; 235| 0|} 236| | 237| |+ (void)setGraphErrorRecoveryEnabled:(BOOL)graphErrorRecoveryEnabled 238| 0|{ 239| 0| g_disableErrorRecovery = !graphErrorRecoveryEnabled; 240| 0|} 241| | 242| |+ (CGFloat)JPEGCompressionQuality 243| 0|{ 244| 0| return self.sharedSettings._JPEGCompressionQualityNumber.floatValue; 245| 0|} 246| | 247| |+ (void)setJPEGCompressionQuality:(CGFloat)JPEGCompressionQuality 248| 0|{ 249| 0| [self.sharedSettings _setJPEGCompressionQualityNumber:@(JPEGCompressionQuality)]; 250| 0|} 251| | 252| |+ (BOOL)isInstrumentEnabled 253| 0|{ 254| 0| return self.sharedSettings._instrumentEnabled.boolValue; 255| 0|} 256| | 257| |+ (void)setInstrumentEnabled:(BOOL)instrumentEnabled 258| 0|{ 259| 0| [self.sharedSettings _setInstrumentEnabled:@(instrumentEnabled)]; 260| 0|} 261| | 262| |+ (BOOL)isCodelessDebugLogEnabled 263| 0|{ 264| 0| return self.sharedSettings._codelessDebugLogEnabled.boolValue; 265| 0|} 266| | 267| |+ (void)setCodelessDebugLogEnabled:(BOOL)codelessDebugLogEnabled 268| 0|{ 269| 0| [self.sharedSettings _setCodelessDebugLogEnabled:@(codelessDebugLogEnabled)]; 270| 0|} 271| | 272| |+ (BOOL)isAutoLogAppEventsEnabled 273| 0|{ 274| 0| return [self.sharedSettings isAutoLogAppEventsEnabled]; 275| 0|} 276| | 277| |- (BOOL)isAutoLogAppEventsEnabled 278| 0|{ 279| 0| return self._autoLogAppEventsEnabled.boolValue; 280| 0|} 281| | 282| |+ (void)setAutoLogAppEventsEnabled:(BOOL)autoLogAppEventsEnabled 283| 0|{ 284| 0| [self.sharedSettings _setAutoLogAppEventsEnabled:@(autoLogAppEventsEnabled)]; 285| 0|} 286| | 287| |+ (BOOL)isAdvertiserIDCollectionEnabled 288| 0|{ 289| 0| return self.sharedSettings._advertiserIDCollectionEnabled.boolValue; 290| 0|} 291| | 292| |+ (void)setAdvertiserIDCollectionEnabled:(BOOL)advertiserIDCollectionEnabled 293| 0|{ 294| 0| [self.sharedSettings _setAdvertiserIDCollectionEnabled:@(advertiserIDCollectionEnabled)]; 295| 0|} 296| | 297| |+ (BOOL)isAdvertiserTrackingEnabled 298| 0|{ 299| 0| return self.sharedSettings.isAdvertiserTrackingEnabled; 300| 0|} 301| | 302| |- (BOOL)isAdvertiserTrackingEnabled 303| 0|{ 304| 0| return self.advertisingTrackingStatus == FBSDKAdvertisingTrackingAllowed; 305| 0|} 306| | 307| |+ (BOOL)setAdvertiserTrackingEnabled:(BOOL)enabled; 308| 0|{ 309| 0| return [self.sharedSettings setAdvertiserTrackingEnabled:enabled]; 310| 0|} 311| | 312| |- (BOOL)setAdvertiserTrackingEnabled:(BOOL)enabled; 313| 0|{ 314| 0| if (@available(iOS 14.0, *)) { 315| 0| [self setAdvertiserTrackingStatus:enabled ? FBSDKAdvertisingTrackingAllowed : FBSDKAdvertisingTrackingDisallowed]; 316| 0| [self recordSetAdvertiserTrackingEnabled]; 317| 0| return YES; 318| 0| } else { 319| 0| return NO; 320| 0| } 321| 0|} 322| | 323| |+ (FBSDKAdvertisingTrackingStatus)advertisingTrackingStatus 324| 0|{ 325| 0| return [self.sharedSettings advertisingTrackingStatus]; 326| 0|} 327| | 328| |- (FBSDKAdvertisingTrackingStatus)advertisingTrackingStatus 329| 0|{ 330| 0| if (@available(iOS 14.0, *)) { 331| 0| if (self.advertiserTrackingStatusBacking == nil) { 332| 0| self.advertiserTrackingStatusBacking = [self.store objectForKey:FBSDKSettingsAdvertisingTrackingStatus]; 333| 0| if (self.advertiserTrackingStatusBacking == nil) { 334| 0| return [[self.appEventsConfigurationProvider cachedAppEventsConfiguration] defaultATEStatus]; 335| 0| } 336| 0| } 337| 0| return self.advertiserTrackingStatusBacking.unsignedIntegerValue; 338| 0| } else { 339| | // @lint-ignore CLANGTIDY 340| 0| return ASIdentifierManager.sharedManager.advertisingTrackingEnabled ? FBSDKAdvertisingTrackingAllowed : FBSDKAdvertisingTrackingDisallowed; 341| 0| } 342| 0|} 343| | 344| |+ (void)setAdvertiserTrackingStatus:(FBSDKAdvertisingTrackingStatus)status 345| 0|{ 346| 0| [self.sharedSettings setAdvertiserTrackingStatus:status]; 347| 0|} 348| | 349| |- (void)setAdvertiserTrackingStatus:(FBSDKAdvertisingTrackingStatus)status 350| 0|{ 351| 0| self.advertiserTrackingStatusBacking = @(status); 352| 0| [self.store setObject:self.advertiserTrackingStatusBacking forKey:FBSDKSettingsAdvertisingTrackingStatus]; 353| 0|} 354| | 355| |+ (BOOL)isSKAdNetworkReportEnabled 356| 0|{ 357| 0| return self.sharedSettings.isSKAdNetworkReportEnabled; 358| 0|} 359| | 360| |- (BOOL)isSKAdNetworkReportEnabled 361| 0|{ 362| 0| return [self _SKAdNetworkReportEnabled].boolValue; 363| 0|} 364| | 365| |+ (void)setSKAdNetworkReportEnabled:(BOOL)SKAdNetworkReportEnabled 366| 0|{ 367| 0| [self _setSKAdNetworkReportEnabled:@(SKAdNetworkReportEnabled)]; 368| 0|} 369| | 370| |+ (BOOL)shouldLimitEventAndDataUsage 371| 0|{ 372| 0| return self.sharedSettings.shouldLimitEventAndDataUsage; 373| 0|} 374| | 375| |- (BOOL)shouldLimitEventAndDataUsage 376| 0|{ 377| 0| NSNumber *storedValue = [FBSDKSettings.store objectForKey:FBSDKSettingsLimitEventAndDataUsage]; 378| 0| if (storedValue == nil) { 379| 0| return NO; 380| 0| } 381| 0| return storedValue.boolValue; 382| 0|} 383| | 384| |+ (void)setLimitEventAndDataUsage:(BOOL)limitEventAndDataUsage 385| 0|{ 386| 0| [self.sharedSettings setLimitEventAndDataUsage:limitEventAndDataUsage]; 387| 0|} 388| | 389| |- (void)setLimitEventAndDataUsage:(BOOL)limitEventAndDataUsage 390| 0|{ 391| 0| [_store setObject:@(limitEventAndDataUsage) forKey:FBSDKSettingsLimitEventAndDataUsage]; 392| 0|} 393| | 394| |+ (BOOL)shouldUseCachedValuesForExpensiveMetadata 395| 0|{ 396| 0| NSNumber *storedValue = [self.store objectForKey:FBSDKSettingsUseCachedValuesForExpensiveMetadata]; 397| 0| if (storedValue == nil) { 398| 0| return NO; 399| 0| } 400| 0| return storedValue.boolValue; 401| 0|} 402| | 403| |+ (void)setShouldUseCachedValuesForExpensiveMetadata:(BOOL)shouldUseCachedValuesForExpensiveMetadata 404| 0|{ 405| 0| [self.store setObject:@(shouldUseCachedValuesForExpensiveMetadata) forKey:FBSDKSettingsUseCachedValuesForExpensiveMetadata]; 406| 0|} 407| | 408| |- (BOOL)shouldUseTokenOptimizations 409| 0|{ 410| 0| NSNumber *storedValue = [self.store objectForKey:FBSDKSettingsUseTokenOptimizations]; 411| 0| if (storedValue == nil) { 412| 0| return YES; 413| 0| } 414| 0| return storedValue.boolValue; 415| 0|} 416| | 417| |- (void)setShouldUseTokenOptimizations:(BOOL)shouldUseTokenOptimizations 418| 0|{ 419| 0| [self.store setObject:@(shouldUseTokenOptimizations) forKey:FBSDKSettingsUseTokenOptimizations]; 420| 0|} 421| | 422| |+ (NSSet *)loggingBehaviors 423| 0|{ 424| 0| if (!g_loggingBehaviors) { 425| 0| NSArray *bundleLoggingBehaviors = [self.sharedSettings.infoDictionaryProvider objectForInfoDictionaryKey:@"FacebookLoggingBehavior"]; 426| 0| if (bundleLoggingBehaviors) { 427| 0| g_loggingBehaviors = [[NSMutableSet alloc] initWithArray:bundleLoggingBehaviors]; 428| 0| } else { 429| | // Establish set of default enabled logging behaviors. You can completely disable logging by 430| | // specifying an empty array for FacebookLoggingBehavior in your Info.plist. 431| 0| g_loggingBehaviors = [[NSMutableSet alloc] initWithObjects:FBSDKLoggingBehaviorDeveloperErrors, nil]; 432| 0| } 433| 0| } 434| 0| return [g_loggingBehaviors copy]; 435| 0|} 436| | 437| |- (NSSet *)loggingBehaviors 438| 0|{ 439| 0| return [self.class loggingBehaviors]; 440| 0|} 441| | 442| |+ (void)setDataProcessingOptions:(nullable NSArray *)options 443| 0|{ 444| 0| [FBSDKSettings setDataProcessingOptions:options country:0 state:0]; 445| 0|} 446| | 447| |#pragma clang diagnostic push 448| |#pragma clang diagnostic ignored "-Wdeprecated-declarations" 449| |+ (void)setDataProcessingOptions:(nullable NSArray *)options 450| | country:(int)country 451| | state:(int)state 452| 0|{ 453| 0| NSDictionary *json = @{ 454| 0| DATA_PROCESSING_OPTIONS : options ?: @[], 455| 0| DATA_PROCESSING_OPTIONS_COUNTRY : @(country), 456| 0| DATA_PROCESSING_OPTIONS_STATE : @(state), 457| 0| }; 458| 0| g_dataProcessingOptions = json; 459| 0| NSData *data = [NSKeyedArchiver archivedDataWithRootObject:g_dataProcessingOptions]; 460| 0| if (data) { 461| 0| [self.store setObject:data 462| 0| forKey:FBSDKSettingsDataProcessingOptions]; 463| 0| } 464| 0|} 465| | 466| |#pragma clang diagnostic pop 467| | 468| |+ (void)setLoggingBehaviors:(NSSet *)loggingBehaviors 469| 0|{ 470| 0| if (![g_loggingBehaviors isEqualToSet:loggingBehaviors]) { 471| 0| g_loggingBehaviors = [loggingBehaviors mutableCopy]; 472| | 473| 0| [self updateGraphAPIDebugBehavior]; 474| 0| } 475| 0|} 476| | 477| |+ (void)enableLoggingBehavior:(FBSDKLoggingBehavior)loggingBehavior 478| 0|{ 479| 0| if (!g_loggingBehaviors) { 480| 0| [self loggingBehaviors]; 481| 0| } 482| 0| [g_loggingBehaviors addObject:loggingBehavior]; 483| 0| [self updateGraphAPIDebugBehavior]; 484| 0|} 485| | 486| |+ (void)disableLoggingBehavior:(FBSDKLoggingBehavior)loggingBehavior 487| 0|{ 488| 0| if (!g_loggingBehaviors) { 489| 0| [self loggingBehaviors]; 490| 0| } 491| 0| [g_loggingBehaviors removeObject:loggingBehavior]; 492| 0| [self updateGraphAPIDebugBehavior]; 493| 0|} 494| | 495| |#pragma mark - Readonly Configuration Settings 496| | 497| |+ (NSString *)sdkVersion 498| 0|{ 499| 0| return FBSDK_VERSION_STRING; 500| 0|} 501| | 502| |#pragma mark - Configuration Validation 503| | 504| |- (void)validateConfiguration 505| 0|{ 506| 0|#if DEBUG 507| 0| if (!self.isConfigured) { 508| 0| static NSString *const reason = @"As of v9.0, you must initialize the SDK prior to calling any methods or setting any properties. " 509| 0| "You can do this by calling `FBSDKApplicationDelegate`'s `application:didFinishLaunchingWithOptions:` method." 510| 0| "Learn more: https://developers.facebook.com/docs/ios/getting-started"; 511| 0| @throw [NSException exceptionWithName:@"InvalidOperationException" reason:reason userInfo:nil]; 512| 0| } 513| 0|#endif 514| 0|} 515| | 516| |#pragma mark - Internal 517| | 518| |+ (NSString *)userAgentSuffix 519| 0|{ 520| 0| return g_userAgentSuffix; 521| 0|} 522| | 523| |+ (void)setUserAgentSuffix:(NSString *)suffix 524| 0|{ 525| 0| if (![g_userAgentSuffix isEqualToString:suffix]) { 526| 0| g_userAgentSuffix = suffix; 527| 0| } 528| 0|} 529| | 530| |+ (void)setGraphAPIVersion:(NSString *)version 531| 0|{ 532| 0| if (![self.sharedSettings.graphAPIVersion isEqualToString:version]) { 533| 0| self.sharedSettings.graphAPIVersion = version; 534| 0| } 535| 0|} 536| | 537| |+ (NSString *)defaultGraphAPIVersion 538| 0|{ 539| 0| return FBSDK_TARGET_PLATFORM_VERSION; 540| 0|} 541| | 542| |+ (NSString *)graphAPIVersion 543| 0|{ 544| 0| return [self.sharedSettings graphAPIVersion]; 545| 0|} 546| | 547| |- (NSString *)graphAPIVersion 548| 0|{ 549| 0| return _graphAPIVersion ?: FBSDKSettings.defaultGraphAPIVersion; 550| 0|} 551| | 552| |+ (NSNumber *)appEventSettingsForPlistKey:(NSString *)plistKey 553| | defaultValue:(NSNumber *)defaultValue 554| 0|{ 555| 0| return [[[NSBundle mainBundle] objectForInfoDictionaryKey:plistKey] copy] ?: defaultValue; 556| 0|} 557| | 558| |+ (NSNumber *)appEventSettingsForUserDefaultsKey:(NSString *)userDefaultsKey 559| | defaultValue:(NSNumber *)defaultValue 560| 0|{ 561| 0| NSData *data = [self.store objectForKey:userDefaultsKey]; 562| 0| if ([data isKindOfClass:[NSNumber class]]) { 563| 0| return (NSNumber *)data; 564| 0| } 565| 0| return defaultValue; 566| 0|} 567| | 568| |#pragma clang diagnostic push 569| |#pragma clang diagnostic ignored "-Wdeprecated-declarations" 570| |+ (NSDictionary *)dataProcessingOptions 571| 0|{ 572| 0| if (!g_dataProcessingOptions) { 573| 0| NSData *data = [self.store objectForKey:FBSDKSettingsDataProcessingOptions]; 574| 0| if ([data isKindOfClass:[NSData class]]) { 575| 0| if (@available(iOS 11.0, tvOS 11.0, *)) { 576| 0| g_dataProcessingOptions = [NSKeyedUnarchiver unarchivedObjectOfClasses:[NSSet setWithArray:@[NSString.class, NSNumber.class, NSArray.class, NSDictionary.class, NSSet.class]] fromData:data error:nil]; 577| 0| } else { 578| 0| NSDictionary *dataProcessingOptions = [NSKeyedUnarchiver unarchiveObjectWithData:data]; 579| 0| if (dataProcessingOptions && [dataProcessingOptions isKindOfClass:[NSDictionary class]]) { 580| 0| g_dataProcessingOptions = dataProcessingOptions; 581| 0| } 582| 0| } 583| 0| } 584| 0| } 585| 0| return g_dataProcessingOptions; 586| 0|} 587| | 588| |#pragma clang diagnostic pop 589| | 590| |+ (BOOL)isDataProcessingRestricted 591| 0|{ 592| 0| return [self.sharedSettings isDataProcessingRestricted]; 593| 0|} 594| | 595| |- (BOOL)isDataProcessingRestricted 596| 0|{ 597| 0| NSArray *options = [FBSDKTypeUtility dictionary:[FBSDKSettings dataProcessingOptions] 598| 0| objectForKey:DATA_PROCESSING_OPTIONS 599| 0| ofType:NSArray.class]; 600| 0| for (NSString *option in options) { 601| 0| if ([@"ldu" isEqualToString:[[FBSDKTypeUtility coercedToStringValue:option] lowercaseString]]) { 602| 0| return YES; 603| 0| } 604| 0| } 605| 0| return NO; 606| 0|} 607| | 608| |- (void)logWarnings 609| 0|{ 610| | // Log warnings for App Event Flags 611| 0| if (![self.infoDictionaryProvider objectForInfoDictionaryKey:@"FacebookAutoLogAppEventsEnabled"]) { 612| 0| NSLog(autoLogAppEventsEnabledNotSetWarning); 613| 0| } 614| 0| if (![self.infoDictionaryProvider objectForInfoDictionaryKey:@"FacebookAdvertiserIDCollectionEnabled"]) { 615| 0| NSLog(advertiserIDCollectionEnabledNotSetWarning); 616| 0| } 617| 0| if (!self._advertiserIDCollectionEnabled.boolValue) { 618| 0| NSLog(advertiserIDCollectionEnabledFalseWarning); 619| 0| } 620| 0|} 621| | 622| |- (void)logIfSDKSettingsChanged 623| 0|{ 624| 0| NSInteger bitmask = 0; 625| | // Starting at 1 to maintain the meaning of the bits since the autoInit flag was removed. 626| 0| NSInteger bit = 1; 627| 0| bitmask |= (self._autoLogAppEventsEnabled.boolValue ? 1 : 0) << bit++; 628| 0| bitmask |= (self._advertiserIDCollectionEnabled.boolValue ? 1 : 0) << bit++; 629| | 630| 0| NSInteger previousBitmask = [self.store integerForKey:FBSDKSettingsBitmask]; 631| 0| if (previousBitmask != bitmask) { 632| 0| [self.store setInteger:bitmask forKey:FBSDKSettingsBitmask]; 633| | 634| 0| NSArray *keys = @[@"FacebookAutoLogAppEventsEnabled", 635| 0| @"FacebookAdvertiserIDCollectionEnabled"]; 636| 0| NSArray *defaultValues = @[@YES, @YES]; 637| 0| NSInteger initialBitmask = 0; 638| 0| NSInteger usageBitmask = 0; 639| 0| for (int i = 0; i < keys.count; i++) { 640| 0| NSNumber *plistValue = [self.infoDictionaryProvider objectForInfoDictionaryKey:[FBSDKTypeUtility array:keys objectAtIndex:i]]; 641| 0| BOOL initialValue = [(plistValue ?: [FBSDKTypeUtility array:defaultValues objectAtIndex:i]) boolValue]; 642| 0| initialBitmask |= (initialValue ? 1 : 0) << i; 643| 0| usageBitmask |= (plistValue != nil ? 1 : 0) << i; 644| 0| } 645| 0| [self.eventLogger logInternalEvent:@"fb_sdk_settings_changed" 646| 0| parameters:@{@"usage" : @(usageBitmask), 647| 0| @"initial" : @(initialBitmask), 648| 0| @"previous" : @(previousBitmask), 649| 0| @"current" : @(bitmask)} 650| 0| isImplicitlyLogged:YES]; 651| 0| } 652| 0|} 653| | 654| |- (void)recordInstall 655| 0|{ 656| 0| if (![self.store objectForKey:FBSDKSettingsInstallTimestamp]) { 657| 0| [self.store setObject:[NSDate date] forKey:FBSDKSettingsInstallTimestamp]; 658| 0| } 659| 0|} 660| | 661| |+ (void)recordSetAdvertiserTrackingEnabled 662| 0|{ 663| 0| [self.sharedSettings recordSetAdvertiserTrackingEnabled]; 664| 0|} 665| | 666| |- (void)recordSetAdvertiserTrackingEnabled 667| 0|{ 668| 0| [self.store setObject:[NSDate date] forKey:FBSDKSettingsSetAdvertiserTrackingEnabledTimestamp]; 669| 0|} 670| | 671| |+ (BOOL)isEventDelayTimerExpired 672| 0|{ 673| 0| NSDate *timestamp = [self.store objectForKey:FBSDKSettingsInstallTimestamp]; 674| 0| if (timestamp) { 675| 0| return [[NSDate date] timeIntervalSinceDate:timestamp] > 86400; 676| 0| } 677| 0| return NO; 678| 0|} 679| | 680| |+ (BOOL)isSetATETimeExceedsInstallTime 681| 0|{ 682| 0| return [self.sharedSettings isSetATETimeExceedsInstallTime]; 683| 0|} 684| | 685| |- (BOOL)isSetATETimeExceedsInstallTime 686| 0|{ 687| 0| NSDate *installTimestamp = [self installTimestamp]; 688| 0| NSDate *setATETimestamp = [self advertiserTrackingEnabledTimestamp]; 689| 0| if (installTimestamp && setATETimestamp) { 690| 0| return [setATETimestamp timeIntervalSinceDate:installTimestamp] > 86400; 691| 0| } 692| 0| return NO; 693| 0|} 694| | 695| |+ (NSDate *_Nullable)getInstallTimestamp 696| 0|{ 697| 0| return self.sharedSettings.installTimestamp; 698| 0|} 699| | 700| |- (NSDate *_Nullable)installTimestamp 701| 0|{ 702| 0| return [self.store objectForKey:FBSDKSettingsInstallTimestamp]; 703| 0|} 704| | 705| |+ (NSDate *_Nullable)getSetAdvertiserTrackingEnabledTimestamp 706| 0|{ 707| 0| return [self.sharedSettings advertiserTrackingEnabledTimestamp]; 708| 0|} 709| | 710| |- (NSDate *_Nullable)advertiserTrackingEnabledTimestamp 711| 0|{ 712| 0| return [self.store objectForKey:FBSDKSettingsSetAdvertiserTrackingEnabledTimestamp]; 713| 0|} 714| | 715| |#pragma mark - Internal - Graph API Debug 716| | 717| |+ (void)updateGraphAPIDebugBehavior 718| 0|{ 719| | // Enable Warnings everytime Info is enabled 720| 0| if ([g_loggingBehaviors containsObject:FBSDKLoggingBehaviorGraphAPIDebugInfo] 721| 0| && ![g_loggingBehaviors containsObject:FBSDKLoggingBehaviorGraphAPIDebugWarning]) { 722| 0| [g_loggingBehaviors addObject:FBSDKLoggingBehaviorGraphAPIDebugWarning]; 723| 0| } 724| 0|} 725| | 726| |+ (NSString *)graphAPIDebugParamValue 727| 0|{ 728| 0| if ([[self loggingBehaviors] containsObject:FBSDKLoggingBehaviorGraphAPIDebugInfo]) { 729| 0| return @"info"; 730| 0| } else if ([[self loggingBehaviors] containsObject:FBSDKLoggingBehaviorGraphAPIDebugWarning]) { 731| 0| return @"warning"; 732| 0| } 733| | 734| 0| return nil; 735| 0|} 736| | 737| |#pragma mark - Testability 738| | 739| |#if DEBUG 740| | #if FBSDKTEST 741| | 742| |+ (void)reset 743| 0|{ 744| 0| [self.sharedSettings reset]; 745| | 746| 0| g_loggingBehaviors = nil; 747| 0| g_userAgentSuffix = nil; 748| 0| g_dataProcessingOptions = nil; 749| 0|} 750| | 751| |- (void)reset 752| 0|{ 753| | // Reset the nonce so that a new instance will be created. 754| 0| if (sharedSettingsNonce) { 755| 0| sharedSettingsNonce = 0; 756| 0| } 757| 0|} 758| | 759| |+ (void)setInfoDictionaryProvider:(id)provider 760| 0|{ 761| 0| self.sharedSettings.infoDictionaryProvider = provider; 762| 0|} 763| | 764| | #endif 765| |#endif 766| | 767| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKURL.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKAppLinkTarget.h" 24| | #import "FBSDKAppLink_Internal.h" 25| | #import "FBSDKCoreKitBasicsImport.h" 26| | #import "FBSDKMeasurementEvent_Internal.h" 27| | #import "FBSDKSettings.h" 28| | #import "FBSDKURL_Internal.h" 29| | 30| |NSString *const AutoAppLinkFlagKey = @"is_auto_applink"; 31| | 32| |@implementation FBSDKURL 33| | 34| |- (instancetype)initWithURL:(NSURL *)url forOpenInboundURL:(BOOL)forOpenURLEvent sourceApplication:(NSString *)sourceApplication forRenderBackToReferrerBar:(BOOL)forRenderBackToReferrerBar 35| 0|{ 36| 0| self = [super init]; 37| 0| if (!self) { 38| 0| return nil; 39| 0| } 40| | 41| 0| _inputURL = url; 42| 0| _targetURL = url; 43| | 44| | // Parse the query string parameters for the base URL 45| 0| NSDictionary *baseQuery = [FBSDKURL queryParametersForURL:url]; 46| 0| _inputQueryParameters = baseQuery; 47| 0| _targetQueryParameters = baseQuery; 48| | 49| | // Check for applink_data 50| 0| NSString *appLinkDataString = baseQuery[FBSDKAppLinkDataParameterName]; 51| 0| if (appLinkDataString) { 52| | // Try to parse the JSON 53| 0| NSError *error = nil; 54| 0| NSDictionary *applinkData = 55| 0| [FBSDKTypeUtility JSONObjectWithData:[appLinkDataString dataUsingEncoding:NSUTF8StringEncoding] 56| 0| options:0 57| 0| error:&error]; 58| 0| if (!error && [applinkData isKindOfClass:[NSDictionary class]]) { 59| | // If the version is not specified, assume it is 1. 60| 0| NSString *version = applinkData[FBSDKAppLinkVersionKeyName] ?: @"1.0"; 61| 0| NSString *target = applinkData[FBSDKAppLinkTargetKeyName]; 62| 0| if ([version isKindOfClass:[NSString class]] 63| 0| && [version isEqual:FBSDKAppLinkVersion]) { 64| | // There's applink data! The target should actually be the applink target. 65| 0| _appLinkData = applinkData; 66| 0| id applinkExtras = applinkData[FBSDKAppLinkExtrasKeyName]; 67| 0| if (applinkExtras && [applinkExtras isKindOfClass:[NSDictionary class]]) { 68| 0| _appLinkExtras = applinkExtras; 69| 0| } 70| 0| _targetURL = ([target isKindOfClass:[NSString class]] ? [NSURL URLWithString:target] : url); 71| 0| _targetQueryParameters = [FBSDKURL queryParametersForURL:_targetURL]; 72| | 73| 0| NSDictionary *refererAppLink = _appLinkData[FBSDKAppLinkRefererAppLink]; 74| 0| NSString *refererURLString = refererAppLink[FBSDKAppLinkRefererUrl]; 75| 0| NSString *refererAppName = refererAppLink[FBSDKAppLinkRefererAppName]; 76| | 77| 0| if (refererURLString && refererAppName) { 78| 0| FBSDKAppLinkTarget *appLinkTarget = [FBSDKAppLinkTarget appLinkTargetWithURL:[NSURL URLWithString:refererURLString] 79| 0| appStoreId:nil 80| 0| appName:refererAppName]; 81| 0| _appLinkReferer = [FBSDKAppLink appLinkWithSourceURL:[NSURL URLWithString:refererURLString] 82| 0| targets:@[appLinkTarget] 83| 0| webURL:nil 84| 0| isBackToReferrer:YES]; 85| 0| } 86| | 87| | // Raise Measurement Event 88| 0| NSString *const EVENT_YES_VAL = @"1"; 89| 0| NSString *const EVENT_NO_VAL = @"0"; 90| 0| NSMutableDictionary *logData = [NSMutableDictionary new]; 91| 0| [FBSDKTypeUtility dictionary:logData setObject:version forKey:@"version"]; 92| 0| if (refererURLString) { 93| 0| [FBSDKTypeUtility dictionary:logData setObject:refererURLString forKey:@"refererURL"]; 94| 0| } 95| 0| if (refererAppName) { 96| 0| [FBSDKTypeUtility dictionary:logData setObject:refererAppName forKey:@"refererAppName"]; 97| 0| } 98| 0| if (sourceApplication) { 99| 0| [FBSDKTypeUtility dictionary:logData setObject:sourceApplication forKey:@"sourceApplication"]; 100| 0| } 101| 0| if (_targetURL.absoluteString) { 102| 0| [FBSDKTypeUtility dictionary:logData setObject:_targetURL.absoluteString forKey:@"targetURL"]; 103| 0| } 104| 0| if (_inputURL.absoluteString) { 105| 0| [FBSDKTypeUtility dictionary:logData setObject:_inputURL.absoluteString forKey:@"inputURL"]; 106| 0| } 107| 0| if (_inputURL.scheme) { 108| 0| [FBSDKTypeUtility dictionary:logData setObject:_inputURL.scheme forKey:@"inputURLScheme"]; 109| 0| } 110| 0| [FBSDKTypeUtility dictionary:logData setObject:forRenderBackToReferrerBar ? EVENT_YES_VAL : EVENT_NO_VAL forKey:@"forRenderBackToReferrerBar"]; 111| 0| [FBSDKTypeUtility dictionary:logData setObject:forOpenURLEvent ? EVENT_YES_VAL : EVENT_NO_VAL forKey:@"forOpenUrl"]; 112| 0| [[FBSDKMeasurementEvent new] postNotificationForEventName:FBSDKAppLinkParseEventName args:logData]; 113| 0| if (forOpenURLEvent) { 114| 0| [[FBSDKMeasurementEvent new] postNotificationForEventName:FBSDKAppLinkNavigateInEventName args:logData]; 115| 0| } 116| 0| } 117| 0| } 118| 0| } 119| | 120| 0| return self; 121| 0|} 122| | 123| |- (BOOL)isAutoAppLink 124| 0|{ 125| 0| NSString *host = self.targetURL.host; 126| 0| NSString *scheme = self.targetURL.scheme; 127| 0| NSString *expectedHost = @"applinks"; 128| 0| NSString *expectedScheme = [NSString stringWithFormat:@"fb%@", FBSDKSettings.appID]; 129| 0| BOOL autoFlag = [self.appLinkData[AutoAppLinkFlagKey] boolValue]; 130| 0| return autoFlag && [expectedHost isEqual:host] && [expectedScheme isEqual:scheme]; 131| 0|} 132| | 133| |+ (instancetype)URLWithURL:(NSURL *)url 134| 0|{ 135| 0| return [[FBSDKURL alloc] initWithURL:url forOpenInboundURL:NO sourceApplication:nil forRenderBackToReferrerBar:NO]; 136| 0|} 137| | 138| |+ (instancetype)URLWithInboundURL:(NSURL *)url sourceApplication:(NSString *)sourceApplication 139| 0|{ 140| 0| return [[FBSDKURL alloc] initWithURL:url forOpenInboundURL:YES sourceApplication:sourceApplication forRenderBackToReferrerBar:NO]; 141| 0|} 142| | 143| |+ (instancetype)URLForRenderBackToReferrerBarURL:(NSURL *)url 144| 0|{ 145| 0| return [[FBSDKURL alloc] initWithURL:url forOpenInboundURL:NO sourceApplication:nil forRenderBackToReferrerBar:YES]; 146| 0|} 147| | 148| |+ (NSDictionary *)queryParametersForURL:(NSURL *)url 149| 0|{ 150| 0| NSMutableDictionary *parameters = [NSMutableDictionary dictionary]; 151| 0| NSString *query = url.query; 152| 0| if ([query isEqualToString:@""]) { 153| 0| return @{}; 154| 0| } 155| 0| NSArray *queryComponents = [query componentsSeparatedByString:@"&"]; 156| 0| for (NSString *component in queryComponents) { 157| 0| NSRange equalsLocation = [component rangeOfString:@"="]; 158| 0| if (equalsLocation.location == NSNotFound) { 159| | // There's no equals, so associate the key with NSNull 160| 0| [FBSDKTypeUtility dictionary:parameters setObject:[NSNull null] forKey:[FBSDKBasicUtility URLDecode:component]]; 161| 0| } else { 162| 0| NSString *key = [FBSDKBasicUtility URLDecode:[component substringToIndex:equalsLocation.location]]; 163| 0| NSString *value = [FBSDKBasicUtility URLDecode:[component substringFromIndex:equalsLocation.location + 1]]; 164| 0| [FBSDKTypeUtility dictionary:parameters setObject:value forKey:key]; 165| 0| } 166| 0| } 167| 0| return [NSDictionary dictionaryWithDictionary:parameters]; 168| 0|} 169| | 170| |@end 171| | 172| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKUserAgeRange.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKUserAgeRange.h" 20| | 21| |#import "FBSDKCoreKitBasicsImport.h" 22| |#import "FBSDKMath.h" 23| | 24| |NSString *const FBSDKUserAgeRangeMinCodingKey = @"FBSDKUserAgeRangeMinCodingKey"; 25| |NSString *const FBSDKUserAgeRangeMaxCodingKey = @"FBSDKUserAgeRangeMaxCodingKey"; 26| | 27| |@implementation FBSDKUserAgeRange 28| | 29| |- (instancetype)initMin:(NSNumber *)min 30| | max:(NSNumber *)max 31| 0|{ 32| 0| if (self = [super init]) { 33| 0| _min = min; 34| 0| _max = max; 35| 0| } 36| | 37| 0| return self; 38| 0|} 39| | 40| |+ (instancetype)ageRangeFromDictionary:(NSDictionary *)dictionary 41| 0|{ 42| 0| if (![FBSDKTypeUtility dictionaryValue:dictionary]) { 43| 0| return nil; 44| 0| } 45| | 46| 0| NSNumber *min = [FBSDKTypeUtility numberValue:dictionary[@"min"]]; 47| 0| NSNumber *max = [FBSDKTypeUtility numberValue:dictionary[@"max"]]; 48| | 49| 0| if ((min == nil && max == nil) 50| 0| || (min != nil && min.longValue < 0) 51| 0| || (max != nil && max.longValue < 0) 52| 0| || (min != nil && max != nil && min.longValue >= max.longValue)) { 53| 0| return nil; 54| 0| } 55| | 56| 0| return [[FBSDKUserAgeRange alloc] initMin:min max:max]; 57| 0|} 58| | 59| |#pragma mark - Equality 60| | 61| |- (NSUInteger)hash 62| 0|{ 63| 0| NSUInteger subhashes[] = { 64| 0| _min.hash, 65| 0| _max.hash, 66| 0| }; 67| 0| return [FBSDKMath hashWithIntegerArray:subhashes count:sizeof(subhashes) / sizeof(subhashes[0])]; 68| 0|} 69| | 70| |- (BOOL)isEqual:(id)object 71| 0|{ 72| 0| if (self == object) { 73| 0| return YES; 74| 0| } 75| 0| if (![object isKindOfClass:[FBSDKUserAgeRange class]]) { 76| 0| return NO; 77| 0| } 78| 0| return [self isEqualToUserAgeRange:object]; 79| 0|} 80| | 81| |- (BOOL)isEqualToUserAgeRange:(FBSDKUserAgeRange *)ageRange 82| 0|{ 83| 0| return (_max == ageRange.max) && (_min == ageRange.min); 84| 0|} 85| | 86| |#pragma mark - NSCopying 87| | 88| |- (id)copyWithZone:(NSZone *)zone 89| 0|{ 90| | // we're immutable. 91| 0| return self; 92| 0|} 93| | 94| |#pragma mark NSCoding 95| |+ (BOOL)supportsSecureCoding 96| 0|{ 97| 0| return YES; 98| 0|} 99| | 100| |- (void)encodeWithCoder:(nonnull NSCoder *)coder 101| 0|{ 102| 0| [coder encodeObject:_min forKey:FBSDKUserAgeRangeMinCodingKey]; 103| 0| [coder encodeObject:_max forKey:FBSDKUserAgeRangeMaxCodingKey]; 104| 0|} 105| | 106| |- (instancetype)initWithCoder:(nonnull NSCoder *)coder 107| 0|{ 108| 0| NSNumber *min = [coder decodeObjectOfClass:NSNumber.class forKey:FBSDKUserAgeRangeMinCodingKey]; 109| 0| NSNumber *max = [coder decodeObjectOfClass:NSNumber.class forKey:FBSDKUserAgeRangeMaxCodingKey]; 110| | 111| 0| return [self initMin:min max:max]; 112| 0|} 113| | 114| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKUtility.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKUtility.h" 20| | 21| |#import "FBSDKAccessToken.h" 22| |#import "FBSDKAuthenticationToken.h" 23| |#import "FBSDKCoreKitBasicsImport.h" 24| |#import "FBSDKInternalUtility.h" 25| | 26| |@implementation FBSDKUtility 27| | 28| |+ (NSDictionary *)dictionaryWithQueryString:(NSString *)queryString 29| 0|{ 30| 0| return [FBSDKBasicUtility dictionaryWithQueryString:queryString]; 31| 0|} 32| | 33| |+ (NSString *)queryStringWithDictionary:(NSDictionary *)dictionary error:(NSError **)errorRef 34| 0|{ 35| 0| return [FBSDKBasicUtility queryStringWithDictionary:dictionary error:errorRef invalidObjectHandler:NULL]; 36| 0|} 37| | 38| |+ (NSString *)URLDecode:(NSString *)value 39| 0|{ 40| 0| return [FBSDKBasicUtility URLDecode:value]; 41| 0|} 42| | 43| |+ (NSString *)URLEncode:(NSString *)value 44| 0|{ 45| 0| return [FBSDKBasicUtility URLEncode:value]; 46| 0|} 47| | 48| |+ (dispatch_source_t)startGCDTimerWithInterval:(double)interval block:(dispatch_block_t)block 49| 0|{ 50| 0| dispatch_source_t timer = dispatch_source_create( 51| 0| DISPATCH_SOURCE_TYPE_TIMER, // source type 52| 0| 0, // handle 53| 0| 0, // mask 54| 0| dispatch_get_main_queue() 55| 0| ); // queue 56| | 57| 0| dispatch_source_set_timer( 58| 0| timer, // dispatch source 59| 0| dispatch_time(DISPATCH_TIME_NOW, interval * NSEC_PER_SEC), // start 60| 0| interval * NSEC_PER_SEC, // interval 61| 0| 0 * NSEC_PER_SEC 62| 0| ); // leeway 63| | 64| 0| dispatch_source_set_event_handler(timer, block); 65| | 66| 0| dispatch_resume(timer); 67| | 68| 0| return timer; 69| 0|} 70| | 71| |+ (void)stopGCDTimer:(dispatch_source_t)timer 72| 0|{ 73| 0| if (timer) { 74| 0| dispatch_source_cancel(timer); 75| 0| } 76| 0|} 77| | 78| |+ (NSString *)SHA256Hash:(NSObject *)input 79| 0|{ 80| 0| return [FBSDKBasicUtility SHA256Hash:input]; 81| 0|} 82| | 83| |+ (NSString *)getGraphDomainFromToken 84| 0|{ 85| 0| NSString *graphDomain = FBSDKAuthenticationToken.currentAuthenticationToken.graphDomain; 86| 0| if (!graphDomain) { 87| 0| #pragma clang diagnostic push 88| 0| #pragma clang diagnostic ignored "-Wdeprecated-declarations" 89| 0| graphDomain = FBSDKAccessToken.currentAccessToken.graphDomain; 90| 0| #pragma clange diagnostic pop 91| 0| } 92| 0| return graphDomain; 93| 0|} 94| | 95| |+ (NSURL *)unversionedFacebookURLWithHostPrefix:(NSString *)hostPrefix 96| | path:(NSString *)path 97| | queryParameters:(NSDictionary *)queryParameters 98| | error:(NSError *__autoreleasing *)errorRef 99| 0|{ 100| 0| return [FBSDKInternalUtility unversionedFacebookURLWithHostPrefix:hostPrefix 101| 0| path:path 102| 0| queryParameters:queryParameters 103| 0| error:errorRef]; 104| 0|} 105| | 106| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/GraphAPI/FBSDKGraphErrorRecoveryProcessor.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKGraphErrorRecoveryProcessor.h" 24| | 25| | #import "FBSDKGraphRequestProtocol.h" 26| | 27| |@interface FBSDKGraphErrorRecoveryProcessor () 28| | 29| |@property (nullable, nonatomic, readonly, weak) id delegate; 30| | 31| |@end 32| | 33| |@implementation FBSDKGraphErrorRecoveryProcessor 34| | 35| |- (BOOL)processError:(NSError *)error 36| | request:(id)request 37| | delegate:(id)delegate 38| 0|{ 39| 0| if ([delegate respondsToSelector:@selector(processorWillProcessError:error:)]) { 40| 0| if (![delegate processorWillProcessError:self error:error]) { 41| 0| return NO; 42| 0| } 43| 0| } 44| | 45| 0| FBSDKGraphRequestError errorCategory = [error.userInfo[FBSDKGraphRequestErrorKey] unsignedIntegerValue]; 46| 0| switch (errorCategory) { 47| 0| case FBSDKGraphRequestErrorTransient: 48| 0| [delegate processorDidAttemptRecovery:self didRecover:YES error:nil]; 49| 0| return YES; 50| 0| case FBSDKGraphRequestErrorRecoverable: 51| 0| case FBSDKGraphRequestErrorOther: 52| 0| return NO; 53| 0| } 54| 0| return NO; 55| 0|} 56| | 57| |@end 58| | 59| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/GraphAPI/FBSDKGraphRequest.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKGraphRequest+Internal.h" 20| | 21| |#import 22| | 23| |#import "FBSDKCoreKitBasicsImport.h" 24| |#import "FBSDKGraphRequestConnecting.h" 25| |#import "FBSDKGraphRequestConnection.h" 26| |#import "FBSDKGraphRequestConnectionFactory.h" 27| |#import "FBSDKGraphRequestConnectionProviding.h" 28| |#import "FBSDKGraphRequestDataAttachment.h" 29| |#import "FBSDKInternalUtility.h" 30| |#import "FBSDKLogger.h" 31| |#import "FBSDKSettings+Internal.h" 32| |#import "FBSDKTokenStringProviding.h" 33| | 34| |// constants 35| |FBSDKHTTPMethod FBSDKHTTPMethodGET = @"GET"; 36| |FBSDKHTTPMethod FBSDKHTTPMethodPOST = @"POST"; 37| |FBSDKHTTPMethod FBSDKHTTPMethodDELETE = @"DELETE"; 38| | 39| |static Class _currentAccessTokenStringProvider; 40| | 41| |@interface FBSDKGraphRequest () 42| |@property (nonatomic, readwrite, assign) FBSDKGraphRequestFlags flags; 43| |@property (nonatomic, readwrite, copy) FBSDKHTTPMethod HTTPMethod; 44| |@property (nonatomic, strong) id connectionFactory; 45| |@end 46| | 47| |@implementation FBSDKGraphRequest 48| | 49| |@synthesize HTTPMethod; 50| |@synthesize flags; 51| | 52| |- (instancetype)initWithGraphPath:(NSString *)graphPath 53| 0|{ 54| 0| return [self initWithGraphPath:graphPath parameters:@{@"fields" : @""}]; 55| 0|} 56| | 57| |- (instancetype)initWithGraphPath:(NSString *)graphPath 58| | HTTPMethod:(FBSDKHTTPMethod)method 59| 0|{ 60| 0| if (method == FBSDKHTTPMethodGET) { 61| 0| return [self initWithGraphPath:graphPath parameters:@{@"fields" : @""} HTTPMethod:method]; 62| 0| } else { 63| 0| return [self initWithGraphPath:graphPath parameters:@{} HTTPMethod:method]; 64| 0| } 65| 0|} 66| | 67| |- (instancetype)initWithGraphPath:(NSString *)graphPath 68| | parameters:(NSDictionary *)parameters 69| 0|{ 70| 0| return [self initWithGraphPath:graphPath 71| 0| parameters:parameters 72| 0| flags:FBSDKGraphRequestFlagNone]; 73| 0|} 74| | 75| |- (instancetype)initWithGraphPath:(NSString *)graphPath 76| | parameters:(NSDictionary *)parameters 77| | HTTPMethod:(FBSDKHTTPMethod)method 78| 0|{ 79| 0| return [self initWithGraphPath:graphPath 80| 0| parameters:parameters 81| 0| tokenString:[_currentAccessTokenStringProvider tokenString] 82| 0| version:nil 83| 0| HTTPMethod:method]; 84| 0|} 85| | 86| |- (instancetype)initWithGraphPath:(NSString *)graphPath 87| | parameters:(NSDictionary *)parameters 88| | flags:(FBSDKGraphRequestFlags)requestFlags 89| 0|{ 90| 0| return [self initWithGraphPath:graphPath 91| 0| parameters:parameters 92| 0| tokenString:[_currentAccessTokenStringProvider tokenString] 93| 0| HTTPMethod:FBSDKHTTPMethodGET 94| 0| flags:requestFlags]; 95| 0|} 96| | 97| |- (instancetype)initWithGraphPath:(NSString *)graphPath 98| | parameters:(NSDictionary *)parameters 99| | tokenString:(NSString *)tokenString 100| | HTTPMethod:(FBSDKHTTPMethod)method 101| | flags:(FBSDKGraphRequestFlags)requestFlags 102| 0|{ 103| 0| if ((self = [self initWithGraphPath:graphPath 104| 0| parameters:parameters 105| 0| tokenString:tokenString 106| 0| version:[FBSDKSettings graphAPIVersion] 107| 0| HTTPMethod:method])) { 108| 0| self.flags |= requestFlags; 109| 0| } 110| 0| return self; 111| 0|} 112| | 113| |- (instancetype)initWithGraphPath:(NSString *)graphPath 114| | parameters:(NSDictionary *)parameters 115| | tokenString:(NSString *)tokenString 116| | HTTPMethod:(NSString *)method 117| | flags:(FBSDKGraphRequestFlags)requestFlags 118| | connectionFactory:(id)factory 119| 0|{ 120| 0| return [self initWithGraphPath:graphPath 121| 0| parameters:parameters 122| 0| tokenString:tokenString 123| 0| HTTPMethod:method 124| 0| version:[FBSDKSettings graphAPIVersion] 125| 0| flags:requestFlags 126| 0| connectionFactory:factory]; 127| 0|} 128| | 129| |- (instancetype)initWithGraphPath:(NSString *)graphPath 130| | parameters:(NSDictionary *)parameters 131| | tokenString:(NSString *)tokenString 132| | HTTPMethod:(NSString *)method 133| | version:(NSString *)version 134| | flags:(FBSDKGraphRequestFlags)requestFlags 135| | connectionFactory:(id)factory 136| 0|{ 137| 0| if ((self = [self initWithGraphPath:graphPath 138| 0| parameters:parameters 139| 0| tokenString:tokenString 140| 0| version:version 141| 0| HTTPMethod:method])) { 142| 0| self.flags |= requestFlags; 143| 0| self.connectionFactory = factory; 144| 0| } 145| 0| return self; 146| 0|} 147| | 148| |- (instancetype)initWithGraphPath:(NSString *)graphPath 149| | parameters:(NSDictionary *)parameters 150| | tokenString:(NSString *)tokenString 151| | version:(NSString *)version 152| | HTTPMethod:(FBSDKHTTPMethod)method 153| 0|{ 154| 0| if ((self = [super init])) { 155| 0| _tokenString = tokenString ? [tokenString copy] : nil; 156| 0| _version = version ? [version copy] : [FBSDKSettings graphAPIVersion]; 157| 0| _graphPath = [graphPath copy]; 158| 0| self.HTTPMethod = method.length > 0 ? [method copy] : FBSDKHTTPMethodGET; 159| 0| _parameters = parameters ?: @{}; 160| 0| if (!FBSDKSettings.isGraphErrorRecoveryEnabled) { 161| 0| self.flags = FBSDKGraphRequestFlagDisableErrorRecovery; 162| 0| } 163| 0| _connectionFactory = [FBSDKGraphRequestConnectionFactory new]; 164| 0| } 165| 0| return self; 166| 0|} 167| | 168| |- (BOOL)isGraphErrorRecoveryDisabled 169| 0|{ 170| 0| return (self.flags & FBSDKGraphRequestFlagDisableErrorRecovery); 171| 0|} 172| | 173| |- (void)setGraphErrorRecoveryDisabled:(BOOL)disable 174| 0|{ 175| 0| if (disable) { 176| 0| self.flags |= FBSDKGraphRequestFlagDisableErrorRecovery; 177| 0| } else { 178| 0| self.flags &= ~FBSDKGraphRequestFlagDisableErrorRecovery; 179| 0| } 180| 0|} 181| | 182| |- (BOOL)hasAttachments 183| 0|{ 184| 0| __block BOOL hasAttachments = NO; 185| 0| [FBSDKTypeUtility dictionary:self.parameters enumerateKeysAndObjectsUsingBlock:^(id key, id obj, BOOL *stop) { 186| 0| if ([FBSDKGraphRequest isAttachment:obj]) { 187| 0| hasAttachments = YES; 188| 0| *stop = YES; 189| 0| } 190| 0| }]; 191| 0| return hasAttachments; 192| 0|} 193| | 194| |+ (BOOL)isAttachment:(id)item 195| 0|{ 196| 0| return ([item isKindOfClass:[UIImage class]] 197| 0| || [item isKindOfClass:[NSData class]] 198| 0| || [item isKindOfClass:[FBSDKGraphRequestDataAttachment class]]); 199| 0|} 200| | 201| |+ (NSString *)serializeURL:(NSString *)baseUrl 202| | params:(NSDictionary *)params 203| 0|{ 204| 0| return [self serializeURL:baseUrl params:params httpMethod:FBSDKHTTPMethodGET]; 205| 0|} 206| | 207| |+ (NSString *)serializeURL:(NSString *)baseUrl 208| | params:(NSDictionary *)params 209| | httpMethod:(NSString *)httpMethod 210| 0|{ 211| 0| return [self serializeURL:baseUrl params:params httpMethod:httpMethod forBatch:NO]; 212| 0|} 213| | 214| |+ (NSString *)serializeURL:(NSString *)baseUrl 215| | params:(NSDictionary *)params 216| | httpMethod:(NSString *)httpMethod 217| | forBatch:(BOOL)forBatch 218| 0|{ 219| 0| params = [self preprocessParams:params]; 220| | 221| 0| #pragma clang diagnostic push 222| 0| #pragma clang diagnostic ignored "-Wdeprecated-declarations" 223| 0| NSURL *parsedURL = [NSURL URLWithString:[baseUrl stringByAddingPercentEscapesUsingEncoding:NSUTF8StringEncoding]]; 224| 0| #pragma clang diagnostic pop 225| | 226| 0| if ([httpMethod isEqualToString:FBSDKHTTPMethodPOST] && !forBatch) { 227| 0| return baseUrl; 228| 0| } 229| | 230| 0| NSString *queryPrefix = parsedURL.query ? @"&" : @"?"; 231| | 232| 0| NSString *query = [FBSDKBasicUtility queryStringWithDictionary:params error:NULL invalidObjectHandler:^id (id object, BOOL *stop) { 233| 0| if ([self isAttachment:object]) { 234| 0| if ([httpMethod isEqualToString:FBSDKHTTPMethodGET]) { 235| 0| [FBSDKLogger singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors logEntry:@"can not use GET to upload a file"]; 236| 0| } 237| 0| return nil; 238| 0| } 239| 0| return object; 240| 0| }]; 241| 0| return [NSString stringWithFormat:@"%@%@%@", baseUrl, queryPrefix, query]; 242| 0|} 243| | 244| |+ (NSDictionary *)preprocessParams:(NSDictionary *)params 245| 0|{ 246| 0| NSString *debugValue = [FBSDKSettings graphAPIDebugParamValue]; 247| 0| if (debugValue) { 248| 0| NSMutableDictionary *mutableParams = [NSMutableDictionary dictionaryWithDictionary:params]; 249| 0| [FBSDKTypeUtility dictionary:mutableParams setObject:debugValue forKey:@"debug"]; 250| 0| return mutableParams; 251| 0| } 252| | 253| 0| return params; 254| 0|} 255| | 256| |+ (void)setCurrentAccessTokenStringProvider:(Class)provider 257| 0|{ 258| 0| if (_currentAccessTokenStringProvider != provider) { 259| 0| _currentAccessTokenStringProvider = provider; 260| 0| } 261| 0|} 262| | 263| |- (id)startWithCompletionHandler:(FBSDKGraphRequestBlock)handler 264| 0|{ 265| 0| FBSDKGraphRequestCompletion completion = ^void (id connection, id result, NSError *error) { 266| 0| handler(FBSDK_CAST_TO_CLASS_OR_NIL(connection, FBSDKGraphRequestConnection), result, error); 267| 0| }; 268| | 269| 0| return [self startWithCompletion:completion]; 270| 0|} 271| | 272| |- (id)startWithCompletion:(FBSDKGraphRequestCompletion)completion 273| 0|{ 274| 0| id connection = [self.connectionFactory createGraphRequestConnection]; 275| 0| id request = (id)self; 276| 0| [connection addRequest:request completion:completion]; 277| 0| [connection start]; 278| 0| return connection; 279| 0|} 280| | 281| |#pragma mark - Debugging helpers 282| | 283| |- (NSString *)description 284| 0|{ 285| 0| return [self formattedDescription]; 286| 0|} 287| | 288| |- (NSString *)formattedDescription 289| 0|{ 290| 0| NSMutableString *result = [NSMutableString stringWithFormat:@"<%@: %p", 291| 0| NSStringFromClass([self class]), 292| 0| self]; 293| 0| if (self.graphPath) { 294| 0| [result appendFormat:@", graphPath: %@", self.graphPath]; 295| 0| } 296| 0| if (self.HTTPMethod) { 297| 0| [result appendFormat:@", HTTPMethod: %@", self.HTTPMethod]; 298| 0| } 299| 0| [result appendFormat:@", parameters: %@>", self.parameters.description]; 300| 0| return result; 301| 0|} 302| | 303| |#if DEBUG 304| | #if FBSDKTEST 305| | 306| |+ (void)reset 307| 0|{ 308| 0| _currentAccessTokenStringProvider = nil; 309| 0|} 310| | 311| |+ (Class)currentAccessTokenStringProvider 312| 0|{ 313| 0| return _currentAccessTokenStringProvider; 314| 0|} 315| | 316| | #endif 317| |#endif 318| | 319| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/GraphAPI/FBSDKGraphRequestConnection.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKGraphRequestConnection+Internal.h" 20| | 21| |#import "FBSDKAppEvents+EventLogging.h" 22| |#import "FBSDKConstants.h" 23| |#import "FBSDKCoreKit+Internal.h" 24| |#import "FBSDKError.h" 25| |#import "FBSDKErrorConfigurationProvider.h" 26| |#import "FBSDKGraphRequest+Internal.h" 27| |#import "FBSDKGraphRequestBody.h" 28| |#import "FBSDKGraphRequestConnectionFactory.h" 29| |#import "FBSDKGraphRequestDataAttachment.h" 30| |#import "FBSDKGraphRequestMetadata.h" 31| |#import "FBSDKGraphRequestPiggybackManagerProvider.h" 32| |#import "FBSDKInternalUtility.h" 33| |#import "FBSDKLogger.h" 34| |#import "FBSDKOperatingSystemVersionComparing.h" 35| |#import "FBSDKSettingsProtocol.h" 36| |#import "FBSDKURLSession+URLSessionProxying.h" 37| |#import "FBSDKURLSessionProxyFactory.h" 38| |#import "FBSDKURLSessionProxying.h" 39| |#import "NSProcessInfo+Protocols.h" 40| | 41| |NSString *const FBSDKNonJSONResponseProperty = @"FACEBOOK_NON_JSON_RESULT"; 42| | 43| |// URL construction constants 44| |static NSString *const kGraphURLPrefix = @"graph."; 45| |static NSString *const kGraphVideoURLPrefix = @"graph-video."; 46| | 47| |static NSString *const kBatchKey = @"batch"; 48| |static NSString *const kBatchMethodKey = @"method"; 49| |static NSString *const kBatchRelativeURLKey = @"relative_url"; 50| |static NSString *const kBatchAttachmentKey = @"attached_files"; 51| |static NSString *const kBatchFileNamePrefix = @"file"; 52| |static NSString *const kBatchEntryName = @"name"; 53| | 54| |static NSString *const kAccessTokenKey = @"access_token"; 55| |#if TARGET_OS_TV 56| |static NSString *const kSDK = @"tvos"; 57| |static NSString *const kUserAgentBase = @"FBtvOSSDK"; 58| |#else 59| |static NSString *const kSDK = @"ios"; 60| |static NSString *const kUserAgentBase = @"FBiOSSDK"; 61| |#endif 62| |static NSString *const kBatchRestMethodBaseURL = @"method/"; 63| | 64| |static NSTimeInterval g_defaultTimeout = 60.0; 65| | 66| |#if !TARGET_OS_TV 67| |static FBSDKAccessToken *_CreateExpiredAccessToken(FBSDKAccessToken *accessToken) 68| 0|{ 69| 0| if (accessToken == nil) { 70| 0| return nil; 71| 0| } 72| 0| if (accessToken.isExpired) { 73| 0| return accessToken; 74| 0| } 75| 0| NSDate *expirationDate = [NSDate dateWithTimeIntervalSinceNow:-1]; 76| 0| #pragma clang diagnostic push 77| 0| #pragma clang diagnostic ignored "-Wdeprecated-declarations" 78| 0| return [[FBSDKAccessToken alloc] initWithTokenString:accessToken.tokenString 79| 0| permissions:accessToken.permissions.allObjects 80| 0| declinedPermissions:accessToken.declinedPermissions.allObjects 81| 0| expiredPermissions:accessToken.expiredPermissions.allObjects 82| 0| appID:accessToken.appID 83| 0| userID:accessToken.userID 84| 0| expirationDate:expirationDate 85| 0| refreshDate:expirationDate 86| 0| dataAccessExpirationDate:expirationDate 87| 0| graphDomain:accessToken.graphDomain]; 88| 0| #pragma clange diagnostic pop 89| 0|} 90| | 91| |#endif 92| | 93| |// ---------------------------------------------------------------------------- 94| |// FBSDKGraphRequestConnectionState 95| | 96| |typedef NS_ENUM(NSUInteger, FBSDKGraphRequestConnectionState) { 97| | kStateCreated, 98| | kStateSerialized, 99| | kStateStarted, 100| | kStateCompleted, 101| | kStateCancelled, 102| |}; 103| | 104| |// ---------------------------------------------------------------------------- 105| |// Private properties and methods 106| | 107| |@interface FBSDKGraphRequestConnection () < 108| | NSURLSessionDataDelegate 109| |#if !TARGET_OS_TV 110| | , FBSDKGraphErrorRecoveryProcessorDelegate 111| |#endif 112| |> 113| | 114| |@property (nonatomic, retain) NSMutableArray *requests; 115| |@property (nonatomic, assign) FBSDKGraphRequestConnectionState state; 116| |@property (nonatomic, strong) FBSDKLogger *logger; 117| |@property (nonatomic, assign) uint64_t requestStartTime; 118| |@property (nonatomic, strong) id session; 119| |@property (nonatomic, strong) id sessionProxyFactory; 120| |@property (nonatomic, strong) id errorConfigurationProvider; 121| |@property (nonatomic, strong) Class piggybackManagerProvider; 122| |@property (nonatomic, strong) Class settings; 123| |@property (nonatomic, strong) id connectionFactory; 124| |@property (nonatomic, strong) id eventLogger; 125| |@property (nonatomic, strong) id operatingSystemVersionComparer; 126| |@property (nonatomic, strong) id macCatalystDeterminator; 127| | 128| |@end 129| | 130| |// ---------------------------------------------------------------------------- 131| |// FBSDKGraphRequestConnection 132| | 133| |@implementation FBSDKGraphRequestConnection 134| |{ 135| | NSString *_overrideVersionPart; 136| | NSUInteger _expectingResults; 137| | NSOperationQueue *_delegateQueue; 138| | id _session; 139| | id _sessionProxyFactory; 140| |#if !TARGET_OS_TV 141| | FBSDKGraphRequestMetadata *_recoveringRequestMetadata; 142| | FBSDKGraphErrorRecoveryProcessor *_errorRecoveryProcessor; 143| |#endif 144| |} 145| | 146| |static BOOL _canMakeRequests = NO; 147| | 148| |- (instancetype)init 149| 0|{ 150| 0| return [self initWithURLSessionProxyFactory:[FBSDKURLSessionProxyFactory new] 151| 0| errorConfigurationProvider:[FBSDKErrorConfigurationProvider new] 152| 0| piggybackManagerProvider:FBSDKGraphRequestPiggybackManagerProvider.self 153| 0| settings:FBSDKSettings.self 154| 0| connectionFactory:[FBSDKGraphRequestConnectionFactory new] 155| 0| eventLogger:FBSDKAppEvents.singleton 156| 0| operatingSystemVersionComparer:NSProcessInfo.processInfo 157| 0| macCatalystDeterminator:NSProcessInfo.processInfo]; 158| 0|} 159| | 160| |- (instancetype)initWithURLSessionProxyFactory:(id)proxyFactory 161| | errorConfigurationProvider:(id)errorConfigurationProvider 162| | piggybackManagerProvider:(Class)piggybackManagerProvider 163| | settings:(Class)settings 164| | connectionFactory:(id)factory 165| | eventLogger:(id)eventLogger 166| | operatingSystemVersionComparer:(id)operatingSystemVersionComparer 167| | macCatalystDeterminator:(id)macCatalystDeterminator 168| 0|{ 169| 0| if ((self = [super init])) { 170| 0| _requests = [NSMutableArray new]; 171| 0| _timeout = g_defaultTimeout; 172| 0| _state = kStateCreated; 173| 0| _logger = [[FBSDKLogger alloc] initWithLoggingBehavior:FBSDKLoggingBehaviorNetworkRequests]; 174| 0| _sessionProxyFactory = proxyFactory; 175| 0| _session = [proxyFactory createSessionProxyWithDelegate:self queue:_delegateQueue]; 176| 0| _errorConfigurationProvider = errorConfigurationProvider; 177| 0| _piggybackManagerProvider = piggybackManagerProvider; 178| 0| _settings = settings; 179| 0| _connectionFactory = factory; 180| 0| _eventLogger = eventLogger; 181| 0| _operatingSystemVersionComparer = operatingSystemVersionComparer; 182| 0| _macCatalystDeterminator = macCatalystDeterminator; 183| 0| } 184| 0| return self; 185| 0|} 186| | 187| |- (void)dealloc 188| 0|{ 189| 0| [self.session invalidateAndCancel]; 190| 0|} 191| | 192| |#pragma mark - Public 193| | 194| |+ (void)setDefaultConnectionTimeout:(NSTimeInterval)defaultTimeout 195| 0|{ 196| 0| if (defaultTimeout >= 0) { 197| 0| g_defaultTimeout = defaultTimeout; 198| 0| } 199| 0|} 200| | 201| |+ (NSTimeInterval)defaultConnectionTimeout 202| 0|{ 203| 0| return g_defaultTimeout; 204| 0|} 205| | 206| |- (void) addRequest:(id)request 207| | completionHandler:(FBSDKGraphRequestBlock)handler 208| 0|{ 209| 0| FBSDKGraphRequestCompletion completion = ^void (id connection, id result, NSError *error) { 210| 0| handler(FBSDK_CAST_TO_CLASS_OR_NIL(connection, FBSDKGraphRequestConnection), result, error); 211| 0| }; 212| | 213| 0| [self addRequest:request completion:completion]; 214| 0|} 215| | 216| |- (void)addRequest:(id)request completion:(FBSDKGraphRequestCompletion)completion 217| 0|{ 218| 0| [self addRequest:request name:@"" completion:completion]; 219| 0|} 220| | 221| |- (void) addRequest:(id)request 222| | batchEntryName:(NSString *)name 223| | completionHandler:(FBSDKGraphRequestBlock)handler 224| 0|{ 225| 0| FBSDKGraphRequestCompletion completion = ^void (id connection, id result, NSError *error) { 226| 0| handler(FBSDK_CAST_TO_CLASS_OR_NIL(connection, FBSDKGraphRequestConnection), result, error); 227| 0| }; 228| | 229| 0| [self addRequest:request name:name completion:completion]; 230| 0|} 231| | 232| |- (void)addRequest:(id)request 233| | name:(NSString *)name 234| | completion:(FBSDKGraphRequestCompletion)completion 235| 0|{ 236| 0| NSDictionary *batchParams = name.length > 0 ? @{kBatchEntryName : name } : nil; 237| 0| [self addRequest:request parameters:batchParams completion:completion]; 238| 0|} 239| | 240| |- (void) addRequest:(id)request 241| | batchParameters:(NSDictionary *)batchParameters 242| | completionHandler:(FBSDKGraphRequestBlock)handler 243| 0|{ 244| 0| FBSDKGraphRequestCompletion completion = ^void (id connection, id result, NSError *error) { 245| 0| handler(FBSDK_CAST_TO_CLASS_OR_NIL(connection, FBSDKGraphRequestConnection), result, error); 246| 0| }; 247| | 248| 0| [self addRequest:request parameters:batchParameters completion:completion]; 249| 0|} 250| | 251| |- (void)addRequest:(id)request 252| | parameters:(NSDictionary *)parameters 253| | completion:(FBSDKGraphRequestCompletion)completion 254| 0|{ 255| 0| if (self.state != kStateCreated) { 256| 0| @throw [NSException exceptionWithName:NSInternalInconsistencyException 257| 0| reason:@"Cannot add requests once started or if a URLRequest is set" 258| 0| userInfo:nil]; 259| 0| } 260| 0| FBSDKGraphRequestMetadata *metadata = [[FBSDKGraphRequestMetadata alloc] initWithRequest:request 261| 0| completionHandler:completion 262| 0| batchParameters:parameters]; 263| | 264| 0| [FBSDKTypeUtility array:self.requests addObject:metadata]; 265| 0|} 266| | 267| |- (void)cancel 268| 0|{ 269| 0| self.state = kStateCancelled; 270| 0| [self.session invalidateAndCancel]; 271| 0|} 272| | 273| |- (void)overrideGraphAPIVersion:(NSString *)version 274| 0|{ 275| 0| if (![_overrideVersionPart isEqualToString:version]) { 276| 0| _overrideVersionPart = [version copy]; 277| 0| } 278| 0|} 279| | 280| |- (void)start 281| 0|{ 282| 0| if (![self.class canMakeRequests]) { 283| 0| NSString *msg = @"FBSDKGraphRequestConnection cannot be started before Facebook SDK initialized."; 284| | // TODO: Use a logger provider for this. 285| 0| [self.logger.class singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors 286| 0| logEntry:msg]; 287| 0| self.state = kStateCancelled; 288| 0| [self completeFBSDKURLSessionWithResponse:nil 289| 0| data:nil 290| 0| networkError:[FBSDKError unknownErrorWithMessage:msg]]; 291| | 292| 0| return; 293| 0| } 294| | 295| 0| if (self.state != kStateCreated && self.state != kStateSerialized) { 296| 0| [self.logger.class singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors 297| 0| logEntry:@"FBSDKGraphRequestConnection cannot be started again."]; 298| 0| return; 299| 0| } 300| 0| Class piggybackManager = [self.piggybackManagerProvider.class piggybackManager]; 301| 0| [piggybackManager.class addPiggybackRequests:self]; 302| 0| NSMutableURLRequest *request = [self requestWithBatch:self.requests timeout:_timeout]; 303| | 304| 0| self.state = kStateStarted; 305| | 306| 0| [self logRequest:request bodyLength:0 bodyLogger:nil attachmentLogger:nil]; 307| 0| _requestStartTime = [FBSDKInternalUtility currentTimeInMilliseconds]; 308| | 309| 0| FBSDKURLSessionTaskBlock completionHandler = ^(NSData *responseDataV1, NSURLResponse *responseV1, NSError *errorV1) { 310| 0| FBSDKURLSessionTaskBlock handler = ^(NSData *responseDataV2, 311| 0| NSURLResponse *responseV2, 312| 0| NSError *errorV2) { 313| 0| [self completeFBSDKURLSessionWithResponse:responseV2 314| 0| data:responseDataV2 315| 0| networkError:errorV2]; 316| 0| }; 317| | 318| 0| if (errorV1) { 319| 0| [self _taskDidCompleteWithError:errorV1 handler:handler]; 320| 0| } else { 321| 0| [self taskDidCompleteWithResponse:responseV1 data:responseDataV1 requestStartTime:self.requestStartTime handler:handler]; 322| 0| } 323| 0| }; 324| 0| [self.session executeURLRequest:request completionHandler:completionHandler]; 325| | 326| 0| id delegate = self.delegate; 327| 0| if ([delegate respondsToSelector:@selector(requestConnectionWillBeginLoading:)]) { 328| 0| if (_delegateQueue) { 329| 0| [_delegateQueue addOperationWithBlock:^{ 330| 0| [delegate requestConnectionWillBeginLoading:self]; 331| 0| }]; 332| 0| } else { 333| 0| [delegate requestConnectionWillBeginLoading:self]; 334| 0| } 335| 0| } 336| 0|} 337| | 338| |- (NSOperationQueue *)delegateQueue 339| 0|{ 340| 0| return _delegateQueue; 341| 0|} 342| | 343| |- (void)setDelegateQueue:(NSOperationQueue *)queue 344| 0|{ 345| 0| _session.delegateQueue = queue; 346| 0| _delegateQueue = queue; 347| 0|} 348| | 349| |#pragma mark - Private Properties 350| | 351| |+ (void)setCanMakeRequests 352| 0|{ 353| 0| _canMakeRequests = YES; 354| 0|} 355| | 356| |+ (BOOL)canMakeRequests 357| 0|{ 358| 0| return _canMakeRequests; 359| 0|} 360| | 361| |- (id)session 362| 0|{ 363| 0| return _session; 364| 0|} 365| | 366| |- (id)sessionProxyFactory 367| 0|{ 368| 0| return _sessionProxyFactory; 369| 0|} 370| | 371| |#pragma mark - Private methods (request generation) 372| | 373| |// 374| |// Adds request data to a batch in a format expected by the JsonWriter. 375| |// Binary attachments are referenced by name in JSON and added to the 376| |// attachments dictionary. 377| |// 378| |- (void)addRequest:(FBSDKGraphRequestMetadata *)metadata 379| | toBatch:(NSMutableArray *)batch 380| | attachments:(NSMutableDictionary *)attachments 381| | batchToken:(NSString *)batchToken 382| 0|{ 383| 0| NSMutableDictionary *requestElement = [NSMutableDictionary new]; 384| | 385| 0| if (metadata.batchParameters) { 386| 0| [requestElement addEntriesFromDictionary:metadata.batchParameters]; 387| 0| } 388| | 389| 0| if (batchToken) { 390| 0| NSMutableDictionary *params = [NSMutableDictionary 391| 0| dictionaryWithDictionary:metadata.request.parameters]; 392| 0| [FBSDKTypeUtility dictionary:params setObject:batchToken forKey:kAccessTokenKey]; 393| 0| metadata.request.parameters = params; 394| 0| [self registerTokenToOmitFromLog:batchToken]; 395| 0| } 396| | 397| 0| NSString *urlString = [self urlStringForSingleRequest:metadata.request forBatch:YES]; 398| 0| [FBSDKTypeUtility dictionary:requestElement setObject:urlString forKey:kBatchRelativeURLKey]; 399| 0| [FBSDKTypeUtility dictionary:requestElement setObject:metadata.request.HTTPMethod forKey:kBatchMethodKey]; 400| | 401| 0| NSMutableArray *attachmentNames = [NSMutableArray array]; 402| | 403| 0| [FBSDKTypeUtility dictionary:metadata.request.parameters enumerateKeysAndObjectsUsingBlock:^(id key, id value, BOOL *stop) { 404| 0| if ([FBSDKGraphRequest isAttachment:value]) { 405| 0| NSString *name = [NSString stringWithFormat:@"%@%lu", 406| 0| kBatchFileNamePrefix, 407| 0| (unsigned long)attachments.count]; 408| 0| [FBSDKTypeUtility array:attachmentNames addObject:name]; 409| 0| [FBSDKTypeUtility dictionary:attachments setObject:value forKey:name]; 410| 0| } 411| 0| }]; 412| | 413| 0| if (attachmentNames.count) { 414| 0| [FBSDKTypeUtility dictionary:requestElement setObject:[attachmentNames componentsJoinedByString:@","] forKey:kBatchAttachmentKey]; 415| 0| } 416| | 417| 0| [FBSDKTypeUtility array:batch addObject:requestElement]; 418| 0|} 419| | 420| |- (void)appendAttachments:(NSDictionary *)attachments 421| | toBody:(FBSDKGraphRequestBody *)body 422| | addFormData:(BOOL)addFormData 423| | logger:(FBSDKLogger *)logger 424| 0|{ 425| 0| [FBSDKTypeUtility dictionary:attachments enumerateKeysAndObjectsUsingBlock:^(id key, id value, BOOL *stop) { 426| 0| value = [FBSDKBasicUtility convertRequestValue:value]; 427| 0| if ([value isKindOfClass:[NSString class]]) { 428| 0| if (addFormData) { 429| 0| [body appendWithKey:key formValue:(NSString *)value logger:logger]; 430| 0| } 431| 0| } else if ([value isKindOfClass:[UIImage class]]) { 432| 0| [body appendWithKey:key imageValue:(UIImage *)value logger:logger]; 433| 0| } else if ([value isKindOfClass:[NSData class]]) { 434| 0| [body appendWithKey:key dataValue:(NSData *)value logger:logger]; 435| 0| } else if ([value isKindOfClass:[FBSDKGraphRequestDataAttachment class]]) { 436| 0| [body appendWithKey:key dataAttachmentValue:(FBSDKGraphRequestDataAttachment *)value logger:logger]; 437| 0| } else { 438| 0| NSString *msg = [NSString stringWithFormat:@"Unsupported FBSDKGraphRequest attachment:%@, skipping.", value]; 439| 0| [logger.class singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors logEntry:msg]; 440| 0| } 441| 0| }]; 442| 0|} 443| | 444| |// 445| |// Serializes all requests in the batch to JSON and appends the result to 446| |// body. Also names all attachments that need to go as separate blocks in 447| |// the body of the request. 448| |// 449| |// All the requests are serialized into JSON, with any binary attachments 450| |// named and referenced by name in the JSON. 451| |// 452| |- (void)appendJSONRequests:(NSArray *)requests 453| | toBody:(FBSDKGraphRequestBody *)body 454| | andNameAttachments:(NSMutableDictionary *)attachments 455| | logger:(FBSDKLogger *)logger 456| 0|{ 457| 0| NSMutableArray *batch = [NSMutableArray new]; 458| 0| NSString *batchToken = nil; 459| 0| for (FBSDKGraphRequestMetadata *metadata in requests) { 460| 0| NSString *individualToken = [self accessTokenWithRequest:metadata.request]; 461| 0| BOOL isClientToken = [self.settings.class clientToken] && [individualToken hasSuffix:[self.settings.class clientToken]]; 462| 0| if (!batchToken 463| 0| && !isClientToken) { 464| 0| batchToken = individualToken; 465| 0| } 466| 0| [self addRequest:metadata 467| 0| toBatch:batch 468| 0| attachments:attachments 469| 0| batchToken:[batchToken isEqualToString:individualToken] ? nil : individualToken]; 470| 0| } 471| | 472| 0| NSString *jsonBatch = [FBSDKBasicUtility JSONStringForObject:batch error:NULL invalidObjectHandler:NULL]; 473| | 474| 0| [body appendWithKey:kBatchKey formValue:jsonBatch logger:logger]; 475| 0| if (batchToken) { 476| 0| [body appendWithKey:kAccessTokenKey formValue:batchToken logger:logger]; 477| 0| } 478| 0|} 479| | 480| |- (BOOL)_shouldWarnOnMissingFieldsParam:(id)request 481| 0|{ 482| 0| NSString *minVersion = @"2.4"; 483| 0| NSString *version = request.version; 484| 0| if (!version) { 485| 0| return YES; 486| 0| } 487| 0| if ([version hasPrefix:@"v"]) { 488| 0| version = [version substringFromIndex:1]; 489| 0| } 490| | 491| 0| NSComparisonResult result = [version compare:minVersion options:NSNumericSearch]; 492| | 493| | // if current version is the same as minVersion, or if the current version is > minVersion 494| 0| return (result == NSOrderedSame) || (result == NSOrderedDescending); 495| 0|} 496| | 497| |// Validate that all GET requests after v2.4 have a "fields" param 498| |- (void)_validateFieldsParamForGetRequests:(NSArray *)requests 499| 0|{ 500| 0| for (FBSDKGraphRequestMetadata *metadata in requests) { 501| 0| id request = metadata.request; 502| 0| if ([request.HTTPMethod.uppercaseString isEqualToString:@"GET"] 503| 0| && [self _shouldWarnOnMissingFieldsParam:request] 504| 0| && !request.parameters[@"fields"] 505| 0| && [request.graphPath rangeOfString:@"fields="].location == NSNotFound) { 506| 0| NSString *msg = [NSString stringWithFormat:@"starting with Graph API v2.4, GET requests for /%@ should contain an explicit \"fields\" parameter", request.graphPath]; 507| 0| [FBSDKLogger singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors 508| 0| logEntry:msg]; 509| 0| } 510| 0| } 511| 0|} 512| | 513| |// 514| |// Generates a NSURLRequest based on the contents of self.requests, and sets 515| |// options on the request. Chooses between URL-based request for a single 516| |// request and JSON-based request for batches. 517| |// 518| |- (NSMutableURLRequest *)requestWithBatch:(NSArray *)requests 519| | timeout:(NSTimeInterval)timeout 520| 0|{ 521| 0| FBSDKGraphRequestBody *body = [FBSDKGraphRequestBody new]; 522| 0| FBSDKLogger *bodyLogger = [[FBSDKLogger alloc] initWithLoggingBehavior:_logger.loggingBehavior]; 523| 0| FBSDKLogger *attachmentLogger = [[FBSDKLogger alloc] initWithLoggingBehavior:_logger.loggingBehavior]; 524| | 525| 0| NSMutableURLRequest *request; 526| | 527| 0| if (requests.count == 0) { 528| 0| [[NSException exceptionWithName:NSInvalidArgumentException 529| 0| reason:@"FBSDKGraphRequestConnection: Must have at least one request or urlRequest not specified." 530| 0| userInfo:nil] 531| 0| raise]; 532| 0| } 533| | 534| 0| [self _validateFieldsParamForGetRequests:requests]; 535| | 536| 0| if (requests.count == 1) { 537| 0| FBSDKGraphRequestMetadata *metadata = [FBSDKTypeUtility array:requests objectAtIndex:0]; 538| 0| NSURL *url = [NSURL URLWithString:[self urlStringForSingleRequest:metadata.request forBatch:NO]]; 539| 0| request = [NSMutableURLRequest requestWithURL:url 540| 0| cachePolicy:NSURLRequestUseProtocolCachePolicy 541| 0| timeoutInterval:timeout]; 542| | 543| | // HTTP methods are case-sensitive; be helpful in case someone provided a mixed case one. 544| 0| NSString *httpMethod = metadata.request.HTTPMethod.uppercaseString; 545| 0| request.HTTPMethod = httpMethod; 546| 0| [self appendAttachments:metadata.request.parameters 547| 0| toBody:body 548| 0| addFormData:[httpMethod isEqualToString:@"POST"] 549| 0| logger:attachmentLogger]; 550| 0| } else { 551| | // Find the session with an app ID and use that as the batch_app_id. If we can't 552| | // find one, try to load it from the plist. As a last resort, pass 0. 553| 0| NSString *batchAppID = [self.settings.class appID]; 554| 0| if (!batchAppID || batchAppID.length == 0) { 555| | // The Graph API batch method requires either an access token or batch_app_id. 556| | // If we can't determine an App ID to use for the batch, we can't issue it. 557| 0| [[NSException exceptionWithName:NSInternalInconsistencyException 558| 0| reason:@"FBSDKGraphRequestConnection: [FBSDKSettings appID] must be specified for batch requests" 559| 0| userInfo:nil] 560| 0| raise]; 561| 0| } 562| | 563| 0| [body appendWithKey:@"batch_app_id" formValue:batchAppID logger:bodyLogger]; 564| | 565| 0| NSMutableDictionary *attachments = [NSMutableDictionary new]; 566| | 567| 0| [self appendJSONRequests:requests 568| 0| toBody:body 569| 0| andNameAttachments:attachments 570| 0| logger:bodyLogger]; 571| | 572| 0| [self appendAttachments:attachments 573| 0| toBody:body 574| 0| addFormData:NO 575| 0| logger:attachmentLogger]; 576| | 577| 0| NSURL *url = [FBSDKInternalUtility 578| 0| facebookURLWithHostPrefix:kGraphURLPrefix 579| 0| path:@"" 580| 0| queryParameters:@{} 581| 0| defaultVersion:_overrideVersionPart 582| 0| error:NULL]; 583| | 584| 0| request = [NSMutableURLRequest requestWithURL:url 585| 0| cachePolicy:NSURLRequestUseProtocolCachePolicy 586| 0| timeoutInterval:timeout]; 587| 0| request.HTTPMethod = @"POST"; 588| 0| } 589| | 590| 0| if ([request.HTTPMethod isEqualToString:@"POST"]) { 591| 0| [self addBody:body toPostRequest:request]; 592| 0| } else { 593| 0| request.HTTPBody = body.data; 594| 0| } 595| 0| [request setValue:[self userAgent] forHTTPHeaderField:@"User-Agent"]; 596| 0| [request setValue:[body mimeContentType] forHTTPHeaderField:@"Content-Type"]; 597| 0| [request setHTTPShouldHandleCookies:NO]; 598| | 599| 0| [self logRequest:request bodyLength:(request.HTTPBody.length / 1024) bodyLogger:bodyLogger attachmentLogger:attachmentLogger]; 600| | 601| 0| return request; 602| 0|} 603| | 604| |- (void)addBody:(FBSDKGraphRequestBody *)body toPostRequest:(NSMutableURLRequest *)request 605| 0|{ 606| 0| NSData *compressedData; 607| 0| if ((compressedData = [body compressedData])) { 608| 0| request.HTTPBody = compressedData; 609| 0| [request setValue:@"gzip" forHTTPHeaderField:@"Content-Encoding"]; 610| 0| } else { 611| 0| request.HTTPBody = body.data; 612| 0| } 613| 0|} 614| | 615| |// 616| |// Generates a URL for a batch containing only a single request, 617| |// and names all attachments that need to go in the body of the 618| |// request. 619| |// 620| |// The URL contains all parameters that are not body attachments, 621| |// including the session key if present. 622| |// 623| |// Attachments are named and referenced by name in the URL. 624| |// 625| |- (NSString *)urlStringForSingleRequest:(id)request forBatch:(BOOL)forBatch 626| 0|{ 627| 0| NSMutableDictionary *params = [NSMutableDictionary dictionaryWithDictionary:request.parameters]; 628| 0| [FBSDKTypeUtility dictionary:params setObject:@"json" forKey:@"format"]; 629| 0| [FBSDKTypeUtility dictionary:params setObject:kSDK forKey:@"sdk"]; 630| 0| [FBSDKTypeUtility dictionary:params setObject:@"false" forKey:@"include_headers"]; 631| | 632| 0| request.parameters = params; 633| | 634| 0| NSString *baseURL; 635| 0| if (forBatch) { 636| 0| baseURL = request.graphPath; 637| 0| } else { 638| 0| NSString *token = [self accessTokenWithRequest:request]; 639| 0| if (token) { 640| 0| [params setValue:token forKey:kAccessTokenKey]; 641| 0| request.parameters = params; 642| 0| [self registerTokenToOmitFromLog:token]; 643| 0| } 644| | 645| 0| NSString *prefix = kGraphURLPrefix; 646| | // We special case a graph post to /videos and send it to graph-video.facebook.com 647| | // We only do this for non batch post requests 648| 0| NSString *graphPath = request.graphPath.lowercaseString; 649| 0| if ([request.HTTPMethod.uppercaseString isEqualToString:@"POST"] 650| 0| && [graphPath hasSuffix:@"/videos"]) { 651| 0| graphPath = [graphPath stringByTrimmingCharactersInSet:[NSCharacterSet characterSetWithCharactersInString:@"/"]]; 652| 0| NSArray *components = [graphPath componentsSeparatedByString:@"/"]; 653| 0| if (components.count == 2) { 654| 0| prefix = kGraphVideoURLPrefix; 655| 0| } 656| 0| } 657| | 658| 0| baseURL = [FBSDKInternalUtility 659| 0| facebookURLWithHostPrefix:prefix 660| 0| path:request.graphPath 661| 0| queryParameters:@{} 662| 0| defaultVersion:request.version 663| 0| error:NULL].absoluteString; 664| 0| } 665| | 666| 0| NSString *url = [FBSDKGraphRequest serializeURL:baseURL 667| 0| params:request.parameters 668| 0| httpMethod:request.HTTPMethod 669| 0| forBatch:forBatch]; 670| 0| return url; 671| 0|} 672| | 673| |#pragma mark - Private methods (response parsing) 674| | 675| |- (void)completeFBSDKURLSessionWithResponse:(NSURLResponse *)response 676| | data:(NSData *)data 677| | networkError:(NSError *)error 678| 0|{ 679| 0| if (self.state != kStateCancelled) { 680| 0| NSAssert( 681| 0| self.state == kStateStarted, 682| 0| @"Unexpected state %lu in completeWithResponse", 683| 0| (unsigned long)self.state 684| 0| ); 685| 0| self.state = kStateCompleted; 686| 0| } 687| | 688| 0| NSArray *results = nil; 689| 0| _urlResponse = (NSHTTPURLResponse *)response; 690| 0| if (response) { 691| 0| NSAssert( 692| 0| [response isKindOfClass:[NSHTTPURLResponse class]], 693| 0| @"Expected NSHTTPURLResponse, got %@", 694| 0| response 695| 0| ); 696| | 697| 0| NSInteger statusCode = _urlResponse.statusCode; 698| | 699| 0| if (!error && [response.MIMEType hasPrefix:@"image"]) { 700| 0| error = [FBSDKError errorWithCode:FBSDKErrorGraphRequestNonTextMimeTypeReturned 701| 0| message:@"Response is a non-text MIME type; endpoints that return images and other " 702| 0| @"binary data should be fetched using NSURLRequest and NSURLSession"]; 703| 0| } else { 704| 0| results = [self parseJSONResponse:data 705| 0| error:&error 706| 0| statusCode:statusCode]; 707| 0| } 708| 0| } else if (!error) { 709| 0| error = [FBSDKError errorWithCode:FBSDKErrorUnknown 710| 0| message:@"Missing NSURLResponse"]; 711| 0| } 712| | 713| 0| if (!error) { 714| 0| if (self.requests.count != results.count) { 715| 0| error = [FBSDKError errorWithCode:FBSDKErrorGraphRequestProtocolMismatch 716| 0| message:@"Unexpected number of results returned from server."]; 717| 0| } else { 718| 0| [_logger appendFormat:@"Response <#%lu>\nDuration: %llu msec\nSize: %lu kB\nResponse Body:\n%@\n\n", 719| 0| (unsigned long)_logger.loggerSerialNumber, 720| 0| [FBSDKInternalUtility currentTimeInMilliseconds] - _requestStartTime, 721| 0| (unsigned long)data.length, 722| 0| results]; 723| 0| } 724| 0| } 725| | 726| 0| if (error) { 727| 0| [_logger appendFormat:@"Response <#%lu> :\n%@\n%@\n", 728| 0| (unsigned long)_logger.loggerSerialNumber, 729| 0| error.localizedDescription, 730| 0| error.userInfo]; 731| 0| } 732| 0| [_logger emitToNSLog]; 733| | 734| 0| [self _completeWithResults:results networkError:error]; 735| | 736| 0| [self.session invalidateAndCancel]; 737| 0|} 738| | 739| |// 740| |// If there is one request, the JSON is the response. 741| |// If there are multiple requests, the JSON has an array of dictionaries whose 742| |// body property is the response. 743| |// [{ "code":200, 744| |// "body":"JSON-response-as-a-string" }, 745| |// { "code":200, 746| |// "body":"JSON-response-as-a-string" }] 747| |// 748| |// In both cases, this function returns an NSArray containing the results. 749| |// The NSArray looks just like the multiple request case except the body 750| |// value is converted from a string to parsed JSON. 751| |// 752| |- (NSArray *)parseJSONResponse:(NSData *)data 753| | error:(NSError **)error 754| | statusCode:(NSInteger)statusCode 755| 0|{ 756| | // Graph API can return "true" or "false", which is not valid JSON. 757| | // Translate that before asking JSON parser to look at it. 758| 0| NSString *responseUTF8 = [[NSString alloc] initWithData:data encoding:NSUTF8StringEncoding]; 759| 0| NSMutableArray *results = [NSMutableArray new];; 760| 0| id response = [self parseJSONOrOtherwise:responseUTF8 error:error]; 761| | 762| 0| if (responseUTF8 == nil) { 763| 0| NSString *base64Data = data.length != 0 ? [data base64EncodedStringWithOptions:0] : @""; 764| 0| if (base64Data != nil) { 765| 0| [self.eventLogger logInternalEvent:@"fb_response_invalid_utf8" isImplicitlyLogged:YES]; 766| 0| } 767| 0| } 768| | 769| 0| NSDictionary *responseError = nil; 770| 0| if (!response) { 771| 0| if ((error != NULL) && (*error == nil)) { 772| 0| *error = [self _errorWithCode:FBSDKErrorUnknown 773| 0| statusCode:statusCode 774| 0| parsedJSONResponse:nil 775| 0| innerError:nil 776| 0| message:@"The server returned an unexpected response."]; 777| 0| } 778| 0| } else if (self.requests.count == 1) { 779| | // response is the entry, so put it in a dictionary under "body" and add 780| | // that to array of responses. 781| 0| [FBSDKTypeUtility array:results addObject:@{ 782| 0| @"code" : @(statusCode), 783| 0| @"body" : response 784| 0| }]; 785| 0| } else if ([response isKindOfClass:[NSArray class]]) { 786| | // response is the array of responses, but the body element of each needs 787| | // to be decoded from JSON. 788| 0| for (id item in response) { 789| | // Don't let errors parsing one response stop us from parsing another. 790| 0| NSError *batchResultError = nil; 791| 0| if (![item isKindOfClass:[NSDictionary class]]) { 792| 0| [FBSDKTypeUtility array:results addObject:item]; 793| 0| } else { 794| 0| NSMutableDictionary *result = [((NSDictionary *)item) mutableCopy]; 795| 0| if (result[@"body"]) { 796| 0| [FBSDKTypeUtility dictionary:result setObject:[self parseJSONOrOtherwise:result[@"body"] error:&batchResultError] forKey:@"body"]; 797| 0| } 798| 0| [FBSDKTypeUtility array:results addObject:result]; 799| 0| } 800| 0| if (batchResultError && (*error == nil)) { 801| | // We'll report back the last error we saw. 802| 0| *error = batchResultError; 803| 0| } 804| 0| } 805| 0| } else if ([response isKindOfClass:[NSDictionary class]] 806| 0| && (responseError = [FBSDKTypeUtility dictionaryValue:response[@"error"]]) != nil 807| 0| && [responseError[@"type"] isEqualToString:@"OAuthException"]) { 808| | // if there was one request then return the only result. if there were multiple requests 809| | // but only one error then the server rejected the batch access token 810| 0| NSDictionary *result = @{ 811| 0| @"code" : @(statusCode), 812| 0| @"body" : response 813| 0| }; 814| | 815| 0| for (NSUInteger resultIndex = 0, resultCount = self.requests.count; resultIndex < resultCount; ++resultIndex) { 816| 0| [FBSDKTypeUtility array:results addObject:result]; 817| 0| } 818| 0| } else if (error != NULL) { 819| 0| *error = [self _errorWithCode:FBSDKErrorGraphRequestProtocolMismatch 820| 0| statusCode:statusCode 821| 0| parsedJSONResponse:results 822| 0| innerError:nil 823| 0| message:nil]; 824| 0| } 825| | 826| 0| return results; 827| 0|} 828| | 829| |- (id)parseJSONOrOtherwise:(NSString *)unsafeString 830| | error:(NSError **)error 831| 0|{ 832| 0| id parsed = nil; 833| | 834| | // Historically, people have passed-in `id` here. So, gotta double-check. 835| 0| NSString *const utf8 = FBSDK_CAST_TO_CLASS_OR_NIL(unsafeString, NSString); 836| 0| if (!(*error) && utf8) { 837| 0| parsed = [FBSDKBasicUtility objectForJSONString:utf8 error:error]; 838| | // if we fail parse we attempt a re-parse of a modified input to support results in the form "foo=bar", "true", etc. 839| | // which is shouldn't be necessary since Graph API v2.1. 840| 0| if (*error) { 841| | // we round-trip our hand-wired response through the parser in order to remain 842| | // consistent with the rest of the output of this function (note, if perf turns out 843| | // to be a problem -- unlikely -- we can return the following dictionary outright) 844| 0| NSError *reparseError = nil; 845| 0| parsed = 846| 0| [FBSDKBasicUtility 847| 0| objectForJSONString: 848| 0| [FBSDKBasicUtility JSONStringForObject:@{ FBSDKNonJSONResponseProperty : utf8 } 849| 0| error:NULL 850| 0| invalidObjectHandler:NULL] 851| 0| error:&reparseError]; 852| | 853| 0| if (!reparseError) { 854| 0| *error = nil; 855| 0| } 856| 0| } 857| 0| } 858| 0| return parsed; 859| 0|} 860| | 861| |- (void)_completeWithResults:(NSArray *)results 862| | networkError:(NSError *)networkError 863| 0|{ 864| 0| NSUInteger count = self.requests.count; 865| 0| _expectingResults = count; 866| 0| NSUInteger disabledRecoveryCount = 0; 867| 0| for (FBSDKGraphRequestMetadata *metadata in self.requests) { 868| 0| if ([metadata.request isGraphErrorRecoveryDisabled]) { 869| 0| disabledRecoveryCount++; 870| 0| } 871| 0| } 872| 0|#if !TARGET_OS_TV 873| 0| BOOL isSingleRequestToRecover = (count - disabledRecoveryCount == 1); 874| 0|#endif 875| | 876| 0| [self.requests enumerateObjectsUsingBlock:^(FBSDKGraphRequestMetadata *metadata, NSUInteger i, BOOL *stop) { 877| 0| id result = networkError ? nil : [FBSDKTypeUtility array:results objectAtIndex:i]; 878| 0| NSError *const resultError = networkError ?: [self errorFromResult:result request:metadata.request]; 879| | 880| 0| id body = nil; 881| 0| if (!resultError && [result isKindOfClass:[NSDictionary class]]) { 882| 0| NSDictionary *resultDictionary = [FBSDKTypeUtility dictionaryValue:result]; 883| 0| body = [FBSDKTypeUtility dictionaryValue:resultDictionary[@"body"]]; 884| 0| } 885| | 886| 0| #if !TARGET_OS_TV 887| 0| BOOL isRecoveryDisabled = [metadata.request isGraphErrorRecoveryDisabled]; 888| 0| if (resultError && !isRecoveryDisabled && isSingleRequestToRecover) { 889| 0| self->_recoveringRequestMetadata = metadata; 890| 0| self->_errorRecoveryProcessor = [FBSDKGraphErrorRecoveryProcessor new]; 891| 0| if ([self->_errorRecoveryProcessor processError:resultError request:metadata.request delegate:self]) { 892| 0| return; 893| 0| } 894| 0| } 895| 0| #endif 896| | 897| 0| [self processResultBody:body error:resultError metadata:metadata canNotifyDelegate:networkError == nil]; 898| 0| }]; 899| | 900| 0| if (networkError) { 901| 0| if ([_delegate respondsToSelector:@selector(requestConnection:didFailWithError:)]) { 902| 0| [_delegate requestConnection:self didFailWithError:networkError]; 903| 0| } 904| 0| } 905| 0|} 906| | 907| |- (void)processResultBody:(NSDictionary *)body error:(NSError *)error metadata:(FBSDKGraphRequestMetadata *)metadata canNotifyDelegate:(BOOL)canNotifyDelegate 908| 0|{ 909| 0| void (^finishAndInvokeCompletionHandler)(void) = ^{ 910| 0| NSDictionary *graphDebugDict = body[@"__debug__"]; 911| 0| if ([graphDebugDict isKindOfClass:[NSDictionary class]]) { 912| 0| [self processResultDebugDictionary:graphDebugDict]; 913| 0| } 914| 0| [metadata invokeCompletionHandlerForConnection:self withResults:body error:error]; 915| | 916| 0| if (--self->_expectingResults == 0) { 917| 0| if (canNotifyDelegate && [self->_delegate respondsToSelector:@selector(requestConnectionDidFinishLoading:)]) { 918| 0| [self->_delegate requestConnectionDidFinishLoading:self]; 919| 0| } 920| 0| } 921| 0| }; 922| | 923| 0|#if !TARGET_OS_TV 924| 0| void (^clearToken)(NSInteger) = ^(NSInteger errorSubcode) { 925| 0| FBSDKGraphRequestFlags flags = [metadata.request flags]; 926| 0| if (flags & FBSDKGraphRequestFlagDoNotInvalidateTokenOnError) { 927| 0| return; 928| 0| } 929| 0| if (errorSubcode == 493) { 930| 0| [FBSDKAccessToken setCurrentAccessToken:_CreateExpiredAccessToken([FBSDKAccessToken currentAccessToken])]; 931| 0| } else { 932| 0| [FBSDKAccessToken setCurrentAccessToken:nil]; 933| 0| } 934| 0| }; 935| | 936| 0| NSString *metadataTokenString = metadata.request.tokenString; 937| 0| NSString *currentTokenString = [FBSDKAccessToken currentAccessToken].tokenString; 938| | 939| 0| if ([metadataTokenString isEqualToString:currentTokenString]) { 940| 0| NSInteger errorCode = [error.userInfo[FBSDKGraphRequestErrorGraphErrorCodeKey] integerValue]; 941| 0| NSInteger errorSubcode = [error.userInfo[FBSDKGraphRequestErrorGraphErrorSubcodeKey] integerValue]; 942| 0| if (errorCode == 190 || errorCode == 102) { 943| 0| clearToken(errorSubcode); 944| 0| } 945| 0| } 946| 0|#endif 947| | // this is already on the queue since we are currently in the NSURLSession callback. 948| 0| finishAndInvokeCompletionHandler(); 949| 0|} 950| | 951| |- (void)processResultDebugDictionary:(NSDictionary *)dict 952| 0|{ 953| 0| NSArray *messages = [FBSDKTypeUtility arrayValue:dict[@"messages"]]; 954| 0| if (!messages.count) { 955| 0| return; 956| 0| } 957| | 958| 0| [messages enumerateObjectsUsingBlock:^(id obj, NSUInteger idx, BOOL *stop) { 959| 0| NSDictionary *messageDict = [FBSDKTypeUtility dictionaryValue:obj]; 960| 0| NSString *message = [FBSDKTypeUtility coercedToStringValue:messageDict[@"message"]]; 961| 0| NSString *type = [FBSDKTypeUtility coercedToStringValue:messageDict[@"type"]]; 962| 0| NSString *link = [FBSDKTypeUtility coercedToStringValue:messageDict[@"link"]]; 963| 0| if (!message || !type) { 964| 0| return; 965| 0| } 966| | 967| 0| NSString *loggingBehavior = FBSDKLoggingBehaviorGraphAPIDebugInfo; 968| 0| if ([type isEqualToString:@"warning"]) { 969| 0| loggingBehavior = FBSDKLoggingBehaviorGraphAPIDebugWarning; 970| 0| } 971| 0| if (link) { 972| 0| message = [message stringByAppendingFormat:@" Link: %@", link]; 973| 0| } 974| | 975| 0| [self.logger.class singleShotLogEntry:loggingBehavior logEntry:message]; 976| 0| }]; 977| 0|} 978| | 979| |- (NSError *_Nullable)errorFromResult:(id)untypedParam request:(id)request 980| 0|{ 981| 0| NSDictionary *const result = FBSDK_CAST_TO_CLASS_OR_NIL(untypedParam, NSDictionary); 982| 0| if (!result) { 983| 0| return nil; 984| 0| } 985| | 986| 0| NSDictionary *const body = FBSDK_CAST_TO_CLASS_OR_NIL(result[@"body"], NSDictionary); 987| 0| if (!body) { 988| 0| return nil; 989| 0| } 990| | 991| 0| NSDictionary *const errorDictionary = FBSDK_CAST_TO_CLASS_OR_NIL(body[@"error"], NSDictionary); 992| 0| if (!errorDictionary) { 993| 0| return nil; 994| 0| } 995| | 996| 0| NSMutableDictionary *userInfo = [NSMutableDictionary dictionary]; 997| 0| [FBSDKTypeUtility dictionary:userInfo setObject:errorDictionary[@"code"] forKey:FBSDKGraphRequestErrorGraphErrorCodeKey]; 998| 0| [FBSDKTypeUtility dictionary:userInfo setObject:errorDictionary[@"error_subcode"] forKey:FBSDKGraphRequestErrorGraphErrorSubcodeKey]; 999| | // "message" is preferred over error_msg or error_reason. 1000| 0| [FBSDKTypeUtility dictionary:userInfo setObject:errorDictionary[@"error_msg"] forKey:FBSDKErrorDeveloperMessageKey]; 1001| 0| [FBSDKTypeUtility dictionary:userInfo setObject:errorDictionary[@"error_reason"] forKey:FBSDKErrorDeveloperMessageKey]; 1002| 0| [FBSDKTypeUtility dictionary:userInfo setObject:errorDictionary[@"message"] forKey:FBSDKErrorDeveloperMessageKey]; 1003| 0| [FBSDKTypeUtility dictionary:userInfo setObject:errorDictionary[@"error_user_title"] forKey:FBSDKErrorLocalizedTitleKey]; 1004| 0| [FBSDKTypeUtility dictionary:userInfo setObject:errorDictionary[@"error_user_msg"] forKey:FBSDKErrorLocalizedDescriptionKey]; 1005| 0| [FBSDKTypeUtility dictionary:userInfo setObject:errorDictionary[@"error_user_msg"] forKey:NSLocalizedDescriptionKey]; 1006| 0| [FBSDKTypeUtility dictionary:userInfo setObject:result[@"code"] forKey:FBSDKGraphRequestErrorHTTPStatusCodeKey]; 1007| 0| [FBSDKTypeUtility dictionary:userInfo setObject:result forKey:FBSDKGraphRequestErrorParsedJSONResponseKey]; 1008| | 1009| 0| NSString *errorCode = [[FBSDKTypeUtility numberValue:userInfo[FBSDKGraphRequestErrorGraphErrorCodeKey]] stringValue]; 1010| 0| NSString *errorSubcode = [[FBSDKTypeUtility numberValue:userInfo[FBSDKGraphRequestErrorGraphErrorSubcodeKey]] stringValue]; 1011| 0| FBSDKErrorRecoveryConfiguration *recoveryConfiguration = [self.errorConfigurationProvider.errorConfiguration 1012| 0| recoveryConfigurationForCode:errorCode ?: @"*" 1013| 0| subcode:errorSubcode ?: @"*" 1014| 0| request:request]; 1015| 0| BOOL isTransient = [[FBSDKTypeUtility numberValue:errorDictionary[@"is_transient"]] boolValue]; 1016| 0| NSNumber *errorCategory = isTransient ? @(FBSDKGraphRequestErrorTransient) : @(recoveryConfiguration.errorCategory); 1017| 0| [FBSDKTypeUtility dictionary:userInfo 1018| 0| setObject:errorCategory 1019| 0| forKey:FBSDKGraphRequestErrorKey]; 1020| 0| [FBSDKTypeUtility dictionary:userInfo 1021| 0| setObject:recoveryConfiguration.localizedRecoveryDescription 1022| 0| forKey:NSLocalizedRecoverySuggestionErrorKey]; 1023| 0| [FBSDKTypeUtility dictionary:userInfo 1024| 0| setObject:recoveryConfiguration.localizedRecoveryOptionDescriptions 1025| 0| forKey:NSLocalizedRecoveryOptionsErrorKey]; 1026| 0| FBSDKErrorRecoveryAttempter *attempter = [FBSDKErrorRecoveryAttempter recoveryAttempterFromConfiguration:recoveryConfiguration]; 1027| 0| [FBSDKTypeUtility dictionary:userInfo setObject:attempter forKey:NSRecoveryAttempterErrorKey]; 1028| | 1029| 0| return [FBSDKError errorWithCode:FBSDKErrorGraphRequestGraphAPI 1030| 0| userInfo:userInfo 1031| 0| message:nil 1032| 0| underlyingError:nil]; 1033| 0|} 1034| | 1035| |- (NSError *)_errorWithCode:(FBSDKCoreError)code 1036| | statusCode:(NSInteger)statusCode 1037| | parsedJSONResponse:(id)response 1038| | innerError:(NSError *)innerError 1039| | message:(NSString *)message 1040| 0|{ 1041| 0| NSMutableDictionary *const userInfo = [NSMutableDictionary new]; 1042| 0| [FBSDKTypeUtility dictionary:userInfo setObject:@(statusCode) forKey:FBSDKGraphRequestErrorHTTPStatusCodeKey]; 1043| | 1044| 0| if (response) { 1045| 0| [FBSDKTypeUtility dictionary:userInfo setObject:response forKey:FBSDKGraphRequestErrorParsedJSONResponseKey]; 1046| 0| } 1047| | 1048| 0| if (innerError) { 1049| 0| [FBSDKTypeUtility dictionary:userInfo setObject:innerError forKey:FBSDKGraphRequestErrorParsedJSONResponseKey]; 1050| 0| } 1051| | 1052| 0| if (message) { 1053| 0| [FBSDKTypeUtility dictionary:userInfo setObject:message forKey:FBSDKErrorDeveloperMessageKey]; 1054| 0| } 1055| | 1056| 0| return 1057| 0| [[NSError alloc] 1058| 0| initWithDomain:FBSDKErrorDomain 1059| 0| code:code 1060| 0| userInfo:userInfo]; 1061| 0|} 1062| | 1063| |#pragma mark - Private methods (logging and completion) 1064| | 1065| |- (void)logAndInvokeHandler:(FBSDKURLSessionTaskBlock)handler 1066| | error:(NSError *)error 1067| 0|{ 1068| 0| if (error) { 1069| 0| NSString *logEntry = [NSString 1070| 0| stringWithFormat:@"FBSDKURLSessionTask <#%lu>:\n Error: '%@'\n%@\n", 1071| 0| (unsigned long)[FBSDKLogger generateSerialNumber], 1072| 0| error.localizedDescription, 1073| 0| error.userInfo]; 1074| | 1075| 0| [self logMessage:logEntry]; 1076| 0| } 1077| | 1078| 0| [self invokeHandler:handler error:error response:nil responseData:nil]; 1079| 0|} 1080| | 1081| |- (void)logAndInvokeHandler:(FBSDKURLSessionTaskBlock)handler 1082| | response:(NSURLResponse *)response 1083| | responseData:(NSData *)responseData 1084| | requestStartTime:(uint64_t)requestStartTime 1085| 0|{ 1086| | // Basic logging just prints out the URL. FBSDKGraphRequest logging provides more details. 1087| 0| NSString *mimeType = response.MIMEType; 1088| 0| NSMutableString *mutableLogEntry = [NSMutableString stringWithFormat:@"FBSDKGraphRequestConnection <#%lu>:\n Duration: %llu msec\nResponse Size: %lu kB\n MIME type: %@\n", 1089| 0| (unsigned long)[FBSDKLogger generateSerialNumber], 1090| 0| [FBSDKInternalUtility currentTimeInMilliseconds] - requestStartTime, 1091| 0| (unsigned long)responseData.length / 1024, 1092| 0| mimeType]; 1093| | 1094| 0| if ([mimeType isEqualToString:@"text/javascript"]) { 1095| 0| NSString *responseUTF8 = [[NSString alloc] initWithData:responseData encoding:NSUTF8StringEncoding]; 1096| 0| [mutableLogEntry appendFormat:@" Response:\n%@\n\n", responseUTF8]; 1097| 0| } 1098| | 1099| 0| [self logMessage:mutableLogEntry]; 1100| | 1101| 0| [self invokeHandler:handler error:nil response:response responseData:responseData]; 1102| 0|} 1103| | 1104| |- (void)invokeHandler:(FBSDKURLSessionTaskBlock)handler 1105| | error:(NSError *)error 1106| | response:(NSURLResponse *)response 1107| | responseData:(NSData *)responseData 1108| 0|{ 1109| 0| if (handler != nil) { 1110| 0| dispatch_async(dispatch_get_main_queue(), ^{ 1111| 0| handler(responseData, response, error); 1112| 0| }); 1113| 0| } 1114| 0|} 1115| | 1116| |- (void)logMessage:(NSString *)message 1117| 0|{ 1118| 0| [FBSDKLogger singleShotLogEntry:FBSDKLoggingBehaviorNetworkRequests logEntry:message]; 1119| 0|} 1120| | 1121| |- (void)taskDidCompleteWithResponse:(NSURLResponse *)response 1122| | data:(NSData *)data 1123| | requestStartTime:(uint64_t)requestStartTime 1124| | handler:(FBSDKURLSessionTaskBlock)handler 1125| 0|{ 1126| 0| @try { 1127| 0| [self logAndInvokeHandler:handler 1128| 0| response:response 1129| 0| responseData:data 1130| 0| requestStartTime:requestStartTime]; 1131| 0| } @finally {} 1132| 0|} 1133| | 1134| |#pragma mark - Private methods (miscellaneous) 1135| | 1136| |- (void)_taskDidCompleteWithError:(NSError *)error 1137| | handler:(FBSDKURLSessionTaskBlock)handler 1138| 0|{ 1139| 0| @try { 1140| 0| if ([error.domain isEqualToString:NSURLErrorDomain] && error.code == kCFURLErrorSecureConnectionFailed) { 1141| 0| [FBSDKLogger singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors 1142| 0| logEntry:@"WARNING: FBSDK secure network request failed. Please verify you have followed " 1143| 0| "all of the steps at https://developers.facebook.com/docs/ios/getting-started"]; 1144| 0| } 1145| 0| [self logAndInvokeHandler:handler error:error]; 1146| 0| } @finally {} 1147| 0|} 1148| | 1149| |- (void)logRequest:(NSMutableURLRequest *)request 1150| | bodyLength:(NSUInteger)bodyLength 1151| | bodyLogger:(FBSDKLogger *)bodyLogger 1152| | attachmentLogger:(FBSDKLogger *)attachmentLogger 1153| 0|{ 1154| 0| if (_logger.isActive) { 1155| 0| [_logger appendFormat:@"Request <#%lu>:\n", (unsigned long)_logger.loggerSerialNumber]; 1156| 0| [_logger appendKey:@"URL" value:request.URL.absoluteString]; 1157| 0| [_logger appendKey:@"Method" value:request.HTTPMethod]; 1158| 0| [_logger appendKey:@"UserAgent" value:[request valueForHTTPHeaderField:@"User-Agent"]]; 1159| 0| [_logger appendKey:@"MIME" value:[request valueForHTTPHeaderField:@"Content-Type"]]; 1160| | 1161| 0| if (bodyLength != 0) { 1162| 0| [_logger appendKey:@"Body Size" value:[NSString stringWithFormat:@"%lu kB", (unsigned long)bodyLength / 1024]]; 1163| 0| } 1164| | 1165| 0| if (bodyLogger != nil) { 1166| 0| [_logger appendKey:@"Body (w/o attachments)" value:bodyLogger.contents]; 1167| 0| } 1168| | 1169| 0| if (attachmentLogger != nil) { 1170| 0| [_logger appendKey:@"Attachments" value:attachmentLogger.contents]; 1171| 0| } 1172| | 1173| 0| [_logger appendString:@"\n"]; 1174| | 1175| 0| [_logger emitToNSLog]; 1176| 0| } 1177| 0|} 1178| | 1179| |- (NSString *)accessTokenWithRequest:(id)request 1180| 0|{ 1181| 0| [self warnIfMissingClientToken]; 1182| 0| NSString *token = request.tokenString ?: request.parameters[kAccessTokenKey]; 1183| 0| FBSDKGraphRequestFlags flags = [request flags]; 1184| 0| if (!token && !(flags & FBSDKGraphRequestFlagSkipClientToken) && [[self.settings.class clientToken] length] > 0) { 1185| 0| NSString *baseTokenString = [NSString stringWithFormat:@"%@|%@", [self.settings.class appID], [self.settings.class clientToken]]; 1186| 0| if ([FBSDKAuthenticationToken.currentAuthenticationToken.graphDomain isEqualToString:@"gaming"]) { 1187| 0| return [@"GG|" stringByAppendingString:baseTokenString]; 1188| 0| } else { 1189| 0| return baseTokenString; 1190| 0| } 1191| 0| } 1192| 0| return token; 1193| 0|} 1194| | 1195| |- (void)registerTokenToOmitFromLog:(NSString *)token 1196| 0|{ 1197| 0| if (![[self.settings.class loggingBehaviors] containsObject:FBSDKLoggingBehaviorAccessTokens]) { 1198| 0| [FBSDKLogger registerStringToReplace:token replaceWith:@"ACCESS_TOKEN_REMOVED"]; 1199| 0| } 1200| 0|} 1201| | 1202| |- (void)warnIfMissingClientToken 1203| 0|{ 1204| 0| if (![self.settings.class clientToken]) { 1205| 0| NSString *const message = @"Starting with v13 of the SDK, a client token must be embedded in your client code before making Graph API calls. " 1206| 0| "Visit https://developers.facebook.com/docs/ios/getting-started#step-3---configure-your-project to learn how to implement this change."; 1207| 0| [self.logger.class singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors 1208| 0| logEntry:message]; 1209| 0| } 1210| 0|} 1211| | 1212| |#pragma clang diagnostic push 1213| |#pragma clang diagnostic ignored "-Warc-performSelector-leaks" 1214| |- (NSString *)userAgent 1215| 0|{ 1216| 0| static NSString *agent = nil; 1217| 0| static dispatch_once_t onceToken; 1218| 0| dispatch_once(&onceToken, ^{ 1219| 0| agent = [NSString stringWithFormat:@"%@.%@", kUserAgentBase, FBSDK_VERSION_STRING]; 1220| 0| }); 1221| 0| NSString *agentWithSuffix = nil; 1222| 0| if ([self.settings.class userAgentSuffix]) { 1223| 0| agentWithSuffix = [NSString stringWithFormat:@"%@/%@", agent, [self.settings.class userAgentSuffix]]; 1224| 0| } 1225| 0| if (@available(iOS 13.0, *)) { 1226| 0| SEL selector = NSSelectorFromString(@"isMacCatalystApp"); 1227| 0| if (selector && [self.macCatalystDeterminator respondsToSelector:selector] && [self.macCatalystDeterminator performSelector:selector]) { 1228| 0| return [NSString stringWithFormat:@"%@/%@", agentWithSuffix ?: agent, @"macOS"]; 1229| 0| } 1230| 0| } 1231| | 1232| 0| return agentWithSuffix ?: agent; 1233| 0|} 1234| | 1235| |#pragma clang diagnostic pop 1236| | 1237| |#pragma mark - NSURLSessionDataDelegate 1238| | 1239| |- (void) URLSession:(NSURLSession *)session 1240| | task:(NSURLSessionTask *)task 1241| | didSendBodyData:(int64_t)bytesSent 1242| | totalBytesSent:(int64_t)totalBytesSent 1243| | totalBytesExpectedToSend:(int64_t)totalBytesExpectedToSend 1244| 0|{ 1245| 0| id delegate = self.delegate; 1246| | 1247| 0| if ([delegate respondsToSelector:@selector(requestConnection:didSendBodyData:totalBytesWritten:totalBytesExpectedToWrite:)]) { 1248| 0| [delegate requestConnection:self 1249| 0| didSendBodyData:(NSUInteger)bytesSent 1250| 0| totalBytesWritten:(NSUInteger)totalBytesSent 1251| 0| totalBytesExpectedToWrite:(NSUInteger)totalBytesExpectedToSend]; 1252| 0| } 1253| 0|} 1254| | 1255| |#pragma mark - FBSDKGraphErrorRecoveryProcessorDelegate 1256| | 1257| |#if !TARGET_OS_TV 1258| |- (void)processorDidAttemptRecovery:(FBSDKGraphErrorRecoveryProcessor *)processor didRecover:(BOOL)didRecover error:(NSError *)error 1259| 0|{ 1260| 0| @try { 1261| 0| if (didRecover) { 1262| 0| id originalRequest = _recoveringRequestMetadata.request; 1263| 0| id retryRequest = [[FBSDKGraphRequest alloc] initWithGraphPath:originalRequest.graphPath 1264| 0| parameters:originalRequest.parameters 1265| 0| tokenString:[FBSDKAccessToken currentAccessToken].tokenString 1266| 0| HTTPMethod:originalRequest.HTTPMethod 1267| 0| version:originalRequest.version 1268| 0| flags:FBSDKGraphRequestFlagDisableErrorRecovery 1269| 0| connectionFactory:self.connectionFactory]; 1270| 0| FBSDKGraphRequestMetadata *retryMetadata = [[FBSDKGraphRequestMetadata alloc] initWithRequest:retryRequest completionHandler:_recoveringRequestMetadata.completionHandler batchParameters:_recoveringRequestMetadata.batchParameters]; 1271| 0| [retryRequest startWithCompletion:^(id potentialConnection, id result, NSError *retriedError) { 1272| 0| [self processResultBody:result error:retriedError metadata:retryMetadata canNotifyDelegate:YES]; 1273| 0| self->_errorRecoveryProcessor = nil; 1274| 0| self->_recoveringRequestMetadata = nil; 1275| 0| }]; 1276| 0| } else { 1277| 0| [self processResultBody:nil error:error metadata:_recoveringRequestMetadata canNotifyDelegate:YES]; 1278| 0| _errorRecoveryProcessor = nil; 1279| 0| _recoveringRequestMetadata = nil; 1280| 0| } 1281| 0| } @catch (NSException *exception) {} 1282| 0|} 1283| | 1284| |#endif 1285| | 1286| |#pragma mark - Debugging helpers 1287| | 1288| |- (NSString *)description 1289| 0|{ 1290| 0| NSMutableString *result = [NSMutableString stringWithFormat:@"<%@: %p, %lu request(s): (\n", 1291| 0| NSStringFromClass([self class]), 1292| 0| self, 1293| 0| (unsigned long)self.requests.count]; 1294| 0| BOOL comma = NO; 1295| 0| for (FBSDKGraphRequestMetadata *metadata in self.requests) { 1296| 0| id request = metadata.request; 1297| 0| if (comma) { 1298| 0| [result appendString:@",\n"]; 1299| 0| } 1300| 0| [result appendString:request.formattedDescription]; 1301| 0| comma = YES; 1302| 0| } 1303| 0| [result appendString:@"\n)>"]; 1304| 0| return result; 1305| 0|} 1306| | 1307| |// MARK: - Testability 1308| | 1309| |#if DEBUG 1310| | #if FBSDKTEST 1311| | 1312| |/// Resets the default connection timeout to 60 seconds 1313| |+ (void)resetDefaultConnectionTimeout 1314| 0|{ 1315| 0| g_defaultTimeout = 60; 1316| 0|} 1317| | 1318| |- (NSString *)_overrideVersionPart 1319| 0|{ 1320| 0| return _overrideVersionPart; 1321| 0|} 1322| | 1323| |+ (void)resetCanMakeRequests 1324| 0|{ 1325| 0| _canMakeRequests = NO; 1326| 0|} 1327| | 1328| | #endif 1329| |#endif 1330| | 1331| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/GraphAPI/FBSDKGraphRequestDataAttachment.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKGraphRequestDataAttachment.h" 20| | 21| |@implementation FBSDKGraphRequestDataAttachment 22| | 23| |- (instancetype)initWithData:(NSData *)data filename:(NSString *)filename contentType:(NSString *)contentType 24| 0|{ 25| 0| if ((self = [super init])) { 26| 0| _data = data; 27| 0| _filename = [filename copy]; 28| 0| _contentType = [contentType copy]; 29| 0| } 30| 0| return self; 31| 0|} 32| | 33| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/BridgeAPI/FBSDKBridgeAPIResponseFactory.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKBridgeAPIResponseFactory.h" 24| | 25| | #import "FBSDKBridgeAPIResponse.h" 26| | 27| |NS_ASSUME_NONNULL_BEGIN 28| | 29| |@implementation FBSDKBridgeAPIResponseFactory 30| | 31| |- (FBSDKBridgeAPIResponse *)createResponseCancelledWithRequest:(NSObject *)request 32| 0|{ 33| 0| return [FBSDKBridgeAPIResponse bridgeAPIResponseCancelledWithRequest:request]; 34| 0|} 35| | 36| |- (FBSDKBridgeAPIResponse *)createResponseWithRequest:(NSObject *)request 37| | error:(NSError *)error 38| 0|{ 39| 0| return [FBSDKBridgeAPIResponse bridgeAPIResponseWithRequest:request 40| 0| error:error]; 41| 0|} 42| | 43| |- (nullable FBSDKBridgeAPIResponse *)createResponseWithRequest:(NSObject *)request 44| | responseURL:(NSURL *)responseURL 45| | sourceApplication:(nullable NSString *)sourceApplication 46| | error:(NSError *__autoreleasing _Nullable *_Nullable)errorRef 47| 0|{ 48| 0| return [FBSDKBridgeAPIResponse bridgeAPIResponseWithRequest:request 49| 0| responseURL:responseURL 50| 0| sourceApplication:sourceApplication 51| 0| error:errorRef]; 52| 0|} 53| | 54| |@end 55| | 56| |NS_ASSUME_NONNULL_END 57| | 58| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Cryptography/FBSDKCrypto.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKCrypto.h" 20| | 21| |#import "FBSDKCoreKitBasicsImport.h" 22| |#import "FBSDKDynamicFrameworkLoader.h" 23| | 24| |static inline void FBSDKCryptoBlankData(NSData *data) 25| 0|{ 26| 0| if (!data) { 27| 0| return; 28| 0| } 29| 0| bzero((void *) [data bytes], [data length]); 30| 0|} 31| | 32| |@implementation FBSDKCrypto 33| | 34| |+ (NSData *)randomBytes:(NSUInteger)numOfBytes 35| 0|{ 36| 0| uint8_t *buffer = malloc(numOfBytes); 37| 0| int result = fbsdkdfl_SecRandomCopyBytes([FBSDKDynamicFrameworkLoader loadkSecRandomDefault], numOfBytes, buffer); 38| 0| if (result != 0) { 39| 0| free(buffer); 40| 0| return nil; 41| 0| } 42| 0| return [NSData dataWithBytesNoCopy:buffer length:numOfBytes]; 43| 0|} 44| | 45| |+ (NSString *)randomString:(NSUInteger)numOfBytes 46| 0|{ 47| 0| NSData *randomStringData = [FBSDKCrypto randomBytes:numOfBytes]; 48| 0| NSString *randomString = [FBSDKBase64 encodeData:randomStringData]; 49| 0| FBSDKCryptoBlankData(randomStringData); 50| 0| return randomString; 51| 0|} 52| | 53| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ErrorRecovery/FBSDKErrorRecoveryAttempter.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKErrorRecoveryAttempter.h" 20| | 21| |#import "FBSDKErrorRecoveryConfiguration.h" 22| | 23| |@interface FBSDKTemporaryErrorRecoveryAttempter : FBSDKErrorRecoveryAttempter 24| |@end 25| | 26| |@implementation FBSDKTemporaryErrorRecoveryAttempter 27| | 28| |- (void)attemptRecoveryFromError:(NSError *)error optionIndex:(NSUInteger)recoveryOptionIndex completionHandler:(void (^)(BOOL didRecover))completionHandler 29| 0|{ 30| 0| @try { 31| 0| completionHandler(YES); 32| 0| } @catch (NSException *exception) { 33| 0| NSLog(@"Fail to complete error recovery. Exception reason: %@", exception.reason); 34| 0| } 35| 0|} 36| | 37| |@end 38| | 39| |@implementation FBSDKErrorRecoveryAttempter 40| | 41| |+ (instancetype)recoveryAttempterFromConfiguration:(FBSDKErrorRecoveryConfiguration *)configuration 42| 0|{ 43| 0| if (configuration.errorCategory == FBSDKGraphRequestErrorTransient) { 44| 0| return [FBSDKTemporaryErrorRecoveryAttempter new]; 45| 0| } else if (configuration.errorCategory == FBSDKGraphRequestErrorOther) { 46| 0| return nil; 47| 0| } 48| 0| if ([configuration.recoveryActionName isEqualToString:@"login"]) { 49| 0| Class loginRecoveryAttmpterClass = NSClassFromString(@"_FBSDKLoginRecoveryAttempter"); 50| 0| if (loginRecoveryAttmpterClass) { 51| 0| return [loginRecoveryAttmpterClass new]; 52| 0| } 53| 0| } 54| 0| return nil; 55| 0|} 56| | 57| |- (void)attemptRecoveryFromError:(NSError *)error optionIndex:(NSUInteger)recoveryOptionIndex completionHandler:(void (^)(BOOL didRecover))completionHandler 58| 0|{ 59| | // should be implemented by subclasses. 60| 0|} 61| | 62| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKAuthenticationStatusUtility.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKAuthenticationStatusUtility.h" 24| | 25| | #import "FBSDKAccessToken.h" 26| | #import "FBSDKAuthenticationToken.h" 27| | #import "FBSDKCoreKitBasicsImport.h" 28| | #import "FBSDKInternalUtility.h" 29| | #import "FBSDKLogger.h" 30| | #import "FBSDKProfile.h" 31| | 32| |static NSString *const FBSDKOIDCStatusPath = @"/platform/oidc/status"; 33| | 34| |@implementation FBSDKAuthenticationStatusUtility 35| | 36| |+ (void)checkAuthenticationStatus 37| 0|{ 38| 0| NSURL *requestURL = [self _requestURL]; 39| 0| if (!requestURL) { 40| 0| return; 41| 0| } 42| | 43| 0| NSURLRequest *request = [NSURLRequest requestWithURL:requestURL]; 44| 0| if (request) { 45| 0| [[NSURLSession.sharedSession dataTaskWithRequest:request 46| 0| completionHandler:^(NSData *_Nullable data, NSURLResponse *_Nullable response, NSError *_Nullable error) { 47| 0| if (!error) { 48| 0| fb_dispatch_on_main_thread(^{ 49| 0| [self _handleResponse:response]; 50| 0| }); 51| 0| } else { 52| 0| [FBSDKLogger singleShotLogEntry:FBSDKLoggingBehaviorNetworkRequests 53| 0| logEntry:error.localizedDescription]; 54| 0| } 55| 0| }] resume]; 56| 0| } 57| 0|} 58| | 59| |+ (void)_handleResponse:(NSURLResponse *)response 60| 0|{ 61| 0| NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *)response; 62| | 63| 0| if (httpResponse.statusCode != 200) { 64| 0| return; 65| 0| } 66| | 67| 0| if ([httpResponse respondsToSelector:@selector(allHeaderFields)]) { 68| 0| NSDictionary *header = [httpResponse allHeaderFields]; 69| 0| NSString *status = [FBSDKTypeUtility dictionary:header objectForKey:@"fb-s" ofType:NSString.class]; 70| 0| if ([status isEqualToString:@"not_authorized"]) { 71| 0| [self _invalidateCurrentSession]; 72| 0| } 73| 0| } 74| 0|} 75| | 76| |+ (NSURL *)_requestURL 77| 0|{ 78| 0| FBSDKAuthenticationToken *token = FBSDKAuthenticationToken.currentAuthenticationToken; 79| | 80| 0| if (!token.tokenString) { 81| 0| return nil; 82| 0| } 83| | 84| 0| NSDictionary *params = @{@"id_token" : token.tokenString}; 85| 0| NSError *error; 86| | 87| 0| NSURL *requestURL = [FBSDKInternalUtility unversionedFacebookURLWithHostPrefix:@"m" 88| 0| path:FBSDKOIDCStatusPath 89| 0| queryParameters:params 90| 0| error:&error]; 91| 0| return error == nil ? requestURL : nil; 92| 0|} 93| | 94| |+ (void)_invalidateCurrentSession 95| 0|{ 96| 0| FBSDKAccessToken.currentAccessToken = nil; 97| 0| FBSDKAuthenticationToken.currentAuthenticationToken = nil; 98| 0| FBSDKProfile.currentProfile = nil; 99| 0|} 100| | 101| |@end 102| | 103| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKBackgroundEventLogger.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKBackgroundEventLogger.h" 24| | 25| | #import "FBSDKCoreKitBasicsImport.h" 26| | #import "FBSDKEventLogging.h" 27| | 28| |@interface FBSDKBackgroundEventLogger () 29| | 30| |@property (nonnull, nonatomic, readonly) id infoDictionaryProvider; 31| |@property (nonnull, nonatomic, readonly) id eventLogger; 32| | 33| |@end 34| | 35| |@implementation FBSDKBackgroundEventLogger 36| | 37| |- (instancetype)initWithInfoDictionaryProvider:(id)infoDictionaryProvider 38| | eventLogger:(id)eventLogger 39| 0|{ 40| 0| if ((self = [super init])) { 41| 0| _infoDictionaryProvider = infoDictionaryProvider; 42| 0| _eventLogger = eventLogger; 43| 0| } 44| 0| return self; 45| 0|} 46| | 47| |- (void)logBackgroundRefresStatus:(UIBackgroundRefreshStatus)status 48| 0|{ 49| 0| BOOL isNewVersion = [self _isNewBackgroundRefresh]; 50| 0| switch (status) { 51| 0| case UIBackgroundRefreshStatusAvailable: 52| 0| [_eventLogger logInternalEvent:@"fb_sdk_background_status_available" 53| 0| parameters:@{@"version" : @(isNewVersion ? 1 : 0)} 54| 0| isImplicitlyLogged:YES]; 55| 0| break; 56| 0| case UIBackgroundRefreshStatusDenied: 57| 0| [_eventLogger logInternalEvent:@"fb_sdk_background_status_denied" 58| 0| isImplicitlyLogged:YES]; 59| 0| break; 60| 0| case UIBackgroundRefreshStatusRestricted: 61| 0| [_eventLogger logInternalEvent:@"fb_sdk_background_status_restricted" 62| 0| isImplicitlyLogged:YES]; 63| 0| break; 64| 0| } 65| 0|} 66| | 67| |- (BOOL)_isNewBackgroundRefresh 68| 0|{ 69| 0| if ([_infoDictionaryProvider objectForInfoDictionaryKey:@"BGTaskSchedulerPermittedIdentifiers"]) { 70| 0| return YES; 71| 0| } 72| 0| return NO; 73| 0|} 74| | 75| |@end 76| | 77| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKContainerViewController.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKContainerViewController.h" 24| | 25| |@implementation FBSDKContainerViewController 26| | 27| |- (void)viewDidDisappear:(BOOL)animated 28| 0|{ 29| 0| [super viewDidDisappear:animated]; 30| 0| if ([self.delegate respondsToSelector:@selector(viewControllerDidDisappear:animated:)]) { 31| 0| [self.delegate viewControllerDidDisappear:self animated:animated]; 32| 0| } 33| 0|} 34| | 35| |- (void)displayChildController:(UIViewController *)childController 36| 0|{ 37| 0| [self addChildViewController:childController]; 38| 0| UIView *view = self.view; 39| 0| UIView *childView = childController.view; 40| 0| childView.translatesAutoresizingMaskIntoConstraints = NO; 41| 0| childView.frame = view.frame; 42| 0| [view addSubview:childView]; 43| | 44| 0| [view addConstraints: 45| 0| @[ 46| 0| [NSLayoutConstraint constraintWithItem:childView 47| 0| attribute:NSLayoutAttributeTop 48| 0| relatedBy:NSLayoutRelationEqual 49| 0| toItem:view 50| 0| attribute:NSLayoutAttributeTop 51| 0| multiplier:1.0 52| 0| constant:0.0], 53| | 54| 0| [NSLayoutConstraint constraintWithItem:childView 55| 0| attribute:NSLayoutAttributeBottom 56| 0| relatedBy:NSLayoutRelationEqual 57| 0| toItem:view 58| 0| attribute:NSLayoutAttributeBottom 59| 0| multiplier:1.0 60| 0| constant:0.0], 61| | 62| 0| [NSLayoutConstraint constraintWithItem:childView 63| 0| attribute:NSLayoutAttributeLeading 64| 0| relatedBy:NSLayoutRelationEqual 65| 0| toItem:view 66| 0| attribute:NSLayoutAttributeLeading 67| 0| multiplier:1.0 68| 0| constant:0.0], 69| | 70| 0| [NSLayoutConstraint constraintWithItem:childView 71| 0| attribute:NSLayoutAttributeTrailing 72| 0| relatedBy:NSLayoutRelationEqual 73| 0| toItem:view 74| 0| attribute:NSLayoutAttributeTrailing 75| 0| multiplier:1.0 76| 0| constant:0.0], 77| 0| ]]; 78| | 79| 0| [childController didMoveToParentViewController:self]; 80| 0|} 81| | 82| |@end 83| | 84| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKDynamicFrameworkLoader.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKDynamicFrameworkLoader.h" 20| | 21| |#import 22| |#import 23| | 24| |#import 25| | 26| |#import "FBSDKLogger.h" 27| |#import "FBSDKSettings.h" 28| | 29| |static NSString *const g_frameworkPathTemplate = @"/System/Library/Frameworks/%@.framework/%@"; 30| | 31| |#pragma mark - Library and Symbol Loading 32| | 33| |struct FBSDKDFLLoadSymbolContext { 34| | void *(*library)(void); // function to retrieve the library handle (it's a function instead of void * so it can be staticlly bound) 35| | const char *name; // name of the symbol to retrieve 36| | void **address; // [out] address of the symbol in the process address space 37| |}; 38| | 39| |// Retrieves the handle for a library for framework. The paths for each are constructed 40| |// differently so the loading function passed to dispatch_once() calls this. 41| |static void *fbsdkdfl_load_library_once(const char *path) 42| 0|{ 43| 0| void *handle = dlopen(path, RTLD_LAZY); 44| 0| NSString *msg; 45| 0| if (handle) { 46| 0| msg = [NSString stringWithFormat:@"Dynamically loaded library at %s", path]; 47| 0| [FBSDKLogger singleShotLogEntry:FBSDKLoggingBehaviorInformational logEntry:msg]; 48| 0| } else { 49| 0| msg = [NSString stringWithFormat:@"Failed to load library at %s", path]; 50| 0| [FBSDKLogger singleShotLogEntry:FBSDKLoggingBehaviorInformational logEntry:msg]; 51| 0| } 52| 0| return handle; 53| 0|} 54| | 55| |// Constructs the path for a system framework with the given name and returns the handle for dlsym 56| |static void *fbsdkdfl_load_framework_once(NSString *framework) 57| 0|{ 58| 0| NSString *path = [NSString stringWithFormat:g_frameworkPathTemplate, framework, framework]; 59| 0| return fbsdkdfl_load_library_once(path.fileSystemRepresentation); 60| 0|} 61| | 62| |// Implements the callback for dispatch_once() that loads the handle for specified framework name 63| |#define _fbsdkdfl_load_framework_once_impl_(FRAMEWORK) \ 64| 0| static void fbsdkdfl_load_ ## FRAMEWORK ## _once(void *context) { \ 65| 0| *(void **)context = fbsdkdfl_load_framework_once(@#FRAMEWORK); \ 66| 0| } ------------------ | Unexecuted instantiation: FBSDKDynamicFrameworkLoader.m:fbsdkdfl_load_Security_once ------------------ | Unexecuted instantiation: FBSDKDynamicFrameworkLoader.m:fbsdkdfl_load_Social_once ------------------ | Unexecuted instantiation: FBSDKDynamicFrameworkLoader.m:fbsdkdfl_load_QuartzCore_once ------------------ | Unexecuted instantiation: FBSDKDynamicFrameworkLoader.m:fbsdkdfl_load_AdSupport_once ------------------ | Unexecuted instantiation: FBSDKDynamicFrameworkLoader.m:fbsdkdfl_load_SafariServices_once ------------------ | Unexecuted instantiation: FBSDKDynamicFrameworkLoader.m:fbsdkdfl_load_AuthenticationServices_once ------------------ | Unexecuted instantiation: FBSDKDynamicFrameworkLoader.m:fbsdkdfl_load_CoreTelephony_once ------------------ 67| | 68| |// Implements the framework/library retrieval function for the given name. 69| |// It calls the loading function once and caches the handle in a local static variable 70| |#define _fbsdkdfl_handle_get_impl_(LIBRARY) \ 71| 0| static void *fbsdkdfl_handle_get_ ## LIBRARY(void) { \ 72| 0| static void *LIBRARY ## _handle; \ 73| 0| static dispatch_once_t LIBRARY ## _once; \ 74| 0| dispatch_once_f(&LIBRARY ## _once, &LIBRARY ## _handle, &fbsdkdfl_load_ ## LIBRARY ## _once); \ 75| 0| return LIBRARY ## _handle; \ 76| 0| } ------------------ | Unexecuted instantiation: FBSDKDynamicFrameworkLoader.m:fbsdkdfl_handle_get_Security ------------------ | Unexecuted instantiation: FBSDKDynamicFrameworkLoader.m:fbsdkdfl_handle_get_Social ------------------ | Unexecuted instantiation: FBSDKDynamicFrameworkLoader.m:fbsdkdfl_handle_get_QuartzCore ------------------ | Unexecuted instantiation: FBSDKDynamicFrameworkLoader.m:fbsdkdfl_handle_get_AdSupport ------------------ | Unexecuted instantiation: FBSDKDynamicFrameworkLoader.m:fbsdkdfl_handle_get_SafariServices ------------------ | Unexecuted instantiation: FBSDKDynamicFrameworkLoader.m:fbsdkdfl_handle_get_AuthenticationServices ------------------ | Unexecuted instantiation: FBSDKDynamicFrameworkLoader.m:fbsdkdfl_handle_get_CoreTelephony ------------------ 77| | 78| |// Callback from dispatch_once() to load a specific symbol 79| |static void fbsdkdfl_load_symbol_once(void *context) 80| 0|{ 81| 0| struct FBSDKDFLLoadSymbolContext *ctx = context; 82| 0| *ctx->address = dlsym(ctx->library(), ctx->name); 83| 0|} 84| | 85| |// The boilerplate code for loading a symbol from a given library once and caching it in a static local 86| |#define _fbsdkdfl_symbol_get(LIBRARY, PREFIX, SYMBOL, TYPE, VARIABLE_NAME) \ 87| 0| static TYPE VARIABLE_NAME; \ 88| 0| static dispatch_once_t SYMBOL ## _once; \ 89| 0| static struct FBSDKDFLLoadSymbolContext ctx = { .library = &fbsdkdfl_handle_get_ ## LIBRARY, .name = PREFIX #SYMBOL, .address = (void *)&VARIABLE_NAME }; \ 90| 0| dispatch_once_f(&SYMBOL ## _once, &ctx, &fbsdkdfl_load_symbol_once) 91| | 92| 0|#define _fbsdkdfl_symbol_get_c(LIBRARY, SYMBOL) _fbsdkdfl_symbol_get(LIBRARY, "OBJC_CLASS_$_", SYMBOL, Class, c) // convenience symbol retrieval macro for getting an Objective-C class symbol and storing it in the local static c 93| 0|#define _fbsdkdfl_symbol_get_f(LIBRARY, SYMBOL) _fbsdkdfl_symbol_get(LIBRARY, "", SYMBOL, SYMBOL ## _type, f) // convenience symbol retrieval macro for getting a function pointer and storing it in the local static f 94| 0|#define _fbsdkdfl_symbol_get_k(LIBRARY, SYMBOL, TYPE) _fbsdkdfl_symbol_get(LIBRARY, "", SYMBOL, TYPE, k) // convenience symbol retrieval macro for getting a pointer to a named variable and storing it in the local static k 95| | 96| |// convenience macro for verifying a pointer to a named variable was successfully loaded and returns the value 97| |#define _fbsdkdfl_return_k(FRAMEWORK, SYMBOL) \ 98| 0| NSCAssert(k != NULL, @"Failed to load constant %@ in the %@ framework", @#SYMBOL, @#FRAMEWORK); \ 99| 0| return *k 100| | 101| |// convenience macro for getting a pointer to a named NSString, verifying it loaded correctly, and returning it 102| |#define _fbsdkdfl_get_and_return_NSString(LIBRARY, SYMBOL) \ 103| 0| _fbsdkdfl_symbol_get_k(LIBRARY, SYMBOL, NSString **); \ 104| 0| NSCAssert([*k isKindOfClass:[NSString class]], @"Loaded symbol %@ is not of type NSString *", @#SYMBOL); \ 105| 0| _fbsdkdfl_return_k(LIBRARY, SYMBOL) 106| | 107| |#pragma mark - Security Framework 108| | 109| |_fbsdkdfl_load_framework_once_impl_(Security) 110| |_fbsdkdfl_handle_get_impl_(Security) 111| | 112| |#pragma mark - Security Constants 113| | 114| |@implementation FBSDKDynamicFrameworkLoader 115| | 116| |+ (FBSDKDynamicFrameworkLoader *)shared 117| 0|{ 118| 0| static dispatch_once_t onceToken; 119| 0| static FBSDKDynamicFrameworkLoader *shared = nil; 120| 0| dispatch_once(&onceToken, ^{ 121| 0| shared = [self new]; 122| 0| }); 123| 0| return shared; 124| 0|} 125| | 126| |- (Class)safariViewControllerClass 127| 0|{ 128| 0| return fbsdkdfl_SFSafariViewControllerClass(); 129| 0|} 130| | 131| |- (Class)asIdentifierManagerClass 132| 0|{ 133| 0| return fbsdkdfl_ASIdentifierManagerClass(); 134| 0|} 135| | 136| 0|#define _fbsdkdfl_Security_get_k(SYMBOL) _fbsdkdfl_symbol_get_k(Security, SYMBOL, CFTypeRef *) 137| | 138| |#define _fbsdkdfl_Security_get_and_return_k(SYMBOL) \ 139| 0| _fbsdkdfl_Security_get_k(SYMBOL); \ 140| 0| _fbsdkdfl_return_k(Security, SYMBOL) 141| | 142| |+ (SecRandomRef)loadkSecRandomDefault 143| 0|{ 144| 0| _fbsdkdfl_symbol_get_k(Security, kSecRandomDefault, SecRandomRef *); 145| 0| _fbsdkdfl_return_k(Security, kSecRandomDefault); 146| 0|} 147| | 148| |+ (CFTypeRef)loadkSecAttrAccessible 149| 0|{ 150| 0| _fbsdkdfl_Security_get_and_return_k(kSecAttrAccessible); 151| 0|} 152| | 153| |+ (CFTypeRef)loadkSecAttrAccessibleAfterFirstUnlockThisDeviceOnly 154| 0|{ 155| 0| _fbsdkdfl_Security_get_and_return_k(kSecAttrAccessibleAfterFirstUnlockThisDeviceOnly); 156| 0|} 157| | 158| |+ (CFTypeRef)loadkSecAttrAccount 159| 0|{ 160| 0| _fbsdkdfl_Security_get_and_return_k(kSecAttrAccount); 161| 0|} 162| | 163| |+ (CFTypeRef)loadkSecAttrService 164| 0|{ 165| 0| _fbsdkdfl_Security_get_and_return_k(kSecAttrService); 166| 0|} 167| | 168| |+ (CFTypeRef)loadkSecValueData 169| 0|{ 170| 0| _fbsdkdfl_Security_get_and_return_k(kSecValueData); 171| 0|} 172| | 173| |+ (CFTypeRef)loadkSecClassGenericPassword 174| 0|{ 175| 0| _fbsdkdfl_Security_get_and_return_k(kSecClassGenericPassword); 176| 0|} 177| | 178| |+ (CFTypeRef)loadkSecAttrAccessGroup 179| 0|{ 180| 0| _fbsdkdfl_Security_get_and_return_k(kSecAttrAccessGroup); 181| 0|} 182| | 183| |+ (CFTypeRef)loadkSecMatchLimitOne 184| 0|{ 185| 0| _fbsdkdfl_Security_get_and_return_k(kSecMatchLimitOne); 186| 0|} 187| | 188| |+ (CFTypeRef)loadkSecMatchLimit 189| 0|{ 190| 0| _fbsdkdfl_Security_get_and_return_k(kSecMatchLimit); 191| 0|} 192| | 193| |+ (CFTypeRef)loadkSecReturnData 194| 0|{ 195| 0| _fbsdkdfl_Security_get_and_return_k(kSecReturnData); 196| 0|} 197| | 198| |+ (CFTypeRef)loadkSecClass 199| 0|{ 200| 0| _fbsdkdfl_Security_get_and_return_k(kSecClass); 201| 0|} 202| | 203| |@end 204| | 205| |#pragma mark - Security APIs 206| | 207| 0|#define _fbsdkdfl_Security_get_f(SYMBOL) _fbsdkdfl_symbol_get_f(Security, SYMBOL) 208| | 209| |typedef int (*SecRandomCopyBytes_type)(SecRandomRef, size_t, uint8_t *); 210| |typedef OSStatus (*SecItemUpdate_type)(CFDictionaryRef, CFDictionaryRef); 211| |typedef OSStatus (*SecItemAdd_type)(CFDictionaryRef, CFTypeRef); 212| |typedef OSStatus (*SecItemCopyMatching_type)(CFDictionaryRef, CFTypeRef); 213| |typedef OSStatus (*SecItemDelete_type)(CFDictionaryRef); 214| | 215| |int fbsdkdfl_SecRandomCopyBytes(SecRandomRef rnd, size_t count, void *bytes) 216| 0|{ 217| 0| _fbsdkdfl_Security_get_f(SecRandomCopyBytes); 218| 0| return f(rnd, count, bytes); 219| 0|} 220| | 221| |OSStatus fbsdkdfl_SecItemUpdate(CFDictionaryRef query, CFDictionaryRef attributesToUpdate) 222| 0|{ 223| 0| _fbsdkdfl_Security_get_f(SecItemUpdate); 224| 0| return f(query, attributesToUpdate); 225| 0|} 226| | 227| |OSStatus fbsdkdfl_SecItemAdd(CFDictionaryRef attributes, CFTypeRef *result) 228| 0|{ 229| 0| _fbsdkdfl_Security_get_f(SecItemAdd); 230| 0| return f(attributes, result); 231| 0|} 232| | 233| |OSStatus fbsdkdfl_SecItemCopyMatching(CFDictionaryRef query, CFTypeRef *result) 234| 0|{ 235| 0| _fbsdkdfl_Security_get_f(SecItemCopyMatching); 236| 0| return f(query, result); 237| 0|} 238| | 239| |OSStatus fbsdkdfl_SecItemDelete(CFDictionaryRef query) 240| 0|{ 241| 0| _fbsdkdfl_Security_get_f(SecItemDelete); 242| 0| return f(query); 243| 0|} 244| | 245| |#pragma mark - Social Constants 246| | 247| |_fbsdkdfl_load_framework_once_impl_(Social) 248| |_fbsdkdfl_handle_get_impl_(Social) 249| | 250| 0|#define _fbsdkdfl_Social_get_and_return_constant(SYMBOL) _fbsdkdfl_get_and_return_NSString(Social, SYMBOL) 251| | 252| |NSString *fbsdkdfl_SLServiceTypeFacebook(void) 253| 0|{ 254| 0| __weak _fbsdkdfl_Social_get_and_return_constant(SLServiceTypeFacebook); 255| 0|} 256| | 257| |#pragma mark - Social Classes 258| | 259| 0|#define _fbsdkdfl_Social_get_c(SYMBOL) _fbsdkdfl_symbol_get_c(Social, SYMBOL) 260| | 261| |Class fbsdkdfl_SLComposeViewControllerClass(void) 262| 0|{ 263| 0| _fbsdkdfl_Social_get_c(SLComposeViewController); 264| 0| return c; 265| 0|} 266| | 267| |#pragma mark - QuartzCore Classes 268| | 269| |_fbsdkdfl_load_framework_once_impl_(QuartzCore) 270| |_fbsdkdfl_handle_get_impl_(QuartzCore) 271| | 272| 0|#define _fbsdkdfl_QuartzCore_get_c(SYMBOL) _fbsdkdfl_symbol_get_c(QuartzCore, SYMBOL); 273| | 274| |Class fbsdkdfl_CATransactionClass(void) 275| 0|{ 276| 0| _fbsdkdfl_QuartzCore_get_c(CATransaction); 277| 0| return c; 278| 0|} 279| | 280| |#pragma mark - QuartzCore APIs 281| | 282| 0|#define _fbsdkdfl_QuartzCore_get_f(SYMBOL) _fbsdkdfl_symbol_get_f(QuartzCore, SYMBOL) 283| | 284| |typedef CATransform3D (*CATransform3DMakeScale_type)(CGFloat, CGFloat, CGFloat); 285| |typedef CATransform3D (*CATransform3DMakeTranslation_type)(CGFloat, CGFloat, CGFloat); 286| |typedef CATransform3D (*CATransform3DConcat_type)(CATransform3D, CATransform3D); 287| | 288| |const CATransform3D fbsdkdfl_CATransform3DIdentity = {1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1}; 289| | 290| |CATransform3D fbsdkdfl_CATransform3DMakeScale(CGFloat sx, CGFloat sy, CGFloat sz) 291| 0|{ 292| 0| _fbsdkdfl_QuartzCore_get_f(CATransform3DMakeScale); 293| 0| return f(sx, sy, sz); 294| 0|} 295| | 296| |CATransform3D fbsdkdfl_CATransform3DMakeTranslation(CGFloat tx, CGFloat ty, CGFloat tz) 297| 0|{ 298| 0| _fbsdkdfl_QuartzCore_get_f(CATransform3DMakeTranslation); 299| 0| return f(tx, ty, tz); 300| 0|} 301| | 302| |CATransform3D fbsdkdfl_CATransform3DConcat(CATransform3D a, CATransform3D b) 303| 0|{ 304| 0| _fbsdkdfl_QuartzCore_get_f(CATransform3DConcat); 305| 0| return f(a, b); 306| 0|} 307| | 308| |#pragma mark - Ad Support Classes 309| | 310| |_fbsdkdfl_load_framework_once_impl_(AdSupport) 311| |_fbsdkdfl_handle_get_impl_(AdSupport) 312| | 313| 0|#define _fbsdkdfl_AdSupport_get_c(SYMBOL) _fbsdkdfl_symbol_get_c(AdSupport, SYMBOL); 314| | 315| |Class fbsdkdfl_ASIdentifierManagerClass(void) 316| 0|{ 317| 0| _fbsdkdfl_AdSupport_get_c(ASIdentifierManager); 318| 0| return c; 319| 0|} 320| | 321| |#pragma mark - Safari Services 322| |_fbsdkdfl_load_framework_once_impl_(SafariServices) 323| |_fbsdkdfl_handle_get_impl_(SafariServices) 324| | 325| 0|#define _fbsdkdfl_SafariServices_get_c(SYMBOL) _fbsdkdfl_symbol_get_c(SafariServices, SYMBOL); 326| | 327| |Class fbsdkdfl_SFSafariViewControllerClass(void) 328| 0|{ 329| 0| _fbsdkdfl_SafariServices_get_c(SFSafariViewController); 330| 0| return c; 331| 0|} 332| | 333| |Class fbsdkdfl_SFAuthenticationSessionClass(void) 334| 0|{ 335| 0| _fbsdkdfl_SafariServices_get_c(SFAuthenticationSession); 336| 0| return c; 337| 0|} 338| | 339| |#pragma mark - Authentication Services 340| |_fbsdkdfl_load_framework_once_impl_(AuthenticationServices) 341| |_fbsdkdfl_handle_get_impl_(AuthenticationServices) 342| | 343| 0|#define _fbsdkdfl_AuthenticationServices_get_c(SYMBOL) _fbsdkdfl_symbol_get_c(AuthenticationServices, SYMBOL); 344| | 345| |Class fbsdkdfl_ASWebAuthenticationSessionClass(void) 346| 0|{ 347| 0| _fbsdkdfl_AuthenticationServices_get_c(ASWebAuthenticationSession); 348| 0| return c; 349| 0|} 350| | 351| |#pragma mark - CoreTelephony Classes 352| | 353| |_fbsdkdfl_load_framework_once_impl_(CoreTelephony) 354| |_fbsdkdfl_handle_get_impl_(CoreTelephony) 355| | 356| 0|#define _fbsdkdfl_CoreTelephonyLibrary_get_c(SYMBOL) _fbsdkdfl_symbol_get_c(CoreTelephony, SYMBOL); 357| | 358| |Class fbsdkdfl_CTTelephonyNetworkInfoClass(void) 359| 0|{ 360| 0| _fbsdkdfl_CoreTelephonyLibrary_get_c(CTTelephonyNetworkInfo); 361| 0| return c; 362| 0|} /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKError.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKError.h" 20| | 21| |#import "FBSDKConstants.h" 22| |#import "FBSDKCoreKitBasicsImport.h" 23| |#import "FBSDKErrorReporting.h" 24| |#import "FBSDKFeatureManager.h" 25| |#import "FBSDKSettings.h" 26| | 27| |@interface FBSDKError () 28| | 29| |@property (class, nullable, nonatomic) id errorReporter; 30| | 31| |@end 32| | 33| |@implementation FBSDKError 34| | 35| |static id _errorReporter; 36| | 37| |#pragma mark - Class Methods 38| | 39| |+ (id)errorReporter 40| 0|{ 41| 0| return _errorReporter; 42| 0|} 43| | 44| |+ (void)setErrorReporter:(id)errorReporter 45| 0|{ 46| 0| _errorReporter = errorReporter; 47| 0|} 48| | 49| |+ (void)configureWithErrorReporter:(id)errorReporter 50| 0|{ 51| 0| self.errorReporter = errorReporter; 52| 0|} 53| | 54| |+ (NSError *)errorWithCode:(NSInteger)code message:(NSString *)message 55| 0|{ 56| 0| return [self errorWithCode:code message:message underlyingError:nil]; 57| 0|} 58| | 59| |+ (NSError *)errorWithDomain:(NSErrorDomain)domain code:(NSInteger)code message:(NSString *)message 60| 0|{ 61| 0| return [self errorWithDomain:domain code:code message:message underlyingError:nil]; 62| 0|} 63| | 64| |+ (NSError *)errorWithCode:(NSInteger)code message:(NSString *)message underlyingError:(NSError *)underlyingError 65| 0|{ 66| 0| return [self errorWithCode:code userInfo:@{} message:message underlyingError:underlyingError]; 67| 0|} 68| | 69| |+ (NSError *)errorWithDomain:(NSErrorDomain)domain 70| | code:(NSInteger)code 71| | message:(NSString *)message 72| | underlyingError:(NSError *)underlyingError 73| 0|{ 74| 0| return [self errorWithDomain:domain code:code userInfo:@{} message:message underlyingError:underlyingError]; 75| 0|} 76| | 77| |+ (NSError *)errorWithCode:(NSInteger)code 78| | userInfo:(NSDictionary *)userInfo 79| | message:(NSString *)message 80| | underlyingError:(NSError *)underlyingError 81| 0|{ 82| 0| return [self errorWithDomain:FBSDKErrorDomain 83| 0| code:code 84| 0| userInfo:userInfo 85| 0| message:message 86| 0| underlyingError:underlyingError]; 87| 0|} 88| | 89| |+ (NSError *)errorWithDomain:(NSErrorDomain)domain 90| | code:(NSInteger)code 91| | userInfo:(NSDictionary *)userInfo 92| | message:(NSString *)message 93| | underlyingError:(NSError *)underlyingError 94| 0|{ 95| 0| NSMutableDictionary *fullUserInfo = [[NSMutableDictionary alloc] initWithDictionary:userInfo]; 96| 0| [FBSDKTypeUtility dictionary:fullUserInfo setObject:message forKey:FBSDKErrorDeveloperMessageKey]; 97| 0| [FBSDKTypeUtility dictionary:fullUserInfo setObject:underlyingError forKey:NSUnderlyingErrorKey]; 98| 0| userInfo = fullUserInfo.count ? [fullUserInfo copy] : nil; 99| 0| [self.errorReporter saveError:code errorDomain:domain message:message]; 100| | 101| 0| return [[NSError alloc] initWithDomain:domain code:code userInfo:userInfo]; 102| 0|} 103| | 104| |+ (NSError *)invalidArgumentErrorWithName:(NSString *)name value:(id)value message:(NSString *)message 105| 0|{ 106| 0| return [self invalidArgumentErrorWithName:name value:value message:message underlyingError:nil]; 107| 0|} 108| | 109| |+ (NSError *)invalidArgumentErrorWithDomain:(NSErrorDomain)domain 110| | name:(NSString *)name 111| | value:(id)value 112| | message:(NSString *)message 113| 0|{ 114| 0| return [self invalidArgumentErrorWithDomain:domain name:name value:value message:message underlyingError:nil]; 115| 0|} 116| | 117| |+ (NSError *)invalidArgumentErrorWithName:(NSString *)name 118| | value:(id)value 119| | message:(NSString *)message 120| | underlyingError:(NSError *)underlyingError 121| 0|{ 122| 0| return [self invalidArgumentErrorWithDomain:FBSDKErrorDomain 123| 0| name:name 124| 0| value:value 125| 0| message:message 126| 0| underlyingError:underlyingError]; 127| 0|} 128| | 129| |+ (NSError *)invalidArgumentErrorWithDomain:(NSErrorDomain)domain 130| | name:(NSString *)name 131| | value:(id)value 132| | message:(NSString *)message 133| | underlyingError:(NSError *)underlyingError 134| 0|{ 135| 0| if (!message) { 136| 0| message = [[NSString alloc] initWithFormat:@"Invalid value for %@: %@", name, value]; 137| 0| } 138| 0| NSMutableDictionary *userInfo = [NSMutableDictionary new]; 139| 0| [FBSDKTypeUtility dictionary:userInfo setObject:name forKey:FBSDKErrorArgumentNameKey]; 140| 0| [FBSDKTypeUtility dictionary:userInfo setObject:value forKey:FBSDKErrorArgumentValueKey]; 141| 0| return [self errorWithDomain:domain 142| 0| code:FBSDKErrorInvalidArgument 143| 0| userInfo:userInfo 144| 0| message:message 145| 0| underlyingError:underlyingError]; 146| 0|} 147| | 148| |+ (NSError *)invalidCollectionErrorWithName:(NSString *)name 149| | collection:(id)collection 150| | item:(id)item 151| | message:(NSString *)message 152| 0|{ 153| 0| return [self invalidCollectionErrorWithName:name collection:collection item:item message:message underlyingError:nil]; 154| 0|} 155| | 156| |+ (NSError *)invalidCollectionErrorWithName:(NSString *)name 157| | collection:(id)collection 158| | item:(id)item 159| | message:(NSString *)message 160| | underlyingError:(NSError *)underlyingError 161| 0|{ 162| 0| if (!message) { 163| 0| message = 164| 0| [[NSString alloc] initWithFormat:@"Invalid item (%@) found in collection for %@: %@", item, name, collection]; 165| 0| } 166| 0| NSMutableDictionary *userInfo = [NSMutableDictionary new]; 167| 0| [FBSDKTypeUtility dictionary:userInfo setObject:name forKey:FBSDKErrorArgumentNameKey]; 168| 0| [FBSDKTypeUtility dictionary:userInfo setObject:item forKey:FBSDKErrorArgumentValueKey]; 169| 0| [FBSDKTypeUtility dictionary:userInfo setObject:collection forKey:FBSDKErrorArgumentCollectionKey]; 170| 0| return [self errorWithCode:FBSDKErrorInvalidArgument 171| 0| userInfo:userInfo 172| 0| message:message 173| 0| underlyingError:underlyingError]; 174| 0|} 175| | 176| |+ (NSError *)requiredArgumentErrorWithName:(NSString *)name message:(NSString *)message 177| 0|{ 178| 0| return [self requiredArgumentErrorWithName:name message:message underlyingError:nil]; 179| 0|} 180| | 181| |+ (NSError *)requiredArgumentErrorWithDomain:(NSErrorDomain)domain name:(NSString *)name message:(NSString *)message 182| 0|{ 183| 0| if (!message) { 184| 0| message = [[NSString alloc] initWithFormat:@"Value for %@ is required.", name]; 185| 0| } 186| 0| return [self invalidArgumentErrorWithDomain:domain name:name value:nil message:message underlyingError:nil]; 187| 0|} 188| | 189| |+ (NSError *)requiredArgumentErrorWithName:(NSString *)name 190| | message:(NSString *)message 191| | underlyingError:(NSError *)underlyingError 192| 0|{ 193| 0| if (!message) { 194| 0| message = [[NSString alloc] initWithFormat:@"Value for %@ is required.", name]; 195| 0| } 196| 0| return [self invalidArgumentErrorWithName:name value:nil message:message underlyingError:underlyingError]; 197| 0|} 198| | 199| |+ (NSError *)unknownErrorWithMessage:(NSString *)message 200| 0|{ 201| 0| return [self errorWithCode:FBSDKErrorUnknown userInfo:@{} message:message underlyingError:nil]; 202| 0|} 203| | 204| |+ (BOOL)isNetworkError:(NSError *)error 205| 0|{ 206| 0| NSError *innerError = error.userInfo[NSUnderlyingErrorKey]; 207| 0| if (innerError && [self isNetworkError:innerError]) { 208| 0| return YES; 209| 0| } 210| | 211| 0| switch (error.code) { 212| 0| case NSURLErrorTimedOut: 213| 0| case NSURLErrorCannotFindHost: 214| 0| case NSURLErrorCannotConnectToHost: 215| 0| case NSURLErrorNetworkConnectionLost: 216| 0| case NSURLErrorDNSLookupFailed: 217| 0| case NSURLErrorNotConnectedToInternet: 218| 0| case NSURLErrorInternationalRoamingOff: 219| 0| case NSURLErrorCallIsActive: 220| 0| case NSURLErrorDataNotAllowed: 221| 0| return YES; 222| 0| default: 223| 0| return NO; 224| 0| } 225| 0|} 226| | 227| |#if DEBUG 228| | #if FBSDKTEST 229| | 230| |+ (void)reset 231| 0|{ 232| 0| _errorReporter = nil; 233| 0|} 234| | 235| | #endif 236| |#endif 237| | 238| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKFeatureManager.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKFeatureManager.h" 20| | 21| |#import "FBSDKGateKeeperManager.h" 22| |#import "FBSDKGateKeeperManaging.h" 23| |#import "FBSDKSettings.h" 24| |#import "NSUserDefaults+FBSDKDataPersisting.h" 25| | 26| |static NSString *const FBSDKFeatureManagerPrefix = @"com.facebook.sdk:FBSDKFeatureManager.FBSDKFeature"; 27| | 28| |NS_ASSUME_NONNULL_BEGIN 29| | 30| |@interface FBSDKFeatureManager () 31| | 32| |@property (nullable, nonatomic) Class gateKeeperManager; 33| |@property (nullable, nonatomic) id store; 34| | 35| |@end 36| | 37| |@implementation FBSDKFeatureManager 38| | 39| |#pragma mark - Public methods 40| | 41| |// Transitional singleton introduced as a way to change the usage semantics 42| |// from a type-based interface to an instance-based interface. 43| |// The goal is to move from: 44| |// ClassWithoutUnderlyingInstance -> ClassRelyingOnUnderlyingInstance -> Instance 45| |+ (instancetype)shared 46| 0|{ 47| 0| static dispatch_once_t nonce; 48| 0| static id instance; 49| 0| dispatch_once(&nonce, ^{ 50| 0| instance = [self new]; 51| 0| }); 52| 0| return instance; 53| 0|} 54| | 55| |- (instancetype)init 56| 0|{ 57| 0| return [self initWithGateKeeperManager:FBSDKGateKeeperManager.class 58| 0| store:NSUserDefaults.standardUserDefaults]; 59| 0|} 60| | 61| |- (instancetype)initWithGateKeeperManager:(Class)gateKeeperManager 62| | store:(id)store 63| 0|{ 64| 0| if ((self = [super init])) { 65| 0| _gateKeeperManager = gateKeeperManager; 66| 0| _store = store; 67| 0| } 68| 0| return self; 69| 0|} 70| | 71| |+ (void)checkFeature:(FBSDKFeature)feature 72| | completionBlock:(FBSDKFeatureManagerBlock)completionBlock 73| 0|{ 74| 0| [self.shared checkFeature:feature completionBlock:completionBlock]; 75| 0|} 76| | 77| |- (void)checkFeature:(FBSDKFeature)feature 78| | completionBlock:(FBSDKFeatureManagerBlock)completionBlock 79| 0|{ 80| | // check if the feature is locally disabled by Crash Shield first 81| 0| NSString *version = [self.store stringForKey:[self storageKeyForFeature:feature]]; 82| 0| if (version && [version isEqualToString:[FBSDKSettings sdkVersion]]) { 83| 0| if (completionBlock) { 84| 0| completionBlock(false); 85| 0| } 86| 0| return; 87| 0| } 88| | // check gk 89| 0| [self.gateKeeperManager loadGateKeepers:^(NSError *_Nullable error) { 90| 0| if (completionBlock) { 91| 0| completionBlock([self isEnabled:feature]); 92| 0| } 93| 0| }]; 94| 0|} 95| | 96| |- (BOOL)isEnabled:(FBSDKFeature)feature 97| 0|{ 98| 0| if (FBSDKFeatureCore == feature || FBSDKFeatureNone == feature) { 99| 0| return YES; 100| 0| } 101| | 102| 0| FBSDKFeature parentFeature = [self.class getParentFeature:feature]; 103| 0| if (parentFeature == feature) { 104| 0| return [self checkGK:feature]; 105| 0| } else { 106| 0| return [self isEnabled:parentFeature] && [self checkGK:feature]; 107| 0| } 108| 0|} 109| | 110| |- (void)disableFeature:(FBSDKFeature)feature 111| 0|{ 112| 0| [self.store setObject:[FBSDKSettings sdkVersion] forKey:[self storageKeyForFeature:feature]]; 113| 0|} 114| | 115| |- (NSString *)storageKeyForFeature:(FBSDKFeature)feature 116| 0|{ 117| 0| return [FBSDKFeatureManagerPrefix stringByAppendingString:[self.class featureName:feature]]; 118| 0|} 119| | 120| |#pragma mark - Private methods 121| | 122| |+ (FBSDKFeature)getParentFeature:(FBSDKFeature)feature 123| 0|{ 124| 0| if ((feature & 0xFF) > 0) { 125| 0| return feature & 0xFFFFFF00; 126| 0| } else if ((feature & 0xFF00) > 0) { 127| 0| return feature & 0xFFFF0000; 128| 0| } else if ((feature & 0xFF0000) > 0) { 129| 0| return feature & 0xFF000000; 130| 0| } else { 131| 0| return 0; 132| 0| } 133| 0|} 134| | 135| |- (BOOL)checkGK:(FBSDKFeature)feature 136| 0|{ 137| 0| NSString *key = [NSString stringWithFormat:@"FBSDKFeature%@", [self.class featureName:feature]]; 138| 0| BOOL defaultValue = [self.class defaultStatus:feature]; 139| | 140| 0| return [self.gateKeeperManager boolForKey:key 141| 0| defaultValue:defaultValue]; 142| 0|} 143| | 144| |+ (NSString *)featureName:(FBSDKFeature)feature 145| 0|{ 146| 0| NSString *featureName; 147| 0| switch (feature) { 148| 0| case FBSDKFeatureNone: featureName = @"NONE"; break; 149| 0| case FBSDKFeatureCore: featureName = @"CoreKit"; break; 150| 0| case FBSDKFeatureAppEvents: featureName = @"AppEvents"; break; 151| 0| case FBSDKFeatureCodelessEvents: featureName = @"CodelessEvents"; break; 152| 0| case FBSDKFeatureRestrictiveDataFiltering: featureName = @"RestrictiveDataFiltering"; break; 153| 0| case FBSDKFeatureAAM: featureName = @"AAM"; break; 154| 0| case FBSDKFeaturePrivacyProtection: featureName = @"PrivacyProtection"; break; 155| 0| case FBSDKFeatureSuggestedEvents: featureName = @"SuggestedEvents"; break; 156| 0| case FBSDKFeatureIntelligentIntegrity: featureName = @"IntelligentIntegrity"; break; 157| 0| case FBSDKFeatureModelRequest: featureName = @"ModelRequest"; break; 158| 0| case FBSDKFeatureEventDeactivation: featureName = @"EventDeactivation"; break; 159| 0| case FBSDKFeatureSKAdNetwork: featureName = @"SKAdNetwork"; break; 160| 0| case FBSDKFeatureSKAdNetworkConversionValue: featureName = @"SKAdNetworkConversionValue"; break; 161| 0| case FBSDKFeatureInstrument: featureName = @"Instrument"; break; 162| 0| case FBSDKFeatureCrashReport: featureName = @"CrashReport"; break; 163| 0| case FBSDKFeatureCrashShield: featureName = @"CrashShield"; break; 164| 0| case FBSDKFeatureErrorReport: featureName = @"ErrorReport"; break; 165| 0| case FBSDKFeatureATELogging: featureName = @"ATELogging"; break; 166| 0| case FBSDKFeatureAEM: featureName = @"AEM"; break; 167| 0| case FBSDKFeatureLogin: featureName = @"LoginKit"; break; 168| 0| case FBSDKFeatureShare: featureName = @"ShareKit"; break; 169| 0| case FBSDKFeatureGamingServices: featureName = @"GamingServicesKit"; break; 170| 0| } 171| | 172| 0| return featureName; 173| 0|} 174| | 175| |+ (BOOL)defaultStatus:(FBSDKFeature)feature 176| 0|{ 177| 0| switch (feature) { 178| 0| case FBSDKFeatureRestrictiveDataFiltering: 179| 0| case FBSDKFeatureEventDeactivation: 180| 0| case FBSDKFeatureInstrument: 181| 0| case FBSDKFeatureCrashReport: 182| 0| case FBSDKFeatureCrashShield: 183| 0| case FBSDKFeatureErrorReport: 184| 0| case FBSDKFeatureAAM: 185| 0| case FBSDKFeaturePrivacyProtection: 186| 0| case FBSDKFeatureSuggestedEvents: 187| 0| case FBSDKFeatureIntelligentIntegrity: 188| 0| case FBSDKFeatureModelRequest: 189| 0| case FBSDKFeatureATELogging: 190| 0| case FBSDKFeatureAEM: 191| 0| case FBSDKFeatureSKAdNetwork: 192| 0| case FBSDKFeatureSKAdNetworkConversionValue: 193| 0| return NO; 194| 0| case FBSDKFeatureNone: 195| 0| case FBSDKFeatureLogin: 196| 0| case FBSDKFeatureShare: 197| 0| case FBSDKFeatureCore: 198| 0| case FBSDKFeatureAppEvents: 199| 0| case FBSDKFeatureCodelessEvents: 200| 0| case FBSDKFeatureGamingServices: 201| 0| return YES; 202| 0| } 203| 0|} 204| | 205| |@end 206| | 207| |NS_ASSUME_NONNULL_END /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKInternalUtility.h: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import 20| |#import 21| | 22| |NS_ASSUME_NONNULL_BEGIN 23| | 24| 0|#define FBSDK_CANOPENURL_FACEBOOK @"fbauth2" 25| |#define FBSDK_CANOPENURL_FBAPI @"fbapi" 26| 0|#define FBSDK_CANOPENURL_MESSENGER @"fb-messenger-share-api" 27| 0|#define FBSDK_CANOPENURL_MSQRD_PLAYER @"msqrdplayer" 28| |#define FBSDK_CANOPENURL_SHARE_EXTENSION @"fbshareextension" 29| | 30| |@protocol FBSDKInfoDictionaryProviding; 31| | 32| |/** 33| | Describes the callback for appLinkFromURLInBackground. 34| | @param object the FBSDKAppLink representing the deferred App Link 35| | @param stop the error during the request, if any 36| | 37| | */ 38| |typedef id _Nullable (^FBSDKInvalidObjectHandler)(id object, BOOL *stop) 39| |NS_SWIFT_NAME(InvalidObjectHandler); 40| | 41| |NS_SWIFT_NAME(InternalUtility) 42| |@interface FBSDKInternalUtility : NSObject 43| | 44| |- (instancetype)init NS_UNAVAILABLE; 45| |+ (instancetype)new NS_UNAVAILABLE; 46| | 47| |+ (void)configureWithInfoDictionaryProvider:(id)infoDictionaryProvider; 48| | 49| |@property (class, nonnull, readonly) FBSDKInternalUtility *sharedUtility; 50| | 51| |/** 52| | Constructs the scheme for apps that come to the current app through the bridge. 53| | */ 54| |@property (class, nonatomic, copy, readonly) NSString *appURLScheme; 55| | 56| |/** 57| | Returns bundle for returning localized strings 58| | 59| | We assume a convention of a bundle named FBSDKStrings.bundle, otherwise we 60| | return the main bundle. 61| | */ 62| |@property (class, nonatomic, strong, readonly) NSBundle *bundleForStrings; 63| | 64| |/** 65| | Gets the milliseconds since the Unix Epoch. 66| | 67| | Changes in the system clock will affect this value. 68| | @return The number of milliseconds since the Unix Epoch. 69| | */ 70| |@property (class, nonatomic, assign, readonly) uint64_t currentTimeInMilliseconds; 71| | 72| |/** 73| | The version of the operating system on which the process is executing. 74| | */ 75| |@property (class, nonatomic, assign, readonly) NSOperatingSystemVersion operatingSystemVersion; 76| | 77| |/* 78| | Checks if the app is Unity. 79| | */ 80| |@property (class, nonatomic, assign, readonly) BOOL isUnity; 81| | 82| |/** 83| | Constructs an URL for the current app. 84| | @param host The host for the URL. 85| | @param path The path for the URL. 86| | @param queryParameters The query parameters for the URL. This will be converted into a query string. 87| | @param errorRef If an error occurs, upon return contains an NSError object that describes the problem. 88| | @return The app URL. 89| | */ 90| |+ (NSURL *)appURLWithHost:(NSString *)host 91| | path:(NSString *)path 92| | queryParameters:(NSDictionary *)queryParameters 93| | error:(NSError *__autoreleasing *)errorRef; 94| | 95| |/** 96| | Parses an FB url's query params (and potentially fragment) into a dictionary. 97| | @param url The FB url. 98| | @return A dictionary with the key/value pairs. 99| | */ 100| |+ (NSDictionary *)parametersFromFBURL:(NSURL *)url; 101| | 102| |/** 103| | Constructs a Facebook URL. 104| | @param hostPrefix The prefix for the host, such as 'm', 'graph', etc. 105| | @param path The path for the URL. This may or may not include a version. 106| | @param queryParameters The query parameters for the URL. This will be converted into a query string. 107| | @param errorRef If an error occurs, upon return contains an NSError object that describes the problem. 108| | @return The Facebook URL. 109| | */ 110| |+ (NSURL *)facebookURLWithHostPrefix:(NSString *)hostPrefix 111| | path:(NSString *)path 112| | queryParameters:(NSDictionary *)queryParameters 113| | error:(NSError *__autoreleasing *)errorRef; 114| | 115| |/** 116| | Constructs a Facebook URL. 117| | @param hostPrefix The prefix for the host, such as 'm', 'graph', etc. 118| | @param path The path for the URL. This may or may not include a version. 119| | @param queryParameters The query parameters for the URL. This will be converted into a query string. 120| | @param defaultVersion A version to add to the URL if none is found in the path. 121| | @param errorRef If an error occurs, upon return contains an NSError object that describes the problem. 122| | @return The Facebook URL. 123| | */ 124| |+ (NSURL *)facebookURLWithHostPrefix:(NSString *)hostPrefix 125| | path:(NSString *)path 126| | queryParameters:(NSDictionary *)queryParameters 127| | defaultVersion:(NSString *)defaultVersion 128| | error:(NSError *__autoreleasing *)errorRef; 129| | 130| |/** 131| | Constructs a Facebook URL that doesn't need to specify an API version. 132| | @param hostPrefix The prefix for the host, such as 'm', 'graph', etc. 133| | @param path The path for the URL. This may or may not include a version. 134| | @param queryParameters The query parameters for the URL. This will be converted into a query string. 135| | @param errorRef If an error occurs, upon return contains an NSError object that describes the problem. 136| | @return The Facebook URL. 137| | */ 138| |+ (NSURL *)unversionedFacebookURLWithHostPrefix:(NSString *)hostPrefix 139| | path:(NSString *)path 140| | queryParameters:(NSDictionary *)queryParameters 141| | error:(NSError *__autoreleasing *)errorRef; 142| | 143| |/** 144| | Tests whether the supplied URL is a valid URL for opening in the browser. 145| | @param URL The URL to test. 146| | @return YES if the URL refers to an http or https resource, otherwise NO. 147| | */ 148| |+ (BOOL)isBrowserURL:(NSURL *)URL; 149| | 150| |/** 151| | Tests whether the supplied bundle identifier references a Facebook app. 152| | @param bundleIdentifier The bundle identifier to test. 153| | @return YES if the bundle identifier refers to a Facebook app, otherwise NO. 154| | */ 155| |+ (BOOL)isFacebookBundleIdentifier:(NSString *)bundleIdentifier; 156| | 157| |/** 158| | Tests whether the supplied bundle identifier references the Safari app. 159| | @param bundleIdentifier The bundle identifier to test. 160| | @return YES if the bundle identifier refers to the Safari app, otherwise NO. 161| | */ 162| |+ (BOOL)isSafariBundleIdentifier:(NSString *)bundleIdentifier; 163| | 164| |/** 165| | Checks equality between 2 objects. 166| | 167| | Checks for pointer equality, nils, isEqual:. 168| | @param object The first object to compare. 169| | @param other The second object to compare. 170| | @return YES if the objects are equal, otherwise NO. 171| | */ 172| |+ (BOOL)object:(id)object isEqualToObject:(id)other; 173| | 174| |/** 175| | Constructs an NSURL. 176| | @param scheme The scheme for the URL. 177| | @param host The host for the URL. 178| | @param path The path for the URL. 179| | @param queryParameters The query parameters for the URL. This will be converted into a query string. 180| | @param errorRef If an error occurs, upon return contains an NSError object that describes the problem. 181| | @return The URL. 182| | */ 183| |+ (nullable NSURL *)URLWithScheme:(NSString *)scheme 184| | host:(NSString *)host 185| | path:(NSString *)path 186| | queryParameters:(NSDictionary *)queryParameters 187| | error:(NSError *__autoreleasing *)errorRef; 188| | 189| |/** 190| | * Deletes all the cookies in the NSHTTPCookieStorage for Facebook web dialogs 191| | */ 192| |+ (void)deleteFacebookCookies; 193| | 194| |/** 195| | Extracts permissions from a response fetched from me/permissions 196| | @param responseObject the response 197| | @param grantedPermissions the set to add granted permissions to 198| | @param declinedPermissions the set to add declined permissions to. 199| | */ 200| |+ (void)extractPermissionsFromResponse:(NSDictionary *)responseObject 201| | grantedPermissions:(NSMutableSet *)grantedPermissions 202| | declinedPermissions:(NSMutableSet *)declinedPermissions 203| | expiredPermissions:(NSMutableSet *)expiredPermissions; 204| | 205| |/** 206| | Registers a transient object so that it will not be deallocated until unregistered 207| | @param object The transient object 208| | */ 209| |+ (void)registerTransientObject:(id)object; 210| | 211| |/** 212| | Unregisters a transient object that was previously registered with registerTransientObject: 213| | @param object The transient object 214| | */ 215| |+ (void)unregisterTransientObject:(__weak id)object; 216| | 217| |/** 218| | validates that the app ID is non-nil, throws an NSException if nil. 219| | */ 220| |+ (void)validateAppID; 221| | 222| |/** 223| | Validates that the client access token is non-nil, otherwise - throws an NSException otherwise. 224| | Returns the composed client access token. 225| | */ 226| |+ (NSString *)validateRequiredClientAccessToken; 227| | 228| |/** 229| | validates that the right URL schemes are registered, throws an NSException if not. 230| | */ 231| |+ (void)validateURLSchemes; 232| | 233| |/** 234| | validates that Facebook reserved URL schemes are not registered, throws an NSException if they are. 235| | */ 236| |+ (void)validateFacebookReservedURLSchemes; 237| | 238| |/** 239| | Attempts to find the first UIViewController in the view's responder chain. Returns nil if not found. 240| | */ 241| |+ (nullable UIViewController *)viewControllerForView:(UIView *)view; 242| | 243| |/** 244| | returns true if the url scheme is registered in the CFBundleURLTypes 245| | */ 246| |+ (BOOL)isRegisteredURLScheme:(NSString *)urlScheme; 247| | 248| |/** 249| | returns the current key window 250| | */ 251| |- (nullable UIWindow *)findWindow; 252| | 253| |/** 254| | returns currently displayed top view controller. 255| | */ 256| |+ (nullable UIViewController *)topMostViewController; 257| | 258| |#if !TARGET_OS_TV 259| |/** 260| | returns interface orientation for the key window. 261| | */ 262| |+ (UIInterfaceOrientation)statusBarOrientation; 263| |#endif 264| | 265| |/** 266| | Converts NSData to a hexadecimal UTF8 String. 267| | */ 268| |+ (nullable NSString *)hexadecimalStringFromData:(NSData *)data; 269| | 270| |/* 271| | Checks if the permission is a publish permission. 272| | */ 273| |+ (BOOL)isPublishPermission:(NSString *)permission; 274| | 275| |#pragma mark - FB Apps Installed 276| | 277| |@property (class, nonatomic, assign, readonly) BOOL isFacebookAppInstalled; 278| |@property (class, nonatomic, assign, readonly) BOOL isMessengerAppInstalled; 279| |@property (class, nonatomic, assign, readonly) BOOL isMSQRDPlayerAppInstalled; 280| | 281| |+ (void)checkRegisteredCanOpenURLScheme:(NSString *)urlScheme; 282| |+ (BOOL)isRegisteredCanOpenURLScheme:(NSString *)urlScheme; 283| | 284| 0|#define FBSDKConditionalLog(condition, loggingBehavior, desc, ...) \ 285| 0|{ \ 286| 0| if (!(condition)) { \ 287| 0| NSString *msg = [NSString stringWithFormat:(desc), ##__VA_ARGS__]; \ 288| 0| [FBSDKLogger singleShotLogEntry:loggingBehavior logEntry:msg]; \ 289| 0| } \ 290| 0|} 291| | 292| |#define FB_BASE_URL @"facebook.com" 293| | 294| |@end 295| | 296| |NS_ASSUME_NONNULL_END /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKInternalUtility.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKInternalUtility.h" 20| | 21| |#import 22| |#import 23| | 24| |#import "FBSDKCoreKit+Internal.h" 25| |#import "FBSDKCoreKitBasicsImport.h" 26| |#import "FBSDKError.h" 27| |#import "FBSDKSettings.h" 28| |#import "FBSDKSettings+Internal.h" 29| | 30| |typedef NS_ENUM(NSUInteger, FBSDKInternalUtilityVersionMask) { 31| | FBSDKInternalUtilityMajorVersionMask = 0xFFFF0000, 32| | // FBSDKInternalUtilityMinorVersionMask = 0x0000FF00, // unused 33| | // FBSDKInternalUtilityPatchVersionMask = 0x000000FF, // unused 34| |}; 35| | 36| |typedef NS_ENUM(NSUInteger, FBSDKInternalUtilityVersionShift) { 37| | FBSDKInternalUtilityMajorVersionShift = 16, 38| | // FBSDKInternalUtilityMinorVersionShift = 8, // unused 39| | // FBSDKInternalUtilityPatchVersionShift = 0, // unused 40| |}; 41| | 42| |@interface FBSDKInternalUtility () 43| | 44| |// TODO: Replace this with an instance variable i.e.: @property (nonnull, nonatomic) id logger; 45| |@property (class, nonnull, nonatomic) Class loggerType; 46| |@property (nonatomic) BOOL isConfigured; 47| | 48| |@end 49| | 50| |@implementation FBSDKInternalUtility 51| | 52| |static id _infoDictionaryProvider; 53| |static Class _loggerType; 54| | 55| |// These are stored at the class level so that they can be reset in unit tests 56| |static dispatch_once_t fetchApplicationQuerySchemesToken; 57| |static dispatch_once_t checkIfFacebookAppInstalledToken; 58| |static dispatch_once_t checkIfMessengerAppInstalledToken; 59| |static dispatch_once_t checkIfMSQRDPlayerAppInstalledToken; 60| |static dispatch_once_t checkRegisteredCanOpenUrlSchemesToken; 61| |static dispatch_once_t checkOperatingSystemVersionToken; 62| |static dispatch_once_t fetchUrlSchemesToken; 63| |static dispatch_once_t sharedUtilityNonce; 64| | 65| |static BOOL ShouldOverrideHostWithGamingDomain(NSString *hostPrefix) 66| 0|{ 67| 0| return [FBSDKAuthenticationToken.currentAuthenticationToken respondsToSelector:@selector(graphDomain)] 68| 0| && [FBSDKAuthenticationToken.currentAuthenticationToken.graphDomain isEqualToString:@"gaming"] 69| 0| && ([hostPrefix isEqualToString:@"graph."] || [hostPrefix isEqualToString:@"graph-video."]); 70| 0|} 71| | 72| |// Transitional singleton introduced as a way to change the usage semantics 73| |// from a type-based interface to an instance-based interface. 74| |+ (instancetype)sharedUtility 75| 0|{ 76| 0| static id instance; 77| 0| dispatch_once(&sharedUtilityNonce, ^{ 78| 0| instance = [self new]; 79| 0| }); 80| 0| return instance; 81| 0|} 82| | 83| |#pragma mark - Class Methods 84| | 85| |+ (void)configureWithInfoDictionaryProvider:(id)infoDictionaryProvider 86| 0|{ 87| 0| if (self == FBSDKInternalUtility.class) { 88| 0| _infoDictionaryProvider = infoDictionaryProvider; 89| | 90| 0| self.sharedUtility.isConfigured = YES; 91| 0| } 92| 0|} 93| | 94| |+ (id)infoDictionaryProvider 95| 0|{ 96| 0| return _infoDictionaryProvider; 97| 0|} 98| | 99| |+ (void)setLoggerType:(Class)loggerType 100| 0|{ 101| 0| _loggerType = loggerType; 102| 0|} 103| | 104| |+ (Class)loggerType 105| 0|{ 106| 0| if (_loggerType == nil) { 107| 0| _loggerType = [FBSDKLogger class]; 108| 0| } 109| 0| return _loggerType; 110| 0|} 111| | 112| |+ (NSString *)appURLScheme 113| 0|{ 114| 0| return self.sharedUtility.appURLScheme; 115| 0|} 116| | 117| |- (NSString *)appURLScheme 118| 0|{ 119| 0| NSString *appID = ([FBSDKSettings appID] ?: @""); 120| 0| NSString *suffix = ([FBSDKSettings appURLSchemeSuffix] ?: @""); 121| 0| return [[NSString alloc] initWithFormat:@"fb%@%@", appID, suffix]; 122| 0|} 123| | 124| |+ (NSURL *)appURLWithHost:(NSString *)host 125| | path:(NSString *)path 126| | queryParameters:(NSDictionary *)queryParameters 127| | error:(NSError *__autoreleasing *)errorRef 128| 0|{ 129| 0| return [self URLWithScheme:[self appURLScheme] 130| 0| host:host 131| 0| path:path 132| 0| queryParameters:queryParameters 133| 0| error:errorRef]; 134| 0|} 135| | 136| |+ (NSDictionary *)parametersFromFBURL:(NSURL *)url 137| 0|{ 138| | // version 3.2.3 of the Facebook app encodes the parameters in the query but 139| | // version 3.3 and above encode the parameters in the fragment; 140| | // merge them together with fragment taking priority. 141| 0| NSMutableDictionary *params = [NSMutableDictionary dictionary]; 142| 0| [params addEntriesFromDictionary:[FBSDKBasicUtility dictionaryWithQueryString:url.query]]; 143| | 144| | // Only get the params from the fragment if it has authorize as the host 145| 0| if ([url.host isEqualToString:@"authorize"]) { 146| 0| [params addEntriesFromDictionary:[FBSDKBasicUtility dictionaryWithQueryString:url.fragment]]; 147| 0| } 148| 0| return params; 149| 0|} 150| | 151| |+ (NSBundle *)bundleForStrings 152| 0|{ 153| 0| static NSBundle *bundle; 154| 0| static dispatch_once_t onceToken; 155| 0| dispatch_once(&onceToken, ^{ 156| 0| NSString *stringsBundlePath = [[NSBundle bundleForClass:[FBSDKApplicationDelegate class]] 157| 0| pathForResource:@"FacebookSDKStrings" 158| 0| ofType:@"bundle"]; 159| 0| bundle = [NSBundle bundleWithPath:stringsBundlePath] ?: [NSBundle mainBundle]; 160| 0| }); 161| 0| return bundle; 162| 0|} 163| | 164| |+ (uint64_t)currentTimeInMilliseconds 165| 0|{ 166| 0| struct timeval time; 167| 0| gettimeofday(&time, NULL); 168| 0| return ((uint64_t)time.tv_sec * 1000) + (time.tv_usec / 1000); 169| 0|} 170| | 171| |+ (void)extractPermissionsFromResponse:(NSDictionary *)responseObject 172| | grantedPermissions:(NSMutableSet *)grantedPermissions 173| | declinedPermissions:(NSMutableSet *)declinedPermissions 174| | expiredPermissions:(NSMutableSet *)expiredPermissions 175| 0|{ 176| 0| NSArray *resultData = [FBSDKTypeUtility dictionary:responseObject objectForKey:@"data" ofType:NSArray.class]; 177| 0| if (resultData.count > 0) { 178| 0| for (NSDictionary *permissionsDictionary in resultData) { 179| 0| NSString *permissionName = [FBSDKTypeUtility dictionary:permissionsDictionary objectForKey:@"permission" ofType:NSString.class]; 180| 0| NSString *status = [FBSDKTypeUtility dictionary:permissionsDictionary objectForKey:@"status" ofType:NSString.class]; 181| | 182| 0| if (!permissionName || !status) { 183| 0| continue; 184| 0| } 185| | 186| 0| if ([status isEqualToString:@"granted"]) { 187| 0| [grantedPermissions addObject:permissionName]; 188| 0| } else if ([status isEqualToString:@"declined"]) { 189| 0| [declinedPermissions addObject:permissionName]; 190| 0| } else if ([status isEqualToString:@"expired"]) { 191| 0| [expiredPermissions addObject:permissionName]; 192| 0| } 193| 0| } 194| 0| } 195| 0|} 196| | 197| |+ (NSURL *)facebookURLWithHostPrefix:(NSString *)hostPrefix 198| | path:(NSString *)path 199| | queryParameters:(NSDictionary *)queryParameters 200| | error:(NSError *__autoreleasing *)errorRef 201| 0|{ 202| 0| return [self facebookURLWithHostPrefix:hostPrefix 203| 0| path:path 204| 0| queryParameters:queryParameters 205| 0| defaultVersion:@"" 206| 0| error:errorRef]; 207| 0|} 208| | 209| |+ (NSURL *)facebookURLWithHostPrefix:(NSString *)hostPrefix 210| | path:(NSString *)path 211| | queryParameters:(NSDictionary *)queryParameters 212| | defaultVersion:(NSString *)defaultVersion 213| | error:(NSError *__autoreleasing *)errorRef 214| 0|{ 215| 0| NSString *version = (defaultVersion.length > 0) ? defaultVersion : [FBSDKSettings graphAPIVersion]; 216| 0| if (version.length) { 217| 0| version = [@"/" stringByAppendingString:version]; 218| 0| } 219| | 220| 0| return [self _facebookURLWithHostPrefix:hostPrefix 221| 0| path:path 222| 0| queryParameters:queryParameters 223| 0| defaultVersion:version 224| 0| error:errorRef]; 225| 0|} 226| | 227| |+ (NSURL *)unversionedFacebookURLWithHostPrefix:(NSString *)hostPrefix 228| | path:(NSString *)path 229| | queryParameters:(NSDictionary *)queryParameters 230| | error:(NSError *__autoreleasing *)errorRef 231| 0|{ 232| 0| return [self _facebookURLWithHostPrefix:hostPrefix 233| 0| path:path 234| 0| queryParameters:queryParameters 235| 0| defaultVersion:@"" 236| 0| error:errorRef]; 237| 0|} 238| | 239| |+ (NSURL *)_facebookURLWithHostPrefix:(NSString *)hostPrefix 240| | path:(NSString *)path 241| | queryParameters:(NSDictionary *)queryParameters 242| | defaultVersion:(NSString *)version 243| | error:(NSError *__autoreleasing *)errorRef 244| 0|{ 245| 0| if (hostPrefix.length && ![hostPrefix hasSuffix:@"."]) { 246| 0| hostPrefix = [hostPrefix stringByAppendingString:@"."]; 247| 0| } 248| | 249| 0| NSString *host = 250| 0| ShouldOverrideHostWithGamingDomain(hostPrefix) 251| 0| ? @"fb.gg" 252| 0| : @"facebook.com"; 253| | 254| 0| NSString *domainPart = [FBSDKSettings facebookDomainPart]; 255| 0| if (domainPart.length) { 256| 0| host = [[NSString alloc] initWithFormat:@"%@.%@", domainPart, host]; 257| 0| } 258| 0| host = [NSString stringWithFormat:@"%@%@", hostPrefix ?: @"", host ?: @""]; 259| | 260| 0| if (path.length) { 261| 0| NSScanner *versionScanner = [[NSScanner alloc] initWithString:path]; 262| 0| if ([versionScanner scanString:@"/v" intoString:NULL] 263| 0| && [versionScanner scanInteger:NULL] 264| 0| && [versionScanner scanString:@"." intoString:NULL] 265| 0| && [versionScanner scanInteger:NULL]) { 266| 0| [self.loggerType singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors 267| 0| logEntry:[NSString stringWithFormat:@"Invalid Graph API version:%@, assuming %@ instead", 268| 0| version, 269| 0| [FBSDKSettings graphAPIVersion]]]; 270| 0| version = nil; 271| 0| } 272| 0| if (![path hasPrefix:@"/"]) { 273| 0| path = [@"/" stringByAppendingString:path]; 274| 0| } 275| 0| } 276| 0| path = [[NSString alloc] initWithFormat:@"%@%@", version ?: @"", path ?: @""]; 277| | 278| 0| return [self URLWithScheme:@"https" 279| 0| host:host 280| 0| path:path 281| 0| queryParameters:queryParameters 282| 0| error:errorRef]; 283| 0|} 284| | 285| |+ (BOOL)isBrowserURL:(NSURL *)URL 286| 0|{ 287| 0| NSString *scheme = URL.scheme.lowercaseString; 288| 0| return ([scheme isEqualToString:@"http"] || [scheme isEqualToString:@"https"]); 289| 0|} 290| | 291| |+ (BOOL)isFacebookBundleIdentifier:(NSString *)bundleIdentifier 292| 0|{ 293| 0| return ([bundleIdentifier hasPrefix:@"com.facebook."] 294| 0| || [bundleIdentifier hasPrefix:@".com.facebook."]); 295| 0|} 296| | 297| |+ (BOOL)isSafariBundleIdentifier:(NSString *)bundleIdentifier 298| 0|{ 299| 0| return ([bundleIdentifier isEqualToString:@"com.apple.mobilesafari"] 300| 0| || [bundleIdentifier isEqualToString:@"com.apple.SafariViewService"]); 301| 0|} 302| | 303| |+ (BOOL)object:(id)object isEqualToObject:(id)other 304| 0|{ 305| 0| if (object == other) { 306| 0| return YES; 307| 0| } 308| 0| if (!object || !other) { 309| 0| return NO; 310| 0| } 311| 0| return [object isEqual:other]; 312| 0|} 313| | 314| |+ (NSOperatingSystemVersion)operatingSystemVersion 315| 0|{ 316| 0| static NSOperatingSystemVersion operatingSystemVersion = { 317| 0| .majorVersion = 0, 318| 0| .minorVersion = 0, 319| 0| .patchVersion = 0, 320| 0| }; 321| 0| dispatch_once(&checkOperatingSystemVersionToken, ^{ 322| 0| operatingSystemVersion = [NSProcessInfo processInfo].operatingSystemVersion; 323| 0| }); 324| 0| return operatingSystemVersion; 325| 0|} 326| | 327| |+ (NSURL *)URLWithScheme:(NSString *)scheme 328| | host:(NSString *)host 329| | path:(NSString *)path 330| | queryParameters:(NSDictionary *)queryParameters 331| | error:(NSError *__autoreleasing *)errorRef 332| 0|{ 333| 0| if (![path hasPrefix:@"/"]) { 334| 0| path = [@"/" stringByAppendingString:path ?: @""]; 335| 0| } 336| | 337| 0| NSString *queryString = nil; 338| 0| if (queryParameters.count) { 339| 0| NSError *queryStringError; 340| 0| NSString *queryStringFromParams = [FBSDKBasicUtility queryStringWithDictionary:queryParameters 341| 0| error:&queryStringError 342| 0| invalidObjectHandler:NULL]; 343| 0| if (queryStringFromParams) { 344| 0| queryString = [@"?" stringByAppendingString:queryStringFromParams]; 345| 0| } 346| 0| if (!queryString) { 347| 0| if (errorRef != NULL) { 348| 0| *errorRef = [FBSDKError invalidArgumentErrorWithName:@"queryParameters" 349| 0| value:queryParameters 350| 0| message:nil 351| 0| underlyingError:queryStringError]; 352| 0| } 353| 0| return nil; 354| 0| } 355| 0| } 356| | 357| 0| NSURL *const URL = [NSURL URLWithString:[NSString stringWithFormat: 358| 0| @"%@://%@%@%@", 359| 0| scheme ?: @"", 360| 0| host ?: @"", 361| 0| path ?: @"", 362| 0| queryString ?: @""]]; 363| 0| if (errorRef != NULL) { 364| 0| if (URL) { 365| 0| *errorRef = nil; 366| 0| } else { 367| 0| *errorRef = [FBSDKError unknownErrorWithMessage:@"Unknown error building URL."]; 368| 0| } 369| 0| } 370| 0| return URL; 371| 0|} 372| | 373| |+ (void)deleteFacebookCookies 374| 0|{ 375| 0| NSHTTPCookieStorage *cookies = [NSHTTPCookieStorage sharedHTTPCookieStorage]; 376| 0| NSArray *facebookCookies = [cookies cookiesForURL:[self facebookURLWithHostPrefix:@"m." 377| 0| path:@"/dialog/" 378| 0| queryParameters:@{} 379| 0| error:NULL]]; 380| | 381| 0| for (NSHTTPCookie *cookie in facebookCookies) { 382| 0| [cookies deleteCookie:cookie]; 383| 0| } 384| 0|} 385| | 386| |static NSMapTable *_transientObjects; 387| | 388| |+ (void)registerTransientObject:(id)object 389| 0|{ 390| 0| NSAssert([NSThread isMainThread], @"Must be called from the main thread!"); 391| 0| if (!_transientObjects) { 392| 0| _transientObjects = [NSMapTable new]; 393| 0| } 394| 0| NSUInteger count = ((NSNumber *)[_transientObjects objectForKey:object]).unsignedIntegerValue; 395| 0| [_transientObjects setObject:@(count + 1) forKey:object]; 396| 0|} 397| | 398| |+ (void)unregisterTransientObject:(__weak id)object 399| 0|{ 400| 0| if (!object) { 401| 0| return; 402| 0| } 403| 0| NSAssert([NSThread isMainThread], @"Must be called from the main thread!"); 404| 0| NSUInteger count = ((NSNumber *)[_transientObjects objectForKey:object]).unsignedIntegerValue; 405| 0| if (count == 1) { 406| 0| [_transientObjects removeObjectForKey:object]; 407| 0| } else if (count != 0) { 408| 0| [_transientObjects setObject:@(count - 1) forKey:object]; 409| 0| } else { 410| 0| NSString *msg = [NSString stringWithFormat:@"unregisterTransientObject:%@ count is 0. This may indicate a bug in the FBSDK. Please" 411| 0| " file a report to developers.facebook.com/bugs if you encounter any problems. Thanks!", [object class]]; 412| 0| [self.loggerType singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors 413| 0| logEntry:msg]; 414| 0| } 415| 0|} 416| | 417| |+ (UIViewController *)viewControllerForView:(UIView *)view 418| 0|{ 419| 0| UIResponder *responder = view.nextResponder; 420| 0| while (responder) { 421| 0| if ([responder isKindOfClass:[UIViewController class]]) { 422| 0| return (UIViewController *)responder; 423| 0| } 424| 0| responder = responder.nextResponder; 425| 0| } 426| 0| return nil; 427| 0|} 428| | 429| |#pragma mark - FB Apps Installed 430| | 431| |+ (BOOL)isFacebookAppInstalled 432| 0|{ 433| 0| dispatch_once(&checkIfFacebookAppInstalledToken, ^{ 434| 0| [FBSDKInternalUtility checkRegisteredCanOpenURLScheme:FBSDK_CANOPENURL_FACEBOOK]; 435| 0| }); 436| 0| return [self _canOpenURLScheme:FBSDK_CANOPENURL_FACEBOOK]; 437| 0|} 438| | 439| |+ (BOOL)isMessengerAppInstalled 440| 0|{ 441| 0| dispatch_once(&checkIfMessengerAppInstalledToken, ^{ 442| 0| [FBSDKInternalUtility checkRegisteredCanOpenURLScheme:FBSDK_CANOPENURL_MESSENGER]; 443| 0| }); 444| 0| return [self _canOpenURLScheme:FBSDK_CANOPENURL_MESSENGER]; 445| 0|} 446| | 447| |+ (BOOL)isMSQRDPlayerAppInstalled 448| 0|{ 449| 0| dispatch_once(&checkIfMSQRDPlayerAppInstalledToken, ^{ 450| 0| [FBSDKInternalUtility checkRegisteredCanOpenURLScheme:FBSDK_CANOPENURL_MSQRD_PLAYER]; 451| 0| }); 452| 0| return [self _canOpenURLScheme:FBSDK_CANOPENURL_MSQRD_PLAYER]; 453| 0|} 454| | 455| |#pragma mark - Helper Methods 456| | 457| |+ (BOOL)_canOpenURLScheme:(NSString *)scheme 458| 0|{ 459| 0| scheme = [FBSDKTypeUtility coercedToStringValue:scheme]; 460| 0| if (!scheme) { 461| 0| return NO; 462| 0| } 463| | 464| 0| NSURLComponents *components = [NSURLComponents new]; 465| 0| @try { 466| 0| components.scheme = scheme; 467| 0| } @catch (NSException *exception) { 468| 0| NSString *msg = [NSString stringWithFormat:@"Invalid URL scheme provided: %@", scheme]; 469| 0| [self.loggerType singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors 470| 0| logEntry:msg]; 471| 0| return NO; 472| 0| } 473| | 474| 0| components.path = @"/"; 475| 0| return [[UIApplication sharedApplication] canOpenURL:components.URL]; 476| 0|} 477| | 478| |+ (void)validateAppID 479| 0|{ 480| 0| [self.sharedUtility validateConfiguration]; 481| 0| if (![FBSDKSettings appID]) { 482| 0| NSString *reason = @"App ID not found. Add a string value with your app ID for the key " 483| 0| @"FacebookAppID to the Info.plist or call [FBSDKSettings setAppID:]."; 484| 0| @throw [NSException exceptionWithName:@"InvalidOperationException" reason:reason userInfo:nil]; 485| 0| } 486| 0|} 487| | 488| |+ (NSString *)validateRequiredClientAccessToken 489| 0|{ 490| 0| [self.sharedUtility validateConfiguration]; 491| 0| if (![FBSDKSettings clientToken]) { 492| 0| NSString *reason = @"ClientToken is required to be set for this operation. " 493| 0| @"Set the FacebookClientToken in the Info.plist or call [FBSDKSettings setClientToken:]. " 494| 0| @"You can find your client token in your App Settings -> Advanced."; 495| 0| @throw [NSException exceptionWithName:@"InvalidOperationException" reason:reason userInfo:nil]; 496| 0| } 497| 0| return [NSString stringWithFormat:@"%@|%@", [FBSDKSettings appID], [FBSDKSettings clientToken]]; 498| 0|} 499| | 500| |+ (void)validateURLSchemes 501| 0|{ 502| 0| [self validateAppID]; 503| 0| NSString *defaultUrlScheme = [NSString stringWithFormat:@"fb%@%@", [FBSDKSettings appID], [FBSDKSettings appURLSchemeSuffix] ?: @""]; 504| 0| if (![self isRegisteredURLScheme:defaultUrlScheme]) { 505| 0| NSString *reason = [NSString stringWithFormat:@"%@ is not registered as a URL scheme. Please add it in your Info.plist", defaultUrlScheme]; 506| 0| @throw [NSException exceptionWithName:@"InvalidOperationException" reason:reason userInfo:nil]; 507| 0| } 508| 0|} 509| | 510| |+ (void)validateFacebookReservedURLSchemes 511| 0|{ 512| 0| for (NSString *fbUrlScheme in @[FBSDK_CANOPENURL_FACEBOOK, FBSDK_CANOPENURL_MESSENGER, FBSDK_CANOPENURL_FBAPI, FBSDK_CANOPENURL_SHARE_EXTENSION]) { 513| 0| if ([self isRegisteredURLScheme:fbUrlScheme]) { 514| 0| NSString *reason = [NSString stringWithFormat:@"%@ is registered as a URL scheme. Please move the entry from CFBundleURLSchemes in your Info.plist to LSApplicationQueriesSchemes. If you are trying to resolve \"canOpenURL: failed\" warnings, those only indicate that the Facebook app is not installed on your device or simulator and can be ignored.", fbUrlScheme]; 515| 0| @throw [NSException exceptionWithName:@"InvalidOperationException" reason:reason userInfo:nil]; 516| 0| } 517| 0| } 518| 0|} 519| | 520| |- (UIWindow *)findWindow 521| 0|{ 522| 0| #pragma clang diagnostic push 523| 0| #pragma clang diagnostic ignored "-Wdeprecated-declarations" 524| 0| UIWindow *topWindow = [UIApplication sharedApplication].keyWindow; 525| 0| #pragma clang diagnostic pop 526| 0| if (topWindow == nil || topWindow.windowLevel < UIWindowLevelNormal) { 527| 0| for (UIWindow *window in [UIApplication sharedApplication].windows) { 528| 0| if (window.windowLevel >= topWindow.windowLevel && !window.isHidden) { 529| 0| topWindow = window; 530| 0| } 531| 0| } 532| 0| } 533| | 534| 0| if (topWindow != nil) { 535| 0| return topWindow; 536| 0| } 537| | 538| | // Find active key window from UIScene 539| 0| if (@available(iOS 13.0, tvOS 13, *)) { 540| 0| NSSet *scenes = [[UIApplication sharedApplication] valueForKey:@"connectedScenes"]; 541| 0| for (id scene in scenes) { 542| 0| id activationState = [scene valueForKeyPath:@"activationState"]; 543| 0| BOOL isActive = activationState != nil && [activationState integerValue] == 0; 544| 0| if (isActive) { 545| 0| Class WindowScene = NSClassFromString(@"UIWindowScene"); 546| 0| if ([scene isKindOfClass:WindowScene]) { 547| 0| NSArray *windows = [scene valueForKeyPath:@"windows"]; 548| 0| for (UIWindow *window in windows) { 549| 0| if (window.isKeyWindow) { 550| 0| return window; 551| 0| } else if (window.windowLevel >= topWindow.windowLevel && !window.isHidden) { 552| 0| topWindow = window; 553| 0| } 554| 0| } 555| 0| } 556| 0| } 557| 0| } 558| 0| } 559| | 560| 0| if (topWindow == nil) { 561| 0| [self.class.loggerType singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors 562| 0| logEntry:@"Unable to find a valid UIWindow"]; 563| 0| } 564| 0| return topWindow; 565| 0|} 566| | 567| |+ (UIViewController *)topMostViewController 568| 0|{ 569| 0| UIWindow *keyWindow = [self.sharedUtility findWindow]; 570| | // SDK expects a key window at this point, if it is not, make it one 571| 0| if (keyWindow != nil && !keyWindow.isKeyWindow) { 572| 0| NSString *msg = [NSString stringWithFormat:@"Unable to obtain a key window, marking %@ as keyWindow", keyWindow.description]; 573| 0| [self.loggerType singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors 574| 0| logEntry:msg]; 575| 0| [keyWindow makeKeyWindow]; 576| 0| } 577| | 578| 0| UIViewController *topController = keyWindow.rootViewController; 579| 0| while (topController.presentedViewController) { 580| 0| topController = topController.presentedViewController; 581| 0| } 582| 0| return topController; 583| 0|} 584| | 585| |#if !TARGET_OS_TV 586| |+ (UIInterfaceOrientation)statusBarOrientation 587| 0|{ 588| 0|#if __IPHONE_OS_VERSION_MAX_ALLOWED >= 130000 589| 0| if (@available(iOS 13.0, *)) { 590| 0| return [self.sharedUtility findWindow].windowScene.interfaceOrientation; 591| 0| } else { 592| 0| return UIInterfaceOrientationUnknown; 593| 0| } 594| |#else 595| | return UIApplication.sharedApplication.statusBarOrientation; 596| |#endif 597| 0|} 598| | 599| |#endif 600| | 601| |+ (NSString *)hexadecimalStringFromData:(NSData *)data 602| 0|{ 603| 0| NSUInteger dataLength = data.length; 604| 0| if (dataLength == 0) { 605| 0| return nil; 606| 0| } 607| | 608| 0| const unsigned char *dataBuffer = data.bytes; 609| 0| NSMutableString *hexString = [NSMutableString stringWithCapacity:(dataLength * 2)]; 610| 0| for (int i = 0; i < dataLength; ++i) { 611| 0| [hexString appendFormat:@"%02x", dataBuffer[i]]; 612| 0| } 613| 0| return [hexString copy]; 614| 0|} 615| | 616| |+ (BOOL)isRegisteredURLScheme:(NSString *)urlScheme 617| 0|{ 618| 0| [self.sharedUtility validateConfiguration]; 619| | 620| 0| static NSArray *urlTypes = nil; 621| 0| dispatch_once(&fetchUrlSchemesToken, ^{ 622| 0| urlTypes = [self.infoDictionaryProvider.infoDictionary valueForKey:@"CFBundleURLTypes"]; 623| 0| }); 624| 0| for (NSDictionary *urlType in urlTypes) { 625| 0| NSArray *urlSchemes = [urlType valueForKey:@"CFBundleURLSchemes"]; 626| 0| if ([urlSchemes containsObject:urlScheme]) { 627| 0| return YES; 628| 0| } 629| 0| } 630| 0| return NO; 631| 0|} 632| | 633| |+ (void)checkRegisteredCanOpenURLScheme:(NSString *)urlScheme 634| 0|{ 635| 0| static NSMutableSet *checkedSchemes = nil; 636| 0| dispatch_once(&checkRegisteredCanOpenUrlSchemesToken, ^{ 637| 0| checkedSchemes = [NSMutableSet set]; 638| 0| }); 639| | 640| 0| @synchronized(self) { 641| 0| if ([checkedSchemes containsObject:urlScheme]) { 642| 0| return; 643| 0| } else { 644| 0| [checkedSchemes addObject:urlScheme]; 645| 0| } 646| 0| } 647| | 648| 0| if (![self isRegisteredCanOpenURLScheme:urlScheme]) { 649| 0| NSString *reason = [NSString stringWithFormat:@"%@ is missing from your Info.plist under LSApplicationQueriesSchemes and is required.", urlScheme]; 650| 0| [self.loggerType singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors logEntry:reason]; 651| 0| } 652| 0|} 653| | 654| |+ (BOOL)isRegisteredCanOpenURLScheme:(NSString *)urlScheme 655| 0|{ 656| 0| static NSArray *schemes = nil; 657| 0| dispatch_once(&fetchApplicationQuerySchemesToken, ^{ 658| 0| schemes = [self.infoDictionaryProvider.infoDictionary valueForKey:@"LSApplicationQueriesSchemes"]; 659| 0| }); 660| | 661| 0| return [schemes containsObject:urlScheme]; 662| 0|} 663| | 664| |+ (BOOL)isPublishPermission:(NSString *)permission 665| 0|{ 666| 0| return [permission hasPrefix:@"publish"] 667| 0| || [permission hasPrefix:@"manage"] 668| 0| || [permission isEqualToString:@"ads_management"] 669| 0| || [permission isEqualToString:@"create_event"] 670| 0| || [permission isEqualToString:@"rsvp_event"]; 671| 0|} 672| | 673| |+ (BOOL)isUnity 674| 0|{ 675| 0| NSString *userAgentSuffix = [FBSDKSettings userAgentSuffix]; 676| 0| if (userAgentSuffix != nil && [userAgentSuffix rangeOfString:@"Unity"].location != NSNotFound) { 677| 0| return YES; 678| 0| } 679| 0| return NO; 680| 0|} 681| | 682| |- (void)validateConfiguration 683| 0|{ 684| 0|#if DEBUG 685| 0| if (!self.isConfigured) { 686| 0| static NSString *const reason = @"As of v9.0, you must initialize the SDK prior to calling any methods or setting any properties. " 687| 0| "You can do this by calling `FBSDKApplicationDelegate`'s `application:didFinishLaunchingWithOptions:` method. " 688| 0| "Learn more: https://developers.facebook.com/docs/ios/getting-started"; 689| 0| @throw [NSException exceptionWithName:@"InvalidOperationException" reason:reason userInfo:nil]; 690| 0| } 691| 0|#endif 692| 0|} 693| | 694| |#pragma mark - Testability 695| | 696| |#if DEBUG 697| | #if FBSDKTEST 698| | 699| |+ (void)reset 700| 0|{ 701| 0| if (fetchApplicationQuerySchemesToken) { 702| 0| fetchApplicationQuerySchemesToken = 0; 703| 0| } 704| 0| if (checkRegisteredCanOpenUrlSchemesToken) { 705| 0| checkRegisteredCanOpenUrlSchemesToken = 0; 706| 0| } 707| 0| if (checkIfFacebookAppInstalledToken) { 708| 0| checkIfFacebookAppInstalledToken = 0; 709| 0| } 710| 0| if (checkIfMessengerAppInstalledToken) { 711| 0| checkIfMessengerAppInstalledToken = 0; 712| 0| } 713| 0| if (checkIfMSQRDPlayerAppInstalledToken) { 714| 0| checkIfMSQRDPlayerAppInstalledToken = 0; 715| 0| } 716| 0| if (checkOperatingSystemVersionToken) { 717| 0| checkOperatingSystemVersionToken = 0; 718| 0| } 719| 0| if (fetchUrlSchemesToken) { 720| 0| fetchUrlSchemesToken = 0; 721| 0| } 722| 0| if (sharedUtilityNonce) { 723| 0| sharedUtilityNonce = 0; 724| 0| } 725| 0| _infoDictionaryProvider = nil; 726| 0|} 727| | 728| | #endif 729| |#endif 730| | 731| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKLogger.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKLogger.h" 20| | 21| |#import "FBSDKCoreKitBasicsImport.h" 22| |#import "FBSDKInternalUtility.h" 23| |#import "FBSDKSettings.h" 24| | 25| |static NSUInteger g_serialNumberCounter = 1111; 26| |static NSMutableDictionary *g_stringsToReplace = nil; 27| |static NSMutableDictionary *g_startTimesWithTags = nil; 28| | 29| |@interface FBSDKLogger () 30| | 31| |@property (nonatomic, readonly, strong) NSMutableString *internalContents; 32| | 33| |@end 34| | 35| |@implementation FBSDKLogger 36| | 37| |// Lifetime 38| | 39| |- (instancetype)initWithLoggingBehavior:(NSString *)loggingBehavior 40| 0|{ 41| 0| if ((self = [super init])) { 42| 0| _active = [FBSDKSettings.loggingBehaviors containsObject:loggingBehavior]; 43| 0| _loggingBehavior = loggingBehavior; 44| 0| if (_active) { 45| 0| _internalContents = [NSMutableString new]; 46| 0| _loggerSerialNumber = [FBSDKLogger generateSerialNumber]; 47| 0| } 48| 0| } 49| | 50| 0| return self; 51| 0|} 52| | 53| |// Public properties 54| | 55| |- (NSString *)contents 56| 0|{ 57| 0| return _internalContents; 58| 0|} 59| | 60| |- (void)setContents:(NSString *)contents 61| 0|{ 62| 0| if (_active) { 63| 0| _internalContents = [NSMutableString stringWithString:contents]; 64| 0| } 65| 0|} 66| | 67| |// Public instance methods 68| | 69| |- (void)appendString:(NSString *)string 70| 0|{ 71| 0| if (_active) { 72| 0| [_internalContents appendString:string]; 73| 0| } 74| 0|} 75| | 76| |- (void)appendFormat:(NSString *)formatString, ... 77| 0|{ 78| 0| if (_active) { 79| 0| va_list vaArguments; 80| 0| va_start(vaArguments, formatString); 81| 0| NSString *logString = [[NSString alloc] initWithFormat:formatString arguments:vaArguments]; 82| 0| va_end(vaArguments); 83| | 84| 0| [self appendString:logString]; 85| 0| } 86| 0|} 87| | 88| |- (void)appendKey:(NSString *)key value:(NSString *)value 89| 0|{ 90| 0| if (_active && value.length) { 91| 0| [_internalContents appendFormat:@" %@:\t%@\n", key, value]; 92| 0| } 93| 0|} 94| | 95| |- (void)emitToNSLog 96| 0|{ 97| 0| if (_active) { 98| 0| for (NSString *key in [g_stringsToReplace keyEnumerator]) { 99| 0| [_internalContents replaceOccurrencesOfString:key 100| 0| withString:g_stringsToReplace[key] 101| 0| options:NSLiteralSearch 102| 0| range:NSMakeRange(0, _internalContents.length)]; 103| 0| } 104| | 105| | // Xcode 4.4 hangs on extremely long NSLog output (http://openradar.appspot.com/11972490). Truncate if needed. 106| 0| const int MAX_LOG_STRING_LENGTH = 10000; 107| 0| NSString *logString = _internalContents; 108| 0| if (_internalContents.length > MAX_LOG_STRING_LENGTH) { 109| 0| logString = [NSString stringWithFormat:@"TRUNCATED: %@", [_internalContents substringToIndex:MAX_LOG_STRING_LENGTH]]; 110| 0| } 111| 0| NSLog(@"FBSDKLog: %@", logString); 112| | 113| 0| [_internalContents setString:@""]; 114| 0| } 115| 0|} 116| | 117| |// Public static methods 118| | 119| |+ (NSUInteger)generateSerialNumber 120| 0|{ 121| 0| @synchronized(self) { 122| 0| return ++g_serialNumberCounter; 123| 0| } 124| 0|} 125| | 126| |+ (void)singleShotLogEntry:(NSString *)loggingBehavior 127| | logEntry:(NSString *)logEntry 128| 0|{ 129| 0| FBSDKLogger *logger = [[FBSDKLogger alloc] initWithLoggingBehavior:loggingBehavior]; 130| 0| [logger logEntry:logEntry]; 131| 0|} 132| | 133| |- (void)logEntry:(NSString *)logEntry 134| 0|{ 135| 0| if ([FBSDKSettings.loggingBehaviors containsObject:_loggingBehavior]) { 136| 0| [self appendString:logEntry]; 137| 0| [self emitToNSLog]; 138| 0| } 139| 0|} 140| | 141| |+ (void)singleShotLogEntry:(NSString *)loggingBehavior 142| | timestampTag:(NSObject *)timestampTag 143| | formatString:(NSString *)formatString, ... 144| 0|{ 145| 0| if ([FBSDKSettings.loggingBehaviors containsObject:loggingBehavior]) { 146| 0| va_list vaArguments; 147| 0| va_start(vaArguments, formatString); 148| 0| NSString *logString = [[NSString alloc] initWithFormat:formatString arguments:vaArguments]; 149| 0| va_end(vaArguments); 150| | 151| | // Start time of this "timestampTag" is stashed in the dictionary. 152| | // Treat the incoming object tag simply as an address, since it's only used to identify during lifetime. If 153| | // we send in as an object, the dictionary will try to copy it. 154| 0| NSNumber *tagAsNumber = @((unsigned long)(__bridge void *)timestampTag); 155| 0| NSNumber *startTimeNumber = g_startTimesWithTags[tagAsNumber]; 156| | 157| | // Only log if there's been an associated start time. 158| 0| if (startTimeNumber != nil) { 159| 0| uint64_t elapsed = [FBSDKInternalUtility currentTimeInMilliseconds] - startTimeNumber.unsignedLongLongValue; 160| 0| [g_startTimesWithTags removeObjectForKey:tagAsNumber]; // served its purpose, remove 161| | 162| | // Log string is appended with "%d msec", with nothing intervening. This gives the most control to the caller. 163| 0| logString = [NSString stringWithFormat:@"%@%llu msec", logString, elapsed]; 164| | 165| 0| [self singleShotLogEntry:loggingBehavior logEntry:logString]; 166| 0| } 167| 0| } 168| 0|} 169| | 170| |+ (void)registerCurrentTime:(NSString *)loggingBehavior 171| | withTag:(NSObject *)timestampTag 172| 0|{ 173| 0| if ([FBSDKSettings.loggingBehaviors containsObject:loggingBehavior]) { 174| 0| if (!g_startTimesWithTags) { 175| 0| g_startTimesWithTags = [NSMutableDictionary new]; 176| 0| } 177| | 178| 0| if (g_startTimesWithTags.count >= 1000) { 179| 0| [FBSDKLogger singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors logEntry: 180| 0| @"Unexpectedly large number of outstanding perf logging start times, something is likely wrong."]; 181| 0| } 182| | 183| 0| uint64_t currTime = [FBSDKInternalUtility currentTimeInMilliseconds]; 184| | 185| | // Treat the incoming object tag simply as an address, since it's only used to identify during lifetime. If 186| | // we send in as an object, the dictionary will try to copy it. 187| 0| unsigned long tagAsNumber = (unsigned long)(__bridge void *)timestampTag; 188| 0| [FBSDKTypeUtility dictionary:g_startTimesWithTags setObject:@(currTime) forKey:@(tagAsNumber)]; 189| 0| } 190| 0|} 191| | 192| |+ (void)registerStringToReplace:(NSString *)replace 193| | replaceWith:(NSString *)replaceWith 194| 0|{ 195| | // Strings sent in here never get cleaned up, but that's OK, don't ever expect too many. 196| | 197| 0| if (FBSDKSettings.loggingBehaviors.count > 0) { // otherwise there's no logging. 198| 0| if (!g_stringsToReplace) { 199| 0| g_stringsToReplace = [NSMutableDictionary new]; 200| 0| } 201| | 202| 0| [g_stringsToReplace setValue:replaceWith forKey:replace]; 203| 0| } 204| 0|} 205| | 206| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKLoggerFactory.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKLoggerFactory.h" 20| | 21| |#import 22| | 23| |#import "FBSDKLogger.h" 24| |#import "FBSDKLogger+Logging.h" 25| | 26| |NS_ASSUME_NONNULL_BEGIN 27| | 28| |@implementation FBSDKLoggerFactory 29| | 30| |- (id)createLoggerWithLoggingBehavior:(FBSDKLoggingBehavior)loggingBehavior 31| 0|{ 32| 0| return [[FBSDKLogger alloc] initWithLoggingBehavior:loggingBehavior]; 33| 0|} 34| | 35| |@end 36| | 37| |NS_ASSUME_NONNULL_END /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKMath.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |// 20| |// Based on Thomas Wang 32/64 bit mix hash 21| |// http://www.concentric.net/~Ttwang/tech/inthash.htm 22| |// 23| | 24| |#import "FBSDKMath.h" 25| | 26| |#import 27| | 28| |@implementation FBSDKMath 29| | 30| |#pragma mark - Class Methods 31| | 32| |+ (CGSize)ceilForSize:(CGSize)value 33| 0|{ 34| 0| return CGSizeMake(ceilf(value.width), ceilf(value.height)); 35| 0|} 36| | 37| |+ (CGSize)floorForSize:(CGSize)value 38| 0|{ 39| 0| return CGSizeMake(floorf(value.width), floorf(value.height)); 40| 0|} 41| | 42| |+ (NSUInteger)hashWithInteger:(NSUInteger)value 43| 0|{ 44| 0| return [self hashWithPointer:(void *)value]; 45| 0|} 46| | 47| |+ (NSUInteger)hashWithInteger:(NSUInteger)value1 andInteger:(NSUInteger)value2 48| 0|{ 49| 0| return [self hashWithLong:(((unsigned long long)value1) << 32 | value2)]; 50| 0|} 51| | 52| |+ (NSUInteger)hashWithIntegerArray:(NSUInteger *)values count:(NSUInteger)count 53| 0|{ 54| 0| if (count == 0) { 55| 0| return 0; 56| 0| } 57| 0| NSUInteger hash = values[0]; 58| 0| for (NSUInteger i = 1; i < count; ++i) { 59| 0| hash = [self hashWithInteger:hash andInteger:values[i]]; 60| 0| } 61| 0| return hash; 62| 0|} 63| | 64| |+ (NSUInteger)hashWithLong:(unsigned long long)value 65| 0|{ 66| 0| value = (~value) + (value << 18); // key = (key << 18) - key - 1; 67| 0| value ^= (value >> 31); 68| 0| value *= 21; // key = (key + (key << 2)) + (key << 4); 69| 0| value ^= (value >> 11); 70| 0| value += (value << 6); 71| 0| value ^= (value >> 22); 72| 0| return (NSUInteger)value; 73| 0|} 74| | 75| |+ (NSUInteger)hashWithPointer:(const void *)value 76| 0|{ 77| 0| NSUInteger hash = (NSUInteger)value; 78| |#if !TARGET_RT_64_BIT 79| | hash = ~hash + (hash << 15); // key = (key << 15) - key - 1; 80| | hash ^= (hash >> 12); 81| | hash += (hash << 2); 82| | hash ^= (hash >> 4); 83| | hash *= 2057; // key = (key + (key << 3)) + (key << 11); 84| | hash ^= (hash >> 16); 85| |#else 86| 0| hash += ~hash + (hash << 21); // key = (key << 21) - key - 1; 87| 0| hash ^= (hash >> 24); 88| 0| hash = (hash + (hash << 3)) + (hash << 8); 89| 0| hash ^= (hash >> 14); 90| 0| hash = (hash + (hash << 2)) + (hash << 4); // key * 21 91| 0| hash ^= (hash >> 28); 92| 0| hash += (hash << 31); 93| 0|#endif 94| 0| return hash; 95| 0|} 96| | 97| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKObjectDecoder.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKObjectDecoder.h" 20| | 21| |@interface FBSDKObjectDecoder () 22| |@property (nonatomic, strong) NSKeyedUnarchiver *unarchiver; 23| |@end 24| | 25| |@implementation FBSDKObjectDecoder 26| | 27| |- (instancetype)initWith:(NSKeyedUnarchiver *)unarchiver 28| 0|{ 29| 0| self = [super init]; 30| 0| if (self) { 31| 0| self.unarchiver = unarchiver; 32| 0| } 33| 0| return self; 34| 0|} 35| | 36| |- (id)decodeObjectOfClass:(Class)aClass forKey:(NSString *)key 37| 0|{ 38| 0| return [self.unarchiver decodeObjectOfClass:aClass forKey:key]; 39| 0|} 40| | 41| |- (id)decodeObjectOfClasses:(NSSet *)classes forKey:(NSString *)key 42| 0|{ 43| 0| return [self.unarchiver decodeObjectOfClasses:classes forKey:key]; 44| 0|} 45| | 46| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKSettings+Internal.h: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#if SWIFT_PACKAGE 20| |#import "FBSDKAdvertisingTrackingStatus.h" 21| | #import "FBSDKSettings.h" 22| |#else 23| |#import 24| | #import 25| |#endif 26| | 27| 0|#define DATA_PROCESSING_OPTIONS @"data_processing_options" 28| 0|#define DATA_PROCESSING_OPTIONS_COUNTRY @"data_processing_options_country" 29| 0|#define DATA_PROCESSING_OPTIONS_STATE @"data_processing_options_state" 30| | 31| |@protocol FBSDKTokenCaching; 32| |@protocol FBSDKDataPersisting; 33| |@protocol FBSDKAppEventsConfigurationProviding; 34| |@protocol FBSDKInfoDictionaryProviding; 35| |@protocol FBSDKEventLogging; 36| | 37| |@interface FBSDKSettings (Internal) 38| | 39| |@property (class, nullable, nonatomic, readonly, copy) NSString *graphAPIDebugParamValue; 40| | 41| |@property (nonatomic, copy, null_resettable) NSString *graphAPIVersion; 42| | 43| |// used by Unity. 44| |@property (class, nullable, nonatomic, copy) NSString *userAgentSuffix; 45| | 46| |@property (class, nonnull, readonly) FBSDKSettings *sharedSettings; 47| |@property (nonatomic) BOOL shouldUseTokenOptimizations; 48| | 49| |+ (void)configureWithStore:(nonnull id)store 50| |appEventsConfigurationProvider:(nonnull Class)provider 51| | infoDictionaryProvider:(nonnull id)infoDictionaryProvider 52| | eventLogger:(nonnull id)eventLogger 53| |NS_SWIFT_NAME(configure(store:appEventsConfigurationProvider:infoDictionaryProvider:eventLogger:)); 54| | 55| |+ (nullable NSObject *)tokenCache; 56| | 57| |+ (void)setTokenCache:(nullable NSObject *)tokenCache; 58| | 59| |+ (FBSDKAdvertisingTrackingStatus)advertisingTrackingStatus; 60| | 61| |+ (void)setAdvertiserTrackingStatus:(FBSDKAdvertisingTrackingStatus)status; 62| | 63| |+ (nullable NSDictionary *)dataProcessingOptions; 64| | 65| |+ (BOOL)isDataProcessingRestricted; 66| | 67| | 68| |+ (void)recordSetAdvertiserTrackingEnabled; 69| | 70| |+ (BOOL)isEventDelayTimerExpired; 71| | 72| |+ (BOOL)isSetATETimeExceedsInstallTime; 73| | 74| |+ (NSDate *_Nullable)getInstallTimestamp; 75| | 76| |+ (NSDate *_Nullable)getSetAdvertiserTrackingEnabledTimestamp; 77| | 78| |- (void)recordInstall; 79| | 80| |- (void)logWarnings; 81| | 82| |- (void)logIfSDKSettingsChanged; 83| | 84| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKSwizzler.h: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import 20| | 21| |// Cast to turn things that are not ids into NSMapTable keys 22| 0|#define MAPTABLE_ID(x) (__bridge id)((void *)x) 23| | 24| |#pragma clang diagnostic push 25| |#pragma clang diagnostic ignored "-Wstrict-prototypes" 26| | 27| |typedef void (^swizzleBlock)(); 28| | 29| |#pragma clang diagnostic pop 30| | 31| |// Rename to avoid duplicate symbol errors 32| |NS_SWIFT_NAME(Swizzler) 33| |@interface FBSDKSwizzler : NSObject 34| | 35| |+ (void)swizzleSelector:(SEL)aSelector onClass:(Class)aClass withBlock:(swizzleBlock)block named:(NSString *)aName; 36| |+ (void)unswizzleSelector:(SEL)aSelector onClass:(Class)aClass named:(NSString *)aName; 37| |+ (void)printSwizzles; 38| | 39| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKSwizzler.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKSwizzler.h" 20| | 21| |#import 22| | 23| 0|#define MIN_ARGS 2 24| 0|#define MAX_ARGS 5 25| | 26| |#define FB_FIND_SWIZZLE \ 27| 0| FBSDKSwizzlingOnClass *swizzlingOnClass = fb_findSwizzle(self, _cmd); \ 28| 0| FBSDKSwizzle *swizzle = swizzlingOnClass.bindingSwizzle; 29| | 30| |#define FB_REMOVE_SELECTOR \ 31| 0| [FBSDKSwizzler object:self ofClass:swizzlingOnClass.bindingClass removeSelector:_cmd]; 32| | 33| |@interface FBSDKSwizzle : NSObject 34| | 35| |@property (nonatomic, assign) Class class; 36| |@property (nonatomic, assign) SEL selector; 37| |@property (nonatomic, assign) IMP originalMethod; 38| |@property (nonatomic, assign) uint numArgs; 39| |@property (nonatomic, copy) NSMapTable *blocks; 40| | 41| |- (instancetype)initWithBlock:(swizzleBlock)aBlock 42| | named:(NSString *)aName 43| | forClass:(Class)aClass 44| | selector:(SEL)aSelector 45| | originalMethod:(IMP)aMethod 46| | withNumArgs:(uint)numArgs; 47| | 48| |@end 49| | 50| |@interface FBSDKSwizzlingOnClass : NSObject 51| | 52| |@property FBSDKSwizzle *bindingSwizzle; 53| |@property Class bindingClass; 54| | 55| |- (instancetype)initWithSwizzle:(FBSDKSwizzle *)aSwizzle 56| | class:(Class)aClass; 57| | 58| |@end 59| | 60| |@interface FBSDKSwizzler () 61| | 62| |+ (void)object:(id)anObject ofClass:(Class)aClass addSelector:(SEL)aSelector; 63| |+ (void)object:(id)anObject ofClass:(Class)aClass removeSelector:(SEL)aSelector; 64| |+ (BOOL)object:(id)anObject ofClass:(Class)aClass isCallingSelector:(SEL)aSelector; 65| | 66| |@end 67| | 68| |static NSMapTable *swizzles; 69| |static NSMutableSet *selectorCallingSet; 70| |static dispatch_queue_t swizzleQueue; 71| | 72| |static FBSDKSwizzlingOnClass *fb_findSwizzle(id self, SEL _cmd) 73| 0|{ 74| 0| Method aMethod = class_getInstanceMethod([self class], _cmd); 75| 0| Class this_class = [self class]; 76| 0| FBSDKSwizzle *swizzle = nil; 77| | 78| 0| if (![FBSDKSwizzler object:self ofClass:this_class isCallingSelector:_cmd]) { 79| 0| swizzle = (FBSDKSwizzle *)[swizzles objectForKey:MAPTABLE_ID(aMethod)]; 80| 0| } 81| | 82| 0| while (!swizzle && class_getSuperclass(this_class)) { 83| 0| this_class = class_getSuperclass(this_class); 84| 0| aMethod = class_getInstanceMethod(this_class, _cmd); 85| | 86| 0| if (![FBSDKSwizzler object:self ofClass:this_class isCallingSelector:_cmd]) { 87| 0| swizzle = (FBSDKSwizzle *)[swizzles objectForKey:MAPTABLE_ID(aMethod)]; 88| 0| } 89| 0| } 90| | 91| 0| if (swizzle) { 92| 0| [FBSDKSwizzler object:self ofClass:this_class addSelector:_cmd]; 93| 0| } 94| 0| FBSDKSwizzlingOnClass *swizzlingOnClass = [[FBSDKSwizzlingOnClass alloc] initWithSwizzle:swizzle 95| 0| class:this_class]; 96| 0| return swizzlingOnClass; 97| 0|} 98| | 99| |static void fb_swizzledMethod_2(id self, SEL _cmd) 100| 0|{ 101| 0| FB_FIND_SWIZZLE; 102| 0| if (swizzle) { 103| 0| ((void (*)(id, SEL))swizzle.originalMethod)(self, _cmd); 104| | 105| 0| NSEnumerator *blocks = [swizzle.blocks objectEnumerator]; 106| 0| swizzleBlock block; 107| 0| while ((block = [blocks nextObject])) { 108| 0| block(self, _cmd); 109| 0| } 110| 0| FB_REMOVE_SELECTOR; 111| 0| } 112| 0|} 113| | 114| |static void fb_swizzledMethod_3(id self, SEL _cmd, id arg) 115| 0|{ 116| 0| FB_FIND_SWIZZLE; 117| 0| if (swizzle) { 118| 0| ((void (*)(id, SEL, id))swizzle.originalMethod)(self, _cmd, arg); 119| | 120| 0| NSEnumerator *blocks = [swizzle.blocks objectEnumerator]; 121| 0| swizzleBlock block; 122| 0| while ((block = [blocks nextObject])) { 123| 0| block(self, _cmd, arg); 124| 0| } 125| 0| FB_REMOVE_SELECTOR; 126| 0| } 127| 0|} 128| | 129| |static void fb_swizzledMethod_4(id self, SEL _cmd, id arg, id arg2) 130| 0|{ 131| 0| FB_FIND_SWIZZLE; 132| 0| if (swizzle) { 133| 0| ((void (*)(id, SEL, id, id))swizzle.originalMethod)(self, _cmd, arg, arg2); 134| | 135| 0| NSEnumerator *blocks = [swizzle.blocks objectEnumerator]; 136| 0| swizzleBlock block; 137| 0| while ((block = [blocks nextObject])) { 138| 0| block(self, _cmd, arg, arg2); 139| 0| } 140| 0| FB_REMOVE_SELECTOR; 141| 0| } 142| 0|} 143| | 144| |static void fb_swizzledMethod_5(id self, SEL _cmd, id arg, id arg2, id arg3) 145| 0|{ 146| 0| FB_FIND_SWIZZLE; 147| 0| if (swizzle) { 148| 0| ((void (*)(id, SEL, id, id, id))swizzle.originalMethod)(self, _cmd, arg, arg2, arg3); 149| | 150| 0| NSEnumerator *blocks = [swizzle.blocks objectEnumerator]; 151| 0| swizzleBlock block; 152| 0| while ((block = [blocks nextObject])) { 153| 0| block(self, _cmd, arg, arg2, arg3); 154| 0| } 155| 0| FB_REMOVE_SELECTOR; 156| 0| } 157| 0|} 158| | 159| |static void fb_swizzleMethod_4_io(id self, SEL _cmd, NSInteger arg, id arg2) 160| 0|{ 161| 0| FB_FIND_SWIZZLE; 162| 0| if (swizzle) { 163| 0| ((void (*)(id, SEL, NSInteger, id))swizzle.originalMethod)(self, _cmd, arg, arg2); 164| | 165| 0| NSEnumerator *blocks = [swizzle.blocks objectEnumerator]; 166| 0| swizzleBlock block; 167| 0| while ((block = [blocks nextObject])) { 168| 0| block(self, _cmd, arg, arg2); 169| 0| } 170| 0| FB_REMOVE_SELECTOR; 171| 0| } 172| 0|} 173| | 174| |#pragma clang diagnostic push 175| |#pragma clang diagnostic ignored "-Wstrict-prototypes" 176| | 177| |static void (*fb_swizzledMethods[MAX_ARGS - MIN_ARGS + 1])() = {fb_swizzledMethod_2, fb_swizzledMethod_3, fb_swizzledMethod_4, fb_swizzledMethod_5}; 178| | 179| |#pragma clang diagnostic pop 180| | 181| |@implementation FBSDKSwizzler 182| | 183| |+ (void)initialize 184| 0|{ 185| 0| swizzles = [NSMapTable mapTableWithKeyOptions:(NSPointerFunctionsOpaqueMemory 186| 0| | NSPointerFunctionsOpaquePersonality) 187| 0| valueOptions:(NSPointerFunctionsStrongMemory 188| 0| | NSPointerFunctionsObjectPointerPersonality)]; 189| 0| selectorCallingSet = [NSMutableSet set]; 190| 0| swizzleQueue = dispatch_queue_create("com.facebook.swizzler", DISPATCH_QUEUE_SERIAL); 191| 0| [FBSDKSwizzler resolveConflict]; 192| 0|} 193| | 194| |+ (void)resolveConflict 195| 0|{ 196| 0| Class swizzler = objc_lookUpClass("MPSwizzler"); 197| 0| if (swizzler) { 198| 0| Method method = class_getClassMethod(swizzler, @selector(swizzleSelector:onClass:withBlock:named:)); 199| 0| Method newMethod = class_getClassMethod(self, @selector(swizzleSelector:onClass:withBlock:named:)); 200| 0| method_setImplementation(method, method_getImplementation(newMethod)); 201| 0| } 202| 0|} 203| | 204| |+ (void)printSwizzles 205| 0|{ 206| 0| NSEnumerator *en = [swizzles objectEnumerator]; 207| 0| FBSDKSwizzle *swizzle; 208| 0| while ((swizzle = (FBSDKSwizzle *)[en nextObject])) { 209| 0| NSLog(@"%@", swizzle); 210| 0| } 211| 0|} 212| | 213| |+ (FBSDKSwizzle *)swizzleForMethod:(Method)aMethod 214| 0|{ 215| 0| return (FBSDKSwizzle *)[swizzles objectForKey:MAPTABLE_ID(aMethod)]; 216| 0|} 217| | 218| |+ (void)removeSwizzleForMethod:(Method)aMethod 219| 0|{ 220| 0| [swizzles removeObjectForKey:MAPTABLE_ID(aMethod)]; 221| 0|} 222| | 223| |+ (void)setSwizzle:(FBSDKSwizzle *)swizzle forMethod:(Method)aMethod 224| 0|{ 225| 0| [swizzles setObject:swizzle forKey:MAPTABLE_ID(aMethod)]; 226| 0|} 227| | 228| |+ (BOOL)isLocallyDefinedMethod:(Method)aMethod onClass:(Class)aClass 229| 0|{ 230| 0| uint count; 231| 0| BOOL isLocal = NO; 232| 0| Method *methods = class_copyMethodList(aClass, &count); 233| 0| for (NSUInteger i = 0; i < count; i++) { 234| 0| if (aMethod == methods[i]) { 235| 0| isLocal = YES; 236| 0| break; 237| 0| } 238| 0| } 239| 0| free(methods); 240| 0| return isLocal; 241| 0|} 242| | 243| |+ (void)swizzleSelector:(SEL)aSelector onClass:(Class)aClass withBlock:(swizzleBlock)aBlock named:(NSString *)aName 244| 0|{ 245| 0| [self swizzleSelector:aSelector onClass:aClass withBlock:aBlock named:aName async:YES]; 246| 0|} 247| | 248| |+ (void)swizzleSelector:(SEL)aSelector onClass:(Class)aClass withBlock:(swizzleBlock)aBlock named:(NSString *)aName async:(BOOL)async 249| 0|{ 250| 0| [self swizzleSelectorWithBlock:^{ 251| 0| @try { 252| 0| Method aMethod = class_getInstanceMethod(aClass, aSelector); 253| 0| if (aMethod) { 254| 0| uint numArgs = method_getNumberOfArguments(aMethod); 255| 0| if (numArgs >= MIN_ARGS && numArgs <= MAX_ARGS) { 256| 0| BOOL isLocal = [FBSDKSwizzler isLocallyDefinedMethod:aMethod onClass:aClass]; 257| 0| IMP swizzledMethod = (IMP)fb_swizzledMethods[numArgs - 2]; 258| | // Check whether the first parameter is integer 259| 0| if (4 == numArgs) { 260| 0| char *type = method_copyArgumentType(aMethod, 2); 261| 0| NSString *firstType = [NSString stringWithCString:type encoding:NSUTF8StringEncoding]; 262| 0| NSString *integerTypes = @"islq"; 263| 0| if ([integerTypes containsString:firstType.lowercaseString]) { 264| 0| swizzledMethod = (IMP)fb_swizzleMethod_4_io; 265| 0| } 266| 0| free(type); 267| 0| } 268| | 269| 0| FBSDKSwizzle *swizzle = [FBSDKSwizzler swizzleForMethod:aMethod]; 270| | 271| 0| if (isLocal) { 272| 0| if (!swizzle) { 273| 0| IMP originalMethod = method_getImplementation(aMethod); 274| | 275| | // Replace the local implementation of this method with the swizzled one 276| 0| method_setImplementation(aMethod, swizzledMethod); 277| | 278| | // Create and add the swizzle 279| 0| swizzle = [[FBSDKSwizzle alloc] initWithBlock:aBlock named:aName forClass:aClass selector:aSelector originalMethod:originalMethod withNumArgs:numArgs]; 280| 0| [FBSDKSwizzler setSwizzle:swizzle forMethod:aMethod]; 281| 0| } else { 282| 0| [swizzle.blocks setObject:aBlock forKey:aName]; 283| 0| } 284| 0| } else { 285| 0| IMP originalMethod = swizzle ? swizzle.originalMethod : method_getImplementation(aMethod); 286| | 287| | // Add the swizzle as a new local method on the class. 288| 0| if (!class_addMethod(aClass, aSelector, swizzledMethod, method_getTypeEncoding(aMethod))) { 289| 0| return; 290| 0| } 291| | // Now re-get the Method, it should be the one we just added. 292| 0| Method newMethod = class_getInstanceMethod(aClass, aSelector); 293| 0| if (aMethod == newMethod) { 294| 0| return; 295| 0| } 296| | 297| 0| FBSDKSwizzle *newSwizzle = [[FBSDKSwizzle alloc] initWithBlock:aBlock named:aName forClass:aClass selector:aSelector originalMethod:originalMethod withNumArgs:numArgs]; 298| 0| [FBSDKSwizzler setSwizzle:newSwizzle forMethod:newMethod]; 299| 0| } 300| 0| } 301| 0| } 302| 0| } @catch (NSException *exception) { 303| 0| NSLog(@"Fail to swizzle selector. Exception reason: %@", exception.reason); 304| 0| } 305| 0| } 306| 0| async:async]; 307| 0|} 308| | 309| |/* 310| | Remove the named swizzle from the given class/selector. If aName is nil, remove all 311| | swizzles for this class/selector 312| |*/ 313| |+ (void)unswizzleSelector:(SEL)aSelector onClass:(Class)aClass named:(NSString *)aName 314| 0|{ 315| 0| @try { 316| 0| Method aMethod = class_getInstanceMethod(aClass, aSelector); 317| 0| FBSDKSwizzle *swizzle = [FBSDKSwizzler swizzleForMethod:aMethod]; 318| 0| if (swizzle) { 319| 0| if (aName) { 320| 0| [swizzle.blocks removeObjectForKey:aName]; 321| 0| } 322| 0| if (!aName || swizzle.blocks.count == 0) { 323| 0| method_setImplementation(aMethod, swizzle.originalMethod); 324| 0| [FBSDKSwizzler removeSwizzleForMethod:aMethod]; 325| 0| } 326| 0| } 327| 0| } @catch (NSException *exception) { 328| 0| NSLog(@"Fail to remove the named swizzle from given class/selector. Exception reason: %@", exception.reason); 329| 0| } 330| 0|} 331| | 332| |+ (void)object:(id)anObject ofClass:(Class)aClass addSelector:(SEL)aSelector 333| 0|{ 334| 0| NSString *objectClassSelectorString = [NSString stringWithFormat:@"%p %@ %@", anObject, NSStringFromClass(aClass), NSStringFromSelector(aSelector)]; 335| 0| @synchronized(selectorCallingSet) { 336| 0| [selectorCallingSet addObject:objectClassSelectorString]; 337| 0| } 338| 0|} 339| | 340| |+ (void)object:(id)anObject ofClass:(Class)aClass removeSelector:(SEL)aSelector 341| 0|{ 342| 0| NSString *objectClassSelectorString = [NSString stringWithFormat:@"%p %@ %@", anObject, NSStringFromClass(aClass), NSStringFromSelector(aSelector)]; 343| 0| @synchronized(selectorCallingSet) { 344| 0| [selectorCallingSet removeObject:objectClassSelectorString]; 345| 0| } 346| 0|} 347| | 348| |+ (BOOL)object:(id)anObject ofClass:(Class)aClass isCallingSelector:(SEL)aSelector 349| 0|{ 350| 0| NSString *objectClassSelectorString = [NSString stringWithFormat:@"%p %@ %@", anObject, NSStringFromClass(aClass), NSStringFromSelector(aSelector)]; 351| 0| if ([selectorCallingSet containsObject:objectClassSelectorString]) { 352| 0| return YES; 353| 0| } 354| 0| return NO; 355| 0|} 356| | 357| |+ (void)swizzleSelectorWithBlock:(dispatch_block_t)block async:(BOOL)async 358| 0|{ 359| 0| if (async) { 360| 0| dispatch_async(swizzleQueue, block); 361| 0| } else { 362| 0| block(); 363| 0| } 364| 0|} 365| | 366| |#if DEBUG 367| | #if FBSDKTEST 368| | 369| |+ (void)setSwizzleQueue:(dispatch_queue_t)queue 370| 0|{ 371| 0| swizzleQueue = queue; 372| 0|} 373| | 374| | #endif 375| |#endif 376| | 377| |@end 378| | 379| |@implementation FBSDKSwizzle 380| | 381| |- (instancetype)init 382| 0|{ 383| 0| if (self = [super init]) { 384| 0| self.blocks = [NSMapTable mapTableWithKeyOptions:(NSPointerFunctionsStrongMemory 385| 0| | NSPointerFunctionsObjectPersonality) 386| 0| valueOptions:(NSPointerFunctionsStrongMemory 387| 0| | NSPointerFunctionsObjectPointerPersonality)]; 388| 0| } 389| 0| return self; 390| 0|} 391| | 392| |- (instancetype)initWithBlock:(swizzleBlock)aBlock 393| | named:(NSString *)aName 394| | forClass:(Class)aClass 395| | selector:(SEL)aSelector 396| | originalMethod:(IMP)aMethod 397| | withNumArgs:(uint)numArgs 398| 0|{ 399| 0| if (self = [self init]) { 400| 0| self.class = aClass; 401| 0| self.selector = aSelector; 402| 0| self.numArgs = numArgs; 403| 0| self.originalMethod = aMethod; 404| 0| [_blocks setObject:aBlock forKey:aName]; 405| 0| } 406| 0| return self; 407| 0|} 408| | 409| |- (NSString *)description 410| 0|{ 411| 0| NSString *descriptors = @""; 412| 0| NSString *key; 413| 0| NSEnumerator *keys = [_blocks keyEnumerator]; 414| 0| while ((key = [keys nextObject])) { 415| 0| descriptors = [descriptors stringByAppendingFormat:@"\t%@ : %@\n", key, [_blocks objectForKey:key]]; 416| 0| } 417| 0| return [NSString stringWithFormat:@"Swizzle on %@::%@ [\n%@]", NSStringFromClass(self.class), 418| 0| NSStringFromSelector(self.selector), descriptors]; 419| 0|} 420| | 421| |@end 422| | 423| |@implementation FBSDKSwizzlingOnClass 424| | 425| |- (instancetype)initWithSwizzle:(FBSDKSwizzle *)aSwizzle 426| | class:(Class)aClass 427| 0|{ 428| 0| if (self = [super init]) { 429| 0| self.bindingSwizzle = aSwizzle; 430| 0| self.bindingClass = aClass; 431| 0| } 432| 0| return self; 433| 0|} 434| | 435| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKUnarchiverProvider.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKUnarchiverProvider.h" 20| | 21| |#import "FBSDKObjectDecoder.h" 22| | 23| |@implementation FBSDKUnarchiverProvider 24| | 25| |+ (NSKeyedUnarchiver *)_unarchiverFor:(NSData *)data 26| 0|{ 27| |#if __IPHONE_OS_VERSION_MIN_REQUIRED >= __IPHONE_11_0 28| | NSKeyedUnarchiver *unarchiver = [[NSKeyedUnarchiver alloc] initForReadingFromData:data error:NULL]; 29| |#else 30| 0| NSKeyedUnarchiver *unarchiver = [[NSKeyedUnarchiver alloc] initForReadingWithData:data]; 31| 0|#endif 32| 0| return unarchiver; 33| 0|} 34| | 35| |+ (id)createSecureUnarchiverFor:(NSData *)data 36| 0|{ 37| 0| NSKeyedUnarchiver *unarchiver = [FBSDKUnarchiverProvider _unarchiverFor:data]; 38| 0| unarchiver.requiresSecureCoding = YES; 39| 0| return [[FBSDKObjectDecoder alloc]initWith:unarchiver]; 40| 0|} 41| | 42| |+ (id)createInsecureUnarchiverFor:(NSData *)data 43| 0|{ 44| 0| NSKeyedUnarchiver *unarchiver = [FBSDKUnarchiverProvider _unarchiverFor:data]; 45| 0| unarchiver.requiresSecureCoding = NO; 46| 0| return [[FBSDKObjectDecoder alloc]initWith:unarchiver]; 47| 0|} 48| | 49| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Instrument/CrashReport/FBSDKCrashObserver.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKCrashObserver.h" 20| | 21| |#import "FBSDKCrashShield.h" 22| |#import "FBSDKFeatureChecking.h" 23| |#import "FBSDKFeatureManager+FeatureChecking.h" 24| |#import "FBSDKGraphRequest.h" 25| |#import "FBSDKGraphRequestFactory.h" 26| |#import "FBSDKGraphRequestProviding.h" 27| |#import "FBSDKSettings+Internal.h" 28| |#import "FBSDKSettings+SettingsLogging.h" 29| |#import "FBSDKSettings+SettingsProtocols.h" 30| |#import "FBSDKSettingsProtocol.h" 31| | 32| |@interface FBSDKCrashObserver () 33| | 34| |@property (nonatomic, strong) id featureChecker; 35| |@property (nonatomic, strong) id requestProvider; 36| |@property (nonatomic, strong) id settings; 37| | 38| |@end 39| | 40| |@implementation FBSDKCrashObserver 41| | 42| |@synthesize prefixes, frameworks; 43| | 44| |- (instancetype)init 45| 0|{ 46| 0| return [self initWithFeatureChecker:FBSDKFeatureManager.shared 47| 0| graphRequestProvider:[FBSDKGraphRequestFactory new] 48| 0| settings:FBSDKSettings.sharedSettings]; 49| 0|} 50| | 51| |- (instancetype)initWithFeatureChecker:(id)featureChecker 52| | graphRequestProvider:(id)requestProvider 53| | settings:(id)settings 54| 0|{ 55| 0| if ((self = [super init])) { 56| 0| prefixes = @[@"FBSDK", @"_FBSDK"]; 57| 0| frameworks = @[@"FBSDKCoreKit", 58| 0| @"FBSDKLoginKit", 59| 0| @"FBSDKShareKit", 60| 0| @"FBSDKGamingServicesKit", 61| 0| @"FBSDKTVOSKit"]; 62| 0| _featureChecker = featureChecker; 63| 0| _requestProvider = requestProvider; 64| 0| _settings = settings; 65| 0| } 66| 0| return self; 67| 0|} 68| | 69| |+ (instancetype)shared 70| 0|{ 71| 0| static FBSDKCrashObserver *_sharedInstance; 72| 0| static dispatch_once_t nonce; 73| 0| dispatch_once(&nonce, ^{ 74| 0| _sharedInstance = [self new]; 75| 0| }); 76| 0| return _sharedInstance; 77| 0|} 78| | 79| |- (void)didReceiveCrashLogs:(NSArray *> *)processedCrashLogs 80| 0|{ 81| 0| if ([_settings isDataProcessingRestricted]) { 82| 0| return; 83| 0| } 84| 0| if (0 == processedCrashLogs.count) { 85| 0| [FBSDKCrashHandler clearCrashReportFiles]; 86| 0| return; 87| 0| } 88| 0| NSData *jsonData = [FBSDKTypeUtility dataWithJSONObject:processedCrashLogs options:0 error:nil]; 89| 0| if (jsonData) { 90| 0| NSString *crashReports = [[NSString alloc] initWithData:jsonData encoding:NSUTF8StringEncoding]; 91| | 92| 0| id request = [_requestProvider createGraphRequestWithGraphPath:[NSString stringWithFormat:@"%@/instruments", [_settings appID]] 93| 0| parameters:@{@"crash_reports" : crashReports ?: @""} 94| 0| HTTPMethod:FBSDKHTTPMethodPOST]; 95| | 96| 0| [request startWithCompletion:^(id connection, id result, NSError *error) { 97| 0| if (!error && [result isKindOfClass:[NSDictionary class]] && result[@"success"]) { 98| 0| [FBSDKCrashHandler clearCrashReportFiles]; 99| 0| } 100| 0| }]; 101| 0| } 102| 0| [_featureChecker checkFeature:FBSDKFeatureCrashShield completionBlock:^(BOOL enabled) { 103| 0| if (enabled) { 104| 0| [FBSDKCrashShield analyze:processedCrashLogs]; 105| 0| } 106| 0| }]; 107| 0|} 108| | 109| |#if DEBUG 110| | #if FBSDKTEST 111| |- (id)settings 112| 0|{ 113| 0| return _settings; 114| 0|} 115| | 116| | #endif 117| |#endif 118| | 119| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Instrument/CrashReport/FBSDKCrashShield.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKCrashShield.h" 20| | 21| |#import "FBSDKCoreKitBasicsImport.h" 22| |#import "FBSDKFeatureChecking.h" 23| |#import "FBSDKFeatureDisabling.h" 24| |#import "FBSDKGraphRequestFactory.h" 25| |#import "FBSDKGraphRequestHTTPMethod.h" 26| |#import "FBSDKGraphRequestProtocol.h" 27| |#import "FBSDKGraphRequestProviding.h" 28| |#import "FBSDKInternalUtility.h" 29| |#import "FBSDKSettings+Internal.h" 30| |#import "FBSDKSettingsProtocol.h" 31| | 32| |@interface FBSDKCrashShield () 33| | 34| |@property (class, nullable, nonatomic, readonly) id requestProvider; 35| |@property (class, nullable, nonatomic, readonly) id featureChecking; 36| |@property (class, nullable, nonatomic, readonly) id settings; 37| | 38| |@end 39| | 40| |@implementation FBSDKCrashShield 41| | 42| |static id _requestProvider; 43| |static id _featureChecking; 44| |static NSDictionary *> *_featureMapping; 45| |static NSDictionary *_featureForStringMap; 46| |static id _settings; 47| | 48| |+ (id)settings 49| 0|{ 50| 0| return _settings; 51| 0|} 52| | 53| |+ (id)requestProvider 54| 0|{ 55| 0| return _requestProvider; 56| 0|} 57| | 58| |+ (id)featureChecking 59| 0|{ 60| 0| return _featureChecking; 61| 0|} 62| | 63| |+ (void)configureWithSettings:(id)settings 64| | requestProvider:(id)requestProvider 65| | featureChecking:(id)featureChecking 66| 0|{ 67| 0| if (self == [FBSDKCrashShield class]) { 68| 0| _settings = settings; 69| 0| _requestProvider = requestProvider; 70| 0| _featureChecking = featureChecking; 71| 0| } 72| 0|} 73| | 74| |+ (void)initialize 75| 0|{ 76| 0| if (self == [FBSDKCrashShield class]) { 77| 0| _featureMapping = 78| 0| @{ 79| 0| @"AEM" : @ [ 80| 0| @"FBSDKAEMConfiguration", 81| 0| @"FBSDKAEMEvent", 82| 0| @"FBSDKAEMInvocation", 83| 0| @"FBSDKAEMReporter", 84| 0| @"FBSDKAEMRule", 85| 0| ], 86| 0| @"AAM" : @[ 87| 0| @"FBSDKMetadataIndexer", 88| 0| ], 89| 0| @"CodelessEvents" : @[ 90| 0| @"FBSDKCodelessIndexer", 91| 0| @"FBSDKEventBinding", 92| 0| @"FBSDKEventBindingManager", 93| 0| @"FBSDKViewHierarchy", 94| 0| @"FBSDKCodelessPathComponent", 95| 0| @"FBSDKCodelessParameterComponent", 96| 0| ], 97| 0| @"RestrictiveDataFiltering" : @[ 98| 0| @"FBSDKRestrictiveDataFilterManager", 99| 0| ], 100| 0| @"ErrorReport" : @[ 101| 0| @"FBSDKErrorReport", 102| 0| ], 103| 0| @"PrivacyProtection" : @[ 104| 0| @"FBSDKModelManager", 105| 0| ], 106| 0| @"SuggestedEvents" : @[ 107| 0| @"FBSDKSuggestedEventsIndexer", 108| 0| @"FBSDKFeatureExtractor", 109| 0| ], 110| 0| @"IntelligentIntegrity" : @[ 111| 0| @"FBSDKIntegrityManager", 112| 0| ], 113| 0| @"EventDeactivation" : @[ 114| 0| @"FBSDKEventDeactivationManager", 115| 0| ], 116| 0| @"SKAdNetworkConversionValue" : @[ 117| 0| @"FBSDKSKAdNetworkReporter", 118| 0| @"FBSDKSKAdNetworkConversionConfiguration", 119| 0| @"FBSDKSKAdNetworkRule", 120| 0| @"FBSDKSKAdNetworkEvent", 121| 0| ], 122| 0| }; 123| | 124| 0| _featureForStringMap = @{ 125| 0| @"CoreKit" : @(FBSDKFeatureCore), 126| 0| @"AppEvents" : @(FBSDKFeatureAppEvents), 127| 0| @"CodelessEvents" : @(FBSDKFeatureCodelessEvents), 128| 0| @"RestrictiveDataFiltering" : @(FBSDKFeatureRestrictiveDataFiltering), 129| 0| @"AAM" : @(FBSDKFeatureAAM), 130| 0| @"PrivacyProtection" : @(FBSDKFeaturePrivacyProtection), 131| 0| @"SuggestedEvents" : @(FBSDKFeatureSuggestedEvents), 132| 0| @"IntelligentIntegrity" : @(FBSDKFeatureIntelligentIntegrity), 133| 0| @"ModelRequest" : @(FBSDKFeatureModelRequest), 134| 0| @"EventDeactivation" : @(FBSDKFeatureEventDeactivation), 135| 0| @"SKAdNetwork" : @(FBSDKFeatureSKAdNetwork), 136| 0| @"SKAdNetworkConversionValue" : @(FBSDKFeatureSKAdNetworkConversionValue), 137| 0| @"Instrument" : @(FBSDKFeatureInstrument), 138| 0| @"CrashReport" : @(FBSDKFeatureCrashReport), 139| 0| @"CrashShield" : @(FBSDKFeatureCrashShield), 140| 0| @"ErrorReport" : @(FBSDKFeatureErrorReport), 141| 0| @"ATELogging" : @(FBSDKFeatureATELogging), 142| 0| @"AEM" : @(FBSDKFeatureAEM), 143| 0| @"LoginKit" : @(FBSDKFeatureLogin), 144| 0| @"ShareKit" : @(FBSDKFeatureShare), 145| 0| @"GamingServicesKit" : @(FBSDKFeatureGamingServices), 146| 0| }; 147| 0| } 148| 0|} 149| | 150| |+ (void)analyze:(NSArray *> *)crashLogs 151| 0|{ 152| 0| NSMutableSet *disabledFeatures = [NSMutableSet set]; 153| 0| for (NSDictionary *crashLog in crashLogs) { 154| 0| NSArray *callstack = crashLog[@"callstack"]; 155| 0| NSString *featureName = [self _getFeature:callstack]; 156| 0| if (featureName) { 157| 0| [_featureChecking disableFeature:[self featureForString:featureName]]; 158| 0| [disabledFeatures addObject:featureName]; 159| 0| continue; 160| 0| } 161| 0| } 162| 0| if ([self.settings isDataProcessingRestricted]) { 163| 0| return; 164| 0| } 165| 0| if (disabledFeatures.count > 0) { 166| 0| NSDictionary *disabledFeatureLog = @{@"feature_names" : [disabledFeatures allObjects], 167| 0| @"timestamp" : [NSString stringWithFormat:@"%.0lf", [[NSDate date] timeIntervalSince1970]], }; 168| 0| NSData *jsonData = [FBSDKTypeUtility dataWithJSONObject:disabledFeatureLog options:0 error:nil]; 169| 0| if (jsonData) { 170| 0| NSString *disabledFeatureReport = [[NSString alloc] initWithData:jsonData encoding:NSUTF8StringEncoding]; 171| 0| if (disabledFeatureReport) { 172| 0| id request = [_requestProvider createGraphRequestWithGraphPath:[NSString stringWithFormat:@"%@/instruments", [self.settings appID]] 173| 0| parameters:@{@"crash_shield" : disabledFeatureReport} 174| 0| HTTPMethod:FBSDKHTTPMethodPOST]; 175| | 176| 0| [request startWithCompletion:nil]; 177| 0| } 178| 0| } 179| 0| } 180| 0|} 181| | 182| |#pragma mark - Private Methods 183| |+ (int)featureForString:(NSString *)featureName 184| 0|{ 185| 0| NSNumber *feature = [FBSDKTypeUtility dictionary:_featureForStringMap objectForKey:featureName ofType:NSObject.class]; 186| 0| return feature.intValue; 187| 0|} 188| | 189| |+ (nullable NSString *)_getFeature:(NSArray *)callstack 190| 0|{ 191| 0| NSArray *validCallstack = [FBSDKTypeUtility arrayValue:callstack]; 192| 0| NSArray *featureNames = _featureMapping.allKeys; 193| 0| for (NSString *entry in validCallstack) { 194| 0| NSString *className = [self _getClassName:[FBSDKTypeUtility coercedToStringValue:entry]]; 195| 0| for (NSString *featureName in featureNames) { 196| 0| NSArray *classArray = [FBSDKTypeUtility dictionary:_featureMapping objectForKey:featureName ofType:NSObject.class]; 197| 0| if (className && [classArray containsObject:className]) { 198| 0| return featureName; 199| 0| } 200| 0| } 201| 0| } 202| 0| return nil; 203| 0|} 204| | 205| |+ (nullable NSString *)_getClassName:(NSString *)entry 206| 0|{ 207| 0| NSString *validEntry = [FBSDKTypeUtility coercedToStringValue:entry]; 208| 0| NSArray *items = [validEntry componentsSeparatedByString:@" "]; 209| 0| NSString *className = nil; 210| | // parse class name only from an entry in format "-[className functionName]+offset" 211| | // or "+[className functionName]+offset" 212| 0| if (items.count > 0 && ([[FBSDKTypeUtility array:items objectAtIndex:0] hasPrefix:@"+["] || [[FBSDKTypeUtility array:items objectAtIndex:0] hasPrefix:@"-["])) { 213| 0| className = [[FBSDKTypeUtility array:items objectAtIndex:0] substringFromIndex:2]; 214| 0| } 215| 0| return className; 216| 0|} 217| | 218| |#if DEBUG 219| | #if FBSDKTEST 220| | 221| |+ (void)reset 222| 0|{ 223| 0| _settings = nil; 224| 0| _requestProvider = nil; 225| 0| _featureChecking = nil; 226| 0|} 227| | 228| | #endif 229| |#endif 230| | 231| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Instrument/ErrorReport/FBSDKErrorReport.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKErrorReport.h" 20| | 21| |#import "FBSDKCoreKitBasicsImport.h" 22| |#import "FBSDKGraphRequest.h" 23| |#import "FBSDKGraphRequestConnection.h" 24| |#import "FBSDKGraphRequestFactory.h" 25| |#import "FBSDKGraphRequestProviding.h" 26| |#import "FBSDKInternalUtility.h" 27| |#import "FBSDKLogger.h" 28| |#import "FBSDKSettings+Internal.h" 29| |#import "FBSDKSettings+SettingsProtocols.h" 30| |#import "FBSDKSettingsProtocol.h" 31| | 32| |#define FBSDK_MAX_ERROR_REPORT_LOGS 1000 33| | 34| |@interface FBSDKErrorReport () 35| | 36| |@property (nonatomic, strong) id requestProvider; 37| |@property (nonatomic, strong) id fileManager; 38| |@property (nonatomic, strong) id settings; 39| |@property (nonatomic, strong) Class dataExtractor; 40| |@property (nonatomic, readonly, strong) NSString *directoryPath; 41| |@property (nonatomic) BOOL isEnabled; 42| | 43| |@end 44| | 45| |@implementation FBSDKErrorReport 46| | 47| |static NSString *ErrorReportStorageDirName = @"instrument/"; 48| | 49| |NSString *const kFBSDKErrorCode = @"error_code"; 50| |NSString *const kFBSDKErrorDomain = @"domain"; 51| |NSString *const kFBSDKErrorTimestamp = @"timestamp"; 52| | 53| |# pragma mark - Public Methods 54| | 55| |- (instancetype)init 56| 0|{ 57| 0| return [self initWithGraphRequestProvider:[FBSDKGraphRequestFactory new] 58| 0| fileManager:NSFileManager.defaultManager 59| 0| settings:FBSDKSettings.sharedSettings 60| 0| fileDataExtractor:NSData.class]; 61| 0|} 62| | 63| |- (instancetype)initWithGraphRequestProvider:(nonnull id)requestProvider 64| | fileManager:(nonnull id)fileManager 65| | settings:(nonnull id)settings 66| | fileDataExtractor:(nonnull Class)dataExtractor 67| 0|{ 68| 0| if ((self = [super init])) { 69| 0| _requestProvider = requestProvider; 70| 0| _fileManager = fileManager; 71| 0| _settings = settings; 72| 0| _dataExtractor = dataExtractor; 73| 0| _directoryPath = [NSTemporaryDirectory() stringByAppendingPathComponent:ErrorReportStorageDirName]; 74| 0| } 75| | 76| 0| return self; 77| 0|} 78| | 79| |+ (instancetype)shared 80| 0|{ 81| 0| static FBSDKErrorReport *_sharedInstance; 82| 0| static dispatch_once_t nonce; 83| 0| dispatch_once(&nonce, ^{ 84| 0| _sharedInstance = [self new]; 85| 0| }); 86| 0| return _sharedInstance; 87| 0|} 88| | 89| |- (void)enable 90| 0|{ 91| 0| [self createErrorDirectoryIfNeeded]; 92| 0| if (![self.settings isDataProcessingRestricted]) { 93| 0| [self uploadErrors]; 94| 0| } 95| 0| self.isEnabled = YES; 96| 0|} 97| | 98| |+ (void)saveError:(NSInteger)errorCode 99| | errorDomain:(NSErrorDomain)errorDomain 100| | message:(nullable NSString *)message 101| 0|{ 102| 0| [[FBSDKErrorReport new] saveError:errorCode 103| 0| errorDomain:errorDomain 104| 0| message:message]; 105| 0|} 106| | 107| |- (void)saveError:(NSInteger)errorCode 108| | errorDomain:(NSErrorDomain)errorDomain 109| | message:(nullable NSString *)message 110| 0|{ 111| 0| if (self.isEnabled) { 112| 0| NSString *timestamp = [NSString stringWithFormat:@"%.0lf", [[NSDate date] timeIntervalSince1970]]; 113| 0| [self _saveErrorInfoToDisk:@{ 114| 0| kFBSDKErrorCode : @(errorCode), 115| 0| kFBSDKErrorDomain : errorDomain, 116| 0| kFBSDKErrorTimestamp : timestamp, 117| 0| }]; 118| 0| } 119| 0|} 120| | 121| |#pragma mark - Private Methods 122| | 123| |- (void)createErrorDirectoryIfNeeded 124| 0|{ 125| 0| if (![self.fileManager fileExistsAtPath:self.directoryPath]) { 126| 0| if (![self.fileManager createDirectoryAtPath:self.directoryPath 127| 0| withIntermediateDirectories:NO 128| 0| attributes:NULL 129| 0| error:NULL]) { 130| 0| NSString *msg = [NSString stringWithFormat:@"Failed to create library at %@", self.directoryPath]; 131| 0| [FBSDKLogger singleShotLogEntry:FBSDKLoggingBehaviorInformational logEntry:msg]; 132| 0| } 133| 0| } 134| 0|} 135| | 136| |- (void)uploadErrors 137| 0|{ 138| 0| NSArray *> *errorReports = [self loadErrorReports]; 139| 0| if ([errorReports count] == 0) { 140| 0| return [self _clearErrorInfo]; 141| 0| } 142| 0| NSData *jsonData = [FBSDKTypeUtility dataWithJSONObject:errorReports options:0 error:nil]; 143| 0| if (!jsonData) { 144| 0| return; 145| 0| } 146| 0| NSString *errorData = [[NSString alloc] initWithData:jsonData encoding:NSUTF8StringEncoding]; 147| 0| id request = [self.requestProvider createGraphRequestWithGraphPath:[NSString stringWithFormat:@"%@/instruments", self.settings.appID] 148| 0| parameters:@{@"error_reports" : errorData ?: @""} 149| 0| HTTPMethod:FBSDKHTTPMethodPOST]; 150| | 151| 0| [request startWithCompletion:^(id connection, id result, NSError *error) { 152| 0| if (!error && [result isKindOfClass:[NSDictionary class]] && result[@"success"]) { 153| 0| [self _clearErrorInfo]; 154| 0| } 155| 0| }]; 156| 0|} 157| | 158| |- (NSArray *> *)loadErrorReports 159| 0|{ 160| 0| NSMutableArray *> *errorReportArr = [NSMutableArray array]; 161| 0| NSArray *fileNames = [self.fileManager contentsOfDirectoryAtPath:self.directoryPath error:NULL]; 162| 0| NSPredicate *predicate = [NSPredicate predicateWithBlock:^BOOL (id _Nullable evaluatedObject, NSDictionary *_Nullable bindings) { 163| 0| NSString *str = (NSString *)evaluatedObject; 164| 0| return [str hasPrefix:@"error_report_"] && [str hasSuffix:@".json"]; 165| 0| }]; 166| 0| fileNames = [fileNames filteredArrayUsingPredicate:predicate]; 167| 0| fileNames = [fileNames sortedArrayUsingComparator:^NSComparisonResult (id _Nonnull obj1, id _Nonnull obj2) { 168| 0| return [obj2 compare:obj1]; 169| 0| }]; 170| 0| if (fileNames.count > 0) { 171| 0| fileNames = [fileNames subarrayWithRange:NSMakeRange(0, MIN(fileNames.count, FBSDK_MAX_ERROR_REPORT_LOGS))]; 172| 0| for (NSUInteger i = 0; i < fileNames.count; i++) { 173| 0| NSData *data = [self.dataExtractor dataWithContentsOfFile:[self.directoryPath stringByAppendingPathComponent:[FBSDKTypeUtility array:fileNames objectAtIndex:i]] 174| 0| options:NSDataReadingMappedIfSafe 175| 0| error:nil]; 176| 0| if (data) { 177| 0| NSDictionary *errorReport = [FBSDKTypeUtility JSONObjectWithData:data 178| 0| options:0 179| 0| error:nil]; 180| 0| if (errorReport) { 181| 0| [FBSDKTypeUtility array:errorReportArr addObject:errorReport]; 182| 0| } 183| 0| } 184| 0| } 185| 0| } 186| 0| return [errorReportArr copy]; 187| 0|} 188| | 189| |- (void)_clearErrorInfo 190| 0|{ 191| 0| NSArray *files = [self.fileManager contentsOfDirectoryAtPath:self.directoryPath error:nil]; 192| 0| for (NSUInteger i = 0; i < files.count; i++) { 193| 0| if ([[FBSDKTypeUtility array:files objectAtIndex:i] hasPrefix:@"error_report"]) { 194| 0| [self.fileManager removeItemAtPath:[self.directoryPath stringByAppendingPathComponent:[FBSDKTypeUtility array:files objectAtIndex:i]] error:nil]; 195| 0| } 196| 0| } 197| 0|} 198| | 199| |- (void)_saveErrorInfoToDisk:(NSDictionary *)errorInfo 200| 0|{ 201| 0| if (errorInfo.count > 0) { 202| 0| NSData *data = [FBSDKTypeUtility dataWithJSONObject:errorInfo options:0 error:nil]; 203| 0| [data writeToFile:[self _pathToErrorInfoFile] 204| 0| atomically:YES]; 205| 0| } 206| 0|} 207| | 208| |- (NSString *)_pathToErrorInfoFile 209| 0|{ 210| 0| NSString *timestamp = [NSString stringWithFormat:@"%.0lf", [[NSDate date] timeIntervalSince1970]]; 211| 0| return [self.directoryPath stringByAppendingPathComponent:[NSString stringWithFormat:@"error_report_%@.json", timestamp]]; 212| 0|} 213| | 214| |#if DEBUG 215| | #if FBSDKTEST 216| | 217| |- (void)reset 218| 0|{ 219| 0| _isEnabled = NO; 220| 0|} 221| | 222| | #endif 223| |#endif 224| | 225| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Instrument/FBSDKInstrumentManager.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKInstrumentManager.h" 20| | 21| |#import "FBSDKCoreKitBasicsImport.h" 22| |#import "FBSDKCrashObserver.h" 23| |#import "FBSDKErrorReport+ErrorReporting.h" 24| |#import "FBSDKFeatureChecking.h" 25| |#import "FBSDKFeatureManager+FeatureChecking.h" 26| |#import "FBSDKSettings+Internal.h" 27| | 28| |#if defined FBSDK_SWIFT_PACKAGE 29| | #import "FBSDKSettingsProtocol.h" 30| |#else 31| | #import 32| |#endif 33| | 34| |#import "FBSDKSettings+SettingsProtocols.h" 35| | 36| |@interface FBSDKInstrumentManager () 37| | 38| |@property (nonatomic, strong) id featureChecker; 39| |@property (nonatomic, strong) id settings; 40| |@property (nonatomic, strong) id crashObserver; 41| |@property (nonatomic, strong) id errorReport; 42| |@property (nonatomic, strong) id crashHandler; 43| | 44| |@end 45| | 46| |@implementation FBSDKInstrumentManager 47| | 48| |- (instancetype)init 49| 0|{ 50| 0| return [self initWithFeatureCheckerProvider:FBSDKFeatureManager.shared 51| 0| settings:FBSDKSettings.sharedSettings 52| 0| crashObserver:FBSDKCrashObserver.shared 53| 0| errorReport:FBSDKErrorReport.shared 54| 0| crashHandler:FBSDKCrashHandler.shared]; 55| 0|} 56| | 57| |- (instancetype)initWithFeatureCheckerProvider:(id)featureChecker 58| | settings:(id)settings 59| | crashObserver:(id)crashObserver 60| | errorReport:(id)errorReport 61| | crashHandler:(id)crashHandler 62| 0|{ 63| 0| if ((self = [super init])) { 64| 0| _featureChecker = featureChecker; 65| 0| _settings = settings; 66| 0| _crashObserver = crashObserver; 67| 0| _errorReport = errorReport; 68| 0| _crashHandler = crashHandler; 69| 0| } 70| 0| return self; 71| 0|} 72| | 73| |+ (instancetype)shared 74| 0|{ 75| 0| static dispatch_once_t nonce; 76| 0| static id instance; 77| 0| dispatch_once(&nonce, ^{ 78| 0| instance = [self new]; 79| 0| }); 80| 0| return instance; 81| 0|} 82| | 83| |- (void)enable 84| 0|{ 85| 0| if (![self.settings isAutoLogAppEventsEnabled]) { 86| 0| return; 87| 0| } 88| | 89| 0| [self.featureChecker checkFeature:FBSDKFeatureCrashReport completionBlock:^(BOOL enabled) { 90| 0| if (enabled) { 91| 0| [self.crashHandler addObserver:self.crashObserver]; 92| 0| } 93| 0| }]; 94| 0| [self.featureChecker checkFeature:FBSDKFeatureErrorReport completionBlock:^(BOOL enabled) { 95| 0| if (enabled) { 96| 0| [self.errorReport enable]; 97| 0| } 98| 0| }]; 99| 0|} 100| | 101| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKGraphRequestBody.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKGraphRequestBody.h" 20| | 21| |#import "FBSDKConstants.h" 22| |#import "FBSDKCoreKitBasicsImport.h" 23| |#import "FBSDKCrypto.h" 24| |#import "FBSDKGraphRequestDataAttachment.h" 25| |#import "FBSDKLogger.h" 26| |#import "FBSDKSettings.h" 27| | 28| 0|#define kNewline @"\r\n" 29| | 30| |@implementation FBSDKGraphRequestBody 31| |{ 32| | NSMutableData *_data; 33| | NSMutableDictionary *_json; 34| | NSString *_stringBoundary; 35| |} 36| | 37| |- (instancetype)init 38| 0|{ 39| 0| if ((self = [super init])) { 40| 0| _stringBoundary = [FBSDKCrypto randomString:32]; 41| 0| _data = [NSMutableData new]; 42| 0| _json = [NSMutableDictionary dictionary]; 43| 0| _requiresMultipartDataFormat = NO; 44| 0| } 45| | 46| 0| return self; 47| 0|} 48| | 49| |- (NSString *)mimeContentType 50| 0|{ 51| 0| if (self.requiresMultipartDataFormat) { 52| 0| return [NSString stringWithFormat:@"multipart/form-data; boundary=%@", _stringBoundary]; 53| 0| } else { 54| 0| return @"application/json"; 55| 0| } 56| 0|} 57| | 58| |- (void)appendUTF8:(NSString *)utf8 59| 0|{ 60| 0| if (!_data.length) { 61| 0| NSString *headerUTF8 = [NSString stringWithFormat:@"--%@%@", _stringBoundary, kNewline]; 62| 0| NSData *headerData = [headerUTF8 dataUsingEncoding:NSUTF8StringEncoding]; 63| 0| [_data appendData:headerData]; 64| 0| } 65| 0| NSData *data = [utf8 dataUsingEncoding:NSUTF8StringEncoding]; 66| 0| [_data appendData:data]; 67| 0|} 68| | 69| |- (void)appendWithKey:(NSString *)key 70| | formValue:(NSString *)value 71| | logger:(FBSDKLogger *)logger 72| 0|{ 73| 0| [self _appendWithKey:key filename:nil contentType:nil contentBlock:^{ 74| 0| [self appendUTF8:value]; 75| 0| }]; 76| 0| if (key && value) { 77| 0| [FBSDKTypeUtility dictionary:_json setObject:value forKey:key]; 78| 0| } 79| 0| [logger appendFormat:@"\n %@:\t%@", key, (NSString *)value]; 80| 0|} 81| | 82| |- (void)appendWithKey:(NSString *)key 83| | imageValue:(UIImage *)image 84| | logger:(FBSDKLogger *)logger 85| 0|{ 86| 0| NSData *data = UIImageJPEGRepresentation(image, [FBSDKSettings JPEGCompressionQuality]); 87| 0| [self _appendWithKey:key filename:key contentType:@"image/jpeg" contentBlock:^{ 88| 0| [self->_data appendData:data]; 89| 0| }]; 90| 0| self.requiresMultipartDataFormat = YES; 91| 0| [logger appendFormat:@"\n %@:\t", key, (unsigned long)(data.length / 1024)]; 92| 0|} 93| | 94| |- (void)appendWithKey:(NSString *)key 95| | dataValue:(NSData *)data 96| | logger:(FBSDKLogger *)logger 97| 0|{ 98| 0| [self _appendWithKey:key filename:key contentType:@"content/unknown" contentBlock:^{ 99| 0| [self->_data appendData:data]; 100| 0| }]; 101| 0| self.requiresMultipartDataFormat = YES; 102| 0| [logger appendFormat:@"\n %@:\t", key, (unsigned long)(data.length / 1024)]; 103| 0|} 104| | 105| |- (void)appendWithKey:(NSString *)key 106| | dataAttachmentValue:(FBSDKGraphRequestDataAttachment *)dataAttachment 107| | logger:(FBSDKLogger *)logger 108| 0|{ 109| 0| NSString *filename = dataAttachment.filename ?: key; 110| 0| NSString *contentType = dataAttachment.contentType ?: @"content/unknown"; 111| 0| NSData *data = dataAttachment.data; 112| 0| [self _appendWithKey:key filename:filename contentType:contentType contentBlock:^{ 113| 0| [self->_data appendData:data]; 114| 0| }]; 115| 0| self.requiresMultipartDataFormat = YES; 116| 0| [logger appendFormat:@"\n %@:\t", key, (unsigned long)(data.length / 1024)]; 117| 0|} 118| | 119| |- (NSData *)data 120| 0|{ 121| 0| if (self.requiresMultipartDataFormat) { 122| 0| return [_data copy]; 123| 0| } else { 124| 0| NSData *jsonData; 125| 0| if (_json.allKeys.count > 0) { 126| 0| jsonData = [FBSDKTypeUtility dataWithJSONObject:_json options:0 error:nil]; 127| 0| } else { 128| 0| jsonData = [NSData data]; 129| 0| } 130| | 131| 0| return jsonData; 132| 0| } 133| 0|} 134| | 135| |- (void)_appendWithKey:(NSString *)key 136| | filename:(NSString *)filename 137| | contentType:(NSString *)contentType 138| | contentBlock:(FBSDKCodeBlock)contentBlock 139| 0|{ 140| 0| NSMutableArray *disposition = [NSMutableArray new]; 141| 0| [FBSDKTypeUtility array:disposition addObject:@"Content-Disposition: form-data"]; 142| 0| if (key) { 143| 0| [FBSDKTypeUtility array:disposition addObject:[[NSString alloc] initWithFormat:@"name=\"%@\"", key]]; 144| 0| } 145| 0| if (filename) { 146| 0| [FBSDKTypeUtility array:disposition addObject:[[NSString alloc] initWithFormat:@"filename=\"%@\"", filename]]; 147| 0| } 148| 0| [self appendUTF8:[[NSString alloc] initWithFormat:@"%@%@", [disposition componentsJoinedByString:@"; "], kNewline]]; 149| 0| if (contentType) { 150| 0| [self appendUTF8:[[NSString alloc] initWithFormat:@"Content-Type: %@%@", contentType, kNewline]]; 151| 0| } 152| 0| [self appendUTF8:kNewline]; 153| 0| if (contentBlock != NULL) { 154| 0| contentBlock(); 155| 0| } 156| 0| [self appendUTF8:[[NSString alloc] initWithFormat:@"%@--%@%@", kNewline, _stringBoundary, kNewline]]; 157| 0|} 158| | 159| |- (NSData *)compressedData 160| 0|{ 161| 0| if (!self.data.length || ![[self mimeContentType] isEqualToString:@"application/json"]) { 162| 0| return nil; 163| 0| } 164| | 165| 0| return [FBSDKBasicUtility gzip:self.data]; 166| 0|} 167| | 168| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKGraphRequestConnectionFactory.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKGraphRequestConnectionFactory.h" 20| | 21| |#import "FBSDKGraphRequestConnection.h" 22| |#import "FBSDKGraphRequestConnection+GraphRequestConnecting.h" 23| | 24| |@implementation FBSDKGraphRequestConnectionFactory 25| | 26| |- (nonnull id)createGraphRequestConnection 27| 0|{ 28| 0| return [FBSDKGraphRequestConnection new]; 29| 0|} 30| | 31| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKGraphRequestFactory.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKGraphRequestFactory.h" 20| | 21| |#import "FBSDKGraphRequest+Internal.h" 22| | 23| |@implementation FBSDKGraphRequestFactory 24| | 25| |- (nonnull id)createGraphRequestWithGraphPath:(NSString *)graphPath 26| | parameters:(NSDictionary *)parameters 27| | tokenString:(NSString *)tokenString 28| | HTTPMethod:(FBSDKHTTPMethod)method 29| | flags:(FBSDKGraphRequestFlags)flags 30| 0|{ 31| 0| return [[FBSDKGraphRequest alloc] initWithGraphPath:graphPath 32| 0| parameters:parameters 33| 0| tokenString:tokenString 34| 0| HTTPMethod:method 35| 0| flags:flags]; 36| 0|} 37| | 38| |- (nonnull id)createGraphRequestWithGraphPath:(nonnull NSString *)graphPath 39| 0|{ 40| 0| return [[FBSDKGraphRequest alloc] initWithGraphPath:graphPath]; 41| 0|} 42| | 43| |- (nonnull id)createGraphRequestWithGraphPath:(nonnull NSString *)graphPath 44| | parameters:(nonnull NSDictionary *)parameters 45| 0|{ 46| 0| return [[FBSDKGraphRequest alloc] initWithGraphPath:graphPath parameters:parameters]; 47| 0|} 48| | 49| |- (nonnull id)createGraphRequestWithGraphPath:(nonnull NSString *)graphPath 50| | parameters:(nonnull NSDictionary *)parameters 51| | HTTPMethod:(nonnull FBSDKHTTPMethod)method 52| 0|{ 53| 0| return [[FBSDKGraphRequest alloc] initWithGraphPath:graphPath 54| 0| parameters:parameters 55| 0| HTTPMethod:method]; 56| 0|} 57| | 58| |- (nonnull id)createGraphRequestWithGraphPath:(NSString *)graphPath 59| | parameters:(NSDictionary *)parameters 60| | tokenString:(NSString *)tokenString 61| | version:(nullable NSString *)version 62| | HTTPMethod:(FBSDKHTTPMethod)method 63| 0|{ 64| 0| return [[FBSDKGraphRequest alloc] initWithGraphPath:graphPath 65| 0| parameters:parameters 66| 0| tokenString:tokenString 67| 0| version:version 68| 0| HTTPMethod:method]; 69| 0|} 70| | 71| |- (nonnull id)createGraphRequestWithGraphPath:(nonnull NSString *)graphPath 72| | parameters:(nonnull NSDictionary *)parameters 73| | flags:(FBSDKGraphRequestFlags)flags 74| 0|{ 75| 0| return [[FBSDKGraphRequest alloc] initWithGraphPath:graphPath 76| 0| parameters:parameters 77| 0| flags:flags]; 78| 0|} 79| | 80| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKGraphRequestMetadata.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKGraphRequestMetadata.h" 20| | 21| |#import "FBSDKGraphRequestProtocol.h" 22| | 23| |@implementation FBSDKGraphRequestMetadata 24| | 25| |- (instancetype)initWithRequest:(id)request 26| | completionHandler:(FBSDKGraphRequestCompletion)handler 27| | batchParameters:(NSDictionary *)batchParameters 28| 0|{ 29| 0| if ((self = [super init])) { 30| 0| _request = request; 31| 0| _batchParameters = [batchParameters copy]; 32| 0| _completionHandler = [handler copy]; 33| 0| } 34| 0| return self; 35| 0|} 36| | 37| |- (void)invokeCompletionHandlerForConnection:(id)connection 38| | withResults:(id)results 39| | error:(NSError *)error 40| 0|{ 41| 0| if (self.completionHandler) { 42| 0| self.completionHandler(connection, results, error); 43| 0| } 44| 0|} 45| | 46| |- (NSString *)description 47| 0|{ 48| 0| return [NSString stringWithFormat:@"<%@: %p, batchParameters: %@, completionHandler: %@, request: %@>", 49| 0| NSStringFromClass([self class]), 50| 0| self, 51| 0| self.batchParameters, 52| 0| self.completionHandler, 53| 0| self.request.formattedDescription]; 54| 0|} 55| | 56| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKGraphRequestPiggybackManager.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKGraphRequestPiggybackManager.h" 20| | 21| |#import "FBSDKCoreKit+Internal.h" 22| |#import "FBSDKCoreKitBasicsImport.h" 23| |#import "FBSDKGraphRequestConnecting+Internal.h" 24| |#import "FBSDKServerConfigurationLoading.h" 25| |#import "FBSDKServerConfigurationProviding.h" 26| |#import "FBSDKSettings+SettingsLogging.h" 27| |#import "FBSDKSettings+SettingsProtocols.h" 28| | 29| |static int const FBSDKTokenRefreshThresholdSeconds = 24 * 60 * 60; // day 30| |static int const FBSDKTokenRefreshRetrySeconds = 60 * 60; // hour 31| | 32| |@implementation FBSDKGraphRequestPiggybackManager 33| | 34| |static NSDate *_lastRefreshTry = nil; 35| |static Class _tokenWallet = nil; 36| |static id _settings; 37| |static Class _serverConfiguration; 38| |static id _requestProvider; 39| | 40| |+ (Class)tokenWallet 41| 0|{ 42| 0| return _tokenWallet; 43| 0|} 44| | 45| |+ (id)settings 46| 0|{ 47| 0| return _settings; 48| 0|} 49| | 50| |+ (Class)serverConfiguration 51| 0|{ 52| 0| return _serverConfiguration; 53| 0|} 54| | 55| |+ (id)requestProvider 56| 0|{ 57| 0| return _requestProvider; 58| 0|} 59| | 60| |+ (void)configureWithTokenWallet:(Class)tokenWallet 61| | settings:(id)settings 62| | serverConfiguration:(Class)serverConfiguration 63| | requestProvider:(id)requestProvider 64| 0|{ 65| 0| if (self == [FBSDKGraphRequestPiggybackManager class]) { 66| 0| _tokenWallet = tokenWallet; 67| 0| _settings = settings; 68| 0| _serverConfiguration = serverConfiguration; 69| 0| _requestProvider = requestProvider; 70| 0| } 71| 0|} 72| | 73| |+ (void)addPiggybackRequests:(id)connection 74| 0|{ 75| 0| if ([self.settings appID].length > 0) { 76| 0| BOOL safeForPiggyback = YES; 77| 0| id<_FBSDKGraphRequestConnecting> internalConnection = FBSDK_CAST_TO_PROTOCOL_OR_NIL(connection, _FBSDKGraphRequestConnecting); 78| | 79| 0| for (FBSDKGraphRequestMetadata *metadata in internalConnection.requests) { 80| 0| if (![self _safeForPiggyback:metadata.request]) { 81| 0| safeForPiggyback = NO; 82| 0| break; 83| 0| } 84| 0| } 85| 0| if (safeForPiggyback) { 86| 0| [[self class] addRefreshPiggybackIfStale:connection]; 87| 0| [[self class] addServerConfigurationPiggyback:connection]; 88| 0| } 89| 0| } 90| 0|} 91| | 92| |+ (void)addRefreshPiggyback:(id)connection permissionHandler:(FBSDKGraphRequestCompletion)permissionHandler 93| 0|{ 94| 0| FBSDKAccessToken *expectedToken = [self.tokenWallet currentAccessToken]; 95| 0| if (!expectedToken) { 96| 0| return; 97| 0| } 98| 0| __block NSMutableSet *permissions = nil; 99| 0| __block NSMutableSet *declinedPermissions = nil; 100| 0| __block NSMutableSet *expiredPermissions = nil; 101| 0| __block NSString *tokenString = nil; 102| 0| __block NSNumber *expirationDateNumber = nil; 103| 0| __block NSNumber *dataAccessExpirationDateNumber = nil; 104| 0| __block NSString *graphDomain = nil; 105| 0| __block int expectingCallbacksCount = 2; 106| 0| void (^expectingCallbackComplete)(void) = ^{ 107| 0| if (--expectingCallbacksCount == 0) { 108| 0| FBSDKAccessToken *currentToken = [self.tokenWallet currentAccessToken]; 109| 0| NSDate *expirationDate = currentToken.expirationDate; 110| 0| if (expirationDateNumber != nil) { 111| 0| expirationDate = (expirationDateNumber.doubleValue > 0 112| 0| ? [NSDate dateWithTimeIntervalSince1970:expirationDateNumber.doubleValue] 113| 0| : [NSDate distantFuture]); 114| 0| } 115| 0| NSDate *dataExpirationDate = currentToken.dataAccessExpirationDate; 116| 0| if (dataAccessExpirationDateNumber != nil) { 117| 0| dataExpirationDate = (dataAccessExpirationDateNumber.doubleValue > 0 118| 0| ? [NSDate dateWithTimeIntervalSince1970:dataAccessExpirationDateNumber.doubleValue] 119| 0| : [NSDate distantFuture]); 120| 0| } 121| | 122| 0| #pragma clang diagnostic push 123| 0| #pragma clang diagnostic ignored "-Wdeprecated-declarations" 124| 0| FBSDKAccessToken *refreshedToken = [[FBSDKAccessToken alloc] initWithTokenString:tokenString ?: currentToken.tokenString 125| 0| permissions:(permissions ?: currentToken.permissions).allObjects 126| 0| declinedPermissions:(declinedPermissions ?: currentToken.declinedPermissions).allObjects 127| 0| expiredPermissions:(expiredPermissions ?: currentToken.expiredPermissions).allObjects 128| 0| appID:currentToken.appID 129| 0| userID:currentToken.userID 130| 0| expirationDate:expirationDate 131| 0| refreshDate:[NSDate date] 132| 0| dataAccessExpirationDate:dataExpirationDate 133| 0| graphDomain:graphDomain ?: currentToken.graphDomain]; 134| 0| #pragma clange diagnostic pop 135| | 136| 0| if (expectedToken == currentToken) { 137| 0| [self.tokenWallet setCurrentAccessToken:refreshedToken]; 138| 0| } 139| 0| } 140| 0| }; 141| 0| id extendRequest = [self.requestProvider createGraphRequestWithGraphPath:@"oauth/access_token" 142| 0| parameters:@{@"grant_type" : @"fb_extend_sso_token", 143| 0| @"fields" : @"", 144| 0| @"client_id" : expectedToken.appID} 145| 0| flags:FBSDKGraphRequestFlagDisableErrorRecovery]; 146| | 147| 0| [connection addRequest:extendRequest completion:^(id innerConnection, id result, NSError *error) { 148| 0| tokenString = [FBSDKTypeUtility dictionary:result objectForKey:@"access_token" ofType:NSString.class]; 149| 0| expirationDateNumber = [FBSDKTypeUtility dictionary:result objectForKey:@"expires_at" ofType:NSNumber.class]; 150| 0| dataAccessExpirationDateNumber = [FBSDKTypeUtility dictionary:result objectForKey:@"data_access_expiration_time" ofType:NSNumber.class]; 151| 0| graphDomain = [FBSDKTypeUtility dictionary:result objectForKey:@"graph_domain" ofType:NSString.class]; 152| 0| expectingCallbackComplete(); 153| 0| }]; 154| 0| id permissionsRequest = [self.requestProvider createGraphRequestWithGraphPath:@"me/permissions" 155| 0| parameters:@{@"fields" : @""} 156| 0| flags:FBSDKGraphRequestFlagDisableErrorRecovery]; 157| | 158| 0| [connection addRequest:permissionsRequest completion:^(id innerConnection, id result, NSError *error) { 159| 0| if (!error) { 160| 0| permissions = [NSMutableSet set]; 161| 0| declinedPermissions = [NSMutableSet set]; 162| 0| expiredPermissions = [NSMutableSet set]; 163| | 164| 0| [FBSDKInternalUtility extractPermissionsFromResponse:result 165| 0| grantedPermissions:permissions 166| 0| declinedPermissions:declinedPermissions 167| 0| expiredPermissions:expiredPermissions]; 168| 0| } 169| 0| expectingCallbackComplete(); 170| 0| if (permissionHandler) { 171| 0| permissionHandler(innerConnection, result, error); 172| 0| } 173| 0| }]; 174| 0|} 175| | 176| |+ (void)addRefreshPiggybackIfStale:(id)connection 177| 0|{ 178| | // don't piggy back more than once an hour as a cheap way of 179| | // retrying in cases of errors and preventing duplicate refreshes. 180| | // obviously this is not foolproof but is simple and sufficient. 181| 0| NSDate *now = [NSDate date]; 182| 0| NSDate *tokenRefreshDate = [self.tokenWallet currentAccessToken].refreshDate; 183| 0| if (tokenRefreshDate 184| 0| && [now timeIntervalSinceDate:[self _lastRefreshTry]] > [self _tokenRefreshRetryInSeconds] 185| 0| && [now timeIntervalSinceDate:tokenRefreshDate] > [self _tokenRefreshThresholdInSeconds]) { 186| 0| [self addRefreshPiggyback:connection permissionHandler:NULL]; 187| 0| [self _setLastRefreshTry:[NSDate date]]; 188| 0| } 189| 0|} 190| | 191| |+ (void)addServerConfigurationPiggyback:(id)connection 192| 0|{ 193| 0| if (![self.serverConfiguration cachedServerConfiguration].isDefaults 194| 0| && [[NSDate date] timeIntervalSinceDate:[self.serverConfiguration cachedServerConfiguration].timestamp] 195| 0| < FBSDK_SERVER_CONFIGURATION_MANAGER_CACHE_TIMEOUT) { 196| 0| return; 197| 0| } 198| 0| NSString *appID = [self.settings appID]; 199| 0| id serverConfigurationRequest = [self.serverConfiguration requestToLoadServerConfiguration:appID]; 200| 0| [connection addRequest:serverConfigurationRequest 201| 0| completion:^(id conn, id result, NSError *error) { 202| 0| [self.serverConfiguration processLoadRequestResponse:result error:error appID:appID]; 203| 0| }]; 204| 0|} 205| | 206| |+ (BOOL)_safeForPiggyback:(id)request 207| 0|{ 208| 0| BOOL isVersionSafe = [request.version isEqualToString:[self.settings graphAPIVersion]]; 209| 0| BOOL hasAttachments = [(id)request hasAttachments]; 210| 0| return isVersionSafe && !hasAttachments; 211| 0|} 212| | 213| |+ (int)_tokenRefreshThresholdInSeconds 214| 0|{ 215| 0| return FBSDKTokenRefreshThresholdSeconds; 216| 0|} 217| | 218| |+ (int)_tokenRefreshRetryInSeconds 219| 0|{ 220| 0| return FBSDKTokenRefreshRetrySeconds; 221| 0|} 222| | 223| |+ (NSDate *)_lastRefreshTry 224| 0|{ 225| 0| if (!_lastRefreshTry) { 226| 0| _lastRefreshTry = [NSDate distantPast]; 227| 0| } 228| 0| return _lastRefreshTry; 229| 0|} 230| | 231| |+ (void)_setLastRefreshTry:(NSDate *)date 232| 0|{ 233| 0| _lastRefreshTry = date; 234| 0|} 235| | 236| |#if DEBUG 237| | #if FBSDKTEST 238| | 239| |+ (void)setTokenWallet:(Class)tokenWallet 240| 0|{ 241| 0| _tokenWallet = tokenWallet; 242| 0|} 243| | 244| |+ (void)reset 245| 0|{ 246| 0| _tokenWallet = nil; 247| 0| _lastRefreshTry = nil; 248| 0|} 249| | 250| | #endif 251| |#endif 252| | 253| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKGraphRequestPiggybackManagerProvider.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKGraphRequestPiggybackManagerProvider.h" 20| | 21| |#import "FBSDKGraphRequestPiggybackManager+GraphRequestPiggybackManaging.h" 22| | 23| |@implementation FBSDKGraphRequestPiggybackManagerProvider 24| | 25| |+ (Class)piggybackManager 26| 0|{ 27| 0| return FBSDKGraphRequestPiggybackManager.class; 28| 0|} 29| | 30| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKURLSessionProxyFactory.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKURLSessionProxyFactory.h" 20| | 21| |#import 22| | 23| |@implementation FBSDKURLSessionProxyFactory 24| | 25| |- (nonnull id)createSessionProxyWithDelegate:(id)delegate 26| | queue:(NSOperationQueue *)queue 27| 0|{ 28| 0| return (id)[[FBSDKURLSession alloc] initWithDelegate:delegate delegateQueue:queue]; 29| 0|} 30| | 31| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ServerConfiguration/FBSDKDialogConfiguration.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKDialogConfiguration.h" 20| | 21| 0|#define FBSDK_DIALOG_CONFIGURATION_APP_VERSIONS_KEY @"appVersions" 22| 0|#define FBSDK_DIALOG_CONFIGURATION_NAME_KEY @"name" 23| 0|#define FBSDK_DIALOG_CONFIGURATION_URL_KEY @"url" 24| | 25| |@implementation FBSDKDialogConfiguration 26| | 27| |#pragma mark - Object Lifecycle 28| | 29| |- (instancetype)initWithName:(NSString *)name URL:(NSURL *)URL appVersions:(NSArray *)appVersions 30| 0|{ 31| 0| if ((self = [super init])) { 32| 0| _name = [name copy]; 33| 0| _URL = [URL copy]; 34| 0| _appVersions = [appVersions copy]; 35| 0| } 36| 0| return self; 37| 0|} 38| | 39| |#pragma mark NSCoding 40| | 41| |+ (BOOL)supportsSecureCoding 42| 0|{ 43| 0| return YES; 44| 0|} 45| | 46| |- (id)initWithCoder:(NSCoder *)decoder 47| 0|{ 48| 0| NSString *name = [decoder decodeObjectOfClass:[NSString class] forKey:FBSDK_DIALOG_CONFIGURATION_NAME_KEY]; 49| 0| NSURL *URL = [decoder decodeObjectOfClass:[NSURL class] forKey:FBSDK_DIALOG_CONFIGURATION_URL_KEY]; 50| 0| NSSet *appVersionsClasses = [NSSet setWithObjects:[NSArray class], [NSNumber class], nil]; 51| 0| NSArray *appVersions = [decoder decodeObjectOfClasses:appVersionsClasses 52| 0| forKey:FBSDK_DIALOG_CONFIGURATION_APP_VERSIONS_KEY]; 53| 0| return [self initWithName:name URL:URL appVersions:appVersions]; 54| 0|} 55| | 56| |- (void)encodeWithCoder:(NSCoder *)encoder 57| 0|{ 58| 0| [encoder encodeObject:_appVersions forKey:FBSDK_DIALOG_CONFIGURATION_APP_VERSIONS_KEY]; 59| 0| [encoder encodeObject:_name forKey:FBSDK_DIALOG_CONFIGURATION_NAME_KEY]; 60| 0| [encoder encodeObject:_URL forKey:FBSDK_DIALOG_CONFIGURATION_URL_KEY]; 61| 0|} 62| | 63| |#pragma mark - NSCopying 64| | 65| |- (id)copyWithZone:(NSZone *)zone 66| 0|{ 67| 0| return self; 68| 0|} 69| | 70| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ServerConfiguration/FBSDKErrorConfiguration.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKErrorConfiguration.h" 20| | 21| |#import "FBSDKCoreKitBasicsImport.h" 22| |#import "FBSDKGraphRequestProtocol.h" 23| |#import "FBSDKInternalUtility.h" 24| |#import "FBSDKSettings.h" 25| | 26| |static NSString *const kErrorCategoryOther = @"other"; 27| |static NSString *const kErrorCategoryTransient = @"transient"; 28| |static NSString *const kErrorCategoryLogin = @"login"; 29| | 30| 0|#define FBSDKERRORCONFIGURATION_DICTIONARY_KEY @"configurationDictionary" 31| | 32| |@implementation FBSDKErrorConfiguration 33| |{ 34| | NSMutableDictionary *_configurationDictionary; 35| |} 36| | 37| |- (instancetype)initWithDictionary:(NSDictionary *)dictionary 38| 0|{ 39| 0| if ((self = [super init])) { 40| 0| if (dictionary) { 41| 0| _configurationDictionary = [NSMutableDictionary dictionaryWithDictionary:dictionary]; 42| 0| } else { 43| 0| _configurationDictionary = [NSMutableDictionary dictionary]; 44| 0| NSString *localizedOK = 45| 0| NSLocalizedStringWithDefaultValue( 46| 0| @"ErrorRecovery.OK", 47| 0| @"FacebookSDK", 48| 0| [FBSDKInternalUtility bundleForStrings], 49| 0| @"OK", 50| 0| @"The title of the label to start attempting error recovery" 51| 0| ); 52| 0| NSString *localizedCancel = 53| 0| NSLocalizedStringWithDefaultValue( 54| 0| @"ErrorRecovery.Cancel", 55| 0| @"FacebookSDK", 56| 0| [FBSDKInternalUtility bundleForStrings], 57| 0| @"Cancel", 58| 0| @"The title of the label to decline attempting error recovery" 59| 0| ); 60| 0| NSString *localizedTransientSuggestion = 61| 0| NSLocalizedStringWithDefaultValue( 62| 0| @"ErrorRecovery.Transient.Suggestion", 63| 0| @"FacebookSDK", 64| 0| [FBSDKInternalUtility bundleForStrings], 65| 0| @"The server is temporarily busy, please try again.", 66| 0| @"The fallback message to display to retry transient errors" 67| 0| ); 68| 0| NSString *localizedLoginRecoverableSuggestion = 69| 0| NSLocalizedStringWithDefaultValue( 70| 0| @"ErrorRecovery.Login.Suggestion", 71| 0| @"FacebookSDK", 72| 0| [FBSDKInternalUtility bundleForStrings], 73| 0| @"Please log into this app again to reconnect your Facebook account.", 74| 0| @"The fallback message to display to recover invalidated tokens" 75| 0| ); 76| 0| NSArray *fallbackArray = @[ 77| 0| @{ @"name" : @"login", 78| 0| @"items" : @[@{ @"code" : @102 }, 79| 0| @{ @"code" : @190 }], 80| 0| @"recovery_message" : localizedLoginRecoverableSuggestion, 81| 0| @"recovery_options" : @[localizedOK, localizedCancel]}, 82| 0| @{ @"name" : @"transient", 83| 0| @"items" : @[@{ @"code" : @1 }, 84| 0| @{ @"code" : @2 }, 85| 0| @{ @"code" : @4 }, 86| 0| @{ @"code" : @9 }, 87| 0| @{ @"code" : @17 }, 88| 0| @{ @"code" : @341 }], 89| 0| @"recovery_message" : localizedTransientSuggestion, 90| 0| @"recovery_options" : @[localizedOK]}, 91| 0| ]; 92| 0| [self updateWithArray:fallbackArray]; 93| 0| } 94| 0| } 95| 0| return self; 96| 0|} 97| | 98| |- (FBSDKErrorRecoveryConfiguration *)recoveryConfigurationForCode:(NSString *)code subcode:(NSString *)subcode request:(id)request 99| 0|{ 100| 0| code = code ?: @"*"; 101| 0| subcode = subcode ?: @"*"; 102| 0| FBSDKErrorRecoveryConfiguration *configuration = (_configurationDictionary[code][subcode] 103| 0| ?: _configurationDictionary[code][@"*"] 104| 0| ?: _configurationDictionary[@"*"][subcode] 105| 0| ?: _configurationDictionary[@"*"][@"*"]); 106| 0| if (configuration.errorCategory == FBSDKGraphRequestErrorRecoverable 107| 0| && [FBSDKSettings clientToken] 108| 0| && [request.parameters[@"access_token"] hasSuffix:[FBSDKSettings clientToken]]) { 109| | // do not attempt to recovery client tokens. 110| 0| return nil; 111| 0| } 112| 0| return configuration; 113| 0|} 114| | 115| |- (void)updateWithArray:(NSArray *)array 116| 0|{ 117| 0| for (NSDictionary *dictionary in [FBSDKTypeUtility arrayValue:array]) { 118| 0| [FBSDKTypeUtility dictionary:dictionary enumerateKeysAndObjectsUsingBlock:^(NSString *key, id obj, BOOL *stop) { 119| 0| FBSDKGraphRequestError category; 120| 0| NSString *action = [FBSDKTypeUtility coercedToStringValue:dictionary[@"name"]]; 121| 0| if ([action isEqualToString:kErrorCategoryOther]) { 122| 0| category = FBSDKGraphRequestErrorOther; 123| 0| } else if ([action isEqualToString:kErrorCategoryTransient]) { 124| 0| category = FBSDKGraphRequestErrorTransient; 125| 0| } else { 126| 0| category = FBSDKGraphRequestErrorRecoverable; 127| 0| } 128| 0| NSString *suggestion = dictionary[@"recovery_message"]; 129| 0| NSArray *options = dictionary[@"recovery_options"]; 130| | 131| 0| NSArray *validItems = [FBSDKTypeUtility dictionary:dictionary objectForKey:@"items" ofType:NSArray.class]; 132| 0| for (NSDictionary *codeSubcodesDictionary in validItems) { 133| 0| NSDictionary *validCodeSubcodesDictionary = [FBSDKTypeUtility dictionaryValue:codeSubcodesDictionary]; 134| 0| if (!validCodeSubcodesDictionary) { 135| 0| continue; 136| 0| } 137| | 138| 0| NSNumber *numericCode = [FBSDKTypeUtility dictionary:validCodeSubcodesDictionary objectForKey:@"code" ofType:NSNumber.class]; 139| 0| NSString *code = numericCode.stringValue; 140| 0| if (!code) { 141| 0| return; 142| 0| } 143| | 144| 0| NSMutableDictionary *currentSubcodes = self->_configurationDictionary[code]; 145| 0| if (!currentSubcodes) { 146| 0| currentSubcodes = [NSMutableDictionary dictionary]; 147| 0| [FBSDKTypeUtility dictionary:self->_configurationDictionary setObject:currentSubcodes forKey:code]; 148| 0| } 149| | 150| 0| NSArray *validSubcodes = [FBSDKTypeUtility dictionary:validCodeSubcodesDictionary objectForKey:@"subcodes" ofType:NSArray.class]; 151| 0| if (validSubcodes.count > 0) { 152| 0| for (NSNumber *subcodeNumber in validSubcodes) { 153| 0| NSNumber *validSubcodeNumber = [FBSDKTypeUtility numberValue:subcodeNumber]; 154| 0| if (validSubcodeNumber == nil) { 155| 0| continue; 156| 0| } 157| 0| [FBSDKTypeUtility dictionary:currentSubcodes setObject:[[FBSDKErrorRecoveryConfiguration alloc] 158| 0| initWithRecoveryDescription:suggestion 159| 0| optionDescriptions:options 160| 0| category:category 161| 0| recoveryActionName:action] forKey:validSubcodeNumber.stringValue]; 162| 0| } 163| 0| } else { 164| 0| [FBSDKTypeUtility dictionary:currentSubcodes setObject:[[FBSDKErrorRecoveryConfiguration alloc] 165| 0| initWithRecoveryDescription:suggestion 166| 0| optionDescriptions:options 167| 0| category:category 168| 0| recoveryActionName:action] forKey:@"*"]; 169| 0| } 170| 0| } 171| 0| }]; 172| 0| } 173| 0|} 174| | 175| |#pragma mark - NSSecureCoding 176| | 177| |+ (BOOL)supportsSecureCoding 178| 0|{ 179| 0| return YES; 180| 0|} 181| | 182| |- (id)initWithCoder:(NSCoder *)decoder 183| 0|{ 184| 0| NSSet *classes = [[NSSet alloc] initWithObjects:[NSDictionary class], [FBSDKErrorRecoveryConfiguration class], nil]; 185| 0| NSDictionary *configurationDictionary = [decoder decodeObjectOfClasses:classes 186| 0| forKey:FBSDKERRORCONFIGURATION_DICTIONARY_KEY]; 187| 0| return [self initWithDictionary:configurationDictionary]; 188| 0|} 189| | 190| |- (void)encodeWithCoder:(NSCoder *)encoder 191| 0|{ 192| 0| [encoder encodeObject:_configurationDictionary forKey:FBSDKERRORCONFIGURATION_DICTIONARY_KEY]; 193| 0|} 194| | 195| |#pragma mark - NSCopying 196| | 197| |- (id)copyWithZone:(NSZone *)zone 198| 0|{ 199| 0| return self; 200| 0|} 201| | 202| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ServerConfiguration/FBSDKErrorConfigurationProvider.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKErrorConfigurationProvider.h" 20| | 21| |#import "FBSDKServerConfigurationManager.h" 22| | 23| |@implementation FBSDKErrorConfigurationProvider 24| | 25| |- (id)errorConfiguration 26| 0|{ 27| 0| return [[FBSDKServerConfigurationManager cachedServerConfiguration] errorConfiguration] 28| 0| ?: [[FBSDKErrorConfiguration alloc] initWithDictionary:nil]; 29| 0|} 30| | 31| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ServerConfiguration/FBSDKErrorRecoveryConfiguration.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKErrorRecoveryConfiguration.h" 20| | 21| 0|#define FBSDK_ERROR_RECOVERY_CONFIGURATION_DESCRIPTION_KEY @"description" 22| 0|#define FBSDK_ERROR_RECOVERY_CONFIGURATION_OPTIONS_KEY @"options" 23| 0|#define FBSDK_ERROR_RECOVERY_CONFIGURATION_CATEGORY_KEY @"category" 24| 0|#define FBSDK_ERROR_RECOVERY_CONFIGURATION_ACTION_KEY @"action" 25| | 26| |@implementation FBSDKErrorRecoveryConfiguration 27| | 28| |- (instancetype)initWithRecoveryDescription:(NSString *)description 29| | optionDescriptions:(NSArray *)optionDescriptions 30| | category:(FBSDKGraphRequestError)category 31| | recoveryActionName:(NSString *)recoveryActionName 32| 0|{ 33| 0| if ((self = [super init])) { 34| 0| _localizedRecoveryDescription = [description copy]; 35| 0| _localizedRecoveryOptionDescriptions = [optionDescriptions copy]; 36| 0| _errorCategory = category; 37| 0| _recoveryActionName = [recoveryActionName copy]; 38| 0| } 39| 0| return self; 40| 0|} 41| | 42| |#pragma mark - NSSecureCoding 43| | 44| |+ (BOOL)supportsSecureCoding 45| 0|{ 46| 0| return YES; 47| 0|} 48| | 49| |- (id)initWithCoder:(NSCoder *)decoder 50| 0|{ 51| 0| NSString *description = [decoder decodeObjectOfClass:[NSString class] forKey:FBSDK_ERROR_RECOVERY_CONFIGURATION_DESCRIPTION_KEY]; 52| 0| NSArray *options = [decoder decodeObjectOfClass:[NSArray class] forKey:FBSDK_ERROR_RECOVERY_CONFIGURATION_OPTIONS_KEY]; 53| 0| NSNumber *category = [decoder decodeObjectOfClass:[NSNumber class] forKey:FBSDK_ERROR_RECOVERY_CONFIGURATION_CATEGORY_KEY]; 54| 0| NSString *action = [decoder decodeObjectOfClass:[NSString class] forKey:FBSDK_ERROR_RECOVERY_CONFIGURATION_ACTION_KEY]; 55| | 56| 0| return [self initWithRecoveryDescription:description 57| 0| optionDescriptions:options 58| 0| category:category.unsignedIntegerValue 59| 0| recoveryActionName:action]; 60| 0|} 61| | 62| |- (void)encodeWithCoder:(NSCoder *)encoder 63| 0|{ 64| 0| [encoder encodeObject:_localizedRecoveryDescription forKey:FBSDK_ERROR_RECOVERY_CONFIGURATION_DESCRIPTION_KEY]; 65| 0| [encoder encodeObject:_localizedRecoveryOptionDescriptions forKey:FBSDK_ERROR_RECOVERY_CONFIGURATION_OPTIONS_KEY]; 66| 0| [encoder encodeObject:@(_errorCategory) forKey:FBSDK_ERROR_RECOVERY_CONFIGURATION_CATEGORY_KEY]; 67| 0| [encoder encodeObject:_recoveryActionName forKey:FBSDK_ERROR_RECOVERY_CONFIGURATION_ACTION_KEY]; 68| 0|} 69| | 70| |#pragma mark - NSCopying 71| | 72| |- (id)copyWithZone:(NSZone *)zone 73| 0|{ 74| | // immutable 75| 0| return self; 76| 0|} 77| | 78| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ServerConfiguration/FBSDKGateKeeperManager.h: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import 20| |#import "FBSDKGateKeeperManaging.h" 21| | 22| 0|#define FBSDK_GATEKEEPER_MANAGER_CACHE_TIMEOUT (60 * 60) 23| | 24| |NS_ASSUME_NONNULL_BEGIN 25| | 26| |@protocol FBSDKSettings; 27| |@protocol FBSDKGraphRequestProviding; 28| |@protocol FBSDKGraphRequestConnectionProviding; 29| |@protocol FBSDKDataPersisting; 30| | 31| |/// typedef for FBSDKAppEventUserDataType 32| |typedef NSString *const FBSDKGateKeeperKey NS_TYPED_EXTENSIBLE_ENUM NS_SWIFT_NAME(GateKeeperManager.GateKeeperKey); 33| |typedef void (^FBSDKGKManagerBlock)(NSError * _Nullable error) 34| |NS_SWIFT_NAME(GKManagerBlock); 35| | 36| |NS_SWIFT_NAME(GateKeeperManager) 37| |@interface FBSDKGateKeeperManager : NSObject 38| | 39| |- (instancetype)init NS_UNAVAILABLE; 40| |+ (instancetype)new NS_UNAVAILABLE; 41| | 42| |/** 43| | Configures the manager with various dependencies that are required to load the gate keepers 44| | */ 45| |+ (void)configureWithSettings:(Class)settings 46| | requestProvider:(id)requestProvider 47| | connectionProvider:(id)connectionProvider 48| | store:(id)store; 49| | 50| |/** 51| | Returns the locally cached configuration. 52| | */ 53| |+ (BOOL)boolForKey:(NSString *)key defaultValue:(BOOL)defaultValue; 54| | 55| |/** 56| | Load the gate keeper configurations from server 57| | 58| | WARNING: Must call `configure` before loading gate keepers. 59| | */ 60| |+ (void)loadGateKeepers:(nullable FBSDKGKManagerBlock)completionBlock; 61| | 62| |@end 63| | 64| |NS_ASSUME_NONNULL_END /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ServerConfiguration/FBSDKGateKeeperManager.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKGateKeeperManager.h" 20| | 21| |#import 22| | 23| |#import 24| | 25| |#import "FBSDKAppEventsUtility.h" 26| |#import "FBSDKCoreKitBasicsImport.h" 27| |#import "FBSDKDataPersisting.h" 28| |#import "FBSDKGraphRequest.h" 29| |#import "FBSDKGraphRequest+Internal.h" 30| |#import "FBSDKGraphRequestConnecting.h" 31| |#import "FBSDKGraphRequestConnectionProviding.h" 32| |#import "FBSDKGraphRequestProviding.h" 33| |#import "FBSDKObjectDecoding.h" 34| |#import "FBSDKSettings.h" 35| |#import "FBSDKSettingsProtocol.h" 36| |#import "FBSDKUnarchiverProvider.h" 37| | 38| 0|#define FBSDK_GATEKEEPERS_USER_DEFAULTS_KEY @"com.facebook.sdk:GateKeepers%@" 39| | 40| 0|#define FBSDK_GATEKEEPER_APP_GATEKEEPER_EDGE @"mobile_sdk_gk" 41| 0|#define FBSDK_GATEKEEPER_APP_GATEKEEPER_FIELDS @"gatekeepers" 42| | 43| |@implementation FBSDKGateKeeperManager 44| | 45| |static BOOL _canLoadGateKeepers; 46| |static NSDictionary *_gateKeepers; 47| |static NSMutableArray *_completionBlocks; 48| |static const NSTimeInterval kTimeout = 4.0; 49| |static NSDate *_timestamp; 50| |static BOOL _loadingGateKeepers; 51| |static BOOL _requeryFinishedForAppStart; 52| |static id _requestProvider; 53| |static id _connectionProvider; 54| |static Class _settings; 55| |static id _store; 56| | 57| |#pragma mark - Public Class Methods 58| |+ (void)initialize 59| 0|{ 60| 0| if (self == [FBSDKGateKeeperManager class]) { 61| 0| _completionBlocks = [NSMutableArray array]; 62| 0| _store = nil; 63| 0| _requestProvider = nil; 64| 0| _connectionProvider = nil; 65| 0| _settings = nil; 66| 0| _canLoadGateKeepers = NO; 67| 0| } 68| 0|} 69| | 70| |+ (void)configureWithSettings:(Class)settings 71| | requestProvider:(id)requestProvider 72| | connectionProvider:(id)connectionProvider 73| | store:(id)store 74| 0|{ 75| 0| _settings = settings; 76| 0| _requestProvider = requestProvider; 77| 0| _connectionProvider = connectionProvider; 78| 0| _store = store; 79| 0| _canLoadGateKeepers = YES; 80| 0|} 81| | 82| |+ (BOOL)boolForKey:(NSString *)key defaultValue:(BOOL)defaultValue 83| 0|{ 84| 0| [self loadGateKeepers:nil]; 85| | 86| 0| return _gateKeepers[key] != nil ? [_gateKeepers[key] boolValue] : defaultValue; 87| 0|} 88| | 89| |+ (void)loadGateKeepers:(FBSDKGKManagerBlock)completionBlock 90| 0|{ 91| 0| @try { 92| 0| @synchronized(self) { 93| 0| if (!_canLoadGateKeepers) { 94| | // If we can't load the gatekeepers then it means we didn't have an opportunity 95| | // to inject our own logger type. Fall back to NSLog for the developer error. 96| 0| NSLog(@"Cannot load gate keepers before configuring."); 97| 0| return; 98| 0| } 99| | 100| 0| NSString *appID = [self.settings appID]; 101| 0| if (!appID) { 102| 0| _gateKeepers = nil; 103| 0| if (completionBlock != NULL) { 104| 0| completionBlock(nil); 105| 0| } 106| 0| return; 107| 0| } 108| | 109| 0| if (!_gateKeepers) { 110| | // load the defaults 111| 0| NSString *defaultKey = [NSString stringWithFormat:FBSDK_GATEKEEPERS_USER_DEFAULTS_KEY, 112| 0| appID]; 113| 0| NSData *data = [self.store objectForKey:defaultKey]; 114| 0| if ([data isKindOfClass:[NSData class]]) { 115| 0| id unarchiver = [FBSDKUnarchiverProvider createSecureUnarchiverFor:data]; 116| 0| @try { 117| 0| _gateKeepers = [FBSDKTypeUtility dictionaryValue: 118| 0| [unarchiver decodeObjectOfClasses: 119| 0| [NSSet setWithObjects:NSDictionary.class, NSString.class, NSNumber.class, nil] 120| 0| forKey:NSKeyedArchiveRootObjectKey]]; 121| 0| } @catch (NSException *ex) { 122| | // ignore decoding exceptions 123| 0| } 124| 0| } 125| 0| } 126| | 127| | // Query the server when the requery is not finished for app start or the timestamp is not valid 128| 0| if ([self _gateKeeperIsValid]) { 129| 0| if (completionBlock) { 130| 0| completionBlock(nil); 131| 0| } 132| 0| } else { 133| 0| [FBSDKTypeUtility array:_completionBlocks addObject:completionBlock]; 134| 0| if (!_loadingGateKeepers) { 135| 0| _loadingGateKeepers = YES; 136| 0| id request = [[self class] requestToLoadGateKeepers]; 137| | 138| | // start request with specified timeout instead of the default 180s 139| 0| id requestConnection = [self.connectionProvider createGraphRequestConnection]; 140| 0| requestConnection.timeout = kTimeout; 141| 0| [requestConnection addRequest:request completion:^(id connection, id result, NSError *error) { 142| 0| _requeryFinishedForAppStart = YES; 143| 0| [self processLoadRequestResponse:result error:error]; 144| 0| }]; 145| 0| [requestConnection start]; 146| 0| } 147| 0| } 148| 0| } 149| 0| } @catch (NSException *exception) {} 150| 0|} 151| | 152| |#pragma mark - Internal Class Methods 153| | 154| |+ (nullable id)requestToLoadGateKeepers 155| 0|{ 156| 0| NSMutableDictionary *parameters = [NSMutableDictionary new]; 157| 0| [FBSDKTypeUtility dictionary:parameters setObject:@"ios" forKey:@"platform"]; 158| 0| [FBSDKTypeUtility dictionary:parameters setObject:[self.settings sdkVersion] forKey:@"sdk_version"]; 159| 0| [FBSDKTypeUtility dictionary:parameters setObject:FBSDK_GATEKEEPER_APP_GATEKEEPER_FIELDS forKey:@"fields"]; 160| 0| [FBSDKTypeUtility dictionary:parameters setObject:[UIDevice currentDevice].systemVersion forKey:@"os_version"]; 161| | 162| 0| return [self.requestProvider createGraphRequestWithGraphPath:[NSString stringWithFormat:@"%@/%@", 163| 0| [self.settings appID], FBSDK_GATEKEEPER_APP_GATEKEEPER_EDGE] 164| 0| parameters:parameters 165| 0| tokenString:nil 166| 0| HTTPMethod:nil 167| 0| flags:FBSDKGraphRequestFlagSkipClientToken | FBSDKGraphRequestFlagDisableErrorRecovery]; 168| 0|} 169| | 170| |#pragma mark - Helper Class Methods 171| | 172| |+ (void)processLoadRequestResponse:(id)result error:(NSError *)error 173| 0|{ 174| 0| @synchronized(self) { 175| 0| _loadingGateKeepers = NO; 176| | 177| 0| if (!error) { 178| | // Update the timestamp only when there is no error 179| 0| _timestamp = [NSDate date]; 180| | 181| 0| NSMutableDictionary *gateKeeper = [_gateKeepers mutableCopy]; 182| 0| if (!gateKeeper) { 183| 0| gateKeeper = [NSMutableDictionary new]; 184| 0| } 185| 0| NSDictionary *resultDictionary = [FBSDKTypeUtility dictionaryValue:result]; 186| 0| NSDictionary *fetchedData = [FBSDKTypeUtility dictionaryValue:[resultDictionary[@"data"] firstObject]]; 187| 0| NSArray *gateKeeperList = fetchedData != nil ? [FBSDKTypeUtility arrayValue:fetchedData[FBSDK_GATEKEEPER_APP_GATEKEEPER_FIELDS]] : nil; 188| | 189| 0| if (gateKeeperList != nil) { 190| | // updates gate keeper with fetched data 191| 0| for (id gateKeeperEntry in gateKeeperList) { 192| 0| NSDictionary *entry = [FBSDKTypeUtility dictionaryValue:gateKeeperEntry]; 193| 0| NSString *key = [FBSDKTypeUtility coercedToStringValue:entry[@"key"]]; 194| 0| NSNumber *value = [FBSDKTypeUtility numberValue:entry[@"value"]]; 195| 0| if (entry != nil && key != nil && value != nil) { 196| 0| [FBSDKTypeUtility dictionary:gateKeeper setObject:value forKey:key]; 197| 0| } 198| 0| } 199| 0| _gateKeepers = [gateKeeper copy]; 200| 0| } 201| | // update the cached copy in user defaults 202| 0| NSString *defaultKey = [NSString stringWithFormat:FBSDK_GATEKEEPERS_USER_DEFAULTS_KEY, 203| 0| [self.settings appID]]; 204| | 205| | #if __IPHONE_OS_VERSION_MIN_REQUIRED >= __IPHONE_11_0 206| | NSData *data = [NSKeyedArchiver archivedDataWithRootObject:gateKeeper requiringSecureCoding:NO error:NULL]; 207| | #else 208| 0| NSData *data = [NSKeyedArchiver archivedDataWithRootObject:gateKeeper]; 209| 0| #endif 210| | 211| 0| [self.store setObject:data forKey:defaultKey]; 212| 0| } 213| | 214| 0| [self _didProcessGKFromNetwork:error]; 215| 0| } 216| 0|} 217| | 218| |+ (void)_didProcessGKFromNetwork:(NSError *)error 219| 0|{ 220| 0| NSArray *completionBlocks = [NSArray arrayWithArray:_completionBlocks]; 221| 0| [_completionBlocks removeAllObjects]; 222| 0| for (FBSDKGKManagerBlock completionBlock in completionBlocks) { 223| 0| completionBlock(error); 224| 0| } 225| 0|} 226| | 227| |+ (BOOL)_gateKeeperTimestampIsValid:(NSDate *)timestamp 228| 0|{ 229| 0| if (timestamp == nil) { 230| 0| return NO; 231| 0| } 232| 0| return ([[NSDate date] timeIntervalSinceDate:timestamp] < FBSDK_GATEKEEPER_MANAGER_CACHE_TIMEOUT); 233| 0|} 234| | 235| |+ (BOOL)_gateKeeperIsValid 236| 0|{ 237| 0| if (_requeryFinishedForAppStart && (_timestamp && [self _gateKeeperTimestampIsValid:_timestamp])) { 238| 0| return YES; 239| 0| } 240| 0| return NO; 241| 0|} 242| | 243| |+ (id)requestProvider 244| 0|{ 245| 0| return _requestProvider; 246| 0|} 247| | 248| |+ (Class)settings 249| 0|{ 250| 0| return _settings; 251| 0|} 252| | 253| |+ (id)connectionProvider 254| 0|{ 255| 0| return _connectionProvider; 256| 0|} 257| | 258| |+ (NSDictionary *)gateKeepers 259| 0|{ 260| 0| return _gateKeepers; 261| 0|} 262| | 263| |+ (id)store 264| 0|{ 265| 0| return _store; 266| 0|} 267| | 268| |// MARK: - Testability 269| | 270| |#if DEBUG 271| | 272| |+ (BOOL)canLoadGateKeepers 273| 0|{ 274| 0| return _canLoadGateKeepers; 275| 0|} 276| | 277| |+ (void)setGateKeepers:(NSDictionary *)gateKeepers 278| 0|{ 279| 0| _gateKeepers = gateKeepers; 280| 0|} 281| | 282| |+ (void)setRequeryFinishedForAppStart:(BOOL)isFinished 283| 0|{ 284| 0| _requeryFinishedForAppStart = isFinished; 285| 0|} 286| | 287| |+ (void)setTimestamp:(NSDate *)timestamp 288| 0|{ 289| 0| _timestamp = timestamp; 290| 0|} 291| | 292| |+ (BOOL)isLoadingGateKeepers 293| 0|{ 294| 0| return _loadingGateKeepers; 295| 0|} 296| | 297| |+ (void)setIsLoadingGateKeepers:(BOOL)isLoadingGateKeepers 298| 0|{ 299| 0| _loadingGateKeepers = isLoadingGateKeepers; 300| 0|} 301| | 302| |+ (void)reset 303| 0|{ 304| 0| _requestProvider = nil; 305| 0| _gateKeepers = nil; 306| 0| _settings = nil; 307| 0| _connectionProvider = nil; 308| 0| _store = nil; 309| 0| _timestamp = nil; 310| 0| _requeryFinishedForAppStart = NO; 311| 0| _completionBlocks = [NSMutableArray array]; 312| 0| _loadingGateKeepers = NO; 313| 0| _canLoadGateKeepers = NO; 314| 0|} 315| | 316| |#endif 317| | 318| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ServerConfiguration/FBSDKServerConfiguration.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKServerConfiguration.h" 20| |#import "FBSDKServerConfiguration+Internal.h" 21| | 22| |#import "FBSDKCoreKitBasicsImport.h" 23| | 24| |// one minute 25| 0|#define DEFAULT_SESSION_TIMEOUT_INTERVAL 60 26| | 27| 0|#define FBSDK_SERVER_CONFIGURATION_ADVERTISING_ID_ENABLED_KEY @"advertisingIDEnabled" 28| 0|#define FBSDK_SERVER_CONFIGURATION_APP_ID_KEY @"appID" 29| 0|#define FBSDK_SERVER_CONFIGURATION_APP_NAME_KEY @"appName" 30| 0|#define FBSDK_SERVER_CONFIGURATION_DIALOG_CONFIGS_KEY @"dialogConfigs" 31| 0|#define FBSDK_SERVER_CONFIGURATION_DIALOG_FLOWS_KEY @"dialogFlows" 32| 0|#define FBSDK_SERVER_CONFIGURATION_ERROR_CONFIGS_KEY @"errorConfigs" 33| 0|#define FBSDK_SERVER_CONFIGURATION_IMPLICIT_LOGGING_ENABLED_KEY @"implicitLoggingEnabled" 34| 0|#define FBSDK_SERVER_CONFIGURATION_DEFAULT_SHARE_MODE_KEY @"defaultShareMode" 35| 0|#define FBSDK_SERVER_CONFIGURATION_IMPLICIT_PURCHASE_LOGGING_ENABLED_KEY @"implicitPurchaseLoggingEnabled" 36| 0|#define FBSDK_SERVER_CONFIGURATION_CODELESS_EVENTS_ENABLED_KEY @"codelessEventsEnabled" 37| 0|#define FBSDK_SERVER_CONFIGURATION_LOGIN_TOOLTIP_ENABLED_KEY @"loginTooltipEnabled" 38| 0|#define FBSDK_SERVER_CONFIGURATION_LOGIN_TOOLTIP_TEXT_KEY @"loginTooltipText" 39| 0|#define FBSDK_SERVER_CONFIGURATION_TIMESTAMP_KEY @"timestamp" 40| 0|#define FBSDK_SERVER_CONFIGURATION_SESSION_TIMEOUT_INTERVAL @"sessionTimeoutInterval" 41| 0|#define FBSDK_SERVER_CONFIGURATION_LOGGING_TOKEN @"loggingToken" 42| 0|#define FBSDK_SERVER_CONFIGURATION_SMART_LOGIN_OPTIONS_KEY @"smartLoginEnabled" 43| 0|#define FBSDK_SERVER_CONFIGURATION_SMART_LOGIN_BOOKMARK_ICON_URL_KEY @"smarstLoginBookmarkIconURL" 44| 0|#define FBSDK_SERVER_CONFIGURATION_SMART_LOGIN_MENU_ICON_URL_KEY @"smarstLoginBookmarkMenuURL" 45| 0|#define FBSDK_SERVER_CONFIGURATION_UPDATE_MESSAGE_KEY @"SDKUpdateMessage" 46| 0|#define FBSDK_SERVER_CONFIGURATION_EVENT_BINDINGS @"eventBindings" 47| 0|#define FBSDK_SERVER_CONFIGURATION_RESTRICTIVE_PARAMS @"restrictiveParams" 48| 0|#define FBSDK_SERVER_CONFIGURATION_AAM_RULES @"AAMRules" 49| 0|#define FBSDK_SERVER_CONFIGURATION_SUGGESTED_EVENTS_SETTING @"suggestedEventsSetting" 50| 0|#define FBSDK_SERVER_CONFIGURATION_VERSION_KEY @"version" 51| 0|#define FBSDK_SERVER_CONFIGURATION_TRACK_UNINSTALL_ENABLED_KEY @"trackAppUninstallEnabled" 52| | 53| |#pragma mark - Dialog Names 54| | 55| |NSString *const FBSDKDialogConfigurationNameDefault = @"default"; 56| | 57| |NSString *const FBSDKDialogConfigurationNameLogin = @"login"; 58| | 59| |NSString *const FBSDKDialogConfigurationNameSharing = @"sharing"; 60| | 61| |NSString *const FBSDKDialogConfigurationNameAppInvite = @"app_invite"; 62| |NSString *const FBSDKDialogConfigurationNameGameRequest = @"game_request"; 63| |NSString *const FBSDKDialogConfigurationNameGroup = @"group"; 64| |NSString *const FBSDKDialogConfigurationNameLike = @"like"; 65| |NSString *const FBSDKDialogConfigurationNameMessage = @"message"; 66| |NSString *const FBSDKDialogConfigurationNameShare = @"share"; 67| | 68| |NSString *const FBSDKDialogConfigurationFeatureUseNativeFlow = @"use_native_flow"; 69| |NSString *const FBSDKDialogConfigurationFeatureUseSafariViewController = @"use_safari_vc"; 70| | 71| |// Increase this value when adding new fields and previous cached configurations should be 72| |// treated as stale. 73| |const NSInteger FBSDKServerConfigurationVersion = 2; 74| | 75| |@implementation FBSDKServerConfiguration 76| |{ 77| | NSDictionary *_dialogConfigurations; 78| | NSDictionary *_dialogFlows; 79| | NSInteger _version; 80| |} 81| | 82| |#pragma mark - Object Lifecycle 83| | 84| |- (instancetype) initWithAppID:(NSString *)appID 85| | appName:(NSString *)appName 86| | loginTooltipEnabled:(BOOL)loginTooltipEnabled 87| | loginTooltipText:(NSString *)loginTooltipText 88| | defaultShareMode:(NSString *)defaultShareMode 89| | advertisingIDEnabled:(BOOL)advertisingIDEnabled 90| | implicitLoggingEnabled:(BOOL)implicitLoggingEnabled 91| | implicitPurchaseLoggingEnabled:(BOOL)implicitPurchaseLoggingEnabled 92| | codelessEventsEnabled:(BOOL)codelessEventsEnabled 93| | uninstallTrackingEnabled:(BOOL)uninstallTrackingEnabled 94| | dialogConfigurations:(NSDictionary *)dialogConfigurations 95| | dialogFlows:(NSDictionary *)dialogFlows 96| | timestamp:(NSDate *)timestamp 97| | errorConfiguration:(FBSDKErrorConfiguration *)errorConfiguration 98| | sessionTimeoutInterval:(NSTimeInterval)sessionTimeoutInterval 99| | defaults:(BOOL)defaults 100| | loggingToken:(NSString *)loggingToken 101| | smartLoginOptions:(FBSDKServerConfigurationSmartLoginOptions)smartLoginOptions 102| | smartLoginBookmarkIconURL:(NSURL *)smartLoginBookmarkIconURL 103| | smartLoginMenuIconURL:(NSURL *)smartLoginMenuIconURL 104| | updateMessage:(NSString *)updateMessage 105| | eventBindings:(NSArray *)eventBindings 106| | restrictiveParams:(NSDictionary *)restrictiveParams 107| | AAMRules:(NSDictionary *)AAMRules 108| | suggestedEventsSetting:(NSDictionary *)suggestedEventsSetting 109| 0|{ 110| 0| if ((self = [super init])) { 111| 0| _appID = [appID copy]; 112| 0| _appName = [appName copy]; 113| 0| _loginTooltipEnabled = loginTooltipEnabled; 114| 0| _loginTooltipText = [loginTooltipText copy]; 115| 0| _defaultShareMode = defaultShareMode; 116| 0| _advertisingIDEnabled = advertisingIDEnabled; 117| 0| _implicitLoggingEnabled = implicitLoggingEnabled; 118| 0| _implicitPurchaseLoggingEnabled = implicitPurchaseLoggingEnabled; 119| 0| _codelessEventsEnabled = codelessEventsEnabled; 120| 0| _uninstallTrackingEnabled = uninstallTrackingEnabled; 121| 0| _dialogConfigurations = [dialogConfigurations copy]; 122| 0| _dialogFlows = [dialogFlows copy]; 123| 0| _timestamp = [timestamp copy]; 124| 0| _errorConfiguration = [errorConfiguration copy]; 125| 0| _sessionTimoutInterval = sessionTimeoutInterval ?: DEFAULT_SESSION_TIMEOUT_INTERVAL; 126| 0| _defaults = defaults; 127| 0| _loggingToken = loggingToken; 128| 0| _smartLoginOptions = smartLoginOptions; 129| 0| _smartLoginMenuIconURL = [smartLoginMenuIconURL copy]; 130| 0| _smartLoginBookmarkIconURL = [smartLoginBookmarkIconURL copy]; 131| 0| _updateMessage = [updateMessage copy]; 132| 0| _eventBindings = eventBindings; 133| 0| _restrictiveParams = restrictiveParams; 134| 0| _AAMRules = AAMRules; 135| 0| _suggestedEventsSetting = suggestedEventsSetting; 136| 0| _version = FBSDKServerConfigurationVersion; 137| 0| } 138| 0| return self; 139| 0|} 140| | 141| |+ (FBSDKServerConfiguration *)defaultServerConfigurationForAppID:(NSString *)appID 142| 0|{ 143| | // Use a default configuration while we do not have a configuration back from the server. This allows us to set 144| | // the default values for any of the dialog sets or anything else in a centralized location while we are waiting for 145| | // the server to respond. 146| 0| static FBSDKServerConfiguration *_defaultServerConfiguration = nil; 147| 0| if (![_defaultServerConfiguration.appID isEqualToString:appID]) { 148| | // Enable SFSafariViewController by default. 149| 0| NSDictionary *dialogFlows = @{ 150| 0| FBSDKDialogConfigurationNameDefault : @{ 151| 0| FBSDKDialogConfigurationFeatureUseNativeFlow : @NO, 152| 0| FBSDKDialogConfigurationFeatureUseSafariViewController : @YES, 153| 0| }, 154| 0| FBSDKDialogConfigurationNameMessage : @{ 155| 0| FBSDKDialogConfigurationFeatureUseNativeFlow : @YES, 156| 0| }, 157| 0| }; 158| 0| _defaultServerConfiguration = [[FBSDKServerConfiguration alloc] initWithAppID:appID 159| 0| appName:nil 160| 0| loginTooltipEnabled:NO 161| 0| loginTooltipText:nil 162| 0| defaultShareMode:nil 163| 0| advertisingIDEnabled:NO 164| 0| implicitLoggingEnabled:NO 165| 0| implicitPurchaseLoggingEnabled:NO 166| 0| codelessEventsEnabled:NO 167| 0| uninstallTrackingEnabled:NO 168| 0| dialogConfigurations:nil 169| 0| dialogFlows:dialogFlows 170| 0| timestamp:nil 171| 0| errorConfiguration:nil 172| 0| sessionTimeoutInterval:DEFAULT_SESSION_TIMEOUT_INTERVAL 173| 0| defaults:YES 174| 0| loggingToken:nil 175| 0| smartLoginOptions:FBSDKServerConfigurationSmartLoginOptionsUnknown 176| 0| smartLoginBookmarkIconURL:nil 177| 0| smartLoginMenuIconURL:nil 178| 0| updateMessage:nil 179| 0| eventBindings:nil 180| 0| restrictiveParams:nil 181| 0| AAMRules:nil 182| 0| suggestedEventsSetting:nil 183| 0| ]; 184| 0| } 185| 0| return _defaultServerConfiguration; 186| 0|} 187| | 188| |#pragma mark - Public Methods 189| | 190| |- (FBSDKDialogConfiguration *)dialogConfigurationForDialogName:(NSString *)dialogName 191| 0|{ 192| 0| return _dialogConfigurations[dialogName]; 193| 0|} 194| | 195| |- (BOOL)useNativeDialogForDialogName:(NSString *)dialogName 196| 0|{ 197| 0| return [self _useFeatureWithKey:FBSDKDialogConfigurationFeatureUseNativeFlow dialogName:dialogName]; 198| 0|} 199| | 200| |- (BOOL)useSafariViewControllerForDialogName:(NSString *)dialogName 201| 0|{ 202| 0| return [self _useFeatureWithKey:FBSDKDialogConfigurationFeatureUseSafariViewController dialogName:dialogName]; 203| 0|} 204| | 205| |#pragma mark - Helper Methods 206| | 207| |- (BOOL)_useFeatureWithKey:(NSString *)key dialogName:(NSString *)dialogName 208| 0|{ 209| 0| if ([dialogName isEqualToString:FBSDKDialogConfigurationNameLogin]) { 210| 0| return ((NSNumber *)(_dialogFlows[dialogName][key] 211| 0| ?: _dialogFlows[FBSDKDialogConfigurationNameDefault][key])).boolValue; 212| 0| } else { 213| 0| return ((NSNumber *)(_dialogFlows[dialogName][key] 214| 0| ?: _dialogFlows[FBSDKDialogConfigurationNameSharing][key] 215| 0| ?: _dialogFlows[FBSDKDialogConfigurationNameDefault][key])).boolValue; 216| 0| } 217| 0|} 218| | 219| |#pragma mark - NSCoding 220| | 221| |+ (BOOL)supportsSecureCoding 222| 0|{ 223| 0| return YES; 224| 0|} 225| | 226| |- (instancetype)initWithCoder:(NSCoder *)decoder 227| 0|{ 228| 0| NSString *appID = [decoder decodeObjectOfClass:[NSString class] forKey:FBSDK_SERVER_CONFIGURATION_APP_ID_KEY]; 229| 0| NSString *appName = [decoder decodeObjectOfClass:[NSString class] forKey:FBSDK_SERVER_CONFIGURATION_APP_NAME_KEY]; 230| 0| BOOL loginTooltipEnabled = [decoder decodeBoolForKey:FBSDK_SERVER_CONFIGURATION_LOGIN_TOOLTIP_ENABLED_KEY]; 231| 0| NSString *loginTooltipText = [decoder decodeObjectOfClass:[NSString class] 232| 0| forKey:FBSDK_SERVER_CONFIGURATION_LOGIN_TOOLTIP_TEXT_KEY]; 233| 0| NSString *defaultShareMode = [decoder decodeObjectOfClass:[NSString class] 234| 0| forKey:FBSDK_SERVER_CONFIGURATION_DEFAULT_SHARE_MODE_KEY]; 235| 0| BOOL advertisingIDEnabled = [decoder decodeBoolForKey:FBSDK_SERVER_CONFIGURATION_ADVERTISING_ID_ENABLED_KEY]; 236| 0| BOOL implicitLoggingEnabled = [decoder decodeBoolForKey:FBSDK_SERVER_CONFIGURATION_IMPLICIT_LOGGING_ENABLED_KEY]; 237| 0| BOOL implicitPurchaseLoggingEnabled = 238| 0| [decoder decodeBoolForKey:FBSDK_SERVER_CONFIGURATION_IMPLICIT_PURCHASE_LOGGING_ENABLED_KEY]; 239| 0| BOOL codelessEventsEnabled = 240| 0| [decoder decodeBoolForKey:FBSDK_SERVER_CONFIGURATION_CODELESS_EVENTS_ENABLED_KEY]; 241| 0| BOOL uninstallTrackingEnabled = 242| 0| [decoder decodeBoolForKey:FBSDK_SERVER_CONFIGURATION_TRACK_UNINSTALL_ENABLED_KEY]; 243| 0| FBSDKServerConfigurationSmartLoginOptions smartLoginOptions = [decoder decodeIntegerForKey:FBSDK_SERVER_CONFIGURATION_SMART_LOGIN_OPTIONS_KEY]; 244| 0| NSDate *timestamp = [decoder decodeObjectOfClass:[NSDate class] forKey:FBSDK_SERVER_CONFIGURATION_TIMESTAMP_KEY]; 245| 0| NSSet *dialogConfigurationsClasses = [[NSSet alloc] initWithObjects: 246| 0| [NSDictionary class], 247| 0| [FBSDKDialogConfiguration class], 248| 0| nil]; 249| 0| NSDictionary *dialogConfigurations = [decoder decodeObjectOfClasses:dialogConfigurationsClasses 250| 0| forKey:FBSDK_SERVER_CONFIGURATION_DIALOG_CONFIGS_KEY]; 251| 0| NSSet *dialogFlowsClasses = [[NSSet alloc] initWithObjects: 252| 0| [NSDictionary class], 253| 0| [NSString class], 254| 0| [NSNumber class], 255| 0| nil]; 256| 0| NSDictionary *dialogFlows = [decoder decodeObjectOfClasses:dialogFlowsClasses 257| 0| forKey:FBSDK_SERVER_CONFIGURATION_DIALOG_FLOWS_KEY]; 258| 0| FBSDKErrorConfiguration *errorConfiguration = [decoder decodeObjectOfClass:[FBSDKErrorConfiguration class] forKey:FBSDK_SERVER_CONFIGURATION_ERROR_CONFIGS_KEY]; 259| 0| NSTimeInterval sessionTimeoutInterval = [decoder decodeDoubleForKey:FBSDK_SERVER_CONFIGURATION_SESSION_TIMEOUT_INTERVAL]; 260| 0| NSString *loggingToken = [decoder decodeObjectOfClass:[NSString class] forKey:FBSDK_SERVER_CONFIGURATION_LOGGING_TOKEN]; 261| 0| NSURL *smartLoginBookmarkIconURL = [decoder decodeObjectOfClass:[NSURL class] forKey:FBSDK_SERVER_CONFIGURATION_SMART_LOGIN_BOOKMARK_ICON_URL_KEY]; 262| 0| NSURL *smartLoginMenuIconURL = [decoder decodeObjectOfClass:[NSURL class] forKey:FBSDK_SERVER_CONFIGURATION_SMART_LOGIN_MENU_ICON_URL_KEY]; 263| 0| NSString *updateMessage = [decoder decodeObjectOfClass:[NSString class] forKey:FBSDK_SERVER_CONFIGURATION_UPDATE_MESSAGE_KEY]; 264| 0| NSArray *eventBindings = [decoder decodeObjectOfClass:[NSArray class] forKey:FBSDK_SERVER_CONFIGURATION_EVENT_BINDINGS]; 265| 0| NSSet *dictionaryClasses = [NSSet setWithObjects: 266| 0| [NSDictionary class], 267| 0| [NSArray class], 268| 0| [NSData class], 269| 0| [NSString class], 270| 0| [NSNumber class], 271| 0| nil]; 272| 0| NSDictionary *restrictiveParams = [FBSDKTypeUtility dictionaryValue:[decoder decodeObjectOfClasses:dictionaryClasses forKey:FBSDK_SERVER_CONFIGURATION_RESTRICTIVE_PARAMS]]; 273| 0| NSDictionary *AAMRules = [FBSDKTypeUtility dictionaryValue:[decoder decodeObjectOfClasses:dictionaryClasses forKey:FBSDK_SERVER_CONFIGURATION_AAM_RULES]]; 274| 0| NSDictionary *suggestedEventsSetting = [FBSDKTypeUtility dictionaryValue:[decoder decodeObjectOfClasses:dictionaryClasses forKey:FBSDK_SERVER_CONFIGURATION_SUGGESTED_EVENTS_SETTING]]; 275| 0| NSInteger version = [decoder decodeIntegerForKey:FBSDK_SERVER_CONFIGURATION_VERSION_KEY]; 276| 0| FBSDKServerConfiguration *configuration = [self initWithAppID:appID 277| 0| appName:appName 278| 0| loginTooltipEnabled:loginTooltipEnabled 279| 0| loginTooltipText:loginTooltipText 280| 0| defaultShareMode:defaultShareMode 281| 0| advertisingIDEnabled:advertisingIDEnabled 282| 0| implicitLoggingEnabled:implicitLoggingEnabled 283| 0| implicitPurchaseLoggingEnabled:implicitPurchaseLoggingEnabled 284| 0| codelessEventsEnabled:codelessEventsEnabled 285| 0| uninstallTrackingEnabled:uninstallTrackingEnabled 286| 0| dialogConfigurations:dialogConfigurations 287| 0| dialogFlows:dialogFlows 288| 0| timestamp:timestamp 289| 0| errorConfiguration:errorConfiguration 290| 0| sessionTimeoutInterval:sessionTimeoutInterval 291| 0| defaults:NO 292| 0| loggingToken:loggingToken 293| 0| smartLoginOptions:smartLoginOptions 294| 0| smartLoginBookmarkIconURL:smartLoginBookmarkIconURL 295| 0| smartLoginMenuIconURL:smartLoginMenuIconURL 296| 0| updateMessage:updateMessage 297| 0| eventBindings:eventBindings 298| 0| restrictiveParams:restrictiveParams 299| 0| AAMRules:AAMRules 300| 0| suggestedEventsSetting:suggestedEventsSetting 301| 0| ]; 302| 0| configuration->_version = version; 303| 0| return configuration; 304| 0|} 305| | 306| |- (void)encodeWithCoder:(NSCoder *)encoder 307| 0|{ 308| 0| [encoder encodeBool:_advertisingIDEnabled forKey:FBSDK_SERVER_CONFIGURATION_ADVERTISING_ID_ENABLED_KEY]; 309| 0| [encoder encodeObject:_appID forKey:FBSDK_SERVER_CONFIGURATION_APP_ID_KEY]; 310| 0| [encoder encodeObject:_appName forKey:FBSDK_SERVER_CONFIGURATION_APP_NAME_KEY]; 311| 0| [encoder encodeObject:_defaultShareMode forKey:FBSDK_SERVER_CONFIGURATION_DEFAULT_SHARE_MODE_KEY]; 312| 0| [encoder encodeObject:_dialogConfigurations forKey:FBSDK_SERVER_CONFIGURATION_DIALOG_CONFIGS_KEY]; 313| 0| [encoder encodeObject:_dialogFlows forKey:FBSDK_SERVER_CONFIGURATION_DIALOG_FLOWS_KEY]; 314| 0| [encoder encodeObject:_errorConfiguration forKey:FBSDK_SERVER_CONFIGURATION_ERROR_CONFIGS_KEY]; 315| 0| [encoder encodeBool:_implicitLoggingEnabled forKey:FBSDK_SERVER_CONFIGURATION_IMPLICIT_LOGGING_ENABLED_KEY]; 316| 0| [encoder encodeBool:_implicitPurchaseLoggingEnabled 317| 0| forKey:FBSDK_SERVER_CONFIGURATION_IMPLICIT_PURCHASE_LOGGING_ENABLED_KEY]; 318| 0| [encoder encodeBool:_codelessEventsEnabled 319| 0| forKey:FBSDK_SERVER_CONFIGURATION_CODELESS_EVENTS_ENABLED_KEY]; 320| 0| [encoder encodeBool:_loginTooltipEnabled forKey:FBSDK_SERVER_CONFIGURATION_LOGIN_TOOLTIP_ENABLED_KEY]; 321| 0| [encoder encodeBool:_uninstallTrackingEnabled 322| 0| forKey:FBSDK_SERVER_CONFIGURATION_TRACK_UNINSTALL_ENABLED_KEY]; 323| 0| [encoder encodeObject:_loginTooltipText forKey:FBSDK_SERVER_CONFIGURATION_LOGIN_TOOLTIP_TEXT_KEY]; 324| 0| [encoder encodeObject:_timestamp forKey:FBSDK_SERVER_CONFIGURATION_TIMESTAMP_KEY]; 325| 0| [encoder encodeDouble:_sessionTimoutInterval forKey:FBSDK_SERVER_CONFIGURATION_SESSION_TIMEOUT_INTERVAL]; 326| 0| [encoder encodeObject:_loggingToken forKey:FBSDK_SERVER_CONFIGURATION_LOGGING_TOKEN]; 327| 0| [encoder encodeInteger:_smartLoginOptions forKey:FBSDK_SERVER_CONFIGURATION_SMART_LOGIN_OPTIONS_KEY]; 328| 0| [encoder encodeObject:_smartLoginBookmarkIconURL forKey:FBSDK_SERVER_CONFIGURATION_SMART_LOGIN_BOOKMARK_ICON_URL_KEY]; 329| 0| [encoder encodeObject:_smartLoginMenuIconURL forKey:FBSDK_SERVER_CONFIGURATION_SMART_LOGIN_MENU_ICON_URL_KEY]; 330| 0| [encoder encodeObject:_updateMessage forKey:FBSDK_SERVER_CONFIGURATION_UPDATE_MESSAGE_KEY]; 331| 0| [encoder encodeObject:_eventBindings forKey:FBSDK_SERVER_CONFIGURATION_EVENT_BINDINGS]; 332| 0| [encoder encodeObject:_restrictiveParams forKey:FBSDK_SERVER_CONFIGURATION_RESTRICTIVE_PARAMS]; 333| 0| [encoder encodeObject:_AAMRules forKey:FBSDK_SERVER_CONFIGURATION_AAM_RULES]; 334| 0| [encoder encodeObject:_suggestedEventsSetting forKey:FBSDK_SERVER_CONFIGURATION_SUGGESTED_EVENTS_SETTING]; 335| 0| [encoder encodeInteger:_version forKey:FBSDK_SERVER_CONFIGURATION_VERSION_KEY]; 336| 0|} 337| | 338| |#pragma mark - NSCopying 339| | 340| |- (instancetype)copyWithZone:(NSZone *)zone 341| 0|{ 342| 0| return self; 343| 0|} 344| | 345| |// Private accessors for unit tests 346| |- (NSDictionary *)dialogConfigurations 347| 0|{ 348| 0| return _dialogConfigurations; 349| 0|} 350| | 351| |- (NSDictionary *)dialogFlows 352| 0|{ 353| 0| return _dialogFlows; 354| 0|} 355| | 356| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ServerConfiguration/FBSDKServerConfigurationManager.h: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import 20| | 21| |#import "FBSDKServerConfiguration.h" 22| |#import "FBSDKServerConfigurationProviding.h" 23| | 24| 0|#define FBSDK_SERVER_CONFIGURATION_MANAGER_CACHE_TIMEOUT (60 * 60) 25| | 26| | 27| |NS_SWIFT_NAME(ServerConfigurationManager) 28| |@interface FBSDKServerConfigurationManager : NSObject 29| | 30| |/** 31| | Returns the locally cached configuration. 32| | 33| | The result will be valid for the appID from FBSDKSettings, but may be expired. A network request will be 34| | initiated to update the configuration if a valid and unexpired configuration is not available. 35| | */ 36| |+ (FBSDKServerConfiguration *)cachedServerConfiguration; 37| | 38| |/** 39| | Executes the completionBlock with a valid and current configuration when it is available. 40| | 41| | This method will use a cached configuration if it is valid and not expired. 42| | */ 43| |+ (void)loadServerConfigurationWithCompletionBlock:(FBSDKServerConfigurationBlock)completionBlock; 44| | 45| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ServerConfiguration/FBSDKServerConfigurationManager.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKServerConfigurationManager+Internal.h" 20| | 21| |#import 22| | 23| |#import "FBSDKAppEventsUtility.h" 24| |#import "FBSDKCoreKitBasicsImport.h" 25| |#import "FBSDKGraphRequest.h" 26| |#import "FBSDKGraphRequest+Internal.h" 27| |#import "FBSDKGraphRequestConnection.h" 28| |#import "FBSDKGraphRequestConnection+GraphRequestConnecting.h" 29| |#import "FBSDKImageDownloader.h" 30| |#import "FBSDKInternalUtility.h" 31| |#import "FBSDKLogger.h" 32| |#import "FBSDKObjectDecoding.h" 33| |#import "FBSDKServerConfiguration+Internal.h" 34| |#import "FBSDKSettings.h" 35| |#import "FBSDKUnarchiverProvider.h" 36| | 37| 0|#define FBSDK_SERVER_CONFIGURATION_USER_DEFAULTS_KEY @"com.facebook.sdk:serverConfiguration%@" 38| | 39| 0|#define FBSDK_SERVER_CONFIGURATION_APP_EVENTS_FEATURES_FIELD @"app_events_feature_bitmask" 40| 0|#define FBSDK_SERVER_CONFIGURATION_APP_NAME_FIELD @"name" 41| 0|#define FBSDK_SERVER_CONFIGURATION_DEFAULT_SHARE_MODE_FIELD @"default_share_mode" 42| 0|#define FBSDK_SERVER_CONFIGURATION_DIALOG_CONFIGS_FIELD @"ios_dialog_configs" 43| 0|#define FBSDK_SERVER_CONFIGURATION_DIALOG_FLOWS_FIELD @"ios_sdk_dialog_flows" 44| 0|#define FBSDK_SERVER_CONFIGURATION_ERROR_CONFIGURATION_FIELD @"ios_sdk_error_categories" 45| 0|#define FBSDK_SERVER_CONFIGURATION_IMPLICIT_LOGGING_ENABLED_FIELD @"supports_implicit_sdk_logging" 46| 0|#define FBSDK_SERVER_CONFIGURATION_LOGIN_TOOLTIP_ENABLED_FIELD @"gdpv4_nux_enabled" 47| 0|#define FBSDK_SERVER_CONFIGURATION_LOGIN_TOOLTIP_TEXT_FIELD @"gdpv4_nux_content" 48| 0|#define FBSDK_SERVER_CONFIGURATION_SESSION_TIMEOUT_FIELD @"app_events_session_timeout" 49| 0|#define FBSDK_SERVER_CONFIGURATION_LOGGIN_TOKEN_FIELD @"logging_token" 50| 0|#define FBSDK_SERVER_CONFIGURATION_SMART_LOGIN_OPTIONS_FIELD @"seamless_login" 51| 0|#define FBSDK_SERVER_CONFIGURATION_SMART_LOGIN_BOOKMARK_ICON_URL_FIELD @"smart_login_bookmark_icon_url" 52| 0|#define FBSDK_SERVER_CONFIGURATION_SMART_LOGIN_MENU_ICON_URL_FIELD @"smart_login_menu_icon_url" 53| 0|#define FBSDK_SERVER_CONFIGURATION_UPDATE_MESSAGE_FIELD @"sdk_update_message" 54| 0|#define FBSDK_SERVER_CONFIGURATION_EVENT_BINDINGS_FIELD @"auto_event_mapping_ios" 55| 0|#define FBSDK_SERVER_CONFIGURATION_RESTRICTIVE_PARAMS_FIELD @"restrictive_data_filter_params" 56| 0|#define FBSDK_SERVER_CONFIGURATION_AAM_RULES_FIELD @"aam_rules" 57| 0|#define FBSDK_SERVER_CONFIGURATION_SUGGESTED_EVENTS_SETTING_FIELD @"suggested_events_setting" 58| |#define FBSDK_SERVER_CONFIGURATION_MONITORING_CONFIG_FIELD @"monitoringConfiguration" 59| | 60| |@implementation FBSDKServerConfigurationManager 61| | 62| |static NSMutableArray *_completionBlocks; 63| |static BOOL _loadingServerConfiguration; 64| |static FBSDKServerConfiguration *_serverConfiguration; 65| |static NSError *_serverConfigurationError; 66| |static NSDate *_serverConfigurationErrorTimestamp; 67| |static const NSTimeInterval kTimeout = 4.0; 68| |static BOOL _requeryFinishedForAppStart; 69| | 70| |#if DEBUG 71| |static BOOL _printedUpdateMessage; 72| |#endif 73| | 74| |typedef NS_OPTIONS(NSUInteger, FBSDKServerConfigurationManagerAppEventsFeatures) 75| |{ 76| | FBSDKServerConfigurationManagerAppEventsFeaturesNone = 0, 77| | FBSDKServerConfigurationManagerAppEventsFeaturesAdvertisingIDEnabled = 1 << 0, 78| | FBSDKServerConfigurationManagerAppEventsFeaturesImplicitPurchaseLoggingEnabled = 1 << 1, 79| | FBSDKServerConfigurationManagerAppEventsFeaturesCodelessEventsTriggerEnabled = 1 << 5, 80| | FBSDKServerConfigurationManagerAppEventsFeaturesUninstallTrackingEnabled = 1 << 7, 81| |}; 82| | 83| |#pragma mark - Public Class Methods 84| | 85| |+ (void)initialize 86| 0|{ 87| 0| if (self == [FBSDKServerConfigurationManager class]) { 88| 0| _completionBlocks = [NSMutableArray new]; 89| 0| } 90| 0|} 91| | 92| |+ (void)clearCache 93| 0|{ 94| 0| _serverConfiguration = nil; 95| 0| _serverConfigurationError = nil; 96| 0| _serverConfigurationErrorTimestamp = nil; 97| 0| NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults]; 98| 0| NSString *defaultsKey = [NSString stringWithFormat:FBSDK_SERVER_CONFIGURATION_USER_DEFAULTS_KEY, [FBSDKSettings appID]]; 99| 0| [defaults removeObjectForKey:defaultsKey]; 100| 0| [defaults synchronize]; 101| 0|} 102| | 103| |+ (FBSDKServerConfiguration *)cachedServerConfiguration 104| 0|{ 105| 0| NSString *appID = [FBSDKSettings appID]; 106| 0| @synchronized(self) { 107| | // load the server configuration if we don't have it already 108| 0| [self loadServerConfigurationWithCompletionBlock:nil]; 109| | 110| | // use whatever configuration we have or the default 111| 0| return _serverConfiguration ?: [FBSDKServerConfiguration defaultServerConfigurationForAppID:appID]; 112| 0| } 113| 0|} 114| | 115| |#pragma clang diagnostic push 116| |#pragma clang diagnostic ignored "-Wdeprecated-declarations" 117| |+ (void)loadServerConfigurationWithCompletionBlock:(FBSDKServerConfigurationBlock)completionBlock 118| 0|{ 119| 0| @try { 120| 0| void (^loadBlock)(void) = nil; 121| 0| NSString *appID = [FBSDKSettings appID]; 122| 0| @synchronized(self) { 123| | // validate the cached configuration has the correct appID 124| 0| if (_serverConfiguration && ![_serverConfiguration.appID isEqualToString:appID]) { 125| 0| _serverConfiguration = nil; 126| 0| _serverConfigurationError = nil; 127| 0| _serverConfigurationErrorTimestamp = nil; 128| 0| } 129| | 130| | // load the configuration from NSUserDefaults 131| 0| if (!_serverConfiguration) { 132| | // load the defaults 133| 0| NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults]; 134| 0| NSString *defaultsKey = [NSString stringWithFormat:FBSDK_SERVER_CONFIGURATION_USER_DEFAULTS_KEY, appID]; 135| 0| NSData *data = [defaults objectForKey:defaultsKey]; 136| 0| if ([data isKindOfClass:[NSData class]]) { 137| | // decode the configuration 138| 0| id unarchiver = [FBSDKUnarchiverProvider createSecureUnarchiverFor:data]; 139| 0| FBSDKServerConfiguration *serverConfiguration = nil; 140| 0| @try { 141| 0| serverConfiguration = [unarchiver decodeObjectOfClass:[FBSDKServerConfiguration class] forKey:NSKeyedArchiveRootObjectKey]; 142| 0| } @catch (NSException *ex) { 143| | // Ignore decoding error 144| 0| } @finally { 145| | // ensure that the configuration points to the current appID 146| 0| if ([serverConfiguration.appID isEqualToString:appID]) { 147| 0| _serverConfiguration = serverConfiguration; 148| 0| } 149| 0| } 150| 0| } 151| 0| } 152| | 153| 0| if (_requeryFinishedForAppStart 154| 0| && ((_serverConfiguration && [self _serverConfigurationTimestampIsValid:_serverConfiguration.timestamp] && _serverConfiguration.version >= FBSDKServerConfigurationVersion))) { 155| | // we have a valid server configuration, use that 156| 0| loadBlock = [self _wrapperBlockForLoadBlock:completionBlock]; 157| 0| } else { 158| | // hold onto the completion block 159| 0| [FBSDKTypeUtility array:_completionBlocks addObject:[completionBlock copy]]; 160| | 161| | // check if we are already loading 162| 0| if (!_loadingServerConfiguration) { 163| | // load the configuration from the network 164| 0| _loadingServerConfiguration = YES; 165| 0| FBSDKGraphRequest *request = [[self class] requestToLoadServerConfiguration:appID]; 166| | 167| | // start request with specified timeout instead of the default 180s 168| 0| id requestConnection = [FBSDKGraphRequestConnection new]; 169| 0| requestConnection.timeout = kTimeout; 170| 0| [requestConnection addRequest:request completion:^(id connection, id result, NSError *error) { 171| 0| _requeryFinishedForAppStart = YES; 172| 0| [self processLoadRequestResponse:result error:error appID:appID]; 173| 0| }]; 174| 0| [requestConnection start]; 175| 0| } 176| 0| } 177| 0| } 178| | 179| 0| if (loadBlock) { 180| 0| loadBlock(); 181| 0| } 182| 0| } @catch (NSException *exception) {} 183| 0|} 184| | 185| |#pragma clang diagnostic pop 186| | 187| |#pragma mark - Internal Class Methods 188| | 189| |+ (void)processLoadRequestResponse:(id)result error:(NSError *)error appID:(NSString *)appID 190| 0|{ 191| 0| @try { 192| 0| if (error) { 193| 0| [self _didProcessConfigurationFromNetwork:nil appID:appID error:error]; 194| 0| return; 195| 0| } 196| | 197| 0| NSDictionary *resultDictionary = [FBSDKTypeUtility dictionaryValue:result]; 198| 0| NSUInteger appEventsFeatures = [FBSDKTypeUtility unsignedIntegerValue:resultDictionary[FBSDK_SERVER_CONFIGURATION_APP_EVENTS_FEATURES_FIELD]]; 199| 0| BOOL advertisingIDEnabled = (appEventsFeatures & FBSDKServerConfigurationManagerAppEventsFeaturesAdvertisingIDEnabled) != 0; 200| 0| BOOL implicitPurchaseLoggingEnabled = (appEventsFeatures & FBSDKServerConfigurationManagerAppEventsFeaturesImplicitPurchaseLoggingEnabled) != 0; 201| 0| BOOL codelessEventsEnabled = (appEventsFeatures & FBSDKServerConfigurationManagerAppEventsFeaturesCodelessEventsTriggerEnabled) != 0; 202| 0| BOOL uninstallTrackingEnabled = (appEventsFeatures & FBSDKServerConfigurationManagerAppEventsFeaturesUninstallTrackingEnabled) != 0; 203| 0| NSString *appName = [FBSDKTypeUtility coercedToStringValue:resultDictionary[FBSDK_SERVER_CONFIGURATION_APP_NAME_FIELD]]; 204| 0| BOOL loginTooltipEnabled = [FBSDKTypeUtility boolValue:resultDictionary[FBSDK_SERVER_CONFIGURATION_LOGIN_TOOLTIP_ENABLED_FIELD]]; 205| 0| NSString *loginTooltipText = [FBSDKTypeUtility coercedToStringValue:resultDictionary[FBSDK_SERVER_CONFIGURATION_LOGIN_TOOLTIP_TEXT_FIELD]]; 206| 0| NSString *defaultShareMode = [FBSDKTypeUtility coercedToStringValue:resultDictionary[FBSDK_SERVER_CONFIGURATION_DEFAULT_SHARE_MODE_FIELD]]; 207| 0| BOOL implicitLoggingEnabled = [FBSDKTypeUtility boolValue:resultDictionary[FBSDK_SERVER_CONFIGURATION_IMPLICIT_LOGGING_ENABLED_FIELD]]; 208| 0| NSDictionary *dialogConfigurations = [FBSDKTypeUtility dictionaryValue:resultDictionary[FBSDK_SERVER_CONFIGURATION_DIALOG_CONFIGS_FIELD]]; 209| 0| dialogConfigurations = [self _parseDialogConfigurations:dialogConfigurations]; 210| 0| NSDictionary *dialogFlows = [FBSDKTypeUtility dictionaryValue:resultDictionary[FBSDK_SERVER_CONFIGURATION_DIALOG_FLOWS_FIELD]]; 211| 0| FBSDKErrorConfiguration *errorConfiguration = [[FBSDKErrorConfiguration alloc] initWithDictionary:nil]; 212| 0| [errorConfiguration updateWithArray:resultDictionary[FBSDK_SERVER_CONFIGURATION_ERROR_CONFIGURATION_FIELD]]; 213| 0| NSTimeInterval sessionTimeoutInterval = [FBSDKTypeUtility timeIntervalValue:resultDictionary[FBSDK_SERVER_CONFIGURATION_SESSION_TIMEOUT_FIELD]]; 214| 0| NSString *loggingToken = [FBSDKTypeUtility coercedToStringValue:resultDictionary[FBSDK_SERVER_CONFIGURATION_LOGGIN_TOKEN_FIELD]]; 215| 0| FBSDKServerConfigurationSmartLoginOptions smartLoginOptions = [FBSDKTypeUtility integerValue:resultDictionary[FBSDK_SERVER_CONFIGURATION_SMART_LOGIN_OPTIONS_FIELD]]; 216| 0| NSURL *smartLoginBookmarkIconURL = [FBSDKTypeUtility URLValue:resultDictionary[FBSDK_SERVER_CONFIGURATION_SMART_LOGIN_BOOKMARK_ICON_URL_FIELD]]; 217| 0| NSURL *smartLoginMenuIconURL = [FBSDKTypeUtility URLValue:resultDictionary[FBSDK_SERVER_CONFIGURATION_SMART_LOGIN_MENU_ICON_URL_FIELD]]; 218| 0| NSString *updateMessage = [FBSDKTypeUtility coercedToStringValue:resultDictionary[FBSDK_SERVER_CONFIGURATION_UPDATE_MESSAGE_FIELD]]; 219| 0| NSArray *eventBindings = [FBSDKTypeUtility arrayValue:resultDictionary[FBSDK_SERVER_CONFIGURATION_EVENT_BINDINGS_FIELD]]; 220| 0| NSDictionary *restrictiveParams = [FBSDKBasicUtility objectForJSONString:resultDictionary[FBSDK_SERVER_CONFIGURATION_RESTRICTIVE_PARAMS_FIELD] error:nil]; 221| 0| NSDictionary *AAMRules = [FBSDKBasicUtility objectForJSONString:resultDictionary[FBSDK_SERVER_CONFIGURATION_AAM_RULES_FIELD] error:nil]; 222| 0| NSDictionary *suggestedEventsSetting = [FBSDKBasicUtility objectForJSONString:resultDictionary[FBSDK_SERVER_CONFIGURATION_SUGGESTED_EVENTS_SETTING_FIELD] error:nil]; 223| 0| FBSDKServerConfiguration *serverConfiguration = [[FBSDKServerConfiguration alloc] initWithAppID:appID 224| 0| appName:appName 225| 0| loginTooltipEnabled:loginTooltipEnabled 226| 0| loginTooltipText:loginTooltipText 227| 0| defaultShareMode:defaultShareMode 228| 0| advertisingIDEnabled:advertisingIDEnabled 229| 0| implicitLoggingEnabled:implicitLoggingEnabled 230| 0| implicitPurchaseLoggingEnabled:implicitPurchaseLoggingEnabled 231| 0| codelessEventsEnabled:codelessEventsEnabled 232| 0| uninstallTrackingEnabled:uninstallTrackingEnabled 233| 0| dialogConfigurations:dialogConfigurations 234| 0| dialogFlows:dialogFlows 235| 0| timestamp:[NSDate date] 236| 0| errorConfiguration:errorConfiguration 237| 0| sessionTimeoutInterval:sessionTimeoutInterval 238| 0| defaults:NO 239| 0| loggingToken:loggingToken 240| 0| smartLoginOptions:smartLoginOptions 241| 0| smartLoginBookmarkIconURL:smartLoginBookmarkIconURL 242| 0| smartLoginMenuIconURL:smartLoginMenuIconURL 243| 0| updateMessage:updateMessage 244| 0| eventBindings:eventBindings 245| 0| restrictiveParams:restrictiveParams 246| 0| AAMRules:AAMRules 247| 0| suggestedEventsSetting:suggestedEventsSetting]; 248| | #if TARGET_OS_TV 249| | // don't download icons more than once a day. 250| | static const NSTimeInterval kSmartLoginIconsTTL = 60 * 60 * 24; 251| | 252| | BOOL smartLoginEnabled = (smartLoginOptions & FBSDKServerConfigurationSmartLoginOptionsEnabled); 253| | // for TVs go ahead and prime the images 254| | if (smartLoginEnabled 255| | && smartLoginMenuIconURL 256| | && smartLoginBookmarkIconURL) { 257| | [[FBSDKImageDownloader sharedInstance] downloadImageWithURL:serverConfiguration.smartLoginBookmarkIconURL 258| | ttl:kSmartLoginIconsTTL 259| | completion:nil]; 260| | [[FBSDKImageDownloader sharedInstance] downloadImageWithURL:serverConfiguration.smartLoginMenuIconURL 261| | ttl:kSmartLoginIconsTTL 262| | completion:nil]; 263| | } 264| | #endif 265| 0| [self _didProcessConfigurationFromNetwork:serverConfiguration appID:appID error:nil]; 266| 0| } @catch (NSException *exception) {} 267| 0|} 268| | 269| |+ (FBSDKGraphRequest *)requestToLoadServerConfiguration:(NSString *)appID 270| 0|{ 271| 0| NSOperatingSystemVersion operatingSystemVersion = [FBSDKInternalUtility operatingSystemVersion]; 272| 0| NSString *osVersion = [NSString stringWithFormat:@"%ti.%ti.%ti", 273| 0| operatingSystemVersion.majorVersion, 274| 0| operatingSystemVersion.minorVersion, 275| 0| operatingSystemVersion.patchVersion]; 276| 0| NSString *dialogFlowsField = [NSString stringWithFormat:@"%@.os_version(%@)", 277| 0| FBSDK_SERVER_CONFIGURATION_DIALOG_FLOWS_FIELD, 278| 0| osVersion]; 279| 0| NSArray *fields = @[FBSDK_SERVER_CONFIGURATION_APP_EVENTS_FEATURES_FIELD, 280| 0| FBSDK_SERVER_CONFIGURATION_APP_NAME_FIELD, 281| 0| FBSDK_SERVER_CONFIGURATION_DEFAULT_SHARE_MODE_FIELD, 282| 0| FBSDK_SERVER_CONFIGURATION_DIALOG_CONFIGS_FIELD, 283| 0| dialogFlowsField, 284| 0| FBSDK_SERVER_CONFIGURATION_ERROR_CONFIGURATION_FIELD, 285| 0| FBSDK_SERVER_CONFIGURATION_IMPLICIT_LOGGING_ENABLED_FIELD, 286| 0| FBSDK_SERVER_CONFIGURATION_LOGIN_TOOLTIP_ENABLED_FIELD, 287| 0| FBSDK_SERVER_CONFIGURATION_LOGIN_TOOLTIP_TEXT_FIELD, 288| 0| FBSDK_SERVER_CONFIGURATION_SESSION_TIMEOUT_FIELD, 289| 0| FBSDK_SERVER_CONFIGURATION_LOGGIN_TOKEN_FIELD, 290| 0| FBSDK_SERVER_CONFIGURATION_RESTRICTIVE_PARAMS_FIELD, 291| 0| FBSDK_SERVER_CONFIGURATION_AAM_RULES_FIELD, 292| 0| FBSDK_SERVER_CONFIGURATION_SUGGESTED_EVENTS_SETTING_FIELD 293| 0| #if !TARGET_OS_TV 294| 0| , FBSDK_SERVER_CONFIGURATION_EVENT_BINDINGS_FIELD 295| 0| #endif 296| 0| #ifdef DEBUG 297| 0| , FBSDK_SERVER_CONFIGURATION_UPDATE_MESSAGE_FIELD 298| 0| #endif 299| | #if TARGET_OS_TV 300| | , FBSDK_SERVER_CONFIGURATION_SMART_LOGIN_OPTIONS_FIELD, 301| | FBSDK_SERVER_CONFIGURATION_SMART_LOGIN_BOOKMARK_ICON_URL_FIELD, 302| | FBSDK_SERVER_CONFIGURATION_SMART_LOGIN_MENU_ICON_URL_FIELD 303| | #endif 304| 0| ]; 305| 0| NSDictionary *parameters = @{ @"fields" : [fields componentsJoinedByString:@","], 306| 0| @"os_version" : osVersion}; 307| | 308| 0| FBSDKGraphRequest *request = [[FBSDKGraphRequest alloc] initWithGraphPath:appID 309| 0| parameters:parameters 310| 0| tokenString:nil 311| 0| HTTPMethod:nil 312| 0| flags:FBSDKGraphRequestFlagSkipClientToken | FBSDKGraphRequestFlagDisableErrorRecovery]; 313| 0| return request; 314| 0|} 315| | 316| |#pragma mark - Helper Class Methods 317| | 318| |+ (void)_didProcessConfigurationFromNetwork:(FBSDKServerConfiguration *)serverConfiguration 319| | appID:(NSString *)appID 320| | error:(NSError *)error 321| 0|{ 322| 0| NSMutableArray *completionBlocks = [NSMutableArray new]; 323| 0| @synchronized(self) { 324| 0| if (error) { 325| | // Only set the error if we don't have previously fetched app settings. 326| | // (i.e., if we have app settings and a new call gets an error, we'll 327| | // ignore the error and surface the last successfully fetched settings). 328| 0| if (_serverConfiguration && [_serverConfiguration.appID isEqualToString:appID]) { 329| | // We have older app settings but the refresh received an error. 330| | // Log and ignore the error. 331| 0| NSString *msg = [NSString stringWithFormat:@"loadServerConfigurationWithCompletionBlock failed with %@", error]; 332| 0| [FBSDKLogger singleShotLogEntry:FBSDKLoggingBehaviorInformational 333| 0| logEntry:msg]; 334| 0| } else { 335| 0| _serverConfiguration = nil; 336| 0| } 337| 0| _serverConfigurationError = error; 338| 0| _serverConfigurationErrorTimestamp = [NSDate date]; 339| 0| } else { 340| 0| _serverConfiguration = serverConfiguration; 341| 0| _serverConfigurationError = nil; 342| 0| _serverConfigurationErrorTimestamp = nil; 343| | 344| 0| #ifdef DEBUG 345| 0| NSString *updateMessage = _serverConfiguration.updateMessage; 346| 0| if (updateMessage && updateMessage.length > 0 && !_printedUpdateMessage) { 347| 0| _printedUpdateMessage = YES; 348| 0| [FBSDKLogger singleShotLogEntry:FBSDKLoggingBehaviorInformational logEntry:updateMessage]; 349| 0| } 350| 0| #endif 351| 0| } 352| | 353| | // update the cached copy in NSUserDefaults 354| 0| NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults]; 355| 0| NSString *defaultsKey = [NSString stringWithFormat:FBSDK_SERVER_CONFIGURATION_USER_DEFAULTS_KEY, appID]; 356| 0| if (serverConfiguration) { 357| 0| #pragma clang diagnostic push 358| 0| #pragma clang diagnostic ignored "-Wdeprecated-declarations" 359| 0| NSData *data = [NSKeyedArchiver archivedDataWithRootObject:serverConfiguration]; 360| 0| #pragma clang diagnostic pop 361| 0| [defaults setObject:data forKey:defaultsKey]; 362| 0| } 363| | 364| | // wrap the completion blocks 365| 0| for (FBSDKServerConfigurationBlock completionBlock in _completionBlocks) { 366| 0| [FBSDKTypeUtility array:completionBlocks addObject:[self _wrapperBlockForLoadBlock:completionBlock]]; 367| 0| } 368| 0| [_completionBlocks removeAllObjects]; 369| 0| _loadingServerConfiguration = NO; 370| 0| } 371| | 372| | // release the lock before calling out of this class 373| 0| for (void (^completionBlock)(void) in completionBlocks) { 374| 0| completionBlock(); 375| 0| } 376| 0|} 377| | 378| |+ (NSDictionary *)_parseDialogConfigurations:(NSDictionary *)dictionary 379| 0|{ 380| 0| NSMutableDictionary *dialogConfigurations = [NSMutableDictionary new]; 381| 0| NSArray *dialogConfigurationsArray = [FBSDKTypeUtility arrayValue:dictionary[@"data"]]; 382| 0| for (id dialogConfiguration in dialogConfigurationsArray) { 383| 0| NSDictionary *dialogConfigurationDictionary = [FBSDKTypeUtility dictionaryValue:dialogConfiguration]; 384| 0| if (dialogConfigurationDictionary) { 385| 0| NSString *name = [FBSDKTypeUtility coercedToStringValue:dialogConfigurationDictionary[@"name"]]; 386| 0| if (name.length) { 387| 0| NSURL *URL = [FBSDKTypeUtility URLValue:dialogConfigurationDictionary[@"url"]]; 388| 0| NSArray *appVersions = [FBSDKTypeUtility arrayValue:dialogConfigurationDictionary[@"versions"]]; 389| 0| [FBSDKTypeUtility dictionary:dialogConfigurations setObject:[[FBSDKDialogConfiguration alloc] initWithName:name 390| 0| URL:URL 391| 0| appVersions:appVersions] forKey:name]; 392| 0| } 393| 0| } 394| 0| } 395| 0| return dialogConfigurations; 396| 0|} 397| | 398| |+ (BOOL)_serverConfigurationTimestampIsValid:(NSDate *)timestamp 399| 0|{ 400| 0| return ([[NSDate date] timeIntervalSinceDate:timestamp] < FBSDK_SERVER_CONFIGURATION_MANAGER_CACHE_TIMEOUT); 401| 0|} 402| | 403| |+ (FBSDKCodeBlock)_wrapperBlockForLoadBlock:(FBSDKServerConfigurationBlock)loadBlock 404| 0|{ 405| 0| if (!loadBlock) { 406| 0| return nil; 407| 0| } 408| | 409| | // create local vars to capture the current values from the ivars to allow this wrapper to be called outside of a lock 410| 0| FBSDKServerConfiguration *serverConfiguration; 411| 0| NSError *serverConfigurationError; 412| 0| @synchronized(self) { 413| 0| serverConfiguration = _serverConfiguration; 414| 0| serverConfigurationError = _serverConfigurationError; 415| 0| } 416| 0| return ^{ 417| 0| loadBlock(serverConfiguration, serverConfigurationError); 418| 0| }; 419| 0|} 420| | 421| |#pragma mark - Object Lifecycle 422| | 423| |- (instancetype)init 424| 0|{ 425| 0| return nil; 426| 0|} 427| | 428| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/TokenCaching/FBSDKAccessTokenExpirer.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKAccessTokenExpirer.h" 20| | 21| |#import "FBSDKAccessToken.h" 22| |#import "FBSDKApplicationLifecycleNotifications.h" 23| |#import "FBSDKCoreKitBasicsImport.h" 24| |#import "FBSDKNotificationProtocols.h" 25| | 26| |@interface FBSDKAccessTokenExpirer () 27| | 28| |@property (nonnull, nonatomic, readonly) id notificationCenter; 29| | 30| |@end 31| | 32| |@implementation FBSDKAccessTokenExpirer 33| |{ 34| | NSTimer *_timer; 35| |} 36| | 37| |- (instancetype)initWithNotificationCenter:(id)notificationCenter 38| 0|{ 39| 0| if (self = [super init]) { 40| 0| _notificationCenter = notificationCenter; 41| 0| [notificationCenter addObserver:self selector:@selector(_checkAccessTokenExpirationDate) name:FBSDKAccessTokenDidChangeNotification object:nil]; 42| 0| [notificationCenter addObserver:self selector:@selector(_checkAccessTokenExpirationDate) name:FBSDKApplicationDidBecomeActiveNotification object:nil]; 43| 0| [self _checkAccessTokenExpirationDate]; 44| 0| } 45| 0| return self; 46| 0|} 47| | 48| |- (void)dealloc 49| 0|{ 50| 0| [_timer invalidate]; 51| 0| _timer = nil; 52| 0| [self.notificationCenter removeObserver:self]; 53| 0|} 54| | 55| |- (void)_checkAccessTokenExpirationDate 56| 0|{ 57| 0| [_timer invalidate]; 58| 0| _timer = nil; 59| 0| FBSDKAccessToken *accessToken = FBSDKAccessToken.currentAccessToken; 60| 0| if (accessToken == nil || accessToken.isExpired) { 61| 0| return; 62| 0| } 63| 0| _timer = [NSTimer scheduledTimerWithTimeInterval:accessToken.expirationDate.timeIntervalSinceNow target:self selector:@selector(_timerDidFire) userInfo:nil repeats:NO]; 64| 0|} 65| | 66| |- (void)_timerDidFire 67| 0|{ 68| 0| FBSDKAccessToken *accessToken = FBSDKAccessToken.currentAccessToken; 69| 0| NSMutableDictionary *userInfo = [NSMutableDictionary dictionary]; 70| 0| [FBSDKTypeUtility dictionary:userInfo setObject:accessToken forKey:FBSDKAccessTokenChangeNewKey]; 71| 0| [FBSDKTypeUtility dictionary:userInfo setObject:accessToken forKey:FBSDKAccessTokenChangeOldKey]; 72| 0| userInfo[FBSDKAccessTokenDidExpireKey] = @YES; 73| | 74| 0| [self.notificationCenter postNotificationName:FBSDKAccessTokenDidChangeNotification 75| 0| object:[FBSDKAccessToken class] 76| 0| userInfo:userInfo]; 77| 0|} 78| | 79| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/TokenCaching/FBSDKKeychainStore.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKKeychainStore.h" 20| | 21| |#import "FBSDKCoreKitBasicsImport.h" 22| |#import "FBSDKDynamicFrameworkLoader.h" 23| |#import "FBSDKLogger.h" 24| |#import "FBSDKUnarchiverProvider.h" 25| | 26| |@implementation FBSDKKeychainStore 27| | 28| |- (instancetype)initWithService:(NSString *)service accessGroup:(NSString *)accessGroup 29| 0|{ 30| 0| if ((self = [super init])) { 31| 0| _service = service ? [service copy] : [NSBundle mainBundle].bundleIdentifier; 32| 0| _accessGroup = [accessGroup copy]; 33| 0| NSAssert(_service, @"Keychain must be initialized with service"); 34| 0| } 35| | 36| 0| return self; 37| 0|} 38| | 39| |#pragma clang diagnostic push 40| |#pragma clang diagnostic ignored "-Wdeprecated-declarations" 41| |- (BOOL)setDictionary:(NSDictionary *)value forKey:(NSString *)key accessibility:(CFTypeRef)accessibility 42| 0|{ 43| 0| NSData *data = value == nil ? nil : [NSKeyedArchiver archivedDataWithRootObject:value]; 44| 0| return [self setData:data forKey:key accessibility:accessibility]; 45| 0|} 46| | 47| |- (NSDictionary *)dictionaryForKey:(NSString *)key 48| 0|{ 49| 0| NSData *data = [self dataForKey:key]; 50| 0| if (!data) { 51| 0| return nil; 52| 0| } 53| 0| id unarchiver = [FBSDKUnarchiverProvider createInsecureUnarchiverFor:data]; 54| | 55| 0| NSDictionary *dict = nil; 56| 0| @try { 57| 0| dict = [unarchiver decodeObjectOfClass:NSDictionary.class forKey:NSKeyedArchiveRootObjectKey]; 58| 0| } @catch (NSException *ex) { 59| | // ignore decoding exceptions 60| 0| } 61| 0| return dict; 62| 0|} 63| | 64| |#pragma clang diagnostic pop 65| | 66| |- (BOOL)setString:(NSString *)value forKey:(NSString *)key accessibility:(CFTypeRef)accessibility 67| 0|{ 68| 0| NSData *data = [value dataUsingEncoding:NSUTF8StringEncoding]; 69| 0| return [self setData:data forKey:key accessibility:accessibility]; 70| 0|} 71| | 72| |- (NSString *)stringForKey:(NSString *)key 73| 0|{ 74| 0| NSData *data = [self dataForKey:key]; 75| 0| if (!data) { 76| 0| return nil; 77| 0| } 78| | 79| 0| return [[NSString alloc] initWithData:data encoding:NSUTF8StringEncoding]; 80| 0|} 81| | 82| |- (BOOL)setData:(NSData *)value forKey:(NSString *)key accessibility:(CFTypeRef)accessibility 83| 0|{ 84| 0| if (!key) { 85| 0| return NO; 86| 0| } 87| | 88| 0|#if TARGET_OS_SIMULATOR 89| 0| [FBSDKLogger singleShotLogEntry:FBSDKLoggingBehaviorInformational 90| 0| logEntry:@"Falling back to storing access token in NSUserDefaults because of simulator bug"]; 91| 0| [[NSUserDefaults standardUserDefaults] setObject:value forKey:key]; 92| | 93| 0| return [[NSUserDefaults standardUserDefaults] synchronize]; 94| |#else 95| | NSMutableDictionary *query = [self queryForKey:key]; 96| | 97| | OSStatus status; 98| | if (value) { 99| | NSMutableDictionary *attributesToUpdate = [NSMutableDictionary dictionary]; 100| | [attributesToUpdate setObject:value forKey:[FBSDKDynamicFrameworkLoader loadkSecValueData]]; 101| | 102| | status = fbsdkdfl_SecItemUpdate((__bridge CFDictionaryRef)query, (__bridge CFDictionaryRef)attributesToUpdate); 103| | if (status == errSecItemNotFound) { 104| | #if !TARGET_OS_TV 105| | if (@available(macOS 10.9, iOS 8, *)) { 106| | if (accessibility) { 107| | [query setObject:(__bridge id)(accessibility) forKey:[FBSDKDynamicFrameworkLoader loadkSecAttrAccessible]]; 108| | } 109| | } 110| | #endif 111| | [query setObject:value forKey:[FBSDKDynamicFrameworkLoader loadkSecValueData]]; 112| | 113| | status = fbsdkdfl_SecItemAdd((__bridge CFDictionaryRef)query, NULL); 114| | } 115| | } else { 116| | status = fbsdkdfl_SecItemDelete((__bridge CFDictionaryRef)query); 117| | if (status == errSecItemNotFound) { 118| | status = errSecSuccess; 119| | } 120| | } 121| | 122| | return (status == errSecSuccess); 123| |#endif 124| 0|} 125| | 126| |- (NSData *)dataForKey:(NSString *)key 127| 0|{ 128| 0| if (!key) { 129| 0| return nil; 130| 0| } 131| | 132| 0|#if TARGET_OS_SIMULATOR 133| 0| [FBSDKLogger singleShotLogEntry:FBSDKLoggingBehaviorInformational 134| 0| logEntry:@"Falling back to loading access token from NSUserDefaults because of simulator bug"]; 135| 0| return [[NSUserDefaults standardUserDefaults] dataForKey:key]; 136| |#else 137| | NSMutableDictionary *query = [self queryForKey:key]; 138| | [query setObject:(id)kCFBooleanTrue forKey:[FBSDKDynamicFrameworkLoader loadkSecReturnData]]; 139| | [query setObject:[FBSDKDynamicFrameworkLoader loadkSecMatchLimitOne] forKey:[FBSDKDynamicFrameworkLoader loadkSecMatchLimit]]; 140| | 141| | CFTypeRef data = nil; 142| | OSStatus status = fbsdkdfl_SecItemCopyMatching((__bridge CFDictionaryRef)query, &data); 143| | if (status != errSecSuccess) { 144| | return nil; 145| | } 146| | 147| | if (!data || CFGetTypeID(data) != CFDataGetTypeID()) { 148| | return nil; 149| | } 150| | 151| | NSData *ret = [NSData dataWithData:(__bridge NSData *)(data)]; 152| | CFRelease(data); 153| | 154| | return ret; 155| |#endif 156| 0|} 157| | 158| |- (NSMutableDictionary *)queryForKey:(NSString *)key 159| 0|{ 160| 0| NSMutableDictionary *query = [NSMutableDictionary dictionary]; 161| 0| [FBSDKTypeUtility dictionary:query setObject:[FBSDKDynamicFrameworkLoader loadkSecClassGenericPassword] forKey:[FBSDKDynamicFrameworkLoader loadkSecClass]]; 162| 0| [FBSDKTypeUtility dictionary:query setObject:_service forKey:[FBSDKDynamicFrameworkLoader loadkSecAttrService]]; 163| 0| [FBSDKTypeUtility dictionary:query setObject:key forKey:[FBSDKDynamicFrameworkLoader loadkSecAttrAccount]]; 164| |#if !TARGET_OS_SIMULATOR 165| | if (_accessGroup) { 166| | [query setObject:_accessGroup forKey:[FBSDKDynamicFrameworkLoader loadkSecAttrAccessGroup]]; 167| | } 168| |#endif 169| | 170| 0| return query; 171| 0|} 172| | 173| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/TokenCaching/FBSDKTokenCache.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKTokenCache.h" 20| | 21| |#import "FBSDKAuthenticationToken+Internal.h" 22| |#import "FBSDKDynamicFrameworkLoader.h" 23| |#import "FBSDKKeychainStore.h" 24| |#import "FBSDKSettingsProtocol.h" 25| |#import "FBSDKUnarchiverProvider.h" 26| | 27| |static NSString *const kFBSDKAccessTokenUserDefaultsKey = @"com.facebook.sdk.v4.FBSDKAccessTokenInformationKey"; 28| |static NSString *const kFBSDKAccessTokenKeychainKey = @"com.facebook.sdk.v4.FBSDKAccessTokenInformationKeychainKey"; 29| | 30| |static NSString *const kFBSDKAuthenticationTokenUserDefaultsKey = @"com.facebook.sdk.v9.FBSDKAuthenticationTokenInformationKey"; 31| |static NSString *const kFBSDKAuthenticationTokenKeychainKey = @"com.facebook.sdk.v9.FBSDKAuthenticationTokenInformationKeychainKey"; 32| | 33| |static NSString *const kFBSDKTokenUUIDKey = @"tokenUUID"; 34| |static NSString *const kFBSDKTokenEncodedKey = @"tokenEncoded"; 35| | 36| |@implementation FBSDKTokenCache 37| |{ 38| | FBSDKKeychainStore *_keychainStore; 39| | id _settings; 40| |} 41| | 42| |- (instancetype)initWithSettings:(id)settings 43| 0|{ 44| 0| if ((self = [super init])) { 45| 0| NSString *keyChainServiceIdentifier = [NSString stringWithFormat:@"com.facebook.sdk.tokencache.%@", [NSBundle mainBundle].bundleIdentifier]; 46| 0| _keychainStore = [[FBSDKKeychainStore alloc] initWithService:keyChainServiceIdentifier accessGroup:nil]; 47| 0| _settings = settings; 48| 0| } 49| 0| return self; 50| 0|} 51| | 52| |#pragma clang diagnostic push 53| |#pragma clang diagnostic ignored "-Wdeprecated-declarations" 54| | 55| |- (FBSDKAccessToken *)accessToken 56| 0|{ 57| 0| NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults]; 58| 0| NSString *uuid = [defaults objectForKey:kFBSDKAccessTokenUserDefaultsKey]; 59| 0| NSDictionary *dict = [_keychainStore dictionaryForKey:kFBSDKAccessTokenKeychainKey]; 60| | 61| 0| if (_settings.shouldUseTokenOptimizations) { 62| 0| if (!uuid && !dict) { 63| 0| return nil; 64| 0| } 65| | 66| 0| if (!uuid) { 67| 0| [self clearAccessTokenCache]; 68| 0| return nil; 69| 0| } 70| | 71| 0| if (!dict) { 72| 0| [defaults setObject:nil forKey:kFBSDKAccessTokenUserDefaultsKey]; 73| 0| return nil; 74| 0| } 75| 0| } 76| | 77| 0| if ([dict[kFBSDKTokenUUIDKey] isKindOfClass:[NSString class]]) { 78| | // there is a bug while running on simulator that the uuid stored in dict can be NSData, 79| | // do a type check to make sure it is NSString 80| 0| if ([dict[kFBSDKTokenUUIDKey] isEqualToString:uuid]) { 81| 0| id tokenData = dict[kFBSDKTokenEncodedKey]; 82| 0| if ([tokenData isKindOfClass:[NSData class]]) { 83| 0| id unarchiver = [FBSDKUnarchiverProvider createSecureUnarchiverFor:tokenData]; 84| | 85| 0| FBSDKAccessToken *unarchivedToken = nil; 86| 0| @try { 87| 0| unarchivedToken = [unarchiver decodeObjectOfClass:FBSDKAccessToken.class forKey:NSKeyedArchiveRootObjectKey]; 88| 0| } @catch (NSException *ex) { 89| | // ignore decoding exceptions 90| 0| } 91| 0| return unarchivedToken; 92| 0| } 93| 0| } 94| 0| } 95| | // if the uuid doesn't match (including if there is no uuid in defaults which means uninstalled case) 96| | // clear the access token cache and return nil. 97| 0| [self clearAccessTokenCache]; 98| 0| return nil; 99| 0|} 100| | 101| |- (void)setAccessToken:(FBSDKAccessToken *)token 102| 0|{ 103| 0| if (!token) { 104| 0| [self clearAccessTokenCache]; 105| 0| return; 106| 0| } 107| 0| NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults]; 108| 0| NSString *uuid = [defaults objectForKey:kFBSDKAccessTokenUserDefaultsKey]; 109| 0| if (!uuid) { 110| 0| uuid = [NSUUID UUID].UUIDString; 111| 0| [defaults setObject:uuid forKey:kFBSDKAccessTokenUserDefaultsKey]; 112| 0| } 113| 0| NSData *tokenData = [NSKeyedArchiver archivedDataWithRootObject:token]; 114| 0| NSDictionary *dict = @{ 115| 0| kFBSDKTokenUUIDKey : uuid, 116| 0| kFBSDKTokenEncodedKey : tokenData 117| 0| }; 118| | 119| 0| [_keychainStore setDictionary:dict 120| 0| forKey:kFBSDKAccessTokenKeychainKey 121| 0| accessibility:[FBSDKDynamicFrameworkLoader loadkSecAttrAccessibleAfterFirstUnlockThisDeviceOnly]]; 122| 0|} 123| | 124| |- (FBSDKAuthenticationToken *)authenticationToken 125| 0|{ 126| 0| NSUserDefaults *defaults = NSUserDefaults.standardUserDefaults; 127| 0| NSString *uuid = [defaults objectForKey:kFBSDKAuthenticationTokenUserDefaultsKey]; 128| 0| NSDictionary *dict = [_keychainStore dictionaryForKey:kFBSDKAuthenticationTokenKeychainKey]; 129| | 130| 0| if (_settings.shouldUseTokenOptimizations) { 131| 0| if (!uuid && !dict) { 132| 0| return nil; 133| 0| } 134| | 135| 0| if (!uuid) { 136| 0| [self clearAuthenticationTokenCache]; 137| 0| return nil; 138| 0| } 139| | 140| 0| if (!dict) { 141| 0| [defaults setObject:nil forKey:kFBSDKAuthenticationTokenKeychainKey]; 142| 0| return nil; 143| 0| } 144| 0| } 145| | 146| 0| if ([dict[kFBSDKTokenUUIDKey] isKindOfClass:[NSString class]]) { 147| | // there is a bug while running on simulator that the uuid stored in dict can be NSData, 148| | // do a type check to make sure it is NSString 149| 0| if ([dict[kFBSDKTokenUUIDKey] isEqualToString:uuid]) { 150| 0| id tokenData = dict[kFBSDKTokenEncodedKey]; 151| 0| id unarchiver = [FBSDKUnarchiverProvider createSecureUnarchiverFor:tokenData]; 152| | 153| 0| FBSDKAuthenticationToken *unarchivedToken = nil; 154| 0| @try { 155| 0| unarchivedToken = [unarchiver decodeObjectOfClass:FBSDKAuthenticationToken.class forKey:NSKeyedArchiveRootObjectKey]; 156| 0| } @catch (NSException *ex) { 157| | // ignore decoding exceptions 158| 0| } @finally { 159| 0| return unarchivedToken; 160| 0| } 161| 0| return nil; 162| 0| } 163| 0| } 164| | // if the uuid doesn't match (including if there is no uuid in defaults which means uninstalled case) 165| | // clear the authentication token cache and return nil. 166| 0| [self clearAuthenticationTokenCache]; 167| 0| return nil; 168| 0|} 169| | 170| |- (void)setAuthenticationToken:(FBSDKAuthenticationToken *)token 171| 0|{ 172| 0| if (!token) { 173| 0| [self clearAuthenticationTokenCache]; 174| 0| return; 175| 0| } 176| 0| NSUserDefaults *defaults = NSUserDefaults.standardUserDefaults; 177| 0| NSString *uuid = [defaults objectForKey:kFBSDKAuthenticationTokenUserDefaultsKey]; 178| 0| if (!uuid) { 179| 0| uuid = NSUUID.UUID.UUIDString; 180| 0| [defaults setObject:uuid forKey:kFBSDKAuthenticationTokenUserDefaultsKey]; 181| 0| } 182| 0| NSData *tokenData = [NSKeyedArchiver archivedDataWithRootObject:token]; 183| 0| NSDictionary *dict = @{ 184| 0| kFBSDKTokenUUIDKey : uuid, 185| 0| kFBSDKTokenEncodedKey : tokenData 186| 0| }; 187| | 188| 0| [_keychainStore setDictionary:dict 189| 0| forKey:kFBSDKAuthenticationTokenKeychainKey 190| 0| accessibility:[FBSDKDynamicFrameworkLoader loadkSecAttrAccessibleAfterFirstUnlockThisDeviceOnly]]; 191| 0|} 192| | 193| |#pragma clang diagnostic pop 194| | 195| |- (void)clearAuthenticationTokenCache 196| 0|{ 197| 0| [_keychainStore setDictionary:nil 198| 0| forKey:kFBSDKAuthenticationTokenKeychainKey 199| 0| accessibility:NULL]; 200| 0| NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults]; 201| 0| [defaults removeObjectForKey:kFBSDKAuthenticationTokenUserDefaultsKey]; 202| 0| [defaults synchronize]; 203| 0|} 204| | 205| |- (void)clearAccessTokenCache 206| 0|{ 207| 0| [_keychainStore setDictionary:nil 208| 0| forKey:kFBSDKAccessTokenKeychainKey 209| 0| accessibility:NULL]; 210| 0| NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults]; 211| 0| [defaults removeObjectForKey:kFBSDKAccessTokenUserDefaultsKey]; 212| 0| [defaults synchronize]; 213| 0|} 214| | 215| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/UI/FBSDKCloseIcon.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKCloseIcon.h" 24| | 25| |@implementation FBSDKCloseIcon 26| | 27| | #pragma mark - Public API 28| | 29| |- (UIImage *)imageWithSize:(CGSize)size 30| 0|{ 31| 0| return [self imageWithSize:size 32| 0| primaryColor:UIColor.whiteColor 33| 0| secondaryColor:UIColor.blackColor 34| 0| scale:UIScreen.mainScreen.scale]; 35| 0|} 36| | 37| |- (UIImage *)imageWithSize:(CGSize)size 38| | primaryColor:(UIColor *)primaryColor 39| | secondaryColor:(UIColor *)secondaryColor 40| | scale:(CGFloat)scale 41| 0|{ 42| 0| UIGraphicsBeginImageContextWithOptions(size, NO, scale); 43| 0| CGContextRef context = UIGraphicsGetCurrentContext(); 44| | 45| 0| CGFloat iconSize = MIN(size.width, size.height); 46| | 47| 0| CGRect rect = CGRectMake((size.width - iconSize) / 2, (size.height - iconSize) / 2, iconSize, iconSize); 48| 0| CGFloat step = iconSize / 12; 49| | 50| | // shadow 51| 0| rect = CGRectIntegral(CGRectInset(rect, step, step)); 52| 0| NSArray *colors = @[ 53| 0| (__bridge id)[UIColor colorWithWhite:0.0 alpha:0.7].CGColor, 54| 0| (__bridge id)[UIColor colorWithWhite:0.0 alpha:0.3].CGColor, 55| 0| (__bridge id)[UIColor colorWithWhite:0.0 alpha:0.1].CGColor, 56| 0| (__bridge id)[UIColor colorWithWhite:0.0 alpha:0.0].CGColor, 57| 0| ]; 58| 0| CGFloat locations[4] = { 59| 0| 0.70, 60| 0| 0.80, 61| 0| 0.90, 62| 0| 1.0, 63| 0| }; 64| 0| CGColorSpaceRef colorSpace = CGColorSpaceCreateDeviceGray(); 65| 0| CGGradientRef gradient = CGGradientCreateWithColors(colorSpace, (__bridge CFArrayRef)colors, locations); 66| 0| CGColorSpaceRelease(colorSpace); 67| 0| CGPoint center = CGPointMake(CGRectGetMidX(rect) - step / 6, CGRectGetMidY(rect) + step / 4); 68| 0| CGContextDrawRadialGradient(context, gradient, center, 0.0, center, (CGRectGetWidth(rect) - step / 2) / 2, 0); 69| 0| CGGradientRelease(gradient); 70| | 71| | // outer circle 72| 0| rect = CGRectIntegral(CGRectInset(rect, step, step)); 73| 0| [primaryColor setFill]; 74| 0| CGContextFillEllipseInRect(context, rect); 75| | 76| | // inner circle 77| 0| rect = CGRectIntegral(CGRectInset(rect, step, step)); 78| 0| [secondaryColor setFill]; 79| 0| CGContextFillEllipseInRect(context, rect); 80| | 81| | // cross 82| 0| rect = CGRectIntegral(CGRectInset(rect, step, step)); 83| 0| CGFloat lineWidth = step * 5 / 4; 84| 0| rect.origin.y = CGRectGetMidY(rect) - lineWidth / 2; 85| 0| rect.size.height = lineWidth; 86| 0| [primaryColor setFill]; 87| 0| CGContextTranslateCTM(context, size.width / 2, size.height / 2); 88| 0| CGContextRotateCTM(context, M_PI_4); 89| 0| CGContextTranslateCTM(context, -size.width / 2, -size.height / 2); 90| 0| CGContextFillRect(context, rect); 91| 0| CGContextTranslateCTM(context, size.width / 2, size.height / 2); 92| 0| CGContextRotateCTM(context, M_PI_2); 93| 0| CGContextTranslateCTM(context, -size.width / 2, -size.height / 2); 94| 0| CGContextFillRect(context, rect); 95| | 96| 0| UIImage *image = UIGraphicsGetImageFromCurrentImageContext(); 97| 0| UIGraphicsEndImageContext(); 98| 0| return image; 99| 0|} 100| | 101| |@end 102| | 103| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/UI/FBSDKIcon.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKIcon.h" 20| | 21| |@implementation FBSDKIcon 22| | 23| |#pragma mark - Public API 24| | 25| |- (UIImage *)imageWithSize:(CGSize)size 26| 0|{ 27| 0| return [self imageWithSize:size scale:UIScreen.mainScreen.scale color:UIColor.whiteColor]; 28| 0|} 29| | 30| |- (UIImage *)imageWithSize:(CGSize)size scale:(CGFloat)scale 31| 0|{ 32| 0| return [self imageWithSize:size scale:scale color:UIColor.whiteColor]; 33| 0|} 34| | 35| |- (UIImage *)imageWithSize:(CGSize)size color:(UIColor *)color 36| 0|{ 37| 0| return [self imageWithSize:size scale:UIScreen.mainScreen.scale color:color]; 38| 0|} 39| | 40| |- (UIImage *)imageWithSize:(CGSize)size scale:(CGFloat)scale color:(UIColor *)color 41| 0|{ 42| 0| if ((size.width == 0) || (size.height == 0)) { 43| 0| return nil; 44| 0| } 45| 0| UIGraphicsBeginImageContextWithOptions(size, NO, scale); 46| 0| CGContextRef context = UIGraphicsGetCurrentContext(); 47| 0| CGPathRef path = [self pathWithSize:size]; 48| 0| CGContextAddPath(context, path); 49| 0| CGContextSetFillColorWithColor(context, color.CGColor); 50| 0| CGContextFillPath(context); 51| 0| UIImage *image = UIGraphicsGetImageFromCurrentImageContext(); 52| 0| UIGraphicsEndImageContext(); 53| 0| return image; 54| 0|} 55| | 56| |- (CGPathRef)pathWithSize:(CGSize)size 57| 0|{ 58| 0| return NULL; 59| 0|} 60| | 61| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/UI/FBSDKLogo.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKLogo.h" 20| | 21| |@implementation FBSDKLogo 22| | 23| |- (CGPathRef)pathWithSize:(CGSize)size 24| 0|{ 25| 0| CGFloat originalCanvasWidth = 1366; 26| 0| CGFloat originalCanvasHeight = 1366; 27| | 28| 0| CGAffineTransform transformValue = CGAffineTransformMakeScale(size.width / originalCanvasWidth, size.height / originalCanvasHeight); 29| | 30| 0| UIBezierPath *path = [UIBezierPath bezierPath]; 31| 0| [path moveToPoint:CGPointMake(1365.33, 682.67)]; 32| 0| [path addCurveToPoint:CGPointMake(682.67, -0) 33| 0| controlPoint1:CGPointMake(1365.33, 305.64) 34| 0| controlPoint2:CGPointMake(1059.69, -0)]; 35| 0| [path addCurveToPoint:CGPointMake(0, 682.67) 36| 0| controlPoint1:CGPointMake(305.64, -0) 37| 0| controlPoint2:CGPointMake(0, 305.64)]; 38| 0| [path addCurveToPoint:CGPointMake(576, 1357.04) 39| 0| controlPoint1:CGPointMake(0, 1023.41) 40| 0| controlPoint2:CGPointMake(249.64, 1305.83)]; 41| 0| [path addLineToPoint:CGPointMake(576, 880)]; 42| 0| [path addLineToPoint:CGPointMake(402.67, 880)]; 43| 0| [path addLineToPoint:CGPointMake(402.67, 682.67)]; 44| 0| [path addLineToPoint:CGPointMake(576, 682.67)]; 45| 0| [path addLineToPoint:CGPointMake(576, 532.27)]; 46| 0| [path addCurveToPoint:CGPointMake(833.85, 266.67) 47| 0| controlPoint1:CGPointMake(576, 361.17) 48| 0| controlPoint2:CGPointMake(677.92, 266.67)]; 49| 0| [path addCurveToPoint:CGPointMake(986.67, 280) 50| 0| controlPoint1:CGPointMake(908.54, 266.67) 51| 0| controlPoint2:CGPointMake(986.67, 280)]; 52| 0| [path addLineToPoint:CGPointMake(986.67, 448)]; 53| 0| [path addLineToPoint:CGPointMake(900.58, 448)]; 54| 0| [path addCurveToPoint:CGPointMake(789.33, 554.61) 55| 0| controlPoint1:CGPointMake(815.78, 448) 56| 0| controlPoint2:CGPointMake(789.33, 500.62)]; 57| 0| [path addLineToPoint:CGPointMake(789.33, 682.67)]; 58| 0| [path addLineToPoint:CGPointMake(978.67, 682.67)]; 59| 0| [path addLineToPoint:CGPointMake(948.4, 880)]; 60| 0| [path addLineToPoint:CGPointMake(789.33, 880)]; 61| 0| [path addLineToPoint:CGPointMake(789.33, 1357.04)]; 62| 0| [path addCurveToPoint:CGPointMake(1365.33, 682.67) 63| 0| controlPoint1:CGPointMake(1115.69, 1305.83) 64| 0| controlPoint2:CGPointMake(1365.33, 1023.41)]; 65| 0| [path closePath]; 66| 0| [path applyTransform:transformValue]; 67| | 68| 0| return [path CGPath]; 69| 0|} 70| | 71| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/UI/FBSDKUIUtility.h: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import 20| | 21| |/** 22| | Insets a CGSize with the insets in a UIEdgeInsets. 23| | */ 24| |static inline CGSize FBSDKEdgeInsetsInsetSize(CGSize size, UIEdgeInsets insets) 25| 0|{ 26| 0| CGRect rect = CGRectZero; 27| 0| rect.size = size; 28| 0| return UIEdgeInsetsInsetRect(rect, insets).size; 29| 0|} ------------------ | Unexecuted instantiation: FBSDKLoginCompletion.m:FBSDKEdgeInsetsInsetSize ------------------ | Unexecuted instantiation: FBSDKGraphRequestPiggybackManager.m:FBSDKEdgeInsetsInsetSize ------------------ | Unexecuted instantiation: FBSDKLoginManager.m:FBSDKEdgeInsetsInsetSize ------------------ | Unexecuted instantiation: FBSDKTokenCache.m:FBSDKEdgeInsetsInsetSize ------------------ | Unexecuted instantiation: FBSDKLoginManagerLoginResult.m:FBSDKEdgeInsetsInsetSize ------------------ | Unexecuted instantiation: FBSDKLoginUtility.m:FBSDKEdgeInsetsInsetSize ------------------ | Unexecuted instantiation: FBSDKLoginConfiguration.m:FBSDKEdgeInsetsInsetSize ------------------ | Unexecuted instantiation: _FBSDKLoginRecoveryAttempter.m:FBSDKEdgeInsetsInsetSize ------------------ | Unexecuted instantiation: FBSDKLoginManagerLogger.m:FBSDKEdgeInsetsInsetSize ------------------ | Unexecuted instantiation: FBSDKApplicationDelegate.m:FBSDKEdgeInsetsInsetSize ------------------ | Unexecuted instantiation: FBSDKBridgeAPI.m:FBSDKEdgeInsetsInsetSize ------------------ | Unexecuted instantiation: FBSDKAccessToken.m:FBSDKEdgeInsetsInsetSize ------------------ | Unexecuted instantiation: FBSDKInternalUtility.m:FBSDKEdgeInsetsInsetSize ------------------ | Unexecuted instantiation: FBSDKAppLinkUtility.m:FBSDKEdgeInsetsInsetSize ------------------ | Unexecuted instantiation: FBSDKPaymentObserver.m:FBSDKEdgeInsetsInsetSize ------------------ | Unexecuted instantiation: FBSDKButton.m:FBSDKEdgeInsetsInsetSize ------------------ | Unexecuted instantiation: FBSDKProfile.m:FBSDKEdgeInsetsInsetSize ------------------ | Unexecuted instantiation: FBSDKGraphRequestConnection.m:FBSDKEdgeInsetsInsetSize ------------------ | Unexecuted instantiation: FBSDKAuthenticationToken.m:FBSDKEdgeInsetsInsetSize ------------------ | Unexecuted instantiation: FBSDKURLSessionProxyFactory.m:FBSDKEdgeInsetsInsetSize ------------------ | Unexecuted instantiation: FBSDKGraphRequestPiggybackManagerProvider.m:FBSDKEdgeInsetsInsetSize ------------------ 30| | 31| |/** 32| | Outsets a CGSize with the insets in a UIEdgeInsets. 33| | */ 34| |static inline CGSize FBSDKEdgeInsetsOutsetSize(CGSize size, UIEdgeInsets insets) 35| 0|{ 36| 0| return CGSizeMake( 37| 0| insets.left + size.width + insets.right, 38| 0| insets.top + size.height + insets.bottom 39| 0| ); 40| 0|} ------------------ | Unexecuted instantiation: FBSDKLoginCompletion.m:FBSDKEdgeInsetsOutsetSize ------------------ | Unexecuted instantiation: FBSDKGraphRequestPiggybackManager.m:FBSDKEdgeInsetsOutsetSize ------------------ | Unexecuted instantiation: FBSDKLoginManager.m:FBSDKEdgeInsetsOutsetSize ------------------ | Unexecuted instantiation: FBSDKTokenCache.m:FBSDKEdgeInsetsOutsetSize ------------------ | Unexecuted instantiation: FBSDKLoginManagerLoginResult.m:FBSDKEdgeInsetsOutsetSize ------------------ | Unexecuted instantiation: FBSDKLoginUtility.m:FBSDKEdgeInsetsOutsetSize ------------------ | Unexecuted instantiation: FBSDKLoginConfiguration.m:FBSDKEdgeInsetsOutsetSize ------------------ | Unexecuted instantiation: _FBSDKLoginRecoveryAttempter.m:FBSDKEdgeInsetsOutsetSize ------------------ | Unexecuted instantiation: FBSDKLoginManagerLogger.m:FBSDKEdgeInsetsOutsetSize ------------------ | Unexecuted instantiation: FBSDKApplicationDelegate.m:FBSDKEdgeInsetsOutsetSize ------------------ | Unexecuted instantiation: FBSDKBridgeAPI.m:FBSDKEdgeInsetsOutsetSize ------------------ | Unexecuted instantiation: FBSDKAccessToken.m:FBSDKEdgeInsetsOutsetSize ------------------ | Unexecuted instantiation: FBSDKInternalUtility.m:FBSDKEdgeInsetsOutsetSize ------------------ | Unexecuted instantiation: FBSDKAppLinkUtility.m:FBSDKEdgeInsetsOutsetSize ------------------ | Unexecuted instantiation: FBSDKPaymentObserver.m:FBSDKEdgeInsetsOutsetSize ------------------ | Unexecuted instantiation: FBSDKButton.m:FBSDKEdgeInsetsOutsetSize ------------------ | Unexecuted instantiation: FBSDKProfile.m:FBSDKEdgeInsetsOutsetSize ------------------ | Unexecuted instantiation: FBSDKGraphRequestConnection.m:FBSDKEdgeInsetsOutsetSize ------------------ | Unexecuted instantiation: FBSDKAuthenticationToken.m:FBSDKEdgeInsetsOutsetSize ------------------ | Unexecuted instantiation: FBSDKURLSessionProxyFactory.m:FBSDKEdgeInsetsOutsetSize ------------------ | Unexecuted instantiation: FBSDKGraphRequestPiggybackManagerProvider.m:FBSDKEdgeInsetsOutsetSize ------------------ 41| | 42| |static inline CGSize FBSDKTextSize(NSString *text, 43| | UIFont *font, 44| | CGSize constrainedSize, 45| | NSLineBreakMode lineBreakMode) 46| 0|{ 47| 0| if (!text) { 48| 0| return CGSizeZero; 49| 0| } 50| | 51| 0| NSMutableParagraphStyle *paragraphStyle = [NSMutableParagraphStyle new]; 52| 0| paragraphStyle.lineBreakMode = lineBreakMode; 53| 0| NSDictionary *attributes = @{ 54| 0| NSFontAttributeName : font, 55| 0| NSParagraphStyleAttributeName : paragraphStyle, 56| 0| }; 57| 0| NSAttributedString *attributedString = [[NSAttributedString alloc] initWithString:text attributes:attributes]; 58| 0| CGSize size = [attributedString boundingRectWithSize:constrainedSize 59| 0| options:(NSStringDrawingUsesDeviceMetrics 60| 0| | NSStringDrawingUsesLineFragmentOrigin 61| 0| | NSStringDrawingUsesFontLeading) 62| 0| context:NULL].size; 63| 0| return CGSizeMake(ceilf(size.width), ceilf(size.height)); 64| 0|} ------------------ | Unexecuted instantiation: FBSDKLoginCompletion.m:FBSDKTextSize ------------------ | Unexecuted instantiation: FBSDKGraphRequestPiggybackManager.m:FBSDKTextSize ------------------ | Unexecuted instantiation: FBSDKLoginManager.m:FBSDKTextSize ------------------ | Unexecuted instantiation: FBSDKTokenCache.m:FBSDKTextSize ------------------ | Unexecuted instantiation: FBSDKLoginManagerLoginResult.m:FBSDKTextSize ------------------ | Unexecuted instantiation: FBSDKLoginUtility.m:FBSDKTextSize ------------------ | Unexecuted instantiation: FBSDKLoginConfiguration.m:FBSDKTextSize ------------------ | Unexecuted instantiation: _FBSDKLoginRecoveryAttempter.m:FBSDKTextSize ------------------ | Unexecuted instantiation: FBSDKLoginManagerLogger.m:FBSDKTextSize ------------------ | Unexecuted instantiation: FBSDKApplicationDelegate.m:FBSDKTextSize ------------------ | Unexecuted instantiation: FBSDKBridgeAPI.m:FBSDKTextSize ------------------ | Unexecuted instantiation: FBSDKAccessToken.m:FBSDKTextSize ------------------ | Unexecuted instantiation: FBSDKInternalUtility.m:FBSDKTextSize ------------------ | Unexecuted instantiation: FBSDKAppLinkUtility.m:FBSDKTextSize ------------------ | Unexecuted instantiation: FBSDKPaymentObserver.m:FBSDKTextSize ------------------ | Unexecuted instantiation: FBSDKButton.m:FBSDKTextSize ------------------ | Unexecuted instantiation: FBSDKProfile.m:FBSDKTextSize ------------------ | Unexecuted instantiation: FBSDKGraphRequestConnection.m:FBSDKTextSize ------------------ | Unexecuted instantiation: FBSDKAuthenticationToken.m:FBSDKTextSize ------------------ | Unexecuted instantiation: FBSDKURLSessionProxyFactory.m:FBSDKTextSize ------------------ | Unexecuted instantiation: FBSDKGraphRequestPiggybackManagerProvider.m:FBSDKTextSize ------------------ /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/UI/FBSDKViewImpressionTracker.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKViewImpressionTracker.h" 20| | 21| |#import "FBSDKAccessToken.h" 22| |#import "FBSDKAccessTokenProtocols.h" 23| |#import "FBSDKAppEvents+Internal.h" 24| |#import "FBSDKCoreKitBasicsImport.h" 25| |#import "FBSDKEventLogging.h" 26| |#import "FBSDKGraphRequestProviding.h" 27| |#import "FBSDKInternalUtility.h" 28| |#import "FBSDKNotificationProtocols.h" 29| | 30| |@interface FBSDKViewImpressionTracker () 31| | 32| |@property (nonatomic, strong) id graphRequestProvider; 33| |@property (nonatomic, strong) id eventLogger; 34| |@property (nonatomic, strong) id notificationObserver; 35| |@property (nonatomic, strong) Class tokenWallet; 36| | 37| |@end 38| | 39| |@implementation FBSDKViewImpressionTracker 40| |{ 41| | NSMutableSet *_trackedImpressions; 42| |} 43| | 44| |static dispatch_once_t token; 45| | 46| |#pragma mark - Class Methods 47| | 48| |+ (instancetype)impressionTrackerWithEventName:(NSString *)eventName 49| | graphRequestProvider:(id)graphRequestProvider 50| | eventLogger:(id)eventLogger 51| | notificationObserver:(id)notificationObserver 52| | tokenWallet:(Class)tokenWallet 53| 0|{ 54| 0| static NSMutableDictionary *_impressionTrackers = nil; 55| | 56| 0| dispatch_once(&token, ^{ 57| 0| _impressionTrackers = [NSMutableDictionary new]; 58| 0| }); 59| | // Maintains a single instance of an impression tracker for each event name 60| 0| FBSDKViewImpressionTracker *impressionTracker = _impressionTrackers[eventName]; 61| 0| if (!impressionTracker) { 62| 0| impressionTracker = [[self alloc] initWithEventName:eventName 63| 0| graphRequestProvider:graphRequestProvider 64| 0| eventLogger:eventLogger 65| 0| notificationObserver:notificationObserver 66| 0| tokenWallet:tokenWallet]; 67| 0| [FBSDKTypeUtility dictionary:_impressionTrackers setObject:impressionTracker forKey:eventName]; 68| 0| } 69| 0| return impressionTracker; 70| 0|} 71| | 72| |#pragma mark - Object Lifecycle 73| | 74| |- (instancetype)initWithEventName:(NSString *)eventName 75| | graphRequestProvider:(id)graphRequestProvider 76| | eventLogger:(id)eventLogger 77| | notificationObserver:(id)notificationObserver 78| | tokenWallet:(Class)tokenWallet 79| 0|{ 80| 0| if ((self = [super init])) { 81| 0| _eventName = [eventName copy]; 82| 0| _trackedImpressions = [NSMutableSet new]; 83| 0| _graphRequestProvider = graphRequestProvider; 84| 0| _eventLogger = eventLogger; 85| 0| _notificationObserver = notificationObserver; 86| 0| _tokenWallet = tokenWallet; 87| | 88| 0| [self.notificationObserver addObserver:self 89| 0| selector:@selector(_applicationDidEnterBackgroundNotification:) 90| 0| name:UIApplicationDidEnterBackgroundNotification 91| 0| object:UIApplication.sharedApplication]; 92| 0| } 93| 0| return self; 94| 0|} 95| | 96| |- (void)dealloc 97| 0|{ 98| 0| [self.notificationObserver removeObserver:self]; 99| 0|} 100| | 101| |#pragma mark - Public API 102| | 103| |- (void)logImpressionWithIdentifier:(NSString *)identifier parameters:(NSDictionary *)parameters 104| 0|{ 105| 0| NSMutableDictionary *keys = [NSMutableDictionary dictionary]; 106| 0| [FBSDKTypeUtility dictionary:keys setObject:identifier forKey:@"__view_impression_identifier__"]; 107| 0| [keys addEntriesFromDictionary:parameters]; 108| 0| NSDictionary *impressionKey = [keys copy]; 109| | // Ensure that each impression is only tracked once 110| 0| if ([_trackedImpressions containsObject:impressionKey]) { 111| 0| return; 112| 0| } 113| 0| [_trackedImpressions addObject:impressionKey]; 114| | 115| 0| [self.eventLogger logInternalEvent:self.eventName 116| 0| parameters:parameters 117| 0| isImplicitlyLogged:YES 118| 0| accessToken:[self.tokenWallet currentAccessToken]]; 119| 0|} 120| | 121| |#pragma mark - Helper Methods 122| | 123| |- (void)_applicationDidEnterBackgroundNotification:(NSNotification *)notification 124| 0|{ 125| | // reset all tracked impressions when the app backgrounds so we will start tracking them again the next time they 126| | // are triggered. 127| 0| [_trackedImpressions removeAllObjects]; 128| 0|} 129| | 130| |#if DEBUG 131| | #if FBSDKTEST 132| | 133| |+ (void)reset 134| 0|{ 135| 0| if (token) { 136| 0| token = 0; 137| 0| } 138| 0|} 139| | 140| |- (NSMutableSet *)trackedImpressions 141| 0|{ 142| 0| return _trackedImpressions; 143| 0|} 144| | 145| | #endif 146| |#endif 147| | 148| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/WebDialog/FBSDKWebDialogView.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKWebDialogView.h" 24| | 25| | #import 26| | 27| | #import "FBSDKCloseIcon.h" 28| | #import "FBSDKCoreKitBasicsImport.h" 29| | #import "FBSDKError.h" 30| | #import "FBSDKURLOpener.h" 31| | #import "FBSDKWebViewProviding.h" 32| | 33| 0| #define FBSDK_WEB_DIALOG_VIEW_BORDER_WIDTH 10.0 34| | 35| |@interface FBSDKWebDialogView () 36| | 37| |@property (nonatomic, strong) UIButton *closeButton; 38| |@property (nonatomic, strong) UIActivityIndicatorView *loadingView; 39| |@property (nonatomic, strong) id webView; 40| | 41| |@end 42| | 43| |@implementation FBSDKWebDialogView 44| | 45| |static id _webViewProvider; 46| |static id _urlOpener; 47| | 48| |+ (void)configureWithWebViewProvider:(id)provider 49| | urlOpener:(id)urlOpener; 50| 0|{ 51| 0| _webViewProvider = provider; 52| 0| _urlOpener = urlOpener; 53| 0|} 54| | 55| |+ (id)urlOpener 56| 0|{ 57| 0| return _urlOpener; 58| 0|} 59| | 60| |- (id)urlOpener 61| 0|{ 62| 0| return FBSDKWebDialogView.urlOpener; 63| 0|} 64| | 65| | #pragma mark - Object Lifecycle 66| | 67| |- (instancetype)initWithFrame:(CGRect)frame 68| 0|{ 69| 0| if ((self = [super initWithFrame:frame])) { 70| 0| self.backgroundColor = [UIColor clearColor]; 71| 0| self.opaque = NO; 72| | 73| 0| _webView = [_webViewProvider createWebViewWithFrame:CGRectZero]; 74| 0| _webView.navigationDelegate = self; 75| | 76| | // Since we cannot constrain the webview protocol to be a UIView subclass 77| | // perform a check here to make sure it can be cast to a UIView 78| 0| UIView *webView = FBSDK_CAST_TO_CLASS_OR_NIL(_webView, UIView); 79| 0| if (!webView) { 80| 0| return self; 81| 0| } 82| | 83| 0| [self addSubview:webView]; 84| | 85| 0| _closeButton = [UIButton buttonWithType:UIButtonTypeCustom]; 86| 0| UIImage *closeImage = [[FBSDKCloseIcon new] imageWithSize:CGSizeMake(29.0, 29.0)]; 87| 0| [_closeButton setImage:closeImage forState:UIControlStateNormal]; 88| 0| [_closeButton setTitleColor:[UIColor colorWithRed:167.0 / 255.0 89| 0| green:184.0 / 255.0 90| 0| blue:216.0 / 255.0 91| 0| alpha:1.0] forState:UIControlStateNormal]; 92| 0| [_closeButton setTitleColor:[UIColor whiteColor] forState:UIControlStateHighlighted]; 93| 0| _closeButton.showsTouchWhenHighlighted = YES; 94| 0| [_closeButton sizeToFit]; 95| 0| [self addSubview:_closeButton]; 96| 0| [_closeButton addTarget:self action:@selector(_close:) forControlEvents:UIControlEventTouchUpInside]; 97| | 98| 0| UIActivityIndicatorViewStyle style; 99| 0| if (@available(iOS 13.0, *)) { 100| 0| style = UIActivityIndicatorViewStyleLarge; 101| 0| } else { 102| 0| #pragma clang diagnostic push 103| 0| #pragma clang diagnostic ignored "-Wdeprecated-declarations" 104| 0| style = UIActivityIndicatorViewStyleWhiteLarge; 105| 0| #pragma clang diagnostic pop 106| 0| } 107| 0| _loadingView = [[UIActivityIndicatorView alloc] initWithActivityIndicatorStyle:style]; 108| 0| _loadingView.color = [UIColor grayColor]; 109| 0| _loadingView.hidesWhenStopped = YES; 110| 0| [webView addSubview:_loadingView]; 111| 0| } 112| 0| return self; 113| 0|} 114| | 115| |- (void)dealloc 116| 0|{ 117| 0| self.webView.navigationDelegate = nil; 118| 0|} 119| | 120| | #pragma mark - Public Methods 121| | 122| |- (void)loadURL:(NSURL *)URL 123| 0|{ 124| 0| [self.loadingView startAnimating]; 125| 0| [self.webView loadRequest:[NSURLRequest requestWithURL:URL]]; 126| 0|} 127| | 128| |- (void)stopLoading 129| 0|{ 130| 0| [self.webView stopLoading]; 131| 0| [self.loadingView stopAnimating]; 132| 0|} 133| | 134| | #pragma mark - Layout 135| | 136| |- (void)drawRect:(CGRect)rect 137| 0|{ 138| 0| CGContextRef context = UIGraphicsGetCurrentContext(); 139| 0| CGContextSaveGState(context); 140| 0| [self.backgroundColor setFill]; 141| 0| CGContextFillRect(context, self.bounds); 142| 0| [[UIColor blackColor] setStroke]; 143| 0| CGContextSetLineWidth(context, 1.0 / self.layer.contentsScale); 144| 0| CGContextStrokeRect(context, self.webView.frame); 145| 0| CGContextRestoreGState(context); 146| 0| [super drawRect:rect]; 147| 0|} 148| | 149| |- (void)layoutSubviews 150| 0|{ 151| 0| [super layoutSubviews]; 152| | 153| 0| CGRect bounds = self.bounds; 154| 0| if (UIDevice.currentDevice.userInterfaceIdiom == UIUserInterfaceIdiomPad) { 155| 0| CGFloat horizontalInset = CGRectGetWidth(bounds) * 0.2; 156| 0| CGFloat verticalInset = CGRectGetHeight(bounds) * 0.2; 157| 0| UIEdgeInsets iPadInsets = UIEdgeInsetsMake(verticalInset, horizontalInset, verticalInset, horizontalInset); 158| 0| bounds = UIEdgeInsetsInsetRect(bounds, iPadInsets); 159| 0| } 160| 0| UIEdgeInsets webViewInsets = UIEdgeInsetsMake( 161| 0| FBSDK_WEB_DIALOG_VIEW_BORDER_WIDTH, 162| 0| FBSDK_WEB_DIALOG_VIEW_BORDER_WIDTH, 163| 0| FBSDK_WEB_DIALOG_VIEW_BORDER_WIDTH, 164| 0| FBSDK_WEB_DIALOG_VIEW_BORDER_WIDTH 165| 0| ); 166| 0| self.webView.frame = CGRectIntegral(UIEdgeInsetsInsetRect(bounds, webViewInsets)); 167| | 168| 0| CGRect webViewBounds = self.webView.bounds; 169| 0| self.loadingView.center = CGPointMake(CGRectGetMidX(webViewBounds), CGRectGetMidY(webViewBounds)); 170| | 171| 0| if (CGRectGetHeight(webViewBounds) == 0.0) { 172| 0| self.closeButton.alpha = 0.0; 173| 0| } else { 174| 0| self.closeButton.alpha = 1.0; 175| 0| CGRect closeButtonFrame = self.closeButton.bounds; 176| 0| closeButtonFrame.origin = bounds.origin; 177| 0| self.closeButton.frame = CGRectIntegral(closeButtonFrame); 178| 0| } 179| 0|} 180| | 181| | #pragma mark - Actions 182| | 183| |- (void)_close:(id)sender 184| 0|{ 185| 0| [self.delegate webDialogViewDidCancel:self]; 186| 0|} 187| | 188| | #pragma mark - WKNavigationDelegate 189| | 190| |- (void)webView:(WKWebView *)webView didFailNavigation:(WKNavigation *)navigation withError:(NSError *)error 191| 0|{ 192| 0| [self.loadingView stopAnimating]; 193| | 194| | // 102 == WebKitErrorFrameLoadInterruptedByPolicyChange 195| | // NSURLErrorCancelled == "Operation could not be completed", note NSURLErrorCancelled occurs when the user clicks 196| | // away before the page has completely loaded, if we find cases where we want this to result in dialog failure 197| | // (usually this just means quick-user), then we should add something more robust here to account for differences in 198| | // application needs 199| 0| if (!(([error.domain isEqualToString:NSURLErrorDomain] && error.code == NSURLErrorCancelled) 200| 0| || ([error.domain isEqualToString:@"WebKitErrorDomain"] && error.code == 102))) { 201| 0| [self.delegate webDialogView:self didFailWithError:error]; 202| 0| } 203| 0|} 204| | 205| |- (void) webView:(WKWebView *)webView 206| | decidePolicyForNavigationAction:(WKNavigationAction *)navigationAction 207| | decisionHandler:(void (^)(WKNavigationActionPolicy))decisionHandler 208| 0|{ 209| 0| NSURL *URL = navigationAction.request.URL; 210| | 211| 0| if ([URL.scheme isEqualToString:@"fbconnect"]) { 212| 0| NSMutableDictionary *parameters = [[FBSDKBasicUtility dictionaryWithQueryString:URL.query] mutableCopy]; 213| 0| [parameters addEntriesFromDictionary:[FBSDKBasicUtility dictionaryWithQueryString:URL.fragment]]; 214| 0| if ([URL.resourceSpecifier hasPrefix:@"//cancel"]) { 215| 0| NSInteger errorCode = [FBSDKTypeUtility integerValue:parameters[@"error_code"]]; 216| 0| if (errorCode) { 217| 0| NSString *errorMessage = [FBSDKTypeUtility coercedToStringValue:parameters[@"error_msg"]]; 218| 0| NSError *error = [FBSDKError errorWithCode:errorCode message:errorMessage]; 219| 0| [self.delegate webDialogView:self didFailWithError:error]; 220| 0| } else { 221| 0| [self.delegate webDialogViewDidCancel:self]; 222| 0| } 223| 0| } else { 224| 0| [self.delegate webDialogView:self didCompleteWithResults:parameters]; 225| 0| } 226| 0| decisionHandler(WKNavigationActionPolicyCancel); 227| 0| } else if (navigationAction.navigationType == WKNavigationTypeLinkActivated) { 228| 0| if (@available(iOS 10.0, *)) { 229| 0| [self.urlOpener openURL:URL options:@{} completionHandler:^(BOOL success) { 230| 0| decisionHandler(WKNavigationActionPolicyCancel); 231| 0| }]; 232| 0| } else { 233| 0| [self.urlOpener openURL:URL]; 234| 0| decisionHandler(WKNavigationActionPolicyCancel); 235| 0| } 236| 0| } else { 237| 0| decisionHandler(WKNavigationActionPolicyAllow); 238| 0| } 239| 0|} 240| | 241| |- (void)webView:(WKWebView *)webView didFinishNavigation:(WKNavigation *)navigation 242| 0|{ 243| 0| [self.loadingView stopAnimating]; 244| 0| [self.delegate webDialogViewDidFinishLoad:self]; 245| 0|} 246| | 247| | #if DEBUG 248| | #if FBSDKTEST 249| | 250| |+ (void)reset 251| 0|{ 252| 0| _webViewProvider = nil; 253| 0| _urlOpener = nil; 254| 0|} 255| | 256| |+ (id)webViewProvider 257| 0|{ 258| 0| return _webViewProvider; 259| 0|} 260| | 261| | #endif 262| | #endif 263| | 264| |@end 265| | 266| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/WebDialog/FBSDKWebViewFactory.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKWebViewFactory.h" 24| | 25| | #import "WKWebView+WebViewProtocol.h" 26| | 27| |@protocol FBSDKWebView; 28| | 29| |@implementation FBSDKWebViewFactory 30| | 31| |- (nonnull id)createWebViewWithFrame:(CGRect)frame 32| 0|{ 33| 0| return [[WKWebView alloc] initWithFrame:frame]; 34| 0|} 35| | 36| |@end 37| | 38| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/FBSDKLoginConfiguration.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKLoginConfiguration.h" 24| | 25| | #import "FBSDKNonceUtility.h" 26| | 27| | #ifdef FBSDKCOCOAPODS 28| | #import 29| | #else 30| | #import "FBSDKCoreKit+Internal.h" 31| | #endif 32| | 33| | #import "FBSDKCoreKitBasicsImportForLoginKit.h" 34| | #import "FBSDKPermission.h" 35| | 36| |FBSDKLoginAuthType FBSDKLoginAuthTypeRerequest = @"rerequest"; 37| |FBSDKLoginAuthType FBSDKLoginAuthTypeReauthorize = @"reauthorize"; 38| | 39| |@interface FBSDKLoginConfiguration () 40| |@property (nullable, nonatomic, readwrite, copy) FBSDKLoginAuthType authType; 41| |@end 42| | 43| |@implementation FBSDKLoginConfiguration 44| | 45| |- (nullable instancetype)initWithTracking:(FBSDKLoginTracking)tracking 46| 0|{ 47| 0| return [[FBSDKLoginConfiguration alloc] initWithPermissions:@[] 48| 0| tracking:tracking]; 49| 0|} 50| | 51| |- (nullable instancetype)initWithPermissions:(NSArray *)permissions 52| | tracking:(FBSDKLoginTracking)tracking 53| 0|{ 54| 0| return [[FBSDKLoginConfiguration alloc] initWithPermissions:permissions 55| 0| tracking:tracking 56| 0| nonce:NSUUID.UUID.UUIDString]; 57| 0|} 58| | 59| |- (nullable instancetype)initWithPermissions:(NSArray *)permissions 60| | tracking:(FBSDKLoginTracking)tracking 61| | messengerPageId:(nullable NSString *)messengerPageId 62| 0|{ 63| 0| return [[FBSDKLoginConfiguration alloc] initWithPermissions:permissions 64| 0| tracking:tracking 65| 0| nonce:NSUUID.UUID.UUIDString 66| 0| messengerPageId:messengerPageId]; 67| 0|} 68| | 69| |- (nullable instancetype)initWithPermissions:(NSArray *)permissions 70| | tracking:(FBSDKLoginTracking)tracking 71| | messengerPageId:(nullable NSString *)messengerPageId 72| | authType:(nullable FBSDKLoginAuthType)authType 73| 0|{ 74| 0| return [[FBSDKLoginConfiguration alloc] initWithPermissions:permissions 75| 0| tracking:tracking 76| 0| nonce:NSUUID.UUID.UUIDString 77| 0| messengerPageId:messengerPageId 78| 0| authType:authType]; 79| 0|} 80| | 81| |- (nullable instancetype)initWithPermissions:(NSArray *)permissions 82| | tracking:(FBSDKLoginTracking)tracking 83| | nonce:(NSString *)nonce 84| 0|{ 85| 0| return [[FBSDKLoginConfiguration alloc] initWithPermissions:permissions 86| 0| tracking:tracking 87| 0| nonce:nonce 88| 0| messengerPageId:nil]; 89| 0|} 90| | 91| |- (nullable instancetype)initWithPermissions:(NSArray *)permissions 92| | tracking:(FBSDKLoginTracking)tracking 93| | nonce:(NSString *)nonce 94| | messengerPageId:(nullable NSString *)messengerPageId 95| 0|{ 96| 0| return [[FBSDKLoginConfiguration alloc] initWithPermissions:permissions 97| 0| tracking:tracking 98| 0| nonce:nonce 99| 0| messengerPageId:messengerPageId 100| 0| authType:FBSDKLoginAuthTypeRerequest]; 101| 0|} 102| | 103| |- (nullable instancetype)initWithPermissions:(NSArray *)permissions 104| | tracking:(FBSDKLoginTracking)tracking 105| | nonce:(NSString *)nonce 106| | messengerPageId:(nullable NSString *)messengerPageId 107| | authType:(nullable FBSDKLoginAuthType)authType 108| 0|{ 109| 0| if (![FBSDKNonceUtility isValidNonce:nonce]) { 110| 0| NSString *msg = [NSString stringWithFormat:@"Invalid nonce:%@ provided to login configuration. Returning nil.", nonce]; 111| 0| [FBSDKLogger singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors 112| 0| logEntry:msg]; 113| 0| return nil; 114| 0| } 115| | 116| 0| NSSet *permissionsSet = [FBSDKPermission permissionsFromRawPermissions:[NSSet setWithArray:permissions]]; 117| 0| if (!permissionsSet) { 118| 0| [FBSDKLogger singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors 119| 0| logEntry:@"Invalid combination of permissions provided to login configuration."]; 120| 0| return nil; 121| 0| } 122| | 123| 0| if (authType != nil && [FBSDKLoginConfiguration authTypeForString:authType] == nil) { 124| 0| [FBSDKLogger singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors 125| 0| logEntry:@"Invalid auth_type provided to login configuration."]; 126| 0| return nil; 127| 0| } 128| | 129| 0| if ((self = [super init])) { 130| 0| _requestedPermissions = permissionsSet; 131| 0| _tracking = tracking; 132| 0| _nonce = nonce; 133| 0| _messengerPageId = [FBSDKTypeUtility coercedToStringValue:messengerPageId]; 134| 0| self.authType = authType; 135| 0| } 136| | 137| 0| return self; 138| 0|} 139| | 140| |- (instancetype)init 141| 0|{ 142| 0| if ((self = [super init])) { 143| 0| _requestedPermissions = [NSSet set]; 144| 0| _tracking = FBSDKLoginTrackingEnabled; 145| 0| _nonce = NSUUID.UUID.UUIDString; 146| 0| _messengerPageId = nil; 147| 0| self.authType = FBSDKLoginAuthTypeRerequest; 148| 0| } 149| | 150| 0| return self; 151| 0|} 152| | 153| |+ (nullable FBSDKLoginAuthType)authTypeForString:(NSString *)rawValue 154| 0|{ 155| 0| NSDictionary *map = @{ 156| 0| (NSString *)FBSDKLoginAuthTypeRerequest : FBSDKLoginAuthTypeRerequest, 157| 0| (NSString *)FBSDKLoginAuthTypeReauthorize : FBSDKLoginAuthTypeReauthorize 158| 0| }; 159| | 160| 0| return [FBSDKTypeUtility dictionary:map objectForKey:rawValue ofType:NSString.class]; 161| 0|} 162| | 163| |@end 164| | 165| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/FBSDKLoginManager.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKLoginManager+Internal.h" 24| | 25| | #import "FBSDKLoginManagerLoginResult+Internal.h" 26| | 27| | #ifdef SWIFT_PACKAGE 28| | #import "FBSDKAccessToken.h" 29| | #import "FBSDKSettings.h" 30| | #else 31| | #import 32| | #endif 33| | 34| | #import "FBSDKAuthenticationTokenFactory.h" 35| | #import "FBSDKCoreKitBasicsImportForLoginKit.h" 36| | #import "FBSDKLoginCompletion.h" 37| | #import "FBSDKLoginConstants.h" 38| | #import "FBSDKLoginError.h" 39| | #import "FBSDKLoginManagerLogger.h" 40| | #import "FBSDKLoginUtility.h" 41| | #import "FBSDKMonotonicTime.h" 42| | #import "FBSDKPermission.h" 43| | #import "_FBSDKLoginRecoveryAttempter.h" 44| | 45| |static int const FBClientStateChallengeLength = 20; 46| |static NSString *const FBSDKExpectedChallengeKey = @"expected_login_challenge"; 47| |static NSString *const FBSDKExpectedNonceKey = @"expected_login_nonce"; 48| |static NSString *const FBSDKOauthPath = @"/dialog/oauth"; 49| |static NSString *const SFVCCanceledLogin = @"com.apple.SafariServices.Authentication"; 50| |static NSString *const ASCanceledLogin = @"com.apple.AuthenticationServices.WebAuthenticationSession"; 51| | 52| |@implementation FBSDKLoginManager 53| |{ 54| | FBSDKLoginManagerLoginResultBlock _handler; 55| | FBSDKLoginManagerLogger *_logger; 56| | FBSDKLoginManagerState _state; 57| | FBSDKKeychainStore *_keychainStore; 58| | FBSDKLoginConfiguration *_configuration; 59| | BOOL _usedSFAuthSession; 60| |} 61| | 62| |+ (void)initialize 63| 0|{ 64| 0| if (self == [FBSDKLoginManager class]) { 65| 0| [_FBSDKLoginRecoveryAttempter class]; 66| 0| [FBSDKServerConfigurationManager loadServerConfigurationWithCompletionBlock:NULL]; 67| 0| } 68| 0|} 69| | 70| |- (instancetype)init 71| 0|{ 72| 0| self = [super init]; 73| 0| if (self) { 74| 0| NSString *keyChainServiceIdentifier = [NSString stringWithFormat:@"com.facebook.sdk.loginmanager.%@", [NSBundle mainBundle].bundleIdentifier]; 75| 0| _keychainStore = [[FBSDKKeychainStore alloc] initWithService:keyChainServiceIdentifier accessGroup:nil]; 76| 0| } 77| 0| return self; 78| 0|} 79| | 80| |- (void)logInFromViewController:(UIViewController *)viewController 81| | configuration:(FBSDKLoginConfiguration *)configuration 82| | completion:(FBSDKLoginManagerLoginResultBlock)completion 83| 0|{ 84| 0| if (![self validateLoginStartState]) { 85| 0| return; 86| 0| } 87| | 88| 0| [self logInFromViewControllerImpl:viewController 89| 0| configuration:configuration 90| 0| completion:completion]; 91| 0|} 92| | 93| |- (void)logInFromViewControllerImpl:(UIViewController *)viewController 94| | configuration:(FBSDKLoginConfiguration *)configuration 95| | completion:(FBSDKLoginManagerLoginResultBlock)completion 96| 0|{ 97| 0| if (!configuration) { 98| 0| NSString *failureMessage = @"Cannot login without a valid login configuration. Please make sure the `LoginConfiguration` provided is non-nil"; 99| 0| [FBSDKLogger singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors 100| 0| logEntry:failureMessage]; 101| 0| NSError *error = [FBSDKError errorWithCode:FBSDKErrorInvalidArgument message:failureMessage]; 102| | 103| 0| _handler = [completion copy]; 104| 0| [self invokeHandler:nil error:error]; 105| 0| return; 106| 0| } 107| | 108| 0| self.fromViewController = viewController; 109| 0| _configuration = configuration; 110| 0| _requestedPermissions = configuration.requestedPermissions; 111| | 112| 0| [self logInWithPermissions:configuration.requestedPermissions handler:completion]; 113| 0|} 114| | 115| |- (void)logInWithPermissions:(NSArray *)permissions 116| | fromViewController:(UIViewController *)viewController 117| | handler:(FBSDKLoginManagerLoginResultBlock)handler 118| 0|{ 119| 0| FBSDKLoginConfiguration *config = [[FBSDKLoginConfiguration alloc] initWithPermissions:permissions 120| 0| tracking:FBSDKLoginTrackingEnabled]; 121| 0| [self logInFromViewController:viewController 122| 0| configuration:config 123| 0| completion:handler]; 124| 0|} 125| | 126| |- (void)reauthorizeDataAccess:(UIViewController *)fromViewController handler:(FBSDKLoginManagerLoginResultBlock)handler 127| 0|{ 128| 0| if (![self validateLoginStartState]) { 129| 0| return; 130| 0| } 131| | 132| 0| if (!FBSDKAccessToken.currentAccessToken) { 133| 0| NSString *errorMessage = @"Must have an access token for which to reauthorize data access"; 134| 0| NSError *error = [FBSDKError errorWithDomain:FBSDKLoginErrorDomain 135| 0| code:FBSDKLoginErrorMissingAccessToken 136| 0| message:errorMessage]; 137| 0| [FBSDKLogger singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors logEntry:errorMessage]; 138| 0| handler(nil, error); 139| 0| return; 140| 0| } 141| | 142| 0| FBSDKLoginConfiguration *config = [[FBSDKLoginConfiguration alloc] initWithPermissions:@[] // Don't need to pass permissions for data reauthorization. 143| 0| tracking:FBSDKLoginTrackingEnabled 144| 0| messengerPageId:nil 145| 0| authType:FBSDKLoginAuthTypeReauthorize]; 146| 0| [self logInFromViewControllerImpl:fromViewController configuration:config completion:handler]; 147| 0|} 148| | 149| |- (void)logOut 150| 0|{ 151| 0| [FBSDKAccessToken setCurrentAccessToken:nil]; 152| 0| [FBSDKAuthenticationToken setCurrentAuthenticationToken:nil]; 153| 0| [FBSDKProfile setCurrentProfile:nil]; 154| 0|} 155| | 156| |- (void)logInWithURL:(NSURL *)url 157| | handler:(nullable FBSDKLoginManagerLoginResultBlock)handler 158| 0|{ 159| 0| FBSDKServerConfiguration *serverConfiguration = [FBSDKServerConfigurationManager cachedServerConfiguration]; 160| 0| _logger = [[FBSDKLoginManagerLogger alloc] initWithLoggingToken:serverConfiguration.loggingToken 161| 0| tracking:FBSDKLoginTrackingEnabled]; 162| 0| _handler = [handler copy]; 163| | 164| 0| [_logger startSessionForLoginManager:self]; 165| 0| [_logger startAuthMethod:FBSDKLoginManagerLoggerAuthMethod_Applink]; 166| | 167| 0| NSDictionary *params = [self logInParametersFromURL:url]; 168| 0| if (params) { 169| 0| id completer = [[FBSDKLoginURLCompleter alloc] initWithURLParameters:params 170| 0| appID:FBSDKSettings.appID 171| 0| connectionProvider:FBSDKGraphRequestConnectionFactory.new 172| 0| authenticationTokenCreator:FBSDKAuthenticationTokenFactory.new]; 173| 0| [completer completeLoginWithHandler:^(FBSDKLoginCompletionParameters *parameters) { 174| 0| [self completeAuthentication:parameters expectChallenge:NO]; 175| 0| }]; 176| 0| } 177| 0|} 178| | 179| | #pragma mark - Private 180| | 181| |- (void)handleImplicitCancelOfLogIn 182| 0|{ 183| 0| FBSDKLoginManagerLoginResult *result = [[FBSDKLoginManagerLoginResult alloc] initWithToken:nil 184| 0| authenticationToken:nil 185| 0| isCancelled:YES 186| 0| grantedPermissions:NSSet.set 187| 0| declinedPermissions:NSSet.set]; 188| 0| [result addLoggingExtra:@YES forKey:@"implicit_cancel"]; 189| 0| [self invokeHandler:result error:nil]; 190| 0|} 191| | 192| |- (BOOL)validateLoginStartState 193| 0|{ 194| 0| switch (_state) { 195| 0| case FBSDKLoginManagerStateStart: { 196| 0| if (self->_usedSFAuthSession) { 197| | // Using SFAuthenticationSession makes an interestitial dialog that blocks the app, but in certain situations such as 198| | // screen lock it can be dismissed and have the control returned to the app without invoking the completionHandler. 199| | // In this case, the viewcontroller has the control back and tried to reinvoke the login. This is acceptable behavior 200| | // and we should pop up the dialog again 201| 0| return YES; 202| 0| } 203| | 204| 0| NSString *errorStr = @"** WARNING: You are trying to start a login while a previous login has not finished yet." 205| 0| "This is unsupported behavior. You should wait until the previous login handler gets called to start a new login."; 206| 0| [FBSDKLogger singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors 207| 0| logEntry:errorStr]; 208| 0| return NO; 209| 0| } 210| 0| case FBSDKLoginManagerStatePerformingLogin: { 211| 0| [self handleImplicitCancelOfLogIn]; 212| 0| return YES; 213| 0| } 214| 0| case FBSDKLoginManagerStateIdle: 215| 0| _state = FBSDKLoginManagerStateStart; 216| 0| return YES; 217| 0| } 218| 0|} 219| | 220| |- (BOOL)isPerformingLogin 221| 0|{ 222| 0| return _state == FBSDKLoginManagerStatePerformingLogin; 223| 0|} 224| | 225| |- (void)completeAuthentication:(FBSDKLoginCompletionParameters *)parameters expectChallenge:(BOOL)expectChallenge 226| 0|{ 227| 0| FBSDKLoginManagerLoginResult *result = nil; 228| | 229| 0| NSError *error = parameters.error; 230| 0| NSString *accessTokenString = parameters.accessTokenString; 231| 0| BOOL cancelled = ((accessTokenString == nil) && (parameters.authenticationToken == nil)); 232| | 233| 0| if (expectChallenge && !cancelled && !error) { 234| 0| error = [self _verifyChallengeWithCompletionParameters:parameters]; 235| 0| } 236| 0| [self storeExpectedChallenge:nil]; 237| | 238| 0| if (!error) { 239| 0| if (!cancelled) { 240| 0| result = [self successResultFromParameters:parameters]; 241| | 242| 0| if (result.token && FBSDKAccessToken.currentAccessToken) { 243| 0| [self validateReauthentication:FBSDKAccessToken.currentAccessToken withResult:result]; 244| | // in a reauth, short circuit and let the login handler be called when the validation finishes. 245| 0| return; 246| 0| } 247| 0| } else { 248| 0| result = [self cancelledResultFromParameters:parameters]; 249| 0| } 250| 0| } 251| | 252| 0| [self _setGlobalPropertiesWithParameters:parameters result:result]; 253| | 254| 0| [self invokeHandler:result error:error]; 255| 0|} 256| | 257| |- (void)_setGlobalPropertiesWithParameters:(FBSDKLoginCompletionParameters *)parameters 258| | result:(FBSDKLoginManagerLoginResult *)result 259| 0|{ 260| 0| BOOL hasNewAuthenticationToken = (parameters.authenticationToken != nil); 261| 0| BOOL hasNewOrUpdatedAccessToken = (result.token != nil); 262| | 263| 0| if (!hasNewAuthenticationToken && !hasNewOrUpdatedAccessToken) { 264| | // Assume cancellation. Don't do anything 265| 0| } else { 266| 0| [self _setSharedAuthenticationToken:parameters.authenticationToken 267| 0| accessToken:result.token 268| 0| profile:parameters.profile]; 269| 0| } 270| 0|} 271| | 272| |/// Helper for setting global properties 273| |- (void)_setSharedAuthenticationToken:(FBSDKAuthenticationToken *_Nullable)authToken 274| | accessToken:(FBSDKAccessToken *_Nullable)accessToken 275| | profile:(FBSDKProfile *_Nullable)profile 276| 0|{ 277| 0| FBSDKAuthenticationToken.currentAuthenticationToken = authToken; 278| 0| FBSDKAccessToken.currentAccessToken = accessToken; 279| 0| FBSDKProfile.currentProfile = profile; 280| 0|} 281| | 282| |/// Returns an error if a stored challenge cannot be obtained from the completion parameters 283| |- (NSError *)_verifyChallengeWithCompletionParameters:(FBSDKLoginCompletionParameters *)parameters 284| 0|{ 285| 0| NSString *challengeReceived = parameters.challenge; 286| 0| NSString *challengeExpected = [[self loadExpectedChallenge] stringByReplacingOccurrencesOfString:@"+" withString:@" "]; 287| 0| if (![challengeExpected isEqualToString:challengeReceived]) { 288| 0| return [NSError fbErrorForFailedLoginWithCode:FBSDKLoginErrorBadChallengeString]; 289| 0| } else { 290| 0| return nil; 291| 0| } 292| 0|} 293| | 294| |- (void)invokeHandler:(FBSDKLoginManagerLoginResult *)result error:(NSError *)error 295| 0|{ 296| 0| [_logger endLoginWithResult:result error:error]; 297| 0| [_logger endSession]; 298| 0| [_logger postLoginHeartbeat]; 299| 0| _logger = nil; 300| 0| _state = FBSDKLoginManagerStateIdle; 301| | 302| 0| if (_handler) { 303| 0| FBSDKLoginManagerLoginResultBlock handler = _handler; 304| 0| _handler(result, error); 305| 0| if (handler == _handler) { 306| 0| _handler = nil; 307| 0| } else { 308| 0| [FBSDKLogger singleShotLogEntry:FBSDKLoggingBehaviorDeveloperErrors 309| 0| logEntry:@"** WARNING: You are requesting permissions inside the completion block of an existing login." 310| 0| "This is unsupported behavior. You should request additional permissions only when they are needed, such as requesting for publish_actions" 311| 0| "when the user performs a sharing action."]; 312| 0| } 313| 0| } 314| 0|} 315| | 316| |- (NSString *)loadExpectedChallenge 317| 0|{ 318| 0| return [_keychainStore stringForKey:FBSDKExpectedChallengeKey]; 319| 0|} 320| | 321| |- (NSString *)loadExpectedNonce 322| 0|{ 323| 0| return [_keychainStore stringForKey:FBSDKExpectedNonceKey]; 324| 0|} 325| | 326| |- (NSDictionary *)logInParametersWithConfiguration:(FBSDKLoginConfiguration *)configuration 327| | serverConfiguration:(FBSDKServerConfiguration *)serverConfiguration 328| | logger:(FBSDKLoginManagerLogger *)logger 329| | authMethod:(NSString *)authMethod 330| 0|{ 331| | // Making sure configuration is not nil in case this method gets called 332| | // internally without specifying a cofiguration. 333| 0| if (!configuration) { 334| 0| NSString *failureMessage = @"Unable to perform login."; 335| 0| NSError *error = [FBSDKError errorWithCode:FBSDKErrorUnknown message:failureMessage]; 336| 0| [self invokeHandler:nil error:error]; 337| 0| return nil; 338| 0| } 339| | 340| 0| [FBSDKInternalUtility validateURLSchemes]; 341| | 342| 0| NSMutableDictionary *loginParams = [NSMutableDictionary dictionary]; 343| 0| [FBSDKTypeUtility dictionary:loginParams setObject:[FBSDKSettings appID] forKey:@"client_id"]; 344| 0| [FBSDKTypeUtility dictionary:loginParams setObject:@"touch" forKey:@"display"]; 345| 0| [FBSDKTypeUtility dictionary:loginParams setObject:@"ios" forKey:@"sdk"]; 346| 0| [FBSDKTypeUtility dictionary:loginParams setObject:@"true" forKey:@"return_scopes"]; 347| 0| loginParams[@"sdk_version"] = FBSDK_VERSION_STRING; 348| 0| [FBSDKTypeUtility dictionary:loginParams setObject:@([FBSDKInternalUtility isFacebookAppInstalled]) forKey:@"fbapp_pres"]; 349| 0| [FBSDKTypeUtility dictionary:loginParams setObject:configuration.authType forKey:@"auth_type"]; 350| 0| [FBSDKTypeUtility dictionary:loginParams setObject:serverConfiguration.loggingToken forKey:@"logging_token"]; 351| 0| long long cbtInMilliseconds = round(1000 * [NSDate date].timeIntervalSince1970); 352| 0| [FBSDKTypeUtility dictionary:loginParams setObject:@(cbtInMilliseconds) forKey:@"cbt"]; 353| 0| [FBSDKTypeUtility dictionary:loginParams setObject:[FBSDKSettings isAutoLogAppEventsEnabled] ? @1 : @0 forKey:@"ies"]; 354| 0| [FBSDKTypeUtility dictionary:loginParams setObject:[FBSDKSettings appURLSchemeSuffix] forKey:@"local_client_id"]; 355| 0| [FBSDKTypeUtility dictionary:loginParams setObject:[FBSDKLoginUtility stringForAudience:self.defaultAudience] forKey:@"default_audience"]; 356| | 357| 0| NSSet *permissions = [configuration.requestedPermissions setByAddingObject:[[FBSDKPermission alloc]initWithString:@"openid"]]; 358| 0| [FBSDKTypeUtility dictionary:loginParams setObject:[permissions.allObjects componentsJoinedByString:@","] forKey:@"scope"]; 359| | 360| 0| if (configuration.messengerPageId) { 361| 0| [FBSDKTypeUtility dictionary:loginParams setObject:configuration.messengerPageId forKey:@"messenger_page_id"]; 362| 0| } 363| | 364| 0| NSError *error; 365| 0| NSURL *redirectURL = [FBSDKInternalUtility appURLWithHost:@"authorize" path:@"" queryParameters:@{} error:&error]; 366| 0| if (!error) { 367| 0| [FBSDKTypeUtility dictionary:loginParams 368| 0| setObject:redirectURL.absoluteString 369| 0| forKey:@"redirect_uri"]; 370| 0| } 371| | 372| 0| NSString *expectedChallenge = [FBSDKLoginManager stringForChallenge]; 373| 0| NSDictionary *state = @{@"challenge" : [FBSDKUtility URLEncode:expectedChallenge]}; 374| 0| NSString *clientState = [FBSDKLoginManagerLogger clientStateForAuthMethod:authMethod andExistingState:state logger:logger]; 375| 0| [FBSDKTypeUtility dictionary:loginParams setObject:clientState forKey:@"state"]; 376| 0| [self storeExpectedChallenge:expectedChallenge]; 377| | 378| 0| NSString *responseType; 379| 0| NSString *tp; 380| | 381| 0| switch (configuration.tracking) { 382| 0| case FBSDKLoginTrackingLimited: 383| 0| responseType = @"id_token,graph_domain"; 384| 0| tp = @"ios_14_do_not_track"; 385| 0| break; 386| 0| case FBSDKLoginTrackingEnabled: 387| 0| responseType = @"id_token,token_or_nonce,signed_request,graph_domain"; 388| 0| break; 389| 0| } 390| | 391| 0| [FBSDKTypeUtility dictionary:loginParams setObject:responseType forKey:@"response_type"]; 392| 0| [FBSDKTypeUtility dictionary:loginParams setObject:tp forKey:@"tp"]; 393| | 394| 0| [FBSDKTypeUtility dictionary:loginParams setObject:configuration.nonce forKey:@"nonce"]; 395| 0| [self storeExpectedNonce:configuration.nonce keychainStore:_keychainStore]; 396| | 397| 0| NSTimeInterval timeValue = (NSTimeInterval)FBSDKMonotonicTimeGetCurrentSeconds(); 398| 0| NSString *e2eTimestampString = [FBSDKBasicUtility JSONStringForObject:@{ @"init" : @(timeValue) } 399| 0| error:NULL 400| 0| invalidObjectHandler:NULL]; 401| 0| [FBSDKTypeUtility dictionary:loginParams setObject:e2eTimestampString forKey:@"e2e"]; 402| | 403| 0| return loginParams; 404| 0|} 405| | 406| |- (void)logInWithPermissions:(NSSet *)permissions handler:(FBSDKLoginManagerLoginResultBlock)handler 407| 0|{ 408| 0| FBSDKServerConfiguration *serverConfiguration = [FBSDKServerConfigurationManager cachedServerConfiguration]; 409| | 410| 0| if (_configuration) { 411| 0| _logger = [[FBSDKLoginManagerLogger alloc] initWithLoggingToken:serverConfiguration.loggingToken 412| 0| tracking:_configuration.tracking]; 413| 0| } 414| 0| _handler = [handler copy]; 415| | 416| 0| [_logger startSessionForLoginManager:self]; 417| | 418| 0| [self logIn]; 419| 0|} 420| | 421| |- (NSDictionary *)logInParametersFromURL:(NSURL *)url 422| 0|{ 423| 0| NSError *error = nil; 424| 0| FBSDKURL *parsedUrl = [FBSDKURL URLWithURL:url]; 425| 0| NSDictionary *extras = parsedUrl.appLinkExtras; 426| | 427| 0| if (extras) { 428| 0| NSString *fbLoginDataString = extras[@"fb_login"]; 429| 0| NSDictionary *fbLoginData = [FBSDKTypeUtility dictionaryValue:[FBSDKBasicUtility objectForJSONString:fbLoginDataString error:&error]]; 430| 0| if (!error && fbLoginData) { 431| 0| return fbLoginData; 432| 0| } 433| 0| } 434| 0| error = error ?: [FBSDKError errorWithCode:FBSDKLoginErrorUnknown message:@"Failed to parse deep link url for login data"]; 435| 0| [self invokeHandler:nil error:error]; 436| 0| return nil; 437| 0|} 438| | 439| |- (void)logIn 440| 0|{ 441| 0| self->_usedSFAuthSession = NO; 442| | 443| 0| void (^completion)(BOOL, NSError *) = ^void (BOOL didPerformLogIn, NSError *error) { 444| 0| if (didPerformLogIn) { 445| 0| self->_state = FBSDKLoginManagerStatePerformingLogin; 446| 0| } else if ([error.domain isEqualToString:SFVCCanceledLogin] 447| 0| || [error.domain isEqualToString:ASCanceledLogin]) { 448| 0| [self handleImplicitCancelOfLogIn]; 449| 0| } else { 450| 0| if (!error) { 451| 0| error = [NSError errorWithDomain:FBSDKLoginErrorDomain code:FBSDKLoginErrorUnknown userInfo:nil]; 452| 0| } 453| 0| [self invokeHandler:nil error:error]; 454| 0| } 455| 0| }; 456| | 457| 0| [self performBrowserLogInWithHandler:^(BOOL openedURL, 458| 0| NSError *openedURLError) { 459| 0| completion(openedURL, openedURLError); 460| 0| }]; 461| 0|} 462| | 463| |- (void)storeExpectedChallenge:(NSString *)challengeExpected 464| 0|{ 465| 0| [_keychainStore setString:challengeExpected 466| 0| forKey:FBSDKExpectedChallengeKey 467| 0| accessibility:[FBSDKDynamicFrameworkLoader loadkSecAttrAccessibleAfterFirstUnlockThisDeviceOnly]]; 468| 0|} 469| | 470| |- (void)storeExpectedNonce:(NSString *)nonceExpected keychainStore:(FBSDKKeychainStore *)keychainStore 471| 0|{ 472| 0| [keychainStore setString:nonceExpected 473| 0| forKey:FBSDKExpectedNonceKey 474| 0| accessibility:[FBSDKDynamicFrameworkLoader loadkSecAttrAccessibleAfterFirstUnlockThisDeviceOnly]]; 475| 0|} 476| | 477| |+ (NSString *)stringForChallenge 478| 0|{ 479| 0| NSString *challenge = fb_randomString(FBClientStateChallengeLength); 480| | 481| 0| return [challenge stringByReplacingOccurrencesOfString:@"+" withString:@"="]; 482| 0|} 483| | 484| |- (void)validateReauthentication:(FBSDKAccessToken *)currentToken withResult:(FBSDKLoginManagerLoginResult *)loginResult 485| 0|{ 486| 0| id provider = [FBSDKGraphRequestConnectionFactory new]; 487| 0| [self validateReauthenticationWithGraphRequestConnectionProvider:provider withToken:currentToken withResult:loginResult]; 488| 0|} 489| | 490| |- (void)validateReauthenticationWithGraphRequestConnectionProvider:(nonnull id)connectionProvider 491| | withToken:(FBSDKAccessToken *)currentToken 492| | withResult:(FBSDKLoginManagerLoginResult *)loginResult 493| 0|{ 494| 0| FBSDKGraphRequest *request = [[FBSDKGraphRequest alloc] initWithGraphPath:@"me" 495| 0| parameters:@{@"fields" : @""} 496| 0| tokenString:loginResult.token.tokenString 497| 0| HTTPMethod:nil 498| 0| flags:FBSDKGraphRequestFlagDoNotInvalidateTokenOnError | FBSDKGraphRequestFlagDisableErrorRecovery]; 499| 0| FBSDKGraphRequestCompletion handler = ^(id connection, id result, NSError *error) { 500| 0| NSString *actualID = result[@"id"]; 501| 0| if ([currentToken.userID isEqualToString:actualID]) { 502| 0| [FBSDKAccessToken setCurrentAccessToken:loginResult.token]; 503| 0| [self invokeHandler:loginResult error:nil]; 504| 0| } else { 505| 0| NSMutableDictionary *userInfo = [NSMutableDictionary dictionary]; 506| 0| [FBSDKTypeUtility dictionary:userInfo setObject:error forKey:NSUnderlyingErrorKey]; 507| 0| NSError *resultError = [NSError errorWithDomain:FBSDKLoginErrorDomain 508| 0| code:FBSDKLoginErrorUserMismatch 509| 0| userInfo:userInfo]; 510| 0| [self invokeHandler:nil error:resultError]; 511| 0| } 512| 0| }; 513| | 514| 0| id connection = [connectionProvider createGraphRequestConnection]; 515| 0| [connection addRequest:request completion:handler]; 516| 0| [connection start]; 517| 0|} 518| | 519| |// change bool to auth method string. 520| |- (void)performBrowserLogInWithHandler:(FBSDKBrowserLoginSuccessBlock)handler 521| 0|{ 522| 0| [_logger willAttemptAppSwitchingBehavior]; 523| | 524| 0| FBSDKServerConfiguration *serverConfiguration = [FBSDKServerConfigurationManager cachedServerConfiguration]; 525| 0| BOOL useSafariViewController = [serverConfiguration useSafariViewControllerForDialogName:FBSDKDialogConfigurationNameLogin]; 526| 0| NSString *authMethod = (useSafariViewController ? FBSDKLoginManagerLoggerAuthMethod_SFVC : FBSDKLoginManagerLoggerAuthMethod_Browser); 527| | 528| 0| NSDictionary *loginParams = [self logInParametersWithConfiguration:_configuration 529| 0| serverConfiguration:serverConfiguration 530| 0| logger:_logger 531| 0| authMethod:authMethod]; 532| 0| NSError *error; 533| 0| NSURL *authURL = nil; 534| 0| if (loginParams[@"redirect_uri"]) { 535| 0| authURL = [FBSDKInternalUtility facebookURLWithHostPrefix:@"m." 536| 0| path:FBSDKOauthPath 537| 0| queryParameters:loginParams 538| 0| error:&error]; 539| 0| } 540| | 541| 0| [_logger startAuthMethod:authMethod]; 542| | 543| 0| if (authURL) { 544| 0| void (^handlerWrapper)(BOOL, NSError *) = ^(BOOL didOpen, NSError *anError) { 545| 0| if (handler) { 546| 0| handler(didOpen, anError); 547| 0| } 548| 0| }; 549| | 550| 0| if (useSafariViewController) { 551| | // Note based on above, authURL must be a http scheme. If that changes, add a guard, otherwise SFVC can throw 552| 0| self->_usedSFAuthSession = YES; 553| 0| [[FBSDKBridgeAPI sharedInstance] openURLWithSafariViewController:authURL 554| 0| sender:self 555| 0| fromViewController:self.fromViewController 556| 0| handler:handlerWrapper]; 557| 0| } else { 558| 0| [[FBSDKBridgeAPI sharedInstance] openURL:authURL sender:self handler:handlerWrapper]; 559| 0| } 560| 0| } else { 561| 0| error = error ?: [FBSDKError errorWithCode:FBSDKLoginErrorUnknown message:@"Failed to construct oauth browser url"]; 562| 0| if (handler) { 563| 0| handler(NO, error); 564| 0| } 565| 0| } 566| 0|} 567| | 568| |- (FBSDKLoginManagerLoginResult *)cancelledResultFromParameters:(FBSDKLoginCompletionParameters *)parameters 569| 0|{ 570| 0| NSSet *declinedPermissions = nil; 571| 0| if (FBSDKAccessToken.currentAccessToken != nil) { 572| | // Always include the list of declined permissions from this login request 573| | // if an access token is already cached by the SDK 574| 0| declinedPermissions = [FBSDKPermission rawPermissionsFromPermissions:parameters.declinedPermissions]; 575| 0| } 576| | 577| 0| return [[FBSDKLoginManagerLoginResult alloc] initWithToken:nil 578| 0| authenticationToken:nil 579| 0| isCancelled:YES 580| 0| grantedPermissions:NSSet.set 581| 0| declinedPermissions:declinedPermissions]; 582| 0|} 583| | 584| |- (FBSDKLoginManagerLoginResult *)successResultFromParameters:(FBSDKLoginCompletionParameters *)parameters 585| 0|{ 586| 0| NSSet *grantedPermissions = parameters.permissions; 587| 0| NSSet *declinedPermissions = parameters.declinedPermissions; 588| | 589| | // Recent permissions are largely based on the existence of an access token 590| | // without an access token the 'recent' permissions will match the 591| | // intersect of the granted permissions and the requested permissions. 592| | // This is important because we want to create a 'result' that accurately reflects 593| | // the currently granted permissions even when there is no access token. 594| 0| NSSet *recentlyGrantedPermissions = [self recentlyGrantedPermissionsFromGrantedPermissions:grantedPermissions]; 595| 0| NSSet *recentlyDeclinedPermissions = [self recentlyDeclinedPermissionsFromDeclinedPermissions:declinedPermissions]; 596| | 597| 0| if (recentlyGrantedPermissions.count > 0) { 598| 0| NSSet *rawGrantedPermissions = [FBSDKPermission rawPermissionsFromPermissions:grantedPermissions]; 599| 0| NSSet *rawDeclinedPermissions = [FBSDKPermission rawPermissionsFromPermissions:declinedPermissions]; 600| 0| NSSet *rawRecentlyGrantedPermissions = [FBSDKPermission rawPermissionsFromPermissions:recentlyGrantedPermissions]; 601| 0| NSSet *rawRecentlyDeclinedPermissions = [FBSDKPermission rawPermissionsFromPermissions:recentlyDeclinedPermissions]; 602| | 603| 0| FBSDKAccessToken *token; 604| 0| if (parameters.accessTokenString) { 605| 0| #pragma clang diagnostic push 606| 0| #pragma clang diagnostic ignored "-Wdeprecated-declarations" 607| 0| token = [[FBSDKAccessToken alloc] initWithTokenString:parameters.accessTokenString 608| 0| permissions:rawGrantedPermissions.allObjects 609| 0| declinedPermissions:rawDeclinedPermissions.allObjects 610| 0| expiredPermissions:@[] 611| 0| appID:parameters.appID 612| 0| userID:parameters.userID 613| 0| expirationDate:parameters.expirationDate 614| 0| refreshDate:[NSDate date] 615| 0| dataAccessExpirationDate:parameters.dataAccessExpirationDate 616| 0| graphDomain:parameters.graphDomain]; 617| 0| #pragma clange diagnostic pop 618| 0| } 619| | 620| 0| return [[FBSDKLoginManagerLoginResult alloc] initWithToken:token 621| 0| authenticationToken:parameters.authenticationToken 622| 0| isCancelled:NO 623| 0| grantedPermissions:rawRecentlyGrantedPermissions 624| 0| declinedPermissions:rawRecentlyDeclinedPermissions]; 625| 0| } else { 626| 0| return [self cancelledResultFromParameters:parameters]; 627| 0| } 628| 0|} 629| | 630| | #pragma mark - Permissions Helpers 631| | 632| |- (NSSet *)recentlyGrantedPermissionsFromGrantedPermissions:(NSSet *)grantedPermissions 633| 0|{ 634| 0| NSMutableSet *recentlyGrantedPermissions = grantedPermissions.mutableCopy; 635| 0| NSSet *previouslyGrantedPermissions = FBSDKAccessToken.currentAccessToken.permissions; 636| | 637| | // If there were no requested permissions for this auth, or no previously granted permissions - treat all permissions as recently granted. 638| | // Otherwise this is a reauth, so recentlyGranted should be a subset of what was requested. 639| 0| if (previouslyGrantedPermissions.count > 0 && _requestedPermissions.count != 0) { 640| 0| [recentlyGrantedPermissions intersectSet:_requestedPermissions]; 641| 0| } 642| | 643| 0| return recentlyGrantedPermissions; 644| 0|} 645| | 646| |- (NSSet *)recentlyDeclinedPermissionsFromDeclinedPermissions:(NSSet *)declinedPermissions 647| 0|{ 648| 0| NSMutableSet *recentlyDeclinedPermissions = _requestedPermissions.mutableCopy; 649| 0| [recentlyDeclinedPermissions intersectSet:declinedPermissions]; 650| 0| return recentlyDeclinedPermissions; 651| 0|} 652| | 653| | #pragma mark - Test Methods 654| | 655| |- (void)setHandler:(FBSDKLoginManagerLoginResultBlock)handler 656| 0|{ 657| 0| _handler = [handler copy]; 658| 0|} 659| | 660| |- (void)setRequestedPermissions:(NSSet *)requestedPermissions 661| 0|{ 662| 0| _requestedPermissions = [FBSDKPermission permissionsFromRawPermissions:requestedPermissions]; 663| 0|} 664| | 665| |- (FBSDKLoginConfiguration *)configuration 666| 0|{ 667| 0| return _configuration; 668| 0|} 669| | 670| | #pragma mark - FBSDKURLOpening 671| |- (BOOL)application:(UIApplication *)application openURL:(NSURL *)url sourceApplication:(NSString *)sourceApplication annotation:(id)annotation 672| 0|{ 673| 0| BOOL isFacebookURL = [self canOpenURL:url forApplication:application sourceApplication:sourceApplication annotation:annotation]; 674| | 675| 0| if (!isFacebookURL && [self isPerformingLogin]) { 676| 0| [self handleImplicitCancelOfLogIn]; 677| 0| } 678| | 679| 0| if (isFacebookURL) { 680| 0| NSDictionary *urlParameters = [FBSDKLoginUtility queryParamsFromLoginURL:url]; 681| 0| id completer = [[FBSDKLoginURLCompleter alloc] initWithURLParameters:urlParameters 682| 0| appID:FBSDKSettings.appID 683| 0| connectionProvider:FBSDKGraphRequestConnectionFactory.new 684| 0| authenticationTokenCreator:FBSDKAuthenticationTokenFactory.new]; 685| | 686| | // any necessary strong reference is maintained by the FBSDKLoginURLCompleter handler 687| 0| [completer completeLoginWithHandler:^(FBSDKLoginCompletionParameters *parameters) { 688| 0| if ((self->_configuration) && (self->_logger == nil)) { 689| 0| self->_logger = [FBSDKLoginManagerLogger loggerFromParameters:urlParameters 690| 0| tracking:self->_configuration.tracking]; 691| 0| } 692| 0| [self completeAuthentication:parameters expectChallenge:YES]; 693| 0| } nonce:[self loadExpectedNonce]]; 694| 0| [self storeExpectedNonce:nil keychainStore:_keychainStore]; 695| 0| } 696| | 697| 0| return isFacebookURL; 698| 0|} 699| | 700| |- (BOOL) canOpenURL:(NSURL *)url 701| | forApplication:(UIApplication *)application 702| | sourceApplication:(NSString *)sourceApplication 703| | annotation:(id)annotation 704| 0|{ 705| | // verify the URL is intended as a callback for the SDK's log in 706| 0| return [url.scheme hasPrefix:[NSString stringWithFormat:@"fb%@", [FBSDKSettings appID]]] 707| 0| && [url.host isEqualToString:@"authorize"]; 708| 0|} 709| | 710| |- (void)applicationDidBecomeActive:(UIApplication *)application 711| 0|{ 712| 0| if ([self isPerformingLogin]) { 713| 0| [self handleImplicitCancelOfLogIn]; 714| 0| } 715| 0|} 716| | 717| |- (BOOL)isAuthenticationURL:(NSURL *)url 718| 0|{ 719| 0| return [url.path hasSuffix:FBSDKOauthPath]; 720| 0|} 721| | 722| |- (BOOL)shouldStopPropagationOfURL:(NSURL *)url 723| 0|{ 724| 0| return 725| 0| [url.scheme hasPrefix:[NSString stringWithFormat:@"fb%@", [FBSDKSettings appID]]] 726| 0| && [url.host isEqualToString:@"no-op"]; 727| 0|} 728| | 729| |@end 730| | 731| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/FBSDKLoginManagerLoginResult.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKLoginManagerLoginResult+Internal.h" 24| | 25| | #ifdef FBSDKCOCOAPODS 26| | #import 27| | #else 28| | #import "FBSDKCoreKit+Internal.h" 29| | #endif 30| | 31| | #import "FBSDKCoreKitBasicsImportForLoginKit.h" 32| | 33| |@implementation FBSDKLoginManagerLoginResult 34| |{ 35| | NSMutableDictionary *_mutableLoggingExtras; 36| |} 37| | 38| |- (instancetype)initWithToken:(FBSDKAccessToken *)token 39| | authenticationToken:(FBSDKAuthenticationToken *)authenticationToken 40| | isCancelled:(BOOL)isCancelled 41| | grantedPermissions:(NSSet *)grantedPermissions 42| | declinedPermissions:(NSSet *)declinedPermissions 43| 0|{ 44| 0| if ((self = [super init])) { 45| 0| _mutableLoggingExtras = [NSMutableDictionary dictionary]; 46| 0| _token = token ? [token copy] : nil; 47| 0| _authenticationToken = authenticationToken; 48| 0| _isCancelled = isCancelled; 49| 0| _grantedPermissions = [grantedPermissions copy]; 50| 0| _declinedPermissions = [declinedPermissions copy]; 51| 0| } 52| 0| ; 53| 0| return self; 54| 0|} 55| | 56| |- (void)addLoggingExtra:(id)object forKey:(id)key 57| 0|{ 58| 0| [FBSDKTypeUtility dictionary:_mutableLoggingExtras setObject:object forKey:key]; 59| 0|} 60| | 61| |- (NSDictionary *)loggingExtras 62| 0|{ 63| 0| return [_mutableLoggingExtras copy]; 64| 0|} 65| | 66| |@end 67| | 68| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKAuthenticationTokenFactory.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKAuthenticationTokenFactory.h" 20| | 21| |#import 22| | 23| |#import 24| | 25| |#import "FBSDKAuthenticationTokenHeader.h" 26| |#import "FBSDKCoreKitBasicsImportForLoginKit.h" 27| |#import "FBSDKCoreKitImport.h" 28| | 29| |@interface NSURLSession (SessionProviding) 30| |@end 31| | 32| |static NSString *const FBSDKBeginCertificate = @"-----BEGIN CERTIFICATE-----"; 33| |static NSString *const FBSDKEndCertificate = @"-----END CERTIFICATE-----"; 34| | 35| |typedef void (^FBSDKPublicCertCompletionBlock)(SecCertificateRef cert); 36| |typedef void (^FBSDKPublicKeyCompletionBlock)(SecKeyRef key); 37| |typedef void (^FBSDKVerifySignatureCompletionBlock)(BOOL success); 38| | 39| |@interface FBSDKAuthenticationToken (FactoryInitializer) 40| | 41| |- (instancetype)initWithTokenString:(NSString *)tokenString 42| | nonce:(NSString *)nonce 43| | graphDomain:(NSString *)graphDomain; 44| | 45| |@end 46| | 47| |@interface FBSDKAuthenticationTokenClaims (Internal) 48| | 49| |+ (nullable FBSDKAuthenticationTokenClaims *)claimsFromEncodedString:(NSString *)encodedClaims nonce:(NSString *)expectedNonce; 50| | 51| |@end 52| | 53| |@interface FBSDKAuthenticationTokenFactory () 54| | 55| |@end 56| | 57| |@implementation FBSDKAuthenticationTokenFactory 58| |{ 59| | NSString *_cert; 60| | id _sessionProvider; 61| |} 62| | 63| |- (instancetype)init 64| 0|{ 65| 0| self = [self initWithSessionProvider:[NSURLSession sessionWithConfiguration:NSURLSessionConfiguration.defaultSessionConfiguration delegate:self delegateQueue:nil]]; 66| 0| return self; 67| 0|} 68| | 69| |- (instancetype)initWithSessionProvider:(id)sessionProvider 70| 0|{ 71| 0| if ((self = [super init])) { 72| 0| _sessionProvider = sessionProvider; 73| 0| } 74| 0| return self; 75| 0|} 76| | 77| |- (void)createTokenFromTokenString:(NSString *_Nonnull)tokenString 78| | nonce:(NSString *_Nonnull)nonce 79| | completion:(FBSDKAuthenticationTokenBlock)completion 80| 0|{ 81| 0| [self createTokenFromTokenString:tokenString 82| 0| nonce:nonce 83| 0| graphDomain:@"facebook" 84| 0| completion:completion]; 85| 0|} 86| | 87| |- (void)createTokenFromTokenString:(NSString *_Nonnull)tokenString 88| | nonce:(NSString *_Nonnull)nonce 89| | graphDomain:(NSString *)graphDomain 90| | completion:(FBSDKAuthenticationTokenBlock)completion 91| 0|{ 92| 0| if (tokenString.length == 0 || nonce.length == 0) { 93| 0| completion(nil); 94| 0| return; 95| 0| } 96| | 97| 0| NSString *signature; 98| 0| FBSDKAuthenticationTokenClaims *claims; 99| 0| FBSDKAuthenticationTokenHeader *header; 100| | 101| 0| NSArray *segments = [tokenString componentsSeparatedByString:@"."]; 102| 0| if (segments.count != 3) { 103| 0| completion(nil); 104| 0| return; 105| 0| } 106| | 107| 0| NSString *encodedHeader = [FBSDKTypeUtility array:segments objectAtIndex:0]; 108| 0| NSString *encodedClaims = [FBSDKTypeUtility array:segments objectAtIndex:1]; 109| 0| signature = [FBSDKTypeUtility array:segments objectAtIndex:2]; 110| | 111| 0| claims = [FBSDKAuthenticationTokenClaims claimsFromEncodedString:encodedClaims nonce:nonce]; 112| 0| header = [FBSDKAuthenticationTokenHeader headerFromEncodedString:encodedHeader]; 113| | 114| 0| if (!claims || !header) { 115| 0| completion(nil); 116| 0| return; 117| 0| } 118| | 119| 0| [self verifySignature:signature 120| 0| header:encodedHeader 121| 0| claims:encodedClaims 122| 0| certificateKey:header.kid 123| 0| completion:^(BOOL success) { 124| 0| if (success) { 125| 0| FBSDKAuthenticationToken *token = [[FBSDKAuthenticationToken alloc] initWithTokenString:tokenString 126| 0| nonce:nonce 127| 0| graphDomain:graphDomain]; 128| 0| completion(token); 129| 0| } else { 130| 0| completion(nil); 131| 0| } 132| 0| }]; 133| 0|} 134| | 135| |- (void)verifySignature:(NSString *)signature 136| | header:(NSString *)header 137| | claims:(NSString *)claims 138| | certificateKey:(NSString *)certificateKey 139| | completion:(FBSDKVerifySignatureCompletionBlock)completion 140| 0|{ 141| 0|#if DEBUG 142| 0|#if FBSDKTEST 143| | // skip signature checking for tests 144| 0| if (_skipSignatureVerification && completion) { 145| 0| completion(YES); 146| 0| } 147| 0|#endif 148| 0|#endif 149| | 150| 0| NSData *signatureData = [FBSDKBase64 decodeAsData:[FBSDKBase64 base64FromBase64Url:signature]]; 151| 0| NSString *signedString = [NSString stringWithFormat:@"%@.%@", header, claims]; 152| 0| NSData *signedData = [signedString dataUsingEncoding:NSASCIIStringEncoding]; 153| 0| [self getPublicKeyWithCertificateKey:certificateKey 154| 0| completion:^(SecKeyRef key) { 155| 0| if (key && signatureData && signedData) { 156| 0| size_t signatureBytesSize = SecKeyGetBlockSize(key); 157| 0| const void *signatureBytes = signatureData.bytes; 158| | 159| 0| size_t digestSize = CC_SHA256_DIGEST_LENGTH; 160| 0| uint8_t digestBytes[digestSize]; 161| 0| CC_SHA256(signedData.bytes, (CC_LONG)signedData.length, digestBytes); 162| | 163| 0| OSStatus status = SecKeyRawVerify( 164| 0| key, 165| 0| kSecPaddingPKCS1SHA256, 166| 0| digestBytes, 167| 0| digestSize, 168| 0| signatureBytes, 169| 0| signatureBytesSize 170| 0| ); 171| 0| fb_dispatch_on_main_thread(^{ 172| 0| completion(status == errSecSuccess); 173| 0| }); 174| 0| } else { 175| 0| fb_dispatch_on_main_thread(^{ 176| 0| completion(NO); 177| 0| }); 178| 0| } 179| 0| }]; 180| 0|} 181| | 182| |- (void)getPublicKeyWithCertificateKey:(NSString *)certificateKey 183| | completion:(FBSDKPublicKeyCompletionBlock)completion 184| 0|{ 185| 0| [self getCertificateWithKey:certificateKey 186| 0| completion:^(SecCertificateRef cert) { 187| 0| SecKeyRef publicKey = nil; 188| | 189| 0| if (cert) { 190| 0| SecPolicyRef policy = SecPolicyCreateBasicX509(); 191| 0| OSStatus status = -1; 192| 0| SecTrustRef trust; 193| | 194| 0| status = SecTrustCreateWithCertificates(cert, policy, &trust); 195| | 196| 0| if (status == errSecSuccess && trust) { 197| 0| publicKey = SecTrustCopyPublicKey(trust); 198| 0| } 199| | 200| 0| CFRelease(policy); 201| 0| CFRelease(cert); 202| 0| } 203| | 204| 0| completion(publicKey); 205| 0| }]; 206| 0|} 207| | 208| |- (void)getCertificateWithKey:(NSString *)certificateKey 209| | completion:(FBSDKPublicCertCompletionBlock)completion 210| 0|{ 211| 0| NSURLRequest *request = [NSURLRequest requestWithURL:[self _certificateEndpoint]]; 212| 0| [[_sessionProvider dataTaskWithRequest:request 213| 0| completionHandler:^(NSData *_Nullable data, NSURLResponse *_Nullable response, NSError *_Nullable error) { 214| 0| if (error || !data) { 215| 0| return completion(nil); 216| 0| } 217| | 218| 0| if ([response isKindOfClass:[NSHTTPURLResponse class]]) { 219| 0| NSHTTPURLResponse *httpResponse = (NSHTTPURLResponse *)response; 220| 0| if (httpResponse.statusCode != 200) { 221| 0| return completion(nil); 222| 0| } 223| 0| } 224| | 225| 0| SecCertificateRef result = NULL; 226| 0| NSDictionary *certs = [FBSDKTypeUtility JSONObjectWithData:data options:0 error:nil]; 227| 0| NSString *certString = [FBSDKTypeUtility dictionary:certs objectForKey:certificateKey ofType:NSString.class]; 228| 0| if (!certString) { 229| 0| return completion(nil); 230| 0| } 231| 0| certString = [certString stringByReplacingOccurrencesOfString:FBSDKBeginCertificate withString:@""]; 232| 0| certString = [certString stringByReplacingOccurrencesOfString:FBSDKEndCertificate withString:@""]; 233| 0| certString = [certString stringByReplacingOccurrencesOfString:@"\n" withString:@""]; 234| | 235| 0| NSData *secCertificateData = [[NSData alloc] initWithBase64EncodedString:certString options:0]; 236| 0| result = SecCertificateCreateWithData(kCFAllocatorDefault, (__bridge CFDataRef)secCertificateData); 237| 0| completion(result); 238| 0| }] resume]; 239| 0|} 240| | 241| |- (NSURL *)_certificateEndpoint 242| 0|{ 243| 0| NSError *error; 244| 0| NSURL *url = [FBSDKUtility unversionedFacebookURLWithHostPrefix:@"m" 245| 0| path:@"/.well-known/oauth/openid/certs/" 246| 0| queryParameters:@{} 247| 0| error:&error]; 248| | 249| 0| return url; 250| 0|} 251| | 252| |#pragma mark - Test methods 253| | 254| |#if DEBUG 255| | #if FBSDKTEST 256| | 257| |static BOOL _skipSignatureVerification; 258| | 259| |+ (void)setSkipSignatureVerification:(BOOL)value 260| 0|{ 261| 0| _skipSignatureVerification = value; 262| 0|} 263| | 264| |+ (instancetype)emptyInstance 265| 0|{ 266| 0| return [super new]; 267| 0|} 268| | 269| |- (void)setCertificate:(NSString *)certificate 270| 0|{ 271| 0| _cert = certificate; 272| 0|} 273| | 274| | #endif 275| |#endif 276| | 277| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKAuthenticationTokenHeader.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKAuthenticationTokenHeader.h" 20| | 21| |#import "FBSDKCoreKitBasicsImportForLoginKit.h" 22| | 23| |@implementation FBSDKAuthenticationTokenHeader 24| | 25| |- (instancetype)initWithAlg:(NSString *)alg 26| | typ:(NSString *)typ 27| | kid:(NSString *)kid 28| 0|{ 29| 0| if (self = [super init]) { 30| 0| _alg = alg; 31| 0| _typ = typ; 32| 0| _kid = kid; 33| 0| } 34| | 35| 0| return self; 36| 0|} 37| | 38| |+ (nullable FBSDKAuthenticationTokenHeader *)headerFromEncodedString:(NSString *)encodedHeader 39| 0|{ 40| 0| NSError *error; 41| 0| NSData *headerData = [FBSDKBase64 decodeAsData:[FBSDKBase64 base64FromBase64Url:encodedHeader]]; 42| | 43| 0| if (headerData) { 44| 0| NSDictionary *header = [FBSDKTypeUtility JSONObjectWithData:headerData options:0 error:&error]; 45| 0| NSString *alg = [FBSDKTypeUtility dictionary:header objectForKey:@"alg" ofType:NSString.class]; 46| 0| NSString *typ = [FBSDKTypeUtility dictionary:header objectForKey:@"typ" ofType:NSString.class]; 47| 0| NSString *kid = [FBSDKTypeUtility dictionary:header objectForKey:@"kid" ofType:NSString.class]; 48| 0| if (!error && [alg isEqualToString:@"RS256"] && [typ isEqualToString:@"JWT"] && kid.length > 0) { 49| 0| return [[FBSDKAuthenticationTokenHeader alloc] initWithAlg:alg typ:typ kid:kid]; 50| 0| } 51| 0| } 52| | 53| 0| return nil; 54| 0|} 55| | 56| |- (BOOL)isEqualToHeader:(FBSDKAuthenticationTokenHeader *)header 57| 0|{ 58| 0| return [_alg isEqualToString:header.alg] 59| 0| && [_typ isEqualToString:header.typ] 60| 0| && [_kid isEqualToString:header.kid]; 61| 0|} 62| | 63| |- (BOOL)isEqual:(id)object 64| 0|{ 65| 0| if (self == object) { 66| 0| return YES; 67| 0| } 68| | 69| 0| if (![object isKindOfClass:[FBSDKAuthenticationTokenHeader class]]) { 70| 0| return NO; 71| 0| } 72| | 73| 0| return [self isEqualToHeader:(FBSDKAuthenticationTokenHeader *)object]; 74| 0|} 75| | 76| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKLoginCompletion.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKLoginCompletion+Internal.h" 24| | 25| | #if SWIFT_PACKAGE 26| |@import FBSDKCoreKit; 27| | #else 28| | #import 29| | #endif 30| | 31| | #import "FBSDKAuthenticationTokenCreating.h" 32| | #import "FBSDKCoreKitBasicsImportForLoginKit.h" 33| | #import "FBSDKLoginConstants.h" 34| | #import "FBSDKLoginError.h" 35| | #import "FBSDKLoginManager+Internal.h" 36| | #import "FBSDKLoginUtility.h" 37| | #import "FBSDKPermission.h" 38| | #import "FBSDKProfileFactory.h" 39| | 40| |@implementation FBSDKLoginCompletionParameters 41| | 42| |- (instancetype)init 43| 0|{ 44| 0| return [super init]; 45| 0|} 46| | 47| |- (instancetype)initWithError:(NSError *)error 48| 0|{ 49| 0| if ((self = [self init]) != nil) { 50| 0| self.error = error; 51| 0| } 52| 0| return self; 53| 0|} 54| | 55| |@end 56| | 57| | #pragma mark - Completers 58| | 59| |@implementation FBSDKLoginURLCompleter 60| |{ 61| | FBSDKLoginCompletionParameters *_parameters; 62| | id _observer; 63| | BOOL _performExplicitFallback; 64| | id _connectionProvider; 65| | id _authenticationTokenCreator; 66| |} 67| | 68| |static id _profileFactory; 69| |static NSDateFormatter *_dateFormatter; 70| | 71| |+ (void)initialize 72| 0|{ 73| 0| if (self == [FBSDKLoginURLCompleter class]) { 74| 0| _profileFactory = [FBSDKProfileFactory new]; 75| 0| } 76| 0|} 77| | 78| |- (instancetype)initWithURLParameters:(NSDictionary *)parameters 79| | appID:(NSString *)appID 80| | connectionProvider:(id)connectionProvider 81| | authenticationTokenCreator:(id)authenticationTokenCreator 82| 0|{ 83| 0| if ((self = [super init]) != nil) { 84| 0| _connectionProvider = connectionProvider; 85| 0| _authenticationTokenCreator = authenticationTokenCreator; 86| 0| _parameters = [FBSDKLoginCompletionParameters new]; 87| | 88| 0| BOOL hasNonEmptyNonceString = ((NSString *)[FBSDKTypeUtility dictionary:parameters objectForKey:@"nonce" ofType:NSString.class]).length > 0; 89| 0| BOOL hasNonEmptyIdTokenString = ((NSString *)[FBSDKTypeUtility dictionary:parameters objectForKey:@"id_token" ofType:NSString.class]).length > 0; 90| 0| BOOL hasNonEmptyAccessTokenString = ((NSString *)[FBSDKTypeUtility dictionary:parameters objectForKey:@"access_token" ofType:NSString.class]).length > 0; 91| | 92| | // Nonce and id token are mutually exclusive parameters 93| 0| BOOL hasBothNonceAndIdToken = hasNonEmptyNonceString && hasNonEmptyIdTokenString; 94| 0| BOOL hasEitherNonceOrIdToken = hasNonEmptyNonceString || hasNonEmptyIdTokenString; 95| | 96| 0| if (hasNonEmptyAccessTokenString || (hasEitherNonceOrIdToken && !hasBothNonceAndIdToken)) { 97| 0| [self setParametersWithDictionary:parameters appID:appID]; 98| 0| } else if ([FBSDKTypeUtility dictionary:parameters objectForKey:@"error" ofType:NSString.class] || [FBSDKTypeUtility dictionary:parameters objectForKey:@"error_message" ofType:NSString.class]) { 99| 0| [self setErrorWithDictionary:parameters]; 100| 0| } else if (hasBothNonceAndIdToken) { 101| | // If a nonce is present in the parameter we assume that 102| | // user logged in by app switching. 103| | // Currently OIDC is not supported for app switching. We 104| | // will treat the login attempt as invalid if an ID token 105| | // if returned together with nonce. 106| 0| _parameters.error = [FBSDKError errorWithCode:FBSDKLoginErrorUnknown message:@"Invalid server response. Please try to login again"]; 107| 0| } 108| 0| } 109| 0| return self; 110| 0|} 111| | 112| |- (void)completeLoginWithHandler:(FBSDKLoginCompletionParametersBlock)handler 113| 0|{ 114| 0| [self completeLoginWithHandler:handler nonce:nil]; 115| 0|} 116| | 117| |/// Performs the work needed to populate the login completion parameters before they 118| |/// are used to determine login success, failure or cancellation. 119| |- (void)completeLoginWithHandler:(FBSDKLoginCompletionParametersBlock)handler 120| | nonce:(nullable NSString *)nonce 121| 0|{ 122| | // If there is a nonceString then it means we logged in from the app. 123| 0| if (_parameters.nonceString) { 124| 0| [self exchangeNonceForTokenWithHandler:handler authenticationNonce:nonce]; 125| 0| } else if (_parameters.authenticationTokenString && !nonce) { 126| | // If there is no nonce then somehow an auth token string was provided 127| | // but the call did not originate from the sdk. This is not a valid state 128| 0| _parameters.error = [FBSDKError errorWithCode:FBSDKLoginErrorUnknown message:@"Please try to login again"]; 129| 0| handler(_parameters); 130| 0| } else if (_parameters.authenticationTokenString && nonce) { 131| 0| [self fetchAndSetPropertiesForParameters:_parameters 132| 0| nonce:nonce 133| 0| handler:handler]; 134| 0| } else { 135| 0| handler(_parameters); 136| 0| } 137| 0|} 138| | 139| |/// Sets authenticationToken and profile onto the provided parameters and calls the provided completion handler 140| |- (void)fetchAndSetPropertiesForParameters:(nonnull FBSDKLoginCompletionParameters *)parameters 141| | nonce:(nonnull NSString *)nonce 142| | handler:(FBSDKLoginCompletionParametersBlock)handler 143| 0|{ 144| 0| FBSDKAuthenticationTokenBlock completion = ^(FBSDKAuthenticationToken *token) { 145| 0| if (token) { 146| 0| parameters.authenticationToken = token; 147| 0| parameters.profile = [FBSDKLoginURLCompleter profileWithClaims:token.claims]; 148| 0| } else { 149| 0| parameters.error = [FBSDKError errorWithCode:FBSDKLoginErrorInvalidIDToken message:@"Invalid ID token from login response."]; 150| 0| } 151| 0| handler(parameters); 152| 0| }; 153| 0| [_authenticationTokenCreator createTokenFromTokenString:_parameters.authenticationTokenString 154| 0| nonce:nonce 155| 0| graphDomain:parameters.graphDomain 156| 0| completion:completion]; 157| 0|} 158| | 159| |- (void)setParametersWithDictionary:(NSDictionary *)parameters appID:(NSString *)appID 160| 0|{ 161| 0| NSString *grantedPermissionsString = [FBSDKTypeUtility dictionary:parameters objectForKey:@"granted_scopes" ofType:NSString.class]; 162| 0| NSString *declinedPermissionsString = [FBSDKTypeUtility dictionary:parameters objectForKey:@"denied_scopes" ofType:NSString.class]; 163| 0| NSString *signedRequest = [FBSDKTypeUtility dictionary:parameters objectForKey:@"signed_request" ofType:NSString.class]; 164| 0| NSString *userID = [FBSDKTypeUtility dictionary:parameters objectForKey:@"user_id" ofType:NSString.class]; 165| 0| NSString *domain = [FBSDKTypeUtility dictionary:parameters objectForKey:@"graph_domain" ofType:NSString.class]; 166| | 167| 0| _parameters.accessTokenString = [FBSDKTypeUtility dictionary:parameters objectForKey:@"access_token" ofType:NSString.class]; 168| 0| _parameters.nonceString = [FBSDKTypeUtility dictionary:parameters objectForKey:@"nonce" ofType:NSString.class]; 169| 0| _parameters.authenticationTokenString = [FBSDKTypeUtility dictionary:parameters objectForKey:@"id_token" ofType:NSString.class]; 170| | 171| | // check the string length so that we assign an empty set rather than a set with an empty string 172| 0| _parameters.permissions = (grantedPermissionsString.length > 0) 173| 0| ? [FBSDKPermission permissionsFromRawPermissions:[NSSet setWithArray:[grantedPermissionsString componentsSeparatedByString:@","]]] 174| 0| : NSSet.set; 175| 0| _parameters.declinedPermissions = (declinedPermissionsString.length > 0) 176| 0| ? [FBSDKPermission permissionsFromRawPermissions:[NSSet setWithArray:[declinedPermissionsString componentsSeparatedByString:@","]]] 177| 0| : NSSet.set; 178| | 179| 0| _parameters.expiredPermissions = NSSet.set; 180| | 181| 0| _parameters.appID = appID; 182| | 183| 0| if (userID.length == 0 && signedRequest.length > 0) { 184| 0| _parameters.userID = [FBSDKLoginUtility userIDFromSignedRequest:signedRequest]; 185| 0| } else { 186| 0| _parameters.userID = userID; 187| 0| } 188| | 189| 0| if (domain.length > 0) { 190| 0| _parameters.graphDomain = domain; 191| 0| } 192| | 193| 0| _parameters.expirationDate = [FBSDKLoginURLCompleter expirationDateFromParameters:parameters]; 194| 0| _parameters.dataAccessExpirationDate = [FBSDKLoginURLCompleter dataAccessExpirationDateFromParameters:parameters]; 195| 0| _parameters.challenge = [FBSDKLoginURLCompleter challengeFromParameters:parameters]; 196| 0|} 197| | 198| |- (void)setErrorWithDictionary:(NSDictionary *)parameters 199| 0|{ 200| 0| NSString *legacyErrorReason = [FBSDKTypeUtility dictionary:parameters objectForKey:@"error" ofType:NSString.class]; 201| | 202| 0| if ([legacyErrorReason isEqualToString:@"service_disabled_use_browser"] 203| 0| || [legacyErrorReason isEqualToString:@"service_disabled"]) { 204| 0| _performExplicitFallback = YES; 205| 0| } 206| | 207| | // if error is nil, then this should be processed as a cancellation unless 208| | // _performExplicitFallback is set to YES and the log in behavior is Native. 209| 0| _parameters.error = [NSError fbErrorFromReturnURLParameters:parameters]; 210| 0|} 211| | 212| |- (void)exchangeNonceForTokenWithHandler:(FBSDKLoginCompletionParametersBlock)handler 213| | authenticationNonce:(NSString *)authenticationNonce 214| 0|{ 215| 0| if (!handler) { 216| 0| return; 217| 0| } 218| | 219| 0| NSString *nonce = _parameters.nonceString ?: @""; 220| 0| NSString *appID = _parameters.appID ?: @""; 221| | 222| 0| if (nonce.length == 0 || appID.length == 0) { 223| 0| _parameters.error = [FBSDKError errorWithCode:FBSDKErrorInvalidArgument message:@"Missing required parameters to exchange nonce for access token."]; 224| 0| handler(_parameters); 225| 0| return; 226| 0| } 227| | 228| 0| FBSDKGraphRequest *tokenRequest = [[FBSDKGraphRequest alloc] 229| 0| initWithGraphPath:@"oauth/access_token" 230| 0| parameters:@{ @"grant_type" : @"fb_exchange_nonce", 231| 0| @"fb_exchange_nonce" : nonce, 232| 0| @"client_id" : appID, 233| 0| @"fields" : @"" } 234| 0| flags:FBSDKGraphRequestFlagDoNotInvalidateTokenOnError 235| 0| | FBSDKGraphRequestFlagDisableErrorRecovery]; 236| 0| __block FBSDKLoginCompletionParameters *parameters = _parameters; 237| 0| id connection = [_connectionProvider createGraphRequestConnection]; 238| 0| [connection addRequest:tokenRequest completion:^(id requestConnection, 239| 0| id result, 240| 0| NSError *graphRequestError) { 241| 0| if (!graphRequestError) { 242| 0| parameters.accessTokenString = [FBSDKTypeUtility dictionary:result objectForKey:@"access_token" ofType:NSString.class]; 243| 0| parameters.expirationDate = [FBSDKLoginURLCompleter expirationDateFromParameters:result]; 244| 0| parameters.dataAccessExpirationDate = [FBSDKLoginURLCompleter dataAccessExpirationDateFromParameters:result]; 245| 0| parameters.authenticationTokenString = [FBSDKTypeUtility dictionary:result objectForKey:@"id_token" ofType:NSString.class]; 246| | 247| 0| if (parameters.authenticationTokenString) { 248| 0| [self fetchAndSetPropertiesForParameters:parameters 249| 0| nonce:authenticationNonce 250| 0| handler:handler]; 251| 0| return; 252| 0| } 253| 0| } else { 254| 0| parameters.error = graphRequestError; 255| 0| } 256| | 257| 0| handler(parameters); 258| 0| }]; 259| | 260| 0| [connection start]; 261| 0|} 262| | 263| |+ (nullable FBSDKProfile *)profileWithClaims:(FBSDKAuthenticationTokenClaims *)claims 264| 0|{ 265| 0| if (claims.sub.length == 0) { 266| 0| return nil; 267| 0| } 268| | 269| 0| NSURL *imageURL; 270| 0| if (claims.picture) { 271| 0| imageURL = [NSURL URLWithString:claims.picture]; 272| 0| } 273| | 274| 0| NSDate *birthday; 275| 0| if (claims.userBirthday) { 276| 0| [FBSDKLoginURLCompleter.dateFormatter setDateFormat:@"MM/dd/yyyy"]; 277| 0| birthday = [FBSDKLoginURLCompleter.dateFormatter dateFromString:claims.userBirthday]; 278| 0| } 279| | 280| 0| return [_profileFactory createProfileWithUserID:claims.sub 281| 0| firstName:claims.givenName 282| 0| middleName:claims.middleName 283| 0| lastName:claims.familyName 284| 0| name:claims.name 285| 0| linkURL:[NSURL URLWithString:claims.userLink] 286| 0| refreshDate:nil 287| 0| imageURL:imageURL 288| 0| email:claims.email 289| 0| friendIDs:claims.userFriends 290| 0| birthday:birthday 291| 0| ageRange:[FBSDKUserAgeRange ageRangeFromDictionary:claims.userAgeRange] 292| 0| hometown:[FBSDKLocation locationFromDictionary:claims.userHometown] 293| 0| location:[FBSDKLocation locationFromDictionary:claims.userLocation] 294| 0| gender:claims.userGender 295| 0| isLimited:YES]; 296| 0|} 297| | 298| |+ (NSDate *)expirationDateFromParameters:(NSDictionary *)parameters 299| 0|{ 300| 0| NSString *expiresString = [FBSDKTypeUtility dictionary:parameters objectForKey:@"expires" ofType:NSString.class]; 301| 0| NSString *expiresAtString = [FBSDKTypeUtility dictionary:parameters objectForKey:@"expires_at" ofType:NSString.class]; 302| 0| NSString *expiresInString = [FBSDKTypeUtility dictionary:parameters objectForKey:@"expires_in" ofType:NSString.class]; 303| 0| NSString *expirationDateString = expiresString ?: expiresAtString; 304| | 305| 0| if (expirationDateString.doubleValue > 0) { 306| 0| return [NSDate dateWithTimeIntervalSince1970:expirationDateString.doubleValue]; 307| 0| } else if (expiresInString.integerValue > 0) { 308| 0| return [NSDate dateWithTimeIntervalSinceNow:expiresInString.integerValue]; 309| 0| } else { 310| 0| return NSDate.distantFuture; 311| 0| } 312| 0|} 313| | 314| |+ (NSDate *)dataAccessExpirationDateFromParameters:(NSDictionary *)parameters 315| 0|{ 316| 0| NSString *dataAccessExpirationDateString = [FBSDKTypeUtility dictionary:parameters objectForKey:@"data_access_expiration_time" ofType:NSString.class]; 317| 0| if (dataAccessExpirationDateString.integerValue > 0) { 318| 0| return [NSDate dateWithTimeIntervalSince1970:dataAccessExpirationDateString.integerValue]; 319| 0| } else { 320| 0| return NSDate.distantFuture; 321| 0| } 322| 0|} 323| | 324| |+ (NSString *)challengeFromParameters:(NSDictionary *)parameters 325| 0|{ 326| 0| NSString *stateString = [FBSDKTypeUtility dictionary:parameters objectForKey:@"state" ofType:NSString.class]; 327| 0| if (stateString.length > 0) { 328| 0| NSError *error = nil; 329| 0| NSDictionary *state = [FBSDKBasicUtility objectForJSONString:stateString error:&error]; 330| | 331| 0| if (!error) { 332| 0| NSString *challenge = [FBSDKTypeUtility dictionary:state objectForKey:@"challenge" ofType:NSString.class]; 333| 0| if (challenge.length > 0) { 334| 0| return [FBSDKUtility URLDecode:challenge]; 335| 0| } 336| 0| } 337| 0| } 338| 0| return nil; 339| 0|} 340| | 341| |+ (NSDateFormatter *)dateFormatter 342| 0|{ 343| 0| if (!_dateFormatter) { 344| 0| _dateFormatter = NSDateFormatter.new; 345| 0| } 346| 0| return _dateFormatter; 347| 0|} 348| | 349| |// MARK: Test Helpers 350| | 351| | #if DEBUG 352| | #if FBSDKTEST 353| | 354| |+ (id)profileFactory 355| 0|{ 356| 0| return _profileFactory; 357| 0|} 358| | 359| |+ (void)setProfileFactory:(id)factory 360| 0|{ 361| 0| _profileFactory = factory; 362| 0|} 363| | 364| |- (FBSDKLoginCompletionParameters *)parameters 365| 0|{ 366| 0| return _parameters; 367| 0|} 368| | 369| |+ (void)reset 370| 0|{ 371| 0| _profileFactory = [FBSDKProfileFactory new]; 372| 0|} 373| | 374| | #endif 375| | #endif 376| | 377| |@end 378| | 379| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKLoginManagerLogger.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKLoginManagerLogger.h" 24| | 25| | #import "FBSDKCoreKitBasicsImportForLoginKit.h" 26| | #import "FBSDKLoginError.h" 27| | #import "FBSDKLoginManagerLoginResult+Internal.h" 28| | #import "FBSDKLoginUtility.h" 29| | #import "FBSDKMonotonicTime.h" 30| | 31| |NSString *const FBSDKLoginManagerLoggerAuthMethod_Native = @"fb_application_web_auth"; 32| |NSString *const FBSDKLoginManagerLoggerAuthMethod_Browser = @"browser_auth"; 33| |NSString *const FBSDKLoginManagerLoggerAuthMethod_SFVC = @"sfvc_auth"; 34| |NSString *const FBSDKLoginManagerLoggerAuthMethod_Applink = @"applink_auth"; 35| | 36| |static NSString *const FBSDKLoginManagerLoggingClientStateKey = @"state"; 37| |static NSString *const FBSDKLoginManagerLoggingClientStateIsClientState = @"com.facebook.sdk_client_state"; 38| | 39| |static NSString *const FBSDKLoginManagerLoggerParamIdentifierKey = @"0_auth_logger_id"; 40| |static NSString *const FBSDKLoginManagerLoggerParamTimestampKey = @"1_timestamp_ms"; 41| |static NSString *const FBSDKLoginManagerLoggerParamResultKey = @"2_result"; 42| |static NSString *const FBSDKLoginManagerLoggerParamAuthMethodKey = @"3_method"; 43| |static NSString *const FBSDKLoginManagerLoggerParamErrorCodeKey = @"4_error_code"; 44| |static NSString *const FBSDKLoginManagerLoggerParamErrorMessageKey = @"5_error_message"; 45| |static NSString *const FBSDKLoginManagerLoggerParamExtrasKey = @"6_extras"; 46| |static NSString *const FBSDKLoginManagerLoggerParamLoggingTokenKey = @"7_logging_token"; 47| | 48| |static NSString *const FBSDKLoginManagerLoggerValueEmpty = @""; 49| | 50| |static NSString *const FBSDKLoginManagerLoggerResultSuccessString = @"success"; 51| |static NSString *const FBSDKLoginManagerLoggerResultCancelString = @"cancelled"; 52| |static NSString *const FBSDKLoginManagerLoggerResultErrorString = @"error"; 53| |static NSString *const FBSDKLoginManagerLoggerResultSkippedString = @"skipped"; 54| | 55| |static NSString *const FBSDKLoginManagerLoggerTryNative = @"tryFBAppAuth"; 56| |static NSString *const FBSDKLoginManagerLoggerTryBrowser = @"trySafariAuth"; 57| | 58| |/** Use to log the result of the App Switch OS AlertView. Only available on OS >= iOS10 */ 59| |FBSDKAppEventName const FBSDKAppEventNameFBSessionFASLoginDialogResult = @"fb_mobile_login_fas_dialog_result"; 60| | 61| |/** Use to log the start of an auth request that cannot be fulfilled by the token cache */ 62| |FBSDKAppEventName const FBSDKAppEventNameFBSessionAuthStart = @"fb_mobile_login_start"; 63| | 64| |/** Use to log the end of an auth request that was not fulfilled by the token cache */ 65| |FBSDKAppEventName const FBSDKAppEventNameFBSessionAuthEnd = @"fb_mobile_login_complete"; 66| | 67| |/** Use to log the start of a specific auth method as part of an auth request */ 68| |FBSDKAppEventName const FBSDKAppEventNameFBSessionAuthMethodStart = @"fb_mobile_login_method_start"; 69| | 70| |/** Use to log the end of the last tried auth method as part of an auth request */ 71| |FBSDKAppEventName const FBSDKAppEventNameFBSessionAuthMethodEnd = @"fb_mobile_login_method_complete"; 72| | 73| |/** Use to log the post-login heartbeat event after the end of an auth request*/ 74| |FBSDKAppEventName const FBSDKAppEventNameFBSessionAuthHeartbeat = @"fb_mobile_login_heartbeat"; 75| | 76| |@implementation FBSDKLoginManagerLogger 77| |{ 78| | @private 79| | NSString *_identifier; 80| | NSMutableDictionary *_extras; 81| | 82| | NSString *_lastResult; 83| | NSError *_lastError; 84| | 85| | NSString *_authMethod; 86| | NSString *_loggingToken; 87| |} 88| | 89| |+ (FBSDKLoginManagerLogger *)loggerFromParameters:(NSDictionary *)parameters 90| | tracking:(FBSDKLoginTracking)tracking 91| 0|{ 92| 0| NSDictionary *clientState = [FBSDKBasicUtility objectForJSONString:parameters[FBSDKLoginManagerLoggingClientStateKey] error:NULL]; 93| | 94| 0| id isClientState = clientState[FBSDKLoginManagerLoggingClientStateIsClientState]; 95| 0| if ([isClientState isKindOfClass:[NSNumber class]] && [isClientState boolValue]) { 96| 0| FBSDKLoginManagerLogger *logger = [[self alloc] initWithLoggingToken:nil tracking:tracking]; 97| 0| if (logger != nil) { 98| 0| logger->_identifier = clientState[FBSDKLoginManagerLoggerParamIdentifierKey]; 99| 0| logger->_authMethod = clientState[FBSDKLoginManagerLoggerParamAuthMethodKey]; 100| 0| logger->_loggingToken = clientState[FBSDKLoginManagerLoggerParamLoggingTokenKey]; 101| 0| return logger; 102| 0| } 103| 0| } 104| 0| return nil; 105| 0|} 106| | 107| |- (instancetype)initWithLoggingToken:(NSString *)loggingToken 108| | tracking:(FBSDKLoginTracking)tracking 109| 0|{ 110| 0| switch (tracking) { 111| 0| case FBSDKLoginTrackingEnabled: 112| 0| break; 113| 0| case FBSDKLoginTrackingLimited: 114| 0| return nil; 115| 0| } 116| | 117| 0| if ((self = [super init]) != nil) { 118| 0| _identifier = [NSUUID UUID].UUIDString; 119| 0| _extras = [NSMutableDictionary dictionary]; 120| 0| _loggingToken = [loggingToken copy]; 121| 0| } 122| 0| return self; 123| 0|} 124| | 125| |- (void)startSessionForLoginManager:(FBSDKLoginManager *)loginManager 126| 0|{ 127| 0| BOOL isReauthorize = ([FBSDKAccessToken currentAccessToken] != nil); 128| 0| BOOL willTryNative = NO; 129| 0| BOOL willTryBrowser = YES; 130| 0| NSString *behaviorString = @"FBSDKLoginBehaviorBrowser"; 131| | 132| 0| [_extras addEntriesFromDictionary:@{ 133| 0| FBSDKLoginManagerLoggerTryNative : @(willTryNative), 134| 0| FBSDKLoginManagerLoggerTryBrowser : @(willTryBrowser), 135| 0| @"isReauthorize" : @(isReauthorize), 136| 0| @"login_behavior" : behaviorString, 137| 0| @"default_audience" : [FBSDKLoginUtility stringForAudience:loginManager.defaultAudience], 138| 0| @"permissions" : [loginManager.requestedPermissions.allObjects componentsJoinedByString:@","] ?: @"" 139| 0| }]; 140| | 141| 0| [self logEvent:FBSDKAppEventNameFBSessionAuthStart params:[self _parametersForNewEvent]]; 142| 0|} 143| | 144| |- (void)endSession 145| 0|{ 146| 0| [self logEvent:FBSDKAppEventNameFBSessionAuthEnd result:_lastResult error:_lastError]; 147| 0| if (FBSDKAppEvents.flushBehavior != FBSDKAppEventsFlushBehaviorExplicitOnly) { 148| 0| [FBSDKAppEvents flush]; 149| 0| } 150| 0|} 151| | 152| |- (void)startAuthMethod:(NSString *)authMethod 153| 0|{ 154| 0| _authMethod = [authMethod copy]; 155| 0| [self logEvent:FBSDKAppEventNameFBSessionAuthMethodStart params:[self _parametersForNewEvent]]; 156| 0|} 157| | 158| |- (void)endLoginWithResult:(FBSDKLoginManagerLoginResult *)result error:(NSError *)error 159| 0|{ 160| 0| NSString *resultString = @""; 161| | 162| 0| if (error != nil) { 163| 0| resultString = FBSDKLoginManagerLoggerResultErrorString; 164| 0| } else if (result.isCancelled) { 165| 0| resultString = FBSDKLoginManagerLoggerResultCancelString; 166| 0| } else if (result.isSkipped) { 167| 0| resultString = FBSDKLoginManagerLoggerResultSkippedString; 168| 0| } else if (result.token) { 169| 0| resultString = FBSDKLoginManagerLoggerResultSuccessString; 170| 0| if (result.declinedPermissions.count) { 171| 0| [FBSDKTypeUtility dictionary:_extras setObject:[result.declinedPermissions.allObjects componentsJoinedByString:@","] forKey:@"declined_permissions"]; 172| 0| } 173| 0| } 174| | 175| 0| _lastResult = resultString; 176| 0| _lastError = error; 177| 0| [_extras addEntriesFromDictionary:result.loggingExtras]; 178| | 179| 0| [self logEvent:FBSDKAppEventNameFBSessionAuthMethodEnd result:resultString error:error]; 180| 0|} 181| | 182| |- (void)postLoginHeartbeat 183| 0|{ 184| 0| [NSTimer scheduledTimerWithTimeInterval:5.0 target:self selector:@selector(heartbestTimerDidFire) userInfo:nil repeats:NO]; 185| 0|} 186| | 187| |- (void)heartbestTimerDidFire 188| 0|{ 189| 0| [self logEvent:FBSDKAppEventNameFBSessionAuthHeartbeat result:_lastResult error:_lastError]; 190| 0|} 191| | 192| |+ (NSDictionary *)parametersWithTimeStampAndClientState:(NSDictionary *)loginParams 193| | forAuthMethod:(NSString *)authMethod 194| | logger:(FBSDKLoginManagerLogger *)logger 195| 0|{ 196| 0| NSMutableDictionary *params = [loginParams mutableCopy]; 197| | 198| 0| NSTimeInterval timeValue = (NSTimeInterval)FBSDKMonotonicTimeGetCurrentSeconds(); 199| 0| NSString *e2eTimestampString = [FBSDKBasicUtility JSONStringForObject:@{ @"init" : @(timeValue) } 200| 0| error:NULL 201| 0| invalidObjectHandler:NULL]; 202| 0| [FBSDKTypeUtility dictionary:params setObject:e2eTimestampString forKey:@"e2e"]; 203| | 204| 0| NSDictionary *existingState = [FBSDKBasicUtility objectForJSONString:params[FBSDKLoginManagerLoggingClientStateKey] error:NULL]; 205| 0| [FBSDKTypeUtility dictionary:params 206| 0| setObject:[FBSDKLoginManagerLogger clientStateForAuthMethod:authMethod 207| 0| andExistingState:existingState 208| 0| logger:logger] 209| 0| forKey:FBSDKLoginManagerLoggingClientStateKey]; 210| 0| return params; 211| 0|} 212| | 213| |- (void)willAttemptAppSwitchingBehavior 214| 0|{ 215| 0| NSString *defaultUrlScheme = [NSString stringWithFormat:@"fb%@%@", [FBSDKSettings appID], [FBSDKSettings appURLSchemeSuffix] ?: @""]; 216| 0| BOOL isURLSchemeRegistered = [FBSDKInternalUtility isRegisteredURLScheme:defaultUrlScheme]; 217| | 218| 0| BOOL isFacebookAppCanOpenURLSchemeRegistered = [FBSDKInternalUtility isRegisteredCanOpenURLScheme:FBSDK_CANOPENURL_FACEBOOK]; 219| 0| BOOL isMessengerAppCanOpenURLSchemeRegistered = [FBSDKInternalUtility isRegisteredCanOpenURLScheme:FBSDK_CANOPENURL_MESSENGER]; 220| | 221| 0| [_extras addEntriesFromDictionary:@{ 222| 0| @"isURLSchemeRegistered" : @(isURLSchemeRegistered), 223| 0| @"isFacebookAppCanOpenURLSchemeRegistered" : @(isFacebookAppCanOpenURLSchemeRegistered), 224| 0| @"isMessengerAppCanOpenURLSchemeRegistered" : @(isMessengerAppCanOpenURLSchemeRegistered), 225| 0| }]; 226| 0|} 227| | 228| |- (void)logNativeAppDialogResult:(BOOL)result dialogDuration:(NSTimeInterval)dialogDuration 229| 0|{ 230| 0| NSOperatingSystemVersion iOS10Version = { .majorVersion = 10, .minorVersion = 0, .patchVersion = 0 }; 231| 0| if ([NSProcessInfo.processInfo isOperatingSystemAtLeastVersion:iOS10Version]) { 232| 0| [FBSDKTypeUtility dictionary:_extras setObject:@(dialogDuration) forKey:@"native_app_login_dialog_duration"]; 233| 0| [FBSDKTypeUtility dictionary:_extras setObject:@(result) forKey:@"native_app_login_dialog_result"]; 234| 0| [self logEvent:FBSDKAppEventNameFBSessionFASLoginDialogResult params:[self _parametersForNewEvent]]; 235| 0| } 236| 0|} 237| | 238| |- (void)addSingleLoggingExtra:(id)extra forKey:(NSString *)key 239| 0|{ 240| 0| [FBSDKTypeUtility dictionary:_extras setObject:extra forKey:key]; 241| 0|} 242| | 243| | #pragma mark - Private 244| | 245| |- (NSString *)identifier 246| 0|{ 247| 0| return _identifier; 248| 0|} 249| | 250| |+ (NSString *)clientStateForAuthMethod:(NSString *)authMethod 251| | andExistingState:(NSDictionary *)existingState 252| | logger:(FBSDKLoginManagerLogger *)logger 253| 0|{ 254| 0| NSDictionary *clientState = @{ 255| 0| FBSDKLoginManagerLoggerParamAuthMethodKey : authMethod ?: @"", 256| 0| FBSDKLoginManagerLoggerParamIdentifierKey : logger.identifier ?: NSUUID.UUID.UUIDString, 257| 0| FBSDKLoginManagerLoggingClientStateIsClientState : @YES, 258| 0| }; 259| | 260| 0| if (existingState) { 261| 0| NSMutableDictionary *mutableState = [clientState mutableCopy]; 262| 0| [mutableState addEntriesFromDictionary:existingState]; 263| 0| clientState = mutableState; 264| 0| } 265| | 266| 0| return [FBSDKBasicUtility JSONStringForObject:clientState error:NULL invalidObjectHandler:NULL]; 267| 0|} 268| | 269| |- (NSMutableDictionary *)_parametersForNewEvent 270| 0|{ 271| 0| NSMutableDictionary *eventParameters = [NSMutableDictionary new]; 272| | 273| | // NOTE: We ALWAYS add all params to each event, to ensure predictable mapping on the backend. 274| 0| [FBSDKTypeUtility dictionary:eventParameters setObject:_identifier ?: FBSDKLoginManagerLoggerValueEmpty forKey:FBSDKLoginManagerLoggerParamIdentifierKey]; 275| 0| [FBSDKTypeUtility dictionary:eventParameters setObject:@(round(1000 * [NSDate date].timeIntervalSince1970)) forKey:FBSDKLoginManagerLoggerParamTimestampKey]; 276| 0| [FBSDKTypeUtility dictionary:eventParameters setObject:FBSDKLoginManagerLoggerValueEmpty forKey:FBSDKLoginManagerLoggerParamResultKey]; 277| 0| [FBSDKTypeUtility dictionary:eventParameters setObject:_authMethod forKey:FBSDKLoginManagerLoggerParamAuthMethodKey]; 278| 0| [FBSDKTypeUtility dictionary:eventParameters setObject:FBSDKLoginManagerLoggerValueEmpty forKey:FBSDKLoginManagerLoggerParamErrorCodeKey]; 279| 0| [FBSDKTypeUtility dictionary:eventParameters setObject:FBSDKLoginManagerLoggerValueEmpty forKey:FBSDKLoginManagerLoggerParamErrorMessageKey]; 280| 0| [FBSDKTypeUtility dictionary:eventParameters setObject:FBSDKLoginManagerLoggerValueEmpty forKey:FBSDKLoginManagerLoggerParamExtrasKey]; 281| 0| [FBSDKTypeUtility dictionary:eventParameters setObject:_loggingToken ?: FBSDKLoginManagerLoggerValueEmpty forKey:FBSDKLoginManagerLoggerParamLoggingTokenKey]; 282| | 283| 0| return eventParameters; 284| 0|} 285| | 286| |- (void)logEvent:(NSString *)eventName params:(NSMutableDictionary *)params 287| 0|{ 288| 0| if (_identifier) { 289| 0| NSString *extrasJSONString = [FBSDKBasicUtility JSONStringForObject:_extras 290| 0| error:NULL 291| 0| invalidObjectHandler:NULL]; 292| 0| if (extrasJSONString) { 293| 0| [FBSDKTypeUtility dictionary:params setObject:extrasJSONString forKey:FBSDKLoginManagerLoggerParamExtrasKey]; 294| 0| } 295| 0| [_extras removeAllObjects]; 296| | 297| 0| [FBSDKAppEvents logInternalEvent:eventName 298| 0| parameters:params 299| 0| isImplicitlyLogged:YES]; 300| 0| } 301| 0|} 302| | 303| |- (void)logEvent:(NSString *)eventName result:(NSString *)result error:(NSError *)error 304| 0|{ 305| 0| NSMutableDictionary *params = [self _parametersForNewEvent]; 306| | 307| 0| [FBSDKTypeUtility dictionary:params setObject:result forKey:FBSDKLoginManagerLoggerParamResultKey]; 308| | 309| 0| if ([error.domain isEqualToString:FBSDKErrorDomain] || [error.domain isEqualToString:FBSDKLoginErrorDomain]) { 310| | // tease apart the structure. 311| | 312| | // first see if there is an explicit message in the error's userInfo. If not, default to the reason, 313| | // which is less useful. 314| 0| NSString *value = error.userInfo[@"error_message"] ?: error.userInfo[FBSDKErrorLocalizedDescriptionKey]; 315| 0| [FBSDKTypeUtility dictionary:params setObject:value forKey:FBSDKLoginManagerLoggerParamErrorMessageKey]; 316| | 317| 0| value = error.userInfo[FBSDKGraphRequestErrorGraphErrorCodeKey] ?: [NSString stringWithFormat:@"%ld", (long)error.code]; 318| 0| [FBSDKTypeUtility dictionary:params setObject:value forKey:FBSDKLoginManagerLoggerParamErrorCodeKey]; 319| | 320| 0| NSError *innerError = error.userInfo[NSUnderlyingErrorKey]; 321| 0| if (innerError != nil) { 322| 0| value = innerError.userInfo[@"error_message"] ?: innerError.userInfo[NSLocalizedDescriptionKey]; 323| 0| [FBSDKTypeUtility dictionary:_extras setObject:value forKey:@"inner_error_message"]; 324| | 325| 0| value = innerError.userInfo[FBSDKGraphRequestErrorGraphErrorCodeKey] ?: [NSString stringWithFormat:@"%ld", (long)innerError.code]; 326| 0| [FBSDKTypeUtility dictionary:_extras setObject:value forKey:@"inner_error_code"]; 327| 0| } 328| 0| } else if (error) { 329| 0| [FBSDKTypeUtility dictionary:params setObject:@(error.code) forKey:FBSDKLoginManagerLoggerParamErrorCodeKey]; 330| 0| [FBSDKTypeUtility dictionary:params setObject:error.localizedDescription forKey:FBSDKLoginManagerLoggerParamErrorMessageKey]; 331| 0| } 332| | 333| 0| [self logEvent:eventName params:params]; 334| 0|} 335| | 336| |@end 337| | 338| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKLoginUtility.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKLoginUtility.h" 24| | 25| | #if SWIFT_PACKAGE 26| |@import FBSDKCoreKit; 27| | #else 28| | #import 29| | #endif 30| | 31| | #ifdef FBSDKCOCOAPODS 32| | #import 33| | #else 34| | #import "FBSDKCoreKit+Internal.h" 35| | #endif 36| | 37| | #import "FBSDKCoreKitBasicsImportForLoginKit.h" 38| | #import "FBSDKLoginConstants.h" 39| | 40| |@implementation FBSDKLoginUtility 41| | 42| |+ (NSString *)stringForAudience:(FBSDKDefaultAudience)audience 43| 0|{ 44| 0| switch (audience) { 45| 0| case FBSDKDefaultAudienceOnlyMe: 46| 0| return @"only_me"; 47| 0| case FBSDKDefaultAudienceFriends: 48| 0| return @"friends"; 49| 0| case FBSDKDefaultAudienceEveryone: 50| 0| return @"everyone"; 51| 0| } 52| 0|} 53| | 54| |+ (NSDictionary *)queryParamsFromLoginURL:(NSURL *)url 55| 0|{ 56| 0| NSString *expectedUrlPrefix = [FBSDKInternalUtility 57| 0| appURLWithHost:@"authorize" 58| 0| path:@"" 59| 0| queryParameters:@{} 60| 0| error:NULL].absoluteString; 61| 0| if (![url.absoluteString hasPrefix:expectedUrlPrefix]) { 62| | // Don't have an App ID, just verify path. 63| 0| NSString *host = url.host; 64| 0| if (![host isEqualToString:@"authorize"]) { 65| 0| return nil; 66| 0| } 67| 0| } 68| 0| NSMutableDictionary *params = [NSMutableDictionary dictionaryWithDictionary:[FBSDKInternalUtility parametersFromFBURL:url]]; 69| | 70| 0| NSString *userID = [[self class] userIDFromSignedRequest:params[@"signed_request"]]; 71| 0| if (userID) { 72| 0| [FBSDKTypeUtility dictionary:params setObject:userID forKey:@"user_id"]; 73| 0| } 74| | 75| 0| return params; 76| 0|} 77| | 78| |+ (NSString *)userIDFromSignedRequest:(NSString *)signedRequest 79| 0|{ 80| 0| if (!signedRequest) { 81| 0| return nil; 82| 0| } 83| | 84| 0| NSArray *signatureAndPayload = [signedRequest componentsSeparatedByString:@"."]; 85| 0| NSString *userID = nil; 86| | 87| 0| if (signatureAndPayload.count == 2) { 88| 0| NSData *data = [FBSDKBase64 decodeAsData:[FBSDKTypeUtility array:signatureAndPayload objectAtIndex:1]]; 89| 0| if (data) { 90| 0| NSDictionary *dictionary = [FBSDKTypeUtility JSONObjectWithData:data options:0 error:nil]; 91| 0| userID = dictionary[@"user_id"]; 92| 0| } 93| 0| } 94| 0| return userID; 95| 0|} 96| | 97| |@end 98| | 99| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKMonotonicTime.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKMonotonicTime.h" 24| | 25| | #include 26| | #include 27| | #include 28| | #include 29| | 30| |static uint64_t _get_time_nanoseconds(void) 31| 0|{ 32| 0| static struct mach_timebase_info tb_info = {0}; 33| 0| static dispatch_once_t onceToken; 34| 0| dispatch_once(&onceToken, ^{ 35| 0| int ret = mach_timebase_info(&tb_info); 36| 0| assert(0 == ret); 37| 0| }); 38| | 39| 0| return (mach_absolute_time() * tb_info.numer) / tb_info.denom; 40| 0|} 41| | 42| |FBSDKMonotonicTimeSeconds FBSDKMonotonicTimeGetCurrentSeconds(void) 43| 0|{ 44| 0| const uint64_t nowNanoSeconds = _get_time_nanoseconds(); 45| 0| return (FBSDKMonotonicTimeSeconds)nowNanoSeconds / (FBSDKMonotonicTimeSeconds)1000000000.0; 46| 0|} 47| | 48| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKNonceUtility.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKNonceUtility.h" 20| | 21| |#import "FBSDKCoreKitBasicsImportForLoginKit.h" 22| | 23| |@implementation FBSDKNonceUtility 24| | 25| |+ (BOOL)isValidNonce:(NSString *)nonce 26| 0|{ 27| 0| NSString *string = [FBSDKTypeUtility coercedToStringValue:nonce]; 28| 0| NSRange whiteSpaceRange = [string rangeOfCharacterFromSet:[NSCharacterSet whitespaceCharacterSet]]; 29| 0| BOOL containsWhitespace = (whiteSpaceRange.location != NSNotFound); 30| | 31| 0| return (([string length] > 0) && !containsWhitespace); 32| 0|} 33| | 34| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKPermission.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKPermission.h" 20| | 21| |#import "FBSDKCoreKitBasicsImportForLoginKit.h" 22| | 23| |@implementation FBSDKPermission 24| | 25| |- (nullable instancetype)initWithString:(NSString *)string 26| 0|{ 27| 0| NSString *permission = [FBSDKTypeUtility coercedToStringValue:string]; 28| 0| if (permission.length <= 0) { 29| 0| return nil; 30| 0| } 31| | 32| 0| NSCharacterSet *allowedSet = [NSCharacterSet characterSetWithCharactersInString:@"abcdefghijklmnopqrstuvwxyz_"]; 33| 0| if (![[string stringByTrimmingCharactersInSet:allowedSet] isEqualToString:@""]) { 34| 0| return nil; 35| 0| } 36| | 37| 0| if ((self = [super init])) { 38| 0| _value = permission; 39| 0| } 40| 0| return self; 41| 0|} 42| | 43| |+ (NSSet *)permissionsFromRawPermissions:(NSSet *)rawPermissions 44| 0|{ 45| 0| NSMutableSet *permissions = NSMutableSet.new; 46| | 47| 0| for (NSString *rawPermission in rawPermissions) { 48| 0| FBSDKPermission *permission = [[FBSDKPermission alloc] initWithString:rawPermission]; 49| 0| if (!permission) { 50| 0| return nil; 51| 0| } 52| 0| [permissions addObject:permission]; 53| 0| } 54| | 55| 0| return permissions; 56| 0|} 57| | 58| |+ (NSSet *)rawPermissionsFromPermissions:(NSSet *)permissions 59| 0|{ 60| 0| NSMutableSet *rawPermissions = NSMutableSet.new; 61| | 62| 0| for (FBSDKPermission *permission in permissions) { 63| 0| [rawPermissions addObject:permission.value]; 64| 0| } 65| | 66| 0| return rawPermissions; 67| 0|} 68| | 69| |- (BOOL)isEqual:(id)obj 70| 0|{ 71| 0| if (![obj isKindOfClass:[FBSDKPermission class]]) { 72| 0| return NO; 73| 0| } 74| | 75| 0| FBSDKPermission *other = (FBSDKPermission *)obj; 76| 0| return [self.value isEqualToString:other.value]; 77| 0|} 78| | 79| |- (NSString *)description 80| 0|{ 81| 0| return self.value; 82| 0|} 83| | 84| |- (NSUInteger)hash 85| 0|{ 86| 0| return self.value.hash; 87| 0|} 88| | 89| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKProfileFactory.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "FBSDKProfileFactory.h" 24| | 25| | #import "FBSDKLoginKit.h" 26| | 27| |@implementation FBSDKProfileFactory 28| | 29| |- (FBSDKProfile *)createProfileWithUserID:(FBSDKUserIdentifier *)userID 30| | firstName:(nullable NSString *)firstName 31| | middleName:(nullable NSString *)middleName 32| | lastName:(nullable NSString *)lastName 33| | name:(nullable NSString *)name 34| | linkURL:(nullable NSURL *)linkURL 35| | refreshDate:(nullable NSDate *)refreshDate 36| | imageURL:(nullable NSURL *)imageURL 37| | email:(nullable NSString *)email 38| | friendIDs:(nullable NSArray *)friendIDs 39| | birthday:(nullable NSDate *)birthday 40| | ageRange:(nullable FBSDKUserAgeRange *)ageRange 41| | hometown:(nullable FBSDKLocation *)hometown 42| | location:(nullable FBSDKLocation *)location 43| | gender:(nullable NSString *)gender 44| | isLimited:(BOOL)isLimited 45| 0|{ 46| 0| return [[FBSDKProfile alloc] initWithUserID:userID 47| 0| firstName:firstName 48| 0| middleName:middleName 49| 0| lastName:lastName 50| 0| name:name 51| 0| linkURL:linkURL 52| 0| refreshDate:refreshDate 53| 0| imageURL:imageURL 54| 0| email:email 55| 0| friendIDs:friendIDs 56| 0| birthday:birthday 57| 0| ageRange:ageRange 58| 0| hometown:hometown 59| 0| location:location 60| 0| gender:gender 61| 0| isLimited:isLimited]; 62| 0|} 63| | 64| |@end 65| | 66| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/_FBSDKLoginRecoveryAttempter.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "TargetConditionals.h" 20| | 21| |#if !TARGET_OS_TV 22| | 23| | #import "_FBSDKLoginRecoveryAttempter.h" 24| | 25| | #import "FBSDKLoginKit+Internal.h" 26| | #import "FBSDKLoginManagerLoginResult+Internal.h" 27| | 28| |@implementation _FBSDKLoginRecoveryAttempter 29| | 30| |- (void)attemptRecoveryFromError:(NSError *)error 31| | optionIndex:(NSUInteger)recoveryOptionIndex 32| | completionHandler:(void (^)(BOOL didRecover))completionHandler 33| 0|{ 34| 0| NSSet *currentPermissions = [FBSDKAccessToken currentAccessToken].permissions; 35| 0| if (recoveryOptionIndex == 0 && currentPermissions.count > 0) { 36| 0| FBSDKLoginManager *login = [FBSDKLoginManager new]; 37| 0| [login logInWithPermissions:currentPermissions.allObjects fromViewController:nil handler:^(FBSDKLoginManagerLoginResult *result, NSError *loginError) { 38| | // we can only consider a recovery successful if there are no declines 39| | // (note this could still set an updated currentAccessToken). 40| 0| completionHandler(!loginError && !result.isCancelled && result.declinedPermissions.count == 0); 41| 0| }]; 42| 0| } else { 43| 0| completionHandler(NO); 44| 0| } 45| 0|} 46| | 47| |@end 48| | 49| |#endif /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKBase64.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKBase64.h" 20| | 21| |@implementation FBSDKBase64 22| | 23| |static FBSDKBase64 *_decoder; 24| |static FBSDKBase64 *_encoder; 25| | 26| |#pragma mark - Class Methods 27| | 28| |+ (void)initialize 29| 0|{ 30| 0| if (self == [FBSDKBase64 class]) { 31| 0| _decoder = [FBSDKBase64 new]; 32| 0| _encoder = [FBSDKBase64 new]; 33| 0| } 34| 0|} 35| | 36| |+ (NSData *)decodeAsData:(NSString *)string 37| 0|{ 38| 0| return [_decoder decodeAsData:string]; 39| 0|} 40| | 41| |+ (NSString *)decodeAsString:(NSString *)string 42| 0|{ 43| 0| return [_decoder decodeAsString:string]; 44| 0|} 45| | 46| |+ (NSString *)encodeData:(NSData *)data 47| 0|{ 48| 0| return [_encoder encodeData:data]; 49| 0|} 50| | 51| |+ (NSString *)encodeString:(NSString *)string 52| 0|{ 53| 0| return [_encoder encodeString:string]; 54| 0|} 55| | 56| |+ (NSString *)base64FromBase64Url:(NSString *)base64Url 57| 0|{ 58| 0| NSString *base64 = [base64Url stringByReplacingOccurrencesOfString:@"-" withString:@"+"]; 59| 0| base64 = [base64 stringByReplacingOccurrencesOfString:@"_" withString:@"/"]; 60| | 61| 0| return base64; 62| 0|} 63| | 64| |#pragma mark - Object Lifecycle 65| | 66| |#pragma mark - Implementation Methods 67| | 68| |- (NSData *)decodeAsData:(NSString *)string 69| 0|{ 70| 0| if (!string) { 71| 0| return nil; 72| 0| } 73| | // This padding will be appended before stripping unknown characters, so if there are unknown characters of count % 4 74| | // it will not be able to decode. Since we assume valid base64 data, we will take this as is. 75| 0| int needPadding = string.length % 4; 76| 0| if (needPadding > 0) { 77| 0| needPadding = 4 - needPadding; 78| 0| string = [string stringByPaddingToLength:string.length + needPadding withString:@"=" startingAtIndex:0]; 79| 0| } 80| | 81| 0| return [[NSData alloc] initWithBase64EncodedString:string options:NSDataBase64DecodingIgnoreUnknownCharacters]; 82| 0|} 83| | 84| |- (NSString *)decodeAsString:(NSString *)string 85| 0|{ 86| 0| NSData *data = [self decodeAsData:string]; 87| 0| if (!data) { 88| 0| return nil; 89| 0| } 90| 0| return [[NSString alloc] initWithData:data encoding:NSUTF8StringEncoding]; 91| 0|} 92| | 93| |- (NSString *)encodeData:(NSData *)data 94| 0|{ 95| 0| if (!data) { 96| 0| return nil; 97| 0| } 98| | 99| 0| return [data base64EncodedStringWithOptions:0]; 100| 0|} 101| | 102| |- (NSString *)encodeString:(NSString *)string 103| 0|{ 104| 0| return [self encodeData:[string dataUsingEncoding:NSUTF8StringEncoding]]; 105| 0|} 106| | 107| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKBasicUtility.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKBasicUtility.h" 20| | 21| |#import 22| |#import 23| | 24| |#import "FBSDKTypeUtility.h" 25| | 26| 0|#define kChunkSize 1024 27| | 28| |static NSString *const FBSDK_BASICUTILITY_ANONYMOUSIDFILENAME = @"com-facebook-sdk-PersistedAnonymousID.json"; 29| |static NSString *const FBSDK_BASICUTILITY_ANONYMOUSID_KEY = @"anon_id"; 30| | 31| |void fb_dispatch_on_main_thread(dispatch_block_t block) 32| 0|{ 33| 0| if (block != nil) { 34| 0| if ([NSThread isMainThread]) { 35| 0| block(); 36| 0| } else { 37| 0| dispatch_async(dispatch_get_main_queue(), block); 38| 0| } 39| 0| } 40| 0|} 41| | 42| |void fb_dispatch_on_default_thread(dispatch_block_t block) 43| 0|{ 44| 0| if (block != nil) { 45| 0| dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_DEFAULT, 0), block); 46| 0| } 47| 0|} 48| | 49| |@protocol BASIC_FBSDKError 50| | 51| |+ (NSError *)invalidArgumentErrorWithName:(NSString *)name value:(id)value message:(NSString *)message; 52| | 53| |@end 54| | 55| |@implementation FBSDKBasicUtility 56| | 57| |+ (NSString *)JSONStringForObject:(id)object 58| | error:(NSError *__autoreleasing *)errorRef 59| | invalidObjectHandler:(FBSDKInvalidObjectHandler)invalidObjectHandler 60| 0|{ 61| 0| if (invalidObjectHandler || ![FBSDKTypeUtility isValidJSONObject:object]) { 62| 0| object = [self _convertObjectToJSONObject:object invalidObjectHandler:invalidObjectHandler stop:NULL]; 63| 0| if (![FBSDKTypeUtility isValidJSONObject:object]) { 64| 0| if (errorRef != NULL) { 65| 0| Class FBSDKErrorClass = NSClassFromString(@"FBSDKError"); 66| 0| if ([FBSDKErrorClass respondsToSelector:@selector(invalidArgumentErrorWithName:value:message:)]) { 67| 0| *errorRef = [FBSDKErrorClass invalidArgumentErrorWithName:@"object" 68| 0| value:object 69| 0| message:@"Invalid object for JSON serialization."]; 70| 0| } 71| 0| } 72| 0| return nil; 73| 0| } 74| 0| } 75| 0| NSData *data = [FBSDKTypeUtility dataWithJSONObject:object options:0 error:errorRef]; 76| 0| if (!data) { 77| 0| return nil; 78| 0| } 79| 0| return [[NSString alloc] initWithData:data encoding:NSUTF8StringEncoding]; 80| 0|} 81| | 82| |+ (BOOL) dictionary:(NSMutableDictionary *)dictionary 83| | setJSONStringForObject:(id)object 84| | forKey:(id)key 85| | error:(NSError *__autoreleasing *)errorRef 86| 0|{ 87| 0| if (!object || !key) { 88| 0| return YES; 89| 0| } 90| 0| NSString *JSONString = [self JSONStringForObject:object error:errorRef invalidObjectHandler:NULL]; 91| 0| if (!JSONString) { 92| 0| return NO; 93| 0| } 94| 0| [FBSDKTypeUtility dictionary:dictionary setObject:JSONString forKey:key]; 95| 0| return YES; 96| 0|} 97| | 98| |+ (id)_convertObjectToJSONObject:(id)object 99| | invalidObjectHandler:(FBSDKInvalidObjectHandler)invalidObjectHandler 100| | stop:(BOOL *)stopRef 101| 0|{ 102| 0| __block BOOL stop = NO; 103| 0| if ([object isKindOfClass:[NSString class]] || [object isKindOfClass:[NSNumber class]]) { 104| | // good to go, keep the object 105| 0| } else if ([object isKindOfClass:[NSURL class]]) { 106| 0| object = ((NSURL *)object).absoluteString; 107| 0| } else if ([object isKindOfClass:[NSDictionary class]]) { 108| 0| NSMutableDictionary *dictionary = [NSMutableDictionary new]; 109| 0| [FBSDKTypeUtility dictionary:(NSDictionary *) object enumerateKeysAndObjectsUsingBlock:^(id key, id obj, BOOL *dictionaryStop) { 110| 0| [FBSDKTypeUtility dictionary:dictionary 111| 0| setObject:[self _convertObjectToJSONObject:obj invalidObjectHandler:invalidObjectHandler stop:&stop] 112| 0| forKey:[FBSDKTypeUtility coercedToStringValue:key]]; 113| 0| if (stop) { 114| 0| *dictionaryStop = YES; 115| 0| } 116| 0| }]; 117| 0| object = dictionary; 118| 0| } else if ([object isKindOfClass:[NSArray class]]) { 119| 0| NSMutableArray *array = [NSMutableArray new]; 120| 0| for (id obj in (NSArray *)object) { 121| 0| id convertedObj = [self _convertObjectToJSONObject:obj invalidObjectHandler:invalidObjectHandler stop:&stop]; 122| 0| [FBSDKTypeUtility array:array addObject:convertedObj]; 123| 0| if (stop) { 124| 0| break; 125| 0| } 126| 0| } 127| 0| object = array; 128| 0| } else { 129| 0| object = invalidObjectHandler(object, stopRef); 130| 0| } 131| 0| if (stopRef != NULL) { 132| 0| *stopRef = stop; 133| 0| } 134| 0| return object; 135| 0|} 136| | 137| |+ (id)objectForJSONString:(NSString *)string error:(NSError *__autoreleasing *)errorRef 138| 0|{ 139| 0| NSData *data = [[FBSDKTypeUtility stringValueOrNil:string] dataUsingEncoding:NSUTF8StringEncoding]; 140| 0| if (!data) { 141| 0| if (errorRef != NULL) { 142| 0| *errorRef = nil; 143| 0| } 144| 0| return nil; 145| 0| } 146| 0| return [FBSDKTypeUtility JSONObjectWithData:data options:NSJSONReadingAllowFragments error:errorRef]; 147| 0|} 148| | 149| |+ (nullable NSString *)queryStringWithDictionary:(NSDictionary *)dictionary 150| | error:(NSError *__autoreleasing *)errorRef 151| | invalidObjectHandler:(FBSDKInvalidObjectHandler)invalidObjectHandler 152| 0|{ 153| 0| NSMutableString *queryString = [NSMutableString new]; 154| 0| __block BOOL hasParameters = NO; 155| 0| if (dictionary) { 156| 0| NSMutableArray *keys = [dictionary.allKeys mutableCopy]; 157| | // remove non-string keys, as they are not valid 158| 0| [keys filterUsingPredicate:[NSPredicate predicateWithBlock:^BOOL (id evaluatedObject, NSDictionary *bindings) { 159| 0| return [evaluatedObject isKindOfClass:[NSString class]]; 160| 0| }]]; 161| | // sort the keys so that the query string order is deterministic 162| 0| [keys sortUsingSelector:@selector(compare:)]; 163| 0| BOOL stop = NO; 164| 0| for (NSString *key in keys) { 165| 0| id value = [self convertRequestValue:dictionary[key]]; 166| 0| if ([value isKindOfClass:[NSString class]]) { 167| 0| value = [self URLEncode:value]; 168| 0| } 169| 0| if (invalidObjectHandler && ![value isKindOfClass:[NSString class]]) { 170| 0| value = invalidObjectHandler(value, &stop); 171| 0| if (stop) { 172| 0| break; 173| 0| } 174| 0| } 175| 0| if (value) { 176| 0| if (hasParameters) { 177| 0| [queryString appendString:@"&"]; 178| 0| } 179| 0| [queryString appendFormat:@"%@=%@", key, value]; 180| 0| hasParameters = YES; 181| 0| } 182| 0| } 183| 0| } 184| 0| if (errorRef != NULL) { 185| 0| *errorRef = nil; 186| 0| } 187| 0| return (queryString.length ? [queryString copy] : nil); 188| 0|} 189| | 190| |+ (id)convertRequestValue:(id)value 191| 0|{ 192| 0| if ([value isKindOfClass:[NSNumber class]]) { 193| 0| value = ((NSNumber *)value).stringValue; 194| 0| } else if ([value isKindOfClass:[NSURL class]]) { 195| 0| value = ((NSURL *)value).absoluteString; 196| 0| } 197| 0| return value; 198| 0|} 199| | 200| |#pragma clang diagnostic push 201| |#pragma clang diagnostic ignored "-Wdeprecated-declarations" 202| |+ (NSString *)URLEncode:(NSString *)value 203| 0|{ 204| 0| return (__bridge_transfer NSString *)CFURLCreateStringByAddingPercentEscapes( 205| 0| NULL, 206| 0| (CFStringRef)value, 207| 0| NULL, // characters to leave unescaped 208| 0| CFSTR(":!*();@/&?+$,='"), 209| 0| kCFStringEncodingUTF8 210| 0| ); 211| 0|} 212| | 213| |#pragma clang diagnostic pop 214| | 215| |+ (NSDictionary *)dictionaryWithQueryString:(NSString *)queryString 216| 0|{ 217| 0| NSMutableDictionary *result = [NSMutableDictionary new]; 218| 0| NSArray *parts = [queryString componentsSeparatedByString:@"&"]; 219| | 220| 0| for (NSString *part in parts) { 221| 0| if (part.length == 0) { 222| 0| continue; 223| 0| } 224| | 225| 0| NSRange index = [part rangeOfString:@"="]; 226| 0| NSString *key; 227| 0| NSString *value; 228| | 229| 0| if (index.location == NSNotFound) { 230| 0| key = part; 231| 0| value = @""; 232| 0| } else { 233| 0| key = [part substringToIndex:index.location]; 234| 0| value = [part substringFromIndex:index.location + index.length]; 235| 0| } 236| | 237| 0| key = [self URLDecode:key]; 238| 0| value = [self URLDecode:value]; 239| 0| if (key && value) { 240| 0| [FBSDKTypeUtility dictionary:result setObject:value forKey:key]; 241| 0| } 242| 0| } 243| 0| return result; 244| 0|} 245| | 246| |+ (NSString *)URLDecode:(NSString *)value 247| 0|{ 248| 0| value = [value stringByReplacingOccurrencesOfString:@"+" withString:@" "]; 249| 0| #pragma clang diagnostic push 250| 0| #pragma clang diagnostic ignored "-Wdeprecated-declarations" 251| 0| value = [value stringByReplacingPercentEscapesUsingEncoding:NSUTF8StringEncoding]; 252| 0| #pragma clang diagnostic pop 253| 0| return value; 254| 0|} 255| | 256| |+ (NSData *)gzip:(NSData *)data 257| 0|{ 258| 0| const void *bytes = data.bytes; 259| 0| const NSUInteger length = data.length; 260| | 261| 0| if (!bytes || !length) { 262| 0| return nil; 263| 0| } 264| | 265| 0|#if defined(__LP64__) && __LP64__ 266| 0| if (length > UINT_MAX) { 267| 0| return nil; 268| 0| } 269| 0|#endif 270| | 271| | // initialze stream 272| 0| z_stream stream; 273| 0| bzero(&stream, sizeof(z_stream)); 274| | 275| 0| if (deflateInit2(&stream, -1, Z_DEFLATED, 31, 8, Z_DEFAULT_STRATEGY) != Z_OK) { 276| 0| return nil; 277| 0| } 278| 0| stream.avail_in = (uint)length; 279| 0| stream.next_in = (Bytef *)bytes; 280| | 281| 0| int retCode; 282| 0| NSMutableData *result = [NSMutableData dataWithCapacity:(length / 4)]; 283| 0| unsigned char output[kChunkSize]; 284| 0| do { 285| 0| stream.avail_out = kChunkSize; 286| 0| stream.next_out = output; 287| 0| retCode = deflate(&stream, Z_FINISH); 288| 0| if (retCode != Z_OK && retCode != Z_STREAM_END) { 289| 0| deflateEnd(&stream); 290| 0| return nil; 291| 0| } 292| 0| unsigned size = kChunkSize - stream.avail_out; 293| 0| if (size > 0) { 294| 0| [result appendBytes:output length:size]; 295| 0| } 296| 0| } while (retCode == Z_OK); 297| | 298| 0| deflateEnd(&stream); 299| | 300| 0| return result; 301| 0|} 302| | 303| |+ (NSString *)anonymousID 304| 0|{ 305| | // Grab previously written anonymous ID and, if none have been generated, create and 306| | // persist a new one which will remain associated with this app. 307| 0| NSString *result = [[self class] retrievePersistedAnonymousID]; 308| 0| if (!result) { 309| | // Generate a new anonymous ID. Create as a UUID, but then prepend the fairly 310| | // arbitrary 'XZ' to the front so it's easily distinguishable from IDFA's which 311| | // will only contain hex. 312| 0| result = [NSString stringWithFormat:@"XZ%@", [NSUUID UUID].UUIDString]; 313| | 314| 0| [self persistAnonymousID:result]; 315| 0| } 316| 0| return result; 317| 0|} 318| | 319| |+ (NSString *)retrievePersistedAnonymousID 320| 0|{ 321| 0| NSString *file = [[self class] persistenceFilePath:FBSDK_BASICUTILITY_ANONYMOUSIDFILENAME]; 322| 0| NSString *content = [[NSString alloc] initWithContentsOfFile:file 323| 0| encoding:NSASCIIStringEncoding 324| 0| error:nil]; 325| 0| NSDictionary *results = [FBSDKBasicUtility objectForJSONString:content error:NULL]; 326| 0| return results[FBSDK_BASICUTILITY_ANONYMOUSID_KEY]; 327| 0|} 328| | 329| |+ (NSString *)persistenceFilePath:(NSString *)filename 330| 0|{ 331| 0| NSSearchPathDirectory directory = NSLibraryDirectory; 332| 0| NSArray *paths = NSSearchPathForDirectoriesInDomains(directory, NSUserDomainMask, YES); 333| 0| NSString *docDirectory = [FBSDKTypeUtility array:paths objectAtIndex:0]; 334| 0| return [docDirectory stringByAppendingPathComponent:filename]; 335| 0|} 336| | 337| |+ (void)persistAnonymousID:(NSString *)anonymousID 338| 0|{ 339| 0| NSDictionary *data = @{ FBSDK_BASICUTILITY_ANONYMOUSID_KEY : anonymousID }; 340| 0| NSString *content = [self JSONStringForObject:data error:NULL invalidObjectHandler:NULL]; 341| | 342| 0| [content writeToFile:[[self class] persistenceFilePath:FBSDK_BASICUTILITY_ANONYMOUSIDFILENAME] 343| 0| atomically:YES 344| 0| encoding:NSASCIIStringEncoding 345| 0| error:nil]; 346| 0|} 347| | 348| |+ (NSString *)SHA256Hash:(NSObject *)input 349| 0|{ 350| 0| NSData *data = nil; 351| | 352| 0| if ([input isKindOfClass:[NSData class]]) { 353| 0| data = (NSData *)input; 354| 0| } else if ([input isKindOfClass:[NSString class]]) { 355| 0| data = [(NSString *)input dataUsingEncoding:NSUTF8StringEncoding]; 356| 0| } 357| | 358| 0| if (!data) { 359| 0| return nil; 360| 0| } 361| | 362| 0| uint8_t digest[CC_SHA256_DIGEST_LENGTH]; 363| 0| CC_SHA256(data.bytes, (CC_LONG)data.length, digest); 364| 0| NSMutableString *hashed = [NSMutableString stringWithCapacity:CC_SHA256_DIGEST_LENGTH * 2]; 365| 0| for (int i = 0; i < CC_SHA256_DIGEST_LENGTH; i++) { 366| 0| [hashed appendFormat:@"%02x", digest[i]]; 367| 0| } 368| | 369| 0| return [hashed copy]; 370| 0|} 371| | 372| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKCrashHandler.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKCrashHandler.h" 20| | 21| |#import 22| | 23| |#import 24| | 25| |#import "FBSDKCrashObserving.h" 26| |#import "FBSDKFileDataExtracting.h" 27| |#import "FBSDKFileManaging.h" 28| |#import "FBSDKLibAnalyzer.h" 29| |#import "FBSDKTypeUtility.h" 30| |#import "NSBundle+InfoDictionaryProviding.h" 31| | 32| |#define FBSDK_MAX_CRASH_LOGS 5 33| 0|#define FBSDK_CRASH_PATH_NAME @"instrument" 34| |#ifndef FBSDK_VERSION_STRING 35| 0| #define FBSDK_VERSION_STRING @"11.0.1" 36| |#endif 37| | 38| |static NSUncaughtExceptionHandler *previousExceptionHandler = NULL; 39| |static NSString *mappingTableIdentifier = NULL; 40| |static NSString *directoryPath; 41| | 42| |NSString *const kFBSDKAppVersion = @"app_version"; 43| |NSString *const kFBSDKCallstack = @"callstack"; 44| |NSString *const kFBSDKCrashReason = @"reason"; 45| |NSString *const kFBSDKCrashTimestamp = @"timestamp"; 46| |NSString *const kFBSDKDeviceModel = @"device_model"; 47| |NSString *const kFBSDKDeviceOSVersion = @"device_os_version"; 48| | 49| |NSString *const kFBSDKMapingTable = @"mapping_table"; 50| |NSString *const kFBSDKMappingTableIdentifier = @"mapping_table_identifier"; 51| | 52| |@interface FBSDKCrashHandler () 53| | 54| |@property (nonatomic) BOOL isTurnedOn; 55| |@property (nonatomic) id fileManager; 56| |@property (nonatomic, strong) Class dataExtractor; 57| |@property (nonatomic) id bundle; 58| |@property (nonatomic) NSHashTable> *observers; 59| |@property (nonatomic) NSArray *> *processedCrashLogs; 60| | 61| |@end 62| | 63| |@implementation FBSDKCrashHandler 64| | 65| |- (instancetype)init 66| 0|{ 67| 0| return [self initWithFileManager:NSFileManager.defaultManager 68| 0| bundle:NSBundle.mainBundle 69| 0| fileDataExtractor:NSData.class 70| 0| ]; 71| 0|} 72| | 73| |- (instancetype)initWithFileManager:(id)fileManager 74| | bundle:(id)bundle 75| | fileDataExtractor:(nonnull Class)dataExtractor 76| 0|{ 77| 0| if ((self = [super init])) { 78| 0| _observers = [NSHashTable new]; 79| 0| _isTurnedOn = YES; 80| 0| _fileManager = fileManager; 81| 0| _bundle = bundle; 82| 0| _dataExtractor = dataExtractor; 83| | 84| 0| NSString *dirPath = [NSTemporaryDirectory() stringByAppendingPathComponent:FBSDK_CRASH_PATH_NAME]; 85| 0| if (![_fileManager fileExistsAtPath:dirPath]) { 86| 0| [_fileManager createDirectoryAtPath:dirPath withIntermediateDirectories:NO attributes:NULL error:NULL]; 87| 0| } 88| 0| directoryPath = dirPath; 89| 0| NSString *identifier = [[NSUUID UUID] UUIDString]; 90| 0| mappingTableIdentifier = [identifier stringByReplacingOccurrencesOfString:@"-" withString:@""]; 91| 0| } 92| 0| return self; 93| 0|} 94| | 95| |+ (instancetype)shared 96| 0|{ 97| 0| static dispatch_once_t nonce; 98| 0| static id instance; 99| 0| dispatch_once(&nonce, ^{ 100| 0| instance = [self new]; 101| 0| }); 102| 0| return instance; 103| 0|} 104| | 105| |#pragma mark - Public API 106| | 107| |+ (NSString *)getFBSDKVersion 108| 0|{ 109| 0| return FBSDK_VERSION_STRING; 110| 0|} 111| | 112| |+ (void)disable 113| 0|{ 114| 0| [FBSDKCrashHandler.shared disable]; 115| 0|} 116| | 117| |- (void)disable 118| 0|{ 119| 0| self.isTurnedOn = NO; 120| 0| [FBSDKCrashHandler.shared _uninstallExceptionsHandler]; 121| 0| self.observers = nil; 122| 0|} 123| | 124| |+ (void)addObserver:(id)observer 125| 0|{ 126| 0| [FBSDKCrashHandler.shared addObserver:observer]; 127| 0|} 128| | 129| |- (void)addObserver:(id)observer 130| 0|{ 131| 0| if (!self.isTurnedOn || ![self _isSafeToGenerateMapping]) { 132| 0| return; 133| 0| } 134| 0| static dispatch_once_t onceToken; 135| 0| dispatch_once(&onceToken, ^{ 136| 0| [FBSDKCrashHandler.shared _installExceptionsHandler]; 137| 0| _processedCrashLogs = [self _getProcessedCrashLogs]; 138| 0| }); 139| 0| @synchronized(_observers) { 140| 0| if (![self.observers containsObject:observer]) { 141| 0| [self.observers addObject:observer]; 142| 0| dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_BACKGROUND, 0), ^(void) { 143| 0| [self _generateMethodMapping:observer]; 144| 0| }); 145| 0| [self _sendCrashLogs]; 146| 0| } 147| 0| } 148| 0|} 149| | 150| |+ (void)removeObserver:(id)observer 151| 0|{ 152| 0| [FBSDKCrashHandler.shared removeObserver:observer]; 153| 0|} 154| | 155| |- (void)removeObserver:(id)observer 156| 0|{ 157| 0| @synchronized(_observers) { 158| 0| if ([self.observers containsObject:observer]) { 159| 0| [self.observers removeObject:observer]; 160| 0| if (self.observers.count == 0) { 161| 0| [FBSDKCrashHandler.shared _uninstallExceptionsHandler]; 162| 0| } 163| 0| } 164| 0| } 165| 0|} 166| | 167| |+ (void)clearCrashReportFiles 168| 0|{ 169| 0| [FBSDKCrashHandler.shared clearCrashReportFiles]; 170| 0|} 171| | 172| |- (void)clearCrashReportFiles 173| 0|{ 174| 0| NSArray *files = [self.fileManager contentsOfDirectoryAtPath:directoryPath error:nil]; 175| | 176| 0| for (NSUInteger i = 0; i < files.count; i++) { 177| | // remove all crash related files except for the current mapping table 178| 0| if ([[FBSDKTypeUtility array:files objectAtIndex:i] hasPrefix:@"crash_"] && ![[FBSDKTypeUtility array:files objectAtIndex:i] containsString:mappingTableIdentifier]) { 179| 0| [self.fileManager removeItemAtPath:[directoryPath stringByAppendingPathComponent:[FBSDKTypeUtility array:files objectAtIndex:i]] error:nil]; 180| 0| } 181| 0| } 182| 0|} 183| | 184| |# pragma mark - Handler 185| | 186| |+ (void)_installExceptionsHandler 187| 0|{ 188| 0| [FBSDKCrashHandler.shared _installExceptionsHandler]; 189| 0|} 190| | 191| |- (void)_installExceptionsHandler 192| 0|{ 193| 0| NSUncaughtExceptionHandler *currentHandler = NSGetUncaughtExceptionHandler(); 194| | 195| 0| if (currentHandler != FBSDKExceptionHandler) { 196| 0| previousExceptionHandler = currentHandler; 197| 0| NSSetUncaughtExceptionHandler(&FBSDKExceptionHandler); 198| 0| } 199| 0|} 200| | 201| |+ (void)_uninstallExceptionsHandler 202| 0|{ 203| 0| [FBSDKCrashHandler.shared _uninstallExceptionsHandler]; 204| 0|} 205| | 206| |- (void)_uninstallExceptionsHandler 207| 0|{ 208| 0| NSSetUncaughtExceptionHandler(previousExceptionHandler); 209| 0| previousExceptionHandler = nil; 210| 0|} 211| | 212| |static void FBSDKExceptionHandler(NSException *exception) 213| 0|{ 214| 0| [FBSDKCrashHandler.shared _saveException:exception]; 215| 0| if (previousExceptionHandler) { 216| 0| previousExceptionHandler(exception); 217| 0| } 218| 0|} 219| | 220| |#pragma mark - Storage & Process 221| | 222| |+ (void)_saveException:(NSException *)exception 223| 0|{ 224| 0| [FBSDKCrashHandler.shared _saveException:exception]; 225| 0|} 226| | 227| |- (void)_saveException:(NSException *)exception 228| 0|{ 229| 0| if (exception.callStackSymbols && exception.name) { 230| 0| NSArray *stackSymbols = [NSArray arrayWithArray:exception.callStackSymbols]; 231| 0| [self _saveCrashLog:@{ 232| 0| kFBSDKCallstack : stackSymbols, 233| 0| kFBSDKCrashReason : exception.name, 234| 0| }]; 235| 0| } 236| 0|} 237| | 238| |+ (NSArray *> *)_getProcessedCrashLogs 239| 0|{ 240| 0| return [FBSDKCrashHandler.shared _getProcessedCrashLogs]; 241| 0|} 242| | 243| |- (NSArray *> *)_getProcessedCrashLogs 244| 0|{ 245| 0| NSArray *> *crashLogs = [self _loadCrashLogs]; 246| 0| if (0 == crashLogs.count) { 247| 0| [self clearCrashReportFiles]; 248| 0| return nil; 249| 0| } 250| 0| NSMutableArray *> *processedCrashLogs = [NSMutableArray array]; 251| | 252| 0| for (NSDictionary *crashLog in crashLogs) { 253| 0| NSArray *callstack = crashLog[kFBSDKCallstack]; 254| 0| NSData *data = [self _loadLibData:crashLog]; 255| 0| if (!data) { 256| 0| continue; 257| 0| } 258| 0| NSDictionary *methodMapping = [FBSDKTypeUtility JSONObjectWithData:data 259| 0| options:kNilOptions 260| 0| error:nil]; 261| 0| NSArray *symbolicatedCallstack = [FBSDKLibAnalyzer symbolicateCallstack:callstack methodMapping:methodMapping]; 262| 0| NSMutableDictionary *symbolicatedCrashLog = [NSMutableDictionary dictionaryWithDictionary:crashLog]; 263| 0| if (symbolicatedCallstack) { 264| 0| [FBSDKTypeUtility dictionary:symbolicatedCrashLog setObject:symbolicatedCallstack forKey:kFBSDKCallstack]; 265| 0| [symbolicatedCrashLog removeObjectForKey:kFBSDKMappingTableIdentifier]; 266| 0| [FBSDKTypeUtility array:processedCrashLogs addObject:symbolicatedCrashLog]; 267| 0| } 268| 0| } 269| 0| return processedCrashLogs; 270| 0|} 271| | 272| |+ (NSArray *> *)_loadCrashLogs 273| 0|{ 274| 0| return [FBSDKCrashHandler.shared _loadCrashLogs]; 275| 0|} 276| | 277| |- (NSArray *> *)_loadCrashLogs 278| 0|{ 279| 0| NSArray *files = [self.fileManager contentsOfDirectoryAtPath:directoryPath error:NULL]; 280| 0| NSArray *fileNames = [[self _getCrashLogFileNames:files] sortedArrayUsingComparator:^NSComparisonResult (id _Nonnull obj1, id _Nonnull obj2) { 281| 0| return [obj2 compare:obj1]; 282| 0| }]; 283| 0| NSMutableArray *> *crashLogArray = [NSMutableArray array]; 284| | 285| 0| for (NSUInteger i = 0; i < MIN(fileNames.count, FBSDK_MAX_CRASH_LOGS); i++) { 286| 0| NSData *data = [self _loadCrashLog:[FBSDKTypeUtility array:fileNames objectAtIndex:i]]; 287| 0| if (!data) { 288| 0| continue; 289| 0| } 290| 0| NSDictionary *crashLog = [FBSDKTypeUtility JSONObjectWithData:data 291| 0| options:kNilOptions 292| 0| error:nil]; 293| 0| if (crashLog) { 294| 0| [FBSDKTypeUtility array:crashLogArray addObject:crashLog]; 295| 0| } 296| 0| } 297| 0| return [crashLogArray copy]; 298| 0|} 299| | 300| |+ (nullable NSData *)_loadCrashLog:(NSString *)fileName 301| 0|{ 302| 0| return [FBSDKCrashHandler.shared _loadCrashLog:fileName]; 303| 0|} 304| | 305| |- (nullable NSData *)_loadCrashLog:(NSString *)fileName 306| 0|{ 307| 0| return [self.dataExtractor dataWithContentsOfFile:[directoryPath stringByAppendingPathComponent:fileName] options:NSDataReadingMappedIfSafe error:nil]; 308| 0|} 309| | 310| |+ (NSArray *)_getCrashLogFileNames:(NSArray *)files 311| 0|{ 312| 0| return [FBSDKCrashHandler.shared _getCrashLogFileNames:files]; 313| 0|} 314| | 315| |- (NSArray *)_getCrashLogFileNames:(NSArray *)files 316| 0|{ 317| 0| NSMutableArray *fileNames = [NSMutableArray array]; 318| | 319| 0| for (NSString *fileName in files) { 320| 0| if ([fileName hasPrefix:@"crash_log_"] && [fileName hasSuffix:@".json"]) { 321| 0| [FBSDKTypeUtility array:fileNames addObject:fileName]; 322| 0| } 323| 0| } 324| | 325| 0| return fileNames; 326| 0|} 327| | 328| |+ (void)_saveCrashLog:(NSDictionary *)crashLog 329| 0|{ 330| 0| [FBSDKCrashHandler.shared _saveCrashLog:crashLog]; 331| 0|} 332| | 333| |- (void)_saveCrashLog:(NSDictionary *)crashLog 334| 0|{ 335| 0| NSMutableDictionary *completeCrashLog = [NSMutableDictionary dictionaryWithDictionary:crashLog]; 336| 0| NSString *currentTimestamp = [NSString stringWithFormat:@"%.0lf", [[NSDate date] timeIntervalSince1970]]; 337| | 338| 0| [FBSDKTypeUtility dictionary:completeCrashLog setObject:currentTimestamp forKey:kFBSDKCrashTimestamp]; 339| 0| [FBSDKTypeUtility dictionary:completeCrashLog setObject:mappingTableIdentifier forKey:kFBSDKMappingTableIdentifier]; 340| | 341| 0| NSString *version = [self.bundle objectForInfoDictionaryKey:@"CFBundleShortVersionString"]; 342| 0| NSString *build = [self.bundle objectForInfoDictionaryKey:@"CFBundleVersion"]; 343| 0| [FBSDKTypeUtility dictionary:completeCrashLog setObject:[NSString stringWithFormat:@"%@(%@)", version, build] forKey:kFBSDKAppVersion]; 344| | 345| 0| struct utsname systemInfo; 346| 0| uname(&systemInfo); 347| 0| [FBSDKTypeUtility dictionary:completeCrashLog setObject:@(systemInfo.machine) forKey:kFBSDKDeviceModel]; 348| | 349| 0| [FBSDKTypeUtility dictionary:completeCrashLog setObject:[UIDevice currentDevice].systemVersion forKey:kFBSDKDeviceOSVersion]; 350| | 351| 0| NSData *data = [FBSDKTypeUtility dataWithJSONObject:completeCrashLog options:0 error:nil]; 352| | 353| 0| [data writeToFile:[self _getPathToCrashFile:currentTimestamp] 354| 0| atomically:YES]; 355| 0|} 356| | 357| |+ (void)_sendCrashLogs 358| 0|{ 359| 0| [FBSDKCrashHandler.shared _sendCrashLogs]; 360| 0|} 361| | 362| |- (void)_sendCrashLogs 363| 0|{ 364| 0| for (id observer in _observers) { 365| 0| if (observer) { 366| 0| NSArray *> *filteredCrashLogs = [self _filterCrashLogs:observer.prefixes processedCrashLogs:_processedCrashLogs]; 367| 0| [observer didReceiveCrashLogs:filteredCrashLogs]; 368| 0| } 369| 0| } 370| 0|} 371| | 372| |+ (NSArray *> *)_filterCrashLogs:(NSArray *)prefixList 373| | processedCrashLogs:(NSArray *> *)processedCrashLogs 374| 0|{ 375| 0| return [FBSDKCrashHandler.shared _filterCrashLogs:prefixList processedCrashLogs:processedCrashLogs]; 376| 0|} 377| | 378| |- (NSArray *> *)_filterCrashLogs:(NSArray *)prefixList 379| | processedCrashLogs:(NSArray *> *)processedCrashLogs 380| 0|{ 381| 0| NSMutableArray *> *crashLogs = [NSMutableArray array]; 382| 0| for (NSDictionary *crashLog in processedCrashLogs) { 383| 0| NSArray *callstack = crashLog[kFBSDKCallstack]; 384| 0| if ([self _callstack:callstack containsPrefix:prefixList]) { 385| 0| [FBSDKTypeUtility array:crashLogs addObject:crashLog]; 386| 0| } 387| 0| } 388| 0| return crashLogs; 389| 0|} 390| | 391| |+ (BOOL)_callstack:(NSArray *)callstack 392| | containsPrefix:(NSArray *)prefixList 393| 0|{ 394| 0| return [FBSDKCrashHandler.shared _callstack:callstack containsPrefix:prefixList]; 395| 0|} 396| | 397| |- (BOOL)_callstack:(NSArray *)callstack 398| | containsPrefix:(NSArray *)prefixList 399| 0|{ 400| 0| NSString *callStackString = [callstack componentsJoinedByString:@""]; 401| 0| for (NSString *prefix in prefixList) { 402| 0| if ([callStackString containsString:prefix]) { 403| 0| return YES; 404| 0| } 405| 0| } 406| 0| return NO; 407| 0|} 408| | 409| |#pragma mark - Method Mapping 410| | 411| |+ (void)_generateMethodMapping:(id)observer 412| 0|{ 413| 0| [FBSDKCrashHandler.shared _generateMethodMapping:observer]; 414| 0|} 415| | 416| |- (void)_generateMethodMapping:(id)observer 417| 0|{ 418| 0| if (observer.prefixes.count == 0) { 419| 0| return; 420| 0| } 421| 0| [[NSUserDefaults standardUserDefaults] setObject:mappingTableIdentifier forKey:kFBSDKMappingTableIdentifier]; 422| 0| NSDictionary *methodMapping = [FBSDKLibAnalyzer getMethodsTable:observer.prefixes 423| 0| frameworks:observer.frameworks]; 424| 0| if (methodMapping.count > 0) { 425| 0| NSData *data = [FBSDKTypeUtility dataWithJSONObject:methodMapping options:0 error:nil]; 426| 0| [data writeToFile:[self _getPathToLibDataFile:mappingTableIdentifier] 427| 0| atomically:YES]; 428| 0| } 429| 0|} 430| | 431| |+ (nullable NSData *)_loadLibData:(NSDictionary *)crashLog 432| 0|{ 433| 0| return [FBSDKCrashHandler.shared _loadLibData:crashLog]; 434| 0|} 435| | 436| |- (nullable NSData *)_loadLibData:(NSDictionary *)crashLog 437| 0|{ 438| 0| NSString *identifier = [FBSDKTypeUtility dictionary:crashLog objectForKey:kFBSDKMappingTableIdentifier ofType:NSObject.class]; 439| 0| return [self.dataExtractor dataWithContentsOfFile:[self _getPathToLibDataFile:identifier] options:NSDataReadingMappedIfSafe error:nil]; 440| 0|} 441| | 442| |+ (NSString *)_getPathToCrashFile:(NSString *)timestamp 443| 0|{ 444| 0| return [FBSDKCrashHandler.shared _getPathToCrashFile:timestamp]; 445| 0|} 446| | 447| |- (NSString *)_getPathToCrashFile:(NSString *)timestamp 448| 0|{ 449| 0| return [directoryPath stringByAppendingPathComponent: 450| 0| [NSString stringWithFormat:@"crash_log_%@.json", timestamp]]; 451| 0|} 452| | 453| |+ (NSString *)_getPathToLibDataFile:(NSString *)identifier 454| 0|{ 455| 0| return [FBSDKCrashHandler.shared _getPathToLibDataFile:identifier]; 456| 0|} 457| | 458| |- (NSString *)_getPathToLibDataFile:(NSString *)identifier 459| 0|{ 460| 0| return [directoryPath stringByAppendingPathComponent: 461| 0| [NSString stringWithFormat:@"crash_lib_data_%@.json", identifier]]; 462| 0|} 463| | 464| |+ (BOOL)_isSafeToGenerateMapping 465| 0|{ 466| 0| return [FBSDKCrashHandler.shared _isSafeToGenerateMapping]; 467| 0|} 468| | 469| |- (BOOL)_isSafeToGenerateMapping 470| 0|{ 471| 0|#if TARGET_OS_SIMULATOR 472| 0| return YES; 473| |#else 474| | NSString *identifier = [[NSUserDefaults standardUserDefaults] objectForKey:kFBSDKMappingTableIdentifier]; 475| | // first app start 476| | if (!identifier) { 477| | return YES; 478| | } 479| | 480| | return [self.fileManager fileExistsAtPath:[self _getPathToLibDataFile:identifier]]; 481| |#endif 482| 0|} 483| | 484| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKLibAnalyzer.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKLibAnalyzer.h" 20| | 21| |#import 22| | 23| |#import "FBSDKTypeUtility.h" 24| | 25| |@implementation FBSDKLibAnalyzer 26| | 27| |static NSMutableDictionary *_methodMapping; 28| | 29| |+ (void)initialize 30| 0|{ 31| 0| _methodMapping = [NSMutableDictionary dictionary]; 32| 0|} 33| | 34| |+ (NSDictionary *)getMethodsTable:(NSArray *)prefixes 35| | frameworks:(NSArray *)frameworks 36| 0|{ 37| 0| NSArray *allClasses = [self _getClassNames:prefixes frameworks:frameworks]; 38| 0| for (NSString *className in allClasses) { 39| 0| Class class = NSClassFromString(className); 40| 0| if (class) { 41| 0| [self _addClass:class isClassMethod:NO]; 42| 0| [self _addClass:object_getClass(class) isClassMethod:YES]; 43| 0| } 44| 0| } 45| 0| @synchronized(_methodMapping) { 46| 0| return [_methodMapping copy]; 47| 0| } 48| 0|} 49| | 50| |+ (nullable NSArray *)symbolicateCallstack:(NSArray *)callstack 51| | methodMapping:(NSDictionary *)methodMapping 52| 0|{ 53| 0| if (!callstack || !methodMapping) { 54| 0| return nil; 55| 0| } 56| 0| NSArray *sortedAllAddress = [methodMapping.allKeys sortedArrayUsingComparator:^NSComparisonResult (id _Nonnull obj1, id _Nonnull obj2) { 57| 0| return [obj1 compare:obj2]; 58| 0| }]; 59| | 60| 0| BOOL containsFBSDKFunction = NO; 61| 0| NSInteger nonSDKMethodCount = 0; 62| 0| NSMutableArray *symbolicatedCallstack = [NSMutableArray array]; 63| | 64| 0| for (NSUInteger i = 0; i < callstack.count; i++) { 65| 0| NSString *rawAddress = [self _getAddress:[FBSDKTypeUtility array:callstack objectAtIndex:i]]; 66| 0| if (rawAddress.length < 10) { 67| 0| continue; 68| 0| } 69| 0| NSString *addressString = [NSString stringWithFormat:@"0x%@", [rawAddress substringWithRange:NSMakeRange(rawAddress.length - 10, 10)]]; 70| 0| NSString *methodAddress = [self _searchMethod:addressString sortedAllAddress:sortedAllAddress]; 71| | 72| 0| if (methodAddress) { 73| 0| containsFBSDKFunction = YES; 74| 0| nonSDKMethodCount == 0 ?: [FBSDKTypeUtility array:symbolicatedCallstack addObject:[NSString stringWithFormat:@"(%ld DEV METHODS)", (long)nonSDKMethodCount]]; 75| 0| nonSDKMethodCount = 0; 76| 0| NSString *methodName = [FBSDKTypeUtility dictionary:methodMapping objectForKey:methodAddress ofType:NSObject.class]; 77| | 78| | // filter out cxx_destruct 79| 0| if ([methodName containsString:@".cxx_destruct"]) { 80| 0| return nil; 81| 0| } 82| 0| [FBSDKTypeUtility array:symbolicatedCallstack addObject:[NSString stringWithFormat:@"%@%@", methodName, [self _getOffset:addressString secondString:methodAddress]]]; 83| 0| } else { 84| 0| nonSDKMethodCount++; 85| 0| } 86| 0| } 87| 0| nonSDKMethodCount == 0 ?: [FBSDKTypeUtility array:symbolicatedCallstack addObject:[NSString stringWithFormat:@"(%ld DEV METHODS)", (long)nonSDKMethodCount]]; 88| | 89| 0| return containsFBSDKFunction ? symbolicatedCallstack : nil; 90| 0|} 91| | 92| |#pragma mark - Private Methods 93| | 94| |+ (NSArray *)_getClassNames:(NSArray *)prefixes 95| | frameworks:(NSArray *)frameworks 96| 0|{ 97| 0| NSMutableArray *classNames = [NSMutableArray new]; 98| | // from main bundle 99| 0| [classNames addObjectsFromArray:[self _getClassesFrom:[[NSBundle mainBundle] executablePath] 100| 0| prefixes:prefixes]]; 101| | // from dynamic libraries 102| 0| if (frameworks.count > 0) { 103| 0| unsigned int count = 0; 104| 0| const char **images = objc_copyImageNames(&count); 105| 0| for (int i = 0; i < count; i++) { 106| 0| NSString *image = [NSString stringWithUTF8String:images[i]]; 107| 0| for (NSString *framework in frameworks) { 108| 0| if ([image containsString:framework]) { 109| 0| [classNames addObjectsFromArray:[self _getClassesFrom:image 110| 0| prefixes:nil]]; 111| 0| } 112| 0| } 113| 0| } 114| 0| free(images); 115| 0| } 116| | 117| 0| return [classNames copy]; 118| 0|} 119| | 120| |+ (NSArray *)_getClassesFrom:(NSString *)image 121| | prefixes:(NSArray *)prefixes 122| 0|{ 123| 0| NSMutableArray *classNames = [NSMutableArray array]; 124| 0| unsigned int count = 0; 125| 0| const char **classes = objc_copyClassNamesForImage([image UTF8String], &count); 126| 0| for (unsigned int i = 0; i < count; i++) { 127| 0| NSString *className = [NSString stringWithUTF8String:classes[i]]; 128| 0| if (prefixes.count > 0) { 129| 0| for (NSString *prefix in prefixes) { 130| 0| if ([className hasPrefix:prefix]) { 131| 0| [FBSDKTypeUtility array:classNames addObject:className]; 132| 0| break; 133| 0| } 134| 0| } 135| 0| } else { 136| 0| [FBSDKTypeUtility array:classNames addObject:className]; 137| 0| } 138| 0| } 139| 0| free(classes); 140| 0| return [classNames copy]; 141| 0|} 142| | 143| |+ (void)_addClass:(Class)class 144| | isClassMethod:(BOOL)isClassMethod 145| 0|{ 146| 0| unsigned int methodsCount = 0; 147| 0| Method *methods = class_copyMethodList(class, &methodsCount); 148| | 149| 0| NSString *methodType = isClassMethod ? @"+" : @"-"; 150| | 151| 0| for (unsigned int i = 0; i < methodsCount; i++) { 152| 0| Method method = methods[i]; 153| | 154| 0| if (method) { 155| 0| SEL selector = method_getName(method); 156| | 157| 0| IMP methodImplementation = class_getMethodImplementation(class, selector); 158| 0| NSString *methodAddress = [NSString stringWithFormat:@"0x%010lx", (unsigned long)methodImplementation]; 159| 0| NSString *methodName = [NSString stringWithFormat:@"%@[%@ %@]", 160| 0| methodType, 161| 0| NSStringFromClass(class), 162| 0| NSStringFromSelector(selector)]; 163| | 164| 0| if (methodAddress && methodName) { 165| 0| @synchronized(_methodMapping) { 166| 0| [FBSDKTypeUtility dictionary:_methodMapping setObject:methodName forKey:methodAddress]; 167| 0| } 168| 0| } 169| 0| } 170| 0| } 171| 0| free(methods); 172| 0|} 173| | 174| |+ (nullable NSString *)_getAddress:(nullable NSString *)callstackEntry 175| 0|{ 176| 0| if ([callstackEntry isKindOfClass:[NSString class]]) { 177| 0| NSArray *components = [callstackEntry componentsSeparatedByString:@" "]; 178| 0| for (NSString *component in components) { 179| 0| if ([component containsString:@"0x"]) { 180| 0| return component; 181| 0| } 182| 0| } 183| 0| } 184| 0| return nil; 185| 0|} 186| | 187| |+ (NSString *)_getOffset:(NSString *)firstString 188| | secondString:(NSString *)secondString 189| 0|{ 190| 0| unsigned long long first = 0, second = 0; 191| 0| NSScanner *scanner = [NSScanner scannerWithString:firstString]; 192| 0| [scanner scanHexLongLong:&first]; 193| | 194| 0| scanner = [NSScanner scannerWithString:secondString]; 195| 0| [scanner scanHexLongLong:&second]; 196| | 197| 0| unsigned long long difference = first - second; 198| 0| return [NSString stringWithFormat:@"+%llu", difference]; 199| 0|} 200| | 201| |+ (nullable NSString *)_searchMethod:(NSString *)address 202| | sortedAllAddress:(NSArray *)sortedAllAddress 203| 0|{ 204| 0| if (0 == sortedAllAddress.count) { 205| 0| return nil; 206| 0| } 207| 0| NSString *lowestAddress = [FBSDKTypeUtility array:sortedAllAddress objectAtIndex:0]; 208| 0| NSString *highestAddress = [FBSDKTypeUtility array:sortedAllAddress objectAtIndex:sortedAllAddress.count - 1]; 209| | 210| 0| if ([address compare:lowestAddress] == NSOrderedAscending || [address compare:highestAddress] == NSOrderedDescending) { 211| 0| return nil; 212| 0| } 213| | 214| 0| if ([address compare:lowestAddress] == NSOrderedSame) { 215| 0| return lowestAddress; 216| 0| } 217| | 218| 0| if ([address compare:highestAddress] == NSOrderedSame) { 219| 0| return highestAddress; 220| 0| } 221| | 222| 0| NSUInteger index = [sortedAllAddress indexOfObject:address 223| 0| inSortedRange:NSMakeRange(0, sortedAllAddress.count - 1) 224| 0| options:NSBinarySearchingInsertionIndex 225| 0| usingComparator:^NSComparisonResult (id _Nonnull obj1, id _Nonnull obj2) { 226| 0| return [obj1 compare:obj2]; 227| 0| }]; 228| 0| return [FBSDKTypeUtility array:sortedAllAddress objectAtIndex:index - 1]; 229| 0|} 230| | 231| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKSafeCast.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKSafeCast.h" 20| | 21| |id _FBSDKCastToClassOrNilUnsafeInternal(id object, Class klass) 22| 0|{ 23| 0| return [(NSObject *)object isKindOfClass:klass] ? object : nil; 24| 0|} 25| | 26| |id _FBSDKCastToProtocolOrNilUnsafeInternal(id object, Protocol *protocol) 27| 0|{ 28| 0| return [(NSObject *)object conformsToProtocol:protocol] ? object : nil; 29| 0|} /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKTypeUtility.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKTypeUtility.h" 20| | 21| |@implementation FBSDKTypeUtility 22| | 23| |#pragma mark - Class Methods 24| | 25| |+ (NSArray *)arrayValue:(id)object 26| 0|{ 27| 0| return (NSArray *)[self _objectValue:object ofClass:[NSArray class]]; 28| 0|} 29| | 30| |+ (nullable id)array:(NSArray *)array objectAtIndex:(NSUInteger)index 31| 0|{ 32| 0| if ([self arrayValue:array] && index < array.count) { 33| 0| return [array objectAtIndex:index]; 34| 0| } 35| | 36| 0| return nil; 37| 0|} 38| | 39| |+ (void)array:(NSMutableArray *)array addObject:(id)object 40| 0|{ 41| 0| if (object && [array isKindOfClass:NSMutableArray.class]) { 42| 0| [array addObject:object]; 43| 0| } 44| 0|} 45| | 46| |+ (void)array:(NSMutableArray *)array addObject:(nullable id)object atIndex:(NSUInteger)index 47| 0|{ 48| 0| if (object && [array isKindOfClass:NSMutableArray.class]) { 49| 0| if (index < array.count) { 50| 0| [array insertObject:object atIndex:index]; 51| 0| } else if (index == array.count) { 52| 0| [array addObject:object]; 53| 0| } 54| 0| } 55| 0|} 56| | 57| |+ (BOOL)boolValue:(id)object 58| 0|{ 59| 0| if ([object isKindOfClass:[NSNumber class]]) { 60| | // @0 or @NO returns NO, otherwise YES 61| 0| return ((NSNumber *)object).boolValue; 62| 0| } else if ([object isKindOfClass:[NSString class]]) { 63| | // Returns YES on encountering one of "Y", "y", "T", "t", or a digit 1-9, otherwise NO 64| 0| return ((NSString *)object).boolValue; 65| 0| } else { 66| 0| return ([self objectValue:object] != nil); 67| 0| } 68| 0|} 69| | 70| |+ (NSDictionary *)dictionaryValue:(id)object 71| 0|{ 72| 0| return (NSDictionary *)[self _objectValue:object ofClass:[NSDictionary class]]; 73| 0|} 74| | 75| |+ (id)dictionary:(NSDictionary *)dictionary objectForKey:(NSString *)key ofType:(Class)type 76| 0|{ 77| 0| id potentialValue = [[self dictionaryValue:dictionary] objectForKey:key]; 78| | 79| 0| if ([potentialValue isKindOfClass:type]) { 80| 0| return potentialValue; 81| 0| } else { 82| 0| return nil; 83| 0| } 84| 0|} 85| | 86| |+ (void)dictionary:(NSMutableDictionary *)dictionary setObject:(id)object forKey:(id)key 87| 0|{ 88| 0| if (object && key) { 89| 0| dictionary[key] = object; 90| 0| } 91| 0|} 92| | 93| |+ (void)dictionary:(NSDictionary *)dictionary enumerateKeysAndObjectsUsingBlock:(void(NS_NOESCAPE ^)(id key, id obj, BOOL *stop))block 94| 0|{ 95| 0| NSDictionary *validDictionary = [self dictionaryValue:dictionary]; 96| 0| if (validDictionary) { 97| 0| [validDictionary enumerateKeysAndObjectsUsingBlock:block]; 98| 0| } 99| 0|} 100| | 101| |+ (NSNumber *)numberValue:(id)object 102| 0|{ 103| 0| return [self _objectValue:object ofClass:NSNumber.class]; 104| 0|} 105| | 106| |+ (NSInteger)integerValue:(id)object 107| 0|{ 108| 0| if ([object isKindOfClass:[NSNumber class]]) { 109| 0| return ((NSNumber *)object).integerValue; 110| 0| } else if ([object isKindOfClass:[NSString class]]) { 111| 0| return ((NSString *)object).integerValue; 112| 0| } else { 113| 0| return 0; 114| 0| } 115| 0|} 116| | 117| |+ (NSString *)stringValueOrNil:(id)object 118| 0|{ 119| 0| return [self _objectValue:object ofClass:NSString.class]; 120| 0|} 121| | 122| |+ (id)objectValue:(id)object 123| 0|{ 124| 0| return ([object isKindOfClass:[NSNull class]] ? nil : object); 125| 0|} 126| | 127| |+ (NSString *)coercedToStringValue:(id)object 128| 0|{ 129| 0| if ([object isKindOfClass:[NSString class]]) { 130| 0| return (NSString *)object; 131| 0| } else if ([object isKindOfClass:[NSNumber class]]) { 132| 0| return ((NSNumber *)object).stringValue; 133| 0| } else if ([object isKindOfClass:[NSURL class]]) { 134| 0| return ((NSURL *)object).absoluteString; 135| 0| } else { 136| 0| return nil; 137| 0| } 138| 0|} 139| | 140| |+ (NSTimeInterval)timeIntervalValue:(id)object 141| 0|{ 142| 0| if ([object isKindOfClass:[NSNumber class]]) { 143| 0| return ((NSNumber *)object).doubleValue; 144| 0| } else if ([object isKindOfClass:[NSString class]]) { 145| 0| return ((NSString *)object).doubleValue; 146| 0| } else { 147| 0| return 0; 148| 0| } 149| 0|} 150| | 151| |+ (NSUInteger)unsignedIntegerValue:(id)object 152| 0|{ 153| 0| if ([object isKindOfClass:[NSNumber class]]) { 154| 0| return ((NSNumber *)object).unsignedIntegerValue; 155| 0| } else { 156| | // there is no direct support for strings containing unsigned values > NSIntegerMax - not worth writing ourselves 157| | // right now, so just cap unsigned values at NSIntegerMax until we have a need for larger 158| 0| NSInteger integerValue = [self integerValue:object]; 159| 0| if (integerValue < 0) { 160| 0| integerValue = 0; 161| 0| } 162| 0| return (NSUInteger)integerValue; 163| 0| } 164| 0|} 165| | 166| |+ (NSURL *)URLValue:(id)object 167| 0|{ 168| 0| if ([object isKindOfClass:[NSURL class]]) { 169| 0| return (NSURL *)object; 170| 0| } else if ([object isKindOfClass:[NSString class]]) { 171| 0| return [NSURL URLWithString:(NSString *)object]; 172| 0| } else { 173| 0| return nil; 174| 0| } 175| 0|} 176| | 177| |+ (BOOL)isValidJSONObject:(id)obj 178| 0|{ 179| 0| return [NSJSONSerialization isValidJSONObject:obj]; 180| 0|} 181| | 182| |+ (NSData *)dataWithJSONObject:(id)obj options:(NSJSONWritingOptions)opt error:(NSError *__autoreleasing _Nullable *)error 183| 0|{ 184| 0| NSData *data; 185| | 186| 0| @try { 187| 0| data = [NSJSONSerialization dataWithJSONObject:obj options:opt error:error]; 188| 0| } @catch (NSException *exception) { 189| 0| NSLog(@"FBSDKJSONSerialization - dataWithJSONObject:options:error failed: %@", exception.reason); 190| 0| } 191| 0| return data; 192| 0|} 193| | 194| |+ (id)JSONObjectWithData:(NSData *)data options:(NSJSONReadingOptions)opt error:(NSError *__autoreleasing _Nullable *)error 195| 0|{ 196| 0| if (![data isKindOfClass:NSData.class]) { 197| 0| return nil; 198| 0| } 199| | 200| 0| id object; 201| 0| @try { 202| 0| object = [NSJSONSerialization JSONObjectWithData:data options:opt error:error]; 203| 0| } @catch (NSException *exception) { 204| 0| NSLog(@"FBSDKJSONSerialization - JSONObjectWithData:options:error failed: %@", exception.reason); 205| 0| } 206| 0| return object; 207| 0|} 208| | 209| |#pragma mark - Helper Methods 210| | 211| |+ (id)_objectValue:(id)object ofClass:(Class)expectedClass 212| 0|{ 213| 0| return ([object isKindOfClass:expectedClass] ? object : nil); 214| 0|} 215| | 216| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKURLSession.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKURLSession.h" 20| | 21| |#import 22| | 23| |#import "FBSDKBasicUtility.h" 24| |#import "FBSDKURLSessionTask.h" 25| | 26| |// At some point this default conformance declaration needs to be moved out of 27| |// this class and treated like the dependency it is. 28| |@interface NSURLSession (SessionProviding) 29| |@end 30| | 31| |@implementation FBSDKURLSession 32| | 33| |- (instancetype)initWithDelegate:(id)delegate 34| | delegateQueue:(NSOperationQueue *)queue 35| 0|{ 36| 0| if ((self = [super init])) { 37| 0| self.delegate = delegate; 38| 0| self.delegateQueue = queue; 39| 0| } 40| 0| return self; 41| 0|} 42| | 43| |- (void)executeURLRequest:(NSURLRequest *)request 44| | completionHandler:(FBSDKURLSessionTaskBlock)handler 45| 0|{ 46| 0| if (!self.valid) { 47| 0| [self updateSessionWithBlock:^{ 48| 0| FBSDKURLSessionTask *task = [[FBSDKURLSessionTask alloc] initWithRequest:request fromSession:self.session completionHandler:handler]; 49| 0| [task start]; 50| 0| }]; 51| 0| } else { 52| 0| FBSDKURLSessionTask *task = [[FBSDKURLSessionTask alloc] initWithRequest:request fromSession:self.session completionHandler:handler]; 53| 0| [task start]; 54| 0| } 55| 0|} 56| | 57| |- (void)updateSessionWithBlock:(dispatch_block_t)block 58| 0|{ 59| 0| if (!self.valid) { 60| 0| self.session = [NSURLSession sessionWithConfiguration:[NSURLSessionConfiguration defaultSessionConfiguration] 61| 0| delegate:_delegate 62| 0| delegateQueue:_delegateQueue]; 63| 0| } 64| 0| block(); 65| 0|} 66| | 67| |- (void)invalidateAndCancel 68| 0|{ 69| 0| [self.session invalidateAndCancel]; 70| 0| self.session = nil; 71| 0|} 72| | 73| |- (BOOL)valid 74| 0|{ 75| 0| return self.session != nil; 76| 0|} 77| | 78| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKURLSessionTask.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKURLSessionTask.h" 20| | 21| |#import "FBSDKSessionProviding.h" 22| | 23| |@implementation FBSDKURLSessionTask 24| | 25| |- (instancetype)init 26| 0|{ 27| 0| if ((self = [super init])) { 28| 0| _requestStartDate = [NSDate date]; 29| 0| } 30| 0| return self; 31| 0|} 32| | 33| |- (instancetype)initWithRequest:(NSURLRequest *)request 34| | fromSession:(id)session 35| | completionHandler:(FBSDKURLSessionTaskBlock)handler 36| 0|{ 37| 0| if ((self = [self init])) { 38| 0| self.requestStartTime = (uint64_t)([self.requestStartDate timeIntervalSince1970] * 1000); 39| 0| self.task = [session dataTaskWithRequest:request completionHandler:handler]; 40| 0| } 41| 0| return self; 42| 0|} 43| | 44| |- (NSURLSessionTaskState)state 45| 0|{ 46| 0| return self.task.state; 47| 0|} 48| | 49| |#pragma mark - Task State 50| | 51| |- (void)start 52| 0|{ 53| 0| [self.task resume]; 54| 0|} 55| | 56| |- (void)cancel 57| 0|{ 58| 0| [self.task cancel]; 59| 0| self.handler = nil; 60| 0|} 61| | 62| |@end /Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKUserDataStore.m: 1| |// Copyright (c) 2014-present, Facebook, Inc. All rights reserved. 2| |// 3| |// You are hereby granted a non-exclusive, worldwide, royalty-free license to use, 4| |// copy, modify, and distribute this software in source code or binary form for use 5| |// in connection with the web services and APIs provided by Facebook. 6| |// 7| |// As with any software that integrates with the Facebook platform, your use of 8| |// this software is subject to the Facebook Developer Principles and Policies 9| |// [http://developers.facebook.com/policy/]. This copyright notice shall be 10| |// included in all copies or substantial portions of the software. 11| |// 12| |// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 13| |// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 14| |// FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 15| |// COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 16| |// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 17| |// CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 18| | 19| |#import "FBSDKUserDataStore.h" 20| | 21| |#import "FBSDKBasicUtility.h" 22| |#import "FBSDKTypeUtility.h" 23| | 24| |static NSString *const FBSDKUserDataKey = @"com.facebook.appevents.UserDataStore.userData"; 25| |static NSString *const FBSDKInternalUserDataKey = @"com.facebook.appevents.UserDataStore.internalUserData"; 26| | 27| |static NSMutableDictionary *hashedUserData; 28| |static NSMutableDictionary *internalHashedUserData; 29| |static NSMutableSet *enabledRules; 30| | 31| |static dispatch_queue_t serialQueue; 32| | 33| |// 34| |// Public event user data types 35| |// 36| | 37| |FBSDKAppEventUserDataType FBSDKAppEventEmail = @"em"; 38| |FBSDKAppEventUserDataType FBSDKAppEventFirstName = @"fn"; 39| |FBSDKAppEventUserDataType FBSDKAppEventLastName = @"ln"; 40| |FBSDKAppEventUserDataType FBSDKAppEventPhone = @"ph"; 41| |FBSDKAppEventUserDataType FBSDKAppEventDateOfBirth = @"dob"; 42| |FBSDKAppEventUserDataType FBSDKAppEventGender = @"ge"; 43| |FBSDKAppEventUserDataType FBSDKAppEventCity = @"ct"; 44| |FBSDKAppEventUserDataType FBSDKAppEventState = @"st"; 45| |FBSDKAppEventUserDataType FBSDKAppEventZip = @"zp"; 46| |FBSDKAppEventUserDataType FBSDKAppEventCountry = @"country"; 47| |FBSDKAppEventUserDataType FBSDKAppEventExternalId = @"external_id"; 48| | 49| |@implementation FBSDKUserDataStore 50| | 51| |+ (void)initialize 52| 0|{ 53| 0| serialQueue = dispatch_queue_create("com.facebook.appevents.UserDataStore", DISPATCH_QUEUE_SERIAL); 54| 0| hashedUserData = [FBSDKUserDataStore initializeUserData:FBSDKUserDataKey]; 55| 0| internalHashedUserData = [FBSDKUserDataStore initializeUserData:FBSDKInternalUserDataKey]; 56| 0| enabledRules = [NSMutableSet new]; 57| 0|} 58| | 59| |+ (void)setUserEmail:(nullable NSString *)email 60| | firstName:(nullable NSString *)firstName 61| | lastName:(nullable NSString *)lastName 62| | phone:(nullable NSString *)phone 63| | dateOfBirth:(nullable NSString *)dateOfBirth 64| | gender:(nullable NSString *)gender 65| | city:(nullable NSString *)city 66| | state:(nullable NSString *)state 67| | zip:(nullable NSString *)zip 68| | country:(nullable NSString *)country 69| | externalId:(nullable NSString *)externalId 70| 0|{ 71| 0| NSMutableDictionary *ud = [NSMutableDictionary new]; 72| 0| if (email) { 73| 0| [FBSDKTypeUtility dictionary:ud setObject:[FBSDKUserDataStore encryptData:email type:FBSDKAppEventEmail] forKey:FBSDKAppEventEmail]; 74| 0| } 75| 0| if (firstName) { 76| 0| [FBSDKTypeUtility dictionary:ud setObject:[FBSDKUserDataStore encryptData:firstName type:FBSDKAppEventFirstName] forKey:FBSDKAppEventFirstName]; 77| 0| } 78| 0| if (lastName) { 79| 0| [FBSDKTypeUtility dictionary:ud setObject:[FBSDKUserDataStore encryptData:lastName type:FBSDKAppEventLastName] forKey:FBSDKAppEventLastName]; 80| 0| } 81| 0| if (phone) { 82| 0| [FBSDKTypeUtility dictionary:ud setObject:[FBSDKUserDataStore encryptData:phone type:FBSDKAppEventPhone] forKey:FBSDKAppEventPhone]; 83| 0| } 84| 0| if (dateOfBirth) { 85| 0| [FBSDKTypeUtility dictionary:ud setObject:[FBSDKUserDataStore encryptData:dateOfBirth type:FBSDKAppEventDateOfBirth] forKey:FBSDKAppEventDateOfBirth]; 86| 0| } 87| 0| if (gender) { 88| 0| [FBSDKTypeUtility dictionary:ud setObject:[FBSDKUserDataStore encryptData:gender type:FBSDKAppEventGender] forKey:FBSDKAppEventGender]; 89| 0| } 90| 0| if (city) { 91| 0| [FBSDKTypeUtility dictionary:ud setObject:[FBSDKUserDataStore encryptData:city type:FBSDKAppEventCity] forKey:FBSDKAppEventCity]; 92| 0| } 93| 0| if (state) { 94| 0| [FBSDKTypeUtility dictionary:ud setObject:[FBSDKUserDataStore encryptData:state type:FBSDKAppEventState] forKey:FBSDKAppEventState]; 95| 0| } 96| 0| if (zip) { 97| 0| [FBSDKTypeUtility dictionary:ud setObject:[FBSDKUserDataStore encryptData:zip type:FBSDKAppEventZip] forKey:FBSDKAppEventZip]; 98| 0| } 99| 0| if (country) { 100| 0| [FBSDKTypeUtility dictionary:ud setObject:[FBSDKUserDataStore encryptData:country type:FBSDKAppEventCountry] forKey:FBSDKAppEventCountry]; 101| 0| } 102| 0| if (externalId) { 103| 0| [FBSDKTypeUtility dictionary:ud setObject:[FBSDKUserDataStore encryptData:externalId type:FBSDKAppEventExternalId] forKey:FBSDKAppEventExternalId]; 104| 0| } 105| | 106| 0| dispatch_async(serialQueue, ^{ 107| 0| hashedUserData = [ud mutableCopy]; 108| 0| [[NSUserDefaults standardUserDefaults] setObject:[FBSDKUserDataStore stringByHashedData:hashedUserData] 109| 0| forKey:FBSDKUserDataKey]; 110| 0| }); 111| 0|} 112| | 113| |+ (void)setUserData:(nullable NSString *)data 114| | forType:(FBSDKAppEventUserDataType)type 115| 0|{ 116| 0| [FBSDKUserDataStore setHashData:[FBSDKUserDataStore encryptData:data type:type] 117| 0| forType:type]; 118| 0|} 119| | 120| |+ (void)setHashData:(nullable NSString *)hashData 121| | forType:(FBSDKAppEventUserDataType)type 122| 0|{ 123| 0| dispatch_async(serialQueue, ^{ 124| 0| if (!hashData) { 125| 0| [hashedUserData removeObjectForKey:type]; 126| 0| } else { 127| 0| [FBSDKTypeUtility dictionary:hashedUserData setObject:hashData forKey:type]; 128| 0| } 129| 0| [[NSUserDefaults standardUserDefaults] setObject:[FBSDKUserDataStore stringByHashedData:hashedUserData] 130| 0| forKey:FBSDKUserDataKey]; 131| 0| }); 132| 0|} 133| | 134| |+ (void)setInternalHashData:(nullable NSString *)hashData 135| | forType:(FBSDKAppEventUserDataType)type 136| 0|{ 137| 0| dispatch_async(serialQueue, ^{ 138| 0| if (!hashData) { 139| 0| [internalHashedUserData removeObjectForKey:type]; 140| 0| } else { 141| 0| internalHashedUserData[type] = hashData; 142| 0| } 143| 0| [[NSUserDefaults standardUserDefaults] setObject:[FBSDKUserDataStore stringByHashedData:internalHashedUserData] 144| 0| forKey:FBSDKInternalUserDataKey]; 145| 0| }); 146| 0|} 147| | 148| |+ (void)setEnabledRules:(NSArray *)rules 149| 0|{ 150| 0| if (rules.count > 0) { 151| 0| [enabledRules addObjectsFromArray:rules]; 152| 0| } 153| 0|} 154| | 155| |+ (void)clearUserDataForType:(FBSDKAppEventUserDataType)type 156| 0|{ 157| 0| [FBSDKUserDataStore setUserData:nil forType:type]; 158| 0|} 159| | 160| |+ (NSString *)getUserData 161| 0|{ 162| 0| return [FBSDKUserDataStore getHashedData]; 163| 0|} 164| | 165| |+ (NSString *)getHashedData 166| 0|{ 167| 0| __block NSString *hashedUserDataString; 168| 0| dispatch_sync(serialQueue, ^{ 169| 0| NSMutableDictionary *hashedUD = [NSMutableDictionary new]; 170| 0| [hashedUD addEntriesFromDictionary:hashedUserData]; 171| 0| for (NSString *key in enabledRules) { 172| 0| if (internalHashedUserData[key]) { 173| 0| hashedUD[key] = internalHashedUserData[key]; 174| 0| } 175| 0| } 176| 0| hashedUserDataString = [FBSDKUserDataStore stringByHashedData:hashedUD]; 177| 0| }); 178| 0| return hashedUserDataString; 179| 0|} 180| | 181| |+ (void)clearUserData 182| 0|{ 183| 0| [FBSDKUserDataStore setUserEmail:nil 184| 0| firstName:nil 185| 0| lastName:nil 186| 0| phone:nil 187| 0| dateOfBirth:nil 188| 0| gender:nil 189| 0| city:nil 190| 0| state:nil 191| 0| zip:nil 192| 0| country:nil 193| 0| externalId:nil]; 194| 0|} 195| | 196| |+ (NSString *)getInternalHashedDataForType:(FBSDKAppEventUserDataType)type 197| 0|{ 198| 0| __block NSString *hashedData; 199| 0| dispatch_sync(serialQueue, ^{ 200| 0| hashedData = [FBSDKTypeUtility dictionary:internalHashedUserData objectForKey:type ofType:NSObject.class]; 201| 0| }); 202| 0| return hashedData; 203| 0|} 204| | 205| |#pragma mark - Helper Methods 206| | 207| |+ (NSMutableDictionary *)initializeUserData:(NSString *)userDataKey 208| 0|{ 209| 0| NSString *userData = [[NSUserDefaults standardUserDefaults] stringForKey:userDataKey]; 210| 0| NSMutableDictionary *hashedUD = nil; 211| 0| if (userData) { 212| 0| hashedUD = (NSMutableDictionary *)[FBSDKTypeUtility JSONObjectWithData:[userData dataUsingEncoding:NSUTF8StringEncoding] 213| 0| options: NSJSONReadingMutableContainers 214| 0| error: nil]; 215| 0| } 216| 0| if (!hashedUD) { 217| 0| hashedUD = [NSMutableDictionary new]; 218| 0| } 219| 0| return hashedUD; 220| 0|} 221| | 222| |+ (NSString *)stringByHashedData:(id)hashedData 223| 0|{ 224| 0| NSError *error; 225| 0| NSData *jsonData = [FBSDKTypeUtility dataWithJSONObject:hashedData 226| 0| options:0 227| 0| error:&error]; 228| 0| if (jsonData) { 229| 0| return [[NSString alloc] initWithData:jsonData 230| 0| encoding:NSUTF8StringEncoding]; 231| 0| } else { 232| 0| return @""; 233| 0| } 234| 0|} 235| | 236| |+ (NSString *)encryptData:(NSString *)data 237| | type:(FBSDKAppEventUserDataType)type 238| 0|{ 239| 0| if (data.length == 0 || [FBSDKUserDataStore maybeSHA256Hashed:data]) { 240| 0| return data; 241| 0| } 242| 0| return [FBSDKBasicUtility SHA256Hash:[FBSDKUserDataStore normalizeData:data type:type]]; 243| 0|} 244| | 245| |+ (NSString *)normalizeData:(NSString *)data 246| | type:(FBSDKAppEventUserDataType)type 247| 0|{ 248| 0| NSString *normalizedData = @""; 249| 0| NSSet *set = [NSSet setWithArray: 250| 0| @[FBSDKAppEventEmail, FBSDKAppEventFirstName, FBSDKAppEventLastName, FBSDKAppEventCity, FBSDKAppEventState, FBSDKAppEventCountry]]; 251| 0| if ([set containsObject:type]) { 252| 0| normalizedData = [data stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceCharacterSet]]; 253| 0| normalizedData = normalizedData.lowercaseString; 254| 0| } else if ([type isEqualToString:FBSDKAppEventPhone]) { 255| 0| NSError *error = nil; 256| 0| NSRegularExpression *regex = [NSRegularExpression regularExpressionWithPattern:@"[^0-9]" 257| 0| options:NSRegularExpressionCaseInsensitive 258| 0| error:&error 259| 0| ]; 260| 0| normalizedData = [regex stringByReplacingMatchesInString:data 261| 0| options:0 262| 0| range:NSMakeRange(0, data.length) 263| 0| withTemplate:@"" 264| 0| ]; 265| 0| } else if ([type isEqualToString:FBSDKAppEventGender]) { 266| 0| NSString *temp = [data stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceCharacterSet]]; 267| 0| temp = temp.lowercaseString; 268| 0| normalizedData = temp.length > 0 ? [temp substringToIndex:1] : @""; 269| 0| } else if ([type isEqualToString:FBSDKAppEventExternalId]) { 270| 0| normalizedData = data; 271| 0| } 272| 0| return normalizedData; 273| 0|} 274| | 275| |+ (BOOL)maybeSHA256Hashed:(NSString *)data 276| 0|{ 277| 0| NSRange range = [data rangeOfString:@"[A-Fa-f0-9]{64}" options:NSRegularExpressionSearch]; 278| 0| return (data.length == 64) && (range.location != NSNotFound); 279| 0|} 280| | 281| |@end <<<<<< EOF # path=Parse#Internal#User#AuthenticationProviders#Controller#PFUserAuthenticationController.m.gcov.reduced -: 0:Source:Parse/Internal/User/AuthenticationProviders/Controller/PFUserAuthenticationController.m <<<<<< EOF # path=#Applications#Xcode_13.1.app#Contents#Developer#Platforms#iPhoneSimulator.platform#Developer#SDKs#iPhoneSimulator15.0.sdk#System#Library#Frameworks#CoreGraphics.framework#Headers#CGGeometry.h.gcov.reduced -: 0:Source:/Applications/Xcode_13.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator15.0.sdk/System/Library/Frameworks/CoreGraphics.framework/Headers/CGGeometry.h #####:280: #####:281: #####:282: <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#AEM#FBSDKAEMRule.h.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMRule.h <<<<<< EOF # path=FBSDKCoreKit#GraphAPI#FBSDKGraphRequest.h.gcov.reduced -: 0:Source:FBSDKCoreKit/GraphAPI/FBSDKGraphRequest.h <<<<<< EOF # path=FBSDKLoginKit#Internal#FBSDKAuthenticationTokenHeader.h.gcov.reduced -: 0:Source:FBSDKLoginKit/Internal/FBSDKAuthenticationTokenHeader.h <<<<<< EOF # path=Tests#Unit#FacebookAuthenticationProviderTests.m.gcov.reduced -: 0:Source:Tests/Unit/FacebookAuthenticationProviderTests.m <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#PFEncoder.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/PFEncoder.m #####:99: <<<<<< EOF # path=OCMock#OCMStubRecorder.m.gcov.reduced -: 0:Source:OCMock/OCMStubRecorder.m <<<<<< EOF # path=Parse#Internal#PFEventuallyPin.m.gcov.reduced -: 0:Source:Parse/Internal/PFEventuallyPin.m <<<<<< EOF # path=Parse#Internal#ParseClientConfiguration_Private.h.gcov.reduced -: 0:Source:Parse/Internal/ParseClientConfiguration_Private.h <<<<<< EOF # path=ParseFacebookUtils#Internal#PFFacebookPrivateUtilities.m.gcov.reduced -: 0:Source:ParseFacebookUtils/Internal/PFFacebookPrivateUtilities.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#EventDeactivation#FBSDKEventDeactivationManager.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/EventDeactivation/FBSDKEventDeactivationManager.m <<<<<< EOF # path=Parse#Internal#PFCategoryLoader.m.gcov.reduced -: 0:Source:Parse/Internal/PFCategoryLoader.m <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#Internal#PFKeychainStore.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/Internal/PFKeychainStore.m #####:74: <<<<<< EOF # path=FBSDKCoreKit#Internal#FBSDKSwizzler.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/FBSDKSwizzler.m <<<<<< EOF # path=FBSDKCoreKit#Internal#ServerConfiguration#FBSDKServerConfigurationManager.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/ServerConfiguration/FBSDKServerConfigurationManager.m <<<<<< EOF # path=Parse#Internal#PFTaskQueue.h.gcov.reduced -: 0:Source:Parse/Internal/PFTaskQueue.h <<<<<< EOF # path=ParseFacebookUtils#Internal#AuthenticationProvider#PFFacebookAuthenticationProvider.m.gcov.reduced -: 0:Source:ParseFacebookUtils/Internal/AuthenticationProvider/PFFacebookAuthenticationProvider.m <<<<<< EOF # path=Parse#Internal#Object#Coder#File#PFObjectFileCoder.m.gcov.reduced -: 0:Source:Parse/Internal/Object/Coder/File/PFObjectFileCoder.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#AEM#FBSDKAEMInvocation.h.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMInvocation.h <<<<<< EOF # path=Parse#Internal#Object#FilePersistence#PFObjectFilePersistenceController.h.gcov.reduced -: 0:Source:Parse/Internal/Object/FilePersistence/PFObjectFilePersistenceController.h <<<<<< EOF # path=#Applications#Xcode_13.1.app#Contents#Developer#Platforms#iPhoneSimulator.platform#Developer#SDKs#iPhoneSimulator15.0.sdk#System#Library#Frameworks#UIKit.framework#Headers#UIGeometry.h.gcov.reduced -: 0:Source:/Applications/Xcode_13.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator15.0.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIGeometry.h #####:135: #####:136: #####:137: #####:138: #####:139: #####:140: <<<<<< EOF # path=#Applications#Xcode_13.1.app#Contents#Developer#Platforms#iPhoneSimulator.platform#Developer#SDKs#iPhoneSimulator15.0.sdk#usr#include#c++#v1#typeinfo.gcov.reduced -: 0:Source:/Applications/Xcode_13.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator15.0.sdk/usr/include/c++/v1/typeinfo #####:201: #####:202: #####:336: #####:337: #####:338: <<<<<< EOF # path=Parse#Internal#File#State#PFFileState.m.gcov.reduced -: 0:Source:Parse/Internal/File/State/PFFileState.m <<<<<< EOF # path=FBSDKCoreKit#FBSDKBridgeAPIResponse.m.gcov.reduced -: 0:Source:FBSDKCoreKit/FBSDKBridgeAPIResponse.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#FBSDKHybridAppEventsScriptMessageHandler.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/FBSDKHybridAppEventsScriptMessageHandler.m <<<<<< EOF # path=Parse#Internal#Commands#CommandRunner#URLRequestConstructor#PFCommandURLRequestConstructor.m.gcov.reduced -: 0:Source:Parse/Internal/Commands/CommandRunner/URLRequestConstructor/PFCommandURLRequestConstructor.m <<<<<< EOF # path=Parse#Internal#Config#Controller#PFConfigController.h.gcov.reduced -: 0:Source:Parse/Internal/Config/Controller/PFConfigController.h <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#Internal#PFBaseState.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/Internal/PFBaseState.m #####:69: <<<<<< EOF # path=FBSDKCoreKit#Internal#BridgeAPI#FBSDKBridgeAPIResponseFactory.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/BridgeAPI/FBSDKBridgeAPIResponseFactory.m <<<<<< EOF # path=Parse#Internal#LocalDataStore#OfflineQueryLogic#PFOfflineQueryLogic.m.gcov.reduced -: 0:Source:Parse/Internal/LocalDataStore/OfflineQueryLogic/PFOfflineQueryLogic.m <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Parse#Parse#Internal#User#AuthenticationProviders#Controller#PFUserAuthenticationController.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Parse/Parse/Internal/User/AuthenticationProviders/Controller/PFUserAuthenticationController.m #####:86: <<<<<< EOF # path=Parse#Internal#Purchase#Controller#PFPurchaseController.h.gcov.reduced -: 0:Source:Parse/Internal/Purchase/Controller/PFPurchaseController.h <<<<<< EOF # path=Bolts#Common#BFCancellationTokenSource.m.gcov.reduced -: 0:Source:Bolts/Common/BFCancellationTokenSource.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#AEM#FBSDKAEMAdvertiserRuleFactory.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMAdvertiserRuleFactory.m <<<<<< EOF # path=Parse#Internal#PFErrorUtilities.m.gcov.reduced -: 0:Source:Parse/Internal/PFErrorUtilities.m <<<<<< EOF # path=FBSDKCoreKit#Internal#ServerConfiguration#FBSDKDialogConfiguration.h.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/ServerConfiguration/FBSDKDialogConfiguration.h <<<<<< EOF # path=Parse#Internal#Object#State#PFObjectState_Private.h.gcov.reduced -: 0:Source:Parse/Internal/Object/State/PFObjectState_Private.h <<<<<< EOF # path=Parse#Internal#LocalDataStore#SQLite#PFSQLiteDatabaseController.m.gcov.reduced -: 0:Source:Parse/Internal/LocalDataStore/SQLite/PFSQLiteDatabaseController.m <<<<<< EOF # path=Parse#Internal#ACL#State#PFACLState_Private.h.gcov.reduced -: 0:Source:Parse/Internal/ACL/State/PFACLState_Private.h <<<<<< EOF # path=Parse#Internal#MultiProcessLock#PFMultiProcessFileLockController.m.gcov.reduced -: 0:Source:Parse/Internal/MultiProcessLock/PFMultiProcessFileLockController.m <<<<<< EOF # path=Parse#PFPolygon.m.gcov.reduced -: 0:Source:Parse/PFPolygon.m <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Carthage#Checkouts#facebook-ios-sdk#Sources#FBSDKCoreKit_Basics#include#FBSDKURLSession.h.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/include/FBSDKURLSession.h <<<<<< EOF # path=OCMock#OCMObserverRecorder.m.gcov.reduced -: 0:Source:OCMock/OCMObserverRecorder.m <<<<<< EOF # path=OCMock#OCMVerifier.m.gcov.reduced -: 0:Source:OCMock/OCMVerifier.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#Codeless#FBSDKCodelessPathComponent.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/Codeless/FBSDKCodelessPathComponent.m <<<<<< EOF # path=FBSDKCoreKit#Internal#Instrument#CrashReport#FBSDKCrashShield.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/Instrument/CrashReport/FBSDKCrashShield.m <<<<<< EOF # path=Parse#Internal#PFCommandCache.m.gcov.reduced -: 0:Source:Parse/Internal/PFCommandCache.m <<<<<< EOF # path=Parse#Internal#User#State#PFUserState.m.gcov.reduced -: 0:Source:Parse/Internal/User/State/PFUserState.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#Codeless#FBSDKCodelessParameterComponent.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/Codeless/FBSDKCodelessParameterComponent.m <<<<<< EOF # path=Parse#Internal#Push#State#PFMutablePushState.m.gcov.reduced -: 0:Source:Parse/Internal/Push/State/PFMutablePushState.m <<<<<< EOF # path=Parse#Internal#CloudCode#PFCloudCodeController.m.gcov.reduced -: 0:Source:Parse/Internal/CloudCode/PFCloudCodeController.m <<<<<< EOF # path=Parse#PFQuery.m.gcov.reduced -: 0:Source:Parse/PFQuery.m <<<<<< EOF # path=OCMock#OCMRecorder.m.gcov.reduced -: 0:Source:OCMock/OCMRecorder.m <<<<<< EOF # path=OCMock#OCObserverMockObject.m.gcov.reduced -: 0:Source:OCMock/OCObserverMockObject.m <<<<<< EOF # path=#Applications#Xcode_13.1.app#Contents#Developer#Platforms#iPhoneSimulator.platform#Developer#SDKs#iPhoneSimulator15.0.sdk#usr#include#c++#v1#tuple.gcov.reduced -: 0:Source:/Applications/Xcode_13.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator15.0.sdk/usr/include/c++/v1/tuple #####:231: #####:232: #####:233: #####:234: #####:276: #####:383: #####:388: #####:390: #####:701: #####:702: #####:706: #####:707: #####:783: #####:793: #####:797: #####:1008: #####:1009: #####:1011: #####:1146: #####:1147: #####:1148: #####:1397: #####:1400: #####:1401: #####:1402: #####:1403: <<<<<< EOF # path=FBSDKCoreKit#Internal#ErrorRecovery#FBSDKErrorRecoveryAttempter.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/ErrorRecovery/FBSDKErrorRecoveryAttempter.m <<<<<< EOF # path=#Applications#Xcode_13.1.app#Contents#Developer#Platforms#iPhoneSimulator.platform#Developer#SDKs#iPhoneSimulator15.0.sdk#usr#include#c++#v1#utility.gcov.reduced -: 0:Source:/Applications/Xcode_13.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator15.0.sdk/usr/include/c++/v1/utility #####:309: #####:444: #####:447: #####:525: #####:531: #####:532: #####:533: #####:534: #####:970: #####:971: #####:973: #####:974: #####:1038: #####:1039: #####:1042: #####:1043: #####:1046: #####:1047: #####:1050: #####:1052: #####:1053: #####:1054: #####:1055: #####:1056: #####:1057: #####:1058: #####:1059: #####:1062: #####:1064: #####:1065: #####:1066: #####:1067: #####:1068: #####:1070: #####:1071: #####:1072: #####:1073: #####:1075: #####:1076: #####:1077: #####:1078: #####:1079: #####:1080: #####:1081: #####:1082: #####:1084: #####:1085: #####:1087: #####:1089: #####:1090: #####:1091: #####:1092: #####:1093: #####:1094: #####:1095: #####:1100: #####:1103: #####:1104: #####:1105: #####:1106: #####:1107: #####:1108: #####:1109: #####:1110: #####:1114: #####:1117: #####:1118: #####:1119: #####:1120: #####:1121: #####:1122: #####:1123: #####:1127: #####:1129: #####:1130: #####:1131: #####:1132: #####:1133: #####:1134: #####:1135: #####:1136: #####:1137: #####:1138: #####:1139: #####:1140: #####:1141: #####:1142: #####:1143: #####:1144: #####:1145: #####:1146: #####:1147: #####:1148: #####:1149: #####:1150: #####:1157: #####:1158: #####:1159: #####:1160: #####:1161: #####:1162: #####:1164: #####:1166: #####:1167: #####:1172: #####:1173: #####:1174: #####:1175: #####:1176: #####:1177: #####:1178: #####:1179: #####:1182: #####:1183: #####:1184: #####:1185: #####:1186: #####:1187: #####:1188: #####:1189: #####:1190: #####:1191: #####:1192: #####:1193: #####:1194: #####:1195: #####:1196: #####:1197: #####:1198: #####:1199: <<<<<< EOF # path=Parse#Internal#Commands#CommandRunner#URLSession#PFURLSessionCommandRunner_Private.h.gcov.reduced -: 0:Source:Parse/Internal/Commands/CommandRunner/URLSession/PFURLSessionCommandRunner_Private.h <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#FBSDKAppEventsConfiguration.h.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsConfiguration.h <<<<<< EOF # path=Parse#Internal#Object#OperationSet#PFOperationSet.m.gcov.reduced -: 0:Source:Parse/Internal/Object/OperationSet/PFOperationSet.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#FBSDKAppEventsState.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsState.m <<<<<< EOF # path=Parse#Internal#Query#Controller#PFQueryController.h.gcov.reduced -: 0:Source:Parse/Internal/Query/Controller/PFQueryController.h <<<<<< EOF # path=Parse#PFRelation.m.gcov.reduced -: 0:Source:Parse/PFRelation.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#Codeless#FBSDKEventBinding.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/Codeless/FBSDKEventBinding.m <<<<<< EOF # path=Parse#Internal#Object#State#PFObjectState.h.gcov.reduced -: 0:Source:Parse/Internal/Object/State/PFObjectState.h <<<<<< EOF # path=Parse#Internal#Persistence#Group#PFUserDefaultsPersistenceGroup.m.gcov.reduced -: 0:Source:Parse/Internal/Persistence/Group/PFUserDefaultsPersistenceGroup.m <<<<<< EOF # path=#Applications#Xcode_13.1.app#Contents#Developer#Platforms#iPhoneSimulator.platform#Developer#SDKs#iPhoneSimulator15.0.sdk#usr#include#c++#v1#initializer_list.gcov.reduced -: 0:Source:/Applications/Xcode_13.1.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator15.0.sdk/usr/include/c++/v1/initializer_list #####:84: #####:88: #####:92: <<<<<< EOF # path=FBSDKCoreKit#AppLink#Internal#FBSDKMeasurementEventListener.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppLink/Internal/FBSDKMeasurementEventListener.m <<<<<< EOF # path=Bolts#Common#BFCancellationTokenRegistration.m.gcov.reduced -: 0:Source:Bolts/Common/BFCancellationTokenRegistration.m <<<<<< EOF # path=FBSDKLoginKit#Internal#FBSDKLoginCompletion+Internal.h.gcov.reduced -: 0:Source:FBSDKLoginKit/Internal/FBSDKLoginCompletion+Internal.h <<<<<< EOF # path=Parse#Internal#Installation#CurrentInstallationController#PFCurrentInstallationController.h.gcov.reduced -: 0:Source:Parse/Internal/Installation/CurrentInstallationController/PFCurrentInstallationController.h <<<<<< EOF # path=FBSDKCoreKit#Internal#FBSDKLogger.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/FBSDKLogger.m <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Carthage#Checkouts#facebook-ios-sdk#Sources#FBSDKCoreKit_Basics#FBSDKBase64.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKBase64.m 1:28: 1:30: 1:31: 1:32: 1:33: 1:34: #####:36: #####:38: #####:39: #####:41: #####:43: #####:44: 1:46: 1:48: 1:49: #####:51: #####:53: #####:54: #####:56: #####:58: #####:59: #####:61: #####:62: #####:68: #####:70: #####:71: #####:75: #####:76: #####:77: #####:78: #####:79: #####:81: #####:82: #####:84: #####:86: #####:87: #####:88: #####:90: #####:91: 1:93: 1:95: #####:96: 1:99: 1:100: #####:102: #####:104: #####:105: <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#SKAdNetwork#FBSDKSKAdNetworkEvent.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/SKAdNetwork/FBSDKSKAdNetworkEvent.m <<<<<< EOF # path=Parse#Internal#File#State#PFFileState_Private.h.gcov.reduced -: 0:Source:Parse/Internal/File/State/PFFileState_Private.h <<<<<< EOF # path=OCMock#OCMConstraint.m.gcov.reduced -: 0:Source:OCMock/OCMConstraint.m <<<<<< EOF # path=FBSDKCoreKit#Internal#FBSDKContainerViewController.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/FBSDKContainerViewController.m <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Carthage#Checkouts#facebook-ios-sdk#Sources#FBSDKCoreKit_Basics#FBSDKCrashHandler.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKCrashHandler.m #####:65: #####:67: #####:68: #####:69: #####:71: #####:73: #####:77: #####:78: #####:79: #####:80: #####:81: #####:82: #####:84: #####:85: #####:86: #####:87: #####:88: #####:89: #####:90: #####:91: #####:92: #####:93: #####:95: #####:99: #####:100: #####:101: #####:102: #####:107: #####:109: #####:112: #####:114: #####:115: #####:117: #####:119: #####:120: #####:121: #####:122: #####:124: #####:126: #####:127: #####:129: #####:131: #####:132: #####:135: #####:136: #####:137: #####:138: #####:139: #####:140: #####:141: #####:142: #####:143: #####:144: #####:145: #####:146: #####:147: #####:148: #####:150: #####:152: #####:153: #####:155: #####:157: #####:158: #####:159: #####:160: #####:161: #####:162: #####:163: #####:164: #####:165: #####:167: #####:169: #####:170: #####:172: #####:174: #####:176: #####:178: #####:179: #####:180: #####:181: #####:182: #####:186: #####:188: #####:189: #####:191: #####:193: #####:195: #####:196: #####:197: #####:198: #####:199: #####:201: #####:203: #####:204: #####:206: #####:208: #####:209: #####:210: #####:212: #####:213: #####:214: #####:215: #####:216: #####:217: #####:218: #####:222: #####:224: #####:225: #####:227: #####:229: #####:230: #####:231: #####:232: #####:233: #####:235: #####:236: #####:238: #####:240: #####:243: #####:245: #####:246: #####:247: #####:248: #####:250: #####:252: #####:253: #####:254: #####:255: #####:256: #####:258: #####:261: #####:262: #####:263: #####:264: #####:265: #####:266: #####:267: #####:268: #####:269: #####:270: #####:272: #####:274: #####:277: #####:279: #####:280: #####:281: #####:282: #####:283: #####:285: #####:286: #####:287: #####:288: #####:290: #####:293: #####:294: #####:295: #####:296: #####:297: #####:298: #####:300: #####:302: #####:303: #####:305: #####:307: #####:308: #####:310: #####:312: #####:313: #####:315: #####:317: #####:319: #####:320: #####:321: #####:322: #####:323: #####:325: #####:326: #####:328: #####:330: #####:331: #####:333: #####:335: #####:336: #####:338: #####:339: #####:341: #####:342: #####:343: #####:346: #####:347: #####:349: #####:351: #####:353: #####:355: #####:357: #####:359: #####:360: #####:362: #####:364: #####:365: #####:366: #####:367: #####:368: #####:369: #####:370: #####:372: #####:375: #####:376: #####:378: #####:381: #####:382: #####:383: #####:384: #####:385: #####:386: #####:387: #####:388: #####:389: #####:391: #####:394: #####:395: #####:397: #####:400: #####:401: #####:402: #####:403: #####:405: #####:406: #####:407: #####:411: #####:413: #####:414: #####:416: #####:418: #####:419: #####:421: #####:422: #####:423: #####:424: #####:425: #####:426: #####:428: #####:429: #####:431: #####:433: #####:434: #####:436: #####:438: #####:439: #####:440: #####:442: #####:444: #####:445: #####:447: #####:449: #####:450: #####:451: #####:453: #####:455: #####:456: #####:458: #####:460: #####:461: #####:462: #####:464: #####:466: #####:469: #####:472: <<<<<< EOF # path=FBSDKLoginKit#Internal#FBSDKLoginManagerLogger.m.gcov.reduced -: 0:Source:FBSDKLoginKit/Internal/FBSDKLoginManagerLogger.m <<<<<< EOF # path=Parse#Internal#KeyValueCache#PFKeyValueCache_Private.h.gcov.reduced -: 0:Source:Parse/Internal/KeyValueCache/PFKeyValueCache_Private.h <<<<<< EOF # path=Parse#Internal#Commands#CommandRunner#URLSession#Session#PFURLSession.h.gcov.reduced -: 0:Source:Parse/Internal/Commands/CommandRunner/URLSession/Session/PFURLSession.h <<<<<< EOF # path=Parse#PFUser.m.gcov.reduced -: 0:Source:Parse/PFUser.m <<<<<< EOF # path=FBSDKCoreKit#AppLink#FBSDKAppLink.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppLink/FBSDKAppLink.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#ML#FBSDKModelManager.mm.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/ML/FBSDKModelManager.mm <<<<<< EOF # path=FBSDKCoreKit#Internal#TokenCaching#FBSDKAccessTokenExpirer.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/TokenCaching/FBSDKAccessTokenExpirer.m <<<<<< EOF # path=FBSDKCoreKit#Internal#UI#FBSDKViewImpressionTracker.h.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/UI/FBSDKViewImpressionTracker.h <<<<<< EOF # path=OCMock#OCMArg.m.gcov.reduced -: 0:Source:OCMock/OCMArg.m <<<<<< EOF # path=FBSDKLoginKit#Internal#FBSDKPermission.m.gcov.reduced -: 0:Source:FBSDKLoginKit/Internal/FBSDKPermission.m <<<<<< EOF # path=Parse#Internal#User#Controller#PFUserController.h.gcov.reduced -: 0:Source:Parse/Internal/User/Controller/PFUserController.h <<<<<< EOF # path=FBSDKLoginKit#Internal#_FBSDKLoginRecoveryAttempter.m.gcov.reduced -: 0:Source:FBSDKLoginKit/Internal/_FBSDKLoginRecoveryAttempter.m <<<<<< EOF # path=Tests#Unit#FacebookUtilsTests.m.gcov.reduced -: 0:Source:Tests/Unit/FacebookUtilsTests.m <<<<<< EOF # path=FBSDKCoreKit#FBSDKButton.m.gcov.reduced -: 0:Source:FBSDKCoreKit/FBSDKButton.m <<<<<< EOF # path=Parse#PFDecoder.m.gcov.reduced -: 0:Source:Parse/PFDecoder.m <<<<<< EOF # path=FBSDKCoreKit#AppEvents#Internal#FBSDKAppEventsUtility.m.gcov.reduced -: 0:Source:FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsUtility.m <<<<<< EOF # path=Parse#Internal#Push#State#PFPushState_Private.h.gcov.reduced -: 0:Source:Parse/Internal/Push/State/PFPushState_Private.h <<<<<< EOF # path=Parse#Internal#PFBaseState.m.gcov.reduced -: 0:Source:Parse/Internal/PFBaseState.m <<<<<< EOF # path=FBSDKLoginKit#FBSDKLoginManagerLoginResult.h.gcov.reduced -: 0:Source:FBSDKLoginKit/FBSDKLoginManagerLoginResult.h <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Carthage#Checkouts#facebook-ios-sdk#Sources#FBSDKCoreKit_Basics#include#FBSDKURLSessionTask.h.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/include/FBSDKURLSessionTask.h <<<<<< EOF # path=#Users#runner#work#Parse-SDK-iOS-OSX#Parse-SDK-iOS-OSX#Carthage#Checkouts#facebook-ios-sdk#FBSDKCoreKit#FBSDKCoreKit#AppEvents#Internal#FBSDKAppEventsAtePublisher.m.gcov.reduced -: 0:Source:/Users/runner/work/Parse-SDK-iOS-OSX/Parse-SDK-iOS-OSX/Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsAtePublisher.m #####:108: <<<<<< EOF # path=FBSDKCoreKit#Internal#FBSDKError.m.gcov.reduced -: 0:Source:FBSDKCoreKit/Internal/FBSDKError.m <<<<<< EOF # path=fixes ./ParseFacebookUtils/ParseFacebookUtils/PFFacebookUtils.m:9,11,15,17,23,25,29,31,35,36,37,40,41,44,45,49,54,65,67,68,69,72,76,77,79,83,86,87,91,92,95,96,100,101,105,111,112,115,119,125,126,130,131,135,139,140,145,146,150,151,156,157,160,164,166,167,172,173,178,184,185,189,193,194,197,198,202,205,206 ./ParseFacebookUtils/ParseFacebookUtils/ParseFacebookUtilsV4.h:9 ./ParseFacebookUtils/ParseFacebookUtils/Internal/PFFacebookUtils_Private.h:9,11,13,15,18 ./ParseFacebookUtils/ParseFacebookUtils/Internal/AuthenticationProvider/PFFacebookAuthenticationProvider.m:9,11,13,15,17,19,23,28,31,33,34,38,39,43,49,50,55,56,60,65,66,72,73,75,76 ./ParseFacebookUtils/ParseFacebookUtils/Internal/AuthenticationProvider/iOS/PFFacebookMobileAuthenticationProvider.m:9,12,15,18,20,22,24,28,33,35,37,38,42,46,48,57,59,61,63,64,68,72,74,75 ./ParseFacebookUtils/ParseFacebookUtils/Internal/AuthenticationProvider/iOS/PFFacebookMobileAuthenticationProvider.h:9,11,13,16,18,20,22,24,26,28 ./ParseFacebookUtils/ParseFacebookUtils/Internal/AuthenticationProvider/iOS/PFFacebookMobileAuthenticationProvider_Private.h:9,11,13,15,17,19 ./ParseFacebookUtils/ParseFacebookUtils/Internal/AuthenticationProvider/tvOS/PFFacebookDeviceAuthenticationProvider.h:9,11,13,15 ./ParseFacebookUtils/ParseFacebookUtils/Internal/AuthenticationProvider/tvOS/PFFacebookDeviceAuthenticationProvider.m:9,11,14,19,21,25,26,28,30,34,43,49,51,54,55,59,63,65,66,70,75,76,83,84,89,90 ./ParseFacebookUtils/ParseFacebookUtils/Internal/AuthenticationProvider/PFFacebookAuthenticationProvider.h:9,12,14,17,19,21,23,27,30,35,39,45,47 ./ParseFacebookUtils/ParseFacebookUtils/Internal/PFFacebookPrivateUtilities.m:9,11,13,15,20,22,23,27,34,35,39,40,44,45,51,52,56,57,59,61,66,69,70,75,78,79,82,83,85,87,92,93,95,97,104,105 ./ParseFacebookUtils/ParseFacebookUtils/Internal/PFFacebookPrivateUtilities.h:9,12,16,18,20,22,24,28,33,35,37,39,43,45,47,49,51,53,55,57 ./ParseFacebookUtils/ParseFacebookUtils/PFFacebookUtils.h:9,11,13,16,18,22,24,27,31,35,38,41,43,47,52,54,59,63,66,69,71,75,78,81,88,91,94,96,100,103,106,113,116,119,121,125,128,131,138,142,145,149,152,157,160,164,173,176,180,183,188,191,195,204,207,211,214,218,221,225,234,238,241,246,249,255,259,262,264,268,270 ./ParseFacebookUtils/Tests/Unit/FacebookUtilsTests.m:9,11,13,17,21,23,25,27,31,34,36,37,41,46,47,51,57,59,61,65,69,71,72,76,78,81,82,87,90,98,106,107,112,115,123,131,132,138,141,150,159,160,164,167,169,177,184,185,189,193,201,208,209,215,218,221,229,236,237,241,244,252,259,260,264,267,270,271 ./ParseFacebookUtils/Tests/Unit/FacebookAuthenticationProviderTests.m:9,11,14,17,19,21,23,26,27,32,34,40,50,56,59,62,71,72,77,79,85,95,101,104,107,116,117,120,123,129,139,145,148,156,157,160,166,172,175,178,186,187,191,197,200,203,211,212,215,218,220,226,236,242,245,247,248,249,252,261,262,267,269,272,274,275,279,282,284,286,287 ./ParseFacebookUtils/Tests/Other/TestCase/PFFacebookTestCase.m:9,11,15,16,20,23,26,27,32,35,37,38,42,47,48,51,52,56,61,62 ./ParseFacebookUtils/Tests/Other/TestCase/PFFacebookTestCase.h:9,11,13,15,19,22,26,29,33,35,37,41,47,53,59,65,68,71,74,77 ./ParseFacebookUtils/Tests/TestApplication/Classes/main.m:9,11,13,15,17,23,24,26,30,31 ./ParseFacebookUtils/Vendor/FBSDKLoginKit.framework/Headers/FBSDKLoginConfiguration.h:18,20,22,24,28,31,34,38,42,46,50,53,56,59,62,65,68,80,83,97,100,110,113,122,125,136,139,146,149,154,157,161,163 ./ParseFacebookUtils/Vendor/FBSDKLoginKit.framework/Headers/FBSDKReferralManager.h:18,20,22,24,26,28,37,43,49,55,57,59 ./ParseFacebookUtils/Vendor/FBSDKLoginKit.framework/Headers/FBSDKDeviceLoginManagerResult.h:18,20,24,26,28,35,41,46,52,54 ./ParseFacebookUtils/Vendor/FBSDKLoginKit.framework/Headers/FBSDKLoginButton.h:18,20,22,24,26,28,30,32,34,37,39,41,47,57,60,64,67,73,86,89,118,120,127,138,144,152,154,156 ./ParseFacebookUtils/Vendor/FBSDKLoginKit.framework/Headers/FBSDKLoginConstants.h:18,20,22,24,27,32,34,37,42,44,50,56,61,66,71,76,81,86,93,98,103,108,114,137 ./ParseFacebookUtils/Vendor/FBSDKLoginKit.framework/Headers/FBSDKDeviceLoginManager.h:18,20,23,25,27,33,42,53,55,62,67,75,78,83,88,94,100,105,107 ./ParseFacebookUtils/Vendor/FBSDKLoginKit.framework/Headers/FBSDKReferralManagerResult.h:18,20,22,24,26,28,34,37,42,47,56,58 ./ParseFacebookUtils/Vendor/FBSDKLoginKit.framework/Headers/FBSDKTooltipView.h:18,20,22,24,26,29,33,39,42,46,52,54,57,58,59,64,71,77,82,87,90,92,94,96,97,98,100,101,107,111,115,116,117,123,126,128,130,138,141,142,143,147,149,151 ./ParseFacebookUtils/Vendor/FBSDKLoginKit.framework/Headers/FBSDKCoreKitImport.h:18,23 ./ParseFacebookUtils/Vendor/FBSDKLoginKit.framework/Headers/FBSDKLoginManager.h:18,20,22,24,26,35,38,41,44,46,49,54,59,61,63,65,74,75,78,80,87,95,98,101,105,111,114,118,121,127,133,142,145,150,157,166,171,174,180,186,193,200,203,205,209,211,213 ./ParseFacebookUtils/Vendor/FBSDKLoginKit.framework/Headers/FBSDKLoginKit.h:18,20,27 ./ParseFacebookUtils/Vendor/FBSDKLoginKit.framework/Headers/FBSDKLoginKit-Swift.h:8,21,25,31,53,68,131,136,140,194,202,209,210,211,212,218,225,238,242,248,270,285,348,353,357,411,419,426,427,428,429,435 ./ParseFacebookUtils/Vendor/FBSDKLoginKit.framework/Headers/FBSDKDeviceLoginCodeInfo.h:18,20,22,29,35,40,45,50,55,60,62 ./ParseFacebookUtils/Vendor/FBSDKLoginKit.framework/Headers/FBSDKReferralCode.h:18,20,22,24,26,32,35,40,47,49,51 ./ParseFacebookUtils/Vendor/FBSDKLoginKit.framework/Headers/FBSDKLoginTooltipView.h:18,20,22,24,26,28,30,32,35,36,40,44,48,51,55,57,60,66,68,71,75,76,80,84,88,92,96,97,99,101 ./ParseFacebookUtils/Vendor/FBSDKLoginKit.framework/Headers/FBSDKLoginManagerLoginResult.h:18,20,22,24,33,35,41,43,45,48,54,57,62,67,72,75,79,82,86,102,104 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKAuthenticationTokenClaims.h:18,20,22,24,27,30,33,36,39,42,45,48,51,54,57,60,64,67,70,74,77,80,83,86,89,92,95,97 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKGraphRequestHTTPMethod.h:18,20,23,26,29 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKDeviceViewControllerBase.h:18,20,22,24,26,29,35,37 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKURLOpening.h:18,20,22,24,28,33,41,49,51,53,56,58 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKWebViewAppLinkResolver.h:18,20,22,24,26,28,35,41,43,45 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKSettingsLogging.h:18,20,22,25,29,31 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKBridgeAPIRequest.h:18,20,22,24,28,32,36,42,44,46,50,55,64,72,74,76 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKWebDialog.h:18,20,22,24,26,28,32,37,41,45,48,52,57,61,67,69,73,78,82,86,90,94,98,102,104,106 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKGraphRequestFlags.h:18,20,22,35 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKAppEvents.h:18,20,24,38,40,42,44,48,50,54,56,60,66,88,94,99,102,105,108,111,114,117,120,123,126,129,132,135,139,142,145,148,151,154,157,160,163,166,169,172,175,178,181,184,187,190,193,196,199,202,205,210,213,216,219,224,228,230,231,234,235,236,238,243,245,247,249,255,258,260,263,266,268,276,278,281,284,288,292,296,298,302,305,306,307,312,317,320,324,329,333,335,337,341,343,345,347,350,356,357,359,362,365,373,375,378,381,384,389,394,395,397,401,404,408,413,420,424,426,428,431,434,435,438,442,444,447,450,453,458,459,462,467,469,472,475,478,483,485,486,489,495,496,500,503,507,510,515,555,558,560,566,569,570,571,579,583,586,587,588,590,594,597,598,599,601,606,612,617,622,627,630,635,640,644,646,669,674,679,683,685,691,696,704,709,713,715,717,719,722,727,732,736,742,746,753,755 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKAccessTokenProtocols.h:18,20,23,27,32,35,37,41,46,48 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKAccessToken.h:18,20,23,29,31,33,36,43,45,48,56,60,65,72,75,80,83,88,95,96,102,103,106,111,114,117,121,125,130,135,141,147,152,158,163,168,173,178,183,188,191,207,222,239,255,262,269,274,277,282,287,290,294,296 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKURL.h:18,20,22,24,26,28,35,38,48,57,63,68,74,79,84,89,94,99,101,103 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKAppLinkTarget.h:18,20,22,24,26,33,36,42,45,48,51,53,55 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKImpressionTrackingButton.h:18,20,22,26,32 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKSettingsProtocol.h:18,21,24,42 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKAppLinkNavigation.h:18,20,22,24,27,29,41,46,50,60,63,70,77,84,87,93,99,107,111,114,119,123,131,134,142,144,146 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKUtility.h:18,20,22,28,31,39,50,58,66,74,80,83,88,93,97,104,106 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKConstants.h:18,20,22,24,27,32,34,37,42,44,46,50,53,59,65,71,74,79,85,91,95,98,103,109,115,121,127,129,133,136,142,148,154,157,162,168,174,178,181,186,192,198,204,210,212,216,222,228,234,238,244,250,255,260,265,270,276,281,284,288,291,296,299,303,306,311,316,321,326,331,337,343,351,357,363,370 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKSettings.h:18,20,22,24,27,30,35,40,44,46,50,56,62,68,74,81,88,93,96,100,103,107,111,114,118,121,124,128,132,136,140,143,145,149,152,154,158,164,167,172,175,179,182,190,193,197,200,204,206 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKBridgeAPIProtocolType.h:18,20,22,24,28,35 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKAppLinkUtility.h:18,20,22,24,26,31,32,38,39,45,48,55,57,58,61,67,70,72,74,75,81,88,90,92 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKMeasurementEvent.h:18,20,22,24,26,28,32,34,38,40,48,55,62,66,73,76,78,80 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKBridgeAPIProtocol.h:18,20,22,24,26,28,32,36,41,52,54 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKApplicationDelegate.h:18,20,22,24,26,30,31,32,38,41,47,52,54,56,58,60,67,73,75,77,79,86,92,94,96,101,104,108,111,115,117 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKAppEventsFlushBehavior.h:18,20,22,24,26,29,30,33,39,40 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKDeviceButton.h:18,20,22,24,26,29,34,36,38 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKCoreKit.h:18,20,22,56,81,83,119,143 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKAppLinkResolving.h:18,20,22,24,26,28,33,37,38,46,49,55,57,59 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKBridgeAPIResponse.h:18,20,22,24,27,29,33,38,41,48,53,55,57 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKGraphRequestDataAttachment.h:18,20,22,28,31,42,47,52,57,59 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKLocation.h:18,21,23,26,35,38,42,46,48 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKRandom.h:18,20 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKAppLinkResolver.h:18,20,22,24,26,28,37,39,43,46,49,52,55,61,67,69,71 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKGraphErrorRecoveryProcessor.h:18,20,22,24,30,32,35,41,51,57,64,66,68,70,73,76,83,86,89,97,107,109,111 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKMutableCopying.h:18,20,22,24,26,28,31,36,42,44,46 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKButtonImpressionTracking.h:18,20,24,29,33 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKBridgeAPI.h:18,20,22,24,31,38,40,44,49,53,57,61,66,70,73,81,86,91,95,97,99,101 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKProfile.h:18,20,22,24,29,31,33,36,43,45,48,55,57,59,64,66,71,76,80,86,89,93,96,101,104,122,159,194,198,201,205,228,230,235,246,252,256,259,263,266,270,273,277,280,284,287,291,295,298,304,308,313,321,328,330 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKProfilePictureView.h:18,20,22,24,26,28,34,56,62,65,71,74,78,83,88,91,96,98,100 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKGraphRequestConnecting.h:18,20,22,26,31,35,38,41,44,46 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKCoreKitVersions.h:18 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKAdvertisingTrackingStatus.h:18,20,22,26,30,35 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKGraphRequestProtocol.h:18,20,23,25,28,32,36,40,45,50,55,60,65,70,75,80,86,91,93 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKCopying.h:18,20,22,25,30,36,38 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKGraphRequestConnection.h:18,20,22,26,27,34,38,41,44,47,49,53,55,60,63,66,69,71,75,77,84,87,93,95,98,100,101,102,106,110,113,115,116,117,122,124,128,131,133,134,135,139,147,150,152,153,154,156,158,168,170,172,174,175,176,180,184,189,194,199,202,203,204,207,212,215,220,224,228,231,233,236,243,246,248,251,257,260,262,264,267,272,281,284,286,288,291,296,304,307,309,311,313,317,326,329,331,333,335,339,347,351,354,357,365,368,371,372,375,379,382,384,388,392,394 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKApplicationObserving.h:18,20,22,28,35,40,42 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKUserAgeRange.h:18,21,23,26,35,38,42,47,49 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKFeature.h:18,20,22,26,29,42,46,70,74,78,82,84,88,92 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKLoggingBehavior.h:18,20,22,26,28,31,34,37,40,43,46,49,54,57,60 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKGraphRequestConnection+GraphRequestConnecting.h:18,20,22,24,28 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKAppEventParameterName.h:18,20,25,28,36,39,42,45,48,51,54,57,60,63,66 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKAppLinkResolverRequestBuilder.h:18,20,22,24,28,34,37,42,46,48 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKGraphRequest.h:18,20,23,25,29,30,34,38,40,43,48,51,57,65,73,83,98,103,108,113,118,123,127,132,137,144,150,152 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKCoreKit-Swift.h:8,21,25,31,53,68,131,136,140,194,202,209,210,216,223,236,240,246,268,283,346,351,355,409,417,424,425,431 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKFeatureChecking.h:18,20,24,29,31,34 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKAppEventName.h:18,20,25,28,31,34,37,40,43,46,49,52,55,58,61,64,67,70,73,76,79,82,85,88,91,94 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKButton.h:18,20,22,24,30,32 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKAuthenticationToken.h:18,20,22,25,27,33,36,39,44,49,54,59,64,68,72,74 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKAppLink.h:18,20,22,24,26,28,32,39,42,45,48,58,61,67,70,72,74 ./ParseFacebookUtils/Vendor/FBSDKCoreKit.framework/Headers/FBSDKTokenCaching.h:18,20,23,27,32,36,40,44,48 ./ParseTwitterUtils/ParseTwitterUtils/PF_Twitter.m:9,12,16,19,21,27,29,33,38,39,45,49,53,55,56,60,65,66,77,78,88,94,99,100,111,113,116,117,129,132,133,137,139,148,153,154,159,169,174,176,177,186,192,193,207,214,217,218,238,247,250,251,258,263,266,267,270,276,285,287,289,290,297,298,302,305,309,310,314,315,318,322,323,329,332,342,348,352,354,355,358,365,367,368,371,375,382,383,394,400,402,403,406,411,412,418,419,423,424,426,431,432,437,438,440,453,457,459,460,465,467,469,475,477,479,480,484,496,497 ./ParseTwitterUtils/ParseTwitterUtils/PFTwitterUtils.h:9,11,14,16,19,22,26,30,33,37,40,42,47,50,52,56,60,63,66,70,73,76,81,84,87,93,96,99,104,111,114,117,130,133,136,151,155,158,161,163,167,170,173,175,179,182,185,191,194,197,204,207,210,223,226,229,244,247,250,267,271,274,276,280,283,286,290,293,295,299,302,308,311,317,319 ./ParseTwitterUtils/ParseTwitterUtils/Internal/PFTwitterPrivateUtilities.m:9,11,13,15,22,23,28,29,31,33,36,41,43,44,48,49,54,57,58,63,66,67,70,71 ./ParseTwitterUtils/ParseTwitterUtils/Internal/PFTwitterAuthenticationProvider.h:9,11,13,16,18,20,22,24,28,30,35,37 ./ParseTwitterUtils/ParseTwitterUtils/Internal/OAuthCore/PF_OAuthCore.m:9,11,13,18,19,21,25,28,30,31,50,51,53,55,62,65,71,74,75,82,83,89,90,94,98,99,102,107,111,114,116,123,126,128,129,131,133,139,141,145,147,148,159,160,162,163,165,167,169,173,187,188,190,191 ./ParseTwitterUtils/ParseTwitterUtils/Internal/OAuthCore/PF_OAuthCore.h:9,11,13,15,19,22,25,27,30,33,42,44,46,48,50,52,54,56,58,60,62 ./ParseTwitterUtils/ParseTwitterUtils/Internal/PFTwitterLocalization.h:9,12,15 ./ParseTwitterUtils/ParseTwitterUtils/Internal/PFTwitterAlertView.m:9,11,13,15,17,19,23,33,42,43,46,50,55,56,61,62,72,75,76,80,81,84,88,89,90,92,96,103,104,105,106,108 ./ParseTwitterUtils/ParseTwitterUtils/Internal/Dialog/PFOAuth1FlowDialog.h:9,14,16,19,28,30,32,37,40,43,48,50,55,61,66,68,73,76,81,84,85,87 ./ParseTwitterUtils/ParseTwitterUtils/Internal/Dialog/PFOAuth1FlowDialog.m:9,13,15,18,21,23,26,28,35,37,39,47,48,56,57,80,82,83,86,89,99,101,102,103,106,108,112,114,115,128,131,133,134,136,137,141,144,146,149,151,154,156,158,161,164,167,169,172,174,175,178,186,188,197,206,211,220,222,224,225,231,233,234,237,238,241,244,246,247,250,253,256,257,260,263,270,275,283,288,290,293,294,297,300,301,304,306,307,310,314,316,321,325,327,331,336,343,347,348,350,351,354,362,368,374,375,376,380,381,384,388,390,391,394,395,398,401,402,405,408,409,412,427,428,431,438,439,440,441,442,445,446,449,453,455,456,457,460,464,465,466,469,483,484,495,496,499,508,509,510,514,515,520,521,527,528,543,544,546,547,551,555,557,559,562,566,568,569,572,575,580,581,587,594,596,598,599,600,603,606,612,619,621,623,624,625 ./ParseTwitterUtils/ParseTwitterUtils/Internal/PFTwitterPrivateUtilities.h:9,11,13,15,17,19,21,23,25,28,32,34 ./ParseTwitterUtils/ParseTwitterUtils/Internal/PFTwitterUtils_Private.h:9,11,13,15,18 ./ParseTwitterUtils/ParseTwitterUtils/Internal/PF_Twitter_Private.h:9,11,13,17,19,21,25,29,35,37 ./ParseTwitterUtils/ParseTwitterUtils/Internal/PFTwitterAuthenticationProvider.m:9,11,13,15,18,20,27,29,33,38,39,43,45,47,48,51,52,56,68,69,73,82,83,87,96,97,109,111,112 ./ParseTwitterUtils/ParseTwitterUtils/Internal/PFTwitterAlertView.h:9,11,13,15,21 ./ParseTwitterUtils/ParseTwitterUtils/PF_Twitter.h:9,11,13,15,17,23,27,32,37,42,47,52,57,62,66,70,74,78,82,90,94,96,100,102 ./ParseTwitterUtils/ParseTwitterUtils/ParseTwitterUtils.h:9 ./ParseTwitterUtils/ParseTwitterUtils/PFTwitterUtils.m:9,11,14,16,20,22,26,28,31,32,35,36,40,44,45,49,50,57,60,62,63,64,67,68,71,72,75,76,79,80,84,85,88,89,94,95,99,100,103,108,109,112,113,118,119,126,133,134,146,147,166,167,170,175,176,179,180,185,186,192,199,200,210,211,228,229 ./ParseTwitterUtils/Tests/Unit/TwitterUtilsTests.m:9,13,15,19,21,23,25,29,32,34,35,39,44,49,54,56,57,62,64,69,74,76,77,80,81 ./ParseTwitterUtils/Tests/Unit/OAuthCoreTests.m:9,11,14,16,19,20,23,24,26,28,31,33,35,39,42,43,46,47,50,54,60,61,65,68,71,72,76,89,91,92,105,107,108,121,124,125,131,144,148,149,150,153,166,167 ./ParseTwitterUtils/Tests/Unit/TwitterAuthenticationProviderTests.m:9,11,15,17,19,21,25,28,31,33,34,42,43,47,53,57,59,60,64,70,71,74,75,78,83,86,88,94,99,100,107,109,115,117,118,122,125,126,133,136,138,139 ./ParseTwitterUtils/Tests/Unit/TwitterTests.m:9,14,20,22,25,27,31,36,45,46,49,57,70,71,77,88,89,95,98,101,103,104,110,119,121,122,128,130,133,139,142,149,152,157,160,164,166,169,172,173,178,180,187,190,195,198,203,205,208,211,212,217,220,226,229,231,234,236,247,252,255,263,264,270,273,279,282,285,288,295,299,309,314,319,324,327,332,337,339,342,344,345,352,355,361,364,368,371,378,379,383,393,398,403,413,416,421,424,429,434,436,439,441,442,449,452,458,461,464,467,477,484,485,495,496,501,504,509,512,520,524,527,532,537,539,542,544,547,548,553,560,561,571,572,577,580,585,588,596,600,603,608,613,615,618,620,623,624,630,641,642,646,655,666,672,677,682,683 ./ParseTwitterUtils/Tests/Unit/OAuth1FlowDialogTests.m:9,13,15,17,19,26,28,31,34,35,38,39,41,44,46,50,54,60,65,66,72,73,76,80,81,85,91,95,97,98,100,105,107,110,114,117,121,124,126,127,132,135,144,146,148,151,155,160,162,166,170,175,177,181,185,190,192,193 ./ParseTwitterUtils/Tests/Other/TestCase/PFTwitterTestCase.h:9,11,13,15,19,22,26,29,33,35,37,41,47,53,59,65,68,71,74,77 ./ParseTwitterUtils/Tests/Other/TestCase/PFTwitterTestCase.m:9,11,15,16,20,23,26,27,32,35,37,38,42,47,48,51,52,56,61,62 ./ParseTwitterUtils/Tests/Other/PFTwitterTestMacros.h:9,12,25 ./ParseTwitterUtils/Tests/TestApplication/Classes/main.m:9,11,13,15,17,23,24,26,30,31 ./ParseStarterProject/watchOS/ParseStarterProject-Swift/ParseStarterProject/ViewController.swift:9,12,14,18,19,23,24 ./ParseStarterProject/watchOS/ParseStarterProject-Swift/ParseStarterProject/AppDelegate.swift:9,11,13,16,19,21,25,30,36,39,43,45,47,49,52,54,59,64,67,68,69,78,79,81,82,86,91,97,98,99,100,106,107,108,113,114,115,124,128,135 ./ParseStarterProject/watchOS/ParseStarterProject-Swift/ParseStarter Extension/InterfaceController.swift:9,13,15,18,20,21,25,26,30,31,32 ./ParseStarterProject/watchOS/ParseStarterProject-Swift/ParseStarter Extension/ExtensionDelegate.swift:9,12,14,19,25,28,32,34,37,38,41,42,46,47,48 ./ParseStarterProject/OSX/ParseOSXStarterProject-Swift/ParseOSXStarterProject/AppDelegate.swift:9,11,13,16,18,23,29,32,36,38,40,44,46,54,56,57,67,68,69,70,73,74,81 ./ParseStarterProject/OSX/ParseOSXStarterProject/ParseOSXStarterProject/AppDelegate.h:9,11,13,15,17 ./ParseStarterProject/OSX/ParseOSXStarterProject/ParseOSXStarterProject/main.m:9,11,13,15 ./ParseStarterProject/OSX/ParseOSXStarterProject/ParseOSXStarterProject/AppDelegate.m:9,11,13,15,18,23,27,30,33,38,40,42,45,47,57,59,60,62,67,73,75,76,80,81,84,85 ./ParseStarterProject/iOS/ParseStarterProject/ParseStarterProject/ParseStarterProjectAppDelegate.h:9,11,13,15,17,19 ./ParseStarterProject/iOS/ParseStarterProject/ParseStarterProject/ParseStarterProjectViewController.h:9,11,13 ./ParseStarterProject/iOS/ParseStarterProject/ParseStarterProject/ParseStarterProjectViewController.m:9,11,13,15,18,22,23,27,29,30,34,35 ./ParseStarterProject/iOS/ParseStarterProject/ParseStarterProject/ParseStarterProjectAppDelegate.m:9,11,14,17,20,22,25,30,34,37,40,45,51,53,55,58,60,62,65,74,75,76,89,90,92,93,95,100,106,108,109,116,117,118,121,124,125,126,135,137,147 ./ParseStarterProject/iOS/ParseStarterProject/ParseStarterProject/main.m:9,10,12,14,16,19,20 ./ParseStarterProject/iOS/ParseStarterProject-Swift/ParseStarterProject/ViewController.swift:9,12,14,18,19,23,24 ./ParseStarterProject/iOS/ParseStarterProject-Swift/ParseStarterProject/AppDelegate.swift:9,12,14,17,20,22,26,31,37,40,44,46,53,55,57,60,62,67,72,75,76,77,82,90,91,93,94,98,103,109,110,111,112,118,119,120,125,126,127,136,140,147 ./ParseStarterProject/tvOS/ParseStarterProject-Swift/ParseStarter/ViewController.swift:9,12,14,18,19,23,24,25 ./ParseStarterProject/tvOS/ParseStarterProject-Swift/ParseStarter/AppDelegate.swift:9,11,13,16,18,22,27,33,36,38,40,44,46,47,48 ./Parse/ParseUnitTests-iOS-host/AppDelegate.h:8,10,12,14,15,17 ./Parse/ParseUnitTests-iOS-host/ViewController.m:8,10,12,14,16,20,21,22,26,27,28 ./Parse/ParseUnitTests-iOS-host/main.m:8,11,15,16 ./Parse/ParseUnitTests-iOS-host/AppDelegate.m:8,10,12,14,16,17,21,22,23,27,28,29,33,34,35,38,39,40,43,44,45,48,49,50 ./Parse/ParseUnitTests-iOS-host/ViewController.h:8,10,12,13,15 ./Parse/Parse/PFFileObject.m:9,12,14,31,34,35,38,43,45,47,49,53,55,58,59,62,63,69,70,74,81,83,84,88,90,91,99,100,111,113,114,118,120,121,124,125,127,130,131,134,135,138,139,143,144,146,149,150,153,154,157,158,161,162,165,166,169,170,173,174,177,178,182,183,187,188,191,192,197,200,201,204,205,209,210,212,218,219,221,228,229,232,233,237,239,243,246,248,250,251,254,255,257,262,267,270,277,278,285,286,292,293,313,314,316,321,322,327,328,334,337,344,345,356,357,363,366,373,374,385,386,388,391,392,397,399,400,405,407,408,412,420,424,425,433,437,438,440,447,448,455,456,459,460,468,469,472,473,480,481,483,487,488,492,493,497,500,501,503,507,509,511,514,515,518,519,521,524,525,528,529,532,533,536,537,539,543,545,550,551,556,557 ./Parse/Parse/PFNetworkActivityIndicatorManager.m:9,11,14,16,19,20,22,24,26,28,31,35,44,45,49,52,61,63,64,68,69,73,81,82,89,90,93,94,98,106,107,115,116,120,126,141,142,143,144,148,149,150,154,157,158,161,162 ./Parse/Parse/PFFileUploadResult.h:8,10 ./Parse/Parse/PFProduct.m:9,12,15,17,24,28,33,34,37,38,42,47 ./Parse/Parse/PFFileObject+Synchronous.h:9,12,14,21,25,28,32,35,37,41,45,50,53,57,61,63,67,70,72,76,79,81,86,88 ./Parse/Parse/PFQuery.h:9,11,13,18,20,25,29,31,35,38,42,45,47,51,54,56,63,65,70,75,80,84,87,90,92,96,99,101,105,108,110,112,116,119,121,125,128,130,134,137,140,144,147,150,154,158,161,165,169,172,176,180,183,187,191,194,198,202,205,209,213,216,220,224,227,231,235,238,242,246,250,253,256,260,264,267,271,277,281,284,288,294,299,303,309,313,317,321,336,348,352,355,357,360,364,367,369,375,381,384,386,389,393,396,398,401,405,408,410,413,417,421,424,426,430,434,438,444,448,452,458,461,463,466,470,473,475,478,482,486,489,491,495,498,500,504,507,509,513,516,518,522,525,527,529,533,536,538,540,544,548,551,554,556,560,563,566,573,577,582,586,589,593,596,601,605,608,610,614,617,619,626,630,633,637,640,645,649,654,658,662,666,671,675,678,680,686,691,694,698,703,708,712,715,717,719,723,726,728,730,735,738,740,742,744,749,752,754,756,760,764,767,771,773 ./Parse/Parse/PFPurchase.h:9,12,14,17,19,21,25,28,32,35,40,45,48,53,56,58,64,67,69,77,80,83,88,91,93,97,99 ./Parse/Parse/ParseClientConfiguration.h:9,11,13,15,17,20,23,31,35,40,45,49,53,58,62,65,69,73,76,81,84,88,92,97,102,104,107,109,114,118,123,128,134,139,143,146,150,154,157,162,165,169,173,176,180,185,189,193,195,203,205,209,212,214 ./Parse/Parse/PFUserAuthenticationDelegate.h:9,11,13,15,20,24,26,28,33,35 ./Parse/Parse/PFEncoder.h:9,11,13,18,22,24,26,29,31,36,38,43,45,51,53,60,62,64 ./Parse/Parse/PFInstallation.m:9,12,33,37,38,40,42,56,57,61,62,69,70,75,76,79,80,87,88,89,92,93,97,100,101,105,113,114,118,121,122,124,126,133,137,140,141,144,145,149,152,153,156,157,161,166,167,169,170,174,179,182,183,185,186,190,192,193,200,201,206,207,210,211,214,215,220,221,224,225,230,231,234,235,239,251,252,255,256,259,260,264,272,273,274,275,282,283,284,292,293,294,295,301,313,314,315,323,326,329,332,333,334,337,342,349,352,353,359,360,365,366,367,371,374,375 ./Parse/Parse/PFRole.m:9,11,13,18,20,24,27,28,32,35,37,38,41,42,45,46,50,52,56,57,60,61,65,72,74,75,79,80,85,86,89,90 ./Parse/Parse/PFPush.h:9,11,13,16,18,20,22,25,30,34,36,40,43,48,51,56,59,61,65,68,70,74,77,79,81,85,88,90,94,97,99,103,106,111,113,117,120,126,130,135,138,140,144,148,151,155,159,162,170,173,176,181,184,194,200,203,208,211,213,217,221,224,226,236,239,241,245,250,253,255,265,269,273,277,279,283,287,290,292,297,300,304,311,314,317,321,324,331,334,336,340,343,349,351 ./Parse/Parse/PFRelation.m:9,12,14,22,26,39,40,42,44,46,48,52,55,57,58,62,65,67,68,72,74,76,77,81,84,88,89,92,94,95,98,99,102,103,106,107,111,114,115,118,119,122,126,127,130,137,138,142,149,156,157,159,160,163,164,169,170,174,177,181,182,186,189,193,194,202,204,205,211,212,219,223,225,226,231,232,237,238 ./Parse/Parse/PFAnalytics.h:9,11,13,15,17,20,26,30,35,37,41,45,50,52,61,66,71,75,80,89,93,96,98,100,104,109,115,119,122,124,129,131,134,139,144,147,153,155,164,166 ./Parse/Parse/PFObject.m:9,15,19,21,62,74,78,79,80,82,83,88,90,93,96,98,102,103,105,107,109,111,113,116,117,123,124,132,133,146,155,163,164,169,177,178,184,186,190,191,192,193,197,226,230,231,245,250,264,265,266,270,281,283,284,290,292,297,298,309,310,313,318,319,321,322,337,338,353,355,356,366,370,379,380,381,382,384,385,393,394,403,404,411,413,414,416,417,427,431,432,443,447,448,462,463,465,470,481,486,487,488,496,508,515,517,518,528,530,535,541,551,552,555,559,560,565,566,567,574,575,579,583,585,586,588,589,600,601,607,608,609,612,626,627,629,634,651,652,653,657,658,660,663,664,668,669,670,674,679,680,684,685,687,688,689,693,694,695,699,701,705,706,715,718,719,720,724,732,733,734,735,742,743,744,745,749,750,754,756,757,758,762,766,767,774,775,779,786,787,789,790,795,800,804,806,807,815,816,831,833,834,837,852,856,857,862,869,870,875,890,893,898,906,910,911,915,929,930,937,938,948,950,963,964,966,969,970,974,976,985,1003,1004,1011,1012,1014,1015,1018,1020,1023,1024,1025,1037,1041,1042,1044,1045,1050,1054,1055,1057,1061,1062,1065,1069,1073,1077,1078,1083,1084,1092,1095,1099,1106,1107,1110,1111,1112,1116,1119,1133,1134,1135,1141,1142,1164,1165,1166,1174,1175,1178,1179,1185,1186,1187,1196,1197,1206,1207,1211,1221,1222,1223,1231,1236,1237,1238,1245,1246,1247,1249,1250,1257,1258,1259,1266,1267,1268,1277,1278,1279,1284,1285,1286,1292,1293,1300,1302,1305,1306,1307,1313,1315,1316,1317,1323,1328,1329,1330,1334,1336,1339,1348,1351,1352,1353,1354,1360,1371,1379,1385,1389,1393,1394,1396,1397,1398,1402,1405,1408,1414,1417,1423,1424,1429,1431,1433,1434,1438,1442,1443,1444,1450,1456,1462,1463,1465,1468,1474,1479,1494,1498,1501,1502,1511,1512,1521,1522,1526,1534,1540,1541,1546,1547,1548,1549,1552,1553,1557,1562,1568,1569,1570,1575,1576,1579,1580,1581,1585,1588,1589,1592,1593,1598,1600,1601,1602,1607,1609,1610,1611,1615,1616,1617,1624,1625,1626,1627,1630,1631,1637,1644,1645,1649,1650,1652,1654,1656,1660,1664,1672,1674,1682,1686,1687,1689,1690,1694,1695,1699,1700,1710,1712,1713,1716,1717,1725,1726,1734,1735,1736,1739,1740,1742,1749,1750,1755,1756,1758,1763,1764,1768,1770,1775,1776,1780,1786,1788,1789,1792,1793,1796,1797,1799,1802,1803,1807,1813,1814,1818,1819,1820,1821,1825,1826,1827,1831,1832,1833,1839,1840,1842,1847,1849,1850,1851,1854,1855,1862,1866,1867,1868,1869,1872,1873,1876,1877,1880,1881,1884,1885,1891,1892,1893,1897,1900,1904,1910,1911,1917,1918,1924,1925,1930,1934,1935,1936,1940,1945,1946,1949,1950,1954,1959,1960,1963,1964,1971,1972,1975,1976,1985,1988,1998,2002,2009,2010,2014,2017,2018,2022,2023,2024,2028,2031,2032,2035,2036,2039,2040,2043,2044,2050,2054,2055,2058,2059,2063,2065,2066,2069,2070,2074,2078,2081,2091,2092,2095,2096,2101,2111,2112,2115,2116,2120,2123,2124,2129,2130,2134,2137,2138,2141,2142,2147,2155,2156,2157,2162,2163,2165,2166,2167,2170,2171,2177,2178,2179,2180,2185,2190,2191,2192,2195,2197,2198,2199,2200,2207,2208,2209,2210,2212,2215,2216,2222,2226,2228,2229,2230,2232,2235,2236,2239,2240,2243,2244,2247,2248,2251,2252,2255,2256,2258,2261,2262,2265,2266,2270,2273,2274,2277,2278,2285,2286,2290,2294,2295,2296,2299,2303,2308,2309,2314,2315,2316,2321,2322,2323,2327,2335,2336,2339,2340,2344,2349,2352,2359,2369,2370,2373,2374,2378,2391,2392,2396,2397,2402,2403,2406,2408,2409,2414,2415,2416,2420,2423,2424,2427,2428,2431,2432,2435,2436,2439,2440,2444,2447,2448,2452,2453,2456,2457,2462,2463,2468,2469,2473,2476,2477,2480,2481,2484,2485,2488,2489,2493,2496,2497,2500,2501,2504,2505,2508,2509,2512,2513,2516,2517,2520,2521,2524,2525,2529,2532,2533,2536,2537,2540,2541,2544,2545,2548,2549,2552,2553,2555,2559,2561,2563,2566,2567,2570,2571,2573,2576,2577,2580,2581,2583,2586,2587,2590,2591,2594,2595,2598,2599,2601,2604,2605,2608,2609,2612,2613,2616,2617,2619,2622,2623,2626,2627,2629,2632,2633,2636,2637,2639,2642,2643,2646,2647,2649,2652,2653,2656,2657,2660,2661,2664,2665,2667,2670,2671,2674,2675,2678,2679,2682,2683,2685,2688,2689,2692,2693,2696,2697,2700,2701,2703,2706,2707,2710,2711,2714,2715,2718,2719,2722,2723,2726,2727,2730,2731,2734,2735,2737,2741,2743,2745,2750,2751,2753,2758,2759,2761,2764,2765,2770,2771,2776,2777,2779,2784,2785,2790,2791,2793,2798,2799,2801,2806,2807 ./Parse/Parse/PFConstants.h:9,11,15,17,21,23,27,30,34,36,71,75,78,113,117,122,125,352,356,359,372,376,381,386,391,397,403,409,410,414,426,430,446,450,458,462,472,476,480,488,496,504,512,520,528,536,544 ./Parse/Parse/PFSession.h:9,11,13,16,18,20,22,29,34,37,41,44,49,51 ./Parse/Parse/PFPolygon.m:9,12,14,20,22,26,31,32,33,37,41,44,47,61,63,64,66,67,79,80,83,84,94,95,96,98,99,103,106,112,113,116,117,121,124,126,128,129,133,137,138,141,142,144,146,147,153,154,158,162,163,167,173,174,180,181 ./Parse/Parse/PFGeoPoint.m:9,12,14,20,23,25,29,32,33,37,38,44,45,49,50,56,57,61,66,67,72,73,88,89,92,93,96,97,101,105,112,113,116,117,121,124,127,130,132,133,137,141,142,145,146,148,151,152,155,156,163,164,168,172,173,177,184,185,191,192 ./Parse/Parse/PFAnonymousUtils.h:9,11,13,16,18,22,38,42,45,49,52,57,61,64,66,70,72 ./Parse/Parse/PFConfig.h:9,11,13,15,17,19,21,27,31,34,36,40,43,45,49,53,56,60,63,68,72,75,77,81,84,87,89,91,95,97 ./Parse/Parse/PFUser+Deprecated.h:9,12,14,19,23,26,28,30,36,41,45,48,51,57,64,68,71,74,79,85,89,92,95,102,108,110 ./Parse/Parse/PFQuery+Deprecated.h:9,12,14,19,23,26,28,34,40,44,47,52,57,61,64,66,72,77,81,84,88,93,95 ./Parse/Parse/PFPush+Deprecated.h:9,12,14,19,23,26,35,42,45,51,56,59,61,70,77,81,84,89,94,97,105,111,114,121,127,129 ./Parse/Parse/PFACL.m:9,12,26,30,32,34,36,39,40,44,48,50,52,53,57,60,61,67,68,71,72,76,77,83,84,89,90,93,94,100,102,103,107,110,117,120,121,124,125,128,132,133,139,140,146,148,149,152,153,157,165,167,168,172,173,177,178,182,183,187,188,191,192,195,196,199,200,203,204,208,209,213,214,218,219,223,224,228,229,233,234,238,239,243,244,248,249,258,260,268,272,273,274,278,279,286,288,290,291,295,299,300,304,305,312,314,316,317,321,325,326,329,330,334,338,341,342,346,347,350,351,355,358,359,363,367,368,371,372 ./Parse/Parse/PFCloud.h:9,11,13,15,17,22,25,28,33,37,46,48 ./Parse/Parse/Parse.h:9,11,47,49,57,59,64,66,71,73,75,80,84,87,92,95,97,101,104,108,118,123,125,130,132,137,141,147,150,154,158,161,164,166,170,173,176,179,185,188,192,195,199,201,205,208,211,215,219,221,225,227,231,234,238,243,245,249,254 ./Parse/Parse/PFConfig+Synchronous.h:9,12,14,21,25,28,32,35,37,41,43 ./Parse/Parse/PFObject+Synchronous.h:9,12,14,21,25,28,32,35,37,41,45,48,50,54,57,60,64,68,75,79,84,87,91,95,98,102,106,112,118,122,128,132,138,142,145,149,153,156,160,163,165,169,173,176,178,182,185,188,192,196,200,205,207,212,216,221,223,225,230,233,238,240,242,246,249,254,257,259,263,267,271,276,278,280,285,289,294,297,299,304,307,312,315,317,321,324,329,333,335,339,343,347,349,354,358,360,362,367,370,372,374,378,381,384,386,390,394,398,400,404,408,410,412,416,419,421,425,428,431,435,439,441,443,448,452,455,457,462,465,468,470,474,477,481,483,487,489 ./Parse/Parse/PFUser.h:9,11,13,17,19,22,25,30,34,36,40,43,47,50,54,57,61,64,68,71,76,80,83,87,90,94,99,104,107,112,117,120,122,124,128,131,133,135,140,144,147,150,153,157,160,163,170,174,177,180,182,186,189,192,198,202,205,209,214,217,221,225,229,232,236,240,243,247,251,255,264,267,270,276,280,283,286,291,294,297,300,305,308,311,314,319,322,325,327,331,334,337,339,343,345 ./Parse/Parse/Internal/PFJSONSerialization.h:9,11,13,15,23,27,35,39,45,51,54,56,58,62,64 ./Parse/Parse/Internal/PFBaseState.h:9,11,20,22,24,26,29,31,33,36,39,43,45,51,54,56,59,63,65,69,73,75 ./Parse/Parse/Internal/ParseManagerPrivate.h:9,11,13,15 ./Parse/Parse/Internal/PFFileManager.m:9,11,13,18,20,27,28,35,36,38,41,43,45,49,52,53,59,60,69,72,73,78,79,92,93,94,98,102,103,110,113,114,118,124,127,128,134,135,144,150,151,163,167,170,171,175,177,183,184,191,195,201,202,205,206,211,219,221,222,225,228,229,233,235,240,243,245,246,248,265,267,272,274,275,287,290,291,294,295,307,308,312,317,318,320,326,327,329,330 ./Parse/Parse/Internal/PFHash.h:9,11,13,15,17,19 ./Parse/Parse/Internal/PFDateFormatter.h:9,11,13,15,17,21,24,26,30,34,37,46,48,52,54 ./Parse/Parse/Internal/PFBase64Encoder.m:9,11,13,17,19,20,24,26,27 ./Parse/Parse/Internal/ParseModule.h:9,12,14,16,18,20,22,24,27,29,31 ./Parse/Parse/Internal/Relation/State/PFRelationState_Private.h:9,11,13,16,18,22,30,31,38 ./Parse/Parse/Internal/Relation/State/PFRelationState.m:9,12,14,16,20,28,29,33,37,39,41,42,45,46,49,50,54,57,58,61,62 ./Parse/Parse/Internal/Relation/State/PFMutableRelationState.m:9,11,14,16,23,27,30,32,34,35,39,43,45,47,48,52,59,60,61 ./Parse/Parse/Internal/Relation/State/PFMutableRelationState.h:9,11,13,18 ./Parse/Parse/Internal/Relation/State/PFRelationState.h:9,11,13,15,22,26,29 ./Parse/Parse/Internal/Relation/PFRelationPrivate.h:9,11,13,15,17,26 ./Parse/Parse/Internal/PFAlertView.m:9,11,13,15,17,19,23,33,42,43,46,50,55,56,61,62,72,75,76,80,81,84,88,89,90,92,96,103,104,105,106,108 ./Parse/Parse/Internal/BFTask+Private.h:9,11,14,16,18,20,22,24,27,30,33,38,48,55,60,64,67,71,73 ./Parse/Parse/Internal/PFInternalUtils.m:9,11,14,16,38,42,44,46,50,51,52,55,56,62,63,70,75,77,78,82,83,88,89,93,96,123,124,127,128,132,134,139,140,142,156,157,158,161,165,168,170,171,173,174,180,182,183,186,187,190,191,197,199,202,203,211,220,223,224,226,227,232,233,237,238,241,244,247,249,250,252,253,261,264,265 ./Parse/Parse/Internal/PFNetworkCommand.h:9,11,13,17,20,24,28,31,33,37,46 ./Parse/Parse/Internal/PFDevice.h:9,11,13,15,19,21,23 ./Parse/Parse/Internal/PFSystemLogger.h:9,11,13,15,17,19,23,26,30,34,38,46 ./Parse/Parse/Internal/PFLocationManager.m:9,11,13,17,19,23,28,30,32,36,39,48,50,51,55,59,60,65,66,72,78,80,81,85,88,89,93,97,98,111,124,130,131,136,137,141,144,146,151,154,155,156,159,164,167,168,169 ./Parse/Parse/Internal/PFPinningEventuallyQueue.m:9,11,14,26,33,39,45,50,55,56,58,60,64,71,72,78,80,87,90,92,93,97,100,106,109,110,115,124,125,128,133,135,136,140,143,144,147,154,158,159,163,174,180,181,187,189,190,199,200,215,218,219,226,227,231,236,244,248,249,252,259,260,269,270,272,278,282,289,291,292,296,303,308,309,315,318,319,323,324 ./Parse/Parse/Internal/PFCategoryLoader.h:9,11,13,15 ./Parse/Parse/Internal/File/FileDataStream/PFFileDataStream.m:9,11,14,18,21,23,24,26,28,31,35,37,38,41,43,44,48,51,52,55,56,60,61,65,68,69,72,73,77,78,82,83,88,90,91,96,97,99,100,104,109,110,111 ./Parse/Parse/Internal/File/FileDataStream/PFFileDataStream.h:9,11,13,16,19,24,26,28,30 ./Parse/Parse/Internal/File/State/PFMutableFileState.m:9,11,13,15,19,21 ./Parse/Parse/Internal/File/State/PFFileState.h:9,11,13,15,17,21,23,27,32,34 ./Parse/Parse/Internal/File/State/PFMutableFileState.h:9,11,13,15,19,21 ./Parse/Parse/Internal/File/State/PFFileState_Private.h:9,11,13,16,18,22,24,26,30,32 ./Parse/Parse/Internal/File/State/PFFileState.m:9,12,15,17,19,21,23,27,32,33,37,40,41,47,51,53,54,58,63,64,65,69,70,73,74,78,79,83,84,87,90,91,95,98,99,102,103,105 ./Parse/Parse/Internal/File/Controller/PFFileController.m:9,11,14,29,31,37,38,40,42,44,48,52,54,59,61,62,65,66,70,76,80,81,85,91,96,97,102,107,118,131,134,135,147,150,157,158,165,166,178,180,183,184,188,189,197,199,200,203,204,208,216,221,222,223,257,258,259,263,268,269,273,274,278,279,282,283,289,293,294,300,303,304 ./Parse/Parse/Internal/File/Controller/PFFileStagingController.m:9,11,18,20,23,24,28,32,35,37,39,40,43,44,48,51,52,56,64,65,73,74,78,79,83,89,90 ./Parse/Parse/Internal/File/Controller/PFFileUploadResult.m:8,10,12 ./Parse/Parse/Internal/File/Controller/PFFileController.h:9,11,13,16,22,24,26,28,30,34,37,39,41,45,48,52,58,61,65,71,75,78,84,92,96,99,101 ./Parse/Parse/Internal/File/Controller/PFFileStagingController.h:9,11,13,15,17,19,21,23,25,29,32,34,36,40,43,47,51,55,59,63,66,69,73,75 ./Parse/Parse/Internal/File/PFFileObject_Private.h:9,11,14,16,18,20,22,24,26,28 ./Parse/Parse/Internal/PFDataProvider.h:9,12,14,16,18,20,22,24,26,28,30,32,34,36,38,40,42,45,47,49,51,53,55,57,59,61,63,65,67,69,71,73,75,77,79,81,83,85,87,89,91,93,95,97 ./Parse/Parse/Internal/ParseClientConfiguration_Private.h:9,11,13,15,17,21,23,25,29,31,34,36,38,43 ./Parse/Parse/Internal/PFReachability.h:9,11,13,15,17,19,25,27,29,31,33,35,38,40,46,52,57,62,64 ./Parse/Parse/Internal/Config/PFConfig_Private.h:9,11,13,15,17,19,21 ./Parse/Parse/Internal/Config/Controller/PFConfigController.h:9,11,13,15,19,21,23,25,29,32,34,38,41,43,47 ./Parse/Parse/Internal/Config/Controller/PFCurrentConfigController.h:9,11,13,15,18,20,22,26,29,31,33,37,40,43 ./Parse/Parse/Internal/Config/Controller/PFConfigController.m:9,11,20,25,26,28,30,32,36,40,42,44,47,49,50,54,71,72,76,82,86,87 ./Parse/Parse/Internal/Config/Controller/PFCurrentConfigController.m:9,11,19,21,25,26,28,30,32,36,40,42,44,46,47,50,51,55,63,66,67,73,79,85,86,96,97,103,104,108,118,119,122,123,127,130,131 ./Parse/Parse/Internal/PFMemoryEventuallyQueue.m:9,12,15,19,22,23,25,27,31,38,39,45,48,51,53,54,58,61,66,67,71,74,75,82,83,90,91,98,99,106,107,110,111 ./Parse/Parse/Internal/PFGeoPointPrivate.h:9,11,13,16,18,20,22,27,32 ./Parse/Parse/Internal/PFTaskQueue.m:9,11,13,15,18,20,22,26,28,30,31,35,40,45,47,48,49 ./Parse/Parse/Internal/PFWeakValue.m:9,11,13,15,17,19,24,25 ./Parse/Parse/Internal/PFErrorUtilities.h:9,11,13,15,18,21,24,29,32,35,37,42,44 ./Parse/Parse/Internal/PropertyInfo/PFPropertyInfo_Runtime.m:9,11,14,16,22,25,27,30,35,37,40,43,47,52,56,59,60,63,66,67,73,76,77,78,79,83,86,88,93,97,98,102,103,107,112,113,116,120,121,122,124 ./Parse/Parse/Internal/PropertyInfo/PFPropertyInfo.h:9,11,13,15,17,20,23,27,30,34,37,46,49,51 ./Parse/Parse/Internal/PropertyInfo/PFPropertyInfo_Private.h:9,11,13,15,18,21,24 ./Parse/Parse/Internal/PropertyInfo/PFPropertyInfo_Runtime.h:9,11,13,20,22,29,36,38 ./Parse/Parse/Internal/PropertyInfo/PFPropertyInfo.m:9,11,13,17,22,28,29,34,35,37,41,44,45,50,54,56,60,69,72,74,75,77,81,84,87,90,95,96,99,100,105,114,115,116,118,119,122,123,127,128,132,136,137,139,140,145,146,148,149,153,158,160,161,164,167,169,174,177,178,181,183,184,188,191,192,196,197,200,201,203,208,209 ./Parse/Parse/Internal/PFCommandCache.m:9,11,14,17,33,35,38,41,42,44,46,48,50,54,68,69,78,83,85,87,88,92,95,97,100,104,105,107,109,110,114,118,119,123,131,132,138,140,141,144,149,151,159,161,162,174,178,181,182,184,185,190,191,203,204,212,213,214,215,216,219,220,224,225,229,233,235,237,249,253,254,255,256,258,265,268,270,271,272,275,276,279,280,284,290,291,295,309,310,313,314,324,325,335,336,339,340,343,344 ./Parse/Parse/Internal/PFEventuallyQueue.h:9,11,13,16,21,24,26,28,31,33,40,44,47,51,55,58,62,68 ./Parse/Parse/Internal/PFCoreManager.h:9,11,14,16,18,27,29,31,40,58,60,66,70,73,75,77,81,83,85 ./Parse/Parse/Internal/FieldOperation/PFFieldOperationDecoder.h:9,11,14,16,18,22,24,28,31,36,38 ./Parse/Parse/Internal/FieldOperation/PFFieldOperation.h:9,11,13,16,20,28,32,37,46,51,56,59,62,66,68,72,78,80,84,86,91,93,95,99,104,106,110,112,116,121,123,125,127,133,135,137,139,145,147,149,151,155,160,164,167 ./Parse/Parse/Internal/FieldOperation/PFFieldOperationDecoder.m:9,11,15,18,19,21,23,25,29,33,36,38,39,47,48,52,55,56,69,71,74,84,88,93,98,103,108,113,114,118,124,125 ./Parse/Parse/Internal/FieldOperation/PFFieldOperation.m:9,11,19,23,26,30,31,35,36,40,41,43,47,49,52,53,57,60,62,63,66,67,70,71,74,75,78,79,82,83,85,87,90,91,94,95,98,99,102,103,106,107,109,113,115,118,119,123,125,127,128,131,132,135,136,140,141,155,158,159,163,164,167,168,170,174,176,180,182,184,185,188,189,192,193,199,200,214,219,222,223,229,232,233,235,237,241,243,245,246,249,250,253,254,260,261,274,278,281,282,300,303,304,306,309,310,312,314,317,319,321,322,325,326,329,330,336,337,351,355,356,359,360,367,380,381,382,384,387,388,390,394,397,401,404,406,407,412,413,418,419,421,422,427,428,433,434,436,437,443,444,451,453,454,462,465,470,473,474,478,479,482,483,486,489,490,494,495,498,500,504,510,514,518,519,523,527,529,530,544,545,549,550,553,556,557,559,560 ./Parse/Parse/Internal/PFApplication.m:9,11,19,21,23,27,35,36,46,48,50,51,55,60,62,63,66,67,79,80,82,87,88,91,92,100,106,110,111,112,117,118,120,128,129,134,136,137 ./Parse/Parse/Internal/PFKeychainStore.m:9,11,16,18,21,22,25,27,29,33,38,40,45,47,49,50,54,58,61,65,67,68,72,78,83,86,87,89,91,92,95,96,99,103,108,122,124,129,130,133,134,137,138,142,143,145,146,150,153,156,157,161,162,165,167,175,177,181,182,184,185,188,189,196,197,202,205,206,211,218,219,225,226,229,230 ./Parse/Parse/Internal/PFCommandResult.h:9,11,13,15,19,23,26,33,35 ./Parse/Parse/Internal/User/PFUserPrivate.h:9,11,13,15,19,23,25,31,33,35,37,42,48,50,52,55,58,65,67,69,73,75 ./Parse/Parse/Internal/User/Constants/PFUserConstants.m:9,11 ./Parse/Parse/Internal/User/Constants/PFUserConstants.h:9,11 ./Parse/Parse/Internal/User/State/PFUserState.h:9,11,13,15,17,20,22,26,30,34,36 ./Parse/Parse/Internal/User/State/PFMutableUserState.m:9,11,13,15,19 ./Parse/Parse/Internal/User/State/PFUserState_Private.h:9,11,16,18,19,22,24 ./Parse/Parse/Internal/User/State/PFUserState.m:9,13,17,19,23,27,31,33,34,38,40,42,43,46,47,51,58,59,63,66,67,71,74,75,79,82,83 ./Parse/Parse/Internal/User/State/PFMutableUserState.h:9,11,13,16,18 ./Parse/Parse/Internal/User/Controller/PFUserController.m:11,21,23,27,32,35,37,38,43,44,48,62,67,68,78,79,97,102,103,107,114,115,140,142,143,147,158,159,163,174,175 ./Parse/Parse/Internal/User/Controller/PFUserController.h:9,11,15,17,19,22,26,32,36,41,46,50,52,56,58,60 ./Parse/Parse/Internal/User/CurrentUserController/PFCurrentUserController.h:9,11,13,18,21,25,27,30,32,36,39,46,50,52,54,58,60 ./Parse/Parse/Internal/User/CurrentUserController/PFCurrentUserController.m:9,11,13,25,29,32,33,35,37,39,43,49,52,56,58,59,66,67,71,76,78,79,85,86,90,95,96,107,108,112,114,115,123,135,139,140,147,154,159,169,170,175,181,182,185,190,191,193,204,205,209,218,226,227,235,242,249,250,259,260,266,267,271,278,282,283,285,291,294,295,298,299,306,309,310,312,315,316,319,320,324,330,331,335,339,348,349,356,357 ./Parse/Parse/Internal/User/Coder/File/PFUserFileCodingLogic.h:9,11,13,15,17 ./Parse/Parse/Internal/User/Coder/File/PFUserFileCodingLogic.m:9,11,17,19,21,23,27,30,36,37,53,55,56,58,59 ./Parse/Parse/Internal/User/AuthenticationProviders/Providers/Anonymous/PFAnonymousAuthenticationProvider.m:9,11,13,15,17,21,24,25,29,34,35 ./Parse/Parse/Internal/User/AuthenticationProviders/Providers/Anonymous/PFAnonymousAuthenticationProvider.h:9,11,13,15,17,19,24,26 ./Parse/Parse/Internal/User/AuthenticationProviders/Providers/Anonymous/PFAnonymousUtils_Private.h:9,11,14,16,19,21 ./Parse/Parse/Internal/User/AuthenticationProviders/Controller/PFUserAuthenticationController.h:9,11,14,16,18,21,23,25,29,32,34,38,41,43,47,51,55,58,60 ./Parse/Parse/Internal/User/AuthenticationProviders/Controller/PFUserAuthenticationController.m:9,11,21,25,26,28,30,34,38,42,44,45,48,49,53,63,70,71,75,79,80,84,85,91,92,96,102,106,107,110,111,115,126,129,132,134,141,156,157,160,161,166,167 ./Parse/Parse/Internal/PFMulticastDelegate.h:9,11,16,19,27 ./Parse/Parse/Internal/PFEventuallyPin.m:9,11,13,22,24,32,34,38,41,42,47,48,51,52,56,59,60,63,64,67,68,71,72,75,76,81,83,84,88,91,92,99,106,107,110,111,116,119,120,124,129,130,131,136,137,141,154,157,160,163,164,175,176,187,188,190,191 ./Parse/Parse/Internal/ParseInternal.h:9,11,13,25,27,31 ./Parse/Parse/Internal/Installation/PFInstallationPrivate.h:9,11,13,15,17,20,22,24,29 ./Parse/Parse/Internal/Installation/InstallationIdentifierStore/PFInstallationIdentifierStore.m:9,11,21,23,26,27,29,31,33,35,39,43,46,48,49,53,58,61,62,75,76,82,83,87,101,102,114,115,118,119 ./Parse/Parse/Internal/Installation/InstallationIdentifierStore/PFInstallationIdentifierStore_Private.h:9,11,13,18 ./Parse/Parse/Internal/Installation/InstallationIdentifierStore/PFInstallationIdentifierStore.h:9,11,13,15,17,19,21,25,28,30,34,39,43,48 ./Parse/Parse/Internal/Installation/CurrentInstallationController/PFCurrentInstallationController.m:9,11,21,24,28,29,32,35,37,39,41,44,48,54,57,61,63,64,71,72,76,84,85,95,96,99,103,119,120,126,127,138,139,142,146,149,155,156,160,163,164,169,174,179,180,183,186,187,192,195,196,200,206,214,215,220,221,224,225,234,235,238,239,243,246,247,250,251,258,259,264,266,267,274,275,280,281 ./Parse/Parse/Internal/Installation/CurrentInstallationController/PFCurrentInstallationController.h:9,11,13,18,20,23,26,28,31,35,40,44,48,50,53 ./Parse/Parse/Internal/Installation/Constants/PFInstallationConstants.h:9,11 ./Parse/Parse/Internal/Installation/Constants/PFInstallationConstants.m:9,11 ./Parse/Parse/Internal/Installation/Controller/PFInstallationController.m:9,11,18,20,24,28,30,32,33,36,37,41,48,52,53,61,62,69,70,79,80,84,88,89,93,94,98,101,102,105,106 ./Parse/Parse/Internal/Installation/Controller/PFInstallationController.h:9,11,14,16,18,20,22,26,30,32 ./Parse/Parse/Internal/Product/PFProduct+Private.h:9,11,17,23,24,30,35,40,45 ./Parse/Parse/Internal/Product/ProductsRequestHandler/PFProductsRequestHandler.m:9,11,14,16,20,23,25,26,28,30,33,35,37,41,45,47,50,52,53,57,61,62,66,70,72,73,77,80,83,84,88,90,91,95,96 ./Parse/Parse/Internal/Product/ProductsRequestHandler/PFProductsRequestHandler.h:9,12,14,17,19,21,24,26,28,35,37,39 ./Parse/Parse/Internal/ParseManager.m:9,11,13,31,36,41,45,47,49,61,63,64,66,68,85,89,93,107,109,111,112,116,119,124,125,126,130,136,137,142,143,150,151,154,155,159,166,171,183,186,187,192,193,201,202,211,212,216,218,226,230,231,233,240,244,245,247,253,257,258,263,270,271,278,279,282,294,295,297,303,307,308,310,314,315,325,329,330,332,339,343,344,346,352,356,357,362,363,365,367,373,377,378,383,384,386,388,394,398,399,404,406,407,409,411,417,421,422,427,428,430,434,439,449,452,453,457,464,465,481,482,484,485 ./Parse/Parse/Internal/PFAsyncTaskQueue.h:9,11,13,15,17,19,21,23 ./Parse/Parse/Internal/HTTPRequest/PFHTTPURLRequestConstructor.m:9,11,15,17,19,23,30,32,35,40,42,48,50,51 ./Parse/Parse/Internal/HTTPRequest/PFURLConstructor.h:9,11,13,15,19,21 ./Parse/Parse/Internal/HTTPRequest/PFHTTPRequest.h:9,12,14,20,23 ./Parse/Parse/Internal/HTTPRequest/PFURLConstructor.m:9,11,13,15,19,32,34,37,39,40 ./Parse/Parse/Internal/HTTPRequest/PFHTTPURLRequestConstructor.h:9,11,13,18 ./Parse/Parse/Internal/PFBase64Encoder.h:9,11,13,16 ./Parse/Parse/Internal/PFPolygonPrivate.h:9,11,13,15,17,19,24,29 ./Parse/Parse/Internal/PFDateFormatter.m:9,11,14,17,21,22,24,26,30,38,39,43,45,58,60,61,66,67,71,77,81,82,86,87,91,97,100,104,105,112,114,115 ./Parse/Parse/Internal/LocalDataStore/Pin/PFPin.h:9,11,14,17,22,25,29,32 ./Parse/Parse/Internal/LocalDataStore/Pin/PFPin.m:9,11,19,22,24,28,31,32,37,38,41,42,46,50,53,55,56,59,60,64,67,68,71,72,75,76,79,80 ./Parse/Parse/Internal/LocalDataStore/SQLite/PFSQLiteStatement.h:9,11,13,18,20,23,25,28,30 ./Parse/Parse/Internal/LocalDataStore/SQLite/PFSQLiteDatabaseResult.h:9,11,13,15,17,19,25,31,36,40,43,46,49,52,55,58,61,64,67,69 ./Parse/Parse/Internal/LocalDataStore/SQLite/PFSQLiteDatabase.m:9,12,14,17,27,31,34,39,45,46,51,56,58,60,64,68,71,81,83,85,86,89,90,94,99,100,108,109,116,117,120,125,126,130,131,139,140,143,145,147,153,156,157,161,165,166,170,171,175,176,180,190,192,195,198,199,206,207,213,214,217,218,221,222,227,228,239,240,249,253,260,263,264,267,268,282,291,294,295,296,300,304,305,307,308,311,312,315,316,320,327,328,333,334,345,346,350,353,354 ./Parse/Parse/Internal/LocalDataStore/SQLite/PFSQLiteDatabaseController.h:9,11,13,17,19,21,23,27,30,33,37,41,43,48,50 ./Parse/Parse/Internal/LocalDataStore/SQLite/PFSQLiteDatabase_Private.h:9,11,13,15,17,19 ./Parse/Parse/Internal/LocalDataStore/SQLite/PFSQLiteStatement.m:9,11,13,15,17,21,24,26,27,30,31,36,37,40,43,44,49,50,54,55 ./Parse/Parse/Internal/LocalDataStore/SQLite/PFSQLiteDatabaseResult.m:9,11,13,16,18,22,24,26,28,33,35,36,39,40,45,46,49,50,53,54,59,60,63,64,69,70,73,74,79,80,83,84,89,90,93,94,99,100,104,107,108,111,112,116,117,120,121,126,127,132,135,136,139,140,153,155,156,159,160,165,166,171,174,175,184,187,189,190 ./Parse/Parse/Internal/LocalDataStore/SQLite/PFSQLiteDatabaseController.m:9,11,14,19,22,23,27,31,34,36,37,40,41,45,57,62,63,66,69,71,72 ./Parse/Parse/Internal/LocalDataStore/SQLite/PFSQLiteDatabase.h:9,11,13,15,19,21,26,31,36,41,43,45,49,51,55,57,61,66,71,76,80,85,90,95,99,104,109,114,116 ./Parse/Parse/Internal/LocalDataStore/OfflineQueryLogic/PFOfflineQueryLogic.h:9,11,13,15,22,24,30,32,38,43,48,55,58,64,71,78 ./Parse/Parse/Internal/LocalDataStore/OfflineQueryLogic/PFOfflineQueryLogic.m:9,11,14,28,31,36,40,42,44,48,53,54,56,57,61,70,75,76,78,80,82,84,86,90,94,96,97,101,105,106,112,118,128,129,131,133,134,137,140,150,159,160,161,165,175,176,178,179,190,191,192,196,210,211,214,215,218,219,226,227,236,240,241,250,254,255,264,268,269,278,282,283,292,293,295,299,300,302,303,310,311,318,322,323,325,326,335,336,339,340,343,347,350,353,356,357,364,365,373,374,376,377,386,389,393,394,405,413,418,419,460,464,465,479,480,493,494,512,513,516,517,530,531,557,558,559,568,569,577,580,583,584,602,625,627,635,644,646,649,650,654,660,661,670,672,673,683,687,688,691,697,698,711,718,719,723,727,728,732,735,738,739,742,743,747,748,752,755,758,759,762,763,767,773,778,781,782,786,793,794,798,804,805,810,811,812,814,815,823,825,834,835,837,841,842,847,852,853,854,861,862,865,875,876,879,880,881,882,885,886,899,901,902,914,916,917 ./Parse/Parse/Internal/LocalDataStore/OfflineStore/PFOfflineStore.m:9,11,13,32,34,36,43,46,48,50,52,54,61,68,75,82,84,86,88,90,92,96,100,111,113,115,116,120,131,132,136,145,146,153,156,161,175,183,187,196,199,201,202,213,222,223,234,237,238,245,251,261,264,271,281,284,285,289,295,296,301,302,313,316,318,319,331,332,333,338,339,347,348,356,360,361,364,365,372,373,381,397,407,408,419,420,424,429,430,441,444,445,459,460,469,472,478,491,498,506,509,510,518,523,538,543,546,549,554,556,560,564,569,574,575,579,582,590,591,597,599,600,605,606,614,615,616,621,635,648,649,652,655,656,660,665,666,669,677,678,679,684,696,702,709,713,714,718,720,724,725,728,746,748,751,752,756,764,767,768,773,774,777,792,810,811,812,815,816,820,821,830,831,835,841,842,846,851,857,858,862,867,868,880,882,883,885,891,901,902,903,911,917,918,921,926,927,939,940,941,959,964,967,968,978,984,985,986,988,989,991,995,1003,1004,1006,1007,1018,1020,1024,1025,1028,1041,1044,1045,1046,1048,1052,1053,1071,1072,1083,1084,1098,1099,1103,1114,1115,1123,1124,1128,1133,1135,1136,1137,1141,1148,1149,1150,1155,1158,1159 ./Parse/Parse/Internal/LocalDataStore/OfflineStore/PFOfflineStore.h:9,11,13,15,23,27,30,33,37,41,45,47,52,57,61,65,74,82,86,89,93,96,100,103,105,112,116,118,124,132,136,143,147,152,156,158,162,169,172,177,185,189,194,199 ./Parse/Parse/Internal/Push/ChannelsController/PFPushChannelsController.h:9,11,13,15,17,19,21,23,25,29,32,35,39,41,45,48,50 ./Parse/Parse/Internal/Push/ChannelsController/PFPushChannelsController.m:9,11,18,20,22,24,26,30,34,36,38,39,42,43,47,51,55,60,61,65,72,73,77,78,86,90,91,95,103,104,107,108,112,115,116 ./Parse/Parse/Internal/Push/State/PFMutablePushState.h:9,11,13,15,17,20,24,26,30,32,34 ./Parse/Parse/Internal/Push/State/PFPushState.m:9,12,16,18,20,24,32,33,37,40,41,44,45,49,56,57,58,62,65,66,70,73,74,76 ./Parse/Parse/Internal/Push/State/PFPushState_Private.h:9,11,14,16,20,22,24,27,31,33,35 ./Parse/Parse/Internal/Push/State/PFMutablePushState.m:9,11,13,15,22,26,32,33,34 ./Parse/Parse/Internal/Push/State/PFPushState.h:9,11,13,15,17,19,21,23,26,30,32,36,39,41 ./Parse/Parse/Internal/Push/Controller/PFPushController.m:9,11,17,19,23,27,29,31,32,35,36,40,53,54 ./Parse/Parse/Internal/Push/Controller/PFPushController.h:9,11,13,15,19,21,23,25,29,32,34,36,40,43,46,50,52 ./Parse/Parse/Internal/Push/Manager/PFPushManager.m:9,11,16,19,20,22,24,27,31,36,40,42,43,47,48,52,58,62,63,68,69,73,79,83,84,89,90 ./Parse/Parse/Internal/Push/Manager/PFPushManager.h:9,11,13,16,18,21,23,25,28,31,35,38,41,44,46 ./Parse/Parse/Internal/Push/Utilites/PFPushUtilities.h:9,11,13,15,17,19,21 ./Parse/Parse/Internal/Push/Utilites/PFPushUtilities.m:9,11,13,16,19,24,26,30,39,41,42,43,49,50,55,56,58,68,69,72,76,78,79,82,83,84,87,88,90 ./Parse/Parse/Internal/Push/PFPushPrivate.h:9,11,13,15,17,19,21,26,28,32,34,36,38,42,44 ./Parse/Parse/Internal/PFFileManager.h:9,11,13,15,18,22,24,28,30,35,38,41,45,49,53,56,59,63,68,75,77 ./Parse/Parse/Internal/MultiProcessLock/PFMultiProcessFileLockController.m:9,11,13,18,19,21,23,27,31,33,36,38,39,47,48,52,59,60,62,66,67,72,76,78,79,86,87 ./Parse/Parse/Internal/MultiProcessLock/PFMultiProcessFileLock.h:9,11,14,17,21,24,27 ./Parse/Parse/Internal/MultiProcessLock/PFMultiProcessFileLockController.h:9,11,14,17,21,25,29,33,35 ./Parse/Parse/Internal/MultiProcessLock/PFMultiProcessFileLock.m:9,11,14,16,20,21,24,26,28,32,36,39,42,44,45,48,49,52,53,57,63,64,70,71,73,74,80,81,85,86,90,93,98,99 ./Parse/Parse/Internal/PFHash.m:9,11,13,21,24,25,28,29,37,38,47,48,51,61,72,73,76 ./Parse/Parse/Internal/ThreadSafety/PFThreadsafety.h:9,11,14,15 ./Parse/Parse/Internal/ThreadSafety/PFThreadsafety.m:9,11,13,17,20,22,23,27,32,33 ./Parse/Parse/Internal/PFBaseState.m:9,11,14,19,23,25,28,29,33,35,37,38,41,42,45,46,48,51,52,54,56,60,68,74,75,78,84,87,89,90,94,99,100,103,104,108,111,112,115,118,121,122,124,125,128,129,133,136,139,140,142,143,147,151,154,157,161,164,165,169,170,171,173,174,178,182,183,186,187,190,193,197,200,201,202,204,205,209,213,217,219,220,223,224,227,228,231,232,236,239,240,245,248,251,254,255,256,258,259,261,262,265,266 ./Parse/Parse/Internal/PFJSONSerialization.m:9,11,14,16,21,23,24,28,29,37,38,40,41,44,45,50,51,53,59,60,65,66,68,70,71 ./Parse/Parse/Internal/PFEventuallyQueue_Private.h:9,11,17,20,22,24,28,32,34,36,42,43,45,49,59,63,66,69,71,75,76,81,85,89,92,95,99,103,107,116,119 ./Parse/Parse/Internal/PFCoreDataProvider.h:9,12,14,18,20,22,24,26,30,32,34,36,38,40,42,44,46,48,50,52,54,56,58,60,62,64,66,68,70,74,76,78,80,82,84,86,88,90,92,94,96,98,102,104,106,108,110,112,114,116,118,120 ./Parse/Parse/Internal/Object/LocalIdStore/PFObjectLocalIdStore.h:9,11,13,23,25,29,32,35,39,43,46,50 ./Parse/Parse/Internal/Object/LocalIdStore/PFObjectLocalIdStore.m:9,11,18,20,24,29,32,35,37,39,42,43,47,50,53,55,56,62,63,66,67,69,73,78,79,81,83,90,92,95,98,103,104,106,107,110,111,115,122,125,129,130,132,133,138,140,142,148,149,159,160,161,162,163,165,166,172,176,177,183,187,188,195,200,202,204,205,206,215,218,219,220,230,235,236,237,238,247,252,253,256,257,258,268,269,272,273,274,281,283,285,291,292,293,300,301,302 ./Parse/Parse/Internal/Object/PFObjectPrivate.h:9,11,13,15,20,34,38,40,42,46,50,52,56,62,64,68,73,82,83,89,95,97,99,102,106,108,112,115,119,123,129,134,138,140,142,144,147,152,156,158,160,165,170,172,176,185,190,196,200,202,206,215,221,225,229,238,242,255,259,264,269,273,275,284,293,299,303,307,311,315,323,329,331,334,335,337 ./Parse/Parse/Internal/Object/Constants/PFObjectConstants.h:9,11,22 ./Parse/Parse/Internal/Object/Constants/PFObjectConstants.m:9,11,21 ./Parse/Parse/Internal/Object/EstimatedData/PFObjectEstimatedData.h:9,11,14,16,20,25,29,32,34,37,41,43 ./Parse/Parse/Internal/Object/EstimatedData/PFObjectEstimatedData.m:9,11,13,16,17,19,21,25,29,31,33,34,39,44,45,47,48,52,53,57,60,61,64,65,68,69,72,73,76,77,81,84,85 ./Parse/Parse/Internal/Object/BatchController/PFObjectBatchController.m:9,11,13,26,28,32,36,38,40,41,44,45,49,53,54,68,69,78,79,85,90,98,100,103,104,108,112,113,120,129,136,147,148,152,156,157,167,169,170,177,184,188,189,193,198,199,206,207,213,215,216,218,219,223,224,229,230,235,236,238,239 ./Parse/Parse/Internal/Object/BatchController/PFObjectBatchController.h:9,11,13,16,19,21,23,25,29,32,35,39,41,45,47,51,54,56 ./Parse/Parse/Internal/Object/State/PFObjectState.h:9,11,14,16,18,21,24,26,29,33,35,42,48,52,55,57,59,63,67,69 ./Parse/Parse/Internal/Object/State/PFMutableObjectState.h:9,11,13,15,18,21,23,26,30,34,37,41,44 ./Parse/Parse/Internal/Object/State/PFObjectState.m:9,13,20,22,26,30,32,34,35,39,42,45,47,50,52,53,56,57,63,67,69,70,74,76,78,79,82,83,86,87,94,95,99,103,104,105,109,114,117,120,129,135,137,138,142,144,150,151,152,155,156,159,160,163,164,167,168,170,174,177,180,182,184,185,188,189,193,196,197,201,204,205,209,212,213 ./Parse/Parse/Internal/Object/State/PFObjectState_Private.h:9,11,13,21,24,25,31,34,36,38,42,46,49,53,56 ./Parse/Parse/Internal/Object/State/PFMutableObjectState.m:9,11,14,16,24,28,30,33,34,37,38,41,42,45,46,49,50,52,55,56,59,60 ./Parse/Parse/Internal/Object/Controller/PFObjectController.h:9,11,14,17,19,21,23,27,30,33,35 ./Parse/Parse/Internal/Object/Controller/PFObjectControlling.h:9,11,13,15,18,20,22,26,29,32,36,38,42,45,48,52,55,57 ./Parse/Parse/Internal/Object/Controller/PFObjectController.m:9,12,23,25,29,33,35,37,38,41,42,46,48,63,64,67,68,75,78,79,81,91,92,102,108,109,112,113,120,121 ./Parse/Parse/Internal/Object/Controller/PFObjectController_Private.h:9,11,13,15,19,21 ./Parse/Parse/Internal/Object/Controller/OfflineController/PFOfflineObjectController.m:9,11,18,20,22,24,26,28,32,35,36,39,40,44,51,61,65,66,73,76,77,81,84,85 ./Parse/Parse/Internal/Object/Controller/OfflineController/PFOfflineObjectController.h:9,11,13,15,17,21,24,26 ./Parse/Parse/Internal/Object/Utilities/PFObjectUtilities.m:9,11,14,16,20,30,32,33,38,39,43,46,47 ./Parse/Parse/Internal/Object/Utilities/PFObjectUtilities.h:9,11,13,16,18,22,27,31,33,35 ./Parse/Parse/Internal/Object/FilePersistence/PFObjectFilePersistenceController.h:9,11,13,16,19,21,23,27,30,33,37,40,42,46,49,52,56,59,61,65 ./Parse/Parse/Internal/Object/FilePersistence/PFObjectFilePersistenceController.m:9,11,19,21,25,29,31,33,34,37,38,42,53,62,63,74,75,85,86,90,93,94 ./Parse/Parse/Internal/Object/OperationSet/PFOperationSet.h:9,11,15,22,27,32,34,40,47,54,58,60,64,66,71 ./Parse/Parse/Internal/Object/OperationSet/PFOperationSet.m:9,12,19,24,26,28,30,32,36,39,40,44,47,49,51,52,56,66,69,70,74,87,90,94,95,98,101,104,105,116,117,122,123,126,133,138,142,144,145,149,152,153,156,157,160,161,164,165,168,169,173,174,177,178,182,183,187,188,192,197,198,202,209,210 ./Parse/Parse/Internal/Object/CurrentController/PFCurrentObjectControlling.h:9,11,13,15,18,23,25,27,31,34,36 ./Parse/Parse/Internal/Object/Coder/File/PFObjectFileCodingLogic.m:9,11,14,16,20,23,24,28,34,38,42,44,52,56,57 ./Parse/Parse/Internal/Object/Coder/File/PFObjectFileCoder.h:9,11,15,17,23,27,29,33,35,37 ./Parse/Parse/Internal/Object/Coder/File/PFObjectFileCoder.m:9,11,16,18,22,29,30,34,39,43,44 ./Parse/Parse/Internal/Object/Coder/File/PFObjectFileCodingLogic.h:9,11,14,16,18,22,24,28,30,32 ./Parse/Parse/Internal/Object/PinningStore/PFPinningObjectStore.m:9,11,18,23,24,26,28,32,36,40,42,44,45,48,49,53,76,77,81,82,91,100,101,102,104,110,113,114,118,122,123,132,133,137,139,143,145,148,149,156,157 ./Parse/Parse/Internal/Object/PinningStore/PFPinningObjectStore.h:9,11,13,16,18,21,23,25,29,32,35,39,42,44,48,51,55,61,65,68,71,75,78,80,84,86 ./Parse/Parse/Internal/Object/Subclassing/PFObjectSubclassingController.h:9,11,14,16,20,22,26,30,33 ./Parse/Parse/Internal/Object/Subclassing/PFObjectSubclassInfo.m:9,11,13,18,22,29,30,41,46,54,56,57,66,68,69,74,75,79,83,86,89,91,92,95,96,100,106,109,110,112,113,117,123,124,128,129,132,138,141,142,145,148,150,151,155,162,163,168,169,177,178,184,185,187,191,194,195,197,198 ./Parse/Parse/Internal/Object/Subclassing/PFObjectSubclassingController.m:9,11,13,16,24,27,33,43,52,56,61,63,64,74,75,79,80,86,87,91,95,99,101,102,107,108,112,119,120,133,137,138,139,144,145,150,156,157,160,161,164,169,170,175,177,178,182,183,187,193,196,205,210,211,212,224,225,226,228,229,234,237,240,243,248,251,254,257,258,263,264,265,266,272,273,278,281,282,289,291,300,306,307,314,315,320,321,329,331,332,337,341,343,344,347,351,352,355,364,367,370,375,376,379,380,386,397,399,400,401,404,405 ./Parse/Parse/Internal/Object/Subclassing/PFObjectSubclassInfo.h:9,11,13,15,17,20,23,26 ./Parse/Parse/Internal/CloudCode/PFCloudCodeController.m:9,11,20,22,26,30,32,34,35,38,39,43,64,65 ./Parse/Parse/Internal/CloudCode/PFCloudCodeController.h:9,11,14,16,18,20,24,27,29,31,35,38,42,48 ./Parse/Parse/Internal/PFMemoryEventuallyQueue.h:9,11,15,17,19 ./Parse/Parse/Internal/PFReachability.m:9,11,13,20,24,26,27,29,31,36,37,39,41,45,48,52,53,58,66,67,68,77,79,81,82,86,90,94,96,97,106,107,111,118,119,120,124,130,131,141,142,147,148,156,157,162,163,167,173,174,181,182,185,186,190,199,205,206,207,209,210 ./Parse/Parse/Internal/PFCategoryLoader.m:9,11,13,15,18,19 ./Parse/Parse/Internal/Persistence/Group/PFFilePersistenceGroup.m:9,11,15,17,21,26,29,31,32,36,42,43,50,53,54,60,63,66,67,75,78,79,82,83,87,88,94,95,99,100,106,107,111,114,115 ./Parse/Parse/Internal/Persistence/Group/PFUserDefaultsPersistenceGroup.h:9,11,13,15,18,22,26 ./Parse/Parse/Internal/Persistence/Group/PFPersistenceGroup.h:9,11,13,15,17,19,23,25,28,30,34,37,39 ./Parse/Parse/Internal/Persistence/Group/PFFilePersistenceGroup.h:9,11,13,15,19,21,24,27,29 ./Parse/Parse/Internal/Persistence/Group/PFUserDefaultsPersistenceGroup.m:9,11,14,18,19,21,23,27,30,31,35,38,40,42,43,47,54,55,63,64,72,73,81,82,85,86,89,90,94,100,103,104,110,111 ./Parse/Parse/Internal/Persistence/PFPersistenceController.h:9,11,13,15,17,19,23,25,27,30,34,39,43,45,47 ./Parse/Parse/Internal/Persistence/PFPersistenceController.m:9,11,14,18,21,26,27,29,31,35,41,45,47,49,50,54,59,62,63,67,82,83,87,99,102,103,120,123,124,128,133,134 ./Parse/Parse/Internal/PFPinningEventuallyQueue.h:9,11,13,15,19,21 ./Parse/Parse/Internal/PFMacros.h:9,12,15,20,32,41,47,55,63,67,74,78,82,89,94,97,111,124,129,136 ./Parse/Parse/Internal/PFDevice.m:9,11,13,21,25,31,35,37,40,41,44,45,51,54,55,57,61,69,70,74,85,87,88,94,96,123,126,128,129,132,133,141,144,145 ./Parse/Parse/Internal/PFSystemLogger.m:9,11,14,16,20,31,33,34,52,54,55,59,67,68,72,74,76,77,81,87,88,91,93,97,98,100,102,104,105 ./Parse/Parse/Internal/PFLocationManager.h:9,11,13,16,18,20,22,24,28,37,41,43,45,49,51,55,57 ./Parse/Parse/Internal/PFInternalUtils.h:9,11,13,15,19,21,24,30,36,38,43,53,56,59,63,65 ./Parse/Parse/Internal/Purchase/Controller/PFPurchaseController.m:9,11,13,15,29,32,33,35,37,40,44,49,52,54,55,59,60,64,68,69,70,74,87,88,91,97,103,109,110,111,120,125,126,127,132,133,143,144,153,157,158,170,177,178,187,198,203,204,210,211,214,215,219,223,225,226,231,233,234 ./Parse/Parse/Internal/Purchase/Controller/PFPurchaseController.h:9,11,13,15,18,23,27,29,32,35,37,41,45,48,52,58,61 ./Parse/Parse/Internal/Purchase/PaymentTransactionObserver/PFPaymentTransactionObserver_Private.h:9,11,13,18 ./Parse/Parse/Internal/Purchase/PaymentTransactionObserver/PFPaymentTransactionObserver.m:9,11,13,15,20,24,28,33,35,36,40,52,53,54,55,59,62,67,68,69,75,76,77,80,81,85,89,90,91,96,103,105,106,107 ./Parse/Parse/Internal/Purchase/PaymentTransactionObserver/PFPaymentTransactionObserver.h:9,12,14,17,28,31 ./Parse/Parse/Internal/PFAlertView.h:9,12,14,17,19,21,27 ./Parse/Parse/Internal/BFTask+Private.m:9,11,14,16,18,26,27,29,31,34,35,38,39,42,43,46,47,52,53,58,59,64,71,74,77,78,84,85,88,89,93,97,98,101,102,113,116,119,121,122,124,128 ./Parse/Parse/Internal/ParseModule.m:9,11,13,17,19,21,24,26,28,32,36,39,41,42,46,51,52,57,58,65,68,69,72,73,77,79,81,88,90,91,92,96,99,100,103,105,111,114,119,120,123,124,127,128,132,134,135,137 ./Parse/Parse/Internal/Commands/PFRESTFileCommand.h:9,11,13,15,18,20 ./Parse/Parse/Internal/Commands/PFRESTUserCommand.m:9,11,14,17,19,21,23,25,29,45,48,49,53,66,67,77,78,89,90,94,105,106,110,117,118,125,126,133,134,138,145,146 ./Parse/Parse/Internal/Commands/PFRESTSessionCommand.m:9,11,13,15,22,23 ./Parse/Parse/Internal/Commands/PFRESTAnalyticsCommand.h:9,11,13,16,18,21,25,28,30 ./Parse/Parse/Internal/Commands/PFRESTObjectBatchCommand.m:9,11,15,17,19,27,37,38,40,46,47 ./Parse/Parse/Internal/Commands/PFRESTPushCommand.h:9,11,13,15,17,19,21,25,27 ./Parse/Parse/Internal/Commands/PFRESTCloudCommand.m:9,11,14,16,27,28 ./Parse/Parse/Internal/Commands/CommandRunner/URLRequestConstructor/PFCommandURLRequestConstructor.h:9,11,13,15,18,20,22,25,29,32,34,38,40,44,48,52,56,58 ./Parse/Parse/Internal/Commands/CommandRunner/URLRequestConstructor/PFCommandURLRequestConstructor.m:9,11,23,25,29,33,36,38,39,42,43,47,59,60,65,74,79,83,84,90,91,95,101,104,105,112,115,116,119,120,124,137,139,143,144,147,152,156,157,159,160,167,173,174 ./Parse/Parse/Internal/Commands/CommandRunner/PFCommandRunningConstants.h:9,11,15,17,21,30,34 ./Parse/Parse/Internal/Commands/CommandRunner/URLSession/PFURLSessionCommandRunner_Private.h:9,11,14,16,18,21,26,28 ./Parse/Parse/Internal/Commands/CommandRunner/URLSession/PFURLSessionCommandRunner.m:9,12,14,33,35,38,40,42,47,51,61,62,69,77,82,84,85,92,95,99,101,102,108,109,120,121,125,129,130,134,137,138,142,145,146,158,159,163,173,187,188,201,202,206,212,213,216,217,219,228,229,239,240,245,254,257,258,262,266,270,282,291,292,294,296,297,301,310,311,323,326,327,332,333 ./Parse/Parse/Internal/Commands/CommandRunner/URLSession/PFURLSessionCommandRunner.h:9,11,13,15,17,20,26,28 ./Parse/Parse/Internal/Commands/CommandRunner/URLSession/Session/PFURLSession.h:9,11,13,15,18,20,22,24,26,28,30,32,34,38,41,44,47,51,53,57,61,67,72,74 ./Parse/Parse/Internal/Commands/CommandRunner/URLSession/Session/TaskDelegate/PFURLSessionUploadTaskDelegate.h:9,11,13,15,17,19,26,28 ./Parse/Parse/Internal/Commands/CommandRunner/URLSession/Session/TaskDelegate/PFURLSessionDataTaskDelegate_Private.h:9,11,13,15,17,23,26,28,31,33 ./Parse/Parse/Internal/Commands/CommandRunner/URLSession/Session/TaskDelegate/PFURLSessionJSONDataTaskDelegate.m:9,11,15,21,23,25,27,31,34,36,43,48,49,50,57,61,62,66,67,80,81,82,83,86,88,89 ./Parse/Parse/Internal/Commands/CommandRunner/URLSession/Session/TaskDelegate/PFURLSessionFileDownloadTaskDelegate.h:9,11,13,15,17,19,23,32,34 ./Parse/Parse/Internal/Commands/CommandRunner/URLSession/Session/TaskDelegate/PFURLSessionDataTaskDelegate.m:9,12,15,18,21,22,24,26,29,33,38,40,47,49,50,54,55,59,62,63,67,69,70,74,81,82,83,87,88,91,92,96,100,101,108,115,116,118,120,121,127,128,130,131,135,136,140,147,148,155,156,157,161,168,170,171,174,175 ./Parse/Parse/Internal/Commands/CommandRunner/URLSession/Session/TaskDelegate/PFURLSessionUploadTaskDelegate.m:9,11,14,15,19,25,27,29,30,37,38,42,52,54,55 ./Parse/Parse/Internal/Commands/CommandRunner/URLSession/Session/TaskDelegate/PFURLSessionJSONDataTaskDelegate.h:9,11,13,15,17,19 ./Parse/Parse/Internal/Commands/CommandRunner/URLSession/Session/TaskDelegate/PFURLSessionFileDownloadTaskDelegate.m:9,11,15,19,20,22,24,28,35,39,41,42,51,52,56,60,61,64,65,69,72,73,77,86,90,91,98,99,100,102,103,107,111,112 ./Parse/Parse/Internal/Commands/CommandRunner/URLSession/Session/TaskDelegate/PFURLSessionDataTaskDelegate.h:9,11,13,15,17,19,21,24,27,30,33,36,38 ./Parse/Parse/Internal/Commands/CommandRunner/URLSession/Session/PFURLSession.m:9,12,14,22,24,30,31,33,35,39,47,48,53,56,58,61,63,64,68,69,73,74,78,81,82,86,92,93,99,100,109,110,118,119,125,126,136,137,144,145,151,152,163,164,167,173,180,185,188,189,193,200,201,206,207,212,213,217,229,230,234,235,239,246,247,251,252,258,259 ./Parse/Parse/Internal/Commands/CommandRunner/URLSession/Session/PFURLSession_Private.h:9,11,13,15,18,21,23 ./Parse/Parse/Internal/Commands/CommandRunner/PFCommandRunning.h:9,11,13,15,21,25,27,29,31,33,37,39,43,52,56,59,62,67,70,74,80,84,91,96,98 ./Parse/Parse/Internal/Commands/CommandRunner/PFCommandRunningConstants.m:9,11,13,22 ./Parse/Parse/Internal/Commands/CommandRunner/PFCommandRunning.m:9,11 ./Parse/Parse/Internal/Commands/PFRESTConfigCommand.m:9,11,14,16,23,24,33,34 ./Parse/Parse/Internal/Commands/PFRESTQueryCommand.h:9,11,13,15,17,21,25,37,41,44,48,60,62 ./Parse/Parse/Internal/Commands/PFRESTCommand.m:9,12,22,28,32,34,38,42,54,55,69,70,74,78,79,83,86,87,89,95,96,100,102,106,107,115,116,121,124,129,131,134,137,139,140,143,144,145,147,160,164,165,169,170,171,174,175,176,180,187,189,190,198,203,208,209,214,215,220,221,226,227,228,230,231,236,242,243,245,246,254,259,262,263 ./Parse/Parse/Internal/Commands/PFRESTObjectCommand.h:9,11,13,15,17,20,25,30,33,35 ./Parse/Parse/Internal/Commands/PFRESTUserCommand.h:9,11,13,15,17,21,34,38,43,47,51,55,57,59 ./Parse/Parse/Internal/Commands/PFRESTFileCommand.m:9,11,14,16,22,28,29 ./Parse/Parse/Internal/Commands/PFRESTCommand_Private.h:9,11,13,15,18,20,22,24 ./Parse/Parse/Internal/Commands/PFRESTAnalyticsCommand.m:9,11,13,20,22,29,30,36,37,43,44,49,53,60,61 ./Parse/Parse/Internal/Commands/PFRESTSessionCommand.h:9,11,13,15,17,19 ./Parse/Parse/Internal/Commands/PFRESTCloudCommand.h:9,11,13,15,20,22 ./Parse/Parse/Internal/Commands/PFRESTPushCommand.m:9,11,19,21,26,31,36,37,38,42,43,48,49,52,53,57,58,64,65 ./Parse/Parse/Internal/Commands/PFRESTObjectBatchCommand.h:9,11,13,15,17,19,24,26 ./Parse/Parse/Internal/Commands/PFRESTObjectCommand.m:9,11,15,17,22,30,31,37,46,47,54,63,64,68,72,79,80 ./Parse/Parse/Internal/Commands/PFRESTCommand.h:9,11,13,15,17,20,23,25,27,31,37,44,46 ./Parse/Parse/Internal/Commands/PFRESTQueryCommand.m:9,11,18,20,24,32,33,59,60,73,74,78,84,90,91,95,106,107,118,121,126,131,134,137,141,145,161,175,176,182,183,191,197,199,201,203,207,208,210,211,215,216,236,246,247,253,255,257,258 ./Parse/Parse/Internal/Commands/PFRESTConfigCommand.h:9,11,13,15,19,21 ./Parse/Parse/Internal/PFKeychainStore.h:9,11,13,15,19,23,26,28,31,36,38 ./Parse/Parse/Internal/PFApplication.h:9,11,13,22,28,30,33,35,37 ./Parse/Parse/Internal/PFCoreManager.m:9,11,32,37,42,43,45,47,50,65,70,71,75,79,81,87,88,91,92,96,102,106,107,111,117,121,122,126,137,138,142,143,148,149,153,159,163,164,169,170,174,180,184,185,190,191,195,201,205,206,211,212,216,226,227,231,232,237,238,242,249,253,254,259,260,264,270,274,275,279,285,289,290,295,296,300,306,310,311,316,317,321,329,333,334,339,340,344,350,354,355,360,361,365,371,375,376,381,382,384,388,400,404,405,410,411,413,417,429,433,434,439,440,442,446,452,456,457,462,463,465,469,476,480,481,486,487 ./Parse/Parse/Internal/PFEventuallyQueue.m:9,12,15,25,29,32,37,40,42,44,48,54,58,61,66,70,72,74,76,78,80,81,85,88,89,92,94,99,109,110,111,119,121,122,129,130,135,138,141,142,143,147,150,151,154,155,158,159,162,163,167,173,174,178,182,183,187,190,191,195,196,201,202,206,209,211,212,215,218,219,231,235,236,241,247,254,255,260,266,272,275,280,284,285,290,291,292,294,295,299,307,308,309,313,314,315,319,320,325,326,331,335,337,338,342,343,347,354,356,358,362,363,368,369,371,374,375,379,391,392,400,402,404,405,409,423,424,428,429,432,433,436,437,439,443,447,448,449,451 ./Parse/Parse/Internal/PFCommandCache.h:9,11,13,15,19,26,28,31,35,45,49,56 ./Parse/Parse/Internal/KeyValueCache/PFKeyValueCache.m:9,11,18,23,25,27,30,32,34,37,38,42,45,47,48,51,52,55,56,58,62,66,67,71,76,77,83,87,89,93,95,96,100,104,105,109,112,113,117,122,123,128,129,133,140,141,145,147,148,157,158,164,166,167,170,174,175,178,183,184,189,190,194,197,198,201,202,205,206,210,215,216,219,220,225,227,232,236,242,243,244,248,249,253,260,261,266,267,270,274,277,280,283,285,291,292,293,300,307,309,310,314,315,320,323,325,326,327 ./Parse/Parse/Internal/KeyValueCache/PFKeyValueCache_Private.h:9,11,13,15,19,22,26,30,34,38,40,42,44,48,51,55,58,63,65 ./Parse/Parse/Internal/KeyValueCache/PFKeyValueCache.h:9,11,13,15,17,21,24,26,30,33,37,39,43,46,48 ./Parse/Parse/Internal/PFLogging.h:9,12,14,16,19,22,25,28,31,34,39 ./Parse/Parse/Internal/PFErrorUtilities.m:9,11,14,16,19,20,25,26,29,30,33,35,39,40,44,46,47 ./Parse/Parse/Internal/PFWeakValue.h:9,11,13,15,17 ./Parse/Parse/Internal/Query/PFQueryConstants.m:9,11,36 ./Parse/Parse/Internal/Query/State/PFQueryState.m:9,12,16,18,22,31,36,41,44,45,49,53,57,59,60,63,64,67,68,72,75,76,80,83,84,87,88 ./Parse/Parse/Internal/Query/State/PFMutableQueryState.m:9,12,15,21,22,24,26,31,43,47,50,55,57,58,62,66,68,70,71,74,75,79,82,87,90,92,94,95,99,101,102,109,110,113,114,118,122,123,127,128,134,135,136,141,142,143,147,153,154,155,161,162,163,167,173,174,175,179,183,185,186 ./Parse/Parse/Internal/Query/State/PFQueryState_Private.h:9,11,13,16,18,22,26,28,30,34,37,40,42,47,48,50,53,57,60,62,66,71 ./Parse/Parse/Internal/Query/State/PFQueryState.h:9,11,13,15,17,19,21,24,28,31,35,38,40,44,57,61,64 ./Parse/Parse/Internal/Query/State/PFMutableQueryState.h:9,11,13,15,18,22,25,27,31,36,40,43,47,49,52,54,58,62,66,69,73,75,79,81 ./Parse/Parse/Internal/Query/Controller/PFQueryController.m:9,11,13,25,27,29,31,35,39,41,43,44,47,48,52,58,63,64,75,82,89,90,91,97,98,101,102,106,114,115,130,131,135,138,139,142,143,145,146,148,149,153,160,161 ./Parse/Parse/Internal/Query/Controller/PFOfflineQueryController.h:9,11,13,15,17,20,23,28,30 ./Parse/Parse/Internal/Query/Controller/PFCachedQueryController.m:9,11,13,26,28,30,34,37,38,41,42,46,52,53,56,60,63,69,75,91,94,97,108,111,117,123,125,127,128,136,145,149,150,154,158,159,163,166,167,172,173,176,177,188,189,195,196,198,203,204,209,212,213 ./Parse/Parse/Internal/Query/Controller/PFQueryController.h:9,11,13,15,17,23,25,27,29,33,36,38,40,44,48,52,58,62,66,70,76,80,83,86,88,90,93,97,103,105 ./Parse/Parse/Internal/Query/Controller/PFOfflineQueryController.m:9,11,23,26,27,29,31,33,37,42,45,47,48,52,53,57,65,66,78,79,80,82,83,92,96,97,103,104,105,114,115,120,126,127,131,139,141,142,151,152,157,163,164,168,175,176 ./Parse/Parse/Internal/Query/Controller/PFCachedQueryController.h:9,11,13,15,17,19,22,24 ./Parse/Parse/Internal/Query/Utilities/PFQueryUtilities.h:9,11,13,17,22,26,29,31,35,39,41 ./Parse/Parse/Internal/Query/Utilities/PFQueryUtilities.m:9,11,15,17,21,24,25,38,44,45,48,49,55,56,59,60,70,76,78,84,86,91,92,97,102,106,111,115,119,123,127,130,140,141,142,153,155,156,169,170,178,180,181,193,197,200,203,206,213,226,229,230,248,252,256,260,264,268,274,285,286,292,295,296,310,311,312,321,324,325,329,331,332,345,346,347,353,354,357,362,363,365,366,376,377,378,383,384,387,388,401,402,410,413,416,419,423,424,427,428,439,440,451,452,457,458,459,462,463,465,474,475,478,479,489,490,491,496,497,501,511,512,516,519,520 ./Parse/Parse/Internal/Query/PFQueryConstants.h:9,11,13,38,46 ./Parse/Parse/Internal/Query/PFQueryPrivate.h:9,11,13,15,18,20,22,25 ./Parse/Parse/Internal/PFTaskQueue.h:9,11,13,15,17,20,28 ./Parse/Parse/Internal/PFAsyncTaskQueue.m:9,11,13,15,17,20,22,24,28,32,35,37,38,41,42,46,58,63,64 ./Parse/Parse/Internal/ParseManager.h:9,11,14,18,26,35,37,39,43,45,49,53,56,59,61,65,70,74,76,80,82,86,88,92,94 ./Parse/Parse/Internal/PFAssert.h:9,12,15,27,36,48,60,67,68,74,82,83,87,88,95,96,103,104,111,112,121,133,141,150,163 ./Parse/Parse/Internal/ACL/PFACLPrivate.h:9,11,13,15,17,19,24,29,34,39,41 ./Parse/Parse/Internal/ACL/State/PFMutableACLState.h:9,11,13,15,18,20 ./Parse/Parse/Internal/ACL/State/PFACLState.h:9,11,13,15,17,19,22,26,30,33,37,39,41 ./Parse/Parse/Internal/ACL/State/PFACLState_Private.h:9,11,13,16,18,22,27,28,31 ./Parse/Parse/Internal/ACL/State/PFMutableACLState.m:9,11,13,15,18,22,26,28,30,31 ./Parse/Parse/Internal/ACL/State/PFACLState.m:9,11,13,15,19,25,26,30,34,37,39,40,43,44,48,51,53,55,57,58,61,62,65,66,70,73,74,77,78,82,85,86 ./Parse/Parse/Internal/ACL/DefaultACLController/PFDefaultACLController.h:9,11,13,15,18,20,22,24,28,31,33,37,40,44,47,50,54,56 ./Parse/Parse/Internal/ACL/DefaultACLController/PFDefaultACLController.m:9,11,13,17,20,23,26,27,31,35,38,40,41,44,45,49,54,55,61,62,69,73,74,79,82,84,87,88 ./Parse/Parse/Internal/PFEventuallyPin.h:9,11,15,18,20,27,30,44,46,48,50,52,54,56,60,65,70,72,74 ./Parse/Parse/Internal/PFMulticastDelegate.m:9,11,14,15,17,19,23,25,27,28,31,32,35,36,41,42,45,46 ./Parse/Parse/Internal/PFCommandResult.m:9,11,13,15,19,25,29,31,32,37,38 ./Parse/Parse/Internal/Analytics/PFAnalytics_Private.h:9,11 ./Parse/Parse/Internal/Analytics/Controller/PFAnalyticsController.h:9,11,13,16,18,20,22,24,28,31,33,35,39,44,47,52,55,59,65,67 ./Parse/Parse/Internal/Analytics/Controller/PFAnalyticsController.m:9,11,17,19,21,23,25,29,33,35,37,38,41,42,46,57,62,63,69,75,76,84,90,91,95,98,99 ./Parse/Parse/Internal/Analytics/Utilities/PFAnalyticsUtilities.h:9,11,13,21,23,27 ./Parse/Parse/Internal/Analytics/Utilities/PFAnalyticsUtilities.m:9,11,13,15,22,26,31,35,37,38 ./Parse/Parse/Internal/PFCommandCache_Private.h:9,11,13,15 ./Parse/Parse/Internal/Parse_Private.h:9,11,13,15,17,19,21,24 ./Parse/Parse/Internal/Session/PFSession_Private.h:9,11,13,15,17,21,23 ./Parse/Parse/Internal/Session/Controller/PFSessionController.h:9,11,13,15,18,20,22,24,28,31,35,37,39 ./Parse/Parse/Internal/Session/Controller/PFSessionController.m:9,11,19,21,25,29,31,33,34,37,38,42,58,59 ./Parse/Parse/Internal/Session/Utilities/PFSessionUtilities.h:9,11,13,15,19,21,23 ./Parse/Parse/Internal/Session/Utilities/PFSessionUtilities.m:9,11,13,17,20,21 ./Parse/Parse/PFObject+Subclass.h:9,11,13,15,17,20,25,28,30,33,35,38,40,42,43,45,47,50,51,53,54,60,64,67,74,79,82,85,90,92,96,98,101,108,111,114,118,121,124,126,128,132,134,143,145 ./Parse/Parse/PFDecoder.m:9,11,23,27,29,31,39,40,42,47,48,53,56,59,62,65,69,81,82,85,90,95,99,100,101,107,108,111,112,115,116,121,123,124,130,132,133,135,139,141,147,149,151,156,157,159,165,166,169,170,172,176,178,180,182,184,189,190,194,196,197 ./Parse/Parse/PFSubclassing.h:9,11,13,15,19,25,27,32,34,37,41,43,47,50,54,57,59,61,63,67,70,74,76 ./Parse/Parse/PFEncoder.m:9,11,24,26,34,35,44,50,61,67,74,78,82,86,93,95,107,112,114,115,117,118,122,123,125,129,131,139,140,144,145,147,151,153,161,162,170,176,177,179,183,185,193,194,198,199,201,205,207,212,214,216,220,221,225,228,231,233,234,237,238,244,245,254,256,257,265,266,268,271,272 ./Parse/Parse/PFFileUploadController.h:8,11,18,21,28 ./Parse/Parse/PFAnonymousUtils+Deprecated.h:9,12,14,19,23,26,30,35,37 ./Parse/Parse/ParseClientConfiguration.m:9,12,19,21,23,27,30,31,35,39,41,42,46,48,50,52,53,56,57,61,65,66,69,70,75,76,81,83,84,90,92,93,97,98,102,105,106,110,111,122,123,127,142,143 ./Parse/Parse/PFPurchase.m:9,11,20,22,26,32,36,38,39,44,47,48,51,52,56,57,69,70,76,77,79,80,84,87,88 ./Parse/Parse/PFQuery.m:9,14,17,38,49,53,54,55,57,58,68,72,73,74,76,77,80,81,83,85,87,91,95,97,99,100,104,106,108,109,113,115,118,119,123,124,126,129,130,133,134,136,139,140,143,144,146,150,152,153,157,159,160,162,165,166,169,170,172,175,176,179,180,184,189,190,195,196,201,202,207,208,216,217,219,220,224,225,229,235,236,242,243,247,248,252,253,257,258,262,263,267,268,271,272,275,276,279,280,283,284,288,289,292,293,296,297,302,303,307,308,312,313,317,318,321,322,329,332,333,337,338,342,343,347,348,351,352,355,356,359,360,363,364,370,371,377,378,382,383,386,387,391,396,397,402,403,407,412,413,417,422,423,428,434,439,444,449,454,459,469,478,486,488,492,493,502,511,519,521,526,533,536,540,541,542,543,565,569,570,574,580,583,585,590,593,595,601,602,606,607,608,612,617,618,619,620,625,626,627,631,634,635,639,640,643,644,654,656,660,661,665,669,670,674,675,687,688,689,690,696,703,704,707,708,712,715,716,720,723,727,728,735,741,742,743,744,750,751,753,768,772,773,776,777,781,786,787,797,798,799,800,803,809,810,813,814,818,823,824,831,832,838,844,845,846,847,853,854,856,871,875,876,879,880,884,890,891,892,893,897,900,901,905,908,909,913,914,917,918,920,921,925,929,930,934,935,938,939,943,954,955,956,960,963,964,967,968,972,975,977,978,982,984,986,987,991,994,995,1000,1001,1005,1006,1010,1013,1014,1018,1022,1024,1025,1027,1031,1033,1035,1038,1039,1043,1044,1047,1048,1051,1052,1054,1057,1058,1062,1063,1065,1068,1069,1072,1073,1075,1078,1079,1082,1083,1085,1088,1089,1096,1097,1099,1100,1102,1106,1108,1110,1115,1116,1118,1123,1124,1126,1131,1132,1134,1139,1140 ./Parse/Parse/PFProduct.h:9,11,15,18,20,25,29,33,36,40,45,50,55,58,62,65,69,71 ./Parse/Parse/PFPush+Synchronous.h:9,12,14,21,25,28,30,34,37,42,46,49,53,57,60,62,67,71,74,76,81,85,89,92,94,98,101,105,109,112,115,119,121 ./Parse/Parse/PFNetworkActivityIndicatorManager.h:9,12,14,18,20,25,30,38,43,48,51,55,58,63,66,71,73 ./Parse/Parse/PFFileObject.h:9,11,13,15,17,25,31,35,38,41,43,47,50,55,59,62,65,69,74,77,84,90,93,95,100,106,109,117,124,127,130,134,138,141,147,152,157,161,164,168,171,173,177,180,184,187,190,196,200,205,208,210,214,217,219,221,223,227,230,232,236,239,244,247,251,255,258,262,265,270,273,275,279,282,286,289,291,295,298,301,307,311,313,319,322,326,330,333,337,339,343,346,350,354,357,361,367,371,376,380,383,387,390,394,396 ./Parse/Parse/PFGeoPoint.h:9,12,14,16,18,22,26,30,33,37,40,42,46,49,52,56,59,62,65,70,74,79,84,88,91,93,97,100,102,106,109,111,115,117 ./Parse/Parse/PFConfig.m:9,12,21,23,25,27,29,31,35,38,39,41,44,45,48,49,53,57,59,61,62,66,73,74,77,78,82,85,86,89,90,92,95,96,100,104,105,107,108,110,114,116,118,121,122,125,126 ./Parse/Parse/PFAnonymousUtils.m:9,12,17,19,23,27,28,31,32,36,39,40,44,46,54,55,64,67,68,74,75,79,83,84,86,88,93,94 ./Parse/Parse/PFPolygon.h:9,13,15,17,23,27,30,35,38,43,47,52,54 ./Parse/Parse/PFSession.m:9,11,21,35,36,38,40,44,47,48,51,52,56,60,61,63,70,71,74,75,79,84,85,90,91,96,97,101,104,105 ./Parse/Parse/PFFileObject+Deprecated.h:9,12,14,19,23,26,32,37,41,44,49,54,56 ./Parse/Parse/PFConstants.m:9,11,21,23,27 ./Parse/Parse/PFObject.h:9,11,13,15,17,21,26,33,37,40,43,47,50,53,57,61,64,68,71,74,77,82,86,91,96,101,106,111,114,119,123,126,128,132,135,141,145,148,152,155,158,160,164,167,170,176,180,183,187,190,192,196,201,205,209,213,216,221,224,229,232,234,239,243,245,250,253,258,261,266,270,273,277,280,285,289,292,296,299,304,308,311,318,322,326,330,337,342,346,349,351,355,358,365,369,376,379,386,390,393,397,399,402,406,409,411,415,418,421,425,427,430,434,437,442,446,450,453,458,462,465,467,471,475,482,485,487,491,495,502,506,510,514,518,523,527,530,534,537,542,546,550,557,561,565,569,573,576,578,582,586,590,595,597,602,606,611,614,619,622,627,629,631,635,638,643,647,651,655,659,664,666,668,673,677,682,686,691,694,699,702,704,708,711,716,721,727,731,735,737,742,746,749,754,757,759,761,765,768,772,776,780,784,786,790,794,797,801,804,806,810,813,819,823,825,827,832,836,840,845,848,851,853,857,860,865,871,873 ./Parse/Parse/PFAnalytics.m:9,12,16,24,26,30,39,41,42,46,47,54,55,59,60,64,67,68,71,72,81,87,88,93,94 ./Parse/Parse/PFRole.h:9,11,15,17,19,26,30,34,38,42,45,50,53,55,59,62,67,71,74,77,81,84,90,93,99,101 ./Parse/Parse/PFRelation.h:9,11,14,16,22,27,31,36,40,43,47,50,54,56 ./Parse/Parse/PFPush.m:9,12,14,32,34,36,39,41,43,46,47,52,54,55,57,59,63,65,68,69,73,75,77,78,80,84,85,89,90,93,94,97,98,101,102,106,107,111,112,116,117,120,121,124,125,128,129,131,137,138,146,147,150,151,153,159,161,162,166,171,172,176,179,180,184,185,188,189,194,195,199,201,205,206,209,210,216,217,220,221,223,229,230,236,237,243,244,250,251,255,257,260,261,264,265,267,270,271,274,275,277,280,281,284,285,289,295,296,298,301,313,314,317,318,320,325,326,329,337,338,340,342,346,350,351,355,359,360,362,364,368,371,372,375,376,378,382,384,386,389,390,393,394,397,398,404,405,411,412,414,417,418,421,422,425,426,428,432,434,436,441,442,450,451,459,460,462,467,468,473,474,479,480 ./Parse/Parse/PFUser+Synchronous.h:9,12,14,21,25,28,30,32,36,39,41,43,45,49,53,56,59,62,67,70,73,77,82,86,89,92,94,99,102,105,108,113,117,122,126,129,132,134,138,141,144,150,152 ./Parse/Parse/PFInstallation.h:9,11,14,16,18,25,32,36,38,42,45,48,52,55,58,62,66,71,76,81,86,91,96,99,103,107,110,112,116,120,122 ./Parse/Parse/PFCloud+Synchronous.h:9,12,14,21,24,27,31,35,39,44,46 ./Parse/Parse/PFObject+Deprecated.h:9,12,17,21,24,30,35,39,42,49,55,59,62,68,73,76,82,87,90,96,101,105,109,116,122,126,133,139,143,146,152,157,161,164,171,177 ./Parse/Parse/PFUser.m:9,14,17,48,52,55,56,59,60,62,64,66,68,70,74,75,78,79,83,87,88,91,92,96,98,105,108,109,116,119,120,122,126,128,129,134,135,143,149,151,152,167,168,171,174,175,183,185,186,187,196,199,200,204,214,215,216,220,231,232,233,244,247,254,256,259,260,267,273,285,286,292,293,294,302,305,306,307,308,309,316,320,321,326,329,332,334,335,336,339,347,348,349,354,361,362,377,379,380,385,388,389,390,395,396,403,404,405,406,414,415,416,417,422,429,430,436,441,448,449,460,461,463,464,465,468,469,477,479,480,491,492,497,498,505,506,511,513,518,525,526,530,533,539,542,543,547,548,553,560,561,566,581,582,583,588,590,595,597,598,599,600,607,608,609,610,614,623,628,629,633,637,642,643,650,653,655,656,658,660,661,662,675,677,685,686,690,698,699,706,707,712,713,719,723,726,727,733,737,738,742,743,757,763,764,768,771,772,775,776,779,780,782,784,786,791,797,800,801,804,805,808,809,813,814,815,819,820,821,825,830,831,836,837,841,844,845,847,858,859,861,871,876,878,882,885,887,888,893,894,899,908,909,911,919,920,923,924,926,931,932,933,935,938,939,943,947,948,951,952,956,960,963,964,970,971,975,979,980,983,984,988,992,993,999,1000,1003,1011,1013,1015,1019,1020,1022,1027,1029,1030,1034,1040,1042,1043,1048,1049,1054,1055,1057,1058,1063,1064,1066,1067,1070,1071,1075,1076,1085,1086,1087,1090,1091,1095,1096,1104,1107,1108,1112,1114,1115,1121,1122,1126,1128,1129,1134,1135,1139,1140,1148,1150,1151,1152,1155,1156,1159,1160,1170,1171,1173,1174,1175,1178,1179,1183,1185,1190,1191,1193,1197,1199,1201,1204,1205,1208,1209,1211,1214,1215,1218,1219,1221,1224,1225,1228,1229,1231,1234,1235,1237,1240,1241,1244,1245,1247,1251,1253,1255,1260,1261,1263,1271,1272,1274,1279,1280,1282,1287,1288 ./Parse/Parse/Parse.m:9,29,33,35,37,39,42,49,51,52,53,57,63,65,69,70,79,82,84,88,97,98,99,102,103,106,107,112,113,116,117,122,123,126,127,130,131,135,141,143,144,151,154,155,160,161,166,167,170,171,175,179,183,184,188,190,191,195,197,200,201,204,205,207,211,214,215,218,219,223,226,227,230,231,235,238,239,242,243,246,247,255,256 ./Parse/Parse/PFACL.h:9,11,13,16,24,28,31,35,38,42,46,51,56,60,63,68,73,75,79,82,87,92,94,98,101,106,111,113,117,120,125,130,132,136,140,144,146,150,153,158,162,164,168,171,176,180,183,185,189,192,195,200,204,207,209,213,216,219,224,228,231,241,243 ./Parse/Parse/PFCloud.m:9,11,18,20,24,33,34,39,40,42,46,48,51,52,55,56,58,62,64,72,73 ./Parse/Parse/PFQuery+Synchronous.h:9,12,14,21,25,28,31,35,38,42,46,49,52,54,58,61,64,67,71,75,78,80,84,92,96,99,103,106,108,112,116,119,121,125,128,130,132,136,140,143,147,150,152,156,158 ./Parse/Parse/PFCloud+Deprecated.h:9,12,14,19,23,30,37,39 ./Parse/Parse/PFDecoder.h:9,11,13,15,20,27,29,35,37,39,44,46,48 ./Parse/Tests/Unit/RoleUnitTests.m:9,11,17,19,21,23,28,33,34,37,38,41,44,45,49,52,53,56,61,64,71,73,76,77 ./Parse/Tests/Unit/DecoderTests.m:9,18,20,22,24,28,29,34,35,38,42,47,48,51,54,58,59,62,66,71,72,75,79,83,86,87,90,95,99,101,102,105,110,115,116,119,126,130,133,134,137,142,146,149,150,153,161,165,168,172,176,177,180,185,189,192,193,196,203,206,217,218,221,225,229,231,232,235,238,242,245,246,250,254,255,259,267,271,276,277,281,285,286,290,298,301,305,306 ./Parse/Tests/Unit/ParseSetupUnitTests.m:9,12,14,16,18,22,26,28,29,33,37,40,42,43,47,48,54,55 ./Parse/Tests/Unit/DefaultACLControllerTests.m:9,11,13,21,23,25,27,29,33,36,37,41,47,48,51,54,56,60,68,70,71,77,80,82,84,88,97,99,100,106,109,113,115,119,124,128,137,139,140 ./Parse/Tests/Unit/PushControllerTests.m:9,11,13,21,23,25,27,30,34,38,39,43,46,48,53,54,57,62,65,70,73,75,76 ./Parse/Tests/Unit/ObjectSubclassPropertiesTests.m:9,16,20,33,34,56,58,60,82,85,86,90,91,95,97,101,103,105,107,111,114,120,121,124,131,132,135,140,144,148,152,156,160,161,167,171,172,175,180,183,184,187,191,192,195,199,200,203,206,209,211,212,215,218,221,223,227,233,235,236,239,244,246,247,250,253,256,258,259,265,269,270,277,278,288,289,294,295,298,301,302,306,307 ./Parse/Tests/Unit/URLSessionCommandRunnerTests.m:9,11,14,25,27,29,31,35,46,57,58,64,67,69,71,76,78,83,87,92,94,95,101,103,105,110,113,119,124,125,131,133,138,140,143,149,151,157,162,164,169,171,172,178,180,185,188,193,195,197,203,213,215,216,222,225,227,233,235,239,246,248,253,266,268,269,275,278,280,282,287,289,294,298,303,305,306,315,316,325,326,335,336,346,347,360,362,369,371,378,379 ./Parse/Tests/Unit/OfflineQueryLogicUnitTests.m:9,16,19,20,22,24,28,31,33,34,37,39,40,44,48,52,56,64,68,76,80,88,93,101,107,115,121,129,134,142,144,145,149,153,157,165,169,177,181,189,194,202,207,215,220,228,230,231,235,242,245,253,257,265,269,277,281,289,293,301,305,313,317,325,330,338,342,350,355,363,368,376,378,379,383,390,393,401,405,413,417,425,429,437,441,449,453,461,465,473,477,485,489,497,502,510,515,523,525,526,530,537,540,548,552,560,564,572,576,584,588,596,600,608,612,620,624,632,636,644,649,657,662,670,672,673,677,684,687,695,699,707,711,719,723,731,735,743,747,755,759,767,771,779,783,791,796,804,809,817,819,820,824,831,834,842,846,854,858,866,870,878,882,890,894,902,906,914,916,917,921,928,931,939,943,951,955,963,967,975,979,987,991,999,1003,1011,1013,1014,1018,1025,1028,1036,1040,1048,1052,1060,1064,1072,1076,1084,1088,1096,1098,1099,1103,1109,1112,1120,1124,1132,1136,1144,1146,1147,1151,1160,1163,1171,1175,1183,1187,1195,1199,1207,1211,1219,1223,1231,1235,1243,1247,1255,1259,1267,1271,1279,1283,1291,1295,1303,1307,1315,1317,1318,1322,1329,1332,1340,1344,1352,1356,1364,1366,1367,1371,1377,1380,1388,1392,1400,1402,1403,1407,1413,1417,1425,1430,1438,1440,1441,1445,1452,1459,1467,1469,1470,1473,1479,1482,1488,1489,1490,1493,1499,1502,1508,1509,1510,1513,1519,1522,1528,1529,1530,1533,1540,1545,1552,1553,1554,1557,1559,1562,1567,1568 ./Parse/Tests/Unit/ObjectLocalIdStoreTests.m:9,11,18,20,22,24,28,33,34,38,43,47,51,52,57,59,64,69,73,77,82,86,91,95,99,103,107,111,113,114,119,121,127,129,130,134,136,141,142,147,156,157 ./Parse/Tests/Unit/OperationSetUnitTests.m:9,14,16,18,20,27,28,32,37,40,43,46,49,50,65,70,74,77,78,85,88,91,92,95,98,100,105,106,109,112,116,123,124,128,134,135,140,144,146,147 ./Parse/Tests/Unit/CommandURLRequestConstructorTests.m:9,11,20,22,24,26,30,37,38,42,46,51,52,57,64,73,74,79,87,95,103,111,112,117,127,128,133,144,145,158,159,164,177,178 ./Parse/Tests/Unit/ObjectCommandTests.m:9,14,16,18,20,30,31,36,40,44,45,58,69,70,77,78,91,92,99,105,111,112,122,123,128,132,133 ./Parse/Tests/Unit/ConfigUnitTests.m:9,11,13,20,22,24,26,28,32,35,37,38,41,43,44,48,52,55,59,60,62,63,66,67,71,74,77,78,81,84,85,88,91,94,97,99,100,103,106,109,113,114 ./Parse/Tests/Unit/PolygonUnitTests.m:9,11,18,21,22,24,26,29,31,32,36,37,43,44,47,50,54,55,58,62,66,67,74,75,82,83,87,88,91,94,95,100,101,104,107,110,111,116,120,121 ./Parse/Tests/Unit/ConfigCommandTests.m:9,13,15,17,19,27,28,37,38 ./Parse/Tests/Unit/ObjectBatchControllerTests.m:9,11,23,25,27,29,33,39,40,44,47,51,55,56,58,62,72,74,76,86,90,91,95,98,99,103,113,115,118,129,133,134,136,141,143,154,158,164,169,170,174,177,178,183,185,189,196,198,203,204,215,216,218,223,229,230,235,239,240,246,247,254,261,262,271,274,280,281 ./Parse/Tests/Unit/FieldOperationDecoderTests.m:9,15,17,19,21,25,26,30,31,35,36,39,47,48,51,59,60,63,71,72,75,83,84,87,93,94,97,113,114,117,131,132,135,145,146,149,159,160 ./Parse/Tests/Unit/HashTests.m:9,11,13,15,17,19,24,25,30,34,35 ./Parse/Tests/Unit/AnalyticsControllerTests.m:9,11,18,20,22,24,28,34,35,41,42,46,49,53,57,58,62,67,70,80,81,87,91,94,99,101,102,109,119,120,126,130,133,137,139,140,147,156,157 ./Parse/Tests/Unit/PushUnitTests.m:9,11,13,26,28,31,33,35,39,44,47,49,50,53,56,57,61,64,66,67,71,75,78,79,84,85,87,93,97,101,104,108,112,116,120,124,128,132,136,140,144,145,150,155,158,163,168,173,178,183,184,188,190,193,196,200,202,205,207,209,211,214,218,221,223,227,229,233,235,238,240,243,247,253,256,262,264,269,271,272,276,278,282,286,289,295,303,306,312,321,323,324,329,331,335,339,342,347,350,356,365,367,368,372,374,378,382,384,390,398,401,403,404,409,411,415,419,421,426,434,437,439,440,444,446,449,452,456,461,464,470,476,478,479,482,484,487,490,495,501,504,510,512,519,521,522,525,527,530,533,538,544,547,553,555,562,564,565,569,572,574,576,579,582,585,588,591,592,595,598,601,603,604,608,612,616,620,624,625,629,634,635,639,644,645,650,655,656 ./Parse/Tests/Unit/FileDataStreamTests.m:9,11,13,15,17,19,21,24,25,28,30,31,35,42,45,47,50,52,54,56,58,61,62,65,68,75,79,82,86,89,92,96,100,103,105,106 ./Parse/Tests/Unit/ExtensionDataSharingMobileTests.m:9,15,17,20,21,23,25,29,32,34,37,38,43,48,51,53,55,56,60,63,67,72,73,74 ./Parse/Tests/Unit/GeoPointLocationTests.m:9,15,17,19,21,25,28,30,31,35,38,51,57,60,65,68,69,72,79,82,88,91,92,97,106,110,111,116,124,125 ./Parse/Tests/Unit/AnalyticsUnitTests.m:9,11,13,17,19,21,23,27,31,36,37,41,53,54,58,64,65,69,74,82,83,96,101,102,115,116,120,127,131,132,136,143,147,155,156,160,162,166,167,171,173,177,185,186 ./Parse/Tests/Unit/QueryUtilitiesTests.m:9,13,15,17,19,23,26,27,33,34,38,39,43,52,54,55,64,66,67,70,73,74,78,79,83,84,87,90,91,95,97,100,101,105,108,111,112,115,119,120 ./Parse/Tests/Unit/RelationUnitTests.m:9,11,13,19,21,23,25,30,34,36,39,41,45,46,49,53,56,60,62,66,67,69,72,76,79,83,84,85,88,91,93,95,96,99,102,105,107,108,111,114,117,119,122,124,127,130,132,133,138,141,143,147,148,159,162,165,166,170,172,173 ./Parse/Tests/Unit/PinUnitTests.m:9,13,15,17,19,23,26,29,32,33 ./Parse/Tests/Unit/ConfigControllerTests.m:9,11,13,22,24,26,28,30,32,36,42,43,47,50,54,55,58,60,62,63,73,75,77,80,83,85,88,90,91 ./Parse/Tests/Unit/CurrentConfigControllerTests.m:9,11,13,22,24,26,28,32,35,36,42,43,51,52,56,59,63,67,68,73,76,81,85,87,88,93,96,102,107,111,113,114,119,121,123,129,134,138,140,148,150,151,156,158,160,166,171,175,180,183,185,187,188 ./Parse/Tests/Unit/ObjectEstimatedDataTests.m:9,14,16,18,20,26,31,37,43,46,54,55,61,62,68,79,82,83,88,89,98,99 ./Parse/Tests/Unit/ObjectFileCoderTests.m:9,16,18,20,22,27,32,33,38,45,46 ./Parse/Tests/Unit/CloudCodeControllerTests.m:9,11,13,20,22,24,26,30,33,37,41,42,47,51,56,61,63,64,72,74,84,85,93,95,106,107 ./Parse/Tests/Unit/CloudCommandTests.m:9,13,15,17,19,30,40,41 ./Parse/Tests/Unit/ObjectStateTests.m:9,15,17,19,21,25,31,32,37,38,42,48,53,54,58,61,64,67,72,77,82,87,88,91,94,97,100,103,104,110,115,116,120,123,128,129,132,135,138,141,145,148,149,153,156,159,162,165,167,168,172,175,178,179,186,193,196,197,204,208,210,215,216,224,229,232,233 ./Parse/Tests/Unit/BaseStateTests.m:9,11,14,18,19,21,27,29,31,35,37,39,40,44,51,52,55,56,58,60,62,64,68,72,74,77,78,82,85,87,91,94,95,98,101,104,107,109,112,114,115,117,121,122,125,127,130,134,137,139,142,143,145,150,151,154,156,159,161,163,166,169,173,174,177,179,182,184,186,189,192,195,196,200,204,206,208,210,212,213,217,219,220,224,227,231,233,236,238,239,243,245,246,247,251,254,257,261,264,266,268,270,272,273,277,280,283,285,288,291,293,296,297,301,305,307,309,310 ./Parse/Tests/Unit/SessionUnitTests.m:9,11,19,21,23,25,29,36,37,41,42,46,50,51,61,62,65,67,74,76,83,84,88,89,93,94,99,107,108,113,121,122,127,135,136,141,149,150 ./Parse/Tests/Unit/DeviceTests.m:9,12,14,16,18,23,24,29,30,35,38,39,44,45,50,51,55,56 ./Parse/Tests/Unit/URLSessionTests.m:9,11,14,21,26,29,32,34,36,38,44,45,46,52,53,54,56,58,60,62,67,73,79,84,89,90,96,99,101,103,105,109,115,123,126,130,136,145,149,150,157,160,162,173,174,175,181,184,187,189,191,195,201,210,215,220,224,230,240,244,245,251,254,257,259,261,267,271,277,287,291,292,298,301,304,321,322,328,331,334,336,338,347,354,355,362,366,371,375,381,383,400,404,405,406,412,415,419,421,423,427,433,440,441,448,452,454,459,464,468,474,476,492,496,497,503,506,508,510,522,531,537,541,547,556,560,561,567,568 ./Parse/Tests/Unit/OfflineQueryControllerTests.m:9,11,14,28,30,32,34,38,43,49,55,56,60,65,69,73,76,81,84,86,91,93,96,98,99,103,106,110,113,116,119,121,126,128,131,133,134,138,145,148,152,155,158,160,167,172,181,184,186,191,194,200,202,205,207,210,211,215,221,224,227,230,233,235,238,241,247,249,252,254,255,259,265,267,271,273,280,285,294,297,299,304,307,313,315,318,320,321,325,329,331,334,336,339,342,348,350,353,355,356,360,366,368,372,375,378,380,382,386,389,391,396,400,402,403,407,412,416,419,422,424,427,430,436,440,442,443,447,453,455,459,461,468,473,482,485,487,493,496,498,499,503,507,509,512,514,517,520,526,528,531,533,534 ./Parse/Tests/Unit/ProductTests.m:9,13,15,17,19,22,25,26 ./Parse/Tests/Unit/ACLDefaultTests.m:9,11,13,15,17,19,24,28,29 ./Parse/Tests/Unit/PushManagerTests.m:9,11,18,20,22,24,28,34,35,41,42,47,48,52,56,62,68,69,73,77,83,84,88,92,98,99 ./Parse/Tests/Unit/AnalyticsUtilitiesTests.m:9,13,15,17,19,41,42 ./Parse/Tests/Unit/QueryControllerUnitTests.m:9,11,13,21,23,25,27,31,34,36,48,50,52,53,59,60,64,67,71,75,76,80,88,94,99,100,104,107,117,118,122,130,135,136,140,143,153,154,158,161,162,166,169,170,174,178,179,182,185,186 ./Parse/Tests/Unit/PushChannelsControllerTests.m:9,11,13,19,21,23,25,29,32,35,37,38,42,45,49,53,54,58,60,66,69,71,77,82,83,87,89,95,98,100,106,111,112,116,120,123,125,132,137,138,142,144,152,155,157,163,168,170,171,175,181,184,186,192,197,198,202,204,210,213,215,221,226,228,229,233,235,241,244,246,252,257,258 ./Parse/Tests/Unit/ObjectSubclassingControllerTests.m:9,13,18,21,24,28,29,34,37,39,41,44,47,49,52,53,55,57,60,61,63,65,67,70,71,73,74,75,77,79,82,83,85,88,90,92,94,98,101,102,110,114,116,117,121,125,126,130,132,133,138,143,144,148,150,152,154,155,159,163,166,169,172,173,177,181,185,186,189,190,195,197,203,208,209,214,220,227,233,239,245,252,260,267,270,271,276,277,282,284,285,290,295,302,310,318,326,332,333,338,344,350,356,362,369,380,385,386,391,398,403,410,418,424,425 ./Parse/Tests/Unit/LocationManagerTests.m:9,11,13,17,19,21,24,26,29,31,35,39,43,45,47,50,54,56,58,59,62,65,69,72,76,78,80,86,89,91,93,94,99,103,106,110,112,114,118,121,123,125,126 ./Parse/Tests/Unit/RelationStateTests.m:9,13,15,17,19,23,26,30,32,33,37,41,48,51,58,59,62,65,68,71,74,75,79,82,83,88,90,91 ./Parse/Tests/Unit/QueryPredicateUnitTests.m:9,13,15,17,19,23,27,28,31,32,36,40,43,46,49,52,55,58,62,66,69,72,77,78,86,87,90,93,96,97,101,104,105,109,112,116,119,120 ./Parse/Tests/Unit/ObjectUnitTests.m:9,15,17,19,21,25,27,33,36,41,42,47,48,52,57,60,84,91,96,97,99,105,106,110,111,115,119,123,124,127,132,133,136,139,142,146,150,153,156,160,161,164,167,170,173,174,179,182,183,189,190,202,210,211,213,216,226,227,229,233,239,242,250,251,253,265,266,279,280,282,287,291,295,297,298,309,320,321,332,333,338,348,349,354,362,363 ./Parse/Tests/Unit/QueryUnitTests.m:9,11,13,21,23,25,27,29,30,32,33,35,36,38,40,42,44,48,53,62,63,68,77,78,82,84,88,93,98,99,105,106,113,114,118,121,122,124,130,131,137,138,140,146,147,153,156,159,160,166,167,171,173,176,177,181,183,185,188,189,194,197,198,200,204,207,208,214,215,220,225,226,231,234,235,237,244,245,252,253,260,261,268,269,274,277,281,282,284,289,290,295,296,301,302,307,308,317,319,320,325,326,331,332,337,338,343,344,353,354,359,360,365,366,371,372,375,379,380,383,386,389,390,393,396,399,400,403,407,408,412,416,417,422,426,427,430,434,435,440,441,446,447,452,453,458,459,464,465,470,471,477,478,484,485,491,492,498,499,505,506,511,512,514,520,523,526,527,533,537,542,543,547,553,558,559,563,571,576,577,581,590,597,598,602,605,611,612,616,622,625,633,634,638,644,647,655,656,661,663,674,678,682,697,701,702,706,712,715,721,726,728,729,731,737,740,743,744,750,754,759,760,766,769,770,772,776,780,781,785,788,793,794,798,800,808,809,813,815,823,824,829,836,840,844,859,863,864,868,871,877,882,884,885,889,895,901,909,910,914,922,930,931,933,937,941,946,947,951,955,958,963,964,968,975,982,983,987,991,994,1002,1003,1007,1011,1014,1022,1023,1028,1030,1039,1043,1047,1062,1066,1067,1071,1075,1078,1084,1089,1091,1092,1094,1098,1102,1103,1107,1110,1115,1116,1120,1122,1130,1131,1135,1137,1145,1146,1151,1158,1162,1166,1181,1185,1186,1190,1192,1198,1203,1205,1206,1208,1214,1217,1220,1221,1227,1230,1233,1234,1240,1243,1246,1247,1253,1256,1258,1259,1265,1275,1276,1278,1281,1287,1290,1293,1295,1297,1299,1306,1309,1312,1314,1315,1317,1321,1324,1327,1330,1333,1336,1339,1342,1345,1349,1352,1355,1358,1361,1364,1367,1368,1377,1381,1387,1388,1392,1397,1402,1403,1406,1407,1409,1414,1415,1427,1428,1429 ./Parse/Tests/Unit/UserUnitTests.m:9,13,15,17,19,23,26,27,31,32,37,38,40,44,55,56,60,71,72 ./Parse/Tests/Unit/CloudUnitTests.m:9,11,17,19,21,23,25,27,29,33,40,41,47,48,52,58,63,64,68,71,76,77,81,89,90,94,102,103,107,109,113,121,123,124,128,136,137,141,149,150,154,156,160,168,170,171,175,178,182,183 ./Parse/Tests/Unit/PinningObjectStoreTests.m:9,11,18,20,22,24,28,34,35,39,41,44,45,48,52,56,57,60,66,68,76,77,80,86,88,99,100,103,108,110,120,121,125,131,133,144,145,149,151,154,159,161,172,173,177,185,186,190,192,199,201,212,213,217,221,226,228,237,238,242,246,251,253,262,263,267,275,276,284,294,295,298,305,307,316,317 ./Parse/Tests/Unit/PurchaseControllerTests.m:9,11,13,16,33,35,37,40,42,46,49,51,52,55,57,59,60,64,72,73,79,80,88,90,91,94,95,99,103,105,109,112,115,116,120,122,124,126,131,133,137,139,140,144,146,149,152,158,162,167,176,177,180,185,188,190,193,195,199,201,204,206,207,211,213,216,221,225,227,231,236,238,241,244,247,253,256,257,260,263,265,269,270,274,276,279,285,293,295,298,300,301,305,307,310,315,317,325,327,330,332,333,337,339,342,347,351,358,366,368,371,373,374 ./Parse/Tests/Unit/UserCommandTests.m:9,13,15,17,19,34,42,43,58,66,67,82,90,91,104,112,113,121,122,130,131,139,140,148,149 ./Parse/Tests/Unit/PropertyInfoTests.m:9,13,15,18,20,22,24,26,30,31,34,35,37,39,41,43,46,49,53,56,57,62,65,68,69,72,75,78,81,82,86,90,94,98,102,103,107,111,112 ./Parse/Tests/Unit/GeoPointUnitTests.m:9,11,15,17,19,21,24,28,29,32,36,40,41,44,47,52,53,56,62,63,67,70,73,74,79,80,85,98,104,109,115,120,125,130,136,141,146,150,155,158,161,164,167,170,173,176,179,182,186,190,193,196,199,203,204,208,211,212,215,218,222,223,227,231,235,236,240,241 ./Parse/Tests/Unit/ExtensionDataSharingTests.m:9,11,18,20,23,24,26,28,32,35,37,38,41,43,46,56,57,59,61,62,66,70,73,76,79,80,84,88,92,95,96,100,103,107,108,112,116,120,121,123,125,127,129,132,141,146,150,153,157,159,164,169,170,172,173,175,177,179,181,184,193,198,202,205,210,212,216,218,224,229,230,232,233 ./Parse/Tests/Unit/FileCommandTests.m:9,13,15,17,19,27,28 ./Parse/Tests/Unit/KeyValueCacheTests.m:9,11,17,20,22,26,29,30,33,34,38,41,42,46,56,59,64,72,73,80,83,85,88,89,95,98,101,103,106,108,109,114,117,119,120,128,130,131,139,142,144,147,149,152,154,155,163,166,169,171,174,176 ./Parse/Tests/Unit/IncrementUnitTests.m:9,12,14,16,18,22,25,26 ./Parse/Tests/Unit/ParseModuleUnitTests.m:9,12,14,16,18,20,24,25,27,29,31,33,36,39,41,44,46,47,50,54,55,57,60,62,63,66,69,72,74,78,79 ./Parse/Tests/Unit/URLSessionDataTaskDelegateTests.m:9,11,14,19,21,23,25,34,40,41,44,49,56,58,59,63,67,70,75,81,88,91,93,96,97,101,105,107,118,125,127,129,132,133,137,141,143,154,161,164,167,168,172,176,185,196,203,206,208,209 ./Parse/Tests/Unit/AlertViewTests.m:9,11,13,18,21,24,25,28,29,31,33,35,37,41,48,59,60,66,69,72,77,78,82,86,89,91,99,107,110,113,114,115,118,125,127,133,136,137,141,144,148,151,153,161,164,169,170,171 ./Parse/Tests/Unit/SQLiteDatabaseTest.m:9,11,17,20,22,24,28,31,32,36,39,41,42,47,50,53,56,58,59,63,76,77,81,106,107,124,131,139,144,147,158,163,166,179,187,188,203,208,211,220,225,228,240,247,257,261,274,279,287,302,307,319,324,327,328,350,353,357,358,374,379,387,392,396,407,412,416,420,421,437,442,445,449,458,466,476,477,488,489,502,503,515,520,525,530,535,540,545,550,555,560,565,570,575,580,585,590,595,600,605,608,609 ./Parse/Tests/Unit/LocationManagerMobileTests.m:9,12,14,17,21,25,27,30,32,34,37,39,41,43,45,48,52,54,58,61,65,68,73,77,83,86,88,90,91,94,98,100,104,107,111,114,119,123,129,132,134,136,137 ./Parse/Tests/Unit/ObjectSubclassTests.m:9,15,19,22,23,25,29,31,34,38,40,42,43,46,47,49,51,53,55,58,59,61,64,66,70,72,74,75,78,79,81,84,87,90,94,96,98,100,102,104,106,109,110,112,116,118,120,122,126,130,135,136,140,145,146,150,151,156,157,163,164,169,172,173 ./Parse/Tests/Unit/URLConstructorTests.m:9,11,13,15,17,19,33,34,76,77 ./Parse/Tests/Unit/PushCommandTests.m:9,15,17,19,21,23,26,33,34,38,45,46,49,53,60,61,65,73,74,78,86,87,91,100,101,105,112,113,115 ./Parse/Tests/Unit/InstallationUnitTests.m:10,20,22,24,26,31,32,39,45,49,51,58,66,67,71,75,76,80,84,85,94,95,111,112 ./Parse/Tests/Unit/InstallationIdentifierUnitTests.m:9,11,17,19,21,23,27,30,41,42,45,47,53,55,58,60,63,64,72,73,80,83,86,88,96,97 ./Parse/Tests/Unit/FieldOperationTests.m:9,11,15,17,19,21,25,29,30,34,35,40,41,45,46,50,55,59,60,64,65,69,70,81,82,86,89,90,94,98,101,102,106,107,110,113,116,117,129,130,134,139,143,144,148,149,152,155,158,161,162,166,171,173,177,181,184,185,189,194,195,199,200,204,209,210,213,215,219,222,224,227,230,233,234,238,243,244,248,249,253,258,259,262,264,268,271,273,276,279,282,283,287,292,293,297,298,302,307,308,311,313,317,322,325,328,329,333,336,342,348,352,353,357,360,361,366,371,376,378,384,387,388,392,399,400 ./Parse/Tests/Unit/ObjectUtilitiesTests.m:9,14,16,18,20,23,29,30,33,38,39,47,48 ./Parse/Tests/Unit/FileStateTests.m:9,12,14,16,18,22,25,26,29,34,35,39,46,52,53,56,59,62,63,66,71,76,77,86,94,95,99,102,103,108,109,119,120,127,131,135,139,140 ./Parse/Tests/Unit/ParseClientConfigurationTests.m:9,11,16,19,21,23,26,28,29,32,34,35,44,50,51,57,64,71,78,85,91,92,101,103,106,108,110,116,117,120,124,128,131,133,136,137,142,146,147 ./Parse/Tests/Unit/DateFormatterTests.m:9,12,14,16,18,22,23,28,29,34,36,40,41,42,48,52,55,58,59,60 ./Parse/Tests/Unit/PurchaseUnitTests.m:9,11,13,23,25,27,29,31,33,37,45,47,50,52,53,57,62,64,69,72,77,86,88,89,93,96,102,104,105,109,111,116,118,120,121,125,127,132,136,140,147,152,155,157,158,162,164,166,169,170,172,177,180,181 ./Parse/Tests/Unit/CommandUnitTests.m:9,19,21,23,25,29,32,34,35,39,49,55,63,67,69,70,80,86,95,99,101,102,108,114,119,125,128,129 ./Parse/Tests/Unit/ObjectBatchCommandTests.m:9,15,17,19,21,23,27,37,44,49,51,52,56,71,72,75,79,86,87,89 ./Parse/Tests/Unit/SessionControllerTests.m:9,11,21,23,25,27,31,34,40,41,45,48,49,53,56,60,64,65,68,71,74,78,86,87,94,103,108,109,113,122,123 ./Parse/Tests/Unit/ObjectFilePersistenceControllerTests.m:9,11,17,19,21,23,27,32,33,39,40,45,46,50,56,60,61,65,67,71,75,83,88,90,91,95,105,107,110,118,120,121,125,129,131,139,141,142 ./Parse/Tests/Unit/QueryCachedControllerTests.m:9,11,13,23,25,27,29,31,33,37,40,43,46,48,49,56,57,67,68,72,78,79,83,86,90,94,95,103,106,116,117,121,124,127,137,138,143,146,155,160,161,164,167,173,176,186,187,193,199,202,212,213,216,220,223,233,234,237,241,247,250,260,261,264,267,273,276,286,287,292,302,303,308,318,319,327,330,340,341,347,350,360,361,365,368,371,374,375,379,382,384,389,391,396,399,400,405,409,411,412,417,420,422,423 ./Parse/Tests/Unit/AnonymousUtilsTests.m:9,11,19,21,23,25,27,29,31,34,37,38,43,45,46,50,55,56,60,64,68,72,74,75,77,79,83,86,95,96,98,100,104,107,116,117,119,121,125,128,130,135,140,143,144 ./Parse/Tests/Unit/URLSessionUploadTaskDelegateTests.m:9,11,14,18,20,22,24,33,42,48,57,58,65,72,74,75,79,85,88,90,95,98,103,110,111,113,120,123,125,129,130,134,138,142,145,150,156,163,166,168,171,172,176,180,182,193,200,202,204,207,208,212,216,218,229,236,239,242,243,247,251,260,271,278,281,283,284 ./Parse/Tests/Unit/QueryStateUnitTests.m:9,13,15,17,19,23,35,38,40,45,46,50,58,65,67,68,72,78,83,84,89,92,95,98,99,103,106,107,111,114,115,119,122,123,127,129,130,134,136,137,141,144,145,150,153,154,157,160,163,164,167,170,172,175,178,181,182,185,189,192,193,198,201,202,207,210,211,214,218,221,224,225,228,231,232,236,239,240 ./Parse/Tests/Unit/ObjectPinTests.m:9,11,17,19,21,23,27,31,36,38,39,43,46,48,49,53,56,58,59,63,65,69,72,73,76,79,84,85,89,98,99,103,112,113,117,120,121,124,127,132,133,137,146,147,151,160,161,163,167,170,171,174,177,182,183,187,196,197,201,210,211,215,218,219,222,225,230,231,235,244,245,249,258,259,261,265,268,269,272,275,280,281,285,294,295,299,308,309,313,316,317,320,323,328,329,333,342,343,347,356,357,359,363,366,367,370,373,378,379,383,392,393,397,406,407,411,414,415,418,421,426,427,431,440,441,445,454,455,460,461,465,470,471,474,483,484,487,496,497,502,503,507,512,513,516,525,526,529,538,539 ./Parse/Tests/Unit/KeychainStoreTests.m:9,12,14,16,18,20,24,27,29,30,34,36,37,41,45,46,50,51,56,59,60,65,68,69,72,74,77,81,84,87,90,93,96,99,102,105,108,110,112,113,114,116,117,121,124,125,129,132,133,139,141,144,145,150,151,157,158,165,166 ./Parse/Tests/Unit/PushMobileTests.m:9,11,15,17,19,21,25,29,32,34,36,37,41,45,47,49,51,53,54,58,62,65,67,69,70,75,79,82,84,86,87,91,95,98,100,102,103 ./Parse/Tests/Unit/ObjectFileCodingLogicTests.m:9,15,17,19,21,25,28,30,31,36,39,44,45,54,57,64,69,70 ./Parse/Tests/Unit/UserFileCodingLogicTests.m:9,14,16,18,20,24,27,29,30,39,42,47,51,52,59,62,65,69,70 ./Parse/Tests/Unit/FileControllerTests.m:9,11,15,22,24,26,28,30,32,36,43,45,46,49,50,55,57,62,63,67,70,72,73,77,78,82,85,88,91,92,95,101,104,111,120,123,125,129,132,137,141,143,147,148,151,157,160,163,166,173,185,187,191,199,202,207,208,217,220,226,227,229,231,232,235,241,244,246,255,258,263,266,267,280,281,284,290,293,302,305,310,317,326,327,330,335,338,341,353,355,359,370,375,376,388,394,395,397,399,400,403,409,412,413,414,419,427,432,449,450,455,461,465,473,478,481,494,497,498,502,505,509,514,521,523,524,528,531,535,537,544,546,547 ./Parse/Tests/Unit/FileUnitTests.m:9,11,13,21,24,26,30,33,34,36,37,39,41,42,44,46,48,50,51,52,54,56,58,60,64,68,70,71,74,75,80,82,83,91,92,96,100,108,110,111,118,119,122,123,127,130,132,133,137,145,152,159,166,175,182,190,191,194,200,204,205,211,219,222,225,226,230,233,235,239,247,255,262,269,275,280,282,283,289,291,300,301,306,314,315,320,323,326,329,331,335,338,342,350,358,365,372,380,387,396,403,410,415,423,432,441,450,459,468,470,471,477,479,488,489,494,497,503,506,509,510,513,516,526,528,529,533,543,545,546 ./Parse/Tests/Unit/AnonymousAuthenticationProviderTests.m:9,11,14,16,18,20,24,25,28,33,34,38,39,43,44 ./Parse/Tests/Unit/SessionUtilitiesTests.m:9,12,14,16,18,21,22,25,26,29,30,33,34 ./Parse/Tests/Unit/ObjectOfflineTests.m:9,11,16,18,20,22,25,27,29,34,36,37,38,40,44,49,50,54,57,61,63,64,67,70,72,76,78,79,82,85,93,95,96,98,100,102,105,113,115,116,118,119 ./Parse/Tests/Unit/PushStateTests.m:9,14,16,18,20,24,34,35,43,44,48,57,65,66,69,72,75,78,81,82,86,89,90,95,96,99,104,109,112,115,120,121,126,129,130,135,138,147,148 ./Parse/Tests/Unit/UserControllerTests.m:9,11,22,24,26,28,32,38,39,45,46,50,54,60,65,66,71,76,81,84,86,92,95,106,108,109,116,121,124,127,139,140,145,150,156,159,161,167,170,183,185,186,193,198,201,204,218,220,221,228,233,236,239,249,251,252,259,263,266,269,279,281,282 ./Parse/Tests/Unit/ACLStateTests.m:9,13,15,17,19,24,28,32,36,43,50,51,55,59,63,67,70,71 ./Parse/Tests/Unit/CommandResultTests.m:9,12,14,16,18,23,31,39,40 ./Parse/Tests/Unit/AnalyticsCommandTests.m:9,13,15,17,19,29,36,37,47,57,58,67,68 ./Parse/Tests/Unit/ACLTests.m:9,11,18,20,22,24,28,33,38,39,43,46,47,50,53,56,59,60,64,68,70,75,78,81,84,87,88,92,96,98,103,106,109,112,115,116,119,121,126,128,131,134,138,140,142,145,147,150,153,155,157,161,162,166,169,172,174,176,177,181,184,186,187,191,194,196,198,199,204,208,209,210,211,234,235,242,245,251,252 ./Parse/Tests/Other/Cache/TestCache.m:9,11,15,16,19,20,24,27,29,30,36,38,39,44,45,50,51,56,57 ./Parse/Tests/Other/Cache/TestCache.h:9,11,18,20,25 ./Parse/Tests/Other/ExtensionDataSharing/PFExtensionDataSharingTestHelper.m:9,11,14,16,19,21,23,27,32,33,41,42,44,48,49,51,58,60,61,65,66,70,78,79,82,83,86,87 ./Parse/Tests/Other/ExtensionDataSharing/PFExtensionDataSharingTestHelper.h:9,11,13,16,19 ./Parse/Tests/Other/StoreKitMocking/PFTestSKPaymentTransaction.h:9,11,13,21,25 ./Parse/Tests/Other/StoreKitMocking/PFTestSKPaymentQueue.m:9,11,13,15,17,18,20,22,30,31,35,36,39,40,44,46,49,51,53,54,65,66,69,70,72,73,76,77,83,84 ./Parse/Tests/Other/StoreKitMocking/PFTestSKProductsResponse.h:9,11,13,16 ./Parse/Tests/Other/StoreKitMocking/PFTestSKProductsRequest.m:9,11,13,15,17,19,21,23,27,30,31,35,39,41,43,44,52,55,58,65,66,68,69 ./Parse/Tests/Other/StoreKitMocking/PFTestSKProduct.m:9,11,13,18,20,22,27,38,39 ./Parse/Tests/Other/StoreKitMocking/PFTestSKPaymentTransaction.m:9,11,13,22,31,32 ./Parse/Tests/Other/StoreKitMocking/PFTestSKPaymentQueue.h:9,11,13,15 ./Parse/Tests/Other/StoreKitMocking/PFTestSKProductsResponse.m:9,11,13,15,18,20,22,25,28,29,34,37,39,40 ./Parse/Tests/Other/StoreKitMocking/PFTestSKProduct.h:9,11,13,18 ./Parse/Tests/Other/StoreKitMocking/PFTestSKProductsRequest.h:9,11,13,15 ./Parse/Tests/Other/Swizzling/PFTestSwizzledMethod.h:9,11,13,15,20,26 ./Parse/Tests/Other/Swizzling/PFTestSwizzlingUtilities.h:9,11,13,15,17,29 ./Parse/Tests/Other/Swizzling/PFTestSwizzlingUtilities.m:9,11,13,24,25,33,34,46,47 ./Parse/Tests/Other/Swizzling/PFTestSwizzledMethod.m:9,11,13,15,18,20,22,26,34,38,39,43,44,46,47,57,58,62,66,68,69,70 ./Parse/Tests/Other/Swift/SwiftSubclass.swift:9,11,13,16,19,22,24,27,28,31,32,39,40,44,50,54,61,62,66,67,76,79,80,81,82,86,87 ./Parse/Tests/Other/NetworkMocking/PFMockURLResponse.m:9,11,13,16,19,21,23,25,29,32,33,39,40,43,44,50,51,60,61,72,73 ./Parse/Tests/Other/NetworkMocking/PFMockURLProtocol.m:9,11,13,15,19,21,23,25,29,31,34,36,38,41,45,50,51,57,58,64,69,72,74,82,83,84,89,91,92,97,98,100,101,104,105,109,112,113,116,117,120,121,128,130,131,137,139,141,142,145,146,150,153,155,162,165,166,176,177,181,184,185,188,189,192,193 ./Parse/Tests/Other/NetworkMocking/PFMockURLResponse.h:9,11,13,16,19,21,22,25,34,39 ./Parse/Tests/Other/NetworkMocking/PFMockURLProtocol.h:9,11,13,16,18,25,27 ./Parse/Tests/Other/FileManager/TestFileManager.m:9,11,13,15,19,21,27,31,32,35,36,40,45,47,48,54,56,57,62,65,68,71,72,78,80,81,88,89,92,93,99,101,102,107,109,112,114,115,117,121,124,125,129,132,136,138,139,145,147,148,155,157,159,161,162,165,166 ./Parse/Tests/Other/FileManager/TestFileManager.h:9,11,13,15,26 ./Parse/Tests/Other/LocationManager/CLLocationManager+TestAdditions.h:9,11,14,16,20,24,26 ./Parse/Tests/Other/LocationManager/CLLocationManager+TestAdditions.m:9,11,13,15,17,19,21,23,25,29,33,39,43,45,46,47,55,56,57,60,61,64,65,70,71,75,85,86,87 ./Parse/Tests/Other/OCMock/OCMock+Parse.h:9,11,13,15,17 ./Parse/Tests/Other/OCMock/OCMock+Parse.m:9,11,13,16,18,29,30 ./Parse/Tests/Other/TestCases/TestCase/PFTestCase.h:9,11,13,15,19,22,26,29,33,37,40,42,46,48,50,54,60,66,72,78,81,84,87,90,93,96 ./Parse/Tests/Other/TestCases/TestCase/PFTestCase.m:9,11,13,15,17,19,21,23,25,27,29,32,33,35,39,40,45,46,50,62,65,66,70,73,75,76,79,81,82,85,88,89,94,96,97,101,106,107,110,111,115,121,122,125,126,131,132,138,139,142,143,146,158,160,167,168,169,170,174,179,180 ./Parse/Tests/Other/TestCases/UnitTestCase/PFUnitTestCase.h:9,11,13,15,18,22,25,27 ./Parse/Tests/Other/TestCases/UnitTestCase/PFUnitTestCase.m:9,11,14,16,19,21,23,27,30,33,37,39,41,42,46,48,49 ./ParseUI/Generated/PFResources.m:5,6,7,10,11,13,14,15,18,19,21,22,23,26,27,29,30,31,34,35,37,38,39,42,43,45,46,47,50,51,53,54,55,58,59,61,62,63,66,67,69,70,71,74,75,77,78,79,82,83,85,86,87,90,91,93,94,95,98,99 ./ParseUI/ParseUIDemo/Classes/AppDelegate.h:21,23,25,27 ./ParseUI/ParseUIDemo/Classes/PFUIDemoViewController.m:21,23,25,41,76,78,80,81,83,85,87,90,93,94,97,98,101,102,105,106,109,112,115,149,150,151,154,157,158,161,162,165,169,170,172,174,175,178,185,190,195,201,206,210,215,220,227,232,238,245,254,263,274,283,290,302,309,312,323,332,337,341,345,350,358,367,377,388,398,408,417,426,430,436,440,441,442,443,446,449,450,453,454,457,460,461,464,465 ./ParseUI/ParseUIDemo/Classes/CustomViewControllers/SignUpViewController/CustomSignUpViewController.m:21,23,25,28,30,35,36 ./ParseUI/ParseUIDemo/Classes/CustomViewControllers/SignUpViewController/CustomSignUpViewController.h:21,23,25 ./ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryCollectionViewController/PaginatedCollectionViewController.h:21,23,25 ./ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryCollectionViewController/SubtitleImageCollectionViewController.m:21,23,25,28,30,33,37,41,43,44,47,50,52,55,56,59,61,65,66,69,74,77,83,84,87,89,90 ./ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryCollectionViewController/SimpleCollectionViewController.h:21,23,25 ./ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryCollectionViewController/SectionedCollectionViewController.h:21,23,25 ./ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryCollectionViewController/StoryboardCollectionViewController.h:21,23,25 ./ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryCollectionViewController/DeletionCollectionViewController.m:21,23,25,27,29,31,33,36,44,46,47,50,53,55,58,66,67,70,72,76,77,78,81,89,90,91,97,101,104,112,117,125,128,130,131,132,135,136,138,145,148,150,151,154,157,160,164,165 ./ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryCollectionViewController/PaginatedCollectionViewController.m:21,23,26,28,30,33,37,42,44,45,48,51,53,56,57,60,62,66,67,70,75,76,79,85,92,95,97,98 ./ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryCollectionViewController/SubtitleImageCollectionViewController.h:21,23,25 ./ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryCollectionViewController/StoryboardCollectionViewController.m:21,23,25,27,29,32,35,37,40,41,44,46,50,51,52,55,60,61,64,70,77,80,82,83 ./ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryCollectionViewController/SectionedCollectionViewController.m:21,23,26,28,31,33,35,37,39,43,47,49,50,53,55,56,58,60,63,64,66,69,71,74,78,81,83,85,86,89,92,94,97,99,100,103,105,109,110,113,116,120,126,127,128,131,132,136,137,140,143,144,148,149,154,157,160,162,163,170,172,173,177,179,180 ./ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryCollectionViewController/SimpleCollectionViewController.m:21,23,25,27,29,32,36,40,42,43,46,49,51,54,55,58,60,64,65,68,73,74,77,83,90,93,95,96 ./ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryCollectionViewController/DeletionCollectionViewController.h:21,23,25 ./ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryTableViewController/DeletionTableViewController.h:21,23,25 ./ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryTableViewController/PaginatedTableViewController.m:21,23,26,28,30,33,41,43,44,47,52,53,56,61,65,66,69,71,72 ./ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryTableViewController/SectionedTableViewController.h:21,23,25,27 ./ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryTableViewController/CustomProductTableViewController.m:21,23,26,28,32,44,45,46 ./ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryTableViewController/SubtitleImageTableViewController.m:21,23,25,27,29,34,38,39,42,45,47,48 ./ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryTableViewController/StoryboardTableViewController.h:21,23,25 ./ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryTableViewController/SimpleTableViewController.h:21,23,25,27 ./ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryTableViewController/PaginatedTableViewController.h:21,23,25,27 ./ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryTableViewController/DeletionTableViewController.m:21,23,25,27,29,31,33,36,40,43,45,46,49,57,58,61,69,70,71,77,81,84,92,97,105,108,110,111,112,115,116,121,122,123,126,129,132,136,137 ./ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryTableViewController/CustomProductTableViewController.h:21,23,25 ./ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryTableViewController/SectionedTableViewController.m:21,23,26,28,30,33,34,36,38,41,47,49,51,52,55,58,62,68,69,70,73,74,78,79,82,85,86,89,90,94,95,100,104,105,107,109,110 ./ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryTableViewController/StoryboardTableViewController.m:21,23,26,28,30,33,38,39,42,47,51,52,55,57,58 ./ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryTableViewController/SubtitleImageTableViewController.h:21,23,25 ./ParseUI/ParseUIDemo/Classes/CustomViewControllers/QueryTableViewController/SimpleTableViewController.m:21,23,26,28,30,33,40,42,43,46,51,52,55,60,64,65,68,70,71 ./ParseUI/ParseUIDemo/Classes/CustomViewControllers/LogInViewController/CustomLogInViewController.h:21,23,25 ./ParseUI/ParseUIDemo/Classes/CustomViewControllers/LogInViewController/CustomLogInViewController.m:21,23,25,28,30,36,37 ./ParseUI/ParseUIDemo/Classes/PFUIDemoViewController.h:21,23,25,27 ./ParseUI/ParseUIDemo/Classes/AppDelegate.m:21,23,28,30,32,35,42,46,50,52,53,62,63,66,80,82,89,94,96,97,98,102,110,112,117,118,119,122,123,124 ./ParseUI/ParseUIDemo/Other/main.m:21,23,25,29,30 ./ParseUI/ParseUIDemo/Swift/CustomViewControllers/ProductTableViewController/CustomProductTableViewController.swift:21,23,26,28,36,37,38,40,41,42 ./ParseUI/ParseUIDemo/Swift/CustomViewControllers/SignUpViewController/CustomSignUpViewController.swift:21,23,26,28,31,33,39,40,41 ./ParseUI/ParseUIDemo/Swift/CustomViewControllers/QueryCollectionViewController/PaginatedCollectionViewController.swift:21,23,26,28,30,36,42,45,46,48,51,56,57,58,60,63,64,66,70,77,81,82,85,87,88,89 ./ParseUI/ParseUIDemo/Swift/CustomViewControllers/QueryCollectionViewController/StoryboardCollectionViewController.swift:21,23,26,28,30,33,37,38,39,42,47,48,49,51,54,55,57,61,68,72,73,76,78,79 ./ParseUI/ParseUIDemo/Swift/CustomViewControllers/QueryCollectionViewController/SubtitleImageCollectionViewController.swift:21,23,26,28,30,36,42,44,45,47,50,55,56,57,59,62,65,70,71,74,76,77,78 ./ParseUI/ParseUIDemo/Swift/CustomViewControllers/QueryCollectionViewController/DeletionCollectionViewController.swift:8,10,13,15,21,23,29,32,34,39,40,43,48,49,50,53,62,63,64,69,74,81,82,84,94,97,99,100,101,106,107,109,114,117,119,120,122,127,128,134,137,138,139,140 ./ParseUI/ParseUIDemo/Swift/CustomViewControllers/QueryCollectionViewController/SimpleCollectionViewController.swift:21,23,26,28,30,36,42,44,45,47,50,55,56,57,59,62,63,65,69,76,80,81,84,86,87,88 ./ParseUI/ParseUIDemo/Swift/CustomViewControllers/QueryCollectionViewController/SectionedCollectionViewController.swift:21,23,26,29,32,35,36,39,42,43,46,48,49,50,52,55,57,63,69,70,71,73,76,78,79,82,87,88,89,91,94,101,103,105,106,111,113,114,115,116,118,119,122,123,127,128,131,134,137,139,140,146,148,149,155,157,158,159 ./ParseUI/ParseUIDemo/Swift/CustomViewControllers/QueryTableViewController/StoryboardTableViewController.swift:21,23,26,28,30,33,34,36,39,43,44,47,54,55,56,59,61,62,63 ./ParseUI/ParseUIDemo/Swift/CustomViewControllers/QueryTableViewController/SectionedTableViewController.swift:21,23,26,28,31,33,36,39,40,42,45,53,54,56,58,59,64,66,67,68,70,73,74,78,79,82,83,86,90,91,93,95,96,97 ./ParseUI/ParseUIDemo/Swift/CustomViewControllers/QueryTableViewController/DeletionTableViewController.swift:8,10,13,15,17,19,22,25,26,29,31,36,37,40,49,50,51,57,58,59,62,65,70,77,78,80,90,93,95,96,97,101,102,104,109,110,115,116,117,118 ./ParseUI/ParseUIDemo/Swift/CustomViewControllers/QueryTableViewController/PaginatedTableViewController.swift:21,23,26,28,30,33,38,39,41,44,45,47,50,54,55,57,63,65,67,68,69 ./ParseUI/ParseUIDemo/Swift/CustomViewControllers/QueryTableViewController/SimpleTableViewController.swift:21,23,26,28,30,33,37,38,40,43,44,46,49,53,54,56,62,64,66,67,68 ./ParseUI/ParseUIDemo/Swift/CustomViewControllers/QueryTableViewController/SubtitleImageTableViewController.swift:21,23,26,28,31,35,36,39,42,44,45,46 ./ParseUI/ParseUIDemo/Swift/CustomViewControllers/LogInViewController/CustomLogInViewController.swift:21,23,26,28,31,33,39,40,41 ./ParseUI/ParseUIDemo/Swift/AppDelegate.swift:21,26,29,31,33,41,44,45,47,48,51,52,54,70,72,81,82,84,98,99,100,101,103,108,109,110,111 ./ParseUI/ParseUIDemo/Swift/UIDemoViewController.swift:21,23,26,60,65,67,68,69,71,138,139,140,141,142,144,147,150,151,152,153,155,158,159,162,163,168,169,170,172,221,230,236,240,346,347,348,349,350,351,353,356,357,358,359,361,364,365,366 ./ParseUI/Classes/ProductTableViewController/PFProductTableViewController.m:21,23,27,31,34,38,40,41,43,45,48,54,57,59,60,63,64,67,70,72,73,78,79,84,85,89,97,101,102,109,110,113,119,124,125,132,139,140,144,148,149,154,163,164,165,167,168,171,175,181,183,184,185,188,191,192,195,196,199,204,205,208,212,216,217,220,224,225,229,230,237,239,240,244,245,249,250 ./ParseUI/Classes/ProductTableViewController/PFProductTableViewController.h:21,23,31,33,40,43,45,49,51 ./ParseUI/Classes/Cells/PFPurchaseTableViewCell.h:21,23,31,33,46,50,54,60,65,70,72 ./ParseUI/Classes/Cells/PFCollectionViewCell.m:21,23,26,28,31,34,37,39,44,49,52,55,56,63,64,65,68,69,72,75,76,79,84,86,87,93,95,96 ./ParseUI/Classes/Cells/PFTableViewCell.h:21,23,31,33,36,41,44,48,50 ./ParseUI/Classes/Cells/PFPurchaseTableViewCell.m:21,23,26,28,31,33,35,38,43,48,53,66,69,71,74,77,79,87,93,95,99,102,107,108,111,115,116,118,121,123,126,135,138,147,151,153,154 ./ParseUI/Classes/Cells/PFCollectionViewCell.h:21,23,29,30,32,35,41,46,49,53,56,59,63,65 ./ParseUI/Classes/Cells/PFTableViewCell.m:21,23,25,27,30,32,34,37,42,45,47,48,51,54,58,62,63,67,68,70,74,77,80,84,87,90,93,96,99,101,104,110,113,114,117,120,121 ./ParseUI/Classes/SignUpViewController/PFSignUpViewController.m:21,23,26,31,35,41,49,50,52,54,56,58,60,63,68,70,71,76,78,79,84,86,87,92,95,96,97,100,104,105,108,113,114,117,119,120,123,128,130,131,132,135,139,140,142,143,146,149,150,154,163,164,165,168,169,172,173,176,179,180,185,186,194,195,196,201,202,203,205,207,208,211,224,230,231,234,240,242,243,247,248,250,255,257,260,263,266,267,271,272,273,283,285,286,290,293,296,297,301,306,307,310,313,315,316,320,322,323,327,329,331,336,358,365,366,370,372,373,374,377,378,382,384,385,389,392,395,398,399,401,402,404,407,408,417,418,424,427,431,432,440,441,445,449,458,459,460,465,466,467,473,483,484,489,492,493,496,497,499,500,503,507,513,514,515 ./ParseUI/Classes/SignUpViewController/PFSignUpView.h:21,23,29,30,32,35,56,59,68,70,75,79,82,84,86,90,93,97,101,106,110,113,117,121,126,131,136,141,144,148,153,158,160 ./ParseUI/Classes/SignUpViewController/PFSignUpView.m:21,23,32,34,38,45,47,50,54,56,59,63,68,69,79,91,93,106,108,109,119,120,126,127,129,130,133,136,138,141,148,149,152,153,158,163,165,169,173,175,176,181,183,184,189,191,192,197,199,200,205,207,208,211,215,217,218,219,223,229,231,233,237,239,243,247,251,255,258,260,262,263,266,268,269,274,275,281,282,286,287,290,296,298,299,300,304,308,312,314,316,317,318,321,331,332,335,336 ./ParseUI/Classes/SignUpViewController/PFSignUpViewController.h:21,23,25,33,34,37,39,45,49,52,56,59,63,67,70,74,79,82,88,90,94,99,102,106,111,115,120,125,130,135,139,145,147,151,154,157,161,165,168,173,176,181,184,188,190 ./ParseUI/Classes/Internal/Cells/PFActivityIndicatorTableViewCell.m:21,23,25,27,29,31,34,36,42,44,45,48,51,56,57,58,59,62,63 ./ParseUI/Classes/Internal/Cells/PFActivityIndicatorCollectionReusableView.h:21,23,30,32,34,37 ./ParseUI/Classes/Internal/Cells/PFActivityIndicatorTableViewCell.h:21,23,29,35,37 ./ParseUI/Classes/Internal/Cells/PFActivityIndicatorCollectionReusableView.m:21,23,25,29,30,32,34,37,41,45,50,54,56,57,60,63,64,67,71,72,75,77,79,82,83,86,89,96,97,98,99,102,103,106,109,110,113,114 ./ParseUI/Classes/Internal/PFImageCache.h:21,23,28,30,33 ./ParseUI/Classes/Internal/PFLocalization.m:21,23,25,28,29,36,41,44,45 ./ParseUI/Classes/Internal/Extensions/PFColor.h:21,23,25,29,31,35,40,44,50 ./ParseUI/Classes/Internal/Extensions/PFImage.m:21,23,27,29,31,34,37,40,42,43,46,48,52,55,61,63,64,67,68,74,75,82,84,93,96,97,102,104,109,110 ./ParseUI/Classes/Internal/Extensions/PFUIAlertView.h:21,23,25,29,31,35,42,50,54,61,63 ./ParseUI/Classes/Internal/Extensions/PFRect.h:21,24,28 ./ParseUI/Classes/Internal/Extensions/PFUIAlertView.m:21,23,25,27,29,31,33,37,48,57,58,61,65,70,71,81,84,85,89,90,93,97,98,99,121,122,125,129,134,135,148,150,156,157,160,164,165,166,170,177,180,182,183,193,194,196,200,207,208,209,210,212 ./ParseUI/Classes/Internal/Extensions/PFImage.h:21,23,25,28,30 ./ParseUI/Classes/Internal/Extensions/PFColor.m:21,23,25,28,34,35,38,41,42,45,46,49,50,53,54,57,63,64,70,71,77,78,84,85,88,89 ./ParseUI/Classes/Internal/Extensions/PFRect.m:21,23,26,27,30,31,34,35,41,42,48 ./ParseUI/Classes/Internal/PFLocalization.h:21,23,26,31,33 ./ParseUI/Classes/Internal/PFImageCache.m:21,23,26,27,29,37,38,41,42,45,46 ./ParseUI/Classes/Internal/Views/Buttons/PFDismissButton.h:21,23,25 ./ParseUI/Classes/Internal/Views/Buttons/PFTextButton.m:21,23,25,28,32,39,41,42,45,51,52 ./ParseUI/Classes/Internal/Views/Buttons/PFPrimaryButton.m:21,23,26,28,30,31,34,36,38,41,44,45,48,49,53,55,59,61,62,65,68,70,76,77,83,84,87,94,95,102,103,104,105,108,109 ./ParseUI/Classes/Internal/Views/Buttons/PFActionButton.m:21,23,26,28,30,32,33,35,38,40,42,45,48,49,52,53,58,61,64,67,70,72,75,77,78,81,84,87,88,94,95,101,102,106,110,111,114,117,118,121,122,125,131,132,139,140,142,143,144,147,148,152,154,155,156,158,161,162,165,167,169,172,175,176,181,184,186,187,190,194,196,197,200,201 ./ParseUI/Classes/Internal/Views/Buttons/PFTextButton.h:21,23,25 ./ParseUI/Classes/Internal/Views/Buttons/PFDismissButton.m:21,23,25,27,30,34,36,38,39,42,45,47,49,51,54,57,59,61,64,66,67,70,76,77,79,82,83 ./ParseUI/Classes/Internal/Views/Buttons/PFPrimaryButton.h:21,23,25,27,30 ./ParseUI/Classes/Internal/Views/Buttons/PFActionButton.h:21,23,25,29,31,33,35,37,41,43,47,51,53,55,58,61,64 ./ParseUI/Classes/Internal/Views/PFLoadingView.h:21,23,28 ./ParseUI/Classes/Internal/Views/PFLoadingView.m:21,23,26,28,31,33,35,38,45,53,55,56,59,62,64,71,75,79,80 ./ParseUI/Classes/QueryCollectionViewController/PFQueryCollectionViewController.m:21,23,26,28,35,38,41,45,46,48,50,53,55,57,60,66,68,70,71,76,78,80,81,84,85,89,91,93,94,98,99,103,110,112,113,116,119,121,127,135,136,137,138,141,143,144,147,149,150,153,156,157,161,162,165,168,169,172,173,176,179,180,184,185,188,192,193,196,197,199,200,204,205,208,209,212,215,219,222,223,226,227,230,233,234,238,241,250,251,253,260,263,264,267,268,272,273,278,282,283,288,289,290,295,296,299,304,305,307,312,313,315,317,318,323,324,325,328,336,337,346,347,350,353,354,357,358,362,363,368,369,372,376,378,379,382,387,388,391,392,395,399,404,405,408,412,413,414,417,420,429,430,431,432,436,438,439 ./ParseUI/Classes/QueryCollectionViewController/PFQueryCollectionViewController.h:21,23,30,31,33,38,42,44,51,55,60,65,70,75,80,85,89,93,95,99,102,105,110,114,120,127,131,136,139,142,144,148,153,158,162,165,169,173,176,180,185,190,194,197,201,205,208,210,214,220,224,226,230,232 ./ParseUI/Classes/QueryTableViewController/PFQueryTableViewController.h:21,23,30,31,33,38,42,44,53,57,60,63,68,71,73,77,81,86,89,93,96,100,103,107,112,117,122,127,132,136,142,149,153,158,161,164,166,170,175,180,185,190,196,202,207,210,214,218,221,225,230,234,240,244,247,250,252,256,262,266,269,273,275 ./ParseUI/Classes/QueryTableViewController/PFQueryTableViewController.m:21,23,27,29,36,41,45,47,50,56,57,59,62,64,66,69,76,78,79,85,87,88,91,92,95,96,101,103,104,108,115,117,118,121,124,132,133,134,137,139,140,143,145,146,149,154,155,157,162,163,165,166,169,174,176,177,182,184,185,190,191,193,198,199,201,203,204,210,211,212,219,220,223,224,228,231,240,241,243,249,252,253,255,259,264,267,269,270,274,275,276,279,288,289,290,296,297,300,304,307,308,310,311,320,321,323,325,326,337,338,342,343,346,347,350,351,352,355,356,359,360,363,364,367,368,371,372,375,378,379,381,384,385,389,390,393,397,398,401,402,404,405,410,411,414,417,422,425,426,429,430,433,439,440,442,444,445,455,456,466,468,469,472,479,480,481,486,487,489,490,494,495,497,498,501,508,509,513,514,520,521,522,523,528,529,530,533,537,542,543,546,549,550,553,556,557,560,563,572,573,574,575,579,581,582 ./ParseUI/Classes/Views/PFTextField.h:21,23,29,30,32,36,47,53,56,58,62,65,69,72,75,79,81 ./ParseUI/Classes/Views/PFImageView.m:21,23,25,27,29,31,34,44,45,46,49,57,60,61,62,65,66,74,76,77,83,85,86,92,95,98,100,101,102,103,111,113,114,126,128,129,134,135,138,140,145,148,149 ./ParseUI/Classes/Views/PFTextField.m:21,23,25,27,30,34,37,39,41,43,45,46,50,52,54,55,58,62,63,68,69,70,73,76,79,82,83,87,88,92,93,94,97,100,101,104,105,108,109,112,118,119 ./ParseUI/Classes/Views/PFImageView.h:21,23,25,31,32,34,36,39,44,47,51,54,56,60,63,65,69,72,74,81,83 ./ParseUI/Classes/LogInViewController/PFLogInViewController.m:21,23,25,34,38,44,50,52,54,56,58,60,62,64,72,73,76,78,80,82,86,91,93,94,99,101,102,107,109,110,115,117,120,121,122,126,130,131,135,139,143,145,146,149,151,152,155,157,161,163,164,165,169,170,172,173,177,180,181,184,185,188,189,193,198,199,200,201,205,215,216,217,223,225,226,230,235,236,237,241,245,249,250,252,253,257,261,264,267,270,273,276,279,282,283,286,293,294,306,313,315,316,329,331,332,333,336,339,340,344,345,347,354,357,359,364,368,369,371,375,376,380,381,388,389,396,398,409,413,414,415,424,425,427,428,430,434,435,438,440,447,448,455,460,461,462,464,468,469,472,476,477,478,482,483,488,489,494,496,497,501,503,504,508,510,511,522,524,526,527,531,533,534,538,542,545,547,548,551,552,562,563,569,572,576,577,585,586,590,594,603,604,605,610,611,612,618,626,627,632,635,636,638,639,641,642 ./ParseUI/Classes/LogInViewController/PFLogInView.m:21,23,33,38,42,52,54,58,65,67,68,72,76,78,80,81,85,89,91,93,94,98,102,104,106,107,111,115,117,120,122,126,128,130,131,135,142,146,147,159,160,171,175,178,179,186,190,191,199,203,204,211,215,216,223,227,228,235,239,240,247,251,252,253,257,260,262,270,271,274,275,279,287,289,293,297,300,301,305,310,314,321,323,330,332,334,335,341,344,345,348,349,355,359,361,365,369,371,372,378,380,381,387,389,390,393,397,399,400,403,408,409,410,417,419,421,425,427,431,435,438,440,442,445,448,450,453,455,456,459,460,466,467,471,472,476,482,483,484,490,492,493,494,498,500,501,502,506,511,512,517,518,519,524,525,526,527,537,538,541,542 ./ParseUI/Classes/LogInViewController/PFLogInView.h:21,23,29,31,34,64,67,79,81,86,90,93,95,97,101,104,108,112,115,119,122,126,130,135,140,145,150,155,160,165,170,175,180,183,187,190,194,196 ./ParseUI/Classes/LogInViewController/PFLogInViewController.h:21,23,25,33,35,37,41,46,50,53,57,58,61,65,69,72,76,79,83,86,91,94,100,102,106,111,117,122,126,132,134,138,141,145,151,155,158,163,166,169,174,177,181,184,188,190,192 ./ParseUI/Classes/LogInViewController/PFLogInView_Private.h:21,27,28,30,32 ./ParseUI/Other/ParseUIConstants.h:21,24,27,31,43 ./ParseUI/Other/ParseUI.h:21 ./ParseUI/SignInWithAppleTests/SignInWithAppleTests.m:8,12,14,16,18,20,22,24,26,28,30,32,35,37,39,41,43,47,49,51,53,55,58,59,62,63,65,78,85,89,100,104,106,107,108,122,129,133,138,141,145,147,148 ./ParseUI/Sign In With Apple/PFAppleUtils.h:8,10,14,16,20,23,25,28,30,32 ./ParseUI/Sign In With Apple/PFAppleAuthenticationProvider.m:8,10,12,15,16 ./ParseUI/Sign In With Apple/PFAppleUtils.m:8,13,17,20,24,26,28,30,33,40,42,43,46,47,53,55,68,71,72,75,76,78,80,82,84,86,88,90,96,97,99,100,104,105,109,110,114,118,120 ./ParseUI/Sign In With Apple/PFAppleAuthenticationProvider.h:8,11,13,15,17 ./Carthage/Checkouts/Bolts-ObjC/BoltsTestUI/AppDelegate.h:10,12,14,16 ./Carthage/Checkouts/Bolts-ObjC/BoltsTestUI/main.m:10,12,14,16,19,20 ./Carthage/Checkouts/Bolts-ObjC/BoltsTestUI/AppDelegate.m:10,12,14,22,23 ./Carthage/Checkouts/Bolts-ObjC/Bolts/iOS/BFAppLinkReturnToRefererView.h:10,13,15,18,24,30,35,41,43,53,58,63,65,72,77 ./Carthage/Checkouts/Bolts-ObjC/Bolts/iOS/BFAppLinkNavigation.h:10,12,14,26,29,38,45,52,55,60,66,69,72,75,78,86,92,95,101,107,113 ./Carthage/Checkouts/Bolts-ObjC/Bolts/iOS/BFAppLink.m:10,12,22,24,28,30,32,34,44,45,53,54,58,60,61 ./Carthage/Checkouts/Bolts-ObjC/Bolts/iOS/BFWebViewAppLinkResolver.m:10,12,19,49,51,55,57,59,63,64,65,67,68,69,70,74,75,76,82,84,86,87,89,91,99,100,107,112,113,116,124,125,126,129,138,143,146,147,154,166,174,184,189,190,193,194,206,210,217,222,224,227,228,230,231,243,245,246,252,254,265,266,275,277,287,288,289,290,294,296,300,303,304,308,309 ./Carthage/Checkouts/Bolts-ObjC/Bolts/iOS/BFAppLinkReturnToRefererController.h:10,13,15,18,24,26,30,36,38,45,50,55,61,67,72,77,82,87 ./Carthage/Checkouts/Bolts-ObjC/Bolts/iOS/Internal/BFMeasurementEvent_Internal.h:10,16,18 ./Carthage/Checkouts/Bolts-ObjC/Bolts/iOS/Internal/BFAppLink_Internal.h:10,12,21,23,28,31 ./Carthage/Checkouts/Bolts-ObjC/Bolts/iOS/Internal/BFAppLinkReturnToRefererView_Internal.h:10,12,14,16 ./Carthage/Checkouts/Bolts-ObjC/Bolts/iOS/Internal/BFURL_Internal.h:10,12 ./Carthage/Checkouts/Bolts-ObjC/Bolts/iOS/BFURL.m:10,15,17,21,24,29,49,52,56,65,66,74,77,80,83,86,89,95,96,97,98,99,101,102,105,106,109,110,113,114,119,120,126,137,138,140,141 ./Carthage/Checkouts/Bolts-ObjC/Bolts/iOS/BFMeasurementEvent.m:10,12,14,17,21,25,29,30,34,35,40,44,48,49,54,56,57,60,61 ./Carthage/Checkouts/Bolts-ObjC/Bolts/iOS/BFAppLinkTarget.h:10,12,18,23,26,29,32 ./Carthage/Checkouts/Bolts-ObjC/Bolts/iOS/BFAppLinkNavigation.m:10,12,14,17,26,28,30,34,36,38,47,48,51,52,63,64,67,71,74,77,84,90,95,96,99,100,101,106,113,118,119,120,128,133,134,135,140,141,146,151,154,155,161,164,167,170,188,191,194,195,200,201,202,205,206,209,210,214,215,229,231,232,237,238,241,242,249,250,251,258,259,260,267,268,269,271,272,276,278,279,282,283 ./Carthage/Checkouts/Bolts-ObjC/Bolts/iOS/BFAppLinkReturnToRefererView.m:10,12,15,18,24,26,30,32,35,36,38,44,46,47,52,54,55,59,64,66,67,77,79,92,96,98,99,100,102,110,112,113,116,118,125,130,131,138,140,141,144,154,158,163,164,166,167,169,174,175,179,180,186,187,193,194,195,199,200,202,206,207,210,213,214,216,218,220,223,225,227,231,235,238,240,241,245,246,248,250,251,254,255,258,259,262,263,266,267 ./Carthage/Checkouts/Bolts-ObjC/Bolts/iOS/BFWebViewAppLinkResolver.h:10,12,14,20,25,27 ./Carthage/Checkouts/Bolts-ObjC/Bolts/iOS/BFAppLink.h:10,12,15,21,24,27,36,39,45,48 ./Carthage/Checkouts/Bolts-ObjC/Bolts/iOS/BFAppLinkReturnToRefererController.m:10,12,16,18,22,23,25,28,29,34,49,50,52,53,57,58,60,66,67,69,70,74,75,78,81,82,83,86,88,94,95,96,97,101,102,107,108,109,111,114,115,120,121,123,128,135,136,137,138,143,151,152,153,154,160,161,162,166,167,169,170,177,181,182,185,186,191,192,197,204,210,211,212,213,219,220,223,226,227,228,229 ./Carthage/Checkouts/Bolts-ObjC/Bolts/iOS/BFAppLinkResolving.h:10,12,14,21,24,29 ./Carthage/Checkouts/Bolts-ObjC/Bolts/iOS/BFAppLinkTarget.m:10,12,14,18,20,22,31,32 ./Carthage/Checkouts/Bolts-ObjC/Bolts/iOS/BFMeasurementEvent.h:10,12,15,21,27,33,36,42,44 ./Carthage/Checkouts/Bolts-ObjC/Bolts/iOS/BFURL.h:10,12,14,20,29,37,43,48,54,59,64,69,74 ./Carthage/Checkouts/Bolts-ObjC/Bolts/Common/BFCancellationTokenSource.h:10,12,14,16,24,29,34,39,44,51,57,59 ./Carthage/Checkouts/Bolts-ObjC/Bolts/Common/BFExecutor.m:10,12,14,16,19,21,23,29,33,36,38,39,41,43,45,47,49,60,66,67,71,72,82,83,94,95,99,100,103,104,109,110,115,116,118,122,124,126,127,129,132,133,135 ./Carthage/Checkouts/Bolts-ObjC/Bolts/Common/Bolts.h:10,18,30,31,33,38 ./Carthage/Checkouts/Bolts-ObjC/Bolts/Common/BFTaskCompletionSource.m:10,12,14,16,18,22,24,26,28,31,32,36,38,40,41,43,48,49,50,55,56,57,62,63,64,67,68,71,72,75,76,78 ./Carthage/Checkouts/Bolts-ObjC/Bolts/Common/BFTask.m:10,12,14,16,18,22,23,26,28,32,33,37,41,43,45,47,51,55,57,58,62,64,66,67,71,73,75,76,80,82,84,85,87,90,91,94,95,98,99,104,105,109,116,119,120,130,135,136,139,141,142,147,148,150,154,155,158,161,168,174,175,176,189,190,191,195,197,198,199,207,208,212,213,220,224,225,230,231,233,237,238,239,244,249,250,251,255,256,257,262,268,269,270,274,275,276,280,281,282,287,292,293,294,298,299,300,308,310,311,312,314,317,318,323,329,330,333,341,344,346,351,352,355,357,365,366,369,370,372,373,376,377,380,381,385,386,392,393,399,401,402,405,406,409,410,412,415,416,420,421,425,427,432,434,435,437,444,450,451,461,462,464 ./Carthage/Checkouts/Bolts-ObjC/Bolts/Common/BFCancellationTokenRegistration.h:10,12,14,20,26,28 ./Carthage/Checkouts/Bolts-ObjC/Bolts/Common/BFCancellationToken.h:10,12,14,16,21,28,33,39,41 ./Carthage/Checkouts/Bolts-ObjC/Bolts/Common/Bolts.m:10,12,14,16 ./Carthage/Checkouts/Bolts-ObjC/Bolts/Common/BFExecutor.h:10,12,14,19,25,30,35,41,47,53,59,61 ./Carthage/Checkouts/Bolts-ObjC/Bolts/Common/BFCancellationTokenSource.m:10,12,14,16,18,21,24,26,28,30,34,36,38,39,42,43,45,48,49,52,53,56,57,60,61,63 ./Carthage/Checkouts/Bolts-ObjC/Bolts/Common/BFCancellationTokenRegistration.m:10,12,14,16,18,23,25,27,29,31,33,39,40,44,46,48,49,54,56,57,62,64,65,70,71,72,75,76,78 ./Carthage/Checkouts/Bolts-ObjC/Bolts/Common/BFTask.h:10,12,15,17,22,27,33,36,43,48,54,60,65,72,80,88,95,103,115,117,122,127,132,137,142,155,170,182,197,209,224,238,255,263,265 ./Carthage/Checkouts/Bolts-ObjC/Bolts/Common/BFTaskCompletionSource.h:10,12,14,16,23,28,33,40,47,53,59,66,72,74 ./Carthage/Checkouts/Bolts-ObjC/Bolts/Common/BFCancellationToken.m:10,13,15,17,21,23,25,27,29,31,33,35,37,41,44,46,47,49,54,55,56,63,67,68,70,71,75,76,77,82,84,85,86,91,92,93,98,99,104,105,109,110,116,117,121,122,123,124,129,133,134,135,139,140,141,143 ./Carthage/Checkouts/Bolts-ObjC/Bolts/Common/BFGeneric.h:10,12,14,17,20 ./Carthage/Checkouts/Bolts-ObjC/BoltsTests/CancellationTests.m:10,12,14,17,19,22,25,27,30,31,36,40,44,45,48,53,56,58,60,61,64,67,71,74,77,78,81,84,86,87,90,93,95,98,99,105,107,110,111,118,123,127,128,133,134,141,143,144,152,154,155,159,162,163,167,170,171 ./Carthage/Checkouts/Bolts-ObjC/BoltsTests/TaskTests.m:10,12,14,17,19,25,26,40,41,45,50,53,55,56,60,65,67,70,72,73,77,79,84,86,88,89,97,98,102,107,109,112,114,115,119,121,126,128,130,131,143,144,157,158,173,174,190,191,206,207,223,224,241,242,260,261,286,287,293,296,298,299,302,309,310,314,317,320,321,324,333,336,337,341,344,350,351,354,355,358,367,370,371,375,378,384,390,391,394,395,398,405,408,409,413,419,420,423,424,427,432,433,436,444,445,449,454,457,458,463,465,467,468,473,475,478,479,483,485,487,488,492,494,496,497,501,503,505,506,507,510,516,517,521,523,524,527,529,537,540,542,544,545,550,553,556,557,562,565,568,569,573,576,577,582,585,592,593,598,600,602,603,606,608,611,613,614,618,620,622,623,627,637,638,642,644,646,647,650,661,662,667,670,671,678,679,682,686,690,691,694,698,702,703,706,709,712,713,716,719,722,723,728,730,737,738,743,746,756,761,762 ./Carthage/Checkouts/Bolts-ObjC/BoltsTests/AppLinkReturnToRefererViewTests.m:10,12,14,18,20,22,24,27,29,30,33,35,37,38,42,45,47,49,50,54,57,59,61,62,66,69,71,74,75,79,84,87,89,90,94,98,101,103,104 ./Carthage/Checkouts/Bolts-ObjC/BoltsTests/ExecutorTests.m:10,12,14,16,18,20,23,33,34,38,48,49,53,60,61,64,70,79,81,82 ./Carthage/Checkouts/Bolts-ObjC/BoltsTests/AppLinkTests.m:8,12,14,16,18,20,22,29,30,35,36,47,49,50,57,64,65,66,67,70,71,76,77,78,82,87,88,94,96,98,99,101,104,106,111,112,115,117,125,126,129,131,136,137,140,145,146,149,155,156,159,166,167,170,178,179,182,184,188,189,200,203,208,211,213,214,216,224,227,230,233,238,240,241,245,247,248,257,260,263,266,271,273,274,283,286,289,292,297,299,300,309,312,315,318,323,325,326,343,346,349,354,359,361,362,373,376,379,382,385,387,388,405,408,411,415,419,421,422,450,453,456,475,478,483,485,486,488,496,499,502,505,510,512,513,517,519,520,529,532,535,538,543,545,546,555,558,561,564,569,571,572,581,584,587,590,595,597,598,615,618,621,626,631,633,634,645,648,651,654,657,659,660,677,680,683,687,691,693,694,722,725,728,747,750,755,757,758,760,769,772,773,782,785,789,790,802,805,810,811,823,826,831,832,844,847,853,854,866,869,874,875,887,890,895,896,902,905,911,912,918,921,922,924,932,935,938,940,943,947,948,962,965,968,970,973,978,979,993,996,999,1001,1004,1009,1010,1013,1016,1018,1021,1027,1028,1037,1040,1043,1045,1048,1054,1055,1060,1063,1066,1068,1071,1077,1078,1081,1084,1086,1087 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKAuthenticationTokenClaims.h:18,20,22,24,27,30,33,36,39,42,45,48,51,54,57,60,64,67,70,74,77,80,83,86,89,92,95,97 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKDeviceViewControllerBase.h:18,20,22,24,26,29,35,37 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKURLOpening.h:18,20,22,24,28,33,41,49,51,53,56,58 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKSettingsLogging.h:18,20,22,25,29,31 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKProfilePictureView.m:18,20,22,25,31,33,39,45,48,50,52,58,65,67,68,70,80,81,83,86,89,90,92,96,97,99,104,105,107,109,115,116,118,120,123,125,126,128,131,133,134,137,140,142,144,145,147,149,150,152,154,155,157,159,167,168,170,171,173,175,176,178,183,184,185,187,191,192,193,195,200,201,202,204,206,211,212,216,217,221,225,226,228,230,234,247,248,250,252,255,258,259,261,264,267,268,270,272,276,278,279,285,286,290,292,294,295,297,301,303,304,310,311,314,316,318,319,321,330,332,333,335,341,342,343,345,347,364,365,366,368,378,381,388,389,392,394,395,397,407,408,410,414,416,417,419,423,428,429,431,435,436,447,448,449,451,453,455,456,458 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKBridgeAPIRequest.h:18,20,22,24,28,32,36,42,44,46,50,55,64,72,74,76 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKBridgeAPI.m:18,20,22,24,34,50,52,58,60,67,73,75,77,83,90,91,93,105,106,113,121,123,124,126,128,129,131,144,148,150,151,158,161,163,164,165,167,171,172,177,179,183,184,189,209,225,226,227,228,230,231,234,235,238,239,241,242,245,248,259,260,261,263,264,266,270,271,272,273,275,279,280,281,282,284,287,288,292,304,308,315,316,318,323,326,333,338,343,344,345,348,360,365,367,368,373,377,378,381,387,388,389,394,400,401,426,427,431,434,435,436,438,440,443,444,449,456,457,460,461,462,464,472,477,478,480,482,483,485,488,491,493,498,501,502,504,506,512,513,514,516,518,525,528,531,534,549,553,554,555,557,560,563,564,570,575,577,579,582,584,586,587,589,591,592,594,596,597,599,601,602,604,606,607,609,611,612,614,616,617,619,621,622,624,626,627,629,631,632,634,636,637,639,641,642,644,646,647,649,651,652,654,656,657,659,661,662,664,666,667,669,671,672,674,676,677,679,681,682,685,687 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKProfile.m:18,21,23,25,29,31,33,35,37,39,45,62,65,67,69,71,73,76,78,80,81,83,85,86,94,110,111,121,137,138,149,165,166,179,195,196,210,227,228,245,262,264,265,281,299,301,302,304,306,307,309,311,312,315,319,323,328,329,330,331,333,335,336,338,346,347,348,350,352,353,355,357,360,361,363,365,385,386,388,391,394,396,397,399,416,417,419,421,423,424,426,459,460,462,479,480,482,484,486,490,495,496,497,501,507,508,509,511,515,520,521,523,524,528,533,542,543,548,556,557,559,564,565,567,571,572,575,576,579,580,583,584,587,588,591,592,595,596,599,600,602,603,605,611,612,616,622,623,627,628,633,639,661,662,667,669,674,681,683,687,691,695,696,697,699,702,703,705,708,713,714,715,718,720,721,723,726,728,729,731,734,736,738,739,741,743,744,746,748,749,751,755,756,759,761 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKWebDialog.h:18,20,22,24,26,28,32,37,41,45,48,52,57,61,67,69,73,78,82,86,90,94,98,102,104,106 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKAccessTokenProtocols.h:18,20,23,27,32,35,37,41,46,48 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKAccessToken.h:18,20,23,29,31,33,36,43,45,48,56,60,65,72,75,80,83,88,95,96,102,103,106,111,114,117,121,125,130,135,141,147,152,158,163,168,173,178,183,188,191,207,222,239,255,262,269,274,277,282,287,290,294,296 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKURL.h:18,20,22,24,26,28,35,38,48,57,63,68,74,79,84,89,94,99,101,103 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKRandom.m:18,20,22,24,26 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKImpressionTrackingButton.h:18,20,22,26,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKLocation.m:18,20,23,26,28,31,35,36,38,39,41,44,45,48,51,52,54,55,57,59,65,66,68,71,74,76,77,79,81,82,84,86,89,90,93,95,96,98,101,102,104,107,109,110 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKSettingsProtocol.h:18,21,24,42 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKUtility.h:18,20,22,28,31,39,50,58,66,74,80,83,88,93,97,104,106 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKUserAgeRange.m:18,20,23,26,28,31,35,36,38,39,41,44,45,48,54,55,57,58,60,62,68,69,71,74,77,79,80,82,84,85,87,89,92,93,96,98,99,101,104,105,107,110,112,113 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKConstants.h:18,20,22,24,27,32,34,37,42,44,46,50,53,59,65,71,74,79,85,91,95,98,103,109,115,121,127,129,133,136,142,148,154,157,162,168,174,178,181,186,192,198,204,210,212,216,222,228,234,238,244,250,255,260,265,270,276,281,284,288,291,296,299,303,306,311,316,321,326,331,337,343,351,357,363,370 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKSettings.h:18,20,22,24,27,30,35,40,44,46,50,56,62,68,74,81,88,93,96,100,103,107,111,114,118,121,124,128,132,136,140,143,145,149,152,154,158,164,167,172,175,179,182,190,193,197,200,204,206 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKBridgeAPIProtocolType.h:18,20,22,24,28,35 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKMeasurementEvent.h:18,20,22,24,26,28,32,34,38,40,48,55,62,66,73,76,78,80 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKBridgeAPIProtocol.h:18,20,22,24,26,28,32,36,41,52,54 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKAccessToken+Internal.h:18,20,22,25,27,29,31,34 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKImageDownloader.m:18,20,22,25,27,30,32,34,36,43,44,46,48,49,51,63,65,66,68,70,71,75,80,85,87,105,110,111,112 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKNotificationProtocols.h:18,20,22,26,31,33,37,42,44,46 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/UI/FBSDKViewImpressionTracker.m:18,20,29,31,36,38,40,42,43,45,47,53,55,68,70,71,73,79,87,92,94,95,97,99,100,102,104,112,114,119,120,122,124,128,129,132,134,137,138,139,141,143,144,147 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/UI/FBSDKIcon.m:18,20,22,24,26,28,29,31,33,34,36,38,39,41,44,54,55,57,59,60 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/UI/FBSDKLogo.m:18,20,22,24,27,29,67,69,70 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/UI/FBSDKHumanSilhouetteIcon.m:18,20,22,24,26,28,53,54,56 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/UI/FBSDKCloseIcon.h:18,20,22,24,27,29,31 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/UI/FBSDKUIUtility.h:18,20,25,29,30,35,40,41,46,49,50,64 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/UI/FBSDKViewImpressionTracker.h:18,20,25,27,30,33,39,41,43,45 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/UI/FBSDKHumanSilhouetteIcon.h:18,20,22,24,26,29,31 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/UI/FBSDKLogo.h:18,20,22,25 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/UI/FBSDKIcon.h:18,20,22,24,27,30,33,36,38 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/UI/FBSDKCloseIcon.m:18,20,22,24,26,28,30,35,36,41,44,46,49,70,75,80,95,99,100,102 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/UI/FBSDKButton+Subclass.h:18,20,28,30,32,34,36,60 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKRulesFromKeyProvider.h:18,20,22,25,27,29 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKSwizzling.h:18,20,23,25,27,29,32,34,36 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKAppLinkResolverRequestBuilding.h:18,20,22,24,27,30,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKCoreKit+Internal.h:18,20,26,28,45,81,83,101,137 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKLogger.m:18,20,24,28,30,32,34,36,38,40,47,48,49,51,52,54,56,58,59,61,64,65,66,68,70,73,74,75,77,83,85,86,87,89,92,93,94,96,103,104,110,112,114,115,116,118,120,123,124,125,128,131,132,134,138,139,140,144,150,156,161,164,166,167,168,169,172,176,177,181,182,184,189,190,191,194,196,200,201,203,204,205 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKSwizzler.m:18,20,22,25,29,32,34,40,47,49,51,54,57,59,61,65,67,71,73,77,80,81,85,88,89,90,93,97,98,100,104,109,111,112,113,115,119,124,126,127,128,130,134,139,141,142,143,145,149,154,156,157,158,160,164,169,171,172,173,176,178,180,182,184,192,193,195,201,202,203,205,210,211,212,214,216,217,219,221,222,224,226,227,229,237,238,241,242,244,246,247,249,265,267,268,270,274,277,283,286,290,295,296,299,300,301,304,305,307,308,314,321,325,326,329,330,331,333,337,338,339,341,345,346,347,349,353,355,356,358,363,364,365,368,370,372,373,376,378,380,382,388,390,391,398,405,407,408,410,416,419,420,422,424,427,431,433,434 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKDynamicFrameworkResolving.h:18,20,22,26,29,31 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKObjectDecoding.h:18,20,23,28,30 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKInternalUtility+AppURLSchemeProviding.h:18,20,23,25,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKDataPersisting.h:18,20,22,26,36,38 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKDynamicFrameworkLoader.h:18,21,23,25,27,30,36,38,40,42,44,46,48,50,55,57,59,61,63,66,68,70,72,74,76,78,80,84,89,92,95,97,100,104,107,111,114,118,121,125,128,132,135,139,142,146,149,153,156,160,163,167,170,174,177,181,183 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKSettings+Internal.h:18,26,30,36,38,40,42,45,48,54,56,58,60,62,64,66,67,69,71,73,75,77,79,81,83 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKLoggerFactory.h:18,20,22,24,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ErrorRecovery/FBSDKErrorRecoveryAttempter.h:18,20,26,28,31,34 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ErrorRecovery/FBSDKErrorRecoveryAttempter.m:18,20,22,25,27,29,34,35,36,38,40,42,47,52,53,55,56,58,60,61 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKProfilePictureView+Internal.h:18,21,23,25,27,29,31,33 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKSwizzler+Swizzling.h:18,20,23,25,29 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/NSProcessInfo+Protocols.h:18,20,23,25,29,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKMath.h:18,21,23,25,28,33,35 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKFeatureManager.m:18,20,25,27,29,31,34,36,38,40,46,53,54,56,59,60,63,67,69,70,73,75,76,79,85,87,92,94,95,97,100,101,107,108,109,111,113,114,116,118,119,121,123,132,133,134,136,139,142,143,145,170,171,173,174,176,202,203,204,206 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/UIApplication+URLOpener.h:18,20,22,24,26,30 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Instrument/CrashReport/FBSDKCrashShield.h:18,20,22,24,26,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Instrument/CrashReport/FBSDKCrashObserver.h:18,20,22,24,28,31,33,37,39 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Instrument/CrashReport/FBSDKCrashShield+Internal.h:18,20,22,24,26,28,32,34 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Instrument/CrashReport/FBSDKCrashObserver+Internal.h:18,20,22,24,26,28,30 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Instrument/CrashReport/FBSDKCrashObserver.m:18,20,31,33,37,39,41,43,45,49,50,54,65,67,68,70,77,78,80,83,87,91,95,99,101,105,107,108,112,114,115,118 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Instrument/CrashReport/FBSDKCrashShield.m:18,20,31,33,37,39,41,47,49,51,52,54,56,57,59,61,62,66,71,72,73,75,123,147,148,149,151,160,161,164,175,177,178,179,180,181,184,187,188,190,199,200,201,203,204,206,214,216,217,220,222,226,227,230 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Instrument/FBSDKInstrumentManager.h:18,20,22,25,27,29,31 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Instrument/ErrorReport/FBSDKErrorReport.m:18,20,31,33,35,42,44,46,48,52,54,56,61,62,67,74,75,77,78,80,87,88,90,94,96,97,101,105,106,110,118,119,120,122,124,132,133,134,135,137,141,145,150,154,156,157,159,182,183,184,185,187,188,190,195,196,197,198,200,205,206,207,209,212,213,216,218,220,221,224 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Instrument/ErrorReport/FBSDKErrorReporting.h:18,20,22,24,27,32,34 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Instrument/ErrorReport/FBSDKErrorReport+ErrorReporting.h:18,20,23,25,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Instrument/ErrorReport/FBSDKErrorReport.h:18,20,22,27,29,32,34,38,44,46 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Instrument/FBSDKInstrumentManager.m:18,20,27,33,35,37,43,45,47,49,55,56,62,69,71,72,74,81,82,84,87,88,92,97,99,100 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKSettings+SettingsProtocols.h:18,20,23,25,29 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/NSNotificationCenter+Extensions.h:18,20,22 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKAppEventsFlushReason.h:18,20,22 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Cryptography/FBSDKCrypto.h:18,20,23,26,30,36 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Cryptography/FBSDKCrypto.m:18,20,23,25,28,30,31,33,35,41,43,44,46,51,52 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKAppEventsUtility+AdvertiserIDProviding.h:18,20,23,25,29 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKBackgroundEventLogger.m:18,20,22,24,27,29,32,34,36,39,43,45,46,48,64,65,66,68,71,73,74,76 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKAccessToken+TokenStringProviding.h:18,20,23,25,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKURL_Internal.h:18,20,22,24,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKUnarchiverProvider.m:18,20,22,24,26,33,34,36,40,41,43,47,48 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKProfile+ProfileProtocols.h:18,20,23,25,29 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKUnarchiverProviding.h:18,20,22,24,26,29,31 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKInternalUtility.m:18,20,23,29,35,41,43,47,49,51,54,64,66,70,71,75,81,82,84,86,89,91,92,93,95,97,98,100,102,103,105,108,110,111,113,115,116,118,122,123,128,134,135,137,143,147,149,150,152,162,163,165,169,170,175,181,184,185,192,193,194,195,196,201,207,208,214,218,219,225,226,231,237,238,244,247,248,253,257,259,271,274,275,277,283,284,286,289,290,292,295,296,298,301,302,304,307,310,312,313,315,325,326,332,335,336,345,352,354,355,356,368,369,371,372,374,380,383,384,385,387,389,393,396,397,399,402,414,415,416,418,423,425,427,428,430,432,437,438,440,445,446,448,453,454,456,458,462,463,472,473,476,477,479,485,486,487,489,496,498,499,501,507,508,509,511,516,517,518,519,521,530,531,532,533,536,537,553,554,555,556,557,558,559,563,565,566,568,576,577,581,583,584,587,593,597,598,600,602,606,607,612,614,615,617,619,628,629,631,632,634,639,645,646,647,651,652,653,655,660,662,663,665,671,672,674,678,680,681,683,690,692,693,695,698,700,703,706,709,712,715,718,721,724,726,727,730 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKIntegrityParametersProcessorProvider.h:18,20,22,24,27,29,31 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKAppEvents+ApplicationLifecycleObserving.h:18,20,23,25,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKContainerViewController.h:18,20,22,24,26,28,31,33,35,38,40,42,44,46 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKURLSessionProxyFactory.h:18,20,23,25,29 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKGraphRequestMetadata.m:18,20,22,24,28,33,35,36,40,43,44,45,47,54,55 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKGraphRequestConnectionFactory.h:18,20,22,24,29 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKGraphRequestBody.m:18,20,27,29,31,35,36,38,44,45,47,48,50,55,56,57,59,64,67,68,72,78,80,81,85,92,93,97,103,104,108,117,118,120,129,130,132,133,134,139,144,147,151,155,157,158,160,163,164,166,167 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKGraphRequest+Internal.h:18,20,28,30,32,34,36,39,43,49,56,64,70,72,74 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKGraphRequestProviding.h:18,20,26,28,30,32,36,42,45,47,51,57,61,63 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKGraphRequestPiggybackManagerProviding.h:18,21,24,27 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKURLSession+URLSessionProxying.h:18,20,23,25,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKGraphRequestPiggybackManager+Internal.h:18,20,22,27,29,34 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKGraphRequestPiggybackManagerProvider.m:18,20,22,24,26,28,29 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKGraphRequestPiggybackManager.m:18,20,28,31,33,39,41,43,44,46,48,49,51,53,54,56,58,59,64,70,71,72,74,78,83,84,88,89,90,91,93,97,114,120,121,135,138,139,146,157,163,168,172,174,175,177,188,189,190,192,197,204,205,207,211,212,214,216,217,219,221,222,224,227,229,230,232,234,235,238,240,242,243,245,248,249,252 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKGraphRequestFactory.h:18,20,22,24,29 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKURLSessionProxyFactory.m:18,20,22,24,27,29,30 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKURLSessionProxying.h:18,20,22,24,28,30,34,36 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKURLSessionProxyProviding.h:18,20,22,24,27,30,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKGraphRequestMetadata.h:18,20,26,28,34,38,41,46 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKGraphRequestPiggybackManagerProvider.h:18,20,22,24,29 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKGraphRequestPiggybackManaging.h:18,21,25,27 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKGraphRequestPiggybackManager+GraphRequestPiggybackManaging.h:18,21,23,27 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKGraphRequestConnecting+Internal.h:18,24,26,28,30 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKGraphRequestBody.h:18,21,24,27,29,35,39,43,47,51,53,55 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKGraphRequestConnectionFactory.m:18,20,23,25,27,29,30 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKGraphRequestConnection+Internal.h:18,22,28,30,32,34,36,43,50 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKGraphRequestConnectionProviding.h:18,20,22,24,28,30,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKGraphRequestFactory.m:18,20,22,24,30,36,37,39,41,42,45,47,48,52,56,57,63,69,70,74,78,79 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Network/FBSDKGraphRequestPiggybackManager.h:18,20,26,29,31,33,35 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKAuthenticationStatusUtility.h:19,21,23,29 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKObjectDecoder.h:18,20 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKEventLogging.h:18,20,28,30,32,35,37,39,42,46,49,53,58,62,64 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKMeasurementEvent_Internal.h:18,20,22,24,26,31,34,36,38 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKIntegrityProcessing.h:18,20,22,24,27,29,31 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKSettings+SettingsLogging.h:18,20,22,24,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/WebDialog/FBSDKWebViewFactory.h:18,20,22,24,26,29,31,33 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/WebDialog/FBSDKWebDialogView.h:18,20,22,24,28,31,33,36,39,41,44,49,51 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/WebDialog/FBSDKWebDialog+Internal.h:18,20,22,24,30,33,35,40,44,46,48 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/WebDialog/FBSDKWebViewFactory.m:18,20,22,24,26,28,30,32,34,35,37 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/WebDialog/FBSDKWebDialog.m:18,20,22,24,34,37,39,41,43,45,47,49,52,53,55,58,63,64,68,73,74,79,85,86,88,90,95,96,98,100,103,105,111,112,114,121,122,125,128,131,132,134,135,137,139,141,142,144,146,147,149,151,152,154,160,162,163,164,166,168,174,175,177,184,186,187,189,192,193,195,197,201,202,204,208,209,211,229,232,233,234,236,246,247,249,263,264,266,273,274,276,283,292,293,295,297,302,304,310,315,317,318,323,330,344,345,346,348 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/WebDialog/FBSDKWebViewProviding.h:18,20,22,25,27,30,34,37,39,42,44,46,48 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/WebDialog/FBSDKWebDialogView.m:18,20,22,24,26,32,34,36,40,42,44,47,50,53,54,56,58,59,61,63,64,66,68,72,75,81,82,84,97,106,111,113,114,116,118,119,121,123,126,127,129,132,133,135,137,147,148,150,152,159,167,170,178,179,180,182,184,186,187,189,191,193,202,203,204,208,210,222,225,235,238,239,240,242,245,246,249,251,254,255,257,259,260,263,265 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/WebDialog/WKWebView+WebViewProtocol.h:18,20,22,25,27,30,33,35 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKError.h:18,20,22,24,27,29,31,33,37,42,47,53,57,62,67,73,78,84,86,90,94,96,98,100 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FeatureManager/FBSDKFeatureDisabling.h:18,20,23,25 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FeatureManager/FBSDKFeatureManager+FeatureDisabling.h:18,20,22,24,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FeatureManager/FBSDKFeatureManager+FeatureChecking.h:18,20,23,25,29 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKBackgroundEventLogging.h:18,20,22,24,27,30,33,36,38,40 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKApplicationLifecycleNotifications.m:18,20,22,24,26,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKInternalUtility+WindowFinding.h:18,20,22,25,27,29,31,33 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/TokenCaching/FBSDKKeychainStore.m:18,20,25,27,29,34,35,37,38,42,45,46,48,52,54,60,62,63,65,67,70,71,73,77,78,80,81,83,86,87,92,96,101,108,109,112,114,119,120,121,124,125,127,130,131,140,145,146,149,150,153,156,157,159,167,169,171,172 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/TokenCaching/FBSDKAccessTokenExpirer.m:18,20,25,27,29,31,33,35,36,38,44,46,47,49,53,54,56,62,64,65,67,73,77,78 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/TokenCaching/FBSDKTokenCache.h:18,20,28,29,31,34,36 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/TokenCaching/FBSDKAccessTokenExpirer.h:18,20,23,26,29,31 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/TokenCaching/FBSDKKeychainStore.h:18,20,23,26,30,33,36,39,42 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/TokenCaching/FBSDKTokenCache.m:18,20,26,29,32,35,37,40,41,43,48,50,51,54,56,60,64,65,69,70,74,75,76,84,90,92,93,94,99,100,102,106,112,118,122,123,125,129,133,134,138,139,143,144,145,152,160,162,163,168,169,171,175,181,187,191,192,194,196,203,204,206,213,214 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKSwizzler.h:18,20,23,26,28,30,34,38 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKLogger.h:18,20,26,28,30,33,38,41,44,47,50,54,57,62,65,68,72,77,81,85,90,94,96 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKAppEventsUtility.h:18,20,22,24,27,30,35,48 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKProfileProtocols.h:18,21,23,25,28,31,33,35 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKImageDownloader.h:18,20,22,29,32,37,39,49,51,53 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKLogger+Logging.h:18,20,22 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKEventProcessing.h:18,20,22,24,27,30,32,34 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKMacCatalystDetermining.h:18,20,22,25,27,29,31 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKAppURLSchemeProviding.h:18,20,22,25,27,29 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKLoggingCreating.h:18,20,23,25,28,30,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKProfile+Internal.h:18,24,27,29,31,33,36,38,40,43,47,52,54,60,62,64 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKFeatureManager.h:18,20,22,24,26,29,31,36,38 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKMath.m:18,23,25,27,29,31,33,35,36,38,40,41,43,45,46,48,50,51,53,56,60,62,63,65,73,74,76,95,96 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/BridgeAPI/FBSDKBridgeAPIResponseFactory.h:18,20,22,24,26,28,32,34 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/BridgeAPI/FBSDKBridgeAPIResponse+BridgeAPIResponseCreating.h:18,20,22,25,27,30,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/BridgeAPI/FBSDKBridgeAPIResponseCreating.h:18,20,22,25,27,30,33,38,40,42,44 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/BridgeAPI/FBSDKBridgeAPIResponseFactory.m:18,20,22,24,26,28,30,32,34,35,38,41,42,47,52,53,55,57 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/BridgeAPI/FBSDKBridgeAPI+ApplicationObserving.h:18,20,22,25,27,30,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/BridgeAPI/FBSDKBridgeAPIRequest+Private.h:18,20,22,25,27,36,38,40 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/BridgeAPI/FBSDKBridgeAPI+Internal.h:19,21,23,25,28,30 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/BridgeAPI/ProtocolVersions/FBSDKBridgeAPIProtocolWebV1.h:18,20,22,24,26,29,31 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/BridgeAPI/ProtocolVersions/FBSDKBridgeAPIProtocolNativeV1.m:18,20,22,24,26,36,38,40,45,47,53,55,59,61,65,72,78,80,85,90,96,101,103,105,107,112,113,118,124,126,127,129,136,139,143,148,159,160,164,168,172,178,179,184,187,190,201,203,208,215,217,226,228,232,234,235,237,239,242,248,250,251,253,264,265,267,270,277,278,280,289,312,313,317,320,321,323,331,337,338,340 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/BridgeAPI/ProtocolVersions/FBSDKBridgeAPIProtocolWebV2.h:18,20,22,24,26,29,31 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/BridgeAPI/ProtocolVersions/UIPasteboard+Pasteboard.h:18,20,22,24,27,29,31,33,34,39,41,42,44,46 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/BridgeAPI/ProtocolVersions/FBSDKBridgeAPIProtocolWebV1.m:18,20,22,24,26,30,33,35,37,44,47,64,65,70,73,79,84,89,91,92,93,103,105,110,115,116,118 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/BridgeAPI/ProtocolVersions/FBSDKBridgeAPIProtocolNativeV1.h:18,20,22,24,26,28,30,36,38,45,47,52,54,59,62,65,72,77,79 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/BridgeAPI/ProtocolVersions/FBSDKPasteboard.h:18,20,22,24,27,29,32,35,37,39 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/BridgeAPI/ProtocolVersions/FBSDKBridgeAPIProtocolWebV2.m:18,20,22,24,32,34,37,39,41,43,45,51,52,55,59,61,62,64,66,74,76,77,79,87,89,90,97,103,105,106,114,115,121,123,127,133,134,139,144,145,147 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKAppEvents+SourceApplicationTracking.h:18,20,23,25,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKAdvertiserIDProviding.h:18,20,22,24,28,30,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKAppLinkResolverRequestBuilder+Protocols.h:18,20,23,25,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKAppLinkUtility+Internal.h:18,21,23,25,27,29,33,35 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKAppEvents+ApplicationStateSetting.h:18,20,23,25,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKAccessToken+AccessTokenProtocols.h:18,24,26 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKLoggerFactory.m:18,20,22,25,27,29,31,33,34,36 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKDynamicFrameworkLoader.m:18,20,23,25,28,30,32,38,42,51,53,54,57,60,61,66,67,76,77,80,83,84,91,95,100,106,108,111,113,115,117,124,125,127,129,130,132,134,135,137,141,143,146,147,149,151,152,154,156,157,159,161,162,164,166,167,169,171,172,174,176,177,179,181,182,184,186,187,189,191,192,194,196,197,199,201,202,204,206,208,214,216,219,220,222,225,226,228,231,232,234,237,238,240,243,244,246,249,251,253,255,256,258,260,262,265,266,268,271,273,275,278,279,281,283,287,289,291,294,295,297,300,301,303,306,307,309,312,314,316,319,320,324,326,328,331,332,334,337,338,342,344,346,349,350,352,355,357,359,362 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Device/FBSDKDeviceDialogView.h:18,20,22,24,27,31,34,37,39,42,44,46 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Device/FBSDKSmartDeviceDialogView.m:18,20,22,24,27,29,33,34,36,39,41,42,44,46,59,60,61,62,64,66,67,69,71,73,74,76,91,102,112,125,135,147,158,163,170,177,195,198,203,212,223,243,258,278,280,281,283,285,286,288 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Device/FBSDKModalFormPresentationController.h:18,20,22,24,26,32,34,36 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Device/FBSDKDeviceUtilities.h:18,20,22,24,27,30,32,34 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Device/FBSDKDeviceButton+Internal.h:18,20,22,24,30,32,36,38 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Device/FBSDKDeviceDialogView.m:18,20,22,24,27,29,33,34,36,40,42,43,45,47,60,61,62,63,65,67,69,70,72,88,100,110,123,133,145,150,159,191,197,205,225,227,228,230,232,233,235 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Device/FBSDKDeviceViewControllerBase+Internal.h:18,20,22,28,31,33,35,38,46,48,50,52 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Device/FBSDKDeviceUtilities.m:18,20,22,24,26,28,32,34,38,42,48,50,51,53 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Device/FBSDKSmartDeviceDialogView.h:18,20,22,24,26,29,31 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/Device/FBSDKModalFormPresentationController.m:18,20,22,24,26,28,29,31,35,37,38,40,42,49,50,52,55,56,57,59,64,65,67,70,71,72,75,80,81,83 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKObjectDecoder.m:18,20,24,26,28,32,34,35,37,39,40,42,44,45 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKAppEvents+AppEventsConfiguring.h:18,20,23,25,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKAuthenticationStatusUtility.m:18,20,22,24,31,33,35,37,41,42,54,56,57,58,60,62,65,66,72,73,74,75,77,79,82,83,86,92,93,95,99,100,102 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKTokenStringProviding.h:18,20,23,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKContainerViewController.m:18,20,22,24,26,28,32,33,34,36,43,53,61,69,78,80,81,83 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKAppLink_Internal.h:18,20,22,24,33,35,40,43,45 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/NSURLSession+Protocols.h:18,20,22,24,27 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/NSUserDefaults+FBSDKDataPersisting.h:18,20,22,24,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKInternalUtility.h:18,21,23,29,31,36,40,43,46,48,50,55,58,63,66,71,76,81,94,101,114,129,142,149,156,163,166,173,188,193,204,210,216,221,227,232,237,242,247,252,257,264,269,274,276,280,283,290,291,293,295 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKURLOpener.h:18,20,22,25,31,33 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKUnarchiverProvider.h:18,20,22 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKAuthenticationTokenProtocols.h:18,20,22,24,27,30,32,35,37 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ServerConfiguration/FBSDKErrorRecoveryConfiguration.m:18,20,25,27,32,38,40,41,43,45,47,48,50,55,60,61,63,68,69,71,73,76,77 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ServerConfiguration/FBSDKErrorConfigurationProtocol.h:18,20,22,25,29 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ServerConfiguration/FBSDKErrorConfigurationProvider.m:18,20,22,24,26,29,30 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ServerConfiguration/FBSDKServerConfiguration.h:18,20,26,29,32,40,42,44,49,52,55,82,107,111 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ServerConfiguration/FBSDKErrorConfiguration.h:18,21,23,25,28,30,38,41,44,47,51 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ServerConfiguration/FBSDKServerConfigurationManager+Internal.h:18,20,22,24,26,28,30,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ServerConfiguration/FBSDKServerConfigurationManager.m:18,20,22,36,38,59,61,69,73,75,82,84,86,89,90,91,93,101,102,104,109,112,113,114,118,128,129,148,149,150,151,152,160,166,175,176,177,178,181,183,184,186,188,190,195,196,251,263,267,268,270,307,314,315,317,321,336,343,349,351,352,362,363,367,370,371,375,376,377,379,392,393,394,396,397,399,401,402,404,407,408,415,419,420,422,424,426,427 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ServerConfiguration/FBSDKErrorConfigurationProviding.h:18,20,22,24,28,30,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ServerConfiguration/FBSDKGateKeeperManager.h:18,21,23,25,30,35,38,41,49,54,57,61,63 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ServerConfiguration/FBSDKServerConfigurationManager+ServerConfigurationProviding.h:18,20,23 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ServerConfiguration/FBSDKServerConfigurationLoading.h:18,20,22,24,27,29,31,33 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ServerConfiguration/FBSDKDialogConfiguration.h:18,20,26,29,32,37,41 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ServerConfiguration/FBSDKErrorConfigurationProvider.h:18,20,22,24,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ServerConfiguration/FBSDKErrorRecoveryConfiguration.h:18,20,26,28,32,37,40,46 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ServerConfiguration/FBSDKGateKeeperManaging.h:18,20,22,25,30,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ServerConfiguration/FBSDKServerConfigurationManager.h:18,20,23,25,26,29,32,37,40,44 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ServerConfiguration/FBSDKServerConfiguration.m:18,21,23,26,52,54,56,58,60,67,70,74,76,80,81,83,109,137,139,140,142,184,186,187,189,191,193,194,196,198,199,201,203,204,206,208,216,217,218,220,222,224,225,227,304,305,307,336,337,339,341,343,344,347,349,350,352,354,355 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ServerConfiguration/FBSDKErrorConfiguration.m:18,20,25,29,31,33,35,36,38,93,94,96,97,99,111,113,114,116,127,130,136,137,142,143,148,149,156,162,169,170,172,173,174,176,178,180,181,183,188,189,191,193,194,196,198,200,201 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ServerConfiguration/FBSDKGateKeeperManager.m:18,20,22,24,37,39,42,44,56,59,67,68,69,74,80,81,83,85,87,88,90,98,99,105,107,108,123,124,125,126,131,137,146,147,148,150,151,153,155,161,168,169,171,173,176,180,184,188,197,198,200,204,210,212,213,215,216,217,219,224,225,226,228,231,233,234,236,239,241,242,244,246,247,249,251,252,254,256,257,259,261,262,264,266,267,269,271,273,275,276,278,280,281,283,285,286,288,290,291,293,295,296,298,300,301,303,314,315,317 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ServerConfiguration/FBSDKServerConfigurationProviding.h:18,20,22,24,27,30,33,37,39,41 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ServerConfiguration/FBSDKServerConfiguration+Internal.h:18,20,22,25,28,30,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/ServerConfiguration/FBSDKDialogConfiguration.m:18,20,24,26,28,30,35,37,38,40,42,44,45,47,54,55,57,61,62,64,66,68,69 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKWindowFinding.h:18,20,22,24,26,29,31,33,35 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKBackgroundEventLogger.h:18,20,22,25,27,30,32,35,40,42,44,46 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKSettings+ClientTokenProviding.h:18,20,22,24,26,30 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKApplicationActivating.h:18,20,22,25,27,29 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKAuthenticationToken+Internal.h:19,25,27,29,31 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKAppEvents+ApplicationActivating.h:18,20,23,25,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKClientTokenProviding.h:18,20,23,25 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKApplicationLifecycleNotifications.h:18,20,22,24,26,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKAppEventsConfiguring.h:18,20,37,39,42,59,61 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKCoreKitBasicsImport.h:18 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKAuthenticationToken+AuthenticationTokenProtocols.h:18,24,26 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKApplicationLifecycleObserving.h:18,20,22,25,28,30 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKError.m:18,20,26,28,30,32,34,36,38,40,42,43,45,47,48,50,52,53,55,57,58,60,62,63,65,67,68,73,75,76,81,87,88,94,100,102,103,105,107,108,113,115,116,121,127,128,134,137,146,147,152,154,155,161,165,174,175,177,179,180,182,185,187,188,192,195,197,198,200,202,203,205,209,210,224,225,226,229,231,233,234,237 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKApplicationDelegate+Internal.h:18,20,26,28,30,32,35,37 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKOperatingSystemVersionComparing.h:18,20,22,26,29,31 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKApplicationStateSetting.h:18,20,22,25,27,29 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/Internal/FBSDKLogging.h:18,20,26,28,31,34,36,39,41,43 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKApplicationDelegate.h:18,20,22,24,26,30,31,32,38,41,47,52,54,56,58,60,67,73,75,77,79,86,92,94,96,101,104,108,111,115,117 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKButton.m:18,21,31,36,38,40,42,44,47,48,50,52,54,55,57,59,60,62,64,69,71,72,74,79,80,82,84,85,87,89,92,93,95,97,100,106,107,109,112,117,118,120,123,127,128,130,134,135,137,140,146,166,167,169,170,172,174,179,180,182,189,190,191,193,198,199,204,213,214,223,232,233,235,237,238,240,242,243,245,247,248,250,252,253,255,257,258,260,262,263,265,267,268,270,272,273,275,278,280,282,284,289,290,292,294,296,297,299,325,326,335,337,340,343,346,349,352,355,356,362,364,367,373,376,379,383,384,391,392,395,406,407,412,420,430,431,434,439,440,442,444,445,447,450,451,453,455,456,458,460,461,463,465,466,468,470,471 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKAuthenticationToken.m:18,21,24,27,31,33,35,37,39,41,42,46,51,53,54,57,61,62,64,66,67,69,73,74,75,77,81,84,85,87,89,91,92,94,97,98,99,101,103,104,106,108,109,111,115,119,120,122,126,127,129,131,134,135,137,140,142,144,145,148 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/FBSDKAppEvents.h:18,20,24,38,40,42,44,48,50,54,56,60,66,88,94,99,102,105,108,111,114,117,120,123,126,129,132,135,139,142,145,148,151,154,157,160,163,166,169,172,175,178,181,184,187,190,193,196,199,202,205,210,213,216,219,224,228,230,231,234,235,236,238,243,245,247,249,255,258,260,263,266,268,276,278,281,284,288,292,296,298,302,305,306,307,312,317,320,324,329,333,335,337,341,343,345,347,350,356,357,359,362,365,373,375,378,381,384,389,394,395,397,401,404,408,413,420,424,426,428,431,434,435,438,442,444,447,450,453,458,459,462,467,469,472,475,478,483,485,486,489,495,496,500,503,507,510,515,555,558,560,566,569,570,571,579,583,586,587,588,590,594,597,598,599,601,606,612,617,622,627,630,635,640,644,646,669,674,679,683,685,691,696,704,709,713,715,717,719,722,727,732,736,742,746,753,755 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsConfigurationProviding.h:18,20,23,25,27,30,32,34,36 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/EventDeactivation/FBSDKEventDeactivationManager.m:18,20,23,26,28,31,34,36,38,41,46,47,49,50,52,54,59,61,64,71,72,74,78,79,81,89,92,93,95,99,104,105,107,108,111,115,121,122,123,127,128,129,131,133,137,146,149,154,155,158,159 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/EventDeactivation/FBSDKEventDeactivationManager+Protocols.h:18,22 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/EventDeactivation/FBSDKEventDeactivationManager.h:18,20,22,25,30,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAtePublisherCreating.h:18,20,22,24,27,30,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsConfigurationProtocol.h:18,20,22,24,27,33,35 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsUtility.m:18,20,22,24,38,42,45,47,49,75,76,82,89,90,93,96,100,101,103,107,108,112,113,116,120,121,130,137,138,140,143,151,152,154,157,158,160,161,163,168,169,172,175,176,180,181,182,186,187,190,193,194,201,203,204,206,209,211,212,214,216,221,222,224,232,233,235,256,258,259,261,263,264,266,272,273,274,278,279,283,286,292,296,297,298,300,301,303,312,317,326,327,328,330,331,333,338,339,341,342,346,349,350,352,356,368,369,371,372,374,376,377,379,381,382,384,389,398,402,403,406,409,410,412,416,417,419,420,422,425,426,428,429,431,433,436,437,440,441,445,446,450,453,458,459,461,462,464,465,467,472,473,476,478,480,481,483,485,486,489 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsDeviceInfo.h:18,20,23,25 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsAtePublisher.m:18,20,28,38,40,45,47,49,54,60,65,67,68,70,73,80,81,84,90,96,99,101,112,115,119,120 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKPaymentObserving.h:18,20 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKTimeSpentData+TimeSpentRecording.h:18,20,23,25,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEvents+EventLogging.h:18,24,26 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AAM/FBSDKMetadataIndexer.m:18,20,22,24,26,30,37,39,43,45,47,51,55,57,61,63,65,67,74,75,77,81,82,84,88,89,95,99,100,101,103,106,111,117,118,119,123,125,126,128,134,135,136,140,141,142,143,145,150,151,152,153,155,171,173,175,181,182,183,185,193,194,196,197,199,201,205,206,213,214,215,217,218,220,223,226,227,229,230,232,235,238,239,241,242,248,256,257,264,265,269,275,276,277,278,280,283,289,290,293,303,304,307,311,312,314,315,318,324,325,326,328,329,332,338,340,341,343,346,354,355,357,360,362,363,365,368,374,379,381,382,384 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AAM/FBSDKMetadataIndexer+MetadataIndexing.h:18,20,22,25,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AAM/FBSDKMetadataIndexer.h:18,20,22,24,26,29,31,33,35 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AAM/FBSDKMetadataIndexing.h:18,20,22,24,26,29,31,33,35 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsNumberParser.m:18,20,22,24,25,27,30,32,33,35,37,41,54,58,59,60,62,63 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKPaymentObserver.h:18,20,22,26,28,31,34,36 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKEventsProcessing.h:18,20,25 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsConfigurationManager.h:18,20,22,28,30,33,39,41,43,45 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAtePublisherFactory.h:18,20,22,26,28,31,34,38,40 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKTimeSpentData.m:18,20,29,36,42,44,48,51,73,75,80,82,94,104,105,108,112,113,115,116,118,122,123,124,127,132,133,136,142,143,145,153,155,160,164,166,167,172,174,183,190,196,198,204,207,212,213,214,217,224,229,230,238,239,240,241,242,243,245,250,251,253,257,258,265,267,268,270,273,274,276,279,280,282,286,290,291,293,296,297,299,304,305 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsConfiguration.m:18,20,22,26,28,30,36,40,49,50,52,53,57,62,64,65,67,72,73,75,77,79,80,82,89,90,92,96,97,99,101,103,104,106,109,111,113,114,117 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsStateFactory.h:18,21 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKPaymentProductRequestorCreating.h:18,20,23,25,28,31,33 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEvents+Internal.h:18,24,26,28,31,33,36,39,42,45,48,51,53,56,59,63,74,77,79,83,91,93,96,99,102,112,114,116,119,123,128,134,139,142,144,147,149 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKTimeSpentData+SourceApplicationTracking.h:18,20,22,24,27 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKHybridAppEventsScriptMessageHandler.m:18,20,22,24,29,31,34,36,38,40,42,44,46,47,49,52,54,55,57,62,73,78,84,88,89,90,91,93 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKTimeSpentRecording.h:18,20,22,25,28,30 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsParameterProcessing.h:18,20,22,25,29,31 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppStoreReceiptProviding.h:18,20,22,25,27,29,33 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsStateManager.m:18,20,22,29,34,36,38,39,41,44,45,47,49,50,52,54,55,57,60,65,66,68,74,75,79,83,86,89,92,93,95,107,108,115,117,118,120,122,124,126,127 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKPaymentProductRequestor.h:18,20,28,30,37,40,49,51,53 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMRule.h:18,20,22,24,26,28,30,32,34,36,38,41,43,45 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMReporter.h:18,20,22,24,26,29,31,33,39,41,43 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMConfiguration.h:18,20,22,24,28,30,33,35,38,40,42,44,46,48,50,52,54,56,59,61,63,65 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMEvent.h:18,20,22,24,26,28,30,32,34,36,38 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMInvocation.m:18,20,22,24,26,28,30,45,47,50,52,54,59,60,68,76,77,78,84,99,100,115,126,133,138,143,145,146,152,156,160,165,170,179,180,182,183,185,189,194,201,202,204,205,207,210,211,213,216,221,236,237,238,240,243,251,252,254,257,261,262,264,269,274,275,283,284,287,290,291,292,294,297,298,300,302,304,305,307,336,337,339,354,355,357,359,361,362,365,367,369,370,372,374,375,377,379,380,382,384,385,387,389,390,392,394,395,397,399,400,402,404,405,407,409,410,412,414,415,417,428,429,432,434 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMAdvertiserRuleFactory.m:18,20,22,24,29,31,33,38,43,45,46,48,53,59,62,64,65,67,71,76,83,85,88,90,91,93,97,129,132,134,135,137,141,142,144,148,174,175,177,181,182,184 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMAdvertiserSingleEntryRule.h:18,20,22,24,27,29,32,34,36,38,40,42,48,50,52 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMAdvertiserMultiEntryRule.m:18,20,22,24,26,29,31,34,38,40,41,43,45,52,55,58,59,68,69,70,72,74,76,77,79,84,85,87,90,91,93,95,97,98,100 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMInvocation.h:18,20,22,24,26,28,31,33,35,37,39,41,43,45,48,50,52,54,56,58,60,62,68,70,72,74,76,78 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMAdvertiserRuleProviding.h:18,20,22,24,28,30,32,34,36 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMConfiguration.m:18,20,22,24,28,37,39,41,43,46,47,48,50,52,53,55,61,72,76,88,89,91,92,100,111,113,114,116,119,125,127,132,135,139,140,142,147,151,152,153,155,156,158,163,167,168,169,171,172,175,177,178,180,183,184,186,188,190,191,193,209,210,212,220,221,223,225,227,228,230 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMEvent.m:18,20,22,24,26,31,33,35,40,45,56,58,60,61,63,64,67,71,73,74,76,78,80,81,83,87,88,90,94,95,96,98,100,102,103,105 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMAdvertiserRuleMatching.h:18,20,22,24,26,28,30,32,34 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMReporter.m:18,20,22,24,26,35,37,39,50,55,66,68,70,72,75,76,77,79,81,82,84,94,102,108,109,110,112,115,116,120,121,123,124,126,129,130,135,136,140,141,143,144,149,153,157,158,163,165,167,168,169,176,182,183,187,190,191,193,194,196,201,202,204,211,214,217,229,233,240,244,249,250,252,258,262,263,265,267,268,270,275,276,279,280,282,284,297,298,299,301,302,304,307,312,313,314,315,317,320,323,325,326,328,331,338,340,347,350,353,354,356,363,364,365,367,368,370,375,376,377,378,380,387,388,391,404,405,409,413,416,417,418,420,431,433,434,436,442,443,444,445,447,452,453,455,462,467,472,474,475,478,480,483,484,485,487,495,497,499,502,503,504,507,511,512,514,515,517,520,522,524,525,527,529,530,532,534,535,537,539,540,542,544,545,547,549,550,552,554,555,557,559,560,562,564,565,567,569,570,572,574,575,577,579,580,583,585 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMRule.m:18,20,22,24,26,30,32,34,39,45,49,51,52,56,61,63,64,67,72,78,79,80,82,83,86,92,93,95,96,98,101,107,109,111,112,114,116,118,119,121,126,127,129,133,134,136,138,140,141,143 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMAdvertiserRuleOperator.h:18,20,22,24,49 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMReporter+Internal.h:18,21,23,25,27,29,31 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMAdvertiserSingleEntryRule.m:18,20,22,24,26,34,36,42,49,51,52,54,56,67,68,69,72,76,80,84,110,112,117,118,122,127,135,136,138,139,142,180,182,183,185,188,193,197,198,202,209,210,213,215,216,218,220,222,223,225,236,237,239,245,246,248,250,252,253,256,258,260,261,264,266 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMAdvertiserRuleFactory.h:18,20,22,24,27,29,32,34,36 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/AEM/FBSDKAEMAdvertiserMultiEntryRule.h:18,20,22,24,27,29,32,34,36,39,41,43 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsStateProviding.h:18,20,22,25,27 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/Codeless/FBSDKCodelessParameterComponent.h:18,20,22,24,27,32,35,37 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/Codeless/FBSDKCodelessIndexer.m:18,20,22,24,26,30,52,54,62,64,66,71,74,86,94,103,104,105,107,109,110,112,114,115,117,119,120,122,124,125,127,129,130,132,134,135,137,139,140,142,145,146,155,159,160,165,169,170,174,175,186,189,190,191,202,208,209,218,221,223,224,226,228,232,233,244,245,247,249,250,252,256,262,263,265,266,268,271,272,296,299,300,302,303,305,308,310,311,313,331,332,340,342,343,345,348,349,352,353,364,367,368,369,371,374,375,377,379,380,382,385,386,389,390,394,395,397,408,417,418,420,421,423,425,437,438,439,440,443,444,446,449,451,454,459,460,462,463,465,469,470,475,477,478,480,482,487,488,491,494,495,505,506,509,511,526,527,529,531,532,534,536,537,539,541,542,545,547 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/Codeless/FBSDKEventBindingManager.m:18,20,22,24,26,28,36,39,44,46,54,56,58,61,68,82,85,88,89,91,93,94,98,105,107,109,110,112,114,119,120,122,123,127,130,131,134,135,137,141,146,153,167,173,175,176,184,185,199,200,207,208,210,213,214,218,219,220,222,225,226,233,234,235,241,246,249,250,251,254,255,256,257,260,263,264,270,271,273,285,286,296,297,300,301,312,313,314,315,325,342,343,344,345,355,362,364,371,372,375,383,384,385,388,389,390,395,396,400,401,403,408,422,424,428,429,430,433,434,436,442,451,452,453,455,456,462,471,472,473,475,476,478,480,481,484,486,488,489,492,494 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/Codeless/FBSDKEventBinding.m:18,20,22,24,33,38,40,42,44,46,48,50,52,53,55,57,58,60,62,63,66,69,74,80,82,88,90,92,93,95,105,112,113,114,115,117,118,121,125,126,128,129,132,136,137,145,149,150,151,152,159,160,161,166,167,174,175,176,178,179,181,184,186,187,189,192,193,197,200,203,204,208,209,217,218,219,223,224,232,233,234,235,237,238,240,243,244,246,250,254,255,265,266,267,274,279,280,281,287,288,289,290,292,293,295,299,300,313,314,318,319,320,324,325,326,328,329,334,337,338,342,343,345,347,348,350 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/Codeless/FBSDKCodelessIndexer+Internal.h:18,21,23,25,34,36,44,46 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/Codeless/FBSDKCodelessPathComponent.h:18,20,22,24,26,33,36,46,49,51 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/Codeless/FBSDKCodelessParameterComponent.m:18,20,22,24,28,30,32,37,43,45,46,48,49,51,54,55,64,67,68,72,73,74,76,77,79 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/Codeless/FBSDKEventBindingManager.h:18,20,22,24,28,30,33,38,40,42 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/Codeless/FBSDKCodelessIndexer.h:18,20,22,24,26,28,31,33,35,37,39 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/Codeless/FBSDKEventBinding.h:18,20,22,26,28,31,39,42,49,51 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/Codeless/FBSDKCodelessPathComponent.m:18,20,22,24,26,28,30,36,41,42,47,48,53,54,57,58,60,61,63,77,78,80 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKPaymentProductRequestorFactory.m:18,20,32,34,42,44,46,48,56,57,65,74,75,77,78,80,89,90 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKProductRequestFactory.m:18,20,22,24,26,28,29 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKTimeSpentRecordingFactory.h:18,20,22,25,27,30,33,36,38 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAtePublishing.h:18,20,22,25,27,29 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsState.h:18,21,25,31,35,42,44 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsNumberParser.h:18,20,22,24,26,28,31,35,37 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/SKAdNetwork/FBSDKSKAdNetworkConversionConfiguration.m:18,20,22,24,26,28,30,36,41,49,54,55,57,58,60,65,69,70,71,73,74,76,81,85,86,87,89,90,92,96,101,105,108,112,113,115 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/SKAdNetwork/FBSDKSKAdNetworkRule.m:18,20,22,24,26,28,30,35,40,43,45,46,49,54,60,66,67,69,70,72,73,75,78,84,86,88,89,91 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/SKAdNetwork/FBSDKSKAdNetworkReporter.h:18,20,22,24,26,29,31,33,37,39,41 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/SKAdNetwork/FBSDKSKAdNetworkEvent.m:18,20,22,24,26,29,31,33,38,43,54,56,58,59,61,62,64 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/SKAdNetwork/SKAdNetwork+ConversionValueUpdating.h:18,21,23,25,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/SKAdNetwork/FBSDKSKAdNetworkReporter+Internal.h:18,21,25,27,32,34 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/SKAdNetwork/FBSDKSKAdNetworkConversionConfiguration.h:18,20,22,24,26,28,30,32,34,36,38,40,42,44,46,48,50 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/SKAdNetwork/FBSDKSKAdNetworkReporter.m:18,20,22,24,26,28,37,39,41,43,46,60,62,66,71,72,73,75,77,78,80,82,83,85,87,88,90,104,105,106,108,112,116,117,118,122,126,129,133,134,135,137,140,147,151,156,164,172,175,179,180,182,185,188,191,194,196,197,201,204,207,210,215,220,227,231,232,233,235,240,244,245,246,247,249,253,258,259,260,262,265,268,269,273,293,299,300,301,302,304,313,314,315,317,319,321,322,324,327,329,335,336,338,340,341,343,345,346,350 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/SKAdNetwork/FBSDKConversionValueUpdating.h:18,21,23,27,29,31 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/SKAdNetwork/FBSDKSKAdNetworkRule.h:18,20,22,24,26,28,30,32,34,36,39,41,43 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/SKAdNetwork/FBSDKSKAdNetworkEvent.h:18,20,22,24,26,28,30,32,34,36,38 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsAtePublisher.h:18,20,22,26,28,31,33,40,42,44 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKFeatureExtracting.h:18,20,22,25,27,29 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsDeviceInfo.m:18,20,23,28,31,37,39,41,44,46,49,55,68,73,74,76,78,80,81,83,85,88,89,90,92,96,98,99,101,104,106,107,109,113,117,118,121,122,126,127,129,130,131,133,137,138,139,140,143,149,152,157,163,167,171,172,174,176,177,180,182,188,189,190,198,199,200,207,208,210,211,213,216,235,237,238,240,242,244,245,247,251,252,254,258,259,261,263,264,266,272,274,275,279,288,289,291 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/SKProductsRequest+FBSDKProductsRequest.h:18,20,22,24,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/SuggestedEvents/FBSDKFeatureExtractor+Testing.h:18,20,22,24,27,29,31,33 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/SuggestedEvents/FBSDKFeatureExtractor.h:18,20,22,24,26,28,30,35,37,41,43 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/SuggestedEvents/FBSDKSuggestedEventsIndexer.h:18,20,22,24,26,28,31,33,35,37,39 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/SuggestedEvents/FBSDKFeatureExtractor+Internal.h:18,20,22,24,26,28,30,32,34,37 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/SuggestedEvents/FBSDKFeatureExtractor.m:18,20,22,24,30,40,45,47,49,51,53,56,57,58,60,84,85,87,91,92,93,96,100,101,103,106,108,112,114,116,121,122,123,127,128,132,134,135,138,145,146,151,159,160,161,170,171,173,174,176,177,182,184,186,192,193,196,201,208,209,214,216,220,224,228,232,234,235,237,239,243,247,251,252,256,257,261,262,266,267,271,272,276,277,280,281,285,286,290,291,293,297,298,300,303,304,306,307,309,312,313,314,316,321,322,326,335,338,339,343,344,345,347,352,353,354,355,357,358,360,364,365,369,370,375,376,381,386,387,390,392,394,395,397,399,400,403,405 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/SuggestedEvents/FBSDKSuggestedEventsIndexer.m:18,20,22,24,26,30,50,53,55,65,67,69,71,79,80,88,99,101,102,106,113,114,116,121,122,126,127,130,133,134,137,141,142,150,151,153,165,177,182,183,185,189,190,191,193,196,197,207,208,211,212,213,214,216,219,220,222,225,226,249,250,251,253,256,257,259,273,274,275,277,282,283,286,295,303,306,313,314,316,318,323,325,326,328,334,335,337,338,342,345,352,353,358,362,363,365,367,369,372,373,374,376,378 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/ML/FBSDKMLMacros.h:18,21,25,34,38,43 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/ML/FBSDKModelManager+RulesFromKeyProvider.h:18,20,22,25,27,30,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/ML/FBSDKModelRuntime.hpp:18,20,22,24,28,30,32,35,38,43,44,46,51,55,58,59,61,66,74,76,78,79,81,95,96,97,99,105,106,108,109,111,123,124,126,127,135,145,147,148,155,177,178,181,182,183,185,186,192,206,208,209,210,212,213,219,228,229,231,232,238,249,250,251,253,254,256,264,265,266,268,274,276,277,279,283,297,304,307,312,318,323,328,335,344,345,346 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/ML/FBSDKModelManager+IntegrityParametersProcessorProvider.h:18,20,22,25,27,30,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/ML/FBSDKModelUtility.m:18,20,22,24,26,28,30,34,35,37 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/ML/FBSDKModelManager.h:18,20,22,24,26,33,35,38,40,52,54,56 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/ML/FBSDKTensor.hpp:18,20,22,30,33,35,40,51,52,54,57,58,59,68,73,79,81,82,84,86,87,89,91,92,94,96,97,99,101,102,104,106,107,109,111,112,114,118,122,124,125,132,133 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/ML/FBSDKModelParser.h:18,20,22,24,26,28,30,33,35,37 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/ML/FBSDKModelManager+IntegrityProcessing.h:18,20,22,25,27,31,33 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/ML/FBSDKModelUtility.h:18,20,22,24,27,29,31 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsConfiguration.h:18,20,28,30,33,35,37,39,41,43,45 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKTimeSpentData.h:18,20,23,25,30,33,36,42,44 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAtePublisherFactory.m:18,20,23,25,27,31,33,35,39,44,46,47,49,54,55,57 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsConfigurationManager.m:18,20,27,31,33,43,45,47,49,55,61,62,67,72,73,80,91,92,95,98,99,101,103,105,106,108,110,111,113,115,116,118,125,128,131,143,144,145,150,152,153,156,163,168,170,174,175,177,179,181,182,185,187,189,190,192,196,197,198,201 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKPaymentObserver+PaymentObserving.h:18,20,23 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsConfigurationManager+AppEventsConfigurationProviding.h:18,20,22,24,27 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKPaymentObserver.m:18,20,22,27,29,33,35,37,40,44,45,47,48,50,52,60,61,63,68,69,70,71,73,78,79,80,81,84,95,96,97,98,100,103,104 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/Integrity/FBSDKRestrictiveDataFilterManager.h:18,20,22,24,26,30,36 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/Integrity/FBSDKIntegrityManager.h:18,20,22,24,27,29,32,35,38,40,42,44 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/Integrity/FBSDKRestrictiveData.h:18,20,22,24,26,31,33 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/Integrity/FBSDKRestrictiveDataFilterManager+Protocols.h:18,22,24,27 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/Integrity/FBSDKIntegrityManager+AppEventsParametersProcessing.h:18,20,22,25,27,30,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/Integrity/FBSDKRestrictiveDataFilterManager.m:18,20,24,26,29,32,35,37,39,42,47,48,50,51,53,55,57,62,64,66,68,71,72,74,82,83,85,86,87,90,93,98,104,105,106,112,113,117,118,119,121,122,124,128,129,131,135,136,138,139,141,143,146,147,148,151,158,159,160,162,163,165,168,180,185,188,189,192,193,194,195 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/Integrity/FBSDKRestrictiveData.m:18,20,22,24,28,30,32,38,43,45,46 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/Integrity/FBSDKIntegrityManager.m:18,20,22,24,28,30,35,37,39,42,46,48,49,51,54,55,59,62,65,72,73,79,81,82,84 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKHybridAppEventsScriptMessageHandler.h:18,20,22,25,28,30 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/ViewHierarchy/FBSDKViewHierarchy.m:18,20,22,24,26,28,34,36,38,40,42,44,47,48,50,62,66,67,68,77,78,96,97,98,99,100,103,115,116,117,118,121,128,129,132,136,137,139,140,142,149,152,159,162,163,166,167,170,171,174,175,180,181,183,184,186,188,189,191,194,195,197,204,205,207,211,213,214,216,219,224,228,229,233,234,239,240,246,249,250,252,254,255,257,259,260,262,265,266,268,270,272,275,278,288,289,292,293,294,296,300,301,306,307,309,310,312,314,321,322,324,325,328,331,332,338,339,340,342,343,345,347,358,363,374,376,377,382,392,397,398,399,401,402,404,414,415,421,427,428,430,431,433,435,444,445,446,448,449,451,453,463,472,473,476,477,481,484,485,487,488,490,503,504,505,506,507,510,511,516,519,520,524,526,527,530,540,541,542,545,548,550,551,555,558,559,573,574,575,576,577,579,580,582,587,588,589,591,592,594,596,600,608,609,610,612,613,615,617,622,623,624,626,627,629,634,636,638,639,641,646,648,650,651,653,660,661,662,664,665,667,669,674,675,678,681,682,692,693,695,699,702,704,705,707,709 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/ViewHierarchy/FBSDKViewHierarchyMacros.h:20,42,45,48,58,61,67,73,81,86,96 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/ViewHierarchy/FBSDKViewHierarchy.h:18,20,22,24,47,49,52,57,66,71,73,75,77 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsStateFactory.m:18,20,22,24,26,28,30,31 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsConfiguration+AppEventsConfigurationProtocol.h:18,20,23,25,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsState.m:18,20,22,24,26,33,35,37,39,40,42,44,45,47,52,54,55,57,62,64,65,67,69,71,72,74,81,85,87,88,90,95,96,98,100,102,103,105,112,113,115,116,119,127,128,129,131,136,146,147,149,150,152,156,157,159,160,162,164,165,167,173,174,176,180,181,187,191,193,194,196,197,201,203,204,207 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKProductsRequestProtocols.h:18,20,22,26,28,31,33,37,39,41 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKProductRequestFactory.h:18,20,22,24,27,29 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKTimeSpentRecordingFactory.m:18,20,26,28,30,33,35,37,40,44,46,47,49,52,53,55 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKPaymentProductRequestorFactory.h:18,20,22,30,32,36,45,47 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsStatePersisting.h:18,20,22,26,30 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKTimeSpentRecordingCreating.h:18,20,23,25,28,30,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKPaymentProductRequestor.m:18,20,22,34,37,51,54,56,70,72,74,76,78,81,82,83,92,111,112,114,115,117,119,120,122,126,128,129,130,132,139,141,142,144,147,148,150,151,153,160,161,162,164,169,173,174,177,193,209,210,211,227,230,233,234,238,239,241,244,248,249,251,254,258,259,262,276,277,278,279,290,291,292,296,297,299,311,313,314,318,319,321,327,331,333,334,336,338,339,341,344,345,347,350,351,352,355,369,372,382,383,387,388,392,393,396,413,414,418,419,423,424,428,430,436,437,438,443,448,449,450,453,457,458 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKSourceApplicationTracking.h:18,20,22,25,29,31 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsStateManager.h:18,20,22,27,29,32,35,36 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/Internal/FBSDKAppEventsStateManager+AppEventsStatePersisting.h:18,20,23 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/FBSDKAppEventsFlushBehavior.h:18,20,22,24,26,29,30,33,39,40 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/FBSDKAppEvents.m:18,22,25,27,63,65,70,72,76,94,102,107,111,126,130,152,156,159,175,178,181,183,185,195,203,210,223,225,227,229,231,233,235,237,239,254,263,267,270,284,289,291,303,305,307,309,316,317,319,321,327,328,329,331,334,335,338,342,348,350,351,353,354,356,362,368,374,375,377,380,381,383,385,387,388,390,393,394,397,400,401,404,408,409,412,415,416,419,424,425,429,433,434,438,443,444,449,454,455,460,466,467,470,474,475,479,484,485,490,492,501,502,507,512,513,514,518,520,522,523,525,527,531,537,538,542,544,545,562,564,593,594,598,599,601,614,617,618,627,630,631,640,643,646,647,650,651,653,655,656,658,660,662,667,672,673,675,677,680,681,683,685,689,690,693,695,699,700,701,702,704,706,707,709,711,713,714,716,718,719,721,723,731,732,733,735,738,739,741,743,744,746,750,751,753,755,756,758,760,762,763,765,767,769,770,781,793,794,796,798,799,801,803,804,807,809,810,812,814,815,817,819,820,823,825,831,840,842,845,846,847,849,851,853,854,858,860,874,875,876,877,879,881,898,915,917,919,920,922,925,926,927,929,932,933,934,936,939,940,941,943,946,947,948,950,953,956,957,959,962,965,966,969,973,974,978,982,983,987,992,993,997,1001,1002,1006,1012,1013,1018,1023,1024,1029,1035,1036,1041,1046,1047,1052,1058,1059,1065,1071,1072,1078,1085,1086,1087,1092,1098,1099,1104,1110,1111,1113,1120,1121,1123,1130,1137,1138,1139,1141,1143,1145,1146,1148,1150,1151,1153,1155,1156,1159,1161,1162,1164,1169,1173,1177,1193,1196,1197,1199,1202,1203,1212,1213,1215,1223,1224,1225,1226,1229,1232,1235,1236,1243,1244,1245,1246,1248,1251,1255,1260,1264,1269,1276,1278,1283,1288,1293,1303,1305,1307,1308,1313,1315,1319,1322,1323,1331,1333,1345,1355,1358,1359,1362,1363,1366,1368,1374,1377,1381,1383,1386,1389,1394,1399,1404,1408,1409,1422,1427,1429,1432,1433,1436,1445,1447,1448,1456,1457,1459,1463,1464,1465,1466,1468,1473,1477,1484,1485,1496,1497,1498,1503,1504,1505,1506,1507,1510,1513,1514,1518,1519,1521,1525,1533,1540,1541,1545,1548,1549,1560,1567,1579,1580,1584,1590,1592,1596,1601,1602,1609,1617,1618,1619,1620,1626,1630,1634,1635,1639,1640,1642,1646,1647,1648,1650,1652,1655,1657,1660,1661,1663,1670,1673,1675,1676,1678,1680,1687,1689,1690,1692,1694,1696,1706,1707,1717,1718,1719,1723,1724,1726,1733,1734,1736,1738,1740,1745,1746,1748,1750,1751,1753,1755,1756,1758,1760,1761,1763,1765,1766,1768,1770,1771,1773,1775,1776,1778,1780,1781,1783,1785,1786,1788,1790,1791,1793,1795,1796,1798,1800,1801,1803,1805,1806,1808,1810,1811,1813,1815,1817,1818,1820,1822,1823,1825,1827,1828,1830,1832,1833,1835,1837 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/FBSDKAppEventParameterName.h:18,20,25,28,36,39,42,45,48,51,54,57,60,63,66 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppEvents/FBSDKAppEventName.h:18,20,25,28,31,34,37,40,43,46,49,52,55,58,61,64,67,70,73,76,79,82,85,88,91,94 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKDeviceButton.h:18,20,22,24,26,29,34,36,38 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKCoreKit.h:18,20,22,56,81,83,119,143 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKBridgeAPIResponse.h:18,20,22,24,27,29,33,38,41,48,53,55,57 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/GraphAPI/FBSDKGraphRequestDataAttachment.m:18,20,22,24,29,31,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/GraphAPI/FBSDKGraphRequestHTTPMethod.h:18,20,23,26,29 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/GraphAPI/FBSDKGraphRequestFlags.h:18,20,22,35 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/GraphAPI/FBSDKGraphErrorRecoveryProcessor.m:18,20,22,24,26,28,30,32,34,38,42,43,44,53,55,56,58 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/GraphAPI/FBSDKGraphRequestConnection.m:18,20,40,42,46,53,63,65,68,71,74,89,90,92,95,103,106,113,127,129,132,134,144,145,147,149,158,159,168,183,185,186,188,190,191,193,195,198,199,200,202,204,205,208,212,214,215,217,219,220,224,228,230,231,235,238,239,243,247,249,250,254,259,263,265,266,268,271,272,274,277,278,279,281,291,293,294,299,303,305,308,317,322,325,334,335,336,337,339,341,342,344,347,348,350,352,354,355,357,359,360,362,364,365,367,369,370,372,382,384,387,388,395,396,400,402,410,412,415,416,418,419,424,430,440,442,443,456,465,470,471,473,477,478,479,481,486,489,490,492,495,496,499,509,510,511,512,520,524,526,532,533,535,542,561,562,564,566,571,576,583,588,589,594,598,600,602,603,605,612,613,614,626,631,633,643,644,655,656,657,664,665,671,672,674,678,686,687,696,698,707,711,712,723,724,725,731,733,735,737,738,755,761,766,767,768,777,797,799,803,804,814,817,824,825,827,828,831,833,852,855,856,857,859,860,863,870,871,875,879,884,885,893,894,896,899,903,904,905,906,908,913,915,919,920,922,928,933,935,938,944,945,949,950,952,956,957,965,966,970,973,974,977,978,980,984,985,989,990,994,995,1008,1028,1033,1034,1040,1043,1046,1047,1050,1051,1054,1055,1061,1062,1064,1067,1074,1076,1077,1079,1080,1085,1093,1097,1098,1100,1102,1103,1108,1113,1114,1115,1117,1119,1120,1125,1132,1133,1135,1138,1144,1147,1148,1153,1160,1163,1164,1167,1168,1171,1172,1174,1176,1177,1178,1180,1190,1191,1193,1194,1196,1199,1200,1201,1203,1209,1210,1211,1215,1224,1229,1230,1231,1233,1234,1236,1238,1244,1246,1252,1253,1254,1256,1259,1280,1282,1283,1285,1287,1289,1299,1302,1305,1306,1308,1311,1314,1316,1317,1319,1321,1322,1324,1326,1327,1330 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/GraphAPI/FBSDKGraphRequest.m:18,20,22,33,38,40,46,48,51,53,55,56,59,64,65,66,69,73,74,78,84,85,89,95,96,102,109,111,112,119,127,128,136,144,146,147,153,162,164,166,167,169,171,172,174,179,180,181,183,189,192,193,195,199,200,203,205,206,210,212,213,218,220,225,228,229,231,236,238,242,243,245,251,252,254,255,257,260,261,262,264,268,270,271,273,279,280,282,284,286,287,289,295,298,301,302,305,307,309,310,312,314,315,318 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/GraphAPI/FBSDKGraphRequestDataAttachment.h:18,20,22,28,31,42,47,52,57,59 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/GraphAPI/FBSDKGraphErrorRecoveryProcessor.h:18,20,22,24,30,32,35,41,51,57,64,66,68,70,73,76,83,86,89,97,107,109,111 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/GraphAPI/FBSDKGraphRequestConnecting.h:18,20,22,26,31,35,38,41,44,46 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/GraphAPI/FBSDKGraphRequestProtocol.h:18,20,23,25,28,32,36,40,45,50,55,60,65,70,75,80,86,91,93 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/GraphAPI/FBSDKGraphRequestConnection.h:18,20,22,26,27,34,38,41,44,47,49,53,55,60,63,66,69,71,75,77,84,87,93,95,98,100,101,102,106,110,113,115,116,117,122,124,128,131,133,134,135,139,147,150,152,153,154,156,158,168,170,172,174,175,176,180,184,189,194,199,202,203,204,207,212,215,220,224,228,231,233,236,243,246,248,251,257,260,262,264,267,272,281,284,286,288,291,296,304,307,309,311,313,317,326,329,331,333,335,339,347,351,354,357,365,368,371,372,375,379,382,384,388,392,394 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/GraphAPI/FBSDKGraphRequestConnection+GraphRequestConnecting.h:18,20,22,24,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/GraphAPI/FBSDKGraphRequest.h:18,20,23,25,29,30,34,38,40,43,48,51,57,65,73,83,98,103,108,113,118,123,127,132,137,144,150,152 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKDeviceViewControllerBase.m:18,20,22,24,28,30,37,39,43,45,46,48,57,58,60,62,63,65,68,70,71,73,103,104,105,107,109,111,112,114,116,117,121,124,125,127,129,131,132,134 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKAuthenticationTokenClaims.m:18,20,23,25,27,48,70,71,73,74,76,79,84,88,91,94,98,102,105,108,116,126,127,129,130,131,134,137,143,144,145,167,168,169,170,172,173,175,186,187,189,190,192,193,195,197,218,219,221,224,225,228,229,231,232 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKImpressionTrackingButton.m:18,20,29,31,33,47,48,50,51 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKLocation.h:18,21,23,26,35,38,42,46,48 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKRandom.h:18,20 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKURL.m:18,20,22,29,31,33,35,39,40,43,48,69,72,76,85,86,94,97,100,103,106,109,115,116,117,118,119,121,122,124,131,132,134,136,137,139,141,142,144,146,147,149,154,165,166,168,169,171 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKAccessToken.m:18,22,27,29,31,33,35,37,42,46,57,59,69,80,82,83,94,106,109,110,112,113,115,117,118,120,122,123,125,127,128,130,132,133,135,138,139,140,142,144,145,147,149,150,152,154,155,157,159,160,163,171,172,174,179,180,186,187,188,189,191,194,195,197,201,204,205,207,220,221,222,224,226,227,229,232,233,234,236,238,254,256,257,259,262,265,267,268,270,285,286,288,290,293,294,296,298,300,301,303,314,327,328,330,344,345,347,350,352,354,355,358 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKMutableCopying.h:18,20,22,24,26,28,31,36,42,44,46 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKButtonImpressionTracking.h:18,20,24,29,33 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKBridgeAPI.h:18,20,22,24,31,38,40,44,49,53,57,61,66,70,73,81,86,91,95,97,99,101 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKProfile.h:18,20,22,24,29,31,33,36,43,45,48,55,57,59,64,66,71,76,80,86,89,93,96,101,104,122,159,194,198,201,205,228,230,235,246,252,256,259,263,266,270,273,277,280,284,287,291,295,298,304,308,313,321,328,330 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKProfilePictureView.h:18,20,22,24,26,28,34,56,62,65,71,74,78,83,88,91,96,98,100 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKBridgeAPIRequest.m:18,20,22,25,32,36,38,40,47,55,56,58,75,76,78,86,89,98,100,102,103,105,107,116,117,119,132,133,135,137,139,140,142,146,152,154,155,157 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKCoreKitVersions.h:18 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKAdvertisingTrackingStatus.h:18,20,22,26,30,35 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKMeasurementEvent.m:18,20,22,26,28,30,32,34,36,38,41,45,49,51,54,60,64,68,69,72,74,75,77 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKCopying.h:18,20,22,25,30,36,38 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKApplicationObserving.h:18,20,22,28,35,40,42 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKSettings.m:18,20,22,30,36,61,62,65,68,79,92,96,108,110,118,130,132,134,146,147,149,159,165,166,171,176,178,179,184,189,190,192,194,195,197,199,200,202,204,205,207,209,210,212,231,233,235,236,238,240,241,243,245,246,248,250,251,253,255,256,258,260,261,263,265,266,268,270,271,273,275,276,278,280,281,283,285,286,288,290,291,293,295,296,298,300,301,303,305,306,308,310,311,313,320,321,322,324,326,327,329,335,336,341,342,343,345,347,348,350,353,354,356,358,359,361,363,364,366,368,369,371,373,374,376,380,382,383,385,387,388,390,392,393,395,399,401,402,404,406,407,409,413,415,416,418,420,421,423,432,433,435,436,438,440,441,443,445,446,452,463,464,465,467,469,472,474,475,476,478,481,484,485,487,490,493,494,496,498,500,501,503,505,512,514,515,517,519,521,522,524,527,528,529,531,534,535,536,538,540,541,543,545,546,548,550,551,554,556,557,560,564,566,567,571,581,582,583,584,586,587,589,591,593,594,596,603,604,606,607,609,613,616,619,620,621,623,629,633,644,651,652,653,655,658,659,660,662,664,665,667,669,670,672,676,678,679,681,683,684,686,691,693,694,696,698,699,701,703,704,706,708,709,711,713,714,716,718,723,724,725,727,732,733,735,736,738,741,743,745,749,750,752,756,757,758,760,762,763,766 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKConstants.m:18,20,22,24,26,28,30,32,39,46,48,55,62 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKUserAgeRange.h:18,21,23,26,35,38,42,47,49 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKFeature.h:18,20,22,26,29,42,46,70,74,78,82,84,88,92 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKUtility.m:18,20,25,27,29,31,32,34,36,37,39,41,42,44,46,47,49,56,63,65,67,69,70,72,75,76,77,79,81,82,84,91,93,94,99,104,105 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKLoggingBehavior.h:18,20,22,26,28,31,34,37,40,43,46,49,54,57,60 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppLink/FBSDKWebViewAppLinkResolver.h:18,20,22,24,26,28,35,41,43,45 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppLink/FBSDKAppLinkTarget.h:18,20,22,24,26,33,36,42,45,48,51,53,55 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppLink/FBSDKAppLinkNavigation.h:18,20,22,24,27,29,41,46,50,60,63,70,77,84,87,93,99,107,111,114,119,123,131,134,142,144,146 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppLink/FBSDKAppLinkUtility.h:18,20,22,24,26,31,32,38,39,45,48,55,57,58,61,67,70,72,74,75,81,88,90,92 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppLink/Internal/FBSDKMeasurementEventListener.m:18,20,22,24,30,34,36,38,50,51,53,59,60,72,76,77,79,81,82,84 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppLink/Internal/FBSDKAppLinkEventPosting.h:18,20,22,24,26,29,32,34,36 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppLink/Internal/FBSDKMeasurementEventListener.h:18,20,22,24,26,29,32,34,36 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppLink/Internal/FBSDKMeasurementEvent+AppLinkEventPosting.h:18,20,22,24,26,28,30,33,35 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppLink/FBSDKAppLink.m:18,20,22,24,34,36,40,42,44,46,51,57,58,62,67,68,70,73,75,76,78 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppLink/FBSDKWebViewAppLinkResolver.m:18,20,22,24,27,32,37,41,71,73,77,79,81,83,86,87,88,90,93,94,95,97,104,105,106,108,110,112,114,116,118,120,121,123,126,128,129,137,138,140,147,148,151,159,160,161,166,168,171,176,177,179,182,186,187,190,192,203,211,223,224,236,240,247,252,254,257,258,260,261,264,277,279,280,286,298,299,308,310,320,321,322,323,327,329,333,336,337,341,342,344 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppLink/FBSDKAppLinkTarget.m:18,20,22,24,26,30,32,34,38,44,45,47 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppLink/FBSDKAppLinkUtility.m:18,20,22,24,32,38,41,44,49,50,51,53,56,62,64,65,67,87,96,97,98,99,104,107,108,110,116,123,124,125,126,128,129,131,134,140,141,142,144,145,147,149,156,158,159,162,164,166,167,169,171,172,174,176,177,180,182 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppLink/FBSDKAppLinkNavigation.m:18,20,22,24,34,43,45,47,51,53,55,59,65,66,69,71,72,74,76,77,79,82,86,89,92,94,101,107,112,113,116,117,118,120,124,125,129,135,142,147,148,149,157,162,163,165,171,172,176,181,182,187,192,197,200,201,207,210,213,216,234,237,240,241,246,247,248,252,254,255,257,259,260,262,264,265,269,277,278,284,285,287,291,292,294,296,297,299,301,302,305,311,312,313,320,321,322,329,330,331,333,334,336,339,341,342,344,346,347,350,352,354,355,358,360 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppLink/Resolver/FBSDKAppLinkResolver.m:18,20,22,24,26,32,40,50,52,58,60,62,64,69,70,75,82,84,85,87,91,92,94,98,99,102,109,110,111,116,117,119,124,125,128,131,132,134,137,138,140,142,147,149,155,156,160,164,165,169,170,174,176,177,179,181 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppLink/Resolver/FBSDKAppLinkResolving.h:18,20,22,24,26,28,33,37,38,46,49,55,57,59 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppLink/Resolver/FBSDKAppLinkResolverRequestBuilder.m:19,21,23,25,27,30,35,39,41,43,46,48,49,51,54,55,57,58,60,63,74,75,77,79,89,90,92,93,95,98,101,102,104,105,107,109,117,118,119,121,122,124 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppLink/Resolver/FBSDKAppLinkResolver.h:18,20,22,24,26,28,37,39,43,46,49,52,55,61,67,69,71 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppLink/Resolver/FBSDKAppLinkResolverRequestBuilder.h:18,20,22,24,28,34,37,42,46,48 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/AppLink/FBSDKAppLink.h:18,20,22,24,26,28,32,39,42,45,48,58,61,67,70,72,74 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKBridgeAPIResponse.m:18,20,22,24,31,39,41,43,45,50,51,56,62,63,69,83,85,87,94,96,98,99,100,111,115,117,122,123,125,130,131,133,138,144,146,147,149,151,153,154,156 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKFeatureChecking.h:18,20,24,29,31,34 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKDeviceButton.m:18,20,22,24,26,28,33,35,37,39,41,52,53,54,56,60,61,63,66,70,81,82,83,85,86,88,90,92,93,95,108,109,111,113,114,116,118,121,138,143,145,146,148 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKButton.h:18,20,22,24,30,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKAuthenticationToken.h:18,20,22,25,27,33,36,39,44,49,54,59,64,68,72,74 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKTokenCaching.h:18,20,23,27,32,36,40,44,48 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKit/FBSDKApplicationDelegate.m:18,21,23,75,97,102,104,115,120,122,124,126,128,130,132,133,135,142,143,145,147,171,172,182,194,196,197,209,223,225,226,228,230,236,237,243,248,250,252,254,260,261,265,267,279,281,282,284,301,302,304,306,307,309,314,319,321,322,324,329,334,336,342,345,355,356,357,358,361,362,364,366,367,369,372,373,376,377,379,383,386,389,393,404,405,406,407,409,410,412,418,419,420,421,423,428,432,437,438,439,440,442,448,449,450,451,453,455,457,460,461,462,464,467,468,469,471,473,474,476,479,480,482,484,487,492,493,497,498,501,505,511,514,518,519,521,534,544,546,547,554,555,556,558,567,569,571,572,574,576,577,579,584,660,669,670,672,675,677,679,680,682,684,685,688 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/ImageDownloaderTests.swift:18,22,25,35,38,43,46,48,50,51,58,59,66,67,75,86,87,97,98,108,109,119,120,130,131,141,142,152,153,163,164,174,175,185,186,197,198,200,212,213,216,222,223,227,233,234,238,244,245,248,253,260,261,264,265,269,271,275,276,282,283,287,289,290,292,304,305,323,324,326,339,340 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/ProfileTests.swift:18,22,24,27,36,37,40,43,44,51,52,58,59,65,66,73,74,80,81,85,96,97,100,106,107 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/MathTests.swift:18,20,29,36,37,38,46,53,54,55,62,63,68,74,75,79,80 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/FBSDKApplicationDelegateTests.m:18,20,22,41,46,50,52,60,62,65,69,75,80,84,90,94,96,98,115,117,119,121,123,130,132,134,136,138,140,142,159,161,162,164,166,168,170,171,173,180,181,183,185,188,190,195,196,198,201,203,268,278,285,291,292,294,297,299,309,310,312,323,324,326,329,331,336,361,362,364,409,410,412,433,434,436,439,446,447,449,464,465,467,489,490,491,493,497,500,501,503,524,525,527,530,533,534,536,540,547,548,550,554,579,580,582,591,592,594,601,607,618,622,625,626,628,631,636,637,639,657,658,660,668,669,671,678,699,700,702,705,711,712,714,729,730,732,741,742,744,753,754,756,763,764,766,768,773,774,776,781,783,789,790,792,795,797,802,803,805,811,817,818,820,823,825,830,831,833,835,837,839,845,846,848,850,852,854,859,860,862,865,868,870,882,883,885,887,889,890,892,894,898,900,910,911,913,915,920,930,931,933,940,941 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/FBSDKAuthenticationTokenTests.m:18,20,22,27,29,33,35,37,39,41,43,44,46,48,52,59,61,62,64,68,74,90,91,93,96,112,113,115,118,119,121,126,127 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/FBSDKAppLinkUtilityTests.swift:18,20,22,25,28,34,35,38,47,48,54,55,61,62,67,68,74,75,85,90,93,94,121,125,126,131,132,133 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Basics/FBSDKSafeCastTests.m:18,20,22,25,28,31,34,37,40,43,45,47,53,59,60,62,69,76,77,79,85,91,92,94,100,106,107,109,112,114,115 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/UI/UIUtilityTests.swift:18,20,22,25,28,35,36,44,45,50,56,57,65,66,71,77,78,91,92,104,105,126,127 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/UI/ViewImpressionTrackerTests.swift:18,21,23,31,34,37,39,40,43,45,46,48,68,69,71,84,85,92,94,99,100,102,108,128,129,135,137,142,147,148,154,157,162,172,173,179,181,186,192,193,199,202,207,213,214,216,225,226 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/UI/DrawableTests.swift:18,20,29,32,33,40,41,48,49,59,60,67,70,71,77,83,84,86,90,91,103,106,107,113,114,116,128,131,132,138,139,141,150,151,157,163,164 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/FBSDKAccessTokenExpirerTests.swift:18,22,25,27,30,33,35,36,39,41,42,45,47,48,72,73,76,78,80,97,102,103 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Instrument/ErrorReportTests.swift:18,22,24,36,39,44,51,52,55,74,75,96,97,99,103,116,117,121,131,132,137,142,143,145,148,153,154,158,167,168,171,173,175,181,182,185,190,198,199,200,201,203,206,215,216,220,222,227,229,245,246,251,256,257,262,267,268,273,278,279,284,289,290,292,295,300,301,303,308,309,312,317,318,320,324,329,330,332,339,340,343,344,348,349,354,359,360,366,367,373,374,379,380,381 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Instrument/InstrumentManagerTests.swift:18,21,23,30,33,41,42,45,70,71,74,76,79,83,84,87,89,92,96,97,100,102,105,109,110,113,115,118,122,123 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Instrument/FBSDKCrashShieldTests.m:18,20,25,27,33,35,37,39,41,45,47,49,51,53,62,63,65,67,72,75,79,82,86,89,93,96,101,104,105,107,113,114,115,117,120,121,122,124,126,131,136,141,142,144,147,148,149,151,158,159,161,164,165,166,168,170,173,178,179,181,184,189,190,192,194,196,201,202,204,207,212,213,215,240,246,247,248,250,252,254,257,258,260,262,265,266,268,272,275,277,278,280,283,286,287,289,291,293,294,296,298,299,301,318,319 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/FeatureManagerTests.swift:18,22,24,29,32,34,35,38,44,45,48,50,51,62,63,74,75,80,81,83,96,97,108,110,124,125,126,146,148,162,163,164,194,196,198,209,210,211,225,233,234,235 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Network/GraphRequestPiggyBackManagerProviderTests.swift:18,20,22,28,29 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Network/GraphRequestFactoryTests.swift:18,20,22,24,35,36,52,53 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Network/GraphRequestConnectionFactoryTests.swift:18,20,22,24,28,29,30,34,39,40 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Network/FBSDKGraphRequestBodyTests.m:18,20,23,26,28,30,34,36,40,41,43,48,50,55,56,58,61,65,66,68,71,75,76,78,84,89,90 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Network/FBSDKGraphRequestPiggybackManagerTests.m:18,20,26,28,38,40,42,45,47,49,51,53,63,64,66,68,70,71,73,78,79,81,83,89,90,92,98,99,101,108,109,111,118,119,121,123,128,129,131,136,137,139,144,145,147,152,153,155,157,159,166,167,169,171,175,181,182,184,187,190,196,197,199,206,207,209,211,215,217,220,231,236,237,239,241,244,245,247,250,253,254,256,259,262,263,265,268,270,273,275,276,278,281,283,285,286,288,294,296,299,300,302,304,306,308,310,311,313,315,317,320,321,323,328,330,333,334,336,338,341,342,344,346,349,350,352,360,361,362,364,366,370,372,374,385,386,388,392,394,401,402,404,408,410,417,418,420,424,426,428,435,436,438,442,444,446,453,454,456,460,462,464,471,472,474,478,482,484,491,492,494,499,503,518,520,521,523,528,533,550,552,553,555,557,561,562,564,569,570,574,578,580,581,585,587,591,592,596,602,603,607,609,614,615,617,623,624,626,628,633,638,643,646,647,649,655,658,664,665,667,673,676,682,683,685,693,696,702,703,705,711,714,720,721,723,729,732,738,739,741,743,745,746,748,751,752,754,756,757,759,761,777,778,780,793,794,797,810,811,814,824,825,828,838,839,842,852,853,858,868,869,879,888,889,891,895,897,903,904,907,909,910,914,916,917,921,923,924,929,933,937,941,942,943 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Network/URLSessionProxyFactoryTests.swift:18,20,22,24,28,29,39,40,44,49,50 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppLinks/FBSDKAppLinkResolverRequestBuilderTests.m:18,20,22,24,26,28,30,33,36,38,40,43,45,46,48,50,53,55,56 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppLinks/WebViewAppLinkResolverTests.swift:18,22,25,31,34,36,37,39,46,47,54,55,57,62,80,81,86,87,89,98,99,104,105,111,123,124,129,130,136,143,144,152,153,159,165,166,167,173,174,183,194,195,197,214,215,238,251,252,272,273,274,295,296,297,299,328,329 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppLinks/AppLinkResolverTests.swift:18,22,39,40,50,51,67,69,76,83,86,88,89,92,94,95,101,102,105,115,119,120,122,124,127,131,132,135,145,149,150,152,154,157,161,162,165,175,179,180,182,185,186,189,195,199,200,202,204,207,210,211,214,223,229,230,232,234,237,241,242,245,251,255,256,258,260,263,265,266,269,281,285,286,288,290,292,293,296,307,311,312,314,316,318,319,322,334,338,339,341,344,345,347,351,352,354,357,358,362,366,367,371,372,379,381,383,385,386 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Base64/FBSDKBase64Tests.swift:18,20,22,27,28,29,41,42,48,49,57,58,63,64 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/FBSDKSettingsTests.m:18,20,29,35,38,41,43,47,48,51,53,55,57,58,60,62,66,72,73,75,77,79,80,82,88,89,91,93,100,101,103,105,111,112,114,117,124,125,127,130,137,138,140,143,153,154,156,158,163,164,166,169,175,176,178,181,187,188,190,194,196,201,207,208,210,212,222,223,225,227,237,238,240,242,252,253,255,257,259,269,270,272,274,278,284,285,287,292,293,295,298,304,305,307,311,313,318,328,329,331,333,343,344,346,348,358,359,361,363,373,374,376,378,380,390,391,393,395,399,405,406,408,413,414,416,419,425,426,428,432,434,444,445,447,449,459,460,462,464,474,475,477,479,489,490,492,494,496,506,507,509,511,515,521,522,524,529,530,532,535,541,542,544,548,550,560,561,563,565,575,576,578,580,590,591,593,595,605,606,608,610,612,622,623,625,627,631,638,639,641,648,649,651,654,660,661,663,666,668,679,680,682,684,694,695,697,699,709,710,712,714,724,725,727,729,731,741,742,744,746,750,756,757,759,764,765,767,770,776,777,779,783,785,795,796,798,800,810,811,813,815,825,826,828,830,840,841,843,845,847,857,858,860,862,865,870,871,873,878,879,881,884,889,890,892,894,903,904,906,908,911,916,917,919,921,923,933,934,936,938,941,946,947,949,954,955,957,960,965,966,968,970,979,980,982,985,988,993,994,996,998,1000,1010,1011,1013,1015,1018,1023,1024,1026,1031,1032,1034,1037,1042,1043,1045,1047,1056,1057,1059,1061,1064,1069,1070,1072,1074,1076,1086,1087,1089,1091,1094,1099,1100,1102,1105,1110,1111,1113,1116,1121,1122,1124,1126,1135,1136,1138,1141,1144,1149,1150,1152,1154,1156,1166,1167,1169,1171,1174,1179,1189,1190,1192,1196,1201,1212,1213,1215,1220,1231,1232,1234,1239,1249,1250,1252,1255,1261,1271,1272,1274,1276,1279,1282,1283,1285,1287,1292,1293,1295,1297,1307,1308,1310,1312,1322,1323,1325,1327,1337,1338,1340,1343,1354,1355,1357,1359,1361,1372,1373,1375,1377,1382,1383,1385,1387,1392,1394,1400,1401,1403,1407,1423,1424,1426,1440,1441,1443,1445,1452,1466,1467,1469,1471,1481,1482,1484,1497,1498,1500,1509,1510,1512,1515,1523,1525,1526,1528,1540,1541,1543,1546,1549,1553,1557,1558,1560,1562,1564,1569,1570,1572,1574,1580,1581,1583,1585,1591,1592,1594,1596,1602,1603,1605,1609,1612,1613,1615,1624,1625,1635,1638,1639,1641 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/EventDeactivation/FBSDKEventDeactivationTests.swift:18,20,25,28,30,39,43,44,46,49,50,59,66,67,73,74 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/FBSDKAppEventsTests.m:18,21,23,42,45,50,55,58,70,72,74,76,79,83,88,94,99,104,106,108,124,125,131,133,135,137,139,141,142,144,146,157,173,177,196,199,201,202,204,206,212,213,215,218,219,221,227,228,230,241,242,244,246,247,249,251,253,255,257,258,260,264,266,276,277,279,281,283,285,286,288,290,309,323,325,326,328,344,358,364,365,367,369,374,385,394,398,399,401,404,409,414,415,417,422,423,425,429,430,432,435,447,449,451,453,454,456,459,461,471,472,474,484,485,487,493,494,496,509,514,515,517,577,595,600,601,603,620,621,623,640,641,643,645,655,663,667,672,678,679,681,684,687,688,690,692,694,700,701,703,705,714,715,717,720,729,730,732,736,741,742,744,749,756,757,759,765,776,777,779,787,789,814,815,817,820,822,824,825,827,829,831,837,846,847,849,851,857,863,864,866,868,880,882,884,885,887,900,902,904,905,907,921,923,925,926,928,939,942,943,945,954,956,957,959,967,969,971,972,974,982,984,986,987,989,991,993,995,1000,1001,1003,1006,1012,1013,1015,1017,1020,1039,1040,1042,1046,1055,1056,1058,1066,1067,1069,1078,1079,1081,1089,1090,1092,1101,1102,1104,1112,1113,1115,1124,1125,1127,1141,1142,1144,1158,1159,1161,1175,1176,1178,1187,1188,1190,1199,1200,1202,1212,1213,1214,1216,1230,1231,1233,1235,1239,1240,1242,1244,1247,1258,1259,1261,1263,1273,1274,1276,1278,1283,1284,1286,1288,1289 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/FBSDKAppEventsConfigurationManagerTests.swift:18,20,23,30,33,35,36,39,41,48,49,52,54,55,57,60,77,78,99,100,109,115,116,118,122,123,124,126,129,153,154,160,161,170,171,176,180,181,186,187,195,196,201,205,206,208,211,212,217,221,222,224,228,231,232,236,242,244,248,250,256,257,261,265,266,272,273,277,279,285,286,290,292,301,302,307,311,312,315,319,322,323,327,339,340,354,355 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/AAM/FBSDKMetadataIndexerTests.m:18,20,22,25,28,30,32,34,36,42,44,46,48,56,58,60,62,100,104,105,109,112,116,120,123,124,127,133,139,140,143,149,152,153,156,162,163,166,172,173,176,193,194,197,214,215,218,235,236,239,256,257,260,277,278,281,298,299,302,317,318,321,327,338,339,342,359,360,363,380,381,384,401,402,405,422,423,426,444,445,448,461,462,464,477,478,480,493,494,497,510,511,513,527,528,530,543,544,547,560,561,563,577,578,580,593,594,597,610,611,614,635,636,638,652,653,655,668,669,672,685,686,688,702,703,705,718,719,722,735,736,738,752,753,755,768,769,772,795,796 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/SuggestedEvent/FBSDKFeatureExtractorTests.m:18,20,27,31,36,38,40,44,47,50,52,54,56,61,64,66,68,76,77,80,82,166,168,174,176,178,181,188,250,251,253,255,257,258,260,263,264,266,271,272,274,275,277,281,282,283,285,288,289,291,296,297,299,302,303,312,317,318,320,321,323,326,327,329,334,335,337,338,340,348,349,351,359,360,362,369,370,372,375,376,378,381,382,383 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/PaymentProductRequestorTests.swift:18,20,23,42,53,59,60,73,74,77,97,98,100,104,106,116,117,119,123,135,146,147,148,152,159,164,175,176,177,180,191,192,196,202,203,205,211,212,218,219,225,226,228,236,240,247,249,250,258,262,269,271,272,281,285,292,294,295,296,304,311,322,324,325,333,340,350,352,353,361,368,380,382,383,391,400,416,417,418,420,422,430,452,453,455,465,467,478,479,488,500,501,515,518,520,538,539,541,560,567,573,574,575,577,581,587,606,607,611,619,621,630,643,644,648,652,654,663,664,668,672,674,684,685,687,694,695,698,699,702,703,707,710,711,713 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/FBSDKAppEventsStateTests.m:18,20,24,26,30,32,37,38,40,42,47,48,50,53,57,61,63,64,66,73,74,76,81,82,84,93,94,96,101,102,104,113,114,116,121,122,124,133,134,136,141,142,144,153,154,156,161,162,164,166,169,172,173,175,177,184,185,187,190,197,198,200,202,209,210,212,215,222,223,225,228,235,236,238,241,243,244,246,248,250,253,254,256,258,260,263,264,266,268,279,280,282,285,287,290,291,293,295,298,299,301,303,306,307,309,311,318,319,321,323,326,327,329,336,337,339,346,357,358,360,362,368,369,371,377,378,380,386,387,389,395,396,398,401,406,407,409,412,417,418,420,422,425,427,428,430,432,435,437,438,440,443,446,448,449,451,454,456,458,460,461,463,466,467 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/SuggestedEventsIndexerTests.swift:18,20,23,35,46,47,54,55,58,60,62,72,73,76,78,79,85,86,88,91,93,96,122,123,149,150,153,158,159,161,164,169,170,173,182,183,186,195,196,203,212,213,219,230,231,237,257,258,264,266,271,277,278,280,287,292,293,300,307,308,337,338,340,346,360,361,364,378,379,382,396,397,400,409,410,415,425,426,431,433,443,444,449,454,456,470,471,476,481,483,492,493,499,502,507,509,519,520,525,530,532,545,546,548,551,556,557,565,567,571,572,586,588,592,593,603,605,607,617,618,621,626,627,630,632,633,636,641,642,645,647,648,650,667,668,674,677,680,681,683,684,699,700,715,716,728,729 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/FBSDKAppEventsAtePublisherTests.swift:18,22,24,37,48,49,56,57,60,77,78,85,87,98,99,106,108,110,117,122,123 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/FBSDKAppEventsUtilityTests.m:18,21,26,30,33,38,42,46,48,53,54,56,58,60,61,63,65,67,73,94,95,97,106,108,109,111,113,115,119,120,122,127,128,130,143,178,189,200,208,209,211,215,216,218,221,230,231,232,234,239,242,243,244,246,248,253,258,259,260,262,264,275,278,289,293,296,297,298,299,300,302,306,309,314,315,317,320,323,332,333,335,338,341,350,351,353,356,367,368,370,373,376,379,382,385,388,389,391,419,420,421,423,425,435,436,438,448,449,451,461,462,464,475,476,478,489,490,492,503,504,506,518,519,521,533,534,536,546,547,549,559,560,562,572,573,575,585,586,588,598,599,601,611,612,614,624,625,627,637,638,640,651,652 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/AEM/FBSDKAEMInvocationTests.swift:18,20,22,50,51,60,61,139,142,144,149,154,159,165,166,170,179,189,190,199,212,213,220,234,235,243,258,259,291,292,297,311,325,326,331,338,339,344,351,358,359,364,370,381,393,402,403,408,419,430,431,442,443,450,451,455,460,461,465,470,471,475,480,481,489,495,496,502,503,508,578,579,583,644,645 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/AEM/FBSDKAEMAdvertiserSingleEntryRuleTests.swift:18,20,22,24,31,32,57,67,83,84,93,106,107,132,133,142,175,176,193,203,213,223,233,243,253,263,264,285,299,313,327,328,345,351,357,363,364,381,382,395,396,409,410,439,440,446,447,452,481,482,486,508,509,510 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/AEM/FBSDKAEMReporterTests.swift:18,21,24,39,40,47,48,58,61,63,64,67,74,75,82,83,87,89,90,94,97,103,108,109,113,114,122,123,129,164,165,169,174,201,209,210,220,221,228,236,237,244,249,250,259,264,265,272,277,278,288,293,294,302,311,312,314,319,329,330,332,337,347,348,361,383,384,388,394,395,398,400,409,410,414,419,420,421,428,431,437,438,441,448,449,450,453,459,460,464,470,473,479,480,484,499,500,504,519,520,531,548,549,560,573,574,585,603,604,613,627,628,637,650,651,653,658,659 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/AEM/FBSDKAEMEventTests.swift:18,20,22,24,30,31,39,40,67,71,98,99,144,145,150,151,152,153,159,160,165,176,177,182,192,193,197,206,207,208 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/AEM/FBSDKAEMAdvertiserRuleFactoryTests.swift:18,20,22,24,26,52,53,73,74,77,93,94,112,113,137,138,139,157,158,167,168,258,259,269,292,293,294,295,308,313,315,316,317 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/AEM/FBSDKAEMConfigurationTests.swift:18,20,22,24,41,42,51,52,75,118,120,123,125,126,132,133,136,161,162,224,225,231,232,238,239,251,252,257,258,259,260,264,277,286,287,291,308,321,322,328,329,334,371,372,376,409,410,411 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/AEM/FBSDKAEMRuleTests.swift:18,20,22,24,33,34,43,44,60,76,90,95,99,103,104,110,114,115,119,122,125,140,156,172,173,178,179,180,181,187,188,193,211,212,216,232,233,255,284,285,309,338,339,363,378,379,380 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/AEM/FBSDKAEMAdvertiserMultiEntryRuleTests.swift:18,20,22,24,28,29,62,63,96,97,130,131,178,179,185,186,191,206,207,211,222,223,224 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/Codeless/EventBindingManagerEventHandlingTests.swift:18,20,22,25,26,28,33,36,39,50,51,56,59,70,71,76,79,90,91,96,98,106,111,112,116,118,126,131,132,137,139,147,152,153,157,159,167,172,173 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/Codeless/EventBindingManagerViewMatchingTests.swift:18,20,22,24,31,36,37,42,47,48,56,61,62,67,72,78,79,83,86,93,94,98,101,108,109 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/Codeless/CodelessIndexerTests.swift:18,21,23,45,52,53,56,58,61,71,72,75,77,78,83,84,86,89,118,119,152,153,155,161,162,165,167,195,196,198,201,211,213,218,219,221,224,227,232,233,237,246,247,250,254,255,257,271,272,275,278,279,281,286,287,291,294,295,297,307,308,312,315,316,318,320,321,324,328,329,331,333,342,343,346,350,351,353,355,364,365,368,372,373,375,377,388,389,393,397,398,400,402,413,414,416,420,421,425,430,431,434,439,440,443,448,449,456,461,462,471,476,477,480,491,499,500,516,517,521,524,526,532,533,537,540,542,548,549,553,556,558,564,565,569,572,574,583,584,586,591,596,597,600,603,604,609,625,626,629,631,640,641,644,646,652,653,656,659,664,665,666,669,671,679,680,684,686,697,698,700,709,710,713,719,721,727,728,731,745,746,749,763,764,769,783,784,789,803,804,808,822,823,825,836,837 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/Codeless/EventBindingManagerTests.swift:18,20,24,25,29,33,39,42,45,51,52,54,66,67,78,79,94,95,96,97,118,119,121,125,127,128,139,144,145,150,152,153,158,160,161,164,168,171,187,192,193,195,200,211,212,217,223,224,227,230,231,238,239,240,244,250,251,256,259,265,266,271,276,277,279,292,293,294,306,307,308,310,319,321,322,332,334,335,348,350,351,352 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/Codeless/FBSDKEventBindingTests.swift:18,20,23,34,37,40,44,49,53,57,61,65,68,69,75,76,84,85,90,92,98,111,112,118,119,124,125,126,129,131,142,143,146,148,159,160,165,166 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/HybridAppEventsScriptMessageHandlerTests.swift:18,20,22,29,30,37,38,42,45,47,48,51,57,58,64,69,70,76,81,82,91,96,97,118,119,120,133,134,147,152,153,170,171,177,196,197,199,226,227,231,234,235,238,239,246,247,248 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/PaymentProductRequestorTests+PaymentProductParameters.swift:18,20,40,75,76,94,95,96 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/SKAdNetwork/FBSDKSKAdNetworkReporterTests.m:18,20,22,30,33,36,44,46,54,56,58,60,62,65,66,68,73,84,87,90,91,93,95,97,98,100,102,103,105,107,109,110,112,123,124,126,129,134,135,137,140,145,146,148,150,154,162,164,165,167,176,182,183,184,186,193,194,196,210,240,243,244,245,247,270,271,273 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/SKAdNetwork/FBSDKSKAdNetworkConversionConfigurationTests.m:18,20,22,24,27,29,31,33,36,38,40,44,49,60,71,87,88,90,97,109,111,127,129,133,145,147,163,165,173,190,191,192,193,210,224,229,230,232,245,257,266,284,289,295,299,300,302,315,327,336,354,359,365,369,370,372 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/SKAdNetwork/FBSDKSKAdNetworkRuleTests.swift:18,20,34,38,42,46,47,63,68,72,73,77,80,95,111,112,131,135,148,149,150 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/SKAdNetwork/FBSDKSKAdNetworkEventTests.swift:18,20,22,24,50,51,82,83,84 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/FBSDKAppEventsStateManagerTests.swift:18,20,26,31,32,36,37,41,46,47,63,64,75,76,79,86,87 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/RawAppEventsConfigurationResponseFixtures.swift:18,20,23,29,30,39,40,47,48,57,58,69,70 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/ML/ModelUtilityTests.swift:18,20,22,24,33,34,41,42,49,50,54,60,61,67,73,74,75 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/ML/FBSDKModelManagerTests.swift:18,20,22,30,34,35,38,40,41,44,54,55,59,61,62,65,67,78,79,82,92,93,96,98,107,108,111,113,124,125,128,133,138,139,142,147,152,153,156,160,163,164,165,168,173,178,179,182,187,193,194,196,199,204,205,209,214,215,219,224,225,229,231,236,242,243,247,252,257,263,264,266,272,273,285,286,287,296,297,306,311,312,322,336,347,352 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/FBSDKAppEventsPublishAteTests.m:18,20,22,27,35,39,41,43,45,48,49,51,53,55,60,61,63,69,70,72,84,102,108,109 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/Integrity/FBSDKRestrictiveDataTests.m:18,20,22,25,28,30,35,36,38,45,46,48,50,51,53,64,69,81,82,84,92,93,94,96,109,114,126,127,129,138,143,155,156,158,167,172,184,185,187,196,201,213,214,216,227,232,244,245,247,258,263,275,276 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/Integrity/FBSDKIntegrityManagerTests.swift:18,20,22,27,30,32,33,36,42,43,46,48,49,68,69,72,82,83,85,88,93,98,101,102,111,118,119,122,133,134,138,139 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/Integrity/FBSDKRestrictiveDataFilterTests.m:18,20,29,31,33,35,40,46,50,52,54,56,62,67,68,72,75,76,78,82,87,89,94,95,97,101,104,105,107,110,111,113,118,123,124,126,130,133,135,141,142 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/FBSDKAppEventsUtilityTests.swift:18,20,22,26,29,32,35,38,42,43,48,53,63,64,68,71,72,77,91,92,98,103,116,117,121,124,125,130,143,144 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/FBSDKTimeSpentDataTests.swift:18,20,22,29,32,34,35,38,40,41,48,49,53,56,57,65,66 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/ViewHierarchy/FBSDKViewHierarchyTests.m:18,20,22,24,26,32,34,36,39,41,43,46,48,49,51,53,55,57,61,66,70,74,75,77,88,89,91,96,99,100,102,104,108,111,118,119,121,125,128,131,132 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/PaymentObserverTests.swift:18,20,23,30,32,35,45,46,57,58,60,67,68,73,78,79,82,87,88,92,97,98,105,114,125,126 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/FBSDKAppEventsConfigurationTests.swift:18,20,22,24,27,28,32,33,37,38,42,43,46,47,51,52,55,56,64,65,73,74,84,85,103,104,120,121,123,128,144,145,149,151,167,168,169,179,180,181 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/FBSDKAppEventsNumberParserTests.m:18,20,22,25,27,29,34,35,37,40,44,45,47,50,54,55 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/AppEvents/PaymentProductRequestorFactoryTests.swift:18,20,22,38,41,43,44,47,49,50,52,55,86,87,120,121,125,162,163 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/WebDialog/WebViewFactoryTests.swift:18,20,22,25,29,30,36,37 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/WebDialog/WebDialogTests.swift:18,21,23,30,33,52,53,56,61,62,65,70,71,73,77,79,81,87,88,92,93,95,100,101,105,106,108,113,114,116,130,131,134,135,139,140,143,144 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/WebDialog/WebDialogViewTests.swift:18,21,23,34,37,42,43,47,56,57,64,65,71,72,77,83,84,94,95,98,108,109,113,123,124,129,135,136,141,147,148,150,153,166,167,171,176,177,181,186,187,197,198,201,202,211,220,221,224,225,226,236,237,247,248,258,259,274,275,276,287,288,296,298,305,306,317,318,325,326,340,341,343,352,354,358,360,361,367,368,375,376,379,380,383,384 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/FBSDKSwizzlerTests.m:18,20,22,24,35,52,54,56,58,69,71,72,74,76,77,79,81,82,84,86,87,90,92,93,97,99,100,105,107,108,110,112,113,115,117,118,120,122,123,125,127,128,130,133,135,137,139,140,142,145,146,148,150,156,158,161,163,165,171,185,192,195,196,198,204,220,221,223,231,251,252,254,264,284,285,287,299,322,323,325,331,348,349,351,357,371,372,374,380,386,389,393,404,405,407,413,420,435,436,438,444,449,455,456,458,465,474,479,495,496 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/BackgroundEventLoggerTests.swift:18,20,22,27,30,35,36,46,47,50,56,57,60,66,67,70,76,77,83,84,90,95,96 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/FBSDKInternalUtilityTests.m:18,21,25,27,36,38,40,42,46,48,50,52,54,56,58,60,62,68,72,73,75,79,81,82,84,86,90,97,104,111,117,123,132,138,145,152,158,165,173,188,189,191,198,205,212,213,215,217,221,228,229,230,232,236,244,245,247,251,259,260,262,266,274,275,277,281,288,291,294,295,297,299,304,306,307,309,319,322,325,326,327,329,337,340,342,343,344,346,348,357,358,360,369,370,372,381,382,384,388,395,396,398,402,409,410,412,416,423,424,426,430,436,437,439,443,450,451,453,457,463,464,466,468,471,473,475,476,478,481,483,485,486,488,490,492,494,497,498,500,502,504,506,510,513,514,516,518,521,527,528,530,533,539,540,542,550,556,557,559,562,568,569,571,574,580,581,583,587,593,594,596,598,601,604,607,609,616,617,619,622,625,632,633,635,638,641,643,654,655,657,659,663,668,669,671,675,680,681,683,687,689,691,693,694,696,699,701,704,705,707,711,713,716,717,719,723,725,728,729,731,735,737,739,740,742,745,747,749,753,757,758,760,763,765,768,769,771,775,777,780,781,783,787,789,792,793,795,799,801,803,804,806,809,811,813,817,821,822,824,827,829,832,833,835,839,841,844,845,847,851,853,856,857,859,863,865,867,868,870,873,875,877,881,885,886,888,890,893,894,896,901,904,905,906,908,915,918,919,920,922,929,932,933,934,936,943,946,947,948,950,956,963,964,965,967,972,979,980,981,983,985,987,988,990,993,995,996,998,1001,1003,1004,1006,1010,1012,1013,1015,1019,1025,1026,1028,1032,1038,1039,1041,1044,1046,1047,1049,1052,1054,1055,1057,1060,1062,1063,1065,1068,1070,1076,1078,1083,1084,1086,1089,1094,1095,1097,1102,1103,1105,1109,1112,1117,1118,1120,1123,1126,1131,1132,1135,1139,1140,1143,1147,1148,1151,1155,1156,1159,1163,1164,1166,1178,1179,1187,1188,1189,1191,1194,1195,1197,1200,1201,1203,1206,1207,1209,1211,1215,1217,1218,1220,1224,1228,1232,1233,1235,1237,1239,1255,1256,1258,1260,1262,1273,1278,1279,1281,1283,1288,1289,1291,1296,1297,1299,1306,1307,1309,1311,1312,1314,1316,1317,1322,1324,1330,1331 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/FBSDKJSONValueTests.m:18,21,23,26,28,30,35,42,43,45,48,53,57,58,59,61,64,67,69,70,72,76,79,80,82,86,89,90,92,94,97,100,106,110,114,118,122,123,125,128,135,136 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/BridgeAPI/BridgeAPIRequestTests.swift:18,20,22,33,35,36 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/BridgeAPI/BridgeAPITests.swift:18,20,22,29,58,59,69,95,96 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/BridgeAPI/FBSDKBridgeAPITests.m:18,20,22,24,26,28,33,35,42,43,45,48,50,51,53,67,68,70,72,74,76,82,83,85,87,89,95,96,98,100,107,116,117,118,120,122,130,131,133,135,143,152,153,154,156,160,162,170,171,173,177,179,190,191,193,205,207,208,210,212,215,223,235,236,237,239,242,249,250,252,254,261,270,271,272,274,276,281,282,284,290,291,293,299,300,302,308,310,315,319,320,322,324,328,331,332,334,339,342,343,345,347,356,359,369,371,372,374,376,380,397,399,400,402,404,415,418,419,421,423,434,437,438,440,442,449,455,459,460,462,479,485,489,490,492,509,515,519,520,522,524,528,531,535,541,547,548,550,552,555,559,565,570,571,573,575,579,582,584,587,588,590,592,595,597,600,601,603,605,608,610,613,614,616,619,621,624,625,627,630,632,635,636,638,642,644,647,648,650,661,663,666,667,669,680,682,685,686,688,701,704,705,707,709,718,719,721,730,731,733,739,740,742,746,747,749,751,752,754,756,757,759,761,762,764,766,767,771 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/BridgeAPI/BridgeAPIResponseTests.swift:18,20,28,31,45,46,49,67,68,77,87,88,89,92,97,114,115,116,117,121,141,142 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/BridgeAPI/FBSDKBridgeAPIOpenBridgeRequestTests.m:18,22,24,26,28,36,38,40,42,44,55,56,58,60,68,71,85,86,88,95,98,107,108,110,118,121,126,127,129,135,138,143,144,146,160,165,175,176,178,204,205,207,234,235,237,263,264,266,268,277,278,280,284,285,287,289,290 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/BridgeAPI/FBSDKBridgeAPIResponseFactoryTests.swift:18,20,22,27,42,43,46,56,57,65,75,76 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/BridgeAPI/FBSDKBridgeAPIOpenUrlWithSafariTests.m:18,21,23,27,29,38,40,42,44,46,60,62,63,65,67,70,75,83,84,86,89,94,102,103,105,108,113,121,122,124,128,133,146,147,149,153,158,163,168,169,171,179,184,186,218,219,221,234,239,243,248,251,253,280,281,283,285,288,289,291,293,294,296,300,301 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/BridgeAPI/FBSDKBridgeAPI+SessionCompletionHandlerTests.m:18,20,22,24,26,34,35,37,50,56,60,61,63,65,78,79,81,90,95,96,98,107,112,113,115,117,126,131,132,134,143,148,149,151,153,157,158 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/BridgeAPI/FBSDKBridgeAPI+ApplicationOpenUrlTests.m:18,20,22,24,26,30,32,41,46,47,49,58,59,61,70,71,73,82,83,85,94,95,97,106,107,109,118,119,121,130,131,133,142,143,145,152,153,155,162,163,165,172,173,175,182,183,185,192,193,195,202,203,205,212,213,215,222,223,225,232,233,235,242,243,245,252,253,255,262,263,265,272,273,275,282,283,285,292,293,295,302,303,305,314,336,337,347,369,370,380,402,403,411,433,434,442,464,465,487,496,498,502,511,523,527,533,534,550,561,587,603,609,614,619,625,626,628,633,634,635,637,644,645,647,656,657,659,661,662 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/BridgeAPI/FBSDKBridgeAPITests.h:18,22,24,28,30,39,42 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/BridgeAPI/ProtocolVersions/FBSDKBridgeAPIProtocolNativeV1Tests.m:18,21,23,27,29,36,38,40,42,44,51,52,54,74,75,77,80,89,98,99,101,104,121,122,124,127,152,153,155,158,182,183,185,188,212,213,215,218,241,242,244,247,280,281,283,286,304,305,307,337,338,340,370,371,373,377,407,408,410,444,445,447,449,454,457,458,460,464,465,467,473,474,476,478,479,481,488,489,491,493,494,496,512,513,515,518,519 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/BridgeAPI/ProtocolVersions/FBSDKBridgeAPIProtocolWebV2Tests.swift:18,20,23,29,30,36,37,41,44,46,51,52,55,57,58,61,70,71,82,83,85,97,98,108,113,114,124,129,130,141,146,147,155,165,166,170,175,176,192,193,204,218,219,221,229,230,233,239,240,247,248,265,266,273,274,296,297,299,311,312,318,319,329,330,336,337,339,356,357,362,363,365,377,378,381,382 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/BridgeAPI/ProtocolVersions/FBSDKBridgeAPIProtocolWebV1Tests.swift:18,20,22,31,32,43,44,49,56,58,61,62,68,69,70,72,84,85,97,98,110,111,134,143,144,145,155,156,166,167,177,178,188,189,197,198,204,205,213,214,220,221 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/CrashHandlerTests.swift:18,21,23,27,37,38,44,45,51,52,58,59,65,66,76,78,85,86,92,93,98,100,101,104,111,119,125,133,134,143,144,145,149,150,157,158,171,182,184,185 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/ServerConfiguration/FBSDKDialogConfigurationTests.swift:18,20,22,25,30,31,37,38,45,47,63,64,67,80,81 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/ServerConfiguration/ErrorConfigurationProviderTests.swift:18,20,22,28,29 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/ServerConfiguration/RawServerConfigurationResponseFixtures.swift:18,20,23,45,46,71,72 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/ServerConfiguration/GateKeeperManagerTests.swift:18,22,24,26,32,35,43,44,47,50,51,53,56,73,74,80,81,83,87,92,93,97,102,103,107,112,113,117,122,123,125,128,131,132,133,142,143,152,154,155,159,167,177,178,183,186,192,193,198,202,205,206,212,214,216,217,220,223,225,234,235,237,241,247,248,252,257,258,260,267,297,298,300,308,309,314,317,318,320,321,324,329,330,333,339,340,346,351,357,358,365,371,372,377,378,379,381,385,390,391,399,400,405,409,410,418,419,421,429,430,431,440,443,457,458 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/ServerConfiguration/FBSDKServerConfigurationManagerTests.swift:18,20,29,30,31 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/ServerConfiguration/FBSDKServerConfigurationTests.m:18,20,26,28,31,33,36,38,40,41,43,45,47,49,50,52,54,56,57,59,61,64,65,67,69,70,72,79,80,82,87,88,90,96,97,99,104,105,107,113,114,116,121,122,124,130,131,133,138,139,141,147,148,150,155,156,158,164,165,167,169,170,172,179,180,182,189,190,192,197,198,200,207,208,210,217,218,220,225,226,228,234,235,237,239,240,242,249,250,252,259,260,262,264,265,267,275,276,278,284,285,287,294,295,297,302,303,305,312,313,315,322,323,325,330,331,333,340,341,343,350,351,353,359,360,362,369,370,372,374,375,377,380,386,387,389,394,395,397,404,405,407,414,415,417,422,423,425,432,433,435,442,443,445,450,451,453,461,462,464,467,473,474,476,481,482,484,489,496,497,499,502,512,518,519,521,529,531,533,539,540,542,547,548,550,552,554,560,561,563,568,569,571,573,575,581,582,584,589,590,592,594,596,602,603,605,608,635,637,665,666,668,671,743,744,746,750,752,758,759,761,765,769,771,777,778,780,784,790,791,795,801,802,806,812,813,817,823,824,828,834,835,839,845,846,850,856,857,861,867,868,872,878,879,883,889,890,894,900,901,905,911,912,916,922,923,927,933,934,938,944,945,949,955,956,960,966,967,971,977,978,982,988,989,993,999,1000,1004,1010,1011,1015,1021,1022,1026,1032,1033,1037,1043,1044,1048,1054,1055,1059,1065,1066,1070,1076,1077,1081,1087,1088,1092,1098,1099,1103,1109,1110,1114,1120,1121,1125,1131,1132,1136,1142,1143,1147,1153,1154,1158,1164,1165,1169,1175,1176,1180,1186,1187,1191,1197,1198,1202,1208,1209,1213,1219,1220,1224,1230,1231,1235,1241,1242,1246,1252,1253,1257,1263,1264,1268,1274,1275,1279,1285,1286,1290,1296,1297,1301,1307,1308,1312,1318,1319,1323,1329,1330,1334,1340,1341,1345,1351,1352,1356,1362,1363,1367,1373,1374,1376,1380,1386,1387,1391,1397,1398,1402,1408,1409,1413,1419,1420,1424,1430,1431,1435,1441,1442,1446,1452,1453,1457,1463,1464,1468,1474,1475,1479,1485,1486,1490,1496,1497,1501,1507,1508,1512,1518,1519,1523,1529,1530,1534,1540,1541,1545,1551,1552,1556,1562,1563,1567,1573,1574,1578,1584,1585,1589,1595,1596,1600,1606,1607,1611,1617,1618,1622,1628,1629,1633,1639,1640,1644,1650,1651,1655,1661,1662,1666,1672,1673,1677,1683,1684,1688,1694,1695,1699,1705,1706,1710,1716,1717,1721,1727,1728,1732,1738,1739,1743,1749,1750,1754,1760,1761,1765,1771,1772,1776,1782,1783,1787,1793,1794,1798,1804,1805,1809,1815,1816,1820,1826,1827,1831,1837,1838,1842,1848,1849,1853,1859,1860,1864,1870,1871,1875,1881,1882,1886,1892,1893,1897,1903,1904,1908,1914,1915,1919,1925,1926,1930,1936,1937,1941,1947,1948,1952,1958,1959,1963,1969,1970,1972,1978,1984,1989,1994,1995,1997,1998,2004,2009,2019,2020,2026,2032,2042,2043 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/FBSDKErrorConfigurationTests.m:18,20,23,25,27,29,31,32,34,36,45,46,48,50,60,61,63,66,73,83,84,86,96,99,100,101,103,113,116,117,118,120,130,133,134,135,137,147,150,151,152,154,164,167,168,169,171,181,184,185,186,188,198,201,202,203,205,215,218,219,220,222,231,234,235,236,238,247,250,251,252,254,257,260,261,262 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/FBSDKAuthenticationStatusUtilityTests.m:18,20,23,25,28,30,32,35,37,40,42,44,49,50,52,54,56,58,61,62,64,66,68,71,74,75,77,79,86,88,92,93,95,102,104,108,109,111,117,119,123,124,126,133,135,139,140,142,144,151,156,158,159,160 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/InternalUtilityTests.swift:18,21,23,26,28,29,35,36,40,45,46 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestTokenCache.swift:18,20,25,32,33 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/SampleGraphRequestConnections.swift:18,21,23,26,29,30,35,37,38,39,50,52,53 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/SampleUrls.swift:18,20,25,28,29,34,35,36,38,42 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestGraphRequestFactory.swift:18,21,24,31,33,46,56,57,66,74,75,87,97,98,103,107,108,115,123,124,133,143,144 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestInvocation.swift:18,21,24,33,34,39,40 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestAppEventsParameterProcessor.swift:18,21,28,31,32,37,38,41,42 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestAppStoreReceiptProvider.swift:18,23,27,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestPaymentQueue.swift:18,20,23,26,27,30,31 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestAtePublisherFactory.swift:18,23,27,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestOnDeviceMLModelManager.swift:18,21,27,36,39,40,41,47,49,50,53,54,57,58 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestAuthenticationTokenWallet.swift:18,20,25,29,30 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestFeatureManager.swift:18,21,24,29,33,34,37,38,41,42,45,46,50,51,54,55,62,64,65 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestIntegrityProcessor.swift:18,21,25,26,28,29 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/FBSDKServerConfigurationFixtures.h:18,20,22,24,27,30,34,36 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/Fuzzer.swift:18,20,23,51,72,75,76,83,86,89,90,91,94,102,103,104,106,107,112,116,120,121,124,125,126,127,129,130 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestSettings.swift:18,29,31,43,46,47,50,51,54,55,58,59,62,63,66,67,70,71,74,75,78,79,82,83,86,87,90,91,98,99 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/SampleRawRemoteGateKeeperList.swift:18,58 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestAdvertiserIDProvider.swift:18,20,23 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/KeychainStoreSpy.swift:18,21,25,26,30,31,35,36 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestOperationQueue.swift:18,20,23,26,30,31 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestBridgeApiResponseFactory.swift:18,21,26,29,30,36,37,45,48,49,51,52,64,65 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestProcessInfo.swift:18,21,25,28,29,32,33,36,37 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestMetadataIndexer.swift:18,22,25,26 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestBridgeApiProtocol.swift:18,31,44,47,48,50,51,60,62,63 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/SampleAEMInvocations.swift:18,20,30,31,40,41 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestAppLinkResolver.swift:18,23,27,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/FBSDKTestCoder.m:18,20,22,24,28,29,31,32,34,36,37,39,42,43,45,48,49,51,54,55,57,59,61,62,64,66,68,69,71,73,75,76,78,80,82,83,85,87,89,90,92,94,96,97 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestLogger.swift:18,26,28,31,32,37,39,42,44,45,48,49,54,55,58,59,62,63,67,68,73,74 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestProductsRequest.swift:18,22,24,27,28,31,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/FakeLoginManager.m:18,20,22,24,25,30,32,34,36,38,40,42,44,46,48,53,54,56,59,61,62,64,67,68,70,71,73,75,80,82,83,85,87,91,93,94,96,98,99 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/SampleAppLinkResolverData.swift:18,20,31,32,35,36,38,43,61,62,66,71,76,81,82 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestURLSessionProxy.swift:18,29,34,35,38,39 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/SampleRawRemoteGateKeeper.swift:18,20,26,27,32,37,41,45 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestPayment.swift:18,24,33,34,37,38,41,42,46,47 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestPaymentProductRequestorFactory.swift:18,24,25,30,33,34,35,43,45,58,60,61 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestAppEventsStateProvider.swift:18,25,32,33 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestErrorConfigurationProvider.swift:18,22,25,26,29,30 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestTimeSpentRecorder.swift:18,21,31,34,35,39,40,44,45,49,50,53,54 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestURLSessionProxyFactory.swift:18,22,25,26,29,30,37,38,44,45,47,50,51 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/SampleEventBindings.swift:18,21,28,29,30,33,36,37,41,42,43 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/SampleGraphRequests.swift:18,20,22,25,33,46,47 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestGraphRequestConnectionFactory.swift:18,22,27,28,30,34,36,37 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestAppEvents.swift:18,20,35,38,39,42,43,46,47,64,100,101,103,107,108,111,112,115,116 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/UserDefaultsSpy.m:18,20,22,24,26,28,29,31,36,37,39,40,42,44,45,47,53,54,56,58,63,64,66,71,72 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestProduct.swift:18,23,26,33,34,37,38,42,43,46,47,50,51,54,55,58,59 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestAppURLSchemeProvider.swift:18,21,23,26,27 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestPaymentObserver.swift:18,23,26,27,30,31 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestViewControllerTransitionCoordinator.swift:18,20,24,37,43,45,46,49,56,57,61,63,66,67,70,71,72,88,93,98,99 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestClientTokenProvider.swift:18,20,24,27,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestMacCatalystDeterminator.swift:18,21,25,28,29 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestAppEventsStateStore.swift:18,25,29,30,33,34,38,39 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestBackgroundEventLogger.swift:18,21,25,26,28,31,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestErrorReport.swift:18,24,27,28,37,38 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestGraphRequestBody.swift:18,26,28,32,33,36,37,40,41,48,49,51 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestCrashHandler.swift:18,21,26,31,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestTimeSpentRecorderFactory.swift:18,22,25,26 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestProductsResponse.swift:18,22,29,30,33,34,37,38 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestLoggerFactory.swift:18,23,28,29 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/FBSDKTestCase.m:18,20,22,25,31,37,41,43,45,47,49,58,59,61,63,66,69,72,75,76,78,85,95,96,100,101,103,105,106,108,110,111,113,115,116,118,120,123,124,126,128,129,131,134,135 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestView.swift:18,21,24,25 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestAtePublisher.swift:18,22,25,26 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestWebView.swift:18,23,27,28,31,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/SampleHTTPUrlResponses.swift:18,20,25,30,31,32,33,40,47,54,61,68,79,80 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/AppDelegateObserverFake.swift:18,24,32,33,36,37 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/FBSDKServerConfigurationFixtures.m:18,20,22,25,27,29,31,33,34,36,40,44,48,52,56,60,64,68,69,96,97 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestAppEventsState.swift:18,20,26,29,30,33,34,39,40 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestBridgeApiRequest.swift:18,26,28,33,34,37,38,42,44,45,48,49,52,53,54 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestReactNativeView.swift:18,20,25,28,29 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestGateKeeperManager.swift:18,25,28,29,36,37,38,42,43,49,50 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestProfileProvider.swift:18,21,24,27,30,31,35,36 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestPaymentTransaction.swift:18,26,39,41,42,45,46,49,50,53,54,57,58,61,62 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestProductDiscount.swift:18,25,36,37,40,41,44,45,48,49,52,53 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestWebKitNavigationAction.swift:18,20,24,31,33,34,37,38,41,42 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestGraphRequestPiggybackManagerProvider.swift:18,21,25,26 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestPasteboard.swift:18,20,29,32,33,37,38 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestNotificationCenter.swift:18,20,23,29,38,39,40,45,47,49,58,59,63,64,79,80,86,87 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/SampleAEMSingleEntryRules.swift:18,20,22,30,38,46,54,62,70,78 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestProductSubscriptionPeriod.swift:18,22,25,26,29,30 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/FakeLoginManager.h:18,20,22,27,43,45,48,50 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestDylibResolver.swift:18,25,29,30,34,35 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/FBSDKTestCoder.h:18,20,22,25,28,30 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/SampleRawRemotePermissions.swift:18,20,23,41,42,52,53,55,66,67,85,86,97,103,109,111,112,113,117 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestApplicationDelegate.swift:18,21,23,25,33,34 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestBundle.swift:18,21,28,33,36,37,38,41,42,45,46,51,52,58,59 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/SampleAuthenticationToken.swift:18,21,27,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestFileManager.swift:18,21,23,32,34,37,38,46,47,56,57,58,62,63,66,68,69,72,73 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestCollectionView.swift:18,20,24,27,28,31,32,35,36 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestFileDataExtractor.swift:18,21,23,27,35,37,38,41,42 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/SampleAppEvents.swift:18,20,23,26,27,30,31 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestAccessTokenWallet.swift:18,20,26,31,34,35,38,39,44,45 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestAppEventsConfigurationProvider.swift:18,24,28,31,32,36,37,40,41 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/ViewControllerSpy.swift:18,20,23,29,32,36,37,41,44,45,49,50,53,54,63,64 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestPaymentProductRequestor.swift:18,21,24,25 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestFeatureExtractor.swift:18,21,24,27,28,31,32,35,36 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestAppEventsConfiguration.swift:18,22,26,35,36,38,39,43,45,46,49,50 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/SampleGraphResponses.swift:18,20,26,31,34,37,38,39,44,47,50,56,57,58 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/UserDefaultsSpy.h:18,20,22,24,31,33 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/SampleAppEventsConfigurations.swift:18,20,23,25,32,33,42,43,52,53,62,63,74,75,86,87 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestProductsRequestFactory.swift:18,22,26,27 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestTableView.swift:18,20,24,27,28,31,32,35,36 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestAppLinkResolverRequestBuilder.swift:18,20,22,25,28,29,32,33 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestWebViewFactory.swift:18,22,26,27 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/SampleAEMData.swift:18,20,22,34,35,41,42,63,93,111,120,126,128,130,132,140,148,156,164,172,180 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestURLOpener.swift:18,21,29,32,33,36,37,41,42,47,49,50,58,59 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestConversionValueUpdating.swift:18,21,24,26,29,30,33,34 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestCrashObserver.swift:18,23,26,27,29,30 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestEventLogger.swift:18,29,33,34,38,39,48,49,53,54,63,64,75,76,83,84 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/SampleError.swift:18 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestMeasurementEvent.swift:18,21,26,30,31 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestTouch.swift:18,22,25,26 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/AuthenticationSessionSpy.swift:18,20,23,29,32,34,35,44,45,49,50,53,54 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestWindowFinder.swift:18,21,24,25,28,29 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestServerConfigurationProvider.swift:18,20,23,29,32,33,37,38,43,44,47,48,52,53 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/FBSDKTestCase.h:18,20,22,25,27,32,34,36,38,40,42,47,50,53,56,59,62,65,68,75,77 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/SampleProducts.swift:18,23,24,27,28,31,32,35,36,41,42,47,48 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/SampleRawRemoteEventBindings.swift:18,21,26,27,144,145,157,158 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestEventBinding.swift:18,23,26,30,31,32,35,36,39,40 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestControl.swift:18,22,25,26,29,30 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestGraphRequestPiggybackManager.swift:18,20,24,27,28,31,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestErrorConfiguration.swift:18,20,27,36,39,41,42 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/TestSwizzler.swift:18,22,29,30,33,34,35,39,47,48,51,52 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Internal/Helpers/SampleAEMConfigurations.swift:18,20,22,35,36,42,43,46,48,73,74,77,79,102,103 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/DynamicFrameworkLoaderTests.swift:18,26,29,35,128,129,133,136,139,141,142,153,156,157,158,167,170,171,172,185,186,189,190,191,199,202,203,204,211,212,218,219,225,226,230,234,235,239,243,244,249,253,254,260,261,267,268,274,275,281,282,288,289 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/FBSDKLocationTests.m:18,20,23,26,28,30,32,35,42,43,45,48,53,54,56,59,64,65,67,73,74,76,82,83,85,90,91,93,99,100,103,107,109,115,121,122,124,126,128,135,141,142 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/FBSDKUtilityTests.swift:18,20,24,26,27,30,32,33,37,40,41,47,48,55,57,58,59,68,69 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/ProfilePictureViewTests.swift:18,22,24,27,30,31,33,38,40,51,52,57,59,70,71,76,78,89,90,95,97,108,109,111,119,121,127,128,136,138,144,145,154,156,162,163,165,169,171,178,179,183,185,192,193,197,199,206,207,211,213,220,221,222,227,230,232,233,236,238,239,242,243 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/FBSDKCoreKitTests-Bridging-Header.h:18,21,181,183,187,190,192,196,198,200,208,211,213,215,220,222,226,228,236,238,240,243,245,247,251,252,255,257,259,261,264,267,269,271,278,283,295,297,299,304,310,312,314,316,318,322,324,326,328,330,333,335,337,342,344,346,348,350,352,354,359,361,363,368,370,372,374,386,388,390,395,399,401,403,409,411,416,418,421,424,426,428,431,432,434,435 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/SettingsTests.swift:18,21,23,27,30,37,38,41,45,46,53,54,60,61,68,69,75,76,83,84,90,91,98,99,105,106,108,112,133,134,150,151,172,173,194,195,206,207,218,219,222,227,228,230,234,240,241 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/AccessTokenTests.swift:18,22,25,27,30,34,35,39,40,45,46,50,53,55,56,61,65,69,70,82,83,89,90,95,141,142,146,183,184,200,201,216,217,221,222,236,242,243,244 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/ApplicationDelegateTests.swift:18,21,24,47,50,52,53,56,70,71,74,76,77,85,86,125,126,169,170,174,180,181,183,186,191,192,195,197,203,204,207,241,242,250,261,262,265,270,271,273,281,286,287,296,298,327,328,330,333,338,339,342,344,350,351,357,359,364,365,367,378,379,381,388,389,392,398,399,403,409,410,414,420,421,424,430,431,434,441,446,447 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/FBSDKErrorTests.swift:18,20,23,33,38,39,42,44,45,48,50,51,54,56,57,60,65,66,68,71,75,76,79,83,84,91,95,106,107,114,118,129,130,138,142,153,154,162,166,177,178,181,185,201,202,212,216,237,238,241,245,256,257,264,268,279,280,283,287,293,294,310,311,318,320,321,322,324,330,331 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/FBSDKProfileTests.m:18,20,22,27,31,39,41,43,45,52,53,58,60,62,64,69,76,79,80,82,85,87,88,90,95,96,98,100,102,109,110,112,115,121,127,128,130,132,135,142,148,149,151,155,162,168,169,171,174,177,184,190,191,193,196,202,208,209,211,214,220,226,227,229,232,238,244,245,247,250,256,262,263,265,268,274,280,281,283,285,288,294,301,302,304,307,313,320,321,323,326,332,339,340,342,344,346,347,349,351,352,354,356,357,359,361,362,364,366,367,369,371,372,374,376,377,379,381,382,384,386,387,389,392,411,414,415,417,427,434,437,438,440,452,453,455,466,474,477,478,480,491,499,502,503,505,516,524,527,528,530,541,549,552,553,555,566,574,577,578,580,591,599,602,603,605,616,624,627,628,630,632,645,647,653,654,656,667,674,675,677,683,690,691,693,700,707,708,710,727,728,730,733,740,742,744,745,747,757,760,761,763,765,767,769,771,772,774,784,785,787,798,799,801,809,812,813,814,816,818,821,823,904,905,907,910,991,992,994,996,1013,1029,1030,1033,1037,1038 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/CrashObserverTests.swift:18,22,24,29,39,40,46,47,53,54,58,60,62,67,68,73,85,86 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/FBSDKGraphRequestConnectionTests.m:18,21,23,31,39,41,52,94,96,111,116,118,122,124,126,128,130,132,156,157,159,166,168,169,171,173,177,178,179,181,185,186,187,189,193,194,195,200,202,203,205,207,215,216,218,220,226,227,229,231,237,238,240,248,249,251,253,259,260,262,270,271,273,275,281,282,284,292,293,295,297,303,304,306,314,315,317,319,325,326,328,336,337,339,341,347,348,350,352,358,359,361,368,369,371,378,379,381,386,387,389,399,400,401,403,412,413,414,416,420,426,427,429,435,436,438,440,441,443,455,456,458,460,468,469,471,480,481,483,494,495,497,499,511,513,520,521,523,536,548,549,551,567,568,570,587,588,590,593,598,626,627,629,631,645,646,648,660,661,663,675,686,687,689,701,712,713,715,730,741,742,744,751,752,754,771,772,774,776,778,783,785,796,797,798,800,802,807,825,837,838,840,842,868,869,870,872,874,889,890,891,893,906,908,909,911,915,921,922,924,926,928,935,936,937,939,944,945,947,951,956,957,959,963,964,965,967,970,982,983,985,1001,1002,1004,1008,1021,1022,1030,1037,1038,1046,1047,1049,1051,1053,1062,1065,1068,1069,1071,1073,1081,1083,1086,1087,1089,1091,1111,1116,1118,1120,1121,1123,1125,1145,1149,1151,1153,1154,1156,1158,1167,1169,1171,1172,1174,1184,1187,1199,1207,1209,1211,1213,1215,1216,1218,1226,1236,1238,1248,1250,1252,1254,1256,1257,1259,1277,1285,1287,1289,1291,1293,1294,1296,1299,1303,1306,1307,1309,1312,1316,1319,1320,1322,1326,1330,1333,1334,1336,1338,1345,1348,1350,1352,1353,1355,1359,1366,1367,1369,1376,1384,1385,1387,1389,1398,1399,1401,1404,1415,1417,1419,1425,1426,1428,1433,1436,1441,1442,1444,1452,1455,1457,1458,1460,1462,1464,1466,1469,1494,1496,1499,1502,1508,1510,1511,1513,1515,1517,1528,1531,1533,1536,1539,1541,1542,1544,1546,1551,1561,1562,1564,1576,1577,1579,1583,1584,1585,1587,1594,1597,1598,1600,1605,1611,1613,1623,1633,1644,1645,1647,1654,1655,1657,1659,1661,1662,1664,1666,1667,1669,1671,1672,1674,1676,1677,1679,1683,1684,1686,1690,1691,1693,1697,1698,1700,1702,1703,1705,1718,1719,1721,1722,1724,1729,1730,1732,1737,1738,1740,1753,1755,1757,1758,1760,1762,1763 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/FBSDKGraphRequestTests.m:18,20,22,33,38,40,41,43,45,46,48,50,52,54,56,58,60,63,65,67,69,72,73,75,77,85,86,88,98,104,105,107,109,115,116,118,120,129,134,141,143,144,146,151,160,161,162,164,169,178,179,180,182,190,191,193,197,205,206,207,209,213,221,222,223,225,237,239,243,246,247,249,258,266,274,275,277,288,289,291,295,301,302,304,313,314,316,323,329,330 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/AppLinkNavigationTests.swift:18,20,22,28,34,35,36,43,46,48,49,52,59,60,63,65,66,72,73,80,81,83,88,98,99,100,109,119,120,121,124,127,132,133,144,145,146,150,154,164,165,166,174,188,189,190,192,210,211,229,230,248,249,255,282,283,306,307,313,320,326,327,329,336,337,342,348,349,354,360,361,366,372,373,378,384,385,387,395,396,400,406,407,409,415,418,420,438,439,440,446,450,453,471,472,473,478,479,484,485,487,488,493,498,499,501,506,508,511,512,517,522,523,525,533,535,538,539,541,546,548,555,556,558,571,572,574,575 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/FBSDKAuthenticationTokenClaimsTests.m:18,20,23,28,30,51,53,55,57,59,61,64,65,67,69,76,78,80,102,104,105,107,109,112,113,115,117,120,123,124,126,129,131,132,134,136,144,152,160,168,176,182,188,189,191,195,196,198,202,206,210,211,213,216,219,222,223,225,229,231,232,234,239,241,242,243,245,247,253,254,257,259,260,262,268,269,272,276,277,279,284,285,287,310,312,313 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/FBSDKUserAgeRangeTests.m:18,20,23,26,28,30,32,35,42,43,45,48,55,56,58,61,68,69,71,77,78,80,86,87,89,94,95,97,103,104,106,112,113,115,121,122,124,127,132,133,135,141,142,144,146,150,151,152,155,159,161,167,173,174,176,178,180,187,193,194 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Interfaces/FBSDKEventDeactivationManager+Testing.h:18,20,22,24,26,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Interfaces/SuggestedEventsIndexer+Testing.h:18,20,24,26,28,38,40,49,58,60 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Interfaces/FBSDKEventBinding+Testing.h:18,20,22,24,26,28,32,34 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Interfaces/FBSDKHybridAppEventsScriptMessageHandler+Testing.h:18,20,22,24,26,28,31,33 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Interfaces/PaymentProductRequestor+Testing.h:18,20,24,26,28,39,51,53 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Interfaces/WebViewAppLinkResolver+Testing.h:18,20,22,25,27,29,34,36 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Interfaces/ImageDownloader+Testing.h:18,20,22,24,26,29,32,34 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Interfaces/FeatureManager+Testing.h:18,20,22,24,26,29,33,35,37 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Interfaces/CodelessIndexer+Testing.h:18,20,22,24,35,38,43,46,48 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Interfaces/FBSDKAppLinkUtility+Testing.h:18,20,22,24,27,30,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Interfaces/FBSDKAccessTokenExpirer+Testing.h:18,20,22,24,26,29,31 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Interfaces/PaymentObserver+Testing.h:18,21,23,25,27,30,34,36,38 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Interfaces/Button+Testing.h:18,20,22,24,26,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Interfaces/FBSDKWebDialog+Testing.h:18,20,22,24,26,28,30,32,34 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Interfaces/FBSDKEventBindingManager+Testing.h:18,20,23,25,27,35,56,58 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Interfaces/FBSDKModelManager+Testing.h:18,20,23,25,27,35,40,47,49 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Interfaces/FBSDKWebDialogView+Testing.h:18,20,25,27,29,35,37,39 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Interfaces/BackgroundEventLogger+Testing.h:18,21,23,25,28,30,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Interfaces/FBSDKErrorReport+Testing.h:18,20,22,26,28,35,40,42 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Interfaces/AEM+Testing.h:18,32,34,36,38,40,42,44,46,48,50,55,61,76,78,80,82,84,86,88,90,92,94,96,98,100,102,111,113,115,117,119,126,128,130,132,134,136,138,140,142,144,146,148,150,152,154,156,158,160,162,164,167,171,173,177,179,181 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Interfaces/AppEventsAtePublisher+Testing.h:18,20,22,24,27,29 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Interfaces/FBSDKIntegrityManager+Testing.h:18,23,25,27,32,34,36 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Interfaces/FBSDKBridgeAPIProtocolWebV2+Testing.h:18,20,24,26,28,31,34,40,42 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Interfaces/FBSDKError+Testing.h:18,20,22,24,26,28,30,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Interfaces/FBSDKCrashHandler+Testing.h:18,20,23,25,26,28,32,34,39,48 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Interfaces/ApplicationDelegate+Testing.h:18,20,22,40,42,55,58,74,76 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Interfaces/FBSDKBridgeAPI+Testing.h:18,25,29,31,33,36,42,44,60,62,64,71,81,87,92,103,108,113,115,117,123,128,130 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Interfaces/FBSDKInstrumentManager+Testing.h:18,24,26,28,34,40,42 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Interfaces/FBSDKTimeSpentData+Testing.h:18,20,22,24,29,33,35 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit/FBSDKCoreKitTests/Interfaces/PaymentProductRequestorFactory+Testing.h:18,20,22,24,32,34 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKTVOSKit/FBSDKTVOSKit/FBSDKTVLoginButtonElement.h:18,20,22,24,29,36,38,43,47,49 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKTVOSKit/FBSDKTVOSKit/FBSDKDeviceLoginViewController.h:18,20,22,24,26,32,37,42,47,49,54,56,58,69,74,79,82,86,92,94 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKTVOSKit/FBSDKTVOSKit/FBSDKTVInterfaceFactory.m:18,20,22,31,34,36,38,39,41,44,45,49,50,52,55,62,65,67,68,70,77,80,82,83,85,88,90,91,93,98,100,101 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKTVOSKit/FBSDKTVOSKit/FBSDKJS.h:18,21,23,30,35,40,46,53,61,69,80,82,90,92,98,100 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKTVOSKit/FBSDKTVOSKit/FBSDKTVOSKit.h:18,26 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKTVOSKit/FBSDKTVOSKit/FBSDKDeviceLoginButton.h:18,20,22,24,26,33,39,44,49,52,56,62,64,71,76,82,87,92,94 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKTVOSKit/FBSDKTVOSKit/FBSDKTVOSConstants.h:18,20,22,24,31,33,40,42,48,53,59 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKTVOSKit/FBSDKTVOSKit/FBSDKTVLoginViewControllerElement.m:18,20,22,24,30,31,33,39,40,42,48,49 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKTVOSKit/FBSDKTVOSKit/FBSDKDeviceLoginViewController.m:18,20,22,28,33,35,38,39,41,44,45,47,49,51,52,54,57,58,60,62,64,65,67,72,123,125,126,127,129,133,147,148,149,151,154,157,158,162,211,212,214,219,227,228,230,233,234 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKTVOSKit/FBSDKTVOSKit/FBSDKTVLoginButtonElement.m:18,20,22,24,26,32,33,35,41,42,44,50,51,53,59,60 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKTVOSKit/FBSDKTVOSKit/FBSDKTVInterfaceFactory.h:18,20,22,24,32,34,37,40,44,47,53,55 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKTVOSKit/FBSDKTVOSKit/FBSDKDeviceLoginButton.m:18,20,26,32,34,36,38,40,43,44,46,48,50,51,53,57,58,60,61,63,66,72,78,79,81,87,88,90,92,95,109,111,117,118,120,122,125,126,127,129,133,154,187,188,189,191,198,199,201,210,211,213,222,223,225,234,235,237,250,252,257,258,259,261,263,265,266,268,270,271,273,275,276 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKTVOSKit/FBSDKTVOSKit/FBSDKJS.m:18,20,22,24,26,28,29,31,33,34,36,38,39,41,43,44,46,48,49,51,53,54,56,58,59 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKTVOSKit/FBSDKTVOSKit/FBSDKTVLoginViewControllerElement.h:18,20,22,24,29,37,38,42,47,53,56,59,61 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKTVOSKit/FBSDKTVOSKit/FBSDKTVOSConstants.m:18,20,22,24,26,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKTVOSKit/FBSDKTVOSKitTests/FBSDKTVOSKitTests.m:18,20,22,24,26,28,31,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/FBSDKContextDialog.m:18,20,22,24,26,28,30,32,34,36,38,40,45,46,48,52,53,55,60,61,63,67,68,70,72,74,75,77,85,89,90,93,96,97,99,104,105,111,112,114,118,119,125,126,127,131,132,138,139,140,142,143,145,147,150,151,156,157,159,162,165,166,168,171,174,175,177,179,182,187,191,195,196,199,200,201,203 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/FBSDKGamingImageUploaderConfiguration.m:18,20,22,24,26,27,31,36,38,39 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/FBSDKGamingPayloadObserver.m:18,20,23,26,28,30,32,35,37,38,40,44,45,48,50,51,53,58,62,63,68,69,71,72 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/FBSDKContextSwitchAsyncContent.m:18,20,22,24,26,28,31,33,35,37,45,47,49,50,52,54,59,60,62,65,68,70,71,73,76,77,79,81,83,84,86,89,91,92,94,96,97,99,101,105,106,108 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/FBSDKGamingPayload.h:19,21,23,26,29,33,36,39,41 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/FBSDKContextCreateAsyncContent.h:18,20,22,24,25,27,33,39,42,44 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/FBSDKGamingVideoUploaderConfiguration.h:18,21,23,26,29,31,34,40,42 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/FBSDKGamingServiceCompletionHandler.h:18,21,24,30,33,40,43 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/FBSDKGamingVideoUploader.m:18,20,24,26,32,34,36,38,40,41,44,50,51,55,64,66,67,76,78,79,84,93,95,96,98,105,107,114,116,117,122,128,130,131,135,137,143,144,147,148,150,151,153,156,157,160,162,163,165,169,175,176,178,180,181,184,186,191,192,195,200,201 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/FBSDKFriendFinderDialog.m:18,20,24,26,28,30,32,36,43,44,46,48,49,51,54,56,57,59,61,62,64,72,74,75,82,83,85,87,88 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/Internal/FBSDKGamingServiceController.m:18,20,22,26,28,32,35,38,39,40,42,50,51,53,57,58,62,67,69,70,72,80,82,83,85,88,89,107,108,110,111,113,116,117,123,130,133,134,136,137,142,147,148,150,153,154,155,157,159,160,162,164,169,170 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/Internal/FBSDKGamingServiceControllerProtocol.h:18,20,22,24,27,29,31 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/Internal/FBSDKGamingServiceControllerFactory.h:18,20,22,24,27 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/Internal/FBSDKGamingServicesCoreKitImport.h:18 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/Internal/FBSDKGamingServiceControllerCreating.h:18,20,22,24,27,31,33 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/Internal/FBSDKCoreKitInternalImport.h:18,27 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/Internal/FBSDKVideoUploader.m:18,20,22,24,38,40,42,44,46,48,51,53,60,61,64,72,74,75,77,80,81,83,85,103,107,115,120,122,123,125,144,155,161,165,170,171,172,174,196,202,204,205,207,217,224,225,230,231,233,237,239,240,242,248,251,252 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/Internal/FBSDKGamingServiceController+GamingServiceControllerProtocol.h:18,20,23,25,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/Internal/FBSDKGamingServiceController.h:18,20,22,24,29,31,33,36,44,46 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/Internal/FBSDKGamingServiceControllerFactory.m:18,20,22,24,26,30,35,36,38 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/Internal/FBSDKVideoUploader.h:18,20,22,26,31,34,44,49,54,59,65,67,70,75,83,91,98 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/FBSDKGamingImageUploader.h:18,20,26,28,31,33,36,44,47,58 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/FBSDKGamingGroupIntegration.m:18,20,23,25,27,34,35,37,39,40 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/FBSDKGamingPayloadObserver.h:18,20,22,26,28,31 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/FBSDKGamingImageUploaderConfiguration.h:18,21,23,26,30,32,35,44,46 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/FBSDKContextDialog.h:18,20,22,24,27,29,31,37,40,49,58,67,76,81,86,91,94,98,103,109,116,118,121,128,135,142,148,150,152 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/FBSDKGamingVideoUploaderConfiguration.m:18,20,22,24,26,27,30,34,36,37 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/FBSDKContextCreateAsyncContent.m:18,20,22,24,26,30,32,34,36,44,46,48,49,51,53,58,59,61,64,67,69,70,72,75,76,78,80,82,83,85,88,90,91,93,95,96,98,100,104,105,107 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/Swift/Exports.swift:18 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/FBSDKGamingPayload.m:2,4,6,9,11,13,16,18,19,21,24,26,27,29,32,34,35 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/FBSDKContextSwitchAsyncContent.h:18,20,22,24,26,32,38,41,43 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/FBSDKFriendFinderDialog.h:18,20,26,29,31,35,40 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/FBSDKGamingVideoUploader.h:18,21,27,29,32,34,37,43,46,55 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/FBSDKGamingServicesKit.h:18,20,33,35,48 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/FBSDKGamingGroupIntegration.h:18,20,26,29,31 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKit/FBSDKGamingImageUploader.m:18,20,25,27,29,30,32,34,36,40,47,48,50,52,53,55,58,60,61,63,66,68,69,72,75,76,79,85,86,90,94,95,99,108,110,111,120,122,123,126,130,133,142,146,157,158,162,163,169,172,174,175,177,182,185,186,188,189 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKitTests/FBSDKGamingServicesKitTests-Bridging-Header.h:18,20 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKitTests/FBSDKGamingImageUploaderTests.m:18,21,23,27,29,33,35,37,39,41,43,47,48,50,52,54,55,57,59,65,66,68,70,73,79,83,84,86,88,90,98,100,101,103,105,113,115,116,118,120,128,130,131,133,142,152,168,170,172,173,175,177,184,186,187,189,193,200,216,218,220,221,223,226,228,233,241,247,249,250,256,259,264,272,274,276,277,279,287,296,303,306,309,310,312,314,321,322,325,329,344,346,347,349,353,369,370,372,374,385,386,388,393,394 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKitTests/FBSDKGamingServicesKitTestUtility.m:18,20,22,24,26,28,31,38,39 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKitTests/FBSDKGamingServicesKitTestUtility.h:18,20,22,24,26 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKitTests/FBSDKGamingVideoUploaderTests.m:18,21,23,27,30,32,35,36,38,40,43,46,47,49,51,56,59,60,62,64,72,74,75,77,79,87,89,90,92,95,103,105,106,108,113,115,123,125,127,128,130,135,143,149,151,152,154,159,167,173,175,176,178,183,192,199,205,214,220,229,236,240,241,243,245,250,256,259,267,269,270 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKitTests/FBSDKFriendFinderDialogTests.m:18,20,22,26,28,32,34,36,38,39,41,43,51,52,54,56,58,59,61,63,69,70,72,74,76,83,85,86,88,94,110,112,113,115,123,138,140,142,143,145,150,157,159,161,162,168,173,180,182,184,185,187,189,200,201 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKitTests/Helpers/TestGamingServiceControllerFactory.swift:18,20,24,27,28,29,32,37,46,48,49 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKitTests/Interfaces/FBSDKGamingImageUploader+Testing.h:18,20,22,24,26,29,31,34,38,40 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKGamingServicesKit/FBSDKGamingServicesKitTests/Interfaces/FBSDKFriendFinderDialog+Testing.h:18,20,22,24,26,29,31,33,35 ./Carthage/Checkouts/facebook-ios-sdk/TestTools/TestTools/SampleAccessTokens.swift:18,21,24,28,40,52,65,66,79,80,93,94,111,112 ./Carthage/Checkouts/facebook-ios-sdk/TestTools/TestTools/TestSessionProvider.swift:18,21,27,30,31,34,35,38,39,40,50,59,60 ./Carthage/Checkouts/facebook-ios-sdk/TestTools/TestTools/TestGraphRequest.swift:18,20,35,41,44,45,51,54,55,62,66,67,74,78,79,86,90,91,100,107,108,117,123,124,128,130,131,134,135,138,139 ./Carthage/Checkouts/facebook-ios-sdk/TestTools/TestTools/TestGraphRequestConnection.swift:18,20,23,25,29,30,39,42,54,55,58,59,62,63 ./Carthage/Checkouts/facebook-ios-sdk/TestTools/TestTools/SampleUserProfiles.swift:18,20,23,27,49,50,53,56,57,60,61,90,91 ./Carthage/Checkouts/facebook-ios-sdk/samples/SmoketestSPM/SmoketestSPM/VerifyFacebookLogin.swift:18,20,25,28,31,32,36,39,42,43 ./Carthage/Checkouts/facebook-ios-sdk/samples/SmoketestSPM/SmoketestSPM/SmoketestSPM.h:18,20,23,26 ./Carthage/Checkouts/facebook-ios-sdk/samples/SmoketestSPM/SmoketestSPM/VerifyFacebookCore.swift:18,20,25,28,31,32 ./Carthage/Checkouts/facebook-ios-sdk/samples/SmoketestSPM/SmoketestSPM/VerifyFacebookShare.swift:18,20,25,28,31,32,36,39,40 ./Carthage/Checkouts/facebook-ios-sdk/samples/SmoketestSPM/SmoketestSPM/VerifyFacebookGamingServices.swift:18,20,25,28,31,32,36,37 ./Carthage/Checkouts/facebook-ios-sdk/samples/FacebookShareSample/FacebookShareSample/ShareViewControllerExtensions.swift:18,21,23,26,34,35,44,45,46,51,53,54,57,61,62,64,65,66 ./Carthage/Checkouts/facebook-ios-sdk/samples/FacebookShareSample/FacebookShareSample/ShareViewController.swift:18,21,23,27,28,32,34,35,44,51,52,56,58,64,65,67,68,75,76,77,78,80,83,84,87,88,91,92,93,94 ./Carthage/Checkouts/facebook-ios-sdk/samples/FacebookShareSample/FacebookShareSample/AppDelegate.swift:18,21,24,34,35,42,48,49,60,61,62,63 ./Carthage/Checkouts/facebook-ios-sdk/samples/FacebookShareSample/FacebookShareSample/SceneDelegate.swift:18,19,22,24,26,30,31,38,39,40 ./Carthage/Checkouts/facebook-ios-sdk/samples/FacebookLoginSample/FacebookLoginSample/LoginButtonViewController.swift:18,21,23,27,30,31,34,37,38,39,40,42,45,48,49,51,52,60,61,67,68,74,75,77,78,81,82,83 ./Carthage/Checkouts/facebook-ios-sdk/samples/FacebookLoginSample/FacebookLoginSample/LoginManagerViewController.swift:18,21,23,27,30,31,34,35,37,45,51,52,53,56,58,59,64,65,67,68,75,76,92,93,94,95,101,102,103 ./Carthage/Checkouts/facebook-ios-sdk/samples/FacebookLoginSample/FacebookLoginSample/LoginViewController.swift:18,21,26,29,30,33,41,42,51,52,53,58,60,61,64,68,69,71,72,75,76,77 ./Carthage/Checkouts/facebook-ios-sdk/samples/FacebookLoginSample/FacebookLoginSample/AppDelegate.swift:18,21,24,34,36,37,48,49,51,62,63,64,65 ./Carthage/Checkouts/facebook-ios-sdk/samples/FacebookLoginSample/FacebookLoginSample/LoginDetailsViewController.swift:18,22,24,33,36,39,43,61,62,63 ./Carthage/Checkouts/facebook-ios-sdk/samples/FacebookLoginSample/FacebookLoginSample/SceneDelegate.swift:18,21,24,26,30,31,38,39,40,41 ./Carthage/Checkouts/facebook-ios-sdk/samples/RPSSample/RPSSample/RPSAutoAppLinkSwiftViewController.swift:18,21,25,28,31,35,39,44,48,51,55,59,69,71,72 ./Carthage/Checkouts/facebook-ios-sdk/samples/RPSSample/RPSSample/RPSCommonObjects.h:18,25,31 ./Carthage/Checkouts/facebook-ios-sdk/samples/RPSSample/RPSSample/RPSRootViewController.m:18,20,23,25,27,30,36,37,40,45,48,49 ./Carthage/Checkouts/facebook-ios-sdk/samples/RPSSample/RPSSample/RPSAppDelegate.h:18,20,28,30,34 ./Carthage/Checkouts/facebook-ios-sdk/samples/RPSSample/RPSSample/RPSGameViewController.m:18,20,23,27,31,38,45,52,54,57,59,70,71,73,78,80,84,88,92,96,100,106,108,110,111,113,115,117,120,123,127,129,138,144,150,154,161,168,173,176,177,178,180,183,184,186,195,196,197,199,202,203,205,218,219,221,227,228,229,231,242,246,248,249,251,256,259,260,262,268,274,280,289,299,300,302,304,305,308,315,316,318,322,328,332,349,351,354,355,356,358,360,361,363,369,370,372,375,376,378,390,391,393,398,399,400,401,403,410,412,416,418,425,429,447,451,452,453,454,455,457,459,460,462,464,465,467,474,479,480,482,486,487,489,501,502,504,508,509,511,514,516,525,526,528,530,531,535,543,545,546,551,553,554,557,559,560,562,570,571,576,584,585,587,600,603,604,606,619,626,627,635,636,643,644,646,648,650,651,653,655,656,658,660,661,663,667,672,681,682,683,685,691,692,694,704,705 ./Carthage/Checkouts/facebook-ios-sdk/samples/RPSSample/RPSSample/RPSFriendsViewController.m:18,20,22,26,29,31,34,35,37,42,43,45,46,48,50,52,66,67,79,84,85,86,87,89,91,98,99,102,104,105,107,109,111,114,115,118,122,123,125,128,132,133,135,137,138,140,142,158,159,164,168,169,173,177,199,200,203,205,218,221,222,236,247,248,251,253,255,256,258,261,262,264,268,269,279,282,297,300,301 ./Carthage/Checkouts/facebook-ios-sdk/samples/RPSSample/RPSSample/RPSAutoAppLinkDebugTool.h:18,20,22,25 ./Carthage/Checkouts/facebook-ios-sdk/samples/RPSSample/RPSSample/RPSAutoAppLinkBasicViewController.h:18,20,22,24 ./Carthage/Checkouts/facebook-ios-sdk/samples/RPSSample/RPSSample/RPSAppLinkedViewController.m:18,20,22,28,30,32,34,36,38,42,43,45,46,48,50,52,53,55,57,59,63,75,78,79,81,82 ./Carthage/Checkouts/facebook-ios-sdk/samples/RPSSample/RPSSample/RPSCoffee.h:18,20,22,26,28 ./Carthage/Checkouts/facebook-ios-sdk/samples/RPSSample/RPSSample/RPSAutoAppLinkStoryboardViewController.h:18,20,22,24 ./Carthage/Checkouts/facebook-ios-sdk/samples/RPSSample/RPSSample/main.m:18,20,22,24,27,28 ./Carthage/Checkouts/facebook-ios-sdk/samples/RPSSample/RPSSample/RPSRootViewController.h:18,20,22,24 ./Carthage/Checkouts/facebook-ios-sdk/samples/RPSSample/RPSSample/RPSCommonObjects.m:18 ./Carthage/Checkouts/facebook-ios-sdk/samples/RPSSample/RPSSample/RPSSample-Bridging-Header.h:18 ./Carthage/Checkouts/facebook-ios-sdk/samples/RPSSample/RPSSample/RPSAppLinkedViewController.h:18,20,22,24 ./Carthage/Checkouts/facebook-ios-sdk/samples/RPSSample/RPSSample/RPSAutoAppLinkBasicViewController.m:18,20,22,24,27,29,31,33,35,39,43,47,51,54,58,62,75,77,78 ./Carthage/Checkouts/facebook-ios-sdk/samples/RPSSample/RPSSample/RPSAutoAppLinkDebugTool.m:18,20,22,24,27,29,31,33,37,42,48,51,54,60,67,68,71,82,83,85,96,104,105,106,107,109,116,117 ./Carthage/Checkouts/facebook-ios-sdk/samples/RPSSample/RPSSample/RPSFriendsViewController.h:18,20,22,24,26,28,30 ./Carthage/Checkouts/facebook-ios-sdk/samples/RPSSample/RPSSample/RPSGameViewController.h:18,20,22,26,28,31,35,38,41,45 ./Carthage/Checkouts/facebook-ios-sdk/samples/RPSSample/RPSSample/RPSAppDelegate.m:18,20,23,30,32,34,36,41,54,55,56,57,59,60,62,66,71,72,78,86,87,93,94,96,99,103,107,110,112,114,115 ./Carthage/Checkouts/facebook-ios-sdk/samples/RPSSample/RPSSample/RPSAutoAppLinkStoryboardViewController.m:18,20,22,25,30,32,34,36,38,41,42,46,49,50,51 ./Carthage/Checkouts/facebook-ios-sdk/samples/RPSSample/RPSSample/RPSCoffee.m:18,20,22,24,29,31,32 ./Carthage/Checkouts/facebook-ios-sdk/samples/HelloTV/HelloTV/FirstViewController.swift:18,22,27,29,32,35,42,43,47,48,52,53,56,63,64,68,72,73,81,85,86,90,91,95,96,98,99,100,102,105,106,110,111,115,116,119,120,121,123,126,127,128 ./Carthage/Checkouts/facebook-ios-sdk/samples/HelloTV/HelloTV/AppDelegate.swift:18,22,25,27,33,34,37,38 ./Carthage/Checkouts/facebook-ios-sdk/samples/HelloTV/HelloTV/SecondViewController.swift:18,24,27,29,32,44,45,48,56,57,59,65,66,70,76,78,79,88,91,92,93,95,100,101,104,105,108,109 ./Carthage/Checkouts/facebook-ios-sdk/testing/TestXcodeIntegration/TestXcodeIntegration/ViewController.swift:18,20,22,26,27 ./Carthage/Checkouts/facebook-ios-sdk/testing/TestXcodeIntegration/TestXcodeIntegration/AppDelegate.swift:18,20,25,28,32,33,35,40,41,46,47 ./Carthage/Checkouts/facebook-ios-sdk/testing/TestXcodeIntegration/TestXcodeIntegration/SceneDelegate.swift:18,20,22,24,30,31,37,38,42,43,47,48,52,53,58,59 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/FBSDKLoginConfiguration.h:18,20,22,24,28,31,34,38,42,46,50,53,56,59,62,65,68,80,83,97,100,110,113,122,125,136,139,146,149,154,157,161,163 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/FBSDKReferralManager.h:18,20,22,24,26,28,37,43,49,55,57,59 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/FBSDKDeviceLoginManagerResult.h:18,20,24,26,28,35,41,46,52,54 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/FBSDKLoginButton.h:18,20,22,24,26,28,30,32,34,37,39,41,47,57,60,64,67,73,86,89,118,120,127,138,144,152,154,156 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/FBSDKLoginConstants.h:18,20,22,24,27,32,34,37,42,44,50,56,61,66,71,76,81,86,93,98,103,108,114,137 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/include/FBSDKCoreKitImport.h:18,23 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/FBSDKReferralCode.m:18,20,22,24,26,28,30,33,34,38,39,43,45,46,48,51,52,55,56,58,60,61,63 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/FBSDKDeviceLoginCodeInfo.m:18,20,22,28,35,37,38 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/FBSDKDeviceLoginManager.h:18,20,23,25,27,33,42,53,55,62,67,75,78,83,88,94,100,105,107 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/FBSDKReferralManagerResult.h:18,20,22,24,26,28,34,37,42,47,56,58 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/FBSDKLoginManagerLoginResult.m:18,20,22,24,30,32,34,36,37,43,51,54,55,57,59,60,62,64,65,67 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKProfileFactory.h:18,20,22,24,26,28,30,33,35,37 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKLoginCompletion.h:18,20,22,24,31,34,36,42,50,53,56,60,64,67,69,72,74,76,78,81,87,94,96,98,102,105,110,117,119,121 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKDeviceLoginManagerResult+Internal.h:18,20,26,28,30,32,40,42 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKPermission.h:18,20,22,25,28,33,37,41,47,53,55 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKLoginManagerLogger.h:18,20,22,24,29,30,35,38,42,46,49,51,55,57,59,62 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKDeviceRequestsHelper.m:18,20,22,24,30,32,42,44,46,48,50,52,59,60,62,73,75,76,78,87,99,111,113,114,116,119,120,122,129,130,131 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/_FBSDKLoginRecoveryAttempter.m:18,20,22,24,27,29,33,44,45,46,48 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKCoreKitBasicsImportForLoginKit.h:18,20 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKAuthenticationTokenCreating.h:18,20,23,26,32,34 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKAuthenticationTokenFactory.h:18,20,27,29,36,50,62,64 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKAuthenticationTokenHeader.m:18,20,22,24,28,33,34,36,37,39,42,50,51,52,54,55,57,61,62,64,67,68,71,72,74,75 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKProfileCreating.h:18,20,22,27,29,32,50,52,54 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKLoginUtility.m:18,20,22,24,30,36,39,41,43,51,52,53,55,66,67,69,73,74,76,77,79,82,83,86,92,93,95,96,98 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKLoginError.h:18,20,22,24,30,32,34,37,40,42,44 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKMonotonicTime.h:18,20,22,24,26,35 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKNonceUtility.m:18,20,22,24,26,30,32,33 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKDeviceLoginCodeInfo+Internal.h:18,20,22,24,26,40,42 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKReferralManagerLogger.m:18,20,22,24,28,36,38,42,45,48,50,55,56,58,65,67,68,70,72,73,75,77,84,85,88,94,99,106,111,119,120,122,123,125,127,150,152,153,155,164,166,170,171,172,174 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKLoginKit+Internal.h:18 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKLoginCompletion.m:18,20,22,24,30,39,41,43,45,46,48,51,53,54,56,58,60,66,67,70,72,75,76,77,82,87,91,95,107,108,110,111,113,115,116,121,136,137,138,143,150,157,158,160,166,170,178,180,182,187,188,191,192,196,197,199,201,205,206,210,211,214,217,218,221,226,227,246,252,255,256,259,261,262,264,267,268,272,273,278,279,296,297,299,304,311,312,313,315,321,322,323,325,330,335,336,337,339,340,342,345,347,348,350,353,355,357,358,360,362,363,365,367,368,370,372,373,376,378 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKLoginManagerLoginResult+Internal.h:18,20,22,24,26,28,30,33,37 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKProfileFactory.m:18,20,22,24,26,28,45,62,63,65 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKLoginManagerLogger.m:18,20,22,24,30,35,38,47,49,54,57,60,63,66,69,72,75,77,81,84,87,88,91,93,102,103,105,106,109,115,116,121,123,124,126,131,140,142,143,145,149,150,151,153,156,157,159,161,172,173,174,178,180,181,183,185,186,188,190,191,195,197,203,211,212,214,217,220,226,227,229,235,236,237,239,241,242,244,246,248,249,253,259,264,265,267,268,270,272,282,284,285,287,294,296,300,301,302,304,306,308,311,316,319,324,327,331,332,334,335,337 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKPermission.m:18,20,22,24,26,30,31,35,36,39,41,42,44,46,51,53,54,56,57,59,61,64,65,67,68,70,73,74,77,78,80,82,83,85,87,88 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKLoginCompletion+Internal.h:18,20,22,24,26,29,33,37,40,42,45,47,49,51,53,55,57 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKLoginManager+Internal.h:18,20,22,24,30,36,41,47,55,63,66,68,70,78,83,91,93 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKAuthenticationTokenFactory.m:18,20,22,24,28,31,34,38,40,44,46,48,50,52,54,56,58,61,62,64,67,68,70,73,75,76,80,85,86,91,95,96,100,105,106,110,113,117,118,131,133,134,140,146,149,158,162,178,180,181,184,188,193,195,198,199,202,203,206,207,210,216,217,222,223,224,230,234,239,240,242,248,250,251,253,256,258,260,262,263,265,267,268,270,272,273,276 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKDeviceRequestsHelper.h:18,20,22,24,27,33,38,45,53,59,61 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/_FBSDKLoginRecoveryAttempter.h:18,20,22,28,30,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKReferralManagerLogger.h:18,20,22,24,27,29,31,33 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKMonotonicTime.m:18,20,22,24,29,31,38,40,41,43,46,47 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKNonceUtility.h:18,20,22,25,30,33,35 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKLoginError.m:18,20,22,24,26,32,38,40,45,47,49,51,52,55,57,59,62,117,118,121,125,126,128,141,143,147,148,150,152,155,159,162,163,165,169,170,172,173,175,177,183,197,198,199,201,202,205,211,218,227,235,236,239,245,246,247,249,250,252 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKLoginUtility.h:18,20,22,24,30,33,36,39,41,43 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKReferralManager+Internal.h:18,20,22,28,34,36,38 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Internal/FBSDKAuthenticationTokenHeader.h:18,20,22,24,27,30,33,39,41 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/FBSDKTooltipView.h:18,20,22,24,26,29,33,39,42,46,52,54,57,58,59,64,71,77,82,87,90,92,94,96,97,98,100,101,107,111,115,116,117,123,126,128,130,138,141,142,143,147,149,151 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/FBSDKLoginTooltipView.m:18,20,22,24,30,33,35,37,47,48,50,59,64,68,69,71,72,73,75 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/FBSDKCoreKitImport.h:18,23 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/FBSDKLoginManager.h:18,20,22,24,26,35,38,41,44,46,49,54,59,61,63,65,74,75,78,80,87,95,98,101,105,111,114,118,121,127,133,142,145,150,157,166,171,174,180,186,193,200,203,205,209,211,213 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/FBSDKLoginButton.m:18,20,22,24,30,34,40,42,44,49,50,52,54,56,57,59,61,63,64,66,68,69,71,74,75,77,79,84,85,86,88,96,97,98,100,102,104,109,110,111,113,115,119,120,122,125,129,131,132,134,142,143,145,146,148,151,153,158,159,163,164,166,168,170,173,191,193,195,196,198,200,202,203,205,214,215,217,220,221,222,224,226,227,229,233,234,236,257,298,299,300,304,306,308,311,312,316,317,318,320,332,333,334,336,344,345,347,355,356,358,366,367,369,377,379,380,381,387,390,397,398,399,401,407,408,409,410,412,421,423,424,426,428,432,433,434,436,438,439,441,443,444,446,449,450,452,453,455,458,460,462,463,465,467,468,471,473 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/FBSDKDeviceLoginManagerResult.m:18,20,22,25,29,31,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/FBSDKReferralManager.m:18,20,22,24,30,35,42,44,50,51,53,57,58,60,61,63,66,68,76,77,83,88,89,90,92,96,98,101,105,110,111,116,117,119,120,122,124,126,127,129,133,137,138,139,141,144,145,147,149,150,152,161,163,164,165,167,171,172,175,176,178,180,185,189,195,196,205,206,207,212,215,216,218,219,224,228,229,231,233,234,236,238,239,241 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/FBSDKLoginKit.h:18,20,27 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/FBSDKLoginConfiguration.m:18,20,22,24,26,32,35,38,42,44,46,49,50,53,57,58,62,67,68,73,79,80,84,89,90,95,101,102,108,114,115,121,122,127,128,135,136,138,139,141,148,149,151,152,154,159,161,162,164 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Swift/FBLoginButton.swift:18,20,24,26,28,31,34,37,45,52,53,54 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Swift/LoginConfiguration.swift:18,22,24,26,29,53,54 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Swift/Exports.swift:18 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/Swift/LoginManager.swift:18,20,24,26,28,32,44,49,50,54,55,59,60,61,66,69,77,83,84,87,91,95,98,109,110,113,117,121,124,137,139,140,143,147,151,154,165,167,168,172,174,175,180,181,182,183 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/FBSDKLoginConstants.m:18,20,22,24,26,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/FBSDKReferralManagerResult.m:18,20,22,24,26,29,33,36,37,39 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/FBSDKDeviceLoginManager.m:18,20,22,29,34,36,38,43,44,46,49,50,51,53,57,59,60,62,65,81,82,89,94,95,99,100,102,106,107,109,111,117,118,120,126,156,178,184,185,186,188,203,204,205,207,212,213,224,232,233,237,238,246,247,250,251,254,258,259,260 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/FBSDKDeviceLoginCodeInfo.h:18,20,22,29,35,40,45,50,55,60,62 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/FBSDKReferralCode.h:18,20,22,24,26,32,35,40,47,49,51 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/FBSDKLoginManager.m:18,20,22,24,26,33,44,51,53,60,61,63,67,68,69,71,76,78,79,83,86,87,91,92,96,102,106,107,111,113,114,118,124,125,127,130,131,140,141,147,148,150,154,155,158,163,166,176,177,178,180,182,190,191,193,202,203,209,213,217,218,219,221,223,224,226,228,232,235,237,241,246,249,250,251,253,255,256,259,262,269,270,271,276,280,281,284,291,292,293,295,301,312,313,314,315,317,319,320,322,324,325,330,338,339,341,356,359,362,363,370,371,377,380,389,390,393,396,402,404,405,407,409,413,415,417,419,420,422,426,432,433,437,438,440,442,452,454,456,461,462,464,468,469,471,475,476,478,480,482,483,485,488,489,493,511,513,517,518,521,523,527,539,540,542,547,549,559,564,565,566,567,569,575,576,582,583,585,588,596,602,618,619,627,628,629,631,633,636,641,642,644,645,647,651,652,654,656,658,659,661,663,664,666,668,669,672,674,677,678,685,691,695,696,698,699,704,708,709,711,714,715,716,718,720,721,723,727,728,730 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/FBSDKLoginTooltipView.h:18,20,22,24,26,28,30,32,35,36,40,44,48,51,55,57,60,66,68,71,75,76,80,84,88,92,96,97,99,101 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/FBSDKTooltipView.m:18,20,22,24,26,32,37,46,49,51,53,74,75,77,94,99,102,111,113,114,116,118,119,121,123,127,128,129,131,135,136,137,139,141,145,146,151,158,159,161,162,164,168,173,175,181,183,184,186,189,191,197,198,200,202,204,205,207,218,228,229,231,232,235,237,245,251,256,261,262,267,275,281,286,300,301,303,309,313,315,316,318,320,324,325,328,329,331,333,340,348,349,351,354,359,367,368,370,372,380,388,394,396,397,399,423,472,474,499,500,502,504,506,510,511,515,521,527,529,533,541,546,561,562,564,573,574,581,582,584,586,588,594,595,598,601,611,612,614,619,620,622,624,626,634,635,636,637,639,646,647,648,650,653,654,656 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKit/FBSDKLoginManagerLoginResult.h:18,20,22,24,33,35,41,43,45,48,54,57,62,67,72,75,79,82,86,102,104 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKitTests/FBSDKLoginManagerTests.m:18,22,25,41,43,48,50,52,54,56,58,60,62,66,68,70,72,74,76,79,81,83,88,91,92,94,97,98,100,102,104,106,113,115,118,119,121,123,126,131,134,138,142,146,170,176,177,179,181,184,187,190,193,196,199,200,202,205,213,223,227,229,231,237,238,241,250,251,254,258,271,273,274,276,280,290,292,293,296,318,320,323,325,327,329,330,333,355,357,360,362,364,366,367,369,380,382,384,385,387,390,397,399,401,402,404,408,410,412,413,415,419,424,438,442,446,448,452,454,456,458,459,461,465,473,476,477,479,483,488,492,495,499,501,510,513,515,517,519,520,522,524,527,529,531,532,534,536,542,543,545,547,550,553,556,557,559,561,563,571,580,581,583,586,589,590,592,597,600,603,605,606,608,611,621,626,628,629,631,638,643,646,647,649,651,657,659,668,669,671,678,680,689,690,692,700,702,705,706,708,716,718,727,728,730,738,740,749,750,752,754,756,761,762,764,766,775,777,779,781,782,784,793,795,797,799,800,802,804,806,810,811,813,815,817,820,823,824,826,828,830,840,841,843,847,852,857,858,860,863,868,870,871,874,876,879,880,882,885,888,889,891,894,897,898,900,904,908,909,911,913,916,917,919,922,926,927,929,931,936,938,956,957,959,964,971,974,976,977,979,984,991,994,996,997,999,1004,1011,1014,1016,1017,1019,1021,1024,1025,1027,1030,1031,1033,1036,1037,1039,1041,1051,1052,1054,1062,1066,1070,1073,1074,1077,1081,1082,1084,1122,1123,1125,1127,1128,1130,1138,1139,1141,1143,1144 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKitTests/LoginButtonTests.swift:18,22,24,26,31,32,35,39,41,42,45,46,49,54,55,58,64,65,71,72,75,80,81,83,88,90,101,102,116,118,129,130,135,137,152,153,155,158,163,164,167,172,173,175,183,185,191,192,200,202,208,209,217,219,225,226,234,236,242,243,245,248,255,256,259,266,267,273,284,285,291,302,303,307,309,315,316,320,323,329,330,333,339,341,343,349,350,352,355,356,359,365,366,369,374,375,377,384,385,388,394,395,398,405,406,409,416,417,425,426,427,432,435,437,438,441,443,444,447,448 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKitTests/FBSDKReferralManagerTests.m:18,21,23,33,36,38,40,42,44,46,48,50,51,53,55,57,61,62,64,69,70,72,77,78,80,82,84,94,98,99,101,103,105,108,109,111,115,128,130,133,137,138,140,143,153,155,158,162,163,165,168,178,180,184,188,189,191,194,202,204,209,210,212,215,224,226,229,233,234,236,240,250,252,255,259,260,262,266,277,279,282,286,287,289,293,306,308,311,315,316 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKitTests/FBSDKAuthenticationTokenHeaderTests.m:18,20,22,24,26,30,32,34,36,38,41,42,44,46,50,56,57,59,61,64,67,68,70,73,75,76,78,82,86,89,90,92,96,98,99,101,106,108,109,110,112,114,120,123,125,126,128,133,134 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKitTests/FBSDKAuthenticationTokenFactoryTests.m:18,20,22,24,26,33,35,37,47,49,51,53,55,57,59,65,67,69,70,72,74,77,78,80,85,98,104,107,108,110,115,128,134,141,142,144,149,162,168,175,176,178,183,196,202,209,210,212,217,230,241,243,244,246,251,257,281,282,283,285,290,307,308,309,311,313,318,319,321,326,328,329,331,333,334,336,340,342,343,345,347,348,350,352,353 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKitTests/ProfileFactoryTests.swift:18,22,24,44,79,80 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKitTests/FBSDKLoginManagerLoggerTests.m:18,21,24,32,35,37,41,42,44,51,52,54,60,61,63,68,69,71,76,77,79,84,85,87,92,93,95,100,101,103,108,109,111,117,118,120,123,129,130,132,138,139,141,147,148,150,153,159,160,162,168,169,171,180,183,191,192,194,196,197 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKitTests/FBSDKLoginCompletionTests.m:18,21,24,32,35,37,39,41,43,45,47,49,51,72,74,76,79,81,83,85,86,88,90,92,94,96,98,100,119,122,123,125,127,129,130,132,134,141,142,144,147,153,154,156,160,162,163,165,168,170,171,173,176,178,179,181,184,186,187,189,192,194,195,197,200,202,203,205,207,209,210,212,216,218,219,221,224,226,227,229,233,234,235,237,239,241,244,246,247,249,252,263,267,268,270,275,277,320,321,323,325,336,340,341,343,346,361,365,366,368,379,382,403,404,406,408,414,420,422,429,430,431,433,438,440,444,445,447,449,454,456,469,470,472,475,482,485,487,488,490,493,501,504,506,507,509,511,517,519,524,525,527,529,534,536,541,542,544,546,646,647,649,651,653,654,656,660,661,663,667,668,670,674,675,677,681,682,684,688,689,691,698,699,701,705,706,708,719,722,725,728,729,731,744,745,748,754,755 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKitTests/LoginConfigurationTests.swift:18,22,24,26,30,31,55,56,65,66,72,73,86,87,88,92,98,99,108,109,118,119,128,129,137,138,142,143,150,151 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKitTests/NonceTests.swift:18,20,22,32,33,34,45,46,47 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKitTests/FBSDKDeviceLoginManagerResultTests.swift:18,22,24,28,32,33,36,40,41 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKitTests/FBSDKLoginKitTests-Bridging-Header.h:18,20,22,40,42,44,46,48,59,61,63,66,68,70,73,75,77,80,82,84,86,89,91 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKitTests/FBSDKPermissionTests.m:18,20,26,28,30,32,34,43,47,48,49,51,57,61,62,63,65,70,74,75,77,79,86,87,89,91,94,95 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKitTests/Helpers/Fuzzer.swift:18,20,23,51,72,76,77,85,88,91,92,93,96,104,105,106,108,109,114,118,122,123,126,127,128,129,131,132 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKitTests/Helpers/TestAuthenticationTokenFactory.swift:18,20,26,36,37 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKitTests/Helpers/TestProfileFactory.swift:18,21,24,42,45,46,81,83,84 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKitTests/Helpers/FakeGraphRequestConnectionProvider.swift:18,20,24,27,28,31,32,34,37,38 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKitTests/FBSDKDeviceLoginCodeInfoTests.m:19,21,27,37,39,45,47,49,51,53,55,59,60,62,69,70,72,77,78,80,91,92 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKLoginKit/FBSDKLoginKitTests/FBSDKReferralCodeTests.m:18,20,26,30,35,37,39,41,43,45,48,49,51,56,57,59,61,62,64,67,68,70,74,75 ./Carthage/Checkouts/facebook-ios-sdk/Package.swift:3,21,23,25,33,36,39,49,57,65,81,129,144,148,158,178,191,207,219,240 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit_Basics/FBSDKCoreKit_BasicsTests/FBSDKBasicUtilityTests.m:19,21,24,26,28,42,43,45,50,55,59,60,62,74,80,81,83,89,90,92,98,99 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit_Basics/FBSDKCoreKit_BasicsTests/FBSDKSafeCastTests.m:18,20,22,25,28,31,34,37,40,43,45,47,53,59,60,62,69,76,77,79,85,91,92,94,100,106,107,109,112,114,115 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit_Basics/FBSDKCoreKit_BasicsTests/UrlSessionTaskTests.swift:18,22,24,28,31,37,38,41,47,48,51,57,58,66,67 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit_Basics/FBSDKCoreKit_BasicsTests/FBSDKTypeUtilityTests.m:18,20,22,24,26,28,30,32,35,36,38,40,47,53,54,56,59,60,61,63,66,67,68,70,74,75,76,78,85,86,87,89,96,97,98,100,103,109,110,111,113,121,127,128,129,131,133,138,139,141,143,148,149,151,153,159,160,162,164,170,171,173,176,182,183,185,189,195,196,198,202,208,209,211,214,216,217 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit_Basics/FBSDKCoreKit_BasicsTests/FBSDKLibAnalyzerTests.m:18,20,22,24,28,30,33,35,37,39,41,42,44,52,53,55,59,63,64 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit_Basics/FBSDKCoreKit_BasicsTests/FBSDKCoreKit_BasicsTests-Bridging-Header.h:18 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit_Basics/FBSDKCoreKit_BasicsTests/Helpers/SampleUrls.swift:18,20,25,28,29,34,35,36,38,42 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKCoreKit_Basics/FBSDKCoreKit_BasicsTests/Helpers/Fuzzer.swift:18,20,23,51,72,75,76,83,86,89,90,91,94,102,103,104,106,107,112,116,120,121,124,125,126,127,129,130 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit/Exports.swift:18 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FacebookCore/Imports.swift:18 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FacebookCore/Exports.swift:18,25 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FacebookCore/Swift/Permission.swift:18,20,111,116,117,119,120,124,125,128,129,131,132,171,172,173,174,211,249,250,251 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FacebookCore/Swift/AccessToken.swift:18,22,24,34,35,41,42,48,49,56,57 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKLibAnalyzer.m:18,20,22,24,26,28,30,32,33,36,43,44,47,48,49,52,55,59,63,68,71,77,81,85,86,88,90,91,93,96,111,112,113,115,116,118,119,122,133,134,137,138,141,142,145,148,150,153,156,163,167,168,169,170,172,173,175,181,182,183,185,186,189,193,196,199,200,203,206,209,212,213,216,217,220,221,229,230 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKCrashHandler.m:18,20,22,24,31,37,41,48,51,53,60,62,64,66,71,72,76,83,87,91,93,94,96,103,104,106,108,110,111,113,115,116,118,122,123,125,127,128,130,133,146,147,148,149,151,153,154,156,162,163,164,165,166,168,170,171,173,175,180,181,182,183,185,187,189,190,192,194,198,199,200,202,204,205,207,210,211,213,217,218,219,221,223,225,226,228,235,236,237,239,241,242,244,249,251,257,267,268,270,271,273,275,276,278,284,289,295,296,298,299,301,303,304,306,308,309,311,313,314,316,318,322,323,324,326,327,329,331,332,334,337,340,344,348,350,352,355,356,358,360,361,363,368,369,370,371,374,376,377,380,386,387,389,390,393,395,396,399,404,405,407,408,410,412,414,415,417,420,428,429,430,432,434,435,437,440,441,443,445,446,448,451,452,454,456,457,459,462,463,465,467,468,470,478,479,482,483 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKJSONValue.m:18,20,22,26,30,32,36,37,40,45,46,47,49,50,52,56,57,60,66,68,72,73,74,76,77,79,81,85,87,89,90,93,98,99,100,102,108,109,111,113,114,116,122,123,125,130,132,133,135,137,139,143,144,153,154,157,158,160,161,167,178,179,180,182,188,189,191,197,198,200,206,207,209,215,216,218,224,225,227,229,232 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKBasicUtility.m:18,20,23,25,27,30,32,38,39,40,41,43,46,47,48,50,52,54,56,60,70,71,73,74,78,80,81,86,89,93,96,97,101,115,125,126,130,133,135,136,138,143,145,147,148,152,168,173,174,178,181,182,183,186,188,189,191,196,198,199,203,211,212,214,216,219,223,224,228,235,236,241,242,244,245,247,254,255,257,260,263,264,268,270,274,277,280,291,295,297,299,301,302,304,313,315,317,318,320,327,328,330,335,336,338,341,346,347,349,351,356,357,360,361,367,368,370,371 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/include/FBSDKTypeUtility.h:18,20,22,25,28,31,38,45,54,57,60,63,73,76,79,82,85,88,91,94,97,100,103,108,111,120,123,134,135,137 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/include/FBSDKFileManaging.h:18,20,22,26,32,37,39,42,45,47,50 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/include/FBSDKInfoDictionaryProviding.h:18,20,22,25,27,29,31 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/include/NSBundle+InfoDictionaryProviding.h:18,20,22,24,28 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/include/FBSDKURLSessionTask.h:18,20,22,27,30,37,39,43,46 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/include/FBSDKFileDataExtracting.h:18,20,22,26,30,32,35 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/include/FBSDKBase64.h:18,20,23,30,37,44,51,58 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/include/FBSDKCrashHandlerProtocol.h:18,20,23,25 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/include/FBSDKUserDataStore.h:18,20,22,25,28,31,34,37,40,43,46,49,52,55,58,61,65,67,92,97,102,106,108,114,119,121 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/include/FBSDKSafeCast.h:18,20,29,32,36,45,48 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/include/FBSDKCrashHandler.h:18,20,22,24,27,29,36,38 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/include/FBSDKLibAnalyzer.h:18,20,22,24,29,31 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/include/FBSDKCrashHandler+CrashHandlerProtocol.h:18,20,22,26 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/include/FBSDKBasicUtility.h:18,20,22,28,34,39,43,45,56,69,78,89,96,103,110,117,124,128,130 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/include/FBSDKJSONValue.h:18,20,27,33,43,49,55,57,62,68,71,77,80,85,90,96,99,101,104,107,111 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/include/FBSDKURLSession.h:18,20,22,24,26,30,33,36,38,40,42,44 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/include/FBSDKCoreKit_Basics.h:18,35 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/include/FBSDKCrashObserving.h:18,20,22,25,28,30,32 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/include/FBSDKSessionProviding.h:18,20,22,26,28,31,33,37,40,42 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKURLSession.m:18,20,22,25,30,32,35,39,41,42,45,54,55,56,58,63,65,66,68,71,72,74,76,77 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKTypeUtility.m:18,20,22,24,26,28,29,31,34,35,37,38,40,43,44,45,47,53,54,55,56,58,67,68,69,71,73,74,76,78,83,84,85,87,90,91,92,94,98,99,100,102,104,105,107,114,115,116,118,120,121,123,125,126,128,137,138,139,141,148,149,150,152,161,163,164,165,167,174,175,176,178,180,181,183,185,190,192,193,195,198,199,205,207,208,210,212,214,215 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKURLSessionTask.m:18,20,22,24,26,29,31,32,36,40,42,43,45,47,48,50,52,54,55,57,60,61 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKSafeCast.m:18,20,22,24,25,27,29 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKUserDataStore.m:18,20,23,26,30,32,36,48,50,52,57,58,70,74,77,80,83,86,89,92,95,98,101,104,105,111,112,115,118,119,122,128,132,133,136,142,146,147,149,152,153,154,156,158,159,161,163,164,166,174,175,179,180,182,194,195,197,203,204,206,208,215,218,220,221,223,233,234,235,238,241,243,244,247,271,273,274,276,279,280 ./Carthage/Checkouts/facebook-ios-sdk/Sources/FBSDKCoreKit_Basics/FBSDKBase64.m:18,20,22,25,27,29,33,34,35,37,39,40,42,44,45,47,49,50,52,54,55,57,60,62,63,65,67,69,72,79,80,82,83,85,89,91,92,94,97,98,100,101,103,105,106 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKitTests/FBSDKShareKitTestUtility.h:18,20,22,27,32,37 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKitTests/Internal/FBSDKShareUtilityTests.m:18,21,27,30,33,35,37,43,44,46,56,57,59,65,66 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKitTests/FakeSharingDelegate.m:18,20,22,24,26,27,29,31,32,34,36,37 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKitTests/Models/FBSDKHashtagTests.m:18,20,22,24,26,28,30,33,34,36,43,44,46,52,53,55,64,65 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKitTests/Models/FBSDKShareMediaContentTests.m:18,20,23,25,27,29,31,34,35,37,41,42,44,53,54 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKitTests/Models/FBSDKAppInviteContentTests.m:18,20,26,28,31,33,35,39,40,42,45,46,48,56,57,59,66,67,69,79,80,82,90,91,93,101,102,104,115,116,118,127,128,130,141,142,144,156,157,159,161,166,167,169,171,172,174,176,177 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKitTests/Models/FBSDKGameRequestContentTests.m:18,20,26,29,32,34,36,46,47,49,52,53,55,63,64,66,68,69,71,73,74,76,79,80,82,86,87,89,93,94,96,101,102,104,108,109,111,116,117,119,123,124,126,131,132,134,138,139,141,145,146,148,153,154,156,161,162,164,169,170,172,178,179,181,185,186,188,190,196,197,199,206,207,209,213,214,216,227,228,230,236,237,239,241,242,244,246,247,249,251,252,254,256,257,259,261,262,264,266,267,269,271,272,274,276,277 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKitTests/Models/FBSDKCameraEffectArgumentsTests.m:18,21,27,31,34,36,38,41,42,44,53,54,56,58,70,73,74 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKitTests/Models/FBSDKShareModelTestUtility.m:18,20,22,24,26,28,29,31,33,34,36,38,39,41,45,46,48,56,57,59,61,62,64,66,67,69,71,72,74,76,77,79,88,89,91,100,101,103,112,113,115,123,124,126,128,129,131,133,134,136,138,139,141,143,144,146,148,149,151,160,161,163,167,168,170,182,183,185,187,188,190,192,193,195,197,198,200,202,203,205,207,208,210,212,213,215,224,225,227,236,237,239,241,242,244,246,247,249,253,254,256,260,261,263,265,266,268,273,274,276,281,282,284,286,302,303 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKitTests/Models/FBSDKSharePhotoTests.m:18,21,27,31,34,36,38,43,44,46,51,52,54,57,58,60,63,64,66,77,78,80,89,90,92,100,101 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKitTests/Models/FBSDKShareLinkContentTests.m:18,20,26,28,32,35,37,39,47,48,50,53,54,56,64,65,67,75,76,78,86,87,89,96,97 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKitTests/Models/FBSDKSharePhotoContentTests.m:18,21,27,31,34,36,38,45,46,48,51,52,54,62,63,65,72,73,75,87,88,90,98,99,101,110,111 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKitTests/Models/FBSDKShareModelTestUtility.h:18,20,30,32,67 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKitTests/Models/FBSDKShareVideoContentTests.m:18,21,27,31,34,36,38,46,47,49,52,53,55,63,64,66,77,78,80,88,89,91,104,105,107,121,122,124,138,139,141,150,151,153,168,169,171,181,182 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKitTests/Models/FBSDKShareVideoTests.m:18,21,27,31,34,36,38,42,43,45,48,49,51,60,61 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKitTests/FBSDKShareDialogTests.m:18,23,31,38,41,43,45,56,57,58,60,69,70,71,73,75,86,87,89,99,100,102,112,113,115,125,126,128,140,141,143,154,155,157,164,165,167,169,185,186,188,190,208,215,216,218,237,238,240,242,266,267,269,276,287,297,307,328,329,331,333,355,356,358,371,372,374,376,398,399,401,414,415,417,423,429,430,432,434,437,449,474,484,485,487,494,495,497,504,505,507,509,515,516,518,524,525,527,533,534,536,542,543,545,551,552,554,560,570,583,585,589,590,595,615,619,625,630,631,636,646,658,662,667,668,670,681,682,684,686,687,690,693,698,699 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKitTests/FBSDKShareKitTestUtility.m:18,20,23,25,28,30,32,37,39,40,42,46,47,49,53,54 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKitTests/FakeSharingDelegate.h:18,20,22,24,26,30,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKitTests/FBSDKMessageDialogTests.m:18,21,27,29,35,38,40,42,49,50,51,53,73,74,76,88,99,110,121,122,124,129,131,148,149,151,156,158,175,176,178,185,187,204,205 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKLikeObjectType.m:18,20,22,30,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKSharingButton.h:18,20,22,24,26,28,31,33,38,43,45,47 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKSendButton.h:18,20,22,24,26,29,31,34,40,42,44 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKShareLinkContent.m:18,20,26,30,39,41,43,52,54,56,60,62,63,65,67,71,72,73,75,78,80,83,89,91,92,94,96,98,99,101,103,115,116,118,121,124,126,127,129,139,140,142,144,146,147,149,159,161,162,164,173,174,176,178,189,190 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKShareKit.h:18,30 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKGameRequestDialog.h:18,20,22,24,26,28,30,36,40,49,58,63,68,73,76,80,85,91,98,100,103,110,117,124,130,132,134 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKShareVideo.h:18,21,26,29,35,41,48,54,61,67,74,80,86,92,98,105,107,109,111,113 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKShareMediaContent.h:18,20,22,24,30,32,38,44,51,53 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKShareDialogMode.h:18,20,22,26,31,61,67 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKSharePhotoContent.m:18,20,22,28,33,42,44,46,54,56,58,62,64,65,67,69,73,74,75,77,81,82,83,85,88,90,107,115,116,120,121,126,127,129,130,132,134,137,141,142,144,145,147,149,161,162,164,167,170,172,173,175,185,186,188,190,192,193,195,206,208,209,211,220,221,223,225,236,237 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKAppGroupContent.h:18,20,22,24,27,29,31,33,39,45,51,57,62,67,72,79,81,83 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKCameraEffectArguments.m:18,20,22,24,30,33,35,37,39,40,42,44,47,49,50,52,54,55,57,59,60,62,64,65,67,69,70,72,74,75,77,79,81,82,84,87,90,92,93,95,97,98,100,102,104,105,107,111,113,114,116,118,119,121,123,127,128,130,132,139,140,141,143,146,147,149,152,153,155,158,161,162,164,174,175,178,179,183,184,185,187 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKAppInviteContent.h:18,20,22,24,26,28,30,36,42,48,51,52,56,59,60,64,67,68,73,76,77,82,85,86,90,97,99,101 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKShareConstants.m:18,20,22,24,26,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKShareButton.m:18,20,22,24,31,34,36,38,39,41,43,45,46,48,51,52,54,56,58,59,61,63,64,66,68,69,71,73,82,87,90,91,93,95,96,98,100,103,104,106 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/include/FBSDKCoreKitImport.h:18,23 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKShareDialog.h:18,20,22,31,35,37,39,43,45,51,62,73,76,80,83,87,89,91 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKSharing.h:18,20,22,24,26,29,31,36,41,46,49,54,61,63,69,72,76,81,87,89,92,99,106,113,119,121 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKLiking.h:18,20,22,24,26,28,31,33,38,41,42,47,50,51,57,59,61 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKShareVideoContent.h:18,20,24,26,32,38,45,47 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKSharePhoto.h:18,20,24,26,28,34,42,48,54,62,68,74,80,86,93,100,101,103 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/Internal/FBSDKGameRequestFrictionlessRecipientCache.h:18,20,22,24,27,30,32 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/Internal/FBSDKLikeButton+Internal.h:18,20,22,24,26,29,31,33,35 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/Internal/FBSDKLikeBoxView.m:18,20,22,24,31,33,36,37,39,41,44,46,47,49,52,54,55,57,59,65,66,67,69,71,72,74,79,80,81,83,85,87,88,90,92,95,96,98,100,101,103,105,108,117,118,120 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/Internal/FBSDKShareUtility.h:18,20,26,32,35,38,62,77 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/Internal/FBSDKLikeDialog.m:18,20,22,24,30,34,36,41,43,45,48,49,50,54,61,62,64,66,68,69,71,79,83,84,99,117,128,129,131,132,134,140,142,145,147,148,150,152,156,157,159,162,168,169,170,172 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/Internal/FBSDKLikeBoxBorderView.h:18,20,22,24,26,29,37,39 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/Internal/FBSDKLikeActionController.m:18,20,22,24,26,32,38,42,49,55,59,61,63,64,66,70,71,73,81,82,83,85,89,91,95,97,99,103,106,117,119,124,130,139,141,144,146,162,163,165,167,169,171,172,174,176,194,197,198,199,202,212,213,214,216,220,223,224,226,230,240,241,242,244,251,252,254,257,266,269,270,271,273,277,282,284,286,287,289,291,292,294,296,298,299,301,304,305,309,310,314,327,329,331,332,334,346,347,349,351,353,354,356,358,359,361,363,365,366,368,370,374,375,377,379,380,382,385,386,387,389,391,392,394,396,402,417,419,420,422,426,429,434,440,442,443,445,447,454,456,457,463,477,478,489,492,522,531,532,540,543,551,555,562,563,568,571,577,586,587,596,599,605,609,629,630,631,634,635,642,661,664,666,667,674,689,692,694,695,701,704,711,724,732,733,742,754,756,765,766,768,771,783,785,786,797,799,802,805,806,810,824,825,826,830,837,838,839,840,844,870,874,885,886,890,914,918,928,929,931,937,939,944,946,947,948,952,953,956,985,986,988,994,1006,1007,1008,1017,1020,1021,1024,1028,1037,1038,1042,1043,1046,1049,1052,1055,1058,1059,1066,1069,1077,1078,1079,1081,1086,1087,1089 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/Internal/FBSDKCheckmarkIcon.h:18,20,22,24,30,33,35 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/Internal/FBSDKMessengerIcon.m:18,20,22,24,26,28,52,53,55 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/Internal/FBSDKCameraEffectArguments+Internal.h:18,20,22,24,26,28,30 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/Internal/FBSDKShareAppEventNames.h:18,20 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/Internal/FBSDKCoreKitInternalImport.h:18 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/Internal/FBSDKLikeActionControllerCache.h:18,20,22,24,27,31,33,37,39 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/Internal/FBSDKShareKit+Internal.h:18,20 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/Internal/FBSDKShareExtension.m:18,20,22,24,29,33,35,40,44,46,47,51,52,54,55 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/Internal/FBSDKLikeBoxBorderView.m:18,20,22,24,30,35,37,39,41,44,46,47,49,52,54,55,57,59,63,64,65,67,71,72,73,75,80,81,82,84,90,91,92,94,102,103,105,112,113,114,116,120,121,122,124,128,129,130,132,134,136,137,139,141,143,144,146,152,153,155,157,160,166,171,172,178,181,206,209,305,306,310,312,313,315,320,322,323,325,330,336,340,344,348,349,350,352,353,355,366,367,369 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/Internal/FBSDKLikeDialog.h:18,20,22,24,26,28,31,35,41,45,47,50,53,55 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/Internal/FBSDKShareUtility.m:18,20,22,28,32,34,36,38,45,46,54,55,56,57,59,68,69,70,71,76,85,86,87,92,95,98,101,103,104,106,112,113,117,118,119,122,139,141,144,145,147,158,160,161,163,166,174,175,176,180,194,195,199,201,212,213,218,220,225,226,228,229,234,256,257,260,263,266,267,268,272,283,285,286,287,289,294,295,297,299,306,308,310,311,313,316,320,323,324,327,344,346,347,348,353,355,356,358,379,380,381,384,387,390,391,392,398,410,415,417,418,419,421,425,427,434,436,449,451,454,456,457,459,463,471,473,474,475,477,486,488,491,493,494,499,504,506,507,513,515,516,518,522,530,532,533,534 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/Internal/FBSDKLikeBoxView.h:18,20,22,24,27,31,41,44,47,49 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/Internal/FBSDKGameRequestFrictionlessRecipientCache.m:18,20,22,24,30,36,38,40,42,43,45,47,54,56,57,59,61,62,64,66,69,73,80,81,82,84,87,88,89,91,93,96,99,100,102,106,116,118,119,121 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/Internal/FBSDKShareAppEventNames.m:18,20,28 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/Internal/FBSDKMessengerIcon.h:18,20,22,24,30,33,35 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/Internal/FBSDKCheckmarkIcon.m:18,20,22,24,26,28,45,46,48 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/Internal/FBSDKShareDefines.h:18,20 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/Internal/FBSDKLikeActionController.h:18,20,22,24,26,28,32,34,38,40,42,45,47,50,57,59,61 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/Internal/FBSDKLikeActionControllerCache.m:18,20,22,24,26,30,33,36,38,41,42,44,46,50,52,53,55,57,59,60,62,71,73,74,76,79,80,82,84,86,87,89,92,93,95,97,98,100,102,111,114,115,117 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/Internal/FBSDKCoreKitBasicsImportForShareKit.h:18,20 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/Internal/FBSDKCameraEffectTextures+Internal.h:18,20,22,24,26,28,30 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/Internal/FBSDKShareExtension.h:18,20,22,24,26,31,35,37 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKSharingContent.h:18,20,23,25,27,33,36,42,48,56,62,68,74,80,91,93 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKMessageDialog.h:18,20,22,24,27,29,32,35,47,56,65,67,69 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKCameraEffectTextures.h:18,20,22,24,26,28,35,43,50,52,54 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKHashtag.m:18,20,26,28,30,37,38,40,42,44,48,49,51,53,58,59,60,62,65,72,73,75,77,79,80,82,85,88,90,91,93,96,97,99,101,103,104,106,109,111,112,114,116,117,119,121,125,126 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKGameRequestURLProvider.h:18,22,24,31,43,49,59 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKGameRequestContent.m:18,20,22,24,32,41,43,45,47,51,52,53,55,59,60,61,63,65,66,68,70,71,73,75,76,78,80,81,83,85,88,98,100,111,113,121,123,124,132,134,135,143,145,146,149,150,166,167,169,171,183,184,186,189,192,194,195,197,207,208,210,212,214,215,217,227,229,230,232,241,242,244,246,257,258,260 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKCoreKitImport.h:18,23 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKShareCameraEffectContent.h:18,20,22,24,29,31,37,42,47,52,59,61,63 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKShareLinkContent.h:18,20,22,24,30,33,38,45,47 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKSendButton.m:18,20,22,24,32,35,38,40,42,43,45,47,49,50,52,55,56,58,60,62,63,65,67,68,70,72,73,75,77,86,89,94,97,98,100,102,103,105,107,110,111,113 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKLikeObjectType.h:18,20,22,28,36,42 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/Swift/Enums+Extensions.swift:18,27,28,29,38,39,40,49,50 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/Swift/Exports.swift:18 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKAppInviteContent.m:18,20,22,24,31,37,39,41,43,44,46,48,49,51,53,58,59,61,65,70,72,73,77,79,80,84,86,87,91,93,94,95,98,99,101,102,104,106,114,115,117,120,123,125,126,128,136,137,139,141,143,144,146,156,158,159,161,167,168,170,172,180,181,183 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKCameraEffectArguments.h:18,20,22,24,26,28,35,43,50,58,65,67,69 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKAppGroupContent.m:18,20,22,24,26,28,29,31,38,42,44,48,51,52,53,54,56,58,60,67,68,70,73,76,78,79,81,86,87,89,91,93,94,96,102,104,105,107,111,112,114,116,122,123,125 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKSharePhotoContent.h:18,20,22,24,26,32,38,45,47 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKShareMediaContent.m:18,20,31,40,42,44,52,54,56,60,62,63,65,67,71,72,73,75,79,80,81,83,86,89,90,92,94,97,108,110,119,120,125,128,135,137,138,140,141,143,145,157,158,160,163,166,168,169,171,181,182,184,186,188,189,191,202,204,205,207,216,217,219,221,232,233 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKShareDialogMode.m:18,20,29,31,35,38,41,44,47,50,53,56,57,58 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKShareVideo.m:18,20,29,34,36,38,40,44,45,47,52,53,55,59,60,62,67,68,70,74,75,77,82,83,85,87,92,93,95,100,101,103,108,109,111,113,121,122,124,127,130,132,133,135,141,142,144,148,152,153,159,161,162,166,173,180,182,183,185,186,190,197,198,199,205,207,208,210,225,227,228,229,231,233,235,236,238,244,247,249,250,252,257,258,260,262,269,270,272,274,276,303,304 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKGameRequestDialog.m:18,20,22,24,30,36,39,42,44,48,49,51,53,55,58,59,60,62,67,68,70,77,79,80,82,86,91,92,100,102,103,105,112,116,117,118,120,125,127,128,134,141,144,145,147,148,153,157,158,160,163,164,165,167,169,170,172,179,180,181,183,185,189,190,192,198,199,204,207,208,210,211,213,215,219,221,222,224,226,228,229,231,239,240,244,245,247,250,251,253,262,266,267,268,270,273,274,276,279,282,288,290,291,293,301,305,306,308,316,320,321,323,325,328,329,331,332,334,337,338,340,341,343,346,347,349,350,352,354,361,362,371,373,382,384,385,387,391,392,396,397,399,400,402,404,410,411,414,416,429,430,435,436,439,440,442,446,447,449,453,454,456,458,461,462,464,467,472,476,480,481,485,486,488 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKShareVideoContent.m:18,20,22,28,32,42,44,46,54,56,58,62,64,65,67,69,73,74,75,77,80,82,95,102,116,117,118,119,124,125,129,131,132,134,136,139,141,142,144,146,158,159,161,164,167,169,170,172,182,183,185,187,189,190,192,202,204,205,207,216,217,219,221,232,233 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKSharePhoto.m:18,20,22,29,35,37,39,41,46,47,49,54,55,57,62,63,65,67,71,72,74,78,79,81,85,86,88,90,99,100,102,105,108,110,111,113,120,121,123,125,134,138,145,147,154,161,163,173,175,184,186,187,188,190,192,194,195,197,204,207,209,210,212,218,219,221,223,231,232 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKShareDialog.m:18,20,22,24,26,32,46,55,58,60,65,66,68,73,74,77,79,82,83,85,87,91,92,93,97,103,104,108,114,115,117,119,124,126,127,128,130,134,136,138,152,155,158,159,160,161,162,164,168,174,178,182,186,190,194,198,199,200,206,208,209,211,213,214,216,218,221,231,238,240,241,243,246,250,251,253,256,260,261,263,265,268,271,272,274,285,286,288,291,294,295,299,300,316,317,320,323,324,325,327,329,330,332,335,336,340,346,348,349,351,360,361,363,369,370,372,374,375,377,379,380,382,389,390,392,394,395,397,408,409,410,411,413,414,416,426,430,431,432,435,437,438,440,447,454,455,456,457,459,460,462,471,473,474,478,494,495,496,497,499,503,504,506,507,509,512,532,534,545,561,563,564,566,569,588,589,591,594,601,602,604,610,612,615,619,622,642,643,657,665,666,668,674,676,679,686,688,692,697,703,705,706,710,711,714,717,720,726,730,731,738,739,741,744,753,758,759,761,764,767,768,770,773,776,777,779,782,783,796,798,799,800,805,806,814,817,820,823,826,830,831,837,839,840,845,850,854,866,868,869,871,872,874,885,887,888,895,897,909,911,915,922,924,925,933,935,939,940,941,949,951,952,954,955,957,968,970,977,979,981,982,984,993,995,996,999,1002,1003,1005,1018,1020,1038,1040,1041,1043,1044,1046,1055,1057,1059,1060,1062,1066,1071,1073,1074,1076,1080,1085,1087,1088,1090,1095,1100,1102,1103,1105,1107,1119,1120,1125,1130,1131,1133,1141,1144,1149,1150,1151,1156,1157,1162,1163,1165,1166,1168 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKSharingScheme.h:18,20,22,24,26,32,39,41,43 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKShareButton.h:18,20,22,24,26,28,30,33,39,41,43 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKShareConstants.h:18,20,22,24,27,32,34,37,42,44,50,56,61,66,69,73,79 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKShareCameraEffectContent.m:18,20,22,24,30,36,47,49,51,62,64,66,70,72,73,75,78,83,89,93,105,112,116,118,119,121,123,128,129,131,132,134,136,144,146,147,148,150,151,153,155,169,170,172,175,178,180,181,183,195,196,198,200,202,203,205,217,219,220,222,233,234,236,238,251,252,254 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKGameRequestURLProvider.m:18,20,26,28,32,34,36,40,42,43,45,52,53,55,59,62,65,70,72,75,76,77,78,80,84,87,90,93,96,99,100,101,102 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKGameRequestContent.h:18,20,22,24,26,29,31,37,40,43,47,54,60,66,70,76,79,83,86,89,93,97,101,106,111,113,115 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKHashtag.h:18,20,22,24,30,38,41,48,51,57,64,66 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKCameraEffectTextures.m:18,20,22,24,30,33,35,37,39,40,42,44,47,49,50,52,54,55,57,59,60,62,64,65,67,69,71,72,74,77,80,82,83,85,87,88,90,92,94,95,97,101,103,104,106,108,109,111,113,117,118,120,122,127,128,129,131,134,135,137,140,141,143 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKMessageDialog.m:18,20,22,24,30,38,40,42,47,49,51,55,56,57,60,65,66,68,72,73,75,79,81,83,85,86,88,96,100,101,126,130,131,133,144,146,147,151,152,154,156,160,161,163,172,173,174,176,180,185,188,189,191,192,194,198,203,206,207,209,210,212,216,221,224,225,227,228,229,231,241,242,246,251,252,254 ./Carthage/Checkouts/facebook-ios-sdk/FBSDKShareKit/FBSDKShareKit/FBSDKSharingValidation.h:18,20,22,27,35,41,48,50 ./Carthage/Checkouts/OCMock/Source/OCMockTests/OCMockObjectPartialMocksTests.m:16,22,29,30,32,38,40,42,44,46,47,49,51,52,54,56,57,59,60,61,62,64,66,69,71,73,75,79,80,82,84,85,87,89,90,92,94,97,98,99,101,102,104,106,107,116,118,120,123,124,126,128,129,130,132,135,136,138,140,141,143,145,146,148,149,150,152,154,155,157,158,160,162,164,166,168,170,171,173,174,176,179,182,184,186,191,193,195,198,201,203,204,206,208,210,212,214,216,221,223,224,226,227,228,230,232,233,235,236,238,240,242,246,247,249,251,256,257,259,263,264,270,272,277,278,280,285,286,288,296,297,299,304,305,306,308,310,313,315,317,318,320,323,325,327,328,330,334,336,338,339,341,345,347,349,350,352,356,358,360,361,362,364,366,376,377,379,381,386,388,390,391,392,394,396,398,401,402,404,410,411,413,415,421,422,424,426,428,429,431,439,440,442,445,448,452,455,456,458,461,466,470,473,474,475,477,479,481,487,489,492,494,497,502,504,507,510,513,516,518,521,523,526,528,531,533,536,538,539,541,543,545,548,550,557,562,564,567,568,570,573,576,579,582,590,594,600,601,602,604,606,607,608,610,612,618,619,621,629,630,632,641,643,644,645,647,649,652,655,657,658,660,663,666,668,669,671,676,677,679,681,682,684,691,692,693,695,697,699,700,702,708,709,710,712,713,714,716,721,722,723,725,727,732,735,737,739,740,741,743,746,749,751,753,754,755,756,758,762,765,766,768,770,771,772,774,779,782,785,786 ./Carthage/Checkouts/OCMock/Source/OCMockTests/OCMStubRecorderTests.m:16,22,23,25,27,28,30,32,34,38,44,45,47,52,55,56,58,63,66,67,68 ./Carthage/Checkouts/OCMock/Source/OCMockTests/OCMockObjectInternalTests.m:16,19,20,22,24,26,28,30,32,34,36,38,39,41,42,43,45,47,49,51,53,56,58,60,62,64,65,66,68,72,74,76,78,80,81,82,84,92,95,97,99,101,104,105,107,108,110,114,116,118,120,122,123,124,126,131,132,133,135,137,140,143,145,146,147,149,151,154,158,162,164,165,166,168,172,175,176,177,179,180,184,186,187,188,190,198,200,201,203,205,208,215,216,217,219,221,223,230,231,232,233 ./Carthage/Checkouts/OCMock/Source/OCMockTests/TestClassWithCustomReferenceCounting.m:16,20,21,23,29,30,32,34,35,37,44,45,47,55,56 ./Carthage/Checkouts/OCMock/Source/OCMockTests/OCMFunctionsTests.m:16,22,26,28,30,31,32,34,35,38,40,42,44,45,47,49,50,52,54,55,57,59,60,62,65,68,72,74,75,77,80,83,87,89,90,91,93,94,95 ./Carthage/Checkouts/OCMock/Source/OCMockTests/OCMockObjectHamcrestTests.m:16,20,21,23,25,26,28,30,34,35,36,38,42,43,44 ./Carthage/Checkouts/OCMock/Source/OCMockTests/OCMBoxedReturnValueProviderTests.m:16,19,20,24,25,27,29,31,33,43,53,56,64,65,66,68,75,81,84,85,86,88,92,95,96,97,99,117,120,121,123,124,125,126 ./Carthage/Checkouts/OCMock/Source/OCMockTests/OCMockObjectVerifyAfterRunTests.m:16,19,20,22,25,27,29,31,33,34,36,38,39,41,43,45,47,49,51,54,55,57,59,61,62,64,66,68,70,72,73,75,77,79,81,82,84,87,89,91,92,94,97,99,102,103,105,107,109,111,112,114,116,118,119,121,123,126,128,131,133,136,137,138,139 ./Carthage/Checkouts/OCMock/Source/OCMockTests/OCMConstraintTests.m:16,19,20,22,24,25,27,28,30,32,34,35,37,42,43,45,47,50,51,53,55,58,59,61,64,68,69,70,72,75,76,78,80,84,85,86,88,91,92,94,96,100,101,102,104,106,107,108,110,113,114,115,117,119,122,124,127,128,130,133,137,139,144,145,147,149,151,152 ./Carthage/Checkouts/OCMock/Source/OCMockTests/NSMethodSignatureOCMAdditionsTests.m:16,19,20,26,28,30,32,34,38,39,41,46,47,49,58,99,100,102,109,110,112,115,118,123,124,126,129,132,141,142,144,148,151,153,154 ./Carthage/Checkouts/OCMock/Source/OCMockTests/OCMockObjectTests.m:16,19,20,22,24,26,28,30,32,33,34,36,37,39,41,43,45,47,49,50,52,55,57,59,61,66,68,70,74,75,77,79,81,83,85,87,89,90,92,94,96,98,100,102,103,105,106,108,110,112,114,116,121,122,124,125,127,130,131,133,135,137,139,140,142,144,145,147,148,155,156,158,160,162,164,166,168,169,171,172,174,177,179,181,183,185,186,188,190,191,193,196,199,201,203,204,206,209,212,213,215,217,218,220,222,223,225,226,227,229,231,233,235,236,238,240,241,243,245,248,249,251,254,255,256,258,261,262,263,265,269,270,272,276,277,278,280,282,285,286,287,289,292,293,295,298,299,300,302,305,306,308,311,312,313,315,319,320,322,326,327,329,333,334,335,337,340,342,343,345,349,351,353,354,356,358,361,362,363,365,368,370,372,373,375,376,378,381,383,384,385,387,390,392,393,395,400,401,402,404,408,409,410,412,416,417,418,420,424,425,426,428,432,433,434,436,441,442,443,445,449,450,452,456,457,459,463,464,466,471,472,473,475,478,479,481,484,485,487,494,495,497,500,501,502,504,506,509,511,512,514,517,519,520,522,527,531,535,539,543,546,551,552,554,558,562,566,569,570,572,574,576,577,579,586,587,589,591,593,595,596,598,600,602,604,605,607,612,614,616,617,619,624,626,628,629,630,631,633,635,638,640,641,643,646,649,651,655,656,658,661,664,667,668,669,671,673,674,676,678,680,682,683,684,686,688,694,696,699,700,702,704,707,708,709,711,713,714,715,717,719,722,725,729,733,734,735,737,740,743,745,746,747,748,750,755,756,757,759,761,762,765,770,776,780,781,783,785,787,788,790,792,794,795,797,799,801,802,804,808,810,811,813,817,819,820,822,824,828,833,836,837,839,841,845,850,853,854,856,863,864,866,869,873,878,881,882,884,888,896,899,900,902,906,910,912,916,917,918,920,922,925,926,927,929,932,934,935,936,938,941,944,945,946,948,951,954,955,956,958,960,963,966,968,969,970,972,975,977,979,980,982,985,988,990,991,992,994,997,1000,1002,1003,1005,1008,1012,1014,1015,1017,1021,1022,1023,1025,1027,1030,1033,1035,1036,1038,1043,1046,1047,1049,1054,1058,1059,1061,1064,1065,1067,1069,1071,1074,1077,1078,1080,1082,1085,1087,1088,1090,1095,1096,1097,1098,1100,1102,1106,1107,1109,1113,1114,1116,1118,1121,1122,1124,1127,1128,1130,1132,1136,1138,1139,1140,1142,1145,1146,1148,1151,1152,1153,1155,1157,1159,1160,1161,1163,1164 ./Carthage/Checkouts/OCMock/Source/OCMockTests/OCMockObjectClassMethodMockingTests.m:16,21,22,24,31,33,35,37,39,40,42,44,45,47,49,50,52,54,55,57,58,59,61,63,64,66,67,69,71,73,75,76,78,80,81,83,85,87,89,91,93,94,96,100,103,104,106,108,111,113,114,116,118,120,123,124,126,128,132,133,135,137,140,142,143,145,148,151,154,155,157,160,163,166,167,169,176,183,189,190,192,194,196,199,200,202,204,206,208,209,211,213,216,219,220,222,224,227,230,232,235,236,238,240,243,246,248,251,252,254,257,260,263,264,266,268,271,275,276,278,282,286,289,292,295,296,298,302,307,312,317,320,323,326,327,329,331,332,334,336,340,342,344,345,347,349,352,354,356,357,359,367,369,370,372,376,377 ./Carthage/Checkouts/OCMock/Source/OCMockTests/OCMNoEscapeBlockTests.m:16,20,21,24,26,28,29,30,32,36,38,40,41,43,46,47,49,51,52,54,58,60,61,62,64,65,68,70,72,83,84,86,96,97 ./Carthage/Checkouts/OCMock/Source/OCMockTests/OCMQuantifierTests.m:16,19,20,22,24,26,28,30,31,32,34,35,37,40,41,43,44,46,48,50,51,53,55,57,59,61,63,64,65,67,69,71,73,75,77,78,79,81,82,84,86,88,90,91,93,95,98,100,101,103,105,109,111,112,113,115,117,119,121,122,124,126,129,131,132,134,136,140,142,143,145,147,148,149,151,153,155,157,158,160,162,165,167,168,170,172,173,174,176,178,180,182,183,184,186,191,192,194,200,201,203 ./Carthage/Checkouts/OCMock/Source/OCMockTests/OCMockObjectProtocolMocksTests.m:16,19,20,24,32,36,38,41,44,50,51,52,54,56,57,59,63,65,68,70,72,73,75,78,79,81,84,85,87,90,91,93,96,97,99,102,103,105,108,109,114,115,120,121,126,127,128,130,134,135,137,141,142,144,149,150,152,154,155,157,165,167,168 ./Carthage/Checkouts/OCMock/Source/OCMockTests/TestClassWithCustomReferenceCounting.h:16,18 ./Carthage/Checkouts/OCMock/Source/OCMockTests/NSInvocationOCMAdditionsTests.m:16,20,21,23,25,27,28,30,32,33,35,37,38,40,42,43,45,46,48,50,51,53,55,60,61,62,64,67,68,70,75,78,79,81,85,88,89,91,97,100,101,103,107,110,111,113,117,120,121,123,127,130,131,133,137,140,141,143,147,150,151,153,157,160,161,163,167,170,171,173,177,180,181,183,187,190,191,193,197,200,201,203,207,210,211,213,217,220,221,223,227,230,231,233,237,240,241,243,247,250,251,253,259,262,263,265,270,273,274,276,280,282,283,285,289,292,293,295,302,308,309,311,317,321,322,323,325,329,332,333,335,337,340,343,346,349,352,355,356,357,358 ./Carthage/Checkouts/OCMock/Source/OCMockTests/OCMockObjectRuntimeTests.m:16,19,20,22,24,26,28,30,32,33,34,36,37,39,41,43,45,47,49,51,53,54,56,58,60,62,64,65,66,68,70,72,74,76,78,81,82,84,85,87,89,91,93,94,97,99,101,103,104,106,108,109,111,112,115,117,119,121,122,124,125,127,129,130,132,133,134,136,141,143,145,146,147,152,153,155,156,157,158,160,162,164,166,168,171,172,173,175,179,180,181,183,186,188,190,191,192,194,197,198,199,201,205,206,207,209,212,213,214,216,218,221,222,224,229,230,231,234,241,246,249,251,253,256,257,259,262,263,265,271,272,273,275,277,285,286,287,289,291,300,301,302,304,306,310,313,315,318,319,320,322,324,327,330,331,332,334,337,338,340,344,345,346,348,350,354,359,361,364,366,369,372,373,375,379,384,386,389,391,394,397,398,403,410,413,414,416,420,427,430,431,433,436,440,442,443,445,448,452,454,455,457,461,462,464,468,469,471,475,479,488,491,492,494,498,502,512,515,516,518,522,532,535,536,537,539,543,555,558,559,561,565,573,576,577,579,583,584,586,590,591,593,597,609,612,613,618,626,629,630,632,636,637,639,643,644,646,650,662,665,666,671,680,683,684,686,690,691,693,697,698,700,704,716,719,720,725,734,737,738,740,744,745,747,751,752,758 ./Carthage/Checkouts/OCMock/Source/OCMockTests/OCObserverMockObjectTests.m:16,19,20,22,23,25,28,29,31,32,34,36,42,43,45,48,50,52,53,55,59,61,63,64,66,70,73,74,76,78,82,85,86,88,90,94,96,97,99,104,107,108,110,112,114,115,117,120,122,123,125,131,132,134,137,139,140,142,146,149,150,152,154,157,159,161,162 ./Carthage/Checkouts/OCMock/Source/OCMockTests/OCMockObjectMacroTests.m:16,19,20,24,26,28,30,32,34,35,37,38,40,42,44,46,49,50,52,54,56,58,60,62,64,65,67,68,69,71,77,78,79,81,86,87,89,90,92,94,96,98,102,104,106,107,108,110,112,114,118,120,122,123,124,126,128,130,132,136,140,141,143,145,147,149,151,153,155,156,160,164,165,167,169,171,175,179,180,181,183,185,187,190,191,193,195,197,199,200,202,204,207,211,212,214,216,219,220,222,224,227,231,232,234,236,238,240,241,243,245,247,254,256,258,260,261,263,270,272,274,275,276,278,280,282,284,285,287,289,290,292,294,296,299,300,302,304,307,310,312,314,317,318,319,321,323,326,328,329,330,332,334,336,338,341,342,343,345,347,349,353,354,356,359,360,362,364,366,370,372,373,375,377,379,383,387,388,390,392,397,398,399,401,403,408,409,411,413,416,418,420,421,422,424,426,431,432,434,436,439,441,443,444,445,447,449,452,454,456,457,458,459,461,463,466,469,470,472,474,476,478,479,481,483,485,487,488,489,491,493,495,497,498,500,502,504,506,507,509,511,513,515,516,517,519,521,523,525,526,527,529,531,533,535,536,538,540,542,544,545,547,568,571,572,574,577,580,582,585,586,587,589,592,595,597,600,601,602,604,607,614,616,619,620,621 ./Carthage/Checkouts/OCMock/Source/OCMockTests/OCMockObjectForwardingTargetTests.m:16,20,21,23,25,27,30,32,37,39,41,43,44,46,48,50,54,57,58,60,62,63,65,70,71,73,79,80,82,86,88,89,91,94,96,97,99,102,104,105,107,109,110,112,114,115,117,118,120,121,123,125,126,128,130,135,136,138,141,144,145 ./Carthage/Checkouts/OCMock/Source/OCMockTests/OCMockObjectDynamicPropertyMockingTests.m:16,19,20,22,28,30,36,38,39,41,43,45,47,49,54,55,57,62,63,65,70,71,73,78,79,81,84,88,89,91,94,98,99,100 ./Carthage/Checkouts/OCMock/Source/OCMockTests/OCMArgTests.m:16,21,28,30,32,33,35,37,49,50,52,54,58,59,61,64,66,67,69,72,73,75,78,80,81,83,88,89,91,94,95,97,102,103 ./Carthage/Checkouts/OCMock/Source/OCMockTests/OCMInvocationMatcherTests.m:16,21,22,24,26,28,30,32,34,35,36,38,39,40,42,44,46,48,50,55,56,58,62,64,66,67,69,72,77,81,82,84,89,96,101,102,104,108,115,120,121,123,125,130,134,135 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMExceptionReturnValueProvider.h:16,18,20,22,23,24 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMBlockCaller.m:16,18,19,21,23,25,27,28,30,31,33,36,37,39,41,43,44,45 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMNonRetainingObjectReturnValueProvider.h:16,18,20,22,23,25,27 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMockMacros.h:16,17,21,22,24,26,28,30,32,34,35,53,71,89,90,91,97,98,102,103,105,107,123,139,141,146,147 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMExpectationRecorder.m:16,20,21,23,25,27,32,33,35,37,38,39,41,43,46,47,48,50,52,55,56,57 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMockObject.h:16,18,25,26,28,35,36,40,43,45,47,49,53,56,59,61,63,67,71,76,78 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMArgAction.h:16,18,20,22 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMMacroState.h:16,18,24,25,27,30,31,34,37,40,44,46,49,51,54 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMRealObjectForwarder.m:16,22,23,25,27,29,32,35,38,42,47,48,49,51,53,60,61,62,63 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMInvocationStub.h:16,18,20,22,23,26,28 ./Carthage/Checkouts/OCMock/Source/OCMock/OCPartialMockObject.h:16,18,20,23,24,26,28 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMQuantifier.m:16,20,21,23,25,27,29,31,33,34,35,37,39,41,42,44,46,47,49,51,52,54,56,57,58,60,62,65,67,68,69,71,73,74,76,78,82,83,84,86,87,89,91,93,94,96,97,99,101,105,106,108,110,111,113,115,116,118,119,121,123,127,128,130,132,133,135,137,138,140 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMock.h:16 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMStubRecorder.m:16,26,30,32,34,36,39,43,44,46,48,49,50,52,54,57,59,61,63,66,67,69,72,73,75,78,79,81,84,85,87,90,91,93,96,97,99,102,103,106,108,111,113,115,117,120,121,122,124,125,127,129,131,133,135,139,141,143,146,147,148,150,152,154,158,159,160,162,164,166,170,171,172,174,176,178,182,183,184,186,188,190,194,195,196,198,200,202,206,207,209,211,213,215,219,221 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMRecorder.m:17,23,24,26,28,33,34,36,40,41,43,45,46,48,50,51,53,56,57,59,61,62,64,66,67,69,71,72,73,75,77,81,82,84,87,88,89,91,93,96,99,103,106,107,109,110,112,116,123,126,127,128,130,132,133,134,136,137,139,141,143,145,149,150,151 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMInvocationExpectation.m:16,19,20,22,24,28,29,31,33,34,36,38,39,41,43,46,48,49,51,53,57,59,62,63,64,65,66 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMFunctions.m:16,25,26,28,32,37,38,40,42,46,47,48,50,52,53,54,56,60,64,66,67,69,71,72,74,76,77,78,80,82,86,90,97,100,101,102,104,106,121,122,123,124,126,129,132,138,146,148,152,154,157,163,165,168,169,170,172,173,174,191,194,196,199,202,208,214,223,229,233,238,241,251,257,260,261,263,269,272,275,277,283,285,286,287,288,290,292,294,296,299,300,301,303,308,316,318,319,320,322,324,325,327,332,333,335,339,343,346,349,350,352,355,356,357,359,361,363,368,369,371,373,375,377,378,380,382,383,385,387,390,392,393,394,396,399,401,403,404,406,412,413,415,420,421,422,424,426,428,432,433,435,438,441,444,445,447,449,453,454,456,458,459,460,462,464,469,475,480,482,484,487,489,491,494,496,498,502,503,505,508,509,510 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMIndirectReturnValueProvider.h:16,18,20,23,24,26,28 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMObjectReturnValueProvider.m:16,18,19,21,23,27,28,30,33,34,35 ./Carthage/Checkouts/OCMock/Source/OCMock/OCProtocolMockObject.m:16,19,20,22,24,26,29,33,34,36,39,40,42,44,47,51,53,54,56,58,59,61,63,64 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMBlockArgCaller.h:16,18,20,22,23,25 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMBoxedReturnValueProvider.m:16,20,21,23,25,31,33,36,38,40,42,44,47,48,49,51,55,59,61,62,63 ./Carthage/Checkouts/OCMock/Source/OCMock/OCClassMockObject.h:16,18,20,24,25,27,30,32 ./Carthage/Checkouts/OCMock/Source/OCMock/NSObject+OCMAdditions.m:16,20,21,23,25,28,31,34,39,41,45,47,49,50,54,56,57,58,60,62,66,68,71,73,74,75,76 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMInvocationMatcher.h:16,18,20,24,25,28,31,33,36 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMPassByRefSetter.h:16,18,20,22,23,25 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMArg.m:16,22,23,25,27,29,30,32,34,35,37,39,40,42,44,45,47,49,50,52,54,55,57,59,60,62,66,67,69,73,74,76,78,79,81,83,84,86,88,89,91,93,94,96,98,99,101,102,106,111,113,115,117,118,119,121,123,124,125,127,130,136,138,143,145,146 ./Carthage/Checkouts/OCMock/Source/OCMock/NSNotificationCenter+OCMAdditions.h:16,18,20,21,23,25 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMObserverRecorder.h:16,18,20,22,23,25,27,29,31,33 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMNotificationPoster.h:16,18,20,22,23,25,27 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMVerifier.h:16,18,21,23,26,28 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMConstraint.m:17,19,20,22,24,26,27,29,31,32,34,36,37,39,49,50,52,58,59,60,62,63,64,66,68,70,72,73,75,76,77,79,81,83,85,86,88,89,90,92,94,96,98,99,101,102,103,105,107,109,111,112,114,115,116,118,120,122,128,129,131,133,135,137,139,141,142,144,145,149,150,152,154,155,156 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMLocation.m:16,18,19,21,23,25,26,28,30,34,35,37,38,40,43,44,46,48,49,51,53,54,56,58,59,61,62,64,66,67 ./Carthage/Checkouts/OCMock/Source/OCMock/NSInvocation+OCMAdditions.m:16,22,27,30,32,33,35,37,40,44,46,49,50,52,53,54,55,57,59,61,64,65,67,70,77,78,81,84,88,90,100,104,105,107,111,113,115,116,117,118,119,122,123,124,126,129,131,134,136,139,141,147,149,151,152,154,156,158,161,163,168,171,178,179,180,181,182,184,186,189,191,195,196,198,200,204,206,210,212,216,218,222,224,228,230,234,236,240,242,246,248,252,254,258,260,264,266,270,272,276,278,282,284,288,291,295,297,305,306,307,310,311,312,314,317,320,325,328,329,331,332,334,336,338,359,360,361,362,364,366,375,376,378,382,383,385,388,390,396,397,399,402,405,406,408,410,413,414,416,418,421,422,424,426,429,430,432,434,437,438,440,442,445,446,448,450,453,454,456,458,461,462,464,466,469,470,472,474,477,478,480,482,485,486,488,490,493,494,496,498,499,501,503,505,510,511,513,515,517,519,521,523,528,529,530,532,534,537,538,539,541,543,546,548,549,553,555,557,561,563,565,566,567,569,571,572,574,579,580 ./Carthage/Checkouts/OCMock/Source/OCMock/NSValue+OCMAdditions.h:16,18,20,22 ./Carthage/Checkouts/OCMock/Source/OCMock/OCObserverMockObject.h:16,18,20,21,24,28,29,31,33,36,38,40,43 ./Carthage/Checkouts/OCMock/Source/OCMock/NSMethodSignature+OCMAdditions.m:16,20,21,23,25,27,32,39,44,45,48,52,56,57,58,60,62,66,69,70,73,78,81,84,85,86,91,95,98,103,104,105,107,109,110,111,113,115,120,122,125,130,133,134,137,138,139,141,143,145,148,151,157,163,164,165,167,173,174,175,177,179,180 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMRealObjectForwarder.h:16,18,20,21,22,24 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMMacroState.m:16,20,21,23,25,27,29,34,35,37,44,50,52,53,54,56,61,62,64,66,67,68,70,75,76,78,84,85,86,88,90,91,93,100,101,103,110,116,117,118,119,121,123,125,126,127,129,131,133,135,136,138,139,141,146,147,149,152,153,155,157,158,160,162,163,165,167,168,169,171,173,175,176,177 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMArgAction.m:16,18,19,21,23,24,25,26,27 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMockObject.m:16,31,32,34,36,38,41,42,43,45,47,49,50,52,54,55,57,59,60,61,63,65,66,68,70,71,72,74,77,78,79,81,83,84,85,87,89,93,96,97,100,102,103,105,107,108,116,117,119,125,126,128,130,131,133,136,138,139,140,142,144,149,150,151,153,155,157,158,159,161,163,165,166,167,169,171,180,181,182,183,185,187,189,190,192,198,202,203,204,205,207,209,210,212,214,215,217,219,220,221,223,225,226,228,231,233,236,237,238,240,244,246,250,251,254,256,258,262,264,266,267,268,270,272,273,275,278,280,283,285,288,289,292,296,298,299,300,302,304,306,307,309,311,312,314,318,320,323,324,328,331,332,333,335,338,342,343,346,347,348,350,352,354,363,365,366,367,369,371,375,377,378,380,382,385,387,389,391,393,396,398,399,401,402,403,405,408,412,415,418,420,423,426,427,433,436,437,438,440,442,444,445,446,448,450,452,454,455,457,458,461,466,467,469,471,474,475,476,478,480,484,486,489,490,491,492,494,496,500,502,504,507,509,510,512,514,517,519,524,526,529,530,531 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMExpectationRecorder.h:16,18,20,22 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMNonRetainingObjectReturnValueProvider.m:16,20,21,23,25,29,30,32,34,36,38,40 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMBlockCaller.h:16,18,20,22,23,25,27,29 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMExceptionReturnValueProvider.m:16,18,19,21,23,24,26,28,29 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMObjectReturnValueProvider.h:16,18,20 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMIndirectReturnValueProvider.m:16,18,19,21,23,25,28,29,31,32,34,37,38,40,43,47,50,51 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMFunctions.h:16,18,19,25,26 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMStubRecorder.h:16,19,21,25,27,35,39,41,42,44,54,57,60,63,66,69,74,76,81,86,88,89,90 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMRecorder.h:16,18,21,22,24,29,30,31,34,37,40,43,44,46,48,51 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMInvocationExpectation.h:16,18,20,23,24,27,29 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMQuantifier.h:16,18,20,22,23,28,30,32,34,35,40 ./Carthage/Checkouts/OCMock/Source/OCMock/OCPartialMockObject.m:16,24,25,27,29,31,39,40,42,44,45,47,49,50,52,54,62,65,66,68,70,78,79,81,82,84,86,88,95,97,98,100,104,105,107,112,113,115,123,126,127,131,133,137,141,143,144,145,146,148,150,152,156,161,168,174,184,186,188,190,192,193,195,199,207,212,213,214,217,223,224,225,227,234,236,237,240,242,243,244,246,251,253,256,257,258,259,261,263,270,273,275,277,278,279 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMInvocationStub.m:16,21,23,24,26,28,32,33,35,38,39,40,42,44,45,47,49,50,51,53,56,60,63,65,69,71,74,76,81,82,84,86,87,88,90,94,97,100,103,106,107,108,110,112,113,114 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMPassByRefSetter.m:16,18,19,21,23,25,27,28,30,31,33,36,37,39,42,47,48,49 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMInvocationMatcher.m:16,24,25,29,30,32,34,37,38,40,48,49,51,53,54,56,58,59,61,63,64,66,68,69,71,73,74,76,82,84,85,87,92,95,99,101,103,104,107,109,113,114,117,119,122,124,126,128,131,133,140,141,143,144 ./Carthage/Checkouts/OCMock/Source/OCMock/NSObject+OCMAdditions.h:16,18,20,23 ./Carthage/Checkouts/OCMock/Source/OCMock/OCClassMockObject.m:16,23,27,28,30,32,34,40,41,43,46,47,49,51,52,54,56,57,59,62,64,68,69,70,72,74,76,78,80,83,85,86,87,89,94,95,96,98,102,103,104,106,108,112,116,121,123,128,134,136,141,153,155,157,159,161,162,163,165,169,173,178,179,180,182,186,188,190,193,194,195,197,199,200,201,203,205,208,210,212,213,215,217,218,220,222,223,225,227,228,230,232,233,235,240,242,244,245,247,248,250,254,267,269,271,273,274,276,278,279,281,283,284,286,288,289,291,293,294,296,298,299,301,303,304,306,308,309,311,313,314,316,318,319 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMBoxedReturnValueProvider.h:16,18,20,21,22 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMBlockArgCaller.m:16,19,20,22,24,27,29,31,32,34,37,38,40,42,43,45,47,50,51,52 ./Carthage/Checkouts/OCMock/Source/OCMock/OCProtocolMockObject.h:16,18,20,22,23,25,27 ./Carthage/Checkouts/OCMock/Source/OCMock/NSMethodSignature+OCMAdditions.h:16,18,20,23,25,28 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMFunctionsPrivate.h:16,18,22,23,31,34,38,42,45,48,50,53,54,55,57,72,74,79 ./Carthage/Checkouts/OCMock/Source/OCMock/NSInvocation+OCMAdditions.h:16,18,20,22,24,26,28,30,48,51 ./Carthage/Checkouts/OCMock/Source/OCMock/OCObserverMockObject.m:16,22,27,29,31,33,36,37,39,40,42,44,45,47,53,54,56,58,59,61,63,64,66,68,70,71,72,73,75,77,80,82,84,85,87,89,90,92,94,96,100,102,106,107,108,109,110,112,116,118,120,124,126,127,129,131,135,137,138,139,141,143,145,147,150,152,155,156,157,160,161,162 ./Carthage/Checkouts/OCMock/Source/OCMock/NSValue+OCMAdditions.m:16,19,20,22,24,27,42,43,44,45,47,55,58,60,70,77,80,83,84,85 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMLocation.h:16,19,21,25,26,28,30,34,36 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMConstraint.h:16,18,20,23,25,27,30,31,33,36,39,42,44,47,48,50,52,55,56,58,60,62,63,65,67 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMVerifier.m:16,22,23,25,27,31,33,34,36,37,39,42,43,45,48,49,51,55,56 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMNotificationPoster.m:16,18,19,21,23,25,27,28,30,31,33,36,37,39,41,42,43 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMObserverRecorder.m:16,20,21,25,27,28,30,32,34,37,38,40,42,43,44,46,48,51,52,54,57,58,59,61,63,67,68,70,72,74,76,78,80,82,84,86,88,90,91,92,93 ./Carthage/Checkouts/OCMock/Source/OCMock/NSNotificationCenter+OCMAdditions.m:16,19,20,22,25,27,30,31,33 ./Carthage/Checkouts/OCMock/Source/OCMock/OCMArg.h:16,18,20,22,34,36,41,43,45,47,49,51,58 ./Carthage/Checkouts/OCMock/Examples/SwiftExamples/usr/include/OCMock/OCMockObject.h:16,18,22,23,25,33,34,38,41,43,45,47,51,54,57,59,61,64,68,71,73 ./Carthage/Checkouts/OCMock/Examples/SwiftExamples/usr/include/OCMock/OCMMacroState.h:16,18,21,22,24,25,26,29,32,35,37,40,42 ./Carthage/Checkouts/OCMock/Examples/SwiftExamples/usr/include/OCMock/OCMock.h:16,24,25,27,29,31,33,35,37,38,45,52,56,57,59,61 ./Carthage/Checkouts/OCMock/Examples/SwiftExamples/usr/include/OCMock/NSNotificationCenter+OCMAdditions.h:16,18,20,21,23,25 ./Carthage/Checkouts/OCMock/Examples/SwiftExamples/usr/include/OCMock/OCMockRecorder.h:16,18,21,22,24,28,29,31,33,41,44,46,49,51,52,54,57,60,63,66,69,72,74,75,76 ./Carthage/Checkouts/OCMock/Examples/SwiftExamples/usr/include/OCMock/OCMLocation.h:16,18,20,24,25,27,29,33,35 ./Carthage/Checkouts/OCMock/Examples/SwiftExamples/usr/include/OCMock/OCMConstraint.h:16,18,19,21,24,26,28,31,32,34,37,40,43,45,48,49,51,53,56,57,59,61,63,64,66,68,69 ./Carthage/Checkouts/OCMock/Examples/SwiftExamples/usr/include/OCMock/OCMArg.h:16,18,20,22,32,34,37,39,41,43,45 ./Carthage/Checkouts/OCMock/Examples/SwiftExamples/SwiftExamples/Connection.swift:8,10,14,15,19,20 ./Carthage/Checkouts/OCMock/Examples/SwiftExamples/SwiftExamples/DetailViewController.swift:8,10,12,14,15,20,21,22,28,29,30,31,36,37,41,42,43,44,45,46 ./Carthage/Checkouts/OCMock/Examples/SwiftExamples/SwiftExamples/Controller.swift:8,10,14,17,18,22,23,26,27 ./Carthage/Checkouts/OCMock/Examples/SwiftExamples/SwiftExamples/AppDelegate.swift:8,10,13,15,16,20,21,25,26,30,31,34,35,38,39,42,43,44,45,46 ./Carthage/Checkouts/OCMock/Examples/SwiftExamples/SwiftExamples/MasterViewController.swift:8,10,12,14,15,18,19,24,27,28,32,33,38,39,41,47,48,49,50,52,55,56,59,60,63,67,68,72,73,80,81,82,83,84,85,86,87 ./Carthage/Checkouts/OCMock/Examples/SwiftExamples/SwiftExamplesTests/SwiftExamplesTests.swift:8,10,12,16,17,21,22,26,27,32,33,34,35 ./Carthage/Checkouts/OCMock/Examples/SwiftExamples/SwiftExamplesTests/MockTests.m:8,12,13,15,17,19,21,23,25,27,28,30,33,36,38,41,42,44,48,51,53,56,57,59,61,64,66,69,70 ./Carthage/Checkouts/OCMock/Examples/SwiftExamples/SwiftExamplesTests/SwiftExamplesTests-Bridging-Header.h:4 ./Carthage/Checkouts/OCMock/Examples/iPhoneExample/Classes/RootViewController.m:8,10,11,13,14,17,21,22,23,27,28,29,32,34,38,39,41,43,44,45,48,50,58,59,60,62 ./Carthage/Checkouts/OCMock/Examples/iPhoneExample/Classes/iPhoneExampleAppDelegate.m:8,11,12,14,17,18,21,23,25,29,31,32,33,39,40,41,47,48,49,54,55,56,61,62,63,69,70,71,74,79,80,81,86,87,88,90 ./Carthage/Checkouts/OCMock/Examples/iPhoneExample/Classes/RootViewController.h:8,10,12,13 ./Carthage/Checkouts/OCMock/Examples/iPhoneExample/Classes/iPhoneExampleAppDelegate.h:8,10,12,15,16,19,21 ./Carthage/Checkouts/OCMock/Examples/iPhoneExample/Tests/RootViewControllerTests.m:8,12,14,17,19,23,25,29,32,41,46,48,49,51,53,55,57,58,59,61,65,67,71,72,73,74 ./Carthage/Checkouts/OCMock/Examples/iPhoneExample/Tests/RootViewControllerTests.h:9,10,13,14,16 ./Carthage/Checkouts/OCMock/Examples/iPhoneExample/Libraries/Headers/OCMock/OCMockObject.h:5,7,9,15,16,20,23,25,27,29,32,34,36,40 ./Carthage/Checkouts/OCMock/Examples/iPhoneExample/Libraries/Headers/OCMock/OCMock.h:5 ./Carthage/Checkouts/OCMock/Examples/iPhoneExample/Libraries/Headers/OCMock/NSNotificationCenter+OCMAdditions.h:5,7,9,10,12,14 ./Carthage/Checkouts/OCMock/Examples/iPhoneExample/Libraries/Headers/OCMock/OCMockRecorder.h:5,7,9,13,14,16,19,28,30 ./Carthage/Checkouts/OCMock/Examples/iPhoneExample/Libraries/Headers/OCMock/OCMConstraint.h:5,7,8,10,13,15,17,20,21,23,26,29,32,34,37,38,40,42,45,46,48,50,52,54,55,57,59,61,62 ./Carthage/Checkouts/OCMock/Examples/iPhoneExample/Libraries/Headers/OCMock/OCMArg.h:5,7,9,11,21,23,25,27,29,31 ./Carthage/Checkouts/OCMock/Examples/iPhoneExample/main.m:8,10,12,17 ./Carthage/Checkouts/OCMock/Examples/ArcExample/ArcExample/main.m:1,4,8,12,14,16,18,19,21,22,24,30,31,33,34 ./Carthage/Checkouts/OCMock/Examples/iOS7Example/usr/include/OCMock/OCMockObject.h:16,18,24,25,27,34,35,39,42,44,46,48,52,55,58,60,62,65,69,72,74 ./Carthage/Checkouts/OCMock/Examples/iOS7Example/usr/include/OCMock/OCMMacroState.h:16,18,23,24,26,28,29,32,35,38,40,42,44 ./Carthage/Checkouts/OCMock/Examples/iOS7Example/usr/include/OCMock/OCMock.h:16,25,26,28,30,32,34,36,38,39,48,57,63,64,66,68,77 ./Carthage/Checkouts/OCMock/Examples/iOS7Example/usr/include/OCMock/NSNotificationCenter+OCMAdditions.h:16,18,20,21,23,25 ./Carthage/Checkouts/OCMock/Examples/iOS7Example/usr/include/OCMock/OCMStubRecorder.h:16,18,19,21,29,31,32,34,37,40,43,46,49,52,54,55,56 ./Carthage/Checkouts/OCMock/Examples/iOS7Example/usr/include/OCMock/OCMRecorder.h:16,18,21,22,24,27,28,31,33,35,38 ./Carthage/Checkouts/OCMock/Examples/iOS7Example/usr/include/OCMock/OCMLocation.h:16,18,20,24,25,27,29,33,35 ./Carthage/Checkouts/OCMock/Examples/iOS7Example/usr/include/OCMock/OCMConstraint.h:16,18,19,21,24,26,28,31,32,34,37,40,43,45,48,49,51,53,56,57,59,61,63,64,66,68,69 ./Carthage/Checkouts/OCMock/Examples/iOS7Example/usr/include/OCMock/OCMArg.h:16,18,20,22,32,34,37,39,41,43,45 ./Carthage/Checkouts/OCMock/Examples/iOS7Example/iOS7ExampleTests/iOS7ExampleTests.m:8,13,15,17,19,21,24,25,27,30,31,33,35,38,40,46,48,50,52,53 ./Carthage/Checkouts/OCMock/Examples/iOS7Example/iOS7Example/AppDelegate.h:8,10,12,14 ./Carthage/Checkouts/OCMock/Examples/iOS7Example/iOS7Example/DetailViewController.m:8,10,15,17,19,21,24,27,28,31,32,33,35,37,40,41,42,44,48,49,51,54,55,57,59,63,64,66,70,71 ./Carthage/Checkouts/OCMock/Examples/iOS7Example/iOS7Example/MasterViewController.h:8,10,12,14,16 ./Carthage/Checkouts/OCMock/Examples/iOS7Example/iOS7Example/main.m:8,10,12,14,17,18 ./Carthage/Checkouts/OCMock/Examples/iOS7Example/iOS7Example/AppDelegate.m:8,10,12,14,20,22,23,25,28,29,31,34,35,37,39,40,42,44,45,47,49,50 ./Carthage/Checkouts/OCMock/Examples/iOS7Example/iOS7Example/MasterViewController.m:8,10,12,15,17,19,21,25,27,28,30,34,38,39,41,44,45,47,50,54,55,57,59,61,62,64,66,67,69,71,75,76,78,81,82,84,90,91,92,96,97,99,103,106,108,110,114,115,116,118,123,124,125 ./Carthage/Checkouts/OCMock/Examples/iOS7Example/iOS7Example/DetailViewController.h:8,10,12,14 ./Carthage/Checkouts/OCMock/Examples/iOS5Example/usr/include/OCMock/OCMockObject.h:5,7,9,16,17,21,24,26,28,30,34,36,38,42 ./Carthage/Checkouts/OCMock/Examples/iOS5Example/usr/include/OCMock/OCMock.h:5 ./Carthage/Checkouts/OCMock/Examples/iOS5Example/usr/include/OCMock/NSNotificationCenter+OCMAdditions.h:5,7,9,10,12,14 ./Carthage/Checkouts/OCMock/Examples/iOS5Example/usr/include/OCMock/OCMockRecorder.h:5,7,9,13,14,16,19,29,31 ./Carthage/Checkouts/OCMock/Examples/iOS5Example/usr/include/OCMock/OCMConstraint.h:5,7,8,10,13,15,17,20,21,23,26,29,32,34,37,38,40,42,45,46,48,50,52,54,55,57,59,61,62 ./Carthage/Checkouts/OCMock/Examples/iOS5Example/usr/include/OCMock/OCMArg.h:5,7,9,11,21,23,25,27,29,31 ./Carthage/Checkouts/OCMock/Examples/iOS5Example/iOS5ExampleTests/ProtocolTests.m:5,8,9,11,13,15,17,19,20,23,25,27,29,33,34,36,38,39,41,43,45,48,50,52,54,55 ./Carthage/Checkouts/OCMock/Examples/iOS5Example/iOS5ExampleTests/iOS5ExampleTests.h:5,7,9 ./Carthage/Checkouts/OCMock/Examples/iOS5Example/iOS5ExampleTests/iOS5ExampleTests.m:5,9,11,13,15,17,18,20,22,24,25,27,29,34,39,41,43,45,46 ./Carthage/Checkouts/OCMock/Examples/iOS5Example/iOS5ExampleTests/ProtocolTests.h:5,7,9 ./Carthage/Checkouts/OCMock/Examples/iOS5Example/iOS5Example/AppDelegate.h:5,7,9,11 ./Carthage/Checkouts/OCMock/Examples/iOS5Example/iOS5Example/DetailViewController.m:5,7,12,14,18,20,22,25,28,29,32,33,34,36,38,41,42,43,45,48,49,51,53,57,58,60,64,65,67,69,70,72,74,75,77,79,80,82,84,85,87,93,94,95,97,99,103,104,106,110,111 ./Carthage/Checkouts/OCMock/Examples/iOS5Example/iOS5Example/MasterViewController.h:5,7,9,11,13 ./Carthage/Checkouts/OCMock/Examples/iOS5Example/iOS5Example/main.m:5,7,9,11,14,15 ./Carthage/Checkouts/OCMock/Examples/iOS5Example/iOS5Example/AppDelegate.m:5,7,9,11,13,19,21,22,24,29,30,32,37,38,40,44,45,47,51,52,54,60,61 ./Carthage/Checkouts/OCMock/Examples/iOS5Example/iOS5Example/MasterViewController.m:5,7,9,11,13,15,19,21,22,24,27,28,30,32,38,39,40,42,46,47,49,51,52,54,56,57,59,61,62,64,66,67,69,75,76,77,81,84,86,87,90,96,97,98,99,103,104,106,110,113,115 ./Carthage/Checkouts/OCMock/Examples/iOS5Example/iOS5Example/DetailViewController.h:5,7,9,11,13 ./Carthage/Checkouts/OCMock/Examples/iOS9Example/usr/include/OCMock/OCMockObject.h:16,18,24,25,27,34,35,39,42,44,46,48,52,55,58,60,62,65,69,72,74 ./Carthage/Checkouts/OCMock/Examples/iOS9Example/usr/include/OCMock/OCMMacroState.h:16,18,23,24,26,28,29,32,35,38,41,43,45,47 ./Carthage/Checkouts/OCMock/Examples/iOS9Example/usr/include/OCMock/OCMock.h:16,26,27,29,31,33,35,37,39,40,54,68,82,88,89,91,93,105 ./Carthage/Checkouts/OCMock/Examples/iOS9Example/usr/include/OCMock/NSNotificationCenter+OCMAdditions.h:16,18,20,21,23,25 ./Carthage/Checkouts/OCMock/Examples/iOS9Example/usr/include/OCMock/OCMFunctions.h:16,18,19,25,26 ./Carthage/Checkouts/OCMock/Examples/iOS9Example/usr/include/OCMock/OCMStubRecorder.h:16,20,22,30,32,33,35,45,48,51,54,57,60,62,63,64 ./Carthage/Checkouts/OCMock/Examples/iOS9Example/usr/include/OCMock/OCMRecorder.h:16,18,21,22,24,27,28,31,33,35,38 ./Carthage/Checkouts/OCMock/Examples/iOS9Example/usr/include/OCMock/OCMLocation.h:16,19,20,22,26,27,29,31,35,37 ./Carthage/Checkouts/OCMock/Examples/iOS9Example/usr/include/OCMock/OCMConstraint.h:16,18,19,21,24,26,28,31,32,34,37,40,43,45,48,49,51,53,56,57,59,61,63,64,66,68,69 ./Carthage/Checkouts/OCMock/Examples/iOS9Example/usr/include/OCMock/OCMArg.h:16,18,20,22,34,36,41,43,45,47,49,51,58 ./Carthage/Checkouts/OCMock/Examples/iOS9Example/iOS9ExampleTests/iOS9ExampleTests.m:8,12,14,16,18,20,22,25,27,33,35,37,39,40 ./Carthage/Checkouts/OCMock/Examples/iOS9Example/iOS9Example/AppDelegate.h:8,10,12,14,15,17 ./Carthage/Checkouts/OCMock/Examples/iOS9Example/iOS9Example/DetailViewController.m:8,10,12,14,16,18,22,25,26,27,32,33,34,39,40,44,45 ./Carthage/Checkouts/OCMock/Examples/iOS9Example/iOS9Example/MasterViewController.h:8,10,12,14,16,17,19 ./Carthage/Checkouts/OCMock/Examples/iOS9Example/iOS9Example/main.m:8,11,15,16 ./Carthage/Checkouts/OCMock/Examples/iOS9Example/iOS9Example/AppDelegate.m:8,11,13,15,17,18,26,27,31,32,36,37,40,41,44,45,48,49,51,58,59,60 ./Carthage/Checkouts/OCMock/Examples/iOS9Example/iOS9Example/MasterViewController.m:8,11,13,16,18,23,27,28,32,33,37,38,42,46,47,49,58,59,60,62,65,66,69,70,73,77,78,82,83,90,91,92 ./Carthage/Checkouts/OCMock/Examples/iOS9Example/iOS9Example/DetailViewController.h:8,10,12,15,17 ./Vendor/bundle/ruby/2.7.0/gems/json-2.3.1/ext/json/ext/fbuffer/fbuffer.h:1,4,6,10,14,24,33,40,45,52,54,59,72,74,81,82,84,87,88,90,92,93,95,97,101,102,104,108,109,110,112,117,118,119,122,125,127,129,131,133,137,138,141,143,146,147,148,150,154,160,161,163,167,168,170,173,177,178,180,185 ./Vendor/bundle/ruby/2.7.0/gems/json-2.3.1/ext/json/ext/parser/parser.h:3,5,9,15,17,19,23,29,47,54,57,77,81,90 ./Vendor/bundle/ruby/2.7.0/gems/json-2.3.1/ext/json/ext/parser/parser.c:5,11,14,18,20,27,29,46,48,64,65,67,88,90,91,95,101,102,104,105,106,111,113,114,116,117,119,123,126,127,129,130,132,134,135,137,139,143,161,167,173,185,196,212,238,247,258,260,261,274,287,298,314,330,346,372,388,404,420,429,456,459,460,462,470,475,476,477,481,482,483,484,485,490,492,493,495,496,498,500,501,503,505,506,508,510,514,532,544,547,551,560,561,567,571,575,579,583,587,592,593,597,602,603,607,609,613,615,619,621,634,645,661,677,693,835,865,868,869,871,876,877,878,879,884,886,887,889,890,892,894,895,897,899,900,903,905,909,914,954,959,962,963,965,975,976,977,978,983,985,986,988,989,991,995,998,999,1001,1002,1004,1006,1007,1009,1011,1012,1015,1017,1021,1026,1050,1066,1090,1108,1123,1127,1137,1140,1141,1143,1158,1159,1163,1164,1165,1166,1167,1172,1174,1175,1177,1178,1180,1183,1186,1188,1189,1191,1193,1194,1196,1198,1202,1228,1237,1247,1249,1250,1263,1284,1298,1314,1330,1346,1372,1388,1397,1414,1417,1418,1420,1426,1427,1428,1430,1434,1478,1487,1488,1491,1496,1501,1502,1505,1506,1507,1512,1514,1515,1517,1518,1521,1527,1529,1530,1532,1535,1537,1539,1541,1542,1545,1547,1551,1566,1572,1580,1581,1652,1660,1663,1664,1666,1675,1676,1677,1682,1687,1688,1689,1701,1703,1709,1713,1716,1717,1746,1749,1752,1773,1776,1782,1788,1794,1799,1805,1811,1817,1823,1830,1832,1842,1849,1850,1851,1856,1858,1859,1861,1862,1870,1875,1876,1878,1880,1881,1885,1887,1891,1909,1921,1924,1935,1946,1962,1978,1994,2003,2014,2017,2018,2020,2026,2027,2028,2030,2038,2039,2041,2045,2046,2048,2051,2052,2063,2065,2070,2071,2079,2082,2083,2085,2099,2102,2105,2108,2129,2130 ./Vendor/bundle/ruby/2.7.0/gems/json-2.3.1/ext/json/ext/generator/generator.c:3,8,20,26,48,66,74,86,95,103,104,106,109,110,113,115,120,121,126,129,130,134,138,145,149,160,162,186,207,208,209,223,224,226,227,233,241,272,284,291,295,296,298,301,302,307,309,310,317,318,330,335,340,345,350,355,360,365,370,375,380,385,390,395,400,410,412,413,424,425,433,435,436,444,446,447,454,456,458,465,467,468,477,478,487,489,490,500,507,508,516,520,521,529,534,535,542,544,545,552,554,555,562,564,565,574,581,582,584,595,596,598,610,611,622,624,628,629,637,650,658,666,674,682,692,693,703,704,713,714,720,721,723,731,732,733,741,756,757,764,770,771,772,779,781,788,790,791,798,801,806,818,822,826,827,828,836,841,844,845,847,856,860,862,868,875,876,877,879,880,882,895,903,904,906,913,914,915,917,918,921,925,927,929,934,940,942,943,945,947,948,950,952,953,955,957,958,960,962,963,965,968,969,972,977,980,991,992,994,995,997,1026,1027,1028,1030,1034,1039,1045,1049,1054,1058,1059,1061,1066,1067,1076,1081,1082,1104,1112,1113,1121,1123,1128,1139,1140,1149,1157,1158,1159,1166,1169,1170,1177,1187,1192,1194,1195,1203,1206,1207,1215,1225,1230,1232,1233,1240,1243,1244,1251,1261,1266,1268,1269,1277,1280,1281,1289,1298,1303,1305,1306,1313,1316,1317,1324,1333,1338,1340,1341,1342,1350,1353,1354,1362,1365,1366,1374,1378,1379,1387,1390,1391,1399,1402,1403,1410,1413,1414,1422,1427,1428,1435,1438,1439,1447,1454,1456,1457,1462,1465,1469,1474,1506,1538,1569 ./Vendor/bundle/ruby/2.7.0/gems/json-2.3.1/ext/json/ext/generator/generator.h:3,6,8,14,18,22,24,26,28,32,38,43,45,48,55,57,78,81,85,90,97,157,161,170 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/include/sass.h:3,5,13,15 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/include/sass/version.h:3,7,11 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/include/sass/context.h:3,9,13,14,17,23,30,36,40,44,49,54,58,62,69,70,89,110,111,124,131,134,144,155,159,164,169,171,173 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/include/sass/values.h:3,7,11,12,15,28,37,45,57,62,65,68,71,75,87,93,99,103,113,124,132,136,140,142,144 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/include/sass/functions.h:3,7,11,12,21,35,42,49,55,56,60,65,68,76,81,89,97,111,116,117,118,124,128,133,134,136,138 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/include/sass/base.h:3,6,19,25,28,37,39,48,50,54,56,61,62,74,81,85,89,92,94,96 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/include/sass2scss.h:6,9,11,20,22,26,28,30,36,42,45,46,52,59,62,66,86,89,90,92,96,102,109,112,115,117,119 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/contrib/plugin.cpp:5,8,11,12,14,22,23,25,35,36,38,47,48,50,60 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/units.cpp:7,9,14,16,25,27,34,36,42,48,54,56,58,65,67,69,71,78,80,82,84,91,93,95,120,121,123,149,150,151,153,177,178,181,192,193,196,217,220,221,223,249,257,259,260,262,265,267,270,272,274,275,277,278,281,284,296,297,309,310,313,316,317,319,320,323,326,332,337,340,349,350,351,355,363,364,367,368,369,371,378,383,385,386,388,391,392,394,397,398,401,402,408,411,414,417,420,423,425,429,438,446,450,451,454,457,460,463,467,476,484,488,489,493,496,499,502,503,505,506,507 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/dart_helpers.hpp:3,8,10,16,21,23,24,38,40,41,46,50,52,54,64,65,67,69,79,80,82,83,89,93,98,100,108,109,112,115,123,127,140,141,142,143,148,153,157,165,166,171,174,175,176,177,180,185,189,191,193,196,197,198 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/fn_miscs.cpp:6,8,10,14,17,20,21,24,26,29,32,33,34,37,39,42,45,46,47,50,54,55,57,60,63,64,65,68,70,73,76,77,78,81,83,92,93,96,100,109,110,112,136,137,139,144,145,149,152,154,155,158,167,168,172,175,187,199,200,201,204,207,209,210,213,217,218,221,231,232,233,236,237,240,241,242,243,244 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/stylesheet.cpp:4,6,8,13,14,15,19,20,21,22 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/extension.cpp:4,8,10,15,21,22,28,29,31,33,35,37,38,39,42,43 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/ordered_map.hpp:3,5,18,20,24,27,31,33,35,38,39,40,46,47,53,54,57,58,63,65,66,69,70,79,80,82,83,86,90,92,93,98,107,109,110,111 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/ast_sel_super.cpp:5,7,9,15,24,33,40,47,48,49,50,52,54,63,67,75,81,82,83,85,86,88,90,99,103,104,106,108,114,118,119,121,123,129,133,134,136,138,146,151,153,155,162,167,168,172,173,176,177,179,181,197,198,201,210,211,212,217,221,222,223,224,233,234,235,236,240,242,248,249,250,257,258,260,261,263,264,266,281,289,290,293,294,302,303,304,306,308,321,326,328,337,338,342,345,348,351,356,357,362,365,366,369,376,382,383,385,386,403,404,405,408,409,412,415,417,420,426,427,430,431,437,438,440,441,445,447,450,451,452,454,455,457,469,481,483,492,498,499,501,503,512,518,519,521,523,528,530,532,534,535,538,539 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/MurmurHash2.hpp:7,10,13,15,17,21,23,25,27,29,31,33,36,39,41,43,45,47,49,51,55,58,61,62,64,66,77,80,84,86,87,89,91 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/to_value.hpp:3,7,9,11,13,15,17,23,37,41,43,44,45 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/prelexer.hpp:3,6,10,14,29,39,43,55,56,57,64,69,74,77,80,83,86,87,92,93,103,104,107,108,110,111,115,123,124,134,135,147,148,149,156,161,163,164,172,175,188,195,198,217,227,231,249,251,255,260,263,265,267,269,273,275,279,283,344,348,356,360,372,376,377,382,385,391,396,405,407,417,419,435,438,439,441,442,445,451,455,457,458,461,467,471,472,475,479,480,481,482,483 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/source.cpp:6,8,11,12,13,23,25,26,30,31,33,35,36,38,40,41,43,45,46,48,50,51,57,59,61,62,64,66,67,68,69 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/util.cpp:10,16,18,20,28,36,37,40,55,56,57,59,60,64,65,69,74,75,77,78,84,90,93,94,97,98,101,116,118,124,125,129,152,153,159,160,163,165,166,172,188,191,196,197,200,201,203,219,220,222,223,225,241,246,248,251,252,258,269,271,272,274,275,278,280,284,287,290,294,296,300,302,307,314,317,318,319,321,323,325,326,327,328,329,331,333,334,335,336,337,339,340,341,343,344,348,351,357,360,362,368,371,373,376,380,385,389,391,396,403,406,407,408,409,410,422,425,426,427,431,432,433,435,436,439,442,446,451,456,457,459,464,465,480,487,488,489,490,493,494,496,501,502,504,506,507,509,528,529,531,535,536,538,541,544,545,558,563,567,570,571,574,575,576,578,579,581,583,584,586,588,589,591,596,597,601,602,604,611,617,618,619,620,623,624,625,627,628,630,642,643,647,648,652,653,657,658,662,663,664,666,667,669,673,677,681,685,686,691,695,696,700,701,705,706,710,711,715,716,717,718,720,721,722,723 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/utf8_string.hpp:3,7,10,15,19,22,25,28,34,35,36,37 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/source_data.hpp:3,6,8,10,23,26,29,30,31 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/ast_selectors.cpp:4,8,10,13,18,23,24,26,28,29,32,45,47,49,50,54,56,57,59,67,68,71,74,81,82,89,91,94,95,97,103,105,106,109,110,113,115,116,119,121,122,124,126,127,129,131,132,134,136,137,140,142,143,145,147,148,150,153,155,157,158,160,165,167,172,173,176,184,186,189,190,193,200,202,205,206,209,216,218,220,221,224,231,233,235,236,239,249,251,256,258,259,261,263,264,267,284,294,296,297,299,304,306,307,309,313,314,316,320,321,323,327,328,330,333,334,338,339,342,353,355,358,360,361,363,366,368,369,371,374,375,376,378,380,381,383,387,389,390,393,399,400,406,407,408,410,413,414,415,417,421,423,424,426,431,432,434,435,437,442,443,445,450,452,453,457,459,460,462,465,467,468,471,475,476,477,482,484,485,486,488,490,491,494,498,499,502,506,507,512,514,515,516,518,520,521,524,530,531,538,540,544,546,547,549,557,559,560,562,566,568,569,571,574,575,576,578,583,584,586,589,591,592,594,598,599,602,606,608,609,613,615,616,619,623,625,626,630,632,633,639,640,641,644,646,650,651,654,655,658,661,664,667,671,680,681,688,697,700,701,704,705,710,715,716,719,722,729,736,741,742,743,754,762,765,773,774,775,781,782,788,789,790,794,796,800,802,803,805,809,811,812,814,818,820,821,823,827,829,830,832,836,838,839,841,845,847,848,852,855,856,859,866,867,868,869,870,873,876,884,899,902,903,906,907,911,917,924,925,926,927,928,937,938,940,941,942,944,946,947,949,951,952,955,956,958,960,963,964,966,971,972,974,975,980,986,987,988,991,993,1006,1008,1009,1010,1012,1013,1014,1016,1024,1026,1027,1030,1042,1043 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/backtrace.hpp:3,8,10,12,15,20,22,24,26,27,28 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/environment.cpp:4,6,22,28,33,35,36,43,45,46,50,51,55,58,62,63,67,70,72,75,77,78,82,85,89,91,92,96,100,103,105,108,110,111,115,118,123,125,127,128,134,139,141,142,148,156,159,161,165,173,176,178,179,184,189,191,193,194,199,206,208,212,217,219,221,222,226,231,233,235,240,250,251,253,258,259,260 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/parser.hpp:3,7,10,17,26,35,37,40,42,58,60,63,65,70,73,75,76,80,82,86,88,91,102,103,108,109,110,115,118,119,124,125,129,132,135,136,137,146,147,149,154,158,161,164,171,172,175,178,181,184,187,188,189,195,215,218,219,223,226,227,229,231,233,242,266,321,323,330,334,336,340,343,346,347,350,366,367,370,371,373,374,385,388,390,392,393 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/json.hpp:4,11,14,23,26,29,38,40,42,46,49,54,57,60,68,70,76,78,80,83,85,90,92,99,104,106,108,116 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/util_string.hpp:3,6,9,19,25,32,34,37,38,41,42,45,46,48,51,52,55,56,60,61,63,67,68,70,71,72 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/error_handling.hpp:3,7,16,18,20,22,27,41,47,56,66,77,86,92,98,108,118,127,136,150,160,170,181,187,198,204,210,216,222,223,224,228,233,236,237,238 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/sass_context.hpp:3,7,10,13,16,19,22,25,33,39,45,50,55,58,61,64,67,69,70,73,74,77,80,83,94,97,99,102,105,107,110,114,116,128 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/memory/memory_pool.hpp:3,9,11,13,19,25,31,36,45,47,50,53,56,62,67,68,70,78,79,80,86,89,90,91,94,95,103,107,114,119,132,133,134,141,142,147,150,153,154,156,158,159,163,166,173,177,178,179,181,183,184,185 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/memory/allocator.hpp:3,7,13,15,17,19,21,23,25,28,30,40,43,46,49,54,57,59,60,63,65,66,69,71,72,76,79,82,83,86,89,90,92,96,98,99,103,105,106,108,115,116,117,118,120,127,132,134,135,137 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/memory/config.hpp:3,6,10,15,19 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/memory/shared_ptr.cpp:4,7,11,13,25,26,27,28,31,33 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/memory/allocator.cpp:4,10,12,14,19,21,24,27,28,30,31,37,42,43,44,45,47,48 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/memory/shared_ptr.hpp:3,5,13,17,19,22,27,29,32,35,38,40,43,46,49,51,68,75,76,78,79,86,92,94,98,101,103,118,127,131,132,140,142,143,146,147,154,157,158,163,177,182,183,191,193,196,199,203,207,212,213,218,219,223,224,233,235,238,242,243,247,248,253,254,258,259,263,264,268,269,273,274,278,279,283,284,288,289,293,294,298,299,303,304,308,309,313,314,318,319,323,324,328,329,330,331 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/ast_helpers.hpp:3,10,12,15,18,22,25,31,35,39,40,45,47,51,52,57,59,63,65,70,71,77,79,84,85,91,93,98,99,105,107,112,113,119,121,128,129,135,137,142,143,149,151,155,162,163,169,171,177,183,185,189,196,200,201,206,207,211,213,214,222,224,225,232,237,238,245,250,252,257,265,267,272,274,276,281,284,286,289,290,291 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/eval.hpp:3,8,13,15,18,20,27,31,34,41,53,78,86,93,97,102,105,107,108,109 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/ast_sel_unify.cpp:4,6,8,18,19,22,29,34,35,36,39,40,41,47,48,50,52,53,55,62,68,70,72,83,84,92,93,97,98,99,101,108,110,111,114,116,117,119,124,128,134,136,139,141,142,147,151,152,154,155,160,161,164,165,169,170,171,173,183,188,189,191,192,195,196,198,199,201,210,215,217,222,224,228,231,233,239,247,249,251,256,265,266,267,269,271,274,275 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/ast.cpp:4,6,8,10,29,30,31,50,51,52,55,57,59,60,62,70,71,73,82,83,85,87,88,91,101,103,105,106,108,110,111,113,115,116,119,130,132,135,137,138,140,143,145,146,149,156,158,160,161,164,174,179,181,182,185,194,196,198,199,202,211,214,224,226,232,238,239,242,249,252,264,266,269,270,273,284,287,300,303,306,316,319,326,329,336,339,346,349,358,360,362,363,366,375,377,379,380,383,396,399,406,409,416,419,426,429,435,437,444,447,460,477,495,512,515,525,528,537,540,548,556,559,576,577,579,581,586,588,590,592,594,600,601,604,607,610,611,619,622,623,624,626,629,630,632,634,638,640,642,644,645,647,651,653,654,657,672,674,677,679,680,682,687,688,689,691,692,694,699,700,701,703,704,706,710,712,716,719,721,725,727,731,734,735,736,737,740,752,755,766,769,778,780,784,786,789,792,794,796,799,802,804,805,806,809,816,819,820,823,825,826,828,830,834,835,837,839,841,843,845,847,849,851,853,854,857,867,870,883,885,889,891,895,897,901,904,905,906,907,910,913,949,952,953 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/settings.hpp:3,5,10,15,18 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/emitter.cpp:7,9,27,30,32,33,35,37,38,40,43,46,49,58,60,63,70,71,74,78,84,89,93,94,95,98,101,102,105,110,112,113,115,117,118,121,128,129,132,133,136,141,149,150,151,154,159,160,161,165,173,176,177,179,181,191,192,194,201,204,205,206,208,212,213,215,219,220,222,224,225,227,233,234,235,236,237,239,244,245,246,248,254,255,256,258,263,264,265,267,276,278,288,295,296,297 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/position.hpp:3,8,10,11,13,19,23,26,33,36,39,43,45,47,53,63,66,69,71,78,87,95,96,99,102,104,106,108,112,115,116,119,120,123,124,127,128,131,132,137,138,142,144,145,146 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/fn_lists.hpp:3,5,7,9,19,29,30,31,32,33 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/values.hpp:3,5,7,10,11 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/extender.cpp:5,9,11,26,41,53,55,57,66,68,70,80,82,86,87,89,94,96,98,101,102,104,108,109,110,112,113,114,115,116,118,119,121,128,132,134,136,144,156,157,159,161,174,175,179,183,184,185,187,189,191,192,193,196,197,199,200,202,210,221,222,223,224,225,226,227,229,239,244,250,252,261,268,275,276,277,280,299,300,303,305,308,310,312,318,326,327,329,338,339,340,341,342,345,346,347,349,352,353,367,368,369,372,373,374,376,385,397,398,399,401,424,425,427,439,442,443,445,454,455,461,470,471,472,475,477,478,479,487,489,490,491,493,494,496,504,505,516,517,522,523,526,527,528,529,532,533,537,538,540,550,551,569,583,584,592,593,595,596,603,604,605,606,610,611,613,617,623,624,626,628,634,635,637,643,645,647,648,649,650,651,653,655,662,667,669,677,684,686,698,699,703,705,708,709,713,720,721,728,730,731,734,735,736,739,740,744,748,749,750,751,759,761,762,787,791,806,807,809,813,819,820,823,824,830,834,835,836,837,844,845,851,852,853,854,856,858,867,868,872,875,878,879,887,889,899,911,914,915,916,921,923,931,932,940,942,952,960,966,967,969,970,972,981,987,994,1002,1003,1004,1005,1006,1007,1010,1021,1023,1024,1025,1029,1030,1032,1040,1046,1047,1049,1061,1062,1069,1074,1078,1089,1090,1094,1095,1104,1105,1106,1107,1113,1114,1120,1121,1124,1125,1126,1128,1129,1131,1136,1140,1142,1147,1152,1154,1156,1164,1167,1169,1174,1176,1178,1183,1185,1187,1188 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/ast_sel_weave.cpp:4,8,10,15,18,20,26,30,32,34,43,44,51,52,53,54,56,64,65,66,67,68,69,71,72,74,82,83,87,88,92,96,97,101,105,106,110,111,118,120,127,129,136,138,140,147,149,151,166,171,172,177,178,182,189,191,203,205,207,215,224,227,231,232,235,237,239,250,251,257,258,264,265,269,273,277,278,280,281,283,294,295,299,300,301,307,308,314,315,319,326,329,332,334,335,341,343,346,349,351,354,357,364,366,367,370,375,378,382,387,388,395,397,398,399,404,409,414,417,418,420,421,423,429,430,431,433,435,437,438,439,445,446,447,449,451,453,454,456,468,470,472,474,477,483,485,486,488,490,499,500,502,503,505,506,508,525,526,533,538,544,547,550,551,555,558,561,564,566,571,575,581,584,585,586,587,592,595,599,603,607,609,610,612,615,616 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/expand.hpp:3,5,10,12,17,20,30,32,34,42,52,54,56,58,62,65,67,70,91,93,95,96,97 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/kwd_arg_macros.hpp:3,14,16,27 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/bind.cpp:11,13,15,17,21,27,28,29,30,39,40,52,53,54,59,61,66,86,87,90,94,96,113,114,115,117,132,136,142,151,152,155,164,165,168,173,174,183,184,185,198,201,202,203,214,218,219,222,228,230,235,237,242,243,250,254,264,265,272,273,279,281,282,284,296,300,304,305,306,307,309,310,311,312 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/c2ast.hpp:3,7,9,11,12,13 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/utf8/core.h:2,10,17,26,27,30,32,34,41,44,54,57,60,62,65,67,70,72,73,76,78,79,82,84,85,88,90,91,94,96,97,101,113,114,117,121,125,129,130,132,133,135,139,142,145,147,148,150,154,157,159,161,162,165,168,170,172,174,176,177,180,183,185,187,189,191,193,195,196,199,202,204,206,208,210,212,214,216,218,219,221,224,227,231,236,254,255,264,267,270,271,275,276,281,282,283,284,286,289,292,298,300,301,304,306,307,310,316,317,321,327,328,329,331,332 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/utf8/unchecked.h:2,10,17,26,27,30,32,34,36,39,45,50,56,58,59,62,86,89,90,93,95,96,99,103,104,108,110,111,114,117,118,121,124,125,129,134,135,138,145,147,149,150,153,159,162,164,165,168,171,173,174,177,180,182,183,194,197,199,201,203,205,207,210,212,216,218,221,223,227,229,230,231,232,233,235 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/utf8/checked.h:2,10,17,26,27,30,33,35,39,48,56,64,69,71,74,77,83,88,94,96,97,100,126,127,129,130,133,136,137,140,154,156,157,160,162,163,166,170,177,178,182,189,190,193,196,197,200,203,204,208,213,214,217,228,231,232,236,238,240,241,244,250,253,255,256,259,262,264,265,268,271,273,274,287,290,294,297,299,303,305,307,309,312,314,318,320,323,325,329,331,332,333,335,336 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/listize.hpp:3,7,10,12,14,16,18,20,24,28,34,35,36 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/source_map.hpp:3,6,11,14,17,19,22,24,29,36,39,41,43,51,62,63,64 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/permutate.hpp:3,5,7,27,28,30,35,36,39,43,49,54,58,59,61,64,65,68,69,72,74,75,78,80,100,103,108,109,112,116,117,122,129,134,142,145,149,150,153,155,156,159,161,162,163 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/sass.hpp:4,9,13,29,30,40,49,50,53,56,60,63,73,77,78,79,87,93,96,100,103,109,111,114,119,123,133,144,146 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/sass_functions.cpp:4,11,14,16,18,19,21,28,29,31,34,35,38,44,46,47,51,55,57,64,65,69,72,74,75,78,80,81,84,90,92,93,96,99,101,102,106,117,118,121,123,124,127,134,135,139,142,148,150,151,154,161,162,170,175,178,182,185,189,192,193,199,204,209,210 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/ast_fwd_decl.hpp:3,9,14,19,21,23,25,27,37,41,44,48,52,56,65,69,76,85,89,97,104,105,112,114,120,125,127,134,139,215,221,225,232,235,239,242,245,248,252,256,271,272,273 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/ast2c.cpp:4,7,9,12,15,18,21,24,26,29,30,32,37,38,39,42,44,48,50,51,53,60,62,63,65,69,71,72,75,79 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/base64vlq.cpp:4,6,8,10,12,14,20,23,25,26,28,33,34,36,38,39,41,46,47 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/context.cpp:5,21,26,29,31,34,35,37,41,43,44,52,62,66,69,74,75,76,80,86,92,96,98,99,100,102,104,106,110,112,116,117,119,124,133,137,138,140,146,147,149,150,151,153,157,163,166,167,172,173,174,175,177,179,182,183,184,186,190,196,199,200,205,206,207,208,210,212,215,216,217,221,228,232,235,236,240,241,249,252,255,259,264,274,279,282,293,298,299,300,317,318,322,326,327,330,331,335,346,347,360,361,362,365,366,367,369,373,376,379,380,385,393,399,401,402,403,404,405,408,430,446,458,470,473,480,481,484,485,492,494,509,514,515,519,520,522,535,536,537,539,540,543,547,550,558,559,564,567,577,580,583,584,585,587,588,591,600,601,604,609,619,622,625,626,629,651,654,659,660,665,670,673,675,677,686,687,689,692,693,695,699,700,701,705,714,715,717,721,722,724,730,731,733,742,743,744,746,847,848,850,854,855,857,861,862,863 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/fn_utils.hpp:3,7,13,15,25,29,33,36,38,41,45,47,48,57,58,59,60,61 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/fn_strings.hpp:3,5,7,9,19,29,30,31,32,33 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/fn_maps.hpp:3,5,7,9,11,18,25,26,27,28,29 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/remove_placeholders.cpp:5,7,9,12,16,17,18,20,23,24,25,27,30,32,33,35,38,43,44,46,47,48,50,53,56,57,59,61,62,64,68,73,74,75,77,79,80,82,84,85,86 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/file.hpp:3,7,10,13,15,17,21,24,28,31,34,38,42,46,49,53,58,62,65,70,71,72,90,101,114,116,119,120,121,122,123 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/ast_supports.hpp:3,7,18,34,36,38,50,61,78,91,105,118,119,120 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/fn_colors.cpp:4,11,13,15,22,23,25,26,29,31,32,33,36,50,51,57,58,61,78,79,86,87,90,100,101,103,115,116,121,122,126,129,132,133,136,139,140,143,146,147,154,157,164,165,168,173,174,175,179,182,196,197,204,205,206,209,226,227,235,236,243,244,245,249,252,255,256,259,262,263,266,269,270,274,277,283,284,287,293,294,295,298,304,305,308,312,313,319,320,323,329,330,333,338,339,344,345,349,352,357,358,361,369,371,372,379,380,384,388,392,393,398,399,401,402,406,412,413,417,423,424,428,431,440,443,446,454,462,468,472,473,476,485,488,491,503,515,522,526,527,530,539,542,545,553,561,566,570,571,574,581,588,592,593,594,595,596 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/sass_values.cpp:4,12,15,18,29,35,41,45,55,65,73,77,81,83,85,91,92,94,102,103,105,114,115,117,125,126,128,136,137,139,149,150,152,160,161,163,168,169,171,178,179,181,188,189,192,211,218,228,229,231,232,233,236,237,243,246,249,252,255,260,262,268,270,273,276,278,279,281,282,283,285,290,291,293,294,296,298,302,314,315,320,327,334,341,344,345,348,351,352,360,361,362 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/constants.cpp:4,6,9,11,23,32,64,81,88,106,108,111,118,131,134,160,164,168,179,197,198,199 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/ast_values.cpp:5,7,9,11,12,15,22,25,32,35,44,53,55,61,63,64,66,69,70,72,82,84,87,88,90,101,103,105,106,115,116,118,119,120,128,131,132,133,136,141,146,148,158,165,167,170,171,173,182,184,186,187,190,196,197,199,200,202,207,208,209,211,212,215,220,228,230,232,234,236,237,239,241,242,244,246,247,249,252,253,255,259,260,262,267,270,271,273,278,280,281,283,288,290,291,294,298,302,304,312,314,317,318,320,325,327,328,332,334,335,338,348,358,368,370,377,379,380,382,387,389,390,392,394,395,399,400,403,407,411,413,416,418,419,421,423,424,427,434,445,455,456,458,459,466,469,472,473,475,478,479,481,488,490,491,493,496,498,499,501,504,506,507,509,517,523,524,526,534,541,546,547,548,551,557,565,567,570,573,576,579,580,582,585,588,591,593,594,597,602,609,611,622,625,626,628,634,636,637,639,646,648,649,651,652,657,661,665,668,672,676,677,682,686,687,689,691,692,695,703,711,713,724,727,728,730,736,738,739,741,748,750,751,754,760,761,763,764,768,778,782,783,785,787,788,791,795,799,801,804,807,808,810,813,815,816,819,823,827,829,832,835,836,838,841,843,844,847,852,858,860,863,865,866,868,871,873,874,876,879,881,882,885,892,895,899,906,908,911,912,913,915,917,919,921,922,924,932,935,938,939,941,948,950,952,953,955,958,960,961,963,967,969,970,972,974,975,978,991,998,1001,1002,1004,1007,1010,1013,1014,1016,1019,1022,1024,1025,1027,1029,1030,1032,1034,1035,1037,1040,1042,1043,1046,1051,1054,1056,1057,1061,1063,1066,1069,1072,1073,1075,1078,1081,1083,1084,1086,1088,1089,1092,1096,1099,1101,1104,1107,1108,1110,1112,1113,1115,1117,1118,1121,1125,1129,1132,1150,1153,1154 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/debug.hpp:3,5,9,22,24,30,34,36,40,42 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/inspect.hpp:3,7,10,15,17,20,97,99,100 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/check_nesting.hpp:3,10,12,14,19,22,26,30,38,40,41,49,55,57,59,67,68,69 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/lexer.cpp:4,10,11,14,16,20,30,34,35,39,43,44,48,51,52,55,60,61,65,76,81,85,88,91,94,103,104,108,111,112,116,119,120,121,122 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/color_maps.cpp:4,8,10,12,162,163,315,316,458,460,611,613,615,616,618,622,626,628,629,631,635,637,638,640,642,643,645,650,651,652 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/fn_selectors.cpp:2,8,10,12,15,17,23,24,34,37,42,43,47,48,54,61,62,64,65,68,70,77,78,89,92,96,100,104,105,106,108,114,115,119,120,128,131,132,133,137,138,140,141,144,149,150,153,155,157,162,163,165,166,169,175,176,179,185,186,189,192,193,196,201,202,203,204,205 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/fn_numbers.cpp:4,12,17,22,24,26,29,35,38,40,43,46,48,54,58,61,65,66,69,74,75,78,83,84,87,92,93,96,101,102,105,111,117,121,123,124,127,133,139,143,145,146,149,160,166,170,181,182,183,186,192,193,196,200,201,204,208,209,212,217,223,224,225,226,227 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/plugins.hpp:3,8,10,15,19,21,25,27,29,30,32,36,42,47,52,54,55,56 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/debugger.hpp:3,7,15,17,19,21,25,26,40,42,45,46,49,50,58,61,62,70,73,74,82,85,86,93,99,102,103,110,115,118,119,126,132,135,136,143,147,150,151,157,161,164,165,173,177,180,181,188,194,197,198,205,209,212,213,220,224,227,229,239,242,243,254,257,259,269,272,273,276,280,281,284,285,287,290,293,295,296,302,303,308,309,311,325,326,328,362,364,376,384,386,395,401,402,404,417,424,466,473,478,485,488,494,503,513,521,529,531,821,889,937,950,951,953,954,955,958,960,962 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/operators.cpp:4,7,9,11,16,23,24,25,32,35,40,41,44,52,53,60,63,70,71,74,76,79,82,85,100,101,105,106,112,113,117,118,120,121,125,126,129,132,133,135,142,143,146,149,152,153,157,158,171,172,173,174,175,177,181,182,192,202,208,209,212,213,216,218,229,239,241,243,244,247,249,253,254,256,263,264,265,266,267 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/output.cpp:4,8,10,16,18,20,22,23,25,31,36,37,39,41,42,44,47,48,50,51,54,59,60,70,71,84,85,88,90,91,92,94,109,110,111,112,113,115,118,120,128,129,130,132,133,136,144,158,159,160,166,168,169,173,174,177,178,180,183,186,187,191,192,198,200,201,203,205,208,215,216,218,219,226,231,232,234,236,237,238,240,253,254,255,257,262,270,275,279,280,284,285,287,289,294,295,297,298,300,307,308,309,311,317,318,319,320 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/cssize.hpp:3,8,10,12,14,18,22,49,56,60,65,68,69,70 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/source_map.cpp:4,9,15,19,21,25,27,29,33,38,39,52,53,57,59,66,68,69,74,78,84,85,88,100,106,107,110,111,124,125,127,128,130,135,139,140,141,146,147,149,151,152,154,160,163,164,167,169,170,172,174,175,177,181,182,184,188,189,197,199,200,201,202 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/sass_functions.hpp:3,7,14,26,32,42,49 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/sass.cpp:4,9,16,18,21,26,28,29,30,31,34,38,43,45,46,48,54,55,58,60,61,64,67,68,71,74,75,77,88,89,91,102,103,108,112,113,117,121,122,125,127,128,131,133,134,135,136,138,141,154,155,156 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/listize.cpp:4,8,13,15,18,20,23,24,26,32,35,36,38,43,45,46,48,53,59,60,63,64,65,68,69,70 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/base64vlq.hpp:3,5,7,9,11,13,15,17,19,21,27,28,29 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/ast2c.hpp:3,7,9,11,13,16,30,34,36,37,38 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/ast_fwd_decl.cpp:2,4,10,15,30,31 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/context.hpp:3,8,9,12,17,19,27,30,38,51,53,59,62,64,68,72,79,86,91,94,102,103,108,112,121,128,133,137,138,139 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/fn_strings.cpp:4,10,12,14,16,19,23,27,31,33,34,38,41,48,51,58,61,63,64,67,74,75,78,83,84,90,91,94,108,110,114,118,121,126,130,131,134,135,140,141,144,151,155,157,163,164,167,173,180,181,183,185,187,190,191,198,199,203,204,208,213,215,217,223,226,227,232,233,236,240,247,248,249,252,256,263,264,265,266,267,268 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/fn_utils.cpp:4,8,10,12,25,26,28,47,48,50,52,55,56,58,64,66,67,69,79,81,82,84,89,90,92,97,98,100,108,109,110,119,120,121,129,132,136,137,144,147,153,154,155,156,157,158 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/ast_sel_cmp.cpp:4,6,8,13,16,21,22,25,32,33,35,41,42,44,47,48,50,56,57,59,65,66,69,71,78,81,83,84,85,86,90,92,99,100,102,109,110,112,119,120,124,126,132,134,135,139,141,148,149,151,158,159,161,168,169,173,175,177,178,182,184,187,189,190,192,195,197,198,204,206,214,218,220,221,222,226,228,235,236,238,245,246,248,257,258,262,264,268,270,277,278,280,287,288,290,297,298,301,303,306,307,309,312,313,315,318,319,321,324,325,327,330,331,333,336,337,340,342,345,346,348,350,351,353,356,357,359,362,363,365,374,376,377,379,389,391,392,395,396 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/fn_maps.cpp:4,6,8,12,15,27,29,30,33,37,38,41,46,48,49,52,57,59,60,63,66,73,74,77,86,88,90,91,92,93,94 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/file.cpp:4,29,32,36,39,42,47,50,53,58,77,78,81,88,102,103,107,117,119,120,123,133,136,139,141,142,145,149,150,153,157,158,162,163,166,171,174,178,179,187,188,191,194,196,197,198,202,203,209,212,215,230,231,233,234,236,238,242,245,246,249,256,259,260,264,265,268,276,277,281,287,290,303,306,309,310,317,320,323,325,326,327,331,333,335,336,345,364,370,376,382,388,389,392,393,395,400,402,403,405,416,417,421,425,426,429,432,435,438,439,444,453,488,492,499,507,508,509,512,523,528,529,530,531 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/remove_placeholders.hpp:3,6,8,10,12,17,18,22,28,32,34,35,36 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/fn_colors.hpp:3,5,7,9,17,21,52,80,81,82,83,84 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/c99func.c:4,11,14,23,25,29,31,33,38,40,41,43,46,50,52,53 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/ast_supports.cpp:5,6,8,11,19,22,26,30,33,43,45,48,50,51,54,61,63,66,67,70,79,81,83,84,87,95,97,99,100,103,110,113,114 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/sass_values.hpp:3,5,9,14,20,28,34,43,49,53,58,63,76,81 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/constants.hpp:3,6,9,20,30,62,79,86,104,107,110,117,130,133,148,160,164,169,178,196,197,198,199 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/ast_values.hpp:3,8,10,20,27,32,37,40,41,43,45,64,67,71,74,78,90,92,95,99,100,115,121,123,126,132,142,146,148,151,155,170,174,177,179,181,185,198,208,210,213,217,221,223,231,242,245,247,250,253,256,259,269,272,274,277,280,283,287,288,298,301,303,306,309,312,316,329,342,352,355,357,359,362,366,387,397,400,403,408,414,440,456,468,470,473,477,488,495,496,497 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/check_nesting.cpp:6,8,14,18,19,21,23,27,32,33,35,41,45,46,47,50,54,55,56,59,61,62,65,66,68,70,74,75,76,80,81,82,86,87,88,91,95,96,97,99,100,101,103,105,106,108,113,114,117,119,121,123,124,126,128,131,132,134,135,137,139,142,145,148,151,154,157,160,162,165,166,169,172,174,175,177,180,181,182,184,189,190,191,193,200,201,202,218,222,227,229,241,242,243,244,246,258,259,260,261,263,280,281,282,284,296,297,298,300,310,311,312,314,318,323,324,325,327,328,329,331,334,335,336,338,340,344,352,353,355,358,359,361,364,365,367,370,371,373,375,378,379,381,383,384,386,392,393 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/lexer.hpp:3,5,8,12,22,26,29,32,43,48,52,55,59,62,66,70,73,77,83,84,96,99,100,101,108,109,122,125,126,134,135,143,144,153,154,162,163,169,170,177,178,186,187,196,202,203,212,218,219,220,227,228,236,237,246,247,258,260,261,265,274,275,284,285,292,299,300,301,302,303 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/inspect.cpp:4,11,18,20,25,28,32,36,41,42,43,44,46,49,52,53,54,56,59,60,62,68,69,71,77,78,79,81,93,96,99,103,104,106,111,115,121,124,125,126,128,134,135,137,143,144,146,155,159,162,165,166,167,169,174,181,187,188,192,197,198,200,207,209,210,212,216,222,223,229,235,236,238,239,240,241,243,249,250,252,258,259,261,267,268,270,276,277,279,283,284,286,297,298,299,301,311,312,314,322,326,327,329,335,336,338,344,345,347,353,354,356,364,368,369,371,378,382,384,385,387,391,392,394,398,411,413,414,417,418,421,422,424,429,435,441,450,456,457,460,470,471,472,475,480,481,484,489,491,501,507,508,509,510,512,520,537,546,547,549,554,555,557,560,561,563,565,566,568,569,572,576,579,582,585,587,588,591,598,604,605,606,609,613,614,617,618,625,626,628,631,635,638,643,651,657,658,674,675,680,681,685,692,693,696,697,707,708,710,711,712,714,717,718,720,723,724,726,733,734,735,737,739,740,742,747,748,749,751,753,754,756,758,759,761,762,766,775,776,780,781,783,789,790,792,798,799,801,803,804,806,812,815,819,820,821,823,826,833,835,836,837,839,846,848,849,850,852,857,858,860,863,864,867,872,875,876,877,879,886,887,889,890,892,896,901,907,910,911,912,914,922,923,925,926,928,930,931,933,935,936,938,940,941,942,944,946,947,949,951,952,954,956,957,959,967,968,973,975,976,978,979,984,992,995,1000,1004,1005,1006,1007,1009,1010,1014,1016,1017,1018,1025,1028,1029,1031,1033,1044,1045,1046,1053,1056,1057,1058,1060,1065,1066,1074,1075,1078,1079,1080,1082,1087,1088,1090,1093,1097,1103,1104,1105,1106,1108,1114,1121,1122,1123,1124,1125 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/fn_selectors.hpp:3,5,7,9,12,21,30,31,32,33,34 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/color_maps.hpp:1,4,7,9,11,161,162,313,314,320,321,322 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/fn_numbers.hpp:3,5,7,9,12,26,40,41,42,43,44 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/plugins.cpp:4,9,18,20,23,26,29,32,33,34,39,45,49,54,55,56,59,60,64,66,69,74,78,81,85,88,92,95,97,102,103,105,109,110,112,113,114,116,117,120,122,124,125,136,139,141,152,154,158,159,160,162,166,167,169,180,182,185,186,187,188 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/mapping.hpp:3,6,8,12,16,17,18 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/output.hpp:3,6,10,13,17,21,25,28,40,42,44,45,46 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/operators.hpp:3,6,8,10,25,27,28,29 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/cssize.cpp:4,8,11,13,19,21,23,24,26,33,34,36,41,42,44,46,54,55,56,65,69,73,75,78,79,81,82,84,86,88,90,91,100,111,112,113,114,117,121,122,128,129,131,132,134,136,141,143,144,146,157,162,166,169,170,174,178,179,181,185,187,190,191,193,194,201,202,206,208,210,211,213,215,216,218,220,222,223,225,227,228,230,235,237,239,240,242,245,248,250,256,258,260,261,263,268,269,271,277,280,281,283,285,286,288,289,291,297,306,309,310,312,322,323,330,331,333,335,343,350,352,355,356,358,360,368,375,377,379,380,382,384,385,387,395,396,399,400,402,403,405,407,411,413,416,418,422,423,425,426,428,432,436,440,443,448,450,452,453,455,460,467,468,470,473,474,477,484,489,492,495,496,499,500,501,502,504,505,507,513,514,517,518,519,520,521 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/ast_def_macros.hpp:3,12,15,17,21,23,25,28,30,33,37,45,53,61,69,71,75,80,85,87,91,96,101,103,107,111,113,125,127,137,139 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/sass2scss.cpp:6,11,20,31,34,37,38,45,48,54,57,61,62,65,69,70,74,75,82,87,97,112,129,148,151,154,155,156,158,160,161,163,165,166,168,170,171,175,176,178,180,181,184,187,190,197,199,201,202,203,204,205,207,211,212,218,220,221,224,227,229,231,233,235,237,239,242,244,247,249,251,253,256,259,260,262,265,268,271,274,275,276,279,280,281,282,284,286,287,289,293,294,302,305,306,309,312,314,317,319,321,323,326,329,331,332,334,337,340,343,346,347,348,351,352,353,354,356,360,363,364,366,369,376,378,382,383,386,392,396,400,405,408,413,416,420,422,425,427,429,432,433,436,439,443,444,447,450,451,453,456,457,460,463,465,466,469,472,475,478,481,484,485,488,491,495,496,499,502,505,510,513,516,522,523,524,527,528,529,532,541,542,545,551,552,555,556,564,572,575,582,587,588,589,590,591,596,597,598,599,613,617,618,619,622,633,636,639,642,645,652,654,655,657,658,665,672,676,677,678,679,682,685,688,692,693,694,697,700,703,710,711,714,723,724,725,728,733,735,739,742,745,746,747,756,759,760,763,766,767,770,774,778,779,784,785,786,787,789,790,792,795,796,798,802,804,810,813,830,831,832,833,836,837,842,855,859,866,874,875,877,878,880,883,884,886,888,889,893,894,895 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/units.hpp:3,8,10,12,21,23,31,37,41,45,50,53,55,90,96,107,108,109 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/fn_miscs.hpp:3,5,7,9,22,35,36,37,38,39 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/stylesheet.hpp:3,7,11,13,18,22,25,28,32,36,40,43,45,48,51,53,54,55,56 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/memory.hpp:3,5,11 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/extension.hpp:3,7,12,14,16,18,21,25,29,32,36,38,42,53,54,55,65,66,67,77,78,82,84,86,87,88 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/operation.hpp:3,7,10,13,16,18,29,44,124,126,210,214,217,218,220,221,222 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/to_value.cpp:4,7,9,12,14,15,18,20,21,24,26,27,30,32,33,36,38,39,42,44,45,48,50,51,54,56,57,60,69,71,72,75,77,78,81,83,84,87,89,90,93,96,97,100,104,105,108,112,113 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/source.hpp:3,8,10,19,24,26,31,34,35,38,39,42,43,45,51,56,58,63,66,67,70,71,74,75,77,78,84,87,92,93,94 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/prelexer.cpp:4,12,13,17,19,20,22,27,57,58,60,77,107,108,110,142,143,146,176,177,179,211,212,220,238,239,241,264,265,268,278,279,282,290,294,298,300,304,307,311,314,315,318,331,332,335,346,347,350,361,362,365,371,372,375,382,383,385,392,393,395,402,403,406,418,419,422,433,434,437,450,451,453,455,456,467,468,471,506,507,511,512,535,536,559,560,568,569,579,580,596,597,599,600,607,617,618,622,623,642,704,705,733,734,746,747,764,765,772,773,786,787,790,791,794,795,798,799,802,803,806,807,810,811,814,815,818,819,822,823,826,827,830,831,834,835,838,839,840,843,844,847,852,853,856,857,860,861,864,865,868,869,872,873,876,877,880,881,887,888,891,892,895,896,899,900,905,908,909,917,918,929,930,945,946,961,962,965,968,971,975,979,984,988,990,993,996,1002,1015,1019,1030,1033,1036,1037,1044,1049,1054,1059,1060,1066,1082,1083,1109,1115,1121,1127,1131,1163,1164,1167,1168,1171,1174,1178,1182,1185,1197,1200,1203,1207,1211,1212,1227,1228,1232,1235,1238,1241,1244,1247,1250,1253,1256,1259,1262,1265,1268,1269,1306,1309,1312,1313,1318,1325,1343,1344,1353,1354,1360,1372,1375,1378,1381,1385,1387,1390,1392,1401,1404,1405,1414,1415,1421,1422,1425,1426,1438,1439,1454,1461,1462,1469,1478,1479,1482,1483,1501,1502,1509,1510,1523,1524,1537,1538,1575,1576,1596,1597,1613,1614,1630,1631,1640,1641,1727,1728,1731,1734,1737,1738,1742,1746,1747,1777,1778,1779,1780 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/util.hpp:3,7,10,16,18,20,24,25,31,32,45,49,52,54,60,62,63,68,69,72,73,78,79,86,87,90,91,93,102,103,104 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/utf8_string.cpp:4,9,11,14,19,23,24,27,28,34,35,46,47,56,60,63,67,71,72,73,75,78,81,88,89,92,99,100,102,103,104 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/ast_selectors.hpp:3,8,10,14,19,23,26,30,34,37,60,72,81,117,120,125,128,132,134,138,142,145,161,178,192,208,227,243,245,247,251,255,258,267,268,281,286,291,294,296,298,300,303,308,313,324,325,328,331,333,336,339,345,351,357,361,363,366,369,372,376,379,384,389,394,397,400,405,410,419,423,426,427,430,434,436,441,444,447,449,451,455,457,462,475,477,482,487,489,492,499,504,519,520,521 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/b64/cencode.h:3,7,10,12,15,17,22,24,26,28,30,32 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/b64/encode.h:4,10,12,14,16,18,19,21,24,27,29,30,32,34,35,37,39,40,42,44,45,47,55,57,63,65,70,73,75,76,77,79 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/backtrace.cpp:2,4,6,9,14,16,19,22,41,42,43,44,47,48,49 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/json.cpp:4,11,14,23,28,30,34,40,48,53,56,62,63,65,67,72,74,80,81,87,89,92,96,102,103,105,109,110,116,118,120,121,123,127,128,130,132,133,144,166,168,178,184,188,194,200,204,212,216,217,218,221,223,228,229,231,232,241,243,245,268,269,270,280,282,284,307,308,309,317,323,324,325,332,334,336,340,341,350,353,362,364,369,373,375,378,382,387,388,390,391,393,395,396,398,401,404,408,409,411,412,414,417,423,427,428,430,431,433,436,443,448,450,452,453,455,456,457,459,461,465,469,471,472,474,477,480,485,486,488,489,491,493,496,500,502,503,505,509,510,512,518,519,521,523,524,526,530,531,533,537,538,540,542,543,545,549,550,552,554,555,557,559,560,562,567,573,574,575,577,582,588,589,590,592,596,597,598,600,604,606,607,608,610,613,615,616,618,622,624,625,626,628,632,635,636,637,639,642,648,653,655,659,660,661,662,664,666,674,676,683,685,692,694,702,704,705,710,712,717,719,727,729,730,731,732,734,738,742,746,747,752,755,759,760,764,765,771,775,776,778,783,787,791,792,797,801,805,808,812,813,817,818,824,831,832,834,840,843,850,851,854,880,883,886,898,899,902,906,913,918,921,922,933,934,936,941,946,947,950,951,954,955,967,969,973,983,984,993,994,1005,1006,1009,1012,1013,1015,1020,1021,1023,1046,1047,1048,1050,1073,1074,1075,1077,1079,1085,1087,1088,1090,1093,1097,1098,1104,1107,1111,1112,1114,1116,1124,1126,1127,1129,1132,1136,1137,1145,1148,1152,1153,1155,1159,1164,1166,1168,1175,1179,1212,1215,1233,1238,1240,1256,1261,1262,1264,1265,1266,1274,1276,1278,1279,1281,1290,1295,1296,1298,1300,1301,1303,1305,1306,1308,1310,1314,1317,1318,1324,1330,1341,1344,1345,1350,1351,1357,1359,1364,1366,1367,1369,1375,1378,1381,1393,1402,1405,1413,1418,1423,1426,1427,1430,1431,1432,1434,1436 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/parser.cpp:4,8,20,21,25,26,41,46,47,54,55,57,61,62,64,67,68,71,72,75,78,84,85,88,93,94,99,102,105,106,108,109,110,115,116,119,123,127,129,132,133,138,141,143,145,146,151,153,154,158,159,162,166,170,172,174,178,181,184,185,189,191,193,197,199,201,212,219,220,229,230,231,242,250,251,252,253,259,261,262,271,274,276,279,284,287,301,302,305,307,310,318,322,326,329,333,336,339,343,346,350,351,355,360,361,362,364,365,367,380,381,383,392,395,396,398,399,401,404,415,418,420,421,423,432,435,436,438,439,441,444,448,449,458,469,471,473,474,476,482,489,495,497,498,501,513,519,531,532,537,547,559,560,567,581,593,595,596,598,601,605,607,610,612,614,622,623,626,637,642,643,645,649,652,655,657,658,660,664,667,670,673,676,679,682,685,688,691,692,694,701,703,707,708,711,715,721,728,729,733,742,746,747,751,752,754,761,762,767,770,771,772,773,774,776,779,782,783,784,788,789,790,792,795,796,798,800,801,803,805,806,808,814,818,822,824,828,831,834,835,838,842,845,846,849,851,857,858,859,867,872,875,883,887,896,897,903,904,905,911,912,913,915,919,923,927,928,930,933,935,939,941,944,946,949,950,954,956,957,959,964,967,968,970,980,983,984,989,991,997,1000,1001,1006,1009,1010,1013,1018,1021,1022,1031,1032,1037,1039,1045,1048,1050,1053,1060,1063,1070,1073,1075,1078,1095,1097,1100,1110,1118,1120,1123,1140,1157,1167,1169,1176,1191,1197,1202,1204,1209,1210,1216,1217,1220,1237,1240,1246,1248,1249,1253,1263,1270,1277,1280,1283,1286,1293,1294,1296,1299,1302,1307,1312,1317,1322,1325,1326,1327,1329,1335,1336,1338,1347,1348,1350,1359,1360,1362,1369,1380,1381,1383,1387,1401,1414,1426,1439,1443,1444,1446,1455,1456,1457,1460,1463,1466,1468,1471,1475,1478,1482,1485,1489,1492,1495,1498,1501,1502,1505,1509,1512,1515,1520,1523,1526,1529,1531,1534,1535,1539,1544,1549,1550,1560,1565,1575,1579,1580,1585,1587,1588,1590,1591,1593,1609,1618,1631,1637,1638,1639,1645,1646,1649,1650,1652,1661,1663,1664,1666,1668,1669,1671,1679,1680,1687,1690,1700,1704,1705,1709,1711,1712,1714,1715,1717,1724,1732,1735,1736,1738,1741,1744,1745,1755,1759,1762,1768,1774,1779,1780,1785,1794,1796,1801,1802,1807,1811,1815,1819,1823,1826,1830,1833,1835,1839,1842,1843,1847,1854,1855,1865,1870,1881,1885,1886,1892,1894,1895,1897,1898,1901,1914,1919,1920,1922,1926,1927,1930,1934,1935,1939,1940,1950,1951,1952,1954,1956,1960,1961,1967,1971,1975,1976,1978,1979,1981,1984,1987,1991,1992,1994,1998,2000,2001,2003,2006,2008,2009,2011,2018,2024,2027,2030,2031,2033,2049,2050,2053,2057,2062,2065,2068,2072,2075,2076,2078,2088,2094,2095,2098,2108,2116,2117,2118,2120,2125,2128,2129,2131,2134,2136,2137,2139,2142,2145,2148,2151,2152,2155,2158,2162,2166,2167,2170,2173,2174,2175,2176,2177,2178,2180,2183,2189,2193,2194,2196,2198,2202,2203,2204,2206,2207,2208,2211,2219,2220,2222,2229,2230,2233,2238,2242,2249,2252,2254,2256,2258,2259,2261,2265,2268,2272,2277,2280,2282,2283,2287,2296,2297,2301,2308,2309,2311,2315,2316,2318,2321,2326,2329,2332,2334,2335,2337,2339,2342,2344,2345,2349,2356,2364,2365,2367,2370,2376,2377,2379,2383,2386,2387,2389,2397,2401,2406,2411,2412,2414,2416,2419,2420,2425,2428,2430,2437,2438,2440,2447,2449,2450,2452,2455,2457,2458,2460,2463,2464,2466,2471,2472,2474,2522,2524,2525,2527,2539,2540,2542,2543,2553,2554,2557,2558,2560,2562,2564,2565,2567,2574,2576,2577,2579,2586,2588,2589,2591,2598,2600,2601,2603,2608,2609,2611,2630,2635,2638,2640,2641,2653,2654,2656,2659,2660,2662,2666,2674,2677,2679,2685,2733,2735,2744,2745,2748,2750,2752,2804,2807,2808,2810,2815,2817,2818,2819,2821,2824,2826,2827,2829,2847,2849,2850,2851,2857,2858,2868,2873,2876,2880,2881,2886,2888,2889,2891,2894,2895,2898,2904,2908,2913,2914,2918,2928,2929,2935,2938,2939,2948,2952,2954,2963,2964,2965 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/util_string.cpp:2,5,8,24,28,29,33,34,35,39,40,41,46,47,53,59,61,63,75,78,79,82,83,88,89,96,99,101,102,109,110,111,118,119,120,121,123,124 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/environment.hpp:3,7,12,14,17,26,33,38,42,46,52,54,56,58,60,62,66,68,75,77,79,83,85,90,96,100,104,108,111,115,117,121,122,123 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/error_handling.cpp:4,9,11,13,15,20,24,25,28,32,33,36,39,40,43,47,48,51,53,54,58,62,65,67,68,71,73,74,77,79,80,83,85,86,88,90,91,93,95,96,99,104,105,108,110,111,114,120,121,124,126,127,130,133,134,137,138,139,140,144,145,146,147,151,152,153,154,155,156,157,158,160,162,163,165,170,173,174,176,178,179,181,186,190,191,193,198,206,207,209,214,218,219,222,225,226,228,231,232,233 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/sass_context.cpp:5,8,10,15,19,20,22,37,38,42,53,56,60,63,65,71,75,76,89,94,109,110,130,135,138,141,144,147,149,150,156,157,159,160,169,171,175,179,184,190,194,197,198,201,204,205,206,207,208,211,223,224,236,242,243,246,254,255,256,263,264,265,272,273,274,285,291,296,299,300,303,306,307,308,311,312,315,320,323,325,327,328,330,334,335,337,342,343,345,359,361,362,364,378,380,381,383,387,388,390,394,395,397,405,409,410,412,419,423,424,426,438,439,441,461,462,465,479,480,483,499,500,511,512,532,533,537,563,564,566,569,576,577,579,581,582,585,588,591,597,598,602,609,622,626,647,660,670,673,674,685,686,687,688,691,696,697,700,704,705,708,713,714,717,721,722,725,726,737,738,739,740,741 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/eval.cpp:4,11,35,37,45,48,50,52,54,55,57,59,60,62,64,65,67,69,70,72,74,75,77,79,80,82,87,89,90,92,101,107,108,111,112,115,116,126,127,130,132,134,136,142,143,144,147,150,151,154,156,157,159,166,170,173,174,178,184,189,198,215,225,226,229,230,234,243,247,251,254,255,258,262,271,272,275,276,280,295,296,304,305,306,309,310,313,314,316,327,329,332,333,335,337,338,340,345,348,358,364,374,375,376,385,386,388,393,396,406,412,422,423,424,429,430,432,437,440,450,456,466,467,468,474,478,479,480,482,489,495,499,500,503,515,520,521,523,525,531,532,542,543,548,549,552,553,555,556,560,566,572,573,577,580,581,583,588,592,593,599,600,617,618,620,623,624,636,637,639,642,643,644,661,662,664,667,668,678,679,681,684,685,686,687,689,699,702,703,705,714,716,717,718,726,734,737,738,743,746,752,754,759,761,770,771,778,779,780,781,785,796,797,798,809,810,812,815,816,819,830,835,840,845,860,864,867,869,875,876,877,880,881,883,887,888,894,895,896,898,899,900,902,908,915,919,922,928,938,939,946,947,951,954,955,957,963,964,971,972,975,978,985,986,994,1003,1004,1005,1009,1012,1014,1016,1026,1032,1033,1038,1040,1044,1057,1061,1064,1067,1070,1071,1082,1083,1097,1106,1118,1120,1126,1127,1132,1137,1138,1140,1155,1156,1158,1160,1161,1163,1165,1166,1168,1170,1171,1173,1175,1176,1178,1180,1185,1190,1197,1198,1201,1207,1208,1209,1211,1216,1217,1227,1238,1240,1241,1256,1257,1258,1260,1261,1262,1264,1274,1275,1276,1277,1278,1290,1291,1296,1305,1306,1307,1309,1311,1312,1314,1320,1321,1323,1332,1333,1335,1341,1342,1344,1352,1353,1355,1361,1362,1364,1374,1375,1377,1388,1390,1391,1393,1400,1408,1414,1415,1417,1419,1420,1422,1426,1431,1440,1441,1448,1449,1451,1459,1460,1461,1465,1469,1475,1484,1487,1488,1489,1494,1496,1498,1499,1501,1503,1504,1506,1515,1521,1522,1524,1529,1530,1531,1533,1535,1536,1538,1542,1543 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/utf8.h:2,10,17,26,27,30,33 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/ast.hpp:3,7,10,15,21,23,36,44,47,49,51,53,66,71,72,74,87,92,93,99,100,105,109,115,121,158,161,176,177,178,182,186,188,190,194,196,198,200,201,203,231,237,238,241,242,248,256,263,266,269,270,273,276,277,278,281,284,285,293,294,298,304,305,315,316,318,319,324,325,327,331,332,334,335,340,341,348,352,363,378,382,388,391,393,395,402,404,408,411,412,414,417,419,425,426,429,430,433,437,440,445,449,496,512,525,540,553,565,582,595,611,625,641,654,665,676,687,700,713,727,739,750,761,798,811,822,841,859,879,880,887,893,903,910,914,915,919,923,927,931,934,937,943,944,951,952,956,957,961,965,980,994,1008,1021,1034,1050,1051,1052,1056,1058,1061,1063 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/values.cpp:4,7,9,11,14,16,19,21,28,29,31,38,40,42,49,51,53,55,57,60,62,64,66,68,70,71,73,74,77,101,112,115,122,124,136,138,139,140 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/extender.hpp:3,7,14,16,20,27,33,39,46,53,60,69,71,73,75,77,82,88,94,100,106,118,132,140,142,146,152,157,169,178,191,199,213,220,229,231,241,251,260,272,280,290,297,305,317,326,336,344,353,361,370,375,380,388,394,396,397,398 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/emitter.hpp:3,7,11,14,16,20,35,44,59,83,96,98,99,100 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/cencode.c:3,7,9,11,15,16,18,22,23,25,31,33,35,37,40,44,50,53,57,63,66,70,76,78,79,82,83,85,87,89,101,103,105,106 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/fn_lists.cpp:4,9,11,13,17,20,31,33,34,37,40,45,53,54,55,60,61,64,74,81,87,93,98,99,100,103,111,114,121,123,124,127,134,137,140,142,143,146,160,164,168,171,181,186,187,190,196,201,204,211,219,222,224,225,228,240,246,247,249,256,258,260,261,264,269,273,274,277,281,282,283,284,285 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/position.cpp:4,7,9,10,15,18,20,21,24,26,27,30,33,37,40,41,45,62,67,68,70,72,73,77,81,82,84,86,87,89,91,92,94,96,97,99,101,102,104,106,107,110,113,116,119,120,123,126,128,131,132,134,138,139,141,143,144,146,148,149,151,153,154,156,158,159,161,163,164,165 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/bind.hpp:3,8,10,12,13,14 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/eval_selectors.cpp:7,8,10,12,17,18,28,29,32,35,36,37,39,40,42,44,45,47,53,59,60,61,62,64,65,67,72,74,75 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/expand.cpp:4,7,17,19,22,37,47,48,54,55,57,58,60,64,65,67,70,71,73,76,77,79,81,82,84,86,87,89,94,99,100,102,107,112,113,115,121,122,124,126,127,129,135,136,138,140,141,144,164,165,167,169,177,183,184,185,187,188,195,196,197,198,201,207,221,224,225,228,230,231,233,240,241,245,252,253,254,256,257,259,271,274,279,280,281,283,286,289,292,294,301,302,304,321,322,324,333,343,344,345,355,356,358,367,373,374,377,378,381,382,392,393,396,398,400,402,408,409,410,413,416,417,420,422,423,425,430,433,437,438,440,446,454,459,467,468,470,474,475,477,481,482,484,488,489,491,496,502,503,505,512,516,520,521,525,531,536,545,561,570,571,575,576,580,587,591,595,598,604,609,618,620,621,626,642,643,650,651,652,654,655,659,660,662,672,676,677,679,682,683,685,686,691,694,696,698,701,702,704,706,714,717,719,724,725,726,730,731,732,735,736,737,738,740,741,742,744,749,761,762,766,767,769,770,773,774,776,781,785,788,801,816,817,819,822,826,831,834,837,841,844,845,847,853,858,861,862,865,871,873,874,875 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/parser_selectors.cpp:4,6,8,11,13,14,16,19,21,23,25,28,32,36,40,44,47,48,49,51,54,56,58,59,60,62,63,68,71,72,75,77,80,85,87,89,96,98,100,103,104,107,109,110,115,118,122,124,129,130,133,139,146,152,155,157,158,161,163,174,175,177,180,181,184,186,187,188,189 ./Vendor/bundle/ruby/2.7.0/gems/sassc-2.4.0/ext/libsass/src/c2ast.cpp:8,10,12,31,37,47,60,62,63,64 ./Vendor/bundle/ruby/2.7.0/gems/sqlite3-1.4.2/ext/sqlite3/sqlite3.c:2,5,7,19,24,27,29,39,49,54,55,56,57,61,62,64,66,67,69,75,76,81,83,84,86,89,91,94,128,129,131,139,144,149,161 ./Vendor/bundle/ruby/2.7.0/gems/sqlite3-1.4.2/ext/sqlite3/database.c:3,7,9,11,14,17,18,20,23,24,27,31,32,34,36,40,42,51,58,60,62,63,69,73,76,78,80,82,83,89,92,94,96,97,104,108,110,111,113,117,118,128,131,134,136,138,140,142,144,145,147,151,153,155,156,172,176,179,181,183,185,188,190,192,193,200,204,206,207,209,229,235,236,237,239,250,254,256,277,282,283,284,286,291,296,297,298,300,302,303,306,308,310,317,321,324,326,337,339,341,343,344,351,353,354,360,364,366,368,369,376,380,382,383,390,394,396,397,404,407,409,410,418,422,424,425,433,442,446,448,449,461,464,467,471,473,475,477,478,490,494,496,498,499,506,510,512,514,515,517,523,525,529,532,536,537,539,541,542,551,555,562,565,567,568,577,584,587,591,592,594,596,603,608,615,616,618,620,622,624,626,630,632,633,639,642,645,647,650,651,653,654,661,665,667,668,670,673,679,680,681,683,685,686,688,691,697,698,699,701,703,704,705,715,721,724,729,730,732,736,737,739,740,747,752,754,757,758,760,763,765,774,776,778,780,781,783,788,815,819,823,825,827 ./Vendor/bundle/ruby/2.7.0/gems/sqlite3-1.4.2/ext/sqlite3/aggregator.c:3,12,22,29,33,36,38,39,43,48,49,56,61,64,65,67,71,76,78,80,81,84,85,87,88,94,99,102,103,106,107,111,112,114,115,118,125,128,129,133,138,139,144,145,147,148,152,156,162,163,164,170,171,173,174,207,213,217,218,224,225,233,234,237,239,243,254,258,259,261,263,264,267,273 ./Vendor/bundle/ruby/2.7.0/gems/sqlite3-1.4.2/ext/sqlite3/exception.c:2,4,6,93,94,98 ./Vendor/bundle/ruby/2.7.0/gems/sqlite3-1.4.2/ext/sqlite3/statement.h:3,5,10,13,15 ./Vendor/bundle/ruby/2.7.0/gems/sqlite3-1.4.2/ext/sqlite3/backup.h:3,5,9,12,14 ./Vendor/bundle/ruby/2.7.0/gems/sqlite3-1.4.2/ext/sqlite3/database.h:3,5,9,12,16 ./Vendor/bundle/ruby/2.7.0/gems/sqlite3-1.4.2/ext/sqlite3/sqlite3_ruby.h:3,5,14,16,23,24,26,30,34,37,42,44 ./Vendor/bundle/ruby/2.7.0/gems/sqlite3-1.4.2/ext/sqlite3/aggregator.h:3,5,8,11 ./Vendor/bundle/ruby/2.7.0/gems/sqlite3-1.4.2/ext/sqlite3/exception.h:3,5,7 ./Vendor/bundle/ruby/2.7.0/gems/sqlite3-1.4.2/ext/sqlite3/backup.c:2,4,8,10,12,15,16,18,21,22,60,64,68,73,78,81,82,84,85,96,99,104,105,111,113,119,120,129,131,135,136,145,147,151,152,154,159,166,167 ./Vendor/bundle/ruby/2.7.0/gems/sqlite3-1.4.2/ext/sqlite3/statement.c:2,6,8,10,13,14,16,20,22,23,32,37,39,42,45,48,49,61,63,68,70,71,78,80,82,84,87,89,90,96,99,101,103,104,106,112,114,116,118,119,123,124,126,135,136,139,142,153,162,165,171,178,179,180,190,191,193,194,204,208,211,221,222,225,239,240,252,260,261,268,269,283,284,286,288,289,296,298,301,303,305,307,308,315,317,320,322,324,326,327,333,336,339,340,346,350,352,353,359,362,365,367,370,371,377,380,383,385,388,389,395,399,401,402,404,410,414,417,418,420,422,424,438,442 ./Vendor/bundle/ruby/2.7.0/gems/xcpretty-0.3.0/spec/fixtures/NSStringTests.m:8,11,13,15,17,20,22,24,26,30,34,38,42,44,48,53,55,59,61,62,63 ./Vendor/bundle/ruby/2.7.0/gems/redcarpet-3.5.0/ext/redcarpet/buffer.c:23,26,28,33,40,43,46,50,53,54,56,57,61,64,66,69,72,76,80,84,85,86,90,93,98,100,101,105,107,110,114,115,117,118,122,125,127,130,134,143,144,148,152,153,156,158,159,163,165,168,171,172,176,178,179,180,184,186,189,192,193,197,200,203 ./Vendor/bundle/ruby/2.7.0/gems/redcarpet-3.5.0/ext/redcarpet/autolink.c:22,25,30,34,37,42,44,47,52,53,55,56,59,62,67,68,72,75,78,83,85,86,89,91,98,99,104,124,130,132,133,136,137,139,140,143,145,148,152,153,164,165,166,175,177,180,183,185,188,191,193,196,199,201,202,211,214,217,220,223,225,226,229,232,235,242,243,246,248,251,254,256,257,266,268,271,274,277,279,284,287,291,293,296,303,306,308 ./Vendor/bundle/ruby/2.7.0/gems/redcarpet-3.5.0/ext/redcarpet/html.h:22,25,29,33,40,42,46,60,66,69,72,75,78,80,82 ./Vendor/bundle/ruby/2.7.0/gems/redcarpet-3.5.0/ext/redcarpet/rc_markdown.c:22,24,28,30,32,34,36,42,45,48,51,54,57,60,63,66,69,72,75,78,80,81,84,86,87,89,92,95,98,101,104,113,115,120,121,125,128,130,131,133,137,139,142,147,151,154,161,164,166,169,171,172,175,177,181,183 ./Vendor/bundle/ruby/2.7.0/gems/redcarpet-3.5.0/ext/redcarpet/houdini_href_e.c:22,26,28,30,74,77,81,84,89,92,96,104,114,120,121,123,124 ./Vendor/bundle/ruby/2.7.0/gems/redcarpet-3.5.0/ext/redcarpet/stack.c:22,25,28,30,33,37,40,43,46,48,49,52,55,57,61,62,65,69,72,74,75,78,81,84 ./Vendor/bundle/ruby/2.7.0/gems/redcarpet-3.5.0/ext/redcarpet/html_blocks.h:5,32,34,38,59,67,69,73,76,78,80,82,94,96,125,127,134,136,137,142,144,151,153,213,215,217,219,221,224,225,227 ./Vendor/bundle/ruby/2.7.0/gems/redcarpet-3.5.0/ext/redcarpet/houdini_html_e.c:22,26,28,30,60,70,73,75,77,82,85,89,95,97,98,99,102,104 ./Vendor/bundle/ruby/2.7.0/gems/redcarpet-3.5.0/ext/redcarpet/markdown.c:23,26,31,35,37,40,42,47,51,55,58,61,65,68,71,77,84,92,106,122,138,143,153,157,160,164,172,173,175,176,179,181,182,185,191,194,197,200,201,202,205,208,211,213,214,219,221,224,227,230,231,234,237,239,243,245,246,248,249,252,254,258,265,266,267,268,271,275,277,279,280,283,288,294,296,298,299,302,305,307,312,313,315,316,319,322,323,326,329,336,337,338,344,346,347,350,361,363,364,368,373,375,380,384,389,392,395,396,397,399,400,404,406,409,413,416,419,423,428,429,430,434,435,439,442,449,450,455,456,461,462,466,470,474,479,480,485,488,491,499,500,501,502,506,508,512,515,519,520,523,527,531,532,534,542,543,545,550,555,556,560,563,567,570,576,577,582,583,586,588,589,590,592,593,598,602,605,611,613,617,618,621,626,629,630,631,633,634,638,642,647,651,658,661,663,665,666,671,674,679,683,687,692,698,704,705,707,708,712,715,719,720,726,728,729,733,735,736,740,742,743,745,746,747,751,754,758,760,761,762,766,768,772,778,779,782,787,791,800,801,803,804,808,810,814,820,821,824,829,833,842,843,845,846,850,853,857,862,866,867,869,870,875,878,881,884,889,894,896,898,899,903,908,917,920,921,924,925,928,931,934,936,941,950,952,953,956,957,960,963,966,968,972,973,976,977,980,983,986,988,992,993,996,997,1001,1011,1015,1020,1023,1026,1031,1032,1033,1036,1039,1044,1047,1050,1052,1059,1060,1064,1066,1067,1072,1077,1080,1082,1086,1091,1097,1098,1101,1108,1114,1115,1117,1122,1127,1128,1129,1133,1137,1142,1143,1147,1148,1150,1151,1156,1163,1169,1175,1176,1182,1186,1187,1191,1196,1197,1202,1207,1213,1214,1220,1221,1226,1230,1233,1234,1246,1247,1248,1252,1253,1258,1262,1263,1268,1269,1272,1275,1278,1281,1284,1287,1292,1295,1296,1299,1304,1306,1307,1311,1315,1317,1321,1323,1324,1328,1331,1337,1343,1349,1351,1352,1354,1355,1360,1363,1369,1373,1375,1379,1380,1383,1385,1386,1390,1393,1397,1400,1402,1405,1408,1409,1412,1417,1418,1421,1426,1427,1428,1432,1433,1437,1439,1440,1442,1443,1447,1450,1453,1456,1459,1460,1462,1463,1467,1469,1475,1481,1483,1484,1487,1489,1492,1495,1497,1498,1502,1507,1511,1513,1514,1516,1517,1521,1524,1526,1527,1531,1533,1537,1540,1543,1546,1549,1551,1552,1556,1558,1562,1567,1570,1572,1573,1574,1578,1579,1583,1587,1592,1594,1597,1603,1611,1613,1614,1620,1621,1624,1628,1632,1635,1638,1641,1643,1649,1650,1665,1666,1672,1673,1679,1680,1681,1683,1684,1688,1697,1702,1705,1709,1713,1716,1720,1722,1723,1726,1729,1731,1732,1734,1735,1739,1743,1746,1748,1752,1757,1758,1760,1767,1769,1770,1773,1776,1779,1780,1783,1786,1788,1793,1799,1806,1808,1809,1812,1814,1817,1820,1821,1826,1830,1834,1838,1841,1846,1850,1854,1858,1860,1863,1869,1870,1875,1877,1881,1882,1888,1889,1896,1897,1902,1905,1908,1913,1917,1918,1920,1924,1925,1929,1935,1943,1946,1947,1951,1955,1956,1957,1961,1964,1966,1970,1973,1974,1979,1980,1984,1987,1990,1992,1995,1998,2001,2004,2006,2009,2011,2012,2014,2015,2019,2022,2024,2028,2029,2033,2037,2040,2042,2048,2049,2053,2054,2064,2066,2072,2080,2083,2085,2086,2093,2097,2103,2105,2106,2116,2119,2123,2124,2126,2127,2128,2132,2136,2140,2144,2147,2150,2154,2157,2159,2162,2168,2169,2170,2176,2185,2186,2187,2188,2191,2192,2196,2201,2202,2205,2210,2212,2213,2223,2226,2229,2231,2234,2238,2240,2243,2245,2248,2250,2253,2256,2259,2260,2264,2265,2267,2269,2270,2279,2282,2287,2290,2292,2295,2298,2301,2304,2309,2313,2316,2319,2323,2324,2327,2328,2332,2333,2336,2339,2342,2344,2345,2348,2356,2358,2359,2366,2368,2371,2374,2377,2380,2384,2386,2390,2394,2395,2404,2406,2407,2410,2411,2416,2417,2421,2425,2429,2433,2436,2440,2443,2447,2450,2452,2453,2457,2461,2464,2467,2470,2473,2476,2477,2478,2479,2480,2484,2488,2494,2496,2504,2515,2520,2523,2525,2529,2536,2539,2540,2545,2552,2555,2556,2558,2567,2568,2570,2571,2574,2583,2585,2586,2588,2589,2593,2600,2608,2617,2628,2632,2634,2637,2640,2651,2656,2677,2680,2684,2687,2691,2694,2698,2699,2700,2702,2703,2705,2707,2710,2713,2714,2717,2720,2724,2726,2727,2728,2732,2739,2741,2743,2747,2749,2752,2754,2758,2765,2766,2769,2772,2775,2779,2784,2785,2788,2794,2796,2797,2800,2803,2807,2811,2814,2817,2820,2825,2826,2829,2834,2838,2847,2851,2857,2858,2860,2861,2862,2865,2869,2874,2876,2877,2881,2884,2887,2894,2895,2898,2899,2902,2904,2907,2910,2913,2915 ./Vendor/bundle/ruby/2.7.0/gems/redcarpet-3.5.0/ext/redcarpet/autolink.h:22,25,27,31,35,38,42,46,50,52,54 ./Vendor/bundle/ruby/2.7.0/gems/redcarpet-3.5.0/ext/redcarpet/buffer.h:23,26,30,34,39,44,52,56,59,62,65,68,71,74,77,80,83,85,87 ./Vendor/bundle/ruby/2.7.0/gems/redcarpet-3.5.0/ext/redcarpet/redcarpet.h:22,25,29,31,34,36,38,46,51 ./Vendor/bundle/ruby/2.7.0/gems/redcarpet-3.5.0/ext/redcarpet/html_smartypants.c:22,25,30,34,39,50,53,66,85,88,90,91,94,96,97,103,106,111,112,113,115,116,120,122,125,128,133,134,142,146,152,153,156,161,162,168,169,173,180,181,182,183,186,187,191,193,194,198,202,206,207,211,212,216,217,218,221,222,226,230,231,235,236,239,240,244,248,249,253,254,257,260,261,265,269,270,274,275,278,279,283,287,288,291,292,296,302,303,304,310,311,312,318,319,320,321,324,325,329,332,334,335,338,343,346,349,353,354,359,362,365,367,368,371,372,376,378,379,381,388,389,391,392,395,398,408,412,413,414,444,447,450,453,455,459,463,466,470,471,472 ./Vendor/bundle/ruby/2.7.0/gems/redcarpet-3.5.0/ext/redcarpet/stack.h:22,25,27,31,37,41,43,45,47 ./Vendor/bundle/ruby/2.7.0/gems/redcarpet-3.5.0/ext/redcarpet/html.c:23,30,32,34,37,40,43,45,49,50,54,57,58,61,64,66,67,69,71,72,74,76,77,83,85,88,93,98,105,106,116,117,119,121,122,125,127,129,137,138,142,147,150,153,154,155,161,162,165,167,168,171,176,177,180,189,190,193,196,201,202,205,208,212,214,215,218,224,225,228,231,235,237,238,241,244,248,250,251,254,257,261,263,264,267,271,272,275,277,282,292,299,304,305,306,310,316,318,319,320,323,325,328,334,337,340,341,344,346,349,351,354,358,359,366,367,371,372,375,380,381,384,390,392,394,395,398,401,403,406,408,411,419,422,429,432,435,437,438,441,444,447,451,453,456,461,464,467,468,471,477,478,481,485,486,489,491,494,496,499,501,504,508,509,512,513,516,518,524,525,528,532,536,540,543,544,547,556,557,560,565,566,569,574,575,580,584,588,591,592,595,600,601,602,605,611,612,615,618,619,622,624,626,630,633,635,636,639,642,653,654,655,663,665,666,669,672,673,676,678,685,687,692,698,702,703,707,713,714,716,717,718,721,725,726,729,731,735,736,737,740,755,771,774,778,781,783,784,787,802,818,821,825,831,834,837,841,842,845 ./Vendor/bundle/ruby/2.7.0/gems/redcarpet-3.5.0/ext/redcarpet/houdini.h:22,25,27,31,42,46,48,50 ./Vendor/bundle/ruby/2.7.0/gems/redcarpet-3.5.0/ext/redcarpet/rc_render.c:22,24,32,33,40,41,48,50,53,55,56,59,61,62,65,67,68,71,73,74,77,79,80,83,86,87,90,93,94,97,99,100,103,105,106,109,111,112,115,117,122,126,130,134,135,137,138,141,143,144,147,149,150,151,157,160,161,164,166,167,170,172,173,176,178,179,182,184,185,188,190,191,194,196,197,200,202,203,206,208,209,212,214,215,218,220,221,224,226,227,230,232,233,236,238,239,242,244,245,251,253,254,257,259,260,263,265,266,269,271,272,275,281,282,285,288,292,293,308,324,327,331,346,362,365,369,371,373,376,377,379,381,382,384,388,389,391,394,398,403,408,412,413,414,418,419,421,424,425,427,431,433,436,439,443,447,451,455,459,463,467,470,473,476,478,479,482,486,487,489,490,492,496,498,501,504,508,511,512,515,522,531,532,534,535,537,540,542,544,547,550,551,553,555,559,562,565,568 ./Vendor/bundle/ruby/2.7.0/gems/redcarpet-3.5.0/ext/redcarpet/markdown.h:23,26,29,33,37,44,52,68,85,102,106,111,113,117,121,125,132,135,138,140,142 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/Type.h:33,36,39,43,45,47,52,55,57,59,61 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/rbffi_endian.h:3,7,9,22,35,47,53,57,59 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/MappedType.h:29,32,33,35,39,40,46,48,50,52,53,55,57,59 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/Thread.c:29,37,50,59,61,64,71,72,75,78,87,88,91,97,98,101,104,107,108,111,113,115,117,118,121,123,125,128,134 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/Buffer.c:30,43,47,54,60,62,65,68,72,74,75,78,82,83,85,86,98,102,104,108,114,115,118,121,122,126,127,130,131,133,134,142,145,150,155,156,160,163,165,166,169,171,172,175,179,182,189,191,192,201,204,206,208,209,219,221,222,230,233,235,237,239,240,241,247,260,262,270,273,278,281,282,286,290,291,293,294,295,299,301,306,307,309,310,313,315,316,319,321,328,334,356,364,365 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/Types.h:30,33,37,61,64,67,70,73,77,80,83,85,87,89 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/LastError.h:29,32,36,37,39,41,43,45,47 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/ArrayType.h:29,32,36,40,41,49,52,53,55,57,59 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/DynamicLibrary.c:29,47,49,55,61,64,65,69,71,83,86,89,90,101,103,104,115,118,120,123,131,139,143,144,147,151,154,156,157,164,168,169,172,177,180,181,185,191,192,193,196,199,201,204,210,212,213,214,223,226,227,230,233,240,242,243,246,249,250,258,261,266,267,270,284,317,322,337,338,339 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/Variadic.c:29,34,44,48,57,62,69,70,75,77,78,81,84,89,91,92,95,99,100,103,112,115,121,129,134,135,137,139,145,149,153,154,160,162,163,166,179,182,191,194,197,199,213,218,221,222,223,227,229,230,234,235,238,253,254,257,259,269,273,274,276,278,281,282,284,285,286,289,292,294,297,298 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/StructByValue.h:29,32,35,39,45,47,49,51,53,55 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/AbstractMemory.h:29,32,40,43,47,48,54,56,61,80,87,88,91,93,95,97,100,104,105,106,109,112,113,114,117,120,121,122,125,161,162,163,167,168,169,171,173,175 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/ffi.c:30,34,36,53,55,57,59,62,70,72,75,93 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/ClosurePool.h:28,31,34,42,44,48,50,53,55,57 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/Pointer.c:29,43,45,48,51,54,57,60,61,68,70,71,74,77,81,83,84,98,102,104,115,116,124,126,130,136,138,139,141,143,144,157,160,166,167,171,172,176,177,182,183,189,192,194,195,198,202,205,207,213,215,216,226,229,231,233,234,245,247,248,256,259,261,267,268,270,271,280,282,284,286,287,296,298,300,303,304,306,307,315,317,319,321,322,328,340,342,350,353,358,361,362,366,370,371,373,374,375,376,384,386,388,393,395,398,400,401,403,404,407,409,411,413,414,423,425,428,430,431,439,441,443,445,446,447,450,454,456,457,460,462,463,466,469,484,501,507,508 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/MemoryPointer.c:30,44,45,50,52,54,57,59,60,63,68,70,71,82,85,88,91,92,94,95,98,101,103,105,110,117,120,121,123,124,127,129,131,136,138,139,141,142,145,149,151,152,161,166,168,169,172,174,176,192,196,197 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/Call.h:32,35,37,41,47,51,73,75,79,82,84,86,89,98,101,103,105,107 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/Platform.c:29,45,49,51,54,70,71,74,83 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/LongDouble.c:5,9,13,16,20,21,25,26,29,30,33,36,37,40,41,47,48,51,52,53,56,59,60,63,65 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/MethodHandle.h:29,32,36,39,40,44,45,50,52,54,56 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/Function.c:29,38,51,57,60,74,84,93,95,96,101,104,106,110,112,129,130,141,142,145,148,150,156,158,159,162,166,167,170,173,174,177,178,180,181,198,199,204,206,215,225,226,231,233,235,236,244,247,248,251,253,254,257,260,267,268,269,273,274,285,286,288,289,292,294,296,298,300,306,312,313,314,318,320,326,330,331,333,335,336,345,347,349,351,352,362,365,367,371,372,376,377,380,381,387,390,391,394,396,397,406,408,410,412,414,415,418,420,422,424,425,433,435,437,440,441,444,446,447,450,452,458,460,466,470,473,479,482,487,491,495,497,504,506,511,512,513,519,522,525,527,534,535,536,538,539,543,545,547,549,554,555,559,560,562,564,565,568,570,575,576,580,582,584,586,589,590,594,595,597,599,600,603,605,610,612,615,617,619,629,631,632,634,637,640,641,644,646,656,662,666,667,717,723,727,728,733,734,736,737,739,745,746,787,789,793,797,799,802,804,808,810,814,817,820,821,824,826,830,831,833,834,837,839,842,844,845,848,851,856,857,859,860,863,869,872,892,902 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/Struct.h:30,33,38,42,48,52,54,58,61,64,72,78,83,86,91,96,100,106,108,110,112 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/rbffi.h:29,32,34,38,40,42,50,52,54 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/Thread.h:29,32,41,45,46,52,63,71,75,77,79,81 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/MappedType.c:29,31,34,37,38,43,45,48,50,52,58,60,61,70,72,75,76,79,80,83,84,89,90,94,96,97,100,103,104,112,115,117,118,125,127,129,131,132,139,141,143,145,146,149,154,156,160,167,168 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/Type.c:29,33,41,42,47,49,51,56,59,62,65,67,68,77,80,82,91,92,94,95,103,105,107,109,110,118,120,122,124,125,133,136,138,141,143,144,147,150,152,156,158,159,162,165,166,174,177,181,183,184,187,189,192,203,206,207,208,211,214,215,216,219,228,230,232,233,236,237,240,249,260,304,311,317,321,324,332,337,347,378,379 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/Types.c:31,42,44,45,48,62,73,78,81,88,94,95,100,105,107,108,116,119,120,124,126,127,131,132,133,136,138,139 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/compat.h:29,32,34,38,42,46,50,54,58,66,70,77,81 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/StructLayout.c:30,32,54,56,60,65,67,68,71,74,78,80,81,84,87,88,99,103,105,107,111,112,114,118,119,126,133,140,141,143,144,152,156,157,165,169,170,178,182,183,191,194,196,197,205,209,210,219,221,226,227,229,230,240,242,247,248,250,252,253,262,264,266,268,269,281,284,286,293,294,296,298,299,302,305,306,315,319,322,325,328,329,339,342,343,346,349,352,359,366,369,370,377,378,381,384,385,387,391,395,396,400,403,404,407,411,412,414,415,416,419,422,431,433,434,445,449,463,470,471,474,476,479,482,483,487,488,491,492,493,498,499,502,503,505,506,515,521,523,528,529,533,534,539,542,543,545,546,549,551,553,555,556,564,566,568,570,571,579,581,583,585,586,594,596,598,600,601,604,612,613,616,621,622,623,626,628,636,643,650,657,664,671,678,688,691,694,702,703,704 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/DynamicLibrary.h:28,31,35,40,44,48,52,57,61,65,69,73,78,82,86,90,92,94,96,98 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/ArrayType.c:29,33,38,40,43,46,48,55,57,58,61,63,64,67,71,72,73,83,86,88,92,97,100,101,103,104,112,114,116,118,119,127,129,131,133,134,137,139,141,156,161,162 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/win32/stdbool.h:3,7 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/win32/stdint.h:8,15,21,25,29,33,37,41,50,59,62,65,68,71,76,83,87,94,98,105,110,116,120,124,132,135,143,146,149,153,157,161,165,173,177,180,185,187,190,196 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/LastError.c:30,44,46,51,57,64,68,70,72,75,77,79,81,82,83,86,89,90,93,95,96,99,102,105,108,110,111,114,116,119,120,122,123,125,126,134,136,137,146,148,150,151,160,161,167,169,170,180,183,185,186,189,196,201,203,204,207,214,217,222,228,229 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/Struct.c:30,53,57,65,66,73,75,78,81,84,86,87,90,93,96,98,99,109,113,115,117,123,124,127,128,130,136,137,139,140,148,151,156,157,160,173,174,178,179,181,182,185,189,190,194,195,197,198,201,205,206,210,211,213,214,217,220,223,224,227,228,230,231,234,237,240,241,243,244,247,252,253,254,257,260,261,262,265,269,275,276,277,279,280,281,284,287,294,298,299,301,302,310,313,315,319,322,327,328,329,339,342,344,348,350,352,360,361,364,365,367,368,377,381,386,387,388,392,396,397,401,403,404,412,414,416,418,419,428,431,436,437,440,442,443,451,453,455,457,458,466,468,470,472,473,479,481,485,490,492,493,494,497,500,504,506,507,510,513,514,524,526,530,535,539,540,542,544,545,553,555,557,559,560,563,566,567,569,570,578,580,582,591,592,597,600,603,604,605,614,616,618,623,626,630,634,635,638,642,644,648,651,652,654,655,662,664,666,668,671,672,674,675,683,687,690,691,694,695,697,698,707,710,712,716,717,720,722,723,731,733,735,738,739,740,743,745,747,767,773,780,781,786,793,796,799,803,813,816,824,825 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/Platform.h:29,32,36,38,39,41,43,45 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/Call.c:31,65,70,80,82,88,91,93,98,102,108,109,110,112,116,117,122,123,126,128,135,136,140,145,148,149,153,158,161,162,166,170,174,181,182,186,193,194,198,205,206,210,217,218,222,229,230,234,241,242,246,253,254,258,265,266,270,277,278,282,289,290,294,295,299,302,303,307,315,316,324,327,331,334,335,336,337,340,343,345,346,349,351,353,354,357,361,362,365,371,373,376,387,391,395,397,400,404,408,409,412,413,416,417,420,422,423,426,428,430,432,435,437,439,441,443,445,449,451,452,455,456,459,461,462,463,466,470,471,477,478,481,483,484,485,488,492,493 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/Function.h:29,32,36,42,44,46,50,55,74,76,81,83,85,87 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/MethodHandle.c:28,52,56,64,65,67,71,79,80,81,84,88,89,93,95,96,99,105,106,111,113,114,117,120,121,122,124,126,127,130,132,134,137,139,148,149,151,152,153,156,158,159,166,169,177,179,180,182,183,184,187,189,192,217,220,223,226,228,229,231,235,262,265,268,269,271,275,277,280,285,286,287,289,290,293,297,298,302,303,305,306,309,314,316,317,320,322,323,325,326,329,333,335,339,344,349,350,352 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/LongDouble.h:29,32,34,38,41,43,45,47 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/AbstractMemory.c:31,41,44,51,60,65,68,73,75,77,133,179,180,185,187,188,191,193,194,201,211,214,216,217,220,222,223,226,228,229,232,234,235,242,250,264,267,282,283,284,286,289,291,292,295,297,298,300,301,309,313,314,322,324,326,328,329,340,344,347,350,353,355,360,361,362,372,376,379,382,385,388,393,394,395,407,413,418,422,423,435,440,445,448,451,453,457,458,465,467,468,469,471,472,482,485,489,490,492,493,494,507,510,514,517,520,522,523,535,538,541,544,546,547,563,568,570,576,581,582,585,587,589,590,600,602,603,615,618,622,623,625,626,634,636,638,640,641,651,654,656,658,660,661,664,666,667,670,672,674,676,678,679,682,687,688,691,692,695,703,704,705,708,710,715,716,718,719,722,724,725,727,728,747,750,786,790,791,810,816,834,839,1082,1090,1093,1100,1104,1105 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/MemoryPointer.h:30,33,40,44,49,51,53 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/include/ffi_common.h:5,9,12,16,18,49,58,62,67,76,81,86,87,92,101,105,108,113,140,142,148,150,152 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/include/ffi_cfi.h:3,6,9,11,31,33,53 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/err_bad_typedef.c:6,8,10,12,15,17,19,21,24,26 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/float3.c:6,8,11,13,15,17,18,20,22,23,25,30,34,41,45,49,51,53,55,62,66,68,70,72,74 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/strlen4.c:6,8,10,12,14,15,17,31,35,41,47,53,55 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/many2.c:6,8,10,12,14,21,23,24,28,30,31,34,41,44,47,49,52,54,57 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/return_fl3.c:6,9,11,13,15,29,37,42 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/struct5.c:6,10,14,16,19,21,22,24,30,32,36,44,49,52,57,59,62,63,66 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/struct1.c:6,9,11,16,18,22,24,25,27,33,35,39,48,51,55,59,61,64,67 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/struct10.c:6,9,12,18,25,26,37,42,46,49,52,57 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/align_stdcall.c:6,8,10,15,17,18,20,32,36,38,40,46 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/align_mixed.c:6,8,10,15,17,18,20,32,36,38,40,46 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/ffitest.h:7,11,15,17,19,34,39,44,53,55,57,63,65,74,88,93,115,124,135 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/strlen3.c:6,8,10,12,14,15,17,28,32,37,42,47,49 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/va_struct3.c:6,9,12,14,18,20,27,30,35,48,49,52,56,59,62,66,69,74,78,83,90,96,98,101,107,110,112,118,123,125 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/float4.c:6,9,12,14,18,20,22,24,25,27,34,37,41,43,47,49,53,55,59,61,62 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/struct6.c:6,10,14,16,19,21,22,24,30,32,36,44,47,50,53,56,58,61,64 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/return_uc.c:6,9,11,13,14,16,21,23,26,30,33,36,38 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/strlen.c:6,9,11,13,14,16,22,25,29,33,37,41,43,44 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/pyobjc-tc.c:6,9,14,19,24,26,30,31,32,34,42,46,54,62,70,80,85,86,87,89,90,97,104,107,109,111,112,114 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/return_sl.c:6,10,12,13,15,21,26,29,32,36,38 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/struct8.c:6,10,16,18,23,25,26,28,34,36,40,50,53,56,61,66,68,73,78,81 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/struct2.c:6,9,11,15,17,20,22,23,25,32,36,44,47,50,53,56,58,61,64,67 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/return_ll1.c:6,11,13,14,16,23,30,34,38,43 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/return_ldl.c:7,9,11,13,15,20,23,27,29,32,34 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/float1.c:6,10,12,14,18,20,22,24,25,27,34,37,41,43,47,49,51,53,57,59,60 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/return_ll.c:6,10,12,13,15,21,24,28,30,33,34,36,39,41 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/return_dbl.c:6,9,11,14,16,21,24,28,30,34,36 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/return_dbl2.c:6,9,11,13,15,29,37,42 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/many.c:6,9,13,15,22,24,25,27,34,36,40,41,45,47,54,59 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/many_mixed.c:6,9,13,33,35,36,38,46,48,53,58,59,60,64,66,78 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/va_struct2.c:6,9,12,14,18,20,27,30,35,46,47,50,54,57,60,64,67,72,76,81,88,94,96,99,105,108,110,116,121,123 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/strlen2.c:6,8,10,12,14,15,17,28,32,37,42,47,49 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/offsets.c:6,10,12,18,21,25,31,36,44,46 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/struct7.c:6,10,15,17,21,23,24,26,32,34,38,47,50,53,57,61,63,67,71,74 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/negint.c:6,8,10,12,13,15,16,18,23,27,34,38,42,44,46,48,50,52 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/return_sc.c:6,9,11,13,15,21,24,28,31,34,36 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/float_va.c:6,9,11,13,15,20,24,27,29,32,36,38,40,42,43,45,47,53,62,68,77,84,92,105,107 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/pr1172638.c:5,8,13,20,25,27,32,34,35,37,44,49,53,61,71,80,83,109,120,122,124,127 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/return_fl1.c:6,9,11,13,15,20,25,31,36 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/float.c:6,8,10,12,14,16,18,19,21,26,31,40,44,49,51,53,55,57,59 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/struct3.c:6,9,11,14,16,18,20,21,23,30,34,41,44,48,51,53,55,57,60 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/return_ul.c:6,10,12,13,15,21,26,29,32,36,38 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/struct9.c:6,9,11,15,17,20,22,23,25,31,33,37,45,48,51,54,57,59,62,65,68 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/return_fl.c:6,9,11,13,15,20,23,27,29,33,35 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/va_1.c:6,9,12,14,18,20,27,30,45,50,53,56,59,62,66,77,78,81,85,88,91,95,98,109,114,118,123,130,146,148,151,157,160,162,173,189,194,196 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/float2.c:7,10,12,14,16,17,19,26,29,33,35,42,45,52,59,61 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/va_struct1.c:6,9,12,14,18,20,27,30,35,44,45,48,52,55,58,62,65,70,74,79,86,92,94,97,103,106,108,114,119,121 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/return_dbl1.c:6,9,11,13,15,30,38,43 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/return_fl2.c:6,9,12,14,17,19,25,34,42,45,49 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/promotion.c:6,11,13,15,16,18,28,37,41,44,51,56,59 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/struct4.c:6,9,11,16,18,20,22,23,25,31,33,37,46,49,52,56,58,60,61,64 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/uninitialized.c:3,5,10,12,16,18,19,21,27,37,42,45,49,53,55,58,61 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.call/many_double.c:6,9,13,27,34,36,37,39,46,48,52,53,57,59,70 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/return_complex_float.c:6,8 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/return_complex1_float.c:6,8 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/cls_align_complex_double.c:6,8 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/cls_complex_va_longdouble.c:6,8 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/return_complex2_longdouble.c:6,8 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/complex_float.c:6,8 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/return_complex1_double.c:6,8 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/cls_complex_struct_longdouble.c:6,8 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/cls_align_complex_longdouble.c:6,8 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/cls_complex_struct_double.c:6,8 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/return_complex2_float.c:6,8 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/cls_complex_va_double.c:6,8 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/cls_complex_float.c:6,8 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/complex_int.c:6,8,12,14,19,20,41,42,48,50,54,60,67,71,76,84,86 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/cls_align_complex_float.c:6,8 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/many_complex_longdouble.c:6,8 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/cls_complex_struct_float.c:6,8 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/many_complex_double.c:6,8 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/complex_double.c:6,8 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/complex_longdouble.c:6,8 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/cls_complex_longdouble.c:6,8 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/many_complex_float.c:6,8 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/cls_complex_va_float.c:6,8,14 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/return_complex_double.c:6,8 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/cls_complex_double.c:6,8 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/return_complex_longdouble.c:6,8 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/return_complex2_double.c:6,8 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.complex/return_complex1_longdouble.c:6,8 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/nested_struct9.c:8,11,16,21,26,28,30,34,38,40,41,45,49,53,55,56,58,68,72,74,79,84,89,93,97,101,102,107,110,115,121,123,129,131 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_struct_va1.c:6,10,12,16,18,25,29,34,39,40,43,48,50,53,56,60,62,67,71,76,83,89,92,96,99,105,107,112,114 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_4byte.c:7,9,11,16,19,21,24,26,28,29,33,34,36,39,41,42,44,52,56,61,65,69,72,76,81,83,88,90 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_align_uint32.c:6,9,15,18,20,24,26,28,29,33,34,36,39,41,42,44,52,56,61,66,70,73,77,82,84,89,91 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_20byte.c:7,10,16,19,21,25,29,30,34,36,39,41,42,44,52,56,61,66,70,73,77,82,84,89,91 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_3float.c:7,9,11,17,20,22,26,29,31,32,36,38,41,43,44,46,54,58,63,68,72,75,79,84,87,93,95 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/nested_struct3.c:8,11,16,21,23,25,29,33,35,36,40,43,46,48,49,51,60,63,65,70,75,79,83,84,88,91,95,101,102,104,111 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_7_1_byte.c:7,10,20,23,25,33,38,40,41,45,46,48,51,53,54,56,64,68,73,82,86,89,93,99,107,109,115,117 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/err_bad_abi.c:6,8,10,15,17,22,24,27,30,32,34,36 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_6_1_byte.c:7,10,19,22,24,31,36,38,39,43,44,46,49,51,52,54,62,66,71,79,83,86,90,96,103,105,111,113 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_ulong_va.c:6,8,10,12,15,17,19,20,22,24,30,34,38,45 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_ushort.c:6,9,12,14,17,19,21,27,30,34,36,41,43 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_4_1byte.c:8,11,18,21,23,28,32,34,35,39,40,42,45,47,48,50,58,62,67,73,77,80,84,89,91,96,98 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/nested_struct7.c:8,11,16,21,23,25,29,33,35,36,40,43,46,48,49,51,60,63,65,70,75,79,83,84,88,91,95,101,103,109,111 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_schar.c:6,7,8,11,14,18,20,22,28,31,35,37,42,44 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_6byte.c:7,8,11,18,21,23,28,32,34,35,39,40,42,45,47,48,50,58,62,67,73,77,80,84,89,91,96,97,99 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_sint.c:6,9,12,16,18,20,26,29,33,35,40,42 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_2byte.c:8,11,16,19,21,24,26,28,29,33,34,36,39,41,42,44,52,56,61,65,69,72,76,81,83,88,90 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/closure_fn2.c:8,11,14,24,35,36,40,42,48,66,70,73,81 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/closure_fn6.c:7,10,14,27,40,41,42,49,51,57,75,79,82,90 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_multi_sshortchar.c:6,9,12,14,16,18,20,21,22,25,28,33,35,36,37,40,42,51,56,62,68,72,77,79,84,86 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_align_float.c:6,9,15,18,20,24,26,28,29,33,34,36,39,41,42,44,52,56,61,66,70,73,77,82,84,89,91 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/nested_struct.c:7,10,16,22,27,31,33,40,48,50,51,55,59,63,64,66,67,69,79,85,90,95,100,105,110,114,115,120,123,128,137,139,152 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_24byte.c:7,10,17,22,24,29,36,38,39,43,45,50,52,53,55,63,69,74,80,86,89,95,100,102,111,113 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_uchar.c:6,9,12,16,18,20,26,29,33,35,40,42 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_19byte.c:7,10,18,21,23,29,30,36,37,41,43,46,48,49,51,59,63,68,75,79,82,86,92,94,100,102 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/nested_struct10.c:8,11,16,22,27,29,31,36,40,42,43,47,51,55,57,58,60,70,74,76,81,86,91,95,100,104,105,110,113,118,124,126,132,134 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_7byte.c:7,10,17,20,22,27,31,33,34,38,39,41,44,46,47,49,57,61,66,72,76,79,83,88,90,95,97 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_sshort.c:6,9,12,16,18,20,26,29,33,35,40,42 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_double.c:6,9,12,14,17,19,21,27,30,34,36,41,43 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/ffitest.h:7,11,15,17,19,34,39,44,53,55,57,63,65,74,88,93,115,124,135 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/nested_struct4.c:8,11,16,21,23,25,29,33,35,36,40,43,46,48,49,51,60,63,65,70,75,79,83,84,88,91,95,101,103,109,111 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_5byte.c:7,10,16,19,21,25,29,31,32,36,37,39,42,44,45,47,55,59,64,69,73,76,80,85,89,91,96,98 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_64byte.c:8,11,22,27,29,38,41,43,44,48,50,55,57,58,60,68,74,79,89,95,98,104,110,112,122,124 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_align_sint32.c:6,9,15,18,20,24,26,28,29,33,34,36,39,41,42,44,52,56,61,66,70,73,77,82,84,89,91 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/huge_struct.c:7,11,13,66,119,130,151,153,154,157,208,215,216,219,222,226,230,243,245,250,263,265,290,293,295,311,313,339,341 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/problem1.c:6,9,15,17,22,23,26,28,29,32,35,38,40,41,42,44,52,56,61,66,70,73,81,83,88,90 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/stret_large2.c:8,11,14,32,38,40,56,60,62,63,66,68,73,75,76,78,86,92,97,114,120,123,129,136,138,146,148 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/closure_fn1.c:8,11,12,15,25,36,37,42,48,66,70,73,81 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_18byte.c:7,10,17,20,22,27,28,33,34,38,40,43,45,46,48,56,60,65,71,75,78,82,87,89,94,96 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_align_pointer.c:6,9,15,18,20,24,30,32,33,37,38,40,43,45,46,48,56,60,65,70,74,77,81,86,88,93,95 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_uint.c:6,9,12,14,17,19,21,27,30,34,36,41,43 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/closure_fn5.c:8,11,15,28,47,48,49,58,60,66,69,73,76,80,83,90,92 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_20byte1.c:7,8,9,12,18,21,23,27,31,32,36,38,41,43,44,46,54,58,63,68,72,75,79,84,86,91,93 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_9byte2.c:9,12,17,20,22,25,28,30,31,34,36,39,41,42,44,52,56,61,65,69,72,76,81,82,84,89,91 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/closure_loc_fn0.c:8,9,10,11,14,18,29,41,42,43,48,50,56,74,78,82,85,87,95 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_longdouble.c:6,11,13,23,25,28,30,31,35,44,47,48,50,57,66,76,79,89,94,96,103,105 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_double_va.c:6,10,12,16,19,21,22,24,30,34,38,42,46,51,54,59,61 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_16byte.c:7,10,16,19,21,25,28,30,31,34,36,39,41,42,44,52,56,61,66,70,73,77,82,86,88,93,95 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_3_1byte.c:8,11,17,20,22,26,30,32,33,37,38,40,43,45,46,48,56,60,65,70,74,77,81,86,88,93,95 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/nested_struct1.c:7,10,16,22,27,32,34,41,50,52,53,57,62,67,68,70,71,73,83,90,95,100,105,110,115,119,120,126,129,135,144,146,161 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/nested_struct11.c:9,12,17,22,27,29,35,37,44,46,47,49,51,56,58,62,65,70,75,80,84,88,92,101,112,121 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_align_longdouble_split.c:6,9,11,21,25,27,35,41,43,44,47,49,57,62,64,65,69,71,74,76,77,79,87,91,96,105,109,112,116,122,124,130,132 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_align_sint16.c:6,9,15,18,20,24,26,28,29,33,34,36,39,41,42,44,52,56,61,66,70,73,77,82,84,89,91 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_3byte1.c:8,11,16,19,21,24,26,28,29,33,34,36,39,41,42,44,52,56,61,65,69,72,76,81,83,88,90 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/nested_struct5.c:8,11,16,21,23,25,29,33,35,36,40,43,46,48,49,51,60,63,65,70,75,79,83,84,88,91,95,101,102,104,110,112 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_multi_sshort.c:6,9,11,13,15,17,19,20,21,24,26,29,31,32,33,35,37,45,48,52,56,60,65,67,72,74 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/stret_medium2.c:8,12,24,30,32,42,45,47,48,51,53,58,60,61,63,71,77,82,93,99,102,108,114,116,123,125 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/closure_fn0.c:8,9,10,11,14,18,29,41,42,43,48,50,56,74,78,81,89 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_float.c:6,9,12,14,17,18,20,22,28,31,35,42 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_longdouble_va.c:6,10,12,16,19,21,22,24,30,34,38,42,46,51,54,59,61 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/stret_medium.c:8,11,23,29,31,41,44,46,47,50,52,57,59,60,62,70,76,81,92,98,101,107,113,115,122,124 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_align_uint64.c:6,7,11,17,20,22,26,28,30,31,35,36,38,41,43,44,46,54,58,63,68,72,75,79,84,86,91,93 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_12byte.c:6,9,15,18,20,24,27,29,30,33,35,38,40,41,43,51,55,60,65,69,72,76,81,83,87,92,94 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_5_1_byte.c:7,10,18,21,23,29,34,36,37,41,42,44,47,49,50,52,60,64,69,76,80,83,87,93,99,101,107,109 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_dbls_struct.c:6,8,10,15,18,20,21,25,27,28,30,32,36,39,41,46,50,52,56,58,61,64,66 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_align_longdouble_split2.c:7,10,12,22,26,28,36,42,44,45,49,51,54,56,57,59,67,71,76,85,89,92,96,102,104,110,112,113,114,115 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/testclosure.c:6,9,16,18,23,24,28,30,32,34,35,36,38,45,47,52,58,61,64,66,70 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/closure_fn4.c:8,10,12,16,29,48,49,50,59,61,67,70,73,77,80,87,89 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/nested_struct2.c:8,11,16,21,23,25,29,32,34,35,39,42,45,47,48,50,59,62,64,69,74,78,82,83,87,90,94,100,102,108,110 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/nested_struct8.c:8,11,16,21,26,28,30,34,38,40,41,45,49,53,55,56,58,68,72,74,79,84,89,93,97,101,102,107,110,115,121,123,129,131 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/stret_large.c:8,11,14,31,37,39,54,58,60,61,64,66,71,73,74,76,84,90,95,111,117,120,126,133,135,143,145 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_multi_uchar.c:6,9,12,14,16,18,20,21,22,25,27,32,34,35,36,39,42,46,48,56,61,67,73,77,82,84,89,91 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_uchar_va.c:6,9,11,14,16,18,19,21,23,29,33,37,44 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_9byte1.c:9,12,17,20,22,25,28,30,31,34,36,39,41,42,44,52,56,61,65,69,72,76,81,83,88,90 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_multi_ushort.c:6,9,11,13,15,17,19,20,21,24,26,29,31,32,33,35,37,45,48,52,56,60,65,67,72,74 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_align_uint16.c:6,9,15,18,20,24,26,28,29,33,34,36,39,41,42,44,52,56,61,66,70,73,77,82,84,89,91 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_many_mixed_float_double.c:6,11,13,16,21,26,28,30,32,34,42,43,55 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_align_longdouble.c:6,8,10,16,19,21,25,27,29,30,34,35,37,40,42,43,45,53,57,62,67,71,74,78,83,85,90,92 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/nested_struct6.c:8,11,16,21,26,28,30,34,38,40,41,45,49,53,55,56,58,68,72,74,79,84,89,93,97,101,102,107,110,115,121,123,129,131 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_3byte2.c:8,11,16,19,21,24,26,28,29,33,34,36,39,41,42,44,52,56,61,65,69,72,76,81,83,88,90 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_uint_va.c:6,8,10,12,15,17,19,20,22,24,30,34,38,45 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_many_mixed_args.c:6,11,13,16,21,23,26,28,31,33,35,39,41,49,51,56,57,61,63,70 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_multi_ushortchar.c:6,9,12,14,16,18,20,21,22,25,28,33,35,36,37,40,42,51,56,62,68,72,77,79,84,86 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_align_sint64.c:6,10,16,19,21,25,27,29,30,34,35,37,40,42,43,45,53,57,62,67,71,74,78,83,85,90,92 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/closure_fn3.c:8,11,14,24,35,36,37,41,43,49,67,71,74,82 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_ushort_va.c:6,9,11,14,16,18,19,21,23,29,33,37,44 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_pointer_stack.c:6,9,11,17,19,20,22,32,35,37,42,44,45,47,57,60,62,67,69,71,72,76,79,88,91,93,94,96,103,108,112,116,119,123,126,131,133,135,140,142 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_multi_schar.c:6,9,11,13,15,17,19,20,21,24,26,29,31,32,33,35,37,45,48,52,56,60,65,67,72,74 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_1_1byte.c:8,9,10,13,17,20,22,24,26,28,29,33,34,36,39,41,42,44,52,56,61,64,68,71,75,80,82,87,89 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/closure_simple.c:6,9,12,17,22,23,24,26,28,34,40,44,47,50,53,55 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_align_double.c:6,7,8,11,17,20,22,26,28,30,31,35,36,38,41,43,44,46,54,58,63,68,72,75,79,84,86,91,93 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_pointer.c:6,9,11,13,18,20,21,25,28,30,31,33,40,45,49,53,56,60,65,67,72,74 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_ulonglong.c:6,10,13,15,18,20,22,28,31,40,45,47 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.closures/cls_8byte.c:7,10,15,18,20,23,25,27,28,32,33,35,38,40,41,43,51,55,60,64,68,71,75,81,86,88 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.go/closure1.c:2,4,6,10,11,13,15,19,22,24,26,28 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.go/aa-direct.c:2,4,6,8,13,16,17,19,22,24,26,28,30,31 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.bhaible/test-call.c:4,9,14,18,20,27,36,39,41,55,56,58,60,64,66,70,75,78,85,104,105,108,112,115,117,118,121,124,132,135,138,139,143,149,153,157,158,162,168,172,176,177,181,187,191,195,196,200,206,210,214,215,219,225,229,233,234,238,240,243,245,251,255,258,259,263,269,273,276,277,281,287,291,294,295,299,305,309,312,313,317,323,327,330,331,335,341,345,348,349,353,356,358,360,365,369,372,373,377,383,387,390,391,395,401,405,408,409,413,419,423,426,427,431,437,441,444,445,450,453,455,461,465,472,473,478,481,487,495,499,504,505,509,517,521,524,525,529,535,539,542,543,547,553,557,560,561,565,571,575,578,579,583,589,593,598,599,603,611,615,618,619,623,629,633,636,637,641,647,651,654,655,659,665,669,672,673,677,683,687,690,691,695,701,705,708,709,713,719,723,726,727,731,737,741,744,745,749,755,759,762,763,767,773,777,780,781,785,791,795,798,799,803,809,813,816,817,821,827,831,834,835,839,845,849,852,853,857,863,867,870,871,875,881,885,888,889,893,899,903,906,907,911,917,921,924,925,930,933,935,940,949,951,952,955,958,963,972,974,975,978,981,986,995,997,998,1001,1004,1009,1018,1020,1021,1024,1027,1032,1041,1043,1044,1047,1050,1055,1064,1066,1067,1070,1073,1078,1087,1089,1090,1093,1096,1101,1110,1112,1113,1116,1119,1124,1133,1135,1136,1139,1141,1144,1154,1160,1170,1173,1174,1183,1193,1196,1197,1206,1216,1219,1220,1229,1239,1242,1243,1252,1262,1265,1266,1275,1285,1288,1289,1299,1309,1313,1314,1323,1333,1336,1337,1342,1344,1345,1348,1357,1362,1367,1373,1377,1380,1381,1390,1394,1397,1398,1407,1411,1414,1415,1424,1428,1431,1432,1441,1445,1448,1449,1458,1462,1465,1466,1475,1479,1482,1483,1492,1496,1499,1500,1509,1513,1516,1517,1526,1530,1533,1534,1543,1547,1550,1551,1560,1564,1567,1568,1577,1581,1584,1585,1594,1598,1601,1602,1611,1615,1618,1619,1628,1632,1635,1636,1645,1649,1652,1653,1662,1666,1669,1670,1679,1683,1686,1687,1696,1700,1703,1704,1713,1717,1720,1721,1726,1727,1730,1733,1743,1745 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.bhaible/alignof.h:3,8,13,16,19,21,35,49 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.bhaible/test-callback.c:18,20,27,36,39,41,55,56,58,60,64,66,70,75,78,83,96,97,99,102,106,107,110,118,125,127,137,149,165,189,192,201,211,223,239,263,294,297,306,316,328,344,367,370,381,384,396,408,421,433,444,456,469,480,490,501,513,526,542,559,580,602,612,623,635,648,664,681,702,723,726,734,742,750,758,766,774,782,790,797,800,812,824,836,848,860,873,885,901,904,914,925,937,950,964,979,995,1024,1053,1065,1078,1092,1107,1123,1140,1152,1165,1179,1194,1210,1226,1227,1253,1254,1256,1266,1269,1275,1280,1283,1286,1293,1298,1303,1310,1316,1321,1328,1334,1339,1346,1352,1357,1364,1370,1375,1382,1388,1393,1394,1397,1404,1410,1415,1422,1428,1433,1440,1446,1451,1458,1464,1469,1476,1482,1487,1494,1500,1505,1506,1507,1510,1517,1523,1528,1535,1541,1546,1553,1559,1564,1571,1577,1582,1589,1595,1600,1601,1604,1611,1617,1622,1623,1630,1637,1643,1648,1655,1661,1666,1673,1679,1684,1691,1697,1702,1709,1715,1720,1727,1733,1738,1745,1751,1756,1763,1769,1774,1781,1787,1792,1799,1805,1810,1817,1823,1828,1835,1841,1846,1853,1859,1864,1871,1877,1882,1889,1895,1900,1907,1913,1918,1925,1931,1936,1943,1949,1954,1961,1967,1972,1979,1985,1990,1997,2003,2008,2015,2021,2026,2033,2039,2044,2045,2048,2054,2065,2069,2071,2073,2079,2090,2094,2096,2098,2104,2115,2119,2121,2123,2129,2140,2144,2146,2148,2154,2165,2169,2171,2173,2179,2190,2194,2196,2198,2204,2215,2219,2221,2223,2229,2240,2244,2246,2248,2254,2265,2269,2271,2272,2283,2290,2302,2307,2314,2326,2331,2338,2350,2355,2362,2374,2379,2386,2398,2403,2410,2422,2427,2435,2447,2452,2460,2472,2479,2480,2481,2483,2492,2497,2502,2509,2515,2520,2527,2533,2538,2545,2551,2556,2563,2569,2574,2581,2587,2592,2599,2605,2610,2617,2623,2628,2635,2641,2646,2653,2659,2664,2671,2677,2682,2689,2695,2700,2707,2713,2718,2725,2731,2736,2743,2749,2754,2761,2767,2772,2779,2785,2790,2797,2803,2808,2815,2821,2826,2833,2839,2844,2851,2857,2862,2869,2875,2880,2881,2882,2884,2885 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/testsuite/libffi.bhaible/testcases.c:18,21,23,25,30,66,78,83,90,107,118,122,125,128,129,132,137,139,144,146,151,153,158,160,165,168,174,175,178,183,185,190,192,197,200,205,208,213,217,222,223,226,231,233,238,240,245,248,253,257,262,263,266,271,272,275,280,282,287,289,294,296,301,303,308,310,315,316,318,323,325,330,331,333,338,340,345,347,352,354,359,362,367,370,375,378,383,386,391,392,394,399,401,406,408,413,415,420,423,428,431,436,440,445,449,454,455,458,462,464,468,470,474,476,480,482,486,488,492,494,498,500,504,506,510,511,514,520,522,528,530,536,538,544,546,552,554,560,562,568,570,579,580,585,587,592,594,599,601,606,608,613,615,620,622,627,629,634,642,647,652,657,658,660,665,667,672,674,679,681,686,688,693,695,700,701,703,708,710,715,717,722,724,729,731,736,738,743 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/msvc_build/aarch64/aarch64_include/fficonfig.h:3,6,11,14,17,20,23,26,29,32,35,38,42,45,48,51,55,58,61,64,67,70,73,76,79,82,85,88,91,94,97,100,103,109,112,115,118,121,124,127,131,134,137,140,143,146,149,152,155,158,161,164,172,175,178,182,185,197,200,201,219 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/msvc_build/aarch64/aarch64_include/ffi.h:4,12,15,24,26,29,34,36,38,40,43,46,50,55,57,59,61,65,68,72,74,99,102,104,110,128,136,144,154,167,175,185,199,205,216,222,234,236,244,248,256,270,271,277,281,285,291,298,300,302,321,327,330,342,349,361,363,367,370,372,375,377,385,387,389,393,396,398,401,403,409,416,422,429,431,433,439,442,445,447,449,456,464,470,474,477,479,481,505,506,508,510 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/m68k/ffitarget.h:5,13,16,25,27,30,34,38,46,48,52,54 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/m68k/ffi.c:3,6,9,23,32,35,38,44,46,56,58,62,65,67,69,73,77,81,85,96,99,101,103,105,109,110,113,114,116,117,128,132,135,139,143,146,147,149,175,177,181,185,195,199,204,208,212,216,217,219,220,223,225,228,231,238,240,245,249,250,251,254,259,262,264,266,272,274,276,281,283,285,289,291,293,295,297,301,302,305,306,307,310,313,316,318,320,322,323,330,333,337,347,356,360,362 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/moxie/ffitarget.h:4,12,15,24,26,29,31,35,43,45,48,51 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/moxie/ffi.c:3,5,13,16,26,29,31,34,36,42,45,47,50,51,55,57,59,61,64,66,69,73,77,81,85,88,89,91,93,95,97,101,102,104,105,108,113,115,117,118,124,129,131,134,137,140,142,145,147,155,156,157,160,166,170,173,176,181,187,192,193,196,198,219,225,227,229,232,234,241,242,245,247,249,254,255,256,263,267,270,272,279,283,285 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/avr32/ffitarget.h:5,13,16,25,27,30,34,38,46,48,50,54 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/avr32/ffi.c:4,6,14,17,27,30,35,37,42,44,47,52,56,58,59,66,68,76,78,81,84,85,88,93,96,98,100,103,105,107,110,113,115,117,120,122,125,126,127,128,130,133,134,137,139,154,155,157,158,162,167,168,170,172,174,175,178,183,186,189,212,223,230,231,233,234,236,238,241,244,247,250,256,258,266,267,268,271,278,282,284,286,289,292,293,295,297,300,302,305,307,309,312,314,316,319,322,324,326,329,331,334,335,336,337,339,342,343,346,351,352,354,355,359,361,363,364,366,369,374,376,379,381,386,388,390,392,393,397,400,416,420,422,423 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/m88k/ffitarget.h:23,27,30,34,42,44,48 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/m88k/ffi.c:23,45,48,51,60,63,67,70,73,81,85,91,93,95,98,102,111,116,118,120,123,126,127,132,133,136,139,140,142,146,150,154,158,166,173,176,177,181,183,187,190,193,194,196,197,201,204,208,216,222,226,227,229,230,233,235,238,241,249,251,255,259,260,261,265,269,275,277,279,281,284,288,297,302,304,306,309,312,313,318,319,322,325,326,331,335,337,341,344,347,348,349,353,356,359,361,363,365,366,371,374,376,381,392,394,398,400 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/ia64/ffitarget.h:5,13,16,25,27,30,34,38,46,48,55 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/ia64/ia64_flags.h:3,5,7,15,18,28,32,35 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/ia64/ffi.c:5,7,15,18,28,31,35,37,42,47,50,51,53,55,60,61,63,66,72,73,78,81,84,87,90,93,95,104,105,106,109,112,114,126,127,128,131,134,136,138,143,145,150,152,157,160,161,162,166,169,171,173,180,186,194,196,198,200,204,209,210,212,215,216,218,219,220,222,225,227,235,239,246,248,251,253,257,259,262,263,265,268,270,272,273,276,279,280,285,288,289,291,294,298,300,304,307,311,313,336,340,344,348,350,356,365,367,371,375,377,381,385,391,392,393,396,398,401,402,403,405,406,413,421,423,430,434,438,440,445,448,451,454,461,463,464,465,469,474,479,484,487,490,510,513,519,524,527,533,538,543,549,554,556,560,564,566,571,573,577,583,584,588,591,593,595,598,599,600,602,604 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/xtensa/ffitarget.h:4,12,15,25,28,32,36,44,46,48,52 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/xtensa/ffi.c:3,5,13,16,26,29,42,44,46,47,49,50,54,56,81,83,87,88,93,95,96,98,102,115,118,121,124,126,127,131,133,161,163,166,169,172,177,181,182,185,186,187,188,189,191,196,199,205,207,210,212,214,215,218,220,223,224,227,234,238,242,247,248,249,252,257,261,263,266,269,270,274,276,279,283,285,289,290,293,294,296,298 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/closures.c:6,8,16,19,29,33,37,41,45,48,53,55,58,63,67,71,74,80,86,91,92,98,99,102,105,111,113,133,142,144,146,148,156,158,161,163,167,172,176,178,182,185,188,191,200,207,219,222,223,229,233,235,239,242,243,245,247,248,251,255,258,261,265,266,269,274,276,280,283,287,288,293,295,296,302,304,312,314,315,318,320,322,326,331,336,338,340,346,348,349,351,354,355,357,359,361,369,372,375,378,382,385,401,406,410,412,415,420,428,436,440,441,445,446,449,451,453,455,459,461,464,473,476,481,485,486,490,492,494,497,499,503,520,526,529,531,534,536,539,543,546,550,552,558,561,563,564,568,575,581,589,591,594,597,600,602,603,608,610,613,615,616,624,627,629,632,634,639,640,643,645,649,652,657,659,662,663,665,669,684,687,693,696,701,704,705,707,708,713,715,717,720,723,726,727,729,731,732,742,744,748,751,753,758,759,761,762,770,772,774,780,781,783,786,789,793,795,798,800,804,805,807,811,813,815,818,822,824,825,827,829,831,832,838,840,845,847,850,851,853,855,859,863,864,866,870,872,873,875,876,881,890,892,896,897,899,900,905,913,914,916,918,924,926,929,931,933,935,937,938,940,941,944,954,955,962,965,969,971,972,974,977,979,982,985,987,988,991,993,994,997,999,1000,1003 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/powerpc/ffi_sysv.c:8,10,18,21,30,32,36,37,42,43,48,50,53,55,58,59,61,65,72,80,82,86,88,89,93,101,104,107,110,121,123,125,140,148,154,157,164,168,169,176,178,180,182,186,191,199,202,206,213,224,236,243,249,252,256,264,280,283,284,285,292,296,299,302,305,308,310,311,314,316,320,323,327,331,336,341,342,344,345,348,350,369,371,374,377,379,386,389,394,401,405,408,415,429,441,448,452,458,460,462,465,470,472,481,483,487,493,495,500,505,509,512,518,525,529,532,533,535,538,541,542,544,548,554,556,565,567,572,574,578,591,596,598,605,606,607,616,617,619,622,630,631,638,640,643,655,658,662,664,665,672,681,686,694,697,699,702,709,713,714,718,722,725,727,734,744,746,749,751,754,758,760,765,767,771,775,777,783,787,792,796,798,802,804,809,813,815,818,821,826,830,832,835,838,843,847,849,852,854,859,863,865,868,870,882,884,888,892,894,900,902,905,906,908,909,911,922 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/powerpc/ffitarget.h:5,7,15,18,27,29,32,36,38,55,59,62,68,74,84,107,117,136,139,141,152,155,160,166,169,172,179,193,203 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/powerpc/ffi_linux64.c:8,10,18,21,30,32,36,37,45,46,51,53,56,58,61,62,64,65,70,72,77,80,86,89,96,98,102,118,121,122,125,126,127,128,132,138,154,160,167,171,178,182,185,196,205,210,214,216,219,227,231,232,234,236,238,242,249,251,254,264,267,274,280,285,289,293,295,298,300,319,320,321,328,336,337,346,349,352,354,355,358,363,369,374,375,380,385,391,399,400,401,404,406,435,437,440,443,445,453,456,463,468,473,478,494,513,521,525,537,539,541,545,559,561,564,570,578,584,593,602,608,616,623,627,633,635,637,643,649,652,657,661,662,665,673,678,680,689,691,695,697,707,712,715,724,732,734,737,742,744,746,757,758,760,780,790,791,792,796,797,798,801,804,812,814,815,822,825,828,840,843,849,853,855,856,857,866,872,879,881,886,889,890,899,902,904,906,914,922,930,937,940,946,949,959,967,972,979,985,987,994,996,1000,1002,1004,1007,1012,1014,1016,1018,1020,1023,1028,1030,1037,1039,1048,1051,1055,1064,1066,1068,1071,1073,1075,1080,1082,1085,1094,1096,1099,1104,1110,1116,1118,1124,1127,1130,1131,1133,1134,1136,1139,1148,1152 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/powerpc/ffi_powerpc.h:8,10,18,21,30,38,42,44,53,55,59,67,72,85,90 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/powerpc/ffi.c:8,10,18,21,30,34,39,47,49,53,59,60,65,71,72,79,83,86,92,95,103,110,113,132,133,134,137,139,140,144,146,147,154,160,161,166,175 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/powerpc/asm.h:3,5,13,16,25,27,28,36,42,76,83,92,114,117,123 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/powerpc/ffi_darwin.c:3,7,9,17,20,29,32,34,37,48,50,56,63,65,68,70,72,95,97,103,105,108,115,118,123,126,136,141,145,148,151,153,171,187,189,255,266,271,282,288,293,302,303,304,310,311,313,319,321,323,325,328,341,342,343,344,347,349,351,357,359,361,388,391,393,394,398,400,402,406,411,416,421,423,424,428,432,435,442,444,467,470,473,474,480,483,485,488,494,501,503,506,508,513,514,516,517,520,523,526,533,535,541,544,549,552,556,559,563,566,568,569,571,575,578,580,583,586,589,609,610,612,620,621,624,627,629,632,635,638,645,646,648,655,656,660,668,672,674,678,679,681,685,686,689,691,712,713,720,727,735,738,741,751,753,757,758,763,767,777,781,782,790,793,805,819,836,864,870,871,872,875,888,899,902,905,907,908,911,914,917,920,922,925,928,931,933,936,938,950,951,952,956,958,961,964,967,969,972,974,982,983,984,987,990,995,998,1000,1002,1036,1038,1045,1049,1051,1053,1055,1067,1085,1088,1090,1092,1095,1097,1105,1109,1111,1112,1117,1119,1121,1123,1128,1133,1135,1136,1139,1149,1150,1153,1159,1160,1162,1166,1170,1174,1181,1187,1191,1193,1195,1199,1208,1210,1212,1215,1219,1222,1225,1230,1231,1235,1238,1240,1250,1260,1271,1277,1281,1285,1286,1288,1294,1316,1330,1335,1340,1342,1344,1347,1352,1355,1357,1359,1366,1368,1372,1375,1377,1379,1382,1384,1390,1393,1398,1404,1406,1408,1415,1417,1418,1420,1423,1424,1428,1431,1432,1436,1439,1440 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/m32r/ffitarget.h:5,13,16,24,26,29,33,35,39,41,48,52 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/m32r/ffi.c:4,6,14,17,26,29,31,34,36,43,46,48,51,52,55,59,61,65,67,71,73,75,79,83,87,91,100,103,104,106,108,110,112,114,117,119,122,123,125,128,129,132,133,134,136,137,141,144,148,152,155,159,165,170,171,173,174,177,179,181,184,189,191,194,196,201,204,206,209,211,213,215,217,220,223,224,225,227,231,232 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/or1k/ffitarget.h:3,5,13,16,26,29,33,35,39,47,49,53,56,58 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/or1k/ffi.c:3,5,13,16,26,29,32,34,40,44,46,50,52,53,56,59,61,64,68,72,76,80,84,91,94,97,101,102,107,109,110,117,118,120,124,126,128,136,137,141,144,145,150,152,159,160,161,162,165,168,171,175,178,186,188,190,193,194,197,198,201,204,206,208,213,218,225,229,232,240,243,246,249,250,252,255,260,261,262,263,270,274,277,281,287,292,295,298,300,301,302,304,306,313,315,317,318,319,322,324,328 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/tile/ffitarget.h:4,12,15,25,28,32,34,36,39,47,50,64 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/tile/ffi.c:3,5,13,16,26,35,36,39,47,51,52,55,61,66,69,70,71,75,77,81,85,89,93,103,107,112,115,117,119,128,132,136,140,141,142,143,146,154,156,161,164,165,167,171,179,181,184,187,190,191,194,196,198,199,200,204,207,208,209,212,213,220,227,230,232,236,242,245,250,252,254,259,262,265,268,272,275,277,278,279,288,299,302,306,310,312,316,317,320,324,332,336,340,341,345,346,349,351,354,355 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/s390/ffitarget.h:5,13,16,25,27,30,34,40,42,46,54,57,59,68,70 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/s390/internal.h:7,10 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/s390/ffi.c:4,6,14,17,30,35,37,42,45,52,55,57,62,64,71,74,77,79,88,91,93,99,103,106,109,115,121,124,125,128,129,131,139,142,147,150,152,154,159,166,171,175,188,204,208,209,211,215,217,223,226,231,236,237,240,243,250,257,262,274,277,284,285,286,289,291,293,294,296,304,311,320,322,325,330,331,333,340,342,347,349,355,360,363,370,375,379,384,387,412,429,434,441,443,451,459,470,474,475,476,478,479,482,484,485,489,491,492,494,502,510,512,516,520,523,526,532,535,538,544,547,552,557,558,561,567,568,571,579,586,603,612,620,628,632,633,638,639,640,643,646,655,660,664,676,683,690,694,695,696,698,706,713,723,725,728,732,736,738,739,741,743,747,750,754,756 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/prep_cif.c:4,12,15,25,29,31,33,36,38,40,43,46,48,51,53,57,60,65,68,70,71,80,87,92,93,98,101,104,107,108,114,118,122,125,130,138,143,150,167,169,170,175,183,185,189,193,197,203,205,207,208,210,216,218,220,223,225,226,233,235,236,238,244,246,247,249,252,257,261,263 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/cris/ffitarget.h:5,13,16,25,27,30,34,38,46,48,55 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/cris/ffi.c:6,8,16,19,28,31,33,36,38,40,44,46,48,52,54,56,59,61,62,67,68,71,77,79,81,84,86,88,90,93,96,98,101,103,111,113,117,119,123,128,132,137,140,142,148,151,152,154,155,161,165,170,175,177,181,183,185,189,191,195,197,200,202,207,208,211,212,214,216,217,220,222,231,235,236,238,239,244,247,249,252,254,256,259,261,269,270,271,274,278,283,288,295,298,305,311,314,317,320,322,325,327,329,333,334,339,342,343,344,347,353,358,360,362,363,365,372,384,386 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/debug.c:3,11,14,24,29,31,33,37,38,40,42,46,47,49,51,53,63,64 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/mips/ffitarget.h:5,13,16,25,27,30,34,47,57,71,82,84,87,94,98,113,123,146,193,203,226,230,232,236,242,244 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/mips/ffi.c:5,7,15,18,28,31,34,40,48,54,62,66,67,70,75,80,92,94,100,104,105,107,109,112,117,119,122,123,126,129,135,138,140,149,150,152,156,160,164,168,172,183,188,193,194,196,200,203,206,210,212,218,219,221,225,226,227,229,235,239,242,244,247,249,253,260,264,267,269,270,273,277,284,287,290,292,297,299,306,308,312,315,319,321,322,324,327,330,335,337,339,341,346,349,350,352,356,358,363,366,367,368,369,370,371,373,375,377,382,388,393,394,396,399,406,411,415,416,418,421,427,431,433,435,437,440,443,445,448,451,453,455,458,460,469,470,472,484,486,488,495,497,504,508,509,511,512,515,517,519,523,525,530,532,533,537,544,547,550,558,563,566,568,573,578,579,581,583,584,586,588,589,593,595,596,601,606,609,611,614,617,623,625,633,639,644,650,654,660,665,668,672,673,674,677,679,680,684,686,687,688,697,704,708,725,773,775,779,786,787,811,816,819,822,824,828,829,833,835,842,849,851,853,858,863,868,873,877,879,882,883,886,888,890,897,898,900,902,903,904,906,911,914,920,926,929,931,936,942,943,944,966,973,978,980,982,989,990,994,996,1000,1003,1006,1013,1015,1017,1020,1022,1027,1030,1032,1037,1042,1047,1052,1057,1062,1065,1071,1073,1078,1079,1082,1083,1086,1088,1089,1091,1099,1103,1105,1122,1126,1128,1129 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/sh/ffitarget.h:5,13,16,25,27,30,34,36,40,48,52,54 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/sh/ffi.c:4,6,14,17,27,30,32,37,43,47,52,54,55,58,60,63,66,68,76,79,80,81,84,87,89,92,98,101,102,103,104,106,107,110,112,123,126,128,132,135,140,142,144,147,150,153,157,161,165,169,173,176,178,180,183,186,189,192,195,198,205,208,220,221,222,229,231,233,236,239,242,246,250,254,258,262,265,267,269,272,275,278,281,284,287,289,293,296,299,302,305,308,311,315,316,317,319,320,323,331,333,336,339,342,350,359,369,370,373,383,385,388,392,400,404,405,407,408,411,413,416,419,422,428,430,433,435,443,444,449,450,455,462,465,468,474,484,488,493,495,496,504,512,517,526,529,533,536,539,543,546,548,551,554,557,562,567,571,574,576,578,581,586,589,594,595,598,607,610,622,623,624,629,631,633,636,639,642,647,652,656,659,661,663,666,669,672,675,678,681,683,687,690,693,696,699,702,706,710,711,712,714,717 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/sh64/ffitarget.h:5,13,16,25,27,30,34,36,40,47,50,52,56,58 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/sh64/ffi.c:4,6,14,17,27,30,32,35,38,39,42,52,54,55,58,60,66,68,70,73,74,77,79,82,86,88,92,96,100,104,108,111,113,115,117,122,129,133,135,139,142,144,146,149,150,151,153,154,157,164,168,170,173,180,183,188,193,196,200,215,216,217,220,224,232,236,237,239,240,250,255,258,261,264,270,272,275,277,285,286,291,292,295,302,304,307,329,333,337,339,340,348,352,359,362,366,369,372,376,379,382,385,387,389,401,404,405,407,409,411,413,416,418,427,428,435,443,445,449,452,454,456,458,461,462,463,465,468,469 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/frv/ffitarget.h:5,13,16,25,27,30,34,36,40,48,50,53,61 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/frv/ffi.c:5,7,15,18,28,31,33,36,38,44,47,51,53,55,57,60,62,64,68,73,76,80,84,88,92,95,96,98,100,102,104,108,109,111,112,115,120,122,124,125,131,136,138,141,144,147,149,152,153,155,163,164,165,168,174,179,183,189,192,194,216,218,223,224,227,233,235,239,245,246,247,254,262,264,281,285,290,292 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/pa/ffitarget.h:5,13,16,25,27,30,34,36,40,43,49,55,64,66,68,72 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/pa/ffi.c:6,9,17,20,30,33,36,38,42,51,53,55,57,63,82,83,85,100,106,112,116,121,124,127,130,133,138,141,143,150,153,156,158,160,162,166,170,174,178,186,193,199,205,207,214,218,220,228,230,234,237,240,242,246,250,253,254,258,259,261,263,266,269,271,272,274,276,277,279,283,285,287,289,295,302,305,306,307,314,316,317,320,323,329,336,345,350,354,355,359,363,367,368,370,371,375,377,379,382,385,393,395,398,399,401,407,411,412,413,420,433,435,441,445,447,449,451,461,467,477,482,486,492,495,499,506,512,515,517,521,525,528,529,532,533,536,539,542,565,569,573,577,585,590,593,596,601,602,605,608,610,614,619,621,622,626,628,635,637,641,645,647,652,655,658,661,667,671,673 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/metag/ffitarget.h:4,12,15,24,26,29,33,37,45,47,51,53 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/metag/ffi.c:3,12,15,24,27,29,31,36,38,43,45,50,51,53,56,58,62,65,69,86,91,92,93,97,98,101,104,108,112,116,118,119,122,126,129,130,132,159,161,162,164,174,176,180,182,187,194,202,203,206,207,209,212,214,217,219,234,235,236,237,239,246,248,253,258,262,264,265,266,273,276,279,288,290,292,293,297,302,305,310,311,313,317,323,328,330 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/x86/ffitarget.h:5,7,15,18,27,29,32,36,38,41,46,51,56,58,79,91,100,126,128,131,136,149,158,160 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/x86/internal.h:17,20,24 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/x86/ffi64.c:6,8,16,19,29,32,37,39,42,54,56,61,63,70,73,76,82,86,99,101,103,107,110,113,117,124,128,136,146,149,150,156,162,164,175,177,179,182,184,187,189,193,195,198,201,218,224,228,231,235,239,240,243,245,247,252,256,257,259,260,262,269,273,274,277,282,288,292,293,298,302,303,305,307,310,321,325,328,338,339,340,342,343,347,351,355,359,363,382,383,386,388,389,391,396,399,405,412,414,418,462,468,470,472,478,489,490,494,519,523,524,529,533,535,538,541,543,546,547,550,553,555,556,560,566,569,574,579,580,585,587,589,594,597,599,601,606,608,612,617,619,623,625,627,638,651,663,664,665,666,668,671,672,677,680,683,686,689,690,696,700,703,706,709,710,711,714,723,730,743,750,755,758,762,764,765,773,779,784,786,793,794,797,800,805,807,811,816,822,825,828,830,833,834,837,840,843,848,849,850,851,854,857,858,861,867,871,878,884,886,887 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/x86/ffi.c:8,10,18,21,31,38,49,53,60,64,67,69,80,81,83,131,134,144,147,151,173,177,179,181,183,186,188,190,191,194,196,205,211,214,215,216,218,226,228,234,245,255,257,261,268,273,276,278,292,293,294,301,306,309,313,317,323,324,327,332,334,336,340,343,345,348,349,351,354,363,373,375,380,382,386,387,388,390,392,393,396,398,399,403,405,406,408,412,414,421,424,432,440,442,445,450,457,458,461,464,469,471,475,478,480,483,484,486,489,493,502,504,509,511,515,516,517,519,520,522,527,528,535,539,541,558,559,562,566,570,574,576,577,581,585,587,589,605,606,610,612,613,615,617,620,627,631,638,642,643,645,654,655,659,663,667,669,670,673,680,684,687,689,703,704,705,712,716,719,723,727,734,735,738,742,744,748,750,754,757,760,762 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/x86/ffiw64.c:4,6,14,17,27,33,39,41,48,51,54,56,58,64,65,68,81,94,96,98,106,108,109,113,118,120,123,127,132,133,138,142,145,148,149,151,153,169,170,171,173,174,177,179,180,184,186,187,188,191,198,210,212,218,219,222,226,228,229,233,235,241,242,246,248,249,251,257,267,271,275,281,285,286,288,292,294,299,304,306,307,311,312 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/x86/asmnames.h:3,11,17,23,29 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/x86/internal64.h:17,19 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/types.c:3,5,13,16,26,30,33,35,46,47,62,63,68,77,79,82,88,101 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/microblaze/ffitarget.h:3,5,13,16,26,29,33,37,45,47,50,52 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/microblaze/ffi.c:3,5,13,16,26,29,33,35,39,43,48,51,52,54,57,64,65,68,69,72,78,81,83,121,124,134,135,136,137,139,142,147,149,150,152,156,163,164,166,174,175,176,180,184,195,200,202,207,208,213,214,217,219,243,245,261,263,264,274,275,276,281,286,290,292,295,301,307,315,319,321 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/arm/ffitarget.h:5,7,15,18,27,29,32,36,40,53,58,63,65,69,71,78,88 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/arm/ffi.c:7,9,17,20,30,38,43,45,49,57,61,64,75,76,79,81,83,96,106,114,120,125,128,129,131,132,135,143,146,148,151,152,154,158,159,160,164,170,175,179,182,183,185,189,192,196,199,206,212,217,223,224,229,230,231,235,238,245,248,252,263,268,275,279,281,289,290,298,301,303,306,307,312,316,319,321,322,327,331,333,334,336,338,345,350,354,360,363,371,373,376,379,382,385,388,391,392,394,398,402,404,407,409,412,413,416,417,420,422,423,427,429,430,434,437,439,442,444,447,448,450,453,457,458,460,461,465,471,474,476,479,480,482,486,488,491,493,495,497,501,505,510,513,515,518,520,521,522,527,528,530,531,533,538,544,550,551,557,563,564,569,571,577,579,581,585,588,594,601,617,621,623,624,628,630,632,636,639,643,645,646,648,652,655,658,661,664,668,670,671,673,674,677,680,683,686,689,692,695,696,698,699,703,706,709,713,717,732,733,738,743,745,749,750,751,755,768,771,774,777,780,783,784,788,789,792,795,798,802,804,807,810,813,814,818,821,826,829,834,835,838,845,847,851,852,853 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/arc/ffitarget.h:5,13,16,24,26,29,33,35,39,41,48,52 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/arc/ffi.c:3,5,13,16,25,28,31,33,41,44,47,52,54,56,59,60,62,65,68,71,75,78,80,82,86,90,94,98,102,105,106,108,110,112,114,116,118,121,122,125,126,128,129,133,136,140,144,150,155,156,158,159,163,166,168,171,175,177,180,182,187,191,192,193,197,203,205,208,211,212,214,217,220,223,227,231,232,234,236,237,239,244,246,248,255,258,259,264,266 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/riscv/ffitarget.h:3,5,13,16,25,27,30,34,38,40,43,53,56,58,60,67,69 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/riscv/ffi.c:6,8,16,19,29,32,35,43,47,49,57,59,65,73,78,84,93,95,96,105,110,120,125,126,128,130,147,162,163,168,169,170,184,185,190,191,205,206,207,211,220,221,222,226,228,237,243,244,250,251,252,257,266,267,268,272,274,285,291,292,299,300,301,307,309,311,312,317,318,320,324,325,329,333,342,354,355,358,363,367,371,373,377,378,381,383,384,388,390,391,393,395,398,401,404,415,419,421,423,424,426,430,433,437,439,440,449,460,464,470,474,476,480,481 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/dlmalloc.c:6,8,12,14,20,34,36,43,48,54,57,66,79,90,100,106,116,125,129,131,137,150,157,162,167,170,182,185,192,194,201,203,207,211,218,222,225,230,235,238,243,254,265,276,283,287,290,303,311,317,327,331,335,343,350,354,359,364,370,376,391,414,438,440,445,466,474,482,486,489,587,594,598,600,612,623,625,629,632,645,648,652,654,656,675,676,682,692,701,708,714,718,720,723,727,731,733,738,743,747,754,767,774,785,798,803,817,824,827,836,843,848,854,860,862,875,878,881,889,895,900,906,910,914,917,928,929,933,939,940,947,950,959,966,970,973,981,986,998,1002,1007,1009,1011,1017,1030,1038,1049,1055,1059,1065,1069,1076,1082,1088,1095,1102,1108,1114,1115,1123,1129,1135,1140,1142,1146,1154,1156,1158,1162,1164,1208,1255,1257,1261,1271,1274,1277,1282,1284,1290,1291,1295,1302,1306,1328,1330,1332,1340,1341,1343,1358,1360,1361,1365,1367,1372,1373,1379,1380,1395,1397,1398,1404,1410,1416,1419,1422,1423,1425,1427,1430,1437,1441,1449,1453,1455,1465,1471,1483,1484,1485,1488,1489,1498,1504,1512,1520,1521,1523,1526,1530,1538,1543,1545,1565,1567,1595,1600,1604,1615,1620,1628,1633,1635,1647,1656,1658,1665,1672,1674,1676,1682,1687,1691,1697,1701,1705,1709,1710,1712,1720,1724,1727,1732,1735,1739,1743,1746,1750,1754,1758,1761,1765,1772,1774,1778,1781,1797,1802,1825,1833,1840,1848,1856,1863,1870,1875,1879,1882,1884,1892,1906,1914,1921,1926,1939,1947,1949,1954,1957,1959,1968,1974,1978,1982,1985,1988,1990,1994,2003,2010,2020,2026,2039,2043,2048,2051,2054,2058,2063,2073,2094,2096,2098,2104,2113,2115,2121,2123,2125,2129,2133,2136,2141,2145,2149,2154,2158,2167,2168,2169,2178,2179,2180,2186,2194,2195,2197,2203,2205,2208,2212,2216,2220,2222,2230,2232,2235,2238,2241,2243,2247,2251,2253,2255,2257,2264,2272,2286,2288,2293,2297,2312,2330,2332,2336,2341,2346,2347,2349,2352,2357,2361,2363,2370,2371,2375,2387,2390,2393,2396,2399,2400,2402,2412,2428,2438,2445,2452,2453,2464,2466,2468,2470,2475,2480,2484,2486,2490,2494,2499,2504,2508,2510,2512,2517,2525,2527,2536,2540,2543,2544,2554,2556,2567,2572,2574,2590,2592,2593,2606,2614,2615,2616,2619,2624,2625,2638,2639,2652,2653,2663,2664,2682,2685,2686,2687,2699,2700,2701,2714,2726,2738,2743,2746,2747,2751,2752,2762,2763,2784,2785,2786,2787,2800,2801,2811,2818,2819,2820,2822,2823,2840,2845,2848,2850,2851,2853,2854,2864,2870,2871,2877,2878,2882,2884,2886,2906,2908,2910,2911,2919,2920,2922,2924,2926,2938,2946,2948,2949,2950,2954,2956,2957,2958,2960,2967,2985,2986,3005,3006,3022,3023,3035,3036,3038,3089,3090,3093,3107,3177,3178,3180,3184,3188,3189,3191,3206,3208,3218,3233,3241,3242,3244,3245,3269,3276,3277,3279,3280,3282,3289,3296,3297,3305,3306,3307,3309,3324,3326,3336,3340,3347,3352,3359,3363,3364,3367,3368,3369,3386,3389,3398,3408,3410,3418,3419,3421,3422,3424,3430,3432,3438,3439,3456,3462,3475,3476,3477,3486,3487,3488,3501,3502,3503,3504,3508,3511,3512,3514,3515,3525,3526,3527,3528,3543,3544,3545,3546,3547,3549,3552,3565,3566,3567,3580,3595,3598,3599,3600,3610,3611,3612,3615,3616,3618,3638,3641,3648,3651,3652,3653,3656,3658,3659,3664,3671,3682,3683,3684,3689,3697,3698,3700,3701,3702,3708,3709,3710,3714,3718,3719,3721,3722,3724,3732,3744,3752,3754,3755,3756,3764,3765,3766,3772,3774,3775,3789,3791,3792,3794,3796,3797,3805,3808,3814,3815,3816,3828,3830,3831,3832,3835,3836,3838,3843,3850,3852,3866,3867,3878,3879,3884,3885,3887,3891,3894,3901,3903,3904,3906,3907,3909,3919,3920,3924,3925,3934,3954,3958,3963,3965,3966,3976,3977,3978,3985,3988,3990,3991,3993,3994,3996,4005,4010,4022,4029,4036,4037,4042,4048,4049,4051,4064,4068,4070,4073,4074,4083,4084,4096,4100,4101,4102,4108,4111,4113,4116,4118,4121,4122,4123,4125,4127,4148,4151,4161,4173,4174,4196,4200,4201,4205,4206,4207,4215,4216,4217,4226,4232,4236,4237,4248,4249,4251,4255,4256,4258,4259,4266,4274,4291,4299,4304,4305,4308,4309,4310,4320,4324,4330,4339,4340,4341,4347,4348,4353,4354,4358,4359,4368,4373,4374,4382,4392,4395,4396,4397,4400,4401,4406,4407,4411,4412,4418,4419,4425,4426,4432,4434,4435,4438,4439,4442,4443,4447,4449,4452,4453,4459,4461,4462,4465,4466,4468,4470,4472,4491,4492,4497,4507,4508,4510,4511,4516,4522,4524,4525,4539,4540,4543,4545,4546,4551,4552,4558,4568,4580,4581,4603,4607,4608,4612,4613,4614,4622,4623,4624,4633,4639,4643,4644,4655,4656,4658,4662,4663,4665,4666,4678,4692,4700,4705,4706,4709,4710,4711,4721,4725,4731,4740,4741,4742,4748,4749,4754,4755,4756,4757,4765,4771,4776,4777,4785,4797,4799,4800,4801,4807,4809,4810,4818,4820,4821,4828,4830,4831,4839,4840,4843,4845,4846,4851,4854,4855,4856,4862,4865,4866,4867,4873,4876,4877,4878,4884,4886,4888,4891,4892,4894,4896,4899,4918,4925,4927,4930,4935,4937,4940,4942,4948,4950,4957,4959,4962,4964,4966,4967,4968,4971,4973,4975,4978,4981,4982,4983,4985,4986,5001,5004,5008,5024,5027,5040,5064,5080,5083,5092,5113,5124,5128,5132,5134,5143,5152,5161,5165 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/alpha/ffitarget.h:5,13,16,25,27,30,34,38,46,49,51,56 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/alpha/internal.h:7,19 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/alpha/ffi.c:4,6,14,17,27,32,43,49,53,57,58,61,63,64,67,71,74,77,80,97,103,111,114,115,116,120,160,173,177,179,187,189,190,193,195,204,209,215,221,224,225,226,230,235,240,245,249,252,254,259,261,277,283,290,295,302,305,306,307,310,311,314,316,317,321,323,324,331,333,336,343,347,349,352,355,357,358,363,366,370,372,373,379,383,387,391,394,395,397,400,405,407,420,426,431,434,437,443,450,454,459,472,477,480,486,493,497,499,502,505,508,511,512,514,515,518,521 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/aarch64/ffitarget.h:2,10,13,21,24,28,43,45,52,54,57,59,66,71,75,77,86,91 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/aarch64/internal.h:9,12,20,24,30,37,42,47,52,56,58,61,64 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/aarch64/ffi.c:2,10,13,21,33,44,46,50,52,55,57,61,63,70,72,76,79,89,90,92,96,99,102,105,108,112,114,115,117,118,121,124,127,130,133,136,139,140,142,143,148,151,154,158,162,173,179,183,184,189,194,196,200,201,202,206,224,227,230,233,236,239,240,244,245,248,251,253,257,262,266,273,274,279,281,291,294,296,297,300,302,324,325,326,332,335,382,384,390,392,395,399,420,423,427,448,453,455,457,461,466,469,472,473,476,480,482,512,520,523,526,533,535,538,539,542,545,546,553,555,556,562,566,568,572,578,585,590,596,599,604,610,613,618,621,625,639,644,655,656,658,664,666,669,673,675,680,683,685,688,693,697,699,701,709,711,714,721,723,730,731,733,735,738,739,742,746,748,749,751,754,755,758,760,761,766,768,770,772,775,782,785,787,792,809,811,813,815,826,830,832,833,837,841,843,846,851,855,857,859,861,868,871,875,882,886,888,890,894,896,900,913,921,925,927,930,939,941,946,947,949,952,956,958,962,964,966,968,974,976,979,982,984,988,989,991,994,995,998,1002,1004,1005,1009,1011,1013,1014 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/sparc/ffitarget.h:5,13,16,25,27,30,34,36,42,46,59,62,67,69,73,79,81 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/sparc/internal.h:12,21,25 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/sparc/ffi64.c:4,6,14,17,27,32,43,45,49,53,56,59,61,64,70,72,74,77,80,98,100,101,104,106,107,110,113,117,123,126,130,132,133,134,136,139,143,149,152,156,158,159,161,164,169,172,185,189,192,194,199,201,205,207,212,213,216,225,226,228,253,256,257,260,264,266,271,274,286,289,290,295,298,301,305,306,309,312,313,316,319,320,323,326,329,333,335,337,342,344,347,348,349,355,358,361,365,367,394,400,404,410,413,414,415,417,418,422,424,426,429,431,432,435,437,438,442,444,445,449,451,455,458,465,468,471,480,484,486,488,489,493,496,500,502,503,509,513,518,520,524,528,531,534,539,542,549,552,555,559,560,562,577,595,598,600,601,604,607 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/sparc/ffi.c:4,6,14,17,27,32,34,45,49,54,57,97,126,130,132,135,139,141,148,154,157,159,160,165,168,171,175,177,178,181,184,188,190,192,197,199,202,203,204,208,214,217,222,224,230,237,245,258,265,268,270,273,275,278,279,280,282,283,287,289,291,297,299,300,303,305,306,310,312,313,317,321,325,328,335,339,342,347,351,353,355,356,360,363,367,369,370,376,380,385,390,394,395,398,401,406,408,415,420,425,428,443,454,457,460,461,464,467 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/java_raw_api.c:3,5,8,10,18,21,31,37,41,43,46,49,51,53,68,69,70,72,73,74,77,80,82,84,86,91,96,105,109,113,118,119,120,122,124,127,141,147,148,152,154,155,158,161,163,165,173,181,189,197,205,213,217,226,230,239,240,241,242,244,247,250,256,266,270,273,275,276,279,282,288,295,299,302,304,305,312,315,320,321,323,327,330,334,335,342,344,351,354,355,357,358,362,368,370,371 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/vax/ffitarget.h:23,27,30,34,42,44,48 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/vax/ffi.c:23,30,33,36,41,45,49,52,58,60,66,68,72,74,77,79,83,87,91,95,99,102,104,106,108,112,113,116,117,119,120,123,126,130,134,137,138,150,157,158,160,161,164,166,169,172,179,181,185,189,190,191,195,199,202,206,208,210,212,215,219,222,223,224,227,230,233,235,237,239,240,245,248,250,258,264,270,274,276 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/bfin/ffitarget.h:3,5,13,16,26,29,33,41,43 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/bfin/ffi.c:4,6,14,17,29,32,35,44,49,54,56,61,62,66,68,104,109,111,112,121,127,135,136,137,138,145,164,170,184,189,192,193,194,195,196 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/raw_api.c:3,5,13,16,26,28,31,33,36,39,41,43,50,51,53,54,55,58,61,63,65,67,72,77,84,90,94,98,102,103,104,106,108,111,114,116,120,122,124,127,128,129,133,135,136,139,142,144,146,150,154,158,162,167,172,178,182,186,190,191,192,193,195,196,203,205,209,210,212,216,219,222,223,230,232,239,242,243,245,246,249,251,255,261,263,264,266 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/nios2/ffitarget.h:2,4,12,15,23,24,27,31,35,43,47,51 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/libffi/src/nios2/ffi.c:2,4,12,15,23,24,27,29,32,37,41,44,48,49,51,57,59,61,70,72,73,74,80,82,85,90,93,94,96,101,105,109,112,116,120,124,128,132,135,136,142,143,144,145,149,151,152,155,161,164,171,173,179,195,196,197,201,205,212,218,221,224,227,230,234,238,242,243,247,248,249,258,261,264,279,291,297,301,303,304 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/FunctionInfo.c:29,35,42,45,49,55,60,62,65,68,76,78,79,82,88,89,90,93,100,102,103,117,126,132,133,135,145,149,153,154,158,159,162,163,168,169,174,175,178,179,182,190,202,203,205,207,208,216,218,220,222,223,231,233,235,237,238,241,243,245,263,268,269,270 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/Pointer.h:29,32,38,42,44,49,57,59,61,63 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/ClosurePool.c:28,53,60,66,68,69,73,79,88,90,94,99,101,107,109,110,113,115,122,124,125,128,133,134,135,136,139,147,152,154,155,161,165,166,172,175,176,177,180,181,187,192,195,201,202,203,206,207,210,220,221,222,223,226,228,229,230,233,241,242,245,252,253,256,262,263,266,273,274,277,279,280 ./Vendor/bundle/ruby/2.7.0/gems/ffi-1.13.1/ext/ffi_c/StructByValue.c:29,44,48,52,54,59,61,64,66,68,72,77,79,80,83,87,91,92,97,100,102,103,106,109,110,113,116,117,118,121,123,126,127,130,132,134,136,137,140,144,149,150 ./Vendor/bundle/ruby/2.7.0/gems/rake-13.0.1/doc/example/a.c:2,4,6 ./Vendor/bundle/ruby/2.7.0/gems/rake-13.0.1/doc/example/main.c:2,5,7,11 ./Vendor/bundle/ruby/2.7.0/gems/rake-13.0.1/doc/example/b.c:2,4,6 <<<<<< EOF