diff --git a/Tests/InstallationTests/CommonFiles/RevenueCat-Swift.h b/Tests/InstallationTests/CommonFiles/RevenueCat-Swift.h index 577d95378d..a1ac174e56 100644 --- a/Tests/InstallationTests/CommonFiles/RevenueCat-Swift.h +++ b/Tests/InstallationTests/CommonFiles/RevenueCat-Swift.h @@ -726,12 +726,12 @@ SWIFT_CLASS_NAMED("Builder") @interface RCConfigurationBuilder (SWIFT_EXTENSION(RevenueCat)) -- (RCConfigurationBuilder * _Nonnull)withObserverMode:(BOOL)observerMode SWIFT_WARN_UNUSED_RESULT SWIFT_AVAILABILITY(macos,obsoleted=1,message="'with' has been renamed to 'withPurchasesAreCompletedBy:storeKitVersion:': Observer Mode is now named PurchasesAreCompletedBy.") SWIFT_AVAILABILITY(watchos,obsoleted=1,message="'with' has been renamed to 'withPurchasesAreCompletedBy:storeKitVersion:': Observer Mode is now named PurchasesAreCompletedBy.") SWIFT_AVAILABILITY(tvos,obsoleted=1,message="'with' has been renamed to 'withPurchasesAreCompletedBy:storeKitVersion:': Observer Mode is now named PurchasesAreCompletedBy.") SWIFT_AVAILABILITY(ios,obsoleted=1,message="'with' has been renamed to 'withPurchasesAreCompletedBy:storeKitVersion:': Observer Mode is now named PurchasesAreCompletedBy."); +- (RCConfigurationBuilder * _Nonnull)withUsesStoreKit2IfAvailable:(BOOL)usesStoreKit2IfAvailable SWIFT_WARN_UNUSED_RESULT SWIFT_DEPRECATED_MSG("Use .with(storeKitVersion:) to enable StoreKit 2"); @end @interface RCConfigurationBuilder (SWIFT_EXTENSION(RevenueCat)) -- (RCConfigurationBuilder * _Nonnull)withUsesStoreKit2IfAvailable:(BOOL)usesStoreKit2IfAvailable SWIFT_WARN_UNUSED_RESULT SWIFT_DEPRECATED_MSG("Use .with(storeKitVersion:) to enable StoreKit 2"); +- (RCConfigurationBuilder * _Nonnull)withObserverMode:(BOOL)observerMode SWIFT_WARN_UNUSED_RESULT SWIFT_AVAILABILITY(macos,obsoleted=1,message="'with' has been renamed to 'withPurchasesAreCompletedBy:storeKitVersion:': Observer Mode is now named PurchasesAreCompletedBy.") SWIFT_AVAILABILITY(watchos,obsoleted=1,message="'with' has been renamed to 'withPurchasesAreCompletedBy:storeKitVersion:': Observer Mode is now named PurchasesAreCompletedBy.") SWIFT_AVAILABILITY(tvos,obsoleted=1,message="'with' has been renamed to 'withPurchasesAreCompletedBy:storeKitVersion:': Observer Mode is now named PurchasesAreCompletedBy.") SWIFT_AVAILABILITY(ios,obsoleted=1,message="'with' has been renamed to 'withPurchasesAreCompletedBy:storeKitVersion:': Observer Mode is now named PurchasesAreCompletedBy."); @end /// Specifies the behavior for a caching API. @@ -961,11 +961,11 @@ SWIFT_CLASS_NAMED("CustomerInfo") - @interface RCCustomerInfo (SWIFT_EXTENSION(RevenueCat)) @property (nonatomic, readonly, copy) NSDictionary * _Nonnull rawData; @end + @class RCStoreTransaction; @interface RCCustomerInfo (SWIFT_EXTENSION(RevenueCat)) @@ -2896,6 +2896,35 @@ SWIFT_AVAILABILITY(visionos,introduced=2.0) SWIFT_AVAILABILITY(watchos,introduce @end +@interface RCPurchases (SWIFT_EXTENSION(RevenueCat)) +/// Enable debug logging. Useful for debugging issues with the lovely team @RevenueCat. +SWIFT_CLASS_PROPERTY(@property (nonatomic, class) BOOL debugLogsEnabled SWIFT_DEPRECATED_MSG("use Purchases.logLevel instead");) ++ (BOOL)debugLogsEnabled SWIFT_WARN_UNUSED_RESULT; ++ (void)setDebugLogsEnabled:(BOOL)newValue; +/// Deprecated +@property (nonatomic) BOOL allowSharingAppStoreAccount SWIFT_DEPRECATED_MSG("\n Configure behavior through the RevenueCat dashboard instead. If you have configured the \"Legacy\" restore\n behavior in the [RevenueCat Dashboard](app.revenuecat.com) and are currently setting this to `true`, keep\n this setting active.\n "); +/// Deprecated. Where responsibility for completing purchase transactions lies. +@property (nonatomic) BOOL finishTransactions SWIFT_DEPRECATED_MSG("Use ``purchasesAreCompletedBy`` instead."); +/// Deprecated ++ (void)addAttributionData:(NSDictionary * _Nonnull)data fromNetwork:(enum RCAttributionNetwork)network SWIFT_DEPRECATED_MSG("Use the set functions instead"); +/// Send your attribution data to RevenueCat so you can track the revenue generated by your different campaigns. +///

