accountmanager 调用说明

增加账户代码说明,

public AccountManagerFuture addAccount(final String accountType,
final String authTokenType, final String[] requiredFeatures,
final Bundle addAccountOptions,
final Activity activity, AccountManagerCallback callback, Handler handler)
会调用Response这个函数进行执行,进行创建service,这个service自动调用打开activiy对话框。
return new AmsTask(activity, handler, callback) {
@Override
public void doWork() throws RemoteException {
mService.addAccount(mResponse, accountType, authTokenType,
requiredFeatures, activity != null, optionsIn);
}
}.start();


调用accountManager的AddAccount-》AccountManagerService的addAccount-》打开service
Response对象在accountManager中创建的,在accountManagerServie中进行二次继承



转载于:https://www.cnblogs.com/istar/p/8251113.html

你可能感兴趣的:(accountmanager 调用说明)