123456789101112131415161718192021222324252627282930313233343536373839404142 |
- //
- // KMDMGPurchaseManager.swift
- // PDF Reader Pro
- //
- // Created by lizhe on 2023/6/8.
- //
- import Cocoa
- class KMDMGPurchaseManager: NSObject {
- public static let manager = KMDMGPurchaseManager()
- var fetchProductCompletion: KMPurchaseFetchProductCompletion?
-
- var availableProducts: [KMProduct] = []
-
- var state: KMPurchaseManagerState {
- get {
- return self.updatePurchaseState()
- }
- }
-
- func updatePurchaseState() -> KMPurchaseManagerState {
- var tempState: KMPurchaseManagerState = .unknow
-
- return tempState
- }
-
- func purchaseProduct(productIdentifier: String, email: String, completion: KMPurchaseCompletion) {
-
- completion(false, .success)
- }
-
- func fetchProducts(completion: @escaping KMPurchaseFetchProductCompletion) {
- self.fetchProductCompletion = completion
-
-
- }
-
- func restorePurchases() {
-
- }
- }
|