AsyncLazy<T>.GetValueAsync Method

Gets the task that produces or has produced the value.

Namespace:  Microsoft.VisualStudio.Threading
Assembly:  Microsoft.VisualStudio.Threading (in Microsoft.VisualStudio.Threading.dll)

Syntax

'Declaration
Public Function GetValueAsync As Task(Of T)
public Task<T> GetValueAsync()
public:
Task<T>^ GetValueAsync()
member GetValueAsync : unit -> Task<'T> 
public function GetValueAsync() : Task<T>

Return Value

Type: System.Threading.Tasks.Task<T>
Returns a task whose result is the lazily constructed value.

Exceptions

Exception Condition
InvalidOperationException

Thrown when the value factory calls GetValueAsyncon this instance.

.NET Framework Security

See Also

Reference

AsyncLazy<T> Class

Microsoft.VisualStudio.Threading Namespace