Files
keyboard/keyBoard/Class/Pay/StoreKit2Manager/Models/StoreKitConfig.swift

49 lines
1.4 KiB
Swift
Raw Normal View History

2025-12-16 13:10:50 +08:00
//
// StoreKitConfig.swift
// StoreKit2Manager
//
// Created by xiaopin on 2025/12/6.
//
import Foundation
/// StoreKit
public struct StoreKitConfig {
/// ID
public let productIds: [String]
/// ID
public let lifetimeIds: [String]
///
/// nil
public let nonRenewableExpirationDays: Int?
///
public let autoSortProducts: Bool
///
public let showLog: Bool
///
/// - Parameters:
/// - productIds: ID
/// - lifetimeIds: ID
/// - nonRenewableExpirationDays: 365
/// - autoSortProducts: true
/// - showLog: false
public init(
productIds: [String],
lifetimeIds: [String],
nonRenewableExpirationDays: Int? = 365,
autoSortProducts: Bool = true,
showLog: Bool = false
) {
self.productIds = productIds
self.lifetimeIds = lifetimeIds
self.nonRenewableExpirationDays = nonRenewableExpirationDays
self.autoSortProducts = autoSortProducts
self.showLog = showLog
}
}