|
| 1 | +*************************************** |
| 2 | +API documentation and generated content |
| 3 | +*************************************** |
| 4 | + |
| 5 | +This page contains general code elements that are common |
| 6 | +for package documentation. |
| 7 | + |
| 8 | +.. contents:: Table of Contents |
| 9 | + |
| 10 | +Pandas DataFrame |
| 11 | +================ |
| 12 | + |
| 13 | +.. currentmodule:: pandas |
| 14 | + |
| 15 | +.. autosummary:: |
| 16 | + :toctree: api/ |
| 17 | + |
| 18 | + DataFrame |
| 19 | + DataFrame.index |
| 20 | + DataFrame.columns |
| 21 | + DataFrame.dtypes |
| 22 | + DataFrame.ftypes |
| 23 | + DataFrame.get_dtype_counts |
| 24 | + DataFrame.get_ftype_counts |
| 25 | + DataFrame.select_dtypes |
| 26 | + DataFrame.values |
| 27 | + |
| 28 | + |
| 29 | +:mod:`pandas.datetime` |
| 30 | +====================== |
| 31 | + |
| 32 | +.. automodule:: pandas.datetime |
| 33 | + :members: |
| 34 | + |
| 35 | + |
| 36 | +C++ API |
| 37 | +======= |
| 38 | + |
| 39 | +.. cpp:type:: MyType |
| 40 | + |
| 41 | + Some type |
| 42 | + |
| 43 | +.. cpp:function:: const MyType Foo(const MyType bar) |
| 44 | + |
| 45 | + Some function type thing |
| 46 | + |
| 47 | +.. cpp:class:: template<typename T, std::size_t N> std::array |
| 48 | + |
| 49 | + Some cpp class |
| 50 | + |
| 51 | +.. cpp:member:: float Sphinx::version |
| 52 | + |
| 53 | + The description of Sphinx::version. |
| 54 | + |
| 55 | +.. cpp:var:: int version |
| 56 | + |
| 57 | + The description of version. |
| 58 | + |
| 59 | +.. cpp:type:: std::vector<int> List |
| 60 | + |
| 61 | + The description of List type. |
| 62 | + |
| 63 | +.. cpp:enum:: MyEnum |
| 64 | + |
| 65 | + An unscoped enum. |
| 66 | + |
| 67 | + .. cpp:enumerator:: A |
| 68 | + |
| 69 | +.. cpp:enum-class:: MyScopedEnum |
| 70 | + |
| 71 | + A scoped enum. |
| 72 | + |
| 73 | + .. cpp:enumerator:: B |
| 74 | + |
| 75 | +.. cpp:enum-struct:: protected MyScopedVisibilityEnum : std::underlying_type<MySpecificEnum>::type |
| 76 | + |
| 77 | + A scoped enum with non-default visibility, and with a specified underlying type. |
| 78 | + |
| 79 | + .. cpp:enumerator:: B |
| 80 | + |
| 81 | + |
| 82 | +JavaScript API |
| 83 | +============== |
| 84 | + |
| 85 | +.. Copied from sphinx-doc/sphinx/tests/roots |
| 86 | +
|
| 87 | +.. js:module:: module_a.submodule |
| 88 | + |
| 89 | +* Link to :js:class:`ModTopLevel` |
| 90 | + |
| 91 | +.. js:class:: ModTopLevel |
| 92 | + |
| 93 | + * Link to :js:meth:`mod_child_1` |
| 94 | + * Link to :js:meth:`ModTopLevel.mod_child_1` |
| 95 | + |
| 96 | +.. js:method:: ModTopLevel.mod_child_1 |
| 97 | + |
| 98 | + * Link to :js:meth:`mod_child_2` |
| 99 | + |
| 100 | +.. js:method:: ModTopLevel.mod_child_2 |
| 101 | + |
| 102 | + * Link to :js:meth:`module_a.submodule.ModTopLevel.mod_child_1` |
| 103 | + |
| 104 | +.. js:module:: module_b.submodule |
| 105 | + |
| 106 | +* Link to :js:class:`ModTopLevel` |
| 107 | + |
| 108 | +.. js:class:: ModNested |
| 109 | + |
| 110 | + .. js:method:: nested_child_1 |
| 111 | + |
| 112 | + * Link to :js:meth:`nested_child_2` |
| 113 | + |
| 114 | + .. js:method:: nested_child_2 |
| 115 | + |
| 116 | + * Link to :js:meth:`nested_child_1` |
| 117 | + |
| 118 | + |
| 119 | +Generated Index |
| 120 | +=============== |
| 121 | + |
| 122 | +Part of the sphinx build process in generate and index file: :ref:`genindex`. |
| 123 | + |
| 124 | + |
| 125 | +Optional parameter args |
| 126 | +======================= |
| 127 | + |
| 128 | +At this point optional parameters `cannot be generated from code`_. |
| 129 | +However, some projects will manually do it, like so: |
| 130 | + |
| 131 | +This example comes from `django-payments module docs`_. |
| 132 | + |
| 133 | +.. class:: payments.dotpay.DotpayProvider(seller_id, pin[, channel=0[, lock=False], lang='pl']) |
| 134 | + |
| 135 | + This backend implements payments using a popular Polish gateway, `Dotpay.pl <http://www.dotpay.pl>`_. |
| 136 | + |
| 137 | + Due to API limitations there is no support for transferring purchased items. |
| 138 | + |
| 139 | + |
| 140 | + :param seller_id: Seller ID assigned by Dotpay |
| 141 | + :param pin: PIN assigned by Dotpay |
| 142 | + :param channel: Default payment channel (consult reference guide) |
| 143 | + :param lang: UI language |
| 144 | + :param lock: Whether to disable channels other than the default selected above |
| 145 | + |
| 146 | +.. _cannot be generated from code: https://groups.google.com/forum/#!topic/sphinx-users/_qfsVT5Vxpw |
| 147 | +.. _django-payments module docs: http://django-payments.readthedocs.org/en/latest/modules.html#payments.authorizenet.AuthorizeNetProvide |
| 148 | + |
| 149 | + |
| 150 | +Data |
| 151 | +==== |
| 152 | + |
| 153 | +.. data:: Data_item_1 |
| 154 | + Data_item_2 |
| 155 | + Data_item_3 |
| 156 | + |
| 157 | + Lorem ipsum dolor sit amet, consectetur adipiscing elit. Fusce congue elit eu hendrerit mattis. |
| 158 | + |
| 159 | +Some data link :data:`Data_item_1`. |
0 commit comments