Home  · Classes  · Annotated Classes  · Modules  · Members  · Namespaces  · Related Pages

ProgressLogger Class Reference

#include <OpenMS/CONCEPT/ProgressLogger.h>

Inheritance diagram for ProgressLogger:

ANDIFile DTA2DFile FeatureFinder InternalCalibration LinearResampler MascotInfile MorphFilter MzDataFile MzXMLFile PeakPicker SignalToNoiseEstimator SmoothFilter TOFCalibration

List of all members.


Detailed Description

Base class for all classes that want to report their progess.

Per default the progress log is disabled. Use setLogType to enable it

Use startProgress, setProgress and endProgress for the actual logging.

Note:
All methods are const, so it can be used through a const reference or in const methods as well!

Public Types

enum  LogType { CMD, GUI, NONE }
 Possible log types. More...

Public Member Functions

 ProgressLogger ()
 Constructor.
 ~ProgressLogger ()
 Destructor.
void setLogType (LogType type) const
 Sets the progress log that should be used. The default type is NONE!
void startProgress (UInt begin, UInt end, const String &label) const
 Initializes the progress display.
void setProgress (UInt value) const
 Sets the current progress.
void endProgress () const
 Ends the progress display.

Protected Attributes

LogType type_
UInt begin_
UInt end_
UInt value_
QProgressDialog * dlg_

Member Enumeration Documentation

enum LogType

Possible log types.

Enumerator:
CMD  Command line progress.
GUI  Progress dialog.
NONE  No progress logging.


Constructor & Destructor Documentation

ProgressLogger (  ) 

Constructor.

~ProgressLogger (  ) 

Destructor.


Member Function Documentation

void setLogType ( LogType  type  )  const

Sets the progress log that should be used. The default type is NONE!

void startProgress ( UInt  begin,
UInt  end,
const String label 
) const

Initializes the progress display.

Sets the progress range from begin to end. If begin equals end, setProgress only indicates that the program is still running, but without showing any absolute progress value.

Sets the label to label.

Note:
Make sure to call setLogType first!

void setProgress ( UInt  value  )  const

Sets the current progress.

void endProgress (  )  const

Ends the progress display.


Member Data Documentation

LogType type_ [mutable, protected]

UInt begin_ [mutable, protected]

UInt end_ [mutable, protected]

UInt value_ [mutable, protected]

QProgressDialog* dlg_ [mutable, protected]


The documentation for this class was generated from the following file:
Generated Tue Apr 1 15:36:43 2008 -- using doxygen 1.5.4 OpenMS / TOPP 1.1