Object oriented Analysis &Design面向对象分析与设计Lecture_08 GRASP 主讲: 陈小红 2 Artifact Influences Design 3 Design Supplementary Specs Glossary Data dictionary Use Case under development, with System Sequence Diagram (System operations) and Contracts Conceptual Model Interactions, class diagram, etc Packages How? OOD After identifying your requirements and creating a domain model, then add methods to the appropriate classes, and define the messaging between the objects to fulfill the requirements 4 Requirement? requirement Use case/ SSD SytemEvent/ OC SystemEvent/ OC Use case/… SSD Use case/ SSD SystemEvent/ OC 5 ? OO System - objects collaborating to respond to System Events 6 System System Event How to judge whether it is finished or not? Operation Contract Input /Output 7 How to assign? In the process Refer to domain model to assign task to objects and make them collaborating with each other 8 How to evaluate whether it is a good design? High cohesion Low coupling 9 Back to OODRealisation ways The problem is Above advice is too general to be handled Deciding what methods belong to where and how objects should interact carries consequences and should be undertaken seriously responsibility-driven design (RDD) thinking about how to assign responsibilities to collaborating objects 10