mirror of
https://github.com/signalapp/Signal-Android.git
synced 2026-04-21 17:29:32 +01:00
Move billing code to shared module.
This commit is contained in:
@@ -1,30 +0,0 @@
|
||||
/*
|
||||
* Copyright 2024 Signal Messenger, LLC
|
||||
* SPDX-License-Identifier: AGPL-3.0-only
|
||||
*/
|
||||
|
||||
package org.thoughtcrime.securesms.billing
|
||||
|
||||
import android.app.Activity
|
||||
|
||||
/**
|
||||
* Variant interface for the BillingApi.
|
||||
*/
|
||||
interface GooglePlayBillingApi {
|
||||
fun isApiAvailable(): Boolean = false
|
||||
suspend fun queryProducts() = Unit
|
||||
|
||||
/**
|
||||
* Queries the user's current purchases. This enqueues a check and will
|
||||
* propagate it to the normal callbacks in the api.
|
||||
*/
|
||||
suspend fun queryPurchases() = Unit
|
||||
|
||||
suspend fun launchBillingFlow(activity: Activity) = Unit
|
||||
|
||||
/**
|
||||
* Empty implementation, to be used when play services are available but
|
||||
* GooglePlayBillingApi is not available.
|
||||
*/
|
||||
object Empty : GooglePlayBillingApi
|
||||
}
|
||||
Reference in New Issue
Block a user