TaskUtils OnOk T1  Method (Task, Func Task T1  , TaskContinuationOptions, TaskContinuationOptions)NFX Class Library

[This is preliminary documentation and is subject to change.]

Chains task 'first' with task returned by 'next' if first is completed, not cancelled and not faulted. Returns task that completes after task returned by 'next' completes with result from 'next' task

Namespace: NFX
Assembly: NFX (in NFX.dll) Version: 3.0.0.1 (3.0.0.1)
Syntax

public static Task<T1> OnOk<T1>(
	this Task first,
	Func<Task<T1>> next,
	TaskContinuationOptions firstOptions = TaskContinuationOptions.ExecuteSynchronously,
	TaskContinuationOptions nextOptions = TaskContinuationOptions.ExecuteSynchronously
)

Parameters

first
Type: OnlineSystem.Threading.Tasks Task
next
Type: OnlineSystem Func OnlineTask T1  
firstOptions (Optional)
Type: OnlineSystem.Threading.Tasks TaskContinuationOptions
nextOptions (Optional)
Type: OnlineSystem.Threading.Tasks TaskContinuationOptions
Type Parameters

T1

Return Value

Type: OnlineTask T1 

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type OnlineTask. When you use instance method syntax to call this method, omit the first parameter. For more information, see OnlineExtension Methods (Visual Basic) or OnlineExtension Methods (C# Programming Guide).
See Also