Quicknav Quicknav
Links

- Google Play Developer Console
- Android Developers Blog
- About Android

Android Sites

- Android.com
- Android Developers
- Android Open Source Project

close

- - Get Started
  - Style
  - Patterns
  - Building Blocks
  - Downloads
  - Videos
- - Training
  - API Guides
  - Reference
  - Tools
    - Get the SDK
  - Google Services
- - Google Play
  - Publishing
  - Promoting
  - App Quality
  - Spotlight
  - Open Distribution

## Results

Loading...
Summary: Inherited Constants | Fields | Methods | Inherited Methods | [Expand All]
public final class

# GameEntity

extends Object
implements Parcelable Game

java.lang.Object
↳ | com.google.android.gms.games.GameEntity

## Class Overview

Data object representing a set of Game data. This is immutable, and therefore safe to cache or store. Note, however, that the data it represents may grow stale.

This class exists solely to support parceling these objects and should not be used directly.

## Summary

[Expand] Inherited Constants

From interface android.os.Parcelable

int | CONTENTS_FILE_DESCRIPTOR |
int | PARCELABLE_WRITE_RETURN_VALUE |

Fields
public static final Creator<GameEntity> | CREATOR |

Public Methods
int | describeContents()
boolean | equals(Object obj)
Game | freeze() Freeze a volatile representation into an immutable representation.
int | getAchievementTotalCount() Retrieves the number of achievements registered for this game.
String | getApplicationId() Retrieves the application ID for this game.
String | getDescription() Retrieves the description of this game.
void | getDescription(CharArrayBuffer dataOut) Loads the description string into the given `CharArrayBuffer`.
String | getDeveloperName() Retrieves the name of the developer of this game.
void | getDeveloperName(CharArrayBuffer dataOut) Loads the developer name into the given `CharArrayBuffer`.
String | getDisplayName() Retrieves the display name for this game.
void | getDisplayName(CharArrayBuffer dataOut) Loads the display name string into the given `CharArrayBuffer`.
Uri | getFeaturedImageUri() Retrieves an image URI that can be used to load the game's featured (banner) image from Google Play.
int | getGameplayAclStatus()
Uri | getHiResImageUri() Retrieves an image URI that can be used to load the game's hi-res image.
Uri | getIconImageUri() Retrieves an image URI that can be used to load the game's icon.
String | getInstancePackageName()
int | getLeaderboardCount() Gets the number of leaderboards registered for this game.
String | getPrimaryCategory() Retrieves the primary category of the game - this is may be null.
String | getSecondaryCategory() Retrieves the secondary category of the game - this may be null.
int | hashCode()
boolean | isDataValid() Check to see if this object is valid for use.
boolean | isInstanceInstalled()
boolean | isPlayEnabledGame()
boolean | isRealTimeMultiplayerEnabled() Indicates whether or not this game supports real-time multiplayer.
boolean | isTurnBasedMultiplayerEnabled() Indicates whether or not this game supports turn-based multiplayer.
String | toString()
void | writeToParcel(Parcel dest, int flags)

[Expand] Inherited Methods

From class java.lang.Object

Object | clone()
boolean | equals(Object arg0)
void | finalize()
final Class<?> | getClass()
int | hashCode()
final void | notify()
final void | notifyAll()
String | toString()
final void | wait()
final void | wait(long arg0, int arg1)
final void | wait(long arg0)

From interface android.os.Parcelable

abstract int | describeContents()
abstract void | writeToParcel(Parcel arg0, int arg1)

From interface com.google.android.gms.common.data.Freezable

abstract T | freeze() Freeze a volatile representation into an immutable representation.
abstract boolean | isDataValid() Check to see if this object is valid for use.

From interface com.google.android.gms.games.Game

abstract int | getAchievementTotalCount() Retrieves the number of achievements registered for this game.
abstract String | getApplicationId() Retrieves the application ID for this game.
abstract String | getDescription() Retrieves the description of this game.
abstract void | getDescription(CharArrayBuffer dataOut) Loads the description string into the given `CharArrayBuffer`.
abstract String | getDeveloperName() Retrieves the name of the developer of this game.
abstract void | getDeveloperName(CharArrayBuffer dataOut) Loads the developer name into the given `CharArrayBuffer`.
abstract String | getDisplayName() Retrieves the display name for this game.
abstract void | getDisplayName(CharArrayBuffer dataOut) Loads the display name string into the given `CharArrayBuffer`.
abstract Uri | getFeaturedImageUri() Retrieves an image URI that can be used to load the game's featured (banner) image from Google Play.
abstract Uri | getHiResImageUri() Retrieves an image URI that can be used to load the game's hi-res image.
abstract Uri | getIconImageUri() Retrieves an image URI that can be used to load the game's icon.
abstract int | getLeaderboardCount() Gets the number of leaderboards registered for this game.
abstract String | getPrimaryCategory() Retrieves the primary category of the game - this is may be null.
abstract String | getSecondaryCategory() Retrieves the secondary category of the game - this may be null.
abstract boolean | isRealTimeMultiplayerEnabled() Indicates whether or not this game supports real-time multiplayer.
abstract boolean | isTurnBasedMultiplayerEnabled() Indicates whether or not this game supports turn-based multiplayer.

