Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

graphical representation #104

Open
fkgl opened this issue Jun 5, 2021 · 4 comments
Open

graphical representation #104

fkgl opened this issue Jun 5, 2021 · 4 comments

Comments

@fkgl
Copy link

fkgl commented Jun 5, 2021

Hi,
Is it possible to visualise the graphical representation of the Metamodel using pyecore?

@aranega
Copy link
Member

aranega commented Jun 8, 2021

Hi @fkgl,

Sorry for the late answer, I didn't receive notification.
At the moment, there is no way of visualizing a graphical representation of a metamodel using PyEcore. For that, a small script using PyEcore would be required. I made a quick test yesterday and it should be fairly easy to generate plantuml syntax from a metamodel. I will try to propose a quick and dirty gist for it as soon as possible :)

Thanks for the proposal!

@fkgl
Copy link
Author

fkgl commented Jun 8, 2021

Hi @aranega,

Thanks for your reply

good luck.

@aranega
Copy link
Member

aranega commented Jun 8, 2021

I had a little bit of time this morning, so I quickly coded this small script: https://gist.github.com/aranega/eca9c8fbbd87b2f9c70317da53676ac6

You can use it this way

python plantumlgen.py mymetamodel.ecore

It will print PlantUML code, you can redirect it to a file, directly compile it with plantuml if you have it installed.

python plantumlgen.py mymetamodel.ecore > visu.plantuml && plantuml -tpng visu.plantuml

@fkgl
Copy link
Author

fkgl commented Jun 8, 2021

Thank you very much for your efforts and for giving me some of your time.
I will try it.

Best regards.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants