C#.Net. Course Contents. Course contents VT BizTalk. No exam, but laborations

Similar documents
Introduce C# as Object Oriented programming language. Explain, tokens,

C#: framework overview and in-the-small features

Introduction to C# Applications

.Net Technologies. Components of.net Framework

Hierarchical inheritance: Contains one base class and multiple derived classes of the same base class.

New programming language introduced by Microsoft contained in its.net technology Uses many of the best features of C++, Java, Visual Basic, and other

DAD Lab. 1 Introduc7on to C#

Getting started 7. Storing values 21. Creating variables 22 Reading input 24 Employing arrays 26 Casting data types 28 Fixing constants 30 Summary 32

Chapter 1 Getting Started

This tutorial has been prepared for the beginners to help them understand basics of c# Programming.

Table of Contents Preface Bare Necessities... 17

Introduction to.net, C#, and Visual Studio. Part I. Administrivia. Administrivia. Course Structure. Final Project. Part II. What is.net?

Introduction To C#.NET

Question No: 1 ( Marks: 1 ) - Please choose one One difference LISP and PROLOG is. AI Puzzle Game All f the given

Appendix G: Writing Managed C++ Code for the.net Framework

C++\CLI. Jim Fawcett CSE687-OnLine Object Oriented Design Summer 2017

Objectives. Introduce the core C# language features class Main types variables basic input and output operators arrays control constructs comments

PES INSTITUTE OF TECHNOLOGY

Darshan Institute of Engineering & Technology for Diploma Studies

C# Programming in the.net Framework

Introduction to Programming Using Java (98-388)

Short Notes of CS201

Question And Answer.

CS201 - Introduction to Programming Glossary By

The C# Programming Language. Overview

What goes inside when you declare a variable?

C# Types. Industrial Programming. Value Types. Signed and Unsigned. Lecture 3: C# Fundamentals

2. A GUI A. uses buttons, menus, and icons B. should be easy for a user to manipulate C. both (a) and (b) D. stands for Graphic Use Interaction

Industrial Programming

AP COMPUTER SCIENCE JAVA CONCEPTS IV: RESERVED WORDS

UNIT 1. Introduction to Microsoft.NET framework and Basics of VB.Net

Visual Studio.NET.NET Framework. Web Services Web Forms Windows Forms. Data and XML classes. Framework Base Classes. Common Language Runtime

A Comparison of Visual Basic.NET and C#

C# Fundamentals. Hans-Wolfgang Loidl School of Mathematical and Computer Sciences, Heriot-Watt University, Edinburgh

