Class EncryptedCredentialsStore

  • All Implemented Interfaces:
    CredentialsStore

    public class EncryptedCredentialsStore
    extends java.lang.Object
    implements CredentialsStore
    Created by Alpar Szotyori on 08.10.2018. Copyright (c) 2018 Gini GmbH.
    • Constructor Detail

      • EncryptedCredentialsStore

        public EncryptedCredentialsStore​(@NonNull
                                         android.content.SharedPreferences sharedPreferences,
                                         @NonNull
                                         android.content.Context context)
    • Method Detail

      • encryptExistingPlaintextCredentials

        public void encryptExistingPlaintextCredentials()
      • storeUserCredentials

        public boolean storeUserCredentials​(UserCredentials userCredentials)
        Description copied from interface: CredentialsStore
        Store the given user credentials. Warning: This method overwrites existing user credentials.
        Specified by:
        storeUserCredentials in interface CredentialsStore
        Parameters:
        userCredentials - The user's credentials.
        Returns:
        Whether the storing of the credentials was successful.
      • getUserCredentials

        public UserCredentials getUserCredentials()
        Description copied from interface: CredentialsStore
        Returns the stored user credentials. Warning: If there are no stored user credentials, this method returns null.
        Specified by:
        getUserCredentials in interface CredentialsStore
        Returns:
        The stored user credentials.
      • deleteUserCredentials

        public boolean deleteUserCredentials()
        Description copied from interface: CredentialsStore
        Deletes the stored user credentials.
        Specified by:
        deleteUserCredentials in interface CredentialsStore
        Returns:
        Whether the deleting of the credentials was successful.