When the writer is launched from rules or Java code, you can set options to tweak the writer's behavior.
Map options = new HashMap(); options.put(MagicDrawOptions.OPTION_WRITER_SHOW_ROLE_NAME Boolean.TRUE); Model umlModel =... umlModel.write("MagicDraw", "c:\path.mdzip", options);
The model writer can be configured with the following options:
EcoreUtil.generateUUID(). In some case, if we ignore the case, several elements can have the same id.
Writing UML Data
MDAccess for UML API Reference
MDAccess for MagicDraw API Reference