Package 

Interface PushRegistrationProvider

    • Method Summary

      Modifier and Type Method Description
      abstract String getSenderID() Returns the Sender ID of the provider, or equivalent.
      abstract String getShortname() Returns the short name of the provider.
      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.
      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.
      abstract String getRegistration() Returns the registration if possible.Some providers might not have it right away.
      abstract AdsIdentifierProvider getAdsIdentifierProvider() Return the ads identifier provider associated with the push registration provider
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • 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.