DSL_progress

<< Click to Display Table of Contents >>

Navigation:  Reference Manual >

DSL_progress

Header file: progress.h


virtual bool Tick(double percComplete=-1, const char *msg=NULL) = 0;

DSL_progress class declares single pure virtual function that must be overridden in the derived classes. SMILE algorithms supporting DSL_progress periodically call  the Tick method with percComplete parameter specifying the percentage (0..100) of work performed so far. If the algorithm cannot predict the number of iterations of its main loop, -1 is used as the percentage.

The string pointed to by msg parameter should be copied if the class derived from DSL_progress uses it for display or logging purposes after the Tick call is finished.

Returning false from Tick causes the calling algorithm to quit with DSL_INTERRUPTED error code.