CSSE 374: Object-Oriented Design Exercise Steve Chenoweth Office: Moench Room F220 Phone: (812) 877-8974 These slides and.

Slides:



Advertisements
Similar presentations
PHP functions What are Functions? A function structure:
Advertisements

Managing Users. Overview for School Admin Users Define Users Users Module Add Users Importing Users and Groups Manually adding users Search for Users.
Object Design Examples with GRASP
OBJECT ORIENTED PROGRAMMING M Taimoor Khan
Robert B. Jackson Brigham Young University John W. Satzinger
CSSE 374: Introduction to Object- Oriented Analysis and Design Q1 Steve Chenoweth Office: Moench Room F220 Phone: (812)
Copyright W. Howden1 Lecture 7: Functional and OO Design Descriptions.
1 Programming for Engineers in Python Autumn Lecture 5: Object Oriented Programming.
IS 421 Information Systems Analysis
CS 106 Introduction to Computer Science I 03 / 19 / 2008 Instructor: Michael Eckmann.
Chapter 10 Class and Method Design
Feb. 27, 2001CSci Clark University1 CSci 250 Software Design & Development Lecture #13 Tuesday, Feb. 27, 2001.
Object-Oriented Analysis and Design
7. 2Object-Oriented Analysis and Design with the Unified Process Objectives  Detailed Object-Oriented Requirements Definitions  System Processes—A Use.
ASP.NET Programming with C# and SQL Server First Edition
is the online course management system used throughout the UW System. Each semester, all UW-Superior undergraduate courses and most graduate.
Domain Modeling Chandan R. Rupakheti and Steve Chenoweth Week 5, Day 1.
CSSE 374: More GRASP’ing and Use Case Realization Steve Chenoweth Office: Moench Room F220 Phone: (812) These.
CSSE 374: Design Class Diagrams Steve Chenoweth Office: Moench Room F220 Phone: (812) These slides and others.
CSSE 374: Domain Model Refinements and Iteration 3 Preparations Q1 These slides and others derived from Shawn Bohner, Curt Clifton, Alex Lo, and others.
CSSE 374: Even More Object Design with Gang of Four Design Patterns These slides derived from Shawn Bohner, Curt Clifton, and others involved in delivering.
CSSE 374: Interaction Diagrams Steve Chenoweth Office: Moench Room F220 Phone: (812) These slides and others derived.
Systems Analysis and Design in a Changing World, Fifth Edition
CSSE 374: Final Perspectives on Software Architecture and Design These slides derived from Shawn Bohner, Curt Clifton, Alex Lo, and others involved in.
CSSE 374: Operations Contracts and Logical Architectures Steve Chenoweth Office: Moench Room F220 Phone: (812)
CSSE 374: GRASP’ing at the First Five Patterns Principles Steve Chenoweth Office: Moench Room F220 Phone: (812)
XP New Perspectives on Microsoft Office Access 2003 Tutorial 11 1 Microsoft Office Access 2003 Tutorial 11 – Using and Writing Visual Basic for Applications.
Chapter 18 Object Design Examples with GRASP. Objectives Design use case realizations –A use-case realization describes how a particular use case is realized.
CSSE 374: More Object Design with Gang of Four Design Patterns Steve Chenoweth Office: Moench Room F220 Phone: (812)
Introduction to Sequence Diagrams
Chandan Rupakheti Office: Moench Room F203 Phone: (812) These slides and others derived from Shawn Bohner, Curt.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 4 Slide 1 Slide 1 Message Analysis Table.
CSSE 374: Introduction to Gang of Four Design Patterns
Chapter 5 Class Design. The Deliverables of the Class Design Process Class diagrams are further refined in this phase of development Object diagrams are.
CSSE 374: 3½ Gang of Four Design Patterns These slides derived from Steve Chenoweth, Shawn Bohner, Curt Clifton, and others involved in delivering 374.
12 Systems Analysis and Design in a Changing World, Fifth Edition.
1 ITEC 3010 “Systems Analysis and Design, I” LECTURE 10: Use Case Realizations [Prof. Peter Khaiter]
Object Design Examples with GRASP (Ch. 18)
© 2009 Bentley Systems, Incorporated Chris Collins D&C Manager Quantities.
Utilities (Part 2) Implementing static features 1.
CSSE 374: More GRASP’ing for Object Responsibilities
Systems Analysis and Design in a Changing World, 3rd Edition
Object Oriented Design Jerry KotubaSYST Object Oriented Methodologies1.
Chapter 10 Defining Classes. The Internal Structure of Classes and Objects Object – collection of data and operations, in which the data can be accessed.
Single Responsibility Principle Steve Chenoweth Office: Moench Room F220 Phone: (812) Chandan Rupakheti Office:
Chapter 5 Introduction to Defining Classes
1  lecture slides online
Moodle Basic Assessment Methods Staff Guide. Adding a Assignment Click Add an Activity or Resource With the course in editing mode...
Applying Use Cases to Implementation (Chapters 25,26 - Requirements Text) Steve Chenoweth & Chandan Rupakheti Question 1.
Session 33 More on SOLID Steve Chenoweth Office: Moench Room F220 Phone: (812) Chandan Rupakheti Office: Moench.
CS 106 Introduction to Computer Science I 03 / 22 / 2010 Instructor: Michael Eckmann.
Sub-Phase Low Level Design (cont)
McGraw-Hill/Irwin© 2008 The McGraw-Hill Companies, All Rights Reserved Chapter 17 Object-Oriented Design and Modeling Using the UML.
PowerPoint Presentation for Dennis, Wixom, & Tegarden Systems Analysis and Design with UML, 3rd Edition Copyright © 2009 John Wiley & Sons, Inc. All rights.
PowerPoint Presentation for Dennis, Wixom, & Tegarden Systems Analysis and Design with UML, 5th Edition Copyright © 2015 John Wiley & Sons, Inc. All rights.
ASET 1 Amity School of Engineering & Technology B. Tech. (CSE/IT), III Semester Database Management Systems Jitendra Rajpurohit.
Welcome to CMPT 225 Data Structures and Programming Anne Lavergne
1 M206 Chapter 31: An Overview of Software Development 1.Defining the problem 2.Analyzing the requirement – constructing initial structural model 3.Analyzing.
1 Sections 6.4 – 6.5 Methods and Variables Fundamentals of Java: AP Computer Science Essentials, 4th Edition Lambert / Osborne.
Design Model: Determining Visibility CH-18. Objectives Identify four kinds of visibility. Design to establish visibility. Illustrate kinds of visibility.
Software Engineering 1 Object-oriented Analysis and Design Applying UML and Patterns An Introduction to Object-oriented Analysis and Design and Iterative.
Chapter 5 Introduction to Defining Classes Fundamentals of Java.
Object Design Examples with GRASP
CSSE 374: UML Activity Diagrams
ITEC 630 Final Examination Spring 2015
GRASP: Visibility and Design
CSSE 374: Domain Model Refinements and Iteration 3 Preparations
Chapter 10: Visibility Chapter 18 in Applying UML and Patterns Book.
Chapter 20 Applying UML and Patterns Craig Larman
Software Design Lecture : 9.
Presentation transcript:

