├── .gitattributes ├── .gitignore ├── README.md └── Software-Engineering-Notes ├── Chapter-01-软件的本质 ├── Chapter 1 软件的本质The Nature of Software f3b292031e104a2db6ff36bb3652661e.md └── Chapter 1 软件的本质The Nature of Software f3b292031e104a2db6ff36bb3652661e │ ├── Untitled 1.png │ └── Untitled.png ├── Chapter-02-软件工程 ├── Chapter 2 软件工程Software Engineering e4457513b79c4c11883e7210ae950571.md └── Chapter 2 软件工程Software Engineering e4457513b79c4c11883e7210ae950571 │ ├── Untitled 1.png │ ├── Untitled 2.png │ ├── Untitled 3.png │ ├── Untitled 4.png │ ├── Untitled 5.png │ ├── Untitled 6.png │ └── Untitled.png ├── Chapter-03-软件过程 ├── Chapter 3 软件过程Software Process e7160395fe3c4f20856e027664643d8a.md └── Chapter 3 软件过程Software Process e7160395fe3c4f20856e027664643d8a │ ├── Untitled 1.png │ ├── Untitled 2.png │ ├── Untitled 3.png │ ├── Untitled 4.png │ ├── Untitled 5.png │ ├── Untitled 6.png │ ├── Untitled 7.png │ └── Untitled.png ├── Chapter-04-过程模型 ├── Chapter 4 过程模型Process Models fd63f7899930489c87ef2d9e58174036.md └── Chapter 4 过程模型Process Models fd63f7899930489c87ef2d9e58174036 │ ├── Untitled 1.png │ ├── Untitled 2.png │ ├── Untitled 3.png │ ├── Untitled 4.png │ ├── Untitled 5.png │ ├── Untitled 6.png │ ├── Untitled 7.png │ └── Untitled.png ├── Chapter-05-敏捷开发 ├── Chapter 5 敏捷开发Agile Development f3a7f28d875b47c38c04a1a9be8995c0.md └── Chapter 5 敏捷开发Agile Development f3a7f28d875b47c38c04a1a9be8995c0 │ ├── Untitled 1.png │ ├── Untitled 2.png │ ├── Untitled 3.png │ └── Untitled.png ├── Chapter-07-软件工程实践原则 ├── Chapter 7 软件工程实践原则Principles that guide practice bdaa5daeb0ba495e9391e6345636ede2.md └── Chapter 7 软件工程实践原则Principles that guide practice bdaa5daeb0ba495e9391e6345636ede2 │ └── Untitled.png ├── Chapter-08-需求 ├── Chapter 8 需求 Requirements fc5282f7a6e448868636cd812680ab31.md └── Chapter 8 需求 Requirements fc5282f7a6e448868636cd812680ab31 │ ├── Untitled 1.png │ ├── Untitled 2.png │ ├── Untitled 3.png │ ├── Untitled 4.png │ ├── Untitled 5.png │ ├── Untitled 6.png │ └── Untitled.png ├── Chapter-09-需求建模:场景建模 ├── Chapter 9 需求建模:基于场景的方法Requirement Modeling Scenari 78c266846b814885bf8d6faa700c2ddf.md └── Chapter 9 需求建模:基于场景的方法Requirement Modeling Scenari 78c266846b814885bf8d6faa700c2ddf │ ├── Untitled 1.png │ ├── Untitled 2.png │ ├── Untitled 3.png │ ├── Untitled 4.png │ └── Untitled.png ├── Chapter-10-需求建模:类的建模 ├── Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682.md └── Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682 │ ├── Untitled 1.png │ ├── Untitled 10.png │ ├── Untitled 11.png │ ├── Untitled 12.png │ ├── Untitled 13.png │ ├── Untitled 14.png │ ├── Untitled 15.png │ ├── Untitled 2.png │ ├── Untitled 3.png │ ├── Untitled 4.png │ ├── Untitled 5.png │ ├── Untitled 6.png │ ├── Untitled 7.png │ ├── Untitled 8.png │ ├── Untitled 9.png │ └── Untitled.png ├── Chapter-11-需求模型:行为,模式和Web:Mobile应用 ├── Chapter 11 需求模型:行为,模式和Web Mobile应用Behavior, Patter faa232a97269449cb6ce53579e561f36.md └── Chapter 11 需求模型:行为,模式和Web Mobile应用Behavior, Patter faa232a97269449cb6ce53579e561f36 │ ├── Untitled 1.png │ ├── Untitled 2.png │ ├── Untitled 3.png │ ├── Untitled 4.png │ └── Untitled.png ├── Chapter-12-设计理念 ├── Chapter 12 设计概念 Design Concepts 66a797a2ef8d4dce83eb09e546473079.md └── Chapter 12 设计概念 Design Concepts 66a797a2ef8d4dce83eb09e546473079 │ ├── Untitled 1.png │ ├── Untitled 2.png │ ├── Untitled 3.png │ ├── Untitled 4.png │ ├── Untitled 5.png │ ├── Untitled 6.png │ ├── Untitled 7.png │ └── Untitled.png ├── Chapter-13-概要设计 ├── Chapter 13 概要设计Architectural Design 9e4603d4be424c0a9a80eae7a68bd514.md └── Chapter 13 概要设计Architectural Design 9e4603d4be424c0a9a80eae7a68bd514 │ ├── Untitled 1.png │ ├── Untitled 10.png │ ├── Untitled 2.png │ ├── Untitled 3.png │ ├── Untitled 4.png │ ├── Untitled 5.png │ ├── Untitled 6.png │ ├── Untitled 7.png │ ├── Untitled 8.png │ ├── Untitled 9.png │ └── Untitled.png └── Chapter-14-详细设计 ├── Chapter 14 详细设计Component-Level Design 773b02d5513548fe811ce52375e9a92c.md └── Chapter 14 详细设计Component-Level Design 773b02d5513548fe811ce52375e9a92c ├── Untitled 1.png ├── Untitled 10.png ├── Untitled 11.png ├── Untitled 12.png ├── Untitled 2.png ├── Untitled 3.png ├── Untitled 4.png ├── Untitled 5.png ├── Untitled 6.png ├── Untitled 7.png ├── Untitled 8.png ├── Untitled 9.png └── Untitled.png /.gitattributes: -------------------------------------------------------------------------------- 1 | # Auto detect text files and perform LF normalization 2 | * text=auto 3 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | 2 | .DS_Store 3 | Software-Engineering-Notes/.DS_Store 4 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Software-Engineering-Notes 2 | 教材: *Software Engineering: A Practitioner's Approach (Eighth Edition)* 3 | 4 | 授课教师:*Prof. Du Qingfeng* 5 | 6 | 同济大学软件学院软件工程课堂笔记&期末复习要点 7 | 8 | 希望能帮助软院人省下时间来做更有意义的事情嗯... 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-01-软件的本质/Chapter 1 软件的本质The Nature of Software f3b292031e104a2db6ff36bb3652661e.md: -------------------------------------------------------------------------------- 1 | # Chapter 1 软件的本质The Nature of Software 2 | 3 | ## 1.1 软件的本质 4 | 5 | 随笔 6 | 7 | - high-level design(概要设计/架构设计)——1. 软件的体系;2. 数据库/数据设计;3.接口设计 8 | 9 | (意义:概要文档对后续的维护有重要作用,因为它就是一个使用指南,可以进行错误定位) 10 | 11 | - 软件既是一种产品,也是交付产品的一个载体(产品和产品交付载体的双重角色) 12 | - error 交付之前——>failure 交付之后运行的结果不符合顾客的需求,failure可能由一个或多个error导致 13 | - 两种error错误检查的技术: **review technology** 评审技术; **testing technology** 测试技术 14 | - 软件开发的问题: 15 | - 开发时间(take so long) 16 | - 开发成本(cost so high) 17 | - 开发错误检查(find all errors) 18 | - 维护时间投入(spend time maintaining) 19 | - 开发进度评估测量(measure progress) 20 | 21 | ### 1.1.1 定义软件 22 | 23 | (要理解) 24 | 25 | 软件是什么: 26 | 27 | 1. 完成软件的特性,功能,性能等所需要的 **计算机程序,指令代码——程序** 28 | - feature特性: *非功能需求* non-functional:如安全性,兼容性,可移植性,可扩展性等 29 | - function功能:与非功能需求相对应 30 | - performance:feature的一部分,但因为很重要所以单拉出来 31 | 2. 使得程序可以充分利用操纵信息所使用的 **数据结构——数据** 32 | 3. 描述程序操作使用的硬拷贝和虚拟形式的 **描述性信息——文档** 33 | 34 | **软件与硬件的生命周期刻画曲线图:** 35 | 36 | 1. 硬件的生命周期 37 | 38 | 解读:浴缸曲线(早期的infant mortality是由于设计引起问题,当设计问题解决后可以平稳运行,直到硬件损耗,期间替换硬件不影响failure rate)***(早期故障多,后期磨损)*** 39 | 40 | ![Untitled](Chapter%201%20%E8%BD%AF%E4%BB%B6%E7%9A%84%E6%9C%AC%E8%B4%A8The%20Nature%20of%20Software%20f3b292031e104a2db6ff36bb3652661e/Untitled.png) 41 | 42 | 2. 软件的生命周期 43 | 44 | 解读:理想曲线——开发后可以一致运行; 45 | 46 | 实际曲线——考虑:1.功能增强的update;2. 功能修改和错误修复modify & bug fixed 47 | 48 | 不断改变后failure rate的突然上升与总体上升: 修改change后导致其他新的问题出现,有"传染性"错误的可扩展性,这是功能调整增强的代价 **(错误的扩展性,修复某问题的副作用 )** 49 | 50 | ![Untitled](Chapter%201%20%E8%BD%AF%E4%BB%B6%E7%9A%84%E6%9C%AC%E8%B4%A8The%20Nature%20of%20Software%20f3b292031e104a2db6ff36bb3652661e/Untitled%201.png) 51 | 52 | 53 | ※**DevOps: 现在开发常用的开发框架** 54 | 55 | development in Operations: 软件开发人员(Dev)和订正人员(Ops)之间的沟通合作 56 | 57 | ※**微服务**: 58 | 59 | 将整个Web应用组织为一系列小的Web Service,这些小的Web Service可以独立的编译部署,并通过各自的API接口相互通信,彼此相互协作,作为一个整体为用户提供服务,但可以独立进行扩展。 60 | 61 | 优点:一个微服务出错不会影响其他 62 | 63 | ### 1.1.2 软件应用领域 64 | 65 | (软件的领域划分) 66 | 67 | - System Software系统软件:操作系统软件(应用软件运行在这之上)——算法核心 68 | - Application Software应用软件:解决特定需求的独立应用程序。 69 | - Engineering/scientific Software工程/科学软件:例如matlab 70 | - Embedded Software嵌入式软件:例如家电内部的,汽车内部的 ——操作系统特殊,硬件交互性强,错误较难以定义 71 | - Product-line Software产品线软件:为不同用户提供特定功能 72 | - Web/mobile App:browser-based 73 | - AI Software人工智能软件:机器人,博弈,模式识别(语音图像),自动驾驶,自然元素处理(文本) 74 | 75 | ### 1.1.3 遗留软件Legacy Software 76 | 77 | (重要) 78 | 79 | 特点:年龄大(太老了),业务关键性(数据难以移植,风险大,很少重新开发) 80 | 81 | 描述:**1.老旧软件; 2. 不断变更以适配需求——臃肿; 3. 质量差,代码可读性差,文档混乱** 82 | 83 | ※遗留系统演化原因:(考试会根据这些设计情景,比如银行系统) 84 | 85 | - A需要进行适应性调整,满足新的计算环境和计算需求(比如:密码升级到指纹) **new tech adapted** 86 | - U升级以实现商业需求 **enhanced implementation** 87 | - E扩展使得可以与更多的系统交互,如现代系统或数据库 **extend** 88 | - A架构需要重新部署来适应新环境(例如下面以前没有mobile,或部 署微服务框架等) **re-architected** 89 | 90 | ## 1.2 软件的演变 91 | 92 | 四大类软件正在发展成主流: 93 | 94 | ※练习:Web技术的发展 95 | 96 | 标红的部分 97 | 98 | - **网页应用WebApp** 99 | 100 | by looking up information, to learn the history of web development.(web1.0~web3.0) 101 | 102 | - **移动设备Mobile Application** 103 | 104 | 在大多数情况下,移动应用程序包含用户界面、与基于 Web 的资源的互操作性和本地处理能力( 对本地的存储和信息进行计算处理 ),还可提供长久的存储能力;移动网络应用程序和移动应用程序之间存在细微的区别:前者浏览器,后者可以直接获取设备硬件信息提供本地处理与存储能力 105 | 106 | 在大多数例子中,移动应用建立一个user interface,以及和网页资源的可交互性(interoperability)和本地处理能力 107 | 108 | - **云计算Cloud Computing 考试看看** 109 | 110 | 云平台:IaaS层(资源层)-虚拟机(跨IaaS与PaaS)->Paas层(平台层:资源监测;预警;优化决策)-->SaaS层(软件,可视化界面) 111 | 112 | - **产品线软件** 113 | 114 | (简单看看即可) 115 | 116 | 练习: 117 | 118 | - Web1.0-3.0 119 | - DevOps 120 | - 微服务 121 | - SOA 122 | - 云计算 -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-01-软件的本质/Chapter 1 软件的本质The Nature of Software f3b292031e104a2db6ff36bb3652661e/Untitled 1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-01-软件的本质/Chapter 1 软件的本质The Nature of Software f3b292031e104a2db6ff36bb3652661e/Untitled 1.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-01-软件的本质/Chapter 1 软件的本质The Nature of Software f3b292031e104a2db6ff36bb3652661e/Untitled.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-01-软件的本质/Chapter 1 软件的本质The Nature of Software f3b292031e104a2db6ff36bb3652661e/Untitled.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-02-软件工程/Chapter 2 软件工程Software Engineering e4457513b79c4c11883e7210ae950571.md: -------------------------------------------------------------------------------- 1 | # Chapter 2 软件工程Software Engineering 2 | 3 | 开发软件前必须知道的事实: 4 | 5 | - 要明确问题 6 | - 设计是关键活动 7 | - 软件必须展现高质量 8 | - 软件必须可维护 9 | 10 | 质量保证的一些做法:**review, SQA(software quality application)(使用checklist)** 11 | 12 | ## 2.1 定义 13 | 14 | ※ IEEE 的软件工程定义: 15 | 16 | 1. SDQ(系规量) 将系统的systematic、规范的disciplined(遵守各种规则,如设计模式,编码规则等)、可量化quantifiable(软件工程里最重要的概念之一)的方法应用于软件的开发、运行和维护; 也就是说,**工程在软件中的应用The application of engineering to software,以开发,使用,维护软件** 17 | 2. 对(1)中的研究方法 18 | 19 | 可量化quantifiable的例子(定量了解项目的开发情况):三个人公司实习,把设计转为代码,系统对你们代码量测试,发现每一个人千行代码平均错误为20、10、5个,这就是通过软件工程思想进行可量化管理 20 | 21 | ![Untitled](Chapter%202%20%E8%BD%AF%E4%BB%B6%E5%B7%A5%E7%A8%8BSoftware%20Engineering%20e4457513b79c4c11883e7210ae950571/Untitled.png) 22 | 23 | 把所有软件工程的工具通常为CASE(计算机辅助软件工程):computer-aided software engineering 24 | 25 | 为过程和方法提供自动化或半自动化的支持 26 | 27 | ※软件工程层次 28 | 29 | 对软件工程进一步的抽象分成4个层次: 30 | 31 | ![Untitled](Chapter%202%20%E8%BD%AF%E4%BB%B6%E5%B7%A5%E7%A8%8BSoftware%20Engineering%20e4457513b79c4c11883e7210ae950571/Untitled%201.png) 32 | 33 | - Q质量: 为什么要有软件工程⇒因为要提高软件的质量,***质量是根基*** 34 | - P过程化:回答了如何提高质量的问题 35 | - M方法:方法贯穿于过程中,eg:**UseCase建模,数据库设计方法,架构方法,分析方法,设计方法,测试方法**等多种方法 36 | - T工具:现在很多方法和技术都工具化了 37 | 38 | ## 2.2 软件过程Software Process 39 | 40 | (重要) 41 | 42 | **对Process的分解:Process—细分为若干→Activity—细分为若干→Action—细分为最小的→task** 43 | 44 | task是最小单元,原子性,高内聚 45 | 46 | 粒度划分: 47 | 48 | - Activity: 力求实现一个广泛的目标——e.g:stakeholder的沟通 49 | - Action: 包含一组产生主要工作产品的任务——e.g:架构设计;一个action要有主要工作产品work product(e.g 架构模型) 50 | - Task: 侧重于产生实际结果的小而明确的目标——e.g:单元测试 51 | 52 | 提问:不同activity, activity的不同action,action的不同task之间的关系?(start-start/start-finish/finish-start) 53 | 54 | 回答:实际情况下,三个关系都有可能发生 55 | 56 | 一个例子: 57 | 58 | Activities:RG过程的一个Activity 59 | 60 | Actions: 小的project,比如上报需求到负责人,开一次腾讯会议 61 | 62 | Tasks:比如:制定会议室时间等 63 | 64 | **架构的三大任务:体系架构设计,接口设计,数据与数据结构设计** 65 | 66 | ### 2.2.1 过程框架Process Framework 67 | 68 | 两大过程: 69 | 70 | - 框架构成Framework Activity: 正常的开发活动(需求调研,需求分析,设计,coding等) 71 | - 伞型活动Umbrella Activity 72 | 73 | milestone:里程碑,经过framework activity和umbrella activity后可以交付给下一个阶段 74 | 75 | ※软件工程的通用过程框架包括五项活动: **CPMCD** 76 | 77 | 1. 交流communication:需求收集requirement gathering& 需求模型诱导 [elicitation](https://www.notion.so/Chapter-3-Software-Process-5d374199f4464c5ea6c52964d0e8cc80) 78 | 2. 计划Planing:planning是一个大的,阶段的计划(如人员安排等),有很多template 79 | 3. 建模Modeling:包括分析建模(Analysis modeling),概要设计(high-level design), component design 组件设计(detailed design),概要设计(high-level design) 80 | 4. 构建Construction:coding & testing 写代码&测试,测试包括单元测试,系统测试 81 | 5. 部署Deployment:delivery & maintenance & feedback 交付,维护,反馈 82 | 83 | 软件开发过程包括很多迭代,并不是线性顺序的模型,而是循环往复 84 | 85 | 86 | ※ **Standard Process包含的Activity** 87 | 88 | 1. **requirement elicitation 需求诱导** 89 | 2. **requirement analysis modeling 需求分析建模** 90 | 3. **architecture design 架构设计** 91 | 4. **component design 组件设计** 92 | 5. **coding 写代码** 93 | 6. **unit testing 单元测试** 94 | 7. **integration testing 集成测试** 95 | 8. **system testing 系统测试** 96 | 9. **acceptance testing 验收测试(用户在开发环境下的测试)** 97 | 10. **Release & Delivery,Feedback & Support 发布,部署,反馈,支持** 98 | 99 | 对应CPMCD: 100 | 101 | Communication: 1 102 | 103 | Planning:(umbrella activity) 104 | 105 | Modeling: 2、3、4 106 | 107 | Construction: 5、6、7、8、9 coding-5 testing 6-9 (UISA) 108 | 109 | Deployment:10 110 | 111 | ### 2.2.2 伞型活动Umbrella Activities 112 | 113 | 作用: 114 | 115 | 保障development activity有high quality,贯穿整个项目,不是单独活动 116 | 117 | 控制进度,保障质量,规避风险 118 | 119 | 导致changing的三个原因: 120 | 121 | - corrected: 122 | - adaptive: 适应性修改,比如法律等 123 | - enhanced: 增强功能,性能等 124 | 125 | 典型的伞活动: 126 | 127 | 1. **Software Project Tracking & Control** 软件项目跟踪控制(如:人员计划,发挥成员特长能力,了解人员是tracking,调整人力是control) 128 | 2. **Risk Management** 风险管理(quantity,是定量管理,risk exposure风险曝光度=probability(0-1)**loss(0-10)概率**损失(例如,人员流失跳槽风险,新技术,云平台不熟悉,数据库不熟悉等...)) 129 | 130 | (如何想到的:经验,原有项目,头脑风暴),算出的风险从高到低排序,并制定方案. 131 | 132 | 风险管理三个阶段:risk management是task但也是umbrella activity 133 | 134 | 1. I risk identification: 风险定位(头脑风暴,相关经验,专家建议) 135 | 2. M risk mitigation: 风险缓解 136 | 3. T risk tracking: 风险追踪 137 | 138 | ![Untitled](Chapter%202%20%E8%BD%AF%E4%BB%B6%E5%B7%A5%E7%A8%8BSoftware%20Engineering%20e4457513b79c4c11883e7210ae950571/Untitled%202.png) 139 | 140 | ![Untitled](Chapter%202%20%E8%BD%AF%E4%BB%B6%E5%B7%A5%E7%A8%8BSoftware%20Engineering%20e4457513b79c4c11883e7210ae950571/Untitled%203.png) 141 | 142 | ![Untitled](Chapter%202%20%E8%BD%AF%E4%BB%B6%E5%B7%A5%E7%A8%8BSoftware%20Engineering%20e4457513b79c4c11883e7210ae950571/Untitled%204.png) 143 | 144 | ![Untitled](Chapter%202%20%E8%BD%AF%E4%BB%B6%E5%B7%A5%E7%A8%8BSoftware%20Engineering%20e4457513b79c4c11883e7210ae950571/Untitled%205.png) 145 | 146 | ![Untitled](Chapter%202%20%E8%BD%AF%E4%BB%B6%E5%B7%A5%E7%A8%8BSoftware%20Engineering%20e4457513b79c4c11883e7210ae950571/Untitled%206.png) 147 | 148 | 3. **Software Quality Assurance** 软件质量保证——定义和实施确保软件质量所需的活动 ;(编程管理,代码规范,需求规约等)有Checklist 149 | 4. **Technical Review** 技术审查——特殊的quality assurance (比如代码Review,需求Review等) 150 | 5. **Measurement** 测量; 对schedule进行测量,对不同时间和schedule的偏差进行度量,对发现的缺陷进行度量,对人员工作量进行度量等 151 | 6. **Software configuration** 软件配置管理; 比如用 Github 进行管理 152 | 7. **Reusability Management** 可重用性管理(苹果的复用做的很好,通过标准化可以降低成本)---前提是重构,让代码和类标准化(可以复用); 153 | 8. **Work product preparation & production** 工作产品准备和生产——包括创建工作产品所需的活动,例如模型、文档、日志、表格和列表。 154 | 155 | 区分:measurement和metric----发现errors,ABCD任务errors计数是measure; ABCDE任务的errors求平均数等数学模型处理是metric(例子:项目进度,安排4个人分工协调,到时间时测量每个人完成度是measure,计算总体完成度是metric,以此制定下阶段目标) 156 | 157 | (TODO) 158 | 159 | ### 2.2.3 流程调整Process Adaptation 160 | 161 | (被调整和被裁减)应该是敏捷和适应性强的(针对问题、项目、团队和组织文化)。 因此,一个项目采用的过程可能与另一个项目采用的过程有很大不同 162 | 163 | 考试→给例子,应用概念来描述 164 | 165 | ※以下的活动可以在不同项目中做适应性调整 166 | 167 | - activity, action, task的总体流程(flow)以及它们之间的相互依存关系 168 | - action和task在每个framework activity中的定义程度 169 | - work product的定义要求的差别 170 | - QA质量保证Activity实施的方法 171 | - 项目跟踪控制和控制类Activity实施的方法 172 | - 过程progress描述的的严格和详细的程度 173 | - stakeholder的参与度(可能是使用完反馈,也可能是直接干预开发) 174 | - 团队的自主程度 175 | - 类似项目有没有类似经验 176 | 177 | (TODO) 178 | 179 | ## 2.3 软件工程实践 180 | 181 | ### 2.3.1 实践的精髓(Essence of practice) 182 | 183 | 4步: 184 | 185 | - 1.理解需求Understand the problem—— 186 | - 交流(requirement gathering) 187 | - 计划(planning) 188 | 189 | 实质:需求调研,需求工程(requirement engineering) 190 | 191 | 具体问题: 192 | 193 | 1.谁是项目的**利益相关者**; 194 | 195 | 2. **不确定因素,数据、功能和特性**(特性还包括一些非功能需求,如安全性,performance,都很重要); 196 | 197 | 3. 问题能否划分,需求能否分解,**减小粒度**(在UML里和Use Case,Class Diagram相关); 198 | 199 | 4.问题可以**可视化表现**吗(图),**分析模型(analysis model)**能否建立; 200 | 201 | - 2.计划解决方案Plan a solution—— 202 | - analysis 203 | - design modeling(Use Case, Class Diagram, Sequence Diagram, Activity Diagram, State Diagram) 204 | - 核心是:**Architecture Design & Component Design** 205 | 206 | 概况:根据上一个阶段的结果,进行建模(数据,功能等角度),提供一种解决方案(比如:框架,接口,界面,数据库的设计) 207 | 208 | 具体问题: 209 | 210 | 1. 有无**相似的模式**可以复用,(设计模式,相似项目,数据,功能,非功能需求等); 211 | 212 | 2.**类似的问题有无解决方法**,有无**可复用**的解决方案元素; 213 | 214 | 3. 子问题能否被定义,**子问题**的解是否显而易见的(软件架构); 215 | 216 | 4.能否以一种能够有效实施的方式来**表示解决方案**?能否创建**设计模型(design model)**? 217 | 218 | - 3.实施解决方案Carry out the plan 219 | - code generation, implementing solution 代码生成 220 | 221 | 具体问题: 222 | 223 | 1.解决方案是否符合计划? 源代码是否可以追溯到设计模型(你的**代码要对应设计架构**,比如说,哪部分代码对应了某功能的微服务) 224 | 225 | 2.解决方案的每个组成部分(component)是否**正确**? 设计和代码是否已经过**审查(review 是Umbrella Activity)**,或者更好,是否已将正确性证明应用于算法 226 | 227 | - 4.检查结果精确度Examine the result for accuracy 228 | - testing 测试 229 | - quality assurance 质量保证 230 | 231 | 具体问题: 232 | 233 | 1.是否可以**测试**解决方案的**每个组成部分?**(单元测试,每个类都有状态图State Diagram,利用状态图进行测试),是架构设计的重要依据) 是否实施了合理的**测试策略(testing strategy)** 234 | 235 | 2.解决方案是否产生符合所需数据、功能和特征的**结果**? 软件是否根据所有利益相关者的要求进行了**验证(**validate->也叫system testing系统测试)? 236 | 237 | 238 | ### 2.3.2 一般原则General Principles 239 | 240 | 1. V存在价值—— 项目的价值是什么,能不能带来生成效益 241 | 2. S保持简洁KISS—— 架构简单清晰明了 242 | 3. V保持视图—— 保持每个阶段可见,可视化,using类图或其他工具 243 | 4. U关注使用者——软件做完后有没有受众面,对客户有作用(输入输出) 244 | 5. F面向未来——可扩展性,比如,接口不写死, 类便于修改维护 245 | 6. R**提前计划复用——**代码尽量标准化,提前考虑组件复用性前瞻性,降低成本 246 | 7. T认真思考 247 | 248 | ## 2.4 软件开发误区Myth 249 | 250 | 管理误区:针对维持预算、防止进度延误和提高质量的压力 251 | 252 | Myth-Reality 253 | 254 | 1. 即使有软件工程这个开发框架也可能会遇到很多问题 255 | 256 | customer myth 257 | 258 | 1. 需求不能随意更改,敏捷开发中需要等到下一个迭代周期才可以更改需求(stories) 259 | 260 | Practitioner’s myths 261 | 262 | 1. 代码要写的慢而精 263 | 2. review SOA去找error 264 | 3. Software engineering is not about creating documents. It is about creating a quality product. 265 | 266 | 267 | 268 | ppt_c2看风险管理,myth部分 -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-02-软件工程/Chapter 2 软件工程Software Engineering e4457513b79c4c11883e7210ae950571/Untitled 1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-02-软件工程/Chapter 2 软件工程Software Engineering e4457513b79c4c11883e7210ae950571/Untitled 1.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-02-软件工程/Chapter 2 软件工程Software Engineering e4457513b79c4c11883e7210ae950571/Untitled 2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-02-软件工程/Chapter 2 软件工程Software Engineering e4457513b79c4c11883e7210ae950571/Untitled 2.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-02-软件工程/Chapter 2 软件工程Software Engineering e4457513b79c4c11883e7210ae950571/Untitled 3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-02-软件工程/Chapter 2 软件工程Software Engineering e4457513b79c4c11883e7210ae950571/Untitled 3.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-02-软件工程/Chapter 2 软件工程Software Engineering e4457513b79c4c11883e7210ae950571/Untitled 4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-02-软件工程/Chapter 2 软件工程Software Engineering e4457513b79c4c11883e7210ae950571/Untitled 4.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-02-软件工程/Chapter 2 软件工程Software Engineering e4457513b79c4c11883e7210ae950571/Untitled 5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-02-软件工程/Chapter 2 软件工程Software Engineering e4457513b79c4c11883e7210ae950571/Untitled 5.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-02-软件工程/Chapter 2 软件工程Software Engineering e4457513b79c4c11883e7210ae950571/Untitled 6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-02-软件工程/Chapter 2 软件工程Software Engineering e4457513b79c4c11883e7210ae950571/Untitled 6.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-02-软件工程/Chapter 2 软件工程Software Engineering e4457513b79c4c11883e7210ae950571/Untitled.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-02-软件工程/Chapter 2 软件工程Software Engineering e4457513b79c4c11883e7210ae950571/Untitled.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-03-软件过程/Chapter 3 软件过程Software Process e7160395fe3c4f20856e027664643d8a.md: -------------------------------------------------------------------------------- 1 | # Chapter 3 软件过程Software Process 2 | 3 | ## 3.1 通用过程模型Generic Process Model 4 | 5 | 通用过程框架(generic process framework) 定义了5个框架活动(framework activity)——CPMCD,以及一系列伞活动(umbrella activity)——project tracking and control, risk management, quality assurance, configuration management, technical reviews, and others 6 | 7 | **※软件过程框架Software process framework** 8 | 9 | 通用过程框架(generic process framework) 包含两部分 10 | 11 | - 框架活动(framework activity)(CPMCD)——development dimension开发维度 12 | - 伞型活动(umbrella activity)——management dimension管理维度(评审,QA等) 13 | 14 | framework activity → software engineering action → task sets 15 | 16 | action是若干个task sets,其内容: 17 | 18 | - T:work tasks: 19 | - P:work products: 在work tasks之后形成一个work products 20 | - Q:quality assurance( QA ) points: 产生work products后要有质量保证 21 | - M:milestone: 形成里程碑 22 | 23 | ![Untitled](Chapter%203%20%E8%BD%AF%E4%BB%B6%E8%BF%87%E7%A8%8BSoftware%20Process%20e7160395fe3c4f20856e027664643d8a/Untitled.png) 24 | 25 | 我们应该注意,尚未讨论软件过程的一个重要方面。这个方面被称为过程流程process flow - 描述了如何在序列和时间内组织在每个框架活动中发生的框架活动和动作和任务 26 | 27 | **※工作流Process flow** 28 | 29 | 种类: 30 | 31 | 1. Linear 32 | 2. Iterative 33 | 3. Evolutionary 34 | 4. Parallel 35 | - **线性工作流和迭代工作流** 36 | 37 | ![Untitled](Chapter%203%20%E8%BD%AF%E4%BB%B6%E8%BF%87%E7%A8%8BSoftware%20Process%20e7160395fe3c4f20856e027664643d8a/Untitled%201.png) 38 | 39 | 迭代流的几个迭代箭头: 40 | 41 | 1. communication和planning反复迭代(planning后,由于1.需求变更;2. 技术和业务更深层的理解;3. 有错误等,重复迭代)→CUE 42 | 2. modeling部分的迭代 43 | 3. construction后(coding&testing),可能在testing时发现需求不明确,又回到了前面四个阶段迭代 44 | - **演化工作流(Evolutionary)——螺旋上升** 45 | 46 | ![Untitled](Chapter%203%20%E8%BD%AF%E4%BB%B6%E8%BF%87%E7%A8%8BSoftware%20Process%20e7160395fe3c4f20856e027664643d8a/Untitled%202.png) 47 | 48 | 解读:本质还是迭代开发 49 | 50 | Planning不回到Communication: 在planning阶段发现有communication的问题,但不回去,而是记录下来直到把本次迭代做完,不论有多少问题,都先进行完本次开发 51 | 52 | increment released: **和单纯的迭代流不同,每次迭代完必须要有一个可展示的产品** 53 | 54 | 每一次的输入(下次迭代要解决的问题):下次开发的新功能+本次开发中记录下来的问题+用户使用这个increment的产品后反馈要解决的问题 55 | 56 | - **并行工作流(Parallel)** 57 | 58 | ![Untitled](Chapter%203%20%E8%BD%AF%E4%BB%B6%E8%BF%87%E7%A8%8BSoftware%20Process%20e7160395fe3c4f20856e027664643d8a/Untitled%203.png) 59 | 60 | planning和modeling同时做,在communication时导出需求,可以进行planning;同时明确的部分可以进行modeling 61 | 62 | ## 3.2 定义框架活动Framework Activity 63 | 64 | 框架活动的关键问题:考虑到要解决的问题的性质、从事工作的人员的特征以及赞助项目的利益相关者,哪些行动适合框架活动? 65 | 66 | - 小项目: 67 | 1. 在线讨论需求和开发笔记; 68 | 69 | 一个人(远程)有直接的需求进行一个小的软件项目:电话交流就好, 70 | 71 | task: 72 | 73 | 1. 和stakeholder通过电话甲流; 74 | 2. 将笔记组织成一个简单的需求书面(written)声明; 75 | 3. 和stakeholder用电子邮件进行审阅和通过 76 | 77 | - 大项目: 78 | 79 | 多个股东,股东的需求不同甚至有冲突 80 | 81 | action: 82 | 83 | 1. I奠基inception 84 | 2. E诱导elicitation (诱导需求,功能需求和非功能需求function requirement& non-function requirements)→requirement gathering 85 | 3. E细化elaboration (建模,用UML各种diagram对需求内容进行抽象) 86 | 4. N协商negotiation ( 甲方讨论需要和不需要的需求,需求规约,需求分析) **与3存在迭代** 87 | 5. S规约specification 88 | 6. V确认validation 89 | 90 | 开发过程控制:MS-project 91 | 92 | ## 3.3 定义任务列表Identify a Task Set 93 | 94 | - 软件工程工作任务work tasks 95 | - 相关工作产品products 96 | - 质量保证点 quality assurance points 97 | - 项目里程碑project milestone的集合 98 | 99 | 例子: 100 | 101 | elicitation: 102 | 103 | ![Untitled](Chapter%203%20%E8%BD%AF%E4%BB%B6%E8%BF%87%E7%A8%8BSoftware%20Process%20e7160395fe3c4f20856e027664643d8a/Untitled%204.png) 104 | 105 | e.g. 书上没有的例子: 106 | 107 | Coding过程的Action :1个 108 | 109 | task set: 110 | 111 | 1. 分析理解详细设计(详细的设计规约,理解接口); 112 | 2. 算法以及数据结构; 113 | 3. 准备环境写代码 114 | 4. (单元测试)自我测试self-testing(可能考虑的:算法复杂度时间性能); 115 | 5. SQA软件质量保证; 116 | 6. refactor重构(测试后对大项目可能要重构,规范性的) 117 | 7. code review; 118 | 8. code end(里程碑任务milestone) 119 | 120 | 提高系统性能的几个方法: 121 | 122 | 1. 后端的数据库设计(冗余设计,表空间划分,范式)(高访问量的几张表不能放在一个表空间里); 123 | 2. 架构设architecture design; 124 | 3. 前端和后端的接口(交易频繁的分到不同接口支流中); 125 | 4. 前端本身的memory使用,和后端的通讯; 126 | 5. 模拟工具测试得到性能 127 | 128 | (TODO) 129 | 130 | ## 3.4 过程模式 Process Pattern 131 | 132 | **※ 非常重要** 133 | 134 | 定义: 135 | 136 | 过程模式Process Pattern描述了在软件工程工作中遇到的与过程有关的问题,确定了遇到该问题的环境,并提出了一个或多个行之有效的解决问题的方法。 137 | 138 | 流程模式为你提供了一个模板--一种在软件流程的背景下描述问题解决方案的一致方法。 139 | 140 | pattern: 已证实有用的,抽象成一个模板步骤 141 | 142 | 具体来说: 143 | 144 | 描述与完整流程模型(例如原型设计)相关的问题(和解决方案);可用于描述与框架活动(例如,计划)或框架活动(例如,项目估算)内的行动相关联的问题(和解决方案) 145 | 146 | **※ 描述模板template** 147 | 148 | | 内容 | 中文 | 描述 | 例子 | 149 | | --- | --- | --- | --- | 150 | | Pattern Name | 模式名字 | 形容软件过程的context | TechnicalReviews | 151 | | Force | 环境 | 所需要的环境,硬件,网络,版本管理工具等 | | 152 | | Type | 类型 | stage pattern: 解决activity相关的(EstablishingCommunication);task pattern:解决action或task的(RequirementGathering);phase pattern: 整个框架活动的序列,涉及各种activity(SpiralModel, Prototyping) | stage pattern; task pattern; phase pattern | 153 | | Initial Context | 启动条件 | 在模式启动之前: (1) 已经发生了哪些组织或团队相关的活动? (2)进程的入口状态是什么? (3) 已有哪些软件工程信息或项目信息? (Activity Happended? State ? SE info) | 规划模式Stage pattern的Initial Context(1)客户和软件工程师建立了协作沟通; (2) 成功完成了通信模式的多个任务模式[指定]; (3)项目范围、基本业务需求、项目约束条件已知。 | 154 | | Problem | 问题 | Pattern可以用来解决什么问题 | | 155 | | Solution | 解决方案 | 描述如何成功执行Pattern | | 156 | | Resulting Context | 接口(出口条件) | 为接下来提交什么信息(哪些activity必须出现;过程的出口状态是怎样的;开发了什么软件工程信息) | | 157 | | Related Pattern | 相关的Pattern | 提供与此直接相关的所有流程模式的列表。这可以表示为层次结构或以其他示意性形式表示(同级或上下) | 比如:同一个action下的两个task上下相关;又比如关于unit test不知道怎么做,去寻找相关、包含或并行的stage pattern | 158 | | Know Uses and Examples | 用过的案例 | | | 159 | 160 | ![Untitled](Chapter%203%20%E8%BD%AF%E4%BB%B6%E8%BF%87%E7%A8%8BSoftware%20Process%20e7160395fe3c4f20856e027664643d8a/Untitled%205.png) 161 | 162 | ## 3.5 过程评估与改进Assessment and Improvement 163 | 164 | Process patterns必须与可靠的软件工程实践相结合。 此外,可以对过程本身进行评估,以确保它满足一组基本过程标准,这些标准已被证明对于成功的软件工程至关重要。 165 | 166 | (CMMI) 167 | 168 | Initial Repeatable Defined Managed Optimize 169 | 170 | ## 软件成熟度模型CMMI 171 | 172 | ![Untitled](Chapter%203%20%E8%BD%AF%E4%BB%B6%E8%BF%87%E7%A8%8BSoftware%20Process%20e7160395fe3c4f20856e027664643d8a/Untitled%206.png) 173 | 174 | ![Untitled](Chapter%203%20%E8%BD%AF%E4%BB%B6%E8%BF%87%E7%A8%8BSoftware%20Process%20e7160395fe3c4f20856e027664643d8a/Untitled%207.png) 175 | 176 | 注:上图的机构过程焦点的例子在下图 177 | 178 | add-read 179 | 180 | ppt-c3 -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-03-软件过程/Chapter 3 软件过程Software Process e7160395fe3c4f20856e027664643d8a/Untitled 1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-03-软件过程/Chapter 3 软件过程Software Process e7160395fe3c4f20856e027664643d8a/Untitled 1.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-03-软件过程/Chapter 3 软件过程Software Process e7160395fe3c4f20856e027664643d8a/Untitled 2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-03-软件过程/Chapter 3 软件过程Software Process e7160395fe3c4f20856e027664643d8a/Untitled 2.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-03-软件过程/Chapter 3 软件过程Software Process e7160395fe3c4f20856e027664643d8a/Untitled 3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-03-软件过程/Chapter 3 软件过程Software Process e7160395fe3c4f20856e027664643d8a/Untitled 3.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-03-软件过程/Chapter 3 软件过程Software Process e7160395fe3c4f20856e027664643d8a/Untitled 4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-03-软件过程/Chapter 3 软件过程Software Process e7160395fe3c4f20856e027664643d8a/Untitled 4.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-03-软件过程/Chapter 3 软件过程Software Process e7160395fe3c4f20856e027664643d8a/Untitled 5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-03-软件过程/Chapter 3 软件过程Software Process e7160395fe3c4f20856e027664643d8a/Untitled 5.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-03-软件过程/Chapter 3 软件过程Software Process e7160395fe3c4f20856e027664643d8a/Untitled 6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-03-软件过程/Chapter 3 软件过程Software Process e7160395fe3c4f20856e027664643d8a/Untitled 6.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-03-软件过程/Chapter 3 软件过程Software Process e7160395fe3c4f20856e027664643d8a/Untitled 7.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-03-软件过程/Chapter 3 软件过程Software Process e7160395fe3c4f20856e027664643d8a/Untitled 7.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-03-软件过程/Chapter 3 软件过程Software Process e7160395fe3c4f20856e027664643d8a/Untitled.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-03-软件过程/Chapter 3 软件过程Software Process e7160395fe3c4f20856e027664643d8a/Untitled.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-04-过程模型/Chapter 4 过程模型Process Models fd63f7899930489c87ef2d9e58174036.md: -------------------------------------------------------------------------------- 1 | # Chapter 4 过程模型Process Models 2 | 3 | 重点: 4 | 5 | 4.1.1 The Waterfall Model 6 | 7 | 4.1.2 Incremental Process Model 8 | 9 | 4.1.3 Evolutionary Process Model 10 | 11 | process model为软件工程工作提供了特定的路线图。 它定义了所有活动、行动和任务的流程、迭代的程度(迭代了几次,迭代的方式(可能是action,task等不断迭代))、工作产品以及必须完成的工作的组织。 12 | 13 | ## 4.1 规定的过程模型Prescriptive Process Models 14 | 15 | "prescriptive": 规定了一系列过程元素:framework activities, SE actions ,tasks ,work product, quality assurance , change control mechanisms 16 | 17 | ### 4.1.1 瀑布模型The Waterfall Model 18 | 19 | 特点: 20 | 21 | 1. 按照general/standard process顺序开发,很少迭代:planing是umbrella可以去掉 22 | 2. 过程明确,需求清晰 23 | 3. 不主张迭代,但也有迭代 24 | 4. 用户需要很长时间才能得到成品 25 | 5. 某阶段受阻,整个项目都会到blocking states,也就是说,没有形成milestone,一个action,task卡住了就都卡了 26 | 6. 线性模型 27 | 7. 项目大的时候不要用,适合需求清晰稳定的情况 28 | 29 | ![Untitled](Chapter%204%20%E8%BF%87%E7%A8%8B%E6%A8%A1%E5%9E%8BProcess%20Models%20fd63f7899930489c87ef2d9e58174036/Untitled.png) 30 | 31 | Planning: EST评估→计划→跟踪 32 | 33 | 瀑布模型的缺点: 34 | 35 | waterfall models的问题: 36 | 37 | ①**实际项目很少遵循模型提出的顺序流程**。 虽然线性模型可以适应迭代,但它是间接这样做的。 因此,随着项目团队的推进,变更可能会导致混乱。(项目发生变更时就不适用,导致混乱) 38 | 39 | ② **客户通常很难明确地陈述所有要求**。 瀑布模型需要这一点,并且难以适应许多项目开始时存在的自然不确定性。(要求需求明确,然而这点很难做到) 40 | 41 | ③ 客户要有耐心。 **程序的工作版本要到项目时间跨度的后期才可用**。 重大失误如果在审查工作计划之前未被发现,可能是灾难性的。(比如:waterfall会导致“阻塞状态”,在这种状态下,某些项目团队成员必须等待团队其他成员完成依赖任务。)(容错率低,且在项目后期发现难以修复,and阻塞状态) 42 | 43 | ### 4.1.1(extended)V-模型 44 | 45 | 瀑布模型的变种 (与standard process非常相似) 46 | 47 | 瀑布模型对软件工程的最大贡献 48 | 49 | 描述了质量保证行动与与沟通、建模和早期建设活动相关的行动之间的关系。 50 | 51 | Unit Testing: 因为需要看底层代码,故依赖Code generation;因为复杂的代码中如何传参,参数指向什么很复杂,需要查看Component Design 和 详细设计规约 52 | 53 | Integration Testing:组件与组件的集成,看Component Design;还因为是和子系统之间的协作有关,涉及接口,数据库,软件结构设计,需要参考接口设计,数据设计,软件体系架构设计,故看Architectural Design 54 | 55 | System Testing:把编好的程序放在各种集成环境下;首先需要需求分析规约来进行模拟测试(主要看的是需求建模中的功能建模),比如模拟Actor,故需要Requirement Modeling;如果发现失败了,要检查什么接口有问题,故要参考Architectural Design( 追溯子系统 ) 56 | 57 | Acceptance Testing: 验收测试是面向用户的,用户不知道你的实现细节而是以需求为依据,所以是需求层面的(需要用到需求规约和需求分析规约),即Requirement Modeling 58 | 59 | ![Untitled](Chapter%204%20%E8%BF%87%E7%A8%8B%E6%A8%A1%E5%9E%8BProcess%20Models%20fd63f7899930489c87ef2d9e58174036/Untitled%201.png) 60 | 61 | ![Untitled](Chapter%204%20%E8%BF%87%E7%A8%8B%E6%A8%A1%E5%9E%8BProcess%20Models%20fd63f7899930489c87ef2d9e58174036/Untitled%202.png) 62 | 63 | ![Untitled](Chapter%204%20%E8%BF%87%E7%A8%8B%E6%A8%A1%E5%9E%8BProcess%20Models%20fd63f7899930489c87ef2d9e58174036/Untitled%203.png) 64 | 65 | ![Untitled](Chapter%204%20%E8%BF%87%E7%A8%8B%E6%A8%A1%E5%9E%8BProcess%20Models%20fd63f7899930489c87ef2d9e58174036/Untitled%204.png) 66 | 67 | ### 4.1.2 增量过程模型 68 | 69 | 场景: 70 | 71 | 1. Non-linear开发工作的整体范围排除了一个纯粹的线性过程。 72 | 2. Rapid Raw Product v1.0 可能迫切需要向**用户快速提供**一组有限的软件功能,然后在以后的软件版本中完善和扩展该功能。 73 | 3. Update v2.0++++ 有部分功能**不成熟需要后期才增量补充**; 74 | 4. Preview Function 市场要求**先发布一部分功能**,后续功能增量补充; 75 | 5. Parallel 一些内容**交叉进行** 76 | 77 | 结合了waterfall模型和并行处理流parallel 78 | 79 | 当使用增量模型时,**第一个增量通常是核心产品**。 也就是说,**解决了基本要求**,但许多补充功能(一些已知,另一些未知)仍未交付。 核心产品由客户使用(或经过详细评估)。 作为使用和/或评估的结果,为下一个增量制定计划。 80 | 81 | 特点: 82 | 83 | - 每一次增量都生成可发布的产品increment producut,第一个增量形成核心基本产品,后续增量形成完善版本 84 | - 每次增量是一个waterfall,一次增量内不主张迭代 85 | - 不同增量间可并行开发(比如:第2个做coding时,第3个可做需求建模)——纵轴重合 86 | 87 | ![Untitled](Chapter%204%20%E8%BF%87%E7%A8%8B%E6%A8%A1%E5%9E%8BProcess%20Models%20fd63f7899930489c87ef2d9e58174036/Untitled%205.png) 88 | 89 | ### 4.1.3 演化过程模型Evolutionary Process Model 90 | 91 | **强调模型迭代iteration** 92 | 93 | 场景: 94 | 95 | 1. Complex系统**复杂**,模型演化**需求变更**; 96 | 2. Preview紧凑的市场期限**要求一个功能有限的版本**需要应对市场和企业的压力; 97 | 3. Requirement一系列核心产品和系统**需求明确**,但产品和系统**拓展的细节还没有被设计出来** 98 | 99 | 两种常见的演化过程模型(都是迭代的): 100 | 101 | ### 4.1.3.1 原型模型Prototype 102 | 103 | 特点:快速 104 | 105 | 为什么要用Prototype(很可能考) 106 | 107 | 一般它是一个可以确定需求identifying software requirement的方法 108 | 109 | 描述:客户定义了一组软件的**一般目标但没有具体需求**时;开发者不知道具体开发细节时,可帮助您和其他利益相关者更好地了解在需求模糊时要构建的内容。 110 | 111 | 迭代发生在原型被调整以满足不同利益相关者的需求时,同时使您能够更好地了解需要做什么。 112 | 113 | 114 | 115 | 啥都快,不过Deployment模块貌似没有support环节? 116 | 117 | ![Untitled](Chapter%204%20%E8%BF%87%E7%A8%8B%E6%A8%A1%E5%9E%8BProcess%20Models%20fd63f7899930489c87ef2d9e58174036/Untitled%206.png) 118 | 119 | Prototype的不足之处: 120 | 121 | - (代码能跑了,但是static的没啥用)成型但不一定可靠:stakeholder看到的软件可运行,但不知道原型是固定在一起的,不知道在急于使其工作时您**没有考虑整体软件质量或长期可维护性**。 122 | - (代码都是垃圾的的但能用,结果没改)错用:经常会在实现上做出妥协,以便让原型快速工作。 不适当的操作系统或编程语言可能仅仅因为可用和已知而被使用; 一个低效的算法可能会被简单地实现来展示能力。 一段时间后,您可能会对这些选择感到满意,而**忘记了它们不合适的所有原因**。 123 | 124 | Prototype主要是用来确定需求,真正开发时可能会被抛弃掉,换成更加注重质量的model;没有被抛弃的部分会成为真正系统的一部份 125 | 126 | 真正的开发要做到质量控制SQA 127 | 128 | ### 4.1.3.2 螺旋模型Spiral Model 129 | 130 | 特点:适合**大型项目,风险较高的项目,需求不明确的项目(big,risky,unclear)**,将**原型设计的迭代性质与瀑布模型的受控和系统方面相结合**。 它为快速开发越来越完整的软件版本提供了潜力。 131 | 132 | ![Untitled](Chapter%204%20%E8%BF%87%E7%A8%8B%E6%A8%A1%E5%9E%8BProcess%20Models%20fd63f7899930489c87ef2d9e58174036/Untitled%207.png) 133 | 134 | 解释: 135 | 136 | 每次迭代circuit后会得到一个work product 137 | 138 | CPMCD:这5个步骤是可裁减的; 139 | 140 | 比如:第一次迭代(circuit)主要为了得到需求规约,则Communication后4个可以减去,最后得到一个Requirement Specification;后面的迭代则都用到了后4个,但详细程度重要程度也不同(比如:第二次迭代得到Prototype,第三次可能会完成部分功能得到可发布的一个版本,第四次进行功能完善等) 141 | 142 | 其他process models: 在软件交付时结束; 143 | 144 | spiral model: 在整个软件的生命周期中都适用 -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-04-过程模型/Chapter 4 过程模型Process Models fd63f7899930489c87ef2d9e58174036/Untitled 1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-04-过程模型/Chapter 4 过程模型Process Models fd63f7899930489c87ef2d9e58174036/Untitled 1.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-04-过程模型/Chapter 4 过程模型Process Models fd63f7899930489c87ef2d9e58174036/Untitled 2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-04-过程模型/Chapter 4 过程模型Process Models fd63f7899930489c87ef2d9e58174036/Untitled 2.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-04-过程模型/Chapter 4 过程模型Process Models fd63f7899930489c87ef2d9e58174036/Untitled 3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-04-过程模型/Chapter 4 过程模型Process Models fd63f7899930489c87ef2d9e58174036/Untitled 3.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-04-过程模型/Chapter 4 过程模型Process Models fd63f7899930489c87ef2d9e58174036/Untitled 4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-04-过程模型/Chapter 4 过程模型Process Models fd63f7899930489c87ef2d9e58174036/Untitled 4.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-04-过程模型/Chapter 4 过程模型Process Models fd63f7899930489c87ef2d9e58174036/Untitled 5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-04-过程模型/Chapter 4 过程模型Process Models fd63f7899930489c87ef2d9e58174036/Untitled 5.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-04-过程模型/Chapter 4 过程模型Process Models fd63f7899930489c87ef2d9e58174036/Untitled 6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-04-过程模型/Chapter 4 过程模型Process Models fd63f7899930489c87ef2d9e58174036/Untitled 6.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-04-过程模型/Chapter 4 过程模型Process Models fd63f7899930489c87ef2d9e58174036/Untitled 7.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-04-过程模型/Chapter 4 过程模型Process Models fd63f7899930489c87ef2d9e58174036/Untitled 7.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-04-过程模型/Chapter 4 过程模型Process Models fd63f7899930489c87ef2d9e58174036/Untitled.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-04-过程模型/Chapter 4 过程模型Process Models fd63f7899930489c87ef2d9e58174036/Untitled.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-05-敏捷开发/Chapter 5 敏捷开发Agile Development f3a7f28d875b47c38c04a1a9be8995c0.md: -------------------------------------------------------------------------------- 1 | # Chapter 5 敏捷开发Agile Development 2 | 3 | 一种传统软件工程项目的合理的替代品 4 | 5 | 简述:敏捷软件工程可以快速提供成功的系统(重要特性:**适应需求变更**) 6 | 7 | 强调: 8 | 9 | - 注重”客户的满意度“和”尽早提交可增量的软件产品“(增量交付,开发过程存在迭代) 10 | - 快速交付,不看重中间产品 11 | - 小型,积极的项目团队,协调能力强,看中团队结构,协作态度 12 | - 可用非正式的方法(e.g. 数据库设计没有写完整的设计文档,中间建模尽量简单) 13 | - 最小的work product(开发过程简单,会要求尽量减少work product且work product简单,不完全按照template) 14 | - 整体发展简单(e.g. 封闭开发) 15 | - 软件工程师和其他项目利益相关者(管理人员,客户,最终用户)在一个敏捷的团队,命运共同体,其中roles和responsibility随时调整 16 | 17 | 特点: 18 | 19 | 1. story / function: 通过需求调研得到项目的一些功能(story / functions) 20 | 2. priority:对story设置优先级 21 | 22 | 在这之后,选择优先级高的stories进行第一次迭代,得到可演示产品;demo后进行第二次迭代,包括对上一次的stories进行修改,加入新的stories,...... 23 | 24 | 3. 每次迭代完后均是可以演示运行的产品 25 | 26 | 基本框架活动 CPMCD (generic process,当然也可以遵循standard process) 27 | 28 | ## 5.1 Agility 敏捷 29 | 30 | 正在构建的软件的变化,对团队成员进行更改,由于新技术而更改,可能对其构建产品或创建产品的项目可能产生影响的各种类型。 31 | 32 | ## 5.2 Agility 和 Change Cost 改变成本 33 | 34 | ※ Change Cost图(出选择题,要理解) 35 | 36 | ![Untitled](Chapter%205%20%E6%95%8F%E6%8D%B7%E5%BC%80%E5%8F%91Agile%20Development%20f3a7f28d875b47c38c04a1a9be8995c0/Untitled.png) 37 | 38 | 理解传统software processes的黑色曲线: 39 | 40 | 比较显然,随着软件开发逐步变化,需求变更可能需要改的部分越多(例如:还在modelling阶段和coding阶段change cost完全不同,coding阶段cost会大得多) 41 | 42 | 理解敏捷模型的曲线: 43 | 44 | regression testing回归测试——变更多了后,回归测试成本越来越高,最终翘了上去(这一版和上一版本的修改会有牵连——相关用例) 45 | 46 | ![Untitled](Chapter%205%20%E6%95%8F%E6%8D%B7%E5%BC%80%E5%8F%91Agile%20Development%20f3a7f28d875b47c38c04a1a9be8995c0/Untitled%201.png) 47 | 48 | ## 5.3 敏捷过程(Agile Process) 49 | 50 | 敏捷开发解决的问题: 51 | 52 | 1. 没有办法提前预测需求是什么,会怎么改,优先级如何 53 | 2. design和construction有交叉,过程中的activity是串联的。这样比较难去预测多少design在construction之前是必要的 54 | 3. 分析analysis, 设计design, 构建construction和测试testing和预想的不同 55 | 56 | 敏捷过程的目的:创建一个可以对付不可预知性的process(to rapidly changing project) 57 | 58 | 结论:需要一个增量的开发战略increment development strategy 59 | 60 | ### 5.3.1 敏捷原则Principles (12个) 61 | 62 | ※ 考试会出选择题(加混淆的选项) 63 | 64 | 1. **Highest** 最高优先级:通过早期early和连续continuous交付有价值的软件来满足客户 65 | 2. **Change** 鼓励需求改动,哪怕是开发过程晚期(好的改动可以提升顾客的竞争优势) 66 | 3. **Frequently** 经常提供work product,最好有短的schedule 67 | 4. **Together** 甲方和开发者daily紧密合作 68 | 5. **Motivated** 和有动力的人开发,给他们好的环境和支持,信任他们 69 | 6. **F-to-F** 面对面讨论,实时解决问题,这是最高效率的 70 | 7. **WorkingSoftware** 进度的最好指标就是产出的可工作的软件 71 | 8. **Sustainable** 敏捷过程保持稳定的开发过程,赞助人,开发者和用户应该maintain a constant pace indefinitely (不定期同步跟踪) 72 | 9. **Excellence** 持续关注追求技术的改进和设计的优化 73 | 10. **Simplicity** 文档尽量简单 74 | 11. **Self-organizing** 一个self-organizing的team可以做出最好的架构、需求和设计 75 | 12. **Reflection** 定期进行回顾 76 | 77 | ## 5.4 极限编程Extreme Programming 78 | 79 | ### 5.4.1 XP Process 80 | 81 | 是agile model 82 | 83 | 是迭代开发的,每轮结束后都可以运行的系统 84 | 85 | 4个framework activities:Planning,Design,Coding和Testing(区别Generic Process Activity的Framework(CPMCD) 86 | 87 | ![Untitled](Chapter%205%20%E6%95%8F%E6%8D%B7%E5%BC%80%E5%8F%91Agile%20Development%20f3a7f28d875b47c38c04a1a9be8995c0/Untitled%202.png) 88 | 89 | - Planning: 导出需求 90 | 1. 设定一系列stories,故事的单位是use case 91 | 2. 客户基于特征或功能的整体业务价值为story分配优先级,划分依据: 92 | 1. 业务上重要性 93 | 2. R此功能(story)是否有高风险(high risk) 94 | 3. D交付时间(deadline要求) 95 | 3. 如果估计故事需要超过三个发展周(工作量太大),请客户拆分为较小的故事 96 | 4. 一旦基本承诺定下(关于要包括故事的协议agreement,交货日期和其他项目问题),XP团队会将以三种方式之一开发story: 97 | 1. 所有story将被实施立即(几周之内) 98 | 2. 最高优先级的story将在计划中提前并首先实施 99 | 3. 最高风险的story将在计划中提前并首先实施 100 | 5. 第一个project(software increment)在发布后,XP team计算目前完成的速率(project velocity)——第一个release版本中部署的customer stories的数量。它可以用于评估接下来release的发布日期和开发schedule,以及看整个项目的所有stories是否存在overcommitment(过度承诺),如果有,则要修改release内容或推迟delivery dates 101 | 6. 迭代 102 | - Design: 103 | - 鼓励使用CRC卡片(Chapter 10 ) 104 | - **Spike Solution**——快速解决问题的模型一种Design Prototype,对没有把握的部分先给出一个快速解决方案(原型)在特定的环境下跑一下(有时不知道是否正确,时间复杂度等也未知,此时可以先快速开发,看有没有把握去解决问题) 105 | - Coding 106 | 107 | 设计完成后,团队不会转移到代码,而是开发一系列unit test,该测试将测试当前版本中包含的每个story(软件增量software increment):业务流程的梳理 108 | 109 | 1. Pair Programming 结对编程(互相看逻辑做Check) 110 | 2. Refactoring 重构(对代码规范化,标准化以进行复用) 111 | 3. Unit test 112 | 113 | 在programming前首先将单元测试的测试用例写出来,用test case覆盖逻辑 114 | 115 | pair programming后马上就运行unit test的测试用例(测试先行) 116 | 117 | - Continuous integration 2个人结对编程时把两个人的代码做基础 118 | 119 | (注意!continuous integration的目的是把两个人的代码做集成;而test中的continuous integration是把不同的pair program写的代码做集成) 120 | 121 | - Test 122 | - Continuous integration 将pair program结对编程小组的代码整合 123 | - Unit test 需重新运行coding阶段的test case;再加一些test case(集成中发现的问题,因为一般一些测试类用例是优化顺序的 124 | - 做成一个test suite测试套件,生成test case set测试集正常执行 125 | - acceptance test: 一般是开发人员模拟用户将story的逻辑全部测试一遍 126 | 127 | - Release: 128 | 129 | software increment project velocity要计算,必入衡量完成的占比 130 | 131 | ![Untitled](Chapter%205%20%E6%95%8F%E6%8D%B7%E5%BC%80%E5%8F%91Agile%20Development%20f3a7f28d875b47c38c04a1a9be8995c0/Untitled%203.png) 132 | 133 | 敏捷原则: 134 | 135 | 1. 个体与交互胜过过程与工具 136 | 2. 可以工作的软件胜过面面俱到的文档 137 | 3. 重视客户协作(每次迭代的完成) 138 | 4. 响应变化 139 | 140 | ## 5.6 SCRUM 141 | 142 | 一种敏捷开发框架,是增量迭代的开发过程(很重要,考试必考SCRUM或XP) 143 | 144 | **阅读公盘的课外材料** -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-05-敏捷开发/Chapter 5 敏捷开发Agile Development f3a7f28d875b47c38c04a1a9be8995c0/Untitled 1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-05-敏捷开发/Chapter 5 敏捷开发Agile Development f3a7f28d875b47c38c04a1a9be8995c0/Untitled 1.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-05-敏捷开发/Chapter 5 敏捷开发Agile Development f3a7f28d875b47c38c04a1a9be8995c0/Untitled 2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-05-敏捷开发/Chapter 5 敏捷开发Agile Development f3a7f28d875b47c38c04a1a9be8995c0/Untitled 2.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-05-敏捷开发/Chapter 5 敏捷开发Agile Development f3a7f28d875b47c38c04a1a9be8995c0/Untitled 3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-05-敏捷开发/Chapter 5 敏捷开发Agile Development f3a7f28d875b47c38c04a1a9be8995c0/Untitled 3.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-05-敏捷开发/Chapter 5 敏捷开发Agile Development f3a7f28d875b47c38c04a1a9be8995c0/Untitled.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-05-敏捷开发/Chapter 5 敏捷开发Agile Development f3a7f28d875b47c38c04a1a9be8995c0/Untitled.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-07-软件工程实践原则/Chapter 7 软件工程实践原则Principles that guide practice bdaa5daeb0ba495e9391e6345636ede2.md: -------------------------------------------------------------------------------- 1 | # Chapter 7 软件工程实践原则Principles that guide practice 2 | 3 | ※ 考点:给一个例子进行分析 4 | 5 | software engineering practice是一系列principle, concepts, methods和tools(方法的工具化,大趋势) 6 | 7 | principles that guide practice建立了对软件工程进行的基础 8 | 9 | ## 7.1 软件工程知识 10 | 11 | 现代软件开发技术一般有3年的半衰期;但软件工程principles没有3年半衰期(变化慢)。这些软件工程原则可能在整个职业生涯中为专业程序员提供服务。 12 | 13 | ## 7.2 核心原则Core Principles 14 | 15 | 作用: 16 | 17 | 1.在流程级别process level,指导软件团队在执行framework activity和umbrella activity时,导航流process flow,并产生一组软件工程work product; 18 | 19 | 2.在practice level,核心原则建立了一个值和规则的集合,即在分析问题,设计解决方案,实施解决方案并测试解决方案时,该规则是指南,并最终部署软件 20 | 21 | ### 7.2.1 引导Process的Principles 22 | 23 | 对什么样的过程模型Process Model均适用 24 | 25 | ※可能考选择题 26 | 27 | 1. **Agile**过程要灵活agile(尽量用敏捷模型开发) 28 | 29 | > *PS:比如对agile model,要求文档不要太多,注重和客户沟通;对非agile model,可以保证每个增量increment之间并行开发,缩短每个增量的开发周期,在人员组织交付工作产品上均灵活些(也就是说,对非敏捷开发模型也有敏捷原则)* 30 | > 31 | 2. **Quality**在每一步产生迭代work product时注重质量 32 | 33 | > review→spike→review→demo,对milestone的work product需要进行评审 34 | > 35 | 3. **Adapt**做好适配的准备 36 | 37 | > 选择process model后可以不断调整以适应项目(如裁减等) 38 | > 39 | 4. **Team**建立高效团队 40 | 5. **Communication**建立沟通和协调coordination机制 41 | 6. **Change**管理变更 42 | 43 | > 比如:一个类经历了N次迭代,在N+1次迭代时需要修改,则需要管理前n次迭代中它所涉及到的类 44 | > 45 | 7. **Risk**风险评估 46 | 47 | > 比如:人员跳槽 48 | > 49 | 8. **Value**产品要有价值 50 | 51 | ### 7.2.2 引导实践Practice的原则 52 | 53 | 软件工程实践具有单一的overriding目标 - 提供可准时,高质量的操作软件,其中包含满足所有利益相关者需求的功能和功能。 54 | 55 | 1. **D&C**分而治之 56 | 57 | > 比如:按业务功能划分 58 | > 59 | 2. **Abstraction**理解和进行分析抽象 60 | 61 | > 比如:把requirement用use-case抽象表达;把数据库设计按entity,加上属性找relation,画出E-R图进行抽象,并最后进行代码的抽象 62 | > 63 | 3. **Consistency**前后一致尽量做到 64 | 4. **Transfer**注意信息的转换 65 | 66 | > 项目开发是一个信息转换过程,比如比如:input->system(本身就是信息转换过程)->output 67 | > 68 | 5. **Modularity** 构建表现出有效模块化的软件(类就是模块化),即类的定义 69 | 6. **Pattern**寻找模式 70 | 71 | > 遇到难以解决的问题,寻找已有模式或自己创造pattern,这样是为了提高产品质量 72 | > 73 | 7. **Perspective** 当可能时,从许多不同的角度来看,代表问题及其解决方案 74 | 8. **Maintain** 版本控制,保证人员调整后能接上工作 75 | 76 | ## 7.3 引导每个framework activity的原则 77 | 78 | CPMCD 79 | 80 | ### 7.3.1 Communication沟通的原则 81 | 82 | 对应requirement gathering,communication非常重要 83 | 84 | 1. **Listen** 听 85 | 2. **Prepare** 交流时要准备好 86 | 3. **Facilitate** 要有一个负责人来协调推动 87 | 4. **F-to-F** 最好面对面交流 88 | 5. **Notes** 交流记笔记 89 | 6. **Collaboration** 在需求调研时通力协作 90 | 7. **Modularize** 专注;模块化你的决策(大家发生冲突时,把发生冲突的部分分解,模块化继续讨论,这点挺重要的) 91 | 8. **Graph** 画图抽象 92 | 9. **Move-on** 同意,或不同意,或有不清晰现阶段无法弄明白的地方,继续并记录在案日后解决; 93 | 10. **Win-Win** 沟通不是竞赛,追求双赢 94 | 95 | ### 7.3.2 Planning计划的原则 96 | 97 | 过度计划浪费时间效率,但缺少计划会混乱 98 | 99 | 软件团队中的每个人都应该参加规划活动 100 | 101 | 1. **Scope** 确定项目的范围和边界才能planning 102 | 2. **Stakeholder** 要和甲方紧密交流,囊括进计划 103 | 3. **Iterative** planning是迭代的 104 | 4. **Estimate** 基于已知的来进行估算 105 | 5. **Risk** 计划时需要考虑风险 106 | 107 | > 对于已经识别的风险,把风险管理作为一个任务在计划中体现;对于未识别的风险,留一定的缓冲buffer空间(风险+预备处理方案) 108 | > 109 | 6. **Realistic** 现实点 110 | 7. **Granularity** 做计划时要定义计划的粒度,并调整粒度 111 | 112 | > 比如:一个大任务→分成n阶段→阶段分成子阶段→细分小粒度task 113 | > 114 | 8. **Quality** 制定计划以保证质量(比如:review) 115 | 9. **Change** 描述如何适应变更 116 | 117 | > 比如:敏捷模型可以更好适应变更 118 | > 119 | 10. **Track&Adjust** 跟踪计划,并根据需要实时调整计划 120 | 121 | > 比如:敏捷模型明天都要进行跟踪(燃尽图) 122 | > 123 | 124 | ### 7.3.3 Modeling建模原则 125 | 126 | 在软件工程工作中,可以创建两类模型:需求模型和设计模型。需求模型(也称为分析模型analyse model)代表客户要求通过将软件描绘在三个不同的域中:信息域(数据建模UML),功能域(Activity Diagram)和行为域(State和Sequence Diagram)。设计模型包括:概要设计&详细设计 127 | 128 | 即:数据建模,功能建模,行为建模 129 | 130 | **总体原则:** 131 | 132 | 1. **Software** 软件团队的主要目标是构建软件,而不是创建模型,模型不用太过细致 133 | 2. **Light** 要多少才建模多少,少建模型,开发过程轻量级 134 | 3. **Simple** 模型尽量简单 135 | 4. **Amenable** 模型要易于在不同迭代过程中进行变更(变更时要做版本控制,是前面提到的) 136 | 5. **Purpose** 模型都要有清晰的目的 137 | 6. **Adapt** 调整模型,适应待开发系统 138 | 7. **Useful** 建立实用的模型,不必完美(强调敏捷,为下一阶段做准备) 139 | 8. **Dogmatic** 构建模型的方法不必死板,不用全部按照规范,只要能辅助理解需求即可;如果它成功通信了,怎么表示是次要的 140 | 9. **Instinct** 直觉告诉你模型不太ok时,仔细检查 141 | 10. **Feedback** 及时反馈(通过daily meeting等) 142 | 143 | 具体来说,分两个:需求建模和设计建模 144 | 145 | 1️⃣需求建模原则 146 | 147 | 1. **Domain** 首先要进行数据建模产生类图 148 | 2. **Functions** 定义好软件功能。即:需要进行功能建模 149 | 150 | > eg:下订单的功能,在类图中找到涉及的类,用活动图表示逻辑,再用泳道图表示逻辑中涉及的类 151 | > 152 | 3. **Behavior** 行为建模 153 | 154 | > 借助State Diagram(注重State Transition) 和时序图Sequence Diagram 155 | > 156 | 4. **Layered** 尽可能细化分层 157 | 5. **Detail** analyse的task应该从基本信息转向实施细节,为后面设计建模和代码服务 158 | 159 | 2️⃣设计建模原则 160 | 161 | 设计模型为软件创建提供各种不同的系统视图(不同角度去理解系统,帮助coding) 162 | 163 | 设计建模: 164 | 165 | - 概要设计建模 166 | - 软件体系结构设计 167 | - 数据设计 168 | - 数据库 169 | - 数据仓库 170 | - 数据结构 171 | - 数据字典 172 | - 接口设计 173 | - 详细设计建模(为每个类每个方法进行设计) 174 | 175 | 1. **Traceable** 设计应追溯到需求模型(和前面的内容前后一致,Strive for consistency),也就是说,设计建模以分析建模作为依据 176 | 2. **Architecture** 概要设计中的软件体系结构(看上面)设计十分重要 177 | 3. **Data** 数据设计(看上面)与功能设计一样重要 178 | 4. **Interface** 内部接口和外部接口设计 179 | 5. **UI** 用户界面设计,要求简易且面向用户需求(一般用prototype model) 180 | 6. **Component** 组件设计应该在功能上独立 181 | 7. **Loose-coupled** 组件之间,组件与外部环境之间松散耦合 182 | 183 | > 比如:方法调用中形参,实参尽量简单而少,模板之间的参数尽量简单 184 | > 185 | 8. **Understandable** 设计模型应该容易理解 186 | 9. **Iterative** 设计应迭代进行 187 | 10. **Agile** 设计模型不应该拖累排除敏捷方法 188 | 189 | ### 7.3.4 Construction构建的原则 190 | 191 | 复习:Construction 192 | 193 | - coding 194 | - testing 195 | - unit testing单元测试 196 | - integration testing集成测试 197 | - system testing系统测试(又叫validation testing) 198 | - acception testing验收测试 199 | 200 | 201 | 1️⃣coding原则 202 | 203 | 要关注编程风格,语言方法集等 204 | 205 | A. 写代码前: 206 | 207 | 1. **Problem** 理解问题(详细设计) 208 | 2. **Principles** 理解基本的设计原则和概念(看详细设计对不对) 209 | 3. **Language** 语言选择,满足要构建的软件的需求以及它将运行的环境 210 | 4. **Environment** 环境选择(IDE等) 211 | 5. **Test** 写代码前把测试用例写进去,测试先行(单元测试Unit Testing先创建) 212 | 213 | B. 写代码时 214 | 215 | 1. **Structured** 结构化编程以写算法(结构化编程就是条件循环语句等) 216 | 2. **Pair** 结对编程 217 | 3. **DataStructure** 选好数据结构,要满足设计需求 218 | 4. **Arch&&Interface** 了解软件体系架构,创建与之一致的接口(也就是概要设计部分的文档内容) 219 | 5. **Simple** 尽可能保证条件逻辑简单 220 | 6. **Nested** 嵌套循环不要太深,要保证嵌套循环的可测试性(尽量避免,但不可避免时要使得嵌套循环可以较简单地被测试) 221 | 7. **Name** 变量命名要规范有意义 222 | 8. **Document** 要有注释(不用太细) 223 | 9. **Layout** 代码布局要好,增强代码的可读性(比如缩进空行等) 224 | 225 | C. 写代码的第一个代码版本完成后 226 | 227 | 1. **Walkthrough** 进行一次代码审查 228 | 229 | > walkthrough: 走查。只读评审(e.g. Review)的一种方法,如一行一行地review 230 | > 231 | 2. **Test** 单元测试,手机错误 232 | 3. **Refactor** 重构代码 233 | 234 | ![Untitled](Chapter%207%20%E8%BD%AF%E4%BB%B6%E5%B7%A5%E7%A8%8B%E5%AE%9E%E8%B7%B5%E5%8E%9F%E5%88%99Principles%20that%20guide%20practice%20bdaa5daeb0ba495e9391e6345636ede2/Untitled.png) 235 | 236 | 237 | 2️⃣testing原则 238 | 239 | 主要指动态测试 240 | 241 | 测试的要求: 242 | 243 | 1. **Definition** 测试是执行程序的过程,其中包含查找错误 244 | 245 | ↓(good) 246 | 247 | 2. **Probability** 一个良好的测试用例可以高概率找到尚未发现的错误 248 | 249 | ↓(successful) 250 | 251 | 3. **Uncover** 成功的测试是揭示尚未发现的错误的测试 252 | 253 | 原则 254 | 255 | 1. **Traceable** 所有测试都应追溯到客户要求Requirement 256 | 2. **Long** 在测试开始之前,应长期计划测试。 257 | 3. **Pareto** 帕累托原则适用于软件测试 258 | 4. **SmallToLarge** 测试应该开始从“小”中并进展到测试“大” (输入不可能覆盖全部情况,从小开始) 259 | 5. **Impossible** 穷尽Exhaustive的测试是不可能的 260 | 6. **Module** 应用于系统中的每个模块,测试工作与其预期的故障密度fault desity相称 261 | 262 | > 假设一千行代码有3-5个fault(也就是fault density故障密度,为度量值 ),测试的时候是7-8个,则说明超过了度量值,是有问题的 263 | > 264 | 7. **Static** 静态测试技术static testing techniques可以产生高结果 265 | 8. **Pattern** 跟踪缺陷并寻找通过测试未覆盖的缺陷模式。也就是说,这些缺陷是否满足一些pattern 266 | 9. **Correctly** 也要考虑演示软件行为正确的测试用例 267 | 268 | ### 7.3.5 Deployment部署原则 269 | 270 | 复习: 271 | 272 | 部署包括 273 | 274 | - delivery 交付 275 | - support 支持 276 | - feedback 反馈 277 | 278 | regime:运维团队 279 | 280 | 1. **Expectation** 处理好客户的预期 281 | 2. **Assembled** 一个完整的部署包delivery package必须被汇集并测试 282 | 3. **Support** 必须在软件交付之前建立支持制度support regime 283 | 4. **Material** 必须向用户提供教学材料(文档) 284 | 5. **Bug** 先修bug再deliver 285 | 286 | ## 7.4 Work Practice 287 | 288 | Isklod建议了超越编程语言和特定技术的10个概念,十分重要的特征。其中一些概念形成了欣赏软件工程在软件过程中的作用所需的先决知识(基础知识) 289 | 290 | 1. Interface (内部接口,外部接口和用户接口(界面)) 291 | 2. Conventions(规范) and templates (编程规范,功能、数据、行为建模的规范等;文档的模板,UseCase图构建的模板) 292 | 3. Layering (分层,抽象化) 293 | 4. Algorithmic complexity 294 | 5. Hashing 295 | 6. Caching 296 | 7. Concurrency 297 | 8. Cloud computing 298 | 9. Relational database -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-07-软件工程实践原则/Chapter 7 软件工程实践原则Principles that guide practice bdaa5daeb0ba495e9391e6345636ede2/Untitled.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-07-软件工程实践原则/Chapter 7 软件工程实践原则Principles that guide practice bdaa5daeb0ba495e9391e6345636ede2/Untitled.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-08-需求/Chapter 8 需求 Requirements fc5282f7a6e448868636cd812680ab31.md: -------------------------------------------------------------------------------- 1 | # Chapter 8 需求 Requirements 2 | 3 | - Modeling中的Analysis Modeling(分析建模) 4 | 5 | 需求阶段的2个work product——2份文档: 6 | 7 | - Requirement Specification 需求规约 8 | - Requirement Analysis Specification 需求分析建模(功能建模,数据建模,行为建模) 9 | 10 | ## 8.1 需求工程Requirement Engineering 11 | 12 | 包括: 13 | 14 | - requirement elicitation 15 | - requirement analysis modeling 16 | 17 | 定义:一系列导出并理解需求的广泛的技术或任务(task) 是需求工程 18 | 19 | 涉及到framework activity的部分: 20 | 21 | - Communication 22 | - Planning 23 | 24 | tasks set(需求工程的7个任务——task set原来的6个再加一个管理): 25 | 26 | 1. Inception 初始化——项目启动阶段 27 | 2. elicitation 诱导——需求调研 28 | 3. elaboration 阐述——细化进行建模 29 | 4. negotiation 谈判——需求谈判 30 | 5. specification 规约——形成2个规约 31 | 1. 需求规约——文字描述,UseCase 32 | 2. 需求分析规约——文字描述,功能建模,数据建模,行为建模 33 | 6. validation 验证——对规约进行评审(Formal Technical Review正规技术评审(见指南v1.0)) 34 | 7. management 管理——对需求进行版本控制和管理 35 | 36 | (7个任务是并行的parallel) 37 | 38 | ### 8.1.1 Inception 项目启动阶段 39 | 40 | 目的: 41 | 42 | 1. Target 确定项目总的目标 43 | 2. Communication 和stakeholder甲方进行初步有效的沟通 44 | 45 | 做的事情: 46 | 47 | 1. Identifying Stakeholders 明确甲方 48 | 2. Recognizing multiple viewpoints 辨认多个视点 49 | 3. Working toward collaboration 协作 50 | 4. Asking the first questions 51 | 5. Nonfunctional requirements 考虑非功能需求 52 | 53 | 明确跟你提要求的人,然后明确问题,从多个角度看问题。之后寻求和甲方的协作。协作达成后,考虑一些初始的问题,最后考虑非功能需求(这一大部分 可能不重要) 54 | 55 | ### 8.1.2 Elicitation 需求调研(诱导) 56 | 57 | 概况:针对上一个阶段确定的目标来进行需求调研 58 | 59 | 组成: 60 | 61 | 1. 确定商业目标establish business goals(要驱动甲方尽量不保留地表达他们的目标) 62 | 2. 建立: 63 | 1. 优先级机制:Prioritization mechanism 64 | 65 | ![Untitled](Chapter%208%20%E9%9C%80%E6%B1%82%20Requirements%20fc5282f7a6e448868636cd812680ab31/Untitled.png) 66 | 67 | 2. 成为一套潜在的软件系统架构设计依据的表达design rationale for a potential arch 68 | 69 | ![Untitled](Chapter%208%20%E9%9C%80%E6%B1%82%20Requirements%20fc5282f7a6e448868636cd812680ab31/Untitled%201.png) 70 | 71 | 72 | ![Untitled](Chapter%208%20%E9%9C%80%E6%B1%82%20Requirements%20fc5282f7a6e448868636cd812680ab31/Untitled%202.png) 73 | 74 | (上图:一套潜在的软件体系架构) 75 | 76 | 77 | 可能碰到的问题: 78 | 79 | 1. Problems of Scope 系统的边界 80 | 2. Problems of Understanding 对目标的进一步理解 81 | 3. Problems of Volatility 需求的易变性(在敏捷开发中容易解决,不能解决的放下,下个迭代时再做) 82 | 83 | ### 8.1.2※ Eliciting Requirements诱导 84 | 85 | 和考试最后的35分综合题有关 86 | 87 | 简述:理解需求,构建用例图,类图等 88 | 89 | **A. Collaborative Requirements Gathering 收集需求** 90 | 91 | 甲方最好提供1-2页的产品需求product request(在inception阶段) 92 | 93 | 基于产品需求开一次会,产品需求下发给每个参会者 94 | 95 | 会前每个参会者需制作的(需求调研要关注的4个方面): 96 | 97 | 1. a list of **objects**找到名词或名词词组(也就是一大堆的object,比如属性,方法,常量等);这些名词和词组有意义的找出来,数据有用的找出来来 (可能自己是对象;可能是某些名词的其他属性,这点要做好归属) 98 | 2. a list of **services(processes or functions)** 把(实意)动词(服务/功能)找出来 99 | 3. a list of **constraints** 找到约束和限制(比如:项目成本约束,项目大小约束,业务规则的约束) 100 | 4. **performance** & **nonfunctional** requirements 性能和系统的非功能需求 101 | 102 | e.g:案例——HomeSafe系统 103 | 104 | ![Untitled](Chapter%208%20%E9%9C%80%E6%B1%82%20Requirements%20fc5282f7a6e448868636cd812680ab31/Untitled%203.png) 105 | 106 | ![Untitled](Chapter%208%20%E9%9C%80%E6%B1%82%20Requirements%20fc5282f7a6e448868636cd812680ab31/Untitled%204.png) 107 | 108 | B. Quality Function Deployment(不重要) 109 | 110 | **C. Usage Scenarios 开发一个初步的(preliminary)使用场景** 111 | 112 | 这一步开始初步开发Use Case Diagram,主要还是scenario层面。更细致地讨论在elaboration 113 | 114 | ![Untitled](Chapter%208%20%E9%9C%80%E6%B1%82%20Requirements%20fc5282f7a6e448868636cd812680ab31/Untitled%205.png) 115 | 116 | **D. Elicitation Work Products 得到需求规约草稿specification draft** 117 | 118 | 需求诱导得到的work product会被系统的大小和软件产品的性质而影响变化 119 | 120 | work product一般内容: 121 | 122 | (1) a statement of need and feasibility, (2) a bounded statement of scope for the system or product, (3) a list of customers, users, and other stakeholders who participated in requirements elicitation, (4) a description of the system’s technical environment, (5) a list of requirements (preferably organized by function) and the domain constraints that applies to each, (6) a set of usage scenarios that provide insight into the use of the system or product under different operating conditions, and (7) any prototypes developed to better define requirements(理解) 123 | 124 | E. Agile Requirements Elicitation(不强调) 125 | 126 | F. Service-Oriented Methods(没啥) 127 | 128 | ### 8.1.3 Elaboration细化建模(ch11) 129 | 130 | 描述:把前两个阶段得到的信息进一步拓展和细化 131 | 132 | 步骤: 133 | 134 | 1. 进一步明确需求 135 | 2. 在这个基础上进行requirement analysis modeling 136 | 137 | **对UseCase的进一步细化开发** 138 | 139 | 8章附件1-图书馆借阅管理系统.doc 140 | 141 | **建立分析模型** 142 | 143 | 分析模型的组成元素: 144 | 145 | 1. 基于场景的元素:use case diagram , activity diagram (功能建模) 146 | 2. 基于类的元素:class diagram (数据建模) 147 | 3. 行为模型: state diagram (sequence diagram)(行为建模) 148 | 149 | (对于所有Use Case要构建sequence diagram,一个Use Case可以有多个sequence diagram) 150 | 151 | 功能建模,对每个功能逻辑的描述(在这里针对Use Case) 152 | 153 | class diagram针对每一个use case把它的类提取出来,提取出来后是离散的,这里会引入泛化( 把名词和名词词组总结出来后,看看名词有没有超过一个以上的属性值,则把它作为潜在的类;如果名词一个属性都没有,它可能是其他类的属性 ;再看有无继承、组合关系提取出来,最后将关系关联起来(一对一,一对多,多对多) 154 | 155 | 事件驱动:系统级别在事件驱动的状态下,可能有系统级别的状态图,是软件的体系结构设计依据。e.x. ATM机,在事件驱动下(读卡,输密码,选择交易,打印票据...靠外部动作事件驱动)--->是系统级别的状态图(state diagram),是main主程序设计的重要依据,而状态细节由客户定义出来。 156 | 157 | 大多数系统都没有系统级别的state diagram,但任何系统都有class的state diagram (把class diagram出来后,对每个class绘制状态图) 158 | 159 | 状态图(初步):可能还要考虑很多collaborator,在设计迭代时完善 160 | 161 | ### 8.1.4 Negotiation 谈判 162 | 163 | 描述:做哪些,不做哪些,并确定优先级 164 | 165 | ①识别系统或子系统的主要利益相关者。---->谁是stakeholder 166 | 167 | ②确定利益攸关方的“胜利条件”。--->stakeholder怎么获利 168 | 169 | ③利益攸关方的赢得条件将其与所有有关的一系列单胜条件(包括软件团队)的胜利条件调和→调和 170 | 171 | ### 8.1.5 Specification 规约 172 | 173 | 描述:这一步形成2个规约文档 174 | 175 | ### 8.1.6 Validation 评审 176 | 177 | 描述:把模糊的unambiguously,省略的omission,错误的error部分改正 178 | 179 | ### 8.1.7 Requirement Management 需求管理 180 | 181 | ![Untitled](Chapter%208%20%E9%9C%80%E6%B1%82%20Requirements%20fc5282f7a6e448868636cd812680ab31/Untitled%206.png) -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-08-需求/Chapter 8 需求 Requirements fc5282f7a6e448868636cd812680ab31/Untitled 1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-08-需求/Chapter 8 需求 Requirements fc5282f7a6e448868636cd812680ab31/Untitled 1.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-08-需求/Chapter 8 需求 Requirements fc5282f7a6e448868636cd812680ab31/Untitled 2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-08-需求/Chapter 8 需求 Requirements fc5282f7a6e448868636cd812680ab31/Untitled 2.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-08-需求/Chapter 8 需求 Requirements fc5282f7a6e448868636cd812680ab31/Untitled 3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-08-需求/Chapter 8 需求 Requirements fc5282f7a6e448868636cd812680ab31/Untitled 3.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-08-需求/Chapter 8 需求 Requirements fc5282f7a6e448868636cd812680ab31/Untitled 4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-08-需求/Chapter 8 需求 Requirements fc5282f7a6e448868636cd812680ab31/Untitled 4.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-08-需求/Chapter 8 需求 Requirements fc5282f7a6e448868636cd812680ab31/Untitled 5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-08-需求/Chapter 8 需求 Requirements fc5282f7a6e448868636cd812680ab31/Untitled 5.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-08-需求/Chapter 8 需求 Requirements fc5282f7a6e448868636cd812680ab31/Untitled 6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-08-需求/Chapter 8 需求 Requirements fc5282f7a6e448868636cd812680ab31/Untitled 6.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-08-需求/Chapter 8 需求 Requirements fc5282f7a6e448868636cd812680ab31/Untitled.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-08-需求/Chapter 8 需求 Requirements fc5282f7a6e448868636cd812680ab31/Untitled.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-09-需求建模:场景建模/Chapter 9 需求建模:基于场景的方法Requirement Modeling Scenari 78c266846b814885bf8d6faa700c2ddf.md: -------------------------------------------------------------------------------- 1 | # Chapter 9 需求建模:基于场景的方法Requirement Modeling:Scenario-Based Methods 2 | 3 | Use case/Activity/Swim lane 4 | 5 | ## 9.1 需求分析Requirement Analysis 6 | 7 | 需求建模这个Action会产出以下一个或多个种类的模型: 8 | 9 | 1. Scenario-Based Models 基于场景的需求模型(从多个系统的"actors"为出发点)**Chapter 9** 10 | 2. Class-Oriented Models or Data Models 类继承的模型或数据模型(基于信息域,表示面向对象类(属性&方法)和类之间的协作collaboration (数据模型现在也基本不用了) **Chapter 10** 11 | 3. Behavior Models 行为模型(外部的"event"引起的软件的动作)**Chapter 11** 12 | 4. Functional Models/Flow-Oriented Models 基于流的建模(现在基本不用) 13 | 14 | ### 9.1.1 需求建模的目标和学问Overall Objectives and Philosophy 15 | 16 | ※可能考多选题 17 | 18 | 需求建模的3个目的(primary objectives of the requirement model): 19 | 20 | 1. 描述用户想要什么 21 | 2. 为设计提供基础(概要设计&组件设计) 22 | 3. 定义需求的集合 23 | 24 | > 代码写完后,这个会作为评审的依据 e.g. 系统测试的依据→需求分析,需求分析规约 25 | > 26 | 27 | 重要的: 需求模型中的所有元素都对应了设计模型(design model)的一部分。但在这两个重要的建模活动之间清晰的analysis task和design task划分并不总是可能的 28 | 29 | ![Untitled](Chapter%209%20%E9%9C%80%E6%B1%82%E5%BB%BA%E6%A8%A1%EF%BC%9A%E5%9F%BA%E4%BA%8E%E5%9C%BA%E6%99%AF%E7%9A%84%E6%96%B9%E6%B3%95Requirement%20Modeling%20Scenari%2078c266846b814885bf8d6faa700c2ddf/Untitled.png) 30 | 31 | (这个边界要根据项目自身的情况确定) 32 | 33 | ### 9.1.2 分析建模的经验规则 Analysis Rules of Thumb 34 | 35 | 分析建模需要遵循的一些规则: 36 | 37 | 1. **Abstraction&Visible**抽象化程度要高,需求应该在问题和业务域内可视化(visible) 38 | 2. **Element**需求模型的每个元素都应增加对软件需求的整体理解,并提供系统的信息域,功能和行为 39 | 3. **Delay**做分析建模时可以先不考虑 40 | 1. 更细节的基础物件(e.g:数据库设计,前端界面等) 41 | 2. 非功能需求和性能的建模细化(e.g 架构,算法,数据库设计等影响性能的因素) 42 | 4. **Min-Coupling** 低耦合 43 | 44 | > 在构建UseCaseDiagram时,需要注意每个UseCase尽量高内聚,状态图中也有体现(大状态分为多个子状态(粒度小,内聚性高),只有高内聚后才有低耦合 45 | > 46 | 5. **Value** 要构建对Stakeholder有价值的需求模型 47 | 6. **Simple** 业务简单化 48 | 49 | ### 9.1.3 领域分析Domain Analysis 50 | 51 | 领域分析目的(为什么要Domain Analysis):把一些公共的analysis class和analysis pattern提取出来,对公共类进行很好定义再标化,以便于以后使用 52 | 53 | (e.g: 政府电子化办公,做完后进行很多类的标准化,**形成类库,**便于以后使用,避免重复开发) 54 | 55 | 领域分析可能被视为一个umbrella activity,是一个持续的软件工程activity 56 | 57 | 领域分析师:发现并定义一些很多人使用(不一定在一个应用中)分析模式,分析类(公共)和互相有联系的信息 58 | 59 | ※构建可复用类库的方式: 60 | 61 | DESER 62 | 63 | TRFD 64 | 65 | ![Untitled](Chapter%209%20%E9%9C%80%E6%B1%82%E5%BB%BA%E6%A8%A1%EF%BC%9A%E5%9F%BA%E4%BA%8E%E5%9C%BA%E6%99%AF%E7%9A%84%E6%96%B9%E6%B3%95Requirement%20Modeling%20Scenari%2078c266846b814885bf8d6faa700c2ddf/Untitled%201.png) 66 | 67 | ### 9.1.4 需求模型方法 Requirements Modeling Approaches 68 | 69 | Give a example for structured analysis modeling 9章附件 DFD data flow diagram建模.doc 70 | 71 | ※分析模型的元素 72 | 73 | ![Untitled](Chapter%209%20%E9%9C%80%E6%B1%82%E5%BB%BA%E6%A8%A1%EF%BC%9A%E5%9F%BA%E4%BA%8E%E5%9C%BA%E6%99%AF%E7%9A%84%E6%96%B9%E6%B3%95Requirement%20Modeling%20Scenari%2078c266846b814885bf8d6faa700c2ddf/Untitled%202.png) 74 | 75 | ## 9.2 SCENARIO-BASED MODELING 76 | 77 | (好像不大重要) 78 | 79 | 9.2.1 Creating a Preliminary Use Case 80 | 81 | 9.2.2 Refining a Preliminary Use Case 82 | 83 | 9.2.3 Writing a Formal Use Case 84 | 85 | ## 9.3 基于UseCase的UML模型 UML Models 86 | 87 | UML活动图通过提供特定方案内的交互流的图形表示来补充用例 88 | 89 | ### 9.3.1 活动图制作Activity Diagram 90 | 91 | 活动图需要针对每一个use case 92 | 93 | 对一个UseCase 94 | 95 | - 数据建模 Class Diagram 语法扫描——名词或名词词组可能是潜在业务类(Chapter 8) 96 | - 要对项目所提出的所有class做聚合和泛化(继承,目的是为了复用) 97 | - 功能建模 Activity Diagram(√ ) 98 | - 行为建模 State Diagram,Sequence Diagram 99 | 100 | ![Untitled](Chapter%209%20%E9%9C%80%E6%B1%82%E5%BB%BA%E6%A8%A1%EF%BC%9A%E5%9F%BA%E4%BA%8E%E5%9C%BA%E6%99%AF%E7%9A%84%E6%96%B9%E6%B3%95Requirement%20Modeling%20Scenari%2078c266846b814885bf8d6faa700c2ddf/Untitled%203.png) 101 | 102 | ### 9.3.2 泳道图制作 Swim Lane Diagram 103 | 104 | 泳道图是需要类的参与的,activity需要哪些类交互完成功能,在这个基础上完成了swimlane,所以一般在activity diagram和类图构建完之后再回到use case图构建swimlane 105 | 106 | 构建activity diagram要注意有正常异常等业务逻辑,所有业务逻辑的出口和流程都要在activity diagram表现;activity diagram也是构建sequence diagram的依据 107 | 108 | ![Untitled](Chapter%209%20%E9%9C%80%E6%B1%82%E5%BB%BA%E6%A8%A1%EF%BC%9A%E5%9F%BA%E4%BA%8E%E5%9C%BA%E6%99%AF%E7%9A%84%E6%96%B9%E6%B3%95Requirement%20Modeling%20Scenari%2078c266846b814885bf8d6faa700c2ddf/Untitled%204.png) -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-09-需求建模:场景建模/Chapter 9 需求建模:基于场景的方法Requirement Modeling Scenari 78c266846b814885bf8d6faa700c2ddf/Untitled 1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-09-需求建模:场景建模/Chapter 9 需求建模:基于场景的方法Requirement Modeling Scenari 78c266846b814885bf8d6faa700c2ddf/Untitled 1.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-09-需求建模:场景建模/Chapter 9 需求建模:基于场景的方法Requirement Modeling Scenari 78c266846b814885bf8d6faa700c2ddf/Untitled 2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-09-需求建模:场景建模/Chapter 9 需求建模:基于场景的方法Requirement Modeling Scenari 78c266846b814885bf8d6faa700c2ddf/Untitled 2.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-09-需求建模:场景建模/Chapter 9 需求建模:基于场景的方法Requirement Modeling Scenari 78c266846b814885bf8d6faa700c2ddf/Untitled 3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-09-需求建模:场景建模/Chapter 9 需求建模:基于场景的方法Requirement Modeling Scenari 78c266846b814885bf8d6faa700c2ddf/Untitled 3.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-09-需求建模:场景建模/Chapter 9 需求建模:基于场景的方法Requirement Modeling Scenari 78c266846b814885bf8d6faa700c2ddf/Untitled 4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-09-需求建模:场景建模/Chapter 9 需求建模:基于场景的方法Requirement Modeling Scenari 78c266846b814885bf8d6faa700c2ddf/Untitled 4.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-09-需求建模:场景建模/Chapter 9 需求建模:基于场景的方法Requirement Modeling Scenari 78c266846b814885bf8d6faa700c2ddf/Untitled.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-09-需求建模:场景建模/Chapter 9 需求建模:基于场景的方法Requirement Modeling Scenari 78c266846b814885bf8d6faa700c2ddf/Untitled.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682.md: -------------------------------------------------------------------------------- 1 | # Chapter 10 需求建模:基于类的方法Requirement Modeling: Class-Based Method 2 | 3 | ![Untitled](Chapter%2010%20%E9%9C%80%E6%B1%82%E5%BB%BA%E6%A8%A1%EF%BC%9A%E5%9F%BA%E4%BA%8E%E7%B1%BB%E7%9A%84%E6%96%B9%E6%B3%95Requirement%20Modeling%20Class-B%2000c5ea765c3d41b68cbc65a11ffda682/Untitled.png) 4 | 5 | Class-Based Model包括的内容: 6 | 7 | - Classes and Objects 类和对象 8 | - Attributes 属性 9 | - Operations 操作 10 | - CRC Models 类-责任-协作模型 11 | - Collaboration Diagrams 协作图 12 | - Packages 包 13 | 14 | ※ 总的步骤: 15 | 16 | 1. 类——**找到潜在的类(业务类)10.1** 17 | 18 | > 检查在Chapter 9 中的需求模型中的一部分usage scenarios;以UseCase为单位和依据,对对用例进行语法分析grammatical parse(每个UseCase检查有实义的名词或名词词组等) 19 | > 20 | 2. 属性和操作——每个UseCase在类定义下来后,**初步定义类里面的属性和方法** 21 | 3. CRC+聚合继承——建立CRC模型,构建**聚合和继承关系** 22 | 4. 关联和依赖——构建类与类之间的**关联关系、依赖关系** 23 | 24 | > 根据UseCase定义的类之间可能的关联(包括同一个UseCase中的类和不同UseCase中的类) 25 | > 26 | 5. 完整类图——构建**完整的类图** 27 | 28 | 第一次迭代通过语法扫描找到属性和方法 29 | 30 | 第二次迭代找到另一些属性方法补充 31 | 32 | 第三次迭代找到类之间协作关系 33 | 34 | ## 10.1 分析类 Analysis Classes 35 | 36 | 开始方法: 37 | 38 | 1. 检查在Chapter 9 中的需求模型中的一部分usage scenarios 39 | 2. 对用例进行语法分析grammatical parse(每个UseCase检查有实义的名词或名词词组等) 40 | 41 | **分析类的构成:边界类,实体类,控制类** 42 | 43 | 语法分析grammatical parse 44 | 45 | 由每个名词或名词短语确定并将其输入一个简单的表格。同义词要被记下来。如果需要类(名词)来实现解决方案,那么它就是解决方案空间的一部分;否则,如果只有要描述解决方案所必需的类,则它是问题空间的一部分。(例如,将物品添加到购物车) 46 | 47 | 分析类出现的方式: 48 | 49 | - **External Entity**外部实体——系统外 50 | 51 | > 其他的系统,设备,人;比如传感器,扫码器,等等 52 | > 53 | - **Things in Info Domain**属于信息域内的东西——系统内 54 | 55 | > 比如:报表,展示,信号灯 56 | > 57 | - **Occurrences or Events**上下文中出现的事件——事情 58 | 59 | > 比如:机器人完成一系列活动(这些例子都怪怪的) 60 | > 61 | - **Roles** 角色(因为Role Class加一些属性可能是系统中的关键信息——人 62 | 63 | > 比如:经理,工程师等 64 | > 65 | - **Organizational Units** 组织单元——组织 66 | 67 | > 以group或team为单位 68 | > 69 | - **Places** 建立问题背景和系统的整体功能的地方——环境 70 | 71 | > 比如:考试安排,则教室是一个分析类 72 | > 73 | - **Structures** 结构或用于定义一类对象或相关类的对象——结构 74 | 75 | > 往往与聚合有关系,如汽车管理系统中的汽车,轮胎等(聚合关系);用于定义一类对象或相关类的对象可能有control panel 76 | > 77 | 78 | ※案例:SafeHome Security 79 | 80 | ![Untitled](Chapter%2010%20%E9%9C%80%E6%B1%82%E5%BB%BA%E6%A8%A1%EF%BC%9A%E5%9F%BA%E4%BA%8E%E7%B1%BB%E7%9A%84%E6%96%B9%E6%B3%95Requirement%20Modeling%20Class-B%2000c5ea765c3d41b68cbc65a11ffda682/Untitled%201.png) 81 | 82 | 黑色:动词,蓝色:名词或名词词组 83 | 84 | ![Untitled](Chapter%2010%20%E9%9C%80%E6%B1%82%E5%BB%BA%E6%A8%A1%EF%BC%9A%E5%9F%BA%E4%BA%8E%E7%B1%BB%E7%9A%84%E6%96%B9%E6%B3%95Requirement%20Modeling%20Class-B%2000c5ea765c3d41b68cbc65a11ffda682/Untitled%202.png) 85 | 86 | 这个List将一直做,直到已考虑处理叙述中的所有名词。请注意,我们调用列表中的每个条目“潜在”类。在最终决定之前,我们必须进一步考虑。 87 | 88 | **最终确定潜在类**的6个方法(考试会考) 89 | 90 | 1. **Retained Info** 需要保留存在数据库中的信息——持久信息 91 | 92 | > 比如:学生有学号信息等 93 | > 94 | 2. **Needed Service** 潜在类中有很多方法服务——服务(方法) 95 | 96 | > 比如:学生需要获取成绩 97 | > 98 | 3. **Multiple Attributes** 潜在类应该有多个属性→低耦合——多属性 99 | 100 | > 只有一个属性的潜在类往往并入到其他类中 101 | > 102 | 4. **Common Attributes** 潜在类有通用属性(泛化,父子关系,基础关系)——通用属性 103 | 5. **Common Operations** 潜在类有通用方法——通用方法 104 | 6. **Essential Requirements** 潜在类(外部实体,必须的生成和消费信息)几乎总是在需求模型中被定义为类(?)——需求相关 105 | 106 | 上面的6种特征要全部满足或几乎全部满足。不过提取这些类是主观的过程,之后的评估可能会导致类的增加减少 107 | 108 | (请参阅英文课本P187页查看教员对类的深刻理解) 109 | 110 | ※以SafeHome Security继续为例子 111 | 112 | ![Untitled](Chapter%2010%20%E9%9C%80%E6%B1%82%E5%BB%BA%E6%A8%A1%EF%BC%9A%E5%9F%BA%E4%BA%8E%E7%B1%BB%E7%9A%84%E6%96%B9%E6%B3%95Requirement%20Modeling%20Class-B%2000c5ea765c3d41b68cbc65a11ffda682/Untitled%203.png) 113 | 114 | 还要注意:(可能考选择题,和分析类有关) 115 | 116 | 1. 上述列表不是全包,必须添加其他类以完成模型 117 | 2. 一些被拒绝的潜在类将成为被接受的那些类的属性(例如,数字和类型是传感器的属性,主密码和电话号码可能成为系统的属性),这是降级 118 | 3. 问题的不同陈述可能导致不同的“接受或拒绝”决定,对use case的理解描述不同,可能实现时有差别,需要交流(例如,如果每个房主都有单独的密码或通过语音印刷识别,房主课程将满足特征1和2,并且已被接受) 119 | 120 | ## 10.2 细化属性Specify Attributes 121 | 122 | 步骤: 123 | 124 | 1. 进一步study用例,一些名词词组或一些含数值信息的名词词组没有成为类,可能是依附于某些类的属性 125 | 2. 没有在用例描述中出现的词,通过data dict进行分解 126 | 127 | 以**UseCase图中的每个用例**作为分析单元,研究每个用例 128 | 129 | 判断依据:当前问题的上下文中有哪些数据项 130 | 131 | 数据字典(输入输出数据的组织):细分出以下作为System类的属性 132 | 133 | ![Untitled](Chapter%2010%20%E9%9C%80%E6%B1%82%E5%BB%BA%E6%A8%A1%EF%BC%9A%E5%9F%BA%E4%BA%8E%E7%B1%BB%E7%9A%84%E6%96%B9%E6%B3%95Requirement%20Modeling%20Class-B%2000c5ea765c3d41b68cbc65a11ffda682/Untitled%204.png) 134 | 135 | 一个分析类的例子:系统类 136 | 137 | ![Untitled](Chapter%2010%20%E9%9C%80%E6%B1%82%E5%BB%BA%E6%A8%A1%EF%BC%9A%E5%9F%BA%E4%BA%8E%E7%B1%BB%E7%9A%84%E6%96%B9%E6%B3%95Requirement%20Modeling%20Class-B%2000c5ea765c3d41b68cbc65a11ffda682/Untitled%205.png) 138 | 139 | ## 10.3 定义操作Operation 140 | 141 | 找Operation的方法:进一步扫描UseCase文字描述,找到实际意义的动词,补充类里面的方法 142 | 143 | 例子: 144 | 145 | ![Untitled](Chapter%2010%20%E9%9C%80%E6%B1%82%E5%BB%BA%E6%A8%A1%EF%BC%9A%E5%9F%BA%E4%BA%8E%E7%B1%BB%E7%9A%84%E6%96%B9%E6%B3%95Requirement%20Modeling%20Class-B%2000c5ea765c3d41b68cbc65a11ffda682/Untitled%206.png) 146 | 147 | 四个广泛类别: 148 | 149 | 1. 操作——操作以某种方式操纵数据(例如,添加,删除,重新格式化,选择)数据操作 150 | 2. 计算——执行计算的操作 151 | 3. 状态——询问对象状态的操作 152 | 4. 监控——监视对象以发生控制事件的操作。 153 | 154 | > 进一步调查下,操作program()可能会被分成一个数字或更加详细的子操作以配置系统。比如program()暗示了具体的电话号码,配置系统的特征(e.g. 创建sensor table,进入alarm特征,输入密码等,但目前我们先把program()细化成单一的方法) 155 | > 156 | 157 | 例子: 158 | 159 | ![Untitled](Chapter%2010%20%E9%9C%80%E6%B1%82%E5%BB%BA%E6%A8%A1%EF%BC%9A%E5%9F%BA%E4%BA%8E%E7%B1%BB%E7%9A%84%E6%96%B9%E6%B3%95Requirement%20Modeling%20Class-B%2000c5ea765c3d41b68cbc65a11ffda682/Untitled%207.png) 160 | 161 | ## 10.4 CRC建模Class-Responsibility-Collaborator(类的建模的基础上) 162 | 163 | Responsibilities是与类相关的属性和操作 164 | 165 | Collaborators是提供Class所需的其他Class,其中包含填写Responsibility所需的信息。通常,一个Collaboration意味着对某些动作的信息请求或请求。 166 | 167 | 例子: 168 | 169 | ![Untitled](Chapter%2010%20%E9%9C%80%E6%B1%82%E5%BB%BA%E6%A8%A1%EF%BC%9A%E5%9F%BA%E4%BA%8E%E7%B1%BB%E7%9A%84%E6%96%B9%E6%B3%95Requirement%20Modeling%20Class-B%2000c5ea765c3d41b68cbc65a11ffda682/Untitled%208.png) 170 | 171 | (TODO) 172 | 173 | ### Class 174 | 175 | 业务实体类:通过对用例描述进行语法扫描得到的类为实体类 176 | 177 | 边界类/界面类: 用于创建接口的类,管理实体类对象与用户之间的交互(不会直接展现) 178 | 179 | ![Untitled](Chapter%2010%20%E9%9C%80%E6%B1%82%E5%BB%BA%E6%A8%A1%EF%BC%9A%E5%9F%BA%E4%BA%8E%E7%B1%BB%E7%9A%84%E6%96%B9%E6%B3%95Requirement%20Modeling%20Class-B%2000c5ea765c3d41b68cbc65a11ffda682/Untitled%209.png) 180 | 181 | 控制类:用于管理: 182 | 183 | 1. **Creation&Updates** 实体对象的创建更新 184 | 2. **BoundaryInstantiation** 边界类的实例化,用以获取实体类信息 185 | 3. **Communication** 管理一组对象之间的复杂通信 186 | 4. **Validation** 验证对象或用户和应用程序之间传送的数据 187 | 188 | ![Untitled](Chapter%2010%20%E9%9C%80%E6%B1%82%E5%BB%BA%E6%A8%A1%EF%BC%9A%E5%9F%BA%E4%BA%8E%E7%B1%BB%E7%9A%84%E6%96%B9%E6%B3%95Requirement%20Modeling%20Class-B%2000c5ea765c3d41b68cbc65a11ffda682/Untitled%2010.png) 189 | 190 | ### Responsibility 191 | 192 | attributes and operations 193 | 194 | 类的Responsibility进一步优化的五个指导思想:DLGES 195 | 196 | 1. **Distributed** 系统的功能应该被均匀的划分到不同的类的属性中去,每个类只获取并执行少量的系统功能任务信息,这样系统的内聚性(同时达到高内聚,什么类就做什么样的事情)得到加权 197 | 2. **General** 属性和方法需要具有一定的通用性 198 | 3. **Encapsulation** info和与它相关的behavior应该在同一类中。这实现了名为封装(encapsulation)的面向对象原则 199 | 4. **Localized** 一个东西的信息不应该被distributed而应该放在一个类中。一个Class应承担store和operate特定类型的信息的责任,实现了单一的功能 200 | 5. **Shared** 责任应在合适的情况下在相关类中共享 201 | 202 | > e.g.游戏Sprite的身体:这些类中的每一个都有自己的属性(例如,位置,方向,颜色,速度),并且所有这些类都必须更新并显示,因为用户操纵操纵杆。因此,必须由每个对象共享职责更新和显示 203 | > 204 | 205 | 206 | ### Collaborations 207 | 208 | 类以两种方式之一履行职责: 209 | 210 | 1. **Inner** 使用自己的方法来操纵自己的属性,从而履行特定的责任; 211 | 2. **Collaborate** 与其他类合作,给其他类用属性或使用其他类属性 212 | 213 | (一个类没法自己实现完全功能时,合作) 214 | 215 | 类之间的关系: 216 | 217 | 1. is-part-of relationship 聚合关系(整体与部分) 218 | 2. has-knowledge-of relationship 关联关系(类之间想获取彼此的想你想) 219 | 3. depend-upon relationship 依赖关系(一个类属性取决于另一个类属性) 220 | 221 | ![Untitled](Chapter%2010%20%E9%9C%80%E6%B1%82%E5%BB%BA%E6%A8%A1%EF%BC%9A%E5%9F%BA%E4%BA%8E%E7%B1%BB%E7%9A%84%E6%96%B9%E6%B3%95Requirement%20Modeling%20Class-B%2000c5ea765c3d41b68cbc65a11ffda682/Untitled%2011.png) 222 | 223 | 224 | 当已开发完整的CRC模型时,stakeholder可以使用以下方法查看模型:(例如:用户登录的用例,其活动图为用户登录活动图.png) 225 | 226 | 1. **Seperation** 审核的所有人都发到CRC卡,有合作关系的卡分开,确保一个人手上的牌之间都没有协作关系 227 | 2. **Category** 所有的use-case scenario(以及相应的用例图)需要被分类 228 | 3. **Leader** 审查的领导人读取一个用例,进而引入一个已命名的对象。领导人将令牌token传递给有相应的类索引的人 229 | 4. **Describe** 当token传递时,要求卡片的持有者描述卡上注明的责任。审核组确定是否有一个(或更多)的责任满足用例要求 230 | 5. **Modify** 如果在索引卡上指出的责任和协作无法适应用例,则\修改卡片。这可能包括新类(以及相应的CRC索引卡)的定义或在现有卡上的新或修订的责任或协作的规范。 231 | 232 | ## 10.5 关联和依赖Associations and Dependencies 233 | 234 | ![Untitled](Chapter%2010%20%E9%9C%80%E6%B1%82%E5%BB%BA%E6%A8%A1%EF%BC%9A%E5%9F%BA%E4%BA%8E%E7%B1%BB%E7%9A%84%E6%96%B9%E6%B3%95Requirement%20Modeling%20Class-B%2000c5ea765c3d41b68cbc65a11ffda682/Untitled%2012.png) 235 | 236 | ![Untitled](Chapter%2010%20%E9%9C%80%E6%B1%82%E5%BB%BA%E6%A8%A1%EF%BC%9A%E5%9F%BA%E4%BA%8E%E7%B1%BB%E7%9A%84%E6%96%B9%E6%B3%95Requirement%20Modeling%20Class-B%2000c5ea765c3d41b68cbc65a11ffda682/Untitled%2013.png) 237 | 238 | ![Untitled](Chapter%2010%20%E9%9C%80%E6%B1%82%E5%BB%BA%E6%A8%A1%EF%BC%9A%E5%9F%BA%E4%BA%8E%E7%B1%BB%E7%9A%84%E6%96%B9%E6%B3%95Requirement%20Modeling%20Class-B%2000c5ea765c3d41b68cbc65a11ffda682/Untitled%2014.png) 239 | 240 | ## 10.6 分析包Analysis Packages 241 | 242 | 分析建模的重要部分是分类。也就是说,需求模型的各种元素(例如,用例,分析类别)被分类为将它们作为分组的分组包装的方式进行分类——就是分析包 243 | 244 | ![Untitled](Chapter%2010%20%E9%9C%80%E6%B1%82%E5%BB%BA%E6%A8%A1%EF%BC%9A%E5%9F%BA%E4%BA%8E%E7%B1%BB%E7%9A%84%E6%96%B9%E6%B3%95Requirement%20Modeling%20Class-B%2000c5ea765c3d41b68cbc65a11ffda682/Untitled%2015.png) -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682/Untitled 1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682/Untitled 1.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682/Untitled 10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682/Untitled 10.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682/Untitled 11.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682/Untitled 11.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682/Untitled 12.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682/Untitled 12.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682/Untitled 13.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682/Untitled 13.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682/Untitled 14.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682/Untitled 14.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682/Untitled 15.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682/Untitled 15.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682/Untitled 2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682/Untitled 2.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682/Untitled 3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682/Untitled 3.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682/Untitled 4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682/Untitled 4.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682/Untitled 5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682/Untitled 5.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682/Untitled 6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682/Untitled 6.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682/Untitled 7.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682/Untitled 7.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682/Untitled 8.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682/Untitled 8.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682/Untitled 9.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682/Untitled 9.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682/Untitled.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-10-需求建模:类的建模/Chapter 10 需求建模:基于类的方法Requirement Modeling Class-B 00c5ea765c3d41b68cbc65a11ffda682/Untitled.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-11-需求模型:行为,模式和Web:Mobile应用/Chapter 11 需求模型:行为,模式和Web Mobile应用Behavior, Patter faa232a97269449cb6ce53579e561f36.md: -------------------------------------------------------------------------------- 1 | # Chapter 11 需求模型:行为,模式和Web/Mobile应用Behavior, Pattern and Web/Mobile App 2 | 3 | sequence diagram图的作用: 4 | 5 | 1. V和类图互相验证 6 | 2. C为类的协作提供依据; 7 | 3. S和swim lane diagram互相印证(类在所有的sequence diagram都要出现)) 8 | 9 | 11.1 - 11.4 行为模型(专注后端) 10 | 11 | 11.5 Web&Mobile模型(专注前端) 12 | 13 | 状态图:对类方法设计的重要参考依据 14 | 15 | **行为建模描述了系统的状态及其Class以及事件对这些状态的影响** 16 | 17 | ## 11.1 行为模型建立 Behavioral Model 18 | 19 | 建立步骤: 20 | 21 | 1. CREATING A BEHAVIORAL MODEL 评估所有的**UseCase**以完全了解系统交互的sequence **11.1** 22 | 2. IDENTIFYING EVENTS WITH THE USE CASE 认清驱动交互sequence的所有**Events**以及它们相关的**Objects 11.3** 23 | 3. STATE REPRESENTATIONS I 为系统或各种类画状态图**StateDiagram 11.4** 24 | 4. STATE REPRESENTATIONS II 对每个用例图画时序图**SequenceDiagram 11.4** 25 | 5. 检查**Examine**行为模型验证准确性与一致性 26 | 27 | 两种图:状态图,时序图 28 | 29 | ## 11.2 认清Use Case的事件 Events 30 | 31 | 需要做的:对每个事件events认清actor,交换的信息和所有约束条件都要罗列出来 32 | 33 | ## 11.3 状态展示 State Presentations 34 | 35 | 在行为建模的上下文中,必须考虑两种不同的状态特征: 36 | 37 | (1)当系统执行其功能时,每个类的状态 类的状态 38 | 39 | (2)当系统执行其功能时从外部观察到的系统状态。 系统状态 40 | 41 | ### 1. 状态图→进一步完善类的方法 42 | 43 | 状态图表示了每个类的活跃状态 STE 44 | 45 | ![Untitled](Chapter%2011%20%E9%9C%80%E6%B1%82%E6%A8%A1%E5%9E%8B%EF%BC%9A%E8%A1%8C%E4%B8%BA,%E6%A8%A1%E5%BC%8F%E5%92%8CWeb%20Mobile%E5%BA%94%E7%94%A8Behavior,%20Patter%20faa232a97269449cb6ce53579e561f36/Untitled.png) 46 | 47 | 系统状态图一定有,而在面向对象设计开发时对每个类图也要有状态图 48 | 49 | guard: 一个布尔条件,是状态转移发生时的判别式 50 | 51 | ![Untitled](Chapter%2011%20%E9%9C%80%E6%B1%82%E6%A8%A1%E5%9E%8B%EF%BC%9A%E8%A1%8C%E4%B8%BA,%E6%A8%A1%E5%BC%8F%E5%92%8CWeb%20Mobile%E5%BA%94%E7%94%A8Behavior,%20Patter%20faa232a97269449cb6ce53579e561f36/Untitled%201.png) 52 | 53 | ### 2. 时序图→实例化的对象怎么交互,来完成UseCase的功能 54 | 55 | 时序图是用例的速写版本。它表示关键类和导致行为从类流到类的行为的事件 56 | 57 | ![Untitled](Chapter%2011%20%E9%9C%80%E6%B1%82%E6%A8%A1%E5%9E%8B%EF%BC%9A%E8%A1%8C%E4%B8%BA,%E6%A8%A1%E5%BC%8F%E5%92%8CWeb%20Mobile%E5%BA%94%E7%94%A8Behavior,%20Patter%20faa232a97269449cb6ce53579e561f36/Untitled%202.png) 58 | 59 | 用例足以描述分析水平的相互作用(在设计期间引入了进一步的细化和细节),但时序图可以更加严格语法化规范化。 60 | 61 | ## 11.4 需求模型的模式Patterns for Requirement Modeling 62 | 63 | 分析模式Analysis Patterns存储在存储库中,以便软件团队的成员可以使用搜索工具来查找和重用它们。 64 | 65 | ## 11.5 Web和Mobile应用的需求建模 66 | 67 | 移动应用程序往往更专注并提供更有限的计算和操纵功能。无论功能性的广度如何,都需要分析功能要求,并在必要时建模。 68 | 69 | ### 11.5.1 分析到什么程度 70 | 71 | 取决于以下因素: 72 | 73 | 1. 应用增量的大小和复杂度 74 | 2. stakeholder的数量 75 | 3. 开发团队的规模 76 | 4. 开发团队有没有之前合作过的经验 77 | 5. 软件开发的成功对整个开发组织活动的成功的重要性 78 | 79 | > 随着项目变小,利益相关者的数量较少,开发团队更具凝聚力,而且应用程序不太重要,应用更轻质的分析方法是合理的,这个时候analyse就没必要太细了 80 | > 81 | 82 | ### 11.5.2 输入 83 | 84 | 不重要应该 85 | 86 | ### 11.5.3 前端需求建模的要求(输出) 87 | 88 | 前端模型的5个主要种类: 89 | 90 | 1. 内容模型 **Content Model** 选择内容对象和内容对象的布局,比如文本图形图像视频等数据 91 | 2. 交互模型 **Interaction Model** 通过交互完成功能 92 | 3. 功能模型 **Functional Model** 定于用于内容对象的操作 93 | 4. 导航模型 **Navigation Model** 完成特定功能的导航(完成应用程序的总体导航策略) 94 | 5. 配置模型 **Configuration Model** 配置图,比如前端、后端、网络等配置 95 | 96 | **以上5个部分确定后,可进行原型模型开发** 97 | 98 | ### 11.5.4 内容模型 **Content Model** ① 99 | 100 | 内容模型包含结构元素,为应用程序提供了重要内容要求的重要视图 101 | 102 | 比如:HomeKeep系统中购买零部件界面中,包含信息的控件(图片,购买说明,宣传视频,价格栏......),他们可能放在不同界面,所以要结构化 103 | 104 | Content objects can be determined directly from use cases by examining the scenario description for direct and indirect references to content. 105 | 106 | 在许多情况下,与每个对象的简要描述耦合的内容对象的简单列表足以定义必须设计和实现的内容的要求。 107 | 108 | ※必考:data tree是干什么的 109 | 110 | ※表达方式:Data Tree(内容模型的数据结构:数据分解树) 111 | 112 | ![Untitled](Chapter%2011%20%E9%9C%80%E6%B1%82%E6%A8%A1%E5%9E%8B%EF%BC%9A%E8%A1%8C%E4%B8%BA,%E6%A8%A1%E5%BC%8F%E5%92%8CWeb%20Mobile%E5%BA%94%E7%94%A8Behavior,%20Patter%20faa232a97269449cb6ce53579e561f36/Untitled%203.png) 113 | 114 | ### 11.5.5 交互建模 Interaction Model ② 115 | 116 | 核心:实现某种功能 117 | 118 | 在内容建模的基础上,针对UseCase的功能,用界面将它的功能反应出来(借助Activity Diagram)来交互建模 119 | 120 | 组成元素:(一个或多个) 121 | 122 | - 用例图U 123 | - 序列图S 124 | - 状态图S 125 | - 用户建模原型prototypes P 126 | 127 | 虽然可以说,创建用户界面原型是一种设计活动,但在创建分析模型Analysis Model期间执行它是一个好主意。因为用户界面prototype做完了,则有很多部分得到了确定 128 | 129 | 例子: 130 | 131 | ![Untitled](Chapter%2011%20%E9%9C%80%E6%B1%82%E6%A8%A1%E5%9E%8B%EF%BC%9A%E8%A1%8C%E4%B8%BA,%E6%A8%A1%E5%BC%8F%E5%92%8CWeb%20Mobile%E5%BA%94%E7%94%A8Behavior,%20Patter%20faa232a97269449cb6ce53579e561f36/Untitled%204.png) 132 | 133 | 练习:创建接口原型的工具(Azure) 134 | 135 | ### 11.5.6 功能建模Functional Model ③ 136 | 137 | 在交互界面的基础上,借助之前的activity diagram,对界面进行细化 138 | 139 | 功能模型解决了两个应用程序处理元素,其中每个应用程序要素表示不同的过程抽象级别: 140 | 141 | 1. 由应用程序传递给最终用户的用户可观察功能 user observable functionality 142 | 2. 在实现与之相关联的行为的分析类中包含的操作类。 143 | 144 | 关键:在交互模型的基础上,借助activity diagram对界面功能逻辑进行细化。比如:通过退货的活动图,画出退货功能的流程图,然后找出完成这个功能所需要进行交互的内容对象 145 | 146 | ### 11.5.7 导航建模 Navigation Modeling ④ 147 | 148 | 导航通常受到相对简单的按钮列表和基于图标的菜单的约束 149 | 150 | 建立导航建模的一些需要考虑的问题:(PPT32页,爱谁看谁看吧,反正记不住) 151 | 152 | ### 11.5.8 配置建模Configure Model 153 | 154 | 配置模型是服务器端和客户端属性的列表。把网络IP,交换机,服务器连接起来的普通图。是High-Level Design -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-11-需求模型:行为,模式和Web:Mobile应用/Chapter 11 需求模型:行为,模式和Web Mobile应用Behavior, Patter faa232a97269449cb6ce53579e561f36/Untitled 1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-11-需求模型:行为,模式和Web:Mobile应用/Chapter 11 需求模型:行为,模式和Web Mobile应用Behavior, Patter faa232a97269449cb6ce53579e561f36/Untitled 1.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-11-需求模型:行为,模式和Web:Mobile应用/Chapter 11 需求模型:行为,模式和Web Mobile应用Behavior, Patter faa232a97269449cb6ce53579e561f36/Untitled 2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-11-需求模型:行为,模式和Web:Mobile应用/Chapter 11 需求模型:行为,模式和Web Mobile应用Behavior, Patter faa232a97269449cb6ce53579e561f36/Untitled 2.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-11-需求模型:行为,模式和Web:Mobile应用/Chapter 11 需求模型:行为,模式和Web Mobile应用Behavior, Patter faa232a97269449cb6ce53579e561f36/Untitled 3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-11-需求模型:行为,模式和Web:Mobile应用/Chapter 11 需求模型:行为,模式和Web Mobile应用Behavior, Patter faa232a97269449cb6ce53579e561f36/Untitled 3.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-11-需求模型:行为,模式和Web:Mobile应用/Chapter 11 需求模型:行为,模式和Web Mobile应用Behavior, Patter faa232a97269449cb6ce53579e561f36/Untitled 4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-11-需求模型:行为,模式和Web:Mobile应用/Chapter 11 需求模型:行为,模式和Web Mobile应用Behavior, Patter faa232a97269449cb6ce53579e561f36/Untitled 4.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-11-需求模型:行为,模式和Web:Mobile应用/Chapter 11 需求模型:行为,模式和Web Mobile应用Behavior, Patter faa232a97269449cb6ce53579e561f36/Untitled.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-11-需求模型:行为,模式和Web:Mobile应用/Chapter 11 需求模型:行为,模式和Web Mobile应用Behavior, Patter faa232a97269449cb6ce53579e561f36/Untitled.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-12-设计理念/Chapter 12 设计概念 Design Concepts 66a797a2ef8d4dce83eb09e546473079.md: -------------------------------------------------------------------------------- 1 | # Chapter 12 设计概念 Design Concepts 2 | 3 | 软件设计包括实现高质量系统或产品的开发的一组**原则principles,概念concepts和实践practices**。 4 | 5 | 设计阶段: 6 | 7 | - 有关软件体系架构的设计(包括:系统架构,设计类图)->以数据建模结果(分析类图)为依据 → high-level design 8 | - 有关数据的设计(数据库,数据结构) 9 | - 接口设计(不同层次的接口,包括UI)→ high-level design 10 | - 组件设计(单个类的设计,同样以分析类图为基础)→ detailed design 11 | 12 | ## 12.1 以软件工程上下文(Context)为依据进行设计 13 | 14 | 在完成需求建模后,Design是Modeling这个Activity最后的Action 15 | 16 | 架构举例: 17 | 18 | 1. C语言(函数调用) 19 | 20 | ![Untitled](Chapter%2012%20%E8%AE%BE%E8%AE%A1%E6%A6%82%E5%BF%B5%20Design%20Concepts%2066a797a2ef8d4dce83eb09e546473079/Untitled.png) 21 | 22 | 2. 面向对象开发的体系架构 23 | 24 | ![Untitled](Chapter%2012%20%E8%AE%BE%E8%AE%A1%E6%A6%82%E5%BF%B5%20Design%20Concepts%2066a797a2ef8d4dce83eb09e546473079/Untitled%201.png) 25 | 26 | 27 | ※ 老师在黑板上画的软件体系架构图 28 | 29 | ![Untitled](Chapter%2012%20%E8%AE%BE%E8%AE%A1%E6%A6%82%E5%BF%B5%20Design%20Concepts%2066a797a2ef8d4dce83eb09e546473079/Untitled%202.png) 30 | 31 | ※ 将需求模型翻译成设计模型requirement model → design model 32 | 33 | interface design: 需要Use Case的场景元素来搭建界面,所以依赖于场景元素里面的场景(不含功能模块),然后,类不仅有类内部的交互,还可能用到其他类的方法,而时序图描述的是一个Use Case中不同类的交互(比如Actor和Entity等),所以这里还需要时序图,故需要行为模型 34 | 35 | data/class design: 包括数据库,数据结构,类设计,数据字典等。很显然需要Class Base Element中的类去搭建(和数据建模相关)其中 1. 数据库设计以分析类图为依据,一对一多对多等关系构建ER图进而建库;2. 数据结构设计也要参考类设计;3. 类的设计自然需要类图,同时完善协作关系; 36 | 37 | Arch design: 这里需要用到类和类之间的协作关系,通过CRC卡片和类去划分功能相关的子系统,同时写子系统内部的类和方法(内部完善)进而再通过协作关系确定子系统间的通信方式,并根据这个写接口类,完成软件体系架构设计 38 | 39 | 组件设计:1 需要参考分析类图,因为需要设计类之间的相互调用,通过看调用关系增加方法;2.要看状态图和时序图,根据不同状态调用不同方法。 40 | 41 | ![Untitled](Chapter%2012%20%E8%AE%BE%E8%AE%A1%E6%A6%82%E5%BF%B5%20Design%20Concepts%2066a797a2ef8d4dce83eb09e546473079/Untitled%203.png) 42 | 43 | ※ 数据设计中的数据字典 44 | 45 | ![Untitled](Chapter%2012%20%E8%AE%BE%E8%AE%A1%E6%A6%82%E5%BF%B5%20Design%20Concepts%2066a797a2ef8d4dce83eb09e546473079/Untitled%204.png) 46 | 47 | ## 12.2 设计过程Design Process 48 | 49 | 设计的描述:对需求阶段的结果不断进行**迭代优化** 50 | 51 | 随着设计迭代的发生,随后的细化(refinement)导致了在更低的抽象层次上的设计表现。这些仍然可以追溯到需求,但这种联系更加微妙 52 | 53 | ### 12.2.1 Software Quality Guidelines and Attributes 54 | 55 | 必考 56 | 57 | 评估一个设计是否好的3个评估标准: 58 | 59 | 1. **Requirements** 设计应由所有(显式)需求演变而来,即以分析建模analysis modeling为基础 60 | 61 | > 需求包括:显式需求,隐式需求;设计时stakeholder要参与 62 | > 63 | 2. **Readable** 设计要好理解 64 | 3. **Picture** 设计要把前阶段的数据建模、功能建模、行为建模等完整表示出来 65 | 66 | (TODO) 67 | 68 | **质量指导方针Quality Guidelines** (8个,可能考选择题) 69 | 70 | 1. 完整地继承分析阶段的体系架构,并由recognizable的架构风格或模式构造而成(architectural styles or patterns) 71 | 2. 设计得出的结构应该 72 | 1. 由好的组件构成composed of components 73 | 2. 可以以进化方式evolutionary fashion实现,从而促进实施implementation和测试testing 74 | 3. 设计的结果应该模块化(modular),构成子系统(subsystems) 75 | 4. 设计的数据结构,接口,组件设计必须清晰(distinct representation) 76 | 5. 设计应该易于实现,类的设计选用合适的数据结构(lead to data structures that are appropriate for the classes to be implemented and are drawn from recognizable data patterns) 77 | 6. 要高内聚,有独立的功能(components should exhibit independent functional characteristic) 78 | 7. 接口要尽量简单(比如参数少) (interface that reduce the complexity) 79 | 8. 设计的结果应可复用(using a repeatable method) 80 | 9. 用于表示设计的记号要有意义(notation that effectively communicates its meaning) 81 | 82 | > 比如:命名应该有意义,便于理解 83 | > 84 | 85 | 86 | 这些设计方针Design Guidelines是通过应用基本设计原则,系统方法论和彻底审查来实现的。 87 | 88 | **质量属性Quality Attributes** 89 | 90 | 所有软件设计的目标——**FURPS** quality attributes 91 | 92 | - F: **Functionality** 功能性 (需求的功能均要实现) 93 | 94 | > 评估方式:程序的函数集和函数function set & function,被delivered的函数的通用性generality以及整个系统的安全性security。 95 | > 96 | - U: **Usability** 可用性 97 | 98 | > 评估方式:overall的美观性aesthetics,一致性consistency,导航navigation,文档documentation等 99 | > 100 | - R: **Reliability** 可靠性 101 | 102 | > 评价方式:测量失败的频率frequency和严重程度severity,输出结果的精度accuracy(如:要求保留两位但只达到一位)),平均故障时间(MTTF, mean -time-to-failure),从故障中恢复的能力recover ability,以及程序的可预测性predictability。 103 | > 104 | - P: **Performance** 性能 105 | 106 | > 评价方式:处理速度processing speed,响应时间response time,资源消耗consumption,吞吐量throughput和效率efficiency 107 | > 108 | 109 | ![Untitled](Chapter%2012%20%E8%AE%BE%E8%AE%A1%E6%A6%82%E5%BF%B5%20Design%20Concepts%2066a797a2ef8d4dce83eb09e546473079/Untitled%205.png) 110 | 111 | - S: **Supportability** 可支持性 112 | 113 | > 评价指标:可维护性(maintainability)【包括:可扩展性extensibility(系统要+功能),适应性adaptability(可以在不同设备上适应)和可维护性serviceability(出了问题或变更需求如何定位可否修复)】。另外,可测试性testability,兼容性compatibility,可配置性configurability,可以安装系统的简化性ease,以及有哪些问题可以本地化(the ease with which a system can be installed, and the ease with which problems can be localized) 114 | > 115 | 116 | 上述质量属性一般同等重要,但在一些应用中可能会强调其中一些 117 | 118 | ### 12.2.2 软件设计的演化The Evolution of Software Design 119 | 120 | method: 121 | 122 | - top-down structured method 自上而下的结构(C语言架构) 123 | - object-oriented approach 面向对象设计方法 124 | - aspect-oriented methods 125 | - model-driven development 126 | - test-driven development 127 | 128 | 这些method的共同特征: 129 | 130 | 1. M将需求模型转换为设计表示的机制mechanism 131 | 2. N表示功能组件及其接口的记号notation 132 | 3. H改进和分区的启发性(heuristics for refinement and partitioning) 133 | 4. G软件评估的指导方针(guidelines for quality assessment) 134 | 135 | ## 12.3 设计概念Design Concepts 136 | 137 | ### 12.3.1 抽象Abstraction 138 | 139 | 建模一直在抽象,代码是最终的抽象 140 | 141 | Give an example for the abstraction 142 | 143 | ### 12.3.2 架构Architectural 144 | 145 | 举例:前后端分离的架构 146 | 147 | 什么是架构: 148 | 149 | architecture is the structure or organization of program components (modules), the manner in which these components interact, and the structure of data that are used by the components 150 | 151 | 即: 1. 对组件模块的组织;2. 组件的交互方式;3. 组件使用数据的结构 152 | 153 | ### 12.3.3 模式Patterns 154 | 155 | 解决某问题的具体步骤(成熟的方法) 156 | 157 | ### 12.3.4 分支Separation of Concerns 158 | 159 | 包括: 160 | 161 | - modularity模块化(大项目分解为子系统,子系统分解为模块) 162 | - aspect每个模块负责的事情 163 | - functional independence功能独立 164 | - refinement功能细化 165 | 166 | ### 12.3.5 模块化Modularity 167 | 168 | Pi:某功能 169 | 170 | C:复杂度 171 | 172 | E:工作量 173 | 174 | 一般对任务$P1$,$P2$,如果$C(P1)>C(P2)$ ,那么$E(P1)>E(P2)$ 175 | 176 | 另外有: 177 | 178 | $E(P1+P2)>E(P1)+E(P2)$ 179 | 180 | $C(P1+P2)>C(P1)+C(P2)$ 181 | 182 | 分而治之在这里体现,合在一起做工作量更大,分而治之可以节约成本 183 | 184 | ※模块化和软件开销的关系 185 | 186 | ![Untitled](Chapter%2012%20%E8%AE%BE%E8%AE%A1%E6%A6%82%E5%BF%B5%20Design%20Concepts%2066a797a2ef8d4dce83eb09e546473079/Untitled%206.png) 187 | 188 | 随着模块数量的增多,用于集成integrate的开销越大,而每个模块开发的成本平摊越少,两者加起来类似一个二次函数,这个二次函数有个最优区间,叫最小开销区间(M) 189 | 190 | ### 12.3.6 模块化中的信息隐藏Modularity→Info Hiding 191 | 192 | 要达到信息隐藏必须有功能独立性也就是模块化 193 | 194 | 应指定和设计模块,以便模块中包含的信息(算法和数据)无法对不需要此类信息的其他模块无法访问 195 | 196 | B调用A时,有时需要A部分信息对B隐藏 197 | 198 | ### 12.3.7 功能的独立性 Functional Independence 199 | 200 | separation of concerns, modularity , abstraction, information hiding 最终共同作用形成 Function Independence 201 | 202 | 独立性的两个标准:内聚性和耦合性(cohesion和coupling)——高内聚低耦合 203 | 204 | ### 12.3.8 细化Refinement 205 | 206 | 细化的过程是一个不断分解的过程 207 | 208 | ### 12.3.9 面向方面的设计(Design) aspects 209 | 210 | 一个aspect是一个crosscutting concern的展示(WTF?),它的实现方式为一个单独的module(component) 211 | 212 | 要跨不同的类进行交互(比如:interface class可能是个aspect) 213 | 214 | ### 12.3.10 重构Refactoring 215 | 216 | 重构的目的:避免代码冗余,调整不合适的数据结构等 217 | 218 | [代码重构的方式(Chapter 7)](https://www.notion.so/Chapter-7-Principles-that-guide-practice-b7c1cbf9ffcf4c7c96ba29341aa2b519) 219 | 220 | ### 12.3.11 面向对象的设计理念Object-Oriented Design Concepts 221 | 222 | ### 12.3.12 设计类Design Classes 223 | 224 | 分析类转设计类 225 | 226 | 设计类的抽象等级要相对高些 227 | 228 | ※设计类的种类(5种,分别代表设计结构design architecture的不同layer): 229 | 230 | 1. User Interface classes 用户界面类的设计(sequence diagram & use case diagram) 231 | 2. Business domain classes 业务类(由分析类直接转过来,基本是一对一,可能有优化比如一个分析类分成2个类等) 232 | 3. Process classes/Control classes 控制类(往往没有属性,只有方法)对系统的可维护性很重要 233 | 4. Persistent classes 持久类(用于数据持久化,比如被Hibernate持久化到数据库中的类,持久化类的实例对象将保存在数据库或文件中) 234 | 5. System classes 系统类(如Java的主类有main()方法) 235 | 236 | ※体现设计类的好会(4个指标( 237 | 238 | 1. Complete and Sufficient 完整充分(属性方法的完整封装encapsulation)封装良好 239 | 2. Primitiveness 原始性(同样的功能和属性不能在2个或多个类中出现) 不重复,每个属性方法都是原始的 240 | 3. High Cohesion 高内聚(属性和方法与类本身相关) 241 | 4. Low Coupling 低耦合(交互接口要简单) 242 | 243 | > 接口类的存在就是为了低耦合;一个类更多应该访问邻界类,尽量少访问其他package或subsystem;子系统中的一个类不需要知道其他类太多信息,最好通过内部接口或外部接口这些控制接口类去访问得到 244 | > 245 | 246 | 247 | ![Untitled](Chapter%2012%20%E8%AE%BE%E8%AE%A1%E6%A6%82%E5%BF%B5%20Design%20Concepts%2066a797a2ef8d4dce83eb09e546473079/Untitled%207.png) -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-12-设计理念/Chapter 12 设计概念 Design Concepts 66a797a2ef8d4dce83eb09e546473079/Untitled 1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-12-设计理念/Chapter 12 设计概念 Design Concepts 66a797a2ef8d4dce83eb09e546473079/Untitled 1.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-12-设计理念/Chapter 12 设计概念 Design Concepts 66a797a2ef8d4dce83eb09e546473079/Untitled 2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-12-设计理念/Chapter 12 设计概念 Design Concepts 66a797a2ef8d4dce83eb09e546473079/Untitled 2.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-12-设计理念/Chapter 12 设计概念 Design Concepts 66a797a2ef8d4dce83eb09e546473079/Untitled 3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-12-设计理念/Chapter 12 设计概念 Design Concepts 66a797a2ef8d4dce83eb09e546473079/Untitled 3.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-12-设计理念/Chapter 12 设计概念 Design Concepts 66a797a2ef8d4dce83eb09e546473079/Untitled 4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-12-设计理念/Chapter 12 设计概念 Design Concepts 66a797a2ef8d4dce83eb09e546473079/Untitled 4.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-12-设计理念/Chapter 12 设计概念 Design Concepts 66a797a2ef8d4dce83eb09e546473079/Untitled 5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-12-设计理念/Chapter 12 设计概念 Design Concepts 66a797a2ef8d4dce83eb09e546473079/Untitled 5.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-12-设计理念/Chapter 12 设计概念 Design Concepts 66a797a2ef8d4dce83eb09e546473079/Untitled 6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-12-设计理念/Chapter 12 设计概念 Design Concepts 66a797a2ef8d4dce83eb09e546473079/Untitled 6.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-12-设计理念/Chapter 12 设计概念 Design Concepts 66a797a2ef8d4dce83eb09e546473079/Untitled 7.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-12-设计理念/Chapter 12 设计概念 Design Concepts 66a797a2ef8d4dce83eb09e546473079/Untitled 7.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-12-设计理念/Chapter 12 设计概念 Design Concepts 66a797a2ef8d4dce83eb09e546473079/Untitled.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-12-设计理念/Chapter 12 设计概念 Design Concepts 66a797a2ef8d4dce83eb09e546473079/Untitled.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-13-概要设计/Chapter 13 概要设计Architectural Design 9e4603d4be424c0a9a80eae7a68bd514.md: -------------------------------------------------------------------------------- 1 | # Chapter 13 概要设计Architectural Design 2 | 3 | 架构设计从数据建模开始(以分析类图为依据) 4 | 5 | 1. 构建子系统 6 | 2. 子系统内部的类,有什么类需要交互 7 | 3. 子系统之间的协作 8 | 4. 子系统之间的控制接口类 9 | 10 | ## Overview: 一个示例 11 | 12 | ![Untitled](Chapter%2013%20%E6%A6%82%E8%A6%81%E8%AE%BE%E8%AE%A1Architectural%20Design%209e4603d4be424c0a9a80eae7a68bd514/Untitled.png) 13 | 14 | superordinate system 上游系统 15 | 16 | subordinate system 下游系统 17 | 18 | ![Untitled](Chapter%2013%20%E6%A6%82%E8%A6%81%E8%AE%BE%E8%AE%A1Architectural%20Design%209e4603d4be424c0a9a80eae7a68bd514/Untitled%201.png) 19 | 20 | 数据流架构 21 | 22 | ## 13.1 体系架构Software Architecture 23 | 24 | ### 13.1.1 什么是体系架构 25 | 26 | 架构是否有效,设计是否依据了需求规约的Use Case图和需求分析规约中的Class Diagram图 27 | 28 | 架构的作用: 29 | 30 | - 在满足其定下的需求时,分析设计的有效性 31 | - 在设计改变仍然很容易时可以考虑架构的替代方案 32 | - 减少与软件构建相关的风险 33 | 34 | 组件:可以是一个类的程序模块,也可能是数据库和中间层 35 | 36 | ### 13.1.2 体系架构设计的重要性Importance 37 | 38 | - 提供了便于StakeHolders交流的表示 39 | - 对后续组件设计和coding有深远意义 40 | - 一个相对小的,容易理解,展现组件如何组合在一起工作的模型 41 | 42 | ### 13.1.3 架构描述 43 | 44 | 要求:架构描述要简洁和易于理解,因为它形成了协商的基础,特别是在确定系统边界的时候 45 | 46 | ### 13.1.4 架构决策Architectural Decisions 47 | 48 | 架构师会考虑多种备选方案,并最终确定最能满足需求的架构 49 | 50 | ![Untitled](Chapter%2013%20%E6%A6%82%E8%A6%81%E8%AE%BE%E8%AE%A1Architectural%20Design%209e4603d4be424c0a9a80eae7a68bd514/Untitled%202.png) 51 | 52 | ## 13.2 体系架构的流派Genres 53 | 54 | 需要体系架构的系统:人工智能的体系架构,通信系统,设备,金融,游戏,工业,法律,.... 55 | 56 | ## 13.3 架构风格Architectural Styles 57 | 58 | 一个Styles会描述系统中的 59 | 60 | - 一系列组件components (比如:数据库,计算模型等) 61 | - 组件中的协作所需的connectors(对系统内部的分系列的连接,子系统间的连接,后台与中间键的连接) 62 | - 一些constraints,定义了组件如何集成为系统需要 63 | - 语义图semantic models(语义模型)→ 便于设计者理解系统的层次 64 | 65 | ### 13.3.1 架构的简单分类 66 | 67 | - **Data-Centered Architectures:** 68 | 69 | 数据为中心的软件体系结构:如Github等,多个客户端软件访问数据中心(最早) 70 | 71 | 数据存储于体系结构的中心,并经常被更新操作删除 72 | 73 | ![Untitled](Chapter%2013%20%E6%A6%82%E8%A6%81%E8%AE%BE%E8%AE%A1Architectural%20Design%209e4603d4be424c0a9a80eae7a68bd514/Untitled%203.png) 74 | 75 | - **Data-Flow Architectures:** 76 | 77 | 数据流的软件体系架构: 金融,银行的batch subsystem 78 | 79 | 当输入数据要经过一系列计算操作组件转化为输入 80 | 81 | 模式:”管道-过滤器“(pipe-filter) 模式 82 | 83 | filters: 通过pipe连接,从一个组件传输到下一个组件,比如银行的批处理过滤出账户信息等 84 | 85 | 一般用c语言写 86 | 87 | ![Untitled](Chapter%2013%20%E6%A6%82%E8%A6%81%E8%AE%BE%E8%AE%A1Architectural%20Design%209e4603d4be424c0a9a80eae7a68bd514/Untitled%204.png) 88 | 89 | - **Call and Return Architectures** 调用和返回结构 90 | 91 | C语言架构 92 | 93 | ![Untitled](Chapter%2013%20%E6%A6%82%E8%A6%81%E8%AE%BE%E8%AE%A1Architectural%20Design%209e4603d4be424c0a9a80eae7a68bd514/Untitled%205.png) 94 | 95 | Call And Return Architecture in C一般3个分支: 96 | 97 | 1. 最左侧分支为对输入处理 98 | 2. 中间分支为对业务本身的处理 99 | 3. 最右侧分支为对输出打印的处理么 100 | - **Object-Oriented Architectures** 面向对象架构 101 | 102 | 设计以Use Case图和类图为依据,要用到CRC 103 | 104 | - **Layered Architectures** 层次架构 105 | 106 | 典型:MVC 107 | 108 | ![Untitled](Chapter%2013%20%E6%A6%82%E8%A6%81%E8%AE%BE%E8%AE%A1Architectural%20Design%209e4603d4be424c0a9a80eae7a68bd514/Untitled%206.png) 109 | 110 | 把前面几种进行整合 111 | 112 | 113 | ![Untitled](Chapter%2013%20%E6%A6%82%E8%A6%81%E8%AE%BE%E8%AE%A1Architectural%20Design%209e4603d4be424c0a9a80eae7a68bd514/Untitled%207.png) 114 | 115 | 在这个银行系统中,左上是Data-Flow Arch, 左下是Call and Return Arch, 右下是Object-Oriented Arch,可见复杂的系统中存在多种架构风格 116 | 117 | ### 13.3.2 架构模式Architectural Patterns 118 | 119 | 架构模式在特定上下文中以及一组限制和约束下解决特定于应用程序的问题。该模式提出了一种可以作为建筑设计的基础的架构解决方案。 120 | 121 | ### 13.3.3 架构的优化Organization and Refinement 122 | 123 | 建立一组设计标准很重要,它可用于评估衍生的架构设计。尤其是用敏捷开发时每一次都要注意架构的优化(特别是最初的迭代) 124 | 125 | related: 演化过程模型(Chapter 4),重构(Chapter 12) 126 | 127 | ## 13.6 系统架构Architectural Design 128 | 129 | 架构师要建立ACD(Architectural Context Diagram): 这个图就是系统的architecture(就是最上面的图) 130 | 131 | 包括: 132 | 133 | 1. 软件架构设计 134 | 2. 数据/数据库设计(以类图为依据,有时涉及数据字典设计,和接口紧密相关) 135 | 3. 接口设计(内部接口(类内方法互相调用) ,类间,子系统间方法调用,外部接口,用户接口) 136 | 137 | deployment diagram: 部署图,要包括(内网外网),系统的部署方式(云平台等) 138 | 139 | (TODO) 140 | 141 | ### 13.6.1 系统上下文的建立 142 | 143 | ※ ACD图: 144 | 145 | ![Untitled](Chapter%2013%20%E6%A6%82%E8%A6%81%E8%AE%BE%E8%AE%A1Architectural%20Design%209e4603d4be424c0a9a80eae7a68bd514/Untitled%208.png) 146 | 147 | 内容:上游系统superordinate,下游系统subordinate,目标系统,Actors,Peers(同级系统,与目标系统同一个等级,与本系统进行交互,双方面通信)。 148 | 149 | ※以家庭安保系统为案例 150 | 151 | ![Untitled](Chapter%2013%20%E6%A6%82%E8%A6%81%E8%AE%BE%E8%AE%A1Architectural%20Design%209e4603d4be424c0a9a80eae7a68bd514/Untitled%209.png) 152 | 153 | ![Untitled](Chapter%2013%20%E6%A6%82%E8%A6%81%E8%AE%BE%E8%AE%A1Architectural%20Design%209e4603d4be424c0a9a80eae7a68bd514/Untitled%2010.png) -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-13-概要设计/Chapter 13 概要设计Architectural Design 9e4603d4be424c0a9a80eae7a68bd514/Untitled 1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-13-概要设计/Chapter 13 概要设计Architectural Design 9e4603d4be424c0a9a80eae7a68bd514/Untitled 1.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-13-概要设计/Chapter 13 概要设计Architectural Design 9e4603d4be424c0a9a80eae7a68bd514/Untitled 10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-13-概要设计/Chapter 13 概要设计Architectural Design 9e4603d4be424c0a9a80eae7a68bd514/Untitled 10.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-13-概要设计/Chapter 13 概要设计Architectural Design 9e4603d4be424c0a9a80eae7a68bd514/Untitled 2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-13-概要设计/Chapter 13 概要设计Architectural Design 9e4603d4be424c0a9a80eae7a68bd514/Untitled 2.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-13-概要设计/Chapter 13 概要设计Architectural Design 9e4603d4be424c0a9a80eae7a68bd514/Untitled 3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-13-概要设计/Chapter 13 概要设计Architectural Design 9e4603d4be424c0a9a80eae7a68bd514/Untitled 3.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-13-概要设计/Chapter 13 概要设计Architectural Design 9e4603d4be424c0a9a80eae7a68bd514/Untitled 4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-13-概要设计/Chapter 13 概要设计Architectural Design 9e4603d4be424c0a9a80eae7a68bd514/Untitled 4.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-13-概要设计/Chapter 13 概要设计Architectural Design 9e4603d4be424c0a9a80eae7a68bd514/Untitled 5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-13-概要设计/Chapter 13 概要设计Architectural Design 9e4603d4be424c0a9a80eae7a68bd514/Untitled 5.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-13-概要设计/Chapter 13 概要设计Architectural Design 9e4603d4be424c0a9a80eae7a68bd514/Untitled 6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-13-概要设计/Chapter 13 概要设计Architectural Design 9e4603d4be424c0a9a80eae7a68bd514/Untitled 6.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-13-概要设计/Chapter 13 概要设计Architectural Design 9e4603d4be424c0a9a80eae7a68bd514/Untitled 7.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-13-概要设计/Chapter 13 概要设计Architectural Design 9e4603d4be424c0a9a80eae7a68bd514/Untitled 7.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-13-概要设计/Chapter 13 概要设计Architectural Design 9e4603d4be424c0a9a80eae7a68bd514/Untitled 8.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-13-概要设计/Chapter 13 概要设计Architectural Design 9e4603d4be424c0a9a80eae7a68bd514/Untitled 8.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-13-概要设计/Chapter 13 概要设计Architectural Design 9e4603d4be424c0a9a80eae7a68bd514/Untitled 9.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-13-概要设计/Chapter 13 概要设计Architectural Design 9e4603d4be424c0a9a80eae7a68bd514/Untitled 9.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-13-概要设计/Chapter 13 概要设计Architectural Design 9e4603d4be424c0a9a80eae7a68bd514/Untitled.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-13-概要设计/Chapter 13 概要设计Architectural Design 9e4603d4be424c0a9a80eae7a68bd514/Untitled.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-14-详细设计/Chapter 14 详细设计Component-Level Design 773b02d5513548fe811ce52375e9a92c.md: -------------------------------------------------------------------------------- 1 | # Chapter 14 详细设计Component-Level Design 2 | 3 | 软件体系架构图中各个部分(每一个类)组件的细化设计。以**分析类为依据**,对分析类进行细化补充 4 | 5 | 组件级(Component-Level)设计定义了分配给每个软件组件的数据结构,算法,接口特性和通信机制。 6 | 7 | 进行设计评审。检查设计以确定数据结构,接口,处理序列和逻辑条件是否正确。 8 | 9 | ![Untitled](Chapter%2014%20%E8%AF%A6%E7%BB%86%E8%AE%BE%E8%AE%A1Component-Level%20Design%20773b02d5513548fe811ce52375e9a92c/Untitled.png) 10 | 11 | ## 14.1 组件 12 | 13 | (要看) 14 | 15 | (面向对象的角度来说)组件不仅包含自己本身,而且还涉及一组合作类 16 | 17 | 要点: 18 | 19 | 1. Attributes——类的属性的详细定义 20 | 2. Operation——对内部方法进行定义(Activity Diagram→对 21 | 22 | 案例:打印商店 23 | 24 | ![Untitled](Chapter%2014%20%E8%AF%A6%E7%BB%86%E8%AE%BE%E8%AE%A1Component-Level%20Design%20773b02d5513548fe811ce52375e9a92c/Untitled%201.png) 25 | 26 | 2个接口:computeJob调用内部4个方法计算各个属性;initJob要进行建立工作,工作顺序排序等 27 | 28 | ![Untitled](Chapter%2014%20%E8%AF%A6%E7%BB%86%E8%AE%BE%E8%AE%A1Component-Level%20Design%20773b02d5513548fe811ce52375e9a92c/Untitled%202.png) 29 | 30 | ![Untitled](Chapter%2014%20%E8%AF%A6%E7%BB%86%E8%AE%BE%E8%AE%A1Component-Level%20Design%20773b02d5513548fe811ce52375e9a92c/Untitled%203.png) 31 | 32 | ## 14.3 进行组件级别设计 33 | 34 | (重点重点!这章最重要的部分) 35 | 36 | 你必须将需求requirements和架构模型architectural model的信息转化为设计表示,以提供足够的细节来指导构建(coding和testing)活动。 37 | 38 | **详细设计步骤:** 39 | 40 | 1. P认定与问题域Problem Domain对应的所有**设计类**(**根据分析类完善业务类的设计**) 41 | 2. I认定与基础域Infrastructure Domain对应的所有设计类(业务功能)——e.g: GUI类,操作系统有关的组件,数据管理有关的类(对数据库访问,比如软件架构图中连接数据库组件和其他子系统的数据库连接子系统的组件) 42 | 43 | > 一些Infrastucture Domain相关的类的知识:①只有方法没有组件的类——接口类(没有内部结构,也没有associations);②只有属性没有方法的类——全局变量初始化类,只定义常量的类;③与业务无关的类——界面类 44 | > 45 | 1. 详细阐述未获得作为可重用组件的所有设计类(对不用复用的业务类进行细化)——包括该类所需的所有接口,属性,操作,还得启发式设计(高内聚低耦合) 46 | 1. 在类或组**件协作时,指定消息**详细信息(message details) 47 | 48 | ![Untitled](Chapter%2014%20%E8%AF%A6%E7%BB%86%E8%AE%BE%E8%AE%A1Component-Level%20Design%20773b02d5513548fe811ce52375e9a92c/Untitled%204.png) 49 | 50 | ![Untitled](Chapter%2014%20%E8%AF%A6%E7%BB%86%E8%AE%BE%E8%AE%A1Component-Level%20Design%20773b02d5513548fe811ce52375e9a92c/Untitled%205.png) 51 | 52 | 2. 定义每个**组件的接口**(先定义消息message,再定义接口interface) 53 | 54 | ![Untitled](Chapter%2014%20%E8%AF%A6%E7%BB%86%E8%AE%BE%E8%AE%A1Component-Level%20Design%20773b02d5513548fe811ce52375e9a92c/Untitled%206.png) 55 | 56 | 3. 定**义属性,数据的类型,和需要的数据结构** 57 | 58 | ![Untitled](Chapter%2014%20%E8%AF%A6%E7%BB%86%E8%AE%BE%E8%AE%A1Component-Level%20Design%20773b02d5513548fe811ce52375e9a92c/Untitled%207.png) 59 | 60 | ![Untitled](Chapter%2014%20%E8%AF%A6%E7%BB%86%E8%AE%BE%E8%AE%A1Component-Level%20Design%20773b02d5513548fe811ce52375e9a92c/Untitled%208.png) 61 | 62 | 4. **详细描述每个类每个方法的处理流程**(利用**UML Activity Diagram**或**伪代码**) 63 | 64 | ![Untitled](Chapter%2014%20%E8%AF%A6%E7%BB%86%E8%AE%BE%E8%AE%A1Component-Level%20Design%20773b02d5513548fe811ce52375e9a92c/Untitled%209.png) 65 | 66 | 67 | 1. 描述持久层的**数据源**(数据库或文件)并定义**数据管理类**(是在概要设计中进行的)——对概要设计中的数据进行review (持久的数据和相关的类) 68 | 2. **Review**一下每个类的状态图是否合理,对设计类进行**行为建模** 69 | 70 | ![Untitled](Chapter%2014%20%E8%AF%A6%E7%BB%86%E8%AE%BE%E8%AE%A1Component-Level%20Design%20773b02d5513548fe811ce52375e9a92c/Untitled%2010.png) 71 | 72 | ![Untitled](Chapter%2014%20%E8%AF%A6%E7%BB%86%E8%AE%BE%E8%AE%A1Component-Level%20Design%20773b02d5513548fe811ce52375e9a92c/Untitled%2011.png) 73 | 74 | 3. 画**部署图**,提供额外的实现细节(基于架构图) 75 | 4. **重构**每个**组件级设计表示**(component-level design representation),考虑备选方案。进行Review 76 | 77 | ![Untitled](Chapter%2014%20%E8%AF%A6%E7%BB%86%E8%AE%BE%E8%AE%A1Component-Level%20Design%20773b02d5513548fe811ce52375e9a92c/Untitled%2012.png) -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-14-详细设计/Chapter 14 详细设计Component-Level Design 773b02d5513548fe811ce52375e9a92c/Untitled 1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-14-详细设计/Chapter 14 详细设计Component-Level Design 773b02d5513548fe811ce52375e9a92c/Untitled 1.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-14-详细设计/Chapter 14 详细设计Component-Level Design 773b02d5513548fe811ce52375e9a92c/Untitled 10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-14-详细设计/Chapter 14 详细设计Component-Level Design 773b02d5513548fe811ce52375e9a92c/Untitled 10.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-14-详细设计/Chapter 14 详细设计Component-Level Design 773b02d5513548fe811ce52375e9a92c/Untitled 11.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-14-详细设计/Chapter 14 详细设计Component-Level Design 773b02d5513548fe811ce52375e9a92c/Untitled 11.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-14-详细设计/Chapter 14 详细设计Component-Level Design 773b02d5513548fe811ce52375e9a92c/Untitled 12.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-14-详细设计/Chapter 14 详细设计Component-Level Design 773b02d5513548fe811ce52375e9a92c/Untitled 12.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-14-详细设计/Chapter 14 详细设计Component-Level Design 773b02d5513548fe811ce52375e9a92c/Untitled 2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-14-详细设计/Chapter 14 详细设计Component-Level Design 773b02d5513548fe811ce52375e9a92c/Untitled 2.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-14-详细设计/Chapter 14 详细设计Component-Level Design 773b02d5513548fe811ce52375e9a92c/Untitled 3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-14-详细设计/Chapter 14 详细设计Component-Level Design 773b02d5513548fe811ce52375e9a92c/Untitled 3.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-14-详细设计/Chapter 14 详细设计Component-Level Design 773b02d5513548fe811ce52375e9a92c/Untitled 4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-14-详细设计/Chapter 14 详细设计Component-Level Design 773b02d5513548fe811ce52375e9a92c/Untitled 4.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-14-详细设计/Chapter 14 详细设计Component-Level Design 773b02d5513548fe811ce52375e9a92c/Untitled 5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-14-详细设计/Chapter 14 详细设计Component-Level Design 773b02d5513548fe811ce52375e9a92c/Untitled 5.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-14-详细设计/Chapter 14 详细设计Component-Level Design 773b02d5513548fe811ce52375e9a92c/Untitled 6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-14-详细设计/Chapter 14 详细设计Component-Level Design 773b02d5513548fe811ce52375e9a92c/Untitled 6.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-14-详细设计/Chapter 14 详细设计Component-Level Design 773b02d5513548fe811ce52375e9a92c/Untitled 7.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-14-详细设计/Chapter 14 详细设计Component-Level Design 773b02d5513548fe811ce52375e9a92c/Untitled 7.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-14-详细设计/Chapter 14 详细设计Component-Level Design 773b02d5513548fe811ce52375e9a92c/Untitled 8.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-14-详细设计/Chapter 14 详细设计Component-Level Design 773b02d5513548fe811ce52375e9a92c/Untitled 8.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-14-详细设计/Chapter 14 详细设计Component-Level Design 773b02d5513548fe811ce52375e9a92c/Untitled 9.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-14-详细设计/Chapter 14 详细设计Component-Level Design 773b02d5513548fe811ce52375e9a92c/Untitled 9.png -------------------------------------------------------------------------------- /Software-Engineering-Notes/Chapter-14-详细设计/Chapter 14 详细设计Component-Level Design 773b02d5513548fe811ce52375e9a92c/Untitled.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/MountPOTATO/Software-Engineering-Notes/26de635187f8e5155ec753e8dd3319fad80c1b56/Software-Engineering-Notes/Chapter-14-详细设计/Chapter 14 详细设计Component-Level Design 773b02d5513548fe811ce52375e9a92c/Untitled.png --------------------------------------------------------------------------------