Please note that the contents of this offline web site may be out of date. To access the most recent documentation visit the online version .
Note that links that point to online resources are green in color and will open in a new window.
We would love it if you could give us feedback about this material by filling this form (You have to be online to fill it)
Android APIs
public class

AccountAuthenticatorActivity

extends Activity
java.lang.Object
   ↳ android.content.Context
     ↳ android.content.ContextWrapper
       ↳ android.view.ContextThemeWrapper
         ↳ android.app.Activity
           ↳ android.accounts.AccountAuthenticatorActivity

Class Overview

Base class for implementing an Activity that is used to help implement an AbstractAccountAuthenticator. If the AbstractAccountAuthenticator needs to use an activity to handle the request then it can have the activity extend AccountAuthenticatorActivity. The AbstractAccountAuthenticator passes in the response to the intent using the following:

        intent.putExtra(
        
         
          KEY_ACCOUNT_AUTHENTICATOR_RESPONSE
         
        
        , response);
       
The activity then sets the result that is to be handed to the response via setAccountAuthenticatorResult(android.os.Bundle) . This result will be sent as the result of the request when the activity finishes. If this is never set or if it is set to null then error ERROR_CODE_CANCELED will be called on the response.

Summary

[Expand]
Inherited Constants
From class android.app.Activity
From class android.content.Context
From interface android.content.ComponentCallbacks2
[Expand]
Inherited Fields
From class android.app.Activity
Public Constructors
AccountAuthenticatorActivity ()
Public Methods
void finish ()
Sends the result or a Constants.ERROR_CODE_CANCELED error if a result isn't present.
final void setAccountAuthenticatorResult ( Bundle result)
Set the result that is to be sent as the result of the request that caused this Activity to be launched.
Protected Methods
void onCreate ( Bundle icicle)
Retreives the AccountAuthenticatorResponse from either the intent of the icicle, if the icicle is non-zero.
[Expand]
Inherited Methods
From class android.app.Activity
From class android.view.ContextThemeWrapper
From class android.content.ContextWrapper
From class android.content.Context
From class java.lang.Object
From interface android.content.ComponentCallbacks
From interface android.content.ComponentCallbacks2
From interface android.view.KeyEvent.Callback
From interface android.view.LayoutInflater.Factory
From interface android.view.LayoutInflater.Factory2
From interface android.view.View.OnCreateContextMenuListener
From interface android.view.Window.Callback

Public Constructors

public AccountAuthenticatorActivity ()

Added in API level 5

Public Methods

public void finish ()

Added in API level 5

Sends the result or a Constants.ERROR_CODE_CANCELED error if a result isn't present.

public final void setAccountAuthenticatorResult ( Bundle result)

Added in API level 5

Set the result that is to be sent as the result of the request that caused this Activity to be launched. If result is null or this method is never called then the request will be canceled.

Parameters
result this is returned as the result of the AbstractAccountAuthenticator request

Protected Methods

protected void onCreate ( Bundle icicle)

Added in API level 5

Retreives the AccountAuthenticatorResponse from either the intent of the icicle, if the icicle is non-zero.

Parameters
icicle the save instance data of this Activity, may be null