/// /// NitroPurchase.kt /// This file was generated by nitrogen. DO NOT MODIFY THIS FILE. /// https://github.com/mrousavy/nitro /// Copyright © 2025 Marc Rousavy @ Margelo /// package com.margelo.nitro.iap import androidx.annotation.Keep import com.facebook.proguard.annotations.DoNotStrip /** * Represents the JavaScript object/struct "NitroPurchase". */ @DoNotStrip @Keep data class NitroPurchase( @DoNotStrip @Keep val id: String, @DoNotStrip @Keep val productId: String, @DoNotStrip @Keep val transactionDate: Double, @DoNotStrip @Keep val purchaseToken: String?, @DoNotStrip @Keep val platform: IapPlatform, @DoNotStrip @Keep val store: IapStore, @DoNotStrip @Keep val quantity: Double, @DoNotStrip @Keep val purchaseState: PurchaseState, @DoNotStrip @Keep val isAutoRenewing: Boolean, @DoNotStrip @Keep val quantityIOS: Double?, @DoNotStrip @Keep val originalTransactionDateIOS: Double?, @DoNotStrip @Keep val originalTransactionIdentifierIOS: String?, @DoNotStrip @Keep val appAccountToken: String?, @DoNotStrip @Keep val appBundleIdIOS: String?, @DoNotStrip @Keep val countryCodeIOS: String?, @DoNotStrip @Keep val currencyCodeIOS: String?, @DoNotStrip @Keep val currencySymbolIOS: String?, @DoNotStrip @Keep val environmentIOS: String?, @DoNotStrip @Keep val expirationDateIOS: Double?, @DoNotStrip @Keep val isUpgradedIOS: Boolean?, @DoNotStrip @Keep val offerIOS: String?, @DoNotStrip @Keep val ownershipTypeIOS: String?, @DoNotStrip @Keep val reasonIOS: String?, @DoNotStrip @Keep val reasonStringRepresentationIOS: String?, @DoNotStrip @Keep val revocationDateIOS: Double?, @DoNotStrip @Keep val revocationReasonIOS: String?, @DoNotStrip @Keep val storefrontCountryCodeIOS: String?, @DoNotStrip @Keep val subscriptionGroupIdIOS: String?, @DoNotStrip @Keep val transactionReasonIOS: String?, @DoNotStrip @Keep val webOrderLineItemIdIOS: String?, @DoNotStrip @Keep val renewalInfoIOS: NitroRenewalInfoIOS?, @DoNotStrip @Keep val purchaseTokenAndroid: String?, @DoNotStrip @Keep val dataAndroid: String?, @DoNotStrip @Keep val signatureAndroid: String?, @DoNotStrip @Keep val autoRenewingAndroid: Boolean?, @DoNotStrip @Keep val purchaseStateAndroid: Double?, @DoNotStrip @Keep val isAcknowledgedAndroid: Boolean?, @DoNotStrip @Keep val packageNameAndroid: String?, @DoNotStrip @Keep val obfuscatedAccountIdAndroid: String?, @DoNotStrip @Keep val obfuscatedProfileIdAndroid: String?, @DoNotStrip @Keep val developerPayloadAndroid: String?, @DoNotStrip @Keep val isSuspendedAndroid: Boolean? ) { private companion object { /** * Constructor called from C++ */ @DoNotStrip @Keep @Suppress("unused") @JvmStatic private fun fromCpp(id: String, productId: String, transactionDate: Double, purchaseToken: String?, platform: IapPlatform, store: IapStore, quantity: Double, purchaseState: PurchaseState, isAutoRenewing: Boolean, quantityIOS: Double?, originalTransactionDateIOS: Double?, originalTransactionIdentifierIOS: String?, appAccountToken: String?, appBundleIdIOS: String?, countryCodeIOS: String?, currencyCodeIOS: String?, currencySymbolIOS: String?, environmentIOS: String?, expirationDateIOS: Double?, isUpgradedIOS: Boolean?, offerIOS: String?, ownershipTypeIOS: String?, reasonIOS: String?, reasonStringRepresentationIOS: String?, revocationDateIOS: Double?, revocationReasonIOS: String?, storefrontCountryCodeIOS: String?, subscriptionGroupIdIOS: String?, transactionReasonIOS: String?, webOrderLineItemIdIOS: String?, renewalInfoIOS: NitroRenewalInfoIOS?, purchaseTokenAndroid: String?, dataAndroid: String?, signatureAndroid: String?, autoRenewingAndroid: Boolean?, purchaseStateAndroid: Double?, isAcknowledgedAndroid: Boolean?, packageNameAndroid: String?, obfuscatedAccountIdAndroid: String?, obfuscatedProfileIdAndroid: String?, developerPayloadAndroid: String?, isSuspendedAndroid: Boolean?): NitroPurchase { return NitroPurchase(id, productId, transactionDate, purchaseToken, platform, store, quantity, purchaseState, isAutoRenewing, quantityIOS, originalTransactionDateIOS, originalTransactionIdentifierIOS, appAccountToken, appBundleIdIOS, countryCodeIOS, currencyCodeIOS, currencySymbolIOS, environmentIOS, expirationDateIOS, isUpgradedIOS, offerIOS, ownershipTypeIOS, reasonIOS, reasonStringRepresentationIOS, revocationDateIOS, revocationReasonIOS, storefrontCountryCodeIOS, subscriptionGroupIdIOS, transactionReasonIOS, webOrderLineItemIdIOS, renewalInfoIOS, purchaseTokenAndroid, dataAndroid, signatureAndroid, autoRenewingAndroid, purchaseStateAndroid, isAcknowledgedAndroid, packageNameAndroid, obfuscatedAccountIdAndroid, obfuscatedProfileIdAndroid, developerPayloadAndroid, isSuspendedAndroid) } } }