Académique Documents
Professionnel Documents
Culture Documents
Unit Introduction
Dr. Quang Vinh Nguyen
General Information
Object Orietend Analysis, 300144
Level 2 10 Credit Points
Assumed Knowledge
300585 System Analysis and Design or 300131 Introduction to Analysis and Design or Equivalent Have gained sufficient equivalent knowledge from the prerequisites to understand and master the concepts discussed and presented in this OOA unit. Have a general understanding of what an information system is and how information system development is undertaken. Comfortable in learning use of the modelling tools and report with some tutorial assistance such a Visio , Rationals ROSE, or Telelogics TauUML and Word and MS Project
Object Oriented Analysis, 300144 2
Staffs
Dr Quang Vinh Nguyen Unit Coordinator and Lecturer Phone: 4736 0482 Email: q.nguyen@uws.edu.au (preferred contact method) Room: Room Y-353, Bld Y, Penrith campus, Room , Hot Office, Parramatta campus Consultation hours: Wednesday 11:00 12:00 (Parramatta campus) Monday 11:00 12:00 (Penrith campus) Friday 10:00 11:00 (Penrith campus) Contact Details of the Tutors are available on vUWS
Staffs
Mahmoud Elkhodr Lecturer and Tutor Email: m.elkhodr@uws.edu.au (preferred contact method) Room: Room UG-25, Bld U, Penrith campus, Consultation hours: TBA
Practical sessions
scheduled for 11 weeks (only 10 marked tutorial sessions) no practical sessions in first week
Assessment
Mid-term Test: 15%, 90 mins test including reading time (Closed book) is held in Week 8 or as specified in class, Group Assignment (also known as Project Work): 20%, OO Analysis Model in a CASE tool + Deliverables Report
Submission at the last week of the semester or as specified in class Students attend < 5 tutorials will receive 0 Score for the assignment.
Final Examination: 50%, 120 mins exam including reading time of 10 mins (Closed book).
Must obtain at least 40% in the final examination, and at least 50% as a total value of all your assessment scores to pass the unit
Object Oriented Analysis, 300144 7
References:
Unhelkar, B., Practical Object Oriented Design, 2005, Thomson Publishing; ISBN: 0170122999. The alternative book that discuss about the design perspectives. Fowler, M., UML Distilled, 3rd Edition, 2004, Addison-Wesley. ISBN: 0321193687. This is a good readable book and should be referred to in addition to the course material. Unhelkar, B., Process Quality Assurance for UML-based Projects, 2003, Boston : AddisonWesley . ISBN: 0201758210. This book contains detailed discussion on the process aspect of quality. Chapter 1 for UML-based models, Chapter 3 for relevant process components, and Chapter 6 for testing are quite relevant. Booch, G., et al, The UML User Guide, 2005, 2nd edition, Addison-Wesley, ISBN: 0321267974. This is a substantial text and should be occasionally referred to, when students (especially teams) are looking for additional and in-depth material on a particular topic. Brown, D., An Introduction to Object-Oriented Analysis: Objects and UML in Plain English, 2nd edition, 2002, New York: Wiley, ISBN: 0471371378. This book is a very general and accessible introduction to Object Oriented Analysis. It contains extensive pedagogy and incorporates patient explanations, making it ideal for beginners as a complement reading material.
Object Oriented Analysis, 300144 8
O-O-A Chapter 1
Fundamentals of Object Orientation
11
Module Outline
Positioning Object Oriented Analysis Fundamentals of ObjectOrientation 1. Classification 2. Encapsulation 3. Abstraction 4. Inheritance 5. Polymorphism The need of Modeling Unified modeling language Mapping the UML to the Modeling Spaces
Object Oriented Analysis, 300144 12
What is Object-Oriented?
Encompasses various aspects of software Development
Analysis; Design; Implementation; Testing; Metrics; Databases; Architecture - especially Distributed; Management;
Unlike Relational (set) Theory, has no Mathematical background; hence no Precise Definition;
13
(cont)
16
(cont)
17
Why Object-Oriented
OO Software Engineering results in easier maintainability and extensibility
Due to Localized and controlled changes
The key benefit of OO approach is: hierarchically breaking down a complex system into manageable components Object Oriented Analysis, 300144
18
19
1990s 1980s
1970s
21
Function Code
Function Code
Class
Function Function
Class
Function Function
Code
Code
Code
Statement Control Loop Jump
Function Function Code Code Code Code
Class
Function Function
Class
Function Function
Component Component Class Component Class Component Class Class Class Class Class Class
Assembly
Dr. Quang Vinh Nguyen
Positioning Objects
In 1970s Flowchart and Structured System Analysis and Design Methods In 1980s Chens popular Entity Relationship and Data Flow diagrams Early 1990s Unified Modeling Language by Booch.
23
Global Business
+
Distributed Computing
Fundamentals
Adopting OO
Process
Experience
Object Oriented Analysis, 300144 25
26
A CLOCK in general is a CLASS. Your CLOCK and My CLOCK are specific Objects
27
What is a Class?
A Class is a DEFINITION, a TEMPLATE, for the Objects NOTE: A Class is NOT a Collection of Objects; A class is not an individual object, but it represents a whole set of objects.
28
What is an Object?
An Entity with crisply defined boundaries A physical or conceptual thing in the problem and the solution domain Identity is a unique identifier of an object Has attributes that describe the object, and also describe the state in which it exists Has behavior that is manifested in changes to the state of the object Sends and receives messages
Object Oriented Analysis, 300144 29
30
Objects vs Classes ?
Object 1 Object 7 Object 2 Object 6 Object 5 Object 4 Object 3
Class: Car
A class represents a set of objects that share a common structure and a common behaviour
An object is simply an instance of a class
Object Oriented Analysis, 300144 31
Data
Procedures
Data
Subprograms
32
Data
Procedures
33
Procedural Mindset What is the system supposed to do? What are the functions of the system? How do I design and code to achieve the functions? Focus is on the algorithms.
OO Mindset What is the system made up of? Objects What are the responsibilities of these objects? How will these objects collaborate to satisfy the responsibilities? Algorithms/code deferred
34
35
Classification
Lithops Lesliei
36
Classification
Starting point of object orientation Grouping meaningful objects. Classification is based on the requirements appearing in the problem space.
37
FROG HAT CLOCK CAT Note that these are ABSTRACTIONS and not real Objects. Objects are Classified and good Classification leads to creation of good Abstractions. Classes that represent a collection of Objects are Abstract.
38
CAT
Requirements from Problem Space Can be Classified & Abstracted to Arrive at Good Classes
CHEST
SHOE HAT
40
41
BIRD
ANIMAL
CRANE
FROG
Object Oriented Analysis, 300144
CAT
42
Inheritance
Inheritance in OO is the ability of a Class to inherit all attributes and behavior of a higher-level class Classifying with optimum granularity also leads to good inheritance structure
43
Inheritance (cont)
Child class inherits from parent class Child class shares the attributes and routines of parent class, plus perhaps adds additional features Child class can change implementation of parent class features multiple inheritance is permitted; some resolution for name clashes is required
Object Oriented Analysis, 300144 44
Generalization
Finding Subclasses
Concrete lower level implementation thinking Essentially WITH Reuse
Specialization
45
Encapsulation
Encapsulation means DATA is accessed only by METHODS
METHODS DATA (Attributes with States)
BEGIN PUBLIC VISIBILITY PRIVATE INFORMATION
CODE
END
46
47
Polymorphism
ANIMAL (move)
(move)
On Receipt of Message move from a Calling Object, the appropriate move - depending on whether it is a Frog or a Horse - will be executed
FROG (move)
HORSE (move)
CAT (move)
Advantage? CALLING object need not know what is Moved, so, if a new CAT object is added, the CALLING class doesnt change
Object Oriented Analysis, 300144 48
Polymorphism..
Essentially the ability of an Entity to behave differently - even after receiving the same message Translates to the ability of the software to substitute different Objects at runtime Implemented via Inheritance in Objectorientation
Object Oriented Analysis, 300144 49
50
MODEL
Create Reality
REALITY
51
Management; Processes
Communication Technology
52
53
OO Models have a Small Semantic Gap (from Unhelkar, CRC Press, 1999)
Passenger
ANALYSIS
Flight
Seat
SEMANTIC GAP
DESIGN
Class:: Passenger
Class:: Flight
Class:: Seat
54
OO facilitates Seamless Transition from Problem to Solution Space (from Unhelkar, CRC Press, 1999)
Class Flight
Class Seat
Design (MOSS)
Implementation (MOSS)
Object Oriented Analysis, 300144 55
Sub-Module
Modeling Spaces
And Relating them to the UML
56
57
Next Lecture
About the UML
Origins and Evolution of the UML Evolution of the UML
Some UML based projects Introduction to UML 2.0 UML 2.0 diagrams and purpose
Object Oriented Analysis, 300144 58
Workbook
Exercises
For Classroom
59
Workbook Exercises
1. 2. 3. 4. 5. What is object orientation? What does it encompass? How is object orientation different from procedural approach to software development? What are the four major factors in learning and adopting object orientation? List FIVE objects from your current surroundings. Create at least TWO classes from the above five objects (This will help you understand the difference between a class and an object).
Object Oriented Analysis, 300144 60
Workbook Exercises
6. List next to each of the above TWO classes, at least FIVE attributes. 7. Discuss the importance of each of the fundamentals of OO within the context of software engineering. 8. What is a process and how it is different from modeling? 9. What are the two main reasons for creating models? 10. How is object-oriented modeling advantageous? 11. Name the three modeling spaces in OO modeling. Discuss the advantage of modeling in each of these three modeling spaces.
Object Oriented Analysis, 300144 61
Conclusions
Software Development benefits with Process and Modeling; UML is OMGs standard for Modeling; OO has Five Fundamentals Classification; Abstraction; Inheritance; Encapsulation and Polymorphism Class is a Template; Object is an Instance; All Modeling Work happens in 3 Spaces: MOPS; MOSS; and MOBS
62