SlideShare a Scribd company logo
1 of 12
Review of OOP …and Procedure-Oriented Programming
Getting in the right frame of mind In this presentation we will review the concepts of OOP and POP. If you were the owner of an ATM machine, which paradigm do you hope the machine designers used? OOP POP 2
POP vs. OOP ATM Machine POP Hmmm…How much should I withdraw? Direct access to pile of cash Src: Flickr.com
POP vs. OOP ATM Machine OOP 4 Hmmm…How much should I withdraw? Src: Flickr.com Access through interface of machine. Withdraw
Procedure-Oriented Programming Program Structure: Program is a main method along with a collection of methods that act on the data in the program. Data:is unprotected, available to all methods in the program. Program Design: POP Programs are linear:  program structure centered about a “main” control structure  Programs have a distinct begin and end. Program design focuses on the steps required to produce the desired outcome. 5
POP  Construction Identify the processes needed to get from Input to Output  Technique: Top down Design with Step-wise refinement use “Divide and Conquer” to break a large problem into cohesive subproblems and solve each separately Subproblems become methods that are “Called” Represent the program design using pseudocode technique or  Flowchart Write code from the design 6
Flowchart for POP Simple program  Joes’ auto shop 7/65
OO Programming Concepts With OOP we can present the world in a more natural way.  We describe ,[object Object]
a student, a loan, an ATM machine or motor vehicle can all be viewed as objects.
An object has a unique identity: its state, and behaviors.
The state of an object consists of a set of datafields (also known as properties) with their current values.
The behavior of an object is defined by a set of methods.8

More Related Content

Similar to OOP_POP

Object-OrientedProgrammingObject-Oriented Pr.docx
Object-OrientedProgrammingObject-Oriented Pr.docxObject-OrientedProgrammingObject-Oriented Pr.docx
Object-OrientedProgrammingObject-Oriented Pr.docxvannagoforth
 
SWE-401 - 6. Software Analysis and Design Tools
SWE-401 - 6. Software Analysis and Design ToolsSWE-401 - 6. Software Analysis and Design Tools
SWE-401 - 6. Software Analysis and Design Toolsghayour abbas
 
A Conceptual Model Of An Erp System Using Uml
A Conceptual Model Of An Erp System Using UmlA Conceptual Model Of An Erp System Using Uml
A Conceptual Model Of An Erp System Using UmlDeborah Gastineau
 
Unit1 jaava
Unit1 jaavaUnit1 jaava
Unit1 jaavamrecedu
 
Secrets of going codeless - How to build enterprise apps without coding
Secrets of going codeless - How to build enterprise apps without codingSecrets of going codeless - How to build enterprise apps without coding
Secrets of going codeless - How to build enterprise apps without codingNewton Day Uploads
 
тизер Clj engl
тизер Clj englтизер Clj engl
тизер Clj englmarina688292
 
Session 7 - Overview of the iOS7 app development architecture
Session 7 - Overview of the iOS7 app development architectureSession 7 - Overview of the iOS7 app development architecture
Session 7 - Overview of the iOS7 app development architectureVu Tran Lam
 
Lecture 1 uml with java implementation
Lecture 1 uml with java implementationLecture 1 uml with java implementation
Lecture 1 uml with java implementationthe_wumberlog
 
Software design.edited (1)
Software design.edited (1)Software design.edited (1)
Software design.edited (1)FarjanaAhmed3
 
Intro to C++ - Class 2 - Objects & Classes
Intro to C++ - Class 2 - Objects & ClassesIntro to C++ - Class 2 - Objects & Classes
Intro to C++ - Class 2 - Objects & ClassesBlue Elephant Consulting
 
Intro To C++ - Class 2 - An Introduction To C++
Intro To C++ - Class 2 - An Introduction To C++Intro To C++ - Class 2 - An Introduction To C++
Intro To C++ - Class 2 - An Introduction To C++Blue Elephant Consulting
 
Object Oriented Database
Object Oriented DatabaseObject Oriented Database
Object Oriented DatabaseMegan Espinoza
 
C++ [ principles of object oriented programming ]
C++ [ principles of object oriented programming ]C++ [ principles of object oriented programming ]
C++ [ principles of object oriented programming ]Rome468
 

Similar to OOP_POP (20)

Object-OrientedProgrammingObject-Oriented Pr.docx
Object-OrientedProgrammingObject-Oriented Pr.docxObject-OrientedProgrammingObject-Oriented Pr.docx
Object-OrientedProgrammingObject-Oriented Pr.docx
 
SWE-401 - 6. Software Analysis and Design Tools
SWE-401 - 6. Software Analysis and Design ToolsSWE-401 - 6. Software Analysis and Design Tools
SWE-401 - 6. Software Analysis and Design Tools
 
