Partilhar via


TextLoader.LoadTextAndVersionAsync Método

Definição

Sobrecargas

LoadTextAndVersionAsync(LoadTextOptions, CancellationToken)

Carregue um texto e uma versão do documento.

LoadTextAndVersionAsync(Workspace, DocumentId, CancellationToken)
Obsoleto.

Carregue um texto e uma versão do documento.

LoadTextAndVersionAsync(LoadTextOptions, CancellationToken)

Source:
TextLoader.cs
Source:
TextLoader.cs
Source:
TextLoader.cs
Source:
TextLoader.cs
Source:
TextLoader.cs

Carregue um texto e uma versão do documento.

public virtual System.Threading.Tasks.Task<Microsoft.CodeAnalysis.TextAndVersion> LoadTextAndVersionAsync (Microsoft.CodeAnalysis.LoadTextOptions options, System.Threading.CancellationToken cancellationToken);
abstract member LoadTextAndVersionAsync : Microsoft.CodeAnalysis.LoadTextOptions * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.CodeAnalysis.TextAndVersion>
override this.LoadTextAndVersionAsync : Microsoft.CodeAnalysis.LoadTextOptions * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.CodeAnalysis.TextAndVersion>
Public Overridable Function LoadTextAndVersionAsync (options As LoadTextOptions, cancellationToken As CancellationToken) As Task(Of TextAndVersion)

Parâmetros

options
LoadTextOptions

As implementações desse método devem ser usadas ChecksumAlgorithm ao criar SourceText a partir de uma representação binária original e ignorá-la caso contrário. Os chamadores desse método devem passar LoadTextOptions especificando as propriedades desejadas de SourceText. A implementação pode retornar um SourceText que não atende aos requisitos especificados. Por exemplo, tipos herdados que não substituem esse método ignorariam todos os options.

cancellationToken
CancellationToken

Token de cancelamento.

Retornos

Exceções

Aplica-se a

LoadTextAndVersionAsync(Workspace, DocumentId, CancellationToken)

Source:
TextLoader.cs
Source:
TextLoader.cs
Source:
TextLoader.cs
Source:
TextLoader.cs
Source:
TextLoader.cs
Source:
TextLoader.cs
Source:
TextLoader.cs
Source:
TextLoader.cs
Source:
TextLoader.cs
Source:
TextLoader.cs
Source:
TextLoader.cs
Source:
TextLoader.cs
Source:
TextLoader.cs
Source:
TextLoader.cs
Source:
TextLoader.cs
Source:
TextLoader.cs
Source:
TextLoader.cs
Source:
TextLoader.cs
Source:
TextLoader.cs
Source:
TextLoader.cs
Source:
TextLoader.cs
Source:
TextLoader.cs
Source:
TextLoader.cs

Cuidado

Use/override LoadTextAndVersionAsync(LoadTextOptions, CancellationToken)

Carregue um texto e uma versão do documento.

public:
 abstract System::Threading::Tasks::Task<Microsoft::CodeAnalysis::TextAndVersion ^> ^ LoadTextAndVersionAsync(Microsoft::CodeAnalysis::Workspace ^ workspace, Microsoft::CodeAnalysis::DocumentId ^ documentId, System::Threading::CancellationToken cancellationToken);
public abstract System.Threading.Tasks.Task<Microsoft.CodeAnalysis.TextAndVersion> LoadTextAndVersionAsync (Microsoft.CodeAnalysis.Workspace workspace, Microsoft.CodeAnalysis.DocumentId documentId, System.Threading.CancellationToken cancellationToken);
[System.Obsolete("Use/override LoadTextAndVersionAsync(LoadTextOptions, CancellationToken)")]
public virtual System.Threading.Tasks.Task<Microsoft.CodeAnalysis.TextAndVersion> LoadTextAndVersionAsync (Microsoft.CodeAnalysis.Workspace? workspace, Microsoft.CodeAnalysis.DocumentId? documentId, System.Threading.CancellationToken cancellationToken);
abstract member LoadTextAndVersionAsync : Microsoft.CodeAnalysis.Workspace * Microsoft.CodeAnalysis.DocumentId * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.CodeAnalysis.TextAndVersion>
[<System.Obsolete("Use/override LoadTextAndVersionAsync(LoadTextOptions, CancellationToken)")>]
abstract member LoadTextAndVersionAsync : Microsoft.CodeAnalysis.Workspace * Microsoft.CodeAnalysis.DocumentId * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.CodeAnalysis.TextAndVersion>
override this.LoadTextAndVersionAsync : Microsoft.CodeAnalysis.Workspace * Microsoft.CodeAnalysis.DocumentId * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.CodeAnalysis.TextAndVersion>
Public MustOverride Function LoadTextAndVersionAsync (workspace As Workspace, documentId As DocumentId, cancellationToken As CancellationToken) As Task(Of TextAndVersion)
Public Overridable Function LoadTextAndVersionAsync (workspace As Workspace, documentId As DocumentId, cancellationToken As CancellationToken) As Task(Of TextAndVersion)

Parâmetros

workspace
Workspace

Obsoleto. Nulo.

documentId
DocumentId

Obsoleto. Nulo.

cancellationToken
CancellationToken

Retornos

Atributos

Exceções

Aplica-se a