1、建模参考图书借阅服务教案资料计算机科学系实验报告课程名称 UML 与可视化建模 班 级 1 班实验名称 图书借阅服务业务系统建模 指导教师 姓名 学 号 000000000 日 期 2011-6-19 一、实验目的(1) 掌握业务系统建模概念与方法。二、实验环境Windows XP UMLet三、实验内容3.1 业务系统建模In business terminology, a business system refers to the value-added chain, which describes the value-added process, meaning the supply o
2、f goods and services. A business can span one or several business systems.在业务术语中,业务系统指的是一个增值链,它描述了一些可以产生价值的过程,即有形商品和无形服务。一个业务可以包含一个或多个业务系统。A business system that is to be modeled can span an entire organization. In this case, we talk about an organization model. 业务系统可以在整个组织范围内进行建模。即所谓的组织模型。It is als
3、o possible to consider and model only a selected part of an organization. In our case study, an IT system is to be integrated into the Library Services operation. 我们也可以从组织的某个部分进行考虑和建模。例如,我将开始进行“图书借阅服务”的业务系统建模。3.1.1 外部视图What Benefit does a Business System Provide? 在外部视图中,我们主要关注于了解一个业务系统能够产生什么样的利益/成果。
4、The customer view describes the interactions with external parties, such as customers and partners, and presents the business system as a black box. 这是一个客户视图,将描述业务系统与外部参与者之间的交互,这些参与者包括客户和合作伙伴,业务系统是以一个黑盒的形式展现。外部视图由UML的用例图、活动图和顺序图组成,下面将根据借书服务的业务过程和参与绘制这三种UML图。1. 借书服务业务用例图Use case diagrams show busines
5、s use cases, actors, and the relationships between them. The relationships between actors and business use cases state that an actor can use a certain functionality of the business system. 用例图是描述用例、参与者及其关系的UML图。参与者与业务用例的关系表示参与者使用了业务系统某个特定功能。借书服务的业务系统中,主要有2个核心业务用例构成,即借书和还书,而业务系统的参与者为借阅者,如图1所示。图1:借书服务
6、的业务用例图2. 借书服务业务活动图Activity diagrams, which are related to program flow plans (flowcharts), are used to illustrate activities. In the external view, we use activity diagrams for the description of those business processes that describe the functionality of the business system. 活动图与程序的流程有关(流程图),是用来描述业
7、务系统内发生的活动。在外部视图中,我们使用活动图来描述与业务系统功能有关的业务过程。下面对借书和还书这两个核心业务用例的活动进行分析,如图2所示。图2:借书活动图还书的类似,此处略。3. 借书服务业务顺序图sequence diagrams emphasize the chronological course of exchanged information. 顺序图强调信息交换的时间顺序。Sequence diagrams can be used as the basis for message exchange between the business system and outside
8、 parties. 顺序图可以用来描述业务系统和外部参与所交换的消息。下面对借书和还书这两个核心业务用例的业务执行过程分析,如图3所示。图3:还书顺序图借书的类似,此处略。3.1.2 内部视图The internal view describes the internal processes and activities, relationships, and structures of the business system. IT systems and people within the business system are responsible for offering the g
9、oods and services of the business system. 内部视图描述业务系统的内部过程、活动、关系和结构。IT系统及业务系统内部人员负责提供业务系统的商品和服务。内部视图由UML的包图、类图和活动图组成,下面将根据借书服务的业务过程和参与绘制这三种UML图。1. 借书服务包图The structure of organization units is important for the internal view of the business system. In UML, organization units are depicted as packages,
10、which can contain employees, business objects, and other organization units. 组织单元的结构是业务系统的重要内部视图,组织单元是用包图描述的,其中可以包含工作者、业务对象及其他组织单元。在业务系统内部,借书服务是由图书馆管理员(worker)完成的,他负责处理借阅者(actor)的帐号信息和书本信息(business object),如图4所示。图4:借书服务的包图2. 借书服务类图The class diagram can be used to illustrate the structural parts of a
11、 business system, meaning the relationships between individual employees, business objects, and outside parties. We significantly simplify class diagrams on the business-model level and use only very few elements. 类图可用于描述一个业务系统的结构组成,包括各个员工、业务对象和外部参与者的关系。我们在业务建模中,只使用一些简单的类图元素。下面对借书服务的类的关系进行分析,得出图5所示的
12、类图。图5:借书服务的类图3. 借书服务内部活动图Activity diagrams are suitable to show the internal processes of a business system. Contrary to activity diagrams of the external view, in activity diagrams of the internal view the relationships to actors are no longer the focal point. 活动图适合表示业务系统的内部过程。与外部视图的活动图不同,内部视图的活动图不
13、需要描述与参与者的关系。下面对借书和还书业务用例的内部活动进行分析,得出如下所示的内部活动图。图6:借书的内部活动图还书的内部活动类似,此处略。3.2 IT系统建模In this section, we show how a conceptual model of an IT system can be developed with the help of UML. 在这一节,我们将利用UML对将要开发的IT系统的概念模型进行建模。The IT system model consists of four different views, each of which emphasizes cer
14、tain aspects and which are closely related to each other. IT系统的模型由4个不同的视图构成,每一个视图都关注一个不同的方面,但是它们之间存在紧密的联系。下面将按照4个视图的不同关注方面对IT系统的静态和动态方面进行建模。3.2.1 外部视图The external view shows the use cases of the IT system in the form of UML use case diagrams and an interface prototype. It makes apparent which functi
15、onalities the IT system provides to users. 外部视图是以UML用例图和一个界面原型来描述IT系统的用例。它能够清晰阐述IT系统向用户提供的功能。图7:系统用例图注:系统用例图可以进一步细化。3.2.2 结构视图The structural view shows the relevant classes of the IT system in the form of UML class diagrams. It makes apparent in which structures information is filed in the IT system
16、. 结构视图是以UML类图来描述IT系统的相关类。它能够清晰阐述IT系统的结构信息。图7:IT系统类图如图7所示,类图可以描述清楚各个类之间的泛化关系,类之间的多样性,以及静态的业务规则,例如,借阅者最多只能借5本书。3.2.4 行为视图The behavioral view shows the behavior of the individual objects in the form of statechart diagrams. It makes apparent everything that can happen with an object that is filed in the IT system. 交互视图是通过UML状态图来描述单个对象的行为。它能够清晰阐述IT系统中对
copyright@ 2008-2022 冰豆网网站版权所有
经营许可证编号:鄂ICP备2022015515号-1