你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn

ShareDirectoryClient.GetHandlesAsync Method

Definition

The GetHandlesAsync(Nullable<Boolean>, CancellationToken) operation returns an async sequence of the open handles on a directory or a file. Enumerating the handles may make multiple requests to the service while fetching all the values.

For more information, see List Handles.

public virtual Azure.AsyncPageable<Azure.Storage.Files.Shares.Models.ShareFileHandle> GetHandlesAsync(bool? recursive = default, System.Threading.CancellationToken cancellationToken = default);
abstract member GetHandlesAsync : Nullable<bool> * System.Threading.CancellationToken -> Azure.AsyncPageable<Azure.Storage.Files.Shares.Models.ShareFileHandle>
override this.GetHandlesAsync : Nullable<bool> * System.Threading.CancellationToken -> Azure.AsyncPageable<Azure.Storage.Files.Shares.Models.ShareFileHandle>
Public Overridable Function GetHandlesAsync (Optional recursive As Nullable(Of Boolean) = Nothing, Optional cancellationToken As CancellationToken = Nothing) As AsyncPageable(Of ShareFileHandle)

Parameters

recursive
Nullable<Boolean>

Optional. A boolean value that specifies if the operation should also apply to the files and subdirectories of the directory specified.

cancellationToken
CancellationToken

Optional CancellationToken to propagate notifications that the operation should be cancelled.

Returns

A AsyncPageable<T> describing the handles on the directory.

Remarks

A RequestFailedException will be thrown if a failure occurs. If multiple failures occur, an AggregateException will be thrown, containing each failure instance.

Applies to