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

# IDStorageFileX::Close

> IDStorageFileX::Close

# IDStorageFileX::Close

ファイルを閉じます。

## 構文

```cpp theme={null}
void Close(  
)  
```

### パラメーター

このメソッドにパラメーターはありません。

### 戻り値

Type: void

## 解説

このメソッドは、一致する `IDStorageFileX` オブジェクトの参照カウントに関係なく、ファイルを明示的に閉じます。

一致する `IDStorageFileX` オブジェクトへの最後の参照が解放されたとき、ファイルは暗黙的に閉じられます。

明示的または暗黙的にファイルを閉じる場合、未処理のすべての I/O 操作が完了するまでブロックされます。

`IDStorageFileX` オブジェクトが閉じられた後は、DirectStorage リクエストで使用できなくなります。

詳細については、[DirectStorage の概要](/build/console-features/storage/directstorage/directstorage-overview) の「IDStorageFileX」セクションを参照してください。

## 要件

**ヘッダー:** dstorage\_xs.h

**ライブラリ:** dstorage\_xs.lib

**サポートされているプラットフォーム:** XBOX Series 本体

## 関連項目

[IDStorageFactoryX::OpenFile](/reference/system/dstorage/interfaces/IDStorageFactoryX/methods/idstoragefactoryx_openfile)\
[IDStorageFileX](/reference/system/dstorage/interfaces/IDStorageFileX/idstoragefilex)


## Related topics

- [IDStorageFileX](/ja-jp/reference/system/dstorage/interfaces/IDStorageFileX/idstoragefilex.md)
- [IDStorageFactoryX::OpenFile](/ja-jp/reference/system/dstorage/interfaces/IDStorageFactoryX/methods/idstoragefactoryx_openfile.md)
- [IDStorageFileX::GetHandle](/ja-jp/reference/system/dstorage/interfaces/IDStorageFileX/methods/idstoragefilex_gethandle.md)
- [DirectStorage の概要](/ja-jp/build/console-features/storage/directstorage/directstorage-overview.md)
- [DStorage](/ja-jp/reference/system/dstorage/dstorage_members.md)
