.NET Overview. 2 Objectives Introduce.NET –overview –languages –libraries –development and execution model Examine simple C# program.

Slides:



Advertisements
Similar presentations
Introduction to .NET Framework
Advertisements

Tahir Nawaz Introduction to.NET Framework. .NET – What Is It? Software platform Language neutral In other words:.NET is not a language (Runtime and a.
History of.Net Introduced by Microsoft Earlier technology was VC++ and VB VC++ comes with so many library and VB was so easy to use and not flexible to.
.NET Framework Overview Pingping Ma Nov 16 th, 2006.
Henrico Dolfing Business Segment Partners. Océ Document Technologies GmbH2 June, NET Framework Version 3.0.
.NET Technology.
CIM2564 Introduction to Development Frameworks 1 Overview of a Development Framework Topic 1.
Overview of the.NET Framework. What is the.NET Framework A new computing platform designed to simplify application development A consistent object-oriented.
Introduction to ASP.NET What is.NET What is ASP.NET and how is different from ASP –ASP: server side technology for creating dynamic web pages using scripting.
Introduction to the C# Programming Language for the VB Programmer.
.NET’s CLR How does it really work? 7/2/20151Bhavani Sankar Ikkurthi CS 795 Presentation.
2. Developing in.NET and C#. 2 Microsoft Objectives “Microsoft.NET development is based on an underlying framework of tools and classes. These tools and.
Platforms and tools for Web Services and Mobile Applications Introduction to C# Bent Thomsen Aalborg University 3rd and 4th of June 2004.
Intro to dot Net Dr. John Abraham UTPA – Fall 09 CSCI 3327.
An Introduction to C# and the .NET Framework
Rajeswari Indupuri Introduction to.NET Framework.
A Free sample background from © 2001 By Default!Slide 1.NET Overview BY: Pinkesh Desai.
Overview of Microsoft.Net and Vb.Net ITSE 2349 Spring 2002 Material from Microsoft.Net an Overview for ACC faculty by Stuart Laughton and Introduction.
Computer Science 317 Database Management Introduction to Web Access to Databases.
Introduction to .Net Framework
1 8/29/05CS360 Windows Programming Professor Shereen Khoja.
Microsoft.NET Framework Overview Abidi Mahmoud Seminarium on Component -based Software Engineering.
Architecture of.NET Framework .NET Framework ٭ Microsoft.NET (pronounced “dot net”) is a software component that runs on the Windows operating.
.NET Overview. 2 Objectives Introduce.NET –overview –languages –libraries –development and execution model Examine simple C# program.
Session 1 - Introduction and Data Access Layer
C# A 1 CSC 298 Introduction to C#. C# A 2 What to expect in this class  Background: knowledge of an object oriented language of the C++, Java, … family.
11 Getting Started with C# Chapter Objectives You will be able to: 1. Say in general terms how C# differs from C. 2. Create, compile, and run a.
.NET Framework & C#.
Introduction to.NET Framework. .NET – What Is It? Software platform Language neutral In other words:.NET is not a language (Runtime and a library for.
Introduction to .NET Framework
Understanding Code Compilation and Deployment Lesson 4.
Windows CE 시스템 개발 개요. 임베디드시스템소프트웨어 -Windows CE 2 Overview  Selecting a Windows Embedded Operating System  The Windows CE Platform Development Cycle.
CIS 375—Web App Dev II Microsoft’s.NET. 2 Introduction to.NET Steve Ballmer (January 2000): Steve Ballmer "Delivering an Internet-based platform of Next.
Introduction .NET Framework
Overview of System Development. Overview Selecting a Windows Embedded Operating System The Windows CE Platform Development Cycle The Application Development.
ISYS 573 Special Topic – VB.Net David Chao. The History of VB Early 1960s:BASIC-Beginner’s All-Purpose Symbolic Instruction Code –Teaching –Simple syntax,
CS795/895: Introduction. Topics Distributed Systems –Availability –Performance –Web Services Security –Authentication –Authorization –Confidentiality.
Component-Based Software Engineering Introduction to.NET Paul Krause.
.NET Framework Danish Sami UG Lead.NetFoundry
Introduction to VB.Net. What is.NET? A brand of Microsoft technologies A platform for creating distributed Web applications A combination of new and updated.
1.NET FRAMEWORK CE-105 Spring 2007 Engr. Faisal ur Rehman.
AUC Technologies Projects Consulting, Development, Mentoring, and Training Company Application Foundation Presented By : Naveed Sattar Software Engineer.
Rajiv and Shipra Introduction to.NET (asp.net,c#,vb)
tom perkins1 XML Web Services -.NET FRAMEWORK – Part 1 CHAPTER 1.1 – 1.3.
Introducing ASP.NET 2.0. Internet Technologies WWW Architecture Web Server Client Server Request Response Network HTTP TCP/IP PC/Mac/Unix + Browser (IE,
Introduction to.NET. What is.NET? Microsoft’s vision of the future of applications in the Internet age –Increased robustness over classic Windows apps.
Active Server Pages (ASP), also known as Classic ASP or ASP Classic, was Microsoft's first server-side script engine for dynamically generated web pages.
Module 3: Using Microsoft.NET- Based Languages. Overview Overview of the.NET-Based Languages Comparison of the.NET-Based Languages.
Intro to dot Net Dr. John Abraham UTPA CSCI 3327.
Key Components of.NET Framework  Common Language Runtime  CLR at Design time  CLR at Runtime  Class Library  Assemblies  Namespaces  ASP.NET  Applications.
Module 1: Overview of the Microsoft .NET Framework
PRIOR TO WEB SERVICES THE OTHER TECHNOLOGIES ARE:.
Chapters 2 & 3. .NET Software development model that allows applications created in disparate programming languages to communicate Universal data access.
ASP.NET (Active Server Page) SNU OOPSLA Lab. October 2005.
.NET Ying Chen Junwei Chen. What is Microsoft.NET. NET is a development platform Incorporated into.NET COM+ component services ASP web development framework.
Microsoft .NET A platform that can be used for building and running windows and web applications such that the software is platform and device-independent.
1. The .NET Architecture 1. The .NET Architecture 2003
Getting Started with.NET Getting Started with.NET/Lesson 1/Slide 1 of 31 Objectives In this lesson, you will learn to: *Identify the components of the.NET.
INTRODUCTION CHAPTER #1 Visual Basic.NET. VB.Net General features It is an object oriented language  In the past VB had objects but focus was not placed.
Text Introduction to.NET Framework. CONFIDENTIAL Agenda .NET Training – Purpose  What is.NET?  Why.NET?  Advantages  Architecture  Components: CLR,
Intro to ASP.NET CS-422 Dick Steflik. What is.NET As applications in the Enterprise become more and more netcentric and less and less standalone.NET is.
Introduction to the Microsoft.NET Framework Chris Wastchak Student Ambassador to Microsoft.
Lecture 1: The .NET Architecture
Introduction to .NET framework
CE-105 Spring 2007 Engr. Faisal ur Rehman
Application Foundation
Introduction to C# AKEEL AHMED.
Programming in C# CHAPTER 1
DOT NET ARCHITECTURE (OR) DOT NET FRAME WORK ARCHITECTURE
IS 135 Business Programming
Presentation transcript:

.NET Overview

2 Objectives Introduce.NET –overview –languages –libraries –development and execution model Examine simple C# program

3 developmentplatformserversservices.NET Overview.NET is a sweeping marketing term for a family of products –development tools and languages –platform –application management servers –value-added services Languages Compilers Visual Studio.NET Common Language Runtime Framework Libraries SQL Server BizTalk SharePoint... My Services Alerts Passport...

4 Overview of.NET Consistent development model The.NET Framework proves an object-oriented and consistent development model for different types of applications, such as Windows Forms applications, Web applications, and Web services. Robust execution environment The.NET Framework provides an execution environment that maximizes security, robustness, and performance of applications while minimizing deployment and versioning conflicts. Support for standards The.NET Framework is built around industry standards such as Extensible Markup Language (XML), Simple Object Access Protocol (SOAP), Common Language Infrastructure (CLI), and C#.

5 Evolution of the platform.NET is the next evolutionary step for the Microsoft platform –new languages largely replace classic C++ and Visual Basic –new runtime model reduces need for COM style integration –XML web services used in place of DCOM –Windows Forms replace MFC –ASP.NET improves on ASP –etc.

6 Software development.NET software development and execution has many actors –languages –libraries –compilers –intermediate language –execution engine

7 Languages Many.NET programming languages available –C# –VB.NET –C++ –etc. Language choice typically based on many factors –programmer background –problem domain –language features –corporate mandate

8 Language power All languages can access.NET infrastructure C# class Hello { static void Main() { System.Console.WriteLine("hello"); } VB.NET Class Goodbye Shared Sub Main() System.Console.WriteLine("goodbye") End Sub End Class

9 Language interoperability All.NET languages can interoperate C# calling VB.NET class Hello { static void Main() { System.Console.WriteLine(Greeting.Message()); } Class Greeting Shared Function Message() As String Return "hello" End Function End Class

10 C# VB.NET Language variability Not all.NET languages have exactly the same capabilities –differ in small but important ways class Hello { static void Main() { int i; uint u; } Class Greeting Shared Sub Main() Dim i as Integer End Sub End Class signed integer unsigned integer signed integer only

11 Common Language Specification Common Language Specification (CLS) defines type subset –required to be supported by all.NET languages –limiting code to CLS maximizes language interoperability –code limited to CLS called CLS compliant public class Calculator { public uint Add(uint a, uint b) { return a + b; } not CLS compliant to use uint in public interface of public class

12.NET is cross-platform.NET apps run on any supported platform.EXE ? Win64Win32 ( XP,2K,98) WinCE Linux via Mono FreeBSD via Rotor.DLL

13 How is this possible?.NET applications are not stand-alone apps –require presence of.NET Framework = CLR + FCL other FCL components CLR (MSCOREE.dll) JIT Compiler Process Underlying OS and HW Core FCL (MSCOR LIB.dll).DLL.EXE obj code CLR = Common Language Runtime FCL = Framework Class Library

14.NET Framework class library Library Extensive set of standard libraries available –for wide range of application types –called.NET Framework class library Collections Web development Input/Output Database access Windows Forms GUI Networking XML processing Threading Reflection Debugging

15 Framework Class Library (FCL)

16 Writing Windows Programs Application Programming Interfaces (API) –Win16 - Windows 3.1 [Segmented Memory] –Win32 - Windows 95/98/NT/2000/XP [Flat Memory] Differences between 9X & NT families Unsupported functions [Security, etc.] Unicode vs ASCII All windows programs use the API, but not all equal –API is C-centric, some things are difficult in VB –Programs are monolithic, can't be part VB, part C MS.NET is "unified API" on top of Win32

17 Compilation Compilers produce Intermediate Language (IL) –IL is not executable –similar to assembly language –processor independent C# codeVB.NET code code VB.NET compilerC# compiler compiler IL

18 IL C# compiler translates C# source code into IL C# source IL.locals init ([0] class Calc c, [1] int32 sum) newobj instance void Calc::.ctor() stloc.0 // c = ptr to new object ldloc.0 ldc.i4.2 // pass second arg ldc.i4.4 // pass first arg callvirt instance int32 Calc::Add(int32,int32) stloc.1 // sum = retval Calc c = new Calc(); int sum = c.Add(2, 4); C# compiler

19 CLR Execution engine Common Language Runtime (CLR) is the execution engine –loads IL –compiles IL –executes resulting machine code IL Runtime compiler Execute machine code

20 Cache JIT runtime compile IL is compiled into machine code at runtime by the CLR –compiles methods as needed –called just in time (JIT) compile JIT compilation model: –first time method is called the IL is compiled and optimized –compiled machine code is cached in transient memory –cached copy used for subsequent calls IL code F() G() H() JIT runtime compiler Execute machine code for F()

21 IL? IL is the assembly language of the.NET platform –IL = "Intermediate Language" –JIT compiler converts IL to asm lang of underlying HW '** simply adds 2 integers together and returns the result… Public Function Add(ByVal x As Integer, ByVal y As Integer) As Integer Add = x + y End Function

22 NGEN install time compile Can compile IL into machine code when app installed –use native image generator ngen.exe –can speed startup time since code pre-compiled –but cannot do as many optimizations –original IL must still be available for type information CLR IL ngen Execute native image cache machine code

23 Execution command CLR automatically invoked when.NET application executed C:\> MyApp hello execute

24 Implications of.NET architecture 1. Your clients will need.NET Framework –available via Redistributable.NET Framework (20MB) –2 versions, v1.0 (2002) and v1.1 (2003) –runs on 98, NT (6a), 2000, XP, Design trade-off… + managed execution (memory mgmt, security, …) + portability – slower execution (10%?) JIT compiler has potential to close performance gap

25 MyApp.cs C# program C# program basics –source file has.cs extension –namespace used to group related types –class defines new type –Main is application entry point –WriteLine writes output –{ and } delimit code block namespace MyNamespace { class MyApp { static void Main() { System.Console.WriteLine("hello"); }

26 Building console executable Can use C# compiler to build console executable –use /t[arget]:exe –use /out: to specify output file name Default values can simplify use –default target type is console executable –default name adds.exe to base name of file containing Main C:\> csc /target:exe /out:MyApp.exe MyApp.cs explicit options C:\> csc MyApp.cs implicit options

27 Building Windows executable Can use C# compiler to build windows executable –use /t[arget]:winexe C:\> csc /target:winexe MyWinApp.cs build Windows application

28 Building library Can use C# compiler to build library –use /t[arget]:library Controlling output file name: –can use /out: to specify output file name –default: adds.dll to base name of first input file C:\> csc /target:library /out:MyLib.dll MyLib.cs create library

29 Summary.NET requires multiple steps to develop and run software –code in one of the many.NET languages –compile into IL –install the CLR –execute CLR JIT compiles IL at runtime –always executes compiled code –never interpreted Can target CLS compliance –to maximize language interoperability