uml

When to use an attribute (property) instead of an association/aggregation/composition when drawing a UML

坚强是说给别人听的谎言 提交于 2019-12-07 07:37:32
问题 Okay so I'm a bit confused as to when I should add an attribute to a class vs drawing an association to a class when trying to show a relationship in a UML diagram. For example let's say I have a DFA class that contains 10 state objects each having a different set of paths to various states in the DFA. Should I draw the composition line from the DFA to the State class or just type all 10 states in the attribute section of the DFA class. Basically I'm trying to figure out if when a Class A

How to draw calls from constructors in UML sequence diagrams?

ぐ巨炮叔叔 提交于 2019-12-07 06:09:17
问题 I've seen multiple ways to draw constructors, namely like here with tails under them (function call) but more often like here without the tails and with no arrow returning (sometimes with the label <<create>> ). I'm aware that there are differences between UML1 and UML2 and I'm not sure if this is one of them, however either way I cannot find any references as to how I can represent method calls from the constructor of an object. EDIT: Example java code below. Say oour entry point is foo() .

Keyboard friendly light weight UML modeling tool? [closed]

馋奶兔 提交于 2019-12-07 03:25:10
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 6 years ago . I'm looking for a free UML tool that runs on Windows and lets me create simple diagrams very fast, with as little mouse fiddling as possible. I have no need for code generation or fancy stuff, just UML style boxes with arrows. What I would like is something that for example lets me add a new class with a

UML系列图--用例图

落爺英雄遲暮 提交于 2019-12-06 22:53:12
UML-Unified Model Language 统一建模语言 ,又称标准建模语言。是用来对 软件 密集系统进行可视化 建模 的一种语言。 在UML系统开发中有三个主要的模型:   功能模型: 从用户的角度展示系统的功能,包括用例图。   对象模型: 采用对象,属性,操作,关联等概念展示系统的结构和基础,包括 类图 、对象图、包图。   动态模型: 展现系统的内部行为。 包括序列图,活动图,状态图。 UML的重要内容可以由以下五种类图定义 用例图 :从用户角度描述系统功能,并指各功能的操作者。 静态图 :包括类图,包图,对象图。 类图:描述系统中类的静态结构 包图:是包和类组成的,表示包与包之间的关系,包图描述系统的分层结构 对象图:是类图的实例 行为图 :描述系统动态模型和对象组成的交换关系。包括状态图和活动图 活动图:描述了业务实现用例的工作流程 状态图:是描述状态到状态控制流,常用于动态特性建模 交互图: 描述对象之间的交互关系 顺序图:对象之间的动态合作关系,强调对象发送消息的顺序,同时显示对象之间的交互 合作图:描述对象之间的协助关系 实现图: 配置图:定义系统中软硬件的物理体系结构 UML包括用例图、类图、构件图、部署图、顺序图、协作图、状态图、活动图 各个图简介: 用例图从外部用户的角度捕获系统的行为。他将系统功能划分为对活动者具有意义的事务。 类图描述类、接口

UML(Unified Modeling Language) -- 早期笔记

妖精的绣舞 提交于 2019-12-06 22:52:20
UML学习笔记 系统的创建步骤: 分析、设计与实现比例 在分析阶段,需向行业专家请教,需要问问自己,谁是系统的最终用户 UML(统一建模语言)是一种系统建模方法,有两个主要构件 -- 结构图和行为图 工具: StarUML 一、用例图 1、说明 1.1 用例图说明的事谁要使用系统以及他们使用该系统可以做些什么? <业务需求> 1.2 解析一个用例图,我们可以发现它包含4个基本组件: 系统 参与者 用例(功能) 关系 另外可以通过在用例前面加上包名和两个冒号来确定该用例是属于哪个包的。如:staff::mechanic。如果用 多个参与者与用例之间有同一关系 ,可以重新考虑为用户选择的在系统中扮演的角色的名称。使名称更为广泛化,以一个参与者取代重复的参与者。 2、包含用例图 用 虚线和箭头连接 ,起始处为包含用例,终止处为被包含用例。包含关系用于表示用例为执行其功能从其他用例引入功能。( 重用某些功能 ) 教师必须记录成绩,更新成绩。这两个用例都从一个用例包含了一项为save grades的公用功能,成绩总会被保存。 3、 扩展关系 ( 继承 ) 表示用例可以通过其他用例得到扩展 Notify guardians 用例是添加到save grades 功能中的一项功能。 与包含关系相比,用例必须包含被包含用例,而扩展关系则有是否使用被扩展功能的选择权。 4、创建用例图步骤

UML基础之图

