pxDoc - EMF Integration
This enabler provides full pxDoc capabilities to the Eclipse Modeling Framework (EMF).
Installation
First make sure that pxDoc is already installed (if this is not the case: install pxDoc).
To install the enabler:
- The EMF enabler is included in pxDoc, no additional install is necessary.
Quick start
Browse the examples
Once installed, you can import the EMF Sample generator Generic example dedicated to EMF, and many other pxDoc sample projects: select File -> New -> Example...
Note: The sample generator is included as plugin in the enabler, so you can launch the generation directly from a model, without installing the examples.
Initialize a new pxDoc generator
See Project creation for more details on pxDoc projects creation.
First create an empty pxDoc project, with File -> New -> Project... and select the pxDoc Project wizard.
In the second page of the wizard (see screenshot below), select the EMF enabler. If you do not want the common libraries (common modules and associated means) to be automatically imported in your project, un-check the checkbox.
If you do not have a Word stylesheet (.dotx file) available, you can select the one deployed in the EMF Generic Generator
Click on finish.
First, the pxDoc project itself is created and the .pxdoc file opens. You may notice errors in this project during few seconds:
These errors are automatically solved with the second step of the project creation:
If you included the Common Libraries, your last step is to properly bind the variable styles from the modules with the chosen stylesheet: use CTRL-SPACE to get all available styles (from the stylesheet) suggested.
Your pxDoc generator is ready to use with a EMF model.
Do not hesitate to go through the provided examples and the Common Libraries documentation to learn quickly how to rule with pxDoc!
Launching the generation
To test or launch your generator,:
- select Debug As or Run As -> Eclipse Application.
In Debug mode, the modifications made to your generator are automatically taken into account, so you just need to re-launch the generation in the 2nd Eclipse to see the result.
- Import your source model, data... in this 2nd Eclipse
- To enable the pxDoc menu, right click on a relevant object of this source (according to the command object defined in the root template of your Generator).
The launching wizard will pop up
Find the project on GitLab
You can find the source project on GitLab: https://gitlab.com/pxdoc/pxdoc-EMF.
Get support on pxDoc
Read the documentation on www.pxdoc.fr.