Class ProductCollection
Provides helper methods to retrieve products by store independent/store specific id.
Namespace: UnityEngine.Purchasing
Syntax
public class ProductCollection
Properties
all
The array of all products
Declaration
public Product[] all { get; }
Property Value
Type | Description |
---|---|
Product[] |
set
The hash set of all products
Declaration
public HashSet<Product> set { get; }
Property Value
Type | Description |
---|---|
HashSet<Product> |
Methods
WithID(String)
Gets a product matching an id
Declaration
public Product WithID(string id)
Parameters
Type | Name | Description |
---|---|---|
String | id | The id of the desired product |
Returns
Type | Description |
---|---|
Product | The product matching the id, or null if not found |
WithStoreSpecificID(String)
Gets a product matching a store-specific id
Declaration
public Product WithStoreSpecificID(string id)
Parameters
Type | Name | Description |
---|---|---|
String | id | The store-specific id of the desired product |
Returns
Type | Description |
---|---|
Product | The product matching the id, or null if not found |