Skip to content

Commit

Permalink
Only generate one documentation file per class. (googleapis#6272)
Browse files Browse the repository at this point in the history
Speeds up BigQuery documentation generation by only generating one file
per class instead of one file per method and attribute.
  • Loading branch information
tswast authored and tseaver committed Oct 19, 2018
1 parent 05dea1b commit a74dc33
Showing 1 changed file with 28 additions and 27 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,34 +2,35 @@

.. currentmodule:: {{ module }}

.. autoclass:: {{ objname }}
{% block methods %}
{% if methods %}
.. rubric:: Methods

{% block methods %}
.. automethod:: __init__

{% if methods %}
.. rubric:: Methods

{# Customized from original by adding toctree. This generates docs for the
listed functions. #}
.. autosummary::
:toctree: .
{% for item in methods %}
{% if item != '__init__' %}
~{{ name }}.{{ item }}
{% endif %}
{%- endfor %}
.. autosummary::
{% for item in methods %}
{% if item != '__init__' %}
~{{ name }}.{{ item }}
{% endif %}
{% endblock %}
{%- endfor %}
{% endif %}
{% endblock %}

{% block attributes %}
{% if attributes %}
.. rubric:: Attributes
{% block attributes %}
{% if attributes %}
.. rubric:: Attributes

.. autosummary::
:toctree: .
{% for item in attributes %}
~{{ name }}.{{ item }}
{%- endfor %}
{% endif %}
{% endblock %}
.. autosummary::
{% for item in attributes %}
~{{ name }}.{{ item }}
{%- endfor %}
{% endif %}
{% endblock %}

.. raw:: html

<p>
<hr>
<p>

.. autoclass:: {{ objname }}
:members:

0 comments on commit a74dc33

Please sign in to comment.