Skip an object in class inheritance diagram with Sphinx.automodapi

你说的曾经没有我的故事 提交于 2020-06-17 09:10:53

问题


I'm trying to automatically build the class inheritance tree of the raytracing module (available on pip) with automodapi extension for sphinx, however, there is one class I would like to omit. The automodapi allows the creation of the tree with the command .. automod-diagram:: moduleName and in the doc there seem to be a skip method, but it only skips in the documentation generation, as I want to skip an object in the class diagram. The name of the class I want to omit is Materials.

To reproduce,

  1. pip install raytracing
  2. Open module as project.
  3. in /docs, open the index.rst file
  4. add .. automod-diagram:: raytracing :parts: 1
  5. in the terminal, reach the /docs location and launch command make html.
  6. Install the dependencies as needed.
  7. Look at the generated class diagram.

Is there a way to omit one of the class from this extension? How should I proceed?

来源:https://stackoverflow.com/questions/62187002/skip-an-object-in-class-inheritance-diagram-with-sphinx-automodapi

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