Object Oriented Analysis and Modeling Object Oriented Modeling

  • Slides: 12
Download presentation
Object Oriented Analysis and Modeling

Object Oriented Analysis and Modeling

Object Oriented Modeling l Major points: l Minor points: • Abstraction • Encapsulation •

Object Oriented Modeling l Major points: l Minor points: • Abstraction • Encapsulation • Inheritance • Polymorphism • Strong typing • Concurency • persistence 10/26/2020 Object Oriented Design Course 2

UML l l UML is a tool that can be used through a process

UML l l UML is a tool that can be used through a process Several processes exist: • RUP (Rational Unified Process) [Booch. Jacobson] 10/26/2020 Object Oriented Design Course 3

Analyzing l l l Define the information domain related to the problem Define functions

Analyzing l l l Define the information domain related to the problem Define functions Define behavior against external components Structure the models of information, functionality and behavior in refined layers Top down approach 10/26/2020 Object Oriented Design Course 4

Defining a model l Model the information domain l Model the functionality domain •

Defining a model l Model the information domain l Model the functionality domain • Data and relations (classes and concepts) • Identify the functions that transform data (usecases) l Model behavior • Identify system states (activity and states) • Identify events that cause state changes (sequence and collaboration) l Partition the Model • Refine each model to several levels of detail 10/26/2020 Object Oriented Design Course 5

UML Diagrams Logical (classes, objects, packages) Implementaion (components) Process/behavioral (state, activity, sequence, collaboration) 10/26/2020

UML Diagrams Logical (classes, objects, packages) Implementaion (components) Process/behavioral (state, activity, sequence, collaboration) 10/26/2020 Scenario (use cases) Deployment (topology, Installation) Object Oriented Design Course 6

Use Cases l l Goal: capture the system behavior Specify what the system does

Use Cases l l Goal: capture the system behavior Specify what the system does (functions) and not how it does it Act as a medium between users, developpers and experts Used to validate the built system 10/26/2020 Object Oriented Design Course 7

High Level Use Case l l Use case: withdraw cash Actor: client Type: primary

High Level Use Case l l Use case: withdraw cash Actor: client Type: primary Description: a client goes to an ATM, identifies himself, and withdraw some cash. 10/26/2020 Object Oriented Design Course 8

Extended Use Case l l l Use case: withdraw cash Actor: client Type: primary

Extended Use Case l l l Use case: withdraw cash Actor: client Type: primary Description: a client goes to an ATM, identifies himself, the system shows amount to debit and ask how much to withdraw, the client choose and receive cash from the machine. Type: primary 10/26/2020 Object Oriented Design Course 9

Extended Use Case l Typical scenario: 1. A client arrives at the ATM 2.

Extended Use Case l Typical scenario: 1. A client arrives at the ATM 2. He identifies himself 3. Presentation of options 4. The client chooses « cash withdrawal » 5. Ask which bank account to debit from 6. Choose the accout 7. Ask for amount 8. Choose amount 9. Debit account 10. Give cash 11. Client takes cash and leaves 10/26/2020 Object Oriented Design Course 10

Extended Use Case l Alternate scenario: • 2. invalid identification: show an error •

Extended Use Case l Alternate scenario: • 2. invalid identification: show an error • 8. The amount is not a mutiple of 20: show an error. • 9. Insufficient cash: how an error. 10/26/2020 Object Oriented Design Course 11

Use Cases l l l Common mistake: represent stages, basic operations or transactions as

Use Cases l l l Common mistake: represent stages, basic operations or transactions as use cases Actors: external to the system Type: primary, secondary, optional. 10/26/2020 Object Oriented Design Course 12