Related articles

+/// +/// \param data Dictionary provided by the network. +/// +/// \param network Enum for the network the data is coming from, see AttributionNetwork for supported +/// networks. +/// +/// \param networkUserId User Id that should be sent to the network. Default is the current App User Id. +/// ++ (void)addAttributionData:(NSDictionary * _Nonnull)data fromNetwork:(enum RCAttributionNetwork)network forNetworkUserId:(NSString * _Nullable)networkUserId SWIFT_DEPRECATED_MSG("Use the set functions instead"); +@end + + @interface RCPurchases (SWIFT_EXTENSION(RevenueCat)) /// Configures an instance of the Purchases SDK with a specified Configuration. /// The instance will be set as a singleton. @@ -2993,35 +3022,6 @@ SWIFT_AVAILABILITY(visionos,introduced=2.0) SWIFT_AVAILABILITY(watchos,introduce @end -@interface RCPurchases (SWIFT_EXTENSION(RevenueCat)) -/// Enable debug logging. Useful for debugging issues with the lovely team @RevenueCat. -SWIFT_CLASS_PROPERTY(@property (nonatomic, class) BOOL debugLogsEnabled SWIFT_DEPRECATED_MSG("use Purchases.logLevel instead");) -+ (BOOL)debugLogsEnabled SWIFT_WARN_UNUSED_RESULT; -+ (void)setDebugLogsEnabled:(BOOL)newValue; -/// Deprecated -@property (nonatomic) BOOL allowSharingAppStoreAccount SWIFT_DEPRECATED_MSG("\n Configure behavior through the RevenueCat dashboard instead. If you have configured the \"Legacy\" restore\n behavior in the [RevenueCat Dashboard](app.revenuecat.com) and are currently setting this to `true`, keep\n this setting active.\n "); -/// Deprecated. Where responsibility for completing purchase transactions lies. -@property (nonatomic) BOOL finishTransactions SWIFT_DEPRECATED_MSG("Use ``purchasesAreCompletedBy`` instead."); -/// Deprecated -+ (void)addAttributionData:(NSDictionary * _Nonnull)data fromNetwork:(enum RCAttributionNetwork)network SWIFT_DEPRECATED_MSG("Use the set functions instead"); -/// Send your attribution data to RevenueCat so you can track the revenue generated by your different campaigns. -///

Related articles

-/// -/// \param data Dictionary provided by the network. -/// -/// \param network Enum for the network the data is coming from, see AttributionNetwork for supported -/// networks. -/// -/// \param networkUserId User Id that should be sent to the network. Default is the current App User Id. -/// -+ (void)addAttributionData:(NSDictionary * _Nonnull)data fromNetwork:(enum RCAttributionNetwork)network forNetworkUserId:(NSString * _Nullable)networkUserId SWIFT_DEPRECATED_MSG("Use the set functions instead"); -@end - - @interface RCPurchases (SWIFT_EXTENSION(RevenueCat)) /// Parses a deep link URL to verify it’s a RevenueCat web purchase redemption link @@ -3381,6 +3381,7 @@ SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong, getter=defau @end + @interface RCPurchasesDiagnostics (SWIFT_EXTENSION(RevenueCat)) /// Perform tests to ensure SDK is configured correctly. ///
    @@ -3394,7 +3395,6 @@ SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong, getter=defau - /// A type that can parse Apple receipts from a device. /// This implements parsing based on Apple’s documentation. /// To use this class you must access PurchasesReceiptParser/default: @@ -3411,13 +3411,13 @@ SWIFT_CLASS("_TtC10RevenueCat22PurchasesReceiptParser") + @interface PurchasesReceiptParser (SWIFT_EXTENSION(RevenueCat)) - (BOOL)receiptHasTransactionsWithReceiptData:(NSData * _Nonnull)receiptData SWIFT_WARN_UNUSED_RESULT; @end - @interface PurchasesReceiptParser (SWIFT_EXTENSION(RevenueCat)) /// A default instance of PurchasesReceiptParser SWIFT_CLASS_PROPERTY(@property (nonatomic, class, readonly, strong, getter=default) PurchasesReceiptParser * _Nonnull default_;) @@ -3659,6 +3659,11 @@ typedef SWIFT_ENUM_NAMED(NSInteger, RCStoreProductType, "ProductType", open) { /// ///
