Upload
rohitpr2007
View
228
Download
0
Embed Size (px)
Citation preview
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 1/33
.NET Framework-Application Development Simplified
1© NIIT
With the change in technology, the approach to application
development has changed completely. Earlier, the
developers had to learn different programming languages to
develop different types of applications. This was a
complicated task.
The .NET Framework has simplified this task by providing a
common platform that enables the developers to develop
different types of applications easily and quickly.
Rationale
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 2/33
.NET Framework-Application Development Simplified
2© NIIT
In this session, you will learnabout the .NET Framework
and how it helps in rapid
application development.
Objective
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 3/33
.NET Framework-Application Development Simplified
3© NIIT
What is the .NET
Framework?
Introducing the .NET Framework
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 4/33
.NET Framework-Application Development Simplified
4© NIIT
The .NET Framework is a:
Language-independent software development environment.
Platform designed for developing interoperable applications.
The objective of the .NET Framework is to bring various
programming languages and services together.
Introducing the .NET Framework (Contd.)
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 5/33
.NET Framework-Application Development Simplified
5© NIIT
The following figure illustrates the .NET Enterprise vision.
Introducing the .NET Framework (Contd.)
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 6/33
.NET Framework-Application Development Simplified
6© NIIT
Using the .NET Framework, you can create applications
that are:
Robust: Applications that remain stable in extreme situations,
such as erroneous inputs
Scalable: Applications that can be extended
Distributed: Applications whose components run on different
computers over a network
The .NET Framework has various components.
Introducing the .NET Framework (Contd.)
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 7/33
.NET Framework-Application Development Simplified
7© NIIT
What are the components
of the .NET Framework?
Components of the .NET Framework
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 8/33
.NET Framework-Application Development Simplified
8© NIIT
Components of the .NET Framework (Contd.)
The following figure shows the architecture of the .NET
Framework.
Common Language RuntimeCommon Language Runtime
Base Class LibraryBase Class Library
Common Language Specification (CLS)Common Language Specification (CLS)
C++C++ C#C# VB.NETVB.NET J#J# ……V
i s u al S t u d i o
.NE T
V i s u al S t u d i o
.NE T
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 9/33
.NET Framework-Application Development Simplified
9© NIIT
Let us discuss the components
of the .NET Framework.
Components of the .NET Framework (Contd.)
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 10/33
.NET Framework-Application Development Simplified
10© NIIT
Common Language RuntimeCommon Language Runtime
The CLR:
Manages code execution at run time.
Performs functions such as code compilation and garbage
collection.
Components of the .NET Framework (Contd.)
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 11/33
.NET Framework-Application Development Simplified
11© NIIT
The Base Class Library:
Is a standard library available to all languages using the .NET
Framework.
Includes a large number of common functions, such as file
reading and writing, graphic rendering, and database
interaction.
Components of the .NET Framework (Contd.)
Common Language RuntimeCommon Language Runtime
Base Class LibraryBase Class Library
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 12/33
.NET Framework-Application Development Simplified
12© NIIT
Programming languages:
Any .NET supported programming language can be used.
Components of the .NET Framework (Contd.)
Common Language RuntimeCommon Language Runtime
Base Class LibraryBase Class Library
C++C++ C#C# VB.NETVB.NET J#J# ……
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 13/33
.NET Framework-Application Development Simplified
13© NIIT
CLS:
Is a set of rules that enables an object or application to interact
with the objects or applications of other languages.
Components of the .NET Framework (Contd.)
Common Language RuntimeCommon Language Runtime
Base Class LibraryBase Class Library
Common Language Specification (CLS)Common Language Specification (CLS)
C++C++ C#C# VB.NETVB.NET J#J# ……V i s u al S t u
d i o
.NE T
V i s u al S t u
d i o
.NE T
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 14/33
.NET Framework-Application Development Simplified
14© NIIT
Let us discuss the main
components in detail.
Components of the .NET Framework (Contd.)
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 15/33
.NET Framework-Application Development Simplified
15© NIIT
Common Language Runtime (CLR):
Is the environment where all programs using .NET
technologies are executed.
Provides services such as code compilation, memory
allocation, and garbage collection for managed code, which is
represented in the form of Intermediate Language (IL).
IL:
Is a low level language that the CLR understands.
Has to be converted into machine language for execution.
Common Language Runtime
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 16/33
.NET Framework-Application Development Simplified
16© NIIT
Just-In-TimeCompiler
IL is converted
into machine
language
by the
Just-In-Time
compiler
Common Language Runtime (Contd.)
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 17/33
.NET Framework-Application Development Simplified
17© NIIT
CLR consists of a set of common rules known as CLS that
are followed by all the .NET Framework supported
languages.
Common Language Runtime (Contd.)
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 18/33
.NET Framework-Application Development Simplified
18© NIIT
Common Language Runtime
Just-In-TimeCompiler
Common LanguageSpecification
CLS
enables an
object or an
application
to interact
with theobjects or
applications
of other
languages.
Common Language Runtime (Contd.)
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 19/33
.NET Framework-Application Development Simplified
19© NIIT
The following figure shows the code compilation andexecution process.
Compilation Process
Execution Process
JITCompiler
NativeCode
ILILCode
Metadata
SourceCode
LanguageCompiler
Known asAssembly(.EXE or .DLL file)
Known asAssembly(.EXE or .DLL file)
Common Language Runtime (Contd.)
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 20/33
.NET Framework-Application Development Simplified
20© NIIT
During execution, CLR performs the following tasks:
Assembly Loading and namespaces identification
JIT compilation
Garbage collection
Common Language Runtime (Contd.)
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 21/33
.NET Framework-Application Development Simplified
21© NIIT
Let us understand the .NET
Framework Base Class Library.
Base Class Library
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 22/33
.NET Framework-Application Development Simplified
22© NIIT
The .NET Framework Base Class Library:
Works with any .NET language, such as VB.NET, VC++ .NET,
and VC# .NET.
Provides classes that can be used in the code to accomplish a
range of common programming tasks, such as file access and
database connectivity.
Comprises namespaces, which are contained within
assemblies.
Base Class Library (Contd.)
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 23/33
.NET Framework-Application Development Simplified
23© NIIT
Assembly
.NET Framework Base Class Library
Namespaces are
stored in
assemblies andhelp you to create
logical groups of
related classes
and interfaces,
which can be used
by any language
targeting the .NET
Framework.
Namespaces
Base Class Library (Contd.)
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 24/33
.NET Framework-Application Development Simplified
24© NIIT
Assembly
.NET Framework Base Class Library
An assembly is a
single deployable
unit that contains
all the informationabout the
implementation of
classes,
structures, and
interfaces.
Base Class Library (Contd.)
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 25/33
.NET Framework-Application Development Simplified
25© NIIT
The .NET Framework enables you to create the following
types of applications:
Console-based
Windows-based
Web-based
Types of Applications
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 26/33
.NET Framework-Application Development Simplified
26© NIIT
Windows-Based
Applications
Console-based
applications are
generally used
in situations
where minimaluser interaction
is required.
Web-BasedApplication
s
Console-Based
Application
s
Types of .NET Applications
Types of Applications (Contd.)
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 27/33
.NET Framework-Application Development Simplified
27© NIIT
Windows-based
applications are
created when
user interaction
is required.
Types of Applications (Contd.)
Windows-Based
Applications
Web-BasedApplication
s
Console-Based
Application
s
Types of .NET Applications
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 28/33
.NET Framework-Application Development Simplified
28© NIIT
Windows-Based
Applications
Web-BasedApplication
s
Console-Based
Application
s
Types of .NET Applications
Web-based
applications are
created when theapplication needs to
be accessed
anywhere, anytime,
and across
platforms.
Types of Applications (Contd.)
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 29/33
.NET Framework-Application Development Simplified
29© NIIT
Some advantages offered by the .NET Framework are:
Consistent programming model
Multi-platform applications
Multi-language integration
Automatic resource managementAttribute-based programming
Ease of deployment
Advantages of the .NET Framework
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 30/33
.NET Framework-Application Development Simplified
30© NIIT
Visual Studio .NET:
Is a development tool.
Contains the following productivity and debugging features:
Supports managed and unmanaged applications
Supports languages such as C#, C++, VB.NET, and J#
Contains many useful tools and wizardsProvides Windows Forms Designer
Provides ASP.NET Web Forms Designer
Provides Web Services support
Provides SQL Server integration with ADO.NET and XML
Provides the same tool for all languages and platforms.
Using Visual Studio .NET
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 31/33
.NET Framework-Application Development Simplified
31© NIIT
You can use Visual Studio .NET to:
Write code.
Design user interface.
Study documentation.
Debug, test, and deploy applications.
Using Visual Studio .NET (Contd.)
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 32/33
.NET Framework-Application Development Simplified
32© NIIT
The following figure shows the main elements of the Visual
Studio .NET IDE.Windows Form Designer Menu Bar
Solution
Explorer
Window
Output
Window
Properties
Window
ToolboxWindow
Using Visual Studio .NET (Contd.)
8/14/2019 Dot Net Framework Session 01
http://slidepdf.com/reader/full/dot-net-framework-session-01 33/33
.NET Framework-Application Development Simplified
The main elements of the Visual Studio .NET IDE are:
Windows Forms Designer window
Solution Explorer window
Properties window
Toolbox windowOutput window
Code and Text Editor window
Using Visual Studio .NET (Contd.)