diff options
Diffstat (limited to 'docs/api')
-rw-r--r-- | docs/api/cmd.rst | 2 | ||||
-rw-r--r-- | docs/api/history.rst | 3 | ||||
-rw-r--r-- | docs/api/index.rst | 29 | ||||
-rw-r--r-- | docs/api/parsing.rst | 15 | ||||
-rw-r--r-- | docs/api/utils.rst | 12 |
5 files changed, 45 insertions, 16 deletions
diff --git a/docs/api/cmd.rst b/docs/api/cmd.rst index 3fcd3352..dd3d3abe 100644 --- a/docs/api/cmd.rst +++ b/docs/api/cmd.rst @@ -52,7 +52,7 @@ cmd2.Cmd A record of previously entered commands. This attribute is an instance of :class:`cmd2.history.History`, and - each command is an instance of :class:`cmd2.history.HistoryItem`. + each command is an instance of :class:`cmd2.Statement`. .. attribute:: statement_parser diff --git a/docs/api/history.rst b/docs/api/history.rst index 3a3ae2c4..5658238d 100644 --- a/docs/api/history.rst +++ b/docs/api/history.rst @@ -1,6 +1,9 @@ cmd2.history =============== +Classes for storing the history of previously entered commands. + + .. autoclass:: cmd2.history.History :members: diff --git a/docs/api/index.rst b/docs/api/index.rst index d5fc013b..aa3371b9 100644 --- a/docs/api/index.rst +++ b/docs/api/index.rst @@ -12,19 +12,42 @@ If a release of this library changes any of the items documented here, the version number will be incremented according to the `Semantic Version Specification <https://semver.org>`_. -This documentation is for version |version| of ``cmd2``. +This documentation is for ``cmd2`` version |version|. .. toctree:: :maxdepth: 1 + :hidden: cmd - parsing decorators - history + parsing argparse_completer argparse_custom ansi utils + history plugin py_bridge constants + +**Modules** + +- :ref:`api/cmd:cmd2.Cmd` - functions and attributes of the main + class in this library +- :ref:`api/decorators:cmd2.decorators` - decorators for ``cmd2`` + commands +- :ref:`api/parsing:cmd2.parsing` - classes for parsing and storing + user input +- :ref:`api/argparse_completer:cmd2.argparse_completer` - classes for + ``argparse``-based tab completion +- :ref:`api/argparse_custom:cmd2.argparse_custom` - classes and functions + for extending ``argparse`` +- :ref:`api/ansi:cmd2.ansi` - convenience classes and functions for generating + ANSI escape sequences to style text in the terminal +- :ref:`api/utils:cmd2.utils` - various utility classes and functions +- :ref:`api/history:cmd2.history` - classes for storing the history + of previously entered commands +- :ref:`api/plugin:cmd2.plugin` - data classes for hook methods +- :ref:`api/py_bridge:cmd2.py_bridge` - classes for bridging calls from the + embedded python environment to the host app +- :ref:`api/constants:cmd2.constants` - just like it says on the tin diff --git a/docs/api/parsing.rst b/docs/api/parsing.rst index c79c8f6b..fa726700 100644 --- a/docs/api/parsing.rst +++ b/docs/api/parsing.rst @@ -1,6 +1,15 @@ cmd2.parsing =============== +Classes for parsing and storing user input. + + +.. autoclass:: cmd2.parsing.StatementParser + :members: + + .. automethod:: __init__ + + .. autoclass:: cmd2.Statement :members: @@ -67,9 +76,3 @@ cmd2.parsing If output was redirected by the user, this contains the requested destination with quotes preserved. - - -.. autoclass:: cmd2.parsing.StatementParser - :members: - - .. automethod:: __init__ diff --git a/docs/api/utils.rst b/docs/api/utils.rst index 2ae5987b..8121fea8 100644 --- a/docs/api/utils.rst +++ b/docs/api/utils.rst @@ -42,12 +42,6 @@ Tab Completion .. autoclass:: cmd2.utils.CompletionError :members: -.. autofunction:: cmd2.utils.remove_duplicates - -.. autofunction:: cmd2.utils.alphabetical_sort - -.. autofunction:: cmd2.utils.natural_sort - .. autofunction:: cmd2.utils.basic_complete @@ -76,3 +70,9 @@ Miscellaneous .. autofunction:: cmd2.utils.namedtuple_with_defaults .. autofunction:: cmd2.utils.categorize + +.. autofunction:: cmd2.utils.remove_duplicates + +.. autofunction:: cmd2.utils.alphabetical_sort + +.. autofunction:: cmd2.utils.natural_sort |