SlideShare a Scribd company logo
1
Module 1: Introduction to OOAD
(Object-Oriented Analysis and Design)
2
Objectives
 Why OO?
 What is OOAD?
 How to do OOAD?
3
Why Object-Oriented?
4
What is Object-Orientation?
- What is Object?
 An "object" is anything to which a concept applies, in our awareness
 Things drawn from the problem domain or solution space.
 E.g., a living person in the problem domain, a software component in the solution space.
 A structure that has identity and properties and behavior
 It is an instance of a collective concept, i.e., a class.
5
Encapsulation
a.k.a. information hiding
Objects encapsulate:
property
behavior as a collection of methods invoked by
messages
…state as a collection of instance variables
Abstraction
Focus on the essential
Omits tremendous amount of details
…Focus on what an object “is and does”
What is Object-Orientation
- Abstraction and Encapsulation
6
What is Object-Orientation
- Another Example of Abstraction and Encapsulation
Class Car
Attributes
 Model
 Location
 #Wheels = 4
Operations
 Start
 Accelerate
<<instanceOf>>
<<instanceOf>>
<<instanceOf>>
What is generalization?
What is over-generalization??
Forall x [Car(x) -> …]
7
What is Object-Orientation?
- Class
 What is CLASS?
 a collection of objects that share common properties, attributes, behavior and
semantics, in general. What are all these???
 A collection of objects with the same data structure (attributes, state variables)
and behavior (function/code/operations) in the solution space.
 Classification
 Grouping of common objects into a class
 Instantiation.
 The act of creating an instance.
Class Car
Attributes
 Model
 Location
 #Wheels = 4
Operations
 Start
 Accelerate
<<instanceOf>>
<<instanceOf>>
<<instanceOf>>
8
What is Object-Orientation
- Subclass vs. Superclass
• Specialization: The act of defining one class as a refinement of another.
• Subclass: A class defined in terms of a specialization of a superclass
using inheritance.
• Superclass: A class serving as a base for inheritance in a class hierarchy
• Inheritance: Automatic duplication of superclass attribute and behavior
definitions in subclass.
multiple inheritance?
Person
name
SSN
Student
std-id
level
Employee
emp-id
age
9
What is Object-Orientation
- Subclass vs. Superclass
A
B
C
A
B
A
B
C
A
B
c: C
A
B
c: C
<<instanceOf>> <<instanceOf>>
A
B
<<instanceOf>>
A
B
<<instanceOf>>
10
What is Object-Orientation
- Polymorphism
Objects of different classes respond to the same message differently.
payTuition
Person
name
SSN
Student
std-id
level
Employee
emp-id
In-State
Student
state
payTuition payTuition
Out-of-State
Student
payTuition
11
What is Object-Orientation
- Interfaces
• Information hiding - all data should be hidden within a class, at least in principle.
• make all data attributes private
• provide public methods to get and set the data values (cf. Java design patterns)
• e.g. Grade information is usually confidential, hence it should be kept
private to the student. Access to the grade information should be
done through interfaces, such as setGrade and getGrade
payTuition
setGrade()
getGrade()
Student
std-id
level
getGrade
setGrade
grade
12
What is Object-Orientation
- Abstract Class vs. Concrete Class
 Abstract Class.
 An incomplete superclass that defines common parts.
 Not instantiated.
 Concrete class.
 Is a complete class.
 Describes a concept completely.
 Is intended to be instantiated.
Work out an example!
13
What is Object-Orientation?
-State
 What is STATE?
"State" is a collection of association an object has with other objects and object types.
 What is STATE CHANGE?
A "state change" is the transition of an object from one state to another.
 What is EVENT?
An "event" is a noteworthy change in state [Rumbaugh]
Work out an example!
14
What is Object-Orientation?
-State transition impossible?
tom: Actor
name = “Tom Cruise”
katie: Actor
name = “Katie Holmes”
tom: Actor
name = “Tom Holmes”
katie: Actor
name = “Katie Holmes”
married/changeLastName
tom: Actor
name = “Tom Holmes”
katie: Actor
name = “Katie Holmes”
suri: BabyActor
name = “Suri Holmes”
newArrival/getName
15
What is Object-Oriented Application?
• Collection of discrete objects, interacting w. each other
• Objects have property and behavior (causing state transition)
• Interactions through message passing
(A sender object sends a request (message) to another object (receiver)
to invoke a method of the receiver object’s)
Fn
Data
O1
Fn
Data
O2
Fn
Data
O3
m1
m2
m3
{m in Fn}
16
What is OOAD?
 Analysis — understanding, finding and describing concepts in
