WorkspaceHelper.GetFirstFileContextsAsync<T>(IWorkspace, String, T, IEnumerable<Guid>, CancellationToken) Methode
Definition
Wichtig
Einige Informationen beziehen sich auf Vorabversionen, die vor dem Release ggf. grundlegend überarbeitet werden. Microsoft übernimmt hinsichtlich der hier bereitgestellten Informationen keine Gewährleistungen, seien sie ausdrücklich oder konkludent.
Ersten verfügbaren Kontext für einen Arbeitsbereichs Kontext
public static System.Threading.Tasks.Task<Microsoft.VisualStudio.Workspace.FileContext> GetFirstFileContextsAsync<T> (this Microsoft.VisualStudio.Workspace.IWorkspace workspace, string filePath, T context, System.Collections.Generic.IEnumerable<Guid> fileContextTypes, System.Threading.CancellationToken cancellationToken = default);
static member GetFirstFileContextsAsync : Microsoft.VisualStudio.Workspace.IWorkspace * string * 'T * seq<Guid> * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.VisualStudio.Workspace.FileContext>
<Extension()>
Public Function GetFirstFileContextsAsync(Of T) (workspace As IWorkspace, filePath As String, context As T, fileContextTypes As IEnumerable(Of Guid), Optional cancellationToken As CancellationToken = Nothing) As Task(Of FileContext)
Typparameter
- T
Typ des Arbeitsbereichs Kontexts
Parameter
- workspace
- IWorkspace
Die Arbeitsbereichs Instanz
- filePath
- String
Der Pfad der Arbeitsbereichs Datei
- context
- T
Die Instanz des Arbeitsbereichs Kontexts.
- fileContextTypes
- IEnumerable<Guid>
Optionale Liste der Datei Kontext Typen
- cancellationToken
- CancellationToken
Ein Abbruchtoken.
Gibt zurück
Der erste verfügbare Datei Kontext