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

# WdCopyFilesStatusCallback

> WdCopyFilesStatusCallback

# WdCopyFilesStatusCallback

コピー操作中にファイル コピーの進行状況を報告するために呼び出されます。

## 構文

```cpp theme={null}
typedef HRESULT (*WdCopyFilesStatusCallback)(
    _In_ size_t fileProgressCount,
    _In_reads_opt_(fileProgressCount) const WdCopyFileProgressInfo* fileUpdates,
    _In_ const WdCopyOperationSummary* copyUpdates,
    _In_opt_ void* context
);
```

### パラメーター

`fileProgressCount _In_`\
Type: **size\_t**

前回のコールバック呼び出し以降に進捗更新があったファイルの数。

`fileUpdates _In_reads_opt_(fileProgressCount)`\
Type: **const [WdCopyFileProgressInfo](/reference/remoting/structs/wdcopyfileprogressinfo)\***

各要素が個々のファイルの進捗情報を含む [WdCopyFileProgressInfo](/reference/remoting/structs/wdcopyfileprogressinfo) 構造体の配列へのポインター。`fileProgressCount` が 0 の場合、`nullptr` の場合があります。

`copyUpdates _In_`\
Type: **const [WdCopyOperationSummary](/reference/remoting/structs/wdcopyoperationsummary)\***

全体のコピー操作の進捗の要約を含む [WdCopyOperationSummary](/reference/remoting/structs/wdcopyoperationsummary) 構造体へのポインター。

`context _In_opt_`
Type: **void\***

[WdCopyStatusCallbacks](/reference/remoting/structs/wdcopystatuscallbacks) 構造体で指定されたユーザー定義のコンテキスト ポインター。

### 戻り値

Type: **HRESULT**

コピー操作を継続するには `S_OK` を返します。コピーを中止するには失敗を示す HRESULT を返します。

## 解説

このコールバックは、[WdRemoteCopy](/reference/remoting/functions/wdremotecopy) により、コピー操作中に個々のファイルの進捗を報告するために呼び出されます。呼び出しの頻度は、[WdCopyStatusCallbacks](/reference/remoting/structs/wdcopystatuscallbacks) の `refreshRateMs` メンバーによって制御されます。

このコールバックから失敗した HRESULT を返すと、コピー操作が中止され、そのエラーが `WdRemoteCopy` から返されます。

このコールバックは、`WdRemoteCopy` の呼び出しと同じスレッド上で呼び出されます。`fileUpdates` 配列、`copyUpdates` 構造体、およびそれらの内容は、コールバック呼び出しの間のみ有効です。

## 要件

| 要件                   | 値                   |
| -------------------- | ------------------- |
| **ヘッダー**             | WdRemoteIteration.h |
| **ライブラリ**            | wdremoteapi.lib     |
| **サポートされている OS**     | Windows 11 以降       |
| **サポートされているアーキテクチャ** | x64、ARM64           |

## 関連項目

* [WdRemoteCopy](/reference/remoting/functions/wdremotecopy)
* [WdCopyFileProgressInfo](/reference/remoting/structs/wdcopyfileprogressinfo)
* [WdCopyOperationSummary](/reference/remoting/structs/wdcopyoperationsummary)
* [WdCopyStatusCallbacks](/reference/remoting/structs/wdcopystatuscallbacks)
* [XBOX PC Remote Iteration API](/reference/remoting/remoteiteration_members)


## Related topics

- [WdCopyStatusCallbacks](/ja-jp/reference/remoting/structs/wdcopystatuscallbacks.md)
- [WdCopyFileProgressInfo](/ja-jp/reference/remoting/structs/wdcopyfileprogressinfo.md)
- [WdCopyOperationSummary](/ja-jp/reference/remoting/structs/wdcopyoperationsummary.md)
- [XBOX PC Remote Iteration API](/ja-jp/reference/remoting/remoteiteration_members.md)
- [WdCopyErrorCallback](/ja-jp/reference/remoting/callbacks/wdcopyerrorcallback.md)
