DotNET A Developer’s Perspective Mike Litzkow University of Wisconsin - MadisonOne.

17
DotNET DotNET A Developer’s A Developer’s Perspective Perspective Mike Litzkow University of Wisconsin - Madison One One

Transcript of DotNET A Developer’s Perspective Mike Litzkow University of Wisconsin - MadisonOne.

Page 1: DotNET A Developer’s Perspective Mike Litzkow University of Wisconsin - MadisonOne.

DotNETDotNETA Developer’s PerspectiveA Developer’s Perspective

Mike Litzkow

University of Wisconsin - Madison

OneOne

Page 2: DotNET A Developer’s Perspective Mike Litzkow University of Wisconsin - MadisonOne.

Microsoft’s GoalsMicrosoft’s Goals

Better software development toolsBetter softwareTake over the world

– Desktop– Servers– Small Devices

Page 3: DotNET A Developer’s Perspective Mike Litzkow University of Wisconsin - MadisonOne.

What Is DotNET?What Is DotNET?

Execution environment above Win32– Common Language Runtime

Major Technology Pieces– DotNET Framework– C#– ASP.NET– XML Web Services (passport & friends)– Visual Studio .NET

Page 4: DotNET A Developer’s Perspective Mike Litzkow University of Wisconsin - MadisonOne.

Common Language Runtime (CLR)Common Language Runtime (CLR)

Supports multiple languages– Languages interoperate freely

All code is compiled on target machine– Compiler aware of actual CPU to be used – Nothing is interpreted (not even script)– JIT is default, can compile at install time

Type safety– Including array bounds checking

Garbage collection

(including inheritance)

C++, C#, VB, JavaScriptCobol, Fortran, Perl, Python, Eiffel, Pascal, SmallTalk, …

Page 5: DotNET A Developer’s Perspective Mike Litzkow University of Wisconsin - MadisonOne.

But, Will the CLR Last?But, Will the CLR Last?

Enterprise development– language interoperability

Security– buffer overrun problems eliminated

Software reliability– memory leaks, access errors eliminated– versioning problems addressed (end of DLL Hell)

Transition to 64-bit architecture– no pointers, target machine compilation

Probably Yes

Page 6: DotNET A Developer’s Perspective Mike Litzkow University of Wisconsin - MadisonOne.

Multi-language development Multi-language debugging Syntax coloring and checking Intellisense Drag ‘n Drop GUI development

– Same GUI tools for multiple languages– Similar GUI tools for desktop and web

Visual Studio.NETVisual Studio.NETC++, C#, VB, JavaScript, HTML, XML, Schema, Bitmaps, …

Command line development is available

(and free) DotNET Framework SDK

Page 7: DotNET A Developer’s Perspective Mike Litzkow University of Wisconsin - MadisonOne.

DotNET FrameworkDotNET Framework

Example content– Object, String, Int,

Float, …– I/O– Windows forms– Web forms– XML processing– Reflection

Usage model– Direct use– Use by inheritance– Custom toolbox

Page 8: DotNET A Developer’s Perspective Mike Litzkow University of Wisconsin - MadisonOne.

C#C#

Extremely similar to Java Differences

– Enumerations– Properties– Delegates– No “checked” exceptions– Everything is an object

Reference types Value types

Page 9: DotNET A Developer’s Perspective Mike Litzkow University of Wisconsin - MadisonOne.

C# - Syntax ExamplesC# - Syntax Examples

Enumerationpublic enum Direction {North, South, East, West};private Direction direction;

Propertypublic Direction Direction {

get { return direction; }set {

direction = value;pointTo( direction );

}}

Property usage

obj.Direction = Direction.North;

Delegate

too comp

lex to s

how here

Page 10: DotNET A Developer’s Perspective Mike Litzkow University of Wisconsin - MadisonOne.

But, Will C# Last?But, Will C# Last?

It’s a good language, but a lot like JavaMS has control – unlike JavaHeavily used inside MS

Is C# a really important part of DotNET?

Probably Yes

Nah

Page 11: DotNET A Developer’s Perspective Mike Litzkow University of Wisconsin - MadisonOne.

ASP.NETASP.NET

Server-side code– runs on CLR– uses .NET Framework

All code is compiled (even JavaScript) Supports separation of code and HTML Easy and efficient DB connectivity Drag ‘n drop web forms development

– Forms work across multiple browsers– Even small devices

Xcopy deployment Debugging, logging, caching, …

Page 12: DotNET A Developer’s Perspective Mike Litzkow University of Wisconsin - MadisonOne.

But, Will ASP.NET Last?But, Will ASP.NET Last?

Probably Yes (CLR on Server, .NET Framework support)Not sure about web forms, HTML/Script connection, DB Connectivty …

Page 13: DotNET A Developer’s Perspective Mike Litzkow University of Wisconsin - MadisonOne.

XML Web ServicesXML Web Services

RPC implemented with XML (SOAP)Service description in XML (WSDL)Underlying protocol HTTP – penetrates

firewallsLots of hype and controversy (Passport)

Geneva convention

Page 14: DotNET A Developer’s Perspective Mike Litzkow University of Wisconsin - MadisonOne.

But, Will XML Web Services Last?But, Will XML Web Services Last?

Web services are an industry wide initiative

Lots of questions about compatibility remain

Will be important for B2B commerce

Much more slowly than Microsoft hopes

Page 15: DotNET A Developer’s Perspective Mike Litzkow University of Wisconsin - MadisonOne.

DotNET BooksDotNET Books

Introducing Microsoft .NET– David S. Platt

C# Essentials– Ben Albahari

Applied Microsoft .NET Framework Programming– Jeffery Richter

Essential .NET: The Common Language Runtime– Don Box

Programming Microsoft Windows With C#– Charles Petzold

Easy Intro to Whole Platform

Compact reference for C#

CLR

CLR

Windows Forms (desktop apps)

Page 16: DotNET A Developer’s Perspective Mike Litzkow University of Wisconsin - MadisonOne.

Further TalksFurther Talks

C#– Delegates– C# vs C++ performance– GUI builder

CLR– Types– Metadata– Versioning– Security

ASP.NET– Web forms– Database connectivity– “Business” logic– Security