UmlGraph vs APIViz for Maven javadoc generation

最后都变了- 提交于 2019-11-29 11:28:22
Pascal Thivent

There is an interesting thread here about UMLGraph vs apiviz (which are mentioned in this question on SO too) and my understanding is the following:

  • UMLGraph is older but is really nice (dixit Fowler which has more weight than me).
  • apiviz is a rewrite of UMLGraph but it's not really clear why the rewrote it.
  • The "big" advantage of apiviz is that the build won't fail if Graphviz isn't installed (this doesn't justify a whole rewrite though in my opinion).
  • apiviz doesn't generate graphs automatically, you have to add tags versus UMLGraph do it automatically by default (which can be convenient) and the totally automatic results is fine and easy for all (UMLGraph can also model composition relation with custom javadocs tags).
  • UMLGraph seems to do more things ("it looks like apiviz does nothing more than provide a view of generalizations and interface utilization" or "the class usage shown by UMLGraph actually helps to understand how a class works") but I didn't check myself and this might be not true anymore or outdated.

So, if you project is public, the fact that apiviz gracefully works without Graphviz is nice. If you have lots of classes, having to add tags in javadoc everywhere is a big pain. If you're looking for special features, UMLGraph might offer more. Actually, I think you should experiment both as you obviously have a better knowledge of your needs and constraints for the final choice.

It is not true that apiviz requires annotations for the generation of graphs, as its documentation clearly states:

APIviz automatically discovers the relationship between packages and classes and their stereotype by default. Additionally, you can use the following doclet tags to add more relationships or to make the generated diagram look cleaner.

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