public class

GoogleSignInOptions

extends Object
implements Parcelable Api.ApiOptions.Optional Parcelable
java.lang.Object
   ↳ com.google.android.gms.auth.api.signin.GoogleSignInOptions

Class Overview

GoogleSignInOptions is options used to configure the GOOGLE_SIGN_IN_API.

Summary

Nested Classes
class GoogleSignInOptions.Builder Builder for GoogleSignInOptions,  
[Expand]
Inherited Constants
From interface android.os.Parcelable
Fields
public static final Creator<GoogleSignInOptions> CREATOR
public static final GoogleSignInOptions DEFAULT_GAMES_SIGN_IN Default and recommended configuration for Games Sign In.
public static final GoogleSignInOptions DEFAULT_SIGN_IN Default configuration for Google Sign In.
Public Methods
boolean equals(Object obj)
Scope[] getScopeArray()
Gets an array of all the requested scopes.
int hashCode()
void writeToParcel(Parcel out, int flags)
[Expand]
Inherited Methods
From class java.lang.Object
From interface android.os.Parcelable

Fields

public static final Creator<GoogleSignInOptions> CREATOR

public static final GoogleSignInOptions DEFAULT_GAMES_SIGN_IN

Default and recommended configuration for Games Sign In.

To maximize chance of auto-sign-in, do NOT use requestScopes(Scope, Scope...) to request additional scopes and do NOT use requestIdToken(String) to request user's real Google identity assertion.

public static final GoogleSignInOptions DEFAULT_SIGN_IN

Default configuration for Google Sign In. You can get a stable user ID and basic profile info back via getId() after you trigger sign in from either silentSignIn(GoogleApiClient) or getSignInIntent(GoogleApiClient). If you require more information for the sign in result, please build a configuration via new GoogleSignInOptions.Builder(GoogleSignInOptions.DEFAULT_SIGN_IN)}.

Public Methods

public boolean equals (Object obj)

Parameters
obj Object
Returns
boolean

public Scope[] getScopeArray ()

Gets an array of all the requested scopes. If you use DEFAULT_SIGN_IN, this array will also include those scopes set by default in DEFAULT_SIGN_IN.

A usage of this method could be set the scopes for the contextual SignInButton. E.g., signInButton.setScopes(googleSignInOptions.getScopeArray())

Returns
Scope[]

public int hashCode ()

Returns
int

public void writeToParcel (Parcel out, int flags)

Parameters
out Parcel
flags int