diff options
Diffstat (limited to 'docs/api')
-rw-r--r-- | docs/api/cmd.rst | 5 | ||||
-rw-r--r-- | docs/api/history.rst | 3 | ||||
-rw-r--r-- | docs/api/index.rst | 1 | ||||
-rw-r--r-- | docs/api/plugin.rst | 45 |
4 files changed, 53 insertions, 1 deletions
diff --git a/docs/api/cmd.rst b/docs/api/cmd.rst index 345e6219..34c0dcf7 100644 --- a/docs/api/cmd.rst +++ b/docs/api/cmd.rst @@ -42,3 +42,8 @@ cmd2.Cmd This attribute is an instance of :class:`cmd2.history.History`, and each command is an instance of :class:`cmd2.history.HistoryItem`. + + .. attribute:: statement_parser + + An instance of :class:`cmd2.parsing.StatementParser` initialized and + configured appropriately for parsing user input. diff --git a/docs/api/history.rst b/docs/api/history.rst index a685db7a..3a3ae2c4 100644 --- a/docs/api/history.rst +++ b/docs/api/history.rst @@ -4,12 +4,13 @@ cmd2.history .. autoclass:: cmd2.history.History :members: + .. autoclass:: cmd2.history.HistoryItem :members: .. attribute:: statement - The statement object resulting from parsing + The :class:`~cmd2.Statement` object parsed from user input .. attribute:: idx diff --git a/docs/api/index.rst b/docs/api/index.rst index 43b36c7a..4009cd29 100644 --- a/docs/api/index.rst +++ b/docs/api/index.rst @@ -10,4 +10,5 @@ API Reference history ansi utils + plugin constants diff --git a/docs/api/plugin.rst b/docs/api/plugin.rst new file mode 100644 index 00000000..4e554b33 --- /dev/null +++ b/docs/api/plugin.rst @@ -0,0 +1,45 @@ +cmd2.plugin +=========== + +.. autoclass:: cmd2.plugin.PostparsingData + :members: + + .. attribute:: stop + + Request the command loop terminate by setting ``True`` + + .. attribute:: statement + + The :class:`~cmd2.Statement` object parsed from user input + + +.. autoclass:: cmd2.plugin.PrecommandData + :members: + + .. attribute:: statement + + The :class:`~cmd2.Statement` object parsed from user input + + +.. autoclass:: cmd2.plugin.PostcommandData + :members: + + .. attribute:: stop + + Request the command loop terminate by setting ``True`` + + .. attribute:: statement + + The :class:`~cmd2.Statement` object parsed from user input + + +.. autoclass:: cmd2.plugin.CommandFinalizationData + :members: + + .. attribute:: stop + + Request the command loop terminate by setting ``True`` + + .. attribute:: statement + + The :class:`~cmd2.Statement` object parsed from user input |