+
+ /* Represents the printing state of a progress meter. */
+ enum meter_state
+ {
+ /* Printing will start with the next output. */
+ START,
+ /* Printing has already started. */
+ WORKING,
+ /* Progress printing has already started. */
+ PROGRESS,
+ /* Printing should not be done. */
+ NO_PRINT
+ };
+
+ /* The state of a recent progress meter. */
+ struct cli_progress_info
+ {
+ /* The current state. */
+ enum meter_state printing;
+ /* The name to print. */
+ std::string name;
+ /* The last notification value. */
+ double last_value;
+ };
+
+ /* Stack of progress meters. */
+ std::vector<cli_progress_info> m_meters;