@Override protected String toDebugString(long now) { return super.toDebugString(now) + ", getAuthToken" + ", " + account + ", authTokenType " + authTokenType + ", loginOptions " + loginOptions + ", notifyOnAuthFailure " + notifyOnAuthFailure; }
IAccountManagerResponse getResponseAndClose() { if (mResponse == null) { // this session has already been closed return null; } IAccountManagerResponse response = mResponse; close(); // this clears mResponse so we need to save the response before this call return response; }
@Override public boolean removeAccountExplicitly(int userId, Account account) { return account != null && removeAccountInternal(userId, account); }
@Override public void run() throws RemoteException { mAccountsOfType = getAccounts(mUserId, mAuthenticatorInfo.desc.type); // check whether each account matches the requested features mAccountsWithFeatures = new ArrayList<Account>(mAccountsOfType.length); mCurrentAccount = 0; checkAccount(); }
public static void systemReady() { VAccountManagerService service = new VAccountManagerService(); service.readAllAccounts(); sInstance.set(service); }
public void refreshServiceCache(String packageName) { Intent intent = new Intent("android.content.SyncAdapter"); if (packageName != null) { intent.setPackage(packageName); } generateServicesMap( VPackageManagerService.get().queryIntentServices( intent, null, PackageManager.GET_META_DATA, 0 ), mAppSyncAdapterInfos, new RegisteredServicesParser() ); }
private VAccount getAccount(int userId, Account account) { return this.getAccount(userId, account.name, account.type); }
@Override public void setPassword(int userId, Account account, String password) { if (account == null) throw new IllegalArgumentException("account is null"); setPasswordInternal(userId, account, password); }
@Override public boolean equals(Object obj) { return VSyncRecord.equals(this.extras, ((SyncExtras) obj).extras, false); } }
public VSyncRecord(int userId, Account account, String authority) { this.userId = userId; key = new SyncRecordKey(account, authority); }
@Override public void onResult(Bundle result) throws RemoteException { if (result != null) { String label = result.getString(AccountManager.KEY_AUTH_TOKEN_LABEL); Bundle bundle = new Bundle(); bundle.putString(AccountManager.KEY_AUTH_TOKEN_LABEL, label); super.onResult(bundle); } else { super.onResult(null); } } }.bind();
@Override protected String toDebugString(long now) { return super.toDebugString(now) + ", editProperties" + ", accountType " + accountType; }
@Override public final String getPreviousName(int userId, Account account) { if (account == null) throw new IllegalArgumentException("account is null"); synchronized (accountsByUserId) { String previousName = null; VAccount vAccount = getAccount(userId, account); if (vAccount != null) { previousName = vAccount.previousName; } return previousName; } }
@Override public void binderDied() { mResponse = null; close(); } }
@Override public void clearPassword(int userId, Account account) { if (account == null) throw new IllegalArgumentException("account is null"); setPasswordInternal(userId, account, null); }
@Override protected String toDebugString(long now) { return super.toDebugString(now) + ", removeAccount" + ", account " + account; }
@Override public String getPassword(int userId, Account account) { if (account == null) throw new IllegalArgumentException("account is null"); synchronized (accountsByUserId) { VAccount vAccount = getAccount(userId, account); if (vAccount != null) { return vAccount.password; } return null; } }
@Override protected String toDebugString(long now) { return super.toDebugString(now) + ", addAccount" + ", accountType " + accountType + ", requiredFeatures " + (requiredFeatures != null ? TextUtils.join(",", requiredFeatures) : null); }
@Override protected String toDebugString(long now) { return super.toDebugString(now) + ", getAccountsByTypeAndFeatures" + ", " + (mFeatures != null ? TextUtils.join(",", mFeatures) : null); } }