> ## Documentation Index
> Fetch the complete documentation index at: https://devdocs.xbox.com/llms.txt
> Use this file to discover all available pages before exploring further.

# XStoreProductQueryCallback

> XStoreProductQueryCallback

# XStoreProductQueryCallback

产品查询的、由游戏定义的回调。

## 语法

```cpp theme={null}
bool XStoreProductQueryCallback(  
         const XStoreProduct* product,  
         void* context  
)  
```

### 参数

*product*   \_In\_\
类型：[XStoreProduct\*](/reference/system/xstore/structs/xstoreproduct)

产品的描述。

*context*   \_In\_opt\_\
类型：void\*

要传递给回调的、由游戏定义的上下文。

### 返回值

类型：bool

返回 true 表示继续枚举查询结果；返回 false 则相反。

## 备注

此由游戏定义的函数用于从枚举的一组应用商店产品中读取信息。该函数的返回类型和参数必须与此处提供的定义相同，并用作 [XStoreEnumerateProductsQuery](/reference/system/xstore/functions/xstoreenumerateproductsquery) 函数的回调。有关用法示例，请参阅 [XStoreQueryAssociatedProductsAsync](/reference/system/xstore/functions/xstorequeryassociatedproductsasync)。

## 要求

**头文件：** XStore.h（包含于 XGameRuntime.h 中）

**库：** xgameruntime.lib

**支持的平台：** Windows、XBOX One 系列主机和 XBOX Series 主机

## 另请参阅

[XStore](/reference/system/xstore/xstore_members)\
[XStoreEnumerateProductsQuery](/reference/system/xstore/functions/xstoreenumerateproductsquery)\
[XStoreQueryAssociatedProductsAsync](/reference/system/xstore/functions/xstorequeryassociatedproductsasync)


## Related topics

- [XStoreEnumerateProductsQuery](/zh-CN/reference/system/xstore/functions/xstoreenumerateproductsquery.md)
- [XStore](/zh-CN/reference/system/xstore/xstore_members.md)
- [XStoreQueryProductsAsync](/zh-CN/reference/system/xstore/functions/xstorequeryproductsasync.md)
- [XStoreQueryProductsResult](/zh-CN/reference/system/xstore/functions/xstorequeryproductsresult.md)
- [XStoreQueryProductForPackageAsync](/zh-CN/reference/system/xstore/functions/xstorequeryproductforpackageasync.md)
