UML模型和图定义在哪里? – XMI 有,标准没有?
因此,我一直在研究 UML 2.3 基础设施、UML 2.3 上部结构、MOF 2.0 和 XMI 2.11 标准,以寻找模型和图表的规范和定义。
我了解模型和图表以及它们是什么(图表显示模型的视图),但是在从 Visual Paradigm 导出的 XMI 文件中看到它们并对其进行分析时,我有点困惑。
在上述标准中,规范特别提到了图表和模型及其相应的含义,但我找不到它的定义位置,也找不到最重要的部分,即它如何进入 UML 元模型。
上面提到的 XMI 具有以下结构(经过大量修剪):
<xmi:XMI xmi:version="2.1" …>
<uml:Model />
<uml:Diagram />
</xmi:XMI>
因此,由于我找不到模型和图表的定义,我也无法找出允许/可能有多少个模型元素以及它可能包含哪些内容。图表也是如此,尽管我知道它们可以是 0..*
。
So, I’ve been looking through the UML 2.3 Infrastructure, UML 2.3 Superstructure, MOF 2.0 and XMI 2.11 standards in search of the specification and definition of Models and Diagrams.
I am aware about models and diagrams and what they are (diagrams show a view on the model), but seeing them in an XMI file exported from Visual Paradigm and analysing it I got a bit confused.
Throughout the standards mentioned above the specification mentions diagrams and models specifically with their corresponding meanings, but I could not find where it is defined, nor, the most important part, how it comes in to the UML Metamodel.
XMI mentioned above has the following structure (heavily pruned):
<xmi:XMI xmi:version="2.1" …>
<uml:Model />
<uml:Diagram />
</xmi:XMI>
So as I could not find definitions on Model and Diagram, I could also not find out how many Model elements are allowed/possible and what content it may have. Same for Diagrams, although I know those can be 0..*
.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
检查模型的最简单方法是使用 EclipseUML2 编辑器。这不是图形 UML,而是一棵树,您可以在其中直接在 XMI 模型上创建元素。 XMI 是 2.1,对应于 UML 2.3,非常干净。
RSA IBM、Topcased、Papyrus 在项目级别使用此 XMI,您甚至可以将多个项目与 Omondo 合并。真的很酷!
THe easiest way to check your model is to use the EclipseUML2 editor. This is not a graphical UML but a tree where you can create elements directly on the XMI model. The XMI is 2.1 corresponding to UML 2.3 and is really clean.
This XMI is used by RSA IBM, Topcased, Papyrus at project level and you can even have multiple projects merge with Omondo. Really cool !!
模型标签用于 XMI 文件中。我不确定是否有一个标准(从某种意义上说,有时您只看到整个 XMI 的单个模型标签,而其他时候工具似乎为每个图表打开一个新的模型标签。
事实是,我们不这样做还没有一个标准来在 XML 文件中存储图表信息(布局、大小……)。 uml-diagram-interchange-format" rel="nofollow">一些工作正在进行,但现在每个工具都使用自己的专有格式(其中一些将信息存储在与模型信息相同的 XMI 中)在单独的文件中执行)。
Models tags are used in XMI files. I'm not sure there's a standard for that (in the sense that sometimes you just see a single model tag for the whole XMI and other times tools seem to open a new model tag for each diagram.
What it is true is that we don't have yet a standard to store in an XML file the diagram information (layout, sizes,...). There is some work in progress but right now each tool uses its own proprietary format for that (some of them store the info in the same XMI as the model information others do it in a separate file).