From 0b4fce5cf82bc742cc5cf7a799ca6a5d6b0025eb Mon Sep 17 00:00:00 2001 From: Benjamin Michaelis Date: Tue, 2 Apr 2024 20:11:27 -0700 Subject: [PATCH] Update Errata and fixes word overflow --- Errata.md | 3 ++- ...ting18.30.RuntimeBindingToXMLElementsWithoutDynamic.cs | 5 +++-- .../Listing18.31.RuntimeBindingToXMLWithDynamics.cs | 8 ++++---- 3 files changed, 9 insertions(+), 7 deletions(-) diff --git a/Errata.md b/Errata.md index 02854f659..1838f2501 100644 --- a/Errata.md +++ b/Errata.md @@ -32,4 +32,5 @@ Zhou Jing | 21 | 1022 | Change "3.1415926535897932384626433832795028841971693993 Zhou Jing | 20 | 1018 | Change paragraph beginning with "The need to support TAP from the UI is one of the key scenarios that led to TAP’s creation." to "Supporting TAP from the UI is a fundamental scenario that led to the development of TAP. Another common scenario occurs on the server side when a client’s request involves retrieving a large dataset from a database. Given that database queries can be time-consuming, it’s crucial to hangle them efficiently. Instead of creating new threads or using threads from the limited thread pool, it’s advisable to utilize asynchronous programming patterns. These patterns avoid blocking threads while waiting for the database response, especially since the actual query operations are executed on a separate machine (the database server). This approach ensures that server resources are used optimally, allowing threads to manage other tasks rather than being idle during I/O operations." Zhou Jing | 18 | 911 | Change CommandLineRequiredAttribute to CommandLineSwitchRequiredAttribute Zhou Jing | 18 | 902-903 | Change CommandLineAliasAttribute to CommandLineSwitchAliasAttribute -Zhou Jing | 23 | 1105 | Change `Length = 10` in listing 23.20 to `Length = 12` to show entire output message \ No newline at end of file +Zhou Jing | 23 | 1105 | Change `Length = 10` in listing 23.20 to `Length = 12` to show entire output message +Zhou Jing | 18 | 926-927 | Change 'LastName' references to be 'FirstName' in paragraphs \ No newline at end of file diff --git a/src/Chapter18/Listing18.30.RuntimeBindingToXMLElementsWithoutDynamic.cs b/src/Chapter18/Listing18.30.RuntimeBindingToXMLElementsWithoutDynamic.cs index b5f545113..b9343b9a7 100644 --- a/src/Chapter18/Listing18.30.RuntimeBindingToXMLElementsWithoutDynamic.cs +++ b/src/Chapter18/Listing18.30.RuntimeBindingToXMLElementsWithoutDynamic.cs @@ -15,8 +15,9 @@ public static void Main() Montoya "); - Console.WriteLine($"{ person.Descendants("FirstName").First().Value }" + - $"{ person.Descendants("LastName").First().Value }"); + Console.WriteLine( + $"{person.Descendants("FirstName").First().Value}" + + $"{person.Descendants("LastName").First().Value}"); //... #endregion INCLUDE } diff --git a/src/Chapter18/Listing18.31.RuntimeBindingToXMLWithDynamics.cs b/src/Chapter18/Listing18.31.RuntimeBindingToXMLWithDynamics.cs index 8feda5ce1..70f7e336e 100644 --- a/src/Chapter18/Listing18.31.RuntimeBindingToXMLWithDynamics.cs +++ b/src/Chapter18/Listing18.31.RuntimeBindingToXMLWithDynamics.cs @@ -8,12 +8,12 @@ public static void Main() #region INCLUDE dynamic person = DynamicXml.Parse( @" - Inigo - Montoya - "); + Inigo + Montoya + "); Console.WriteLine( - $"{ person.FirstName } { person.LastName }"); + $"{person.FirstName} {person.LastName}"); //... #endregion INCLUDE }