SDMetrics home page
The Software Design Metrics tool for the UML

Overview of the Changes in SDMetrics V2.31

July 3, 2013, Jürgen Wüst. Category: Announcements

SDMetrics V2.31 was released today. This is a maintenance release that addresses some issues with the XMI import.

Automatic recognition of XMI 2.4/2.4.1 files

Ever since XMI 1.0, the XMI standards mandated a “version” attribute in the root element of the XMI file to indicate the XMI version of the file.
It was simple and convenient, but also redundant with the XMI namespace URL, which implies the XMI version. So the “version” attribute has been dropped from XMI 2.4 onwards. Therefore, SDMetrics’ XMI import routine now also considers the XMI namespace URL to automatically determine the XMI version of the input file at hand.

Note that you can analyze XMI 2.4/2.4.1 files with older versions of SDMetrics, but you need to tell SDMetrics that it is a UML2.x/XMI2.x file, see SDMetrics FAQ 1.6.

Fixed problem reading XMI files when the default locale is Turkish

SDMetrics used to abort the XMI import with error message “Unknown trigger type ‘ignore'” or “Unknown trigger type ‘xmi2assoc'” when the default locale of the Java VM was Turkish (tr-TR). This was caused by an uppercase conversion of the character ‘i’, which does not yield ‘I’ in the Turkish locale. It is a classic upper/lower case conversion programming pitfall, and I stepped right into it…

Improved XMI import of meta-types “realization” and “substitution”

In the UML2 meta-model, classes “Realization” and “Substitution” define associations “realizingClassifier” and “contract”, respectively, which subset the association “supplier” of the common base class. SDMetrics’ XMI import missed associated elements that were in “suppliers”, but not in “realizingClassifiers” or “contract”. Note that this rarely occurs in practice, and is usually a quirk of the XMI exporter.

In addition to solving these XMI import issues, SDMetrics V2.31 also adds a few minor new features.

New metric procedure “substring”

XMI exporters sometimes mangle various bits of tool-specific information into a single string in the XMI file. For example, the coordinates of an element in a diagram could be specified by a string such as “Top:123, Left:122, Bottom:234, Right:546”. With the new substring procedure, you can extract the relevant parts of such strings for further processing.

New special purpose function “parsenumber” in metric expressions

SDMetrics’ XMI importer only extracts strings from XMI files. Sometimes, these strings represent numbers, as in the diagram coordinates example above. With the new parsenumber function, you can convert such strings to numbers for further arithmetic operations.

New metrics for UML 2 sequence diagrams

The UML 2 sequence diagram metrics that were defined in this and this blog post are now included in the standard set of UML 2 quality metrics that SDMetrics calculates ‘out of the box’.