1 / 26

and why your life will never be the same again

Contents. Why .NET?What is .NET?CLRC

colm
Télécharger la présentation

and why your life will never be the same again

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


    1. .NET and why your life will never be the same again Zef Hemel http://www.zefhemel.com

    2. Contents Why .NET? What is .NET? CLR C# ASP.NET Web services .NET Compact Framework Standardization and Open Source .NET vs. Java Demo

    3. Why .NET? Once upon a time there was a company called Sun Sun created Java Microsoft liked to embrace Java, but wanted Windows-specific extensions Sun and Microsoft fought No more Java for Microsoft (2001) They lived happily ever after The end

    4. Or is it? Microsoft decided to bundle a couple of strategies into a new initiative And its called .NET Reasons: More XML (everybody loves XML) Web services Virtual Machine Unification of programming languages Solve DLL Hell

    5. What is .NET?

    6. What is .NET really? Just an umbrella marketing term More important: what is the .NET Framework?

    7. What is the .NET Framework?

    8. Common Language Runtime (CLR) CLR is the Java Virtual Machine of the .NET Framework Reads CIL (Common Intermediate Language), sometimes still known as MSIL CIL is stored in assemblies (.exe or .dll files), instead of .jar and .class files (like in Java) CIL is optimized for JIT (Just in Time compilation) CLR compiles CIL into native machine code and executes that (fast!)

    9. Common Language Runtime (2) There are many programming language compilers which compile to CIL: C# C++ J# Visual Basic .NET COBOL .NET JScript Eiffel .NET Python, Perl CLR also: Manages memory (garbage collection) Manages security More boring stuff

    10. C# People say its a lot like Java Microsoft says its more like C++++ (hence C#)

    11. C# Lets just say that its loosely based on Java Java: C#:

    12. C# (2) C# is actually Java++ Basically has all of Javas features plus: Boxing: treat primitives like objects: 6.ToString() Operator overloading: change meaning of operators like + or - Rectangular arrays: int ar[,] = new int[4,5]; ar[1,1] = 3;

    13. C# (3) More C# features: Indexers: Hashmap hm = Hashmap(); hm[name] = John; Preprocessor: #define DEBUG #ifdef DEBUG // #endif Foreach statement: foreach(string s in array) { // } Unsafe mode: use pointers and do other unsafe things

    14. C# (4) More C# features (and then Ill stop): Pass parameters by reference: void addTwo(ref int p) { p += 2; } Attributes: add meta data to classes, methods and fields: [WebMethod] public void DoSomethingUseful() { // } More subtle differences: http://www.25hoursaday.com/CsharpVsJava.html

    15. ASP.NET Christmas project of couple of Microsoft employees, called ASP+ Many people within Microsoft liked it Team got call from Bill, demoed it, became official Microsoft project ASP+ team met .NET Framework team, resulted in ASP.NET

    16. ASP.NET: what is it? Build web-applications like normal Windows applications Controls Events Demo will follow

    17. Web services Companies become more web-centered They want to do business to business interaction Solution: web services Companies offer their services as web services to other companies, which can use them Basically just RPC (Remote Procedure Call) All based on XML protocols: SOAP, WSDL

    18. Web services: example uses Google API: add Google search to your (web) applications Credit card payments Post to your weblog from your desktop

    19. .NET Compact Framework Compact version of .NET Framework (duh) Runs on Microsoft Smart Phones and Pocket PCs Theres just a lot of fancy (and sometimes less fancy) stuff missing

    20. .NET Standardization Part of .NET is an ECMA standard: Common Language Runtime C# Large part (all?) of Base Class Library

    21. Opening up .NET Because of standardization, it is allowed and encouraged to create new implementations Rotor (Shared Source Licensed by Microsoft) DotGNU (by GNU) Mono (by Ximian, now Novell)

    22. Mono Mono is the most interesting open source .NET Framework implementation Runs on Unices (Linux, FreeBSD, OS X) and Windows Mono 1.0 already released

    23. Mono Features C# compiler CLR implementation (x86, SPARC, PowerPC) Base Class Library ASP.NET implementation ADO.NET (+ many Mono specific database providers) Mono specific: GTK# (for GUIs), Gecko# (browser control), MonoDevelop, MonoDoc, mod_mono, XSP (ASP.NET webserver) Mainly missing: System.WinForms (Windows compatible GUI)

    24. Mono (2) Novell embraced Mono and is basing interesting applications on it: iFolder 3 (peer to peer file sharing) Beagle (desktop search) Mono might become very popular on Linux systems (once people forget Microsoft invented it)

    25. .NET vs. Java So, which ones better? Zef says: Technologically: .NET C# is Java++ CLR is Java VM++ .NET is more pragmatic than Java .NET doesnt drown you in XML files like Java ASP.NET is cooler than Servlets/JSP But: Java IDEs kick Visual Studios bottom in many respects (particularly: code editing)

    26. Demo Enough talk, show us!

More Related