chap7 需求分析-用例图.ppt

上传人:豆**** 文档编号:25162009 上传时间:2022-07-10 格式:PPT 页数:60 大小:6.47MB
返回 下载 相关 举报
chap7 需求分析-用例图.ppt_第1页
第1页 / 共60页
chap7 需求分析-用例图.ppt_第2页
第2页 / 共60页
点击查看更多>>
资源描述

《chap7 需求分析-用例图.ppt》由会员分享,可在线阅读,更多相关《chap7 需求分析-用例图.ppt(60页珍藏版)》请在taowenge.com淘文阁网|工程机械CAD图纸|机械工程制图|CAD装配图下载|SolidWorks_CaTia_CAD_UG_PROE_设计图分享下载上搜索。

1、chap7 需求分析需求分析-用例用例图图Copyright 2004 The McGraw-Hill Companies. All Rights reservedAn Introduction to Use-Case Modeling 简介简介 One of the primary challenges in a system design process is the ability to elicit(提取提取) the correct and necessary system requirements from the stakeholders and specify them in

2、a manner understandable to them so those requirements can be verified and validated.系统开发过程的首要问题系统开发过程的首要问题是正确地提取用户需求,并是正确地提取用户需求,并以用户能够理解的方式进行表达,以便他们他们能够以用户能够理解的方式进行表达,以便他们他们能够核实并确认核实并确认Copyright 2004 The McGraw-Hill Companies. All Rights reservedAn Introduction to Use-Case Modeling 简介简介 传统的建方法:传统的建

3、方法: Data and process models Prototypes requirement specifications 问题:问题:设计者理解而用户不理解设计者理解而用户不理解 Leads to scope creep(范围蔓延)(范围蔓延), schedule creep (进度蔓延)进度蔓延), cost overruns(成本超支)(成本超支).Copyright 2004 The McGraw-Hill Companies. All Rights reservedUser-Centered Development and Use-Case Modeling以用户为中心的系统

4、开发与用例建模Copyright 2004 The McGraw-Hill Companies. All Rights reservedUser-Centered Development User-centered development a process of systems development based on understanding the needs of the stakeholders and the reasons why the system should be developed.系统开发建立应在理解用户需求之上系统开发建立应在理解用户需求之上Copyright 2

5、004 The McGraw-Hill Companies. All Rights reservedUse-Case Modeling 用例建模用例建模 Use-case modeling the process of modeling a systems functions in terms of 针对系统功能进行建针对系统功能进行建模:模: business events:有哪些业务事件?:有哪些业务事件? who initiated the events:谁发起了这些事件?:谁发起了这些事件? and how the system responds to those events:系统:

6、系统将如何响应这些事件?将如何响应这些事件?Copyright 2004 The McGraw-Hill Companies. All Rights reservedSample Use-Case Model DiagramCopyright 2004 The McGraw-Hill Companies. All Rights reservedBenefits of Use-Case Modeling Provides a tool for capturing functional requirements(获取功能获取功能需求需求). Provides a means of communic

7、ating with users and other stakeholders concerning system functionality in a language that is easily understood.(便于沟通)(便于沟通) Provides a tool for requirements traceability(需求跟踪需求跟踪). Provides a framework for driving the system development project. (提供一个驱动系统开发项目的框架)(提供一个驱动系统开发项目的框架)Copyright 2004 The

8、McGraw-Hill Companies. All Rights reservedSystem Concepts for Use-Case Modeling Use-case diagram describes who will use the system and in what ways the user expects to interact with the system. 用例图用例图描述系统与外部系统或用户之间的交互图描述系统与外部系统或用户之间的交互图 Use-case narrative a textual description of the business event

9、and how the user will interact with the system to accomplish the task.用例说明用例说明针对用例执行过程的文本说明针对用例执行过程的文本说明 Use case a behaviorally related sequence of steps (a scenario), both automated and manual, for the purpose of completing a single business task.用例用例从外部使用者的角度描述系统功能,是一系列相关从外部使用者的角度描述系统功能,是一系列相关的操作

10、步聚,共同完成单一的工作任务。的操作步聚,共同完成单一的工作任务。Copyright 2004 The McGraw-Hill Companies. All Rights reservedSample Use-Case Model DiagramCopyright 2004 The McGraw-Hill Companies. All Rights reservedBasic Use-Case Symbols Use case (用例)(用例) subset of the overall system functionality Represented graphically by a hor

