PROGRAMMING METHODOLOGIES
cod. 16433

Academic year 2010/11
2° year of course - First semester
Professor
Academic discipline
Informatica (INF/01)
Field
Discipline informatiche
Type of training activity
Characterising
48 hours
of face-to-face activities
6 credits
hub:
course unit
in - - -

Learning objectives

Object Oriented Programming is based on a few principles (encapsulation, inheritance, polymorphism, etc.) that years of experiences have shown to be fundamental for the design and development of clear, concise, reusable and
maintainable software. Tools and techniques that support an object oriented methodology are provided by most of the mainstream programming languages. The course will present the advanced characteristics of the C++ programming language, showing how these can be exploited to achieve the goals mentioned above.

Prerequisites

A working knowledge of the imperative fragment of the C++ language is assumed.

Course unit content

A summary of C++: data types; expressions; statements; functions; scope and life cycle; function overloading; classes.
Programming by contract: pre-conditions, post-conditions and class invariants.
Initialization, assignment and destruction.
Exceptions and resource management; dynamic memory management techniques.
Single inheritance: containment versus private inheritance versus public inheritance.
Dynamic polymorphism: virtual functions; the Liskov's substitution principle.
Design of software interfaces: concrete types, abstract types, interface classes and implementation classes; multiple and virtual inheritance.
Static polymorphism: function templates and class templates.
The Standard Template Library: containers, iterators and generic algorithms; function objects.
Development environment: the compiler g++; the debugger gdb; automating the software build process: make; version control: cvs and git.
Documentation of software interfaces: doxygen.

Full programme

- - -

Bibliography

B. Stroustrup.
The C++ Programming Language,
Third Edition or Special Edition, Addison-Wesley.

S. Lippman, J. Lajoie.
C++ Primer,
Third Edition, Addison-Wesley.

Teaching methods

Lectures and guided exercises.

Assessment methods and criteria

Written and oral exam.

Other information

- - -