《详细设计述描的工具》由会员分享,可在线阅读,更多相关《详细设计述描的工具(30页珍藏版)》请在金锄头文库上搜索。
1、 第五章 详细设计描述的工具5.1 详细设计阶段的目的与任务详细设计的目的: : 为软件结构图 (SC)中的每一个模块确定采用的算法和模块内 数据结构,用某种选定的表达工具给出清晰的描述。详细设计阶段的主要任务: : 编写软件 的 “详细设计说明书” Evaluation only.Evaluation only. Created with Aspose.Slides for .NET 3.5 Client Profile 5.2.0.0.Created with Aspose.Slides for .NET 3.5 Client Profile 5.2.0.0. Copyright 2004
2、-2011 Aspose Pty Ltd.Copyright 2004-2011 Aspose Pty Ltd.需求分析问题定义可性行研究计划 时期概要设计详细设计编 码 测 试开发 时期运行与维护运 行 时 期Evaluation only.Evaluation only. Created with Aspose.Slides for .NET 3.5 Client Profile 5.2.0.0.Created with Aspose.Slides for .NET 3.5 Client Profile 5.2.0.0. Copyright 2004-2011 Aspose Pty Ltd
3、.Copyright 2004-2011 Aspose Pty Ltd.详细设计 阶段的主 要任务为每一模块确定算法确定每一模块使用的数据结构确定模块的外部接口和用户界面为每一模块设计一组测试用例Evaluation only.Evaluation only. Created with Aspose.Slides for .NET 3.5 Client Profile 5.2.0.0.Created with Aspose.Slides for .NET 3.5 Client Profile 5.2.0.0. Copyright 2004-2011 Aspose Pty Ltd.Copyrig
4、ht 2004-2011 Aspose Pty Ltd.描述工具程序流程图N-SN-S 图PADPAD 图PDLPDL 伪代码5.2 详细设计阶段的描述工具Evaluation only.Evaluation only. Created with Aspose.Slides for .NET 3.5 Client Profile 5.2.0.0.Created with Aspose.Slides for .NET 3.5 Client Profile 5.2.0.0. Copyright 2004-2011 Aspose Pty Ltd.Copyright 2004-2011 Aspose
5、Pty Ltd.A1、顺序型一、程序流程图B几个连续的加工依次序排列expFTA B2、选择型由某个判断式的取值 决定选择两个加工中的一 个。Evaluation only.Evaluation only. Created with Aspose.Slides for .NET 3.5 Client Profile 5.2.0.0.Created with Aspose.Slides for .NET 3.5 Client Profile 5.2.0.0. Copyright 2004-2011 Aspose Pty Ltd.Copyright 2004-2011 Aspose Pty Ltd
6、.3、当型循环型当循环控制条件成立时 ,重复执行特定的加工。expexpFTS S4、直到型循环型重复执行特定的加工, 直到循环控制条件成立时。 expexpFTS SEvaluation only.Evaluation only. Created with Aspose.Slides for .NET 3.5 Client Profile 5.2.0.0.Created with Aspose.Slides for .NET 3.5 Client Profile 5.2.0.0. Copyright 2004-2011 Aspose Pty Ltd.Copyright 2004-2011 A
7、spose Pty Ltd.5、多情况选择型列出多种加工 情况,根据控制变 量的取值,选择执 行其一。exp=1exp=1 FT S1S1exp=2exp=2exp=nexp=nS2S2TSnSnTFFEvaluation only.Evaluation only. Created with Aspose.Slides for .NET 3.5 Client Profile 5.2.0.0.Created with Aspose.Slides for .NET 3.5 Client Profile 5.2.0.0. Copyright 2004-2011 Aspose Pty Ltd.Copy
8、right 2004-2011 Aspose Pty Ltd.- 具有嵌套形式的程序流程图X1X1FTa aX4X4c cTf fTFF入口b bX2X2X3X3d de eg gh hi iX5X5X6X6FTFT=1=2=3Evaluation only.Evaluation only. Created with Aspose.Slides for .NET 3.5 Client Profile 5.2.0.0.Created with Aspose.Slides for .NET 3.5 Client Profile 5.2.0.0. Copyright 2004-2011 Aspose
9、 Pty Ltd.Copyright 2004-2011 Aspose Pty Ltd.标准化程序流程图规定符号X1X1起止端点 输入/输出 一般处理 准备或预处理 预定义处理条件判断 循环上界 循环下界 文件或文档 外接 内接流程线虚线 省略线 并行方式注解或注释Evaluation only.Evaluation only. Created with Aspose.Slides for .NET 3.5 Client Profile 5.2.0.0.Created with Aspose.Slides for .NET 3.5 Client Profile 5.2.0.0. Copyrig
10、ht 2004-2011 Aspose Pty Ltd.Copyright 2004-2011 Aspose Pty Ltd.流程符号的使用规则1、循环符号的使用循环名 进入循环条件循环体循环名 i=1,100 i=1,100 S=S+ii i S=0S=S+iS=0,i=1i 100i 100i=i+1F FT T循环体- 循环流程符号的使用 Evaluation only.Evaluation only. Created with Aspose.Slides for .NET 3.5 Client Profile 5.2.0.0.Created with Aspose.Slides for
11、 .NET 3.5 Client Profile 5.2.0.0. Copyright 2004-2011 Aspose Pty Ltd.Copyright 2004-2011 Aspose Pty Ltd.2、判断有一个入口,但也允许有多个可选出口A:BA:BA=B ABX=?X=?x=1x=2x=3x=4X=?X=?=1 =2 =3 =4 =5- 多出口判断流程符号的使用 Evaluation only.Evaluation only. Created with Aspose.Slides for .NET 3.5 Client Profile 5.2.0.0.Created with A
12、spose.Slides for .NET 3.5 Client Profile 5.2.0.0. Copyright 2004-2011 Aspose Pty Ltd.Copyright 2004-2011 Aspose Pty Ltd.请利用程序流程图描述下列问题的程序结构 某汽车修配厂,有一个存有汽车零件的 仓库,其中存有若干种零件,请编写一个查 询程序,用于查询该库中某零件的库存量为 多少。 设该模块为 查询模块。请设计该模块的程序结构。具体要求:1、应具有重复查询功能;2、应具有数据检测功能;3、请利用程序流程图描述该模块的算法。 Evaluation only.Evaluation
13、 only. Created with Aspose.Slides for .NET 3.5 Client Profile 5.2.0.0.Created with Aspose.Slides for .NET 3.5 Client Profile 5.2.0.0. Copyright 2004-2011 Aspose Pty Ltd.Copyright 2004-2011 Aspose Pty Ltd.顺序型二、N-SN-S 图AB选择型- Nassi and ShneidemanBpFT AApFTp=1=2=nA1 A2 Ando while(p)Sdo until (p)S当型循环型
14、直到型循环型 多分支选择型 Evaluation only.Evaluation only. Created with Aspose.Slides for .NET 3.5 Client Profile 5.2.0.0.Created with Aspose.Slides for .NET 3.5 Client Profile 5.2.0.0. Copyright 2004-2011 Aspose Pty Ltd.Copyright 2004-2011 Aspose Pty Ltd.零件号100011000210003100041000510006库存量10001250886692020345
15、0建立零件库 (s数组), i=0输入零件号 xdo while(x!=s0i)i+ i+x=s0i)Y Ns0i 输出 s1i 输入错误!继续查询?Y N跳出循环 Evaluation only.Evaluation only. Created with Aspose.Slides for .NET 3.5 Client Profile 5.2.0.0.Created with Aspose.Slides for .NET 3.5 Client Profile 5.2.0.0. Copyright 2004-2011 Aspose Pty Ltd.Copyright 2004-2011 As
16、pose Pty Ltd.三、PADPAD 图直到型循环型ABABp pAp pWhile P SUntil P S当型循环型顺序型选择型A1p pA2An=1=1=2=2=n=n多分支选择型循环型- Problem Analysis DiagramEvaluation only.Evaluation only. Created with Aspose.Slides for .NET 3.5 Client Profile 5.2.0.0.Created with Aspose.Slides for .NET 3.5 Client Profile 5.2.0.0. Copyright 2004-2011 Aspose Pty Ltd.Copyright 2004-2011 Aspose Pty Ltd.s17s22=0while num(1-1000) 输入 ageageage=17=17s17+s18+=18=18s19+=19=