the problem domain.
 Design — understanding and defining software
solution/objects that represent the analysis concepts and will
eventually be implemented in code.
 OOAD — Analysis is object-oriented and design is object-
oriented. A software development approach that emphasizes a
logical solution based on objects.
Traceability!
Involves both a notation and a process
17
How to do OOAD
- notation vs. process
 UML is a notation.
 So are English,
Elvish, Ku, …
 But as yet I can’t
18
Systems Engineering
Requirements Analysis
Project Planning
Architectural Design
Detailed Design
Implementation
Release
Maintenance
Quality
Assurance
Software Lifecycle
How to Do OOAD
– Where to Use OO? Traceability!
Something missing?
What’s yours like?
19
Traceability!
Artificial problem
Accidental design
20
Specifications are important too
21
How to Do OOAD
– OMT as Object-Oriented Methodology
OMT (Object Modeling Technique) by James Rumbaugh
Object Model: describes the static
structure of the objects in the system and
their relationships -> Object Diagrams.
Dynamic Model: describes the
interactions among objects in the
system -> State Diagrams.
Functional Model: describes the data
transformation of the system
-> DataFlow Diagrams.
Traceability!
22
Analysis:
i) Model the real world showing its important
properties;
ii) Concise model of what the system will do
System Design:
Organize into subsystems based on analysis
structure and propose architecture
Object Design: Based on analysis
model but with implementation details;
Focus on data structures and
algorithms to implement each class;
Computer and domain objects
Implementation: Translate the object
classes and relationships into a
programming language
How to Do OOAD
– OMT as Object-Oriented Methodology
OMT (Object Modeling Technique) by James Rumbaugh
Traceability!
23
A Unified Language + A Good Process
+ A Good Goal, perhaps
24
How to Do OOAD
- Historical Perspective
OO Prog. Languages
(Smalltalk, C++)
just program!
OO Design
(Booch) design then
program
OO Analysis
(Rumbaugh, Jacobson)
Process Perspective
OO Technology
Analyze (use case) first,
then design,
T then program
Where are we heading?
25
How to Do OOAD
– One Good Way: Use (OO) Design Patterns
Reusable solutions to typical problems.
“Each design pattern systematically names, explains, and evaluates an
important and recurring design in object-oriented systems.” [Gamma]
 Name — identifies a particular pattern, creating a vocabulary.
 Problem — identifies context when pattern should be applied.
 Solution — an abstract description of a design problem along with a template
object design that solves the problem.
 Consequences — results and trade-offs of applying the pattern.
26
Knowledge
Representation (in A.I.)
Psychological Validity
Philosophical Validity
Computational Validity
Databases
Emphasis in Persistent Data
(and now ACID properties)
RelationalDB
Network DB
Hierarchical DB
OODB
Programming Languages
Emphasis in Efficiency
Simula, SmallTalk, C++, Protel,
Java
ERD
SDM
CM
ADT
ERD: Entity Relationship Diagram
SDM: Semantic Data Model
ADT: Abstract Data Type
CM: Conceptual Model
Why Object-Oriented
- Who’s Behind Object-Orientation w. Diff. Concerns
System/Software
Engineering
Where does Unified Modeling Language come into this?
27
Why Object-Oriented
– A New Paradigm with Evolving Object Orientation
 OOP: Object-Oriented Programming
 Simula (1967), Smalltalk (70’s), C++ (mid 80’s), Eiffel, Ada95,
Turing, …
 OOD: Object-Oriented Design
 Taxis (1976), Adaplex, …, Grady Booch (1980)
 OOA: Object-Oriented Requirements
 RML (1981), James Rumbaugh (late 80’s)
 OO-Databases (OODBs): 1980-90’s
 OLE/DCOM, VisualBasic, CORBA, Java: mid 90’s
 .Net, C#, (eb/voice…/-)XML, J2EE: into 2000+
 UML: mid 90’s and still evolving