11、izontal ellipse(椭园)(椭园) with the name of the use case appearing above, below, or inside the ellipse. Actor (参与者)(参与者) anything that needs to interact with the system to exchange information. Could be a human, an organization, another information system, an external device, or even time. Temporal eve

12、nt (时间事件时间事件) a system event triggered by time. The actor is time.Copyright 2004 The McGraw-Hill Companies. All Rights reservedFour Types of Actors Primary business actor The stakeholder that primarily benefits from the execution of the use case. e.g. the employee receiving the paycheck Primary syst

13、em actor The stakeholder that directly interfaces with the system to initiate or trigger the business or system event. e.g. the bank teller entering deposit information External server actor The stakeholder that responds to a request from the use case. e.g. the credit bureau authorizing a credit car

14、d charge External receiver actor The stakeholder that is not the primary actor but receives something of value from the use case. e.g. the warehouse receiving a packing slipCopyright 2004 The McGraw-Hill Companies. All Rights reservedUse Case Association Relationship Association(关联关联) a relationship

15、 between an actor and a use case in which an interaction occurs between them. Association modeled as a solid line connecting the actor and the use case. Association with an arrowhead touching the use case indicates that the use case was initiated by the actor. Association lacking arrowhead indicates

16、 a receiver actor. 无箭头则表示一个接收者无箭头则表示一个接收者 Associations may be bidirectional or unidirectional.Copyright 2004 The McGraw-Hill Companies. All Rights reservedUse Case Extends Relationship Extension use case(扩展用例)(扩展用例) a use case consisting of steps extracted from a more complex use case in order to si

17、mplify the original case and thus extend its functionality. Relationship between the extension use case and the use case it is extending is called an extends relationship. Represented as an arrowheaded line beginning at the extension use case and point to the use case it is extending. Each extends r

18、elationship line is labeled “.”Copyright 2004 The McGraw-Hill Companies. All Rights reservedUse Case Uses Relationship Abstract use case a use case that reduces redundancy(冗余冗余) among two or more other use cases by combining the common steps found in those cases.Relationship between the abstract use

19、 case and the use case that uses it is called a uses (or includes) relationship.Depicted as an arrow headed line beginning at the original use case and pointing to the use case it is using. Each uses relationship line is labeled “.”Copyright 2004 The McGraw-Hill Companies. All Rights reservedUse Cas

20、e Depends On RelationshipDepends On a use case relationship that specifies which other use cases must be performed before the current use case. Can help determine sequence in which use cases need to be developed. Depicted as an arrow headed line beginning at one use case and pointing to a use case i

21、t is dependent on. Each depends on relationship line is labeled “.”Copyright 2004 The McGraw-Hill Companies. All Rights reservedUse Case Inheritance RelationshipInheritance(继承继承) a use case relationship in which the common behavior of two actors initiating the same use case is extrapolated and assig

22、ned to a new abstract actor to reduce redundancy. Other actors can inherit the interactions of the abstract actor. Depicted as an arrowheaded line beginning at one actor and pointing to the abstract actor whose interactions the first actor inherits. Copyright 2004 The McGraw-Hill Companies. All Righ

23、ts reservedThe Process of Requirements Use-Case ModelingSteps步骤步骤 Identify business actors (参与者参与者). Identify business use cases (用例用例). Construct use-case model diagram (用例模型图用例模型图).1. Documents business requirements use-case narratives (用例说明用例说明).Copyright 2004 The McGraw-Hill Companies. All Right

24、s reserved案例背景:案例背景:Soundstage Entertainment Club 传统广告:传统广告:“1便士任选便士任选10盘盘CD,只要两年内按正常,只要两年内按正常的会员价格购买的会员价格购买5盘以上的盘以上的CD”; 会员按月收到促销商品广告和产品目录,从中选择商会员按月收到促销商品广告和产品目录,从中选择商品;客户也可以订购产品目录中的其他商品和特殊商品;客户也可以订购产品目录中的其他商品和特殊商品;品; 当会员履行了他们最初的订阅合同后,他们就具有了当会员履行了他们最初的订阅合同后,他们就具有了获得奖卷的资格,奖卷可以用来况换产品目录中的免获得奖卷的资格,奖卷可以

