AbstractAccountAuthenticator.FinishSession 方法
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
通过使用 AccountManager 将帐户安装到设备或更新本地凭据,完成 #startAddAccountSession 或 #startUpdateCredentials 启动的会话。
[Android.Runtime.Register("finishSession", "(Landroid/accounts/AccountAuthenticatorResponse;Ljava/lang/String;Landroid/os/Bundle;)Landroid/os/Bundle;", "GetFinishSession_Landroid_accounts_AccountAuthenticatorResponse_Ljava_lang_String_Landroid_os_Bundle_Handler", ApiSince=26)]
public virtual Android.OS.Bundle? FinishSession (Android.Accounts.AccountAuthenticatorResponse? response, string? accountType, Android.OS.Bundle? sessionBundle);
[<Android.Runtime.Register("finishSession", "(Landroid/accounts/AccountAuthenticatorResponse;Ljava/lang/String;Landroid/os/Bundle;)Landroid/os/Bundle;", "GetFinishSession_Landroid_accounts_AccountAuthenticatorResponse_Ljava_lang_String_Landroid_os_Bundle_Handler", ApiSince=26)>]
abstract member FinishSession : Android.Accounts.AccountAuthenticatorResponse * string * Android.OS.Bundle -> Android.OS.Bundle
override this.FinishSession : Android.Accounts.AccountAuthenticatorResponse * string * Android.OS.Bundle -> Android.OS.Bundle
参数
- response
- AccountAuthenticatorResponse
将结果发送回 AccountManager,永远不会为 null
- accountType
- String
要进行身份验证的帐户类型永远不会为 null
- sessionBundle
- Bundle
一组会话数据,用于 #startAddAccountSession
将帐户添加到设备,或 #startUpdateCredentialsSession
用于更新本地凭据。
返回
如果通过响应返回结果,则为捆绑结果或 null。 结果将包含:<ul><li、liAccountManager#KEY_ACCOUNT_NAME
AccountManager#KEY_INTENT
>> 和AccountManager#KEY_ACCOUNT_TYPE
已添加的帐户或<已更新本地凭据的帐户,<以及稍后检查帐户状态(可选AccountManager#KEY_ACCOUNT_STATUS_TOKEN
)或 liAccountManager#KEY_ERROR_CODE
>,并AccountManager#KEY_ERROR_MESSAGE
指示错误 </ul>
- 属性
注解
通过使用 AccountManager 将帐户安装到设备或更新本地凭据,完成 #startAddAccountSession 或 #startUpdateCredentials 启动的会话。 可以在此调用中执行文件 I/O。
注意:重写此方法时, #startAddAccountSession
#startUpdateCredentialsSession
还应重写此方法。
本页的某些部分是根据 Android 开放源代码项目创建和共享的工作进行的修改,并根据 Creative Commons 2.5 属性许可证中所述的术语使用。