Skip to content

Commit f337cf3

Browse files
fix: Minor updates
1 parent 99d6952 commit f337cf3

6 files changed

+2
-30
lines changed

src/Chapter20/Listing20.02.AsynchronousWebRequest.cs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ namespace AddisonWesley.Michaelis.EssentialCSharp.Chapter20.Listing20_02;
33
#region INCLUDE
44
using System;
55
using System.IO;
6-
using System.Net;
76
using System.Runtime.ExceptionServices;
87
using System.Threading.Tasks;
98

@@ -48,7 +47,6 @@ public static void Main(string[] args)
4847
textOccurrenceCount} times at URL '{url}'.");
4948

5049
});
51-
5250
try
5351
{
5452
while (!task.Wait(100))

src/Chapter20/Listing20.14.SynchronousHighLatencyInvocationInWPF.cs

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,3 @@ private void PingButton_Click(
1616
#endregion INCLUDE
1717
}
1818
}
19-
20-
21-
22-
23-

src/Chapter20/Listing20.15.SynchronousHighLatencyInvocationInWPFUsingAwait.cs

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -18,11 +18,5 @@ private async void PingButton_Click(
1818
StatusLabel.Text = pingReply.Status.ToString();
1919
}
2020
#endregion INCLUDE
21-
2221
}
2322
}
24-
25-
26-
27-
28-

src/Chapter21/Listing21.01.SynchronousPiSections.cs

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ public static void Main()
1313
{
1414
string pi = "";
1515
const int iterations = TotalDigits / BatchSize;
16-
for(int i = 0; i < iterations; i++)
16+
for (int i = 0; i < iterations; i++)
1717
{
1818
pi += PiCalculator.Calculate(
1919
BatchSize, i * BatchSize);
@@ -41,8 +41,3 @@ public static string Calculate(
4141
*/
4242
#endregion EXCLUDE
4343
#endregion INCLUDE
44-
45-
46-
47-
48-

src/Chapter21/Listing21.02.ParallelPiCalculation.cs

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,3 @@ public static void Main()
3232
}
3333
}
3434
#endregion INCLUDE
35-
36-
37-
38-
39-

src/Chapter21/Listing21.04.UnhandledExceptionsParallelIterations.cs

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ static void EncryptFiles(
3636
Console.WriteLine(
3737
"ERROR: {0}:",
3838
exception.GetType().Name);
39-
foreach(Exception item in
39+
foreach (Exception item in
4040
#region HIGHLIGHT
4141
exception.InnerExceptions)
4242
#endregion HIGHLIGHT
@@ -56,8 +56,3 @@ private static void Encrypt(string fileName)
5656
#endregion EXCLUDE
5757
}
5858
#endregion INCLUDE
59-
60-
61-
62-
63-

0 commit comments

Comments
 (0)