New File for the QVTr Editor

You may create QVTr files in any project to which the QVTrelation nature has been added. You may therefore skip the create project step and use an existing project.

Step 1: Create Project

From the Eclipse main menu invoke File->New->Project...
Select General->Project, then Next
Enter a project name such as QVTrPlay and then Finish.

Step 2: Add QVTrelation Nature to Project

Select your project (QVTrPlay) and from the right button menu invoke Add QVTrelation Nature.

Step 3: Create New QVTr File

From the Eclipse main menu (or project right button menu) invoke File->New->Other...
Select QVT Wizards->QVTrelation Editor File then Next
Select your project (QVTrPlay) as the container and new_file.qvtr as the file name then Finish.

The editor should open up showing

[If there are no errors, you neglected to Add QVTrelation Nature.]

The example uses the leftMM and rightMM meta-models, neither of which exist, so these contribute the first two errors. These are presumed to supply the Left and Right classes, whose absence produces two further problems.

Step 4: Create a Meta-Model File

You may remedy the missing meta-models by:

From the Eclipse main menu (or project right button menu) invoke File->New->Other...
Select Example EMF Model Creation Wizards->Ecore Model then Next
Select your project (QVTrPlay) as the container and left.ecore as the file then Finish.

Within the editor for left.ecore, select Show Properties View (from the right button menu).
Rename the root package to left (from null), by opening the root resource to show the null package, selecting it and changing its Name to left (in the Properties View).
Create the Left class, by invoking New Child->EClass from the right button menu of the left package. Specify its Name as Left in the Properties View.
Save and close left.ecore.

Step 5: Bind a Meta-Model Accessor Name to a Meta-Model File

This model may now be used to resolve the leftMM reference.

Invoke Add Model Registry Nature from the right button menu of your project (QVTrPlay), so that the project has a Model Registry Property Page.

Invoke Properties, Model Registry from the right button menu of your project (QVTrPlay) to open up the Model Registry Property Page.

In the Property Page for the Model Name Accessor, invoke New...
Enter leftMM, and use Browse Workspace... to locate left.ecore.

Hit OK and OK to complete the registration.

Step 6: Refresh Problem Markers

From the Eclipse main menu invoke Project->Clean... for your project (QVTrPlay), and the errors associated with the leftMM disappear.

You may repeat for the rightMM, but by now you are probably ready to use your own models.