28
Introduction to OOAD - Points to Ponder
1. How do you think your mental image is represented?
2. What kinds of languages are used for what purpose in our daily life?
3. What are the differences among a concept, a model and a language?
4. What are the differences between a language and a methodology?
5. Can we use C# for analysis?
6. If C++ is a language, does it model anything? If so, what?
7. What does a concept in C++ refer to (i.e., semantics)?
8. What does a concept in a (OO) design refer to?
9. What does a concept in an (OO requirements) analysis refer to?
10. Is the current OOAD for Functional Analysis and Design, or Non-
Functional Analysis and Design?
11. What is the relationship between OO (Object-Orientation) and GO
(Goal-Orientation), between OO and AO (Agent-Orientation), and
between GO and AO?
12. Can you prove you and I communicate with each other perfectly?

More Related Content

Similar to M01_OO_Intro.ppt

ooadunitiintroduction-150730050129-lva1-app6892.pptx
ooadunitiintroduction-150730050129-lva1-app6892.pptxooadunitiintroduction-150730050129-lva1-app6892.pptx
ooadunitiintroduction-150730050129-lva1-app6892.pptx
ubaidullah75790
 
Object-Oriented Analysis and Design
Object-Oriented Analysis and DesignObject-Oriented Analysis and Design
Object-Oriented Analysis and Design
RiazAhmad786
 
Introduction to Object Oriented Programming
Introduction to Object Oriented ProgrammingIntroduction to Object Oriented Programming
Introduction to Object Oriented Programming
Moutaz Haddara
 
introduction of Object oriented programming
introduction of Object oriented programmingintroduction of Object oriented programming
introduction of Object oriented programming
RiturajJain8
 
Introduction to object oriented programming
Introduction to object oriented programmingIntroduction to object oriented programming
Introduction to object oriented programmingAbzetdin Adamov
 
OOP programming
OOP programmingOOP programming
OOP programminganhdbh
 
Introduction of object oriented analysis &amp; design by sarmad baloch
Introduction of object oriented analysis &amp; design by sarmad balochIntroduction of object oriented analysis &amp; design by sarmad baloch
Introduction of object oriented analysis &amp; design by sarmad baloch
Sarmad Baloch
 
MIT302 Lesson 2_Advanced Database Systems.pptx
MIT302 Lesson 2_Advanced Database Systems.pptxMIT302 Lesson 2_Advanced Database Systems.pptx
MIT302 Lesson 2_Advanced Database Systems.pptx
elsagalgao
 
01 introduction
01 introduction01 introduction
01 introduction
Baskarkncet
 
M01_OO_Intro.ppt
M01_OO_Intro.pptM01_OO_Intro.ppt
M01_OO_Intro.ppt
RAJESH S
 
Unit-1 OOAD Introduction.pptx
Unit-1 OOAD Introduction.pptxUnit-1 OOAD Introduction.pptx
Unit-1 OOAD Introduction.pptx
Ravindranath67
 
Cs 2352 object oriented analysis and design
Cs 2352 object oriented analysis and designCs 2352 object oriented analysis and design
Cs 2352 object oriented analysis and design
andrewsasi
 
Unit 1( modelling concepts & class modeling)
Unit  1( modelling concepts & class modeling)Unit  1( modelling concepts & class modeling)
Unit 1( modelling concepts & class modeling)
Manoj Reddy
 
Assignment 1 SYD601 2012 rick_danby completed with audio
Assignment 1 SYD601 2012 rick_danby completed with audioAssignment 1 SYD601 2012 rick_danby completed with audio
Assignment 1 SYD601 2012 rick_danby completed with audio
RickNZ
 
Oot
OotOot
OOSD1-unit1_1_16_09.pptx
OOSD1-unit1_1_16_09.pptxOOSD1-unit1_1_16_09.pptx
OOSD1-unit1_1_16_09.pptx
ShobhitSrivastava15887
 
Bt8901 objective oriented systems1
Bt8901 objective oriented systems1Bt8901 objective oriented systems1
Bt8901 objective oriented systems1
Techglyphs
 
Ooad ch 1_2
Ooad ch 1_2Ooad ch 1_2
Ooad ch 1_2
anujabeatrice2
 

Similar to M01_OO_Intro.ppt (20)

ooadunitiintroduction-150730050129-lva1-app6892.pptx
ooadunitiintroduction-150730050129-lva1-app6892.pptxooadunitiintroduction-150730050129-lva1-app6892.pptx
ooadunitiintroduction-150730050129-lva1-app6892.pptx
 
