About the Book

So what is C# 4.0 in a Nutshell?

C# 4.0 in a Nutshell is an updated version of the acclaimed C# 3.0 in a Nutshell, covering the C# 4.0 language and CLR features including features, parallel programming, code contracts and dynamic programming. C# 4.0 in a Nutshell is the product of immense production effort - including 7 technical reviewers from Microsoft plus Jon Skeet and Nicholas Paldino.

Where can I get this book?

You can get them online from amazon.com, or your local bookstore.

I own another "in a Nutshell" book and it features a large reference section with alphabetical listings of types and members. Is C# 4.0 in a Nutshell the same?

No: there are no computer-generated listings and no divorced reference section. We believe in explaining everything clearly and concisely based on our experience, with plenty of examples and real-world scenarios. We maintain strict vigilance in keeping our examples short and clutter-free and follow a policy of being useful and getting straight to the point.

Can I see the table of contents and a sample chapter?

Click here for a Table of Contents. Use the 'Look Inside' feature on the amazon.com listing  for the index.

For a sample chapter, read Threading in C#. The threading and parallel programming chapters in the book are a revision of this article.

Aside from threading, what sections of the .NET Framework does this book cover?

We cover the topics shown in the circles below:

overview

I already own book XYZ and am unhappy with its level of detail. Does this book do better?

Most likely, yes! The reason, in a word, is focus. We dedicate the entire book to what's inside the circles shown above. This gives us space to do justice to difficult topics such as security, application domains, Reflection.Emit, threading—and of course, LINQ. Books covering everything in the diagram cannot offer the same level of depth—this is why you might be frustrated. There's nothing wrong with one-stop-shop books; it's just that they serve a different purpose.

Our focus in C# 4.0 in a Nutshell means we can answer such questions as:

What is LINQ, and why is it important?

LINQ or Language INtegrated Query is a set of language and framework features that allow you to write queries directly in C# 3.0 and 4.0. LINQ drastically cuts the plumbing code required for database applications while reducing runtime errors (LINQ queries are statically type-checked by the compiler). LINQ can also query local in-memory collections and XML trees, and (in Framework 4.0) LINQ greatly simplifies parellel programming.

LINQ to SQL halves the cost of writing and maintaining a data access layer. LINQ also provides a single unified query syntax that works across databases, local collections, XML documents, ADO.NET data services, as well as third-party products.

C# 4.0 in a Nutshell features three chapters on LINQ. We tell you what you need to know to write real-world queries over databases, local collections and XML, and covering all the query operators in detail.

Are these books for beginners?

We've taken care not to alienate readers by presuming too much prior knowledge. Nonetheless, these books assume some general background in programming and so are aimed at intermediate and advanced audiences. As a beginner you'll certainly benefit—but not as your sole book. For something more introductory, I'd recommend a title such as Head First C#, by Andrew Stellman and Jennifer Greene, or Learning C# by Jesse Liberty.

What are your credentials?

I have 17 years' experience in software development, and have been working as a senior architect and developer on a wide range of commercial projects in C# since its inception. I am also the author of LINQPad. Ben has worked for five years at Microsoft as a program manager on three .NET teams, including ADO.NET and the .NET Compact Framework.

The two of you have the same unusual surname... are you related?

We're brothers.

How can I contact you?

Click here.

 

© 2007-2010, Joe Albahari, Ben Albahari and O'Reilly Media, Inc. All rights reserved

C# 4.0 in a Nutshell
Buy from amazon.com Available now