Command line history objet.
More...
#include <command_line_history.h>
|
| Object (void) |
| Default constructor only available to sub-classes. More...
|
|
Command line history objet.
Definition at line 49 of file command_line_history.h.
◆ CmdLineHistory()
CmdLineHistory::CmdLineHistory |
( |
const unsigned int |
UI_StackSize | ) |
|
|
explicit |
Default constructor.
- Parameters
-
UI_StackSize | Number of history lines the stack should manage. |
◆ ~CmdLineHistory()
virtual CmdLineHistory::~CmdLineHistory |
( |
void |
| ) |
|
|
virtual |
◆ Clear()
const bool CmdLineHistory::Clear |
( |
void |
| ) |
|
Cleares all history from the stack.
- Returns
- true for success, false for failure.
◆ EnableNavigationMemory()
void CmdLineHistory::EnableNavigationMemory |
( |
const bool |
B_NavigationMemory | ) |
|
Navigation memory enabling.
As far as the navigation memory is on, the navigation keeps going on. When something happens while the navigation memory is off, the navigation starts from the beginning.
- Parameters
-
B_NavigationMemory | true for enabling, false otherwise. |
◆ GetCount()
const unsigned int CmdLineHistory::GetCount |
( |
void |
| ) |
const |
History line count retrieval.
- Returns
- The number of history lines stacked + 1 for the current one.
◆ GetLine()
const CmdLineEdition& CmdLineHistory::GetLine |
( |
const unsigned int |
UI_BackwardIndex | ) |
const |
History line retrieval.
- Returns
- The expected command line.
- Parameters
-
UI_BackwardIndex | Backward index in history lines. 0 means the current line. |
◆ GetNavigationIndex()
const unsigned int CmdLineHistory::GetNavigationIndex |
( |
void |
| ) |
const |
History index retrieval.
- Returns
- The index of the current navigation position.
◆ Navigate()
History line navigation.
- Returns
- true if all the navigation expected has been executed, false otherwise.
- Parameters
-
CLI_CmdLine | Current command line edition object. |
CLI_Stream | Output stream that should be used to display command lines. |
I_Navigation | Number of steps in history navigation. Positive values mean navigating to older command lines. Negative values mean navigating to newer command lines. |
◆ Push()
Pushes a command line in the history stack.
- Returns
- true for success, false for failure.
- Parameters
-
CLI_Line | Command line to push. |
◆ SaveCurrentLine()
const bool CmdLineHistory::SaveCurrentLine |
( |
const CmdLineEdition & |
CLI_CurrentLine | ) |
|
Saves the current line.
- Returns
- true for success, false otherwise.
- Parameters
-
CLI_CurrentLine | Current line. |
The documentation for this class was generated from the following file: