public interface

Account

com.google.android.gms.plus.Account

This interface is deprecated.
replaced by GoogleSignInApi. See Google Sign-In for guidance on integrating with this API.

Class Overview

The main entry point for Google+ account management. To use these features, you should add the API to your GoogleApiClient.Builder.

Summary

Public Methods
abstract void clearDefaultAccount(GoogleApiClient googleApiClient)
This method is deprecated. replaced with signOut(GoogleApiClient)
abstract String getAccountName(GoogleApiClient googleApiClient)
This method is deprecated. Use GoogleSignInApi and getSignInAccount() and you can get the account name via getEmail().
abstract PendingResult<Status> revokeAccessAndDisconnect(GoogleApiClient googleApiClient)
This method is deprecated. replaced with revokeAccess(GoogleApiClient)

Public Methods

public abstract void clearDefaultAccount (GoogleApiClient googleApiClient)

This method is deprecated.
replaced with signOut(GoogleApiClient)

Removes the default account set in Google Play services for your app. Subsequent calls to connect() will return a resolution intent that will let the user select a different account.

If the user chooses the same account, no consent will be required since access to the app is not revoked. Users should also be given the option to revoke access with revokeAccessAndDisconnect(GoogleApiClient).

Required API: API

Parameters
googleApiClient GoogleApiClient: The connected GoogleApiClient to service the call.

public abstract String getAccountName (GoogleApiClient googleApiClient)

This method is deprecated.
Use GoogleSignInApi and getSignInAccount() and you can get the account name via getEmail().

Gets the account name resolved by Google Play services. The permission &lt;uses-permission android:name="android.permission.GET_ACCOUNTS" /&gt; must be declared in your AndroidManifest.xml to use this method.

Required API: API

Parameters
googleApiClient GoogleApiClient: The connected GoogleApiClient to service the call.
Returns
String The account name. If the user has not selected an account, null is returned.
Throws
SecurityException If your app doesn't have the GET_ACCOUNTS permission.

public abstract PendingResult<Status> revokeAccessAndDisconnect (GoogleApiClient googleApiClient)

This method is deprecated.
replaced with revokeAccess(GoogleApiClient)

Revokes access given to the current application.

Required API: API

Parameters
googleApiClient GoogleApiClient: The connected GoogleApiClient to service the call.
Returns
PendingResult<Status> the PendingResult for notification and access to the result when it's available.