uml

UML学习笔记:类图

落爺英雄遲暮 提交于 2019-11-28 10:36:52
UML学习笔记:类图 有些问题,不去解决,就永远都是问题! 类图   类图(Class Diagrame)是描述 类、接口、协作以及它们之间关系的图 ,用来 显示系统中各个类的静态结构 。   类图包含2种元素:类、接口,6种关系:协作、依赖、泛化、实现以及关联。 组成元素 类    接口    关系 实现关系   类的继承结构表现在UML中为:泛化(generalize)与实现(realize)。实现关系只可用于表示接口与类的继承结构,类会实现接口定义的所有方法。 泛化关系   继承关系为 is-a的关系;两个对象之间如果可以用 is-a 来表示,就是继承关系。比如,西瓜是水果! 依赖关系   描述一个对象在运行期间会用到另一个对象。 关联关系   关联关系,是一种结构关系, 指明一个事物的对象与另一个事物的对象间的关系 。 聚合关系   聚合关系用于表示实体对象之间的关系, 表示整体由部分构成的语义 ; 例如一个部门由多个员工组成 ;但是 整体与部分不是不可分割的,即部门不存在了,员工不会消失,依然存在 。 组合关系   组合关系与聚合关系一样,组合关系 同样表示整体由部分构成的语义 ; 但是这种依赖关系是强依赖 ,即公司不存在,部门也就随之消失了。 参考链接 http://www.woshipm.com/pd/2593231.html https://design

UML学习笔记:活动图

随声附和 提交于 2019-11-28 10:26:38
UML学习笔记:活动图 活动图   在UML里,活动图很类似于流程图,但是有一些区别: 流程图着重描述处理过程,主要控制结构诸如顺序、循环、分支等,各个处理过程过程中有严格的顺序和时间关系。 活动图着重表现系统行为,描述对象活动的顺序关系所遵循的原则 。 活动图可以表示并发活动的情形 ,但是流程图不行。 活动图面向对象 ,流程图面向过程。 组成元素 来源: https://www.cnblogs.com/MrSaver/p/11404822.html

How to indicate a list of types in a Class Diagram

