Chapter 1

.NET Architecture

WHAT’S IN THIS CHAPTER?

  • Compiling and running code that targets .NET
  • Advantages of Microsoft Intermediate Language (MSIL)
  • Value and reference types
  • Data typing
  • Understanding error handling and attributes
  • Assemblies, .NET base classes, and namespaces

WROX.COM CODE DOWNLOADS FOR THIS CHAPTER

There are no code downloads for this chapter.

THE RELATIONSHIP OF C# TO .NET

This book emphasizes that the C# language must be considered in parallel with the .NET Framework, rather than viewed in isolation. The C# compiler specifically targets .NET, which means that all code written in C# always runs within the .NET Framework. This has two important consequences for the C# language:

1. The architecture and methodologies of C# reflect the underlying methodologies of .NET.
2. In many cases, specific language features of C# actually depend on features of .NET or of the .NET base classes.

Because of this dependence, you must gain some understanding of the architecture and methodology of .NET before you begin C# programming, which is the purpose of this chapter.

C# is a programming language newly designed for .NET. and is significant in two respects:

  • It is specifically designed and targeted for use with Microsoft’s .NET Framework (a feature-rich platform for the development, deployment, and execution of distributed applications).
  • It is a language based on the modern object-oriented design methodology, and when designing it Microsoft learned from the experience of ...

Get Professional C# 2012 and .NET 4.5 now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.