Hook docstrings into the published docs

Fixes bug #1182842

We've always had pretty decent documentation coverage in the docstrings
but have never taken the time to hook them into the published docs.

This is a first-cut at doing that. There's plenty of rough edges, but
it's a good start.

Change-Id: I62a509e7d6e156e9b67e75bef9da68fbfc4601ac
This commit is contained in:
Mark McLoughlin
2013-07-10 08:22:13 +01:00
parent 2b14d7314e
commit 4f44b97017
7 changed files with 73 additions and 3 deletions

5
doc/source/cfg.rst Normal file
View File

@@ -0,0 +1,5 @@
--------------
The cfg Module
--------------
.. automodule:: oslo.config.cfg

View File

@@ -0,0 +1,8 @@
--------------------
The ConfigOpts Class
--------------------
.. currentmodule:: oslo.config.cfg
.. autoclass:: ConfigOpts
:members:

16
doc/source/exceptions.rst Normal file
View File

@@ -0,0 +1,16 @@
----------
Exceptions
----------
.. currentmodule:: oslo.config.cfg
.. autoexception:: Error
.. autoexception:: ArgsAlreadyParsedError
.. autoexception:: NoSuchOptError
.. autoexception:: NoSuchGroupError
.. autoexception:: DuplicateOptError
.. autoexception:: RequiredOptError
.. autoexception:: TemplateSubstitutionError
.. autoexception:: ConfigFilesNotFoundError
.. autoexception:: ConfigFileParseError
.. autoexception:: ConfigFileValueError

8
doc/source/helpers.rst Normal file
View File

@@ -0,0 +1,8 @@
----------------
Helper Functions
----------------
.. currentmodule:: oslo.config.cfg
.. autofunction:: find_config_files
.. autofunction:: set_defaults

View File

@@ -5,12 +5,17 @@ An OpenStack library for parsing configuration options from the command
line and configuration files.
Contents
--------
========
.. toctree::
:maxdepth: 1
:maxdepth: 2
api/autoindex
cfg
opts
configopts
helpers
parser
exceptions
Release Notes
=============

17
doc/source/opts.rst Normal file
View File

@@ -0,0 +1,17 @@
------------------
Option Definitions
------------------
.. currentmodule:: oslo.config.cfg
.. autoclass:: Opt
.. autoclass:: StrOpt
.. autoclass:: BoolOpt
.. autoclass:: IntOpt
.. autoclass:: FloatOpt
.. autoclass:: ListOpt
.. autoclass:: DictOpt
.. autoclass:: MultiStrOpt
.. autoclass:: DeprecatedOpt
.. autoclass:: SubCommandOpt
.. autoclass:: OptGroup

11
doc/source/parser.rst Normal file
View File

@@ -0,0 +1,11 @@
------------
File Parsing
------------
.. autoclass:: oslo.config.iniparser.BaseParser
.. autoclass:: oslo.config.cfg.ConfigParser
:members: parse
.. autoclass:: oslo.config.cfg.MultiConfigParser
:members: read, get