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

# XPackageUninstallChunks

> XPackageUninstallChunks

# XPackageUninstallChunks

지정된 선택자와 일치하는 청크를 제거합니다.

## 구문

```cpp theme={null}
HRESULT XPackageUninstallChunks(  
         const char* packageIdentifier,  
         uint32_t selectorCount,  
         XPackageChunkSelector* selectors  
)  
```

### 매개 변수

*packageIdentifier*   \_In\_z\_\
형식: char\*

디스크에 설치된 패키지를 고유하게 식별하는 문자열입니다. 패키지 식별자에 대한 자세한 내용은 [다운로드 가능한 콘텐츠(DLC) 관리 및 라이선스](https://learn.microsoft.com/gaming/gdk/docs/store/commerce/fundamentals/xstore-manage-and-license-optional-packages)를 참조하세요.

*selectorCount*   \_In\_\
형식: uint32\_t

*selectors* 매개 변수의 선택자 수입니다.

*selectors*   \_In\_reads\_(selectorCount)\
형식: [XPackageChunkSelector\*](/reference/system/xpackage/structs/xpackagechunkselector)

제거할 청크를 지정하는 선택자 배열입니다.

정수 ID만을 사용하여 제거할 청크를 지정하는 것은 지원되지 않습니다. 이렇게 하려고 하면 **XPackageUninstallChunks**가 E\_INVALIDARG 값을 반환합니다. 제거할 청크를 지정하려면 언어 또는 태그와 같은 선택자에 대한 추가 정보를 제공하세요.

### 반환 값

형식: HRESULT

HRESULT 성공 또는 오류 코드입니다.

## 설명

<Note>이 함수는 시간에 민감한 스레드에서 호출해서는 안전하지 않습니다. 자세한 내용은 [시간에 민감한 스레드](https://learn.microsoft.com/gaming/gdk/docs/gdk-dev/console-dev/overviews/threads/time-sensitive-threads)를 참조하세요.</Note>

**XPackageUninstallChunks**는 지정된 설치 선택자와 일치하는 청크를 제거합니다. 패키지가 작동하는 데 필요한 청크는 제거되지 않습니다. 예를 들어 현재 실행 중인 게임의 언어에 대한 자산을 제공하는 데 필요한 청크는 제거할 수 없습니다.

청크가 제거될 때 타이틀은 중지되지 않습니다. 타이틀은 제거하는 청크와 더 이상 파일에 액세스하지 않는 청크의 모든 파일 핸들을 닫아야 합니다.

다음 예제에서 **XPackageUninstallChunks**는 태그가 "BigMaps"인 맵 패키지를 제거하는 데 사용됩니다.

```cpp theme={null}
HRESULT UninstallBigMaps()
{
    char id[XPACKAGE_IDENTIFIER_MAX_LENGTH];
    HRESULT hr = XPackageGetCurrentProcessPackageIdentifier(_countof(id), id);
    if (FAILED(hr)) return hr;

    XPackageChunkSelector selector;
    selector.type = XPackageChunkSelectorType::Tag;
    selector.tag = "BigMaps";

    hr = XPackageUninstallChunks(id, 1, &selector);
    return hr;
}
```

## 요구 사항

**헤더:** XPackage.h

**라이브러리:** xgameruntime.lib

**지원 플랫폼:** Windows, XBOX One 제품군 콘솔 및 XBOX Series 콘솔

## 개념 문서

* [Intelligent Delivery: 언어 지정자](/build/core-features/common/packaging/intelligentdelivery-language)
* [Intelligent Delivery: OnDemand 콘텐츠](/build/core-features/common/packaging/intelligentdelivery-ondemand)
* [시간에 민감한 스레드](https://learn.microsoft.com/gaming/gdk/docs/gdk-dev/console-dev/overviews/threads/time-sensitive-threads)

## 함께 보기

[XPackage](/reference/system/xpackage/xpackage_members)\
[스트리밍 설치 및 Intelligent Delivery](/build/core-features/common/packaging/overviews/streaming_install-intelligent_delivery)


## Related topics

- [XPackageUninstallUWPInstance](/ko/reference/system/xpackage/functions/xpackageuninstalluwpinstance.md)
- [Intelligent Delivery: OnDemand 콘텐츠](/ko/build/core-features/common/packaging/intelligentdelivery-ondemand.md)
- [XPackage](/ko/reference/system/xpackage/xpackage_members.md)
- [GDK용 Unity C# API 래퍼](/ko/build/gdk-and-engines/unity/unity-api-wrappers.md)
- [XPackageUninstallPackage](/ko/reference/system/xpackage/functions/xpackageuninstallpackage.md)
