INTRODUCTION
distinction between application-level and system-level exceptions. In addition, this chapter will examine
various tools within Visual Studio that allow you to debug the exceptions that escape your notice.
Chapter 8: Working with Interfa ces
The material in this chapter builds upon your understanding of object-based development by covering
the topic of interface-based programming. Here, you will learn how to define classes and structures that
support multiple behaviors, how to discover these behaviors at runtime, and how to selectively hide
particular behaviors using explicit interface implementation. In addition to creating a number of custom
interfaces, you will also learn how to implement standard interfaces found within the .NET platform.
You will use these to build objects that can be sorted, copied, enumerated, and compared.
Part IV: Advanced C# Programming
This section of the book will deepen your understanding of the C# language by walking you through a
number of more advanced (but very important) concepts. Here, you will complete your examination of
the .NET type system by examining interfaces and delegates. You will also learn about the role of
generics, take a first look at Language Integrated Query (LINQ), and examine a number of more
advanced features of C# (e.g., extension methods, partial methods, and pointer manipulation).
Chapter 9: Collections and Generics
This chapter explores the topic of generics. As you will see, generic programming gives you a way to
create types and type members, which contain various placeholders that can be specified by the caller. In
a nutshell, generics greatly enhance application performance and type safety. Not only will you explore
various generic types within the System.Collections.Generic namespace, but you will also learn how to
build your own generic methods and types (with and without constraints).
Chapter 10: Delegates, Events, and Lambda Expressions
The purpose of Chapter 10 is to demystify the delegate type. Simply put, a .NET delegate is an object that
points to other methods in your application. Using this type, you can build systems that allow multiple
objects to engage in a two-way conversation. After you have examined the use of .NET delegates, you will
then be introduced to the C# event keyword, which you can use to simplify the manipulation of raw
delegate programming. You will wrap up this chapter by investigating the role of the C# lambda operator
(=>) and exploring the connection between delegates, anonymous methods, and lambda expressions.
Chapter 11: Advanced C# Language Features
This chapter deepens your understanding of the C# programming language by introducing you to a
number of advanced programming techniques. Here, you will learn how to overload operators and
create custom conversion routines (both implicit and explicit) for your types. You will also learn how to
build and interact with type indexers, as well as work with extension methods, anonymous types, partial
methods, and C# pointers using an unsafe code context.
lix