Object-Oriented Analysis and Design
Object-Oriented Analysis and DesignObject-Oriented Analysis and Design
Object-Oriented Analysis and Design
 
Introduction to Object Oriented Programming
Introduction to Object Oriented ProgrammingIntroduction to Object Oriented Programming
Introduction to Object Oriented Programming
 
introduction of Object oriented programming
introduction of Object oriented programmingintroduction of Object oriented programming
introduction of Object oriented programming
 
Introduction to object oriented programming
Introduction to object oriented programmingIntroduction to object oriented programming
Introduction to object oriented programming
 
OOP programming
OOP programmingOOP programming
OOP programming
 
Introduction of object oriented analysis &amp; design by sarmad baloch
Introduction of object oriented analysis &amp; design by sarmad balochIntroduction of object oriented analysis &amp; design by sarmad baloch
Introduction of object oriented analysis &amp; design by sarmad baloch
 
MIT302 Lesson 2_Advanced Database Systems.pptx
MIT302 Lesson 2_Advanced Database Systems.pptxMIT302 Lesson 2_Advanced Database Systems.pptx
MIT302 Lesson 2_Advanced Database Systems.pptx
 
01 introduction
01 introduction01 introduction
01 introduction
 
M01_OO_Intro.ppt
M01_OO_Intro.pptM01_OO_Intro.ppt
M01_OO_Intro.ppt
 
Unit-1 OOAD Introduction.pptx
Unit-1 OOAD Introduction.pptxUnit-1 OOAD Introduction.pptx
Unit-1 OOAD Introduction.pptx
 
Cs 2352 object oriented analysis and design
Cs 2352 object oriented analysis and designCs 2352 object oriented analysis and design
Cs 2352 object oriented analysis and design
 
Unit 1( modelling concepts & class modeling)
Unit  1( modelling concepts & class modeling)Unit  1( modelling concepts & class modeling)
Unit 1( modelling concepts & class modeling)
 
Assignment 1 SYD601 2012 rick_danby completed with audio
Assignment 1 SYD601 2012 rick_danby completed with audioAssignment 1 SYD601 2012 rick_danby completed with audio
Assignment 1 SYD601 2012 rick_danby completed with audio
 
5-CEN6016-Chapter1.ppt
5-CEN6016-Chapter1.ppt5-CEN6016-Chapter1.ppt
5-CEN6016-Chapter1.ppt
 
Lecture 1
Lecture 1Lecture 1
Lecture 1
 
Oot
OotOot
Oot
 
OOSD1-unit1_1_16_09.pptx
OOSD1-unit1_1_16_09.pptxOOSD1-unit1_1_16_09.pptx
OOSD1-unit1_1_16_09.pptx
 
Bt8901 objective oriented systems1
Bt8901 objective oriented systems1Bt8901 objective oriented systems1
Bt8901 objective oriented systems1
 
Ooad ch 1_2
Ooad ch 1_2Ooad ch 1_2
Ooad ch 1_2
 

Recently uploaded

Language Across the Curriculm LAC B.Ed.
Language Across the  Curriculm LAC B.Ed.Language Across the  Curriculm LAC B.Ed.
Language Across the Curriculm LAC B.Ed.
Atul Kumar Singh
 
The Challenger.pdf DNHS Official Publication
The Challenger.pdf DNHS Official PublicationThe Challenger.pdf DNHS Official Publication
The Challenger.pdf DNHS Official Publication
Delapenabediema
 
Lapbook sobre os Regimes Totalitários.pdf
Lapbook sobre os Regimes Totalitários.pdfLapbook sobre os Regimes Totalitários.pdf
Lapbook sobre os Regimes Totalitários.pdf
Jean Carlos Nunes Paixão
 
June 3, 2024 Anti-Semitism Letter Sent to MIT President Kornbluth and MIT Cor...
June 3, 2024 Anti-Semitism Letter Sent to MIT President Kornbluth and MIT Cor...June 3, 2024 Anti-Semitism Letter Sent to MIT President Kornbluth and MIT Cor...
June 3, 2024 Anti-Semitism Letter Sent to MIT President Kornbluth and MIT Cor...
Levi Shapiro
 
