devlauer / plantuml-generator

utility and maven plugin project for generating plantuml class diagrams and sequence diagrams out of java classes
https://devlauer.github.io/plantuml-generator/plantuml-generator/latest/index.html
Apache License 2.0
87 stars 27 forks source link

graphml format support #107

Closed AntonioGHub closed 1 year ago

AntonioGHub commented 1 year ago

First, thanks for your plugin, which has a great potential to streamline my workflow.

Second, I'm not sure this is a issue, or a feature request, or I just missed something.

I'd like to be able to generate graphml files out of a maven project, but I cannot find a way to do it. In theory, plantuml can do that (see First shot on graphml export: support most class diagram features by thomaswoyke · Pull Request #1195 · plantuml/plantuml · GitHub) but it is maybe not integrated in your plugin.

I have tried to run it with different version of the "official" plantuml switch, but it always generates the diagram using plantuml default format (not graphml)

mvn \
de.elnarion.maven:plantuml-generator-maven-plugin:generate \
    -Dplantuml-generator.-tgraphml="true"\
    -Dplantuml-generator.tgraphml="true" \
    -Dtgraphml="true" \
    -Dtgraphml \
    -Dgraphml \

Thanks in advance!

devlauer commented 1 year ago

Perhaps the name of the project is a little bit misleading. It is about generating PlantUML diagram texts not about converting PlantUML texts to images or graphml. Regardless, GraphML in PlantUML (jar) is currently only supported in a separate experimental branch and as far as I could see has not arrived in the official version. This is also the reason why there is no dependency on the PlantUML jar in the project and why specifying the switch from PlantUML is of no use here. However, when the experimental PlantUML branch is released, one could possibly use the Maven plugin of this project (https://github.com/devlauer/plantuml-generator) to generate the PlantUML text into a file, which is then subsequently converted into the desired GraphML format by a PlantUML Converter Maven plugin like (https://github.com/arnaudroques/maven-plantuml-plugin or https://github.com/Huluvu424242/plantuml-maven-plugin) together with the appropriate PlantUML jar.

devlauer commented 1 year ago

I hope my answer helped you. I'll close the ticket for now. If there is something else, feel free to open it again

AntonioGHub commented 1 year ago

Thanks, I got the point, I'll stick to using your plugin to generate puml files only.

Fun facts, irrelevant to this "issue":

The plantuml original jar, supports graphml format, it is not technically an experimental branch, because it was merged. But it is true that it is an experimental feature.

I am now fiddling with the plugins you pointed out to convert from your generated puml file to their rendering to other formats. I cannot execute them, I get a java.lang.ClassNotFoundException: net.sourceforge.plantuml.Option even if the original plantuml jar is included, I'll add a message if I figure how to make that work

AntonioGHub commented 11 months ago

well, you were right twice: that branch was merged, true, but into an experimental branch...