How to: Load an .xmi File By Using "Quadrant"
[This content is no longer valid. For the latest information on "M", "Quadrant", SQL Server Modeling Services, and the Repository, see the Model Citizen blog.]
This is the first step in Walkthrough: Using the Microsoft.Uml2 Domain; the next step is How to: Browse the UML Data in "Quadrant". This topic describes how to load .xmi files into the SQL Server Modeling Services database by using a command prompt as well as by using Microsoft code name “Quadrant”.
Load an .xmi file by using a command prompt
Download all sample XMI files from C:\PDC09-HOLS\Modeling Services—DinnerNowClass.xmi and DinnerNowComponent.xmi—to a folder on your machine. For example:
C:\OsloSamples\UML\XMI
.Open the SQL Server Modeling CTP Command Prompt.
Run Loaduml.exe to populate the DinnerNow Component Model from the DinnerNowComponent.xmi file into a Modeling Services folder called DinnerNow by using the following command (replacing the file path with your own file path):
c:\Program Files\Microsoft Oslo\1.0\bin>LoadUml.exe /tf:DinnerNow /d:Repository /tgt:Repository c:\OsloSamples\UML\XMI\DinnerNowComponent.xmi
Note
If you are using SQL Server 2008 Express, you must also pass /s:.</STRONG>expressInstanceName where expressInstanceName is the name of your instance of SQL Server 2008 instance.
The output is:
(0,0): message : Generating instances...
(0,0): message : Finished... 28 elements were loaded.
Load an .xmi file by using “Quadrant”
In “Quadrant”, if there is no Repository Explorer workpad open, click the View menu, click Explorer and then click Repository. In the Repository Explorer workpad, note that the previous step has inserted a DinnerNow folder under the Database entry.
Create another new folder named DinnerNowDesign.
In the Repository Explorer workpad, right-click Database, and then click Insert Folder. A folder named New Folder appears under Database.
Note
The + character that appears just to the right of New Folder indicates that the data has not yet been saved to the database. It remains visible for all data entered in this tutorial until you save the data in step e.
Drag (or double-click) New Folder+ to the workspace to open it in a new workpad.
In the New FoldersTable Record workpad, change the view to Properties.
In the Name text box, type DinnerNowDesign.
On the File menu, click Save Changes (or press CTRL+S). Note that the + character disappears when the data successfully saves.
Close the DinnerNowDesign workpad.
Load UML data from an .xmi file.
In the Repository Explorer workpad, select the DinnerNowDesign folder, and on the Data menu, click Import Uml to start the load process.
In the Import UML dialog box, navigate to and select the DinnerNowClass.xmi file.
Click Open and then click OK in the dialog box that appears.