File conversion for Dia
Converting file from ArgoUML to Dia is not very straightforward,
as ArgoUML files (.zargo extension) are really packages of
To convert a diagram from ArgoUML to dia, one has to parse the PGML file,
and get any missing bit from the XMI file. Anyway, it is possible to read
several XML files from an XSL stylesheet, if the XSL engine is provided
with the correct command line arguments. Therefore, my implementation
consists in two files:
I wrote this translation to work on simple (but not small) class diagrams,
and only a very small subset of ArgoUML objects are converted:
- One single myfile.xmi, which contains the whole model.
This file uses a subset of XMI file format, and it can't be imported
or exported with another XMI-compliant software. Even ArgoUML
seems to crash when given its own XMI alone.
- One myfile_mydiagram.pgml per diagram, which contains
a diagram description, with a few redondant data (like the size of boxes
and position of arrows), but not enough to draw the model.
- Several other files (like a myfile.argo and myfile.todo).
- methods and their return types
- attributes and their types
- associations and the composition/arrow endings