Top Banner
.NET Technology .NET Technology
26

.NET Technology

Feb 03, 2016

Download

Documents

netis

.NET Technology. Visual Studio. It is the complete set of development tools for building ASP.NET Web applications, XML Web Services, desktop applications and mobile applications. Visual Basic, Visual C++, Visual C# and Visual J# all use the same integrated development environment(IDE). - PowerPoint PPT Presentation
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: .NET Technology

.NET Technology.NET Technology

Page 2: .NET Technology

Visual StudioVisual Studio It is the complete set of development It is the complete set of development

tools for building ASP.NET Web tools for building ASP.NET Web applications, XML Web Services, applications, XML Web Services, desktop applications and mobile desktop applications and mobile applications.applications.

Visual Basic, Visual C++, Visual C# and Visual Basic, Visual C++, Visual C# and Visual J# all use the same integrated Visual J# all use the same integrated development environment(IDE).development environment(IDE).

Page 3: .NET Technology

.NET Framework.NET Framework It is the a software component, which is It is the a software component, which is

added to Microsoft windows OS.added to Microsoft windows OS. It had two main component: It had two main component:

The ‘The ‘Common Language Runtime(CLR)’Common Language Runtime(CLR)’ The ‘The ‘Base Class Library(BCL)’Base Class Library(BCL)’

Common Language Runtime:-Common Language Runtime:- It is the foundation of .Net Framework, It is the agent It is the foundation of .Net Framework, It is the agent

that manage the code at execution time.that manage the code at execution time. It provide core services as memory management, It provide core services as memory management,

remoting etc.remoting etc. Code that targets the runtime is known as ‘managed Code that targets the runtime is known as ‘managed

code’.code’. Others known as ‘unmanaged code’.Others known as ‘unmanaged code’.

Page 4: .NET Technology

Base Class Library(BCL)Base Class Library(BCL) It is a comprehensive, object-oriented collection of It is a comprehensive, object-oriented collection of

reusable types(classes) that you can use to develop reusable types(classes) that you can use to develop applications ranging from traditional command-line or applications ranging from traditional command-line or graphical user interface(GUI) application.graphical user interface(GUI) application.

The function of the class library are used by The function of the class library are used by programmers who combine them with their own code programmers who combine them with their own code to produce applications.to produce applications.

Two time compilationTwo time compilation First the source code is compiled using an First the source code is compiled using an

appropriate compiler which generates an appropriate compiler which generates an intermediate code called ‘Microsoft Intermediate intermediate code called ‘Microsoft Intermediate Language(MSIL)’ code.Language(MSIL)’ code.

Second before running the application this MSIL code Second before running the application this MSIL code is compiled to the appropriate native code for the OS is compiled to the appropriate native code for the OS using an appropriate compiler called ‘Just In Time(JIT) using an appropriate compiler called ‘Just In Time(JIT) ‘ compiler, inside the CLR.‘ compiler, inside the CLR.

Page 5: .NET Technology

Principal design featuresPrincipal design features

Interoperability:-Interoperability:- Because interaction between new and older Because interaction between new and older

applications is commonly required, the .NET applications is commonly required, the .NET Framework provides means to access Framework provides means to access functionality that is implemented in functionality that is implemented in programs that execute outside the .NET programs that execute outside the .NET environmentenvironment

Page 6: .NET Technology

Principal design featuresPrincipal design features Common Runtime Engine :-Common Runtime Engine :-

The Common Language Runtime (CLR) is the The Common Language Runtime (CLR) is the virtual machine component of the .NET virtual machine component of the .NET framework.framework.

All .NET programs execute under the All .NET programs execute under the supervision of the CLR, supervision of the CLR,

Main functions in the areas of memory Main functions in the areas of memory management, security, and exception management, security, and exception handling. handling.

Page 7: .NET Technology

Principal design featuresPrincipal design features Language Independence:-Language Independence:-

The .NET Framework introduces a Common The .NET Framework introduces a Common Type System, or CTS. Type System, or CTS.

Because of this feature, the .NET Framework Because of this feature, the .NET Framework supports the exchange of instances of types supports the exchange of instances of types between programs written in any of the .NET between programs written in any of the .NET languageslanguages

Page 8: .NET Technology