678020731-Sumas-y-Restas-Para-Colorear.pdf
678020731-Sumas-y-Restas-Para-Colorear.pdf678020731-Sumas-y-Restas-Para-Colorear.pdf
678020731-Sumas-y-Restas-Para-Colorear.pdf
CarlosHernanMontoyab2
 
TESDA TM1 REVIEWER FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...
TESDA TM1 REVIEWER  FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...TESDA TM1 REVIEWER  FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...
TESDA TM1 REVIEWER FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...
EugeneSaldivar
 
"Protectable subject matters, Protection in biotechnology, Protection of othe...
"Protectable subject matters, Protection in biotechnology, Protection of othe..."Protectable subject matters, Protection in biotechnology, Protection of othe...
"Protectable subject matters, Protection in biotechnology, Protection of othe...
SACHIN R KONDAGURI
 
How to Make a Field invisible in Odoo 17
How to Make a Field invisible in Odoo 17How to Make a Field invisible in Odoo 17
How to Make a Field invisible in Odoo 17
Celine George
 
Palestine last event orientationfvgnh .pptx
Palestine last event orientationfvgnh .pptxPalestine last event orientationfvgnh .pptx
Palestine last event orientationfvgnh .pptx
RaedMohamed3
 
Home assignment II on Spectroscopy 2024 Answers.pdf
Home assignment II on Spectroscopy 2024 Answers.pdfHome assignment II on Spectroscopy 2024 Answers.pdf
Home assignment II on Spectroscopy 2024 Answers.pdf
Tamralipta Mahavidyalaya
 
Supporting (UKRI) OA monographs at Salford.pptx
Supporting (UKRI) OA monographs at Salford.pptxSupporting (UKRI) OA monographs at Salford.pptx
Supporting (UKRI) OA monographs at Salford.pptx
Jisc
 
Welcome to TechSoup New Member Orientation and Q&A (May 2024).pdf
Welcome to TechSoup   New Member Orientation and Q&A (May 2024).pdfWelcome to TechSoup   New Member Orientation and Q&A (May 2024).pdf
Welcome to TechSoup New Member Orientation and Q&A (May 2024).pdf
TechSoup
 
1.4 modern child centered education - mahatma gandhi-2.pptx
1.4 modern child centered education - mahatma gandhi-2.pptx1.4 modern child centered education - mahatma gandhi-2.pptx
1.4 modern child centered education - mahatma gandhi-2.pptx
JosvitaDsouza2
 
Thesis Statement for students diagnonsed withADHD.ppt
Thesis Statement for students diagnonsed withADHD.pptThesis Statement for students diagnonsed withADHD.ppt
Thesis Statement for students diagnonsed withADHD.ppt
EverAndrsGuerraGuerr
 
The basics of sentences session 5pptx.pptx
The basics of sentences session 5pptx.pptxThe basics of sentences session 5pptx.pptx
The basics of sentences session 5pptx.pptx
heathfieldcps1
 
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
siemaillard
 
Embracing GenAI - A Strategic Imperative
Embracing GenAI - A Strategic ImperativeEmbracing GenAI - A Strategic Imperative
Embracing GenAI - A Strategic Imperative
Peter Windle
 
Sha'Carri Richardson Presentation 202345
Sha'Carri Richardson Presentation 202345Sha'Carri Richardson Presentation 202345
Sha'Carri Richardson Presentation 202345
beazzy04
 
The approach at University of Liverpool.pptx
The approach at University of Liverpool.pptxThe approach at University of Liverpool.pptx
The approach at University of Liverpool.pptx
Jisc
 
Adversarial Attention Modeling for Multi-dimensional Emotion Regression.pdf
Adversarial Attention Modeling for Multi-dimensional Emotion Regression.pdfAdversarial Attention Modeling for Multi-dimensional Emotion Regression.pdf
Adversarial Attention Modeling for Multi-dimensional Emotion Regression.pdf
Po-Chuan Chen
 

Recently uploaded (20)

Language Across the Curriculm LAC B.Ed.
Language Across the  Curriculm LAC B.Ed.Language Across the  Curriculm LAC B.Ed.
Language Across the Curriculm LAC B.Ed.
 
The Challenger.pdf DNHS Official Publication
The Challenger.pdf DNHS Official PublicationThe Challenger.pdf DNHS Official Publication
The Challenger.pdf DNHS Official Publication
 