倖福魔咒の 提交于 2019-11-28 08:59:06
问题 As the problem states, I am trying to indicate 'multiple' of a type in a Class Diagram- for example, my Class is a lecture: Lecture topic : String lecturer : String timeStart : Time studentsAttending : **Insert indication of list of students here** 回答1: Create an association between Lecture and Student. On the student end of the association, create an association end called "studentsAttending" having a multiplicity of 0..*. (I recommend you call that association end "attendingStudent" to be

Reverse engineer (oracle) schema to ERD [closed]

旧巷老猫 提交于 2019-11-28 07:58:30
问题 Can anyone recommend good tools for reverse engineering database schemas to ERD/UML, preferably to some generic format. 回答1: As you might expect, there are a few eclipse plugins that can do this. Clay is my personal favourite. It works quickly and with little fuss. There is no real benefit over MS Visio Pro, except for cost (free). Both produce a file in a propritary format, and the best you can do to share with those that don't have the tool is some kind of export to an image. So not ideal.

UML: how to implement Association class in Java

我的梦境 提交于 2019-11-28 05:58:22
I have this UML Association class. Note that: horizontal line is a solid line and the vertical line is a dashed line. --------- --------- | |*(a) *(b)| | | CLASS |________________| CLASS | |STUDENT | | | COURSE | --------- | --------- |*(c) ______|______ | | | | | CLASS | | TRANSCRIPT | |_____________| I understand this relationship but I have met some problems when implement this UML to code. I can implement relation between class Student and class Course to code. Here is my code: class Student { Vector<Course> b; } class Course { Vector<Student> a; } But, at class Transcript , I don't

UML Class Diagram and Generics

为君一笑 提交于 2019-11-28 05:45:31
How do you indicate a generic class or interface in a Class Diagram? I'm looking for two things really: One is how do I model generic java classes if i were doing it with pen and paper. Secondly, what uml tools out there support generic classes/interfaces. Thanks! Usually generics are represented as classifier's template parameter. Here is the example how it looks like in the NetBeans UML Plugin: UML calls them parameterized types - see examples here . As for tools, I know MagicDraw supports them. UML template will help ! Defining Generics with UML Templates http://www.eclipse.org/articles

UML类图的总结和思考

爷,独闯天下 提交于 2019-11-28 05:35:06
UML类图的学习 UML类图简介: UML类图描述的是软件工程中类与类之间的关系,类图一般由三行表示,第一行是类名,第二行是属性,第三行是方法与特性,属性和方法前可以用三种符号”+”、”#”、”-”分别表示public、protected、private。 UML类图设计分析: 一般在系统分析与设计阶段,类通常可以分为三种,分别是实体类、控制类和边界类。 实体类:对应系统需求中的每个实体,它们通常保存在永久存储体中,一般使用数据库表或文件来记录,实体类既包括存储和传递数据的类,还包括操作数据的类;2)控制类:控制类用于体现应用程序的执行逻辑,提供相应的业务操作,将控制类抽象出来可以降低界面和数据库之间的耦合度。3)边界类:用于对外部用户与系统之间的交互对象进行抽象,主要包括界面类、窗口、菜单等。 在类图中,类之间的关系可以分为6种,划分的依据是类之间联系的强弱。 首先是 泛化关系 ,这是一种继承关系,表示一般与特殊,指定了类如何特化父类的特征与行为; 接口关系 是一种实现的关系,接口关系也可以有类之间关系类似的继承关系和依赖关系,但是更多的是接口与类之间的实现关系,类是接口所有特征与行为的实现; 关联关系 是类与类之间最常用的关系,它是一种拥有关系,用于表示一类对象与另一类对象之间有联系,使得一个类知道另一个类的属性和方法,在C++、JAVA等编程语言实现关联关系时

UmlGraph vs APIViz for Maven javadoc generation

时光总嘲笑我的痴心妄想 提交于 2019-11-28 04:49:38
问题 I'm wondering if there are any clear reasons to choose UmlGraph over APIViz for javadoc UML diagram generation in a Maven2 build. Are there any integration or features that one has over the other, they seem pretty similar? 回答1: There is an interesting thread here about UMLGraph vs apiviz (which are mentioned in this question on SO too) and my understanding is the following: UMLGraph is older but is really nice (dixit Fowler which has more weight than me). apiviz is a rewrite of UMLGraph but

Is there a free Eclipse plugin that creates a UML diagram out of Java classes / packages? [closed]

﹥>﹥吖頭↗ 提交于 2019-11-28 04:43:32
This seemed to me like the easiest thing to find, a simple way to display my classes as UML in eclipse But except this: http://java2uml.gforge.enseeiht.fr/ and this http://sourceforge.jp/projects/amateras/releases/ I haven't found any new, maintained and "good" implementation (with all due respect to the above two) Anything else I've missed? VonC Did you consider Creating UML 2 diagrams with Eclipse UML2 Tools - Tutorial ? I had older references for such tools, but the new ones are build upon UML2 project (described in the tutorial). MDT-UML2Tools is in the making, Omondo is there, but not

CRUD in a use-case diagram?

妖精的绣舞 提交于 2019-11-28 03:42:11
My question is quite simple. What is the best way to bring CRUD into a use-case diagram? It should be DRY . I know, UML is sometimes discretionary, but what do you think about it? Some ideas: 1 use-case diagram Not really DRY, if there are a few CRUD objects. 2 use-case diagram Not really DRY, if there are a few CRUD objects. 3 use-case diagram I prefer this. Update 4 use-case diagram (@Uffe) Note maybe needless, when it is described in the documentation? 5 use-case diagram (@home @Uffe) Out of these, I would say #3 is actually the worst, because "CRUD" on its own is not a use case at all; you