Oct. 9, 2003CS WPI1 CS 509 Design of Software Systems Lecture #6 Thursday, Oct. 9, 2003
Oct. 9, 2003CS WPI2 §Term Project administration §Questions §Quiz #3 §Review of Chapter 6 §System & Object Design Exercises Class Format for Today
Oct. 9, 2003CS WPI3 MC Project & Questions §Return Phase 2 documents §Questions? l About Term Project l From last week’s class l From the reading l Anything else?
Oct. 9, 2003CS WPI4 Quiz #3 Choose 5 questions to answer Or answer 6 for extra credit
Oct. 9, 2003CS WPI5 Chapter 6 System Design
Oct. 9, 2003CS WPI6 System Design Terminology §Decomposition §Subsystem (Vs. Class) §Control Flow §Access Control §Services Vs. Interfaces §Coupling Vs. Coherence / Cohesion §Layers & Partitions
Oct. 9, 2003CS WPI7 System Design §Focus: l Processes l Data structures l High level components §Challenges: l Managing conflicting criteria l Managing constraints
Oct. 9, 2003CS WPI8 Impact on Implementation §Coding complexity of subsystems §Cost of rework if design changes §Design of individual components should be delayed - Why?
Oct. 9, 2003CS WPI9 Software Architecture §Subsystem decomposition in terms of responsibilities §Dependencies among subsystems §Subsystem mapping to hardware §Policy decisions §Read & understand bullet list on page 171
Oct. 9, 2003CS WPI10 Subsystems Vs. Classes §Decompose system into simpler parts §Subsystems are composed of some number of classes §Complex subsystems may be further decomposed into smaller subsystems §How do you know when to stop?
Oct. 9, 2003CS WPI11 Services Vs. Interfaces §Service is a set of related operations that share a common purpose (Example?) §Interface is a specification (API) that includes: l Names of operations l Parameter names & types l Return values
Oct. 9, 2003CS WPI12 Focus of System Design §System Design focuses on defining services §Object Design focuses on defining interfaces §During System Design, keep it high level l Focus on services rather than implementation details l Why?
Oct. 9, 2003CS WPI13 Trade-off of conflicting goals §Sometimes increasing coherence also increases coupling – why? §Want a balance between high coherence and low coupling – how can we do both?
Oct. 9, 2003CS WPI14 Layers Vs. Partitions §Both are ways to manage complexity §Layers are hierarchical; partitions are not §Each layer uses services provided by which other layer(s)? §Layers have no knowledge of which other layer(s)? §Define: Closed Architecture Vs. Open l See diagrams on pages 180, 181
Oct. 9, 2003CS WPI15 Layers & Partitions Cont’d §Partitions are responsible for different classes of services §Which to use: Layers or Partitions? l Usually both l How do we know which to use when? §How much is too much? “Excessive partitioning or layering can lead to increased complexity.” Explain.
Oct. 9, 2003CS WPI16 System Design Exercise #1 §Last time we began to design an Internet Browser system. l Reconstruct high-level architecture l How would we represent this in terms of packages? l Should we use layers or partitions? l What services are provided by each subsystem?
Oct. 9, 2003CS WPI17 System Design Exercise #2 §High level architecture for a different type of system: l Word Processor l File System Explorer l E-commerce (e.g., Amazon.com) l Other ideas?
Oct. 9, 2003CS WPI18 Object Design Exercise #3 §Start with one of the System designs §Choose a single subsystem to focus on §Break down into smaller components §Focus on how services will be provided l Division of responsibility Which objects do what? l What interfaces are required between objects?
Oct. 9, 2003CS WPI19 For Next Time Chapter 7 Object Design