ug4
ug::Progress Class Reference

#include <progress.h>

Public Member Functions

void calc_next_value ()
 
 Progress (int minSecondsUntilProgress=-1)
 
void set (double now)
 
void set (int now)
 
void set (size_t now)
 
void set_length (int l)
 
void setD (double now)
 
void start (double total, std::string msg="")
 
void stop ()
 
 ~Progress ()
 

Private Attributes

bool bStarted
 
double dNextValueToUpdate
 
size_t iNextValueToUpdate
 
int m_length
 
int m_minSecondsUntilProgress
 
std::string m_msg
 
double m_now
 
double m_total
 
int myDepth
 
int posNow
 
double startS
 

Static Private Attributes

static int lastUpdateDepth = -1
 
static int totalDepth = 0
 

Constructor & Destructor Documentation

◆ Progress()

ug::Progress::Progress ( int  minSecondsUntilProgress = -1)

◆ ~Progress()

ug::Progress::~Progress ( )
inline

References stop(), and totalDepth.

Member Function Documentation

◆ calc_next_value()

void ug::Progress::calc_next_value ( )
inline

References dNextValueToUpdate, iNextValueToUpdate, m_length, m_total, and posNow.

Referenced by setD(), and start().

◆ set() [1/3]

void ug::Progress::set ( double  now)
inline

References dNextValueToUpdate, and setD().

◆ set() [2/3]

void ug::Progress::set ( int  now)
inline

References iNextValueToUpdate, and setD().

◆ set() [3/3]

void ug::Progress::set ( size_t  now)
inline

References iNextValueToUpdate, and setD().

Referenced by setD().

◆ set_length()

void ug::Progress::set_length ( int  l)
inline

References m_length.

◆ setD()

◆ start()

void ug::Progress::start ( double  total,
std::string  msg = "" 
)

◆ stop()

Member Data Documentation

◆ bStarted

bool ug::Progress::bStarted
private

Referenced by Progress(), setD(), start(), and stop().

◆ dNextValueToUpdate

double ug::Progress::dNextValueToUpdate
private

Referenced by calc_next_value(), and set().

◆ iNextValueToUpdate

size_t ug::Progress::iNextValueToUpdate
private

Referenced by calc_next_value(), and set().

◆ lastUpdateDepth

int ug::Progress::lastUpdateDepth = -1
staticprivate

Referenced by setD(), and stop().

◆ m_length

int ug::Progress::m_length
private

◆ m_minSecondsUntilProgress

int ug::Progress::m_minSecondsUntilProgress
private

Referenced by Progress(), setD(), and stop().

◆ m_msg

std::string ug::Progress::m_msg
private

Referenced by setD(), start(), and stop().

◆ m_now

double ug::Progress::m_now
private

Referenced by setD(), start(), and stop().

◆ m_total

double ug::Progress::m_total
private

Referenced by calc_next_value(), setD(), start(), and stop().

◆ myDepth

int ug::Progress::myDepth
private

Referenced by Progress(), setD(), and stop().

◆ posNow

int ug::Progress::posNow
private

◆ startS

double ug::Progress::startS
private

Referenced by setD(), start(), and stop().

◆ totalDepth

int ug::Progress::totalDepth = 0
staticprivate

Referenced by Progress(), and ~Progress().


The documentation for this class was generated from the following files: