29 IOText(std::ostream& out, std::istream& in) : m_out{out}, m_in{in} {}
32 void println(std::string_view msg);
34 void print(std::string_view msg)
const;
37 void getln(std::string& line);
39 int promptInt(std::string_view prompt,
int validLimit);
47 void promptln(std::string& line, std::string_view prompt);
54 void printCards(
const std::vector<std::string>& cardToPrintGrid);
Text-based input/output interface for terminal interaction.
Definition: iotext.h:20
void getln(std::string &line)
Reads a line of input into the given string.
Definition: iotext.cpp:8
void promptln(std::string &line, std::string_view prompt)
Prints a prompt and reads a line of input.
Definition: iotext.cpp:10
void printCards(const std::vector< std::string > &cardToPrintGrid)
Prints a rendered card grid to the output.
Definition: iotext.cpp:50
void println(std::string_view msg)
Prints a line followed by a newline.
Definition: iotext.cpp:4
void print(std::string_view msg) const
Prints a line (with newline).
Definition: iotext.cpp:6
int promptInt(std::string_view prompt, int validLimit)
Definition: iotext.cpp:16
IOText(std::ostream &out, std::istream &in)
Constructs an IOText interface using the given streams.
Definition: iotext.h:29
void printHand(const RenderedHand &handToPrint)
Prints a rendered hand to the output.
Definition: iotext.cpp:58
Rendered representation of a hand for terminal output.
Definition: handRenderer.h:18