DoWorkWithoutAwait() public method

public DoWorkWithoutAwait ( ) : Task
return Task
コード例 #1
0
ファイル: Program.cs プロジェクト: negativeeddy/blog-examples
 /// <summary>
 /// Runs all 3 variations of the MoreRealistic code to ensure
 /// they all have the same result
 /// </summary>
 /// <returns></returns>
 static async Task MoreRealisticMainAsync()
 {
     var worker = new MoreRealisticAsyncWorker();
     await worker.DoWork();
     await worker.DoWorkExplicitTasks();
     await worker.DoWorkWithoutAwait();
 }
コード例 #2
0
ファイル: Program.cs プロジェクト: zyonet/blog-examples
        /// <summary>
        /// Runs all 3 variations of the MoreRealistic code to ensure
        /// they all have the same result
        /// </summary>
        /// <returns></returns>
        static async Task MoreRealisticMainAsync()
        {
            var worker = new MoreRealisticAsyncWorker();
            await worker.DoWork();

            await worker.DoWorkExplicitTasks();

            await worker.DoWorkWithoutAwait();
        }