xhale¶
Converts sphinx and breathe inventory files to doxygen tag files.
Introduction¶
xhale
transforms an inventory file given by sphinx into a doxygen tag file. This package is mainly used for xeus-cling in order to be able to get the documentation of a C++ package in a jupyter notebook.
To create your tag file, you just have to use the script xhale and give the following arguments
- the package name which will be the name of the tag file
- the url where to find the inventory file
Here is an example
xhale -p xtensor --url https://xtensor.readthedocs.io/en/latest/
xhale package¶
-
xhale.xhale.
extract_tag
(inventory, url)¶ extract data from sphinx inventory.
The extracted datas come from a C++ project documented using Breathe. The structure of the inventory is a dictionary with the following keys
- cpp:class (class names)
- cpp:function (functions or class methods)
- cpp:type (type names)
each value of this dictionary is again a dictionary with
- key : the name of the element
- value : a tuple where the third index is the url to the corresponding documentation
Parameters: - inventory (dict) – sphinx inventory
- url (url of the documentation) –
Returns: - dictionary with keys class, class_methods, func, type
- but now the class methods are with their class.
-
xhale.xhale.
get_sphinx_inventory
(url)¶ get the sphinx inventory from a url.
Parameters: url (url of the package where find objects.inv file) – Returns: the inventory Return type: dict
-
xhale.xhale.
write_tagfile
(tag_elem, package, url)¶ write the doxygen tagfile (package.tag).
Parameters: - tag_elem (dictionary given by extract_tag) –
- package (name of the package) –
- url (url of the documentation) –
Licensing¶
We use a shared copyright model that enables all contributors to maintain the copyright on their contributions.
This software is licensed under the BSD-3-Clause license. See the LICENSE file for details.