CSSE 374: Object-Oriented Design Exercise Steve Chenoweth Office: Moench Room F220 Phone: (812) These slides and others derived from Shawn Bohner, Curt Clifton, Alex Lo, and others involved in delivering 374. Chandan Rupakheti Office: Moench Room F203 Phone: (812)

Learning Outcomes: Patterns, Tradeoffs Identify criteria for the design of a software system and select patterns, create frameworks, and partition software to satisfy the inherent trade-offs. Object visibility Apply OOD to an Extended Example Experience OOD on some aspect of Extended Example

Object Visibility An object B is visible to an object A … if A can send a message to B Related to, but not the same as:  Scope  Access restrictions (public, private, etc.) There are four common ways that B can be visible to A

Attribute Visibility Object A has attribute visibility to object B if… A has an attribute that stores B Quite permanent Most common

Parameter Visibility Object A has parameter visibility to object B if … B is passed in as an argument to a method of A  Not permanent, disappears when method ends  Second most common  Methods often convert parameter visibility to attribute visibility Register has method- return visibility to ProductDescription

Local Visibility Object A has local visibility to object B if …B is referenced by a local variable in a method of A Not permanent, disappears when leaving variable’s scope Third most common Methods often convert local visibility to attribute visibility

Local Visibility Examples 1. Call a constructor and store new object in local var InterestCalculator calc = new InterestCalculator() calc.getInterest(...) 2. Call a method and store returned object in local var ItemDescription id = productCatalog.getItem(itemID) price = id.getPrice() 3. Chained method calls productCatalog.getItem(itemID).getPrice()  very transient visibility to the ItemDescription returned by getItem. Essentially same as #2.