25、用来况换产品目录中的免费商品;费商品; 最近最近12个月内购买过商品的会员帐号为活动帐号,否个月内购买过商品的会员帐号为活动帐号,否则为非活动帐号;非活动帐号再次使用需先进行激活则为非活动帐号;非活动帐号再次使用需先进行激活。Copyright 2004 The McGraw-Hill Companies. All Rights reserved案例项目的初步范围:案例项目的初步范围:营销营销订阅订阅销售和订单录入(对所有的办事处)销售和订单录入(对所有的办事处)仓储(所有的发行中心)仓储(所有的发行中心)库存控制和采购库存控制和采购发货和验收(所有发行中心)发货和验收(所有发行中心)应收帐款

26、和应付帐款应收帐款和应付帐款所有俱乐部的会员服务所有俱乐部的会员服务外部团体外部团体潜在会员、会员、以前的会员、供应商、批发商潜在会员、会员、以前的会员、供应商、批发商Copyright 2004 The McGraw-Hill Companies. All Rights reservedStep 1: identify Business Actors When looking for actors, ask the following questions: Who or what provides inputs to the system?谁向系统提供输入?谁向系统提供输入? Who or

27、what receives outputs from the system?谁接收系统的输出?谁接收系统的输出? Are interfaces (接口接口) required to other systems?需要与其他系统接口吗?需要与其他系统接口吗? Are there events that are automatically triggered (触发触发) at a predetermined time?有无在预定时间自动触发的事件?有无在预定时间自动触发的事件? Who will maintain information in the system?谁来维护系统中的信息?谁来维护系

28、统中的信息?Copyright 2004 The McGraw-Hill Companies. All Rights reservedSample List of Actors(同义词同义词)Copyright 2004 The McGraw-Hill Companies. All Rights reservedStep 2: Identify Business Requirements Use Cases During requirements analysis, strive(努力)努力) to identify and document (记录记录) only the most crit

29、ical, complex, and important use cases, often called essential use cases.在需求分析阶段,应重点识别和记录那些最为关键、在需求分析阶段,应重点识别和记录那些最为关键、最为复杂、以及最为重要的用例,统称为基本用例最为复杂、以及最为重要的用例,统称为基本用例Copyright 2004 The McGraw-Hill Companies. All Rights reservedlooking for use cases, ask the following questions: What are the main tasks

30、of the actor?参与者的主要任务是什么?参与者的主要任务是什么? What information does the actor need from the system?参与者需要系统提供什么信息?参与者需要系统提供什么信息? What information does the actor provide to the system?参与者向系统提供什么信息?参与者向系统提供什么信息? Does the system need to inform the actor of any changes or events that have occurred?一旦变化或事件发生了,系统是

31、否需要及时通知参与者?一旦变化或事件发生了,系统是否需要及时通知参与者? Does the actor need to inform the system of any changes or events that have occurred?一旦变化或事件发生了,参与者是否需要及时通知系统?一旦变化或事件发生了,参与者是否需要及时通知系统?Copyright 2004 The McGraw-Hill Companies. All Rights reservedSample Context DiagramCopyright 2004 The McGraw-Hill Companies. All

32、 Rights reservedSample Use-Case GlossaryCopyright 2004 The McGraw-Hill Companies. All Rights reservedSample Use-Case Glossary (continued)continuedCopyright 2004 The McGraw-Hill Companies. All Rights reservedSample Use-Case Glossary (concluded)Copyright 2004 The McGraw-Hill Companies. All Rights rese

33、rvedStep 3: Construct Use-Case Model DiagramCopyright 2004 The McGraw-Hill Companies. All Rights reservedStep 4: Document Business Requirements Use-Case Narratives(说明书)(说明书) Document first at high level to quickly obtain an understanding of the events and magnitude of the system. 文档首先是文档首先是宏观层面的宏观层面

34、的 Then expand to a fully-documented business requirement narrative 再逐步扩展到完整的需求说明书再逐步扩展到完整的需求说明书 Include the use cases typical course of events and its alternate courses.Copyright 2004 The McGraw-Hill Companies. All Rights reservedSample High-Level Version of a Use-Case NarrativeCopyright 2004 The Mc

35、Graw-Hill Companies. All Rights reservedSample Expanded Version of a Use-Case NarrativecontinuedCopyright 2004 The McGraw-Hill Companies. All Rights reservedSample Expanded Version of a Use-Case Narrative (cont)continuedCopyright 2004 The McGraw-Hill Companies. All Rights reservedSample Expanded Ver

