This course teaches object-oriented programming to those who have learnt basic programming concepts and are ready to learn in-depth programming. It focuses on object-oriented programming using C++. The main concepts discussed are: Objects, Data Abstraction, Data Encapsulation, Polymorphism, and Inheritance. We teach the C++ language constructs that are used to implement these concepts. For example, Classes, Overloaded Operators, Overridden Methods, Friend Functions, Virtual Functions, and Templates, etc.
COURSE LEARNING OUTCOMES (CLO)
CLO: 1. Describe key concepts of object-oriented programming paradigm [C1 Remembering]
CLO: 2. Interpret real world problems in terms of objects rather than procedure [C2 Understanding]
CLO: 3. Apply object-oriented programming principles to implement small and medium scale C++ programs with simple graphical user interface [C3 Applying]
- Overview of Structured Programming in C++
- Object-Oriented Concepts (Introduction to Classes and Objects) – Data Members and Member Functions – Constant Member Functions
- Use of Access Specifiers (public, private) – (Scope of class members) Constructor and Object Instantiation – Importance of Destructor
- Constructor Overloading (No-argument Constructor, Parameterized Constructor) – Introduction to copy constructors
- Shallow Copy and Deep Copy – Array as class data members (Initializing array with constructors) – Static and Dynamic Arrays, Array of Objects
- File handling: how to open and close a file, read from file and write in a file. (ifstream, ofstream, fstream)
- Introduction to single Public and Private Inheritance in OOP – Constructor and Destructor Chaining.
- Protected inheritance, Class Hierarchies (Multi-level Inheritance) – C++ Multiple InheritanceEntity-Relationship Modeling
- Function Overloading and Function Overriding – Object as argument to the Function – Pointer to Objects. Introduction to polymorphism.
- Pure Virtual Functions and Abstract Base Classes – Virtual Inheritance (The Diamond Problem and its Solution)
- Relationships in OOP – (Association, Aggregation, and Composition) – Life Cycle and Ownership of Objects
- Friend Functions-Friend classes
- Operator Overloading – (Unary and Binary Operator Overloading) – Assignment Operator Overloading (Difference between Assignment Operator and Copy Constructor) – Stream Insertion and Extraction Operator Overloading
- Function Templates – Class Template Specialization, Standard Template Libraries