IVsAsyncEnum Interface

Implemented by enumerators supporting asynchronous behavior.

Namespace:  Microsoft.VisualStudio.Shell.Interop
Assembly:  Microsoft.VisualStudio.Shell.Interop (in Microsoft.VisualStudio.Shell.Interop.dll)

Syntax

‘선언
<InterfaceTypeAttribute()> _
<GuidAttribute("C734671A-9BB0-45C5-A08E-B9AB73CF5F47")> _
Public Interface IVsAsyncEnum
‘사용 방법
Dim instance As IVsAsyncEnum
[InterfaceTypeAttribute()]
[GuidAttribute("C734671A-9BB0-45C5-A08E-B9AB73CF5F47")]
public interface IVsAsyncEnum
[InterfaceTypeAttribute()]
[GuidAttribute(L"C734671A-9BB0-45C5-A08E-B9AB73CF5F47")]
public interface class IVsAsyncEnum
[<InterfaceTypeAttribute()>]
[<GuidAttribute("C734671A-9BB0-45C5-A08E-B9AB73CF5F47")>]
type IVsAsyncEnum =  interface end
public interface IVsAsyncEnum

Remarks

You should query for the interface and advise any callback interfaces before calling the Next method. Synchronous enumerators can support IVsAsyncEnum, and the same requirements apply (the callback interfaces are added prior to normal direct manipulation of the enumerator via its primary interface). However, the entire count of elements available is passed as cElementsAvailable to OnDataAvailable, and fIsComplete is set to true.

Stopping an asynchronous enumerator is itself an asynchronous operation. When the enumerator is stopped, an OnDataAvailable event is fired, with cElementsAvailable set to zero, and fIsComplete set to true. Passing true to the Stop call causes the thread to block until the enumerator has fired its final OnDataAvailable event.

See Also

Reference

IVsAsyncEnum Members

Microsoft.VisualStudio.Shell.Interop Namespace