#include <ProgressTracker.h>
Public Member Functions | |
| Stage () | |
| Stage (const std::string &message, const std::string &component, const std::string &key, int weight=1) | |
| ~Stage () | |
| Stage * | getParent () const |
| Step * | getStep () |
| void | initialize (Stage *pParent) |
| void | finalize (Message::Result result, const std::string &failureReason="") |
| void | subdivide (std::vector< Stage > &stages) |
| void | toNextSubStage () |
| Stage & | getActiveStage () |
| int | getPercentComplete (int percent) const |
| std::string | getActiveMessage (std::string message, std::string indent) const |
Definition at line 64 of file ProgressTracker.h.
| ProgressTracker::Stage::Stage | ( | ) |
Construct an empty stage.
This is not usually called and exists as an implementation detail of the ProgressTracker
Definition at line 72 of file ProgressTracker.h.
| ProgressTracker::Stage::Stage | ( | const std::string & | message, | |
| const std::string & | component, | |||
| const std::string & | key, | |||
| int | weight = 1 | |||
| ) |
| ProgressTracker::Stage::~Stage | ( | ) |
Destructor.
| Stage* ProgressTracker::Stage::getParent | ( | ) | const |
Accessor for the parent of this Stage.
| Step* ProgressTracker::Stage::getStep | ( | ) |
Accessor for the MessageLog Step associated with this stage.
| void ProgressTracker::Stage::initialize | ( | Stage * | pParent | ) |
Set this Stage as a child of pParent.
This is called internally by ProgressTracker.
| pParent | The parent of this Stage |
| void ProgressTracker::Stage::finalize | ( | Message::Result | result, | |
| const std::string & | failureReason = "" | |||
| ) |
| void ProgressTracker::Stage::subdivide | ( | std::vector< Stage > & | stages | ) |
Subdivide a Stage into a series of sub-stages.
| stages | The vector of sub-stages. |
| void ProgressTracker::Stage::toNextSubStage | ( | ) |
Advance to the next sub-stage.
| Stage& ProgressTracker::Stage::getActiveStage | ( | ) |
Return the active Stage.
| int ProgressTracker::Stage::getPercentComplete | ( | int | percent | ) | const |
Get the percentage complete of this Stage.
| percent | This will be returned if there are no sub-stages. |
| std::string ProgressTracker::Stage::getActiveMessage | ( | std::string | message, | |
| std::string | indent | |||
| ) | const |
Get the message associated with this Stage and all sub-stages.
| message | This will be prefixed to the messages of sub-stages. | |
| indent | This string is used to indent messages of sub-stages. |