Stores and prints a “key” (a.k.a. legend) to data, that is, an explanation to each element of a certain range of data. More...
#include <KeyPrinter.h>
Public Types | |
typedef std::list< std::string > | KeyLabels |
the list of labels | |
typedef std::initializer_list< std::string > | KeyLabelsInitializer |
convenience typedef for initialization with an initializer_list | |
Public Member Functions | |
template<typename... KeyLabelsPack> | |
KeyPrinter (const std::string &keyTitle, KeyLabelsPack &&...keyLabelsPack) | |
construction from an arbitrary set of arguments capable to construct an object of type KeyLabels | |
KeyPrinter (const std::string &keyTitle, KeyLabelsInitializer il) | |
construction from a KeyLabelsInitializer list | |
size_t | length () const |
number of elements in the key | |
std::ostream & | displayKey (std::ostream &, size_t &) const |
displays the stored key in a nicely tabulated format | |
Getters | |
const std::string & | getTitle () const |
const KeyLabels & | getLabels () const |
Stores and prints a “key” (a.k.a. legend) to data, that is, an explanation to each element of a certain range of data.
The key is composed of a title and a list of labels
Definition at line 24 of file KeyPrinter.h.