Saturday 24 May 2014

Understanding of .Net Framework

Microsoft .Net platform includes the following components that would help develop a new generation of smart Internet services:

  • .NET infrastructure and Tools
  • .NET user experience
  • .NET building block
  • .NET device software
Origin .NET:
Before going to discuss about .Net we should discuss about origin of .Net and its features. 
  • OLE technology
  • COM technology
  • .NET technology
OLE Technology:
OLE(Object Linking and Embedding) technology developed by Microsoft in the early of 90s to enable easy interprocess communications. OLE provided support to archieve the following

  • To embed documents from one application into another application
  • To enable one application to manipulate objects located in another application
This enabled users to develop applications which required inter-operatbility between various products such as MS Word and MS Excel

COM Technology:
At first of COM technology, the monolithic approach had been used for developing software. But when programs become too large and complex the monolithic approach leads to a number of problems in terms of maintainability and testing of software. To over come with the problem Microsoft come up with component based model for development software. In this approach software broken up in number of modules( independent components) where each one offers a particular service. Each component can tested and developed independently and then integrate with main system. This technique is called Component Object Model (COM)  and the software built using COM is referred to as componentware.
it provides great flexibility to developers:
  • reduce overall complexity of the software
  • enable distributed development across multiple organizations or departments
  • enhance software maintainability
.NET Technology:

.NET technology is a third generation component model. This provides a new level of inter-operability compared to COM technology. COM provides a standard binary mechanism for inter module communication. This mechanism is replaced by an intermediate language called Microsoft Intermediate Language (MSIL) or IL.  Various .NET compilers enforce inter operability by complying code  into IL, which automatically compatible with other IL modules. An inherent characteristic of IL code is metadata. Metadata is data about the data and describes its characteristic, including data types and locations. IL allows for true cross language integration. in addition to IL,.NET includes a host of other technologies and tools that will enable us develop and implement Web based applications easily.

THE .NET FRAMEWORK
In short .Net framework provides an environment for building, developing and running web services and other applications. It consists of three distinct technology:-

  1. Common Language Runtime (CLR)
  2. Framework Based Classes
  3. User interface program (Asp.net and Win forms) 
  CLR:
We can say CLR is heart and soul of the .Net framework. As the name its comes, CLR provides run time environment in which programe written in C# and other .Net languages are executed.  It also supports cross language interoperability.
CLR supports number of services as follows:

  1. Loading and execution of the program
  2. Memory isolation for application
  3. Verification of type safety
  4. Compilation of IL into native executable code
  5. Providing metadata
  6. Memory management (automatic garbage collection)
  7. Enforcement of security
  8. Managing errors and exceptions
  9. Support for tasks such as debugging and profiling
  10. Interoperability with other systems
Common Type System (CTS):
The .Net framework provides multiple language support using the features known as Common Type System that build into the CLR. The CTS supports a variety of types and operations found in most programming languages and therefore calling one language from another does not require type conversions. we can build .Net program in a number of other languages including C++ and Visual Baisc .

Common Language Specification (CLS):
The CLS specification defines a set of rules that enables interoperability on the .Net platform. These rules guide the third party compiler designers and library buuilders. The CLS is a subset of CTS and therefore the language supporting the CLS can use each others class libraries as if they are their own.

Microsoft Intermediate Language (MSIL):
MSIL simply called IL, is an instruction set into which all the .NET programs are compiled.  it is akin to assembly language and contains instructions for loading, storing, initializing and calling methods.  When we compile a C# program or any program written in a CLS compliant language, the code is compiled into MSIL.

Managed Code: 
CLR is responsible for managing the execution of code compiled for the .Net platform. The code that satisfies the CLR runtime in order to execute is referred to as managed code.  Compiler that are compatible to the .Net platform generate managed code. The managed code generated by C# is IL code. 


No comments:

Post a Comment

stats counter
your visitor number