public class

Inventory

extends Object
java.lang.Object
   ↳ com.c2call.sdk.pub.billing.util.Inventory

Class Overview

Represents a block of information about in-app items. An Inventory is returned by such methods as queryInventory(boolean, List).

Summary

Public Methods
void erasePurchase(String sku)
Erase a purchase (locally) from the inventory, given its product ID.
List<SkuDetails> getAllSkuDetails()
Purchase getPurchase(String sku)
Returns purchase information for a given product, or null if there is no purchase.
SkuDetails getSkuDetails(String sku)
Returns the listing details for an in-app product.
boolean hasDetails(String sku)
Return whether or not details about the given product are available.
boolean hasPurchase(String sku)
Returns whether or not there exists a purchase of the given product.
String toString()
[Expand]
Inherited Methods
From class java.lang.Object

Public Methods

public void erasePurchase (String sku)

Erase a purchase (locally) from the inventory, given its product ID. This just modifies the Inventory object locally and has no effect on the server! This is useful when you have an existing Inventory object which you know to be up to date, and you have just consumed an item successfully, which means that erasing its purchase data from the Inventory you already have is quicker than querying for a new Inventory.

public List<SkuDetails> getAllSkuDetails ()

public Purchase getPurchase (String sku)

Returns purchase information for a given product, or null if there is no purchase.

public SkuDetails getSkuDetails (String sku)

Returns the listing details for an in-app product.

public boolean hasDetails (String sku)

Return whether or not details about the given product are available.

public boolean hasPurchase (String sku)

Returns whether or not there exists a purchase of the given product.

public String toString ()