Intro To C++ - Class 14 - Midterm Review
Intro To C++ - Class 14 - Midterm ReviewIntro To C++ - Class 14 - Midterm Review
Intro To C++ - Class 14 - Midterm Review
 
Sdlc
SdlcSdlc
Sdlc
 
Sdlc
SdlcSdlc
Sdlc
 
A Conceptual Model Of An Erp System Using Uml
A Conceptual Model Of An Erp System Using UmlA Conceptual Model Of An Erp System Using Uml
A Conceptual Model Of An Erp System Using Uml
 
Unit1 jaava
Unit1 jaavaUnit1 jaava
Unit1 jaava
 
Secrets of going codeless - How to build enterprise apps without coding
Secrets of going codeless - How to build enterprise apps without codingSecrets of going codeless - How to build enterprise apps without coding
Secrets of going codeless - How to build enterprise apps without coding
 
тизер Clj engl
тизер Clj englтизер Clj engl
тизер Clj engl
 
Project report
Project report Project report
Project report
 
Session 7 - Overview of the iOS7 app development architecture
Session 7 - Overview of the iOS7 app development architectureSession 7 - Overview of the iOS7 app development architecture
Session 7 - Overview of the iOS7 app development architecture
 
Design patterns
Design patternsDesign patterns
Design patterns
 
Lecture 1 uml with java implementation
Lecture 1 uml with java implementationLecture 1 uml with java implementation
Lecture 1 uml with java implementation
 
Software design.edited (1)
Software design.edited (1)Software design.edited (1)
Software design.edited (1)
 
OOP ppt.pdf
OOP ppt.pdfOOP ppt.pdf
OOP ppt.pdf
 
Intro to C++ - Class 2 - Objects & Classes
Intro to C++ - Class 2 - Objects & ClassesIntro to C++ - Class 2 - Objects & Classes
Intro to C++ - Class 2 - Objects & Classes
 
Intro To C++ - Class 2 - An Introduction To C++
Intro To C++ - Class 2 - An Introduction To C++Intro To C++ - Class 2 - An Introduction To C++
Intro To C++ - Class 2 - An Introduction To C++
 
chapter-6-oops.pdf
chapter-6-oops.pdfchapter-6-oops.pdf
chapter-6-oops.pdf
 
Object Oriented Database
Object Oriented DatabaseObject Oriented Database
Object Oriented Database
 
C++ [ principles of object oriented programming ]
C++ [ principles of object oriented programming ]C++ [ principles of object oriented programming ]
C++ [ principles of object oriented programming ]
 

OOP_POP

  • 1. Review of OOP …and Procedure-Oriented Programming
  • 2. Getting in the right frame of mind In this presentation we will review the concepts of OOP and POP. If you were the owner of an ATM machine, which paradigm do you hope the machine designers used? OOP POP 2
  • 3. POP vs. OOP ATM Machine POP Hmmm…How much should I withdraw? Direct access to pile of cash Src: Flickr.com
  • 4. POP vs. OOP ATM Machine OOP 4 Hmmm…How much should I withdraw? Src: Flickr.com Access through interface of machine. Withdraw
  • 5. Procedure-Oriented Programming Program Structure: Program is a main method along with a collection of methods that act on the data in the program. Data:is unprotected, available to all methods in the program. Program Design: POP Programs are linear: program structure centered about a “main” control structure Programs have a distinct begin and end. Program design focuses on the steps required to produce the desired outcome. 5
  • 6. POP Construction Identify the processes needed to get from Input to Output Technique: Top down Design with Step-wise refinement use “Divide and Conquer” to break a large problem into cohesive subproblems and solve each separately Subproblems become methods that are “Called” Represent the program design using pseudocode technique or Flowchart Write code from the design 6
  • 7. Flowchart for POP Simple program Joes’ auto shop 7/65
  • 8.
  • 9. a student, a loan, an ATM machine or motor vehicle can all be viewed as objects.
  • 10. An object has a unique identity: its state, and behaviors.
  • 11. The state of an object consists of a set of datafields (also known as properties) with their current values.
  • 12. The behavior of an object is defined by a set of methods.8
  • 13. 9 Object-Oriented Programming Object Data (Fields)typically private to this object Michaelangelo Methods That Operate on the Data length() Code Outside the Object (client) charAt() Name(a String object)
  • 14. Object-Oriented Programming Program Structure: Program is a collection of objects that pass messages to each other. Data:is encapsulated in and protected by the object’s interface. Program Design: Two-dimensional model: program structure centered about objects that interact with one another No distinct begin/end, central control or path through the program. 10
  • 15. OOP Joe’s Auto Shop 11 Truck mechanic Parts and Supplies Auto mechanic Database of fees
  • 16. 12 What’s next….Classes and Objects Now how do we represent objects in Java code? Using a Class, of course