C# Class Ouya.Console.Api.OuyaFacade

Entry point for the OUYA API. Applications should use the singleton instance.
Exibir arquivo Open project: KonajuGames/ouya-csharp Class Usage Examples

Public Methods

Method Description
Init ( Android context, string developerUuid ) : void

Initializes the facade. Should only be called once.

RequestGamerInfoAsync ( ) : Task

Requests the current gamer's info.

RequestProductListAsync ( ) : Task>

Returns a list of Product objects that describe the products (including current price) associated with the specified list of Purchasables.

RequestProductListAsync ( IList purchasables ) : Task>

Returns a list of Product objects that describe the products (including current price) associated with the specified list of Purchasables.

RequestPurchaseAsync ( Product product ) : Task

Requests that the specified Purchasable be purchased on behalf of the current user. The IAP client service is responsible for identifying the user and requesting credentials as appropriate, as well as providing all of the UI for the purchase flow. When purchases are successful, a Product object is returned that describes the product that was purchased.

RequestReceiptsAsync ( ) : Task>

Requests the current receipts from the Store. If the Store is not available, the cached receipts from a previous call are returned.

Private Methods

Method Description
Log ( string msg ) : void
RequestGamerUuidAsync ( ) : Task

Method Details

Init() public method

Initializes the facade. Should only be called once.
public Init ( Android context, string developerUuid ) : void
context Android An Android Context object. Usually the Activity object.
developerUuid string The developer UUID, which is obtained from the developer portal.
return void

RequestGamerInfoAsync() public method

Requests the current gamer's info.
public RequestGamerInfoAsync ( ) : Task
return Task

RequestProductListAsync() public method

Returns a list of Product objects that describe the products (including current price) associated with the specified list of Purchasables.
public RequestProductListAsync ( ) : Task>
return Task>

RequestProductListAsync() public method

Returns a list of Product objects that describe the products (including current price) associated with the specified list of Purchasables.
public RequestProductListAsync ( IList purchasables ) : Task>
purchasables IList A list of Purchasable objects that identify the products to be returned.
return Task>

RequestPurchaseAsync() public method

Requests that the specified Purchasable be purchased on behalf of the current user. The IAP client service is responsible for identifying the user and requesting credentials as appropriate, as well as providing all of the UI for the purchase flow. When purchases are successful, a Product object is returned that describes the product that was purchased.
public RequestPurchaseAsync ( Product product ) : Task
product Product The Purchasable object that describes the item to be purchased.
return Task

RequestReceiptsAsync() public method

Requests the current receipts from the Store. If the Store is not available, the cached receipts from a previous call are returned.
public RequestReceiptsAsync ( ) : Task>
return Task>