mirror of
https://github.com/Novaloop-AG/element-x-android.git
synced 2026-11-02 12:07:28 +00:00
Push distributor: ensure the current UnifiedPush distributor is stored
This commit is contained in:
committed by
Benoit Marty
parent
56ca04affa
commit
d2fbff09b8
+8
@@ -16,6 +16,14 @@
|
||||
|
||||
package io.element.android.libraries.pushproviders.api
|
||||
|
||||
/**
|
||||
* Firebase does not have the concept of distributor. So for Firebase, there will be one distributor:
|
||||
* Distributor("Firebase", "Firebase").
|
||||
*
|
||||
* For UnifiedPush, for instance, the Distributor can be:
|
||||
* Distributor("io.heckel.ntfy", "ntfy").
|
||||
* But other values are possible.
|
||||
*/
|
||||
data class Distributor(
|
||||
val value: String,
|
||||
val name: String,
|
||||
|
||||
+5
@@ -44,6 +44,11 @@ interface PushProvider {
|
||||
*/
|
||||
suspend fun registerWith(matrixClient: MatrixClient, distributor: Distributor)
|
||||
|
||||
/**
|
||||
* Return the current distributor, or null if none.
|
||||
*/
|
||||
suspend fun getCurrentDistributor(matrixClient: MatrixClient): Distributor?
|
||||
|
||||
/**
|
||||
* Unregister the pusher.
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user