Class FCMPushConnector

java.lang.Object
com.streamwide.smartms.lib.std.FCMPushConnector
All Implemented Interfaces:
com.streamwide.smartms.lib.template.push.IPushConnector

public class FCMPushConnector extends Object implements com.streamwide.smartms.lib.template.push.IPushConnector
  • Nested Class Summary

    Nested classes/interfaces inherited from interface com.streamwide.smartms.lib.template.push.IPushConnector

    com.streamwide.smartms.lib.template.push.IPushConnector.ConnectorCallback, com.streamwide.smartms.lib.template.push.IPushConnector.IErrorCallback, com.streamwide.smartms.lib.template.push.IPushConnector.TokenHandler
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    checkRegistrationStatus(android.content.Context context, com.streamwide.smartms.lib.template.push.IPushConnector.IErrorCallback callback, com.streamwide.smartms.lib.template.push.IPushConnector.TokenHandler tokenHandler)
    Check if GCM is already registered or not If Google Play Services are not available, it will display the error and potentially a Google Play Services dialog to help the user
    void
    initCallback(com.streamwide.smartms.lib.template.push.IPushRegistrator pushRegistrator)
     
    void
    registerInBackground(android.content.Context context, com.streamwide.smartms.lib.template.push.IPushConnector.ConnectorCallback connectorCallback)
    Registers the application with GCM servers asynchronously.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • FCMPushConnector

      public FCMPushConnector()
  • Method Details

    • initCallback

      public void initCallback(@Nullable com.streamwide.smartms.lib.template.push.IPushRegistrator pushRegistrator)
      Specified by:
      initCallback in interface com.streamwide.smartms.lib.template.push.IPushConnector
    • registerInBackground

      public void registerInBackground(@NonNull android.content.Context context, @Nullable com.streamwide.smartms.lib.template.push.IPushConnector.ConnectorCallback connectorCallback)
      Registers the application with GCM servers asynchronously.

      Stores the registration ID and the app versionCode in the application's shared preferences.

      Specified by:
      registerInBackground in interface com.streamwide.smartms.lib.template.push.IPushConnector
    • checkRegistrationStatus

      public boolean checkRegistrationStatus(@NonNull android.content.Context context, @Nullable com.streamwide.smartms.lib.template.push.IPushConnector.IErrorCallback callback, @Nullable com.streamwide.smartms.lib.template.push.IPushConnector.TokenHandler tokenHandler)
      Check if GCM is already registered or not If Google Play Services are not available, it will display the error and potentially a Google Play Services dialog to help the user
      Specified by:
      checkRegistrationStatus in interface com.streamwide.smartms.lib.template.push.IPushConnector
      Returns:
      true if GCM is already registered, false otherwise