Lapbook sobre os Regimes Totalitários.pdf
Lapbook sobre os Regimes Totalitários.pdfLapbook sobre os Regimes Totalitários.pdf
Lapbook sobre os Regimes Totalitários.pdf
 
June 3, 2024 Anti-Semitism Letter Sent to MIT President Kornbluth and MIT Cor...
June 3, 2024 Anti-Semitism Letter Sent to MIT President Kornbluth and MIT Cor...June 3, 2024 Anti-Semitism Letter Sent to MIT President Kornbluth and MIT Cor...
June 3, 2024 Anti-Semitism Letter Sent to MIT President Kornbluth and MIT Cor...
 
678020731-Sumas-y-Restas-Para-Colorear.pdf
678020731-Sumas-y-Restas-Para-Colorear.pdf678020731-Sumas-y-Restas-Para-Colorear.pdf
678020731-Sumas-y-Restas-Para-Colorear.pdf
 
TESDA TM1 REVIEWER FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...
TESDA TM1 REVIEWER  FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...TESDA TM1 REVIEWER  FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...
TESDA TM1 REVIEWER FOR NATIONAL ASSESSMENT WRITTEN AND ORAL QUESTIONS WITH A...
 
"Protectable subject matters, Protection in biotechnology, Protection of othe...
"Protectable subject matters, Protection in biotechnology, Protection of othe..."Protectable subject matters, Protection in biotechnology, Protection of othe...
"Protectable subject matters, Protection in biotechnology, Protection of othe...
 
How to Make a Field invisible in Odoo 17
How to Make a Field invisible in Odoo 17How to Make a Field invisible in Odoo 17
How to Make a Field invisible in Odoo 17
 
Palestine last event orientationfvgnh .pptx
Palestine last event orientationfvgnh .pptxPalestine last event orientationfvgnh .pptx
Palestine last event orientationfvgnh .pptx
 
Home assignment II on Spectroscopy 2024 Answers.pdf
Home assignment II on Spectroscopy 2024 Answers.pdfHome assignment II on Spectroscopy 2024 Answers.pdf
Home assignment II on Spectroscopy 2024 Answers.pdf
 
Supporting (UKRI) OA monographs at Salford.pptx
Supporting (UKRI) OA monographs at Salford.pptxSupporting (UKRI) OA monographs at Salford.pptx
Supporting (UKRI) OA monographs at Salford.pptx
 
Welcome to TechSoup New Member Orientation and Q&A (May 2024).pdf
Welcome to TechSoup   New Member Orientation and Q&A (May 2024).pdfWelcome to TechSoup   New Member Orientation and Q&A (May 2024).pdf
Welcome to TechSoup New Member Orientation and Q&A (May 2024).pdf
 
1.4 modern child centered education - mahatma gandhi-2.pptx
1.4 modern child centered education - mahatma gandhi-2.pptx1.4 modern child centered education - mahatma gandhi-2.pptx
1.4 modern child centered education - mahatma gandhi-2.pptx
 
Thesis Statement for students diagnonsed withADHD.ppt
Thesis Statement for students diagnonsed withADHD.pptThesis Statement for students diagnonsed withADHD.ppt
Thesis Statement for students diagnonsed withADHD.ppt
 
The basics of sentences session 5pptx.pptx
The basics of sentences session 5pptx.pptxThe basics of sentences session 5pptx.pptx
The basics of sentences session 5pptx.pptx
 
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
 
Embracing GenAI - A Strategic Imperative
Embracing GenAI - A Strategic ImperativeEmbracing GenAI - A Strategic Imperative
Embracing GenAI - A Strategic Imperative
 
Sha'Carri Richardson Presentation 202345
Sha'Carri Richardson Presentation 202345Sha'Carri Richardson Presentation 202345
Sha'Carri Richardson Presentation 202345
 
The approach at University of Liverpool.pptx
The approach at University of Liverpool.pptxThe approach at University of Liverpool.pptx
The approach at University of Liverpool.pptx
 
Adversarial Attention Modeling for Multi-dimensional Emotion Regression.pdf
Adversarial Attention Modeling for Multi-dimensional Emotion Regression.pdfAdversarial Attention Modeling for Multi-dimensional Emotion Regression.pdf
Adversarial Attention Modeling for Multi-dimensional Emotion Regression.pdf
 

