다음을 통해 공유


VsTaskLibraryHelper.AsVsTask<T>(JoinableTask<T>) Method

Definition

Wraps a JoinableTask<T> instance in an IVsTask that can be returned to COM clients.

public:
generic <typename T>
[System::Runtime::CompilerServices::Extension]
 static Microsoft::VisualStudio::Shell::Interop::IVsTask ^ AsVsTask(Microsoft::VisualStudio::Threading::JoinableTask<T> ^ joinableTask);
public static Microsoft.VisualStudio.Shell.Interop.IVsTask AsVsTask<T> (this Microsoft.VisualStudio.Threading.JoinableTask<T> joinableTask);
static member AsVsTask : Microsoft.VisualStudio.Threading.JoinableTask<'T> -> Microsoft.VisualStudio.Shell.Interop.IVsTask
<Extension()>
Public Function AsVsTask(Of T) (joinableTask As JoinableTask(Of T)) As IVsTask

Type Parameters

T

The type of value returned by the asynchronous operation.

Parameters

joinableTask
JoinableTask<T>

The task to wrap.

Returns

An IVsTask instance.

Applies to