Principal design featuresPrincipal design features Base Class Library :-Base Class Library :-

The Base Class Library (BCL), part of the The Base Class Library (BCL), part of the Framework Class Library (FCL), is a library of Framework Class Library (FCL), is a library of functionality available to all languages using functionality available to all languages using the .NET Framework. the .NET Framework.

The BCL provides classes which encapsulate The BCL provides classes which encapsulate a number of common functions, including a number of common functions, including file reading and writing,graphical rendaring, file reading and writing,graphical rendaring, database interaction and XML document database interaction and XML document manipulation. manipulation.

Page 9: .NET Technology

Principal design featuresPrincipal design features Simplified Deployment :-Simplified Deployment :-

The .NET framework includes design The .NET framework includes design features and tools that help manage the features and tools that help manage the installation of computer software to ensure installation of computer software to ensure that it does not interfere with previously that it does not interfere with previously installed software, and that it conforms to installed software, and that it conforms to security requirements. security requirements.    

Page 10: .NET Technology

Principal design featuresPrincipal design features Security:-Security:-

The design is meant to address some of the The design is meant to address some of the vulnerabilities, such as buffer overflow, that vulnerabilities, such as buffer overflow, that have been exploited by malicious software.have been exploited by malicious software.

Additionally, .NET provides a common Additionally, .NET provides a common security model for all applications. security model for all applications.    

Page 11: .NET Technology

Principal design featuresPrincipal design features Portability:-Portability:-

It is cross-platform compatible. It is cross-platform compatible. Although Microsoft's implementation of the Although Microsoft's implementation of the

CLR and base class libraries are designed to CLR and base class libraries are designed to run only under Microsoft Windows, run only under Microsoft Windows,

A cross-platform implementation is available A cross-platform implementation is available by way of the by way of the Mono ProjectMono Project, which can be , which can be run on both Windows/PC and Unix/Linux run on both Windows/PC and Unix/Linux (however it is compatible only up to .NET (however it is compatible only up to .NET 2.0).   2.0).  

Page 12: .NET Technology

ArchitectureArchitecture

Page 13: .NET Technology

ArchitectureArchitecture

Common Language Infrastructure Common Language Infrastructure (CLI):-(CLI):-

Microsoft's implementation of the CLI is Microsoft's implementation of the CLI is called the common language runtime (CLR)called the common language runtime (CLR)

Assemblies:-Assemblies:- The CIL code is housed in .NET assemblies.The CIL code is housed in .NET assemblies. Assemblies are stored in the Assemblies are stored in the Portable Portable

ExecutableExecutable (PE) format, common on the (PE) format, common on the Windows platform for all DLL and EXE files. Windows platform for all DLL and EXE files.

Page 14: .NET Technology

ArchitectureArchitecture

Metadata:-Metadata:- All CIL is self-describing through .NET All CIL is self-describing through .NET

metadatametadata The CLR checks the metadata to ensure that The CLR checks the metadata to ensure that

the correct method is called. the correct method is called. Metadata is usually generated by language Metadata is usually generated by language

compilers but developers can create their compilers but developers can create their own metadata through custom attributes.own metadata through custom attributes.

Page 15: .NET Technology

ArchitectureArchitecture

Security:-Security:- NET has its own security mechanism with two general NET has its own security mechanism with two general

features: features: Code Access Security (CAS)Code Access Security (CAS), and , and validation and verificationvalidation and verification..

Code Access Security uses evidence to determine the Code Access Security uses evidence to determine the permissions granted to the code. permissions granted to the code.

When an assembly is loaded the CLR performs When an assembly is loaded the CLR performs various tests.various tests.

Two such tests are validation and verification.Two such tests are validation and verification. During validation the CLR checks that the assembly During validation the CLR checks that the assembly

contains valid metadata and CIL, and whether the contains valid metadata and CIL, and whether the internal tables are correct. internal tables are correct.

Page 16: .NET Technology

ArchitectureArchitecture

Class library:-Class library:- The .NET Framework includes a set of standard class The .NET Framework includes a set of standard class

libraries.libraries. The class library is organized in a hierarchy of The class library is organized in a hierarchy of

namespace.namespace. Most of the built in APIs are part of either System.* or Most of the built in APIs are part of either System.* or

