Create or build UML schema from Doctrine entity yml or Xml in symfony2

心不动则不痛 提交于 2019-12-06 06:57:51

Using free tools, a way to do is to use the command

phpuml -x 1 -o C:\symfony\httpfoundation.xmi C:\symfony\vendor\symfony\src\Symfony\Component\HttpFoundation

(this is a sample for generating the schema from symfony source code)

Then using BoUml Viewer or ArgoUML for viewing the generated file.

I tried other way to do it but none was giving good results...

The best way I found (and I use) is to do it with Sparx Systems - Enterprise Architect, but you have to pay for it :(

Anyway, if you find another working way to do it, I'm quite interested :)

Best regards, Christophe

So to resolve that,I'm using visual paradigm for uml,this software is not for free it needs activation key.But it offers a connection directly to your database,just follow "tools => database => reverse Database,then you create your "Entity Relationship Diagram",finally just you click with right button of your mouse on the page of ERD and choose "synchronize to class diagram" and automatically you will have your class diagram,finally you can just add your setter and getter,also you can export it to a lot of kind of format(XML,Xls...).

Check out ORM Designer. It can do exactly what you need, if you don't mind its paid software. And you can use it to edit schemas for your projects in visual environment and generate your XML/YML definitions from the visual schema.

Look at this solution: https://packagist.org/packages/onurb/doctrine-yuml-bundle

It's a symfony bundle that will offer you the console command

bin/console yuml:mappings

and will write an image yuml-mapping.png.

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!