You can migrate your works done in another software to Visual Paradigm through XMI, provided that the software supports XMI. In this chapter, you will see how to import an XMI file.
Importing XMI to current project
- Select Project > Import > XMI… from the toolbar. This displays the Import XMI window.
- Specify the file path of the XMI to import and configure the import if necessary.
- Click OK.Note: All changes made in project will be overwritten by data in XMI. For example, if class Foo is renamed to Bar. By importing an XMI exported before renaming class, Bar will be renamed to Foo.
An overview of Import XMI window
No. | Name | Description |
---|---|---|
1 | File path | The file path of the XMI file to import. |
2 | Import Comment as Note (for XMI 2.1 only) | Determine whether to import comment as description or as note of model. |
3 | Generate new ID for elements not found in current project | You can enable this option to ensure the uniqueness of ID across projects. |
4 | Auto Layout after imported | Determine whether to run a layout on diagram after import. Note that running layout may takes time for a massive amount of diagram data. |
5 | Suppress Super Stereotype | Determine whether to ignore super stereotype when importing. |
6 | Matching | The importing of XMI is a procedure to merge the data in XMI into the opening project. The matching option is to determine how to match between data in XMI and the opening project during export and to perform changes accordingly. |
7 | Fully follow import XMI (will prompt to delete model elements not in XMI file) | By checking this option, the project will fully follow the imported XMI. You will be prompted to delete any data that does not exist in XMI. |
8 | Import | Click here to import the XMI. |
9 | Cancel | Click here to cancel importing. |
10 | Help | Click here to read the Help contents of import XMI. |
Importing XMI to project with command line interface
To import XMI to a project through command line:
- Browse the scripts folder under the Visual Paradigm installation directory. For Mac users, you can find the scripts folder in the Visual Paradigm package by right clicking on it and then selecting Show Package Contents. Then look in Contents\Resources\app\scripts for the scripts folder.
- Copy the script file ImportXMI and paste to the bin folder of Visual Paradigm installation directory.
- Start the command prompt.
- Navigate to the bin folder of Visual Paradigm installation directory.
- Execute the script by supplying the required parameters. For example:
ImportXMI -project C:\Demo\Demo.vpp -file C:\Demo\input\sample.xmi Below is a description of parameters:Parameter Description Example -project Project path C:\Demo\Demo.vpp -file The filepath of the XMI file to import C:\Demo\input\sample.xmi