CST 205 Object Oriented Programming using Java
CST 281 Object Oriented Programming
(As per KTU 2019 Syllabus)
Module 1, Lecture 1
Module 1 Lecture
1
► Approaches to Software Design. Functional Oriented Design, Object
Oriented Design, Case Study of Automated Fire Alarm System
► Object Modeling Using Unified Modeling Language. Basic Object Oriented
concepts, UML diagrams, Use case model, Class diagram, Interaction diagram,
Activity diagram, State chart diagram
► Introduction to Java Java programming. Environment and Runtime
Environment, Development Platforms - Standard, Enterprise. Java Virtual
Machine, Java compiler, Bytecode, Java applet Java Buzzwords, Java program
structure, Comments, Garbage Collection, Lexical Issues
What is software?
● Software is a set of instructions, data or programs used
to operate computers and execute specific tasks
● Software is a set of instructions that tell a computer what
to do.
● Without software, most computers would be useless. For
example, without your Internet browser software, you
could not surf the Internet. Without an operating system,
you cannot even login to your system.
● The term was coined to differentiate these instructions
from hardware.
● By the term software, we referring to all variants such as
Middleware, O.S, Firmware etc.
Types of software
There are two types of software
1. System Software
2. Application Software
● Examples of system software are Operating System, Compilers, Interpreter,
Assemblers, etc.
● Examples of Application software are Railways Reservation Software, Microsoft
Office Suite Software, Microsoft Word, etc.
Software Design
Software design is a process to transform user
requirements into some suitable form, which helps the
programmer in software coding and implementation.
Software design is the process by which an agent creates
a specification of a software artifact, intended to
accomplish goals, using a set of primitive components and
subject to constraints.
Software Design
The design process for software systems often has two levels. At the first level the
focus is on deciding which modules are needed for the system on the basis of
SRS (Software Requirement Specification) and how the modules should be
interconnected.
It tries to specify how to fulfill the requirements mentioned in SRS document.
Approaches to Software Design
There are two generic software development approaches.
Function Oriented Design (FOD)
● FOD is an approach to software design where
the design is decomposed into a set of
interacting units where each unit has a clearly
defined function.
● This design mechanism divides the whole
system into smaller functions
● Starting at this high level view of the system,
each function is successively refined into more
detailed functions
● The system state is centralized and shared
among different functions
● Top down approach
Global variables
Function Oriented Design (FOD)
● At first FOD views a system as a black-box that provides a
set of services to the users of the software.
● These services provided by a software to its users are also
known as the high-level functions supported by the
software.
● During the design process, these high-level functions are
successively decomposed into more detailed functions.
● The term top-down decomposition is often used to denote
the successive decomposition of a set of high-level
functions into more detailed functions.
Functional Oriented Design (FOD)
These functional modules can share information among
themselves by means of information passing and using
information available globally.
Eg: Banking process
Here withdraw, deposit, transfer are functions and that
can be divided into subfunctions again.
So, in FOD, the entire problem is divided in to number of
functions and those functions are broken down into smaller
functions and these smaller functions are converted in to
software modules.
Object Oriented Design (OOD)
● OOD is based on Objects and interaction between the
objects. Interaction between objects is called message
communication.
● In the object-oriented design approach, the system is viewed
as a collection of objects (i.e. entities).
● It involves the designing of objects, classes and the
relationship between the classes
● The state is decentralized among the objects and
each object manages its own state information.
● OOD follows bottom up approach
Consider the example of Banking process.
● Here, customer, money and account are objects
Object Oriented Design (OOD)
For example, in banking example,each customer may be a separate object with its
own data and functions to operate on these data.
Functions defined for one object cannot refer or change data of other objects.
Objects have their own internal data which define their state.
Similar objects constitute a class. In other words, each object is an instance of
some class.
Classes may inherit features from super class. Conceptually, objects
communicate by message passing.
FOD vs OOD
Case study: Automated fire alarm
The owner of a large multi-storied building wants to have a computerized fire alarm
system for his building. Smoke detectors and fire alarms would be placed in each
room of the building. The fire alarm system would monitor the status of these
smoke detectors. Whenever a fire condition is reported by any of the smoke
detectors, the fire alarm system should determine the location at which the fire
condition is reported by any of the smoke detectors, the fire alarm system should
determine the location at which the fire condition has occurred and then sound the
alarms only in the neighboring locations. The fire alarm system should also flash
an alarm message on the computer console. Fire fighting personnel, man the
console round the clock. After a fire condition has been successfully handled, the
fire alarm system should support resetting the alarms by the fire fighting personnel.
FOD: Automated fire alarm
OOD: Automated fire alarm
END OF LECTURE 1
References
● Rajib Mall, Fundamentals of Software Engineering, 4th edition, PHI, 2014.
● GeeksforGeeks - www.geeksforgeeks.org
● Wikipedia - www.wikipedia.org
● Tutorialspoint - www.tutorialspoint.com
● Disclaimer - This document contains images/texts from various internet
sources. Copyright belongs to the respective content creators. Document is
compiled exclusively for study purpose and shall not be used for commercial
purpose.