M01_OO_Intro.ppt

  • 1. 1 Module 1: Introduction to OOAD (Object-Oriented Analysis and Design)
  • 2. 2 Objectives  Why OO?  What is OOAD?  How to do OOAD?
  • 4. 4 What is Object-Orientation? - What is Object?  An "object" is anything to which a concept applies, in our awareness  Things drawn from the problem domain or solution space.  E.g., a living person in the problem domain, a software component in the solution space.  A structure that has identity and properties and behavior  It is an instance of a collective concept, i.e., a class.
  • 5. 5 Encapsulation a.k.a. information hiding Objects encapsulate: property behavior as a collection of methods invoked by messages …state as a collection of instance variables Abstraction Focus on the essential Omits tremendous amount of details …Focus on what an object “is and does” What is Object-Orientation - Abstraction and Encapsulation
  • 6. 6 What is Object-Orientation - Another Example of Abstraction and Encapsulation Class Car Attributes  Model  Location  #Wheels = 4 Operations  Start  Accelerate <<instanceOf>> <<instanceOf>> <<instanceOf>> What is generalization? What is over-generalization?? Forall x [Car(x) -> …]
  • 7. 7 What is Object-Orientation? - Class  What is CLASS?  a collection of objects that share common properties, attributes, behavior and semantics, in general. What are all these???  A collection of objects with the same data structure (attributes, state variables) and behavior (function/code/operations) in the solution space.  Classification  Grouping of common objects into a class  Instantiation.  The act of creating an instance. Class Car Attributes  Model  Location  #Wheels = 4 Operations  Start  Accelerate <<instanceOf>> <<instanceOf>> <<instanceOf>>
  • 8. 8 What is Object-Orientation - Subclass vs. Superclass • Specialization: The act of defining one class as a refinement of another. • Subclass: A class defined in terms of a specialization of a superclass using inheritance. • Superclass: A class serving as a base for inheritance in a class hierarchy • Inheritance: Automatic duplication of superclass attribute and behavior definitions in subclass. multiple inheritance? Person name SSN Student std-id level Employee emp-id age
  • 9. 9 What is Object-Orientation - Subclass vs. Superclass A B C A B A B C A B c: C A B c: C <<instanceOf>> <<instanceOf>> A B <<instanceOf>> A B <<instanceOf>>
  • 10. 10 What is Object-Orientation - Polymorphism Objects of different classes respond to the same message differently. payTuition Person name SSN Student std-id level Employee emp-id In-State Student state payTuition payTuition Out-of-State Student payTuition
  • 11. 11 What is Object-Orientation - Interfaces • Information hiding - all data should be hidden within a class, at least in principle. • make all data attributes private • provide public methods to get and set the data values (cf. Java design patterns) • e.g. Grade information is usually confidential, hence it should be kept private to the student. Access to the grade information should be done through interfaces, such as setGrade and getGrade payTuition setGrade() getGrade() Student std-id level getGrade setGrade grade
  • 12. 12 What is Object-Orientation - Abstract Class vs. Concrete Class  Abstract Class.  An incomplete superclass that defines common parts.  Not instantiated.  Concrete class.  Is a complete class.  Describes a concept completely.  Is intended to be instantiated. Work out an example!
  • 13. 13 What is Object-Orientation? -State  What is STATE? "State" is a collection of association an object has with other objects and object types.  What is STATE CHANGE? A "state change" is the transition of an object from one state to another.  What is EVENT? An "event" is a noteworthy change in state [Rumbaugh] Work out an example!
  • 14. 14 What is Object-Orientation? -State transition impossible? tom: Actor name = “Tom Cruise” katie: Actor name = “Katie Holmes” tom: Actor name = “Tom Holmes” katie: Actor name = “Katie Holmes” married/changeLastName tom: Actor name = “Tom Holmes” katie: Actor name = “Katie Holmes” suri: BabyActor name = “Suri Holmes” newArrival/getName
  • 15. 15 What is Object-Oriented Application? • Collection of discrete objects, interacting w. each other • Objects have property and behavior (causing state transition) • Interactions through message passing (A sender object sends a request (message) to another object (receiver) to invoke a method of the receiver object’s) Fn Data O1 Fn Data O2 Fn Data O3 m1 m2 m3 {m in Fn}
  • 16. 16 What is OOAD?  Analysis — understanding, finding and describing concepts in the problem domain.  Design — understanding and defining software solution/objects that represent the analysis concepts and will eventually be implemented in code.  OOAD — Analysis is object-oriented and design is object- oriented. A software development approach that emphasizes a logical solution based on objects. Traceability! Involves both a notation and a process
  • 17. 17 How to do OOAD - notation vs. process  UML is a notation.  So are English, Elvish, Ku, …  But as yet I can’t
  • 18. 18 Systems Engineering Requirements Analysis Project Planning Architectural Design Detailed Design Implementation Release Maintenance Quality Assurance Software Lifecycle How to Do OOAD – Where to Use OO? Traceability! Something missing? What’s yours like?
  • 21. 21 How to Do OOAD – OMT as Object-Oriented Methodology OMT (Object Modeling Technique) by James Rumbaugh Object Model: describes the static structure of the objects in the system and their relationships -> Object Diagrams. Dynamic Model: describes the interactions among objects in the system -> State Diagrams. Functional Model: describes the data transformation of the system -> DataFlow Diagrams. Traceability!
  • 22. 22 Analysis: i) Model the real world showing its important properties; ii) Concise model of what the system will do System Design: Organize into subsystems based on analysis structure and propose architecture Object Design: Based on analysis model but with implementation details; Focus on data structures and algorithms to implement each class; Computer and domain objects Implementation: Translate the object classes and relationships into a programming language How to Do OOAD – OMT as Object-Oriented Methodology OMT (Object Modeling Technique) by James Rumbaugh Traceability!
  • 23. 23 A Unified Language + A Good Process + A Good Goal, perhaps
  • 24. 24 How to Do OOAD - Historical Perspective OO Prog. Languages (Smalltalk, C++) just program! OO Design (Booch) design then program OO Analysis (Rumbaugh, Jacobson) Process Perspective OO Technology Analyze (use case) first, then design, T then program Where are we heading?
  • 25. 25 How to Do OOAD – One Good Way: Use (OO) Design Patterns Reusable solutions to typical problems. “Each design pattern systematically names, explains, and evaluates an important and recurring design in object-oriented systems.” [Gamma]  Name — identifies a particular pattern, creating a vocabulary.  Problem — identifies context when pattern should be applied.  Solution — an abstract description of a design problem along with a template object design that solves the problem.  Consequences — results and trade-offs of applying the pattern.
  • 26. 26 Knowledge Representation (in A.I.) Psychological Validity Philosophical Validity Computational Validity Databases Emphasis in Persistent Data (and now ACID properties) RelationalDB Network DB Hierarchical DB OODB Programming Languages Emphasis in Efficiency Simula, SmallTalk, C++, Protel, Java ERD SDM CM ADT ERD: Entity Relationship Diagram SDM: Semantic Data Model ADT: Abstract Data Type CM: Conceptual Model Why Object-Oriented - Who’s Behind Object-Orientation w. Diff. Concerns System/Software Engineering Where does Unified Modeling Language come into this?
  • 27. 27 Why Object-Oriented – A New Paradigm with Evolving Object Orientation  OOP: Object-Oriented Programming  Simula (1967), Smalltalk (70’s), C++ (mid 80’s), Eiffel, Ada95, Turing, …  OOD: Object-Oriented Design  Taxis (1976), Adaplex, …, Grady Booch (1980)  OOA: Object-Oriented Requirements  RML (1981), James Rumbaugh (late 80’s)  OO-Databases (OODBs): 1980-90’s  OLE/DCOM, VisualBasic, CORBA, Java: mid 90’s  .Net, C#, (eb/voice…/-)XML, J2EE: into 2000+  UML: mid 90’s and still evolving
  • 28. 28 Introduction to OOAD - Points to Ponder 1. How do you think your mental image is represented? 2. What kinds of languages are used for what purpose in our daily life? 3. What are the differences among a concept, a model and a language? 4. What are the differences between a language and a methodology? 5. Can we use C# for analysis? 6. If C++ is a language, does it model anything? If so, what? 7. What does a concept in C++ refer to (i.e., semantics)? 8. What does a concept in a (OO) design refer to? 9. What does a concept in an (OO requirements) analysis refer to? 10. Is the current OOAD for Functional Analysis and Design, or Non- Functional Analysis and Design? 11. What is the relationship between OO (Object-Orientation) and GO (Goal-Orientation), between OO and AO (Agent-Orientation), and between GO and AO? 12. Can you prove you and I communicate with each other perfectly?