Table of Contents

Method RunSync

Namespace
Innova.Data.Extensions
Assembly
Innova.Data.dll

RunSync<TResult>(Func<Task<TResult>>)

Runs an asynchronous task synchronously and returns the result.

public static TResult RunSync<TResult>(Func<Task<TResult>> func)

Parameters

func Func<Task<TResult>>

The asynchronous task to run.

Returns

TResult

The result of the asynchronous task.

Type Parameters

TResult

The type of the result.

RunSync(Func<Task>)

Runs an asynchronous task synchronously.

public static void RunSync(Func<Task> func)

Parameters

func Func<Task>

The asynchronous task to run.