]> granicus.if.org Git - python/commitdiff
#22613: document Cmd.cmdqueue (thanks Jacques Ducasse)
authorGeorg Brandl <georg@python.org>
Fri, 31 Oct 2014 09:25:38 +0000 (10:25 +0100)
committerGeorg Brandl <georg@python.org>
Fri, 31 Oct 2014 09:25:38 +0000 (10:25 +0100)
Doc/library/cmd.rst

index ea2412238b053c8fc8194146940f007fe6463888..05341d7cb04f7c3548a7795e0f7f4f3cc1d76759 100644 (file)
@@ -151,8 +151,8 @@ A :class:`Cmd` instance has the following methods:
    Hook method executed once when :meth:`cmdloop` is about to return. This method
    is a stub in :class:`Cmd`; it exists to be overridden by subclasses.
 
-Instances of :class:`Cmd` subclasses have some public instance variables:
 
+Instances of :class:`Cmd` subclasses have some public instance variables:
 
 .. attribute:: Cmd.prompt
 
@@ -169,6 +169,13 @@ Instances of :class:`Cmd` subclasses have some public instance variables:
    The last nonempty command prefix seen.
 
 
+.. attribute:: Cmd.cmdqueue
+
+   A list of queued input lines.  The cmdqueue list is checked in
+   :meth:`cmdloop` when new input is needed; if it is nonempty, its elements
+   will be processed in order, as if entered at the prompt.
+
+
 .. attribute:: Cmd.intro
 
    A string to issue as an intro or banner.  May be overridden by giving the