@property (nonatomic, readonly, strong) NSDecimalNumber * _Nonnull price; +/// Calculates the price of this subscription product per day. +/// +/// returns: +/// nil if the product is not a subscription. +@property (nonatomic, readonly, strong) NSDecimalNumber * _Nullable pricePerDay SWIFT_AVAILABILITY(watchos,introduced=6.2) SWIFT_AVAILABILITY(tvos,introduced=11.2) SWIFT_AVAILABILITY(macos,introduced=10.13.2) SWIFT_AVAILABILITY(ios,introduced=11.2); /// Calculates the price of this subscription product per week. /// /// returns: @@ -3692,6 +3697,20 @@ typedef SWIFT_ENUM_NAMED(NSInteger, RCStoreProductType, "ProductType", open) { /// localizedPricePerYear /// /// +@property (nonatomic, readonly, copy) NSString * _Nullable localizedPricePerDay SWIFT_AVAILABILITY(watchos,introduced=6.2) SWIFT_AVAILABILITY(tvos,introduced=11.2) SWIFT_AVAILABILITY(macos,introduced=10.13.2) SWIFT_AVAILABILITY(ios,introduced=11.2); +/// The formatted price per week using StoreProduct/priceFormatter. +///

Related Symbols

+///
    +///
  • +/// pricePerWeek +///
  • +///
  • +/// localizedPricePerMonth +///
  • +///
  • +/// localizedPricePerYear +///
  • +///
@property (nonatomic, readonly, copy) NSString * _Nullable localizedPricePerWeek SWIFT_AVAILABILITY(watchos,introduced=6.2) SWIFT_AVAILABILITY(tvos,introduced=11.2) SWIFT_AVAILABILITY(macos,introduced=10.13.2) SWIFT_AVAILABILITY(ios,introduced=11.2); /// The formatted price per month using StoreProduct/priceFormatter. ///

Related Symbols

@@ -3787,6 +3806,30 @@ typedef SWIFT_ENUM_NAMED(NSInteger, RCDiscountType, "DiscountType", open) { @property (nonatomic, readonly, strong) SKProductDiscount * _Nullable sk1Discount; @end + +@interface RCStoreProductDiscount (SWIFT_EXTENSION(RevenueCat)) +/// Calculates the approximate price of this subscription product per day. +/// +/// returns: +/// nil if the product is not a subscription. +@property (nonatomic, readonly, strong) NSDecimalNumber * _Nullable pricePerDay SWIFT_AVAILABILITY(watchos,introduced=6.2) SWIFT_AVAILABILITY(tvos,introduced=11.2) SWIFT_AVAILABILITY(macos,introduced=10.13.2) SWIFT_AVAILABILITY(ios,introduced=11.2); +/// Calculates the approximate price of this subscription product per week. +/// +/// returns: +/// nil if the product is not a subscription. +@property (nonatomic, readonly, strong) NSDecimalNumber * _Nullable pricePerWeek SWIFT_AVAILABILITY(watchos,introduced=6.2) SWIFT_AVAILABILITY(tvos,introduced=11.2) SWIFT_AVAILABILITY(macos,introduced=10.13.2) SWIFT_AVAILABILITY(ios,introduced=11.2); +/// Calculates the approximate price of this subscription product per month. +/// +/// returns: +/// nil if the product is not a subscription. +@property (nonatomic, readonly, strong) NSDecimalNumber * _Nullable pricePerMonth SWIFT_AVAILABILITY(watchos,introduced=6.2) SWIFT_AVAILABILITY(tvos,introduced=11.2) SWIFT_AVAILABILITY(macos,introduced=10.13.2) SWIFT_AVAILABILITY(ios,introduced=11.2); +/// Calculates the approximate price of this subscription product per year. +/// +/// returns: +/// nil if the product is not a subscription. +@property (nonatomic, readonly, strong) NSDecimalNumber * _Nullable pricePerYear SWIFT_AVAILABILITY(watchos,introduced=6.2) SWIFT_AVAILABILITY(tvos,introduced=11.2) SWIFT_AVAILABILITY(macos,introduced=10.13.2) SWIFT_AVAILABILITY(ios,introduced=11.2); +@end + @class RCStorefront; /// Abstract class that provides access to properties of a transaction. @@ -3952,6 +3995,7 @@ typedef SWIFT_ENUM_NAMED(NSInteger, RCSubscriptionPeriodUnit, "Unit", open) { + @interface RCSubscriptionPeriod (SWIFT_EXTENSION(RevenueCat)) @property (nonatomic, readonly, copy) NSString * _Nonnull debugDescription; @end