为君一笑 提交于 2019-12-06 22:51:42
UML——United Modeling Language, 统一建模语言——是一种面向对象的可视化建模语言。UML 采用了一组形象化的图形(如类图)符号作为建模语言, 使用这些符号可以形象地描述系统的各个方面。UML 通过建立图形之间的各种关系(如类与类之间的关系)来描述模型。 UML 中一共有 5类(9种)图,包括 用例图、静态图( 类图、对象图 )、行为图( 状态图、活动图 )、交互图( 时序图、协作图 )、实现图( 组件图、部署图 ) 。其中的类图是最重要的,还有就是用例图和时序图也是要求要掌握的。UML 中的关系主要包括 4 种:关联关系(association)、依赖关系(dependency)、泛化关系(generalization)、实现关系(realization)。 1、用例图 首先了解一下关于用例图,用例图(Use Case Diagram): 也称为用户模型图, 是从软件需求分析到最终实现的第一步, 它是从用户的角度来描述系统功能。并指出各功能的执行者。用例图包含 3 个基本组件: 参与者(Actor), 用例(Use Case), 关系。 1.1参与者(Actor): 与系统交互的人或其他系统,即使用该系统的人或事物,在 UML 中参与者用人形图标表示。 1.2用例(Use Case): 代表系统的某项完整的功能. 在 UML 中使用一个椭圆来表示。 1

Use case diagram: of several actors of a use case, only some have access to an extending use case

跟風遠走 提交于 2019-12-06 16:10:41
How can I represent a diagram in which several actors have access to the same function, or "use case" but some of them have additional functions or "extends" (if im right) inside it, if i just extend on the main "use case" that would mean its accessible by everyone right? When a use case extends the main use case, extension points at the main use case, can have conditions. As a condition you could specify a specific actor. If the actors can be generalized, I have seen this solution too. But I prefer the first one because I am not sure if it is technically correct (As you noted, extend use case

How to write typedef and alias in plantuml

纵然是瞬间 提交于 2019-12-06 16:08:23
For example my cpp implementation looks like: class B { int value; } typedef MyB B; class A { MyB b; } My plantuml code: class B { int value; } class A { MyB b; } A o-- B How to represent this alias in plantuml. How it should be done in right way. I can't find this in plantuml tutorial. Aliases are merely referred to in the UML specs along with imports (though aliases may be used in namespaces as well). P. 30 gives an example which also addresses your 2nd issue with typedef : In Figure 7.8, the ElementImport is combined with aliasing, meaning that the DataType Types::Real will be referred to

How can we express Concept in UML diagram?

限于喜欢 提交于 2019-12-06 15:28:31
Does UML Class Diagram support expressing Concept? Also, is there any other diagrams that expresses Concept? Just in case of misunderstanding, I mean the "Concept" in C++ and generic programming. xmojmr After reading shortly Wikipedia explanation of C++ "concepts" it looks to me like tool with same goals as generic classes and type constraints in C# If I understood it correctly then by following older Stack Overflow question Representing a C# Generic Method in a UML Class Diagram it turns out that you should check the http://www.uml-diagrams.org/template.html as already suggested by @Aleks

阶段性总结(从软件工程到分层架构)

怎甘沉沦 提交于 2019-12-06 13:16:15
阶段性总结(从软件工程到分层架构) 阶段性总结(从软件工程到分层架构) 写在前面 软件工程 什么是软件工程 我对软件工程的理解 软件工程流程 UML 定义 为什么会出现UML UML模型 UML建模过程 UML如何描述一个系统 UML总结 设计模式 三层架构 总结 写在前面 这篇文字将会将2011年下半年的学习内容做个总结,不求细节只为从宏观上理解它们之间的联系以及学习它们的目的。 内容包括软件工程、UML、设计模式、三层架构还有两门语言,C#和VB.NET 软件工程 什么是软件工程 软件工程是研究和应用如何以系统性的、规范化的、可定量的过程化方法去开发和维护软件,以及如何把经过时间考验而证明正确的管理技术和当前能够得到的最好的技术方法结合起来的学科。(这是维基百科的定义) 其实软件工程的目的就是以健全的工程化的原则,在给定的成本和进度前提下有可修改性、有效性、可靠性、可理解性、可维护性、可重用 软件工程性、可适应性、可移植性、可追踪性和可互操作性并且满足用户需求的软件产品。 我对软件工程的理解 软件工程是伴随着软件的整个生命周期了存在的,它科学的指导着软件的计划、需求分析、设计编码、测试、运行维护整个生命周期的每一个阶段。 软件工程的兴起源于软件危机,人们不得不思考如何保证软件的可靠性,如何保证软件的开发进度等等问题。于是软件工程出现了