purchasePackage
fun purchasePackage(activity: Activity, packageToPurchase: Package, upgradeInfo: UpgradeInfo, listener: ProductChangeListener)
Content copied to clipboard
Change the product from productChangeInfo with the one in packageToPurchase.
Parameters
activity
Current activity
packageToPurchase
The new package to purchase
upgradeInfo
The oldProduct of this object will be replaced with the product in packageToPurchase. An optional BillingFlowParams.ProrationMode can also be specified.
listener
The listener that will be called when the purchase of the new product completes.
fun purchasePackage(activity: Activity, packageToPurchase: Package, listener: MakePurchaseListener)
Content copied to clipboard
Make a purchase.
Parameters
activity
Current activity
packageToPurchase
The Package you wish to purchase
listener
The listener that will be called when purchase completes.