uml

UML类图几种关系的总结

天大地大妈咪最大 提交于 2019-11-28 16:56:42
转自: http://blog.csdn.net/tianhai110/article/details/6339565 在UML类图中,常见的有以下几种关系: 泛化(Generalization), 实现(Realization), 关联(Association), 聚合(Aggregation), 组合(Composition), 依赖(Dependency) 1. 泛化(Generalization) 【泛化关系】:是一种继承关系, 表示一般与特殊的关系, 它指定了子类如何特化父类的所有特征和行为. 例如:老虎是动物的一种, 即有老虎的特性也有动物的共性. 【箭头指向】:带三角箭头的实线,箭头指向父类 2. 实现(Realization) 【实现关系】:是一种类与接口的关系, 表示类是接口所有特征和行为的实现. 【箭头指向】:带三角箭头的虚线,箭头指向接口 3. 关联(Association) 【关联关系】:是一种拥有的关系, 它使一个类知道另一个类的属性和方法;如:老师与学生,丈夫与妻子 关联可以是双向的,也可以是单向的。双向的关联可以有两个箭头或者没有箭头,单向的关联有一个箭头。 【代码体现】:成员变量 【箭头及指向】:带普通箭头的实心线,指向被拥有者 上图中,老师与学生是双向关联,老师有多名学生,学生也可能有多名老师。但学生与某课程间的关系为单向关联

Software for Sequence Diagrams? [closed]

最后都变了- 提交于 2019-11-28 16:50:15
问题 I've been using NClass for object/class modeling in class thus far. However, I do not believe that it is capable of sequence diagrams, which is my next task. I would prefer not to use Visio. Is there a good and free software solution for making sequence diagrams? 回答1: For me there are usually about 3 tools I prefer to use. Netbeans UML Plugin (Its free and its nice) Visual Paradigm UML (its really nice but it isn't free, you might be able to get a free academic copy, but that requires a bit

How to illustrate multiple threads in sequence diagram?

≯℡__Kan透↙ 提交于 2019-11-28 16:28:54
How can you clearly illustrate multiple threads of execution in a sequence diagram or similar diagram? I haven't been able to find any clear examples. All diagrams I see are used to illustrate a single thread. Update : The accepted answer was the best example I saw but it does leave a fair bit to be desired. I ended up illustrating the threads in separate sequence diagrams. I'm not sure if the sequence diagram necessarily works for multiple threads. James Black Here is one diagram that may be useful, and on the left-hand side you can see the explanation: http://sdedit.sourceforge.net

Can UML be used to model a Functional program? [closed]

牧云@^-^@ 提交于 2019-11-28 16:19:42
More specifically, how do you model a functional program, or one developed using the Functional Style (without classes) using a diagram, and not textual representation, is it at all possible and could someone please direct me towards the nearest application that would do this (open source, of free as in beer, if you please) Functional programmers generally don't have a lot of use for diagrams. Many functional programmers (but not all) find that writing down types is a good way to encapsulate the design relationships that OO programmers put into UML diagrams. Because mutable state is rare in

Sequence Diagram Reverse Engineering

萝らか妹 提交于 2019-11-28 16:13:58
I'm looking for a tool that will reverse engineer Java into a sequence diagram BUT also provides the ability to filter out calls to certain libraries. For example, the Netbeans IDE does a fantastic job of this but it includes all calls to String or Integer which clutter up the diagram to the point it is unusable. Any help is greatly appreciated!!!!!!! I think jtracert is what you are looking for. It generates a sequence diagram from a running Java program. Also, because its output is a text description of the diagram (in the formats of several popular SD tools), you can use grep to filter for

What are the differences pre condition ,post condition and invariant in computer terminology [closed]

主宰稳场 提交于 2019-11-28 16:01:12
问题 It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center. Closed 7 years ago . I am reading the book Java Concurrency in Practice and getting a little bit confused with these terms: Pre condition Post condition Invariants Can someone please explain me them (with an example, if it's possible

How to Generate a Sequence Diagram from Java Source Code

人盡茶涼 提交于 2019-11-28 15:47:40
问题 I have a question about generating sequence diagram from Java source code. When I googled I saw someone told to use visual paradigm (VP), but it does not generate sequence diagram for me. Some steps in my VP are different from manual. The manual says to choose method but my VP does not allow to select method in a special class. Reverse Engineering Sequence Diagram from Java Source Code Does anyone have a new idea to generate sequence diagram from Java source code? 回答1: With Intellij 2019

What does a diamond sign signify in UML class diagrams?

↘锁芯ラ 提交于 2019-11-28 15:27:51
Consider the below two diagrams. The top one contains a plain arrow at the right end, and the bottom one contains an arrow with a diamond at the left end and a plain arrow at the right end. The great book GoF has usages of both of these two kinds of diagrams. I want to understand what does the diamond signify in the second case, and which one of these two gives a stronger association between Customer and Order . Is the Customer class responsible for the lifecycle of Order class in either of the two cases? If there is no diamond , then we have a simple association . If the diamond is left empty

Eclipse plugin for generating a class diagram [closed]

依然范特西╮ 提交于 2019-11-28 15:09:35
What is a good Eclipse plugin for generating a class diagram (for a project)? This image right here is exactly what I'm talking about. Vineet Reynolds Assuming that you meant to state 'Class Diagram' instead of 'Project Hierarchy', I've used the following Eclipse plug-ins to generate Class Diagrams at various points in my professional career: ObjectAid . My current preference. EclipseUML from Omondo . Only commercial versions appear to be available right now. The class diagram in your question, is most likely generated by this plugin. Obligatory links The listed tools will not generate class

In UML class diagrams, what are Boundary Classes, Control Classes, and Entity Classes?

大兔子大兔子 提交于 2019-11-28 15:01:32
I'm now using NetBeans as my IDE-of-choice, and it has a plugin for UML modeling. In the class diagram, there are model elements known as Boundary Class , Control Class , and Entity Class . However, I can't find a good definition of them, but I did find this site on UML Class Diagrams. Often used with/as a part of OOAD and business modeling. The definition by Neil is correct, but it is basically identical to MVC, but just abstracted for the business. The "Good summary" is well done so I will not copy it here as it is not my work, more detailed but inline with Neil's bullet points. Good summary