CMSC 345 Fall 2000 Design Issues. Modularity and Abstraction Characteristic of all design methods Components have clearly defined inputs and outputs,

Slides:



Advertisements
Similar presentations
Testing Relational Database
Advertisements

Ch:8 Design Concepts S.W Design should have following quality attribute: Functionality Usability Reliability Performance Supportability (extensibility,
Quality of a Class Abstraction: Coupling & Cohesion Michael L. Collard, Ph.D. Department of Computer Science Kent State University.
Structured Design. 2 Design Quality – Simplicity “There are two ways of constructing a software design: One is to make it so simple that there are obviously.
Lecture # 2 : Process Models
The software process A software process is a set of activities and associated results which lead to the production of a software product. This may involve.
Communication between modules, cohesion and coupling
Design Concepts and Principles
1 Software Design Introduction  The chapter will address the following questions:  How do you factor a program into manageable program modules that can.
What is Software Design?  Introduction  Software design consists of two components, modular design and packaging.  Modular design is the decomposition.
Copyright Irwin/McGraw-Hill Software Design Prepared by Kevin C. Dittman for Systems Analysis & Design Methods 4ed by J. L. Whitten & L. D. Bentley.
© Copyright 2011 John Wiley & Sons, Inc.
Design Creative Process of transferring the problem into a solution
Designing the system Conceptual design and technical design
Jump to first page 1 System Design (Finalizing Design Specifications) Chapter 3d.
PowerPoint Presentation for Dennis & Haley Wixom, Systems Analysis and Design Copyright 2000 © John Wiley & Sons, Inc. All rights reserved. Slide 1 Key.
Chapter 1 Principles of Programming and Software Engineering.
© 2006 Pearson Addison-Wesley. All rights reserved2-1 Chapter 2 Principles of Programming & Software Engineering.
CH05: Designing the System To design a system is to determine a set of components and inter-component interfaces that satisfy a specified set of requirements.
Introduction to Computer Technology
Systems Analysis and Design
Why Analysis Process Refer to earlier chapters Models what the system will do makes it easier for understanding no environment considered (hence, system.
CSE 303 – Software Design and Architecture
Team Skill 6: Building the Right System From Use Cases to Implementation (25)
Coupling and Cohesion Pfleeger, S., Software Engineering Theory and Practice. Prentice Hall, 2001.
 2004 by SEC Chapter 4 Software Design. 2  2004 by SEC Chapter 4 Software Design 4.1 Design Fundamentals 4.2 Design Method 4.3 Architecture Design
Program Design Simple Program Design Third Edition A Step-by-Step Approach 9.
SOFTWARE DESIGN (SWD) Instructor: Dr. Hany H. Ammar
SOFTWARE DESIGN.
1 Software Design Reference: Software Engineering, by Ian Sommerville, Ch. 12 & 13, 5 th edition and Ch. 10, 6 th edition.
SOFTWARE DESIGN Design Concepts Design is a meaningful engineering representation of something that is to be built It can be traced to a customer’s requirements.
1 Software Design Overview Reference: Software Engineering, by Ian Sommerville, Ch. 12 & 13.
SE: CHAPTER 7 Writing The Program
Cohesion and Coupling CS 4311
Systems analysis and design, 6th edition Dennis, wixom, and roth
System Implementation
Requirements as Usecases Capturing the REQUIREMENT ANALYSIS DESIGN IMPLEMENTATION TEST.
Coupling & Cohesion CMSC 201- Fall '11. Vocabulary Routine- A programming unit that performs a task, such as a function, procedure, method, or main class.
Design Concepts and Principles Instructor: Dr. Jerry Gao.
PowerPoint Presentation for Dennis, Wixom, & Roth Systems Analysis and Design, 3rd Edition Copyright 2006 © John Wiley & Sons, Inc. All rights reserved.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 20 Slide 1 Critical systems development 3.
Design Concepts By Deepika Chaudhary.
CCSB223/SAD/CHAPTER131 Chapter 13 Designing the System Internals.
© 2006 Pearson Addison-Wesley. All rights reserved2-1 Chapter 2 Principles of Programming & Software Engineering.
© 2006 Pearson Addison-Wesley. All rights reserved 2-1 Chapter 2 Principles of Programming & Software Engineering.
Conceptual design Tells the customer what the system will do Tells the customer what the system will do Answers: Answers: Where will the data come from?
Software Engineering Issues Software Engineering Concepts System Specifications Procedural Design Object-Oriented Design System Testing.
Systems Design.  Application Design  User Interface Design  Database Design.
Testing Overview Software Reliability Techniques Testing Concepts CEN 4010 Class 24 – 11/17.
Chapter 9: Coupling & Cohesion Omar Meqdadi SE 273 Lecture 9 Department of Computer Science and Software Engineering University of Wisconsin-Platteville.
SOFTWARE DESIGN & SOFTWARE ENGINEERING Software design is a process in which data, program structure, interface and their details are represented by well.
Coupling and Cohesion Schach, S, R. Object-Oriented and Classical Software Engineering. McGraw-Hill, 2002.
Coupling and Cohesion Pfleeger, S., Software Engineering Theory and Practice. Prentice Hall, 2001.
Software Engineering 2007/2008 Chapter 5 Designing the System.
7. Modular and structured design
Coupling and Cohesion Rajni Bhalla.
Coupling and Cohesion 1.
Lecture 9- Design Concepts and Principles
Basic Concepts in Software Design
Software Design Mr. Manoj Kumar Kar.
Systems Analysis and Design
Cohesion and Coupling Chapter 5, Pfleeger 01/01/10.
Designing and Debugging Batch and Interactive COBOL Programs
Chapter 5 Designing the Architecture Shari L. Pfleeger Joanne M. Atlee
CS223: Software Engineering
Software Design CMSC 345, Version 1/11.
Lecture 9- Design Concepts and Principles
Software Design Lecture : 9.
Applying Use Cases (Chapters 25,26)
Cohesion and Coupling.
Presentation transcript:

CMSC 345 Fall 2000 Design Issues

Modularity and Abstraction Characteristic of all design methods Components have clearly defined inputs and outputs, and clearly stated purpose Easy to examine each component separately Organized in hierarchy so system can be investigated one level at a time Components at one level refine those in the level above More abstract top levels hide detail of lower level functional or data components

Information Hiding Components hide internal details and processing from one another Each hides a specific design decision Allows to isolate complex parts of problem, where “decisions” need to be made Possible to use different design methods within different components When a hidden design decision changes, only that component must be changed The rest of the design remains intact

Collaborative Design Most designs created by teams Determine who is best suited to design each aspect of system Document each subsystem design so understandable by other team members Coordinate design components so work well as unified whole The Problem: differences in experience, understanding and prefrence

Trends Toward Collaborative Teams Cut costs and maximize productivity 1. Project performed at single site with on-site developers from multiple locations 2. On-site analysts determine requirements, then off- site groups of designers and programmers continue 3. Off-site developers build generic products and components used worldwide 4. Off-site developers build components that take advantage of their areas of expertise Contrary to iterative feedback among phases Introduces difficult communication problems

Designing User Interface Metaphors: fundamental terms, images, and concepts to be recognized and learned Mental model: organization/representation of data, functions, tasks, roles Navigation rules: how to move among data, functions, activities, roles Look: characteristics of appearance that convey information to the user Feel: interaction techniques the provide appealing experience for user

Characteristics of Good Design High-quality design lead to quality products 1. Ease of understanding 2. Ease of implementation 3. Ease of testing 4. Ease of modification 5. Correct translation from requirments 6. Modifiability

Component Independence Abstraction and Information Hiding allow us to examine ways that components are related Strive to make components as independent as possible Easier to understand if not tied to others Easier to modify if independent Easier to isolate and fix problems

Component Coupling Highly coupled = great deal of dependence between components Loosely coupled = some dependence but interconnections are weak Uncoupled = no interconnections at all

Uncoupled - no dependencies Highly coupled - many dependencies Loosely coupled - some dependencies

How components are coupled References from one component to another, such as invocation Amount of data passed from one component to another Amount of control one component has over another Degree of complexity of interface, e.g., one entry point vs. mutual entry points

Goal is to Minimize Coupling Enables to change portion of system while disrupting rest of system little as possible Very low coupling might allow pull-out, plug- in replacement of only one component Loose coupling may require changing or replacing a few components High coupling may require widespread perturbations in system Low coupling reduces the number of components needing revision

Types of Coupling Content: one component directly modifies data or control flow of another Common: Organizing data into a common store Control: Control flags passed as parameters between components Stamp: Data structures passed Data: Only primitive data passed

HIGH COUPLING LOW LOOSE Data coupling Stamp coupling Uncoupled Control coupling Common coupling Content coupling

A BC DE Component B Go to D1 Component D Go to D1 D1: Content Coupling

Global: A1 A2 A3 Variables: V1 V2 Common data area and variable names Component XComponent YComponent Z Change V1 to zero Increment V1 V1 = V2 + A1 Common Coupling

Maximize Cohesion Cohesion: the degree of interrelatedness of internal parts. All elements of the component are directed towards and essential for the same task

Degrees of Cohesion Coincidental: component’s parts unrelated Logical: logically related functions and/or data placed in same component Temporal: performs several functions in sequence, related only by timing (not ordering) Procedural: functions grouped together to ensure mandatory ordering Communicational: functions operate on or produce same data set Sequential: output from one function is input to next Functional: every processing element essential to single function, and all such essential elements contained in one component

HIGH COHESION LOW Logical Temporal Coincidental Procedural Communicational Sequential Functional

COINCIDENTAL Parts unrelated FUNCTION A FUNCTION B FUNCTION D FUNCTION C FUNCTION E LOGICAL Similar functions FUNCTION A FUNCTION A’ FUNCTION A” logic

TEMPORAL Related by time TIME T0 TIME T0 + X TIME T0 + 2X PROCEDURAL Related by order of functions FUNCTION A FUNCTION B FUNCTION C

COMMUNICATIONAL Access Same Data FUNCTION A FUNCTION B FUNCTION C SEQUENTIAL Output of one part is Input to the next FUNCTION A FUNCTION B FUNCTION C DATA

FUNCTIONAL Sequential with complete, related functions FUNCTION A Part 1 FUNCTION A Part 2 FUNCTION A Part 3

Control Issues Scope of control: set of components supposed to be invoked by another Scope of effect: set of components actually invoked by another Scope of effect should be fully within scope of control

Fans Fan-in: number of components controlling a particular component Fan-out: number of components controlled by a given component Minimize components with high fan-out Probably doing too much, performing more than one function High fan-in should be limited to utility components Goal – High fan-in; low fan-out

A BCD EFG System 1 A BCD EF G System 2

Exceptions “Defensive design”: actively anticipate situations that may lead to problems Make explicit what the system is not supposed to do Not easy to define Should do what it is required to do “but no more” Not easy to define or test Exception: situation counter to what system should do. Typical exceptions: Failure to provide service or data Providing wrong service or data Corrupting data

Exception Handling Retry: restore system to previous state and try again using a different strategy Correct: restore to previous state, correct some aspect, and try again (same strategy) Report: restore to previous state, report problem, and do not provide service

Faults and Failures Fault = error internal to software product Failure = department of system from required behavior Not every fault corresponds to failure, since conditions under which fault leads to failure may never occur

Fault Detection Passive fault detection wait until failure occurs, then do something Active fault detection periodically check for symptoms of faults or try to anticipate failures Mutual suspicion policy = each component assumes other components contain faults Check all inputs for correctness and consistency Fault handled when discovered rather than propagated Limits damage

N-version programming Compare results of multiple processes performing same function but designed separately May not help, since designers often use similar patterns and techniques Diagnostic Transactions Second system monitoring or running diagnostics on first

Fault Correction Compensate for fault’s presence Halt system and fix problem Not acceptable for some applications Note problem and fix later May allow additional damage System criticality determines strategy

Fault Tolerance Correcting fault too expensive, risky or inconvenient Minimize damage and carries on Relies on ability to predict location of faults and timing of failures To build work-around into system design we must be able to guess what may go wrong

Design Reviews Preliminary design review: examine conceptual design with customers/users Critical design review: present technical design to other developers Program design review: feedback to programmers before implementation Egoless: comments and criticism directed at process and product, not designers or other participants

Preliminary Design Review Validation: Make sure all requirements addressed by design Moderator leads discussion but has no vested interest Secretary records main points and outcome Developers not involved in project provide objective outsider’s perspective Customer approves dialogs, menus, report formats, fault handling, etc. Resolve minor issues as appear, major problems lead to design revision and another review

Critical Design Review Addresses technical details Two major questions Does design implement all requirements? Is design of high quality? Program designers need to understand, to derive more detailed designs Explain alternative design strategies and how/why of major design decisions If major problems identified, then revise and re-review

Program Design Review Program designers treat technical design as design descriptions for components to be coded and tested Present coding plans before coding begins

Value of Design Reviews Detecting (not correcting) faults when it is easy and inexpensive to fix By investigating the integrity of the design (not the designers), we emphasize that we are all working together towards the same goal Answers important questions (see text pg )