Global Visibility Object A has global visibility to object B if … B is stored in a global variable accessible from A Very permanent Least common (but highest coupling risk)

Visibility Review Attribute Visibility(Association/Aggregation) B is an attribute of A Parameter visibility (Dependency) B is a parameter of a method of A Local visibility (Dependency) B is a local object in a method of A Global visibility (Dependency) B is globally visible

Students YIKES!!!!!!! HECK IS

Extended Example: Grading System

Problem Statement The system will help instructors and teaching assistants provide thorough, timely feedback to students on assignments. The system will make grading more efficient, allowing students to more quickly receive feedback and course staff to devote more time to improving instruction. The system will take a collection of student solutions to an assignment as PDF files or some other convenient, open standard. It will allow the grader to “write” feedback on student submissions. It will keep track of the grader's place in each assignment so that he or she can grade every student's answer to question 1, then question 2, and so on. Finally the application will create new PDF files including comments for return to the students. Besides feedback, the system will help with calculating grades. The grader can associate points with each piece of feedback, so that the application can calculate points earned on the assignment. The grader will be able to drag remarks from a “well” of previous feedback to give the same feedback to multiple students (and deduct or add the same number of points). The points associated with a particular piece of feedback can be edited, causing the system to update the score calculations for every student that received that feedback.

A Sampling of Use Cases Create assignment Import student submissions Create feedback item Edit feedback item Add feedback to a submission Export graded student submissions

Domain Model for Grading System

Create Assignment Scenario SSD

Create New Assignment Q5,6 Operation createNewAssignment(title, description, dueDate, authors) Cross References Use Case: Create Assignment Preconditions none Postconditions  an Assignment instance, assignment, was created  the attributes of assignment were set from the corresponding arguments  a list, instructors, of new Instructor instances were created for each author in authors  for each instructor in instructors, instructor.name was set to the corresponding author in authors assignment was associated with instructors

Create New Rubric Q6 cont. Operation createNewRubric(assignment, pointsAvailable, initialRequirements, authors) Cross References Use Case: Create Assignment Preconditions assignment is an existing Assignment in the system Postconditions  a Rubric instance, rubric, was created  the attributes of rubric were set from the corresponding arguments  a list, instructors, of new Instructor instances was created for each author in authors  for each instructor in instructors, instructor.name was set to the corresponding author in authors  rubric was associated with instructors  rubric was associated with assignment

Add Requirement Q6 cont. Operation addRequirement(rubric, requirement) Cross References Use Case: Create Assignment Preconditions rubric is an existing Rubric in the system Postconditions  requirement was appended to rubric.requirements

Exercise on Design Examples Break up into your project teams Given the following:  The interaction diagrams you drew above, etc. Draw a partial Design Class Diagram to represent createNewAssignment, AddSubmission, etc.