From 77eec0b91a68004f213455f0710fb8a4a1406cfb Mon Sep 17 00:00:00 2001 From: Victoria Park Date: Fri, 21 Jun 2024 07:17:29 -0700 Subject: [PATCH] MXO Deprecation Annotations --- PayPal.xcworkspace/xcshareddata/swiftpm/Package.resolved | 7 ++++--- Sources/PayPalNativePayments/NativeCheckoutProvider.swift | 1 + Sources/PayPalNativePayments/NativeCheckoutStartable.swift | 1 + .../PayPalNativePayments/PayPalNativeCheckoutClient.swift | 3 +++ .../PayPalNativeCheckoutDelegate.swift | 2 ++ .../PayPalNativePayments/PayPalNativeCheckoutRequest.swift | 1 + .../PayPalNativePayments/PayPalNativeCheckoutResult.swift | 1 + .../PayPalNativePayments/PayPalNativePaysheetActions.swift | 1 + .../PayPalNativePayments/PayPalNativeShippingAddress.swift | 1 + .../PayPalNativePayments/PayPalNativeShippingMethod.swift | 2 ++ 10 files changed, 17 insertions(+), 3 deletions(-) diff --git a/PayPal.xcworkspace/xcshareddata/swiftpm/Package.resolved b/PayPal.xcworkspace/xcshareddata/swiftpm/Package.resolved index 5deda352e..e42d79ab4 100644 --- a/PayPal.xcworkspace/xcshareddata/swiftpm/Package.resolved +++ b/PayPal.xcworkspace/xcshareddata/swiftpm/Package.resolved @@ -1,14 +1,15 @@ { + "originHash" : "9f5faeaf68c5b33128078a8e5ae8e66905c17a87c672e7078cd94c980aa3dd72", "pins" : [ { "identity" : "paypalcheckout-ios", "kind" : "remoteSourceControl", "location" : "https://github.com/paypal/paypalcheckout-ios", "state" : { - "revision" : "f477176da4c6780c8586b493c604f0ab74d9be49", - "version" : "1.2.0" + "revision" : "da1b998dcab91011b05df139a6819cc58dd45ccd", + "version" : "1.3.0" } } ], - "version" : 2 + "version" : 3 } diff --git a/Sources/PayPalNativePayments/NativeCheckoutProvider.swift b/Sources/PayPalNativePayments/NativeCheckoutProvider.swift index d18c123b8..9938f6b80 100644 --- a/Sources/PayPalNativePayments/NativeCheckoutProvider.swift +++ b/Sources/PayPalNativePayments/NativeCheckoutProvider.swift @@ -5,6 +5,7 @@ import PayPalCheckout import CorePayments #endif +@available(*, deprecated, message: "PayPalNativePayments Module is deprecated, use PayPalWebPayments Module instead") class NativeCheckoutProvider: NativeCheckoutStartable { /// Used in POST body for FPTI analytics. diff --git a/Sources/PayPalNativePayments/NativeCheckoutStartable.swift b/Sources/PayPalNativePayments/NativeCheckoutStartable.swift index 4d5b8b1b1..9e68d2e9b 100644 --- a/Sources/PayPalNativePayments/NativeCheckoutStartable.swift +++ b/Sources/PayPalNativePayments/NativeCheckoutStartable.swift @@ -5,6 +5,7 @@ import PayPalCheckout import CorePayments #endif +@available(*, deprecated, message: "PayPalNativePayments Module is deprecated, use PayPalWebPayments Module instead") protocol NativeCheckoutStartable { /// Used in POST body for FPTI analytics. diff --git a/Sources/PayPalNativePayments/PayPalNativeCheckoutClient.swift b/Sources/PayPalNativePayments/PayPalNativeCheckoutClient.swift index 92279bae0..6d734b2ec 100644 --- a/Sources/PayPalNativePayments/PayPalNativeCheckoutClient.swift +++ b/Sources/PayPalNativePayments/PayPalNativeCheckoutClient.swift @@ -4,6 +4,7 @@ import PayPalCheckout import CorePayments #endif +@available(*, deprecated, message: "PayPalNativePayments Module is deprecated, use PayPalWebPayments Module instead") /// PayPal Paysheet to handle PayPal transaction /// encapsulates instance to communicate with nxo public class PayPalNativeCheckoutClient { @@ -18,6 +19,7 @@ public class PayPalNativeCheckoutClient { private let config: CoreConfig private var analyticsService: AnalyticsService? + @available(*, deprecated, message: "PayPalNativePayments Module is deprecated, use PayPalWebPayments Module instead") /// Initialize a PayPalNativeCheckoutClient to process PayPal transaction /// - Parameters: /// - config: The CoreConfig object @@ -35,6 +37,7 @@ public class PayPalNativeCheckoutClient { self.networkingClient = networkingClient } + @available(*, deprecated, message: "PayPalNativePayments Module is deprecated, use PayPalWebPayments Module instead") // NEXT_MAJOR_VERSION: - Change to non-async /// Present PayPal Paysheet and start a PayPal transaction /// - Parameters: diff --git a/Sources/PayPalNativePayments/PayPalNativeCheckoutDelegate.swift b/Sources/PayPalNativePayments/PayPalNativeCheckoutDelegate.swift index 41b102d5a..da661e14c 100644 --- a/Sources/PayPalNativePayments/PayPalNativeCheckoutDelegate.swift +++ b/Sources/PayPalNativePayments/PayPalNativeCheckoutDelegate.swift @@ -4,6 +4,7 @@ import CorePayments #endif import PayPalCheckout +@available(*, deprecated, message: "PayPalNativePayments Module is deprecated, use PayPalWebPayments Module instead") /// A required delegate to handle events from `PayPalNativeCheckoutClient.start()` public protocol PayPalNativeCheckoutDelegate: AnyObject { @@ -28,6 +29,7 @@ public protocol PayPalNativeCheckoutDelegate: AnyObject { func paypalWillStart(_ payPalClient: PayPalNativeCheckoutClient) } +@available(*, deprecated, message: "PayPalNativePayments Module is deprecated, use PayPalWebPayments Module instead") /// A delegate to receive notifications if the user changes their shipping information. /// /// This is **only required** if the order ID was created with `shipping_preferences = GET_FROM_FILE`. [See Orders V2 documentation](https://developer.paypal.com/docs/api/orders/v2/#definition-order_application_context). If the order ID was created with `shipping_preferences = NO_SHIPPING` or `SET_PROVIDED_ADDRESS`, don't implement this protocol. diff --git a/Sources/PayPalNativePayments/PayPalNativeCheckoutRequest.swift b/Sources/PayPalNativePayments/PayPalNativeCheckoutRequest.swift index 93fc2a083..0a95e86ed 100644 --- a/Sources/PayPalNativePayments/PayPalNativeCheckoutRequest.swift +++ b/Sources/PayPalNativePayments/PayPalNativeCheckoutRequest.swift @@ -1,5 +1,6 @@ import Foundation +@available(*, deprecated, message: "PayPalNativePayments Module is deprecated, use PayPalWebPayments Module instead") /// Used to configure options for approving a PayPal native order public struct PayPalNativeCheckoutRequest { diff --git a/Sources/PayPalNativePayments/PayPalNativeCheckoutResult.swift b/Sources/PayPalNativePayments/PayPalNativeCheckoutResult.swift index 3ea27fb5e..be4985cd1 100644 --- a/Sources/PayPalNativePayments/PayPalNativeCheckoutResult.swift +++ b/Sources/PayPalNativePayments/PayPalNativeCheckoutResult.swift @@ -1,5 +1,6 @@ import Foundation +@available(*, deprecated, message: "PayPalNativePayments Module is deprecated, use PayPalWebPayments Module instead") /// The result of a PayPal native payment flow. public struct PayPalNativeCheckoutResult { diff --git a/Sources/PayPalNativePayments/PayPalNativePaysheetActions.swift b/Sources/PayPalNativePayments/PayPalNativePaysheetActions.swift index 9e359ad3d..04e671517 100644 --- a/Sources/PayPalNativePayments/PayPalNativePaysheetActions.swift +++ b/Sources/PayPalNativePayments/PayPalNativePaysheetActions.swift @@ -1,5 +1,6 @@ import PayPalCheckout +@available(*, deprecated, message: "PayPalNativePayments Module is deprecated, use PayPalWebPayments Module instead") /// The actions that can be used to update the Paysheet UI after `PayPalNativeShippingDelegate` methods are invoked. public class PayPalNativePaysheetActions { diff --git a/Sources/PayPalNativePayments/PayPalNativeShippingAddress.swift b/Sources/PayPalNativePayments/PayPalNativeShippingAddress.swift index 7e18b6f49..f0761cacc 100644 --- a/Sources/PayPalNativePayments/PayPalNativeShippingAddress.swift +++ b/Sources/PayPalNativePayments/PayPalNativeShippingAddress.swift @@ -1,5 +1,6 @@ import PayPalCheckout +@available(*, deprecated, message: "PayPalNativePayments Module is deprecated, use PayPalWebPayments Module instead") // Wrapper for PayPalCheckout.ShippingChangeAddress /// The user's selected shipping address via the PayPal Native Checkout UI. /// diff --git a/Sources/PayPalNativePayments/PayPalNativeShippingMethod.swift b/Sources/PayPalNativePayments/PayPalNativeShippingMethod.swift index 4c6cba78c..21e8b9f62 100644 --- a/Sources/PayPalNativePayments/PayPalNativeShippingMethod.swift +++ b/Sources/PayPalNativePayments/PayPalNativeShippingMethod.swift @@ -1,5 +1,6 @@ import PayPalCheckout +@available(*, deprecated, message: "PayPalNativePayments Module is deprecated, use PayPalWebPayments Module instead") // Wrapper for PayPalCheckout.ShippingMethod /// The user's selected shipping method via the PayPal Native Checkout UI. /// @@ -79,6 +80,7 @@ public struct PayPalNativeShippingMethod { } } +@available(*, deprecated, message: "PayPalNativePayments Module is deprecated, use PayPalWebPayments Module instead") extension PayPalCheckout.ShippingType { func toMerchantFacingShippingType() -> PayPalNativeShippingMethod.DeliveryType {