36、sion of a Use-Case Narrative (cont)Copyright 2004 The McGraw-Hill Companies. All Rights reservedUse Cases and Project Management Use-case model can drive the entire development effort. Project manager or systems analyst uses business requirements use cases to plan (estimate and schedule) the build c

37、ycles of the project. Build cycles are scoped on the basis of the importance of the use case and the time it takes to implement the use case. To determine importance of the use cases, will create: Use-case ranking and evaluation matrix Use-case dependency diagramCopyright 2004 The McGraw-Hill Compan

38、ies. All Rights reservedUse-Case Ranking and Priority MatrixIn most projects, the most important use cases are developed first.Use-case ranking and priority matrix a tool used to evaluate use cases and determine their priority. Evaluates use cases on a scale of 1 to 5 against six criteria. Significa

39、nt impact on the architectural design. Easy to implement but contains significant functionality. Includes risky, time-critical, or complex functions. Involves significant research or new or risky technology. Includes primary business functions.1. Will increase revenue or decrease costs.Copyright 200

40、4 The McGraw-Hill Companies. All Rights reservedSample Use-Case Ranking and Priority MatrixCopyright 2004 The McGraw-Hill Companies. All Rights reservedUse-Case Dependency Diagram Use-case dependency diagram a graphical depiction of the dependencies among use cases. Provides the following benefits:G

41、raphical depiction of the systems events and their states enhances understanding of system functionality.Helps identify missing use cases.Helps facilitate project management by depicting which use cases are more critical.Copyright 2004 The McGraw-Hill Companies. All Rights reservedSample Use-Case De

42、pendency Diagram Copyright 2004 The McGraw-Hill Companies. All Rights reserved练习练习1:设计一个小型图书管理系统,具备以下功能设计一个小型图书管理系统,具备以下功能:(1)购入新书后,进行图书编号,并登记入库;购入新书后,进行图书编号,并登记入库;(2)读者读者借书,须办理借书证,每个借书证的编号唯一,并将读者的借书,须办理借书证,每个借书证的编号唯一,并将读者的基本信息登记到读者库;基本信息登记到读者库;(3)当读者借书时,登记流水帐;当读者借书时,登记流水帐;(4)用户还书时,可查询借书日期,如有超期,则进行罚

43、款用户还书时,可查询借书日期,如有超期,则进行罚款处理;处理;(5)输入书号或书名或作者,可查询该书的情况(是输入书号或书名或作者,可查询该书的情况(是否已借出、此种书当前的库存余数等);否已借出、此种书当前的库存余数等);(6)输入借书证号输入借书证号或读者姓名,可查询此人当前的总借书情况(如书名、数量或读者姓名,可查询此人当前的总借书情况(如书名、数量、借阅日期等)。、借阅日期等)。要求分析该系统,并要求分析该系统,并给出该系统的用例图。给出该系统的用例图。Copyright 2004 The McGraw-Hill Companies. All Rights reserved练习练习1(

44、续)(续)如果该小型图书馆完全采用不记名押金管理体系,如果该小型图书馆完全采用不记名押金管理体系,则用例图应做何改动?则用例图应做何改动?当用户租用图书时,提交押金;当用户租用图书时,提交押金;用户归还图书时,根据租用时间及既定费率计算实际发生用户归还图书时,根据租用时间及既定费率计算实际发生费用,将押金剩余部分退还用户或者进行补充收费。费用,将押金剩余部分退还用户或者进行补充收费。Copyright 2004 The McGraw-Hill Companies. All Rights reserved进一步思考:自主进一步思考:自主设计一个社区小型公益图书管理系统设计一个社区小型公益图书管理

45、系统 除少量自购图书外,其余完全由业主自愿捐赠(不退不赔);除少量自购图书外,其余完全由业主自愿捐赠(不退不赔); 图书分类编号,并提供图书分类编号,并提供35个关键字,读者可以通过计算机利用个关键字,读者可以通过计算机利用图书分类、作者、书名、关键字等进行检索;图书分类、作者、书名、关键字等进行检索; 所有社区业主可凭业主卡在阅览室阅读图书,但如需借阅,其所所有社区业主可凭业主卡在阅览室阅读图书,但如需借阅,其所借图书的价格总额不得超出自己捐赠的图书价格总额;借图书的价格总额不得超出自己捐赠的图书价格总额; 借阅天数不受限制;当有其他读者希望借阅同一本书,可以提出借阅天数不受限制;当有其他读

