public class AccountManager extends Object implements DatabaseListener
| Constructor and Description |
|---|
AccountManager() |
public boolean isAutoSelectingAccount()
public SecureCharArray generatePassword(CharSequence masterPassword, String inputText)
masterPassword - master password to useinputText - the input textgeneratePassword(CharSequence, String, String)public SecureUTF8String generatePassword(CharSequence masterPassword, String inputText, String username)
masterPassword - - the masterpassword to useinputText - - the input text // url to use to find the account and generate the passwordusername - - (optional) the username to override the account's username unless its nilpublic void selectAccountById(String id) throws IllegalArgumentException
IllegalArgumentExceptionpublic void clearSelectedAccount()
public void selectAccountByUrl(String url) throws IllegalArgumentException
IllegalArgumentExceptionpublic PasswordMaker getPwm()
public Database getPwmProfiles()
public Account getSelectedProfile()
public void accountAdded(Account parent, Account account)
accountAdded in interface DatabaseListenerpublic void accountRemoved(Account parent, Account account)
accountRemoved in interface DatabaseListenerpublic void accountChanged(Account account)
accountChanged in interface DatabaseListenerpublic void dirtyStatusChanged(boolean b)
dirtyStatusChanged in interface DatabaseListenerpublic void addDatabaseListener(DatabaseListener listener)
public void removeDatabaseListener(DatabaseListener listener)
public void addListener(AccountManagerListener listener)
public void removeListener(AccountManagerListener listener)
public void addFavoriteUrl(String url)
public void addFavoriteUrls(Collection<String> urls)
public void removeFavoriteUrl(String url)
public String encodeFavoriteUrls()
public void decodeFavoritesUrls(String encodedUrlList, boolean clearFirst)
encodedUrlList - - String encoded version of the listclearFirst - - clear the list of favorites firstpublic Account getDefaultAccount() throws NoSuchElementException
NoSuchElementExceptionpublic boolean matchesPasswordHash(SecureUTF8String masterPassword)
public SecureCharArray getCurrentPasswordHash()
public void setCurrentPasswordHashPassword(String newPassword)
newPassword - - the new passwordpublic void replaceCurrentPasswordHash(SecureCharArray hash, String salt)
public String getPasswordSalt()
public boolean hasPasswordHash()
public boolean shouldStorePasswordHash()
public void setStorePasswordHash(boolean storePasswordHash)
public void disablePasswordHash()
Copyright © 2018. All rights reserved.