sphinx-autoapi/autoapi/templates/python/function.rst

14 lines
325 B
ReStructuredText
Raw Normal View History

{%- if obj.display %}
{%- if is_method %}
2015-04-01 00:01:41 +00:00
{# Slice self off #}
.. method:: {{ obj.name.split('.')[-1] }}({{ obj.args[1:]|join(',') }})
2015-04-01 00:01:41 +00:00
{% else %}
.. function:: {{ obj.name.split('.')[-1] }}({{ obj.args|join(',') }})
2015-04-01 00:01:41 +00:00
{% endif %}
{%- if obj.docstring %}
{{ obj.docstring.strip()|indent(3) }}
2015-04-01 00:01:41 +00:00
{% endif %}
{% endif %}