> ## 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.

# XblErrorCondition

> XblErrorCondition

# XblErrorCondition

用于定义 XBOX Live API 错误条件的枚举值。

## 语法

```cpp theme={null}
enum class XblErrorCondition  : uint32_t  
{  
    NoError = 0,  
    GenericError,  
    GenericOutOfRange,  
    Auth,  
    Network,  
    HttpGeneric,  
    Http304NotModified,  
    Http404NotFound,  
    Http412PreconditionFailed,  
    Http429TooManyRequests,  
    HttpServiceTimeout,  
    Rta  
}  
```

## 常量

| 常量                        | 说明                                     |
| ------------------------- | -------------------------------------- |
| NoError                   | 无错误。                                   |
| GenericError              | 一般性错误条件。                               |
| GenericOutOfRange         | 与对象超出范围相关的错误条件。                        |
| Auth                      | 与尝试进行身份验证相关的错误条件。                      |
| Network                   | 与网络连接相关的错误条件。                          |
| HttpGeneric               | 与 HTTP 方法调用相关的错误条件。                    |
| Http304NotModified        | 请求的资源未被修改。                             |
| Http404NotFound           | 找不到请求的资源。                              |
| Http412PreconditionFailed | 请求头字段中给出的一个或多个先决条件在服务器上进行测试时评估为 false。 |
| Http429TooManyRequests    | 客户端发送的请求过多。                            |
| HttpServiceTimeout        | 服务尝试处理请求时超时。                           |
| Rta                       | 与实时活动相关的错误。                            |

## 备注

最佳实践是使用 [XblGetErrorCondition](/reference/live/xsapi-c/errors_c/functions/xblgeterrorcondition) 针对这些错误条件测试返回的 HRESULT。

## 要求

**头文件：** errors\_c.h

## 另请参阅

[errors\_c](/reference/live/xsapi-c/errors_c/errors_c_members)


## Related topics

- [XblGetErrorCondition](/zh-CN/reference/live/xsapi-c/errors_c/functions/xblgeterrorcondition.md)
- [XblTitleStorageETagMatchCondition](/zh-CN/reference/live/xsapi-c/title_storage_c/enums/xbltitlestorageetagmatchcondition.md)
- [面向 GDK 的 Unity C# API 包装器](/zh-CN/build/gdk-and-engines/unity/unity-api-wrappers.md)
- [从 Title Storage 下载 blob](/zh-CN/services/xbox-services/storage/title-storage/how-to/live-downloading-title-storage-blob.md)
- [XblTitleStorageDownloadBlobAsync](/zh-CN/reference/live/xsapi-c/title_storage_c/functions/xbltitlestoragedownloadblobasync.md)