## Fields

#### public static final Creator<GameEntity> CREATOR

## Public Methods

#### public int describeContents ()

#### public boolean equals (Object obj)

#### public Game freeze ()

Freeze a volatile representation into an immutable representation. Objects returned from this call are safe to cache.

Note that the output of `freeze` may not be identical to the parent object, but should be equal. In other words:

     Freezable f1 = new Freezable();
     Freezable f2 = f1.freeze();
     f1 == f2 may not be true.
     f1.equals(f2) will be true.

##### Returns

- A concrete implementation of the data object.

#### public int getAchievementTotalCount ()

Retrieves the number of achievements registered for this game.

##### Returns

- The number of achievements registered for this game.

#### public String getApplicationId ()

Retrieves the application ID for this game.

##### Returns

- The application ID for this game.

#### public String getDescription ()

Retrieves the description of this game.

##### Returns

- The description of this game.

#### public void getDescription (CharArrayBuffer dataOut)

Loads the description string into the given `CharArrayBuffer`.

##### Parameters

dataOut | The buffer to load the data into.

#### public String getDeveloperName ()

Retrieves the name of the developer of this game.

##### Returns

- The name of the developer of this game.

#### public void getDeveloperName (CharArrayBuffer dataOut)

Loads the developer name into the given `CharArrayBuffer`.

##### Parameters

dataOut | The buffer to load the data into.

#### public String getDisplayName ()

Retrieves the display name for this game.

##### Returns

- The display name for this game.

#### public void getDisplayName (CharArrayBuffer dataOut)

Loads the display name string into the given `CharArrayBuffer`.

##### Parameters

dataOut | The buffer to load the data into.

#### public Uri getFeaturedImageUri ()

Retrieves an image URI that can be used to load the game's featured (banner) image from Google Play. Returns null if game has no featured image.

To retrieve the Image from the `Uri`, use `ImageManager`.

##### Returns

- A URI that can be used to load the game's featured image, or null if the game has no featured image.

#### public int getGameplayAclStatus ()

#### public Uri getHiResImageUri ()

Retrieves an image URI that can be used to load the game's hi-res image. Returns null if game has no hi-res image.

To retrieve the Image from the `Uri`, use `ImageManager`.

##### Returns

- A URI that can be used to load the game's hi-res image, or null if the game has no hi-res image.

#### public Uri getIconImageUri ()

Retrieves an image URI that can be used to load the game's icon. Returns null if game has no icon.

To retrieve the Image from the `Uri`, use `ImageManager`.

##### Returns

- A URI that can be used to load the game's icon, or null if the game has no icon.

#### public String getInstancePackageName ()

#### public int getLeaderboardCount ()

Gets the number of leaderboards registered for this game.

##### Returns

- The number of leaderboards registered for this game.

#### public String getPrimaryCategory ()

Retrieves the primary category of the game - this is may be null.

##### Returns

- The primary category of the game.

#### public String getSecondaryCategory ()

Retrieves the secondary category of the game - this may be null.

##### Returns

- The secondary category of the game, or null if not provided.

#### public int hashCode ()

#### public boolean isDataValid ()

Check to see if this object is valid for use. If the object is still volatile, this method will indicate whether or not the object can be safely used. The output of a call to `freeze()` will always be valid.

##### Returns

- whether or not the object is valid for use.

#### public boolean isInstanceInstalled ()

#### public boolean isPlayEnabledGame ()

#### public boolean isRealTimeMultiplayerEnabled ()

Indicates whether or not this game supports real-time multiplayer.

##### Returns

- Whether or not this game supports real-time mulitplayer.

#### public boolean isTurnBasedMultiplayerEnabled ()

Indicates whether or not this game supports turn-based multiplayer.

##### Returns

- Whether or not this game supports turn-based mulitplayer.

#### public String toString ()

#### public void writeToParcel (Parcel dest, int flags)