The Visio diagram Import feature introduced in Version 8.5 helps you easily migrate from Microsoft Visio to IBM® Rational® Software Architect to meet enterprise-level modeling needs, without losing the information in your Visio diagrams. This migration will help you take advantage of the wide-ranging model-driven development capabilities and capitalize on the scalability provided by Rational Software Architect.
Pure diagramming lacks the rigor and precision of formal modeling. Diagrams are easily adoptable with low entry barriers because they don't require the exactness of models. It is difficult for machines (and, at times, a different human looking at the same diagram) to infer the intended semantics of the drawing, because it does not convey much about the precise meaning.
For formal modeling tools, the precision and the rigor that are part of their value become deterrents to using them easily. It takes a fair amount of knowledge and experience with the tools to understand the exactness of the constructs and use them appropriately.
Some think of this as a forced hardship. However, it is actually a measure that provides the impetus to think more precisely and capture situations in a realistic way, rather than promoting shortcuts. Enterprises deal with complex problems and need to reflect that problem statement precisely. This need for precision demands an equally strict and precise set of constructs to reflect those real-life scenarios.
As a tool for IT modeling, Rational Software Architect helps in this endeavor. Now it provides an automated capability to migrate Microsoft Visio diagrams into Rational Software Architect as domain models.
Scope of the Visio Import feature
This feature supports one-time import of Microsoft Visio diagrams into Rational Software Architect. It does not require an installation of Visio for the import.
This section outlines the scope and the specifics of what the initial version of this feature does.
Visio version and editions supported
There are multiple versions of Microsoft Visio and multiple editions of the same version, such as Standard, Professional, and Premium. Rational Software Architect supports the Microsoft Visio 2010 version, and the import feature works with any of the editions for that version.
Types of diagrams supported
From the current set of templates and domains supported by Visio, the following type of diagrams are supported in the Rational Software Architect 8.5 release:-
- UML class diagram
- Captures the classes and their relationships
- UML use case diagram
- Captures the use cases and their relationships with actors
- Network diagram
- Broadly, captures the computing elements and their networking relationship
The first two are UML specification-driven. Thus, they have a natural target in Rational Software Architect as a UML model. Network diagrams are captured as topology models.
File formats supported
Diagrams created in Visio can be persisted in multiple file formats. Visio has a default proprietary binary file format (.vsd), in which diagrams are stored. Rational Software Architect supports the platform-agnostic Visio XML format, which uses a .vdx extension (VDX hereafter). Within Visio, you can choose .vdx as the default format for saving files also.
Considering the backward compatibility of the Visio XML schema, files from older versions of Visio might work without any change.
For the class diagrams, an XMI (XML Metadata Interchange) file is required in addition to the Visio XML, because the XML file has the required semantics. It can be generated by using the macro that is supplied with Microsoft Visio (see Part 2 in this three-part series for more details).
Fidelity of information imported
The core value of the import feature is what information is imported to Rational Software Architect. For any model, there are two important perspectives:
- One is the actual semantics (usually referred to as the semantic model) that communicate the exact semantic for the elements.
- The second is the visual perspective that visually captures a subset of elements in different diagrams.
Although the Visio Import feature creates the semantic model, it also makes a best-effort attempt to preserve the visual aesthetics. The diagram typically conveys additional semantics to the user, based on visual cues, and that is preserved when the information is imported into Rational Software Architect.
From the semantic perspective, between the two types of diagrams supported (UML and network), UML is largely driven by specifications. Therefore, mapping Visio elements to the Rational software naturally aligns the specs. In contrast, because network diagrams are not specification-driven and are largely driven by the type of elements present in the real computing world, there are instances where the import doesn't find a suitable match in topology diagram, so it captures these instances as Sketcher elements.
In capturing ideas and thoughts through notational elements (no semantics attached), the Sketcher component supports evolving those elements as the desired target domain element. This is useful because any element that didn't find its desired target domain element during the import process can still be morphed to the desired target later.
Highlights of the import feature
To improve the usability and make the import process more informative, the overall user experience has been enhanced. The following capabilities, which are applicable for all diagrams, are included with the import process.
Importing the Visio diagram is largely an automated process that executes a certain set of rules and makes certain decisions, based on the content found. To reveal those decisions and provide more insight into what happened "under the hood," an HTML-based report is created.
The report is in a table format, with hyperlinks to navigable content. The information descends from the top table, which contains document-level information, to the lowest level, which includes elements.
Figure 1. Sample report for Visio import
Internal decisions are classified into three categories:
- Information (all messages)
- Warning (warning and error messages)
- Error (only error messages)
You can control their creation in Preferences. Severity information serves as a good visual indicator when looking at the report.
For certain decisions and states of the final imported element, the process creates manual ToDos (visible in Task view) as a mechanism to facilitate user intervention. This is a list of items where the import could not find a perfect match or the desired domain element, so the markers flag those cases for you.
Figure 2. Sample ToDos listed
You can double-click these ToDos to navigate to the respective element in a diagram or model. Like the regular ToDos, you can click the check box to mark them finished and knock them off the list whenever you choose. Creation of ToDos is controlled by Preferences, so you can switch the option On or Off.
As a diagramming tool, Visio works well for human eyes, but when a machine diagnoses the same file, there are certain scenarios that will not match the visual semantics. They are categorized as ambiguous scenarios. As an example, when a connection is made between two elements, the connector can be dropped before properly connecting to the desired element. When reflected in the file, these associations would not exist, but humans can see the intended association in the diagram.
For these types of instances, wherever the import process can find the intended element, it resolves the ambiguity with a built-in algorithm. As an example, for the aforementioned case, where the connection between the two nodes is not made properly, it finds the best possible match of the intended target node and makes that association, so that it is correctly reflected in Rational Software Architect.
Similarly, the UML class diagram import process reconciles the XMI and VDX files. This reconciliation is required to tie the visual element to the semantic element, and it can create certain ambiguities, which are handled to the extent possible.
Control through Preferences
In Preferences, you can tweak the behavior of the Visio import. These options for settings help in fine-tuning certain aspects of the import process.
Figure 3. Preferences available in the Visio Import view
- You can use the two options here to resize the whole diagram by a certain factor. Usually, elements such as classes, drawn in Rational Software Architect, take more real estate. Because we strive to preserve the spatial coordinates of individual elements, the elements tend to overlap with each other. This option enables stretching the diagram. This action is synonymous with zooming in, without losing the relative spatial coordinates.
- Use this group of preferences to decide on the generation of the report, as well as the level of information produced in the report.
- ToDo markers
- Use this simple check box to activate or deactivate creation of create ToDo markers.
There are additional preferences applicable to specific domains. Subsequent articles in this three-part series explain those.
Installation of the feature
To install it, you need to select the Visio Import feature under Rational Software Architect within the IBM Installation Manager (see Figure 1). It is divided into two parts, based on the target domains:
- Visio import for UML diagram
- Visio import for network diagram
Figure 4. IBM Installation Manager with Visio options highlighted
The UML diagram import is grouped with the core UML capability, and the network diagram import is clubbed with the topology model capability, as they are the target domains, respectively.
You can now use Rational Software Architect to migrate Visio diagrams to Rational Software Architect models. This enables a more formal and precise approach to modeling. The software also Version 8.5 also offers usability refinements that make the import more transparent and provides certain controls to tweak the process.
- Learn more at the Rational Software Architect 8.5 support page
- To learn more:
- Start at the Rational Software Architect family of products page and be sure to check the developerWorks page.
- Also, explore What's new in Rational Software Architect 8.5 and see the Rational Software Architect 8.5 Information Center for detailed installation and use instructions. The Rational Software Architect wiki offers additional resources.
- Stay current with developerWorks technical events and webcasts focused on a variety of IBM products and IT industry topics.
- Improve your skills. Check the Rational training and certification catalog, which includes many types of courses on a wide range of topics. You can take some of them anywhere, anytime, and many of the Getting Started ones are free.
Get products and technologies
- Download any of these for a trial at no charge:
- Evaluate IBM software in the way that suits you best: Download it for a trial, try it online, use it in a cloud environment, or spend a few hours in the SOA Sandbox learning how to implement service-oriented architecture efficiently.
- Join the discussion in the Rational Development Tools forum on developerWorks and the Using Design Management forum on Jazz.net.
- Get connected with your peers and keep up on the latest information in the Rational community.
- Rate or review Rational software. It's quick and easy.
- Share your knowledge and help others who use Rational software by writing a developerWorks article. Find out what makes a good developerWorks article and how to proceed.
- Follow Rational software on Facebook, Twitter (@ibmrational), and YouTube, and add your comments and requests.
- Ask and answer questions and increase your expertise when you get involved in the Rational forums, cafés, and wikis.