polychemprint3.commandLineInterface.ioMenuSpec module¶
Contains ioMenuSpec Abstract Base Class.
First created on Sun Oct 20 00:03:21 2019
Revised (dd/mm/yyyy): 20/12/2020 - BP
Author: Bijal Patel
-
class
polychemprint3.commandLineInterface.ioMenuSpec.
ioMenuSpec
(menuTitle, menuItems, menuDesc='', menuInstruc='Choose from the following menu items:', lastCmd='', memCmd='', **kwargs)¶ Bases:
polychemprint3.commandLineInterface.ioElementSpec.ioElementSpec
,abc.ABC
Specifies the interface for CLI menus.
-
ioMenu_printMenu
(showStoredCmds=True)¶ Prints formatted menu options from menuItems dict.
-
ioMenu_updateStoredCmds
(lastCmd, memCmd)¶ Updates stored commands local to this menu item from inputs.
Parameters: - lastCmd (str) – specifying the last command entered
- memCmd (str) – specifying the command saved to memory
-
io_Operate
()¶ Performs menu operations and loops on user input. :returns: Title of next menu to present. :rtype: str
-