Shanghai Jiao Tong University 上海交通大学 Object Oriented Analysis and Design Subsystem Design 上海交通大学软件工程中心
Shanghai Jiao Tong University 上海交通大学软件工程中心 Object Oriented Analysis and Design Subsystem Design
Subsystem Design in Context [Early Elaboration [Inception Iteration] Iteration (Optional)] Define a Candidate Perform Architecture Architectural L Synthesis Analyze Behavior (Optional) Refine the Architecture Subsystem Design Designer Define Design the Components Database Object Oriented Analysis and Design 2
Object Oriented Analysis and Design 2 Subsystem Design in Context [Early Elaboration Iteration] [Inception Iteration (Optional)] Define a Candidate Architecture Perform Architectural Synthesis Analyze Behavior Refine the Architecture Define Components Design the Database (Optional) Subsystem Design Designer
Subsystem Design Overview Design Subsystems and Interfaces Subsystem Project Specific Design Guidelines Design Classes Object Oriented Analysis and Design 3
Object Oriented Analysis and Design 3 Subsystem Design Overview Subsystem Design Design Subsystems and Interfaces Design Classes Project Specific Guidelines
Review:Subsystems and Interfaces A Subsystem: ◆lsa“cross between”a package and a class Realizes one or more interfaces that define its behavior > > Interface Subsystem Name Realization(Canonical form) Interface Subsystem > Subsystem Name Interface Realization (Elided form) Object Oriented Analysis and Design
Object Oriented Analysis and Design 4 A Subsystem: Is a “cross between” a package and a class Realizes one or more interfaces that define its behavior > Subsystem Name Interface Subsystem > Subsystem Name Interface Realization (Canonical form) Realization (Elided form) > Interface Review: Subsystems and Interfaces
Subsystem Guidelines ◆( Goals Loose coupling > A -Portability,plug-and-play compatibility Insulation from change Independent evolution > ◆ Strong Suggestions B Do not expose details,only interfaces Depend only on other interfaces > C Key is abstraction and encapsulation Object Oriented Analysis and Design 5
Object Oriented Analysis and Design 5 Key is abstraction and encapsulation A > B > C > Subsystem Guidelines Goals ▪ Loose coupling ▪ Portability, plug-and-play compatibility ▪ Insulation from change ▪ Independent evolution Strong Suggestions ▪ Do not expose details, only interfaces ▪ Depend only on other interfaces
Review:Modeling Convention for Subsystems and Interfaces > CourseCatalogSystem ICourseCatalog System >package >class Interfaces start with an "I" > CourseCatalogSystem > ICourseCatalogSystem Interfaces are EXTERNAL to the subsystem. Object Oriented Analysis and Design 6
Object Oriented Analysis and Design 6 Review: Modeling Convention for Subsystems and Interfaces CourseCatalogSystem > ICourseCatalogSystem ICourseCatalogSystem > CourseCatalogSystem Interfaces start with an “I” > > package > class Interfaces are EXTERNAL to the subsystem
Outline Distribute subsystem behavior to ◆ subsystem elements Document subsystem elements ◆ Describe subsystem dependencies Object Oriented Analysis and Design 7
Object Oriented Analysis and Design 7 Outline Distribute subsystem behavior to subsystem elements Document subsystem elements Describe subsystem dependencies
Outline Distribute subsystem behavior to subsystem elements Document subsystem elements ◆ Describe subsystem dependencies Object Oriented Analysis and Design 8
Object Oriented Analysis and Design 8 Outline Distribute subsystem behavior to subsystem elements Document subsystem elements Describe subsystem dependencies
Subsystem Responsibilities ◆ Subsystem responsibilities defined by interface operations Model interface realizations O Interface operations may be realized by Internal class operations Internal subsystem operations > ICourseCatalogSystem > CourseCatalogSystem getCourseOfferings() subsystem responsibility Object Oriented Analysis and Design 9
Object Oriented Analysis and Design 9 Subsystem responsibilities defined by interface operations ▪ Model interface realizations Interface operations may be realized by ▪ Internal class operations ▪ Internal subsystem operations CourseCatalogSystem ICourseCatalogSystem > getCourseOfferings() > subsystem responsibility Subsystem Responsibilities
Distributing Subsystem Responsibilities ldentify new,or reuse existing,design elements (for example,classes and/or subsystems) ◆ Allocate subsystem responsibilities to design elements ◆ Incorporate applicable mechanisms (for example, persistence,distribution) Document design element collaborations in "interface realizations ■ One or more interaction diagrams per interface operation Class diagram(s)containing the required design element relationships ◆Revisit“Identify Design Elements” ■ Adjust subsystem boundaries and dependencies,as needed Object Oriented Analysis and Design 10
Object Oriented Analysis and Design 10 Distributing Subsystem Responsibilities Identify new, or reuse existing, design elements (for example, classes and/or subsystems) Allocate subsystem responsibilities to design elements Incorporate applicable mechanisms (for example, persistence, distribution) Document design element collaborations in “interface realizations” ▪ One or more interaction diagrams per interface operation ▪ Class diagram(s) containing the required design element relationships Revisit “Identify Design Elements” ▪ Adjust subsystem boundaries and dependencies, as needed