INTRODUCTION
.NET attributes (both standard and custom). To illustrate the usefulness of each of these topics, the
chapter shows you how to construct an extendable Windows Forms application.
Chapter 16: Dynamic Types and the Dynamic Language Runtime
.NET 4.0 introduces a new aspect of the .NET runtime environment called the dynamic language
runtime. Using the DLR and the C# 2010 dynamic keyword, you can define data that is not truly resolved
until runtime. Using these features simplifies some very complex .NET programming tasks dramatically.
In this chapter, you will learn some practical uses of dynamic data, including how to leverage the .NET
reflection APIs in a streamlined manner, as well as how to communicate with legacy COM libraries with
a minimum of fuss and bother.
Chapter 17: Processes, AppDomains, and Object Contexts
Now that you have a solid understanding of assemblies, this chapter dives deeper into the composition
of a loaded .NET executable. The goal of this chapter is to illustrate the relationship between processes,
application domains, and contextual boundaries. These topics provide the proper foundation for
Chapter 19, where you will examine the construction of multithreaded applications.
Chapter 18: Understanding CIL and the Role of Dynamic Assemblies
The goal of the final chapter in this section is twofold. In the first half (more or less), you will examine the
syntax and semantics of CIL in much greater detail than in previous chapters. The remainder of this
chapter will cover the role of the System.Reflection.Emit namespace. You can use these types to build
software that can generate .NET assemblies in memory at runtime. Formally speaking, assemblies
defined and executed in memory are termed dynamic assemblies.
Part VI: Introducing the .NET Base Class Libraries
By this point in the text, you have a solid handle on the C# language and the details of the .NET assembly
format. Part 6 leverages your newfound knowledge by exploring a number of commonly used services
found within the base class libraries, including the creation of multithreaded applications, file I/O, and
database access using ADO.NET. This part also covers the construction of distributed applications using
Windows Communication Foundation (WCF), workflow-enabled applications that use the Windows
Workflow Foundation (WF) API, and the LINQ to XML API.
Chapter 19: Multithreaded, Parallel, and Async Programming
This chapter examines how to build multithreaded applications and illustrates a number of techniques
you can use to author thread-safe code. The chapter opens by revisiting the .NET delegate type to
ensure, explaining a delegate’s intrinsic support for asynchronous method invocations. Next, you will
investigate the types within the System.Threading namespace. The remainder of this chapter covers the
Task Parallel Library (TPL). Using the TPL, .NET developers can build applications that distribute their
workload across all available CPUs in a wickedly simple manner. At this point, you will also learn about
lxi