Course Description

Object-Oriented Programming in C#
Course UCSPR2: 5 days; Instructor-Led

Learning Goals

The aim of this course is to study in-depth the C# language syntax and object-oriented programming elements in .NET

Target Audience

We target experienced programmers who want to learn to program in C# using Visual Studio 2008/2010.

Prerequisites

Participants should be professional programmers.

Course Outline

Overview of the Microsoft .NET Platform

Introducing Microsoft .NET as a set of software technologies offering us a service-oriented platform on which enterprise applications can run.
What is a .NET Application at design-time and at run-time.
The Common Language Runtime and .NET Class Libraries.
The Intermediate Language.

.NET Skeleton Application

The Visual Studio solution and project.
The Main function.
The compilation process.
Statements, Comments and Documentation in .NET.

Objects in .NET

The term "Object".
State, Behavior, Identity of an object.
Example of objects in .NET.
Constructing an object with the new-operator.
Using the services of an object.
Object as instance of a class.
String objects.
Numerical objects.
Class acting as object.

Introduction to Classes in .NET

Class as type, factory, utility object.
Classes in the .NET Framework: String, Convert, Form, Button...
Creating simple Windows apps.

Referring to Objects

Definition of a .NET reference.
References in code examples.
Strong and Loose typing.
Referring to an object.
Initialization of references.
Using references.
Garbage collection.

Creating Classes in .NET

Anatomy of a class.
Creating a class with Visual Studio wizards.
Data members: fields and properties.
Identifiers.
Access modifiers.
Methods.
Assemblies.
Automatically implemented properties.
References to assemblies.
Name spaces.
Overloading functions.
Creating a simple Windows Form.

Types in .NET

Three kinds of types in .NET.
Unified type system.
Reference type variables.
Value type variables.
Pointer type variables (C# only).
The struct(ure) as .NET value type.
Basic types.
Examples of structs in the .NET Framework.
The enumerated type.
The String and StringBuilder classes.
Arguments of functions. Pass by value, by ref; Passing output.
Boxing and Unboxing.
Nullable types: Nullable conversions and lifted conversions.
Lifted operators.
Null propagating.
Null coalescing operator.
Local variable inference and implicitly typed local variables.
Using object and collection initializers.
Anonymous types.

Instance Constructors

Instance Constructors.
The default constructor.
Examples of constructors in the .NET Framework.
Variable initializers.
Constructor initializers.
Overloading constructors.
Finalizers.
Managed and unmanaged code.
The IDispose interface.
Examples of the IDispose pattern in Windows Forms.

Static Members and Static Classes

Static or Shared Members.
Definition of a static or shared member.
Accessing non-static and accessing static members.
Static or Shared Constructors.
Examples in the .NET Framework.
Static Classes.

Extending Classes

General principle of inheritance.
Inheritance syntax.
Accesibility levels, public, private, protected.
Object class.
The is-operator and the TypeOf/Is operator.
Casting.
Partial Implementation: Partial Types and Partial Methods.
Using Extension Methods.
Examples in .NET Windows Forms, ASP.NET Web Pages.

Exception Handling

The exception-mechanism in .NET.
Exceptions and the stack.
The fault handler: the try-catch block.
The Type-Filtered handler.
The Exception base class and the hierarchy of Exception-classes.
Multiple exception handlers.
The finally-block.
Throwing exceptions.
User-defined exceptions.

Operator overloading

The Operator behavior.
Arithmetic operator overloading.
Overloadable operators.
Implicit and explicit operator overloading.
Conversion operators.

Inheritance and Polymorphism

Weak typing versus Strong typing (Option Strict On/Off).
Types of polymorphism: Interface polymorfphism, Ad-hoc polymorphism, Inheritance polymorphism.
“Virtual” or “Overridable” methods and properties.
Hiding or Shadowing methods.
Calling the base method.
The Object class.
Overriding theToString, Equals and GetHashCode method.
Constructors with inheritance.
Sealed or NotInheritable classes.
Examples of polymorphism in the .NET Framework.

Interfaces

Abstract classes.
Concrete subclass of an abstract class.
Defining interfaces.
Implementation of an interface.
Implementing multiple interfaces.
Inheritance and interfaces.
Base list with class and interfaces.
Interfaces with properties.
Private implementation.
Examples of abstract classes, interfaces and classes in the .NET Framework that implement an interface.
Standard .NET Interfaces: IComparable, IEquatable, ICloneable…

Collections

Arrays, Lists, and Maps in .NET.
The array syntax.
The ArrayList class.
The Hashtable class.
Indexers and default properties.
Examples of collections in Windows Forms: Control.Controls collection, ListBox.Items...
Introducing the ADO.NET DataSet.
Exposing enumerable collections by means of Iterators.
The For Each keyword.
Implementing the IEnumerable and IEnumerator interfaces.
Creating Enumerator class/struct.

Generics

Generics allowing classes, structs, interfaces, and methods to be parameterized.
Type parameters.
Generic class declarations and generic struct declarations.
Generic interface declarations.
Generic algorithms and generic methods.

Delegates

The delegate object.
The delegate class.
The delegate reference.
Combining delegate objects.
SingleCast and MultiCast Delegates.
Defining a Delegate class.
Implementing a method with a delegate.
Delegates representing static or shared methods.
Examples in .NET: Timers and CallBacks.
Anonymous methods for passing a code block as a parameter.
Passing parameters to anonymous methods.

Events

Introducing Events and event handling mechanism.
Defining and Raising an event.
Defining an event handler in the client class.
Example of the Click event handler in Windows Forms.
Linking the event handlers to the events.
Testing the event handling mechanism.
WithEvents and Handles keywords (VB.NET only).
The Guidelines Compliant EventHandler.
The Event Argument Class. Event Accessors.
The difference between Delegates and Events.
Adding a Protected Virtual Event Raiser.
Examples of Events in the .NET Framework.
Example: Responding to the MouseMove event in two ways: using an event handler and overriding the OnMouseMove.

Creating Assemblies and Web Services

Internal structure of an assembly.
Using Visual Studio to create an assembly.
Using an assembly in a client application.
The Manifest.
Configuration and .config files.

CourseCourse Schedule Price DaysJulAugSepOctNovDec
Course
UCSPR2Object-Oriented Programming in C#1750 EUR 5 days26
6
18
15
20
Contact me Contact


Contact me Receive U2U Newsletter.
Looking for a challenging job Download Brochure On Site Training Looking for a challenging job
Calendar Dates Calendar Dates
Object-Oriented Programming in C#
 -  06-Sep-2010
 -  18-Oct-2010
 -  15-Nov-2010
 -  20-Dec-2010

Favorites Favorites
Copyright © 1999-2010 by U2U