Chapter 1: Introduction
To
Object-Oriented Programming

Concept & Terminologies

Object, Attribute, Behaviour

Objects - an instance or specific example of a class

Attributes - data value or a state that describes an object and helps you to tell one object from another of the same class

Behavior – operation or function that an object can perform

Classes & Objects

Class - A template or blueprint to create an object

Object - An instance of a class

Programming Techniques

Examples

Java

Javascript

Python

Javascript

C++

C#

Ruby

PHP

Perl

Swift

Types

Object-Oriented Approach
(OOA)

A process of defining the problem in terms of real-world objects with which the system must interact.

Tasks Include:

Identifying objects

Organizing the objects

Defining the object attributes

Defining the behaviour/ function of the objects

Describing how the objects interact

Object-Oriented Design
(OOD)

A process of defining the components, interfaces, objects, classes, attributes, and operations that will satisfy the requirements.

Tasks Inclue:

Restructuring the class data

Implementation of methods

Implementation of control

Implementation of associations

Object-Oriented
Approach & Design
(OOAD)

A combination of both OOA and OOD.

Advantages

Easy to understand

Easy to maintain

Provides re-usability

Reduced development time & cost

Improves the quality of the system due to program reuse

Disadvantages

Hard to determine all the necessary classes and objects required for a system

Most of our project development teams are familiar with traditional analysis & design

Does not lead to successful reuse on a large scale
without an explicit reuse procedure

Features

Data Abstraction - Refers to the concept of representing only the essential features of a data without including the non-essential details

Encapsulation - Refers to the mechanism of wrapping up of data and methods (that operate on the data) into a single unit (class)

Inheritance - Refers to the concept by which one class derives the properties of another class

Polymorphism - Refers to the ability of an object to take on many form. Eg: buttons on remote control

Unified Modelling Language
(UML)

Is a graphical language designed to capture the artifacts of an OOAD process.

Provides you with a way to create and document a model of a system.

Procedural
Programming

Examples

Fortran

ALGOL

COBOL

BASIC

Pascal

C

Defiinition:Procedural programming is a programming paradigm, derived from structured programming, based on the concept of the procedure call.