53
.NET Framework Introduction Nouman Qureshi [email protected]

NET Framework Introduction Nouman Qureshi [email protected]

Embed Size (px)

Citation preview

Page 1: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

.NET Framework Introduction

Nouman Qureshi [email protected]

Page 2: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• Support Structure

.NET Framework Introduction

Nouman Qureshi [email protected]

Page 3: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• Support Structure.

• Software also designs or develop before framework , but there we should have to do extra efforts .

.NET Framework Introduction

Nouman Qureshi [email protected]

Page 4: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• Support Structure.

• Software also designs or develop before framework , but there we should have to do extra efforts .

• Minimum Libraries Available.

.NET Framework Introduction

Nouman Qureshi [email protected]

Page 5: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• Support Structure.

• Software also designs or develop before framework , but there we should have to do extra efforts .

• Minimum Libraries Available.

• Garbage Collection , Exception Handling , Mouse Routine etc.

• Wheel is Invent. !

.NET Framework Introduction

Nouman Qureshi [email protected]

Page 6: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• Support Structure.

• Software also designs or develop before framework , but there we should have to do extra efforts .

• Minimum Libraries Available.

• Garbage Collection , Exception Handling , Mouse Routine etc.

• Applications was thick (thousand’s lines of code).

.NET Framework Introduction

Nouman Qureshi [email protected]

Page 7: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• No Layer Between App and OS.

.NET Framework Introduction

Nouman Qureshi [email protected]

Page 8: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• Software also designs or develop before framework , but there we should have to do extra efforts .

• Minimum libraries was available we built maximum

• Like in C/C++ Mouse Programming etc

• Now In framework such type of libraries are from very first day.

.NET Framework Introduction

Nouman Qureshi [email protected]

Page 9: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• Before Framework your application was thick and libraries was thin.

• Because minimum libraries was available and maximum you should develop.

• For example to enable mouse in C/C++ we code thousands of lines of code. So your application size will be large.

.NET Framework Introduction

Nouman Qureshi [email protected]

Page 10: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• Also if two developer are developing then they both have to define their own code for mouse no one can use code of other.

• But Now If framework is available your application will be thin.

• Before framework your application communicate OS directly.

• Components of framework are highly integrated with each other.

.NET Framework Introduction

Prepared By : Syed Noman Ali

Page 11: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• Garbage Collection , Exception Handling , Mouse Routine are available from first day.

• Now you don’t to have to invent wheel , wheel is available you just use wheel.

• To Run Application You required Framework.

.NET Framework Introduction

Prepared By : Syed Noman Ali

Page 12: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• Framework platform independent, language independent , tool independent .

• Different framework are available in different languages.

• .NET New and Enhanced Technology.

.NET Framework Introduction

Prepared By : Syed Noman Ali

Page 13: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• Means a Framework which is new and also enhanced, Enhanced means which was available before.

• .Net Framework Software is a software component, which install on Os.

• . For Internet.

• Framework Has Different Components.

.NET Framework Introduction

Prepared By : Syed Noman Ali

Page 14: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• Framework platform independent, language independent , tool independent .

• Different framework are available in different languages.

• .NET New and Enhanced Technology.

.NET Framework Introduction

Prepared By : Syed Noman Ali

Page 15: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• Means a Framework which is new and also enhanced, Enhanced means which was available before.

• .Net Framework Software is a software component, which install on Os.

• . For Internet.

• Framework Has Different Components.

.NET Framework Introduction

Prepared By : Syed Noman Ali

Page 16: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

Libraries

• Libraries are set of functionalities.

• Libraries provide functionalities.

• There are Base Class Library which provide common functionalities like DataType IO Generics.

.NET Framework Introduction

Prepared By : Syed Noman Ali

Page 17: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• Frame Work Class Library has un common things like ASP.NET ADO.NET etc.

• As A whole Framework library is FCL.

• BCL is a sub set of FCL and FCL is a super set of BCL.

• Framework libraries are dynamic.

.NET Framework Introduction

Prepared By : Syed Noman Ali

Page 18: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

CLR • Before framework application directly communicate with your OS .

