Professional Documents
Culture Documents
Introduction to OO Concepts
Introduction to OO Concepts
Introduction
OO Analysis
describes information systems by identifying things called objects popular approach end model = object model represents information systems in terms of objects and object-oriented concepts
Introduction to OO Concepts
Object-oriented concepts
An object represents a real person, place, event or transaction. Example: When a patient makes an appointment to see a doctor, the patient, doctor and appointment are all objects.
Introduction to OO Concepts
Object-oriented concepts
Object
computer representation of real-world thing / event described by its:
Attributes characteristics that describe object Methods tasks / functions
Introduction to OO Concepts
Object
The object's interface consists of a set of commands, each command performing a specific action. An object asks another object to perform an action by sending it a message. The requesting (sending) object is referred to as sender and the receiving object is referred to as receiver.
Introduction to OO Concepts
Object-oriented concepts
Class
category of similar objects template for all objects of that class
Introduction to OO Concepts
Object-oriented concepts
Class Relationships
3 kinds
Association
structural connection between classes UML Association Notation bidirectional
Introduction to OO Concepts
Object-oriented concepts
Association
One-Way Navigation between classes
Named Association
Introduction to OO Concepts
Object-oriented concepts
Association
Association Rules
Association Multiplicity
Introduction to OO Concepts
Object-oriented concepts
Aggregation
A whole / part relationship UML Aggregation Notation
Self-aggregation
Introduction to OO Concepts
Object-oriented concepts
Generalization
relationship between a superclass and the subclasses
Object-oriented concepts
Message
objects interact with each other by sending each other messages requesting particular services client / sender initiating object server / receiver receiving object functional approach data passed between processing units; OO program messages passed between objects
Introduction to OO Concepts
Object-oriented concepts
Introduction to OO Concepts
Object-oriented concepts
Encapsulation
packaging data and operations into an object provides three software desirable software properties: Modularity, Data Abstraction & Data Hiding An object may only access another object's data by sending it messages. This is called encapsulation and assures that there is a secure process for getting to an object's data.
CT026-1 Systems Analysis and Design Introduction to OO Concepts Slide 15 (of 24)
Object-oriented concepts
Inheritance
a mechanism which allows new classes to be defined in terms of existing classes new class inherits / includes the features (operations and attributes) of the class it is created from
Introduction to OO Concepts
Object-oriented concepts
Inheritance
Introduction to OO Concepts
Object-oriented concepts
Polymorphism
the ability to define program entities that take more than one form allows a single message to be interpreted differently by different objects
Introduction to OO Concepts
Object-oriented concepts
Polymorphism
Introduction to OO Concepts
Object-oriented concepts
An analogy of polymorphism to daily life is how students respond to a school bell. When the bell (message) rings, however, it has its own meaning to different students (objects). Some: students go home go to the library, and go to other classes Every student responds to the bell, but how they respond to it might be different.
CT026-1 Systems Analysis and Design Introduction to OO Concepts
Introduction to OO Concepts
Follow-up Assignment
Briefly explain the difference the following pairs of object-oriented terms. You should include small examples to illustrate your answers:
class / object attribute / operation association / multiplicity subclass / superclass message / method encapsulation / data hiding
Introduction to OO Concepts
Q&A
CT026-1 Systems Analysis and Design Introduction to OO Concepts Slide 23 (of 24)
Next Session
Introduction to UML Diagrams
Use Case Diagram Sequence Diagram Class Diagram
Introduction to OO Concepts