16

Intoduction to c# and basics of .net

Embed Size (px)

Citation preview

Page 1: Intoduction to c# and basics of .net
Page 2: Intoduction to c# and basics of .net

*Introduce C# language

*ECMA standard

*originally developed by MSR

*not just Java + C++

*many extensions

*Introduce .NET framework

*future of Windows

*base of Microsoft’s C# implementation

Page 3: Intoduction to c# and basics of .net

*Teach you to program*should be very comfortable writing OO code

*we will not cover much if any basic programming

*Introduce object oriented languages*not even teach you OO style (except wrt C#)

*expected to write all code in OO style

*Give you a detailed grade*S/U only

*even homework

Page 4: Intoduction to c# and basics of .net

*Requirements for the course*come to lecture*participate*do three assignments

*Assignments are S/U*will not be giving a detailed grade* show me that you understand the concepts, and can

write C# code

*All three assignments will be online soon*must be completed by the end of the course

Page 5: Intoduction to c# and basics of .net

*Class time MWF 12:20-1:10

*office hours: W 10:30-12 or by appointment

*[email protected] (4112 Upson)

*Prerequisites: CS 211/212

*really: experience in OO coding/concepts

*Academic Integrity

*Do not submit work that is not your own

*minimum penalty: U in the course

Page 6: Intoduction to c# and basics of .net

*Visual C#*Express: Google “Visual C# Express”

* in Visual Studio: MSDNAA*must be version 2005: we need C# 2.0

*Mono: http://www.go-mono.com *Open Source impl for Linux: not quite at 2.0

*Rotor: http://msdn.microsoft.com/net/sscli *Shared Source impl for Windows (through 2.0)

*Used to work on BSD / OS X, too

Page 7: Intoduction to c# and basics of .net

*Portable.NET: http://www.dotgnu.org *yet another open source impl

*CMS: http://cms.csuglab.cornell.edu*we will use this for homework

*turn on your email notifications!

*Course Webpage: http://www.cs.cornell.edu/courses/cs215 *will post lectures online

*as well as any errata for the homework

Page 8: Intoduction to c# and basics of .net

*You all will have accounts

*MSDNAA access: let me know if you don’t currently have it

*http://www.csuglab.cornell.edu/userinfo.html

*Visual Studio .NET 2005 should be installed there

Page 9: Intoduction to c# and basics of .net

*You all will have accounts

*MSDNAA access: let me know if you don’t currently have it

*http://www.csuglab.cornell.edu/userinfo.html

*Visual Studio .NET 2005 should be installed there

Page 10: Intoduction to c# and basics of .net

*Syllabus (10 more lectures)

*C# constructs: 5 lectures

*Types, Delegates, Generics, Reflection, Iterators

*.NET Memory Management: 1 lecture

*Topics: 4 lectures

*C# 3.0, Threading, Security, MSIL, MSH

Page 11: Intoduction to c# and basics of .net

*Each class will begin with a quiz

*not for credit but for knowledge

*but I will collect them and see what you know

*Today’s quiz will be on prerequisites

*OO programming, mainly to do with Java

* If you don’t know Java, but do have OO experience, it’s OK

*talk to me after if you have trouble

Page 12: Intoduction to c# and basics of .net

*A Framework in which to run code*A Common Language Runtime (CLR)*runs all programs *C# compiles to Microsoft Intermediate Language*MSIL runs on CLR*Virtual Machine like Java*code written in many languages compiles to MSIL

*A Common Language Specification (CLS)*A Common Type System (CTS)

Page 13: Intoduction to c# and basics of .net

Runtime

Operating System

.NET Framework

Common Type

System

Common Language Runtime

Building Blocks (e.g. for Services)

Services: .NET and COM+

SQL Server BizTalk ...

Languages:

C#, Visual Basic, etc

.NET Applications

Enterprise Servers

...Sharepoint ...

Web Services

Page 14: Intoduction to c# and basics of .net

Class Loader

MSIL to NativeCompilers (JIT)

CodeManager

GarbageCollector (GC)

Security Engine Debug Engine

Type Checker Exception Manager

Thread Support COM Marshaler

Base Class Library Support

Page 15: Intoduction to c# and basics of .net

*A set of common types

*any language that runs in CLR should implement

*no syntax specified

*Languages often define aliases

*For example

*CTS defines System.Int32 – 4 byte integer

*C# defines int as an alias of System.Int32

Page 16: Intoduction to c# and basics of .net

www.thinkittraining.in 9566182378