• there was no layer between OS and Application .

• Which was vulnerable. Your application can do any thing with your OS.

• If Your application crash Your OS also Crash.

.NET Framework Introduction

Prepared By : Syed Noman Ali

Page 19: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• Like Blue Screen in Earlier Version of Windows.

• But Now if your application crashed , framework close your application rather than impact on OS.

.NET Framework Introduction

Prepared By : Syed Noman Ali

Page 20: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• Requirement of Application or OS services which is required to your application framework (CLR) provide to your application.

.NET Framework Introduction

Prepared By : Syed Noman Ali

Page 21: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• Before framework application directly communicate with your OS .

• there was no layer between OS and Application .

• Which was vulnerable. Your application can do any thing with your OS.

• Microsoft gives a layer between your application and OS.

.NET Framework Introduction

Prepared By : Syed Noman Ali

Page 22: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• If Your application crash Your OS also Crash.

• Like Blue Screen in Earlier Version of Windows.

• But Now if your application crashed , framework close your application rather than impact on OS.

.NET Framework Introduction

Prepared By : Syed Noman Ali

Page 23: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• Requirement of Application or OS services which is required to your application framework (CLR) provide to your application.

• CLR is live or run time environment when you run your application , CLR communicate with your OS.

.NET Framework Introduction

Prepared By : Syed Noman Ali

Page 24: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• Strong Reason For Developing .NET , Application which is created in C++ ,Vb6

programmer can’t use application of C++ .

• If an Application is Written in C++ in VB you have to write this application again.

• Because Tool Change , Language Change , Input Change , Output change.

.NET Framework Introduction

Prepared By : Syed Noman Ali

Page 25: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• C++ Developer Says he/she create strong application he/she use pointers etc .

• VB6 programmer says he/she creates application rapidly.

• Now like a wheel we create and application in C++ and we can use in VB6 etc.

.NET Framework Introduction

Prepared By : Syed Noman Ali

Page 26: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• Now you have visual studio single integrated development environment, one tool in which you can create application in C++ as Well a VB6 etc.

• But Before .NET tool change language change , input change , output change , Compiler different .

.NET Framework Introduction

Prepared By : Syed Noman Ali

Page 27: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• First your learn Tool then language syntax etc.

• Now Tool same , IDE same , Input (Libraries ) same, out put same . • 30 + languages run on single IDE

.NET Framework Introduction

Prepared By : Syed Noman Ali

Page 28: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• A tool which facilitate all developers.

• C# developer using these tool as well as VB , C++ etc.

• In a single tool VB6 application is compiling , C# sharp compiling , C++ compiling , not possible to think , but Microsoft does.

.NET Framework Introduction

Prepared By : Syed Noman Ali

Page 29: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• VB.Net compiler is vbc , C# compiler is csc .

• All language running on a single platform.

• Behind the scene when you compile your application of VB vbc compiler use, C# application csc compiler use on a single IDE.

.NET Framework Introduction

Prepared By : Syed Noman Ali

Page 30: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• How its possible application written in C++ or VB can use in C#.

• When you compile your application of C# , C# compiler csc produce output in MSIL which is another low level language.

• Also when you compile your VB application , vb compiler vsc compiler produce out in MSIL.

.NET Framework Introduction

Prepared By : Syed Noman Ali

Page 31: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• C# application out is in MSIL and VB application out also in MSIL.

• Out which is produce by vsc VB.NET in the form of MSIL , VB.NET compiler

can consume this out put.

• You can write library , now you can use this library through add reference on 1000 places now your compiler is also producer as well as consumer.

.NET Framework Introduction

Prepared By : Syed Noman Ali

Page 32: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• Suppose you write a function after compile make it DLL , now you can use any where.

• VB.NET compiler is producing and consuming MSIL , C# compiler consuming and producing MSIL , SO now C# compiler can understand output produced by VB.NET.

.NET Framework Introduction

Prepared By : Syed Noman Ali

Page 33: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• Because when both C# and VB.NET understands MSIL so they can communicate.

.NET Framework Introduction

