Share via


IOpenDocumentEnumeratorFactory2.GetEnumeratorFavoringOpenDocuments Method

Definition

Get an enumerator for all open documents.

public Microsoft.VisualStudio.Shell.Internal.FileEnumerationService.IFileEntityAsyncEnumerator GetEnumeratorFavoringOpenDocuments (Microsoft.VisualStudio.Shell.Internal.FileEnumerationService.IFileEntityAsyncEnumerator fileEntityEnumerator, Action<System.Collections.Generic.Dictionary<string,object>>? telemetryCallBack = default);
abstract member GetEnumeratorFavoringOpenDocuments : Microsoft.VisualStudio.Shell.Internal.FileEnumerationService.IFileEntityAsyncEnumerator * Action<System.Collections.Generic.Dictionary<string, obj>> -> Microsoft.VisualStudio.Shell.Internal.FileEnumerationService.IFileEntityAsyncEnumerator
Public Function GetEnumeratorFavoringOpenDocuments (fileEntityEnumerator As IFileEntityAsyncEnumerator, Optional telemetryCallBack As Action(Of Dictionary(Of String, Object)) = Nothing) As IFileEntityAsyncEnumerator

Parameters

fileEntityEnumerator
IFileEntityAsyncEnumerator

Defines an enumerator where opened document must be merged to.

telemetryCallBack
Action<Dictionary<String,Object>>

(optional) An optional method called when the result is completed. Its arguments provide health and performance telemetry.

Returns

Returns an enumerator to get the next discovered file asynchronously.

Remarks

This enumerates everything in fileEntityEnumerator but return all the open documents first, when they are part of the given fileEntityEnumerator.

The current document, if there is one and it is eligible, will always be first.

Applies to