Lecture1 cst205 cst281-oop

  • 1.
    CST 205 ObjectOriented Programming using Java CST 281 Object Oriented Programming (As per KTU 2019 Syllabus) Module 1, Lecture 1
  • 2.
    Module 1 Lecture 1 ►Approaches to Software Design. Functional Oriented Design, Object Oriented Design, Case Study of Automated Fire Alarm System ► Object Modeling Using Unified Modeling Language. Basic Object Oriented concepts, UML diagrams, Use case model, Class diagram, Interaction diagram, Activity diagram, State chart diagram ► Introduction to Java Java programming. Environment and Runtime Environment, Development Platforms - Standard, Enterprise. Java Virtual Machine, Java compiler, Bytecode, Java applet Java Buzzwords, Java program structure, Comments, Garbage Collection, Lexical Issues
  • 3.
    What is software? ●Software is a set of instructions, data or programs used to operate computers and execute specific tasks ● Software is a set of instructions that tell a computer what to do. ● Without software, most computers would be useless. For example, without your Internet browser software, you could not surf the Internet. Without an operating system, you cannot even login to your system. ● The term was coined to differentiate these instructions from hardware. ● By the term software, we referring to all variants such as Middleware, O.S, Firmware etc.
  • 4.
    Types of software Thereare two types of software 1. System Software 2. Application Software ● Examples of system software are Operating System, Compilers, Interpreter, Assemblers, etc. ● Examples of Application software are Railways Reservation Software, Microsoft Office Suite Software, Microsoft Word, etc.
  • 5.
    Software Design Software designis a process to transform user requirements into some suitable form, which helps the programmer in software coding and implementation. Software design is the process by which an agent creates a specification of a software artifact, intended to accomplish goals, using a set of primitive components and subject to constraints.
  • 6.
    Software Design The designprocess for software systems often has two levels. At the first level the focus is on deciding which modules are needed for the system on the basis of SRS (Software Requirement Specification) and how the modules should be interconnected. It tries to specify how to fulfill the requirements mentioned in SRS document.
  • 7.
    Approaches to SoftwareDesign There are two generic software development approaches.
  • 8.
    Function Oriented Design(FOD) ● FOD is an approach to software design where the design is decomposed into a set of interacting units where each unit has a clearly defined function. ● This design mechanism divides the whole system into smaller functions ● Starting at this high level view of the system, each function is successively refined into more detailed functions ● The system state is centralized and shared among different functions ● Top down approach Global variables
  • 9.
    Function Oriented Design(FOD) ● At first FOD views a system as a black-box that provides a set of services to the users of the software. ● These services provided by a software to its users are also known as the high-level functions supported by the software. ● During the design process, these high-level functions are successively decomposed into more detailed functions. ● The term top-down decomposition is often used to denote the successive decomposition of a set of high-level functions into more detailed functions.
  • 10.
    Functional Oriented Design(FOD) These functional modules can share information among themselves by means of information passing and using information available globally. Eg: Banking process Here withdraw, deposit, transfer are functions and that can be divided into subfunctions again. So, in FOD, the entire problem is divided in to number of functions and those functions are broken down into smaller functions and these smaller functions are converted in to software modules.
  • 11.
    Object Oriented Design(OOD) ● OOD is based on Objects and interaction between the objects. Interaction between objects is called message communication. ● In the object-oriented design approach, the system is viewed as a collection of objects (i.e. entities). ● It involves the designing of objects, classes and the relationship between the classes ● The state is decentralized among the objects and each object manages its own state information. ● OOD follows bottom up approach Consider the example of Banking process. ● Here, customer, money and account are objects
  • 12.
    Object Oriented Design(OOD) For example, in banking example,each customer may be a separate object with its own data and functions to operate on these data. Functions defined for one object cannot refer or change data of other objects. Objects have their own internal data which define their state. Similar objects constitute a class. In other words, each object is an instance of some class. Classes may inherit features from super class. Conceptually, objects communicate by message passing.
  • 13.
  • 14.
    Case study: Automatedfire alarm The owner of a large multi-storied building wants to have a computerized fire alarm system for his building. Smoke detectors and fire alarms would be placed in each room of the building. The fire alarm system would monitor the status of these smoke detectors. Whenever a fire condition is reported by any of the smoke detectors, the fire alarm system should determine the location at which the fire condition is reported by any of the smoke detectors, the fire alarm system should determine the location at which the fire condition has occurred and then sound the alarms only in the neighboring locations. The fire alarm system should also flash an alarm message on the computer console. Fire fighting personnel, man the console round the clock. After a fire condition has been successfully handled, the fire alarm system should support resetting the alarms by the fire fighting personnel.
  • 15.
  • 16.
    OOD: Automated firealarm END OF LECTURE 1
  • 17.
    References ● Rajib Mall,Fundamentals of Software Engineering, 4th edition, PHI, 2014. ● GeeksforGeeks - www.geeksforgeeks.org ● Wikipedia - www.wikipedia.org ● Tutorialspoint - www.tutorialspoint.com ● Disclaimer - This document contains images/texts from various internet sources. Copyright belongs to the respective content creators. Document is compiled exclusively for study purpose and shall not be used for commercial purpose.