Computer Components. Software{ User Programs. Operating System. Hardware

Course Hours

Java Programming. Atul Prakash

II. Programming Technologies

.Net. Course Content ASP.NET

Assumptions. History

This web service can be available to any user on the internet regardless of who developed it.

EEE-425 Programming Languages (2013) 1

COPYRIGHTED MATERIAL. Part I The C# Ecosystem. ChapTEr 1: The C# Environment. ChapTEr 2: Writing a First Program

12/14/2016. Errors. Debugging and Error Handling. Run-Time Errors. Debugging in C# Debugging in C# (continued)

UNIT I An overview of Programming models Programmers Perspective

Introduction to C# Applications Pearson Education, Inc. All rights reserved.

Language Specification

Department of Computer Applications

Chapter 2: Using Data

Objective of the Course: (Why the course?) Brief Course outline: (Main headings only) C# Question Bank Chapter1: Philosophy of.net

6.096 Introduction to C++ January (IAP) 2009

Program Fundamentals

Type Conversion. and. Statements

EXAMGOOD QUESTION & ANSWER. Accurate study guides High passing rate! Exam Good provides update free of charge in one year!

C # Language Specification

Microsoft..NET Framework. Overview

MCSA Universal Windows Platform. A Success Guide to Prepare- Programming in C# edusum.com

Microsoft Visual C# Step by Step. John Sharp

3. Java - Language Constructs I

C# Syllabus. MS.NET Framework Introduction

Memory Management: The Details

How to be a C# ninja in 10 easy steps. Benjamin Day

Creating and Running Your First C# Program

EEE-425 Programming Languages (2013) 1

Programming in C and C++

Chapter 6. Simple C# Programs

Operating Systems CMPSCI 377, Lec 2 Intro to C/C++ Prashant Shenoy University of Massachusetts Amherst

Expressions and Data Types CSC 121 Spring 2015 Howard Rosenthal

CS 330 Lecture 18. Symbol table. C scope rules. Declarations. Chapter 5 Louden Outline

Modern Programming Languages. Lecture Java Programming Language. An Introduction

Object Oriented Programming: In this course we began an introduction to programming from an object-oriented approach.

Java: framework overview and in-the-small features

Microsoft. Microsoft Visual C# Step by Step. John Sharp

Crash Course in Java. Why Java? Java notes for C++ programmers. Network Programming in Java is very different than in C/C++

VISUAL PROGRAMMING_IT0309 Semester Number 05. G.Sujatha & R.Vijayalakshmi Assistant professor(o.g) SRM University, Kattankulathur

B.E /B.TECH DEGREE EXAMINATIONS,

PESIT- Bangalore South Campus Hosur Road (1km Before Electronic city) Bangalore

CSC 1214: Object-Oriented Programming

Understand Computer Storage and Data Types

NOIDATUT E Leaning Platform

UNIT I INTRODUCTION TO C#

Very similar to Java C++ C-Based syntax (if, while, ) object base class no pointers, object parameters are references All code in classes

Java language. Part 1. Java fundamentals. Yevhen Berkunskyi, NUoS

COPYRIGHTED MATERIAL. Contents. Part I: C# Fundamentals 1. Chapter 1: The.NET Framework 3. Chapter 2: Getting Started with Visual Studio

STUDY NOTES UNIT 1 - INTRODUCTION TO OBJECT ORIENTED PROGRAMMING

University of West Bohemia in Pilsen. Faculty of Applied Sciences. Department of Computer Science and Engineering DIPLOMA THESIS

Tokens, Expressions and Control Structures

CSC Java Programming, Fall Java Data Types and Control Constructs

Learning to Program in Visual Basic 2005 Table of Contents

Control Abstraction. Hwansoo Han

Computer Components. Software{ User Programs. Operating System. Hardware

Variables. Data Types.

EMBEDDED SYSTEMS PROGRAMMING Language Basics

Prerequisites: The student should have programming experience in a high-level language. ITCourseware, LLC Page 1. Object-Oriented Programming in C#

Outline. Java Models for variables Types and type checking, type safety Interpretation vs. compilation. Reasoning about code. CSCI 2600 Spring

Application Architecture Using Generics C#.Net 2.0

Assignment Operations

PESIT Bangalore South Campus Hosur road, 1km before Electronic City, Bengaluru -100 Department of Computer Science And Engineering

Run-time Program Management. Hwansoo Han

Expressions and Data Types CSC 121 Fall 2015 Howard Rosenthal

Transcription:

, 1 C#.Net VT 2009 Course Contents C# 6 hp approx. BizTalk 1,5 hp approx. No exam, but laborations Course contents Architecture Visual Studio Syntax Classes Forms Class Libraries Inheritance Other C# essentials XML+ intro BizTalk BizTalk Seminars

, 2 Contact Thijs Holleboom 21F411 Thijs.Holleboom@kau.se 054-700 1148 Inger Bran 21E414 Inger.Bran@kau.se 054-700 1970 Per Hurtig 21F422 Per.Hurtig@kau.se 054-700 2335 Programming All programming is the same sequence iteration selection Manipulating computers Level of abstraction differs assembler, c, c++, java, c#, lisp, prolog, sql Expressiveness varies Some languages can do more If you know programming you can use any language (almost) Programming Programming Language Nifty Stuff Abstraction Pre-done stuff Sequence Iteration Selection Memory op s Calculations Computer

, 3 Programming Difficult Full control Easy Less control C++ Java C# C Byte Code CIL Assembler Assembler Virtual Machine CLR Machine code Hardware (computer and peripherals) Structure of.net technology Another visualisation of.net

, 4 Important concepts FCL Common class library CTS Common type system CLR The environment everything builds upon. The motor i a.net application. From code to program Common Language Runtime (CLR) Is essentially an implementation of the CLI Common Language Infrastructure Other implementations exist, e.g. the Mono runtime Responsible for almost everything Uses only OS for threads and bulk memory management

, 5 CLR JIT just in time-compiler Compiles code late Garbage Collector automatic memory handling You don't have to deallocate memory, it is handled by the garbage collector In C/C++ you have to take care of your own garbage, in C# you don't CLR Common Type System (CTS) All languages in the.net family are basically the same, except for the syntax You can include code written in one language into a program written in another Exception handler When something goes wrong, the exception handler comes into play. Common Intermediate Language (CIL) All.NET languages compile to CIL, which basically is advanced assembler. The JIT compiles parts of the CIL to native object code, when that part of the CIL is needed. Before JIT Stub code CIL After JIT Object code

, 6 CIL Is a strongly typed, verbose, assembler language stack-based generic low-level easy to compile has more features than are used by any existing supported language tail recursion (used in functional languages like LISP) CIL Example.assembly HelloWorld{}.method public hidebysig static void Main() cil managed {.entrypoint ldstr "Hello World!" call void [mscorlib]system.console::writeline(string) ret } Garbage Collection Allocation is fast, simple list of used memory instead of linked list Works well with cache memory Your code is smaller, simpler, and more reliable But in a sense uglier

, 7 Garbage collection You never have memory leaks But your program is almost always too big Old stuff lying around Watch out when switching to a language without GC or your program will leak alloc/free in C new/delete in C++ Garbage Collection You may be thinking that it doesn't matter how garbage collection can help you if it means your program might lock up for several seconds anytime it gets asked to do something. And you'd be right -that didsuck, back in the '70's and '80's on Lisp machines and such. Thus, garbage collection is nowadays a very fast process Common Type System (CTS) All.Net languages understand each other's data types All use the same primitives Classes from different languages can inherit from each other Value types scalars, such as integers records (eg. structs) and objects(!)

, 8 CTS Same base classes (highest level) All.Net languages highest objects can be cast to any other. Interfaces are supported like in Java Can do instead of Is-a represented by inheritance CTS All objects inherit via single inheritance from a top-most object Multiple inheritance is not supported Good(?) multiple inheritance is complex multiple inheritance is seldom needed interfaces are better Object Leaving.NET So far, the lesson has covered theoretical aspects of the.net architecture Only a few things of what we covered have practical implications Garbage collector The possibility to interact between.net languages The rest of this lecture will be more practical!

, 9 Namespaces We start with namespaces! Divided into layers hierarchically divided by period, like System.IO Code in different files can belong to the same namespace Use is optional Except for components Helps avoid name clashes Namespaces using removes need to type full namespace name using System; makes it possible to for instance access Console.WriteLine(); without spelling out System.Console.WriteLine(); Namespaces namespace x.y { class Slask { } } // is shorthand for writing namespace x { } namespace y { class Slask { } } If one wants to use class Slask from another namespace the namespace must be addressed Either: using x.y; Slask s=new Slask(); or: x.y.slask s=new x.y.slask();

, 10 Boxing Enables conversion from value type to reference type Unboxing does the reverse, converting from reference box to value type Boxing implies making a copy of the value int i = 123; object box = i; if(box is int) // box contains an int int y = (int) box; // y contains int value // contained in box Keywords abstract as base bool break byte case catch char checked class const continue decimal default delegate do double else enum event explicit extern false finally fixed float for foreach goto if implicit in int interface internal is lock long namespace new null object operator out override params private protected public readonly ref return sbyte sealed short sizeof stackalloc static string struct switch this throw true try typeof uint ulong unchecked unsafe ushort using virtual void volatile while Visual Studio Graphical environment (IDE) for developing.net-applications Microsoft Syntax highlighting Code completion GUI designer drag n drop, very easy to use, supernice Easy handling of events

, 11 Visual Studio competitors.net is standardized C# is also standardized Other compilers and environments exist e.g. Mono for Linux Visual Studio (cont d) VS starting a new project

, 12 VS starting (cont d) VS editing VS handling events

, 13 VS connecting stuff VS -finito