Microsoft.* namespaces.Microsoft.* namespaces. These class libraries implement a large number of These class libraries implement a large number of

common functions, such as file reading and writing, common functions, such as file reading and writing, graphic rendering, database interaction, and XML graphic rendering, database interaction, and XML document manipulation, among others. document manipulation, among others.

The .NET class libraries are available to all .Net The .NET class libraries are available to all .Net languages languages

Page 17: .NET Technology

ArchitectureArchitecture

Memory management:-Memory management:- NET Framework includes a garbage collector NET Framework includes a garbage collector

which runs periodically, on a separate which runs periodically, on a separate thread from the application's thread, that thread from the application's thread, that enumerates all the unusable objects and enumerates all the unusable objects and reclaims the memory allocated to them. reclaims the memory allocated to them.

Page 18: .NET Technology

VersionsVersionsVersion Version Number Release Date Visual Studio Default in Windows

1.0 1.0.3705.0 2002-02-13 Visual Studio .NET

1.1 1.1.4322.573 2003-04-24 Visual Studio .NET 2003 Windows Server 2003

2.0 2.0.50727.42 2005-11-07 Visual Studio 2005

3.0 3.0.4506.30 2006-11-06 Windows Vista, Windows Server 2008

3.5 3.5.21022.8 2007-11-19 Visual Studio 2008 Windows 7, Windows Server 2008 R2

4 Beta 2 2009-10-19 Visual Studio 2010

Page 19: .NET Technology

VersionsVersions .NET Framework 1.0:-.NET Framework 1.0:-

This is the first release of the .NET Framework, This is the first release of the .NET Framework, released on 13 February 2002 and available for released on 13 February 2002 and available for Windows 98, Me, NT 4.0, 2000, and XP. Windows 98, Me, NT 4.0, 2000, and XP.

.NET Framework 1.1:-.NET Framework 1.1:- This is the first major .NET Framework upgrade. This is the first major .NET Framework upgrade.

It is available on its own as a redistributed It is available on its own as a redistributed package or in a software development kit, and package or in a software development kit, and was published on 3 April 2003. was published on 3 April 2003.

It is also part of the second release of Microsoft It is also part of the second release of Microsoft Visual Studio .NET (released as Visual Visual Studio .NET (released as Visual Studio .NET 2003)Studio .NET 2003)

Page 20: .NET Technology

VersionsVersions Changes in 1.1 on comparison Changes in 1.1 on comparison

with 1.0with 1.0 Built-in support for mobile ASP.NET controls. Built-in support for mobile ASP.NET controls. Security changesSecurity changes Built-in support for ODBC and Oracle Built-in support for ODBC and Oracle

databases..databases.. NET Compact Framework - a version of NET Compact Framework - a version of

the .NET Framework for small devices. the .NET Framework for small devices. Internet Protocol version 6 (IPv6) support. Internet Protocol version 6 (IPv6) support. Numerous API changes. Numerous API changes.

Page 21: .NET Technology

VersionsVersions NET Framework 2.0:-NET Framework 2.0:-

Released with Visual Studio 2005, Microsoft Released with Visual Studio 2005, Microsoft SQL Serve 2005SQL Serve 2005

The 2.0 Redistributable Package can be The 2.0 Redistributable Package can be downloaded for free from Microsoft, and was downloaded for free from Microsoft, and was published on 22 January 2006. published on 22 January 2006.

The 2.0 Software Development Kit (SDK) can The 2.0 Software Development Kit (SDK) can be downloaded for free from Microsoft be downloaded for free from Microsoft

It is included as part of Visual Studio 2005 It is included as part of Visual Studio 2005 and Microsoft SQL Server 2005.and Microsoft SQL Server 2005.

Page 22: .NET Technology

VersionsVersions Changes in 2.0 in comparison with 1.1Changes in 2.0 in comparison with 1.1

Numerous API changes. Numerous API changes. Full 64-bit support Full 64-bit support Language support for generics built directly into Language support for generics built directly into

the .NET CLR. the .NET CLR. Many additional and improved ASP.NET web controls. Many additional and improved ASP.NET web controls. New data controls with declarative data binding. New data controls with declarative data binding. New personalization features for ASP.NET, such as New personalization features for ASP.NET, such as

