Example_lib Testmodule¶
mylib docstring.
This module is only here to show how config options look inside the documention, when included from the doc-strings of actual python code.
- class example_lib.BaseA(params)[source]¶
Example parent or base class.
- config A_config¶
option default summary fifth in BaseA.do_something
Multiple options documented at once. [...]
Describe the `first` parameter, context ``allowed``.
fourth in BaseA.do_something
Multiple options documented at once. [...]
Describe the `second` parameter. [...]
How does it handle adding references to other documents?
third in BaseA.do_something
Multiple options documented at once. [...]
- option first: int¶
Describe the first parameter, context
allowed
.
- Parameters
params (dict) – Parameters to be used as
BaseA.params
. See aboveA_config
for details.
- x¶
Usually equal
1+1
.- Type
int
- params¶
Parameters. See above
- Type
dict
- class example_lib.ChildB(params)[source]¶
A subclass of BaseA.
- config B_config¶
option default summary Multiple options documented at once. [...]
Describe the `first` parameter, context ``allowed``.
fourth in ChildB.do_something_else
Yet another parameter that changes in `ChildB` compared to `BaseA`.
Describe the `second` parameter. [...]
How does it handle adding references to other documents?
Another different description of of the `third` parameter, [...]
- option third: str¶
Another different description of of the third parameter, see
A_config.third
for the one in the base class.
- do_something()¶
Some function using self.params.
- example_lib.complicated_function(a, b, c, params)[source]¶
A complicated function.
- config complicated_function¶
option default summary Number of repetitions for `a`.
- option Na: int¶
Number of repetitions for a.
- Parameters
a (int) – Parameter a description.
b (
mylib.B
) – Parameter b description.complicated_params (dict) – Parameters.
- Returns
x – The sum of a and b
- Return type
int