Commit af19c8aa by pidan

补充删除TenjinSDK

parent daa51990
Showing with 0 additions and 2176 deletions
../../../TenjinSDK/TenjinSDK.h
\ No newline at end of file
../../../TenjinSDK/TenjinSDK.h
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1600"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "E84B54C67AA2D084821E0B65836373F4"
BuildableName = "TenjinSDK"
BlueprintName = "TenjinSDK"
ReferencedContainer = "container:Pods.xcodeproj">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
</Testables>
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>
${PODS_ROOT}/Target Support Files/TenjinSDK/TenjinSDK-xcframeworks.sh
${PODS_ROOT}/TenjinSDK/TenjinSDK.xcframework
\ No newline at end of file
${PODS_XCFRAMEWORKS_BUILD_DIR}/TenjinSDK/TenjinSDK.framework
\ No newline at end of file
#!/bin/sh
set -e
set -u
set -o pipefail
function on_error {
echo "$(realpath -mq "${0}"):$1: error: Unexpected failure"
}
trap 'on_error $LINENO' ERR
# This protects against multiple targets copying the same framework dependency at the same time. The solution
# was originally proposed here: https://lists.samba.org/archive/rsync/2008-February/020158.html
RSYNC_PROTECT_TMP_FILES=(--filter "P .*.??????")
variant_for_slice()
{
case "$1" in
"TenjinSDK.xcframework/ios-arm64_armv7")
echo ""
;;
"TenjinSDK.xcframework/ios-arm64_i386_x86_64-simulator")
echo "simulator"
;;
esac
}
archs_for_slice()
{
case "$1" in
"TenjinSDK.xcframework/ios-arm64_armv7")
echo "arm64 armv7"
;;
"TenjinSDK.xcframework/ios-arm64_i386_x86_64-simulator")
echo "arm64 i386 x86_64"
;;
esac
}
copy_dir()
{
local source="$1"
local destination="$2"
# Use filter instead of exclude so missing patterns don't throw errors.
echo "rsync --delete -av "${RSYNC_PROTECT_TMP_FILES[@]}" --links --filter \"- CVS/\" --filter \"- .svn/\" --filter \"- .git/\" --filter \"- .hg/\" \"${source}*\" \"${destination}\""
rsync --delete -av "${RSYNC_PROTECT_TMP_FILES[@]}" --links --filter "- CVS/" --filter "- .svn/" --filter "- .git/" --filter "- .hg/" "${source}"/* "${destination}"
}
SELECT_SLICE_RETVAL=""
select_slice() {
local xcframework_name="$1"
xcframework_name="${xcframework_name##*/}"
local paths=("${@:2}")
# Locate the correct slice of the .xcframework for the current architectures
local target_path=""
# Split archs on space so we can find a slice that has all the needed archs
local target_archs=$(echo $ARCHS | tr " " "\n")
local target_variant=""
if [[ "$PLATFORM_NAME" == *"simulator" ]]; then
target_variant="simulator"
fi
if [[ ! -z ${EFFECTIVE_PLATFORM_NAME+x} && "$EFFECTIVE_PLATFORM_NAME" == *"maccatalyst" ]]; then
target_variant="maccatalyst"
fi
for i in ${!paths[@]}; do
local matched_all_archs="1"
local slice_archs="$(archs_for_slice "${xcframework_name}/${paths[$i]}")"
local slice_variant="$(variant_for_slice "${xcframework_name}/${paths[$i]}")"
for target_arch in $target_archs; do
if ! [[ "${slice_variant}" == "$target_variant" ]]; then
matched_all_archs="0"
break
fi
if ! echo "${slice_archs}" | tr " " "\n" | grep -F -q -x "$target_arch"; then
matched_all_archs="0"
break
fi
done
if [[ "$matched_all_archs" == "1" ]]; then
# Found a matching slice
echo "Selected xcframework slice ${paths[$i]}"
SELECT_SLICE_RETVAL=${paths[$i]}
break
fi
done
}
install_xcframework() {
local basepath="$1"
local name="$2"
local package_type="$3"
local paths=("${@:4}")
# Locate the correct slice of the .xcframework for the current architectures
select_slice "${basepath}" "${paths[@]}"
local target_path="$SELECT_SLICE_RETVAL"
if [[ -z "$target_path" ]]; then
echo "warning: [CP] $(basename ${basepath}): Unable to find matching slice in '${paths[@]}' for the current build architectures ($ARCHS) and platform (${EFFECTIVE_PLATFORM_NAME-${PLATFORM_NAME}})."
return
fi
local source="$basepath/$target_path"
local destination="${PODS_XCFRAMEWORKS_BUILD_DIR}/${name}"
if [ ! -d "$destination" ]; then
mkdir -p "$destination"
fi
copy_dir "$source/" "$destination"
echo "Copied $source to $destination"
}
install_xcframework "${PODS_ROOT}/TenjinSDK/TenjinSDK.xcframework" "TenjinSDK" "framework" "ios-arm64_armv7" "ios-arm64_i386_x86_64-simulator"
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = NO
CONFIGURATION_BUILD_DIR = ${PODS_CONFIGURATION_BUILD_DIR}/TenjinSDK
FRAMEWORK_SEARCH_PATHS = $(inherited) "${PODS_ROOT}/TenjinSDK" "${PODS_XCFRAMEWORKS_BUILD_DIR}/TenjinSDK"
GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1
HEADER_SEARCH_PATHS = $(inherited) "${PODS_ROOT}/Headers/Private" "${PODS_ROOT}/Headers/Private/TenjinSDK" "${PODS_ROOT}/Headers/Public"
OTHER_LDFLAGS = $(inherited) -framework "AdSupport" -framework "AppTrackingTransparency" -framework "StoreKit" -framework "TenjinSDK" -framework "iAd" -weak_framework "AdServices"
OTHER_LINKER_FLAGS = -ObjC -all_load
PODS_BUILD_DIR = ${BUILD_DIR}
PODS_CONFIGURATION_BUILD_DIR = ${PODS_BUILD_DIR}/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME)
PODS_DEVELOPMENT_LANGUAGE = ${DEVELOPMENT_LANGUAGE}
PODS_ROOT = ${SRCROOT}
PODS_TARGET_SRCROOT = ${PODS_ROOT}/TenjinSDK
PODS_XCFRAMEWORKS_BUILD_DIR = $(PODS_CONFIGURATION_BUILD_DIR)/XCFrameworkIntermediates
PRODUCT_BUNDLE_IDENTIFIER = org.cocoapods.${PRODUCT_NAME:rfc1034identifier}
SKIP_INSTALL = YES
USE_RECURSIVE_SCRIPT_INPUTS_IN_SCRIPT_PHASES = YES
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = NO
CONFIGURATION_BUILD_DIR = ${PODS_CONFIGURATION_BUILD_DIR}/TenjinSDK
FRAMEWORK_SEARCH_PATHS = $(inherited) "${PODS_ROOT}/TenjinSDK" "${PODS_XCFRAMEWORKS_BUILD_DIR}/TenjinSDK"
GCC_PREPROCESSOR_DEFINITIONS = $(inherited) COCOAPODS=1
HEADER_SEARCH_PATHS = $(inherited) "${PODS_ROOT}/Headers/Private" "${PODS_ROOT}/Headers/Private/TenjinSDK" "${PODS_ROOT}/Headers/Public"
OTHER_LDFLAGS = $(inherited) -framework "AdSupport" -framework "AppTrackingTransparency" -framework "StoreKit" -framework "TenjinSDK" -framework "iAd" -weak_framework "AdServices"
OTHER_LINKER_FLAGS = -ObjC -all_load
PODS_BUILD_DIR = ${BUILD_DIR}
PODS_CONFIGURATION_BUILD_DIR = ${PODS_BUILD_DIR}/$(CONFIGURATION)$(EFFECTIVE_PLATFORM_NAME)
PODS_DEVELOPMENT_LANGUAGE = ${DEVELOPMENT_LANGUAGE}
PODS_ROOT = ${SRCROOT}
PODS_TARGET_SRCROOT = ${PODS_ROOT}/TenjinSDK
PODS_XCFRAMEWORKS_BUILD_DIR = $(PODS_CONFIGURATION_BUILD_DIR)/XCFrameworkIntermediates
PRODUCT_BUNDLE_IDENTIFIER = org.cocoapods.${PRODUCT_NAME:rfc1034identifier}
SKIP_INSTALL = YES
USE_RECURSIVE_SCRIPT_INPUTS_IN_SCRIPT_PHASES = YES
The MIT License (MIT)
Copyright (c) 2016 Tenjin, Inc.
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>AvailableLibraries</key>
<array>
<dict>
<key>LibraryIdentifier</key>
<string>ios-arm64_armv7</string>
<key>LibraryPath</key>
<string>TenjinSDK.framework</string>
<key>SupportedArchitectures</key>
<array>
<string>arm64</string>
<string>armv7</string>
</array>
<key>SupportedPlatform</key>
<string>ios</string>
</dict>
<dict>
<key>LibraryIdentifier</key>
<string>ios-arm64_i386_x86_64-simulator</string>
<key>LibraryPath</key>
<string>TenjinSDK.framework</string>
<key>SupportedArchitectures</key>
<array>
<string>arm64</string>
<string>i386</string>
<string>x86_64</string>
</array>
<key>SupportedPlatform</key>
<string>ios</string>
<key>SupportedPlatformVariant</key>
<string>simulator</string>
</dict>
</array>
<key>CFBundlePackageType</key>
<string>XFWK</string>
<key>XCFrameworkFormatVersion</key>
<string>1.0</string>
</dict>
</plist>
//
// Created by Tenjin
// Copyright (c) 2022 Tenjin. All rights reserved.
//
#import <Foundation/Foundation.h>
#import "TenjinSDK.h"
@class GADAdValue;
@interface TenjinSDK (AdMobILRD)
+ (void)handleAdMobILRD:(NSObject *)adView :(GADAdValue *)adValue;
+ (void)adMobImpressionFromJSON:(NSString *)jsonString;
@end
//
// Created by Tenjin
// Copyright (c) 2022 Tenjin. All rights reserved.
//
#import "TenjinSDK.h"
#import <Foundation/Foundation.h>
@interface TenjinSDK (AppLovinILRD)
+ (void)subscribeAppLovinImpressions;
+ (void)appLovinImpressionFromJSON:(NSString *)jsonString;
@end
//
// Created by Tenjin
// Copyright (c) 2023 Tenjin. All rights reserved.
//
#import "TenjinSDK.h"
#import <Foundation/Foundation.h>
@interface TenjinSDK (CASILRD)
+ (void)subscribeCASBannerImpressions;
+ (void)casImpressionFromJSON:(NSString *)jsonString;
+ (void)handleCASILRD:(id)adImpression;
@end
//
// Created by Tenjin
// Copyright (c) 2022 Tenjin. All rights reserved.
//
#import <Foundation/Foundation.h>
#import "TenjinSDK.h"
@interface TenjinSDK (HyperBidILRD)
+ (void)hyperBidImpressionFromDict:(NSDictionary *)adImpression;
+ (void)hyperBidImpressionFromJSON:(NSString *)jsonString;
@end
//
// Created by Tenjin
// Copyright (c) 2022 Tenjin. All rights reserved.
//
#import "TenjinSDK.h"
#import <Foundation/Foundation.h>
@interface TenjinSDK (IronSourceILRD)
+ (void)subscribeIronSourceImpressions;
+ (void)ironSourceImpressionFromJSON:(NSString *)jsonString;
@end
//
// Created by Tenjin
// Copyright (c) 2022 Tenjin. All rights reserved.
//
#import <Foundation/Foundation.h>
#import "TenjinSDK.h"
@interface TenjinSDK (TopOnILRD)
+ (void)topOnImpressionFromDict:(NSDictionary *)adImpression;
+ (void)topOnImpressionFromJSON:(NSString *)jsonString;
@end
//
// Created by Tenjin
// Copyright (c) 2023 Tenjin. All rights reserved.
//
#import "TenjinSDK.h"
#import <Foundation/Foundation.h>
@interface TenjinSDK (TradPlusILRD)
+ (void)subscribeTradPlusImpressions;
+ (void)tradPlusImpressionFromJSON:(NSString *)jsonString;
+ (void)handleTradPlusILRD:(NSDictionary *)adInfo;
@end
//
// Created by Tenjin on 2016-05-20.
// Version 88.88.8008
// Copyright (c) 2016 Tenjin. All rights reserved.
//
#import <Foundation/Foundation.h>
#import <StoreKit/StoreKit.h>
@interface TenjinSDK : NSObject
#pragma mark Initialization
- (instancetype)init NS_UNAVAILABLE;
// initialize the Tenjin SDK
+ (TenjinSDK *)init:(NSString *)apiToken __deprecated_msg("use `initialize`");
//initialize the Tenjin SDK with shared secret
+ (TenjinSDK *)init:(NSString *)apiToken
andSharedSecret:(NSString *)secret __deprecated_msg("use `initialize`");
//initialize the Tenjin SDK with app subversion
+ (TenjinSDK *)init:(NSString *)apiToken
andAppSubversion:(NSNumber *)subversion __deprecated_msg("use `initialize`");
//initialize the Tenjin SDK with shared secret and app subversion
+ (TenjinSDK *)init:(NSString *)apiToken
andSharedSecret:(NSString *)secret
andAppSubversion:(NSNumber *)subversion __deprecated_msg("use `initialize`");
// initialize the Tenjin SDK
+ (TenjinSDK *)initialize:(NSString *)apiToken;
//initialize the Tenjin SDK with shared secret
+ (TenjinSDK *)initialize:(NSString *)apiToken
andSharedSecret:(NSString *)secret;
//initialize the Tenjin SDK with app subversion
+ (TenjinSDK *)initialize:(NSString *)apiToken
andAppSubversion:(NSNumber *)subversion;
//initialize the Tenjin SDK with shared secret and app subversion
+ (TenjinSDK *)initialize:(NSString *)apiToken
andSharedSecret:(NSString *)secret
andAppSubversion:(NSNumber *)subversion;
- (id)initWithToken:(NSString *)apiToken
andSharedSecret:(NSString *)secret
andAppSubversion:(NSNumber *)subversion
andDeferredDeeplink:(NSURL *)url
ping:(BOOL)ping NS_DESIGNATED_INITIALIZER;
#pragma mark Singleton access
// initialize the Tenjin SDK
+ (TenjinSDK *)getInstance:(NSString *)apiToken;
//initialize the Tenjin SDK with shared secret
+ (TenjinSDK *)getInstance:(NSString *)apiToken
andSharedSecret:(NSString *)secret;
//initialize the Tenjin SDK with app subversion
+ (TenjinSDK *)getInstance:(NSString *)apiToken
andAppSubversion:(NSNumber *)subversion;
//initialize the Tenjin SDK with shared secret and app subversion
+ (TenjinSDK *)getInstance:(NSString *)apiToken
andSharedSecret:(NSString *)secret
andAppSubversion:(NSNumber *)subversion;
//initialize the Tenjin SDK + connect
+ (TenjinSDK *)sharedInstanceWithToken:(NSString *)apiToken __deprecated_msg("use `init` and `connect`");
//initialize the Tenjin SDK + connect with a third party deeplink
+ (TenjinSDK *)sharedInstanceWithToken:(NSString *)apiToken
andDeferredDeeplink:(NSURL *)url __deprecated_msg("use `init` and `connectWithDeferredDeeplink`");
//returns the shared Tenjin SDK instance
+ (TenjinSDK *)sharedInstance;
#pragma mark - Functionality
//use connect to send connect call. sharedInstanceWithToken automatically does a connect
+ (void)connect;
//use connect to send connect call. sharedInstanceWithToken automatically does a connect
+ (void)connectWithDeferredDeeplink:(NSURL *)url;
//use sendEventWithName for custom event names
+ (void)sendEventWithName:(NSString *)eventName;
//This method is deprecated in favor of [sendEventWithName: andValue:], so you can pass an integer directly
+ (void)sendEventWithName:(NSString *)eventName
andEventValue:(NSString *)eventValue __deprecated_msg("use `sendEventWithName: andValue:` instead");
//Use this method to send custom events with values
+ (void)sendEventWithName:(NSString *)eventName
andValue:(NSInteger)eventValue;
//This method is deprecated in favor of [transaction: andReceipt:], so Tenjin can verify your transactions
+ (void)transaction:(SKPaymentTransaction *)transaction __attribute__((deprecated));
//Use this method to submit a transaction to Tenjin, we will also attempt to verify it for our records
+ (void)transaction:(SKPaymentTransaction *)transaction
andReceipt:(NSData *)receipt;
//use transactionWithProductName... when you don't use Apple's SKPaymentTransaction and need to pass revenue directly
+ (void)transactionWithProductName:(NSString *)productName
andCurrencyCode:(NSString *)currencyCode
andQuantity:(NSInteger)quantity
andUnitPrice:(NSDecimalNumber *)price;
//use transactionWithProductName...when you don't use Apple's SKPaymentTransaction and need to pass revenue directly with a NSData binary receipt
+ (void)transactionWithProductName:(NSString *)productName
andCurrencyCode:(NSString *)currencyCode
andQuantity:(NSInteger)quantity
andUnitPrice:(NSDecimalNumber *)price
andTransactionId:(NSString *)transactionId
andReceipt:(NSData *)receipt;
//use this method when you want to pass in a base64 receipt instead of a NSData receipt
+ (void)transactionWithProductName:(NSString *)productName
andCurrencyCode:(NSString *)currencyCode
andQuantity:(NSInteger)quantity
andUnitPrice:(NSDecimalNumber *)price
andTransactionId:(NSString *)transactionId
andBase64Receipt:(NSString *)receipt;
//use this method to register the attribution callback
- (void)registerDeepLinkHandler:(void (^)(NSDictionary *params, NSError *error))deeplinkHandler;
//notify Tenjin of a new subscription purchase
- (void)handleSubscriptionPurchase:(SKPaymentTransaction *)transaction;
// GDPR opt-out
+ (void)optOut;
// GDPR opt-in
+ (void)optIn;
// GDPR opt-out of list of params
+ (void)optOutParams:(NSArray *)params;
// GDPR opt-in with list of params
+ (void)optInParams:(NSArray *)params;
// GDPR opt-in/opt-out through CMP consents
+ (bool)optInOutUsingCMP;
// Opt out from Google DMA parameters (opted in by default)
+ (void)optOutGoogleDMA;
// Opt out from Google DMA parameters
+ (void)optInGoogleDMA;
// Appends app subversion to app version
+ (void)appendAppSubversion:(NSNumber *)subversion;
// deprecated
+ (void)updateSkAdNetworkConversionValue:(int)conversionValue __deprecated_msg("use `updatePostbackConversionValue:`");
//deprecated
+ (void)updateConversionValue:(int)conversionValue __deprecated_msg("use `updatePostbackConversionValue:`");
// Update conversion value
+ (void)updatePostbackConversionValue:(int)conversionValue;
// Update conversion value and coarse value (iOS 16.1+)
+ (void)updatePostbackConversionValue:(int)conversionValue
coarseValue:(NSString*)coarseValue;
// Update conversion value, coarse value and lock window (iOS 16.1+)
+ (void)updatePostbackConversionValue:(int)conversionValue
coarseValue:(NSString*)coarseValue
lockWindow:(BOOL)lockWindow;
// Set customer user id to send as parameter on each event request
+ (void)setCustomerUserId:(NSString *)userId;
// Get customer user id saved on the device
+ (NSString *)getCustomerUserId;
// Set the setting to enable/disable cache events and retrying, it's false by default
+ (void)setCacheEventSetting:(BOOL)isCacheEventsEnabled;
// Get cached analytics_installation_id
+ (NSString*)getAnalyticsInstallationId;
#pragma mark Util
+ (void)verboseLogs;
+ (void)debugLogs;
+ (void)setLogHandler:(void (^)(NSString *))handler;
+ (NSString *)sdkVersion;
+ (void)setWrapperVersion:(NSString *)wrapperVersion;
+ (void)setValue:(NSString *)value
forKey:(NSString *)key;
//deprecated
+ (void)registerAppForAdNetworkAttribution __deprecated_msg("use `updatePostbackConversionValue:`");
+ (void)requestTrackingAuthorizationWithCompletionHandler:(void (^)(NSUInteger status))completion;
- (void)getAttributionInfo:(void (^)(NSDictionary *attributionInfo, NSError *error))completionHandler;
- (void)setGoogleDMAParametersWithAdPersonalization:(BOOL)adPersonalization adUserData:(BOOL)adUserData;
@end
// swift-interface-format-version: 1.0
// swift-compiler-version: Apple Swift version 5.6.1 (swiftlang-5.6.0.323.66 clang-1316.0.20.12)
// swift-module-flags: -target arm64-apple-ios10.0 -enable-objc-interop -enable-library-evolution -swift-version 5 -enforce-exclusivity=checked -O -module-name TenjinSDK
import CoreData
import Foundation
import Network
import Swift
@_exported import TenjinSDK
import _Concurrency
@objc @_inheritsConvenienceInitializers public class QueueEvent : CoreData.NSManagedObject, Swift.Identifiable {
@nonobjc public class func fetchRequest() -> CoreData.NSFetchRequest<QueueEvent>
@objc @NSManaged dynamic public var params: Swift.String? {
@objc get
@objc set
}
@objc @NSManaged dynamic public var date: Foundation.Date? {
@objc get
@objc set
}
@objc @NSManaged dynamic public var endpoint: Swift.String? {
@objc get
@objc set
}
public var paramsDict: [Swift.String : Any]? {
get
}
@objc override dynamic public init(entity: CoreData.NSEntityDescription, insertInto context: CoreData.NSManagedObjectContext?)
public typealias ID = Swift.ObjectIdentifier
@objc deinit
}
@objc public enum PurposeConsentStatus : Swift.Int {
case ConsentNull
case ConsentTrue
case ConsentFalse
public init?(rawValue: Swift.Int)
public typealias RawValue = Swift.Int
public var rawValue: Swift.Int {
get
}
}
@_inheritsConvenienceInitializers @_hasMissingDesignatedInitializers @objc public class GDPRHelper : ObjectiveC.NSObject {
@objc public func getPurposeConsentsTCF() -> Swift.String?
@objc public func optIn() -> Swift.Bool
@objc public func getGoogleAdPersonalization() -> PurposeConsentStatus
@objc public func getGoogleAdUserData() -> PurposeConsentStatus
@objc public func isGoogleDMADisabled() -> Swift.Bool
@objc deinit
}
@_hasMissingDesignatedInitializers @objc public class RequestHelper : ObjectiveC.NSObject {
@objc public init(apiKey: Swift.String)
@objc public func handlePostRequest(endpoint: Swift.String, params: [Swift.String : Any])
@objc deinit
}
@objc public protocol TJNRequestSender {
@objc var defaultPostCompletionBlock: ((Foundation.Data?, Foundation.URLResponse?, Swift.Error?, Swift.Bool) -> Swift.Void)? { get set }
@objc func post(url: Swift.String, body: Swift.String?, headers: [Swift.AnyHashable : Any]?)
@objc func method(_ method: Swift.String, url: Swift.String, body: Foundation.NSMutableString?)
@objc func method(_ method: Swift.String, url: Swift.String, body: Swift.String?, headers: [Swift.AnyHashable : Any]?)
@objc func method(_ method: Swift.String, url: Swift.String, body: Swift.String?, headers: [Swift.AnyHashable : Any]?, completionBlock block: ((Foundation.Data?, Foundation.URLResponse?, Swift.Error?, Swift.Bool) -> Swift.Void)?)
}
extension CoreData.NSManagedObjectContext {
public func executeAndMergeChanges(using batchDeleteRequest: CoreData.NSBatchDeleteRequest) throws
}
@_inheritsConvenienceInitializers @objc public class TenjinDatasource : ObjectiveC.NSObject {
@objc public static func setBooleanValue(_ value: Swift.Bool, key: Swift.String)
public static func getOptionalBoolean(_ key: Swift.String) -> Swift.Bool?
@objc public static func setCacheEventsSetting(_ isCacheEventsEnabled: Swift.Bool)
@objc public static func getCacheEventsSetting() -> Swift.Bool
@objc public static func getAnalyticsInstallationId() -> Swift.String
@objc override dynamic public init()
@objc deinit
}
@_hasMissingDesignatedInitializers @objc public class TenjinRepository : ObjectiveC.NSObject {
@objc public init(apiKey: Swift.String)
@objc public static func setCacheEventsSetting(_ isRetryEventsEnabled: Swift.Bool)
@objc public static func getCacheEventsSetting() -> Swift.Bool
@objc deinit
}
@objc public class TJNHTTPClient : ObjectiveC.NSObject, Foundation.URLSessionDelegate, TJNRequestSender {
@objc public var defaultPostCompletionBlock: ((Foundation.Data?, Foundation.URLResponse?, Swift.Error?, Swift.Bool) -> Swift.Void)?
@objc public init(apiKey: Swift.String)
@objc public func post(url: Swift.String, body: Swift.String?, headers: [Swift.AnyHashable : Any]?)
@objc public func method(_ method: Swift.String, url: Swift.String, body: Foundation.NSMutableString?)
@objc public func method(_ method: Swift.String, url: Swift.String, body: Swift.String?, headers: [Swift.AnyHashable : Any]?)
@objc public func method(_ method: Swift.String, url: Swift.String, body: Swift.String?, headers: [Swift.AnyHashable : Any]?, completionBlock block: ((Foundation.Data?, Foundation.URLResponse?, Swift.Error?, Swift.Bool) -> Swift.Void)? = nil)
@objc public func urlSession(_ session: Foundation.URLSession, didReceive challenge: Foundation.URLAuthenticationChallenge, completionHandler: @escaping (Foundation.URLSession.AuthChallengeDisposition, Foundation.URLCredential?) -> Swift.Void)
@objc deinit
}
extension PurposeConsentStatus : Swift.Equatable {}
extension PurposeConsentStatus : Swift.Hashable {}
extension PurposeConsentStatus : Swift.RawRepresentable {}
// swift-interface-format-version: 1.0
// swift-compiler-version: Apple Swift version 5.6.1 (swiftlang-5.6.0.323.66 clang-1316.0.20.12)
// swift-module-flags: -target armv7-apple-ios10.0 -enable-objc-interop -enable-library-evolution -swift-version 5 -enforce-exclusivity=checked -O -module-name TenjinSDK
import CoreData
import Foundation
import Network
import Swift
@_exported import TenjinSDK
import _Concurrency
@objc @_inheritsConvenienceInitializers public class QueueEvent : CoreData.NSManagedObject, Swift.Identifiable {
@nonobjc public class func fetchRequest() -> CoreData.NSFetchRequest<QueueEvent>
@objc @NSManaged dynamic public var params: Swift.String? {
@objc get
@objc set
}
@objc @NSManaged dynamic public var date: Foundation.Date? {
@objc get
@objc set
}
@objc @NSManaged dynamic public var endpoint: Swift.String? {
@objc get
@objc set
}
public var paramsDict: [Swift.String : Any]? {
get
}
@objc override dynamic public init(entity: CoreData.NSEntityDescription, insertInto context: CoreData.NSManagedObjectContext?)
public typealias ID = Swift.ObjectIdentifier
@objc deinit
}
@objc public enum PurposeConsentStatus : Swift.Int {
case ConsentNull
case ConsentTrue
case ConsentFalse
public init?(rawValue: Swift.Int)
public typealias RawValue = Swift.Int
public var rawValue: Swift.Int {
get
}
}
@_inheritsConvenienceInitializers @_hasMissingDesignatedInitializers @objc public class GDPRHelper : ObjectiveC.NSObject {
@objc public func getPurposeConsentsTCF() -> Swift.String?
@objc public func optIn() -> Swift.Bool
@objc public func getGoogleAdPersonalization() -> PurposeConsentStatus
@objc public func getGoogleAdUserData() -> PurposeConsentStatus
@objc public func isGoogleDMADisabled() -> Swift.Bool
@objc deinit
}
@_hasMissingDesignatedInitializers @objc public class RequestHelper : ObjectiveC.NSObject {
@objc public init(apiKey: Swift.String)
@objc public func handlePostRequest(endpoint: Swift.String, params: [Swift.String : Any])
@objc deinit
}
@objc public protocol TJNRequestSender {
@objc var defaultPostCompletionBlock: ((Foundation.Data?, Foundation.URLResponse?, Swift.Error?, Swift.Bool) -> Swift.Void)? { get set }
@objc func post(url: Swift.String, body: Swift.String?, headers: [Swift.AnyHashable : Any]?)
@objc func method(_ method: Swift.String, url: Swift.String, body: Foundation.NSMutableString?)
@objc func method(_ method: Swift.String, url: Swift.String, body: Swift.String?, headers: [Swift.AnyHashable : Any]?)
@objc func method(_ method: Swift.String, url: Swift.String, body: Swift.String?, headers: [Swift.AnyHashable : Any]?, completionBlock block: ((Foundation.Data?, Foundation.URLResponse?, Swift.Error?, Swift.Bool) -> Swift.Void)?)
}
extension CoreData.NSManagedObjectContext {
public func executeAndMergeChanges(using batchDeleteRequest: CoreData.NSBatchDeleteRequest) throws
}
@_inheritsConvenienceInitializers @objc public class TenjinDatasource : ObjectiveC.NSObject {
@objc public static func setBooleanValue(_ value: Swift.Bool, key: Swift.String)
public static func getOptionalBoolean(_ key: Swift.String) -> Swift.Bool?
@objc public static func setCacheEventsSetting(_ isCacheEventsEnabled: Swift.Bool)
@objc public static func getCacheEventsSetting() -> Swift.Bool
@objc public static func getAnalyticsInstallationId() -> Swift.String
@objc override dynamic public init()
@objc deinit
}
@_hasMissingDesignatedInitializers @objc public class TenjinRepository : ObjectiveC.NSObject {
@objc public init(apiKey: Swift.String)
@objc public static func setCacheEventsSetting(_ isRetryEventsEnabled: Swift.Bool)
@objc public static func getCacheEventsSetting() -> Swift.Bool
@objc deinit
}
@objc public class TJNHTTPClient : ObjectiveC.NSObject, Foundation.URLSessionDelegate, TJNRequestSender {
@objc public var defaultPostCompletionBlock: ((Foundation.Data?, Foundation.URLResponse?, Swift.Error?, Swift.Bool) -> Swift.Void)?
@objc public init(apiKey: Swift.String)
@objc public func post(url: Swift.String, body: Swift.String?, headers: [Swift.AnyHashable : Any]?)
@objc public func method(_ method: Swift.String, url: Swift.String, body: Foundation.NSMutableString?)
@objc public func method(_ method: Swift.String, url: Swift.String, body: Swift.String?, headers: [Swift.AnyHashable : Any]?)
@objc public func method(_ method: Swift.String, url: Swift.String, body: Swift.String?, headers: [Swift.AnyHashable : Any]?, completionBlock block: ((Foundation.Data?, Foundation.URLResponse?, Swift.Error?, Swift.Bool) -> Swift.Void)? = nil)
@objc public func urlSession(_ session: Foundation.URLSession, didReceive challenge: Foundation.URLAuthenticationChallenge, completionHandler: @escaping (Foundation.URLSession.AuthChallengeDisposition, Foundation.URLCredential?) -> Swift.Void)
@objc deinit
}
extension PurposeConsentStatus : Swift.Equatable {}
extension PurposeConsentStatus : Swift.Hashable {}
extension PurposeConsentStatus : Swift.RawRepresentable {}
framework module TenjinSDK {
umbrella header "TenjinSDK.h"
export *
module Private {
header "TJNLog.h"
header "TenjinConst.h"
header "AsyncOperation.h"
header "TJNOperationQueue.h"
header "CreateRequestOperation.h"
header "TenjinUtil.h"
}
}
module TenjinSDK.Swift {
header "TenjinSDK-Swift.h"
requires objc
}
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>NSPrivacyTrackingDomains</key>
<array>
<string>https://track.tenjin.com</string>
</array>
<key>NSPrivacyTracking</key>
<true/>
<key>NSPrivacyCollectedDataTypes</key>
<array>
<dict>
<key>NSPrivacyCollectedDataType</key>
<string>NSPrivacyCollectedDataTypeAdvertisingData</string>
<key>NSPrivacyCollectedDataTypeLinked</key>
<true/>
<key>NSPrivacyCollectedDataTypeTracking</key>
<false/>
<key>NSPrivacyCollectedDataTypePurposes</key>
<array>
<string>NSPrivacyCollectedDataTypePurposeAnalytics</string>
<string>NSPrivacyCollectedDataTypePurposeAppFunctionality</string>
</array>
</dict>
<dict>
<key>NSPrivacyCollectedDataType</key>
<string>NSPrivacyCollectedDataTypeDeviceID</string>
<key>NSPrivacyCollectedDataTypeLinked</key>
<true/>
<key>NSPrivacyCollectedDataTypeTracking</key>
<false/>
<key>NSPrivacyCollectedDataTypePurposes</key>
<array>
<string>NSPrivacyCollectedDataTypePurposeAnalytics</string>
<string>NSPrivacyCollectedDataTypePurposeAppFunctionality</string>
</array>
</dict>
</array>
<key>NSPrivacyAccessedAPITypes</key>
<array>
<dict>
<key>NSPrivacyAccessedAPIType</key>
<string>NSPrivacyAccessedAPICategoryUserDefaults</string>
<key>NSPrivacyAccessedAPITypeReasons</key>
<array>
<string>CA92.1</string>
</array>
</dict>
</array>
</dict>
</plist>
//
// Created by Tenjin on 2019-12-12.
// Copyright (c) 2019 Tenjin. All rights reserved.
//
#import <Foundation/Foundation.h>
//asynchronous operation to manage startup
@interface AsyncOperation : NSOperation
//do we prevent other operations from running until this one is complete?
@property (atomic, assign) BOOL blocker;
@property(readwrite) BOOL retryable;
@property(readwrite) BOOL success;
@end
//
// Created by Tenjin on 2019-12-17
// Copyright (c) 2019 Tenjin. All rights reserved.
//
#import <Foundation/Foundation.h>
#import "AsyncOperation.h"
#import "TJNOperationQueue.h"
@class TenjinImpl;
@interface CreateRequestOperation : AsyncOperation
@property(nonatomic, strong) NSString *eventName;
@property(nonatomic, strong) NSMutableDictionary *params;
@property(nonatomic, strong) TenjinImpl *client;
+ (CreateRequestOperation *)operationWithParams:(NSMutableDictionary *)deviceParams;
+ (CreateRequestOperation *)operationWithClient:(TenjinImpl *)client
andParams:(NSMutableDictionary *)deviceParams;
@end
// Created by Tenjin on 2019-09-17.
// Copyright (c) 2019 Tenjin. All rights reserved.
#import <Foundation/Foundation.h>
typedef void (^HandlerBlock)(NSData *_Nullable data, NSURLResponse *_Nullable NSURLResponse, NSError *_Nullable error, BOOL retry);
//
// Created by Tenjin on 2019-08-06.
// Copyright (c) 2019 Tenjin. All rights reserved.
//
#import <Foundation/Foundation.h>
typedef void (^LogHandler)(NSString *);
typedef NS_ENUM(NSInteger, TJNLogLevel) {
TJNLogLevelDebug = 0, //tenjin developer logs
TJNLogLevelLog = 1, //publisher + app developer logs
TJNLogLevelError = 2 //errors and informational logs that everyone should know about
};
@interface TJNLogger : NSObject
+ (void)setHandler:(LogHandler)newHandler;
+ (void)setLogLevel:(TJNLogLevel)level;
+ (void)logResponse:(NSHTTPURLResponse *)response
withData:(NSData *)data;
+ (void)logRequest:(NSURLRequest *)request;
+ (void)logTJNError:(NSString *)log;
+ (void)logTJNDebug:(NSString *)log;
+ (void)logTJNLog:(NSString *)log;
@end
void TJNError(NSString *log, ...);
void TJNDebug(NSString *log, ...);
void TJNLog(NSString *log, ...);
//
// Created by Tenjin on 2019-12-12.
// Copyright (c) 2019 Tenjin. All rights reserved.
//
#import <Foundation/Foundation.h>
typedef void (^TJNOperationCompletion)(id sendingOperation);
typedef void (^TJNBlock)(void);
@interface TJNOperationQueue : NSOperationQueue
- (void)addBlock:(TJNBlock)block
withCompletion:(TJNOperationCompletion)completionBlock;
- (void)addBlock:(TJNBlock)block;
- (void)addOperation:(NSOperation *)op
withCompletion:(TJNOperationCompletion)completionBlock;
@end
//endpoints
#define kTenjinEventEndpoint @"event"
#define kTenjinUserEndpoint @"user"
#define kTenjinPurchaseEndpoint @"purchase"
#define kTenjinAdRevenueEndpoint @"ad_impression"
#define kTenjinAdMobAdRevenueEndpoint @"ad_impressions/admob"
#define kTenjinAdRevenueAppLovinEndpoint @"ad_impressions/max"
#define kTenjinAdRevenueIronSourceEndpoint @"ad_impressions/ironsource"
#define kTenjinHyperBidRevenueEndpoint @"ad_impressions/hyperbid"
#define kTenjinTopOnRevenueEndpoint @"ad_impressions/topon"
#define kTenjinCASRevenueEndpoint @"ad_impressions/cas"
#define kTenjinTradPlusRevenueEndpoint @"ad_impressions/tradplus"
#define kTenjinConversionEndpoint @"conversion-values"
//this line replaced by build script
#define kTenjinTenjinSDKVersion @"1.14.3"
#define kTenjinPlatformIos @"ios"
#define kTenjinHTTPMethodPOST @"POST"
#define kTenjinHTTPMethodGET @"GET"
#define kTenjinPrefsFile @"TenjinPreferences"
#define kTenjinBundleId @"bundle_id"
#define kTenjinAdvertisingId @"advertising_id"
#define kTenjinVendorId @"developer_device_id"
#define kTenjinPlatform @"platform"
#define kTenjinAppVersion @"app_version"
#define kTenjinAppSubversion @"app_subversion"
#define kTenjinTrackingAuthorizationStatus @"tracking_status"
#define kTenjinOsVersion @"os_version"
#define kTenjinLimitAdTracking @"limit_ad_tracking"
#define kTenjinSdkVersion @"sdk_version"
#define kTenjinCountry @"country"
#define kTenjinDevice @"device"
#define kTenjinIad @"iad"
#define kTenjinBuildId @"build_id"
#define kTenjinOsVersionRelease @"os_version_release"
#define kTenjinLocale @"locale"
#define kTenjinDeviceInfo @"device_info"
#define kTenjinDeviceModel @"device_model"
#define kTenjinAAAttributionToken @"attribution_token"
#define kTenjinCustomerUserId @"customer_user_id"
#define kTenjinEvent @"event"
#define kTenjinAnalyticsId @"analytics_installation_id"
#define kTenjinSessionId @"session_id"
#define kTenjinSentAt @"sent_at"
#define kTenjinSignature @"signature"
#define kTenjinConversionValue @"conversion_value"
#define kTenjinCoarseConversionValue @"coarse_conversion_value"
#define kTenjinLockWindow @"lock_window"
#define kTenjinRetryEnabled @"retry_enabled"
#define kTenjinGoogleAdPersonalization @"ad_personalization"
#define kTenjinGoogleAdUserData @"ad_user_data"
#define kTenjinIABTCF @"iab_tcf"
#define kTenjinGoogleAdPersonalizationKey @"TENJIN_GOOGLE_AD_PERSONALIZATION"
#define kTenjinGoogleAdUserDataKey @"TENJIN_GOOGLE_AD_USER_DATA"
#define kTenjinGoogleDMADisabled @"TENJIN_GOOGLE_DMA_DISABLED"
#define kTenjinAttributionMaxBackoff 15
#define kTenjinStartupMaxRetries 5
#define kTenjinRetrySleepBaseInSeconds 2.0
#define kTenjinRetrySleepCapInSeconds 15.0
//
// Created by Tenjin on 2019-12-09.
// Copyright (c) 2019 Tenjin. All rights reserved.
//
#import <Foundation/Foundation.h>
#import "AsyncOperation.h"
#import "TJNOperationQueue.h"
@interface TenjinUtil : NSObject
+ (void)setSecret:(NSString *)secret;
+ (BOOL)hasSecret;
+ (NSString *)getSignature:(NSMutableDictionary *)params;
+ (NSString *)signDictionary:(NSMutableDictionary *)params
withSecret:(NSString *)sharedSecret;
+ (NSString *)timestampString;
+ (void)addOperation:(AsyncOperation *)op
withCompletionBlock:(TJNOperationCompletion)block;
+ (void)addBlock:(TJNBlock)block;
+ (NSTimeInterval)backoffTimeForRetry:(int)retry;
@end
//
// Created by Tenjin
// Copyright (c) 2022 Tenjin. All rights reserved.
//
#import <Foundation/Foundation.h>
#import "TenjinSDK.h"
@class GADAdValue;
@interface TenjinSDK (AdMobILRD)
+ (void)handleAdMobILRD:(NSObject *)adView :(GADAdValue *)adValue;
+ (void)adMobImpressionFromJSON:(NSString *)jsonString;
@end
//
// Created by Tenjin
// Copyright (c) 2022 Tenjin. All rights reserved.
//
#import "TenjinSDK.h"
#import <Foundation/Foundation.h>
@interface TenjinSDK (AppLovinILRD)
+ (void)subscribeAppLovinImpressions;
+ (void)appLovinImpressionFromJSON:(NSString *)jsonString;
@end
//
// Created by Tenjin
// Copyright (c) 2023 Tenjin. All rights reserved.
//
#import "TenjinSDK.h"
#import <Foundation/Foundation.h>
@interface TenjinSDK (CASILRD)
+ (void)subscribeCASBannerImpressions;
+ (void)casImpressionFromJSON:(NSString *)jsonString;
+ (void)handleCASILRD:(id)adImpression;
@end
//
// Created by Tenjin
// Copyright (c) 2022 Tenjin. All rights reserved.
//
#import <Foundation/Foundation.h>
#import "TenjinSDK.h"
@interface TenjinSDK (HyperBidILRD)
+ (void)hyperBidImpressionFromDict:(NSDictionary *)adImpression;
+ (void)hyperBidImpressionFromJSON:(NSString *)jsonString;
@end
//
// Created by Tenjin
// Copyright (c) 2022 Tenjin. All rights reserved.
//
#import "TenjinSDK.h"
#import <Foundation/Foundation.h>
@interface TenjinSDK (IronSourceILRD)
+ (void)subscribeIronSourceImpressions;
+ (void)ironSourceImpressionFromJSON:(NSString *)jsonString;
@end
//
// Created by Tenjin
// Copyright (c) 2022 Tenjin. All rights reserved.
//
#import <Foundation/Foundation.h>
#import "TenjinSDK.h"
@interface TenjinSDK (TopOnILRD)
+ (void)topOnImpressionFromDict:(NSDictionary *)adImpression;
+ (void)topOnImpressionFromJSON:(NSString *)jsonString;
@end
//
// Created by Tenjin
// Copyright (c) 2023 Tenjin. All rights reserved.
//
#import "TenjinSDK.h"
#import <Foundation/Foundation.h>
@interface TenjinSDK (TradPlusILRD)
+ (void)subscribeTradPlusImpressions;
+ (void)tradPlusImpressionFromJSON:(NSString *)jsonString;
+ (void)handleTradPlusILRD:(NSDictionary *)adInfo;
@end
//
// Created by Tenjin on 2016-05-20.
// Version 88.88.8008
// Copyright (c) 2016 Tenjin. All rights reserved.
//
#import <Foundation/Foundation.h>
#import <StoreKit/StoreKit.h>
@interface TenjinSDK : NSObject
#pragma mark Initialization
- (instancetype)init NS_UNAVAILABLE;
// initialize the Tenjin SDK
+ (TenjinSDK *)init:(NSString *)apiToken __deprecated_msg("use `initialize`");
//initialize the Tenjin SDK with shared secret
+ (TenjinSDK *)init:(NSString *)apiToken
andSharedSecret:(NSString *)secret __deprecated_msg("use `initialize`");
//initialize the Tenjin SDK with app subversion
+ (TenjinSDK *)init:(NSString *)apiToken
andAppSubversion:(NSNumber *)subversion __deprecated_msg("use `initialize`");
//initialize the Tenjin SDK with shared secret and app subversion
+ (TenjinSDK *)init:(NSString *)apiToken
andSharedSecret:(NSString *)secret
andAppSubversion:(NSNumber *)subversion __deprecated_msg("use `initialize`");
// initialize the Tenjin SDK
+ (TenjinSDK *)initialize:(NSString *)apiToken;
//initialize the Tenjin SDK with shared secret
+ (TenjinSDK *)initialize:(NSString *)apiToken
andSharedSecret:(NSString *)secret;
//initialize the Tenjin SDK with app subversion
+ (TenjinSDK *)initialize:(NSString *)apiToken
andAppSubversion:(NSNumber *)subversion;
//initialize the Tenjin SDK with shared secret and app subversion
+ (TenjinSDK *)initialize:(NSString *)apiToken
andSharedSecret:(NSString *)secret
andAppSubversion:(NSNumber *)subversion;
- (id)initWithToken:(NSString *)apiToken
andSharedSecret:(NSString *)secret
andAppSubversion:(NSNumber *)subversion
andDeferredDeeplink:(NSURL *)url
ping:(BOOL)ping NS_DESIGNATED_INITIALIZER;
#pragma mark Singleton access
// initialize the Tenjin SDK
+ (TenjinSDK *)getInstance:(NSString *)apiToken;
//initialize the Tenjin SDK with shared secret
+ (TenjinSDK *)getInstance:(NSString *)apiToken
andSharedSecret:(NSString *)secret;
//initialize the Tenjin SDK with app subversion
+ (TenjinSDK *)getInstance:(NSString *)apiToken
andAppSubversion:(NSNumber *)subversion;
//initialize the Tenjin SDK with shared secret and app subversion
+ (TenjinSDK *)getInstance:(NSString *)apiToken
andSharedSecret:(NSString *)secret
andAppSubversion:(NSNumber *)subversion;
//initialize the Tenjin SDK + connect
+ (TenjinSDK *)sharedInstanceWithToken:(NSString *)apiToken __deprecated_msg("use `init` and `connect`");
//initialize the Tenjin SDK + connect with a third party deeplink
+ (TenjinSDK *)sharedInstanceWithToken:(NSString *)apiToken
andDeferredDeeplink:(NSURL *)url __deprecated_msg("use `init` and `connectWithDeferredDeeplink`");
//returns the shared Tenjin SDK instance
+ (TenjinSDK *)sharedInstance;
#pragma mark - Functionality
//use connect to send connect call. sharedInstanceWithToken automatically does a connect
+ (void)connect;
//use connect to send connect call. sharedInstanceWithToken automatically does a connect
+ (void)connectWithDeferredDeeplink:(NSURL *)url;
//use sendEventWithName for custom event names
+ (void)sendEventWithName:(NSString *)eventName;
//This method is deprecated in favor of [sendEventWithName: andValue:], so you can pass an integer directly
+ (void)sendEventWithName:(NSString *)eventName
andEventValue:(NSString *)eventValue __deprecated_msg("use `sendEventWithName: andValue:` instead");
//Use this method to send custom events with values
+ (void)sendEventWithName:(NSString *)eventName
andValue:(NSInteger)eventValue;
//This method is deprecated in favor of [transaction: andReceipt:], so Tenjin can verify your transactions
+ (void)transaction:(SKPaymentTransaction *)transaction __attribute__((deprecated));
//Use this method to submit a transaction to Tenjin, we will also attempt to verify it for our records
+ (void)transaction:(SKPaymentTransaction *)transaction
andReceipt:(NSData *)receipt;
//use transactionWithProductName... when you don't use Apple's SKPaymentTransaction and need to pass revenue directly
+ (void)transactionWithProductName:(NSString *)productName
andCurrencyCode:(NSString *)currencyCode
andQuantity:(NSInteger)quantity
andUnitPrice:(NSDecimalNumber *)price;
//use transactionWithProductName...when you don't use Apple's SKPaymentTransaction and need to pass revenue directly with a NSData binary receipt
+ (void)transactionWithProductName:(NSString *)productName
andCurrencyCode:(NSString *)currencyCode
andQuantity:(NSInteger)quantity
andUnitPrice:(NSDecimalNumber *)price
andTransactionId:(NSString *)transactionId
andReceipt:(NSData *)receipt;
//use this method when you want to pass in a base64 receipt instead of a NSData receipt
+ (void)transactionWithProductName:(NSString *)productName
andCurrencyCode:(NSString *)currencyCode
andQuantity:(NSInteger)quantity
andUnitPrice:(NSDecimalNumber *)price
andTransactionId:(NSString *)transactionId
andBase64Receipt:(NSString *)receipt;
//use this method to register the attribution callback
- (void)registerDeepLinkHandler:(void (^)(NSDictionary *params, NSError *error))deeplinkHandler;
//notify Tenjin of a new subscription purchase
- (void)handleSubscriptionPurchase:(SKPaymentTransaction *)transaction;
// GDPR opt-out
+ (void)optOut;
// GDPR opt-in
+ (void)optIn;
// GDPR opt-out of list of params
+ (void)optOutParams:(NSArray *)params;
// GDPR opt-in with list of params
+ (void)optInParams:(NSArray *)params;
// GDPR opt-in/opt-out through CMP consents
+ (bool)optInOutUsingCMP;
// Opt out from Google DMA parameters (opted in by default)
+ (void)optOutGoogleDMA;
// Opt out from Google DMA parameters
+ (void)optInGoogleDMA;
// Appends app subversion to app version
+ (void)appendAppSubversion:(NSNumber *)subversion;
// deprecated
+ (void)updateSkAdNetworkConversionValue:(int)conversionValue __deprecated_msg("use `updatePostbackConversionValue:`");
//deprecated
+ (void)updateConversionValue:(int)conversionValue __deprecated_msg("use `updatePostbackConversionValue:`");
// Update conversion value
+ (void)updatePostbackConversionValue:(int)conversionValue;
// Update conversion value and coarse value (iOS 16.1+)
+ (void)updatePostbackConversionValue:(int)conversionValue
coarseValue:(NSString*)coarseValue;
// Update conversion value, coarse value and lock window (iOS 16.1+)
+ (void)updatePostbackConversionValue:(int)conversionValue
coarseValue:(NSString*)coarseValue
lockWindow:(BOOL)lockWindow;
// Set customer user id to send as parameter on each event request
+ (void)setCustomerUserId:(NSString *)userId;
// Get customer user id saved on the device
+ (NSString *)getCustomerUserId;
// Set the setting to enable/disable cache events and retrying, it's false by default
+ (void)setCacheEventSetting:(BOOL)isCacheEventsEnabled;
// Get cached analytics_installation_id
+ (NSString*)getAnalyticsInstallationId;
#pragma mark Util
+ (void)verboseLogs;
+ (void)debugLogs;
+ (void)setLogHandler:(void (^)(NSString *))handler;
+ (NSString *)sdkVersion;
+ (void)setWrapperVersion:(NSString *)wrapperVersion;
+ (void)setValue:(NSString *)value
forKey:(NSString *)key;
//deprecated
+ (void)registerAppForAdNetworkAttribution __deprecated_msg("use `updatePostbackConversionValue:`");
+ (void)requestTrackingAuthorizationWithCompletionHandler:(void (^)(NSUInteger status))completion;
- (void)getAttributionInfo:(void (^)(NSDictionary *attributionInfo, NSError *error))completionHandler;
- (void)setGoogleDMAParametersWithAdPersonalization:(BOOL)adPersonalization adUserData:(BOOL)adUserData;
@end
// swift-interface-format-version: 1.0
// swift-compiler-version: Apple Swift version 5.6.1 (swiftlang-5.6.0.323.66 clang-1316.0.20.12)
// swift-module-flags: -target arm64-apple-ios10.0-simulator -enable-objc-interop -enable-library-evolution -swift-version 5 -enforce-exclusivity=checked -O -module-name TenjinSDK
import CoreData
import Foundation
import Network
import Swift
@_exported import TenjinSDK
import _Concurrency
@objc @_inheritsConvenienceInitializers public class QueueEvent : CoreData.NSManagedObject, Swift.Identifiable {
@nonobjc public class func fetchRequest() -> CoreData.NSFetchRequest<QueueEvent>
@objc @NSManaged dynamic public var params: Swift.String? {
@objc get
@objc set
}
@objc @NSManaged dynamic public var date: Foundation.Date? {
@objc get
@objc set
}
@objc @NSManaged dynamic public var endpoint: Swift.String? {
@objc get
@objc set
}
public var paramsDict: [Swift.String : Any]? {
get
}
@objc override dynamic public init(entity: CoreData.NSEntityDescription, insertInto context: CoreData.NSManagedObjectContext?)
public typealias ID = Swift.ObjectIdentifier
@objc deinit
}
@objc public enum PurposeConsentStatus : Swift.Int {
case ConsentNull
case ConsentTrue
case ConsentFalse
public init?(rawValue: Swift.Int)
public typealias RawValue = Swift.Int
public var rawValue: Swift.Int {
get
}
}
@_inheritsConvenienceInitializers @_hasMissingDesignatedInitializers @objc public class GDPRHelper : ObjectiveC.NSObject {
@objc public func getPurposeConsentsTCF() -> Swift.String?
@objc public func optIn() -> Swift.Bool
@objc public func getGoogleAdPersonalization() -> PurposeConsentStatus
@objc public func getGoogleAdUserData() -> PurposeConsentStatus
@objc public func isGoogleDMADisabled() -> Swift.Bool
@objc deinit
}
@_hasMissingDesignatedInitializers @objc public class RequestHelper : ObjectiveC.NSObject {
@objc public init(apiKey: Swift.String)
@objc public func handlePostRequest(endpoint: Swift.String, params: [Swift.String : Any])
@objc deinit
}
@objc public protocol TJNRequestSender {
@objc var defaultPostCompletionBlock: ((Foundation.Data?, Foundation.URLResponse?, Swift.Error?, Swift.Bool) -> Swift.Void)? { get set }
@objc func post(url: Swift.String, body: Swift.String?, headers: [Swift.AnyHashable : Any]?)
@objc func method(_ method: Swift.String, url: Swift.String, body: Foundation.NSMutableString?)
@objc func method(_ method: Swift.String, url: Swift.String, body: Swift.String?, headers: [Swift.AnyHashable : Any]?)
@objc func method(_ method: Swift.String, url: Swift.String, body: Swift.String?, headers: [Swift.AnyHashable : Any]?, completionBlock block: ((Foundation.Data?, Foundation.URLResponse?, Swift.Error?, Swift.Bool) -> Swift.Void)?)
}
extension CoreData.NSManagedObjectContext {
public func executeAndMergeChanges(using batchDeleteRequest: CoreData.NSBatchDeleteRequest) throws
}
@_inheritsConvenienceInitializers @objc public class TenjinDatasource : ObjectiveC.NSObject {
@objc public static func setBooleanValue(_ value: Swift.Bool, key: Swift.String)
public static func getOptionalBoolean(_ key: Swift.String) -> Swift.Bool?
@objc public static func setCacheEventsSetting(_ isCacheEventsEnabled: Swift.Bool)
@objc public static func getCacheEventsSetting() -> Swift.Bool
@objc public static func getAnalyticsInstallationId() -> Swift.String
@objc override dynamic public init()
@objc deinit
}
@_hasMissingDesignatedInitializers @objc public class TenjinRepository : ObjectiveC.NSObject {
@objc public init(apiKey: Swift.String)
@objc public static func setCacheEventsSetting(_ isRetryEventsEnabled: Swift.Bool)
@objc public static func getCacheEventsSetting() -> Swift.Bool
@objc deinit
}
@objc public class TJNHTTPClient : ObjectiveC.NSObject, Foundation.URLSessionDelegate, TJNRequestSender {
@objc public var defaultPostCompletionBlock: ((Foundation.Data?, Foundation.URLResponse?, Swift.Error?, Swift.Bool) -> Swift.Void)?
@objc public init(apiKey: Swift.String)
@objc public func post(url: Swift.String, body: Swift.String?, headers: [Swift.AnyHashable : Any]?)
@objc public func method(_ method: Swift.String, url: Swift.String, body: Foundation.NSMutableString?)
@objc public func method(_ method: Swift.String, url: Swift.String, body: Swift.String?, headers: [Swift.AnyHashable : Any]?)
@objc public func method(_ method: Swift.String, url: Swift.String, body: Swift.String?, headers: [Swift.AnyHashable : Any]?, completionBlock block: ((Foundation.Data?, Foundation.URLResponse?, Swift.Error?, Swift.Bool) -> Swift.Void)? = nil)
@objc public func urlSession(_ session: Foundation.URLSession, didReceive challenge: Foundation.URLAuthenticationChallenge, completionHandler: @escaping (Foundation.URLSession.AuthChallengeDisposition, Foundation.URLCredential?) -> Swift.Void)
@objc deinit
}
extension PurposeConsentStatus : Swift.Equatable {}
extension PurposeConsentStatus : Swift.Hashable {}
extension PurposeConsentStatus : Swift.RawRepresentable {}
// swift-interface-format-version: 1.0
// swift-compiler-version: Apple Swift version 5.6.1 (swiftlang-5.6.0.323.66 clang-1316.0.20.12)
// swift-module-flags: -target i386-apple-ios10.0-simulator -enable-objc-interop -enable-library-evolution -swift-version 5 -enforce-exclusivity=checked -O -module-name TenjinSDK
import CoreData
import Foundation
import Network
import Swift
@_exported import TenjinSDK
import _Concurrency
@objc @_inheritsConvenienceInitializers public class QueueEvent : CoreData.NSManagedObject, Swift.Identifiable {
@nonobjc public class func fetchRequest() -> CoreData.NSFetchRequest<QueueEvent>
@objc @NSManaged dynamic public var params: Swift.String? {
@objc get
@objc set
}
@objc @NSManaged dynamic public var date: Foundation.Date? {
@objc get
@objc set
}
@objc @NSManaged dynamic public var endpoint: Swift.String? {
@objc get
@objc set
}
public var paramsDict: [Swift.String : Any]? {
get
}
@objc override dynamic public init(entity: CoreData.NSEntityDescription, insertInto context: CoreData.NSManagedObjectContext?)
public typealias ID = Swift.ObjectIdentifier
@objc deinit
}
@objc public enum PurposeConsentStatus : Swift.Int {
case ConsentNull
case ConsentTrue
case ConsentFalse
public init?(rawValue: Swift.Int)
public typealias RawValue = Swift.Int
public var rawValue: Swift.Int {
get
}
}
@_inheritsConvenienceInitializers @_hasMissingDesignatedInitializers @objc public class GDPRHelper : ObjectiveC.NSObject {
@objc public func getPurposeConsentsTCF() -> Swift.String?
@objc public func optIn() -> Swift.Bool
@objc public func getGoogleAdPersonalization() -> PurposeConsentStatus
@objc public func getGoogleAdUserData() -> PurposeConsentStatus
@objc public func isGoogleDMADisabled() -> Swift.Bool
@objc deinit
}
@_hasMissingDesignatedInitializers @objc public class RequestHelper : ObjectiveC.NSObject {
@objc public init(apiKey: Swift.String)
@objc public func handlePostRequest(endpoint: Swift.String, params: [Swift.String : Any])
@objc deinit
}
@objc public protocol TJNRequestSender {
@objc var defaultPostCompletionBlock: ((Foundation.Data?, Foundation.URLResponse?, Swift.Error?, Swift.Bool) -> Swift.Void)? { get set }
@objc func post(url: Swift.String, body: Swift.String?, headers: [Swift.AnyHashable : Any]?)
@objc func method(_ method: Swift.String, url: Swift.String, body: Foundation.NSMutableString?)
@objc func method(_ method: Swift.String, url: Swift.String, body: Swift.String?, headers: [Swift.AnyHashable : Any]?)
@objc func method(_ method: Swift.String, url: Swift.String, body: Swift.String?, headers: [Swift.AnyHashable : Any]?, completionBlock block: ((Foundation.Data?, Foundation.URLResponse?, Swift.Error?, Swift.Bool) -> Swift.Void)?)
}
extension CoreData.NSManagedObjectContext {
public func executeAndMergeChanges(using batchDeleteRequest: CoreData.NSBatchDeleteRequest) throws
}
@_inheritsConvenienceInitializers @objc public class TenjinDatasource : ObjectiveC.NSObject {
@objc public static func setBooleanValue(_ value: Swift.Bool, key: Swift.String)
public static func getOptionalBoolean(_ key: Swift.String) -> Swift.Bool?
@objc public static func setCacheEventsSetting(_ isCacheEventsEnabled: Swift.Bool)
@objc public static func getCacheEventsSetting() -> Swift.Bool
@objc public static func getAnalyticsInstallationId() -> Swift.String
@objc override dynamic public init()
@objc deinit
}
@_hasMissingDesignatedInitializers @objc public class TenjinRepository : ObjectiveC.NSObject {
@objc public init(apiKey: Swift.String)
@objc public static func setCacheEventsSetting(_ isRetryEventsEnabled: Swift.Bool)
@objc public static func getCacheEventsSetting() -> Swift.Bool
@objc deinit
}
@objc public class TJNHTTPClient : ObjectiveC.NSObject, Foundation.URLSessionDelegate, TJNRequestSender {
@objc public var defaultPostCompletionBlock: ((Foundation.Data?, Foundation.URLResponse?, Swift.Error?, Swift.Bool) -> Swift.Void)?
@objc public init(apiKey: Swift.String)
@objc public func post(url: Swift.String, body: Swift.String?, headers: [Swift.AnyHashable : Any]?)
@objc public func method(_ method: Swift.String, url: Swift.String, body: Foundation.NSMutableString?)
@objc public func method(_ method: Swift.String, url: Swift.String, body: Swift.String?, headers: [Swift.AnyHashable : Any]?)
@objc public func method(_ method: Swift.String, url: Swift.String, body: Swift.String?, headers: [Swift.AnyHashable : Any]?, completionBlock block: ((Foundation.Data?, Foundation.URLResponse?, Swift.Error?, Swift.Bool) -> Swift.Void)? = nil)
@objc public func urlSession(_ session: Foundation.URLSession, didReceive challenge: Foundation.URLAuthenticationChallenge, completionHandler: @escaping (Foundation.URLSession.AuthChallengeDisposition, Foundation.URLCredential?) -> Swift.Void)
@objc deinit
}
extension PurposeConsentStatus : Swift.Equatable {}
extension PurposeConsentStatus : Swift.Hashable {}
extension PurposeConsentStatus : Swift.RawRepresentable {}
// swift-interface-format-version: 1.0
// swift-compiler-version: Apple Swift version 5.6.1 (swiftlang-5.6.0.323.66 clang-1316.0.20.12)
// swift-module-flags: -target x86_64-apple-ios10.0-simulator -enable-objc-interop -enable-library-evolution -swift-version 5 -enforce-exclusivity=checked -O -module-name TenjinSDK
import CoreData
import Foundation
import Network
import Swift
@_exported import TenjinSDK
import _Concurrency
@objc @_inheritsConvenienceInitializers public class QueueEvent : CoreData.NSManagedObject, Swift.Identifiable {
@nonobjc public class func fetchRequest() -> CoreData.NSFetchRequest<QueueEvent>
@objc @NSManaged dynamic public var params: Swift.String? {
@objc get
@objc set
}
@objc @NSManaged dynamic public var date: Foundation.Date? {
@objc get
@objc set
}
@objc @NSManaged dynamic public var endpoint: Swift.String? {
@objc get
@objc set
}
public var paramsDict: [Swift.String : Any]? {
get
}
@objc override dynamic public init(entity: CoreData.NSEntityDescription, insertInto context: CoreData.NSManagedObjectContext?)
public typealias ID = Swift.ObjectIdentifier
@objc deinit
}
@objc public enum PurposeConsentStatus : Swift.Int {
case ConsentNull
case ConsentTrue
case ConsentFalse
public init?(rawValue: Swift.Int)
public typealias RawValue = Swift.Int
public var rawValue: Swift.Int {
get
}
}
@_inheritsConvenienceInitializers @_hasMissingDesignatedInitializers @objc public class GDPRHelper : ObjectiveC.NSObject {
@objc public func getPurposeConsentsTCF() -> Swift.String?
@objc public func optIn() -> Swift.Bool
@objc public func getGoogleAdPersonalization() -> PurposeConsentStatus
@objc public func getGoogleAdUserData() -> PurposeConsentStatus
@objc public func isGoogleDMADisabled() -> Swift.Bool
@objc deinit
}
@_hasMissingDesignatedInitializers @objc public class RequestHelper : ObjectiveC.NSObject {
@objc public init(apiKey: Swift.String)
@objc public func handlePostRequest(endpoint: Swift.String, params: [Swift.String : Any])
@objc deinit
}
@objc public protocol TJNRequestSender {
@objc var defaultPostCompletionBlock: ((Foundation.Data?, Foundation.URLResponse?, Swift.Error?, Swift.Bool) -> Swift.Void)? { get set }
@objc func post(url: Swift.String, body: Swift.String?, headers: [Swift.AnyHashable : Any]?)
@objc func method(_ method: Swift.String, url: Swift.String, body: Foundation.NSMutableString?)
@objc func method(_ method: Swift.String, url: Swift.String, body: Swift.String?, headers: [Swift.AnyHashable : Any]?)
@objc func method(_ method: Swift.String, url: Swift.String, body: Swift.String?, headers: [Swift.AnyHashable : Any]?, completionBlock block: ((Foundation.Data?, Foundation.URLResponse?, Swift.Error?, Swift.Bool) -> Swift.Void)?)
}
extension CoreData.NSManagedObjectContext {
public func executeAndMergeChanges(using batchDeleteRequest: CoreData.NSBatchDeleteRequest) throws
}
@_inheritsConvenienceInitializers @objc public class TenjinDatasource : ObjectiveC.NSObject {
@objc public static func setBooleanValue(_ value: Swift.Bool, key: Swift.String)
public static func getOptionalBoolean(_ key: Swift.String) -> Swift.Bool?
@objc public static func setCacheEventsSetting(_ isCacheEventsEnabled: Swift.Bool)
@objc public static func getCacheEventsSetting() -> Swift.Bool
@objc public static func getAnalyticsInstallationId() -> Swift.String
@objc override dynamic public init()
@objc deinit
}
@_hasMissingDesignatedInitializers @objc public class TenjinRepository : ObjectiveC.NSObject {
@objc public init(apiKey: Swift.String)
@objc public static func setCacheEventsSetting(_ isRetryEventsEnabled: Swift.Bool)
@objc public static func getCacheEventsSetting() -> Swift.Bool
@objc deinit
}
@objc public class TJNHTTPClient : ObjectiveC.NSObject, Foundation.URLSessionDelegate, TJNRequestSender {
@objc public var defaultPostCompletionBlock: ((Foundation.Data?, Foundation.URLResponse?, Swift.Error?, Swift.Bool) -> Swift.Void)?
@objc public init(apiKey: Swift.String)
@objc public func post(url: Swift.String, body: Swift.String?, headers: [Swift.AnyHashable : Any]?)
@objc public func method(_ method: Swift.String, url: Swift.String, body: Foundation.NSMutableString?)
@objc public func method(_ method: Swift.String, url: Swift.String, body: Swift.String?, headers: [Swift.AnyHashable : Any]?)
@objc public func method(_ method: Swift.String, url: Swift.String, body: Swift.String?, headers: [Swift.AnyHashable : Any]?, completionBlock block: ((Foundation.Data?, Foundation.URLResponse?, Swift.Error?, Swift.Bool) -> Swift.Void)? = nil)
@objc public func urlSession(_ session: Foundation.URLSession, didReceive challenge: Foundation.URLAuthenticationChallenge, completionHandler: @escaping (Foundation.URLSession.AuthChallengeDisposition, Foundation.URLCredential?) -> Swift.Void)
@objc deinit
}
extension PurposeConsentStatus : Swift.Equatable {}
extension PurposeConsentStatus : Swift.Hashable {}
extension PurposeConsentStatus : Swift.RawRepresentable {}
framework module TenjinSDK {
umbrella header "TenjinSDK.h"
export *
module Private {
header "TJNLog.h"
header "TenjinConst.h"
header "AsyncOperation.h"
header "TJNOperationQueue.h"
header "CreateRequestOperation.h"
header "TenjinUtil.h"
}
}
module TenjinSDK.Swift {
header "TenjinSDK-Swift.h"
requires objc
}
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>NSPrivacyTrackingDomains</key>
<array>
<string>https://track.tenjin.com</string>
</array>
<key>NSPrivacyTracking</key>
<true/>
<key>NSPrivacyCollectedDataTypes</key>
<array>
<dict>
<key>NSPrivacyCollectedDataType</key>
<string>NSPrivacyCollectedDataTypeAdvertisingData</string>
<key>NSPrivacyCollectedDataTypeLinked</key>
<true/>
<key>NSPrivacyCollectedDataTypeTracking</key>
<false/>
<key>NSPrivacyCollectedDataTypePurposes</key>
<array>
<string>NSPrivacyCollectedDataTypePurposeAnalytics</string>
<string>NSPrivacyCollectedDataTypePurposeAppFunctionality</string>
</array>
</dict>
<dict>
<key>NSPrivacyCollectedDataType</key>
<string>NSPrivacyCollectedDataTypeDeviceID</string>
<key>NSPrivacyCollectedDataTypeLinked</key>
<true/>
<key>NSPrivacyCollectedDataTypeTracking</key>
<false/>
<key>NSPrivacyCollectedDataTypePurposes</key>
<array>
<string>NSPrivacyCollectedDataTypePurposeAnalytics</string>
<string>NSPrivacyCollectedDataTypePurposeAppFunctionality</string>
</array>
</dict>
</array>
<key>NSPrivacyAccessedAPITypes</key>
<array>
<dict>
<key>NSPrivacyAccessedAPIType</key>
<string>NSPrivacyAccessedAPICategoryUserDefaults</string>
<key>NSPrivacyAccessedAPITypeReasons</key>
<array>
<string>CA92.1</string>
</array>
</dict>
</array>
</dict>
</plist>
//
// Created by Tenjin on 2019-12-12.
// Copyright (c) 2019 Tenjin. All rights reserved.
//
#import <Foundation/Foundation.h>
//asynchronous operation to manage startup
@interface AsyncOperation : NSOperation
//do we prevent other operations from running until this one is complete?
@property (atomic, assign) BOOL blocker;
@property(readwrite) BOOL retryable;
@property(readwrite) BOOL success;
@end
//
// Created by Tenjin on 2019-12-17
// Copyright (c) 2019 Tenjin. All rights reserved.
//
#import <Foundation/Foundation.h>
#import "AsyncOperation.h"
#import "TJNOperationQueue.h"
@class TenjinImpl;
@interface CreateRequestOperation : AsyncOperation
@property(nonatomic, strong) NSString *eventName;
@property(nonatomic, strong) NSMutableDictionary *params;
@property(nonatomic, strong) TenjinImpl *client;
+ (CreateRequestOperation *)operationWithParams:(NSMutableDictionary *)deviceParams;
+ (CreateRequestOperation *)operationWithClient:(TenjinImpl *)client
andParams:(NSMutableDictionary *)deviceParams;
@end
// Created by Tenjin on 2019-09-17.
// Copyright (c) 2019 Tenjin. All rights reserved.
#import <Foundation/Foundation.h>
typedef void (^HandlerBlock)(NSData *_Nullable data, NSURLResponse *_Nullable NSURLResponse, NSError *_Nullable error, BOOL retry);
//
// Created by Tenjin on 2019-08-06.
// Copyright (c) 2019 Tenjin. All rights reserved.
//
#import <Foundation/Foundation.h>
typedef void (^LogHandler)(NSString *);
typedef NS_ENUM(NSInteger, TJNLogLevel) {
TJNLogLevelDebug = 0, //tenjin developer logs
TJNLogLevelLog = 1, //publisher + app developer logs
TJNLogLevelError = 2 //errors and informational logs that everyone should know about
};
@interface TJNLogger : NSObject
+ (void)setHandler:(LogHandler)newHandler;
+ (void)setLogLevel:(TJNLogLevel)level;
+ (void)logResponse:(NSHTTPURLResponse *)response
withData:(NSData *)data;
+ (void)logRequest:(NSURLRequest *)request;
+ (void)logTJNError:(NSString *)log;
+ (void)logTJNDebug:(NSString *)log;
+ (void)logTJNLog:(NSString *)log;
@end
void TJNError(NSString *log, ...);
void TJNDebug(NSString *log, ...);
void TJNLog(NSString *log, ...);
//
// Created by Tenjin on 2019-12-12.
// Copyright (c) 2019 Tenjin. All rights reserved.
//
#import <Foundation/Foundation.h>
typedef void (^TJNOperationCompletion)(id sendingOperation);
typedef void (^TJNBlock)(void);
@interface TJNOperationQueue : NSOperationQueue
- (void)addBlock:(TJNBlock)block
withCompletion:(TJNOperationCompletion)completionBlock;
- (void)addBlock:(TJNBlock)block;
- (void)addOperation:(NSOperation *)op
withCompletion:(TJNOperationCompletion)completionBlock;
@end
//endpoints
#define kTenjinEventEndpoint @"event"
#define kTenjinUserEndpoint @"user"
#define kTenjinPurchaseEndpoint @"purchase"
#define kTenjinAdRevenueEndpoint @"ad_impression"
#define kTenjinAdMobAdRevenueEndpoint @"ad_impressions/admob"
#define kTenjinAdRevenueAppLovinEndpoint @"ad_impressions/max"
#define kTenjinAdRevenueIronSourceEndpoint @"ad_impressions/ironsource"
#define kTenjinHyperBidRevenueEndpoint @"ad_impressions/hyperbid"
#define kTenjinTopOnRevenueEndpoint @"ad_impressions/topon"
#define kTenjinCASRevenueEndpoint @"ad_impressions/cas"
#define kTenjinTradPlusRevenueEndpoint @"ad_impressions/tradplus"
#define kTenjinConversionEndpoint @"conversion-values"
//this line replaced by build script
#define kTenjinTenjinSDKVersion @"1.14.3"
#define kTenjinPlatformIos @"ios"
#define kTenjinHTTPMethodPOST @"POST"
#define kTenjinHTTPMethodGET @"GET"
#define kTenjinPrefsFile @"TenjinPreferences"
#define kTenjinBundleId @"bundle_id"
#define kTenjinAdvertisingId @"advertising_id"
#define kTenjinVendorId @"developer_device_id"
#define kTenjinPlatform @"platform"
#define kTenjinAppVersion @"app_version"
#define kTenjinAppSubversion @"app_subversion"
#define kTenjinTrackingAuthorizationStatus @"tracking_status"
#define kTenjinOsVersion @"os_version"
#define kTenjinLimitAdTracking @"limit_ad_tracking"
#define kTenjinSdkVersion @"sdk_version"
#define kTenjinCountry @"country"
#define kTenjinDevice @"device"
#define kTenjinIad @"iad"
#define kTenjinBuildId @"build_id"
#define kTenjinOsVersionRelease @"os_version_release"
#define kTenjinLocale @"locale"
#define kTenjinDeviceInfo @"device_info"
#define kTenjinDeviceModel @"device_model"
#define kTenjinAAAttributionToken @"attribution_token"
#define kTenjinCustomerUserId @"customer_user_id"
#define kTenjinEvent @"event"
#define kTenjinAnalyticsId @"analytics_installation_id"
#define kTenjinSessionId @"session_id"
#define kTenjinSentAt @"sent_at"
#define kTenjinSignature @"signature"
#define kTenjinConversionValue @"conversion_value"
#define kTenjinCoarseConversionValue @"coarse_conversion_value"
#define kTenjinLockWindow @"lock_window"
#define kTenjinRetryEnabled @"retry_enabled"
#define kTenjinGoogleAdPersonalization @"ad_personalization"
#define kTenjinGoogleAdUserData @"ad_user_data"
#define kTenjinIABTCF @"iab_tcf"
#define kTenjinGoogleAdPersonalizationKey @"TENJIN_GOOGLE_AD_PERSONALIZATION"
#define kTenjinGoogleAdUserDataKey @"TENJIN_GOOGLE_AD_USER_DATA"
#define kTenjinGoogleDMADisabled @"TENJIN_GOOGLE_DMA_DISABLED"
#define kTenjinAttributionMaxBackoff 15
#define kTenjinStartupMaxRetries 5
#define kTenjinRetrySleepBaseInSeconds 2.0
#define kTenjinRetrySleepCapInSeconds 15.0
//
// Created by Tenjin on 2019-12-09.
// Copyright (c) 2019 Tenjin. All rights reserved.
//
#import <Foundation/Foundation.h>
#import "AsyncOperation.h"
#import "TJNOperationQueue.h"
@interface TenjinUtil : NSObject
+ (void)setSecret:(NSString *)secret;
+ (BOOL)hasSecret;
+ (NSString *)getSignature:(NSMutableDictionary *)params;
+ (NSString *)signDictionary:(NSMutableDictionary *)params
withSecret:(NSString *)sharedSecret;
+ (NSString *)timestampString;
+ (void)addOperation:(AsyncOperation *)op
withCompletionBlock:(TJNOperationCompletion)block;
+ (void)addBlock:(TJNBlock)block;
+ (NSTimeInterval)backoffTimeForRetry:(int)retry;
@end
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment