Class GenericIdpSignInHandler

    • Constructor Summary

      Constructors 
      Constructor Description
      GenericIdpSignInHandler​(android.app.Application application)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected com.google.firebase.auth.OAuthProvider buildOAuthProvider​(java.lang.String providerId)  
      protected void handleMergeFailure​(com.google.firebase.auth.AuthCredential credential)  
      protected void handleNormalSignInFlow​(com.google.firebase.auth.FirebaseAuth auth, HelperActivityBase activity, com.google.firebase.auth.OAuthProvider provider)  
      protected void handleSuccess​(java.lang.String providerId, com.google.firebase.auth.FirebaseUser user, com.google.firebase.auth.OAuthCredential credential, boolean isNewUser)  
      protected void handleSuccess​(java.lang.String providerId, com.google.firebase.auth.FirebaseUser user, com.google.firebase.auth.OAuthCredential credential, boolean isNewUser, boolean setPendingCredential)  
      void initializeForTesting​(AuthUI.IdpConfig idpConfig)  
      void onActivityResult​(int requestCode, int resultCode, android.content.Intent data)  
      void startSignIn​(HelperActivityBase activity)
      Start the login process for the IDP, e.g.
      void startSignIn​(com.google.firebase.auth.FirebaseAuth auth, HelperActivityBase activity, java.lang.String providerId)
      Start the login process for the IDP using the web based Generic IDP flow if applicable, e.g.
      • Methods inherited from class androidx.lifecycle.AndroidViewModel

        getApplication
      • Methods inherited from class java.lang.Object

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

      • GenericIdpSignInHandler

        public GenericIdpSignInHandler​(android.app.Application application)
    • Method Detail

      • startSignIn

        public void startSignIn​(@NonNull
                                com.google.firebase.auth.FirebaseAuth auth,
                                @NonNull
                                HelperActivityBase activity,
                                @NonNull
                                java.lang.String providerId)
        Description copied from class: ProviderSignInBase
        Start the login process for the IDP using the web based Generic IDP flow if applicable, e.g. sign-in through a custom-chrome tab, otherwise falls back to the default method.
        Specified by:
        startSignIn in class ProviderSignInBase<AuthUI.IdpConfig>
        Parameters:
        auth - the Firebase auth instance
        activity - from which to start the login, DO NOT USE OUTSIDE OF THIS METHOD!!!
        providerId - the provider to sign-in with (e.g. "microsoft.com")
      • handleNormalSignInFlow

        protected void handleNormalSignInFlow​(com.google.firebase.auth.FirebaseAuth auth,
                                              HelperActivityBase activity,
                                              com.google.firebase.auth.OAuthProvider provider)
      • buildOAuthProvider

        protected com.google.firebase.auth.OAuthProvider buildOAuthProvider​(java.lang.String providerId)
      • handleSuccess

        protected void handleSuccess​(@NonNull
                                     java.lang.String providerId,
                                     @NonNull
                                     com.google.firebase.auth.FirebaseUser user,
                                     @NonNull
                                     com.google.firebase.auth.OAuthCredential credential,
                                     boolean isNewUser,
                                     boolean setPendingCredential)
      • handleSuccess

        protected void handleSuccess​(@NonNull
                                     java.lang.String providerId,
                                     @NonNull
                                     com.google.firebase.auth.FirebaseUser user,
                                     @NonNull
                                     com.google.firebase.auth.OAuthCredential credential,
                                     boolean isNewUser)
      • handleMergeFailure

        protected void handleMergeFailure​(@NonNull
                                          com.google.firebase.auth.AuthCredential credential)
      • initializeForTesting

        public void initializeForTesting​(AuthUI.IdpConfig idpConfig)