Wednesday, April 11, 2012

Elements of the .NET Framework


The .NET Framework consists of three key elements

1 Common Language Runtime
2 .NET Class Library
3 Unifying components








Common Language Runtime
The Common Language Runtime (CLR) is a layer between an application and the
operating system it executes on. The CLR simplifies an application's design and reduces
the amount of code developers need to write because it provides a variety of execution
services that include memory management, thread management, component lifetime
management, and default error handling. The key benefit of the CLR is that it
transparently provides these execution services to all applications, regardless of what
programming language they're written in and without any additional effort on the part of
the developer.
The CLR is also responsible for compiling code just before it executes. Instead of
producing a binary representation of your code, as traditional compilers do, .NET
compilers produce a representation of your code in a language common to the .NET
Framework: Microsoft Intermediate Language (MSIL), often referred to as IL. When your
code executes for the first time, the CLR invokes a special compiler called a Just In Time
(JIT) compiler, which transforms the IL into executable instructions that are specific to
the type and model of your system's processor. Because all .NET languages have the
same compiled representation, they all have similar performance characteristics. This
means that a program written in Visual Basic .NET can perform as well as the same
program written in Visual C++ .NET. (C++ is the language of choice for developers who
need the best possible performance a system can deliver.)

Common Type System

The Common Type System (CTS) is a component of the CLR and provides a common
set of data types, each having a common set of behaviors. In Visual Basic, for example,
the String data type maps to the CTS System.String class. Therefore, if a JScript
.NET client needs to communicate with a component implemented in VB .NET, the client
doesn't have to do any additional work to exchange information because it's using a type
common to both JScript .NET and VB .NET. The CTS eliminates many interoperability
problems that exist outside .NET.
.NET programming languages take advantage of the CTS by enabling developers to use
their language's built-in data types — the .NET compilers convert the native data types'
into their equivalent CTS types at compile time. Developers can also use CTS types
directly in their code if they wish. Table 1-2 describes each standard CTS data type.


You can use other non-CTS-compliant data types in your applications and components;
you're free to use non-CTS-compliant data types, but they may not be available on other
implementations of the .NET Framework for other operating systems (see Table 1-3).



.NET Class Library

In an earlier section, "Consistent programming models across programming languages,"
the .NET Class Library was described as containing hundreds of classes that model the
system and services it provides. To make the .NET Class Library easier to work with and
understand, it's divided into namespaces. The root namespace of the .NET Class Library
is called System, and it contains core classes and data types, such as Int32, Object,
Array, and Console. Secondary namespaces reside within the System namespace.
Examples of nested namespaces include the following:
§ System.Diagnostics: Contains classes for working with the Event Log
§ System.Data: Makes it easy to work with data from multiple data
sources (System.Data.OleDb resides within this namespace and
contains the ADO.NET classes)
§ System.IO: Contains classes for working with files and data streams
Figure 1-2 illustrates the relationship between some of the major namespaces in the
.NET Class Library.


The benefits of using the .NET Class Library include a consistent set of services
available to all .NET languages and simplified deployment, because the .NET Class
Library is available on all implementations of the .NET Framework.

Unifying components
Until this point, this chapter has covered the low-level components of the .NET
Framework. The unifying components, listed next, are the means by which you can
access the services the .NET Framework provides:

§ ASP.NET
§ Windows Forms
§ Visual Studio .NET

ASP.NET

ASP.NET introduces two major features: Web Forms and Web Services.

Web Forms
Developers not familiar with Web development can spend a great deal of time, for
example, figuring out how to validate the e-mail address on a form. You can validate the
information on a form by using a client-side script or a server-side script. Deciding which
kind of script to use is complicated by the fact that each approach has its benefits and
drawbacks, some of which aren't apparent unless you've done substantial design work.
If you validate the form on the client by using client-side JScript code, you need to take
into consideration the browser that your users may use to access the form. Not all
browsers expose exactly the same representation of the document to programmatic
interfaces. If you validate the form on the server, you need to be aware of the load that
users might place on the server. The server has to validate the data and send the result
back to the client. Web Forms simplify Web development to the point that it becomes as
easy as dragging and dropping controls onto a designer (the surface that you use to edit
a page) to design interactive Web applications that span from client to server.

Web Services

A Web service is an application that exposes a programmatic interface through standard
access methods. Web Services are designed to be used by other applications and
components and are not intended to be useful directly to human end users. Web
Services make it easy to build applications that integrate features from remote sources.
For example, you can write a Web Service that provides weather information for
subscribers of your service instead of having subscribers link to a page or parse through
a file they download from your site. Clients can simply call a method on your Web
Service as if they are calling a method on a component installed on their system — and
have the weather information available in an easy-to-use format that they can integrate
into their own applications or Web sites with no trouble.


Windows Forms

Windows Forms is the name of a unified set of classes that provides support for creating
traditional desktop applications — applications that have a graphical user interface
(GUI). Windows Forms make it easy to develop end-user applications using any .NET
programming language. Furthermore, through Visual Studio .NET, developers can easily
design forms by using drag-and-drop editing.

Visual Studio .NET

Visual Studio .NET fulfills the promise of a single development environment for all
languages. Visual Studio .NET simplifies development in a mixed-language environment
through features such as support for end-to-end debugging across all programming
languages; visual designers for XML, HTML, data, and server-side code; and full
IntelliSense support (statement completion). Visual Studio .NET replaces the Visual
Basic 6, Visual C++, and Visual InterDev development environments.
Visual Studio .NET is able to provide this level of integration because it relies and builds
on the facilities of the .NET Framework. Designers for Web forms and Windows Forms
enhance developer productivity during the development cycle. Integration of deployment
features enhances productivity during post-deployment debugging. Table 1-4
summarizes Visual Studio .NET's major features.





If you are searching life partner. your searching end with kpmarriage.com. now kpmarriage.com offer free matrimonial website which offer free message, free chat, free view contact information. so register here : kpmarriage.com- Free matrimonial website