Prepared By : Syed Noman Ali

Page 34: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• You compile your application MSIL or exe produce. When your double click or run your application CLR again Compile your application using JIT and

produce native according to your OS.

• IF Your Os is windows 7 then it will generate native code according to windows7.

.NET Framework Introduction

Prepared By : Syed Noman Ali

Page 35: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• Before framework when you compile your code on 32 bit system , so 32 can use your code only.

• But Now your application can run after 10 years because of forward compatibility. Except one platform 16bit.

• Now Your application will be platform independent but for Windows.

.NET Framework Introduction

Prepared By : Syed Noman Ali

Page 36: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• When JIT compile MSIL this is double compilation.

• When you compile one language and in the result another language produce is cross compilation.

• Double compilation .NET framework does and Cross compilation you have to do.

.NET Framework Introduction

Prepared By : Syed Noman Ali

Page 37: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

What is WinAPI Or Win32 API ?

Prepared By : Syed Noman Ali

Page 38: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• Windows APIs are dynamic-link libraries (DLLs) that are part of the Windows operating system.

What is WinAPI Or Win32 API ?

Prepared By : Syed Noman Ali

Page 39: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• You use them to perform tasks when it is difficult to write equivalent procedures of your own.

What is WinAPI Or Win32 API ?

Prepared By : Syed Noman Ali

Page 40: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• Is Microsoft's core set of application programming interfaces (APIs) available in the Microsoft Windows operating systems.

What is WinAPI Or Win32 API ?

Prepared By : Syed Noman Ali

Page 41: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• For example, Windows provides a function named FlashWindowEx that lets you make the title bar for an application alternate between light and dark

shades.

What is WinAPI Or Win32 API ?

Prepared By : Syed Noman Ali

Page 42: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• The advantage of using Windows APIs in your code is that they can save development time because they contain dozens of useful functions that are already written and waiting to be used.

What is WinAPI Or Win32 API ?

Prepared By : Syed Noman Ali

Page 43: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• The disadvantage is that Windows APIs can be difficult to work with and unforgiving when things go wrong.

What is WinAPI Or Win32 API ?

Prepared By : Syed Noman Ali

Page 44: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• Windows APIs represent a special category of interoperability.

What is WinAPI Or Win32 API ?

Prepared By : Syed Noman Ali

Page 45: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• The Windows API, informally WinAPI,.

• It was formerly called the Win32 API;

What is WinAPI Or Win32 API ?

Prepared By : Syed Noman Ali

Page 46: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• .NET provides a new API, new functionality, and new tools for writing Windows and Web applications, components, and services in the Web age.

What is WinAPI Or Win32 API ?

Prepared By : Syed Noman Ali

Page 47: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• Windows APIs do not use managed code, do not have built-in type libraries, and use data types that are different than those used with Visual Studio.

What is WinAPI Or Win32 API ?

Prepared By : Syed Noman Ali

Page 48: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• The Windows API, the library of functions used to write Windows applications, was originally written in C and has steadily grown over the years.

Why do we need a new API

Prepared By : Syed Noman Ali

Page 49: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• It now consists of many thousands of routines and has several problems.

What is WinAPI Or Win32 API ?

Prepared By : Syed Noman Ali

Page 50: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• First, it has grown very large and has no coherent internal organization, which can make it hard to use.

What is WinAPI Or Win32 API ?

Prepared By : Syed Noman Ali

Page 51: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• During its growth, features were added piecemeal,

• so it doesn’t always present a unified interface to developers, and it contains a lot of legacy functions and data types.

What is WinAPI Or Win32 API ?

Prepared By : Syed Noman Ali

Page 52: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• Second, a more major problem is that the Windows API was initially designed for use by C programmers.

What is WinAPI Or Win32 API ?

Prepared By : Syed Noman Ali

Page 53: NET Framework Introduction Nouman Qureshi Noomeee19@hotmail.com

• This means that it can be difficult to use in languages other than C.

• It also doesn’t fit in very well with modern object-oriented programming methods and languages

What is WinAPI Or Win32 API ?

Prepared By : Syed Noman Ali