Presentation is loading. Please wait.

Presentation is loading. Please wait.

Object Oriented Design. Goals  More on UML: Sequence Diagrams  Game 1: Truck versus Frog  Workshop: start game design #2.

Similar presentations


Presentation on theme: "Object Oriented Design. Goals  More on UML: Sequence Diagrams  Game 1: Truck versus Frog  Workshop: start game design #2."— Presentation transcript:

1 Object Oriented Design

2 Goals  More on UML: Sequence Diagrams  Game 1: Truck versus Frog  Workshop: start game design #2

3 Problem Analysis Behavior

4 Diagrams  Structural Diagrams (represent static application structure) u Class Diagram (examples)examples u Object Diagram (examples)examples u Component Diagram u Deployment Diagram  Behavior Diagrams (represent different aspects of dynamic behavior) u Use Case Diagram u Sequence Diagram (examples)examples u Activity Diagram u Collaboration Diagram u Statechart Diagram  Model Management Diagrams (ways you can organize and manage your application modules) u Packages u Subsystems u Models

5 Sequence Diagrams  Sequence diagrams describe BEHAVIOR through describing interactions among classes  Interactions are modeled as exchanges of messages  Contain: u Class roles, the roles an object may/can play within the interaction u Lifelines, the existence of an object over time u Activations, active time when an object performs an operation u Messages, communication between objects u – source: http://www.redwood.nlhttp://www.redwood.nl

6 Notation used in a Sequence Diagram

7 Sequence Diagrams Structure Time use case scenario written down here message() new() [check=true] new() check() local() System Border :class1:class2:class3:class4

8 Game 1: Frogger  You are a frog. Your task is simple: hop across a busy highway, dodging cars and trucks, until you get the to the edge of a river, where you must keep yourself from drowning by crossing safely to your grotto at the top of the screen by leaping across the backs of turtles and logs. But watch out for snakes and alligators! (Sega, 1980)

9 Modeling Frog versus Truck …from the perspective of the  Frog  Truck  Highway using a sequence diagram

10 More objects  How to create and dispose trucks on the fly?

11 Workshop: Model Space Invaders  Analyze Specification: what is missing?  Design Structure: u Class diagram u Object diagram (screen dump)  Design Behavior: u Sequence Diagrams

12 Homework Checkpoint  Download AgentSheets u Key will be emailed to you u Build Frogger game u Email project (Alex & Andri)  Windows: use “email project” feature  Mac: stuff project folder u Due: Sept. 10

13 Announcements  Office hours change THIS WEEK ONLY u Instead of Wednesday: Thursday, Sept 5, 2- 3pm


Download ppt "Object Oriented Design. Goals  More on UML: Sequence Diagrams  Game 1: Truck versus Frog  Workshop: start game design #2."

Similar presentations


Ads by Google