Extension that adds an autosummary:: directive. The directive can be used to generate function/method/attribute/etc. summary lists, similar to those output eg. by Epydoc and other API doc generation tools. An :autolink: role is also provided. autosummary directive --------------------- The autosummary directive has the form:: .. autosummary:: :nosignatures: :toctree: generated/ module.function_1 module.function_2 ... and it generates an output table (containing signatures, optionally) ======================== ============================================= module.function_1(args) Summary line from the docstring of function_1 module.function_2(args) Summary line from the docstring ... ======================== ============================================= If the :toctree: option is specified, files matching the function names are inserted to the toctree with the given prefix: generated/module.function_1 generated/module.function_2 ... Note: The file names contain the module:: or currentmodule:: prefixes. .. seealso:: autosummary_generate.py autolink role ------------- The autolink role functions as ``:obj:`` when the name referred can be resolved to a Python object, and otherwise it becomes simple emphasis. This can be used as the default role to make links 'smart'.
Module | generate |
Generates reST source files for autosummary. |
From __init__.py
:
Class |
|
Smart linking role. |
Class |
|
Pretty table containing short signatures and summaries of functions etc. |
Class | autosummary |
Undocumented |
Class | autosummary |
Undocumented |
Class |
|
Undocumented |
Class |
|
Undocumented |
Exception |
|
Exceptions raised during importing the target objects. |
Function | autosummary |
Undocumented |
Function | autosummary |
Make the first column of the table non-breaking. |
Function | autosummary |
Hide autosummary toctree list in HTML output. |
Function | extract |
Extract summary from docstring. |
Function | get |
Get an autodoc.Documenter class suitable for documenting the given object. |
Function | get |
Obtain current Python import prefixes (for `import_by_name`) from ``document.env`` |
Function | get |
Undocumented |
Function | import |
Import a Python object that has the given *name*, under one of the *prefixes*. The first name that succeeds is used. |
Function | import |
Import an instance variable that has the given *name*, under one of the *prefixes*. The first name that succeeds is used. |
Function | limited |
Join a number of strings into one, limiting the length to *max_chars*. |
Function | mangle |
Reformat a function signature to a more compact form. |
Function | process |
Undocumented |
Function | setup |
Undocumented |
Function | strip |
Strip a type hint from argument definition. |
Constant | WELL |
Undocumented |
Variable | literal |
Undocumented |
Variable | logger |
Undocumented |
Variable | periods |
Undocumented |
Function | _cleanup |
Clean up signature using inspect.signautre() for mangle_signature() |
Function | _import |
Import a Python object given its full name. |
Hide autosummary toctree list in HTML output.
Parameters | |
self:nodes.NodeVisitor | Undocumented |
node:autosummary_toc | Undocumented |
Make the first column of the table non-breaking.
Parameters | |
self:HTML5Translator | Undocumented |
node:autosummary_table | Undocumented |
Get an autodoc.Documenter class suitable for documenting the given object. *obj* is the Python object to be documented, and *parent* is an another Python object (e.g. a module or a class) to which *obj* belongs to.
Parameters | |
app:Sphinx | Undocumented |
obj:Any | Undocumented |
parent:Any | Undocumented |
Returns | |
type[ | Undocumented |
Join a number of strings into one, limiting the length to *max_chars*. If the string overflows this limit, replace the last fitting item by *overflow_marker*. Returns: joined_string
Parameters | |
sep:str | Undocumented |
items:list[ | Undocumented |
maxint | Undocumented |
overflowstr | Undocumented |
Returns | |
str | Undocumented |
Obtain current Python import prefixes (for `import_by_name`) from ``document.env``
Parameters | |
env:BuildEnvironment | Undocumented |
Returns | |
list[ | Undocumented |