46、者希望借阅同一本书,可以提出预约,系统将自动用预约,系统将自动用EMAIL通知借阅者该图书已被预约,催促通知借阅者该图书已被预约,催促其尽快归还;其尽快归还; 每月系统自动输出本月新书推介信息,并评选本月的捐赠之星、每月系统自动输出本月新书推介信息,并评选本月的捐赠之星、读书之星予以表彰。读书之星予以表彰。要求:要求:分析该系统,并对未尽事宜进行完善性设计,分析该系统,并对未尽事宜进行完善性设计,给出该系统的给出该系统的用例图及相关用例的用例说明用例图及相关用例的用例说明;Copyright 2004 The McGraw-Hill Companies. All Rights reserved

47、练习练习2: 影碟出租店管理系统影碟出租店管理系统 要求:要求: 购进影碟后,分类编号登记至影碟记录表购进影碟后,分类编号登记至影碟记录表(包括:碟号包括:碟号、碟名、类型、进价、供应商、出租单价、碟名、类型、进价、供应商、出租单价); 影碟出租时,登记出租流水帐,记录出租单价及出租影碟出租时,登记出租流水帐,记录出租单价及出租日期;日期; 影碟归还时,补充登记出租流水帐,记录归还日期、影碟归还时,补充登记出租流水帐,记录归还日期、应收金额、实收金额;应收金额、实收金额; 日常可根据需要完成以下查询要求:日常可根据需要完成以下查询要求: 给出碟名,可查是否有货可供借出;给出碟名,可查是否有货可

48、供借出; 给出供应商,可查其以往供货情况给出供应商,可查其以往供货情况Copyright 2004 The McGraw-Hill Companies. All Rights reserved练习练习2(续)(续) 请自行设计一个适合于互联网上的影视作品点播管理请自行设计一个适合于互联网上的影视作品点播管理系统,制定业务规则及收费标准,并给出相应的用例系统,制定业务规则及收费标准,并给出相应的用例图与主要的用例说明。图与主要的用例说明。Copyright 2004 The McGraw-Hill Companies. All Rights reserved练习练习3:学术会议论文管理系统:学术

49、会议论文管理系统 组委会收到应征论文后,进行分类编号登记,审稿前打印分组委会收到应征论文后,进行分类编号登记,审稿前打印分类目录和审稿单,按论文分类分送给相应的审稿人审阅;类目录和审稿单,按论文分类分送给相应的审稿人审阅; 组委会收到审稿意见后,登录审稿结论组委会收到审稿意见后,登录审稿结论(录用、不录用录用、不录用),并,并将结论及版面费金额通知作者;将结论及版面费金额通知作者; 组委会收到作者版面费后进行登记;组委会收到作者版面费后进行登记; 打印论文集目录打印论文集目录(收到版面费的录用论文列入论文集收到版面费的录用论文列入论文集)Copyright 2004 The McGraw-Hi

50、ll Companies. All Rights reserved练习练习3(续)(续) 如果会议实行网上论文提交及网上论文评审,则用例如果会议实行网上论文提交及网上论文评审,则用例图如何变化?图如何变化?Copyright 2004 The McGraw-Hill Companies. All Rights reserved练习练习4:彩票电话销售系统:彩票电话销售系统 一个慈善团体通过周期性地发起彩票销售活动来筹集资金;一个慈善团体通过周期性地发起彩票销售活动来筹集资金; 该慈善团体实行会员制。所有彩票仅在会员范围内发行;该慈善团体实行会员制。所有彩票仅在会员范围内发行; 维护会员的各方面

展开阅读全文
相关资源
相关搜索

当前位置:首页 > pptx模板 > 企业培训

本站为文档C TO C交易模式,本站只提供存储空间、用户上传的文档直接被用户下载,本站只是中间服务平台,本站所有文档下载所得的收益归上传人(含作者)所有。本站仅对用户上传内容的表现方式做保护处理,对上载内容本身不做任何修改或编辑。若文档所含内容侵犯了您的版权或隐私,请立即通知淘文阁网,我们立即给予删除!客服QQ:136780468 微信:18945177775 电话:18904686070

工信部备案号:黑ICP备15003705号© 2020-2023 www.taowenge.com 淘文阁