support for themes, skins and webparts. support for themes, skins and webparts. Partial classes Partial classes Data Tables Data Tables Generics Generics

Page 23: .NET Technology

VersionsVersions NET Framework 3.0:-NET Framework 3.0:-

.NET Framework 3.0.NET Framework 3.0, formerly called , formerly called WinFXWinFX, was released , was released on 21 November 2006.on 21 November 2006.

It includes a new set of managed code APIs that are an It includes a new set of managed code APIs that are an integral part of Windows Vista and Windows Server 2008 integral part of Windows Vista and Windows Server 2008 operating systems. operating systems.

It is also available for Windows XP SP2 and Windows Server It is also available for Windows XP SP2 and Windows Server 2003 as a download. 2003 as a download.

There are no major architectural changes included with this There are no major architectural changes included with this releaserelease

.NET Framework 3.0 uses the Common Language Runtime .NET Framework 3.0 uses the Common Language Runtime of .NET Framework 2.0of .NET Framework 2.0

.NET Framework 3.0 consists of four major new .NET Framework 3.0 consists of four major new components: components:

– Windows Presentation FoundationWindows Presentation Foundation– Windows Communication FoundationWindows Communication Foundation – Windows Workflow FoundationWindows Workflow Foundation– Windows CardSpaceWindows CardSpace

Page 24: .NET Technology

VersionsVersions .NET Framework 3.5:-.NET Framework 3.5:-

Version 3.5 of the .NET Framework was released on 19 Version 3.5 of the .NET Framework was released on 19 November 2007, but it is not included with Windows November 2007, but it is not included with Windows Server 2008.Server 2008.

As with .NET Framework 3.0, version 3.5 uses the CLR of As with .NET Framework 3.0, version 3.5 uses the CLR of version 2.0. version 2.0.

It adds some methods and properties to the BCL classes It adds some methods and properties to the BCL classes in version 2.0 which are required for version 3.5 features in version 2.0 which are required for version 3.5 features such as Language Integrated Query (LINQ).such as Language Integrated Query (LINQ).

As with previous versions, a new As with previous versions, a new .NET Compact .NET Compact Framework 3.5Framework 3.5 was released in tandem with this was released in tandem with this update in order to provide support for additional features update in order to provide support for additional features on Windows Mobile and Windows Embedded CE devices.on Windows Mobile and Windows Embedded CE devices.

Page 25: .NET Technology

VersionsVersions ADO.NET:-ADO.NET:-

– This helps catch more programming errors This helps catch more programming errors at compile-time and makes the IDE's at compile-time and makes the IDE's Intellisense feature more beneficial.Intellisense feature more beneficial.

Language Integrated Query (LINQ):-Language Integrated Query (LINQ):-– LINQ to Objects LINQ to Objects – LINQ to XML LINQ to XML – LINQ to SQL LINQ to SQL

NET Framework 4:-NET Framework 4:- Microsoft announced the .NET Framework 4 Microsoft announced the .NET Framework 4

on 29 September 2008on 29 September 2008

Page 26: .NET Technology

NET vs. Java and Java EENET vs. Java and Java EE

The CLI and .NET languages such as C# and VB have many The CLI and .NET languages such as C# and VB have many similarities to Sun's JVM and Java. similarities to Sun's JVM and Java.

Both are based on a virtual machine model that hides the Both are based on a virtual machine model that hides the details of the computer hardware on which their programs details of the computer hardware on which their programs run. run.

Both use their own intermediate byte-code, Microsoft Both use their own intermediate byte-code, Microsoft calling theirs Common Intermediate Language (calling theirs Common Intermediate Language (CILCIL; ; formerly formerly MSILMSIL) and Sun calling theirs Java bytecode. ) and Sun calling theirs Java bytecode.

On .NET the byte-code is always compiled before execution, On .NET the byte-code is always compiled before execution, in Just In Time (JIT) With Java the byte-code is either in Just In Time (JIT) With Java the byte-code is either interpreted, compiled in advance, or compiled JIT.interpreted, compiled in advance, or compiled JIT.

Both provide extensive class libraries Both provide extensive class libraries The namespaces provided in the .NET Framework closely The namespaces provided in the .NET Framework closely

resemble the platform packages in the Java EE API resemble the platform packages in the Java EE API Specification Specification