1 #ifndef CODE_CONSOLE_STORE_H 2 #define CODE_CONSOLE_STORE_H 17 void pushResult(
const char * text,
size_t length);
21 static constexpr
char CurrentSessionCommandMarker = 0x01;
22 static constexpr
char CurrentSessionResultMarker = 0x02;
23 static constexpr
char PreviousSessionCommandMarker = 0x03;
24 static constexpr
char PreviousSessionResultMarker = 0x04;
25 static constexpr
int k_historySize = 1024;
26 static char makePrevious(
char marker) {
27 if (marker == CurrentSessionCommandMarker || marker == CurrentSessionResultMarker) {
32 void push(
const char marker,
const char * text,
size_t length);
34 int indexOfNullMarker()
const;
35 void deleteLineAtIndex(
int index);
36 void deleteFirstLine();
41 void deleteLastLine();
42 char m_history[k_historySize];
int deleteCommandAndResultsAtIndex(int index)
int numberOfLines() const
void deleteLastLineIfEmpty()
void pushCommand(const char *text, size_t length)
void pushResult(const char *text, size_t length)
ConsoleLine lineAtIndex(int i) const