-
public interface PushRegistrationProviderDefines a push notification registration provider
-
-
Method Summary
Modifier and Type Method Description abstract StringgetSenderID()Returns the Sender ID of the provider, or equivalent. abstract StringgetShortname()Returns the short name of the provider. abstract voidcheckServiceAvailability()Is this provider installed on the device?This is the place to check if the service is installed on the device and if its versionmatch the feature we need. abstract voidcheckLibraryAvailability()Is this provider implemented in the app?This is the place to check if the libraries are here at runtime andif the user enabled/disabled your provider. abstract StringgetRegistration()Returns the registration if possible.Some providers might not have it right away. abstract AdsIdentifierProvidergetAdsIdentifierProvider()Return the ads identifier provider associated with the push registration provider -
-
Method Detail
-
getSenderID
abstract String getSenderID()
Returns the Sender ID of the provider, or equivalent. For example: "8122930293"
-
getShortname
abstract String getShortname()
Returns the short name of the provider. For example: "FCM".
-
checkServiceAvailability
abstract void checkServiceAvailability()
Is this provider installed on the device?This is the place to check if the service is installed on the device and if its versionmatch the feature we need.
This method will be called when electing the provider for the current start of the app.
If not available, you should throw a PushRegistrationProviderAvailabilityException withthe human-readable error message.
-
checkLibraryAvailability
abstract void checkLibraryAvailability()
Is this provider implemented in the app?This is the place to check if the libraries are here at runtime andif the user enabled/disabled your provider.
This method will be called right before requesting a push token.
If not available, you should throw a PushRegistrationProviderAvailabilityException withthe human-readable error message.
-
getRegistration
@Nullable() abstract String getRegistration()
Returns the registration if possible.Some providers might not have it right away. Return null in these cases.
-
getAdsIdentifierProvider
abstract AdsIdentifierProvider getAdsIdentifierProvider()
Return the ads identifier provider associated with the push registration provider
-
-
-
-