Compartilhar via


FileSystemOperationsExtensions.OpenAsync Método

Definição

Abre e lê do arquivo especificado.

public static System.Threading.Tasks.Task<System.IO.Stream> OpenAsync (this Microsoft.Azure.Management.DataLake.Store.IFileSystemOperations operations, string accountName, string directFilePath, long? length = default, long? offset = default, Guid? fileSessionId = default, System.Threading.CancellationToken cancellationToken = default);
public static System.Threading.Tasks.Task<System.IO.Stream> OpenAsync (this Microsoft.Azure.Management.DataLake.Store.IFileSystemOperations operations, string accountName, string path, long? length = default, long? offset = default, Guid? fileSessionId = default, System.Threading.CancellationToken cancellationToken = default);
static member OpenAsync : Microsoft.Azure.Management.DataLake.Store.IFileSystemOperations * string * string * Nullable<int64> * Nullable<int64> * Nullable<Guid> * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.IO.Stream>
static member OpenAsync : Microsoft.Azure.Management.DataLake.Store.IFileSystemOperations * string * string * Nullable<int64> * Nullable<int64> * Nullable<Guid> * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.IO.Stream>
<Extension()>
Public Function OpenAsync (operations As IFileSystemOperations, accountName As String, directFilePath As String, Optional length As Nullable(Of Long) = Nothing, Optional offset As Nullable(Of Long) = Nothing, Optional fileSessionId As Nullable(Of Guid) = Nothing, Optional cancellationToken As CancellationToken = Nothing) As Task(Of Stream)
<Extension()>
Public Function OpenAsync (operations As IFileSystemOperations, accountName As String, path As String, Optional length As Nullable(Of Long) = Nothing, Optional offset As Nullable(Of Long) = Nothing, Optional fileSessionId As Nullable(Of Guid) = Nothing, Optional cancellationToken As CancellationToken = Nothing) As Task(Of Stream)

Parâmetros

operations
IFileSystemOperations

O grupo de operações para esse método de extensão.

accountName
String

A conta do Azure Data Lake Store na qual executar operações do sistema de arquivos.

directFilePathpath
String

O caminho do Data Lake Store (começando com '/') do arquivo a ser aberto.

length
Nullable<Int64>

O número de bytes que o servidor tentará recuperar. Ele recuperará <= bytes de comprimento.

offset
Nullable<Int64>

O deslocamento de bytes do qual começar a ler dados.

fileSessionId
Nullable<Guid>

GUID exclusivo opcional por arquivo que indica que todas as leituras com o mesmo fileSessionId são do mesmo cliente e da mesma sessão. Isso dará um benefício de desempenho.

cancellationToken
CancellationToken

O token de cancelamento.

Retornos

Aplica-se a